From: Rasesh Mody Date: Fri, 16 Sep 2011 15:06:48 +0000 (+0000) Subject: bna: Eliminate Small Race Condition Window in RX Path X-Git-Tag: v3.2-rc1~129^2~256 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b9fa1fbf98178c8bbda23ff1d3ed0731bb3c0bd1;p=pandora-kernel.git bna: Eliminate Small Race Condition Window in RX Path Change details: - In a continuous sequence of ifconfig up/down operations, there is a small window of race between bnad_set_rx_mode() and bnad_cleanup_rx() while the former tries to access rx_info->rx & the latter sets it to NULL. This race could lead to bna_rx_mode_set() being called with a NULL (rx_info->rx) pointer and a crash. - Hold bnad->bna_lock while setting / unsetting rx_info->rx in bnad_setup_rx() & bnad_cleanup_rx(), thereby eliminating the race described above. Signed-off-by: Gurunatha Karaje Signed-off-by: Rasesh Mody Signed-off-by: David S. Miller --- Reading git-diff-tree failed