psychovar.h (256281) | psychovar.h (292789) |
---|---|
1/*- 2 * Copyright (c) 1999, 2000 Matthew R. Green 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 11 unchanged lines hidden (view full) --- 20 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 21 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 22 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * 26 * from: NetBSD: psychovar.h,v 1.15 2008/05/29 14:51:26 mrg Exp 27 * | 1/*- 2 * Copyright (c) 1999, 2000 Matthew R. Green 3 * All rights reserved. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 11 unchanged lines hidden (view full) --- 20 * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED 21 * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 22 * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * 26 * from: NetBSD: psychovar.h,v 1.15 2008/05/29 14:51:26 mrg Exp 27 * |
28 * $FreeBSD: stable/10/sys/sparc64/pci/psychovar.h 225931 2011-10-02 23:22:38Z marius $ | 28 * $FreeBSD: stable/10/sys/sparc64/pci/psychovar.h 292789 2015-12-27 19:37:47Z marius $ |
29 */ 30 31#ifndef _SPARC64_PCI_PSYCHOVAR_H_ 32#define _SPARC64_PCI_PSYCHOVAR_H_ 33 34/* 35 * Per-PCI bus on mainbus softc structure; one for sabre, or two 36 * per pair of psychos. 37 */ 38struct psycho_softc { | 29 */ 30 31#ifndef _SPARC64_PCI_PSYCHOVAR_H_ 32#define _SPARC64_PCI_PSYCHOVAR_H_ 33 34/* 35 * Per-PCI bus on mainbus softc structure; one for sabre, or two 36 * per pair of psychos. 37 */ 38struct psycho_softc { |
39 /* 40 * This is here so that we can hook up the common bus interface 41 * methods in ofw_pci.c directly. 42 */ 43 struct ofw_pci_softc sc_ops; 44 45 struct iommu_state *sc_is; |
|
39 struct bus_dma_methods *sc_dma_methods; 40 | 46 struct bus_dma_methods *sc_dma_methods; 47 |
41 device_t sc_dev; 42 | |
43 struct mtx *sc_mtx; 44 | 48 struct mtx *sc_mtx; 49 |
45 /* Interrupt Group Number for this device */ 46 uint32_t sc_ign; | 50 struct resource *sc_mem_res; 51 struct resource *sc_irq_res[PSYCHO_NINTR]; 52 void *sc_ihand[PSYCHO_NINTR]; |
47 | 53 |
54 uint8_t sc_pci_hpbcfg[16]; 55 56 SLIST_ENTRY(psycho_softc) sc_link; 57 58 device_t sc_dev; 59 |
|
48 bus_addr_t sc_pcictl; 49 | 60 bus_addr_t sc_pcictl; 61 |
50 phandle_t sc_node; /* Firmware node */ | |
51 u_int sc_mode; 52#define PSYCHO_MODE_SABRE 0 53#define PSYCHO_MODE_PSYCHO 1 54 55 /* Bus A or B of a psycho pair? */ 56 u_int sc_half; 57 | 62 u_int sc_mode; 63#define PSYCHO_MODE_SABRE 0 64#define PSYCHO_MODE_PSYCHO 1 65 66 /* Bus A or B of a psycho pair? */ 67 u_int sc_half; 68 |
58 struct iommu_state *sc_is; 59 60 struct resource *sc_mem_res; 61 struct resource *sc_irq_res[PSYCHO_NINTR]; 62 void *sc_ihand[PSYCHO_NINTR]; 63 64 struct ofw_bus_iinfo sc_pci_iinfo; 65 66 /* Tags for PCI access */ 67 bus_space_tag_t sc_pci_cfgt; 68 bus_space_tag_t sc_pci_iot; 69 bus_dma_tag_t sc_pci_dmat; 70 71 bus_space_handle_t sc_pci_bh[PSYCHO_NRANGE]; 72 73 struct rman sc_pci_mem_rman; 74 struct rman sc_pci_io_rman; 75 76 uint8_t sc_pci_secbus; 77 uint8_t sc_pci_subbus; 78 79 uint8_t sc_pci_hpbcfg[16]; 80 81 SLIST_ENTRY(psycho_softc) sc_link; | 69 /* Interrupt Group Number for this device */ 70 uint32_t sc_ign; |
82}; 83 84#endif /* !_SPARC64_PCI_PSYCHOVAR_H_ */ | 71}; 72 73#endif /* !_SPARC64_PCI_PSYCHOVAR_H_ */ |