[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <472A18D7.7020703@imap.cc>
Date: Thu, 01 Nov 2007 19:20:07 +0100
From: Tilman Schmidt <tilman@...p.cc>
To: Andrew Morton <akpm@...ux-foundation.org>
CC: linux-kernel@...r.kernel.org, gregkh@...e.de,
linux-usb-devel@...ts.sourceforge.net, hjlipp@....de,
kkeil@...e.de, i4ldeveloper@...tserv.isdn4linux.de
Subject: Re: [PATCH 1/2] usb_gigaset: suspend support [v2]
Am 30.10.2007 22:01 schrieb Andrew Morton:
> On Mon, 29 Oct 2007 22:41:30 +0100 (CET)
> Tilman Schmidt <tilman@...p.cc> wrote:
>
>> From: Tilman Schmidt <tilman@...p.cc>
>>
>> Add basic suspend/resume support to the usb_gigaset driver.
>> (Corrected version.)
>>
>
> You're not a big fan of checkpatch, I see.
Sorry. I promise to mend my ways.
>> +static int gigaset_suspend(struct usb_interface *intf, pm_message_t message)
>> +{
>> + struct cardstate *cs;
>> + struct usb_cardstate *ucs;
>> +
>> + if ((cs = usb_get_intfdata(intf)) == NULL ||
>> + (ucs = cs->hw.usb) == NULL) {
>> + err("%s: no cardstate", __func__);
>> + return -EFAULT;
>> + }
>
> Is the above reeeeeely needed? I bet it never happens.
I'm a great believer in defensive programming. :-)
Anyway, to be sure these checks aren't needed, I would need the
assurance that the suspend and resume methods are serialized with
the probe and disconnect methods. Are they?
Thanks,
Tilman
--
Tilman Schmidt E-Mail: tilman@...p.cc
Bonn, Germany
Diese Nachricht besteht zu 100% aus wiederverwerteten Bits.
Ungeöffnet mindestens haltbar bis: (siehe Rückseite)
Download attachment "signature.asc" of type "application/pgp-signature" (254 bytes)
Powered by blists - more mailing lists