All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] extcon: Fix wrong index in max8997_extcon_cable[]
@ 2012-06-16  3:36 Axel Lin
  2012-06-16  4:01 ` Kyungmin Park
  0 siblings, 1 reply; 2+ messages in thread
From: Axel Lin @ 2012-06-16  3:36 UTC (permalink / raw)
  To: linux-kernel
  Cc: Chanwoo Choi, Myungjoo Ham, Kyungmin Park, Greg Kroah-Hartman

Currently, the index of "Dock-desk" and "Dock-card" are the same.
Thus the latter one overrides the first one.
Then we have problem when calling extcon_find_cable_index() because
edev->supported_cable[7] only matches "Dock-card".

Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
 drivers/extcon/extcon-max8997.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/extcon/extcon-max8997.c b/drivers/extcon/extcon-max8997.c
index 23416e4..5ecf176 100644
--- a/drivers/extcon/extcon-max8997.c
+++ b/drivers/extcon/extcon-max8997.c
@@ -116,8 +116,8 @@ const char *max8997_extcon_cable[] = {
 	[5] = "Charge-downstream",
 	[6] = "MHL",
 	[7] = "Dock-desk",
-	[7] = "Dock-card",
-	[8] = "JIG",
+	[8] = "Dock-card",
+	[9] = "JIG",
 
 	NULL,
 };
-- 
1.7.9.5




^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] extcon: Fix wrong index in max8997_extcon_cable[]
  2012-06-16  3:36 [PATCH] extcon: Fix wrong index in max8997_extcon_cable[] Axel Lin
@ 2012-06-16  4:01 ` Kyungmin Park
  0 siblings, 0 replies; 2+ messages in thread
From: Kyungmin Park @ 2012-06-16  4:01 UTC (permalink / raw)
  To: Axel Lin; +Cc: linux-kernel, Chanwoo Choi, Myungjoo Ham, Greg Kroah-Hartman

Nice catch!

Acked-by: Kyungmin Park <kyungmin.park@samsung.com>

On 6/16/12, Axel Lin <axel.lin@gmail.com> wrote:
> Currently, the index of "Dock-desk" and "Dock-card" are the same.
> Thus the latter one overrides the first one.
> Then we have problem when calling extcon_find_cable_index() because
> edev->supported_cable[7] only matches "Dock-card".
>
> Signed-off-by: Axel Lin <axel.lin@gmail.com>
> ---
>  drivers/extcon/extcon-max8997.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/extcon/extcon-max8997.c
> b/drivers/extcon/extcon-max8997.c
> index 23416e4..5ecf176 100644
> --- a/drivers/extcon/extcon-max8997.c
> +++ b/drivers/extcon/extcon-max8997.c
> @@ -116,8 +116,8 @@ const char *max8997_extcon_cable[] = {
>  	[5] = "Charge-downstream",
>  	[6] = "MHL",
>  	[7] = "Dock-desk",
> -	[7] = "Dock-card",
> -	[8] = "JIG",
> +	[8] = "Dock-card",
> +	[9] = "JIG",
>
>  	NULL,
>  };
> --
> 1.7.9.5
>
>
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-06-16  4:08 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-16  3:36 [PATCH] extcon: Fix wrong index in max8997_extcon_cable[] Axel Lin
2012-06-16  4:01 ` Kyungmin Park

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.