Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/cardbus Fix i386 CARDBUS build.
details: https://anonhg.NetBSD.org/src/rev/9f4cea080f9c
branches: trunk
changeset: 333075:9f4cea080f9c
user: uebayasi <uebayasi%NetBSD.org@localhost>
date: Fri Oct 17 20:52:00 2014 +0000
description:
Fix i386 CARDBUS build.
diffstat:
sys/dev/cardbus/rbus_ppb.c | 24 +++---------------------
1 files changed, 3 insertions(+), 21 deletions(-)
diffs (80 lines):
diff -r 5fa8c717089d -r 9f4cea080f9c sys/dev/cardbus/rbus_ppb.c
--- a/sys/dev/cardbus/rbus_ppb.c Fri Oct 17 20:49:22 2014 +0000
+++ b/sys/dev/cardbus/rbus_ppb.c Fri Oct 17 20:52:00 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: rbus_ppb.c,v 1.42 2012/02/02 19:43:02 tls Exp $ */
+/* $NetBSD: rbus_ppb.c,v 1.43 2014/10/17 20:52:00 uebayasi Exp $ */
/*
* Copyright (c) 1999 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: rbus_ppb.c,v 1.42 2012/02/02 19:43:02 tls Exp $");
+__KERNEL_RCSID(0, "$NetBSD: rbus_ppb.c,v 1.43 2014/10/17 20:52:00 uebayasi Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -156,23 +156,14 @@
void
rbus_do_header_fixup(pci_chipset_tag_t pc, pcitag_t tag, void *context)
{
- int pin, irq;
int bus, device, function;
- pcireg_t intr, id;
+ pcireg_t intr;
int *pline = (int *)context;
int line = *pline;
pci_decompose_tag(pc, tag, &bus, &device, &function);
- id = pci_conf_read(pc, tag, PCI_ID_REG);
intr = pci_conf_read(pc, tag, PCI_INTERRUPT_REG);
- pin = PCI_INTERRUPT_PIN(intr);
- irq = PCI_INTERRUPT_LINE(intr);
-
-#if 0
- printf("do_header %02x:%02x:%02x pin=%d => line %d\n",
- bus, device, function, pin, line);
-#endif
intr &= ~(PCI_INTERRUPT_LINE_MASK << PCI_INTERRUPT_LINE_SHIFT);
intr |= (line << PCI_INTERRUPT_LINE_SHIFT);
@@ -532,7 +523,6 @@
struct cardbus_softc *sc = rct->sc;
cardbus_function_t *cf = sc->sc_cf;
rbus_tag_t rbustag;
- bus_space_tag_t bustag;
bus_addr_t mask = size -1;
bus_addr_t base = 0;
bus_space_handle_t handle;
@@ -565,11 +555,9 @@
}
if(PCI_MAPREG_TYPE(type) == PCI_MAPREG_TYPE_IO) {
- bustag = sc->sc_iot;
rbustag = rct->iobustags[bus];
bustype = "io";
} else {
- bustag = sc->sc_memt;
rbustag = rct->membustags[bus];
bustype = "mem";
}
@@ -630,16 +618,10 @@
struct pcibus_attach_args pba;
char devinfo[256];
pcireg_t busdata;
- int mybus, rv;
- u_int16_t pciirq;
int minbus, maxbus;
csc->sc_dev = self;
- mybus = ct->ct_bus;
- pciirq = 0;
- rv = 0;
-
pci_devinfo(ca->ca_id, ca->ca_class, 0, devinfo, sizeof(devinfo));
printf(": %s (rev. 0x%02x)\n", devinfo, PCI_REVISION(ca->ca_class));
Home |
Main Index |
Thread Index |
Old Index