Lines Matching refs:host

50 bool dcr_map_ok_generic(dcr_host_t host)  in dcr_map_ok_generic()  argument
52 if (host.type == DCR_HOST_NATIVE) in dcr_map_ok_generic()
53 return dcr_map_ok_native(host.host.native); in dcr_map_ok_generic()
54 else if (host.type == DCR_HOST_MMIO) in dcr_map_ok_generic()
55 return dcr_map_ok_mmio(host.host.mmio); in dcr_map_ok_generic()
65 dcr_host_t host; in dcr_map_generic() local
69 host.type = DCR_HOST_INVALID; in dcr_map_generic()
73 return host; in dcr_map_generic()
80 host.type = DCR_HOST_NATIVE; in dcr_map_generic()
81 host.host.native = dcr_map_native(dev, dcr_n, dcr_c); in dcr_map_generic()
83 host.type = DCR_HOST_MMIO; in dcr_map_generic()
84 host.host.mmio = dcr_map_mmio(dev, dcr_n, dcr_c); in dcr_map_generic()
88 return host; in dcr_map_generic()
92 void dcr_unmap_generic(dcr_host_t host, unsigned int dcr_c) in dcr_unmap_generic() argument
94 if (host.type == DCR_HOST_NATIVE) in dcr_unmap_generic()
95 dcr_unmap_native(host.host.native, dcr_c); in dcr_unmap_generic()
96 else if (host.type == DCR_HOST_MMIO) in dcr_unmap_generic()
97 dcr_unmap_mmio(host.host.mmio, dcr_c); in dcr_unmap_generic()
103 u32 dcr_read_generic(dcr_host_t host, unsigned int dcr_n) in dcr_read_generic() argument
105 if (host.type == DCR_HOST_NATIVE) in dcr_read_generic()
106 return dcr_read_native(host.host.native, dcr_n); in dcr_read_generic()
107 else if (host.type == DCR_HOST_MMIO) in dcr_read_generic()
108 return dcr_read_mmio(host.host.mmio, dcr_n); in dcr_read_generic()
115 void dcr_write_generic(dcr_host_t host, unsigned int dcr_n, u32 value) in dcr_write_generic() argument
117 if (host.type == DCR_HOST_NATIVE) in dcr_write_generic()
118 dcr_write_native(host.host.native, dcr_n, value); in dcr_write_generic()
119 else if (host.type == DCR_HOST_MMIO) in dcr_write_generic()
120 dcr_write_mmio(host.host.mmio, dcr_n, value); in dcr_write_generic()
217 void dcr_unmap_mmio(dcr_host_mmio_t host, unsigned int dcr_c) in dcr_unmap_mmio() argument
219 dcr_host_mmio_t h = host; in dcr_unmap_mmio()
223 h.token += host.base * h.stride; in dcr_unmap_mmio()