mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Francois Romieu <romieu@fr.zoreil.com>
To: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>,
	torvalds@osdl.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: [patch 2.6.10-bk1 4/5] pci-ide: fix the incorrect returns for the generic driver
Date: Thu, 30 Dec 2004 01:07:52 +0100	[thread overview]
Message-ID: <20041230000752.GC2217@electric-eye.fr.zoreil.com> (raw)
In-Reply-To: <20041230000622.GB2217@electric-eye.fr.zoreil.com>

This patch updates ide/pci/generic.c to fix the incorrect returns
causing PCI devices to be left reserved wrongly by the driver. It
doesn't contain the other -ac improvements for pci/generic just these
fixes.

Signed-off-by: Alan Cox <alan@redhat.com>

diff -puN drivers/ide/pci/generic.c~ata-035 drivers/ide/pci/generic.c
--- linux-2.6.10-bk1/drivers/ide/pci/generic.c~ata-035	2004-12-29 23:58:27.261699983 +0100
+++ linux-2.6.10-bk1-romieu/drivers/ide/pci/generic.c	2004-12-29 23:58:27.264699493 +0100
@@ -100,18 +100,18 @@ static int __devinit generic_init_one(st
 	if (dev->vendor == PCI_VENDOR_ID_UMC &&
 	    dev->device == PCI_DEVICE_ID_UMC_UM8886A &&
 	    (!(PCI_FUNC(dev->devfn) & 1)))
-		return 1; /* UM8886A/BF pair */
+		return -ENODEV; /* UM8886A/BF pair */
 
 	if (dev->vendor == PCI_VENDOR_ID_OPTI &&
 	    dev->device == PCI_DEVICE_ID_OPTI_82C558 &&
 	    (!(PCI_FUNC(dev->devfn) & 1)))
-		return 1;
+		return -EAGAIN;
 
 	pci_read_config_word(dev, PCI_COMMAND, &command);
 	if(!(command & PCI_COMMAND_IO))
 	{
 		printk(KERN_INFO "Skipping disabled %s IDE controller.\n", d->name);
-		return 1; 
+		return -EAGAIN; 
 	}
 	ide_setup_pci_device(dev, d);
 	return 0;

_

  reply	other threads:[~2004-12-30  0:12 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-27 14:37 PATCH: 2.6.10 - Incorrect return from PCI ide controller Alan Cox
2004-12-28 20:55 ` Francois Romieu
2004-12-28 21:15   ` Bartlomiej Zolnierkiewicz
2004-12-29  0:09     ` Francois Romieu
2004-12-30  0:03     ` [patch 2.6.10-bk1 1/5] pci-ide: propagation of error code in ide setup Francois Romieu
2004-12-30  0:04       ` [patch 2.6.10-bk1 2/5] pci-ide: clean up error path in do_ide_setup_pci_device Francois Romieu
2004-12-30  0:06         ` [patch 2.6.10-bk1 3/5] pci-ide: propagate the error status in ide_pci_enable/ide_setup_pci_controller Francois Romieu
2004-12-30  0:07           ` Francois Romieu [this message]
2004-12-30  0:09             ` [patch 2.6.10-bk1 5/5] pci-ide: make device drivers code aware of the changes made to ide_setup_pci_device{s} Francois Romieu
2004-12-30  0:21               ` colophon Francois Romieu
2004-12-28 22:12   ` PATCH: 2.6.10 - Incorrect return from PCI ide controller Alan Cox

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=20041230000752.GC2217@electric-eye.fr.zoreil.com \
    --to=romieu@fr.zoreil.com \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=bzolnier@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@osdl.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

all inboxes | Powered by JetHome®