Adapt to pci_intr_map change.
This commit is contained in:
parent
f2deab8a4c
commit
7701dc57be
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pci_machdep.h,v 1.1 2000/06/09 05:33:04 soda Exp $ */
|
||||
/* $NetBSD: pci_machdep.h,v 1.2 2001/01/13 10:46:18 ur Exp $ */
|
||||
/* NetBSD: pci_machdep.h,v 1.3 1999/03/19 03:40:46 cgd Exp */
|
||||
|
||||
/*
|
||||
@ -32,6 +32,11 @@
|
||||
* Machine-specific definitions for PCI autoconfiguration.
|
||||
*/
|
||||
|
||||
/*
|
||||
* Forward declarations.
|
||||
*/
|
||||
struct pci_attach_args;
|
||||
|
||||
/*
|
||||
* Types provided to machine-independent PCI code
|
||||
*/
|
||||
@ -52,8 +57,8 @@ struct arc_pci_chipset {
|
||||
int));
|
||||
void (*pc_conf_write) __P((pci_chipset_tag_t, pcitag_t, int,
|
||||
pcireg_t));
|
||||
int (*pc_intr_map) __P((pci_chipset_tag_t, pcitag_t, int,
|
||||
int, pci_intr_handle_t *));
|
||||
int (*pc_intr_map) __P((struct pci_attach_args *,
|
||||
pci_intr_handle_t *));
|
||||
const char *(*pc_intr_string) __P((pci_chipset_tag_t,
|
||||
pci_intr_handle_t));
|
||||
void *(*pc_intr_establish) __P((pci_chipset_tag_t,
|
||||
@ -75,8 +80,8 @@ struct arc_pci_chipset {
|
||||
(*(c)->pc_conf_read)((c), (t), (r))
|
||||
#define pci_conf_write(c, t, r, v) \
|
||||
(*(c)->pc_conf_write)((c), (t), (r), (v))
|
||||
#define pci_intr_map(c, it, ip, il, ihp) \
|
||||
(*(c)->pc_intr_map)((c), (it), (ip), (il), (ihp))
|
||||
#define pci_intr_map(pa, ihp) \
|
||||
(*(pa)->pa_pc->pc_intr_map)((pa), (ihp))
|
||||
#define pci_intr_string(c, ih) \
|
||||
(*(c)->pc_intr_string)((c), (ih))
|
||||
#define pci_intr_establish(c, ih, l, h, a) \
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: necpb.c,v 1.6 2000/12/24 09:25:30 ur Exp $ */
|
||||
/* $NetBSD: necpb.c,v 1.7 2001/01/13 10:46:18 ur Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1997, 1998 The NetBSD Foundation, Inc.
|
||||
@ -106,7 +106,7 @@ void necpb_decompose_tag __P((pci_chipset_tag_t, pcitag_t, int *,
|
||||
pcireg_t necpb_conf_read __P((pci_chipset_tag_t, pcitag_t, int));
|
||||
void necpb_conf_write __P((pci_chipset_tag_t, pcitag_t, int,
|
||||
pcireg_t));
|
||||
int necpb_intr_map __P((pci_chipset_tag_t, pcitag_t, int, int,
|
||||
int necpb_intr_map __P((struct pci_attach_args *,
|
||||
pci_intr_handle_t *));
|
||||
const char * necpb_intr_string __P((pci_chipset_tag_t, pci_intr_handle_t));
|
||||
void * necpb_intr_establish __P((pci_chipset_tag_t, pci_intr_handle_t,
|
||||
@ -329,12 +329,13 @@ necpb_conf_write(pc, tag, reg, data)
|
||||
}
|
||||
|
||||
int
|
||||
necpb_intr_map(pc, intrtag, pin, line, ihp)
|
||||
pci_chipset_tag_t pc;
|
||||
pcitag_t intrtag;
|
||||
int pin, line;
|
||||
necpb_intr_map(pa, ihp)
|
||||
struct pci_attach_args *pa;
|
||||
pci_intr_handle_t *ihp;
|
||||
{
|
||||
pci_chipset_tag_t pc = pa->pa_pc;
|
||||
pcitag_t intrtag = pa->pa_intrtag;
|
||||
int pin = pa->pa_intrpin;
|
||||
int bus, dev;
|
||||
|
||||
if (pin == 0) {
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pbcpcibus.c,v 1.5 2000/06/29 08:34:12 mrg Exp $ */
|
||||
/* $NetBSD: pbcpcibus.c,v 1.6 2001/01/13 10:46:18 ur Exp $ */
|
||||
/* $OpenBSD: pbcpcibus.c,v 1.7 1998/03/25 11:52:48 pefo Exp $ */
|
||||
|
||||
/*
|
||||
@ -72,8 +72,7 @@ void pbc_decompose_tag __P((pci_chipset_tag_t, pcitag_t, int *, int *,
|
||||
pcireg_t pbc_conf_read __P((pci_chipset_tag_t, pcitag_t, int));
|
||||
void pbc_conf_write __P((pci_chipset_tag_t, pcitag_t, int, pcireg_t));
|
||||
|
||||
int pbc_intr_map __P((pci_chipset_tag_t, pcitag_t, int, int,
|
||||
pci_intr_handle_t *));
|
||||
int pbc_intr_map __P((struct pci_attach_args *, pci_intr_handle_t *));
|
||||
const char *pbc_intr_string __P((pci_chipset_tag_t, pci_intr_handle_t));
|
||||
void *pbc_intr_establish __P((pci_chipset_tag_t, pci_intr_handle_t,
|
||||
int, int (*)(void *), void *));
|
||||
@ -473,12 +472,13 @@ pbc_ether_hw_addr(p)
|
||||
#endif
|
||||
|
||||
int
|
||||
pbc_intr_map(pc, bustag, buspin, line, ihp)
|
||||
pci_chipset_tag_t pc;
|
||||
pcitag_t bustag;
|
||||
int buspin, line;
|
||||
pbc_intr_map(pa, ihp)
|
||||
struct pci_attach_args *pa;
|
||||
pci_intr_handle_t *ihp;
|
||||
{
|
||||
pci_chipset_tag_t pc = pa->pa_pc;
|
||||
pcitag_t intrtag = pa->pa_intrtag;
|
||||
int buspin = pa->pa_intrpin;
|
||||
int device, pirq;
|
||||
|
||||
if (buspin == 0) {
|
||||
@ -492,7 +492,7 @@ pbc_intr_map(pc, bustag, buspin, line, ihp)
|
||||
return 1;
|
||||
}
|
||||
|
||||
pbc_decompose_tag(pc, bustag, NULL, &device, NULL);
|
||||
pbc_decompose_tag(pc, intrtag, NULL, &device, NULL);
|
||||
pirq = buspin - 1;
|
||||
|
||||
switch(device) {
|
||||
|
Loading…
Reference in New Issue
Block a user