[<prev] [next>] [day] [month] [year] [list]
Message-ID: <fc9c7000-19f7-33df-b645-e2664978521e@gmx.de>
Date: Sun, 27 Jun 2021 16:52:26 +0200
From: Armin Wolf <W_Armin@....de>
To: Joe Perches <joe@...ches.com>
Cc: Andy Whitcroft <apw@...onical.com>, linux-kernel@...r.kernel.org
Subject: [BUG] checkpatch ALLOC_SIZEOF_STRUCT ignoring devm_* functions
When checking a source file containing something like:
data = devm_kzalloc(&pdev->dev, sizeof(struct dell_smm_data), GFP_KERNEL);
checkpatch is not complaining.
But when doing the same without devres:
data = kzalloc(sizeof(struct dell_smm_data), GFP_KERNEL);
checkpatch complains "Prefer kzalloc(sizeof(*data)...) over
kzalloc(sizeof(struct dell_smm_data)...)".
I think checkpatch ignoring the devm_* function is not intended.
Powered by blists - more mailing lists