usb: musb: am35x: use SIMPLE_DEV_PM_OPS
PATCH 1/4 usb: musb: am35x: use SIMPLE_DEV_PM_OPS
This makes am35x_pm_ops const.
Also, checkpatch.pl complains about the use of DEV_PM_OPS:
ERROR: Macros with complex values should be enclosed in parenthesis
--- drivers/usb/musb/am35x.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
drivers/usb/musb/am35x.c +2 -5
@@ -616,12 +616,9 @@ static int am35x_resume(struct device *dev)return 0 ; } -static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume); -#define DEV_PM_OPS &am35x_pm_ops +#define DEV_PM_OPS (&am35x_pm_ops)#else #define DEV_PM_OPS NULL#endif
Signature · 1 line
1.8.3.1
PATCH 2/4 usb: musb: blackfin: use SIMPLE_DEV_PM_OPS
This makes bfin_pm_ops const.
Also, checkpatch.pl complains about the use of DEV_PM_OPS:
ERROR: Macros with complex values should be enclosed in parenthesis
--- drivers/usb/musb/blackfin.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)
drivers/usb/musb/blackfin.c +2 -5
@@ -562,12 +562,9 @@ static int bfin_resume(struct device *dev)return 0 ; } -static struct dev_pm_ops bfin_pm_ops = { - .suspend = bfin_suspend, - .resume = bfin_resume, -}; +static SIMPLE_DEV_PM_OPS(bfin_pm_ops, bfin_suspend, bfin_resume); -#define DEV_PM_OPS &bfin_pm_ops +#define DEV_PM_OPS (&bfin_pm_ops)#else #define DEV_PM_OPS NULL#endif
Signature · 1 line
1.8.3.1
PATCH 3/4 usb: musb: omap2430: use SIMPLE_DEV_PM_OPS
In reply to Daniel MackThis makes omap2430_pm_ops const.
--- drivers/usb/musb/omap2430.c | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-)
drivers/usb/musb/omap2430.c +3 -4
@@ -660,10 +660,9 @@ static int omap2430_runtime_resume(struct device *dev)return 0 ; } -static struct dev_pm_ops omap2430_pm_ops = { - .runtime_suspend = omap2430_runtime_suspend, - .runtime_resume = omap2430_runtime_resume, -}; +static SIMPLE_DEV_PM_OPS(omap2430_pm_ops, + omap2430_runtime_suspend, + omap2430_runtime_resume);#define DEV_PM_OPS (&omap2430_pm_ops)#else
Signature · 1 line
1.8.3.1
PATCH 4/4 usb: musb: ux500: use SIMPLE_DEV_PM_OPS
In reply to Daniel MackJust a cosmetic change to bring this file in line with other musb platform drivers.
--- drivers/usb/musb/ux500.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/usb/musb/ux500.c +1 -4
@@ -377,10 +377,7 @@ static int ux500_resume(struct device *dev)return 0 ; } -static const struct dev_pm_ops ux500_pm_ops = { - .suspend = ux500_suspend, - .resume = ux500_resume, -}; +static SIMPLE_DEV_PM_OPS(ux500_pm_ops, ux500_suspend, ux500_resume);#define DEV_PM_OPS (&ux500_pm_ops)#else
Signature · 1 line
1.8.3.1
Hi,
Quoted 16 lines · Daniel Mack
This makes
am35x_pm_opsconst.Also, checkpatch.pl complains about the use of
DEV_PM_OPS:ERROR: Macros with complex values should be enclosed in parenthesis
Signed-off-by Daniel Mack <[email protected]>--- drivers/usb/musb/am35x.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-)drivers/usb/musb/am35x.c +0
-0
drivers/usb/musb/am35x.c static int am35x_resume(struct device *dev) · line 619
Quoted 8 lines
drivers/usb/musb/am35x.c +1
-4@@ -616,12 +616,9 @@ static int am35x_resume(struct device *dev)return 0 ; } -static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume);
you could as well remove the DEV_PM_OPS trickery. Ditto for all other patches
Signature · 1 line
balbi
Quoted 10 lines · Felipe Balbi
drivers/usb/musb/am35x.c static int am35x_resume(struct device *dev) · line 619
Quoted 5 lines · Daniel Mack
drivers/usb/musb/am35x.c +1
-4-static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume);you could as well remove the
DEV_PM_OPStrickery. Ditto for all other patches
Yes, I noticed that too. That's why I sent out a v2 of the series :)
Thanks,
Daniel
Quoted 12 lines · Daniel Mack
Quoted 10 lines · Felipe Balbi
drivers/usb/musb/am35x.c static int am35x_resume(struct device *dev) · line 619
Quoted 5 lines · Daniel Mack
drivers/usb/musb/am35x.c +1
-4-static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume);you could as well remove the
DEV_PM_OPStrickery. Ditto for all other patches
Quoted 1 line
Yes, I noticed that too. That's why I sent out a v2 of the series :)
Awesome :-) Thanks dude
Signature · 1 line
balbi
Quoted 13 lines · Felipe Balbi
Quoted 12 lines · Daniel Mack
Quoted 10 lines · Felipe Balbi
drivers/usb/musb/am35x.c static int am35x_resume(struct device *dev) · line 619
Quoted 5 lines · Daniel Mack
drivers/usb/musb/am35x.c +1
-4-static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume);you could as well remove the
DEV_PM_OPStrickery. Ditto for all other patches
Quoted 3 lines
Quoted 1 line
Yes, I noticed that too. That's why I sent out a v2 of the series :)
Awesome :-) Thanks dude
So are you happy with this v2?
It's just a cosmetic cleanup after all ...
Thanks,
Daniel
Hi,
Quoted 14 lines · Daniel Mack
Quoted 13 lines · Felipe Balbi
Quoted 12 lines · Daniel Mack
Quoted 10 lines · Felipe Balbi
drivers/usb/musb/am35x.c static int am35x_resume(struct device *dev) · line 619
Quoted 5 lines · Daniel Mack
drivers/usb/musb/am35x.c +1
-4-static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume);you could as well remove the
DEV_PM_OPStrickery. Ditto for all other patches
Quoted 6 lines
Quoted 3 lines
Quoted 1 line
Yes, I noticed that too. That's why I sent out a v2 of the series :)
Awesome :-) Thanks dude
So are you happy with this v2?
It's just a cosmetic cleanup after all ...
I can't see v2 anywhere... The only version I have is the one with DEV_PM_OPS still in it.
Signature · 1 line
balbi
Quoted 17 lines · Felipe Balbi
Quoted 16 lines · Daniel Mack
Quoted 15 lines · Felipe Balbi
Quoted 13 lines · Daniel Mack
Quoted 10 lines · Felipe Balbi
drivers/usb/musb/am35x.c static int am35x_resume(struct device *dev) · line 619
Quoted 5 lines · Daniel Mack
drivers/usb/musb/am35x.c +1
-4-static struct dev_pm_ops am35x_pm_ops = { - .suspend = am35x_suspend, - .resume = am35x_resume, -}; +static SIMPLE_DEV_PM_OPS(am35x_pm_ops, am35x_suspend, am35x_resume);you could as well remove the
DEV_PM_OPStrickery. Ditto for all other patchesYes, I noticed that too. That's why I sent out a v2 of the series :)
Quoted 7 lines
Quoted 4 lines
Quoted 1 line
Awesome :-) Thanks dude
So are you happy with this v2?
It's just a cosmetic cleanup after all ...I can't see v2 anywhere... The only version I have is the one with
DEV_PM_OPSstill in it.
Ok, I'll resend them later.
Daniel
On 30.09.2013 18:25, Felipe Balbi wrote:
Quoted 4 lines · Daniel Mack
Quoted 2 lines
So are you happy with this v2?
Quoted 1 line
It's just a cosmetic cleanup after all ...
I can't see v2 anywhere... The only version I have is the one with
DEV_PM_OPSstill in it.
Seen them this time?
http://marc.info/?l=linux-usb&m=138056774812520&w=2
http://marc.info/?l=linux-usb&m=138056774612517&w=2
http://marc.info/?l=linux-usb&m=138056775012522&w=2
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html