Skip to contentSkip to conversation

PM: kill dev_pm_ops platform warning for now

PATCH In review Magnus Damm 3 participants 9 messages Aug 7, 2009 – Aug 10, 2009 Driver core

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 PM: kill dev_pm_ops platform warning for now

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

---

Suitable for 2.6.31-rc.

 drivers/base/platform.c |    3 ---
 1 file changed, 3 deletions(-)
drivers/base/platform.c +0 -3
@@ -483,9 +483,6 @@ int platform_driver_register(struct plat
 		drv->driver.remove = platform_drv_remove;
 	if (drv->shutdown)
 		drv->driver.shutdown = platform_drv_shutdown;
-	if (drv->suspend || drv->resume)
-		pr_warning("Platform driver '%s' needs updating - please use "
-			"dev_pm_ops\n", drv->driver.name);
 
 	return driver_register(&drv->driver);
 }
#1 lore raw
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Greg, do you agree with the patch below?

Rafael

---
From: Magnus Damm <[email protected]>
Subject: PM / Driver Core: Kill dev_pm_ops platform warning for now

Commit 783ea7d4eeefe895f2731fe73ac951e94418927b
(Driver Core: Rework platform suspend/resume, print warning) added a warning message printed for platform drivers that use the legacy PM callbacks rather than struct dev_pm_ops. Unfortunately, this resulted in some confusion and made some people try to convert drivers by replacing the old callbacks with struct dev_pm_ops in automatic way, which generally is not a good idea.

Remove the platform device runtime dev_pm_ops warning for now, because it's annoying to users and it's not really necessary right now.

[rjw: Modified the changelog to be more informative.]

---
 drivers/base/platform.c |    3 ---
 1 file changed, 3 deletions(-)
drivers/base/platform.c +0 -3
Index: linux-2.6/drivers/base/platform.c
===================================================================
@@ -483,9 +483,6 @@ int platform_driver_register(struct plat
 		drv->driver.remove = platform_drv_remove;
 	if (drv->shutdown)
 		drv->driver.shutdown = platform_drv_shutdown;
-	if (drv->suspend || drv->resume)
-		pr_warning("Platform driver '%s' needs updating - please use "
-			"dev_pm_ops\n", drv->driver.name);
 
 	return driver_register(&drv->driver);
 }
Acked-by
#2 lore raw
Quoted 11 lines · Rafael J. Wysocki
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Greg, do you agree with the patch below?

Yes, feel free to add:

to the patch and forward it on.

Or do you need me to forward it?

thanks,

greg k-h

Acked-by
#3 lore raw
In reply to Rafael J. Wysocki
Quoted 11 lines · Rafael J. Wysocki
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Greg, do you agree with the patch below?

Yes, feel free to add:

to the patch and forward it on.

Or do you need me to forward it?

thanks,

greg k-h

#4 lore raw
Quoted 11 lines · Greg KH
Quoted 10 lines · Rafael J. Wysocki
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Quoted 7 lines
Quoted 1 line

Greg, do you agree with the patch below?

Yes, feel free to add:

to the patch and forward it on.

Or do you need me to forward it?

If you have anything more to push to Linus, please push this patch along with it with my ACK. Otherwise, please let me know and I'll push it.

Thanks,
Rafael

#5 lore raw
Quoted 14 lines · Rafael J. Wysocki
Quoted 13 lines · Greg KH
Quoted 11 lines · Rafael J. Wysocki
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Greg, do you agree with the patch below?

Quoted 8 lines
Quoted 5 lines

Yes, feel free to add:

to the patch and forward it on.

Or do you need me to forward it?

If you have anything more to push to Linus, please push this patch along with it with my ACK. Otherwise, please let me know and I'll push it.

I do not have any more driver-core changes to push to Linus for 2.6.31, so please send it with your next push.

thanks,

greg k-h

#6 lore raw
In reply to Rafael J. Wysocki
Quoted 14 lines · Rafael J. Wysocki
Quoted 13 lines · Greg KH
Quoted 11 lines · Rafael J. Wysocki
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Greg, do you agree with the patch below?

Quoted 8 lines
Quoted 5 lines

Yes, feel free to add:

to the patch and forward it on.

Or do you need me to forward it?

If you have anything more to push to Linus, please push this patch along with it with my ACK. Otherwise, please let me know and I'll push it.

I do not have any more driver-core changes to push to Linus for 2.6.31, so please send it with your next push.

thanks,

greg k-h

#7 lore raw
In reply to Greg KH
Quoted 11 lines · Greg KH
Quoted 10 lines · Rafael J. Wysocki
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Quoted 7 lines
Quoted 1 line

Greg, do you agree with the patch below?

Yes, feel free to add:

to the patch and forward it on.

Or do you need me to forward it?

If you have anything more to push to Linus, please push this patch along with it with my ACK. Otherwise, please let me know and I'll push it.

Thanks,
Rafael

#8 lore raw
In reply to Magnus Damm
Quoted 6 lines · Magnus Damm

From: Magnus Damm <[email protected]>

Remove the platform device runtime dev_pm_ops warning for now. No point in upsetting users of non-rc kernels.

Thanks for the patch, I modified the changelog a bit.

Greg, do you agree with the patch below?

Rafael

---
From: Magnus Damm <[email protected]>
Subject: PM / Driver Core: Kill dev_pm_ops platform warning for now

Commit 783ea7d4eeefe895f2731fe73ac951e94418927b
(Driver Core: Rework platform suspend/resume, print warning) added a warning message printed for platform drivers that use the legacy PM callbacks rather than struct dev_pm_ops. Unfortunately, this resulted in some confusion and made some people try to convert drivers by replacing the old callbacks with struct dev_pm_ops in automatic way, which generally is not a good idea.

Remove the platform device runtime dev_pm_ops warning for now, because it's annoying to users and it's not really necessary right now.

[rjw: Modified the changelog to be more informative.]

---
 drivers/base/platform.c |    3 ---
 1 file changed, 3 deletions(-)
drivers/base/platform.c +0 -3
Index: linux-2.6/drivers/base/platform.c
===================================================================
@@ -483,9 +483,6 @@ int platform_driver_register(struct plat
 		drv->driver.remove = platform_drv_remove;
 	if (drv->shutdown)
 		drv->driver.shutdown = platform_drv_shutdown;
-	if (drv->suspend || drv->resume)
-		pr_warning("Platform driver '%s' needs updating - please use "
-			"dev_pm_ops\n", drv->driver.name);
 
 	return driver_register(&drv->driver);
 }