Loading drivers/gpu/msm/kgsl.c +14 −2 Original line number Diff line number Diff line /* Copyright (c) 2008-2016, The Linux Foundation. All rights reserved. /* Copyright (c) 2008-2017, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -209,8 +209,11 @@ kgsl_mem_entry_create(void) { struct kgsl_mem_entry *entry = kzalloc(sizeof(*entry), GFP_KERNEL); if (entry) if (entry) { kref_init(&entry->refcount); /* put this ref in the caller functions after init */ kref_get(&entry->refcount); } return entry; } Loading Loading @@ -3259,6 +3262,9 @@ long kgsl_ioctl_map_user_mem(struct kgsl_device_private *dev_priv, trace_kgsl_mem_map(entry, param->fd); kgsl_mem_entry_commit_process(private, entry); /* put the extra refcount for kgsl_mem_entry_create() */ kgsl_mem_entry_put(entry); return result; error_attach: Loading Loading @@ -3603,6 +3609,9 @@ long kgsl_ioctl_gpumem_alloc(struct kgsl_device_private *dev_priv, param->flags = entry->memdesc.flags; kgsl_mem_entry_commit_process(private, entry); /* put the extra refcount for kgsl_mem_entry_create() */ kgsl_mem_entry_put(entry); return result; err: kgsl_sharedmem_free(&entry->memdesc); Loading Loading @@ -3645,6 +3654,9 @@ long kgsl_ioctl_gpumem_alloc_id(struct kgsl_device_private *dev_priv, param->gpuaddr = entry->memdesc.gpuaddr; kgsl_mem_entry_commit_process(private, entry); /* put the extra refcount for kgsl_mem_entry_create() */ kgsl_mem_entry_put(entry); return result; err: if (entry) Loading Loading
drivers/gpu/msm/kgsl.c +14 −2 Original line number Diff line number Diff line /* Copyright (c) 2008-2016, The Linux Foundation. All rights reserved. /* Copyright (c) 2008-2017, The Linux Foundation. All rights reserved. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 and Loading Loading @@ -209,8 +209,11 @@ kgsl_mem_entry_create(void) { struct kgsl_mem_entry *entry = kzalloc(sizeof(*entry), GFP_KERNEL); if (entry) if (entry) { kref_init(&entry->refcount); /* put this ref in the caller functions after init */ kref_get(&entry->refcount); } return entry; } Loading Loading @@ -3259,6 +3262,9 @@ long kgsl_ioctl_map_user_mem(struct kgsl_device_private *dev_priv, trace_kgsl_mem_map(entry, param->fd); kgsl_mem_entry_commit_process(private, entry); /* put the extra refcount for kgsl_mem_entry_create() */ kgsl_mem_entry_put(entry); return result; error_attach: Loading Loading @@ -3603,6 +3609,9 @@ long kgsl_ioctl_gpumem_alloc(struct kgsl_device_private *dev_priv, param->flags = entry->memdesc.flags; kgsl_mem_entry_commit_process(private, entry); /* put the extra refcount for kgsl_mem_entry_create() */ kgsl_mem_entry_put(entry); return result; err: kgsl_sharedmem_free(&entry->memdesc); Loading Loading @@ -3645,6 +3654,9 @@ long kgsl_ioctl_gpumem_alloc_id(struct kgsl_device_private *dev_priv, param->gpuaddr = entry->memdesc.gpuaddr; kgsl_mem_entry_commit_process(private, entry); /* put the extra refcount for kgsl_mem_entry_create() */ kgsl_mem_entry_put(entry); return result; err: if (entry) Loading