aboutsummaryrefslogtreecommitdiff
path: root/net/openvswitch
diff options
context:
space:
mode:
authorGravatar Justin Stitt <justinstitt@google.com> 2023-08-15 20:35:59 +0000
committerGravatar Jakub Kicinski <kuba@kernel.org> 2023-08-17 19:25:40 -0700
commitf3add6dec36d9d747929918ba1d7ce8866e1c054 (patch)
treefe291d4ea3a4d58e2378d46942cad4e0cc2b029c /net/openvswitch
parentMerge branch 'netem-use-a-seeded-prng-for-loss-and-corruption-events' (diff)
downloadlinux-f3add6dec36d9d747929918ba1d7ce8866e1c054.tar.gz
linux-f3add6dec36d9d747929918ba1d7ce8866e1c054.tar.bz2
linux-f3add6dec36d9d747929918ba1d7ce8866e1c054.zip
net: mdio: fix -Wvoid-pointer-to-enum-cast warning
When building with clang 18 I see the following warning: | drivers/net/mdio/mdio-xgene.c:338:13: warning: cast to smaller integer | type 'enum xgene_mdio_id' from 'const void *' [-Wvoid-pointer-to-enum-cast] | 338 | mdio_id = (enum xgene_mdio_id)of_id->data; This is due to the fact that `of_id->data` is a void* while `enum xgene_mdio_id` has the size of an int. This leads to truncation and possible data loss. Link: https://github.com/ClangBuiltLinux/linux/issues/1910 Reported-by: Nathan Chancellor <nathan@kernel.org> Signed-off-by: Justin Stitt <justinstitt@google.com> Reviewed-by: Andrew Lunn <andrew@lunn.ch> Reviewed-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk> Link: https://lore.kernel.org/r/20230815-void-drivers-net-mdio-mdio-xgene-v1-1-5304342e0659@google.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/openvswitch')
0 files changed, 0 insertions, 0 deletions