Lines Matching refs:args

36 	} *args = data;  in nvif_object_ioctl()  local
38 if (size >= sizeof(*args) && args->v0.version == 0) { in nvif_object_ioctl()
39 args->v0.owner = NVIF_IOCTL_V0_OWNER_ANY; in nvif_object_ioctl()
40 args->v0.path_nr = 0; in nvif_object_ioctl()
41 while (args->v0.path_nr < ARRAY_SIZE(args->v0.path)) { in nvif_object_ioctl()
42 args->v0.path[args->v0.path_nr++] = object->handle; in nvif_object_ioctl()
59 } *args; in nvif_object_sclass() local
60 u32 size = count * sizeof(args->sclass.oclass[0]); in nvif_object_sclass()
63 if (!(args = kmalloc(sizeof(*args) + size, GFP_KERNEL))) in nvif_object_sclass()
65 args->ioctl.version = 0; in nvif_object_sclass()
66 args->ioctl.type = NVIF_IOCTL_V0_SCLASS; in nvif_object_sclass()
67 args->sclass.version = 0; in nvif_object_sclass()
68 args->sclass.count = count; in nvif_object_sclass()
70 memcpy(args->sclass.oclass, oclass, size); in nvif_object_sclass()
71 ret = nvif_object_ioctl(object, args, sizeof(*args) + size, NULL); in nvif_object_sclass()
72 ret = ret ? ret : args->sclass.count; in nvif_object_sclass()
73 memcpy(oclass, args->sclass.oclass, size); in nvif_object_sclass()
74 kfree(args); in nvif_object_sclass()
84 } args = { in nvif_object_rd() local
89 int ret = nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_rd()
94 return args.rd.data; in nvif_object_rd()
103 } args = { in nvif_object_wr() local
109 int ret = nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_wr()
121 } *args; in nvif_object_mthd() local
125 if (sizeof(*args) + size > sizeof(stack)) { in nvif_object_mthd()
126 if (!(args = kmalloc(sizeof(*args) + size, GFP_KERNEL))) in nvif_object_mthd()
129 args = (void *)stack; in nvif_object_mthd()
131 args->ioctl.version = 0; in nvif_object_mthd()
132 args->ioctl.type = NVIF_IOCTL_V0_MTHD; in nvif_object_mthd()
133 args->mthd.version = 0; in nvif_object_mthd()
134 args->mthd.method = mthd; in nvif_object_mthd()
136 memcpy(args->mthd.data, data, size); in nvif_object_mthd()
137 ret = nvif_object_ioctl(object, args, sizeof(*args) + size, NULL); in nvif_object_mthd()
138 memcpy(data, args->mthd.data, size); in nvif_object_mthd()
139 if (args != (void *)stack) in nvif_object_mthd()
140 kfree(args); in nvif_object_mthd()
152 } args = { in nvif_object_unmap() local
162 nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_unmap()
174 } args = { in nvif_object_map() local
177 int ret = nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_map()
179 object->map.size = args.map.length; in nvif_object_map()
180 object->map.ptr = client->driver->map(client, args.map.handle, in nvif_object_map()
202 } args = { in nvif_object_fini() local
207 nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_fini()