* [PATCH net-next] nexthop: Fix type of event_type in call_nexthop_notifiers
@ 2020-05-27 8:00 Nathan Chancellor
2020-05-27 13:50 ` David Ahern
2020-05-27 18:22 ` David Miller
0 siblings, 2 replies; 3+ messages in thread
From: Nathan Chancellor @ 2020-05-27 8:00 UTC (permalink / raw)
To: David Ahern, David S. Miller, Alexey Kuznetsov,
Hideaki YOSHIFUJI, Jakub Kicinski
Cc: Roopa Prabhu, netdev, linux-kernel, clang-built-linux, Nathan Chancellor
Clang warns:
net/ipv4/nexthop.c:841:30: warning: implicit conversion from enumeration
type 'enum nexthop_event_type' to different enumeration type 'enum
fib_event_type' [-Wenum-conversion]
call_nexthop_notifiers(net, NEXTHOP_EVENT_DEL, nh);
~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~
1 warning generated.
Use the right type for event_type so that clang does not warn.
Fixes: 8590ceedb701 ("nexthop: add support for notifiers")
Link: https://github.com/ClangBuiltLinux/linux/issues/1038
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
---
net/ipv4/nexthop.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/net/ipv4/nexthop.c b/net/ipv4/nexthop.c
index 143011f9b580..ec1282858cb7 100644
--- a/net/ipv4/nexthop.c
+++ b/net/ipv4/nexthop.c
@@ -37,7 +37,7 @@ static const struct nla_policy rtm_nh_policy[NHA_MAX + 1] = {
};
static int call_nexthop_notifiers(struct net *net,
- enum fib_event_type event_type,
+ enum nexthop_event_type event_type,
struct nexthop *nh)
{
int err;
base-commit: dc0f3ed1973f101508957b59e529e03da1349e09
--
2.27.0.rc0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] nexthop: Fix type of event_type in call_nexthop_notifiers
2020-05-27 8:00 [PATCH net-next] nexthop: Fix type of event_type in call_nexthop_notifiers Nathan Chancellor
@ 2020-05-27 13:50 ` David Ahern
2020-05-27 18:22 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Ahern @ 2020-05-27 13:50 UTC (permalink / raw)
To: Nathan Chancellor, David Ahern, David S. Miller,
Alexey Kuznetsov, Hideaki YOSHIFUJI, Jakub Kicinski
Cc: Roopa Prabhu, netdev, linux-kernel, clang-built-linux
On 5/27/20 2:00 AM, Nathan Chancellor wrote:
> Clang warns:
>
> net/ipv4/nexthop.c:841:30: warning: implicit conversion from enumeration
> type 'enum nexthop_event_type' to different enumeration type 'enum
> fib_event_type' [-Wenum-conversion]
> call_nexthop_notifiers(net, NEXTHOP_EVENT_DEL, nh);
> ~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~
> 1 warning generated.
>
> Use the right type for event_type so that clang does not warn.
>
> Fixes: 8590ceedb701 ("nexthop: add support for notifiers")
> Link: https://github.com/ClangBuiltLinux/linux/issues/1038
> Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
> ---
> net/ipv4/nexthop.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
Reviewed-by: David Ahern <dsahern@gmail.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH net-next] nexthop: Fix type of event_type in call_nexthop_notifiers
2020-05-27 8:00 [PATCH net-next] nexthop: Fix type of event_type in call_nexthop_notifiers Nathan Chancellor
2020-05-27 13:50 ` David Ahern
@ 2020-05-27 18:22 ` David Miller
1 sibling, 0 replies; 3+ messages in thread
From: David Miller @ 2020-05-27 18:22 UTC (permalink / raw)
To: natechancellor
Cc: dsahern, kuznet, yoshfuji, kuba, roopa, netdev, linux-kernel,
clang-built-linux
From: Nathan Chancellor <natechancellor@gmail.com>
Date: Wed, 27 May 2020 01:00:20 -0700
> Clang warns:
>
> net/ipv4/nexthop.c:841:30: warning: implicit conversion from enumeration
> type 'enum nexthop_event_type' to different enumeration type 'enum
> fib_event_type' [-Wenum-conversion]
> call_nexthop_notifiers(net, NEXTHOP_EVENT_DEL, nh);
> ~~~~~~~~~~~~~~~~~~~~~~ ^~~~~~~~~~~~~~~~~
> 1 warning generated.
>
> Use the right type for event_type so that clang does not warn.
>
> Fixes: 8590ceedb701 ("nexthop: add support for notifiers")
> Link: https://github.com/ClangBuiltLinux/linux/issues/1038
> Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Applied, thanks.
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-05-27 18:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-05-27 8:00 [PATCH net-next] nexthop: Fix type of event_type in call_nexthop_notifiers Nathan Chancellor
2020-05-27 13:50 ` David Ahern
2020-05-27 18:22 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).