From: Greg KH <greg@kroah.com>
To: linux-ia64@vger.kernel.org
Subject: Re: [PATCH 5/6]: hotplug/ia64: SN Hotplug Driver - SN Hotplug Driver code
Date: Fri, 13 May 2005 16:44:29 +0000 [thread overview]
Message-ID: <20050513164429.GH11089@kroah.com> (raw)
In-Reply-To: <42835EAB.7010905@sgi.com>
On Thu, May 12, 2005 at 08:46:03PM -0400, Prarit Bhargava wrote:
> +EXPORT_SYMBOL(sn_pci_fixup_slot);
> +EXPORT_SYMBOL(sn_pci_unfixup_slot);
> +EXPORT_SYMBOL(sn_pci_controller_fixup);
> +EXPORT_SYMBOL(sn_bus_store_sysdata);
> +EXPORT_SYMBOL(sn_bus_free_sysdata);
EXPORT_SYMBOL_GPL() please.
> + for (func = 0; func < num_funcs; func++) {
> + dev = pci_get_slot(slot->pci_bus,
> + PCI_DEVFN(slot->device_num + 1,
> + PCI_FUNC(func)));
> +
> +
> + if (dev) {
Unneeded 2 blank lines, only 1 please.
> +static int sn_pci_hotplug_init(void)
> +{
> + struct pci_bus *pci_bus = NULL;
> + int rc;
> + int registered = 0;
> +
> + INIT_LIST_HEAD(&sn_hp_list);
> +
> + if (sn_sal_rev() < SGI_HOTPLUG_PROM_REV) {
> + printk(KERN_ERR "%s: PROM version must be greater than 4.05\n",
> + __FUNCTION__);
> + return -EPERM;
> + }
> +
> + while ((pci_bus = pci_find_next_bus(pci_bus))) {
> + if (!pci_bus->sysdata)
> + continue;
> +
> + rc = sn_pci_bus_valid(pci_bus);
> + if (rc != 1) {
> + dev_dbg(pci_bus->self, "not a valid hotplug bus\n");
> + continue;
> + }
> + dev_dbg(pci_bus->self, "valid hotplug bus\n");
> +
> + rc = sn_hotplug_slot_register(pci_bus);
> + if (!rc)
> + registered = 1;
> + else {
> + registered = 0;
> + break;
> + }
> + }
How do you recover if you fail the second (or third, or fourth) hotplug bus register? It
looks like the code will die a horrible death...
thanks,
greg k-h
next prev parent reply other threads:[~2005-05-13 16:44 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-12 13:48 [PATCH 5/6]: hotplug/ia64: SN Hotplug Driver - SN Hotplug Driver Prarit Bhargava
2005-05-13 0:46 ` [PATCH 5/6]: hotplug/ia64: SN Hotplug Driver - SN Hotplug Driver code Prarit Bhargava
2005-05-13 16:44 ` Greg KH [this message]
2005-05-17 12:47 ` [PATCH 5/6]: hotplug/ia64: SN Hotplug Driver - SN Hotplug Driver Prarit Bhargava
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=20050513164429.GH11089@kroah.com \
--to=greg@kroah.com \
--cc=linux-ia64@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox