Changes in uspace/drv/infrastructure/rootpc/rootpc.c [9e470c0:3e6a98c5] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/drv/infrastructure/rootpc/rootpc.c
r9e470c0 r3e6a98c5 51 51 #include <ops/hw_res.h> 52 52 #include <device/hw_res.h> 53 #include <ops/pio_window.h>54 #include <device/pio_window.h>55 53 56 54 #define NAME "rootpc" … … 58 56 typedef struct rootpc_fun { 59 57 hw_resource_list_t hw_resources; 60 pio_window_t pio_window;61 58 } rootpc_fun_t; 62 59 … … 81 78 .address = 0xCF8, 82 79 .size = 4, 83 .relative = false,84 80 .endianness = LITTLE_ENDIAN 85 81 } … … 90 86 .address = 0xCFC, 91 87 .size = 4, 92 .relative = false,93 88 .endianness = LITTLE_ENDIAN 94 89 } … … 98 93 static rootpc_fun_t pci_data = { 99 94 .hw_resources = { 100 sizeof(pci_conf_regs) /sizeof(pci_conf_regs[0]),95 sizeof(pci_conf_regs)/sizeof(pci_conf_regs[0]), 101 96 pci_conf_regs 102 },103 .pio_window = {104 .mem = {105 .base = UINT32_C(0),106 .size = UINT32_C(0xffffffff) /* practical maximum */107 },108 .io = {109 .base = UINT32_C(0),110 .size = UINT32_C(0x10000)111 }112 97 } 113 98 }; … … 132 117 133 118 return false; 134 }135 136 static pio_window_t *rootpc_get_pio_window(ddf_fun_t *fnode)137 {138 rootpc_fun_t *fun = rootpc_fun(fnode);139 140 assert(fun != NULL);141 return &fun->pio_window;142 119 } 143 120 … … 145 122 .get_resource_list = &rootpc_get_resources, 146 123 .enable_interrupt = &rootpc_enable_interrupt, 147 };148 149 static pio_window_ops_t fun_pio_window_ops = {150 .get_pio_window = &rootpc_get_pio_window151 124 }; 152 125 … … 224 197 ddf_log_init(NAME); 225 198 rootpc_fun_ops.interfaces[HW_RES_DEV_IFACE] = &fun_hw_res_ops; 226 rootpc_fun_ops.interfaces[PIO_WINDOW_DEV_IFACE] = &fun_pio_window_ops;227 199 } 228 200
Note:
See TracChangeset
for help on using the changeset viewer.