Lines Matching refs:rhp
96 struct c4iw_dev *rhp = to_c4iw_dev(context->device); in c4iw_dealloc_ucontext() local
103 c4iw_release_dev_ucontext(&rhp->rdev, &ucontext->uctx); in c4iw_dealloc_ucontext()
112 struct c4iw_dev *rhp = to_c4iw_dev(ibdev); in c4iw_alloc_ucontext() local
125 c4iw_init_dev_ucontext(&rhp->rdev, &context->uctx); in c4iw_alloc_ucontext()
132 rhp->rdev.flags |= T4_STATUS_PAGE_DISABLED; in c4iw_alloc_ucontext()
153 mm->addr = virt_to_phys(rhp->rdev.status_page); in c4iw_alloc_ucontext()
237 struct c4iw_dev *rhp; in c4iw_deallocate_pd() local
241 rhp = php->rhp; in c4iw_deallocate_pd()
243 c4iw_put_resource(&rhp->rdev.resource.pdid_table, php->pdid); in c4iw_deallocate_pd()
244 mutex_lock(&rhp->rdev.stats.lock); in c4iw_deallocate_pd()
245 rhp->rdev.stats.pd.cur--; in c4iw_deallocate_pd()
246 mutex_unlock(&rhp->rdev.stats.lock); in c4iw_deallocate_pd()
257 struct c4iw_dev *rhp; in c4iw_allocate_pd() local
260 rhp = (struct c4iw_dev *) ibdev; in c4iw_allocate_pd()
261 pdid = c4iw_get_resource(&rhp->rdev.resource.pdid_table); in c4iw_allocate_pd()
266 c4iw_put_resource(&rhp->rdev.resource.pdid_table, pdid); in c4iw_allocate_pd()
270 php->rhp = rhp; in c4iw_allocate_pd()
277 mutex_lock(&rhp->rdev.stats.lock); in c4iw_allocate_pd()
278 rhp->rdev.stats.pd.cur++; in c4iw_allocate_pd()
279 if (rhp->rdev.stats.pd.cur > rhp->rdev.stats.pd.max) in c4iw_allocate_pd()
280 rhp->rdev.stats.pd.max = rhp->rdev.stats.pd.cur; in c4iw_allocate_pd()
281 mutex_unlock(&rhp->rdev.stats.lock); in c4iw_allocate_pd()