summaryrefslogtreecommitdiffstats
path: root/Documentation/devicetree/bindings
diff options
context:
space:
mode:
authorRoger Quadros <rogerq@ti.com>2015-07-07 16:06:15 +0300
committerChanwoo Choi <cw00.choi@samsung.com>2015-07-31 10:08:47 +0900
commitbe052cc87745e01846fb036eb81567c784439078 (patch)
treea730360e39f24ab9b75fb930eecc615d21e0baca /Documentation/devicetree/bindings
parente350f8045f642dfc4c28a81c57d2103e1f7ceead (diff)
extcon: Fix hang and extcon_get/set_cable_state().
Users of find_cable_index_by_name() will cause a kernel hang as the while loop counter is never incremented and end condition is never reached. extcon_get_cable_state() and extcon_set_cable_state() are broken because they use cable index instead of cable id. This causes the first cable state (cable.0) to be always invalid in sysfs or extcon_get_cable_state() users. Introduce a new function find_cable_id_by_name() that fixes both of the above issues. Fixes: commit 73b6ecdb93e8 ("extcon: Redefine the unique id of supported external connectors without 'enum extcon' type") Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Roger Quadros <rogerq@ti.com> Tested-by: Ivan T. Ivanov <ivan.ivanov@linaro.org> [cw00.choi: Fix minor coding style] Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Diffstat (limited to 'Documentation/devicetree/bindings')
0 files changed, 0 insertions, 0 deletions