use locator defines in "locators.h" to index cf_loc[]
still to be done and/or decided not to be done: replace all *UNK uses in isa code with the native names from locators.h
This commit is contained in:
parent
c0f08c42a8
commit
bd611fe5b6
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: fd.c,v 1.107 1997/06/23 23:46:40 fvdl Exp $ */
|
||||
/* $NetBSD: fd.c,v 1.108 1997/07/17 01:06:27 jtk Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1993, 1994, 1995, 1996
|
||||
|
@ -424,14 +424,15 @@ fdprobe(parent, match, aux)
|
|||
bus_space_handle_t ioh = fdc->sc_ioh;
|
||||
int n;
|
||||
|
||||
if (cf->cf_loc[0] != -1 && cf->cf_loc[0] != drive)
|
||||
if (cf->cf_loc[FDCCF_DRIVE] != FDCCF_DRIVE_DEFAULT &&
|
||||
cf->cf_loc[FDCCF_DRIVE] != drive)
|
||||
return 0;
|
||||
/*
|
||||
* XXX
|
||||
* This is to work around some odd interactions between this driver
|
||||
* and SMC Ethernet cards.
|
||||
*/
|
||||
if (cf->cf_loc[0] == -1 && drive >= 2)
|
||||
if (cf->cf_loc[FDCCF_DRIVE] == FDCCF_DRIVE_DEFAULT && drive >= 2)
|
||||
return 0;
|
||||
|
||||
/* select drive and turn on motor */
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: pms.c,v 1.32 1996/10/13 03:20:09 christos Exp $ */
|
||||
/* $NetBSD: pms.c,v 1.33 1997/07/17 01:06:29 jtk Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1994 Charles Hannum.
|
||||
|
@ -190,7 +190,7 @@ pmsprobe(parent, match, aux)
|
|||
return (0);
|
||||
|
||||
/* Can't wildcard IRQ. */
|
||||
if (cf->cf_loc[0] == -1)
|
||||
if (cf->cf_loc[PCKBDCF_IRQ] == PCKBDCF_IRQ_DEFAULT)
|
||||
return (0);
|
||||
|
||||
pms_dev_cmd(PMS_RESET);
|
||||
|
@ -210,7 +210,7 @@ pmsattach(parent, self, aux)
|
|||
void *aux;
|
||||
{
|
||||
struct pms_softc *sc = (void *)self;
|
||||
int irq = self->dv_cfdata->cf_loc[0];
|
||||
int irq = self->dv_cfdata->cf_loc[PCKBDCF_IRQ];
|
||||
isa_chipset_tag_t ic = aux; /* XXX */
|
||||
|
||||
printf(" irq %d\n", irq);
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: spkr.c,v 1.27 1996/10/13 03:20:10 christos Exp $ */
|
||||
/* $NetBSD: spkr.c,v 1.28 1997/07/17 01:06:30 jtk Exp $ */
|
||||
|
||||
/*
|
||||
* spkr.c -- device driver for console speaker on 80386
|
||||
|
@ -444,7 +444,7 @@ spkrprobe (parent, match, aux)
|
|||
((strcmp(parent->dv_cfdata->cf_driver->cd_name, "pc") != 0) &&
|
||||
(strcmp(parent->dv_cfdata->cf_driver->cd_name, "vt") != 0)))
|
||||
return (0);
|
||||
if (cf->cf_loc[1] != PITAUX_PORT)
|
||||
if (cf->cf_loc[PCKBDCF_PORT] != PITAUX_PORT)
|
||||
return (0);
|
||||
|
||||
return (1);
|
||||
|
@ -458,7 +458,7 @@ spkrattach(parent, self, aux)
|
|||
struct device *self;
|
||||
void *aux;
|
||||
{
|
||||
printf(" port 0x%x\n", self->dv_cfdata->cf_loc[1]);
|
||||
printf(" port 0x%x\n", self->dv_cfdata->cf_loc[PCKBDCF_PORT]);
|
||||
spkr_attached = 1;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue