]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
clk: clk-max77686: kzalloc + kcalloc to kzalloc
authorRosen Penev <rosenp@gmail.com>
Thu, 26 Mar 2026 05:28:47 +0000 (22:28 -0700)
committerStephen Boyd <sboyd@kernel.org>
Wed, 29 Apr 2026 01:44:39 +0000 (18:44 -0700)
commit4266035a40b6f27f82b5f85dd4e8e23f9a0644a2
tree1c9868cd127f71b8a6dee79759a0e2a0d7b8c442
parent4758f1354f00abf1d97d2f85a016123c78c1f548
clk: clk-max77686: kzalloc + kcalloc to kzalloc

Simplify allocation by using a flexible array member to combine
allocations. Use struct_size to calculate size properly.

Use __counted_by to get extra runtime analysis. Assign counting variable
right after allocation as required by __counted_by.

Signed-off-by: Rosen Penev <rosenp@gmail.com>
Reviewed-by: Brian Masney <bmasney@redhat.com>
Signed-off-by: Stephen Boyd <sboyd@kernel.org>
drivers/clk/clk-max77686.c