Volodymyr Mytnyk 48c77bdf72 net: prestera: acl: fix 'client_map' buff overflow
smatch warnings:
drivers/net/ethernet/marvell/prestera/prestera_acl.c:103
prestera_acl_chain_to_client() error: buffer overflow
'client_map' 3 <= 3

	prestera_acl_chain_to_client(u32 chain_index, ...)
        ...
	u32 client_map[] = {
		PRESTERA_HW_COUNTER_CLIENT_LOOKUP_0,
		PRESTERA_HW_COUNTER_CLIENT_LOOKUP_1,
		PRESTERA_HW_COUNTER_CLIENT_LOOKUP_2
	};
	if (chain_index > ARRAY_SIZE(client_map))
	...

Fixes: fa5d824ce5dd ("net: prestera: acl: add multi-chain support offload")
Reported-by: kernel test robot <lkp@intel.com>
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Volodymyr Mytnyk <vmytnyk@marvell.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2022-02-19 18:56:50 +00:00
..
2022-02-11 11:55:26 -08:00
2022-02-07 17:42:44 +01:00
2022-01-18 14:03:34 +02:00
2022-01-30 01:06:35 +01:00
2021-12-09 20:06:54 -08:00
2022-02-12 10:16:32 -08:00
2022-02-01 16:52:54 +01:00
2022-01-23 06:20:44 +02:00
2022-01-11 11:35:28 -08:00
2022-01-12 11:11:34 -08:00
2022-01-27 13:53:26 +00:00
2022-01-22 08:33:37 +02:00
2022-01-22 09:52:17 +02:00
2022-02-15 09:05:01 -08:00
2022-01-16 08:08:11 +02:00
2022-02-02 10:33:04 +05:30
2022-01-22 08:33:37 +02:00
2022-01-11 11:26:57 -08:00
2022-02-08 21:04:32 -08:00
2022-01-20 13:25:01 +02:00
2022-01-27 11:23:26 +02:00
2022-02-01 12:39:37 -08:00
2022-02-08 09:48:44 +01:00
2021-12-29 10:54:50 +01:00
2022-01-20 13:31:46 +02:00
2022-01-23 06:20:44 +02:00
2022-01-17 08:07:57 +02:00
2022-01-22 08:33:37 +02:00
2021-12-08 14:53:15 -05:00