lan78xx: Debounce link events to minimize poll storm
authorJoshua Emele <jemele@acm.org>
Thu, 8 Nov 2018 00:07:40 +0000 (16:07 -0800)
committerpopcornmix <popcornmix@gmail.com>
Mon, 13 May 2019 23:08:16 +0000 (00:08 +0100)
commit1f9942d019d7e166696d1e23f733239c1250f051
tree5bc63ed45dd48d0a6a255e45385cb36497482de9
parent3c6d8afeb227a3aeb0ae101176c511db578aa131
lan78xx: Debounce link events to minimize poll storm

The bInterval is set to 4 (i.e. 8 microframes => 1ms) and the only bit
that the driver pays attention to is "link was reset". If there's a
flapping status bit in that endpoint data, (such as if PHY negotiation
needs a few tries to get a stable link) then polling at a slower rate
would act as a de-bounce.

See: https://github.com/raspberrypi/linux/issues/2447
drivers/net/usb/lan78xx.c