2022-09-13 07:15:23

by Leo Yan

[permalink] [raw]
Subject: Re: [PATCH] interconnect: qcom: Add the missing MODULE_LICENSE

Hi Yiwei,

On Tue, Sep 13, 2022 at 02:27:21PM +0800, Huang Yiwei wrote:
> Since icc-common.c can be compiled as module, add the missing
> MODULE_LICENSE to avoid compile errors.

Just curious how you can enable config INTERCONNECT_QCOM as "m"
(module)?

I checked the config INTERCONNECT_QCOM which is dependent on
INTERCONNECT, and INTERCONNECT has below dependency:

- DRM_TEGRA [=n] && HAS_IOMEM [=y] && (ARCH_TEGRA [=y] || ARM && COMPILE_TEST [=n]) && COMMON_CLK [=y] && DRM [=m] && OF [=y]
- TEGRA_MC [=n] && MEMORY [=y] && (ARCH_TEGRA [=y] || COMPILE_TEST [=n] && COMMON_CLK [=y])

Seems to me, it's impossible to enable INTERCONNECT as "m" because the
dependency ARCH_TEGRA/OF/COMMON_CLK cannot be configured as "m".

Thanks,
Leo


2022-09-13 08:41:01

by Huang Yiwei

[permalink] [raw]
Subject: Re: [PATCH] interconnect: qcom: Add the missing MODULE_LICENSE

Hi Leo,

On 9/13/2022 Tue 15:08, Leo Yan wrote:
> Hi Yiwei,
>
> On Tue, Sep 13, 2022 at 02:27:21PM +0800, Huang Yiwei wrote:
>> Since icc-common.c can be compiled as module, add the missing
>> MODULE_LICENSE to avoid compile errors.
>
> Just curious how you can enable config INTERCONNECT_QCOM as "m"
> (module)?
>
> I checked the config INTERCONNECT_QCOM which is dependent on
> INTERCONNECT, and INTERCONNECT has below dependency:
>
> - DRM_TEGRA [=n] && HAS_IOMEM [=y] && (ARCH_TEGRA [=y] || ARM && COMPILE_TEST [=n]) && COMMON_CLK [=y] && DRM [=m] && OF [=y]
> - TEGRA_MC [=n] && MEMORY [=y] && (ARCH_TEGRA [=y] || COMPILE_TEST [=n] && COMMON_CLK [=y])
>
> Seems to me, it's impossible to enable INTERCONNECT as "m" because the
> dependency ARCH_TEGRA/OF/COMMON_CLK cannot be configured as "m".
>
> Thanks,
> Leo
>
Found the problem, INTERCONNECT_QCOM is modified to tristate internally
so we can compile it as a module, and the new added icc-common.c uses
INTERCONNECT_QCOM config to compile, then cause the problem. So shall we
change INTERCONNECT_QCOM config to tristate?

Thanks,
Yiwei

2022-09-13 10:08:40

by Leo Yan

[permalink] [raw]
Subject: Re: [PATCH] interconnect: qcom: Add the missing MODULE_LICENSE

Changed to Bjorn's updated email.

On Tue, Sep 13, 2022 at 04:30:50PM +0800, Huang Yiwei wrote:
> Hi Leo,
>
> On 9/13/2022 Tue 15:08, Leo Yan wrote:
> > Hi Yiwei,
> >
> > On Tue, Sep 13, 2022 at 02:27:21PM +0800, Huang Yiwei wrote:
> > > Since icc-common.c can be compiled as module, add the missing
> > > MODULE_LICENSE to avoid compile errors.
> >
> > Just curious how you can enable config INTERCONNECT_QCOM as "m"
> > (module)?
> >
> > I checked the config INTERCONNECT_QCOM which is dependent on
> > INTERCONNECT, and INTERCONNECT has below dependency:
> >
> > - DRM_TEGRA [=n] && HAS_IOMEM [=y] && (ARCH_TEGRA [=y] || ARM && COMPILE_TEST [=n]) && COMMON_CLK [=y] && DRM [=m] && OF [=y]
> > - TEGRA_MC [=n] && MEMORY [=y] && (ARCH_TEGRA [=y] || COMPILE_TEST [=n] && COMMON_CLK [=y])
> >
> > Seems to me, it's impossible to enable INTERCONNECT as "m" because the
> > dependency ARCH_TEGRA/OF/COMMON_CLK cannot be configured as "m".
> >
> > Thanks,
> > Leo
> >
> Found the problem, INTERCONNECT_QCOM is modified to tristate internally
> so we can compile it as a module, and the new added icc-common.c uses
> INTERCONNECT_QCOM config to compile, then cause the problem.

Thanks for confirmation, Yiwei.

> So shall we change INTERCONNECT_QCOM config to tristate?

I personally think modularization is the right thing to do; to avoid
misleading you, I would leave your question to interconnect
maintainers.

Thanks,
Leo

2022-09-13 11:06:39

by Georgi Djakov

[permalink] [raw]
Subject: Re: [PATCH] interconnect: qcom: Add the missing MODULE_LICENSE

Hi Yiwei,

On 13.09.22 13:06, Leo Yan wrote:
> Changed to Bjorn's updated email.
>
> On Tue, Sep 13, 2022 at 04:30:50PM +0800, Huang Yiwei wrote:
>> Hi Leo,
>>
>> On 9/13/2022 Tue 15:08, Leo Yan wrote:
>>> Hi Yiwei,
>>>
>>> On Tue, Sep 13, 2022 at 02:27:21PM +0800, Huang Yiwei wrote:
>>>> Since icc-common.c can be compiled as module, add the missing
>>>> MODULE_LICENSE to avoid compile errors.
>>>
>>> Just curious how you can enable config INTERCONNECT_QCOM as "m"
>>> (module)?
>>>
>>> I checked the config INTERCONNECT_QCOM which is dependent on
>>> INTERCONNECT, and INTERCONNECT has below dependency:
>>>
>>> - DRM_TEGRA [=n] && HAS_IOMEM [=y] && (ARCH_TEGRA [=y] || ARM && COMPILE_TEST [=n]) && COMMON_CLK [=y] && DRM [=m] && OF [=y]
>>> - TEGRA_MC [=n] && MEMORY [=y] && (ARCH_TEGRA [=y] || COMPILE_TEST [=n] && COMMON_CLK [=y])
>>>
>>> Seems to me, it's impossible to enable INTERCONNECT as "m" because the
>>> dependency ARCH_TEGRA/OF/COMMON_CLK cannot be configured as "m".
>>>
>>> Thanks,
>>> Leo
>>>
>> Found the problem, INTERCONNECT_QCOM is modified to tristate internally
>> so we can compile it as a module, and the new added icc-common.c uses
>> INTERCONNECT_QCOM config to compile, then cause the problem.
>
> Thanks for confirmation, Yiwei.
>
>> So shall we change INTERCONNECT_QCOM config to tristate?
>
> I personally think modularization is the right thing to do; to avoid
> misleading you, I would leave your question to interconnect
> maintainers.

Thanks for clarifying! It sounds like the right approach. So this should
be a single patch that allows icc-common.c to be compiled as a module and
also adds MODULE_LICENSE where needed to avoid any compile errors.

Thanks,
Georgi