Skip to contentSkip to conversation

Documentation: Ask driver writers to provide PM support

PATCH In review Rafael J. Wysocki 2 participants 4 messages Feb 19, 2007 – Feb 20, 2007

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

PATCH 1/1 Documentation: Ask driver writers to provide PM support

Add a paragraph in Documentation/SubmittingDrivers requesting that the basic PM support be provided by new device drivers.

Add two new documents in Documentation/power/ giving general instructions on debugging the suspend/resume functionality and testing the suspend and resume support in device drivers.

---
 Documentation/SubmittingDrivers            |   15 ++++
 Documentation/power/basic-pm-debugging.txt |  106 +++++++++++++++++++++++++++++
 Documentation/power/drivers-testing.txt    |   42 +++++++++++
 3 files changed, 163 insertions(+)
Documentation/SubmittingDrivers +15 -0
Index: linux-2.6.20-mm2/Documentation/SubmittingDrivers
===================================================================
@@ -87,6 +87,21 @@ Clarity:	It helps if anyone can see how 
 		driver that intentionally obfuscates how the hardware works
 		it will go in the bitbucket.
 
+PM support:	Since Linux is used on many portable and desktop systems, your
+		driver is likely to be used on such a system and therefore it
+		should support basic power management by implementing, if
+		necessary, the .suspend and .resume methods used during the
+		system-wide suspend and resume transitions.  You should verify
+		that your driver correctly handles the suspend and resume, but
+		if you are unable to ensure that, please at least define the
+		.suspend method returning the -ENOSYS ("Function not
+		implemented") error.  You should also try to make sure that your
+		driver uses as little power as possible when it's not doing
+		anything.  For the driver testing instructions see
+		Documentation/power/drivers-testing.txt and for a relatively
+		complete overview of the power management issues related to
+		drivers see Documentation/power/drivers.txt .
+
 Control:	In general if there is active maintainance of a driver by
 		the author then patches will be redirected to them unless
 		they are totally obvious and without need of checking.
Documentation/power/drivers-testing.txt new file +42 -0

42 lines not on this page · raw message

Documentation/power/basic-pm-debugging.txt new file +106 -0

106 lines not on this page · raw message

#1 lore raw
Quoted 2 lines · Rafael J. Wysocki

Add a paragraph in Documentation/SubmittingDrivers requesting that the basic PM support be provided by new device drivers.

Ouch. There was a wrong file name in the SubmittingDrivers patch, sorry.

---
Add a paragraph in Documentation/SubmittingDrivers requesting that the basic PM support be provided by new device drivers.

Add two new documents in Documentation/power/ giving general instructions on debugging the suspend/resume functionality and testing the suspend and resume support in device drivers.

---
 Documentation/SubmittingDrivers            |   15 ++++
 Documentation/power/basic-pm-debugging.txt |  106 +++++++++++++++++++++++++++++
 Documentation/power/drivers-testing.txt    |   42 +++++++++++
 3 files changed, 163 insertions(+)
Documentation/SubmittingDrivers +15 -0
Index: linux-2.6.20-mm2/Documentation/SubmittingDrivers
===================================================================
@@ -87,6 +87,21 @@ Clarity:	It helps if anyone can see how 
 		driver that intentionally obfuscates how the hardware works
 		it will go in the bitbucket.
 
+PM support:	Since Linux is used on many portable and desktop systems, your
+		driver is likely to be used on such a system and therefore it
+		should support basic power management by implementing, if
+		necessary, the .suspend and .resume methods used during the
+		system-wide suspend and resume transitions.  You should verify
+		that your driver correctly handles the suspend and resume, but
+		if you are unable to ensure that, please at least define the
+		.suspend method returning the -ENOSYS ("Function not
+		implemented") error.  You should also try to make sure that your
+		driver uses as little power as possible when it's not doing
+		anything.  For the driver testing instructions see
+		Documentation/power/drivers-testing.txt and for a relatively
+		complete overview of the power management issues related to
+		drivers see Documentation/power/devices.txt .
+
 Control:	In general if there is active maintainance of a driver by
 		the author then patches will be redirected to them unless
 		they are totally obvious and without need of checking.
Documentation/power/drivers-testing.txt new file +42 -0

42 lines not on this page · raw message

Documentation/power/basic-pm-debugging.txt new file +106 -0

106 lines not on this page · raw message

#2 lore raw
Quoted 10 lines · Rafael J. Wysocki
Quoted 2 lines · Rafael J. Wysocki

Add a paragraph in Documentation/SubmittingDrivers requesting that the basic PM support be provided by new device drivers.

Ouch. There was a wrong file name in the SubmittingDrivers patch, sorry.

---
Add a paragraph in Documentation/SubmittingDrivers requesting that the basic PM support be provided by new device drivers.

Quoted 5 lines

Add two new documents in Documentation/power/ giving general instructions on debugging the suspend/resume functionality and testing the suspend and resume support in device drivers.

Looks ok to me.
Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
#3 lore raw
In reply to Rafael J. Wysocki

Hi!

Quoted 7 lines

Add a paragraph in Documentation/SubmittingDrivers requesting that the basic PM support be provided by new device drivers.

Add two new documents in Documentation/power/ giving general instructions on debugging the suspend/resume functionality and testing the suspend and resume support in device drivers.

Quoted 6 lines
---
 Documentation/SubmittingDrivers            |   15 ++++
 Documentation/power/basic-pm-debugging.txt |  106 +++++++++++++++++++++++++++++
 Documentation/power/drivers-testing.txt    |   42 +++++++++++
 3 files changed, 163 insertions(+)

ACK.

Documentation/SubmittingDrivers Clarity: It helps if anyone can see how · line 103

Quoted 1 line
Documentation/SubmittingDrivers +1 -0
+		drivers see Documentation/power/drivers.txt .

Does this file exist for you? Should it exist for me? (I have pretty current -git here...)

Pavel

Signature · 2 lines
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html