mirror of
git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2025-09-18 22:14:16 +00:00
Merge branch 'for-5.18/google' into for-linus
This commit is contained in:
commit
e0464ad246
1 changed files with 1 additions and 1 deletions
|
|
@ -58,7 +58,7 @@ static int cbas_ec_query_base(struct cros_ec_device *ec_dev, bool get_state,
|
|||
struct cros_ec_command *msg;
|
||||
int ret;
|
||||
|
||||
msg = kzalloc(sizeof(*msg) + max(sizeof(u32), sizeof(*params)),
|
||||
msg = kzalloc(struct_size(msg, data, max(sizeof(u32), sizeof(*params))),
|
||||
GFP_KERNEL);
|
||||
if (!msg)
|
||||
return -ENOMEM;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue