Skip to contentSkip to conversation

rc: st_rc: Use CONFIG_PM_SLEEP instead of CONFIG_PM for st_rc_suspend() and st_rc_resume()

PATCH In review Chen Gang S 2 participants 3 messages Feb 1, 2015 – Feb 12, 2015

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rc: st_rc: Use CONFIG_PM_SLEEP instead of CONFIG_PM for st_rc_suspend() and st_rc_resume()

st_rc_suspend() and st_rc_resume() depend on CONFIG_PM_SLEEP finally, so they need CONFIG_PM_SLEEP instead of CONFIG_PM, or they will cause build warning (with allmodconfig under xtensa):

CC [M] drivers/media/pci/smipcie/smipcie.o
drivers/media/rc/st_rc.c:338:12: warning: 'st_rc_suspend' defined but not used [-Wunused-function]
static int st_rc_suspend(struct device *dev)

              ^
  drivers/media/rc/st_rc.c:359:12: warning: 'st_rc_resume' defined but not used [-Wunused-function]
   static int st_rc_resume(struct device *dev)
              ^
---
 drivers/media/rc/st_rc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/rc/st_rc.c +1 -1
index 0e758ae..fbfe958 100644
@@ -334,7 +334,7 @@ err:
 	return ret;
 }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
 static int st_rc_suspend(struct device *dev)
 {
 	struct st_rc_device *rc_dev = dev_get_drvdata(dev);
Signature · 1 line
1.9.3
Acked-by on v1 1/1
#1 lore raw

Hi Chen

Quoted 22 lines · Chen Gang S

st_rc_suspend() and st_rc_resume() depend on CONFIG_PM_SLEEP finally, so they need CONFIG_PM_SLEEP instead of CONFIG_PM, or they will cause build warning (with allmodconfig under xtensa):

CC [M] drivers/media/pci/smipcie/smipcie.o
drivers/media/rc/st_rc.c:338:12: warning: 'st_rc_suspend' defined but not used [-Wunused-function]
static int st_rc_suspend(struct device *dev)
^
drivers/media/rc/st_rc.c:359:12: warning: 'st_rc_resume' defined but not used [-Wunused-function]
static int st_rc_resume(struct device *dev)
^

---
  drivers/media/rc/st_rc.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/rc/st_rc.c +0 -0
index 0e758ae..fbfe958 100644

drivers/media/rc/st_rc.c err: · line 340

Quoted 8 lines
drivers/media/rc/st_rc.c +1 -1
@@ -334,7 +334,7 @@ err:
  	return ret;
  }
 
-#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
  static int st_rc_suspend(struct device *dev)
  {
  	struct st_rc_device *rc_dev = dev_get_drvdata(dev);

Thanks

#2 lore raw

Hello Maintainers:

Please help to process this patch, when you have time.

Thanks.

Quoted 20 lines · Patrice Chotard

Hi Chen

Quoted 17 lines · Chen Gang S

st_rc_suspend() and st_rc_resume() depend on CONFIG_PM_SLEEP finally, so they need CONFIG_PM_SLEEP instead of CONFIG_PM, or they will cause build warning (with allmodconfig under xtensa):

CC [M] drivers/media/pci/smipcie/smipcie.o
drivers/media/rc/st_rc.c:338:12: warning: 'st_rc_suspend' defined but not used [-Wunused-function]
static int st_rc_suspend(struct device *dev)
^
drivers/media/rc/st_rc.c:359:12: warning: 'st_rc_resume' defined but not used [-Wunused-function]
static int st_rc_resume(struct device *dev)
^

---
  drivers/media/rc/st_rc.c | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 15 lines

drivers/media/rc/st_rc.c err: · line 340

Quoted 12 lines
drivers/media/rc/st_rc.c +1 -0
index 0e758ae..fbfe958 100644
@@ -334,7 +334,7 @@ err:
      return ret;
  }
  -#ifdef CONFIG_PM
+#ifdef CONFIG_PM_SLEEP
  static int st_rc_suspend(struct device *dev)
  {
      struct st_rc_device *rc_dev = dev_get_drvdata(dev);

Thanks.

Signature · 3 lines
Chen Gang

Open, share, and attitude like air, water, and life which God blessed