From: Stephen Hemminger <shemminger@osdl.org>
To: Jiri Kosina <jikos@jikos.cz>
Cc: mlindner@syskonnect.de, rroesler@syskonnect.de,
Andrew Morton <akpm@osdl.org>, Jeff Garzik <jeff@garzik.org>,
linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: Re: [PATCH] sk98lin: handle pci_enable_device() return value in skge_resume() properly
Date: Thu, 12 Oct 2006 15:25:12 -0700 [thread overview]
Message-ID: <20061012152512.66f147b8@freekitty> (raw)
In-Reply-To: <Pine.LNX.4.64.0610130002320.29022@twin.jikos.cz>
On Fri, 13 Oct 2006 00:17:50 +0200 (CEST)
Jiri Kosina <jikos@jikos.cz> wrote:
> [PATCH] sk98lin: handle pci_enable_device() return value in skge_resume() properly
>
> Fix missing handling of pci_enable_device() return value in skge_resume()
>
> Signed-off-by: Jiri Kosina <jikos@jikos.cz>
>
> ---
>
> drivers/net/sk98lin/skge.c | 6 +++++-
> 1 files changed, 5 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/sk98lin/skge.c b/drivers/net/sk98lin/skge.c
> index 99e9262..e12fb62 100644
> --- a/drivers/net/sk98lin/skge.c
> +++ b/drivers/net/sk98lin/skge.c
> @@ -5070,7 +5070,11 @@ static int skge_resume(struct pci_dev *p
>
> pci_set_power_state(pdev, PCI_D0);
> pci_restore_state(pdev);
> - pci_enable_device(pdev);
> + if ((ret = pci_enable_device(pdev))) {
> + printk(KERN_ERR "sk98lin: Cannot enable PCI device during resume\n");
> + unregister_netdev(dev);
>
Having the device unregister seems harsh.
Why put condtional on same line?
Why not print device name dev->name.
--
Stephen Hemminger <shemminger@osdl.org>
next prev parent reply other threads:[~2006-10-12 22:28 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-10-12 22:17 [PATCH] sk98lin: handle pci_enable_device() return value in skge_resume() properly Jiri Kosina
2006-10-12 22:25 ` Stephen Hemminger [this message]
2006-10-12 22:38 ` Jiri Kosina
2006-10-12 22:47 ` Stephen Hemminger
2006-10-12 22:57 ` Jiri Kosina
2006-10-13 0:50 ` Andrew Morton
2006-10-13 1:12 ` Jiri Kosina
2007-02-23 23:17 ` [PATCH] sk98lin: handle pci_enable_device() return value in skge_resume() Dmitriy Monakhov
2007-02-24 11:41 ` Dmitriy Monakhov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20061012152512.66f147b8@freekitty \
--to=shemminger@osdl.org \
--cc=akpm@osdl.org \
--cc=jeff@garzik.org \
--cc=jikos@jikos.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=mlindner@syskonnect.de \
--cc=netdev@vger.kernel.org \
--cc=rroesler@syskonnect.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.