From: Greg KH <greg@kroah.com>
To: linux-kernel@vger.kernel.org, pcihpd-discuss@lists.sourceforge.net
Subject: Re: [PATCH] PCI hotplug changes for 2.5.63
Date: Mon, 24 Feb 2003 17:16 -0800 [thread overview]
Message-ID: <10461357782385@kroah.com> (raw)
In-Reply-To: <1046135774520@kroah.com>
ChangeSet 1.1022.1.10, 2003/02/24 16:30:40-08:00, greg@kroah.com
[PATCH] Compaq PCI Hotplug: remove unused walk of the device on insertion.
diff -Nru a/drivers/hotplug/cpqphp_pci.c b/drivers/hotplug/cpqphp_pci.c
--- a/drivers/hotplug/cpqphp_pci.c Mon Feb 24 17:15:24 2003
+++ b/drivers/hotplug/cpqphp_pci.c Mon Feb 24 17:15:24 2003
@@ -80,61 +80,14 @@
return fp;
}
-static int configure_visit_pci_dev (struct pci_dev_wrapped *wrapped_dev, struct pci_bus_wrapped *wrapped_bus)
-{
- struct pci_bus* bus = wrapped_bus->bus;
- struct pci_dev* dev = wrapped_dev->dev;
- struct pci_func *temp_func;
- int i=0;
-
- //We need to fix up the hotplug function representation with the linux representation
- do {
- temp_func = cpqhp_slot_find(dev->bus->number, dev->devfn >> 3, i++);
- } while (temp_func && (temp_func->function != (dev->devfn & 0x07)));
-
- if (temp_func) {
- temp_func->pci_dev = dev;
- } else {
- //We did not even find a hotplug rep of the function, create it
- //This code might be taken out if we can guarantee the creation of functions
- //in parallel (hotplug and Linux at the same time).
- dbg("@@@@@@@@@@@ cpqhp_slot_create in %s\n", __FUNCTION__);
- temp_func = cpqhp_slot_create(bus->number);
- if (temp_func == NULL)
- return -ENOMEM;
- temp_func->pci_dev = dev;
- }
-
- //Create /proc/bus/pci proc entry for this device and bus device is on
- //Notify the drivers of the change
- if (temp_func->pci_dev) {
-// pci_insert_device (temp_func->pci_dev, bus);
-// pci_proc_attach_device(temp_func->pci_dev);
-// pci_announce_device_to_drivers(temp_func->pci_dev);
- }
-
- return 0;
-}
-
-
-static struct pci_visit configure_functions = {
- .visit_pci_dev = configure_visit_pci_dev,
-};
-
int cpqhp_configure_device (struct controller* ctrl, struct pci_func* func)
{
unsigned char bus;
struct pci_dev dev0;
struct pci_bus *child;
- struct pci_dev* temp;
int rc = 0;
- struct pci_dev_wrapped wrapped_dev;
- struct pci_bus_wrapped wrapped_bus;
- memset(&wrapped_dev, 0, sizeof(struct pci_dev_wrapped));
- memset(&wrapped_bus, 0, sizeof(struct pci_bus_wrapped));
-
memset(&dev0, 0, sizeof(struct pci_dev));
if (func->pci_dev == NULL)
@@ -162,13 +115,6 @@
}
- temp = func->pci_dev;
-
- if (temp) {
- wrapped_dev.dev = temp;
- wrapped_bus.bus = temp->bus;
- rc = pci_visit_dev(&configure_functions, &wrapped_dev, &wrapped_bus);
- }
return rc;
}
next prev parent reply other threads:[~2003-02-25 1:15 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-25 1:13 [BK PATCH] PCI hotplug changes for 2.5.63 Greg KH
2003-02-25 1:15 ` [PATCH] " Greg KH
2003-02-25 1:15 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH [this message]
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-25 1:16 ` Greg KH
2003-02-28 23:59 ` [BK PATCH] " Greg KH
2003-03-01 18:55 ` Linus Torvalds
2003-03-01 21:38 ` Greg KH
2003-03-01 22:00 ` Linus Torvalds
2003-03-01 22:25 ` Greg KH
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=10461357782385@kroah.com \
--to=greg@kroah.com \
--cc=linux-kernel@vger.kernel.org \
--cc=pcihpd-discuss@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox