projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
775921e
)
amdkfd: Implement the Get Version IOCTL
author
Oded Gabbay
<oded.gabbay@amd.com>
Sun, 2 Nov 2014 10:18:29 +0000
(12:18 +0200)
committer
Oded Gabbay
<oded.gabbay@amd.com>
Sun, 2 Nov 2014 10:18:29 +0000
(12:18 +0200)
Signed-off-by: Oded Gabbay <oded.gabbay@amd.com>
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
b/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
index 3130265e68275c6555635e1475a928ec24d1a7be..64c73bae960d7445589c08fbef16411f0cd2f230 100644
(file)
--- a/
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
+++ b/
drivers/gpu/drm/amd/amdkfd/kfd_chardev.c
@@
-123,7
+123,16
@@
static int kfd_open(struct inode *inode, struct file *filep)
static long kfd_ioctl_get_version(struct file *filep, struct kfd_process *p,
void __user *arg)
{
- return -ENODEV;
+ struct kfd_ioctl_get_version_args args;
+ int err = 0;
+
+ args.major_version = KFD_IOCTL_MAJOR_VERSION;
+ args.minor_version = KFD_IOCTL_MINOR_VERSION;
+
+ if (copy_to_user(arg, &args, sizeof(args)))
+ err = -EFAULT;
+
+ return err;
}
static int set_queue_properties_from_user(struct queue_properties *q_properties,