Subject: Re: pci_read_config_byte
To: Ed <garbageout@sbcglobal.net>
From: Allen Briggs <briggs@netbsd.org>
List: tech-kern
Date: 05/28/2005 15:23:29
On Sat, May 28, 2005 at 01:26:29PM -0500, Ed wrote:
> Here's the original Linux code:
> pci_read_config_byte(dev, SIS_DETECT_REGISTER, ®);
> pci_write_config_byte(dev, SIS_DETECT_REGISTER, reg | (1 << 6));
> pci_read_config_word(dev, PCI_DEVICE_ID, &devid);
> if (((devid & 0xfff0) != 0x0960) && (devid != 0x0018)) {
> pci_write_config_byte(dev, SIS_DETECT_REGISTER, reg);
> return;
> }
Oh, that's whacked.
> Here's my (working, but questionably correct) implementation for NetBSD:
That looks like a fine translation.
What does the Linux comment mean about picking up quirks for the 96x ?
-allen
--
Use NetBSD! http://www.NetBSD.org/