linux-ide.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] include: pci_find_device remove (include/asm-i386/ide.h)
@ 2005-09-10 20:32 Jiri Slaby
  2005-09-10 20:55 ` Jeff Garzik
  0 siblings, 1 reply; 17+ messages in thread
From: Jiri Slaby @ 2005-09-10 20:32 UTC (permalink / raw)
  To: Greg KH; +Cc: Linux Kernel Mailing List, linux-pci, linux-ide, B.Zolnierkiewicz

Generated in 2.6.13-mm2 kernel version.

Signed-off-by: Jiri Slaby <xslaby@fi.muni.cz>

Repost, posted on:
02 Sep 2005

 ide.h |    7 ++++++-
 1 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/include/asm-i386/ide.h b/include/asm-i386/ide.h
--- a/include/asm-i386/ide.h
+++ b/include/asm-i386/ide.h
@@ -41,7 +41,12 @@ static __inline__ int ide_default_irq(un
 
 static __inline__ unsigned long ide_default_io_base(int index)
 {
-	if (pci_find_device(PCI_ANY_ID, PCI_ANY_ID, NULL) == NULL) {
+	struct pci_dev *pdev = pci_get_device(PCI_ANY_ID, PCI_ANY_ID, NULL);
+	unsigned int a = !pdev;
+
+	pci_dev_put(pdev);
+
+	if (a) {
 		switch(index) {
 			case 2: return 0x1e8;
 			case 3: return 0x168;

^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2005-10-06 22:24 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-10 20:32 [PATCH] include: pci_find_device remove (include/asm-i386/ide.h) Jiri Slaby
2005-09-10 20:55 ` Jeff Garzik
2005-09-10 21:19   ` Greg KH
2005-09-10 21:24     ` Jiri Slaby
2005-09-10 21:39     ` Jeff Garzik
2005-09-10 22:33       ` Matthew Wilcox
2005-09-10 23:35         ` Jeff Garzik
2005-09-11  0:34           ` Grant Grundler
2005-09-11  0:47             ` Jeff Garzik
2005-09-11  1:06             ` Alan Cox
2005-09-11  1:24               ` Grant Grundler
2005-09-11  1:30               ` Matthew Wilcox
2005-09-12 10:17                 ` Alan Cox
2005-09-12 11:21                   ` Matthew Wilcox
2005-09-12 12:35                     ` Alan Cox
2005-09-11  0:06     ` Alan Cox
2005-10-06 22:24   ` Jiri Slaby

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).