Message ID | CAGTfZH34rfMfjsAFgyPeNue74-5iCi6ZwrdN26_jwOXE6R=hwg@mail.gmail.com (mailing list archive) |
---|---|
State | Accepted |
Delegated to: | Geert Uytterhoeven |
Headers | show |
Hello. On 12/20/2015 05:31 PM, Chanwoo Choi wrote: > This patch depend on GPIOLIB configuration as following: > I modified it with following diff and applied it. > > diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig > index ba4db7d..3d89e60 100644 > --- a/drivers/extcon/Kconfig > +++ b/drivers/extcon/Kconfig > @@ -54,6 +54,7 @@ config EXTCON_MAX14577 > > config EXTCON_MAX3355 > tristate "Maxim MAX3355 USB OTG EXTCON Support" > + depends on GPIOLIB || COMPILE_TEST If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. [...] > Thanks, > Chanwoo Choi MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hi, On 2015? 12? 21? 02:15, Sergei Shtylyov wrote: > Hello. > > On 12/20/2015 05:31 PM, Chanwoo Choi wrote: > >> This patch depend on GPIOLIB configuration as following: >> I modified it with following diff and applied it. >> >> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >> index ba4db7d..3d89e60 100644 >> --- a/drivers/extcon/Kconfig >> +++ b/drivers/extcon/Kconfig >> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >> >> config EXTCON_MAX3355 >> tristate "Maxim MAX3355 USB OTG EXTCON Support" >> + depends on GPIOLIB || COMPILE_TEST > > If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? > And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. Yes. When GPIOLIB is disabled, the build issue don't happen. because include/linux/gpio/consumer.h implement the dummy function for all gpio functions if CONFIG_GPIOLIB is disabled. For correct operation of max3355, you should add the dependency to the extcon-max3355.c driver. This driver use the GPIO library certainly. COMPILE_TEST is used for just build test. You can see the detailed data[1]. [1] https://lkml.org/lkml/2013/5/22/155 Thanks, Chanwoo Choi -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 12/21/2015 5:38 AM, Chanwoo Choi wrote: >>> This patch depend on GPIOLIB configuration as following: >>> I modified it with following diff and applied it. >>> >>> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >>> index ba4db7d..3d89e60 100644 >>> --- a/drivers/extcon/Kconfig >>> +++ b/drivers/extcon/Kconfig >>> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >>> >>> config EXTCON_MAX3355 >>> tristate "Maxim MAX3355 USB OTG EXTCON Support" >>> + depends on GPIOLIB || COMPILE_TEST >> >> If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? >> And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. > > Yes. When GPIOLIB is disabled, the build issue don't happen. What? It surely does happen! > because include/linux/gpio/consumer.h implement the dummy function > for all gpio functions if CONFIG_GPIOLIB is disabled. Linus W. advised to #include this header explicitly -- I'll try and post. > For correct operation of max3355, you should add the dependency > to the extcon-max3355.c driver. This driver use the GPIO library > certainly. I disagree. The driver will just cease to load in this case. I don't see why we need such dependency. Only compilation time dependencies should be specified, I think. > COMPILE_TEST is used for just build test. You can see the detailed data[1]. > [1] https://lkml.org/lkml/2013/5/22/155 I know. Re-read my question please. > Thanks, > Chanwoo Choi MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 12/21/2015 02:01 PM, Sergei Shtylyov wrote: >>>> This patch depend on GPIOLIB configuration as following: >>>> I modified it with following diff and applied it. >>>> >>>> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >>>> index ba4db7d..3d89e60 100644 >>>> --- a/drivers/extcon/Kconfig >>>> +++ b/drivers/extcon/Kconfig >>>> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >>>> >>>> config EXTCON_MAX3355 >>>> tristate "Maxim MAX3355 USB OTG EXTCON Support" >>>> + depends on GPIOLIB || COMPILE_TEST >>> >>> If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? >>> And no, it shouldn't depend on gpiolib. It has empty stubs for the case >>> of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, >>> I'll look into it. >> >> Yes. When GPIOLIB is disabled, the build issue don't happen. > > What? It surely does happen! > >> because include/linux/gpio/consumer.h implement the dummy function >> for all gpio functions if CONFIG_GPIOLIB is disabled. > > Linus W. advised to #include this header explicitly -- I'll try and post. I see you already #include'd it, thanks. But in that case, <linux/gpio.h> doesn't seem necessary. >> Thanks, >> Chanwoo Choi MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 2015? 12? 21? 20:01, Sergei Shtylyov wrote: > Hello. > > On 12/21/2015 5:38 AM, Chanwoo Choi wrote: > >>>> This patch depend on GPIOLIB configuration as following: >>>> I modified it with following diff and applied it. >>>> >>>> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >>>> index ba4db7d..3d89e60 100644 >>>> --- a/drivers/extcon/Kconfig >>>> +++ b/drivers/extcon/Kconfig >>>> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >>>> >>>> config EXTCON_MAX3355 >>>> tristate "Maxim MAX3355 USB OTG EXTCON Support" >>>> + depends on GPIOLIB || COMPILE_TEST >>> >>> If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? >>> And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. >> >> Yes. When GPIOLIB is disabled, the build issue don't happen. > > What? It surely does happen! hmm.... Sure. you need to check the include/linux/gpio/consumer.h. Because of build error happen, you miss to include the "linux/gpio/consumer.h" header file in extcon-max3355.c. Please test it for enough time. > >> because include/linux/gpio/consumer.h implement the dummy function >> for all gpio functions if CONFIG_GPIOLIB is disabled. > > Linus W. advised to #include this header explicitly -- I'll try and post. Don't necessary. I already updated it including the "include/linux/gpio/consumer.h". > >> For correct operation of max3355, you should add the dependency >> to the extcon-max3355.c driver. This driver use the GPIO library >> certainly. > > I disagree. The driver will just cease to load in this case. I don't see why we need such dependency. Only compilation time dependencies should be > specified, I think. This driver have to depend on GPIOLIB. Why are you disagreeing the COMPILE_TEST dependency? It is just compile test without anything. -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 12/22/2015 4:13 AM, Chanwoo Choi wrote: >>>>> This patch depend on GPIOLIB configuration as following: >>>>> I modified it with following diff and applied it. >>>>> >>>>> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >>>>> index ba4db7d..3d89e60 100644 >>>>> --- a/drivers/extcon/Kconfig >>>>> +++ b/drivers/extcon/Kconfig >>>>> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >>>>> >>>>> config EXTCON_MAX3355 >>>>> tristate "Maxim MAX3355 USB OTG EXTCON Support" >>>>> + depends on GPIOLIB || COMPILE_TEST >>>> >>>> If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? >>>> And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. >>> >>> Yes. When GPIOLIB is disabled, the build issue don't happen. >> >> What? It surely does happen! > > hmm.... > Sure. you need to check the include/linux/gpio/consumer.h. > > Because of build error happen, you miss to include the "linux/gpio/consumer.h" > header file in extcon-max3355.c. Please test it for enough time. Yes, with this file #include'd, it build fine now. >>> because include/linux/gpio/consumer.h implement the dummy function >>> for all gpio functions if CONFIG_GPIOLIB is disabled. >> >> Linus W. advised to #include this header explicitly -- I'll try and post. > > Don't necessary. I already updated it including the "include/linux/gpio/consumer.h". I saw that, yes. >>> For correct operation of max3355, you should add the dependency >>> to the extcon-max3355.c driver. This driver use the GPIO library >>> certainly. >> >> I disagree. The driver will just cease to load in this case. I don't see why we need such dependency. Only compilation time dependencies should be >> specified, I think. > > This driver have to depend on GPIOLIB. > Why are you disagreeing the COMPILE_TEST dependency? It is just compile test > without anything. I agree now. I still disagree about the gpiolib dependency though. MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
On 2015? 12? 22? 20:15, Sergei Shtylyov wrote: > Hello. > > On 12/22/2015 4:13 AM, Chanwoo Choi wrote: > >>>>>> This patch depend on GPIOLIB configuration as following: >>>>>> I modified it with following diff and applied it. >>>>>> >>>>>> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >>>>>> index ba4db7d..3d89e60 100644 >>>>>> --- a/drivers/extcon/Kconfig >>>>>> +++ b/drivers/extcon/Kconfig >>>>>> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >>>>>> >>>>>> config EXTCON_MAX3355 >>>>>> tristate "Maxim MAX3355 USB OTG EXTCON Support" >>>>>> + depends on GPIOLIB || COMPILE_TEST >>>>> >>>>> If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? >>>>> And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. >>>> >>>> Yes. When GPIOLIB is disabled, the build issue don't happen. >>> >>> What? It surely does happen! >> >> hmm.... >> Sure. you need to check the include/linux/gpio/consumer.h. >> >> Because of build error happen, you miss to include the "linux/gpio/consumer.h" >> header file in extcon-max3355.c. Please test it for enough time. > > Yes, with this file #include'd, it build fine now. > >>>> because include/linux/gpio/consumer.h implement the dummy function >>>> for all gpio functions if CONFIG_GPIOLIB is disabled. >>> >>> Linus W. advised to #include this header explicitly -- I'll try and post. >> >> Don't necessary. I already updated it including the "include/linux/gpio/consumer.h". > > I saw that, yes. > >>>> For correct operation of max3355, you should add the dependency >>>> to the extcon-max3355.c driver. This driver use the GPIO library >>>> certainly. >>> >>> I disagree. The driver will just cease to load in this case. I don't see why we need such dependency. Only compilation time dependencies should be >>> specified, I think. >> >> This driver have to depend on GPIOLIB. >> Why are you disagreeing the COMPILE_TEST dependency? It is just compile test >> without anything. > > I agree now. I still disagree about the gpiolib dependency though. If gpiolib is disabled, extcon-max3355.c might not operate it correctly. Just this driver could be built without operation because gpiolib function will not do the any behavior. I think that it is not too much problem. I should send the pull request within this week. If you want to need more discussion of extcon-max3355.c, I will not include it on pull request for v4.5 because there is issue. -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Hello. On 12/23/2015 05:17 AM, Chanwoo Choi wrote: >>>>>>> This patch depend on GPIOLIB configuration as following: >>>>>>> I modified it with following diff and applied it. >>>>>>> >>>>>>> diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig >>>>>>> index ba4db7d..3d89e60 100644 >>>>>>> --- a/drivers/extcon/Kconfig >>>>>>> +++ b/drivers/extcon/Kconfig >>>>>>> @@ -54,6 +54,7 @@ config EXTCON_MAX14577 >>>>>>> >>>>>>> config EXTCON_MAX3355 >>>>>>> tristate "Maxim MAX3355 USB OTG EXTCON Support" >>>>>>> + depends on GPIOLIB || COMPILE_TEST >>>>>> >>>>>> If it won't compile w/o gpiolib, what's the use of COMIPLE_TEST? >>>>>> And no, it shouldn't depend on gpiolib. It has empty stubs for the case of CONFIG_GPIOLIB=n. Obviously something is wrong with the GPIO headers, I'll look into it. >>>>> >>>>> Yes. When GPIOLIB is disabled, the build issue don't happen. >>>> >>>> What? It surely does happen! >>> >>> hmm.... >>> Sure. you need to check the include/linux/gpio/consumer.h. >>> >>> Because of build error happen, you miss to include the "linux/gpio/consumer.h" >>> header file in extcon-max3355.c. Please test it for enough time. >> >> Yes, with this file #include'd, it build fine now. >> >>>>> because include/linux/gpio/consumer.h implement the dummy function >>>>> for all gpio functions if CONFIG_GPIOLIB is disabled. >>>> >>>> Linus W. advised to #include this header explicitly -- I'll try and post. >>> >>> Don't necessary. I already updated it including the "include/linux/gpio/consumer.h". >> >> I saw that, yes. >> >>>>> For correct operation of max3355, you should add the dependency >>>>> to the extcon-max3355.c driver. This driver use the GPIO library >>>>> certainly. >>>> >>>> I disagree. The driver will just cease to load in this case. I don't see why we need such dependency. Only compilation time dependencies should be >>>> specified, I think. >>> >>> This driver have to depend on GPIOLIB. >>> Why are you disagreeing the COMPILE_TEST dependency? It is just compile test >>> without anything. >> >> I agree now. I still disagree about the gpiolib dependency though. > > If gpiolib is disabled, extcon-max3355.c might not operate it correctly. It'll just fail the probe, that's all. > Just this driver could be built without operation because gpiolib function > will not do the any behavior. devm_gpiod_get() will just fail with -ENOSYS. > I think that it is not too much problem. I should send the pull request within this week. > If you want to need more discussion of extcon-max3355.c, > I will not include it on pull request for v4.5 because there is issue. No, please include it into the pull request. MBR, Sergei -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/extcon/Kconfig b/drivers/extcon/Kconfig index ba4db7d..3d89e60 100644 --- a/drivers/extcon/Kconfig +++ b/drivers/extcon/Kconfig @@ -54,6 +54,7 @@ config EXTCON_MAX14577 config EXTCON_MAX3355 tristate "Maxim MAX3355 USB OTG EXTCON Support" + depends on GPIOLIB || COMPILE_TEST help If you say yes here you get support for the USB OTG role detection by MAX3355. The MAX3355 chip integrates a charge pump and comparators to