Lines Matching refs:cmd
44 uint32_t *cmd; in vmw_gmr2_bind() local
46 uint32_t define_size = sizeof(define_cmd) + sizeof(*cmd); in vmw_gmr2_bind()
48 uint32_t remap_size = VMW_PPN_SIZE * num_pages + (sizeof(remap_cmd) + sizeof(*cmd)) * remap_num; in vmw_gmr2_bind()
53 cmd_orig = cmd = VMW_CMD_RESERVE(dev_priv, cmd_size); in vmw_gmr2_bind()
54 if (unlikely(cmd == NULL)) in vmw_gmr2_bind()
60 *cmd++ = SVGA_CMD_DEFINE_GMR2; in vmw_gmr2_bind()
61 memcpy(cmd, &define_cmd, sizeof(define_cmd)); in vmw_gmr2_bind()
62 cmd += sizeof(define_cmd) / sizeof(*cmd); in vmw_gmr2_bind()
70 remap_cmd.flags = (VMW_PPN_SIZE > sizeof(*cmd)) ? in vmw_gmr2_bind()
79 *cmd++ = SVGA_CMD_REMAP_GMR2; in vmw_gmr2_bind()
80 memcpy(cmd, &remap_cmd, sizeof(remap_cmd)); in vmw_gmr2_bind()
81 cmd += sizeof(remap_cmd) / sizeof(*cmd); in vmw_gmr2_bind()
85 *cmd = vmw_piter_dma_addr(iter) >> PAGE_SHIFT; in vmw_gmr2_bind()
87 *((uint64_t *)cmd) = vmw_piter_dma_addr(iter) >> in vmw_gmr2_bind()
90 cmd += VMW_PPN_SIZE / sizeof(*cmd); in vmw_gmr2_bind()
98 BUG_ON(cmd != cmd_orig + cmd_size / sizeof(*cmd)); in vmw_gmr2_bind()
110 uint32_t *cmd; in vmw_gmr2_unbind() local
112 cmd = VMW_CMD_RESERVE(dev_priv, define_size); in vmw_gmr2_unbind()
113 if (unlikely(cmd == NULL)) in vmw_gmr2_unbind()
119 *cmd++ = SVGA_CMD_DEFINE_GMR2; in vmw_gmr2_unbind()
120 memcpy(cmd, &define_cmd, sizeof(define_cmd)); in vmw_gmr2_unbind()