>I am having a problem with an onboard AMD 89c970 PCI card on a Hitachi MX
>laptop, running kernel 2.0.31.
>The device IRQ and base address are detected, but the driver fails to
>initialize, exiting in lance_probe1 in lance.c:
> outw(0x0000, ioaddr+LANCE_ADDR); /* Switch to window 0 */
> if (inw(ioaddr+LANCE_DATA) != 0x0004)
> return;
>Anyone have an idea how I can get this device working under linux, so
>I don't have to keep exiting to Win95 to use ethernet?
Several people have reported this problem with the Hitachi laptop.
I have an idea what is happening.
I suspect that you have a BIOS that does not enable the I/O space flag in
the PCI command register.
This flag can be set in the same section of code that the bus master flag is
set.
Try this -- in lance32.c around line 180
________________
if ( ! (pci_command & PCI_COMMAND_MASTER)) {
- printk("PCI Master Bit has not been set. Setting...\n");
- pci_command |= PCI_COMMAND_MASTER;
+ printk("PCI command word was %4.4x, setting...\n", pci_command);
+ pci_command |= PCI_COMMAND_MASTER|PCI_COMMAND_IO;
pcibios_write_config_word(pci_bus, pci_device_fn,
________________
If this works I'll update the code to look (note -- you must also
add 'new_command' to the declaration list).
pcibios_read_config_word(pci_bus, pci_device_fn,
PCI_COMMAND, &pci_command);
new_command = pci_command | PCI_COMMAND_MASTER|PCI_COMMAND_IO;
if (pci_command != new_command) {
printk(KERN_INFO " The PCI BIOS has not enabled this"
" device! Updating PCI command %4.4x->%4.4x.\n",
pci_command, new_command);
pcibios_write_config_word(pci_bus, pci_device_fn,
PCI_COMMAND, new_command);
}
Please send me a report if you try this.
--
USRA-CESDIS, Center of Excellence in Space Data and Information Sciences.
Code 930.5, Goddard Space Flight Center, Greenbelt, MD. 20771
301-286-0882 http://cesdis.gsfc.nasa.gov/pub/people/becker/whoiam.html