Lines Matching refs:__C
83 #define __C(A,B) __CONCAT(A,B)
87 int __C(CHIP,_io_map)(void *, bus_addr_t, bus_size_t, int,
89 void __C(CHIP,_io_unmap)(void *, bus_space_handle_t,
91 int __C(CHIP,_io_subregion)(void *, bus_space_handle_t,
94 int __C(CHIP,_io_translate)(void *, bus_addr_t, bus_size_t,
96 int __C(CHIP,_io_get_window)(void *, int,
100 int __C(CHIP,_io_alloc)(void *, bus_addr_t, bus_addr_t,
103 void __C(CHIP,_io_free)(void *, bus_space_handle_t,
107 void * __C(CHIP,_io_vaddr)(void *, bus_space_handle_t);
110 paddr_t __C(CHIP,_io_mmap)(void *, bus_addr_t, off_t, int, int);
113 static inline void __C(CHIP,_io_barrier)(void *, bus_space_handle_t,
117 static inline uint8_t __C(CHIP,_io_read_1)(void *, bus_space_handle_t,
119 static inline uint16_t __C(CHIP,_io_read_2)(void *, bus_space_handle_t,
121 static inline uint32_t __C(CHIP,_io_read_4)(void *, bus_space_handle_t,
123 static inline uint64_t __C(CHIP,_io_read_8)(void *, bus_space_handle_t,
127 void __C(CHIP,_io_read_multi_1)(void *, bus_space_handle_t,
129 void __C(CHIP,_io_read_multi_2)(void *, bus_space_handle_t,
131 void __C(CHIP,_io_read_multi_4)(void *, bus_space_handle_t,
133 void __C(CHIP,_io_read_multi_8)(void *, bus_space_handle_t,
137 void __C(CHIP,_io_read_region_1)(void *, bus_space_handle_t,
139 void __C(CHIP,_io_read_region_2)(void *, bus_space_handle_t,
141 void __C(CHIP,_io_read_region_4)(void *, bus_space_handle_t,
143 void __C(CHIP,_io_read_region_8)(void *, bus_space_handle_t,
147 static inline void __C(CHIP,_io_write_1)(void *, bus_space_handle_t,
149 static inline void __C(CHIP,_io_write_2)(void *, bus_space_handle_t,
151 static inline void __C(CHIP,_io_write_4)(void *, bus_space_handle_t,
153 static inline void __C(CHIP,_io_write_8)(void *, bus_space_handle_t,
157 void __C(CHIP,_io_write_multi_1)(void *, bus_space_handle_t,
159 void __C(CHIP,_io_write_multi_2)(void *, bus_space_handle_t,
161 void __C(CHIP,_io_write_multi_4)(void *, bus_space_handle_t,
163 void __C(CHIP,_io_write_multi_8)(void *, bus_space_handle_t,
167 void __C(CHIP,_io_write_region_1)(void *, bus_space_handle_t,
169 void __C(CHIP,_io_write_region_2)(void *, bus_space_handle_t,
171 void __C(CHIP,_io_write_region_4)(void *, bus_space_handle_t,
173 void __C(CHIP,_io_write_region_8)(void *, bus_space_handle_t,
177 void __C(CHIP,_io_set_multi_1)(void *, bus_space_handle_t,
179 void __C(CHIP,_io_set_multi_2)(void *, bus_space_handle_t,
181 void __C(CHIP,_io_set_multi_4)(void *, bus_space_handle_t,
183 void __C(CHIP,_io_set_multi_8)(void *, bus_space_handle_t,
187 void __C(CHIP,_io_set_region_1)(void *, bus_space_handle_t,
189 void __C(CHIP,_io_set_region_2)(void *, bus_space_handle_t,
191 void __C(CHIP,_io_set_region_4)(void *, bus_space_handle_t,
193 void __C(CHIP,_io_set_region_8)(void *, bus_space_handle_t,
197 void __C(CHIP,_io_copy_region_1)(void *, bus_space_handle_t,
199 void __C(CHIP,_io_copy_region_2)(void *, bus_space_handle_t,
201 void __C(CHIP,_io_copy_region_4)(void *, bus_space_handle_t,
203 void __C(CHIP,_io_copy_region_8)(void *, bus_space_handle_t,
208 __C(CHIP,_io_ex_storage)[EXTENT_FIXED_STORAGE_SIZE(8) / sizeof(long)];
209 #define CHIP_IO_EX_STORE(v) (__C(CHIP, _io_ex_storage))
210 #define CHIP_IO_EX_STORE_SIZE(v) (sizeof __C(CHIP, _io_ex_storage))
222 __C(CHIP,_bus_io_init)(bus_space_tag_t t, void *v)
234 t->abs_map = __C(CHIP,_io_map);
235 t->abs_unmap = __C(CHIP,_io_unmap);
236 t->abs_subregion = __C(CHIP,_io_subregion);
238 t->abs_translate = __C(CHIP,_io_translate);
239 t->abs_get_window = __C(CHIP,_io_get_window);
242 t->abs_alloc = __C(CHIP,_io_alloc);
243 t->abs_free = __C(CHIP,_io_free);
246 t->abs_vaddr = __C(CHIP,_io_vaddr);
249 t->abs_mmap = __C(CHIP,_io_mmap);
252 t->abs_barrier = __C(CHIP,_io_barrier);
255 t->abs_r_1 = __C(CHIP,_io_read_1);
256 t->abs_r_2 = __C(CHIP,_io_read_2);
257 t->abs_r_4 = __C(CHIP,_io_read_4);
258 t->abs_r_8 = __C(CHIP,_io_read_8);
261 t->abs_rm_1 = __C(CHIP,_io_read_multi_1);
262 t->abs_rm_2 = __C(CHIP,_io_read_multi_2);
263 t->abs_rm_4 = __C(CHIP,_io_read_multi_4);
264 t->abs_rm_8 = __C(CHIP,_io_read_multi_8);
267 t->abs_rr_1 = __C(CHIP,_io_read_region_1);
268 t->abs_rr_2 = __C(CHIP,_io_read_region_2);
269 t->abs_rr_4 = __C(CHIP,_io_read_region_4);
270 t->abs_rr_8 = __C(CHIP,_io_read_region_8);
273 t->abs_w_1 = __C(CHIP,_io_write_1);
274 t->abs_w_2 = __C(CHIP,_io_write_2);
275 t->abs_w_4 = __C(CHIP,_io_write_4);
276 t->abs_w_8 = __C(CHIP,_io_write_8);
279 t->abs_wm_1 = __C(CHIP,_io_write_multi_1);
280 t->abs_wm_2 = __C(CHIP,_io_write_multi_2);
281 t->abs_wm_4 = __C(CHIP,_io_write_multi_4);
282 t->abs_wm_8 = __C(CHIP,_io_write_multi_8);
285 t->abs_wr_1 = __C(CHIP,_io_write_region_1);
286 t->abs_wr_2 = __C(CHIP,_io_write_region_2);
287 t->abs_wr_4 = __C(CHIP,_io_write_region_4);
288 t->abs_wr_8 = __C(CHIP,_io_write_region_8);
291 t->abs_sm_1 = __C(CHIP,_io_set_multi_1);
292 t->abs_sm_2 = __C(CHIP,_io_set_multi_2);
293 t->abs_sm_4 = __C(CHIP,_io_set_multi_4);
294 t->abs_sm_8 = __C(CHIP,_io_set_multi_8);
297 t->abs_sr_1 = __C(CHIP,_io_set_region_1);
298 t->abs_sr_2 = __C(CHIP,_io_set_region_2);
299 t->abs_sr_4 = __C(CHIP,_io_set_region_4);
300 t->abs_sr_8 = __C(CHIP,_io_set_region_8);
303 t->abs_c_1 = __C(CHIP,_io_copy_region_1);
304 t->abs_c_2 = __C(CHIP,_io_copy_region_2);
305 t->abs_c_4 = __C(CHIP,_io_copy_region_4);
306 t->abs_c_8 = __C(CHIP,_io_copy_region_8);
309 ex = extent_create(__S(__C(CHIP,_bus_io)), 0x0UL, 0xffffffffUL,
338 __C(CHIP,_io_translate)(void *v, bus_addr_t ioaddr, bus_size_t iolen,
353 return (__C(CHIP,_io_get_window)(v, 0, abst));
359 return (__C(CHIP,_io_get_window)(v, 1, abst));
366 __S(__C(CHIP,_io_map)), CHIP_IO_W1_BUS_START(v),
371 __S(__C(CHIP,_io_map)), CHIP_IO_W2_BUS_START(v),
380 __C(CHIP,_io_get_window)(void *v, int window,
410 panic(__S(__C(CHIP,_io_get_window)) ": invalid window %d",
418 __C(CHIP,_io_map)(void *v, bus_addr_t ioaddr, bus_size_t iosize,
427 error = __C(CHIP,_io_translate)(v, ioaddr, iosize, flags, &abst);
455 __C(CHIP,_io_unmap)(void *v, bus_space_handle_t ioh,
488 __S(__C(CHIP,_io_map)), CHIP_IO_W1_SYS_START(v),
493 __S(__C(CHIP,_io_map)), CHIP_IO_W2_SYS_START(v),
497 __S(__C(CHIP,_io_unmap)), (ioh << CHIP_ADDR_SHIFT));
507 __S(__C(CHIP,_io_unmap)), ioaddr, ioaddr + iosize - 1,
516 __C(CHIP,_io_subregion)(void *v, bus_space_handle_t ioh,
525 __C(CHIP,_io_alloc)(void *v, bus_addr_t rstart, bus_addr_t rend,
562 error = __C(CHIP,_io_translate)(v, ioaddr, size, flags, &abst);
577 __C(CHIP,_io_free)(void *v, bus_space_handle_t bsh, bus_size_t size)
581 __C(CHIP,_io_unmap)(v, bsh, size, 1);
585 __C(CHIP,_io_vaddr)(void *v, bus_space_handle_t bsh)
595 __C(CHIP,_io_mmap)(void *v, bus_addr_t addr, off_t off, int prot, int flags)
603 __C(CHIP,_io_barrier)(void *v, bus_space_handle_t h,
614 __C(CHIP,_io_read_1)(void *v, bus_space_handle_t ioh, bus_size_t off)
634 __C(CHIP,_io_read_2)(void *v, bus_space_handle_t ioh, bus_size_t off)
654 __C(CHIP,_io_read_4)(void *v, bus_space_handle_t ioh, bus_size_t off)
678 __C(CHIP,_io_read_8)(void *v, bus_space_handle_t ioh, bus_size_t off)
682 panic("%s not implemented", __S(__C(CHIP,_io_read_8)));
687 __C(__C(CHIP,_io_read_multi_),BYTES)(void *v, bus_space_handle_t h, bus_size_t o, TYPE *a, bus_size_t c) \
691 __C(CHIP,_io_barrier)(v, h, o, sizeof *a, \
693 *a++ = __C(__C(CHIP,_io_read_),BYTES)(v, h, o); \
703 __C(__C(CHIP,_io_read_region_),BYTES)(void *v, bus_space_handle_t h, bus_size_t o, TYPE *a, bus_size_t c) \
707 *a++ = __C(__C(CHIP,_io_read_),BYTES)(v, h, o); \
717 __C(CHIP,_io_write_1)(void *v, bus_space_handle_t ioh,
734 __C(CHIP,_io_write_2)(void *v, bus_space_handle_t ioh,
751 __C(CHIP,_io_write_4)(void *v, bus_space_handle_t ioh,
768 __C(CHIP,_io_write_8)(void *v, bus_space_handle_t ioh,
773 panic("%s not implemented", __S(__C(CHIP,_io_write_8)));
779 __C(__C(CHIP,_io_write_multi_),BYTES)(void *v, bus_space_handle_t h, bus_size_t o, const TYPE *a, bus_size_t c) \
783 __C(__C(CHIP,_io_write_),BYTES)(v, h, o, *a++); \
784 __C(CHIP,_io_barrier)(v, h, o, sizeof *a, \
795 __C(__C(CHIP,_io_write_region_),BYTES)(void *v, bus_space_handle_t h, bus_size_t o, const TYPE *a, bus_size_t c) \
799 __C(__C(CHIP,_io_write_),BYTES)(v, h, o, *a++); \
810 __C(__C(CHIP,_io_set_multi_),BYTES)(void *v, bus_space_handle_t h, bus_size_t o, TYPE val, bus_size_t c) \
814 __C(__C(CHIP,_io_write_),BYTES)(v, h, o, val); \
815 __C(CHIP,_io_barrier)(v, h, o, sizeof val, \
826 __C(__C(CHIP,_io_set_region_),BYTES)(void *v, bus_space_handle_t h, bus_size_t o, TYPE val, bus_size_t c) \
830 __C(__C(CHIP,_io_write_),BYTES)(v, h, o, val); \
841 __C(__C(CHIP,_io_copy_region_),BYTES)(void *v, bus_space_handle_t h1, bus_size_t o1, bus_space_handle_t h2, bus_size_t o2, bus_size_t c) \
848 __C(__C(CHIP,_io_write_),BYTES)(v, h2, o2 + o, \
849 __C(__C(CHIP,_io_read_),BYTES)(v, h1, o1 + o)); \
853 __C(__C(CHIP,_io_write_),BYTES)(v, h2, o2 + o, \
854 __C(__C(CHIP,_io_read_),BYTES)(v, h1, o1 + o)); \