On Sat, Sep 10, 2005 at 11:00:34PM +0200, Jiri Slaby wrote:I think so too, but some drivers, that uses pci_find_device are broken for a long time and nobody uses it at all.
Jeff Garzik napsal(a):
Jiri Slaby wrote:
Signed-off-by: Jiri Slaby <xslaby@xxxxxxxxxx>
specialix.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/drivers/char/specialix.c b/drivers/char/specialix.c
--- a/drivers/char/specialix.c
+++ b/drivers/char/specialix.c
@@ -2502,9 +2502,9 @@ static int __init specialix_init(void)
i++;
continue;
}
- pdev = pci_find_device (PCI_VENDOR_ID_SPECIALIX, - PCI_DEVICE_ID_SPECIALIX_IO8, - pdev);
+ pdev = pci_get_device (PCI_VENDOR_ID_SPECIALIX,
+ PCI_DEVICE_ID_SPECIALIX_IO8,
+ pdev);
if (!pdev) break;
if (pci_enable_device(pdev))
@@ -2517,7 +2517,10 @@ static int __init specialix_init(void)
sx_board[i].flags |= SX_BOARD_IS_PCI;
if (!sx_probe(&sx_board[i]))
found ++;
+
}
+ if (i >= SX_NBOARD)
+ pci_dev_put(pdev);
should be converted to PCI probing, rather than this.
I won't do that, i did that for 2 drivers and nobody was interested in that (and its much time left for nothing). These (unrewritten) drivers would be deleted in some time. Greg wants simply wipe this function out.
No, I want it done correctly. If I simply wanted the function removed,
I would have done this kind of wholesale conversion a long time ago.
If the code needs to be converted to the proper pci probing logic,
that's the better way to do it, and that's what should be done.