Changeset View
Changeset View
Standalone View
Standalone View
sys/arm64/cavium/thunder_pcie.c
Context not available. | |||||
/* Forward prototypes */ | /* Forward prototypes */ | ||||
static struct resource *thunder_pcie_alloc_resource(device_t, | static struct resource *thunder_pcie_alloc_resource(device_t, | ||||
device_t, int, int *, u_long, u_long, u_long, u_int); | device_t, int, int *, rman_res_t, rman_res_t, rman_res_t, u_int); | ||||
static int thunder_pcie_attach(device_t); | static int thunder_pcie_attach(device_t); | ||||
static int thunder_pcie_identify_pcib(device_t); | static int thunder_pcie_identify_pcib(device_t); | ||||
static int thunder_pcie_maxslots(device_t); | static int thunder_pcie_maxslots(device_t); | ||||
Context not available. | |||||
static struct resource * | static struct resource * | ||||
thunder_pcie_alloc_resource(device_t dev, device_t child, int type, int *rid, | thunder_pcie_alloc_resource(device_t dev, device_t child, int type, int *rid, | ||||
u_long start, u_long end, u_long count, u_int flags) | rman_res_t start, rman_res_t end, rman_res_t count, u_int flags) | ||||
{ | { | ||||
struct thunder_pcie_softc *sc = device_get_softc(dev); | struct thunder_pcie_softc *sc = device_get_softc(dev); | ||||
struct rman *rm = NULL; | struct rman *rm = NULL; | ||||
Context not available. | |||||
type, rid, start, end, count, flags)); | type, rid, start, end, count, flags)); | ||||
}; | }; | ||||
if ((start == 0UL) && (end == ~0UL)) { | if ((start == 0) && (end == ~0)) { | ||||
/* Read BAR manually to get resource address and size */ | /* Read BAR manually to get resource address and size */ | ||||
pci_read_bar(child, *rid, &map, &testval, NULL); | pci_read_bar(child, *rid, &map, &testval, NULL); | ||||
Context not available. | |||||
thunder_pcie_identify_pcib(device_t dev) | thunder_pcie_identify_pcib(device_t dev) | ||||
{ | { | ||||
struct thunder_pcie_softc *sc; | struct thunder_pcie_softc *sc; | ||||
u_long start; | rman_res_t start; | ||||
sc = device_get_softc(dev); | sc = device_get_softc(dev); | ||||
start = bus_get_resource_start(dev, SYS_RES_MEMORY, 0); | start = bus_get_resource_start(dev, SYS_RES_MEMORY, 0); | ||||
Context not available. |