From: Gabriel C <nix.or.die@googlemail.com>
To: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Cc: netdev <netdev@vger.kernel.org>,
tlan-devel@lists.sourceforge.net, chessman@tux.org
Subject: drivers/net/tlan question
Date: Wed, 31 Oct 2007 18:59:02 +0100 [thread overview]
Message-ID: <4728C266.2010600@googlemail.com> (raw)
Hi,
I noticed on current git the following warning with !CONFIG_PCI :
...
drivers/net/tlan.c: In function 'TLan_probe1':
drivers/net/tlan.c:682: warning: label 'err_out' defined but not used
...
I thought a simply #ifdef is missing but looking at TLan_probe1() I got confused about err_out_regions
...
#ifdef CONFIG_PCI
if (pdev) {
rc = pci_enable_device(pdev);
if (rc)
return rc;
rc = pci_request_regions(pdev, TLanSignature);
if (rc) {
printk(KERN_ERR "TLAN: Could not reserve IO regions\n");
goto err_out;
}
}
#endif /* CONFIG_PCI */
dev = alloc_etherdev(sizeof(TLanPrivateInfo));
if (dev == NULL) {
printk(KERN_ERR "TLAN: Could not allocate memory for device.\n");
rc = -ENOMEM;
goto err_out_regions;
}
...
...
err_out_regions:
#ifdef CONFIG_PCI
if (pdev)
pci_release_regions(pdev);
#endif
err_out:
if (pdev)
pci_disable_device(pdev);
return rc;
...
It is possible 'dev' to be NULL with !CONFIG_PCI ? If is true then err_out_regions: does nothing ?
Does this look right ?
Regards,
Gabriel
next reply other threads:[~2007-10-31 17:59 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-31 17:59 Gabriel C [this message]
2007-10-31 18:08 ` [PATCH] tlan list is subscribers-only Gabriel C
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=4728C266.2010600@googlemail.com \
--to=nix.or.die@googlemail.com \
--cc=chessman@tux.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=tlan-devel@lists.sourceforge.net \
/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.