projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next
[linux-2.6-microblaze.git]
/
drivers
/
net
/
ethernet
/
mellanox
/
mlx5
/
core
/
fs_core.c
diff --git
a/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c
b/drivers/net/ethernet/mellanox/mlx5/core/fs_core.c
index
f9c2c03
..
e1b609c
100644
(file)
--- a/
drivers/net/ethernet/mellanox/mlx5/core/fs_core.c
+++ b/
drivers/net/ethernet/mellanox/mlx5/core/fs_core.c
@@
-1191,8
+1191,7
@@
static struct mlx5_flow_handle *alloc_handle(int num_rules)
{
struct mlx5_flow_handle *handle;
- handle = kzalloc(sizeof(*handle) + sizeof(handle->rule[0]) *
- num_rules, GFP_KERNEL);
+ handle = kzalloc(struct_size(handle, rule, num_rules), GFP_KERNEL);
if (!handle)
return NULL;