[PATCH] libertas: fix command size for CMD_802_11_SUBSCRIBE_EVENT

Holger Schurig hs4233 at mail.mn-solutions.de
Fri May 30 08:53:22 EDT 2008


The size was two small by two bytes.

Signed-off-by: Holger Schurig

---

Before:

libertas cmd: DNLD_CMD: command 0x0075, seq 136, size 16
libertas DNLD_CMD: 75 00 10 00 88 00 00 00 01 00 08 00 04 01 02 00
libertas cmd: CMD_RESP: response 0x8075, seq 136, size 16
libertas CMD_RESP: 75 80 10 00 88 00 00 00 01 00 08 00 04 01 02 00

The value & frequency where missing.


After:

libertas cmd: DNLD_CMD: command 0x0075, seq 32, size 18
libertas DNLD_CMD: 75 00 12 00 20 00 00 00 01 00 08 00 04 01 02 00
libertas DNLD_CMD: 64 00
libertas cmd: CMD_RESP: response 0x8075, seq 32, size 18
libertas CMD_RESP: 75 80 12 00 20 00 00 00 01 00 08 00 04 01 02 00
libertas CMD_RESP: 64 00

Now value (100) and frequency (0) are there.


Index: wireless-testing/drivers/net/wireless/libertas/debugfs.c
===================================================================
--- wireless-testing.orig/drivers/net/wireless/libertas/debugfs.c	2008-05-30 13:43:15.000000000 +0200
+++ wireless-testing/drivers/net/wireless/libertas/debugfs.c	2008-05-30 13:45:04.000000000 +0200
@@ -312,8 +312,8 @@ static ssize_t lbs_threshold_write(uint1
 	if (tlv_type != TLV_TYPE_BCNMISS)
 		tlv->freq = freq;
 
-	/* The command header, the event mask, and the one TLV */
-	events->hdr.size = cpu_to_le16(sizeof(events->hdr) + 2 + sizeof(*tlv));
+	/* The command header, the action, the event mask, and one TLV */
+	events->hdr.size = cpu_to_le16(sizeof(events->hdr) + 4 + sizeof(*tlv));
 
 	ret = lbs_cmd_with_response(priv, CMD_802_11_SUBSCRIBE_EVENT, events);
 



More information about the libertas-dev mailing list