PCI: Remove users of pci_enable_device_bars()
A message that is not in the archive (sent off-list or not yet received): [email protected]
Quoted 38 lines · Linux Kernel Mailing List
Commit:
0948391641918b95d8d96c15089eb5ac156850b3PCI: Remove users of
pci_enable_device_bars()This patch converts users of
pci_enable_device_bars()to the new pci_enable_device_{io,mem} interface.The new API fits nicely, except maybe for the QLA case where a bit of code re-organization might be a good idea but I prefer sticking to the simple patch as I don't have hardware to test on.
I'll also need some feedback on the cs5520 change.
Signed-off-by Benjamin Herrenschmidt <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>drivers/ata/pata_cs5520.c +1
-1@@ -229,7 +229,7 @@ static int __devinit cs5520_init_one(struct pci_dev *pdev, const struct pci_devireturn -ENOMEM ;/* Perform set up for DMA */ -if (pci_enable_device_bars (pdev,1 <<2 )) { +if (pci_enable_device_io (pdev)) { printk(KERN_ERR DRV_NAME ": unable to configure BAR2.\n");return -ENODEV ; }drivers/ide/pci/cs5520.c +1
-2@@ -156,8 +156,14 @@ static int __devinit cs5520_init_one(struct pci_dev *dev, const struct pci_devicide_setup_pci_noise (dev, d);/* We must not grab the entire device, it has 'ISA' space in its -BARS too and we will freak out other bits of the kernel */ -if (pci_enable_device_bars (dev,1 <<2 )) { +* BARS too and we will freak out other bits of the kernel
drivers/ide/pci/cs5520.c static int __devinit cs5520_init_one(struct pci_dev *dev, const struct pci_devic · line 169
Quoted 10 lines
drivers/ide/pci/cs5520.c +7
-0+* +* pci_enable_device_bars() is going away. I replaced it with +* IO only enable for now but I'll need confirmation this is +* allright for that device. If not, it will need some kind of +* quirk. --BenH. +*/ +if (pci_enable_device_io (dev)) {printk (KERN_WARNING "%s: Unable to enable 55x0.\n" , d->name);return -ENODEV ; }
So... did the feedback mentioned in the commit log ever appear? :)
Jeff
Quoted 35 lines · Jeff Garzik
Quoted 34 lines · Linux Kernel Mailing List
Commit:
0948391641918b95d8d96c15089eb5ac156850b3PCI: Remove users of
pci_enable_device_bars()This patch converts users of
pci_enable_device_bars()to the new pci_enable_device_{io,mem} interface.The new API fits nicely, except maybe for the QLA case where a bit of code re-organization might be a good idea but I prefer sticking to the simple patch as I don't have hardware to test on.
I'll also need some feedback on the cs5520 change.
Signed-off-by Benjamin Herrenschmidt <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>drivers/ata/pata_cs5520.c +1
-1@@ -229,7 +229,7 @@ static int __devinit cs5520_init_one(struct pci_dev *pdev, const struct pci_devireturn -ENOMEM ;/* Perform set up for DMA */ -if (pci_enable_device_bars (pdev,1 <<2 )) { +if (pci_enable_device_io (pdev)) { printk(KERN_ERR DRV_NAME ": unable to configure BAR2.\n");return -ENODEV ; }drivers/ide/pci/cs5520.c +0
-0@@ -156,8 +156,14 @@ static int __devinit cs5520_init_one(struct pci_dev *dev, const struct pci_devicide_setup_pci_noise (dev, d);
Quoted 16 lines
Quoted 4 lines
drivers/ide/pci/cs5520.c +1
-2/* We must not grab the entire device, it has 'ISA' space in its -BARS too and we will freak out other bits of the kernel */ -if (pci_enable_device_bars (dev,1 <<2 )) { +* BARS too and we will freak out other bits of the kernel drivers/ide/pci/cs5520.c static int __devinit cs5520_init_one(struct pci_dev *dev, const struct pci_devic · line 169
Quoted 10 lines
drivers/ide/pci/cs5520.c +7
-0+* +* pci_enable_device_bars() is going away. I replaced it with +* IO only enable for now but I'll need confirmation this is +* allright for that device. If not, it will need some kind of +* quirk. --BenH. +*/ +if (pci_enable_device_io (dev)) {printk (KERN_WARNING "%s: Unable to enable 55x0.\n" , d->name);return -ENODEV ; }So... did the feedback mentioned in the commit log ever appear? :)
Since Alan has commented on it:
http://lkml.org/lkml/2007/12/17/422
"5520 in fact is always enabled as it is the host bridge. pci_enable_device_io will do just fine. The 5520 fun is if you disable it the system hangs."
I moved on assuming that either submitter or integrator would follow up... but it seems that it didn't happen. :(
PS Could somebody remove the stale comment from cs5520.c?
Thanks,
Bart
Quoted 57 lines · Bartlomiej Zolnierkiewicz
Quoted 35 lines · Jeff Garzik
Quoted 34 lines · Linux Kernel Mailing List
Commit:
0948391641918b95d8d96c15089eb5ac156850b3PCI: Remove users of
pci_enable_device_bars()This patch converts users of
pci_enable_device_bars()to the new pci_enable_device_{io,mem} interface.The new API fits nicely, except maybe for the QLA case where a bit of code re-organization might be a good idea but I prefer sticking to the simple patch as I don't have hardware to test on.
I'll also need some feedback on the cs5520 change.
Signed-off-by Benjamin Herrenschmidt <[email protected]>Signed-off-by Greg Kroah-Hartman <[email protected]>drivers/ata/pata_cs5520.c +1
-1@@ -229,7 +229,7 @@ static int __devinit cs5520_init_one(struct pci_dev *pdev, const struct pci_devireturn -ENOMEM ;/* Perform set up for DMA */ -if (pci_enable_device_bars (pdev,1 <<2 )) { +if (pci_enable_device_io (pdev)) { printk(KERN_ERR DRV_NAME ": unable to configure BAR2.\n");return -ENODEV ; }drivers/ide/pci/cs5520.c +0
-0@@ -156,8 +156,14 @@ static int __devinit cs5520_init_one(struct pci_dev *dev, const struct pci_devicide_setup_pci_noise (dev, d);Quoted 16 lines
Quoted 4 lines
drivers/ide/pci/cs5520.c +1
-2/* We must not grab the entire device, it has 'ISA' space in its -BARS too and we will freak out other bits of the kernel */ -if (pci_enable_device_bars (dev,1 <<2 )) { +* BARS too and we will freak out other bits of the kernel drivers/ide/pci/cs5520.c static int __devinit cs5520_init_one(struct pci_dev *dev, const struct pci_devic · line 169
Quoted 10 lines
drivers/ide/pci/cs5520.c +7
-0+* +* pci_enable_device_bars() is going away. I replaced it with +* IO only enable for now but I'll need confirmation this is +* allright for that device. If not, it will need some kind of +* quirk. --BenH. +*/ +if (pci_enable_device_io (dev)) {printk (KERN_WARNING "%s: Unable to enable 55x0.\n" , d->name);return -ENODEV ; }So... did the feedback mentioned in the commit log ever appear? :)
Since Alan has commented on it:
Quoted 8 lines
"5520 in fact is always enabled as it is the host bridge.
pci_enable_device_iowill do just fine. The 5520 fun is if you disable it the system hangs."I moved on assuming that either submitter or integrator would follow up... but it seems that it didn't happen. :(
PS Could somebody remove the stale comment from
cs5520.c?
Ben, care to send me a patch for this, as it's your change?
thanks,
greg k-h
Quoted 9 lines
Quoted 9 lines
Since Alan has commented on it:
http://lkml.org/lkml/2007/12/17/422
"5520 in fact is always enabled as it is the host bridge.
pci_enable_device_iowill do just fine. The 5520 fun is if you disable it the system hangs."
Quoted 6 lines
Quoted 4 lines
I moved on assuming that either submitter or integrator would follow up... but it seems that it didn't happen. :(
PS Could somebody remove the stale comment from
cs5520.c?Ben, care to send me a patch for this, as it's your change?
Ah sure, will do tomorrow.
Cheers,
Ben.