blob: a4c9baea7b03047ba168f88f91edb2529fbdd068 [file] [log] [blame]
Stefan Reinauerdebb11f2008-10-29 04:46:52 +00001/*
2 * This file is part of the coreboot project.
3 *
Stefan Reinauera8e11682009-03-11 14:54:18 +00004 * Copyright (C) 2008-2009 coresystems GmbH
Stefan Reinauerdebb11f2008-10-29 04:46:52 +00005 *
Stefan Reinauera8e11682009-03-11 14:54:18 +00006 * This program is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU General Public License as
8 * published by the Free Software Foundation; version 2 of
9 * the License.
Stefan Reinauerdebb11f2008-10-29 04:46:52 +000010 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
Stefan Reinauerdebb11f2008-10-29 04:46:52 +000015 */
16
17/* This code should work for all ICH* southbridges with a NIC. */
18
Stefan Reinauerdebb11f2008-10-29 04:46:52 +000019#include <device/device.h>
20#include <device/pci.h>
21#include <device/pci_ids.h>
22
23static void nic_init(struct device *dev)
24{
25 /* Nothing yet */
26}
27
28static struct device_operations nic_ops = {
29 .read_resources = pci_dev_read_resources,
30 .set_resources = pci_dev_set_resources,
31 .enable_resources = pci_dev_enable_resources,
32 .init = nic_init,
33 .scan_bus = 0,
34};
35
36/* 82801GB/GR/GDH/GBM/GHM (ICH7/ICH7R/ICH7DH/ICH7-M/ICH7-M DH) */
37/* Note: 82801GU (ICH7-U) doesn't have a NIC. */
Uwe Hermannbddc6932008-10-29 13:51:31 +000038/* PCI ID loaded from EEPROM. If EEPROM is 0, 0x27dc is used. */
39static const struct pci_driver i82801gx_nic __pci_driver = {
Stefan Reinauerdebb11f2008-10-29 04:46:52 +000040 .ops = &nic_ops,
41 .vendor = PCI_VENDOR_ID_INTEL,
Uwe Hermann5d7a1c82008-10-31 18:41:09 +000042 .device = 0x27dc,
Stefan Reinauerdebb11f2008-10-29 04:46:52 +000043};