netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* sky2: Correct mistakenly switched read/write sequence
@ 2012-12-01 12:42 Lino Sanfilippo
  2012-12-01 17:27 ` David Miller
  2012-12-01 18:36 ` Stephen Hemminger
  0 siblings, 2 replies; 4+ messages in thread
From: Lino Sanfilippo @ 2012-12-01 12:42 UTC (permalink / raw)
  To: shemminger, mlindner; +Cc: davem, netdev

In sky2_all_down() the order of the read()/write() access to B0_IMSK seems to
be mistakenly switched. The original intention was obviously to avoid PCI write
posting.
This patch fixes the order.

Signed-off-by: Lino Sanfilippo <LinoSanfilippo@gmx.de>
---
 drivers/net/ethernet/marvell/sky2.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/ethernet/marvell/sky2.c b/drivers/net/ethernet/marvell/sky2.c
index 78946fe..b20d2fd 100644
--- a/drivers/net/ethernet/marvell/sky2.c
+++ b/drivers/net/ethernet/marvell/sky2.c
@@ -3481,8 +3481,8 @@ static void sky2_all_down(struct sky2_hw *hw)
 	int i;
 
 	if (hw->flags & SKY2_HW_IRQ_SETUP) {
-		sky2_read32(hw, B0_IMSK);
 		sky2_write32(hw, B0_IMSK, 0);
+		sky2_read32(hw, B0_IMSK);
 
 		synchronize_irq(hw->pdev->irq);
 		napi_disable(&hw->napi);
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-12-01 20:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-01 12:42 sky2: Correct mistakenly switched read/write sequence Lino Sanfilippo
2012-12-01 17:27 ` David Miller
2012-12-01 20:06   ` Lino Sanfilippo
2012-12-01 18:36 ` Stephen Hemminger

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).