]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
[bytgpio] Fix USB disconnect event after listsing pins on gpioc2
authorOleksandr Tymoshenko <gonzo@FreeBSD.org>
Sun, 20 Nov 2016 18:38:32 +0000 (18:38 +0000)
committerOleksandr Tymoshenko <gonzo@FreeBSD.org>
Sun, 20 Nov 2016 18:38:32 +0000 (18:38 +0000)
commit06ae3ba328fccb90c65f6de0f69f608904ad9596
tree3b554f8da376126564863fd7c8023ff34e84ac33
parent44b5cf6ff450e7094d645c6757c02618b12cae29
[bytgpio] Fix USB disconnect event after listsing pins on gpioc2

- Do not set input flag when reading value from GPIO pin, it is not
  required and for gpioc2(S5 bank) setting both input and output flags
  leads to some kind of electric interference (curren drop?) that
  causes USB devices to disconnect

- Check pad configuration when attaching device and provide IN/OUT
  capabilities only for pads that are configured as GPIO. Do not let
  user code to configure or change value of non-GPIO pads. There is
  no information for NC bank in intel's datasheet so for now function
  check is ignored for pins in it

Reported by: Frank H.
MFC after: 3 days
sys/dev/gpio/bytgpio.c