net: bridge: Use array_size() helper in copy_to_user()
authorGustavo A. R. Silva <gustavoars@kernel.org>
Tue, 28 Sep 2021 20:12:39 +0000 (15:12 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 29 Dec 2021 11:28:46 +0000 (12:28 +0100)
commit1c66ea39c6c44821b2a72d9b27bba7d3a839a984
tree4cbf59573a313ee8375fcaec6e910cee7d5d47ca
parentbe2473e5f377fb7fe471a5096f37a2d73a8367e6
net: bridge: Use array_size() helper in copy_to_user()

[ Upstream commit 865bfb2affa8eff5182b29aa90803a2df4409834 ]

Use array_size() helper instead of the open-coded version in
copy_to_user(). These sorts of multiplication factors need
to be wrapped in array_size().

Link: https://github.com/KSPP/linux/issues/160
Signed-off-by: Gustavo A. R. Silva <gustavoars@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
net/bridge/br_ioctl.c