Lines Matching full:object

25 #include <nvif/object.h>
31 nvif_object_ioctl(struct nvif_object *object, void *data, u32 size, void **hack) in nvif_object_ioctl() argument
33 struct nvif_client *client = object->client; in nvif_object_ioctl()
39 if (object != &client->object) in nvif_object_ioctl()
40 args->v0.object = nvif_handle(object); in nvif_object_ioctl()
42 args->v0.object = 0; in nvif_object_ioctl()
47 return client->driver->ioctl(client->object.priv, client->super, in nvif_object_ioctl()
59 nvif_object_sclass_get(struct nvif_object *object, struct nvif_sclass **psclass) in nvif_object_sclass_get() argument
77 ret = nvif_object_ioctl(object, args, size, NULL); in nvif_object_sclass_get()
103 nvif_object_rd(struct nvif_object *object, int size, u64 addr) in nvif_object_rd() argument
113 int ret = nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_rd()
122 nvif_object_wr(struct nvif_object *object, int size, u64 addr, u32 data) in nvif_object_wr() argument
133 int ret = nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_wr()
140 nvif_object_mthd(struct nvif_object *object, u32 mthd, void *data, u32 size) in nvif_object_mthd() argument
161 ret = nvif_object_ioctl(object, args, sizeof(*args) + size, NULL); in nvif_object_mthd()
169 nvif_object_unmap_handle(struct nvif_object *object) in nvif_object_unmap_handle() argument
178 nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_unmap_handle()
182 nvif_object_map_handle(struct nvif_object *object, void *argv, u32 argc, in nvif_object_map_handle() argument
197 ret = nvif_object_ioctl(object, args, argn, NULL); in nvif_object_map_handle()
206 nvif_object_unmap(struct nvif_object *object) in nvif_object_unmap() argument
208 struct nvif_client *client = object->client; in nvif_object_unmap()
209 if (object->map.ptr) { in nvif_object_unmap()
210 if (object->map.size) { in nvif_object_unmap()
211 client->driver->unmap(client, object->map.ptr, in nvif_object_unmap()
212 object->map.size); in nvif_object_unmap()
213 object->map.size = 0; in nvif_object_unmap()
215 object->map.ptr = NULL; in nvif_object_unmap()
216 nvif_object_unmap_handle(object); in nvif_object_unmap()
221 nvif_object_map(struct nvif_object *object, void *argv, u32 argc) in nvif_object_map() argument
223 struct nvif_client *client = object->client; in nvif_object_map()
225 int ret = nvif_object_map_handle(object, argv, argc, &handle, &length); in nvif_object_map()
228 object->map.ptr = client->driver->map(client, in nvif_object_map()
231 if (ret = -ENOMEM, object->map.ptr) { in nvif_object_map()
232 object->map.size = length; in nvif_object_map()
236 object->map.ptr = (void *)(unsigned long)handle; in nvif_object_map()
239 nvif_object_unmap_handle(object); in nvif_object_map()
245 nvif_object_dtor(struct nvif_object *object) in nvif_object_dtor() argument
254 if (!object->client) in nvif_object_dtor()
257 nvif_object_unmap(object); in nvif_object_dtor()
258 nvif_object_ioctl(object, &args, sizeof(args), NULL); in nvif_object_dtor()
259 object->client = NULL; in nvif_object_dtor()
264 s32 oclass, void *data, u32 size, struct nvif_object *object) in nvif_object_ctor() argument
272 object->client = NULL; in nvif_object_ctor()
273 object->name = name ? name : "nvifObject"; in nvif_object_ctor()
274 object->handle = handle; in nvif_object_ctor()
275 object->oclass = oclass; in nvif_object_ctor()
276 object->map.ptr = NULL; in nvif_object_ctor()
277 object->map.size = 0; in nvif_object_ctor()
281 nvif_object_dtor(object); in nvif_object_ctor()
285 object->parent = parent->parent; in nvif_object_ctor()
291 args->new.token = nvif_handle(object); in nvif_object_ctor()
292 args->new.object = nvif_handle(object); in nvif_object_ctor()
298 &object->priv); in nvif_object_ctor()
302 object->client = parent->client; in nvif_object_ctor()
306 nvif_object_dtor(object); in nvif_object_ctor()