[<prev] [next>] [day] [month] [year] [list]
Message-Id: <1446218598-27982-1-git-send-email-brutallesale@gmail.com>
Date: Fri, 30 Oct 2015 16:23:18 +0100
From: Bogicevic Sasa <brutallesale@...il.com>
To: gregkh@...uxfoundation.org
Cc: linux-kernel@...r.kernel.org, devel@...verdev.osuosl.org,
Bogicevic Sasa <brutallesale@...il.com>
Subject: [PATCH] drivers:staging:gdm724x Fix Prefer kmalloc(sizeof(*gdm)...)
This fixes Prefer kmalloc(sizeof(*gdm)...) over
kmalloc(sizeof(struct gdm)...) message from checkpatch.pl
Signed-off-by: Bogicevic Sasa <brutallesale@...il.com>
---
drivers/staging/gdm724x/gdm_tty.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/staging/gdm724x/gdm_tty.c b/drivers/staging/gdm724x/gdm_tty.c
index 85206ef..d600728 100644
--- a/drivers/staging/gdm724x/gdm_tty.c
+++ b/drivers/staging/gdm724x/gdm_tty.c
@@ -225,7 +225,7 @@ int register_lte_tty_device(struct tty_dev *tty_dev, struct device *device)
int j;
for (i = 0; i < TTY_MAX_COUNT; i++) {
- gdm = kmalloc(sizeof(struct gdm), GFP_KERNEL);
+ gdm = kmalloc(sizeof(*gdm), GFP_KERNEL);
if (!gdm)
return -ENOMEM;
--
2.1.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists