| From 36ae721be616c02fd15b4f5c223fd1a1a3adb1ce Mon Sep 17 00:00:00 2001 |
| From: Julan Hsu <julanhsu@google.com> |
| Date: Tue, 15 Jan 2019 15:28:42 -0800 |
| Subject: [PATCH] FROMGIT: nl80211/mac80211: mesh: add hop count to mpath info |
| |
| Expose hop count to destination information in mpath info |
| |
| Signed-off-by: Julan Hsu <julanhsu@google.com> |
| Signed-off-by: Johannes Berg <johannes.berg@intel.com> |
| |
| (cherry-picked from commit cc24163690997c685641d84e77ff6f1c592b06fe |
| git://git.kernel.org/pub/scm/linux/kernel/git/jberg/mac80211-next.git) |
| |
| BUG=b:117941534 |
| TEST=use mpath dump to verify hop count is populated |
| |
| Change-Id: I73a98f05dc24fba124e07bb0c5ec8ad314bf82d0 |
| Reviewed-on: https://chromium-review.googlesource.com/1450133 |
| Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> |
| Tested-by: Julan Hsu <julanhsu@google.com> |
| Reviewed-by: Brian Norris <briannorris@chromium.org> |
| --- |
| include/net/cfg80211.h | 4 ++++ |
| 1 file changed, 4 insertions(+) |
| |
| diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h |
| index ea0ed58db97e..330d6678b29a 100644 |
| --- a/include/net/cfg80211.h |
| +++ b/include/net/cfg80211.h |
| @@ -1252,6 +1252,7 @@ enum monitor_flags { |
| * @MPATH_INFO_DISCOVERY_TIMEOUT: @discovery_timeout filled |
| * @MPATH_INFO_DISCOVERY_RETRIES: @discovery_retries filled |
| * @MPATH_INFO_FLAGS: @flags filled |
| + * @MPATH_INFO_HOP_COUNT: @hop_count filled |
| */ |
| enum mpath_info_flags { |
| MPATH_INFO_FRAME_QLEN = BIT(0), |
| @@ -1261,6 +1262,7 @@ enum mpath_info_flags { |
| MPATH_INFO_DISCOVERY_TIMEOUT = BIT(4), |
| MPATH_INFO_DISCOVERY_RETRIES = BIT(5), |
| MPATH_INFO_FLAGS = BIT(6), |
| + MPATH_INFO_HOP_COUNT = BIT(7) |
| }; |
| |
| /** |
| @@ -1280,6 +1282,7 @@ enum mpath_info_flags { |
| * This number should increase every time the list of mesh paths |
| * changes, i.e. when a station is added or removed, so that |
| * userspace can tell whether it got a consistent snapshot. |
| + * @hop_count: hops to destination |
| */ |
| struct mpath_info { |
| u32 filled; |
| @@ -1290,6 +1293,7 @@ struct mpath_info { |
| u32 discovery_timeout; |
| u8 discovery_retries; |
| u8 flags; |
| + u8 hop_count; |
| |
| int generation; |
| }; |
| -- |
| 2.21.0.360.g471c308f928-goog |
| |