projects
/
openwrt.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[adm5120] add special values for GPIO lines in switch
[openwrt.git]
/
target
/
linux
/
adm5120-2.6
/
files
/
arch
/
mips
/
pci
/
fixup-adm5120.c
diff --git
a/target/linux/adm5120-2.6/files/arch/mips/pci/fixup-adm5120.c
b/target/linux/adm5120-2.6/files/arch/mips/pci/fixup-adm5120.c
index
e838915
..
cf450f0
100644
(file)
--- a/
target/linux/adm5120-2.6/files/arch/mips/pci/fixup-adm5120.c
+++ b/
target/linux/adm5120-2.6/files/arch/mips/pci/fixup-adm5120.c
@@
-25,7
+25,6
@@
*
*/
*
*/
-#include <linux/autoconf.h>
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/init.h>
#include <linux/types.h>
#include <linux/kernel.h>
#include <linux/init.h>
@@
-88,13
+87,14
@@
int __init pcibios_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
int nr_irqs;
int i;
int irq;
int nr_irqs;
int i;
int irq;
-
+
irq = -1;
if (slot < 1 || slot > 3) {
irq = -1;
if (slot < 1 || slot > 3) {
- printk("PCI: slot number %u is not supported\n", slot);
+ printk(KERN_ALERT "PCI: slot number %u is not supported\n",
+ slot);
goto out;
}
goto out;
}
-
+
GETMAP(default);
switch (mips_machtype) {
GETMAP(default);
switch (mips_machtype) {
@@
-112,16
+112,10
@@
int __init pcibios_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
case MACH_ADM5120_P334WT:
/* using default mapping */
break;
case MACH_ADM5120_P334WT:
/* using default mapping */
break;
-#if 0
case MACH_ADM5120_CAS771:
case MACH_ADM5120_CAS771:
- GETMAP(cas771)
+ GETMAP(cas771)
;
break;
break;
- case MACH_ADM5120_CAS630:
- case MACH_ADM5120_CAS670:
- case MACH_ADM5120_CAS700:
- case MACH_ADM5120_CAS790:
- case MACH_ADM5120_CAS861:
-#endif
+
case MACH_ADM5120_NP27G:
case MACH_ADM5120_NP28GHS:
case MACH_ADM5120_WP54AG:
case MACH_ADM5120_NP27G:
case MACH_ADM5120_NP28GHS:
case MACH_ADM5120_WP54AG:
@@
-130,25
+124,24
@@
int __init pcibios_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
case MACH_ADM5120_WPP54AG:
case MACH_ADM5120_WPP54G:
default:
case MACH_ADM5120_WPP54AG:
case MACH_ADM5120_WPP54G:
default:
- printk("PCI: irq map is unknown for %s, using defaults.\n",
- adm5120_board_name());
+ printk(KERN_ALERT "PCI: irq map is unknown, using defaults.\n");
break;
}
break;
}
-
+
for (i=0; i<nr_irqs; i++, p++) {
for (i=0; i<nr_irqs; i++, p++) {
- if ((p->slot == slot) && (PCI_FUNC(dev->devfn) == p->func) &&
+ if ((p->slot == slot) && (PCI_FUNC(dev->devfn) == p->func) &&
(p->pin == pin)) {
irq = p->irq;
break;
}
}
(p->pin == pin)) {
irq = p->irq;
break;
}
}
-
+
if (irq < 0) {
if (irq < 0) {
- printk(KERN_
INFO
"PCI: no irq found for %s pin:%u\n",
+ printk(KERN_
ALERT
"PCI: no irq found for %s pin:%u\n",
pci_name(dev), pin);
} else {
printk(KERN_INFO "PCI: mapping irq for %s pin:%u, irq:%d\n",
pci_name(dev), pin);
} else {
printk(KERN_INFO "PCI: mapping irq for %s pin:%u, irq:%d\n",
- pci_name(dev), pin, irq);
+ pci_name(dev), pin, irq);
}
out:
}
out:
@@
-161,7
+154,7
@@
static void adm5120_pci_fixup(struct pci_dev *dev)
return;
/* setup COMMAND register */
return;
/* setup COMMAND register */
- pci_write_config_word(dev, PCI_COMMAND,
+ pci_write_config_word(dev, PCI_COMMAND,
(PCI_COMMAND_IO | PCI_COMMAND_MEMORY | PCI_COMMAND_MASTER));
/* setup CACHE_LINE_SIZE register */
(PCI_COMMAND_IO | PCI_COMMAND_MEMORY | PCI_COMMAND_MASTER));
/* setup CACHE_LINE_SIZE register */
@@
-172,7
+165,7
@@
static void adm5120_pci_fixup(struct pci_dev *dev)
pci_write_config_dword(dev, PCI_BASE_ADDRESS_1, 0);
}
pci_write_config_dword(dev, PCI_BASE_ADDRESS_1, 0);
}
-DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_ADMTEK, PCI_DEVICE_ID_ADMTEK_ADM5120,
+DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_ADMTEK, PCI_DEVICE_ID_ADMTEK_ADM5120,
adm5120_pci_fixup);
int pcibios_plat_dev_init(struct pci_dev *dev)
adm5120_pci_fixup);
int pcibios_plat_dev_init(struct pci_dev *dev)
This page took
0.024411 seconds
and
4
git commands to generate.