linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ath5k: use positive logic for HP laptop LEDs
@ 2008-07-15 17:07 Bob Copeland
  2008-07-21 21:42 ` Helge Deller
  0 siblings, 1 reply; 3+ messages in thread
From: Bob Copeland @ 2008-07-15 17:07 UTC (permalink / raw)
  To: linville; +Cc: deller, mickflemm, jirislaby, mcgrof, linux-wireless


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>
---
Other ath5k devs, any issues with this patch?  Thread here for
reference:

http://marc.info/?l=linux-wireless&m=121555862316630&w=2

 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 217d506..3394b35 100644
--- a/drivers/net/wireless/ath5k/base.c
+++ b/drivers/net/wireless/ath5k/base.c
@@ -2550,8 +2550,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.
@@ -2560,11 +2558,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;
-- 
1.5.4.2.182.gb3092

-- 
Bob Copeland %% www.bobcopeland.com


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

* Re: [PATCH] ath5k: use positive logic for HP laptop LEDs
  2008-07-15 17:07 [PATCH] ath5k: use positive logic for HP laptop LEDs Bob Copeland
@ 2008-07-21 21:42 ` Helge Deller
  2008-07-21 21:58   ` Bob Copeland
  0 siblings, 1 reply; 3+ messages in thread
From: Helge Deller @ 2008-07-21 21:42 UTC (permalink / raw)
  To: linux-wireless

Bob, I think your patch below somehow got truncated and you wanted to send
this patch ?
http://marc.info/?l=linux-wireless&m=121557127930799&w=2

Bob Copeland wrote:
> 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>
> ---
> Other ath5k devs, any issues with this patch?  Thread here for
> reference:
> 
> http://marc.info/?l=linux-wireless&m=121555862316630&w=2
> 
>  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 217d506..3394b35 100644
> --- a/drivers/net/wireless/ath5k/base.c
> +++ b/drivers/net/wireless/ath5k/base.c
> @@ -2550,8 +2550,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 */



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

* Re: [PATCH] ath5k: use positive logic for HP laptop LEDs
  2008-07-21 21:42 ` Helge Deller
@ 2008-07-21 21:58   ` Bob Copeland
  0 siblings, 0 replies; 3+ messages in thread
From: Bob Copeland @ 2008-07-21 21:58 UTC (permalink / raw)
  To: Helge Deller; +Cc: linux-wireless

On Mon, Jul 21, 2008 at 5:42 PM, Helge Deller <deller@gmx.de> wrote:
> Bob, I think your patch below somehow got truncated and you wanted to send
> this patch ?
> http://marc.info/?l=linux-wireless&m=121557127930799&w=2
>
[...]
>>
>> -     sc->led_on = 0;  /* active low */

Hmm, well it definitely didn't end there, but the version from this
thread on marc's archive wasn't truncated.  Maybe my mailer hiccuped
when CCing you?

Anyway, yep, the patch is unchanged from the earlier posting.

-- 
Bob Copeland %% www.bobcopeland.com

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

end of thread, other threads:[~2008-07-21 21:58 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-15 17:07 [PATCH] ath5k: use positive logic for HP laptop LEDs Bob Copeland
2008-07-21 21:42 ` Helge Deller
2008-07-21 21:58   ` Bob Copeland

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