[PATCH] orinoco: Read only needed data in __orinoco_ev_txexc().
authorPavel Roskin <proski@gnu.org>
Fri, 23 Sep 2005 08:18:06 +0000 (04:18 -0400)
committerJeff Garzik <jgarzik@pobox.com>
Fri, 23 Sep 2005 08:36:13 +0000 (04:36 -0400)
Signed-off-by: Pavel Roskin <proski@gnu.org>
Read only needed data in __orinoco_ev_txexc().

Don't read the 802.11 header beyond addr1.  The rest of the frame is not
used currently.
Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
drivers/net/wireless/orinoco.c

index 1ae301c622817f699a6f1a927c75cda7ddbab059..78afbc7f08be76d0cb7ca6ca8754c9fa41e5a869 100644 (file)
@@ -623,10 +623,10 @@ static void __orinoco_ev_txexc(struct net_device *dev, hermes_t *hw)
        if (fid == DUMMY_FID)
                return; /* Nothing's really happened */
 
-       /* Read the frame header */
+       /* Read part of the frame header - we need status and addr1 */
        err = hermes_bap_pread(hw, IRQ_BAP, &hdr,
-                              sizeof(struct hermes_tx_descriptor) +
-                              sizeof(struct ieee80211_hdr_4addr),
+                              offsetof(struct hermes_tx_descriptor_802_11,
+                                       addr2),
                               fid, 0);
 
        hermes_write_regn(hw, TXCOMPLFID, DUMMY_FID);