aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/extcon
diff options
context:
space:
mode:
authorChanwoo Choi <cw00.choi@samsung.com>2014-07-30 02:39:02 -0400
committerChanwoo Choi <cw00.choi@samsung.com>2014-09-21 22:43:07 -0400
commit0ccc7955acc19e7f4515e51993b7b95cf5a35fdc (patch)
tree99e71187d4852bba6ce8bdb77a028bfbad9ac83b /drivers/extcon
parent9e82bf014195d6f0054982c463575cdce24292be (diff)
extcon: sm5502: Fix bug to check cable type
This patch fix bug when checking cable type. SM5502 have to use ADC value to get correct cable type. Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
Diffstat (limited to 'drivers/extcon')
-rw-r--r--drivers/extcon/extcon-sm5502.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/extcon/extcon-sm5502.c b/drivers/extcon/extcon-sm5502.c
index 560d7dccec7b..a1ba9242e9cb 100644
--- a/drivers/extcon/extcon-sm5502.c
+++ b/drivers/extcon/extcon-sm5502.c
@@ -300,7 +300,7 @@ static unsigned int sm5502_muic_get_cable_type(struct sm5502_muic_info *info)
300 * If ADC is SM5502_MUIC_ADC_GROUND(0x0), external cable hasn't 300 * If ADC is SM5502_MUIC_ADC_GROUND(0x0), external cable hasn't
301 * connected with to MUIC device. 301 * connected with to MUIC device.
302 */ 302 */
303 cable_type &= SM5502_REG_ADC_MASK; 303 cable_type = adc & SM5502_REG_ADC_MASK;
304 if (cable_type == SM5502_MUIC_ADC_GROUND) 304 if (cable_type == SM5502_MUIC_ADC_GROUND)
305 return SM5502_MUIC_ADC_GROUND; 305 return SM5502_MUIC_ADC_GROUND;
306 306