Add support for the Intel 865 chipset.

MFC after:	3 days
Sponsored by:	The Weather Channel
Approved by:	re (murray)
This commit is contained in:
John Baldwin 2003-05-27 18:23:56 +00:00
parent bf423d4637
commit e9ff34a5e2
4 changed files with 20 additions and 6 deletions

View File

@ -98,6 +98,9 @@ agp_intel_match(device_t dev)
case 0x25318086:
return ("Intel 82860 host to AGP bridge");
case 0x25708086:
return ("Intel 82865 host to AGP bridge");
};
if (pci_get_vendor(dev) == 0x8086)
@ -167,7 +170,8 @@ agp_intel_attach(device_t dev)
pci_write_config(dev, AGP_INTEL_AGPCTRL, 0x2280, 4);
break;
default:
pci_write_config(dev, AGP_INTEL_AGPCTRL, 0x0080, 4);
value = pci_read_config(dev, AGP_INTEL_AGPCTRL, 4);
pci_write_config(dev, AGP_INTEL_AGPCTRL, value | 0x80, 4);
}
/* Enable things, clear errors etc. */
@ -188,6 +192,7 @@ agp_intel_attach(device_t dev)
break;
case 0x1a308086: /* i845 */
case 0x25708086: /* i865 */
pci_write_config(dev, AGP_INTEL_I845_MCHCFG,
(pci_read_config(dev, AGP_INTEL_I845_MCHCFG, 1)
| (1 << 1)), 1);
@ -209,7 +214,8 @@ agp_intel_attach(device_t dev)
case 0x1a308086: /* i845 */
case 0x25308086: /* i850 */
case 0x25318086: /* i860 */
pci_write_config(dev, AGP_INTEL_I8XX_ERRSTS, 0x001c, 2);
case 0x25708086: /* i865 */
pci_write_config(dev, AGP_INTEL_I8XX_ERRSTS, 0x00ff, 2);
break;
default: /* Intel Generic (maybe) */
@ -251,6 +257,7 @@ agp_intel_detach(device_t dev)
& ~(1 << 1)), 1);
case 0x1a308086: /* i845 */
case 0x25708086: /* i865 */
printf("%s: set MCHCFG to %x\n", __func__, (unsigned)
(pci_read_config(dev, AGP_INTEL_I845_MCHCFG, 1)
& ~(1 << 1)));

View File

@ -57,7 +57,7 @@
#define AGP_INTEL_ATTBASE 0xb8
/*
* Config offsets for Intel i820/i840/i845/i850/i860 AGP chipsets.
* Config offsets for Intel i820/i840/i845/i850/i860/i865 AGP chipsets.
*/
#define AGP_INTEL_MCHCFG 0x50
#define AGP_INTEL_I820_RDCR 0x51

View File

@ -98,6 +98,9 @@ agp_intel_match(device_t dev)
case 0x25318086:
return ("Intel 82860 host to AGP bridge");
case 0x25708086:
return ("Intel 82865 host to AGP bridge");
};
if (pci_get_vendor(dev) == 0x8086)
@ -167,7 +170,8 @@ agp_intel_attach(device_t dev)
pci_write_config(dev, AGP_INTEL_AGPCTRL, 0x2280, 4);
break;
default:
pci_write_config(dev, AGP_INTEL_AGPCTRL, 0x0080, 4);
value = pci_read_config(dev, AGP_INTEL_AGPCTRL, 4);
pci_write_config(dev, AGP_INTEL_AGPCTRL, value | 0x80, 4);
}
/* Enable things, clear errors etc. */
@ -188,6 +192,7 @@ agp_intel_attach(device_t dev)
break;
case 0x1a308086: /* i845 */
case 0x25708086: /* i865 */
pci_write_config(dev, AGP_INTEL_I845_MCHCFG,
(pci_read_config(dev, AGP_INTEL_I845_MCHCFG, 1)
| (1 << 1)), 1);
@ -209,7 +214,8 @@ agp_intel_attach(device_t dev)
case 0x1a308086: /* i845 */
case 0x25308086: /* i850 */
case 0x25318086: /* i860 */
pci_write_config(dev, AGP_INTEL_I8XX_ERRSTS, 0x001c, 2);
case 0x25708086: /* i865 */
pci_write_config(dev, AGP_INTEL_I8XX_ERRSTS, 0x00ff, 2);
break;
default: /* Intel Generic (maybe) */
@ -251,6 +257,7 @@ agp_intel_detach(device_t dev)
& ~(1 << 1)), 1);
case 0x1a308086: /* i845 */
case 0x25708086: /* i865 */
printf("%s: set MCHCFG to %x\n", __func__, (unsigned)
(pci_read_config(dev, AGP_INTEL_I845_MCHCFG, 1)
& ~(1 << 1)));

View File

@ -57,7 +57,7 @@
#define AGP_INTEL_ATTBASE 0xb8
/*
* Config offsets for Intel i820/i840/i845/i850/i860 AGP chipsets.
* Config offsets for Intel i820/i840/i845/i850/i860/i865 AGP chipsets.
*/
#define AGP_INTEL_MCHCFG 0x50
#define AGP_INTEL_I820_RDCR 0x51