batman-adv: fix potential kernel paging errors for unicast transmissions
There are several functions which might reallocate skb data. Currently some places keep reusing their old ethhdr pointer regardless of whether they became invalid after such a reallocation or not. This potentially leads to kernel paging errors. This patch fixes these by refetching the ethdr pointer after the potential reallocations. Signed-off-by: Linus Lüssing <linus.luessing@web.de> Signed-off-by: Marek Lindner <lindner_marek@yahoo.de> Signed-off-by: Antonio Quartulli <ordex@autistici.org>
This commit is contained in:

committed by
Antonio Quartulli

parent
6453599302
commit
9d2c9488ce
@@ -1529,6 +1529,8 @@ out:
|
||||
* in these cases, the skb is further handled by this function and
|
||||
* returns 1, otherwise it returns 0 and the caller shall further
|
||||
* process the skb.
|
||||
*
|
||||
* This call might reallocate skb data.
|
||||
*/
|
||||
int batadv_bla_tx(struct batadv_priv *bat_priv, struct sk_buff *skb,
|
||||
unsigned short vid)
|
||||
|
Reference in New Issue
Block a user