[lkml]   [2007]   [Feb]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
Messages in this thread
SubjectRe: NAK new drivers without proper power management?
Geert Uytterhoeven schrieb:
> On Mon, 12 Feb 2007, Pavel Machek wrote:

>> > Can't the upper layer just assume -ENOSYS if .resume/.suspend is NULL?
>> > It's nicer if you don't have to implement dummy functions at all.
>> Unfortunately, drivers currently assume "NULL == nothing is needed",

More often than not they assume nothing of the kind.

>> so we'd have t do big search & replace...
> Which means you also cannot easily keep track of which driver supports
> suspend/resume and which doesn't, as there will always be drivers where a
> missing suspend/resume function is correct.

I think those are rare exceptions. They could and should be
asked to make this statement explicit, as you propose:

> Wouldn't it be more sensible to have
> .suspend = suspend_nothing_to_do
> instead, and reserve NULL for `not yet implemented'?

NULL is already taken for 'don't know'. So *two* new values
are needed, one for "nothing to do" and one for "not supported".

Tilman Schmidt E-Mail:
Bonn, Germany
Diese Nachricht besteht zu 100% aus wiederverwerteten Bits.
Ungeöffnet mindestens haltbar bis: (siehe Rückseite)

[unhandled content-type:application/pgp-signature]
 \ /
  Last update: 2007-02-13 11:05    [W:0.109 / U:0.452 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site