summaryrefslogtreecommitdiff
path: root/drivers/media/platform/davinci
diff options
context:
space:
mode:
authorMarkus Elfring <elfring@users.sourceforge.net>2016-10-12 05:44:05 -0300
committerMauro Carvalho Chehab <mchehab@s-opensource.com>2016-11-16 12:44:17 -0200
commit1d3811d35c0fc8d8c6cb3d8e666261ca84687b03 (patch)
tree676e3ed44ab2b82403fcd46f4098d451e4b86a8c /drivers/media/platform/davinci
parentefb74461f5a66c0004d0c13ef59c86bcf5961477 (diff)
[media] DaVinci-VPFE-Capture: Improve another size determination in vpfe_open()
Replace the specification of a data structure by a pointer dereference as the parameter for the operator "sizeof" to make the corresponding size determination a bit safer. Signed-off-by: Markus Elfring <elfring@users.sourceforge.net> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
Diffstat (limited to 'drivers/media/platform/davinci')
-rw-r--r--drivers/media/platform/davinci/vpfe_capture.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/media/platform/davinci/vpfe_capture.c b/drivers/media/platform/davinci/vpfe_capture.c
index cee14aa95061..ab073f273b95 100644
--- a/drivers/media/platform/davinci/vpfe_capture.c
+++ b/drivers/media/platform/davinci/vpfe_capture.c
@@ -511,7 +511,7 @@ static int vpfe_open(struct file *file)
}
/* Allocate memory for the file handle object */
- fh = kmalloc(sizeof(struct vpfe_fh), GFP_KERNEL);
+ fh = kmalloc(sizeof(*fh), GFP_KERNEL);
if (!fh)
return -ENOMEM;