Skip to content

Commit

Permalink
gpu: host1x: returning success instead of -ENOMEM
Browse files Browse the repository at this point in the history
There is a mistake here so it returns PTR_ERR(NULL) which is success
instead of -ENOMEM.

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
  • Loading branch information
Dan Carpenter authored and Thierry Reding committed Aug 27, 2013
1 parent f5fda67 commit 745cecc
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions drivers/gpu/host1x/job.c
Original file line number Diff line number Diff line change
Expand Up @@ -466,9 +466,8 @@ static inline int copy_gathers(struct host1x_job *job, struct device *dev)
&job->gather_copy,
GFP_KERNEL);
if (!job->gather_copy_mapped) {
int err = PTR_ERR(job->gather_copy_mapped);
job->gather_copy_mapped = NULL;
return err;
return -ENOMEM;
}

job->gather_copy_size = size;
Expand Down

0 comments on commit 745cecc

Please sign in to comment.