Patch "wifi: fix multi-link element subelement iteration" has been added to the 6.1-stable tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a note to let you know that I've just added the patch titled

    wifi: fix multi-link element subelement iteration

to the 6.1-stable tree which can be found at:
    http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
     wifi-fix-multi-link-element-subelement-iteration.patch
and it can be found in the queue-6.1 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@xxxxxxxxxxxxxxx> know about it.



commit e2a6125940f613e58bd766d2329a8abe98546977
Author: Johannes Berg <johannes.berg@xxxxxxxxx>
Date:   Sat Sep 17 03:14:53 2022 +0200

    wifi: fix multi-link element subelement iteration
    
    [ Upstream commit 1177aaa7fe9373c762cd5bf5f5de8517bac989d5 ]
    
    The subelements obviously start after the common data, including
    the common multi-link element structure definition itself. This
    bug was possibly just hidden by the higher bits of the control
    being set to 0, so the iteration just found one bogus element
    and most of the code could continue anyway.
    
    Fixes: 0f48b8b88aa9 ("wifi: ieee80211: add definitions for multi-link element")
    Signed-off-by: Johannes Berg <johannes.berg@xxxxxxxxx>
    Signed-off-by: Sasha Levin <sashal@xxxxxxxxxx>

diff --git a/include/linux/ieee80211.h b/include/linux/ieee80211.h
index 79690938d9a2..d3088666f3f4 100644
--- a/include/linux/ieee80211.h
+++ b/include/linux/ieee80211.h
@@ -4594,7 +4594,7 @@ static inline u8 ieee80211_mle_common_size(const u8 *data)
 		return 0;
 	}
 
-	return common + mle->variable[0];
+	return sizeof(*mle) + common + mle->variable[0];
 }
 
 /**



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux