OpenCloudOS-Kernel/drivers/staging/octeon
Aaro Koskinen 7cc4fa1e51 staging: octeon-ethernet: rgmii: enable interrupts that we can handle
Enable only those interrupts that we can handle & acknowledge in the
interrupt handler.

At least on EdgeRouter Lite, the hardware may occasionally interrupt with
some error condition when the physical link status changes frequently.
Since the interrupt condition is not acked properly, this leads to the
following warning and the IRQ gets disabled completely:

[   41.324700] eth0: Link down
[   44.324721] eth0: 1000 Mbps Full duplex, port  0, queue  0
[   44.885590] irq 117: nobody cared (try booting with the "irqpoll" option)
[   44.892397] CPU: 0 PID: 0 Comm: swapper/0 Not tainted 3.11.0-rc5-edge-los.git-27d042f-dirty-00950-gaa42f2d-dirty #8
[   44.902825] Stack : ffffffff815c0000 0000000000000004 0000000000000003 0000000000000000
	  ffffffff81fd0000 ffffffff815c0000 0000000000000004 ffffffff8118530c
	  ffffffff815c0000 ffffffff811858d8 0000000000000000 0000000000000000
	  ffffffff81fd0000 ffffffff81fc0000 ffffffff8152f3a0 ffffffff815b7bf7
	  ffffffff81fc6688 ffffffff815b8060 0000000000000000 0000000000000000
	  0000000000000000 ffffffff815346c8 ffffffff815346b0 ffffffff814a6a18
	  ffffffff8158b848 ffffffff81145614 ffffffff81593800 ffffffff81187174
	  ffffffff815b7d00 ffffffff8158b760 0000000000000000 ffffffff814a9184
	  0000000000000000 0000000000000000 0000000000000000 0000000000000000
	  0000000000000000 ffffffff811203b8 0000000000000000 0000000000000000
	  ...
[   44.968408] Call Trace:
[   44.970873] [<ffffffff811203b8>] show_stack+0x68/0x80
[   44.975937] [<ffffffff814a9184>] dump_stack+0x78/0xb8
[   44.980999] [<ffffffff811aac54>] __report_bad_irq+0x44/0x108
[   44.986662] [<ffffffff811ab238>] note_interrupt+0x248/0x2a0
[   44.992240] [<ffffffff811a85e4>] handle_irq_event_percpu+0x144/0x200
[   44.998598] [<ffffffff811a86f4>] handle_irq_event+0x54/0x90
[   45.004176] [<ffffffff811ab908>] handle_level_irq+0xd0/0x148
[   45.009839] [<ffffffff811a7b04>] generic_handle_irq+0x34/0x50
[   45.015589] [<ffffffff8111dae8>] do_IRQ+0x18/0x30
[   45.020301] [<ffffffff8110486c>] plat_irq_dispatch+0x74/0xb8
[   45.025958]
[   45.027451] handlers:
[   45.029731] [<ffffffff813fca10>] cvm_oct_rgmii_rml_interrupt
[   45.035397] Disabling IRQ #117
[   45.038742] Port 0 receive error code 13, packet dropped
[   46.324719] eth0: Link down
[   48.324733] eth0: 1000 Mbps Full duplex, port  0, queue  0

Reported-by: "Jason A. Donenfeld" <Jason@zx2c4.com>
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Acked-by: David Daney <david.daney@cavium.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: devel@driverdev.osuosl.org
Cc: linux-mips@linux-mips.org
Cc: Jason A. Donenfeld <Jason@zx2c4.com>
Cc: richard@nod.at
Patchwork: https://patchwork.linux-mips.org/patch/5810/
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
2013-09-17 10:11:31 +02:00
..
Kconfig MIPS: OCTEON: Rename Kconfig CAVIUM_OCTEON_REFERENCE_BOARD to CAVIUM_OCTEON_SOC 2013-06-10 18:01:25 +02:00
Makefile MIPS: Octeon: Move some Ethernet support files out of staging. 2011-12-07 22:03:28 +00:00
ethernet-defines.h MIPS: Octeon: Move some Ethernet support files out of staging. 2011-12-07 22:03:28 +00:00
ethernet-mdio.c ethtool: fix drvinfo strings set in drivers 2013-01-06 21:06:31 -08:00
ethernet-mdio.h Staging: octeon: remove unneeded includes 2010-02-27 12:53:28 +01:00
ethernet-mem.c staging: octeon-ethernet: remove skb alloc failure warnings 2013-09-17 10:10:29 +02:00
ethernet-mem.h
ethernet-rgmii.c staging: octeon-ethernet: rgmii: enable interrupts that we can handle 2013-09-17 10:11:31 +02:00
ethernet-rx.c staging: octeon-ethernet: remove skb alloc failure warnings 2013-09-17 10:10:29 +02:00
ethernet-rx.h MIPS: Octeon: Move some Ethernet support files out of staging. 2011-12-07 22:03:28 +00:00
ethernet-sgmii.c MIPS: Octeon: Move some Ethernet support files out of staging. 2011-12-07 22:03:28 +00:00
ethernet-spi.c MIPS: Octeon: Move some Ethernet support files out of staging. 2011-12-07 22:03:28 +00:00
ethernet-tx.c Staging tree pull request for 3.5-rc1 2012-05-22 16:34:21 -07:00
ethernet-tx.h Staging: Octeon: Free transmit SKBs in a timely manner 2010-02-27 12:53:30 +01:00
ethernet-util.h staging:octeon Fix typos in staging:octeon 2012-04-10 09:47:05 -07:00
ethernet-xaui.c MIPS: Octeon: Move some Ethernet support files out of staging. 2011-12-07 22:03:28 +00:00
ethernet.c Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial 2013-02-21 17:40:58 -08:00
octeon-ethernet.h staging: octeon_ethernet: Convert to use device tree. 2012-07-23 13:54:53 +01:00