diff options
author | Gustavo A. R. Silva <garsilva@embeddedor.com> | 2017-07-09 00:45:59 -0500 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2017-07-16 08:40:57 +0200 |
commit | 4a73bb48ded88adfc7180cb5a00a0b89dd41c7fb (patch) | |
tree | d0a8fff795b8f50035bc1a069a87c6297b08de18 /drivers | |
parent | 60ba7c7c26b8df3688a952cf4bcfbc8dcdafdb9b (diff) |
staging: ccree: use sizeof(*var) in kmalloc
Fix the following checkpatch warning:
CHECK: Prefer kmalloc(sizeof(*buff_mgr_handle)...)
over kmalloc(sizeof(struct buff_mgr_handle)...)
Signed-off-by: Gustavo A. R. Silva <garsilva@embeddedor.com>
Acked-by: Gilad Ben-Yossef <gilad@benyossef.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/ccree/ssi_buffer_mgr.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/ccree/ssi_buffer_mgr.c b/drivers/staging/ccree/ssi_buffer_mgr.c index 18a86942134c..9caff9b096db 100644 --- a/drivers/staging/ccree/ssi_buffer_mgr.c +++ b/drivers/staging/ccree/ssi_buffer_mgr.c @@ -1725,7 +1725,7 @@ int ssi_buffer_mgr_init(struct ssi_drvdata *drvdata) struct buff_mgr_handle *buff_mgr_handle; struct device *dev = &drvdata->plat_dev->dev; - buff_mgr_handle = kmalloc(sizeof(struct buff_mgr_handle), GFP_KERNEL); + buff_mgr_handle = kmalloc(sizeof(*buff_mgr_handle), GFP_KERNEL); if (!buff_mgr_handle) return -ENOMEM; |