diff options
author | Trung Thanh Le <trungthanh1608@yahoo.com> | 2015-08-15 14:09:45 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2015-09-13 01:24:27 (GMT) |
commit | b8797affa142840e7c62deccb750813563fc8097 (patch) | |
tree | 2f19bc894cf75e61b8ea9347c4e56d664422effd /drivers/staging/android/sw_sync.c | |
parent | 7048c1fc37f71f860b5042fbe021c9f98218b122 (diff) | |
download | linux-b8797affa142840e7c62deccb750813563fc8097.tar.xz |
staging: android: fix coding style checks in sw_sync.c
replace comparison "obj" to NULL with "!obj"
Signed-off-by: Trung Thanh Le <trungthanh1608@yahoo.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/android/sw_sync.c')
-rw-r--r-- | drivers/staging/android/sw_sync.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/staging/android/sw_sync.c b/drivers/staging/android/sw_sync.c index c90838d..29b5c35 100644 --- a/drivers/staging/android/sw_sync.c +++ b/drivers/staging/android/sw_sync.c @@ -145,7 +145,7 @@ static int sw_sync_open(struct inode *inode, struct file *file) get_task_comm(task_comm, current); obj = sw_sync_timeline_create(task_comm); - if (obj == NULL) + if (!obj) return -ENOMEM; file->private_data = obj; @@ -179,14 +179,14 @@ static long sw_sync_ioctl_create_fence(struct sw_sync_timeline *obj, } pt = sw_sync_pt_create(obj, data.value); - if (pt == NULL) { + if (!pt) { err = -ENOMEM; goto err; } data.name[sizeof(data.name) - 1] = '\0'; fence = sync_fence_create(data.name, pt); - if (fence == NULL) { + if (!fence) { sync_pt_free(pt); err = -ENOMEM; goto err; |