* [PATCH iw] iw: fix enum warnings
@ 2018-10-08 17:51 Brian Norris
2018-10-09 7:58 ` Johannes Berg
0 siblings, 1 reply; 2+ messages in thread
From: Brian Norris @ 2018-10-08 17:51 UTC (permalink / raw)
To: Johannes Berg; +Cc: linux-wireless, Brian Norris
clang warns about the misuse of enums:
reg.c:246:26: warning: implicit conversion from enumeration type 'enum command_identify_by' to different enumeration type 'enum id_input' [-Wenum-conversion]
err = handle_cmd(state, CIB_NONE, 2, dump_args);
~~~~~~~~~~ ^~~~~~~~
info.c:645:26: warning: implicit conversion from enumeration type 'enum command_identify_by' to different enumeration type 'enum id_input' [-Wenum-conversion]
err = handle_cmd(state, CIB_NONE, 2, feat_args);
~~~~~~~~~~ ^~~~~~~~
Signed-off-by: Brian Norris <briannorris@chromium.org>
---
info.c | 2 +-
reg.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/info.c b/info.c
index fbf3ee095f9c..d0577e32552e 100644
--- a/info.c
+++ b/info.c
@@ -718,7 +718,7 @@ static int handle_info(struct nl80211_state *state,
char *feat_args[] = { "features", "-q" };
int err;
- err = handle_cmd(state, CIB_NONE, 2, feat_args);
+ err = handle_cmd(state, II_NONE, 2, feat_args);
if (!err && nl80211_has_split_wiphy) {
nla_put_flag(msg, NL80211_ATTR_SPLIT_WIPHY_DUMP);
nlmsg_hdr(msg)->nlmsg_flags |= NLM_F_DUMP;
diff --git a/reg.c b/reg.c
index cadff3884c04..a2368df39009 100644
--- a/reg.c
+++ b/reg.c
@@ -243,7 +243,7 @@ static int handle_reg_get(struct nl80211_state *state,
char *dump_args[] = { "reg", "dump" };
int err;
- err = handle_cmd(state, CIB_NONE, 2, dump_args);
+ err = handle_cmd(state, II_NONE, 2, dump_args);
/*
* dump might fail since it's not supported on older kernels,
* in that case the handler is still registered already
--
2.19.0.605.g01d371f741-goog
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH iw] iw: fix enum warnings
2018-10-08 17:51 [PATCH iw] iw: fix enum warnings Brian Norris
@ 2018-10-09 7:58 ` Johannes Berg
0 siblings, 0 replies; 2+ messages in thread
From: Johannes Berg @ 2018-10-09 7:58 UTC (permalink / raw)
To: Brian Norris; +Cc: linux-wireless
On Mon, 2018-10-08 at 10:51 -0700, Brian Norris wrote:
> clang warns about the misuse of enums:
>
> reg.c:246:26: warning: implicit conversion from enumeration type 'enum command_identify_by' to different enumeration type 'enum id_input' [-Wenum-conversion]
> err = handle_cmd(state, CIB_NONE, 2, dump_args);
> ~~~~~~~~~~ ^~~~~~~~
> info.c:645:26: warning: implicit conversion from enumeration type 'enum command_identify_by' to different enumeration type 'enum id_input' [-Wenum-conversion]
> err = handle_cmd(state, CIB_NONE, 2, feat_args);
> ~~~~~~~~~~ ^~~~~~~~
Applied, thanks.
johannes
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-10-09 7:58 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-08 17:51 [PATCH iw] iw: fix enum warnings Brian Norris
2018-10-09 7:58 ` Johannes Berg
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.