uctx 119 drivers/gpu/drm/vmwgfx/vmwgfx_context.c static void vmw_context_cotables_unref(struct vmw_user_context *uctx) uctx 125 drivers/gpu/drm/vmwgfx/vmwgfx_context.c spin_lock(&uctx->cotable_lock); uctx 126 drivers/gpu/drm/vmwgfx/vmwgfx_context.c res = uctx->cotables[i]; uctx 127 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->cotables[i] = NULL; uctx 128 drivers/gpu/drm/vmwgfx/vmwgfx_context.c spin_unlock(&uctx->cotable_lock); uctx 137 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 149 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_cmdbuf_res_man_destroy(uctx->man); uctx 151 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_binding_state_kill(uctx->cbs); uctx 158 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_context_cotables_unref(uctx); uctx 181 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 194 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->man = vmw_cmdbuf_res_man_create(dev_priv); uctx 195 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (IS_ERR(uctx->man)) { uctx 196 drivers/gpu/drm/vmwgfx/vmwgfx_context.c ret = PTR_ERR(uctx->man); uctx 197 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->man = NULL; uctx 202 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->cbs = vmw_binding_state_alloc(dev_priv); uctx 203 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (IS_ERR(uctx->cbs)) { uctx 204 drivers/gpu/drm/vmwgfx/vmwgfx_context.c ret = PTR_ERR(uctx->cbs); uctx 208 drivers/gpu/drm/vmwgfx/vmwgfx_context.c spin_lock_init(&uctx->cotable_lock); uctx 212 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->cotables[i] = vmw_cotable_alloc(dev_priv, uctx 213 drivers/gpu/drm/vmwgfx/vmwgfx_context.c &uctx->res, i); uctx 214 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (IS_ERR(uctx->cotables[i])) { uctx 215 drivers/gpu/drm/vmwgfx/vmwgfx_context.c ret = PTR_ERR(uctx->cotables[i]); uctx 225 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_context_cotables_unref(uctx); uctx 368 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 386 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_binding_state_scrub(uctx->cbs); uctx 546 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 550 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_binding_state_scrub(uctx->cbs); uctx 555 drivers/gpu/drm/vmwgfx/vmwgfx_context.c spin_lock(&uctx->cotable_lock); uctx 556 drivers/gpu/drm/vmwgfx/vmwgfx_context.c res = uctx->cotables[vmw_cotable_scrub_order[i]]; uctx 559 drivers/gpu/drm/vmwgfx/vmwgfx_context.c spin_unlock(&uctx->cotable_lock); uctx 575 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 595 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (uctx->dx_query_mob && uctx->dx_query_mob->dx_query_ctx && uctx 597 drivers/gpu/drm/vmwgfx/vmwgfx_context.c WARN_ON(uctx->dx_query_mob->dx_query_ctx != res); uctx 598 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (vmw_query_readback_all(uctx->dx_query_mob)) uctx 828 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 831 drivers/gpu/drm/vmwgfx/vmwgfx_context.c return vmw_binding_state_list(uctx->cbs); uctx 879 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 883 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (uctx->dx_query_mob) { uctx 884 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->dx_query_mob->dx_query_ctx = NULL; uctx 885 drivers/gpu/drm/vmwgfx/vmwgfx_context.c vmw_bo_unreference(&uctx->dx_query_mob); uctx 886 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->dx_query_mob = NULL; uctx 893 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (uctx->dx_query_mob && uctx->dx_query_mob != mob) uctx 898 drivers/gpu/drm/vmwgfx/vmwgfx_context.c if (!uctx->dx_query_mob) uctx 899 drivers/gpu/drm/vmwgfx/vmwgfx_context.c uctx->dx_query_mob = vmw_bo_reference(mob); uctx 912 drivers/gpu/drm/vmwgfx/vmwgfx_context.c struct vmw_user_context *uctx = uctx 915 drivers/gpu/drm/vmwgfx/vmwgfx_context.c return uctx->dx_query_mob; uctx 702 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_ucontext *uctx = rdma_udata_to_drv_context( uctx 707 drivers/infiniband/hw/bnxt_re/ib_verbs.c spin_lock_irqsave(&uctx->sh_lock, flag); uctx 708 drivers/infiniband/hw/bnxt_re/ib_verbs.c wrptr = (u32 *)(uctx->shpg + BNXT_RE_AVID_OFFT); uctx 711 drivers/infiniband/hw/bnxt_re/ib_verbs.c spin_unlock_irqrestore(&uctx->sh_lock, flag); uctx 2559 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_ucontext *uctx = rdma_udata_to_drv_context( uctx 2576 drivers/infiniband/hw/bnxt_re/ib_verbs.c cq->qplib_cq.dpi = &uctx->dpi; uctx 3606 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_ucontext *uctx = uctx 3623 drivers/infiniband/hw/bnxt_re/ib_verbs.c uctx->rdev = rdev; uctx 3625 drivers/infiniband/hw/bnxt_re/ib_verbs.c uctx->shpg = (void *)__get_free_page(GFP_KERNEL); uctx 3626 drivers/infiniband/hw/bnxt_re/ib_verbs.c if (!uctx->shpg) { uctx 3630 drivers/infiniband/hw/bnxt_re/ib_verbs.c spin_lock_init(&uctx->sh_lock); uctx 3658 drivers/infiniband/hw/bnxt_re/ib_verbs.c free_page((unsigned long)uctx->shpg); uctx 3659 drivers/infiniband/hw/bnxt_re/ib_verbs.c uctx->shpg = NULL; uctx 3666 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_ucontext *uctx = container_of(ib_uctx, uctx 3670 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_dev *rdev = uctx->rdev; uctx 3672 drivers/infiniband/hw/bnxt_re/ib_verbs.c if (uctx->shpg) uctx 3673 drivers/infiniband/hw/bnxt_re/ib_verbs.c free_page((unsigned long)uctx->shpg); uctx 3675 drivers/infiniband/hw/bnxt_re/ib_verbs.c if (uctx->dpi.dbr) { uctx 3680 drivers/infiniband/hw/bnxt_re/ib_verbs.c &rdev->qplib_res.dpi_tbl, &uctx->dpi); uctx 3681 drivers/infiniband/hw/bnxt_re/ib_verbs.c uctx->dpi.dbr = NULL; uctx 3688 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_ucontext *uctx = container_of(ib_uctx, uctx 3691 drivers/infiniband/hw/bnxt_re/ib_verbs.c struct bnxt_re_dev *rdev = uctx->rdev; uctx 3705 drivers/infiniband/hw/bnxt_re/ib_verbs.c pfn = virt_to_phys(uctx->shpg) >> PAGE_SHIFT; uctx 189 drivers/infiniband/hw/cxgb3/cxio_hal.c static u32 get_qpid(struct cxio_rdev *rdev_p, struct cxio_ucontext *uctx) uctx 195 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_lock(&uctx->lock); uctx 196 drivers/infiniband/hw/cxgb3/cxio_hal.c if (!list_empty(&uctx->qpids)) { uctx 197 drivers/infiniband/hw/cxgb3/cxio_hal.c entry = list_entry(uctx->qpids.next, struct cxio_qpid_list, uctx 211 drivers/infiniband/hw/cxgb3/cxio_hal.c list_add_tail(&entry->entry, &uctx->qpids); uctx 215 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_unlock(&uctx->lock); uctx 221 drivers/infiniband/hw/cxgb3/cxio_hal.c struct cxio_ucontext *uctx) uctx 230 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_lock(&uctx->lock); uctx 231 drivers/infiniband/hw/cxgb3/cxio_hal.c list_add_tail(&entry->entry, &uctx->qpids); uctx 232 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_unlock(&uctx->lock); uctx 235 drivers/infiniband/hw/cxgb3/cxio_hal.c void cxio_release_ucontext(struct cxio_rdev *rdev_p, struct cxio_ucontext *uctx) uctx 240 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_lock(&uctx->lock); uctx 241 drivers/infiniband/hw/cxgb3/cxio_hal.c list_for_each_safe(pos, nxt, &uctx->qpids) { uctx 248 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_unlock(&uctx->lock); uctx 251 drivers/infiniband/hw/cxgb3/cxio_hal.c void cxio_init_ucontext(struct cxio_rdev *rdev_p, struct cxio_ucontext *uctx) uctx 253 drivers/infiniband/hw/cxgb3/cxio_hal.c INIT_LIST_HEAD(&uctx->qpids); uctx 254 drivers/infiniband/hw/cxgb3/cxio_hal.c mutex_init(&uctx->lock); uctx 258 drivers/infiniband/hw/cxgb3/cxio_hal.c struct t3_wq *wq, struct cxio_ucontext *uctx) uctx 263 drivers/infiniband/hw/cxgb3/cxio_hal.c wq->qpid = get_qpid(rdev_p, uctx); uctx 301 drivers/infiniband/hw/cxgb3/cxio_hal.c put_qpid(rdev_p, wq->qpid, uctx); uctx 317 drivers/infiniband/hw/cxgb3/cxio_hal.c struct cxio_ucontext *uctx) uctx 326 drivers/infiniband/hw/cxgb3/cxio_hal.c put_qpid(rdev_p, wq->qpid, uctx); uctx 956 drivers/infiniband/hw/cxgb3/cxio_hal.c cxio_init_ucontext(rdev_p, &rdev_p->uctx); uctx 110 drivers/infiniband/hw/cxgb3/cxio_hal.h struct cxio_ucontext uctx; uctx 162 drivers/infiniband/hw/cxgb3/cxio_hal.h void cxio_release_ucontext(struct cxio_rdev *rdev, struct cxio_ucontext *uctx); uctx 163 drivers/infiniband/hw/cxgb3/cxio_hal.h void cxio_init_ucontext(struct cxio_rdev *rdev, struct cxio_ucontext *uctx); uctx 165 drivers/infiniband/hw/cxgb3/cxio_hal.h struct cxio_ucontext *uctx); uctx 167 drivers/infiniband/hw/cxgb3/cxio_hal.h struct cxio_ucontext *uctx); uctx 74 drivers/infiniband/hw/cxgb3/iwch_provider.c cxio_release_ucontext(&rhp->rdev, &ucontext->uctx); uctx 85 drivers/infiniband/hw/cxgb3/iwch_provider.c cxio_init_ucontext(&rhp->rdev, &context->uctx); uctx 687 drivers/infiniband/hw/cxgb3/iwch_provider.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx); uctx 759 drivers/infiniband/hw/cxgb3/iwch_provider.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx)) { uctx 797 drivers/infiniband/hw/cxgb3/iwch_provider.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx); uctx 188 drivers/infiniband/hw/cxgb3/iwch_provider.h struct cxio_ucontext uctx; uctx 38 drivers/infiniband/hw/cxgb4/cq.c struct c4iw_dev_ucontext *uctx, struct sk_buff *skb, uctx 67 drivers/infiniband/hw/cxgb4/cq.c c4iw_put_cqid(rdev, cq->cqid, uctx); uctx 71 drivers/infiniband/hw/cxgb4/cq.c struct c4iw_dev_ucontext *uctx, uctx 77 drivers/infiniband/hw/cxgb4/cq.c int user = (uctx != &rdev->uctx); uctx 83 drivers/infiniband/hw/cxgb4/cq.c ucontext = container_of(uctx, struct c4iw_ucontext, uctx); uctx 85 drivers/infiniband/hw/cxgb4/cq.c cq->cqid = c4iw_get_cqid(rdev, uctx); uctx 179 drivers/infiniband/hw/cxgb4/cq.c c4iw_put_cqid(rdev, cq->cqid, uctx); uctx 985 drivers/infiniband/hw/cxgb4/cq.c ucontext ? &ucontext->uctx : &chp->cq.rdev->uctx, uctx 1069 drivers/infiniband/hw/cxgb4/cq.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx, uctx 1140 drivers/infiniband/hw/cxgb4/cq.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx, uctx 748 drivers/infiniband/hw/cxgb4/device.c struct c4iw_dev_ucontext *uctx) uctx 753 drivers/infiniband/hw/cxgb4/device.c mutex_lock(&uctx->lock); uctx 754 drivers/infiniband/hw/cxgb4/device.c list_for_each_safe(pos, nxt, &uctx->qpids) { uctx 767 drivers/infiniband/hw/cxgb4/device.c list_for_each_safe(pos, nxt, &uctx->cqids) { uctx 772 drivers/infiniband/hw/cxgb4/device.c mutex_unlock(&uctx->lock); uctx 776 drivers/infiniband/hw/cxgb4/device.c struct c4iw_dev_ucontext *uctx) uctx 778 drivers/infiniband/hw/cxgb4/device.c INIT_LIST_HEAD(&uctx->qpids); uctx 779 drivers/infiniband/hw/cxgb4/device.c INIT_LIST_HEAD(&uctx->cqids); uctx 780 drivers/infiniband/hw/cxgb4/device.c mutex_init(&uctx->lock); uctx 789 drivers/infiniband/hw/cxgb4/device.c c4iw_init_dev_ucontext(rdev, &rdev->uctx); uctx 925 drivers/infiniband/hw/cxgb4/device.c c4iw_release_dev_ucontext(rdev, &rdev->uctx); uctx 175 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext uctx; uctx 529 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext uctx; uctx 948 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext *uctx); uctx 967 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext *uctx); uctx 969 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext *uctx); uctx 1028 drivers/infiniband/hw/cxgb4/iw_cxgb4.h u32 c4iw_get_cqid(struct c4iw_rdev *rdev, struct c4iw_dev_ucontext *uctx); uctx 1030 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext *uctx); uctx 1031 drivers/infiniband/hw/cxgb4/iw_cxgb4.h u32 c4iw_get_qpid(struct c4iw_rdev *rdev, struct c4iw_dev_ucontext *uctx); uctx 1033 drivers/infiniband/hw/cxgb4/iw_cxgb4.h struct c4iw_dev_ucontext *uctx); uctx 72 drivers/infiniband/hw/cxgb4/provider.c c4iw_release_dev_ucontext(&rhp->rdev, &ucontext->uctx); uctx 86 drivers/infiniband/hw/cxgb4/provider.c c4iw_init_dev_ucontext(&rhp->rdev, &context->uctx); uctx 151 drivers/infiniband/hw/cxgb4/qp.c struct c4iw_dev_ucontext *uctx, int has_rq) uctx 159 drivers/infiniband/hw/cxgb4/qp.c c4iw_put_qpid(rdev, wq->sq.qid, uctx); uctx 167 drivers/infiniband/hw/cxgb4/qp.c c4iw_put_qpid(rdev, wq->rq.qid, uctx); uctx 201 drivers/infiniband/hw/cxgb4/qp.c struct c4iw_dev_ucontext *uctx, uctx 205 drivers/infiniband/hw/cxgb4/qp.c int user = (uctx != &rdev->uctx); uctx 213 drivers/infiniband/hw/cxgb4/qp.c wq->sq.qid = c4iw_get_qpid(rdev, uctx); uctx 218 drivers/infiniband/hw/cxgb4/qp.c wq->rq.qid = c4iw_get_qpid(rdev, uctx); uctx 407 drivers/infiniband/hw/cxgb4/qp.c c4iw_put_qpid(rdev, wq->rq.qid, uctx); uctx 409 drivers/infiniband/hw/cxgb4/qp.c c4iw_put_qpid(rdev, wq->sq.qid, uctx); uctx 2103 drivers/infiniband/hw/cxgb4/qp.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx, !qhp->srq); uctx 2186 drivers/infiniband/hw/cxgb4/qp.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx, uctx 2359 drivers/infiniband/hw/cxgb4/qp.c ucontext ? &ucontext->uctx : &rhp->rdev.uctx, !attrs->srq); uctx 2480 drivers/infiniband/hw/cxgb4/qp.c static void free_srq_queue(struct c4iw_srq *srq, struct c4iw_dev_ucontext *uctx, uctx 2514 drivers/infiniband/hw/cxgb4/qp.c c4iw_put_qpid(rdev, wq->qid, uctx); uctx 2517 drivers/infiniband/hw/cxgb4/qp.c static int alloc_srq_queue(struct c4iw_srq *srq, struct c4iw_dev_ucontext *uctx, uctx 2521 drivers/infiniband/hw/cxgb4/qp.c int user = (uctx != &rdev->uctx); uctx 2530 drivers/infiniband/hw/cxgb4/qp.c wq->qid = c4iw_get_qpid(rdev, uctx); uctx 2647 drivers/infiniband/hw/cxgb4/qp.c c4iw_put_qpid(rdev, wq->qid, uctx); uctx 2731 drivers/infiniband/hw/cxgb4/qp.c ret = alloc_srq_queue(srq, ucontext ? &ucontext->uctx : uctx 2732 drivers/infiniband/hw/cxgb4/qp.c &rhp->rdev.uctx, srq->wr_waitp); uctx 2789 drivers/infiniband/hw/cxgb4/qp.c free_srq_queue(srq, ucontext ? &ucontext->uctx : &rhp->rdev.uctx, uctx 2812 drivers/infiniband/hw/cxgb4/qp.c free_srq_queue(srq, ucontext ? &ucontext->uctx : &rhp->rdev.uctx, uctx 108 drivers/infiniband/hw/cxgb4/resource.c u32 c4iw_get_cqid(struct c4iw_rdev *rdev, struct c4iw_dev_ucontext *uctx) uctx 114 drivers/infiniband/hw/cxgb4/resource.c mutex_lock(&uctx->lock); uctx 115 drivers/infiniband/hw/cxgb4/resource.c if (!list_empty(&uctx->cqids)) { uctx 116 drivers/infiniband/hw/cxgb4/resource.c entry = list_entry(uctx->cqids.next, struct c4iw_qid_list, uctx 133 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->cqids); uctx 144 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->qpids); uctx 150 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->qpids); uctx 154 drivers/infiniband/hw/cxgb4/resource.c mutex_unlock(&uctx->lock); uctx 164 drivers/infiniband/hw/cxgb4/resource.c struct c4iw_dev_ucontext *uctx) uctx 173 drivers/infiniband/hw/cxgb4/resource.c mutex_lock(&uctx->lock); uctx 174 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->cqids); uctx 175 drivers/infiniband/hw/cxgb4/resource.c mutex_unlock(&uctx->lock); uctx 178 drivers/infiniband/hw/cxgb4/resource.c u32 c4iw_get_qpid(struct c4iw_rdev *rdev, struct c4iw_dev_ucontext *uctx) uctx 184 drivers/infiniband/hw/cxgb4/resource.c mutex_lock(&uctx->lock); uctx 185 drivers/infiniband/hw/cxgb4/resource.c if (!list_empty(&uctx->qpids)) { uctx 186 drivers/infiniband/hw/cxgb4/resource.c entry = list_entry(uctx->qpids.next, struct c4iw_qid_list, uctx 207 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->qpids); uctx 218 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->cqids); uctx 224 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->cqids); uctx 228 drivers/infiniband/hw/cxgb4/resource.c mutex_unlock(&uctx->lock); uctx 238 drivers/infiniband/hw/cxgb4/resource.c struct c4iw_dev_ucontext *uctx) uctx 247 drivers/infiniband/hw/cxgb4/resource.c mutex_lock(&uctx->lock); uctx 248 drivers/infiniband/hw/cxgb4/resource.c list_add_tail(&entry->entry, &uctx->qpids); uctx 249 drivers/infiniband/hw/cxgb4/resource.c mutex_unlock(&uctx->lock); uctx 310 drivers/infiniband/hw/hns/hns_roce_main.c static int hns_roce_alloc_ucontext(struct ib_ucontext *uctx, uctx 314 drivers/infiniband/hw/hns/hns_roce_main.c struct hns_roce_ucontext *context = to_hr_ucontext(uctx); uctx 316 drivers/infiniband/hw/hns/hns_roce_main.c struct hns_roce_dev *hr_dev = to_hr_dev(uctx->device); uctx 694 drivers/infiniband/hw/hns/hns_roce_qp.c struct hns_roce_ucontext *uctx = rdma_udata_to_drv_context( uctx 782 drivers/infiniband/hw/hns/hns_roce_qp.c ret = hns_roce_db_map_user(uctx, udata, ucmd.sdb_addr, uctx 797 drivers/infiniband/hw/hns/hns_roce_qp.c ret = hns_roce_db_map_user(uctx, udata, ucmd.db_addr, uctx 976 drivers/infiniband/hw/hns/hns_roce_qp.c hns_roce_db_unmap_user(uctx, &hr_qp->rdb); uctx 988 drivers/infiniband/hw/hns/hns_roce_qp.c hns_roce_db_unmap_user(uctx, &hr_qp->sdb); uctx 119 drivers/infiniband/hw/i40iw/i40iw_verbs.c static int i40iw_alloc_ucontext(struct ib_ucontext *uctx, uctx 122 drivers/infiniband/hw/i40iw/i40iw_verbs.c struct ib_device *ibdev = uctx->device; uctx 126 drivers/infiniband/hw/i40iw/i40iw_verbs.c struct i40iw_ucontext *ucontext = to_ucontext(uctx); uctx 1092 drivers/infiniband/hw/mlx4/main.c static int mlx4_ib_alloc_ucontext(struct ib_ucontext *uctx, uctx 1095 drivers/infiniband/hw/mlx4/main.c struct ib_device *ibdev = uctx->device; uctx 1097 drivers/infiniband/hw/mlx4/main.c struct mlx4_ib_ucontext *context = to_mucontext(uctx); uctx 133 drivers/infiniband/hw/mlx5/devx.c void *uctx; uctx 142 drivers/infiniband/hw/mlx5/devx.c uctx = MLX5_ADDR_OF(create_uctx_in, in, uctx); uctx 152 drivers/infiniband/hw/mlx5/devx.c MLX5_SET(uctx, uctx, cap, cap); uctx 1765 drivers/infiniband/hw/mlx5/main.c static int mlx5_ib_alloc_ucontext(struct ib_ucontext *uctx, uctx 1768 drivers/infiniband/hw/mlx5/main.c struct ib_device *ibdev = uctx->device; uctx 1773 drivers/infiniband/hw/mlx5/main.c struct mlx5_ib_ucontext *context = to_mucontext(uctx); uctx 304 drivers/infiniband/hw/mthca/mthca_provider.c static int mthca_alloc_ucontext(struct ib_ucontext *uctx, uctx 307 drivers/infiniband/hw/mthca/mthca_provider.c struct ib_device *ibdev = uctx->device; uctx 309 drivers/infiniband/hw/mthca/mthca_provider.c struct mthca_ucontext *context = to_mucontext(uctx); uctx 348 drivers/infiniband/hw/ocrdma/ocrdma.h struct ocrdma_ucontext *uctx; uctx 195 drivers/infiniband/hw/ocrdma/ocrdma_ah.c if ((pd->uctx) && (pd->uctx->ah_tbl.va)) { uctx 196 drivers/infiniband/hw/ocrdma/ocrdma_ah.c ahid_addr = pd->uctx->ah_tbl.va + rdma_ah_get_dlid(attr); uctx 199 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static int ocrdma_add_mmap(struct ocrdma_ucontext *uctx, u64 phy_addr, uctx 211 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_lock(&uctx->mm_list_lock); uctx 212 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c list_add_tail(&mm->entry, &uctx->mm_head); uctx 213 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 217 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static void ocrdma_del_mmap(struct ocrdma_ucontext *uctx, u64 phy_addr, uctx 222 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_lock(&uctx->mm_list_lock); uctx 223 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c list_for_each_entry_safe(mm, tmp, &uctx->mm_head, entry) { uctx 231 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 234 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static bool ocrdma_search_mmap(struct ocrdma_ucontext *uctx, u64 phy_addr, uctx 240 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_lock(&uctx->mm_list_lock); uctx 241 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c list_for_each_entry(mm, &uctx->mm_head, entry) { uctx 248 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 364 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx, uctx 369 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (udata && uctx && dev->attr.max_dpp_pds) { uctx 394 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static inline int is_ucontext_pd(struct ocrdma_ucontext *uctx, uctx 397 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c return (uctx->cntxt_pd == pd); uctx 410 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx, uctx 422 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->cntxt_pd = get_ocrdma_pd(pd); uctx 424 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = _ocrdma_alloc_pd(dev, uctx->cntxt_pd, uctx, udata); uctx 426 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c kfree(uctx->cntxt_pd); uctx 430 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->cntxt_pd->uctx = uctx; uctx 431 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->cntxt_pd->ibpd.device = &dev->ibdev; uctx 436 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static void ocrdma_dealloc_ucontext_pd(struct ocrdma_ucontext *uctx) uctx 438 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_pd *pd = uctx->cntxt_pd; uctx 441 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (uctx->pd_in_use) { uctx 445 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c kfree(uctx->cntxt_pd); uctx 446 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->cntxt_pd = NULL; uctx 450 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static struct ocrdma_pd *ocrdma_get_ucontext_pd(struct ocrdma_ucontext *uctx) uctx 454 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_lock(&uctx->mm_list_lock); uctx 455 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (!uctx->pd_in_use) { uctx 456 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->pd_in_use = true; uctx 457 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c pd = uctx->cntxt_pd; uctx 459 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 464 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c static void ocrdma_release_ucontext_pd(struct ocrdma_ucontext *uctx) uctx 466 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_lock(&uctx->mm_list_lock); uctx 467 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->pd_in_use = false; uctx 468 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 471 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c int ocrdma_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata) uctx 473 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ib_device *ibdev = uctx->device; uctx 475 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *ctx = get_ocrdma_ucontext(uctx); uctx 529 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx = get_ocrdma_ucontext(ibctx); uctx 533 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_dealloc_ucontext_pd(uctx); uctx 535 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(uctx, uctx->ah_tbl.pa, uctx->ah_tbl.len); uctx 536 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c dma_free_coherent(&pdev->dev, uctx->ah_tbl.len, uctx->ah_tbl.va, uctx 537 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx->ah_tbl.pa); uctx 539 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c list_for_each_entry_safe(mm, tmp, &uctx->mm_head, entry) { uctx 596 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx = rdma_udata_to_drv_context( uctx 605 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(uctx, db_page_addr, db_page_size); uctx 612 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(uctx, dpp_page_addr, uctx 624 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c pd->uctx = uctx; uctx 629 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, dpp_page_addr, PAGE_SIZE); uctx 631 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, db_page_addr, db_page_size); uctx 642 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx = rdma_udata_to_drv_context( uctx 646 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c pd = ocrdma_get_ucontext_pd(uctx); uctx 654 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = _ocrdma_alloc_pd(dev, pd, uctx, udata); uctx 668 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_release_ucontext_pd(uctx); uctx 679 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx = NULL; uctx 682 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uctx = pd->uctx; uctx 683 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (uctx) { uctx 687 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, dpp_db, PAGE_SIZE); uctx 689 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, usr_db, dev->nic_info.db_page_size); uctx 691 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (is_ucontext_pd(uctx, pd)) { uctx 692 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_release_ucontext_pd(uctx); uctx 943 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx = rdma_udata_to_drv_context( uctx 957 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c uresp.db_page_addr = ocrdma_get_db_addr(dev, uctx->cntxt_pd->id); uctx 966 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(uctx, uresp.db_page_addr, uresp.db_page_size); uctx 969 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(uctx, uresp.page_addr[0], uresp.page_size); uctx 971 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(uctx, uresp.db_page_addr, uresp.db_page_size); uctx 974 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c cq->ucontext = uctx; uctx 986 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c struct ocrdma_ucontext *uctx = rdma_udata_to_drv_context( uctx 1007 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c pd_id = uctx->cntxt_pd->id; uctx 1225 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(pd->uctx, uresp.sq_page_addr[0], uctx 1231 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(pd->uctx, uresp.rq_page_addr[0], uctx 1238 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, uresp.sq_page_addr[0], uresp.sq_page_size); uctx 1725 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (!pd->uctx) { uctx 1731 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (pd->uctx) { uctx 1732 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, (u64) qp->sq.pa, uctx 1735 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(pd->uctx, (u64) qp->rq.pa, uctx 1773 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c status = ocrdma_add_mmap(srq->pd->uctx, uresp.rq_page_addr[0], uctx 1877 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c if (srq->pd->uctx) uctx 1878 drivers/infiniband/hw/ocrdma/ocrdma_verbs.c ocrdma_del_mmap(srq->pd->uctx, (u64) srq->rq.pa, uctx 66 drivers/infiniband/hw/ocrdma/ocrdma_verbs.h int ocrdma_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata); uctx 67 drivers/infiniband/hw/ocrdma/ocrdma_verbs.h void ocrdma_dealloc_ucontext(struct ib_ucontext *uctx); uctx 301 drivers/infiniband/hw/qedr/qedr.h struct qedr_ucontext *uctx; uctx 260 drivers/infiniband/hw/qedr/verbs.c static int qedr_add_mmap(struct qedr_ucontext *uctx, u64 phy_addr, uctx 280 drivers/infiniband/hw/qedr/verbs.c mutex_lock(&uctx->mm_list_lock); uctx 281 drivers/infiniband/hw/qedr/verbs.c list_add(&mm->entry, &uctx->mm_head); uctx 282 drivers/infiniband/hw/qedr/verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 284 drivers/infiniband/hw/qedr/verbs.c DP_DEBUG(uctx->dev, QEDR_MSG_MISC, uctx 287 drivers/infiniband/hw/qedr/verbs.c (unsigned long)mm->key.len, uctx); uctx 292 drivers/infiniband/hw/qedr/verbs.c static bool qedr_search_mmap(struct qedr_ucontext *uctx, u64 phy_addr, uctx 298 drivers/infiniband/hw/qedr/verbs.c mutex_lock(&uctx->mm_list_lock); uctx 299 drivers/infiniband/hw/qedr/verbs.c list_for_each_entry(mm, &uctx->mm_head, entry) { uctx 306 drivers/infiniband/hw/qedr/verbs.c mutex_unlock(&uctx->mm_list_lock); uctx 307 drivers/infiniband/hw/qedr/verbs.c DP_DEBUG(uctx->dev, QEDR_MSG_MISC, uctx 309 drivers/infiniband/hw/qedr/verbs.c mm->key.phy_addr, mm->key.len, uctx, found); uctx 314 drivers/infiniband/hw/qedr/verbs.c int qedr_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata) uctx 316 drivers/infiniband/hw/qedr/verbs.c struct ib_device *ibdev = uctx->device; uctx 318 drivers/infiniband/hw/qedr/verbs.c struct qedr_ucontext *ctx = get_qedr_ucontext(uctx); uctx 371 drivers/infiniband/hw/qedr/verbs.c struct qedr_ucontext *uctx = get_qedr_ucontext(ibctx); uctx 374 drivers/infiniband/hw/qedr/verbs.c DP_DEBUG(uctx->dev, QEDR_MSG_INIT, "Deallocating user context %p\n", uctx 375 drivers/infiniband/hw/qedr/verbs.c uctx); uctx 376 drivers/infiniband/hw/qedr/verbs.c uctx->dev->ops->rdma_remove_user(uctx->dev->rdma_ctx, uctx->dpi); uctx 378 drivers/infiniband/hw/qedr/verbs.c list_for_each_entry_safe(mm, tmp, &uctx->mm_head, entry) { uctx 379 drivers/infiniband/hw/qedr/verbs.c DP_DEBUG(uctx->dev, QEDR_MSG_MISC, uctx 381 drivers/infiniband/hw/qedr/verbs.c mm->key.phy_addr, mm->key.len, uctx); uctx 470 drivers/infiniband/hw/qedr/verbs.c pd->uctx = context; uctx 471 drivers/infiniband/hw/qedr/verbs.c pd->uctx->pd = pd; uctx 1528 drivers/infiniband/hw/qedr/verbs.c params->dpi = pd->uctx ? pd->uctx->dpi : dev->dpi; uctx 46 drivers/infiniband/hw/qedr/verbs.h int qedr_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata); uctx 47 drivers/infiniband/hw/qedr/verbs.h void qedr_dealloc_ucontext(struct ib_ucontext *uctx); uctx 645 drivers/infiniband/hw/usnic/usnic_ib_verbs.c int usnic_ib_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata) uctx 647 drivers/infiniband/hw/usnic/usnic_ib_verbs.c struct ib_device *ibdev = uctx->device; uctx 648 drivers/infiniband/hw/usnic/usnic_ib_verbs.c struct usnic_ib_ucontext *context = to_ucontext(uctx); uctx 675 drivers/infiniband/hw/usnic/usnic_ib_verbs.c struct usnic_ib_ucontext *uctx = to_ucontext(context); uctx 694 drivers/infiniband/hw/usnic/usnic_ib_verbs.c list_for_each_entry(qp_grp, &uctx->qp_grp_list, link) { uctx 68 drivers/infiniband/hw/usnic/usnic_ib_verbs.h int usnic_ib_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata); uctx 313 drivers/infiniband/hw/vmw_pvrdma/pvrdma_verbs.c int pvrdma_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata) uctx 315 drivers/infiniband/hw/vmw_pvrdma/pvrdma_verbs.c struct ib_device *ibdev = uctx->device; uctx 317 drivers/infiniband/hw/vmw_pvrdma/pvrdma_verbs.c struct pvrdma_ucontext *context = to_vucontext(uctx); uctx 399 drivers/infiniband/hw/vmw_pvrdma/pvrdma_verbs.h int pvrdma_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata); uctx 298 drivers/infiniband/sw/rdmavt/vt.c static int rvt_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata) uctx 145 drivers/infiniband/sw/rxe/rxe_verbs.c static int rxe_alloc_ucontext(struct ib_ucontext *uctx, struct ib_udata *udata) uctx 147 drivers/infiniband/sw/rxe/rxe_verbs.c struct rxe_dev *rxe = to_rdev(uctx->device); uctx 148 drivers/infiniband/sw/rxe/rxe_verbs.c struct rxe_ucontext *uc = to_ruc(uctx); uctx 37 drivers/infiniband/sw/siw/siw_verbs.c static u32 siw_create_uobj(struct siw_ucontext *uctx, void *vaddr, u32 size) uctx 47 drivers/infiniband/sw/siw/siw_verbs.c if (xa_alloc_cyclic(&uctx->xa, &key, uobj, limit, &uctx->uobj_nextkey, uctx 58 drivers/infiniband/sw/siw/siw_verbs.c static struct siw_uobj *siw_get_uobj(struct siw_ucontext *uctx, uctx 61 drivers/infiniband/sw/siw/siw_verbs.c struct siw_uobj *uobj = xa_load(&uctx->xa, off); uctx 71 drivers/infiniband/sw/siw/siw_verbs.c struct siw_ucontext *uctx = to_siw_ctx(ctx); uctx 84 drivers/infiniband/sw/siw/siw_verbs.c uobj = siw_get_uobj(uctx, off, size); uctx 86 drivers/infiniband/sw/siw/siw_verbs.c siw_dbg(&uctx->sdev->base_dev, "mmap lookup failed: %lu, %u\n", uctx 137 drivers/infiniband/sw/siw/siw_verbs.c struct siw_ucontext *uctx = to_siw_ctx(base_ctx); uctx 146 drivers/infiniband/sw/siw/siw_verbs.c xa_for_each(&uctx->xa, index, entry) { uctx 147 drivers/infiniband/sw/siw/siw_verbs.c kfree(xa_erase(&uctx->xa, index)); uctx 150 drivers/infiniband/sw/siw/siw_verbs.c xa_destroy(&uctx->xa); uctx 151 drivers/infiniband/sw/siw/siw_verbs.c atomic_dec(&uctx->sdev->num_ctx); uctx 314 drivers/infiniband/sw/siw/siw_verbs.c struct siw_ucontext *uctx = uctx 462 drivers/infiniband/sw/siw/siw_verbs.c siw_create_uobj(uctx, qp->sendq, uctx 467 drivers/infiniband/sw/siw/siw_verbs.c siw_create_uobj(uctx, qp->recvq, uctx 505 drivers/infiniband/sw/siw/siw_verbs.c kfree(xa_erase(&uctx->xa, qp->xa_sq_index)); uctx 507 drivers/infiniband/sw/siw/siw_verbs.c kfree(xa_erase(&uctx->xa, qp->xa_rq_index)); uctx 607 drivers/infiniband/sw/siw/siw_verbs.c struct siw_ucontext *uctx = uctx 621 drivers/infiniband/sw/siw/siw_verbs.c if (uctx && qp->xa_sq_index != SIW_INVAL_UOBJ_KEY) uctx 622 drivers/infiniband/sw/siw/siw_verbs.c kfree(xa_erase(&uctx->xa, qp->xa_sq_index)); uctx 623 drivers/infiniband/sw/siw/siw_verbs.c if (uctx && qp->xa_rq_index != SIW_INVAL_UOBJ_KEY) uctx 624 drivers/infiniband/sw/siw/siw_verbs.c kfree(xa_erase(&uctx->xa, qp->xa_rq_index)); uctx 10008 include/linux/mlx5/mlx5_ifc.h struct mlx5_ifc_uctx_bits uctx; uctx 470 net/key/af_key.c struct xfrm_user_sec_ctx *uctx = NULL; uctx 473 net/key/af_key.c uctx = kmalloc((sizeof(*uctx)+ctx_size), gfp); uctx 475 net/key/af_key.c if (!uctx) uctx 478 net/key/af_key.c uctx->len = pfkey_sec_ctx_len(sec_ctx); uctx 479 net/key/af_key.c uctx->exttype = sec_ctx->sadb_x_sec_exttype; uctx 480 net/key/af_key.c uctx->ctx_doi = sec_ctx->sadb_x_ctx_doi; uctx 481 net/key/af_key.c uctx->ctx_alg = sec_ctx->sadb_x_ctx_alg; uctx 482 net/key/af_key.c uctx->ctx_len = sec_ctx->sadb_x_ctx_len; uctx 483 net/key/af_key.c memcpy(uctx + 1, sec_ctx + 1, uctx 484 net/key/af_key.c uctx->ctx_len); uctx 486 net/key/af_key.c return uctx; uctx 1158 net/key/af_key.c struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); uctx 1160 net/key/af_key.c if (!uctx) uctx 1163 net/key/af_key.c err = security_xfrm_state_alloc(x, uctx); uctx 1164 net/key/af_key.c kfree(uctx); uctx 2290 net/key/af_key.c struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); uctx 2292 net/key/af_key.c if (!uctx) { uctx 2297 net/key/af_key.c err = security_xfrm_policy_alloc(&xp->security, uctx, GFP_KERNEL); uctx 2298 net/key/af_key.c kfree(uctx); uctx 2392 net/key/af_key.c struct xfrm_user_sec_ctx *uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_KERNEL); uctx 2394 net/key/af_key.c if (!uctx) uctx 2397 net/key/af_key.c err = security_xfrm_policy_alloc(&pol_ctx, uctx, GFP_KERNEL); uctx 2398 net/key/af_key.c kfree(uctx); uctx 3300 net/key/af_key.c struct xfrm_user_sec_ctx *uctx; uctx 3311 net/key/af_key.c uctx = pfkey_sadb2xfrm_user_sec_ctx(sec_ctx, GFP_ATOMIC); uctx 3312 net/key/af_key.c *dir = security_xfrm_policy_alloc(&xp->security, uctx, GFP_ATOMIC); uctx 3313 net/key/af_key.c kfree(uctx); uctx 107 net/xfrm/xfrm_user.c struct xfrm_user_sec_ctx *uctx; uctx 112 net/xfrm/xfrm_user.c uctx = nla_data(rt); uctx 113 net/xfrm/xfrm_user.c if (uctx->len > nla_len(rt) || uctx 114 net/xfrm/xfrm_user.c uctx->len != (sizeof(struct xfrm_user_sec_ctx) + uctx->ctx_len)) uctx 815 net/xfrm/xfrm_user.c struct xfrm_user_sec_ctx *uctx; uctx 817 net/xfrm/xfrm_user.c int ctx_size = sizeof(*uctx) + s->ctx_len; uctx 823 net/xfrm/xfrm_user.c uctx = nla_data(attr); uctx 824 net/xfrm/xfrm_user.c uctx->exttype = XFRMA_SEC_CTX; uctx 825 net/xfrm/xfrm_user.c uctx->len = ctx_size; uctx 826 net/xfrm/xfrm_user.c uctx->ctx_doi = s->ctx_doi; uctx 827 net/xfrm/xfrm_user.c uctx->ctx_alg = s->ctx_alg; uctx 828 net/xfrm/xfrm_user.c uctx->ctx_len = s->ctx_len; uctx 829 net/xfrm/xfrm_user.c memcpy(uctx + 1, s->ctx_str, s->ctx_len); uctx 1457 net/xfrm/xfrm_user.c struct xfrm_user_sec_ctx *uctx; uctx 1462 net/xfrm/xfrm_user.c uctx = nla_data(rt); uctx 1463 net/xfrm/xfrm_user.c return security_xfrm_policy_alloc(&pol->security, uctx, GFP_KERNEL); uctx 1895 net/xfrm/xfrm_user.c struct xfrm_user_sec_ctx *uctx = nla_data(rt); uctx 1897 net/xfrm/xfrm_user.c err = security_xfrm_policy_alloc(&ctx, uctx, GFP_KERNEL); uctx 2195 net/xfrm/xfrm_user.c struct xfrm_user_sec_ctx *uctx = nla_data(rt); uctx 2197 net/xfrm/xfrm_user.c err = security_xfrm_policy_alloc(&ctx, uctx, GFP_KERNEL); uctx 14 security/selinux/include/xfrm.h struct xfrm_user_sec_ctx *uctx, uctx 21 security/selinux/include/xfrm.h struct xfrm_user_sec_ctx *uctx); uctx 75 security/selinux/xfrm.c struct xfrm_user_sec_ctx *uctx, uctx 83 security/selinux/xfrm.c if (ctxp == NULL || uctx == NULL || uctx 84 security/selinux/xfrm.c uctx->ctx_doi != XFRM_SC_DOI_LSM || uctx 85 security/selinux/xfrm.c uctx->ctx_alg != XFRM_SC_ALG_SELINUX) uctx 88 security/selinux/xfrm.c str_len = uctx->ctx_len; uctx 99 security/selinux/xfrm.c memcpy(ctx->ctx_str, &uctx[1], str_len); uctx 285 security/selinux/xfrm.c struct xfrm_user_sec_ctx *uctx, uctx 288 security/selinux/xfrm.c return selinux_xfrm_alloc_user(ctxp, uctx, gfp); uctx 334 security/selinux/xfrm.c struct xfrm_user_sec_ctx *uctx) uctx 336 security/selinux/xfrm.c return selinux_xfrm_alloc_user(&x->security, uctx, GFP_KERNEL);