acerhdf: convert to dev_pm_ops
Peter Feuerer
maintainerPATCH 1/2 acerhdf: convert to dev_pm_ops
acerhdf: convert to dev_pm_ops
v 1.1:
Add .freeze func ptr to support suspend-to-disk, as suggested by Dmitry Torokhov.
--- drivers/platform/x86/acerhdf.c | 22 +++++++++------------- 1 files changed, 9 insertions(+), 13 deletions(-)
drivers/platform/x86/acerhdf.c +9 -13
@@ -52,7 +52,7 @@*/ #undef START_IN_KERNEL_MODE -#define DRV_VER "0.5.16" +#define DRV_VER "0.5.17"/* * According to the Atom N270 datasheet,
@@ -435,7 +435,7 @@ struct thermal_cooling_device_ops acerhdf_cooling_ops = { };/* suspend / resume functionality */ -static int acerhdf_suspend (struct platform_device *dev,pm_message_t state) +static int acerhdf_suspend (struct device *dev) {if (kernelmode)acerhdf_change_fanstate (ACERHDF_FAN_AUTO );
@@ -446,14 +446,6 @@ static int acerhdf_suspend(struct platform_device *dev, pm_message_t state)return 0 ; } -static int acerhdf_resume (struct platform_device *device) -{ -if (verbose) -pr_notice ("resuming\n" ); - -return 0 ; -} -static int __devinit acerhdf_probe (struct platform_device *device) {return 0 ;
@@ -464,15 +456,19 @@ static int acerhdf_remove(struct platform_device *device)return 0 ; } +static struct dev_pm_ops acerhdf_pm_ops = { + .suspend = acerhdf_suspend, + .freeze = acerhdf_suspend, +}; +static struct platform_driver acerhdf_driver = { .driver = { - .name ="acerhdf" , + .name ="acerhdf" , .owner =THIS_MODULE , + .pm = &acerhdf_pm_ops, }, .probe = acerhdf_probe, .remove = acerhdf_remove, - .suspend = acerhdf_suspend, - .resume = acerhdf_resume, };
Signature · 6 lines
1.6.4 -- Peter Feuerer <[email protected]>
Peter Feuerer
maintainerRe: [PATCH 2/2] acerhdf: additional BIOS versions
Added BIOS versions:
Acer: AOA110-v0.3307, AOA150-v0.3301, AOA150-v0.3307 Pckard Bell: AOA150-v0.3105
--- drivers/platform/x86/acerhdf.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-)
drivers/platform/x86/acerhdf.c +4 -0
@@ -139,13 +139,16 @@ static const struct bios_settings_t bios_tbl[] = { {"Acer", "AOA110", "v0.3301", 0x55, 0x58, {0xaf, 0x00} }, {"Acer", "AOA110", "v0.3304", 0x55, 0x58, {0xaf, 0x00} }, {"Acer", "AOA110", "v0.3305", 0x55, 0x58, {0xaf, 0x00} }, + {"Acer", "AOA110", "v0.3307", 0x55, 0x58, {0xaf, 0x00} }, {"Acer", "AOA110", "v0.3308", 0x55, 0x58, {0x21, 0x00} }, {"Acer", "AOA110", "v0.3309", 0x55, 0x58, {0x21, 0x00} }, {"Acer", "AOA110", "v0.3310", 0x55, 0x58, {0x21, 0x00} },/* AOA150 */ {"Acer", "AOA150", "v0.3114", 0x55, 0x58, {0x20, 0x00} }, + {"Acer", "AOA150", "v0.3301", 0x55, 0x58, {0x20, 0x00} }, {"Acer", "AOA150", "v0.3304", 0x55, 0x58, {0x20, 0x00} }, {"Acer", "AOA150", "v0.3305", 0x55, 0x58, {0x20, 0x00} }, + {"Acer", "AOA150", "v0.3307", 0x55, 0x58, {0x20, 0x00} }, {"Acer", "AOA150", "v0.3308", 0x55, 0x58, {0x20, 0x00} }, {"Acer", "AOA150", "v0.3309", 0x55, 0x58, {0x20, 0x00} }, {"Acer", "AOA150", "v0.3310", 0x55, 0x58, {0x20, 0x00} },
@@ -154,6 +157,7 @@ static const struct bios_settings_t bios_tbl[] = { {"Gateway", "AOA150", "v0.3103", 0x55, 0x58, {0x20, 0x00} }, {"Packard Bell", "DOA150", "v0.3104", 0x55, 0x58, {0x21, 0x00} }, {"Packard Bell", "AOA110", "v0.3105", 0x55, 0x58, {0x21, 0x00} }, + {"Packard Bell", "AOA150", "v0.3105", 0x55, 0x58, {0x20, 0x00} },/* pewpew-terminator */ {"", "", "", 0, 0, {0, 0} } };
Signature · 5 lines
1.6.4 -- Peter Feuerer <[email protected]>
Quoted 10 lines · On Thu, 13 Aug 2009 12:17:22 +0200 Peter Feuerer <[email protected]> wrote:
acerhdf: convert to
dev_pm_opsv 1.1:
Add .freeze func ptr to support suspend-to-disk, as suggested by Dmitry Torokhov.Signed-off-by Borislav Petkov <[email protected]>Signed-off-by Peter Feuerer <[email protected]>Cc Andreas Mohr <[email protected]>Cc Len Brown <[email protected]>
I believe that Boris wrote this, yes?
The way this patch/email was presented implies that you were the primary author.
Please use an explicit From: line right at the top of the changelog (after all the mail headers) to explicitly identify the primary author.
I added a
From: Borislav Petkov <[email protected]>
to my copy of this patch. Please let me kow if that was incorrect.
Peter Feuerer
maintainerQuoted 9 lines · Andrew Morton
Quoted 6 lines · On Thu, 13 Aug 2009 12:17:22 +0200 Peter Feuerer <[email protected]> wrote:
acerhdf: convert to
dev_pm_opsv 1.1:
Add .freeze func ptr to support suspend-to-disk, as suggested by Dmitry Torokhov.
Quoted 6 lines
Quoted 4 lines
Signed-off-by Borislav Petkov <[email protected]>Signed-off-by Peter Feuerer <[email protected]>Cc Andreas Mohr <[email protected]>Cc Len Brown <[email protected]>I believe that Boris wrote this, yes?
Yes, Boris wrote the patch.
Quoted 4 lines
The way this patch/email was presented implies that you were the primary author.
Quoted 8 lines
Please use an explicit From: line right at the top of the changelog (after all the mail headers) to explicitly identify the primary author.
I added a
From: Borislav Petkov <[email protected]>
to my copy of this patch. Please let me kow if that was incorrect.
Thank you very much for adding this line. And thanks for teaching,.. yet another thing I've learned from you :)
--peter