Re: [PATCH] pata_acpi: take two
> > +#if defined(CONFIG_ATA_ACPI) > > + /* Prefer the ACPI driver for Nvidia hardware */ > > + if (pdev->vendor == PCI_VENDOR_ID_NVIDIA && ata_pata_acpi_present(pdev)) > > + return -ENODEV; > > +#endif > > /* Check for AMD7411 */ > > if (type == 3) > > /* FIFO is broken */ > > Problem with this approach is it may break distro/initrd setups since > the pata_amd driver appears to be the one that "should" work based on > the PCI ID, so the initrd would end up containing only this driver, Diddums > which will fail out with -ENODEV and cause a boot failure. If the root > filesystem was on a disk driven by this controller, the mkinitrd stuff > would have to "know" that it should also try loading pata_acpi. Indeed they will. > Unless there are some Nvidia boxes out there which don't provide > _GTM/_STM ACPI methods (which seems a bit unlikely given Allen Martin's > comments) then we could potentially move the Nvidia PATA PCI IDs into > the pata_acpi driver, at least if ACPI is enabled in the kernel build.. No we can't. It is a dynamic evaluation. The user may be booting with acpi=off to work around BIOS problems, so the distribution initrd tools will just have to learn this out as they do the sata_nv funnies. (Nvidia is already a special case) - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] pata_acpi: take two
On Wed, 7 Feb 2007 16:30:26 -0800 Andrew Morton <[EMAIL PROTECTED]> wrote: > On Wed, 7 Feb 2007 17:22:20 + > Alan <[EMAIL PROTECTED]> wrote: > > > This is a driver for motherboard SFF style PATA ports that have ACPI > > control methods. > > It needs some work against the current libata tree. > > drivers/ata/pata_acpi.c: In function 'pacpi_port_start': > drivers/ata/pata_acpi.c:259: warning: implicit declaration of function > 'ata_port_stop' > drivers/ata/pata_acpi.c: At top level: > drivers/ata/pata_acpi.c:327: error: 'ata_pio_data_xfer' undeclared here (not > in a function) > drivers/ata/pata_acpi.c:336: error: 'ata_host_stop' undeclared here (not in a > function) Ok added to my todo list to sort out once there's a tree to work from. - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] pata_acpi: take two
Alan wrote: --- linux.vanilla-2.6.20-rc6-mm3/drivers/ata/pata_amd.c 2007-01-31 14:20:10.0 + +++ linux-2.6.20-rc6-mm3/drivers/ata/pata_amd.c 2007-02-06 17:04:19.0 + @@ -642,6 +642,11 @@ if (type == 1 && rev > 0x7) type = 2; +#if defined(CONFIG_ATA_ACPI) + /* Prefer the ACPI driver for Nvidia hardware */ + if (pdev->vendor == PCI_VENDOR_ID_NVIDIA && ata_pata_acpi_present(pdev)) + return -ENODEV; +#endif /* Check for AMD7411 */ if (type == 3) /* FIFO is broken */ Problem with this approach is it may break distro/initrd setups since the pata_amd driver appears to be the one that "should" work based on the PCI ID, so the initrd would end up containing only this driver, which will fail out with -ENODEV and cause a boot failure. If the root filesystem was on a disk driven by this controller, the mkinitrd stuff would have to "know" that it should also try loading pata_acpi. Unless there are some Nvidia boxes out there which don't provide _GTM/_STM ACPI methods (which seems a bit unlikely given Allen Martin's comments) then we could potentially move the Nvidia PATA PCI IDs into the pata_acpi driver, at least if ACPI is enabled in the kernel build.. -- Robert Hancock Saskatoon, SK, Canada To email, remove "nospam" from [EMAIL PROTECTED] Home Page: http://www.roberthancock.com/ - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] pata_acpi: take two
On Wed, 7 Feb 2007 17:22:20 + Alan <[EMAIL PROTECTED]> wrote: > This is a driver for motherboard SFF style PATA ports that have ACPI > control methods. It needs some work against the current libata tree. drivers/ata/pata_acpi.c: In function 'pacpi_port_start': drivers/ata/pata_acpi.c:259: warning: implicit declaration of function 'ata_port_stop' drivers/ata/pata_acpi.c: At top level: drivers/ata/pata_acpi.c:327: error: 'ata_pio_data_xfer' undeclared here (not in a function) drivers/ata/pata_acpi.c:336: error: 'ata_host_stop' undeclared here (not in a function) - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Re: [PATCH] pata_acpi: take two
Hello, Just asking ... in: > +static void *ata_pata_find_handle(struct device *dev, int port) ... > + chan_handle = acpi_get_child(handle, port); > + if (chan_handle == NULL) > + return NULL; > + return chan_handle; > +} why not simply: return acpi_get_child(hadnle, port); ? Regards, Mariusz Kozlowski - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/