linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Helge Deller <deller@gmx.de>
To: Bob Copeland <me@bobcopeland.com>
Cc: ath5k-devel@lists.ath5k.org, linux-wireless@vger.kernel.org
Subject: Re: [PATCH] ath5k: convert LED code to use mac80211 triggers
Date: Wed, 09 Jul 2008 08:57:59 +0200	[thread overview]
Message-ID: <48746177.8040903@gmx.de> (raw)
In-Reply-To: <20080709024053.GA3715@hash.localnet>

Bob Copeland wrote:
> I wrote:
>> I guess the conservative approach is to just use sc->led_on = 1 in the
>> VENDOR_ID_COMPAQ branch
> 
> ...here's the obvious patch for this, let me know if it works for you.

Thanks Bob!
Patch works OK.

Helge

> Subject: [PATCH] ath5k: use positive logic for HP laptop LEDs
> 
> Helge Deller reports that HP laptops (NC4010 and NC6000) use active-
> high signals to turn on the LEDs.  Previous code used active-low for
> all devices.
> 
> Signed-off-by: Bob Copeland <me@bobcopeland.com>
> ---
>  drivers/net/wireless/ath5k/base.c |    4 ++--
>  1 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c
> index a43e9b2..fb6fd14 100644
> --- a/drivers/net/wireless/ath5k/base.c
> +++ b/drivers/net/wireless/ath5k/base.c
> @@ -2551,8 +2551,6 @@ ath5k_init_leds(struct ath5k_softc *sc)
>  	struct pci_dev *pdev = sc->pdev;
>  	char name[ATH5K_LED_MAX_NAME_LEN + 1];
>  
> -	sc->led_on = 0;  /* active low */
> -
>  	/*
>  	 * Auto-enable soft led processing for IBM cards and for
>  	 * 5211 minipci cards.
> @@ -2561,11 +2559,13 @@ ath5k_init_leds(struct ath5k_softc *sc)
>  	    pdev->device == PCI_DEVICE_ID_ATHEROS_AR5211) {
>  		__set_bit(ATH_STAT_LEDSOFT, sc->status);
>  		sc->led_pin = 0;
> +		sc->led_on = 0;  /* active low */
>  	}
>  	/* Enable softled on PIN1 on HP Compaq nc6xx, nc4000 & nx5000 laptops */
>  	if (pdev->subsystem_vendor == PCI_VENDOR_ID_COMPAQ) {
>  		__set_bit(ATH_STAT_LEDSOFT, sc->status);
>  		sc->led_pin = 1;
> +		sc->led_on = 1;  /* active high */
>  	}
>  	if (!test_bit(ATH_STAT_LEDSOFT, sc->status))
>  		goto out;


  reply	other threads:[~2008-07-09  6:58 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-06-22 18:11 [PATCH] ath5k: convert LED code to use mac80211 triggers Bob Copeland
2008-06-25 12:12 ` Nick Kossifidis
2008-06-25 13:56   ` Bob Copeland
2008-06-26  2:35     ` Bob Copeland
2008-07-08 23:08       ` Helge Deller
2008-07-09  2:22         ` [ath5k-devel] " Bob Copeland
2008-07-09  2:40           ` Bob Copeland
2008-07-09  6:57             ` Helge Deller [this message]
2008-07-09  7:00           ` [ath5k-devel] " Helge Deller

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=48746177.8040903@gmx.de \
    --to=deller@gmx.de \
    --cc=ath5k-devel@lists.ath5k.org \
    --cc=linux-wireless@vger.kernel.org \
    --cc=me@bobcopeland.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).