Messages in this thread | | | Date | Fri, 16 Apr 1999 14:49:10 -0700 (PDT) | From | Linux Lists <> | Subject | Re: Weird PCI problem |
| |
On Thu, 15 Apr 1999, Gerard Roudier wrote: > > Could it be possible that bit 0 is just writable for this base address > register. You can verify that by hacking appropriately the Cyclades driver > in its detection routine. You may try for example: > > - Read the value of the offending base address reg. and save it. > - Write 1 to that base address reg., then read it and print the value. > - Write 0 to that base address, then read it and print the value. > - Restore the value of that base address.
Ok, did that in a machine where the Cyclom-Y board is assigned the proper address (i.e., the address type it has requested):
- Before:
pcibios_read_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, (unsigned int *) &cy_pci_addr2);
- After:
pcibios_read_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, (unsigned int *) &cy_pci_addr2); printk("got 0x%lx ; ", cy_pci_addr2); cy_pci_addr_tmp = cy_pci_addr2; cy_pci_addr2 |= 0x01; pcibios_write_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, cy_pci_addr2); printk("wrote 0x%lx ; ", cy_pci_addr2); pcibios_read_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, (unsigned int *) &cy_pci_addr2); printk("got 0x%lx\n", cy_pci_addr2); cy_pci_addr2 = 0xffffffff; pcibios_write_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, cy_pci_addr2); printk("wrote 0x%lx ; ", cy_pci_addr2); pcibios_read_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, (unsigned int *) &cy_pci_addr2); printk("got 0x%lx\n", cy_pci_addr2); pcibios_write_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, cy_pci_addr_tmp);
pcibios_read_config_dword(cyy_bus, cyy_dev_fn, PCI_BASE_ADDRESS_2, (unsigned int *) &cy_pci_addr2);
Results:
Cyclades driver 2.1.2.1 1999/04/08 16:17:18 built Apr 16 1999 14:52:03 got 0xe0310000 ; wrote 0xe0310001 ; got 0xe0310000 wrote 0xffffffff ; got 0xffffc000 Cyclom-Y/PCI #1: 0x2e88000-0x2e8bfff, IRQ15, 16 channels starting from port 0.
That has shown that, at least by using the Linux kernel PCI interface commands (pcibios_read/write_config), I'm not able to change that bit. Furthermore, it has shown that I can't write to the last 14 bits [13-0] of the base address register.
Again, this was done in a machine where the Cyclom-Y board is assigned the proper address (i.e., the address type it has requested). Do you think that this test would yell a different result if run on the "deffective" system ??
Regards, Ivan
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |