From: Paul Fox <pgf@laptop.org>
To: Dan Williams <dcbw@redhat.com>
Cc: Dan Carpenter <error27@gmail.com>,
Mike Frysinger <vapier.adi@gmail.com>,
libertas-dev@lists.infradead.org,
kernel-janitors@vger.kernel.org, linux-wireless@vger.kernel.org,
"John W. Linville" <linville@tuxdriver.com>,
Ben Hutchings <ben@decadent.org.uk>
Subject: Re: [rfc patch] libertas: fix if_spi_prog_helper_firmware()
Date: Thu, 26 Aug 2010 18:52:13 +0000 [thread overview]
Message-ID: <6529.1282848733@foxharp.boston.ma.us> (raw)
In-Reply-To: <1282837725.3642.1.camel@dcbw.foobar.com> (sfid-20100826_114702_532051_0C06391A)
dan wrote:
> On Tue, 2010-08-24 at 14:07 +0200, Dan Carpenter wrote:
> > The indenting is not correct here. I don't have this hardware and I'm
> > just guessing as to what was intended. I think that if there is an
> > error we should return an error code, but if there isn't an error we
> > should return success directly without releasing the firmware.
> >
> > Signed-off-by: Dan Carpenter <error27@gmail.com>
>
> I've significantly changed firmware loading in wireless-testing which
> should hit the next merge window. It won't have this problem, and it
> does correctly release the firmware later on. It does preserve the
> existing behavior of releasing the firmware after load, instead of
> keeping it around for resume. If there are fixes I think they should be
> against wireless-testing actually since that's what's "next".
as part of the firmware and suspend/resume topic: on the XO 1.5
laptop, running 2.6.31, we see an apparent leak of the firmware on
every suspend/resume where the card is powered down. (our driver
keeps the wlan module powered acros s/r if there are wakeup events
configured, otherwise it powers down -- i can't remember if that change
has been upstreamed or not.) our trac ticket is here:
http://dev.laptop.org/ticket/9928
i got as far as deciding that the leak wasn't in the libertas driver
itself before we decided we had more important fish to fry, so our
investigation is/was incomplete. from what i found, it seemed like
perhaps the leak would go away if the driver cached a copy of the
firmware, as other drivers do. but that still leaves the suspicion
that there's another copy hanging around in the download path still.
paul
>
> Dan
>
> > diff --git a/drivers/net/wireless/libertas/if_spi.c
> b/drivers/net/wireless/libertas/if_spi.c
> > index fe3f080..123a541 100644
> > --- a/drivers/net/wireless/libertas/if_spi.c
> > +++ b/drivers/net/wireless/libertas/if_spi.c
> > @@ -471,9 +471,12 @@ static int if_spi_prog_helper_firmware(struct
> if_spi_card *card)
> > goto release_firmware;
> > err = spu_write_u16(card, IF_SPI_CARD_INT_CAUSE_REG,
> > IF_SPI_CIC_CMD_DOWNLOAD_OVER);
> > + if (err)
> > goto release_firmware;
> >
> > - lbs_deb_spi("waiting for helper to boot...\n");
> > + lbs_deb_spi("helper firmware loaded...\n");
> > +
> > + return 0;
> >
> > release_firmware:
> > release_firmware(firmware);
> > --
> > 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
>
>
>
> _______________________________________________
> libertas-dev mailing list
> libertas-dev@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/libertas-dev
=---------------------
paul fox, pgf@laptop.org
prev parent reply other threads:[~2010-08-26 18:52 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-24 12:07 [rfc patch] libertas: fix if_spi_prog_helper_firmware() Dan Carpenter
2010-08-24 12:15 ` Ben Hutchings
2010-08-26 3:26 ` Colin McCabe
2010-08-26 3:37 ` Ben Hutchings
2010-08-26 17:04 ` Colin McCabe
2010-08-24 12:17 ` Johannes Berg
2010-08-26 15:48 ` Dan Williams
2010-08-26 18:52 ` Paul Fox [this message]
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=6529.1282848733@foxharp.boston.ma.us \
--to=pgf@laptop.org \
--cc=ben@decadent.org.uk \
--cc=dcbw@redhat.com \
--cc=error27@gmail.com \
--cc=kernel-janitors@vger.kernel.org \
--cc=libertas-dev@lists.infradead.org \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=vapier.adi@gmail.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