Search Linux Wireless

[PATCH] nl80211: Reset split_start on error path when split dump is not used

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When the netlink skb is exhausted split_start is left set. In the
subsequent retry, with a larger buffer, the dump is continued from the
failing point instead of from the beginning.

This was causing my rt28xx based USB dongle to now show up when
running "iw list" with an old iw version without split dump support.

Signed-off-by: Pontus Fuchs <pontus.fuchs@xxxxxxxxx>
---
 net/wireless/nl80211.c | 2 ++
 1 file changed, 2 insertions(+)

Supersedes "nl80211: Don't touch split_start when split dump is not used"

diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
index d0afd82..ba6d438 100644
--- a/net/wireless/nl80211.c
+++ b/net/wireless/nl80211.c
@@ -1631,6 +1631,8 @@ static int nl80211_send_wiphy(struct cfg80211_registered_device *dev,
 	return genlmsg_end(msg, hdr);
 
  nla_put_failure:
+	if (!state->split)
+		state->split_start = 0;
 	genlmsg_cancel(msg, hdr);
 	return -EMSGSIZE;
 }
-- 
1.8.3.2

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux