> -----Original Message----- > From: Sergei Shtylyov [mailto:sshtylyov@xxxxxxxxxx] > Sent: Monday, November 28, 2011 8:06 PM > To: Jingoo Han > Cc: Greg Kroah-Hartman; Alan Stern; linux-usb@xxxxxxxxxxxxxxx; Ben Dooks > Subject: Re: [PATCH V2][RESEND] USB: ohci-s3c2410: add PM support > > Hello. > > On 28-11-2011 10:56, Jingoo Han wrote: > > > This patch adds power management support such as suspend and resume > > functions. > > > Signed-off-by: Jingoo Han<jg1.han@xxxxxxxxxxx> > > --- > > drivers/usb/host/ohci-s3c2410.c | 55 > +++++++++++++++++++++++++++++++++++++- > > 1 files changed, 53 insertions(+), 2 deletions(-) > > > diff --git a/drivers/usb/host/ohci-s3c2410.c b/drivers/usb/host/ohci- > s3c2410.c > > index a1877c4..56dcf06 100644 > > --- a/drivers/usb/host/ohci-s3c2410.c > > +++ b/drivers/usb/host/ohci-s3c2410.c > > @@ -486,15 +486,66 @@ static int __devexit > ohci_hcd_s3c2410_drv_remove(struct platform_device *pdev) > > return 0; > > } > > > > +#ifdef CONFIG_PM > [...] > > +#else > > +#define ohci_hcd_s3c2410_drv_suspend NULL > > +#define ohci_hcd_s3c2410_drv_resume NULL > > +#endif > > + > > +static const struct dev_pm_ops ohci_hcd_s3c2410_pm_ops = { > > + .suspend = ohci_hcd_s3c2410_drv_suspend, > > + .resume = ohci_hcd_s3c2410_drv_resume, > > +}; > > + > > static struct platform_driver ohci_hcd_s3c2410_driver = { > > .probe = ohci_hcd_s3c2410_drv_probe, > > .remove = __devexit_p(ohci_hcd_s3c2410_drv_remove), > > .shutdown = usb_hcd_platform_shutdown, > > - /*.suspend = ohci_hcd_s3c2410_drv_suspend, */ > > - /*.resume = ohci_hcd_s3c2410_drv_resume, */ > > .driver = { > > .owner = THIS_MODULE, > > .name = "s3c2410-ohci", > > + .pm =&ohci_hcd_s3c2410_pm_ops, > > Shouldn't contrarywise 'ohci_hcd_s3c2410_pm_ops' be defined as NULL > when > CONFIG_PM=n? I don't think so. ehci-s5p.c works properly in this way. Is there any problem? > > WBR, Sergei ÿ淸º{.nÇ+돴윯돪†+%듚ÿ깁負¥Šwÿº{.nÇ+돴¥Š{깸ëþ)í끾èw*jgП¨¶‰šŽ듶¢jÿ¾?G«앶ÿ◀◁¦j:+v돣ŠwèjØm¶Ÿÿ?®w?듺þf"·hš뤴얎ÿ녪¥