]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blob - src/patches/linux-h12y-mmio-quirks.patch
Fix makegraphs settings readerror
[people/pmueller/ipfire-2.x.git] / src / patches / linux-h12y-mmio-quirks.patch
1 --- a/drivers/pci/quirks.c 2008-09-08 20:33:16.000000000 +0200
2 +++ b/drivers/pci/quirks.c 2008-09-11 08:52:32.000000000 +0200
3 @@ -1381,6 +1381,50 @@
4 PCI_DEVICE_ID_TOSHIBA_TC86C001_IDE,
5 quirk_tc86c001_ide);
6
7 +/*
8 + * The Twinhad H12Y assign mmio (0xffbfe800-0xffbfecff)
9 + * resources that seems to be used by an unknown device.
10 + * This quirk reserve more than really used mmio space to
11 + * force change the mmio area of the cardreader and the network chip.
12 + * See http://bugzilla.kerbel.org/show_bug.cgi?id=10231
13 + * and http://bugzilla.kerbel.org/show_bug.cgi?id=9905
14 + * for more details
15 + */
16 +static void __init quirk_h12y_1_mmio(struct pci_dev *dev)
17 +{
18 +/*
19 + * Network Device: Realtek 8139C of Twinhead H12Y
20 + * PCI VENDOR: 0x10EC PCI ID:0x8139
21 + * SUB VENDOR: 0x14FF SUB ID:0xA003
22 + */
23 + struct resource *r = &dev->resource[1];
24 + if ((dev->subsystem_vendor) == 0x14FF &&
25 + (dev->subsystem_device) == 0xA003) {
26 + r->start = 0;
27 + r->end = 0x03ff;
28 + }
29 +}
30 +DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_REALTEK,
31 + PCI_DEVICE_ID_REALTEK_8139,
32 + quirk_h12y_1_mmio);
33 +
34 +static void __init quirk_h12y_2_mmio(struct pci_dev *dev)
35 +{
36 +/*
37 + * SD-Cardreader Device: O2 7120 of Twinhead H12Y
38 + * PCI VENDOR: 0x1217 PCI ID:0x7120
39 + * SUB VENDOR: 0x14FF SUB ID:0xA003
40 + */
41 + struct resource *r = &dev->resource[0];
42 + if ((dev->subsystem_vendor) == 0x14FF &&
43 + (dev->subsystem_device) == 0xA003) {
44 + r->start = 0;
45 + r->end = 0x03ff;
46 + }
47 +}
48 +DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_O2,0x7120,quirk_h12y_2_mmio);
49 +
50 +
51 static void __devinit quirk_netmos(struct pci_dev *dev)
52 {
53 unsigned int num_parallel = (dev->subsystem_device & 0xf0) >> 4;