lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Sat, 20 Nov 2021 10:45:02 +0100 (CET)
From:   Julia Lawall <julia.lawall@...ia.fr>
To:     Sidraya <sidraya.bj@...hpartnertech.com>,
        Praneeth Bajjuri <praneeth@...com>,
        Angela Stegmaier <angelabaker@...com>
cc:     linux-kernel@...r.kernel.org, kbuild-all@...ts.01.org
Subject: [PATCH] media: platform: vxd: Kconfig: fix noderef.cocci warnings

From: kernel test robot <lkp@...el.com>

sizeof when applied to a pointer typed expression gives the size of
the pointer

Generated by: scripts/coccinelle/misc/noderef.cocci

CC: Sidraya <sidraya.bj@...hpartnertech.com>
Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: kernel test robot <lkp@...el.com>
Signed-off-by: Julia Lawall <julia.lawall@...ia.fr>
---

tree:   git://git.ti.com/ti-linux-kernel/ti-linux-kernel.git ti-rt-linux-5.10.y
head:   0c67d996db8f3c9149598bc98657ae28fee22208
commit: 97dfdd999ba7266785579c99c40a3c65e63e864a [10173/10206] media: platform: vxd: Kconfig: Add Video decoder Kconfig and Makefile
:::::: branch date: 2 days ago
:::::: commit date: 9 days ago

 work_queue.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

--- a/drivers/media/platform/vxe-vxd/common/work_queue.c
+++ b/drivers/media/platform/vxe-vxd/common/work_queue.c
@@ -39,7 +39,7 @@ void init_work(void **work_args, void *w
 	//create a link
 	struct node *link = kmalloc(sizeof(*link), GFP_KERNEL);

-	*work = kzalloc(sizeof(*work), GFP_KERNEL);
+	*work = kzalloc(sizeof(**work), GFP_KERNEL);
 	if (!(*work)) {
 		pr_err("Memory allocation failed for work_queue\n");
 		return;
@@ -62,7 +62,7 @@ void init_delayed_work(void **work_args,
 	//create a link
 	struct node *link = kmalloc(sizeof(*link), GFP_KERNEL);

-	*work = kzalloc(sizeof(*work), GFP_KERNEL);
+	*work = kzalloc(sizeof(**work), GFP_KERNEL);
 	if (!(*work)) {
 		pr_err("Memory allocation failed for delayed_work_queue\n");
 		return;

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ