linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dan Williams <dcbw@redhat.com>
To: Holger Schurig <holgerschurig@gmail.com>
Cc: linux-wireless@vger.kernel.org, Samuel Ortiz <sameo@linux.intel.com>
Subject: Re: [PATCH] libertas: cfg80211 support
Date: Thu, 04 Feb 2010 13:49:49 -0800	[thread overview]
Message-ID: <1265320189.4290.6.camel@localhost.localdomain> (raw)
In-Reply-To: <201002040828.14406.holgerschurig@gmail.com>

On Thu, 2010-02-04 at 08:28 +0100, Holger Schurig wrote:
> > > I had an application running that was pinging and showed the
> > > signal level. Then I moved out-of-reach of the AP.
> > > This happened:
> > 
> > The command timeout code is just screwed all around.  We've
> > already seen that some commands just take longer than we're
> > expecting them to.  I think we should just get rid of the
> > command retry stuff completely and return EBUSY when trying to
> > submit additional commands if the firmware hasn't replied yet.
> 
> I think the same.
> 
> I think in my case --- which I haven't debugged completely 
> yet  --- user-space code was going wild. The firmware command 
> 001f (get RSSI) failed. Which is to be expected, because the 
> firmware noticed that there's no longer a connection to an AP.
> 
> However, user-space nl80211 code seems to have been buggy and 
> issued the same command in a loop. This flooded the the 
> command-execution logic in libertas, and it couldn't cope with 
> it.
> 
> AFAIK the error I had had nothing to do with the cfg80211-code 
> inside the libertas driver. Or maybe it is, I'll write a little 
> program that floods libertas via cfg80211 with commands in a 
> tight loop, let's see what happens. :-)
> 
> 
> Getting rid of the command-retry and returning an error instead 
> seems to be a sane thing.
> 
> > I don't think I've *ever* seen recovery from this situation
> > unless the firmware finally sends the command reply back, which
> > has happened in some cases with SD8686.  IMHO the command retry
> > stuff causes more problems than it's worth, given that it never
> > actually fixes anything or recovers from the timeout.
> > 
> > If the firmware is hung, the only way to get the device back is
> > to power-cycle it or possibly do a USB reset.  Retrying a
> > command just doesn't work.
> 
> In my case, I could do a "pccardctl eject" / "pccardctl insert" 
> sequence :-)   Not nice. Maybe we need a signal from 
> core-libertas to the libertas-drivers, so that they decide what 
> to do.

There should be some reset logic in there for each bus type; it was only
ever hooked up for USB because it's easy to do a USB reset.  SDIO and
SPI are somewhat harder because often it's board-specific thing.  Not
sure what to do there; we did try writing various SDIO registers that
were supposed to reset the card but that never worked.

Dan



  reply	other threads:[~2010-02-04 21:49 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-02-02  0:09 [PATCH] libertas: cfg80211 support Samuel Ortiz
2010-02-02 20:36 ` John W. Linville
2010-02-03  9:31   ` Holger Schurig
2010-02-03 12:04     ` Samuel Ortiz
2010-02-03 15:32       ` Holger Schurig
2010-02-03 20:30         ` Dan Williams
2010-02-04  7:28           ` Holger Schurig
2010-02-04 21:49             ` Dan Williams [this message]
2010-02-04  9:52 ` Holger Schurig
2010-02-11 12:01   ` Samuel Ortiz
2010-02-11 12:24     ` Holger Schurig
2010-02-04 10:11 ` Holger Schurig
2010-02-11 12:03   ` Samuel Ortiz
2010-02-04 13:44 ` [PATCH] libertas+cfg80211: better disconnect support Holger Schurig
2010-02-15 10:46 ` [PATCH] libertas: cfg80211 support Holger Schurig
     [not found]   ` <cdd918981002240005o1fa50956yfb2a692716c06a55@mail.gmail.com>
2010-02-24 23:35     ` Dan Williams
2010-02-25  8:42       ` David MOUSSAUD
2010-02-25  8:48         ` Johannes Berg
2010-02-25 18:05           ` Andrey Yurovsky
2010-03-07 17:32             ` Kalle Valo
2010-03-07 17:52               ` Gábor Stefanik
2010-02-24  8:22 ` David MOUSSAUD

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=1265320189.4290.6.camel@localhost.localdomain \
    --to=dcbw@redhat.com \
    --cc=holgerschurig@gmail.com \
    --cc=linux-wireless@vger.kernel.org \
    --cc=sameo@linux.intel.com \
    /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).