linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [linux-wireless] [mac80211] Does IEEE80211_IBSS_MAX_STA_ENTRIES (in net/mac80211/ibss.c) work?
@ 2017-06-08  4:50 Xuebing Wang
  2017-06-09  8:59 ` Johannes Berg
  0 siblings, 1 reply; 2+ messages in thread
From: Xuebing Wang @ 2017-06-08  4:50 UTC (permalink / raw)
  To: linux-wireless; +Cc: Johannes Berg

Hi community,

Does IEEE80211_IBSS_MAX_STA_ENTRIES (in net/mac80211/ibss.c) work?

I hard-code it to be 2 (from original 128), and update kernel for one 
node, and start IBSS network with 5 nodes. In the node with hard-coded 
IBSS_MAX_STA_ENTRIES = 2, I still can see and ping all other 4 nodes. I 
am using kernel v3.18.29, does IBSS_MAX_STA_ENTRIES work with latest 
kernel source code?

My purpose is to limit the max number of peers (for all nodes in IBSS 
network) to be 12 or 20.

I apologize if I should dive deeper instead of posting this question. I 
will check here too, just to see if I can get any quick answers. :-)

Thanks a lot.

Xuebing Wang

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [linux-wireless] [mac80211] Does IEEE80211_IBSS_MAX_STA_ENTRIES (in net/mac80211/ibss.c) work?
  2017-06-08  4:50 [linux-wireless] [mac80211] Does IEEE80211_IBSS_MAX_STA_ENTRIES (in net/mac80211/ibss.c) work? Xuebing Wang
@ 2017-06-09  8:59 ` Johannes Berg
  0 siblings, 0 replies; 2+ messages in thread
From: Johannes Berg @ 2017-06-09  8:59 UTC (permalink / raw)
  To: Xuebing Wang, linux-wireless

On Thu, 2017-06-08 at 12:50 +0800, Xuebing Wang wrote:
> Hi community,
> 
> Does IEEE80211_IBSS_MAX_STA_ENTRIES (in net/mac80211/ibss.c) work?

Yes, as far as it's supposed to :)

> I hard-code it to be 2 (from original 128), and update kernel for
> one node, and start IBSS network with 5 nodes. In the node with hard-
> coded IBSS_MAX_STA_ENTRIES = 2, I still can see and ping all other 4
> nodes. I am using kernel v3.18.29, does IBSS_MAX_STA_ENTRIES work
> with latest kernel source code?
> 
> My purpose is to limit the max number of peers (for all nodes in
> IBSS network) to be 12 or 20.

This isn't really the point of this setting, and that's why it's also
not configurable.

This setting is really just intended to catch the case of a rogue
network/transmitter or similar overflowing the amount of memory we
keep.

This setting has no impact on who we can *communicate* with - although
we can only communicate with peers that we don't have a station entry
for on very few low rates, so you won't get good performance beyond
that point.

If you wanted to actually limit the IBSS network to a certain number of
peers, you'd have to

 * make that setting configurable (with a sane upper bound)
 * write some additional code to restrict IBSS communication to when a
   station entry exists

You could also do some higher layer filtering (iptables) I guess.

johannes

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-06-09  8:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-06-08  4:50 [linux-wireless] [mac80211] Does IEEE80211_IBSS_MAX_STA_ENTRIES (in net/mac80211/ibss.c) work? Xuebing Wang
2017-06-09  8:59 ` Johannes Berg

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).