linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drivers/extcon: Fix incompatible pointer type warning
@ 2016-11-28  2:37 ` Peter Foley
  2016-11-29  9:42   ` Chanwoo Choi
  0 siblings, 1 reply; 2+ messages in thread
From: Peter Foley @ 2016-11-28  2:37 UTC (permalink / raw)
  To: linux-kernel, myungjoo.ham, cw00.choi; +Cc: Peter Foley

  CC [M]  drivers/extcon/extcon-adc-jack.o
../drivers/extcon/extcon-adc-jack.c:115:52: error: incompatible pointer types passing 'const enum extcon *' to parameter of type 'const unsigned int *' [-Werror,-Wincompatible-pointer-types]
        data->edev = devm_extcon_dev_allocate(&pdev->dev, pdata->cable_names);
                                                          ^~~~~~~~~~~~~~~~~~
../include/linux/extcon.h:240:30: note: passing argument to parameter 'cable' here
                                                   const unsigned int *cable);
                                                                       ^
1 error generated.

Signed-off-by: Peter Foley <pefoley2@pefoley.com>
---
 include/linux/extcon/extcon-adc-jack.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/extcon/extcon-adc-jack.h b/include/linux/extcon/extcon-adc-jack.h
index a0e03b13b449..2aa32075bca1 100644
--- a/include/linux/extcon/extcon-adc-jack.h
+++ b/include/linux/extcon/extcon-adc-jack.h
@@ -59,7 +59,7 @@ struct adc_jack_pdata {
 	const char *name;
 	const char *consumer_channel;
 
-	const enum extcon *cable_names;
+	const unsigned int *cable_names;
 
 	/* The last entry's state should be 0 */
 	struct adc_jack_cond *adc_conditions;
-- 
2.11.0.rc2

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

* Re: [PATCH] drivers/extcon: Fix incompatible pointer type warning
  2016-11-28  2:37 ` [PATCH] drivers/extcon: Fix incompatible pointer type warning Peter Foley
@ 2016-11-29  9:42   ` Chanwoo Choi
  0 siblings, 0 replies; 2+ messages in thread
From: Chanwoo Choi @ 2016-11-29  9:42 UTC (permalink / raw)
  To: Peter Foley, linux-kernel, myungjoo.ham

On 2016년 11월 28일 11:37, Peter Foley wrote:
>   CC [M]  drivers/extcon/extcon-adc-jack.o
> ../drivers/extcon/extcon-adc-jack.c:115:52: error: incompatible pointer types passing 'const enum extcon *' to parameter of type 'const unsigned int *' [-Werror,-Wincompatible-pointer-types]
>         data->edev = devm_extcon_dev_allocate(&pdev->dev, pdata->cable_names);
>                                                           ^~~~~~~~~~~~~~~~~~
> ../include/linux/extcon.h:240:30: note: passing argument to parameter 'cable' here
>                                                    const unsigned int *cable);
>                                                                        ^
> 1 error generated.
> 
> Signed-off-by: Peter Foley <pefoley2@pefoley.com>
> ---
>  include/linux/extcon/extcon-adc-jack.h | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 

Applied it. Thanks.

I modify the patch title as following:
- old : drivers/extcon: Fix incompatible pointer type warning
- new : extcon: adc-jack: Fix incompatible pointer type warning

-- 
Best Regards,
Chanwoo Choi

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

end of thread, other threads:[~2016-11-29  9:43 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CGME20161128023736epcas2p449756cd8c14670b4debcecd872d529ee@epcas2p4.samsung.com>
2016-11-28  2:37 ` [PATCH] drivers/extcon: Fix incompatible pointer type warning Peter Foley
2016-11-29  9:42   ` Chanwoo Choi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).