Date: Fri, 9 Apr 2004 15:00:11 -0700 (PDT) From: Warner Losh <imp@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 50753 for review Message-ID: <200404092200.i39M0BTl058585@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=50753 Change 50753 by imp@imp_pacopaco on 2004/04/09 14:59:54 IFC @50746 Affected files ... .. //depot/projects/power/sys/dev/acpica/acpi_acad.c#5 integrate .. //depot/projects/power/sys/dev/acpica/acpi_button.c#5 integrate .. //depot/projects/power/sys/dev/acpica/acpi_cmbat.c#5 integrate .. //depot/projects/power/sys/dev/acpica/acpi_cpu.c#6 integrate .. //depot/projects/power/sys/dev/acpica/acpi_ec.c#5 integrate .. //depot/projects/power/sys/dev/acpica/acpi_isab.c#2 integrate .. //depot/projects/power/sys/dev/acpica/acpi_lid.c#4 integrate .. //depot/projects/power/sys/dev/acpica/acpi_pci.c#12 integrate .. //depot/projects/power/sys/dev/acpica/acpi_pcib_acpi.c#4 integrate .. //depot/projects/power/sys/dev/acpica/acpi_pcib_pci.c#2 integrate .. //depot/projects/power/sys/dev/acpica/acpi_resource.c#5 integrate .. //depot/projects/power/sys/dev/acpica/acpi_thermal.c#7 integrate .. //depot/projects/power/sys/dev/acpica/acpi_timer.c#3 integrate .. //depot/projects/power/sys/dev/pccard/pccarddevs#7 integrate .. //depot/projects/power/sys/dev/pccard/pccarddevs.h#7 integrate .. //depot/projects/power/sys/dev/pci/pci.c#11 integrate .. //depot/projects/power/sys/dev/xe/if_xe_pccard.c#5 integrate .. //depot/projects/power/sys/dev/xe/if_xevar.h#3 integrate .. //depot/projects/power/sys/i386/i386/identcpu.c#6 integrate Differences ... ==== //depot/projects/power/sys/dev/acpica/acpi_acad.c#5 (text+ko) ==== @@ -23,7 +23,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/acpica/acpi_acad.c,v 1.21 2004/03/03 18:34:42 njl Exp $ + * $FreeBSD: src/sys/dev/acpica/acpi_acad.c,v 1.22 2004/04/09 18:14:32 njl Exp $ */ #include "opt_acpi.h" @@ -83,6 +83,7 @@ static devclass_t acpi_acad_devclass; DRIVER_MODULE(acpi_acad, acpi, acpi_acad_driver, acpi_acad_devclass, 0, 0); +MODULE_DEPEND(acpi_acad, acpi, 1, 1, 1); static void acpi_acad_get_status(void *context) ==== //depot/projects/power/sys/dev/acpica/acpi_button.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/acpica/acpi_button.c,v 1.20 2004/02/19 18:16:34 njl Exp $ + * $FreeBSD: src/sys/dev/acpica/acpi_button.c,v 1.21 2004/04/09 18:14:32 njl Exp $ */ #include "opt_acpi.h" @@ -83,6 +83,7 @@ static devclass_t acpi_button_devclass; DRIVER_MODULE(acpi_button, acpi, acpi_button_driver, acpi_button_devclass, 0, 0); +MODULE_DEPEND(acpi_button, acpi, 1, 1, 1); static int acpi_button_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_cmbat.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/acpica/acpi_cmbat.c,v 1.27 2003/12/23 18:27:35 njl Exp $ + * $FreeBSD: src/sys/dev/acpica/acpi_cmbat.c,v 1.28 2004/04/09 18:14:32 njl Exp $ */ #include "opt_acpi.h" @@ -110,6 +110,7 @@ static devclass_t acpi_cmbat_devclass; DRIVER_MODULE(acpi_cmbat, acpi, acpi_cmbat_driver, acpi_cmbat_devclass, 0, 0); +MODULE_DEPEND(acpi_cmbat, acpi, 1, 1, 1); static int acpi_cmbat_info_expired(struct timespec *lastupdated) ==== //depot/projects/power/sys/dev/acpica/acpi_cpu.c#6 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_cpu.c,v 1.32 2004/03/17 21:49:47 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_cpu.c,v 1.33 2004/04/09 18:14:32 njl Exp $"); #include "opt_acpi.h" #include <sys/param.h> @@ -184,6 +184,7 @@ static devclass_t acpi_cpu_devclass; DRIVER_MODULE(acpi_cpu, acpi, acpi_cpu_driver, acpi_cpu_devclass, 0, 0); +MODULE_DEPEND(acpi_cpu, acpi, 1, 1, 1); static int acpi_cpu_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_ec.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/acpica/acpi_ec.c,v 1.45 2004/03/17 17:50:24 njl Exp $ + * $FreeBSD: src/sys/dev/acpica/acpi_ec.c,v 1.46 2004/04/09 18:14:32 njl Exp $ */ /****************************************************************************** * @@ -137,7 +137,7 @@ *****************************************************************************/ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_ec.c,v 1.45 2004/03/17 17:50:24 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_ec.c,v 1.46 2004/04/09 18:14:32 njl Exp $"); #include "opt_acpi.h" #include <sys/param.h> @@ -352,6 +352,7 @@ static devclass_t acpi_ec_devclass; DRIVER_MODULE(acpi_ec, acpi, acpi_ec_driver, acpi_ec_devclass, 0, 0); +MODULE_DEPEND(acpi_ec, acpi, 1, 1, 1); /* * Look for an ECDT and if we find one, set up default GPE and ==== //depot/projects/power/sys/dev/acpica/acpi_isab.c#2 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_isab.c,v 1.4 2003/08/24 17:48:01 obrien Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_isab.c,v 1.5 2004/04/09 18:14:32 njl Exp $"); /* * ISA Bridge driver for Generic ISA Bus Devices. See section 10.7 of the @@ -88,6 +88,7 @@ }; DRIVER_MODULE(acpi_isab, acpi, acpi_isab_driver, isab_devclass, 0, 0); +MODULE_DEPEND(acpi_isab, acpi, 1, 1, 1); static int acpi_isab_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_lid.c#4 (text+ko) ==== @@ -28,7 +28,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_lid.c,v 1.16 2004/03/03 18:34:42 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_lid.c,v 1.17 2004/04/09 18:14:32 njl Exp $"); #include "opt_acpi.h" #include <sys/param.h> @@ -75,6 +75,7 @@ static devclass_t acpi_lid_devclass; DRIVER_MODULE(acpi_lid, acpi, acpi_lid_driver, acpi_lid_devclass, 0, 0); +MODULE_DEPEND(acpi_lid, acpi, 1, 1, 1); static int acpi_lid_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_pci.c#12 (text+ko) ==== @@ -27,7 +27,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_pci.c,v 1.11 2004/04/09 15:44:34 imp Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_pci.c,v 1.12 2004/04/09 18:14:32 njl Exp $"); #include "opt_bus.h" @@ -123,8 +123,9 @@ }; DRIVER_MODULE(acpi_pci, pcib, acpi_pci_driver, pci_devclass, 0, 0); +MODULE_DEPEND(acpi_pci, acpi, 1, 1, 1); +MODULE_DEPEND(acpi_pci, pci, 1, 1, 1); MODULE_VERSION(acpi_pci, 1); -MODULE_DEPEND(acpi_pci, pci, 1, 1, 1); static int acpi_pci_read_ivar(device_t dev, device_t child, int which, uintptr_t *result) ==== //depot/projects/power/sys/dev/acpica/acpi_pcib_acpi.c#4 (text+ko) ==== @@ -24,7 +24,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/acpica/acpi_pcib_acpi.c,v 1.31 2004/04/09 15:44:34 imp Exp $ + * $FreeBSD: src/sys/dev/acpica/acpi_pcib_acpi.c,v 1.32 2004/04/09 18:14:32 njl Exp $ */ #include "opt_acpi.h" #include <sys/param.h> @@ -110,6 +110,7 @@ }; DRIVER_MODULE(acpi_pcib, acpi, acpi_pcib_acpi_driver, pcib_devclass, 0, 0); +MODULE_DEPEND(acpi_pcib, acpi, 1, 1, 1); static int acpi_pcib_acpi_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_pcib_pci.c#2 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_pcib_pci.c,v 1.5 2003/08/24 17:48:01 obrien Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_pcib_pci.c,v 1.6 2004/04/09 18:14:32 njl Exp $"); #include "opt_acpi.h" @@ -106,6 +106,7 @@ }; DRIVER_MODULE(acpi_pcib, pci, acpi_pcib_pci_driver, pcib_devclass, 0, 0); +MODULE_DEPEND(acpi_pcib, acpi, 1, 1, 1); static int acpi_pcib_pci_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_resource.c#5 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_resource.c,v 1.22 2004/03/31 17:23:46 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_resource.c,v 1.23 2004/04/09 18:14:32 njl Exp $"); #include "opt_acpi.h" #include <sys/param.h> @@ -568,6 +568,7 @@ static devclass_t acpi_sysresource_devclass; DRIVER_MODULE(acpi_sysresource, acpi, acpi_sysresource_driver, acpi_sysresource_devclass, 0, 0); +MODULE_DEPEND(acpi_sysresource, acpi, 1, 1, 1); static int acpi_sysresource_probe(device_t dev) ==== //depot/projects/power/sys/dev/acpica/acpi_thermal.c#7 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_thermal.c,v 1.41 2004/04/09 06:55:50 njl Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/acpica/acpi_thermal.c,v 1.42 2004/04/09 18:14:32 njl Exp $"); #include "opt_acpi.h" #include <sys/param.h> @@ -137,6 +137,7 @@ static devclass_t acpi_tz_devclass; DRIVER_MODULE(acpi_tz, acpi, acpi_tz_driver, acpi_tz_devclass, 0, 0); +MODULE_DEPEND(acpi_tz, acpi, 1, 1, 1); static struct sysctl_ctx_list acpi_tz_sysctl_ctx; static struct sysctl_oid *acpi_tz_sysctl_tree; ==== //depot/projects/power/sys/dev/acpica/acpi_timer.c#3 (text+ko) ==== @@ -24,7 +24,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/acpica/acpi_timer.c,v 1.27 2004/03/17 17:50:24 njl Exp $ + * $FreeBSD: src/sys/dev/acpica/acpi_timer.c,v 1.28 2004/04/09 18:14:32 njl Exp $ */ #include "opt_acpi.h" #include <sys/param.h> @@ -87,6 +87,7 @@ static devclass_t acpi_timer_devclass; DRIVER_MODULE(acpi_timer, acpi, acpi_timer_driver, acpi_timer_devclass, 0, 0); +MODULE_DEPEND(acpi_timer, acpi, 1, 1, 1); static struct timecounter acpi_timer_timecounter = { acpi_timer_get_timecount_safe, ==== //depot/projects/power/sys/dev/pccard/pccarddevs#7 (text+ko) ==== @@ -1,4 +1,4 @@ -$FreeBSD: src/sys/dev/pccard/pccarddevs,v 1.82 2004/03/25 21:56:28 imp Exp $ +$FreeBSD: src/sys/dev/pccard/pccarddevs,v 1.83 2004/04/09 17:08:12 rsm Exp $ /* $NetBSD: pcmciadevs,v 1.186 2003/09/16 08:26:37 onoe Exp $ */ /* $OpenBSD: pcmciadevs,v 1.93 2002/06/21 08:31:10 henning Exp $ */ @@ -457,17 +457,23 @@ /* Xircom Products */ product XIRCOM CWE1130 0x0007 Xircom Wireless Ethernet Adapter product XIRCOM CE 0x0108 Xircom CreditCard Ethernet -product XIRCOM CE3 0x010a Xircom CreditCard 10/100 Ethernet -product XIRCOM CE2 0x010b Xircom CreditCard Ethernet II +product XIRCOM CE2 0x010a Xircom CreditCard Ethernet II +product XIRCOM CE3 0x010a Xircom CreditCard Ethernet 10/100 +product XIRCOM CE2_2 0x010b Xircom CreditCard Ethernet II product XIRCOM XE2000 0x0153 Xircom XE2000 10/100 Ethernet product XIRCOM CNW_801 0x0801 Xircom CreditCard Netwave (Canada) product XIRCOM CNW_802 0x0802 Xircom CreditCard Netwave (US) product XIRCOM CT2 0x1101 Xircom CreditCard Token Ring II product XIRCOM CEM 0x110a Xircom CreditCard Ethernet + Modem +product XIRCOM CEM2 0x110a Xircom CreditCard Ethernet + Modem +product XIRCOM CEM56 0x110a Xircom CreditCard Ethernet + Modem 56 +product XIRCOM REM10 0x110a Xircom CreditCard Ethernet 10 + Modem 56 product XIRCOM REM56 0x110a Xircom RealPort Ethernet 10/100 + Modem 56 -product XIRCOM CEM28 0x110b Xircom CreditCard Ethernet + Modem 28 -product XIRCOM CEM56 0x110b Xircom CreditCard Ethernet + Modem 56 -product XIRCOM CEM33 0x110d Xircom CreditCard Ethernet + Modem 33 +product XIRCOM XEM5600 0x110a Xircom 10/100 Network + 56K Modem PC Card +product XIRCOM CEM28 0x110b Xircom CreditCard Ethernet + Modem 28.8 +product XIRCOM CEM56_2 0x110b Xircom CreditCard Ethernet + Modem 56 +product XIRCOM CEM33 0x110c Xircom CreditCard Ethernet + Modem 33.6 +product XIRCOM CEM33_2 0x110d Xircom CreditCard Ethernet + Modem 33.6 /* ZONET */ product ZONET ZEN 0x0100 Zonet Zen 10/10 ==== //depot/projects/power/sys/dev/pccard/pccarddevs.h#7 (text+ko) ==== @@ -1,10 +1,10 @@ -/* $FreeBSD: src/sys/dev/pccard/pccarddevs.h,v 1.82 2004/03/25 21:56:43 imp Exp $ */ +/* $FreeBSD: src/sys/dev/pccard/pccarddevs.h,v 1.83 2004/04/09 17:10:12 rsm Exp $ */ /* * THIS FILE AUTOMATICALLY GENERATED. DO NOT EDIT. * * generated from: - * FreeBSD: src/sys/dev/pccard/pccarddevs,v 1.82 2004/03/25 21:56:28 imp Exp + * FreeBSD: src/sys/dev/pccard/pccarddevs,v 1.83 2004/04/09 17:08:12 rsm Exp */ /* $NetBSD: pcmciadevs,v 1.186 2003/09/16 08:26:37 onoe Exp $ */ /* $OpenBSD: pcmciadevs,v 1.93 2002/06/21 08:31:10 henning Exp $ */ @@ -802,12 +802,15 @@ #define PCMCIA_CIS_XIRCOM_CE { NULL, NULL, NULL, NULL } #define PCMCIA_PRODUCT_XIRCOM_CE 0x0108 #define PCMCIA_STR_XIRCOM_CE "Xircom CreditCard Ethernet" +#define PCMCIA_CIS_XIRCOM_CE2 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_CE2 0x010a +#define PCMCIA_STR_XIRCOM_CE2 "Xircom CreditCard Ethernet II" #define PCMCIA_CIS_XIRCOM_CE3 { NULL, NULL, NULL, NULL } #define PCMCIA_PRODUCT_XIRCOM_CE3 0x010a -#define PCMCIA_STR_XIRCOM_CE3 "Xircom CreditCard 10/100 Ethernet" -#define PCMCIA_CIS_XIRCOM_CE2 { NULL, NULL, NULL, NULL } -#define PCMCIA_PRODUCT_XIRCOM_CE2 0x010b -#define PCMCIA_STR_XIRCOM_CE2 "Xircom CreditCard Ethernet II" +#define PCMCIA_STR_XIRCOM_CE3 "Xircom CreditCard Ethernet 10/100" +#define PCMCIA_CIS_XIRCOM_CE2_2 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_CE2_2 0x010b +#define PCMCIA_STR_XIRCOM_CE2_2 "Xircom CreditCard Ethernet II" #define PCMCIA_CIS_XIRCOM_XE2000 { NULL, NULL, NULL, NULL } #define PCMCIA_PRODUCT_XIRCOM_XE2000 0x0153 #define PCMCIA_STR_XIRCOM_XE2000 "Xircom XE2000 10/100 Ethernet" @@ -823,18 +826,33 @@ #define PCMCIA_CIS_XIRCOM_CEM { NULL, NULL, NULL, NULL } #define PCMCIA_PRODUCT_XIRCOM_CEM 0x110a #define PCMCIA_STR_XIRCOM_CEM "Xircom CreditCard Ethernet + Modem" +#define PCMCIA_CIS_XIRCOM_CEM2 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_CEM2 0x110a +#define PCMCIA_STR_XIRCOM_CEM2 "Xircom CreditCard Ethernet + Modem" +#define PCMCIA_CIS_XIRCOM_CEM56 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_CEM56 0x110a +#define PCMCIA_STR_XIRCOM_CEM56 "Xircom CreditCard Ethernet + Modem 56" +#define PCMCIA_CIS_XIRCOM_REM10 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_REM10 0x110a +#define PCMCIA_STR_XIRCOM_REM10 "Xircom CreditCard Ethernet 10 + Modem 56" #define PCMCIA_CIS_XIRCOM_REM56 { NULL, NULL, NULL, NULL } #define PCMCIA_PRODUCT_XIRCOM_REM56 0x110a #define PCMCIA_STR_XIRCOM_REM56 "Xircom RealPort Ethernet 10/100 + Modem 56" +#define PCMCIA_CIS_XIRCOM_XEM5600 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_XEM5600 0x110a +#define PCMCIA_STR_XIRCOM_XEM5600 "Xircom 10/100 Network + 56K Modem PC Card" #define PCMCIA_CIS_XIRCOM_CEM28 { NULL, NULL, NULL, NULL } #define PCMCIA_PRODUCT_XIRCOM_CEM28 0x110b -#define PCMCIA_STR_XIRCOM_CEM28 "Xircom CreditCard Ethernet + Modem 28" -#define PCMCIA_CIS_XIRCOM_CEM56 { NULL, NULL, NULL, NULL } -#define PCMCIA_PRODUCT_XIRCOM_CEM56 0x110b -#define PCMCIA_STR_XIRCOM_CEM56 "Xircom CreditCard Ethernet + Modem 56" +#define PCMCIA_STR_XIRCOM_CEM28 "Xircom CreditCard Ethernet + Modem 28.8" +#define PCMCIA_CIS_XIRCOM_CEM56_2 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_CEM56_2 0x110b +#define PCMCIA_STR_XIRCOM_CEM56_2 "Xircom CreditCard Ethernet + Modem 56" #define PCMCIA_CIS_XIRCOM_CEM33 { NULL, NULL, NULL, NULL } -#define PCMCIA_PRODUCT_XIRCOM_CEM33 0x110d -#define PCMCIA_STR_XIRCOM_CEM33 "Xircom CreditCard Ethernet + Modem 33" +#define PCMCIA_PRODUCT_XIRCOM_CEM33 0x110c +#define PCMCIA_STR_XIRCOM_CEM33 "Xircom CreditCard Ethernet + Modem 33.6" +#define PCMCIA_CIS_XIRCOM_CEM33_2 { NULL, NULL, NULL, NULL } +#define PCMCIA_PRODUCT_XIRCOM_CEM33_2 0x110d +#define PCMCIA_STR_XIRCOM_CEM33_2 "Xircom CreditCard Ethernet + Modem 33.6" /* ZONET */ #define PCMCIA_CIS_ZONET_ZEN { NULL, NULL, NULL, NULL } ==== //depot/projects/power/sys/dev/pci/pci.c#11 (text+ko) ==== @@ -25,7 +25,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sys/dev/pci/pci.c,v 1.238 2004/04/09 15:44:33 imp Exp $ + * $FreeBSD: src/sys/dev/pci/pci.c,v 1.239 2004/04/09 20:41:18 imp Exp $ * */ @@ -1703,9 +1703,11 @@ */ if (dinfo->cfg.hdrtype != 0) return; - printf("pci%d:%d:%d: setting power state D0\n", dinfo->cfg.bus, - dinfo->cfg.slot, dinfo->cfg.func); - pci_set_powerstate(dev, PCI_POWERSTATE_D0); + if (pci_get_powerstate(dev) != PCI_POWERSTATE_D0) { + printf("pci%d:%d:%d: setting power state D0\n", dinfo->cfg.bus, + dinfo->cfg.slot, dinfo->cfg.func); + pci_set_powerstate(dev, PCI_POWERSTATE_D0); + } for (i = 0; i < dinfo->cfg.nummaps; i++) pci_write_config(dev, PCIR_MAPS + i * 4, dinfo->cfg.bar[i], 4); pci_write_config(dev, PCIR_BIOS, dinfo->cfg.bios, 4); @@ -1768,8 +1770,10 @@ */ cls = pci_get_class(dev); if (setstate && cls != PCIC_DISPLAY && cls != PCIC_MEMORY) { - pci_set_powerstate(dev, PCI_POWERSTATE_D3); - printf("pci%d:%d:%d: setting power state D3\n", dinfo->cfg.bus, - dinfo->cfg.slot, dinfo->cfg.func); + if (pci_get_powerstate(dev) != PCI_POWERSTATE_D3) { + printf("pci%d:%d:%d: setting power state D3\n", dinfo->cfg.bus, + dinfo->cfg.slot, dinfo->cfg.func); + pci_set_powerstate(dev, PCI_POWERSTATE_D3); + } } } ==== //depot/projects/power/sys/dev/xe/if_xe_pccard.c#5 (text+ko) ==== @@ -25,7 +25,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/dev/xe/if_xe_pccard.c,v 1.14 2003/11/04 21:09:37 rsm Exp $"); +__FBSDID("$FreeBSD: src/sys/dev/xe/if_xe_pccard.c,v 1.16 2004/04/09 17:34:54 rsm Exp $"); /* xe pccard interface driver */ @@ -53,6 +53,7 @@ #include <dev/pccard/pccardvar.h> #include <dev/pccard/pccarddevs.h> +#include <dev/pccard/pccard_cis.h> #include "card_if.h" /* @@ -75,63 +76,55 @@ #endif -struct xe_vendor_table { - u_int32_t vendor_id; - char *vendor_desc; -} xe_vendor_devs[] = { - { PCMCIA_VENDOR_XIRCOM, "Xircom" }, - { PCMCIA_VENDOR_COMPAQ, "Compaq" }, - { PCMCIA_VENDOR_COMPAQ2, "Compaq" }, /* Maybe Paralon Techologies, Inc */ - { PCMCIA_VENDOR_INTEL, "Intel" }, - { 0, "Unknown" } -}; - #define XE_CARD_TYPE_FLAGS_NO 0x0 #define XE_CARD_TYPE_FLAGS_CE2 0x1 #define XE_CARD_TYPE_FLAGS_MOHAWK 0x2 #define XE_CARD_TYPE_FLAGS_DINGO 0x4 -#define XE_PROD_UMASK 0x11000f -#define XE_PROD_ETHER_UMASK 0x010000 -#define XE_PROD_MODEM_UMASK 0x100000 -#define XE_PROD_SINGLE_ID1 0x010001 -#define XE_PROD_SINGLE_ID2 0x010002 -#define XE_PROD_SINGLE_ID3 0x010003 -#define XE_PROD_MULTI_ID1 0x110001 -#define XE_PROD_MULTI_ID2 0x110002 -#define XE_PROD_MULTI_ID3 0x110003 -#define XE_PROD_MULTI_ID4 0x110004 -#define XE_PROD_MULTI_ID5 0x110005 -#define XE_PROD_MULTI_ID6 0x110006 -#define XE_PROD_MULTI_ID7 0x110007 +#define XE_PROD_ETHER_MASK 0x0100 +#define XE_PROD_MODEM_MASK 0x1000 + +#define XE_BOGUS_MAC_OFFSET 0x90 + +/* MAC vendor prefix used by most Xircom cards is 00:80:c7 */ +#define XE_MAC_ADDR_0 0x00 +#define XE_MAC_ADDR_1 0x80 +#define XE_MAC_ADDR_2 0xc7 + +/* Some (all?) REM56 cards have vendor prefix 00:10:a4 */ +#define XE_REM56_MAC_ADDR_0 0x00 +#define XE_REM56_MAC_ADDR_1 0x10 +#define XE_REM56_MAC_ADDR_2 0xa4 + + +struct xe_pccard_product { + struct pccard_product product; + u_int16_t prodext; + u_int16_t flags; +}; -struct xe_card_type_table { - u_int32_t prod_type; - char *card_type_desc; - u_int32_t flags; -} xe_card_type_devs[] = { - { XE_PROD_MULTI_ID1, "CEM", XE_CARD_TYPE_FLAGS_NO }, - { XE_PROD_MULTI_ID2, "CEM2", XE_CARD_TYPE_FLAGS_CE2 }, - { XE_PROD_MULTI_ID3, "CEM3", XE_CARD_TYPE_FLAGS_CE2 }, - { XE_PROD_MULTI_ID4, "CEM33", XE_CARD_TYPE_FLAGS_CE2 }, - { XE_PROD_MULTI_ID5, "CEM56M", XE_CARD_TYPE_FLAGS_MOHAWK }, - { XE_PROD_MULTI_ID6, "CEM56", XE_CARD_TYPE_FLAGS_MOHAWK | - XE_CARD_TYPE_FLAGS_DINGO }, - { XE_PROD_MULTI_ID7, "CEM56", XE_CARD_TYPE_FLAGS_MOHAWK | - XE_CARD_TYPE_FLAGS_DINGO }, - { XE_PROD_SINGLE_ID1, "CE", XE_CARD_TYPE_FLAGS_NO }, - { XE_PROD_SINGLE_ID2, "CE2", XE_CARD_TYPE_FLAGS_CE2 }, - { XE_PROD_SINGLE_ID3, "CE3", XE_CARD_TYPE_FLAGS_MOHAWK }, - { 0, NULL, -1 } +static const struct xe_pccard_product xe_pccard_products[] = { + { PCMCIA_CARD_D(ACCTON, EN2226, 0), 0x43, XE_CARD_TYPE_FLAGS_MOHAWK }, + { PCMCIA_CARD_D(COMPAQ2, CPQ_10_100, 0), 0x43, XE_CARD_TYPE_FLAGS_MOHAWK }, + { PCMCIA_CARD_D(INTEL, EEPRO100, 0), 0x43, XE_CARD_TYPE_FLAGS_MOHAWK }, + { PCMCIA_CARD_D(XIRCOM, CE, 0), 0x41, XE_CARD_TYPE_FLAGS_NO }, + { PCMCIA_CARD_D(XIRCOM, CE2, 0), 0x41, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CE2, 0), 0x42, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CE2_2, 0), 0x41, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CE2_2, 0), 0x42, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CE3, 0), 0x43, XE_CARD_TYPE_FLAGS_MOHAWK }, + { PCMCIA_CARD_D(XIRCOM, CEM, 0), 0x41, XE_CARD_TYPE_FLAGS_NO }, + { PCMCIA_CARD_D(XIRCOM, CEM2, 0), 0x42, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CEM28, 0), 0x43, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CEM33, 0), 0x44, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CEM33_2, 0), 0x44, XE_CARD_TYPE_FLAGS_CE2 }, + { PCMCIA_CARD_D(XIRCOM, CEM56, 0), 0x45, XE_CARD_TYPE_FLAGS_DINGO }, + { PCMCIA_CARD_D(XIRCOM, CEM56_2, 0), 0x46, XE_CARD_TYPE_FLAGS_DINGO }, + { PCMCIA_CARD_D(XIRCOM, REM56, 0), 0x46, XE_CARD_TYPE_FLAGS_DINGO }, + { PCMCIA_CARD_D(XIRCOM, REM10, 0), 0x47, XE_CARD_TYPE_FLAGS_DINGO }, + { PCMCIA_CARD_D(XIRCOM, XEM5600, 0), 0x56, XE_CARD_TYPE_FLAGS_DINGO }, + { { NULL }, 0, 0 } }; -/* - * Prototypes - */ -static int xe_cemfix(device_t dev); -static struct xe_vendor_table *xe_vendor_lookup(u_int32_t devid, - struct xe_vendor_table *tbl); -static struct xe_card_type_table *xe_card_type_lookup(u_int32_t devid, - struct xe_card_type_table *tbl); /* * Fixing for CEM2, CEM3 and CEM56/REM56 cards. These need some magic to @@ -191,26 +184,71 @@ return (0); } -static struct xe_vendor_table * -xe_vendor_lookup(u_int32_t devid, struct xe_vendor_table *tbl) +/* + * Fixing for CE2-class cards with bogus CIS entry for MAC address. This + * should be in a type 0x22 tuple, but some cards seem to use 0x89. + * This function looks for a sensible MAC address tuple starting at the given + * offset in attribute memory, ignoring the tuple type field. + */ +static int +xe_macfix(device_t dev, int offset) { - while(tbl->vendor_id) { - if(tbl->vendor_id == devid) - return (tbl); - tbl++; - } - return (tbl); /* return Unknown */ -} - -static struct xe_card_type_table * -xe_card_type_lookup(u_int32_t devid, struct xe_card_type_table *tbl) -{ - while(tbl->prod_type) { - if(tbl->prod_type == (devid & XE_PROD_UMASK)) - return (tbl); - tbl++; + struct xe_softc *sc = (struct xe_softc *) device_get_softc(dev); + bus_space_tag_t bst; + bus_space_handle_t bsh; + struct resource *r; + int rid, i; + u_int8_t cisdata[9]; + u_int8_t required[6] = { 0x08, PCCARD_TPLFE_TYPE_LAN_NID, ETHER_ADDR_LEN, + XE_MAC_ADDR_0, XE_MAC_ADDR_1, XE_MAC_ADDR_2 }; + + DEVPRINTF(2, (dev, "macfix\n")); + + rid = 0; + r = bus_alloc_resource(dev, SYS_RES_MEMORY, &rid, 0, + ~0, 4 << 10, RF_ACTIVE); + if (!r) { + device_printf(dev, "macfix: Can't map in attribute memory\n"); + return (-1); + } + + bsh = rman_get_bushandle(r); + bst = rman_get_bustag(r); + + CARD_SET_RES_FLAGS(device_get_parent(dev), dev, SYS_RES_MEMORY, rid, + PCCARD_A_MEM_ATTR); + + /* + * Looking for (relative to offset): + * + * 0x00 0x?? Tuple type (ignored) + * 0x02 0x08 Tuple length (must be 8) + * 0x04 0x04 Address type? (must be 4) + * 0x06 0x06 Address length (must be 6) + * 0x08 0x00 Manufacturer ID, byte 1 + * 0x0a 0x80 Manufacturer ID, byte 2 + * 0x0c 0xc7 Manufacturer ID, byte 3 + * 0x0e 0x?? Card ID, byte 1 + * 0x10 0x?? Card ID, byte 2 + * 0x12 0x?? Card ID, byte 3 + */ + for (i = 0; i < 9; i++) { + cisdata[i] = bus_space_read_1(bst, bsh, offset + (2 * i) + 2); + if (i < 6 && required[i] != cisdata[i]) { + device_printf(dev, "macfix: Can't find valid MAC address\n"); + bus_release_resource(dev, SYS_RES_MEMORY, rid, r); + return (-1); + } + } + + for (i = 0; i < ETHER_ADDR_LEN; i++) { + sc->arpcom.ac_enaddr[i] = cisdata[i + 3]; } - return (NULL); + + bus_release_resource(dev, SYS_RES_MEMORY, rid, r); + + /* success! */ + return (0); } /* @@ -222,20 +260,18 @@ xe_pccard_probe(device_t dev) { struct xe_softc *scp = (struct xe_softc *) device_get_softc(dev); - u_int32_t vendor,prodid,prod; + u_int32_t vendor,product; u_int16_t prodext; const char* vendor_str = NULL; const char* product_str = NULL; const char* cis4_str = NULL; const char *cis3_str=NULL; - struct xe_vendor_table *vendor_itm; - struct xe_card_type_table *card_itm; - int i; + const struct xe_pccard_product *xpp; DEVPRINTF(2, (dev, "pccard_probe\n")); pccard_get_vendor(dev, &vendor); - pccard_get_product(dev, &prodid); + pccard_get_product(dev, &product); pccard_get_prodext(dev, &prodext); pccard_get_vendor_str(dev, &vendor_str); pccard_get_product_str(dev, &product_str); @@ -243,63 +279,70 @@ pccard_get_cis4_str(dev, &cis4_str); DEVPRINTF(1, (dev, "vendor = 0x%04x\n", vendor)); - DEVPRINTF(1, (dev, "product = 0x%04x\n", prodid)); + DEVPRINTF(1, (dev, "product = 0x%04x\n", product)); DEVPRINTF(1, (dev, "prodext = 0x%02x\n", prodext)); DEVPRINTF(1, (dev, "vendor_str = %s\n", vendor_str)); DEVPRINTF(1, (dev, "product_str = %s\n", product_str)); DEVPRINTF(1, (dev, "cis3_str = %s\n", cis3_str)); DEVPRINTF(1, (dev, "cis4_str = %s\n", cis4_str)); + /* - * PCCARD_CISTPL_MANFID = 0x20 + * Possibly already did this search in xe_pccard_match(), + * but we need to do it here anyway to figure out which + * card we have. */ - pccard_get_vendor(dev, &vendor); - vendor_itm = xe_vendor_lookup(vendor, &xe_vendor_devs[0]); - if (vendor_itm == NULL) + for (xpp = xe_pccard_products; xpp->product.pp_vendor != 0; xpp++) { + if (vendor == xpp->product.pp_vendor && + product == xpp->product.pp_product && + prodext == xpp->prodext) + break; + } + + /* Found a match? */ + if (xpp->product.pp_vendor == 0) return (ENODEV); - scp->vendor = vendor_itm->vendor_desc; - pccard_get_product(dev, &prodid); - pccard_get_prodext(dev, &prodext); - /* - * prod(new) = rev, media, prod(old) - * prod(new) = (don't care), (care 0x10 bit), (care 0x0f bit) - */ - prod = (prodid << 8) | prodext; - card_itm = xe_card_type_lookup(prod, &xe_card_type_devs[0]); - if (card_itm == NULL) + + + /* Set card name for logging later */ + if (xpp->product.pp_name != NULL) + device_set_desc(dev, xpp->product.pp_name); + + /* Reject known but unsupported cards */ + if (xpp->flags & XE_CARD_TYPE_FLAGS_NO) { + device_printf(dev, "Sorry, your %s %s card is not supported :(\n", + vendor_str, product_str); return (ENODEV); - scp->card_type = card_itm->card_type_desc; - if (card_itm->prod_type & XE_PROD_MODEM_UMASK) + } + + /* Set various card ID fields in softc */ + scp->vendor = vendor_str; + scp->card_type = product_str; + if (xpp->flags & XE_CARD_TYPE_FLAGS_CE2) + scp->ce2 = 1; + if (xpp->flags & XE_CARD_TYPE_FLAGS_MOHAWK) + scp->mohawk = 1; + if (xpp->flags & XE_CARD_TYPE_FLAGS_DINGO) { + scp->dingo = 1; + scp->mohawk = 1; + } + if (xpp->product.pp_product & XE_PROD_MODEM_MASK) scp->modem = 1; - for(i=1; i!=XE_CARD_TYPE_FLAGS_DINGO; i=i<<1) { - switch(i & card_itm->flags) { - case XE_CARD_TYPE_FLAGS_CE2: - scp->ce2 = 1; break; - case XE_CARD_TYPE_FLAGS_MOHAWK: - scp->mohawk = 1; break; - case XE_CARD_TYPE_FLAGS_DINGO: - scp->dingo = 1; break; - } - } - /* - * PCCARD_CISTPL_VERS_1 = 0x15 - */ - pccard_get_cis3_str(dev, &cis3_str); - if (strcmp(scp->card_type, "CE") == 0) - if (cis3_str != NULL && strcmp(cis3_str, "PS-CE2-10") == 0) - scp->card_type = "CE2"; /* Look for "CE2" string */ - /* - * PCCARD_CISTPL_FUNCE = 0x22 - */ + /* Get MAC address */ pccard_get_ether(dev, scp->arpcom.ac_enaddr); - /* Reject unsupported cards */ - if(strcmp(scp->card_type, "CE") == 0 - || strcmp(scp->card_type, "CEM") == 0) { - device_printf(dev, "Sorry, your %s card is not supported :(\n", - scp->card_type); - return (ENODEV); + /* Deal with bogus MAC address */ + if (xpp->product.pp_vendor == PCMCIA_VENDOR_XIRCOM + && scp->ce2 + && (scp->arpcom.ac_enaddr[0] != XE_MAC_ADDR_0 + || scp->arpcom.ac_enaddr[1] != XE_MAC_ADDR_1 + || scp->arpcom.ac_enaddr[2] != XE_MAC_ADDR_2) + && xe_macfix(dev, XE_BOGUS_MAC_OFFSET) < 0) { + device_printf(dev, + "Unable to find MAC address for your %s card\n", + scp->card_type); + return (ENODEV); } /* Success */ @@ -322,8 +365,8 @@ /* Hack RealPorts into submission */ if (scp->modem && xe_cemfix(dev) < 0) { - device_printf(dev, "Unable to fix your %s combo card\n", - scp->card_type); + device_printf(dev, "Unable to fix your %s %s combo card\n", + scp->vendor, scp->card_type); xe_deactivate(dev); return (ENODEV); } @@ -353,20 +396,22 @@ return (0); } -static const struct pccard_product xe_pccard_products[] = { - PCMCIA_CARD(ACCTON, EN2226, 0), - PCMCIA_CARD(COMPAQ2, CPQ_10_100, 0), - PCMCIA_CARD(INTEL, EEPRO100, 0), - PCMCIA_CARD(XIRCOM, CE, 0), - PCMCIA_CARD(XIRCOM, CE2, 0), - PCMCIA_CARD(XIRCOM, CE3, 0), - PCMCIA_CARD(XIRCOM, CEM, 0), - PCMCIA_CARD(XIRCOM, CEM28, 0), - PCMCIA_CARD(XIRCOM, CEM33, 0), - PCMCIA_CARD(XIRCOM, CEM56, 0), - PCMCIA_CARD(XIRCOM, REM56, 0), - { NULL } -}; +static int +xe_pccard_product_match(device_t dev, const struct pccard_product* ent, int vpfmatch) +{ + const struct xe_pccard_product* xpp; + u_int16_t prodext; + + DEVPRINTF(2, (dev, "pccard_product_match\n")); + + xpp = (const struct xe_pccard_product*)ent; + pccard_get_prodext(dev, &prodext); + + if (xpp->prodext != prodext) + vpfmatch--; + + return (vpfmatch); +} static int xe_pccard_match(device_t dev) @@ -375,12 +420,12 @@ DEVPRINTF(2, (dev, "pccard_match\n")); - if ((pp = pccard_product_lookup(dev, xe_pccard_products, - sizeof(xe_pccard_products[0]), NULL)) != NULL) { - if (pp->pp_name != NULL) - device_set_desc(dev, pp->pp_name); - return (0); - } + pp = (const struct pccard_product*)xe_pccard_products; + + if ((pp = pccard_product_lookup(dev, pp, + sizeof(xe_pccard_products[0]), xe_pccard_product_match)) != NULL) + return (0); + return (EIO); } ==== //depot/projects/power/sys/dev/xe/if_xevar.h#3 (text+ko) ==== @@ -24,7 +24,7 @@ * SUCH DAMAGE. * * $Id: if_xe.c,v 1.20 1999/06/13 19:17:40 scott Exp $ - * $FreeBSD: src/sys/dev/xe/if_xevar.h,v 1.4 2003/10/14 22:51:35 rsm Exp $ + * $FreeBSD: src/sys/dev/xe/if_xevar.h,v 1.5 2004/04/09 17:27:36 rsm Exp $ */ #ifndef DEV_XE_IF_XEDEV_H #define DEV_XE_IF_XEDEV_H @@ -39,8 +39,8 @@ struct callout_handle chand; struct ifnet *ifp; struct ifmedia *ifm; - char *card_type; /* Card model name */ - char *vendor; /* Card manufacturer */ + const char *card_type;/* Card model name */ + const char *vendor; /* Card manufacturer */ device_t dev; /* Device */ bus_space_tag_t bst; /* Bus space tag for card */ bus_space_handle_t bsh; /* Bus space handle for card */ ==== //depot/projects/power/sys/i386/i386/identcpu.c#6 (text+ko) ==== @@ -41,7 +41,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/i386/i386/identcpu.c,v 1.136 2004/04/09 15:01:44 markm Exp $"); +__FBSDID("$FreeBSD: src/sys/i386/i386/identcpu.c,v 1.137 2004/04/09 17:00:03 markm Exp $"); #include "opt_cpu.h" @@ -546,10 +546,10 @@ strcpy(cpu_model, "VIA C3 Ezra-T"); break; case 0x690: + strcpy(cpu_model, "VIA C3 Nehemiah"); do_cpuid(0xc0000000, regs); if (regs[0] == 0xc0000001) { do_cpuid(0xc0000001, regs); - strcpy(cpu_model, "VIA C3 Nehemiah"); if ((cpu_id & 0xf) >= 3) if ((regs[3] & 0x0c) == 0x0c) strcat(cpu_model, "+RNG");
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200404092200.i39M0BTl058585>