MLK-14938-22 mxc_gpio: Change to get value from DR register
authorYe Li <ye.li@nxp.com>
Fri, 28 Apr 2017 14:36:57 +0000 (09:36 -0500)
committerYe Li <ye.li@nxp.com>
Fri, 24 May 2019 11:28:28 +0000 (04:28 -0700)
commit7980dc9700bdeb610cfa91b4b53abe450c688b9b
tree1dd260d40a6f421e7f7cfca91d87daa121cc830c
parent208c009aa15453349ee9272d62e2c1cebe14ecab
MLK-14938-22 mxc_gpio: Change to get value from DR register

Currently the driver gets value from PSR register, but this register
is only for input mode. For output mode, it always return 0 not the
value we set for output.

This patch changes to use DR register, which returns the DR value for
output mode, and PSR value for input mode.

Signed-off-by: Ye Li <ye.li@nxp.com>
(cherry picked from commit 4afc3f90943c6b117f79b66d2cd04e64f437b0c2)
(cherry picked from commit 8cca3efba0d508b2c267f8a32b302970dd05244d)
drivers/gpio/mxc_gpio.c