lkml.org 
[lkml]   [2004]   [Feb]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
SubjectRe: [PATCH] PCI Update for 2.6.3-rc1
Date
From
ChangeSet 1.1500.11.16, 2004/02/03 16:54:54-08:00, eike-hotplug@sf-tec.de

[PATCH] PCI Hotplug: make ibm_unconfigure_device void

ibm_unconfigure_device always returns 0, so we do not need to check for a
return value != 0 and can kill the warning. And if the return value is always
the same we don't need a return value. Also some whitespace fixing. And this
time not line wrapped. Really. Absolutely sure. Checked twice.


drivers/pci/hotplug/ibmphp_core.c | 18 ++++++------------
1 files changed, 6 insertions(+), 12 deletions(-)


diff -Nru a/drivers/pci/hotplug/ibmphp_core.c b/drivers/pci/hotplug/ibmphp_core.c
--- a/drivers/pci/hotplug/ibmphp_core.c Mon Feb 9 14:58:42 2004
+++ b/drivers/pci/hotplug/ibmphp_core.c Mon Feb 9 14:58:42 2004
@@ -704,21 +704,20 @@
debug ("%s -- exit\n", __FUNCTION__);
}

-static int ibm_unconfigure_device (struct pci_func *func)
+static void ibm_unconfigure_device(struct pci_func *func)
{
struct pci_dev *temp;
u8 j;

- debug ("inside %s\n", __FUNCTION__);
- debug ("func->device = %x, func->function = %x\n", func->device, func->function);
- debug ("func->device << 3 | 0x0 = %x\n", func->device << 3 | 0x0);
+ debug("inside %s\n", __FUNCTION__);
+ debug("func->device = %x, func->function = %x\n", func->device, func->function);
+ debug("func->device << 3 | 0x0 = %x\n", func->device << 3 | 0x0);

for (j = 0; j < 0x08; j++) {
- temp = pci_find_slot (func->busno, (func->device << 3) | j);
+ temp = pci_find_slot(func->busno, (func->device << 3) | j);
if (temp)
pci_remove_bus_device(temp);
}
- return 0;
}

/*
@@ -1192,12 +1191,7 @@
slot_cur->func->device = slot_cur->device;
}

- if ((rc = ibm_unconfigure_device (slot_cur->func))) {
- err ("removing from kernel failed... \n");
- err ("Please check to see if it was statically linked or is "
- "in use otherwise. (perhaps the driver is not 'hot-removable')\n");
- goto error;
- }
+ ibm_unconfigure_device(slot_cur->func);

/* If we got here from latch suddenly opening on operating card or
a power fault, there's no power to the card, so cannot
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:00    [W:0.060 / U:2.792 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site