From: Sven Eckelmann Date: Sat, 21 Aug 2010 12:18:10 +0000 (+0200) Subject: Staging: batman-adv: Don't write in not allocated packet_buff X-Git-Tag: v2.6.36-rc3~38^2~1 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f86b9984250fa2b71ce36d4693a939a58579583b;p=pandora-kernel.git Staging: batman-adv: Don't write in not allocated packet_buff Each net_device in a system will automatically managed as a possible batman_if and holds different informations like a buffer with a prepared originator messages. To reduce the memory usage, the packet_buff will only be allocated when the interface is really added/enabled for batman-adv. The function to update the hw address information inside the packet_buff just assumes that the packet_buff is always initialised and thus the kernel will just oops when we try to change the hw address of a not already fully enabled interface. We must always check if the packet_buff is allocated before we try to change information inside of it. Reported-by: Tim Glaremin Reported-by: Kazuki Shimada Signed-off-by: Sven Eckelmann Cc: stable Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed