All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: Error when compiling kernel module - Re: More power management updates for v5.17-rc1
       [not found] <CAGsy+6s36Vf+n9cMbis2a=A4=dUNvsbda7K7rszHikq_HGOAtA@mail.gmail.com>
@ 2022-02-21 16:18 ` Rafael J. Wysocki
  2022-02-21 16:29   ` Paul Cercueil
  0 siblings, 1 reply; 4+ messages in thread
From: Rafael J. Wysocki @ 2022-02-21 16:18 UTC (permalink / raw)
  To: eh kernel; +Cc: Rafael J. Wysocki, Linux Kernel Mailing List, Paul Cercueil

On Mon, Feb 21, 2022 at 1:15 PM eh kernel <ehkernel@gmail.com> wrote:
>
> Hi Rafael,
>
> I now get an error when compiling the kernel module (out-of-tree) with the new PM macros.
>
> /home/ubuntu/pressure/bmp280-core.c:1163:28: error: expected ‘)’ before ‘(’ token
>  1163 |      bmp280_runtime_resume, NULL);

Which of the macros has triggered this error?

>       |                            ^
>       |                            )
> /home/ubuntu/pressure/bmp280-core.c:1149:12: warning: ‘bmp280_runtime_resume’ defined but not used [-Wunused-function]
>  1149 | static int bmp280_runtime_resume(struct device *dev)
>       |            ^~~~~~~~~~~~~~~~~~~~~
> /home/ubuntu/pressure/bmp280-core.c:1141:12: warning: ‘bmp280_runtime_suspend’ defined but not used [-Wunused-function]
>  1141 | static int bmp280_runtime_suspend(struct device *dev)
>       |            ^~~~~~~~~~~~~~~~~~~~~~
>
> When I revert to the old file without the new PM macros it works just fine. Do I need to take some extra parameters into account now with the new format when compiling?
>

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

* Re: Error when compiling kernel module - Re: More power management updates for v5.17-rc1
  2022-02-21 16:18 ` Error when compiling kernel module - Re: More power management updates for v5.17-rc1 Rafael J. Wysocki
@ 2022-02-21 16:29   ` Paul Cercueil
  2022-02-21 16:44     ` Rafael J. Wysocki
  0 siblings, 1 reply; 4+ messages in thread
From: Paul Cercueil @ 2022-02-21 16:29 UTC (permalink / raw)
  To: Rafael J. Wysocki; +Cc: eh kernel, Linux Kernel Mailing List

Hi Rafael,

Le lun., févr. 21 2022 at 17:18:51 +0100, Rafael J. Wysocki 
<rafael@kernel.org> a écrit :
> On Mon, Feb 21, 2022 at 1:15 PM eh kernel <ehkernel@gmail.com> wrote:
>> 
>>  Hi Rafael,
>> 
>>  I now get an error when compiling the kernel module (out-of-tree) 
>> with the new PM macros.
>> 
>>  /home/ubuntu/pressure/bmp280-core.c:1163:28: error: expected 
>> ‘)’ before ‘(’ token
>>   1163 |      bmp280_runtime_resume, NULL);
> 
> Which of the macros has triggered this error?

I think the bug was introduced by 23a133c1ba67 ("iio:adc:ab8500: Switch 
from CONFIG_PM guards to pm_ptr() etc")

The macro takes 4 arguments and its first parameter should be the 
dev_pm_ops name, so "ab8500_gpadc_pm_ops".

It slipped during review.

Cheers,
-Paul

> 
>>        |                            ^
>>        |                            )
>>  /home/ubuntu/pressure/bmp280-core.c:1149:12: warning: 
>> ‘bmp280_runtime_resume’ defined but not used [-Wunused-function]
>>   1149 | static int bmp280_runtime_resume(struct device *dev)
>>        |            ^~~~~~~~~~~~~~~~~~~~~
>>  /home/ubuntu/pressure/bmp280-core.c:1141:12: warning: 
>> ‘bmp280_runtime_suspend’ defined but not used [-Wunused-function]
>>   1141 | static int bmp280_runtime_suspend(struct device *dev)
>>        |            ^~~~~~~~~~~~~~~~~~~~~~
>> 
>>  When I revert to the old file without the new PM macros it works 
>> just fine. Do I need to take some extra parameters into account now 
>> with the new format when compiling?
>> 



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

* Re: Error when compiling kernel module - Re: More power management updates for v5.17-rc1
  2022-02-21 16:29   ` Paul Cercueil
@ 2022-02-21 16:44     ` Rafael J. Wysocki
  2022-02-23 11:45       ` Paul Cercueil
  0 siblings, 1 reply; 4+ messages in thread
From: Rafael J. Wysocki @ 2022-02-21 16:44 UTC (permalink / raw)
  To: Paul Cercueil; +Cc: Rafael J. Wysocki, eh kernel, Linux Kernel Mailing List

On Mon, Feb 21, 2022 at 5:29 PM Paul Cercueil <paul@crapouillou.net> wrote:
>
> Hi Rafael,
>
> Le lun., févr. 21 2022 at 17:18:51 +0100, Rafael J. Wysocki
> <rafael@kernel.org> a écrit :
> > On Mon, Feb 21, 2022 at 1:15 PM eh kernel <ehkernel@gmail.com> wrote:
> >>
> >>  Hi Rafael,
> >>
> >>  I now get an error when compiling the kernel module (out-of-tree)
> >> with the new PM macros.
> >>
> >>  /home/ubuntu/pressure/bmp280-core.c:1163:28: error: expected
> >> ‘)’ before ‘(’ token
> >>   1163 |      bmp280_runtime_resume, NULL);
> >
> > Which of the macros has triggered this error?
>
> I think the bug was introduced by 23a133c1ba67 ("iio:adc:ab8500: Switch
> from CONFIG_PM guards to pm_ptr() etc")
>
> The macro takes 4 arguments and its first parameter should be the
> dev_pm_ops name, so "ab8500_gpadc_pm_ops".
>
> It slipped during review.

I see.

Can you fix this, please?

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

* Re: Error when compiling kernel module - Re: More power management updates for v5.17-rc1
  2022-02-21 16:44     ` Rafael J. Wysocki
@ 2022-02-23 11:45       ` Paul Cercueil
  0 siblings, 0 replies; 4+ messages in thread
From: Paul Cercueil @ 2022-02-23 11:45 UTC (permalink / raw)
  To: Rafael J. Wysocki; +Cc: eh kernel, Linux Kernel Mailing List, Jonathan Cameron

Hi Rafael,

Le lun., févr. 21 2022 at 17:44:28 +0100, Rafael J. Wysocki 
<rafael@kernel.org> a écrit :
> On Mon, Feb 21, 2022 at 5:29 PM Paul Cercueil <paul@crapouillou.net> 
> wrote:
>> 
>>  Hi Rafael,
>> 
>>  Le lun., févr. 21 2022 at 17:18:51 +0100, Rafael J. Wysocki
>>  <rafael@kernel.org> a écrit :
>>  > On Mon, Feb 21, 2022 at 1:15 PM eh kernel <ehkernel@gmail.com> 
>> wrote:
>>  >>
>>  >>  Hi Rafael,
>>  >>
>>  >>  I now get an error when compiling the kernel module 
>> (out-of-tree)
>>  >> with the new PM macros.
>>  >>
>>  >>  /home/ubuntu/pressure/bmp280-core.c:1163:28: error: expected
>>  >> ‘)’ before ‘(’ token
>>  >>   1163 |      bmp280_runtime_resume, NULL);
>>  >
>>  > Which of the macros has triggered this error?
>> 
>>  I think the bug was introduced by 23a133c1ba67 ("iio:adc:ab8500: 
>> Switch
>>  from CONFIG_PM guards to pm_ptr() etc")
>> 
>>  The macro takes 4 arguments and its first parameter should be the
>>  dev_pm_ops name, so "ab8500_gpadc_pm_ops".
>> 
>>  It slipped during review.
> 
> I see.
> 
> Can you fix this, please?

Jonathan already fixed it in his tree.

Cheers,
-Paul



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

end of thread, other threads:[~2022-02-23 11:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAGsy+6s36Vf+n9cMbis2a=A4=dUNvsbda7K7rszHikq_HGOAtA@mail.gmail.com>
2022-02-21 16:18 ` Error when compiling kernel module - Re: More power management updates for v5.17-rc1 Rafael J. Wysocki
2022-02-21 16:29   ` Paul Cercueil
2022-02-21 16:44     ` Rafael J. Wysocki
2022-02-23 11:45       ` Paul Cercueil

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.