linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Williams <dcbw@redhat.com>
To: Johannes Berg <johannes@sipsolutions.net>
Cc: Arend van Spriel <arend@broadcom.com>,
	Adrian Chadd <adrian@freebsd.org>,
	Felix Fietkau <nbd@openwrt.org>,
	linux-wireless@vger.kernel.org,
	Ben Greear <greearb@candelatech.com>
Subject: Re: [RFC V2] cfg80211: introduce critical protocol indication from user-space
Date: Thu, 28 Mar 2013 17:42:57 -0500	[thread overview]
Message-ID: <1364510577.3226.7.camel@dcbw.foobar.com> (raw)
In-Reply-To: <1364506118.10397.29.camel@jlt4.sipsolutions.net>

On Thu, 2013-03-28 at 22:28 +0100, Johannes Berg wrote:
> On Thu, 2013-03-28 at 22:16 +0100, Arend van Spriel wrote:
> > > That seems pretty long? Why have such a long *minimum* duration? At 2.5
> > > seconds, it's way long, and then disabling most of the
> > > protections/powersave/whatever no longer makes sense for this period of
> > > time since really mostly what this does will be reducing the wifi
> > > latency.
> 
> > Ok, so what minimum do you (or someone else can chime in here) think a
> > DHCP exchange takes as that was considered a likely protocol that can
> > benefit from this API.
> 
> Well, you can do DHCP a second or so, I'd think? And EAPOL much quicker,
> of course. I don't really see any reasonable minimum time? We might want
> to enforce a max though, maybe.

Not quite.  A lot is dependent on the server itself, and I've had users
on university and corporate networks report it sometimes takes 30 to 60
seconds for the whole DHCP transaction to complete (DISCOVER, REQUEST,
OFFER, ACK).  Sometimes there's a NAK in there if the server doesn't
like your lease, which means you need another round-trip.  So in many
cases, it's a couple round-trips and each of these packets may or may
not get lost in noisy environments.

"nicer" DHCP clients have larger-bounded random backoffs between request
packets to ensure they don't hammer the DHCP server or network if there
are a bunch of machines booting up at the same time.  That can often
make the transaction take longer than a few seconds if even one DISCOVER
or REQUEST packet gets lost due to noise.

So really at least 15 seconds is a more useful timeout for DHCP.

Dan

> > > Ah, a tricky problem -- unrelated to your patch. You probably saw the
> > > wiphy size limit problem. If we keep adding commands here, we'll
> > > eventually break older userspace completely, so I think we shouldn't. A
> > > new way will probably be required, either adding new commands only
> > > conditionally on split wiphy dump, or inventing a new way. I suppose
> > > making it conditional is acceptable for all new commands since new tools
> > > in userspace will be required anyway to make them work.
> > > 
> > 
> > Indeed noticed some emails on this. I simply added these lines without
> > looking what this code fragment does.
> 
> Probably best to just say
> 	if (split) {
> 		CMD(...)
> 	}
> 
> > Good point. Maybe keep track that crit_proto is started and reject a
> > subsequent call (-EBUSY). Ideally, the start and stop should be done by
> > the same user-space process/application. Is that possible?
> 
> Yes ... but you'd have to make sure you abort when the application dies
> I guess, with the socket closing notifier thing.
> 
> > > Ah, ok, I guess I misunderstood it. You do use it, but don't pass it to
> > > the driver since you let cfg80211 handle the timing...
> > 
> > Indeed. I wanted to be sure that the duration provided by user-space is
> > applicable independent from a driver implementation. Do you think it
> > makes sense to have this dealt with by cfg80211?
> 
> Not sure ... Like I said, I think if we'd implement it we'd like to put
> it into the firmware, so at least it'd have to be optional. And at that
> point I don't really see that much value in doing it in cfg80211, it's
> pretty simple after all.
> 
> johannes
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html



  reply	other threads:[~2013-03-28 22:42 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-28 12:11 [RFC V2] cfg80211: introduce critical protocol indication from user-space Arend van Spriel
2013-03-28 16:17 ` Johannes Berg
2013-03-28 16:30   ` Ben Greear
2013-03-28 21:16   ` Arend van Spriel
2013-03-28 21:28     ` Johannes Berg
2013-03-28 22:42       ` Dan Williams [this message]
2013-03-28 22:44         ` Johannes Berg
2013-03-28 23:01           ` Dan Williams
2013-03-28 23:30             ` Ben Greear
2013-03-29 13:42               ` Arend van Spriel
2013-04-01 14:52               ` Dan Williams
2013-03-29 11:38           ` Arend van Spriel
2013-03-28 22:51         ` Ben Greear
2013-03-28 22:58           ` Dan Williams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1364510577.3226.7.camel@dcbw.foobar.com \
    --to=dcbw@redhat.com \
    --cc=adrian@freebsd.org \
    --cc=arend@broadcom.com \
    --cc=greearb@candelatech.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-wireless@vger.kernel.org \
    --cc=nbd@openwrt.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).