From: Joe Jin Date: Thu, 17 May 2012 07:56:02 +0000 (+0800) Subject: e1000e: use msleep instead of mdelay X-Git-Tag: v2.6.39-400.9.0~423^2~19^2~11^2~313 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=c3468f7525b63543a729a8c520443b4f598a8587;p=users%2Fjedix%2Flinux-maple.git e1000e: use msleep instead of mdelay The e1000_link_stall_workaround_lv() function is always called in non- atomic context so it should use msleep instead of mdelay. Also, remove unnecessary #include . (backported from commit bb9c5ee15b560f944a8877f60e7d3d77ad542286) Signed-off-by: Bruce Allan Tested-by: Aaron Brown Signed-off-by: Jeff Kirsher Signed-off-by: Joe Jin --- diff --git a/drivers/net/e1000e/phy.c b/drivers/net/e1000e/phy.c index d4dbbe741246..d2cc188b35eb 100644 --- a/drivers/net/e1000e/phy.c +++ b/drivers/net/e1000e/phy.c @@ -26,8 +26,6 @@ *******************************************************************************/ -#include - #include "e1000.h" static s32 e1000_get_phy_cfg_done(struct e1000_hw *hw); @@ -3164,7 +3162,7 @@ s32 e1000_link_stall_workaround_hv(struct e1000_hw *hw) BM_CS_STATUS_SPEED_1000)) return 0; - mdelay(200); + msleep(200); /* flush the packets in the fifo buffer */ ret_val = e1e_wphy(hw, HV_MUX_DATA_CTRL, HV_MUX_DATA_CTRL_GEN_TO_MAC |