Lines Matching refs:res_idx
294 #define CCIO_SEARCH_LOOP(ioc, res_idx, mask, size) \
302 res_idx = idx;\
303 ioc->res_hint = res_idx + (size >> 3); \
308 #define CCIO_FIND_FREE_MAPPING(ioa, res_idx, mask, size) \
311 CCIO_SEARCH_LOOP(ioc, res_idx, mask, size); \
313 CCIO_SEARCH_LOOP(ioa, res_idx, mask, size);
342 unsigned int res_idx;
368 CCIO_FIND_FREE_MAPPING(ioc, res_idx, 0xff, 8);
370 CCIO_FIND_FREE_MAPPING(ioc, res_idx, 0xffff, 16);
372 CCIO_FIND_FREE_MAPPING(ioc, res_idx, ~(unsigned int)0, 32);
375 CCIO_FIND_FREE_MAPPING(ioc, res_idx, ~0UL, 64);
387 DBG_RES("%s() res_idx %d res_hint: %d\n",
388 __func__, res_idx, ioc->res_hint);
404 return res_idx << 3;
407 #define CCIO_FREE_MAPPINGS(ioc, res_idx, mask, size) \
408 u##size *res_ptr = (u##size *)&((ioc)->res_map[res_idx]); \
425 unsigned int res_idx = PDIR_INDEX(iovp) >> 3;
431 DBG_RES("%s(): res_idx: %d pages_mapped %d\n",
432 __func__, res_idx, pages_mapped);
439 CCIO_FREE_MAPPINGS(ioc, res_idx, 0xffUL, 8);
441 CCIO_FREE_MAPPINGS(ioc, res_idx, 0xffffUL, 16);
443 CCIO_FREE_MAPPINGS(ioc, res_idx, ~(unsigned int)0, 32);
446 CCIO_FREE_MAPPINGS(ioc, res_idx, ~0UL, 64);