Debian Codegraph @

common/dev_plx.h

raw
1 /*
2 * Cisco router simulation platform.
3 * Copyright (c) 2005,2006 Christophe Fillot ([email protected])
4 */
5
6 #ifndef __DEV_PLX_H__
7 #define __DEV_PLX_H__
8
9 #include <sys/types.h>
10 #include "utils.h"
11 #include "mips64.h"
12 #include "cpu.h"
13 #include "device.h"
14 #include "net_io.h"
15 #include "vm.h"
16
17 /* Forward declaration for PLX private data */
18 struct plx_data;
19
20 /* PLX PCI-to-Local doorbell register callback */
21 typedef void (*dev_plx_doorbell_cbk)(struct plx_data *d,void *arg,
22 m_uint32_t val);
23
24 /* Create a PLX9060 device */
25 vm_obj_t *dev_plx9060_init(vm_instance_t *vm,char *name,
26 struct pci_bus *pci_bus,int pci_device,
27 struct vdevice *dev0);
28
29 /* Create a PLX9054 device */
30 vm_obj_t *dev_plx9054_init(vm_instance_t *vm,char *name,
31 struct pci_bus *pci_bus,int pci_device,
32 struct vdevice *dev0,struct vdevice *dev1);
33
34 /* Set callback function for PCI-to-Local doorbell register */
35 void dev_plx_set_pci2loc_doorbell_cbk(struct plx_data *d,
36 dev_plx_doorbell_cbk wcbk,
37 void *arg);
38
39 /* Set the Local-to-PCI doorbell register (for Local device use) */
40 void dev_plx_set_loc2pci_doorbell_reg(struct plx_data *d,m_uint32_t value);
41
42 #endif