mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Cercueil <paul@crapouillou.net>
To: "Rafael J. Wysocki" <rafael@kernel.org>
Cc: eh kernel <ehkernel@gmail.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: Error when compiling kernel module - Re: More power management updates for v5.17-rc1
Date: Mon, 21 Feb 2022 16:29:19 +0000	[thread overview]
Message-ID: <VSXN7R.644PDRMKJL992@crapouillou.net> (raw)
In-Reply-To: <CAJZ5v0iNLXVAR8fG-gjnRP4BSwReL1sZ9XiLHvO+YVKFJFjGOQ@mail.gmail.com>

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?
>> 



  reply	other threads:[~2022-02-21 16:29 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [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 [this message]
2022-02-21 16:44     ` Rafael J. Wysocki
2022-02-23 11:45       ` Paul Cercueil

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=VSXN7R.644PDRMKJL992@crapouillou.net \
    --to=paul@crapouillou.net \
    --cc=ehkernel@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rafael@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®