All of lore.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: kernel test robot <lkp@intel.com>
Cc: Arnd Bergmann <arnd@arndb.de>,
	llvm@lists.linux.dev, kbuild-all@lists.01.org,
	 Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Masahiro Yamada <masahiroy@kernel.org>,
	 Alex Shi <alexs@kernel.org>,
	Nick Desaulniers <ndesaulniers@google.com>,
	 Miguel Ojeda <ojeda@kernel.org>,
	Nathan Chancellor <nathan@kernel.org>
Subject: Re: drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit declaration of function 'LOCHNAGAR1_' is invalid in C99
Date: Fri, 8 Apr 2022 14:45:15 +0200	[thread overview]
Message-ID: <CAK8P3a2EDu20VNze0r4F6VQ6uxqCYQGo-Dcta6THFqPuyJ81uw@mail.gmail.com> (raw)
In-Reply-To: <202204081729.f4cgbHob-lkp@intel.com>

On Fri, Apr 8, 2022 at 12:02 PM kernel test robot <lkp@intel.com> wrote:
> All errors (new ones prefixed by >>):
>
>    drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: pasting formed 'LOCHNAGAR1_(', an invalid preprocessing token
>    LN1_PIN_GPIO(CDC_RESET,    "codec-reset",    RST,      CDC_RESET,    1);
>    ^
>    drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: expanded from macro 'LN1_PIN_GPIO'
>            LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
>            ^
>    drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:63: note: expanded from macro 'LN_PIN_GPIO'
>            .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
>                                                                         ^
> >> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit declaration of function 'LOCHNAGAR1_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]

I have checked this one, and it looks like this is not a regression.
lkp flags it because the error
message changed: with --std=gnu89, the output was

rivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit
declaration of function 'LOCHNAGAR1_' is invalid in C99
[-Werror,-Wimplicit-function-declaration]

The problem is unrelated to my patch, apparently the global macro named 'RES'
on this platform gets in the way, and removing it fixes the build:

--- a/arch/mips/include/asm/mach-rc32434/rb.h
+++ b/arch/mips/include/asm/mach-rc32434/rb.h
@@ -10,7 +10,6 @@
 #define REGBASE                0x18000000
 #define IDT434_REG_BASE ((volatile void *) KSEG1ADDR(REGBASE))
 #define UART0BASE      0x58000
-#define RST            (1 << 15)
 #define DEV0BASE       0x010000
 #define DEV0MASK       0x010004
 #define DEV0C          0x010008

        Arnd

WARNING: multiple messages have this Message-ID (diff)
From: Arnd Bergmann <arnd@arndb.de>
To: kbuild-all@lists.01.org
Subject: Re: drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit declaration of function 'LOCHNAGAR1_' is invalid in C99
Date: Fri, 08 Apr 2022 14:45:15 +0200	[thread overview]
Message-ID: <CAK8P3a2EDu20VNze0r4F6VQ6uxqCYQGo-Dcta6THFqPuyJ81uw@mail.gmail.com> (raw)
In-Reply-To: <202204081729.f4cgbHob-lkp@intel.com>

[-- Attachment #1: Type: text/plain, Size: 1808 bytes --]

On Fri, Apr 8, 2022 at 12:02 PM kernel test robot <lkp@intel.com> wrote:
> All errors (new ones prefixed by >>):
>
>    drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: pasting formed 'LOCHNAGAR1_(', an invalid preprocessing token
>    LN1_PIN_GPIO(CDC_RESET,    "codec-reset",    RST,      CDC_RESET,    1);
>    ^
>    drivers/pinctrl/cirrus/pinctrl-lochnagar.c:67:2: note: expanded from macro 'LN1_PIN_GPIO'
>            LN_PIN_GPIO(1, ID, NAME, REG, SHIFT, INVERT)
>            ^
>    drivers/pinctrl/cirrus/pinctrl-lochnagar.c:52:63: note: expanded from macro 'LN_PIN_GPIO'
>            .name = NAME, .type = LN_PTYPE_GPIO, .reg = LOCHNAGAR##REV##_##REG, \
>                                                                         ^
> >> drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit declaration of function 'LOCHNAGAR1_' is invalid in C99 [-Werror,-Wimplicit-function-declaration]

I have checked this one, and it looks like this is not a regression.
lkp flags it because the error
message changed: with --std=gnu89, the output was

rivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit
declaration of function 'LOCHNAGAR1_' is invalid in C99
[-Werror,-Wimplicit-function-declaration]

The problem is unrelated to my patch, apparently the global macro named 'RES'
on this platform gets in the way, and removing it fixes the build:

--- a/arch/mips/include/asm/mach-rc32434/rb.h
+++ b/arch/mips/include/asm/mach-rc32434/rb.h
@@ -10,7 +10,6 @@
 #define REGBASE                0x18000000
 #define IDT434_REG_BASE ((volatile void *) KSEG1ADDR(REGBASE))
 #define UART0BASE      0x58000
-#define RST            (1 << 15)
 #define DEV0BASE       0x010000
 #define DEV0MASK       0x010004
 #define DEV0C          0x010008

        Arnd

  reply	other threads:[~2022-04-08 12:45 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-08 10:02 drivers/pinctrl/cirrus/pinctrl-lochnagar.c:200:1: error: implicit declaration of function 'LOCHNAGAR1_' is invalid in C99 kernel test robot
2022-04-08 12:45 ` Arnd Bergmann [this message]
2022-04-08 12:45   ` Arnd Bergmann

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=CAK8P3a2EDu20VNze0r4F6VQ6uxqCYQGo-Dcta6THFqPuyJ81uw@mail.gmail.com \
    --to=arnd@arndb.de \
    --cc=alexs@kernel.org \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=llvm@lists.linux.dev \
    --cc=masahiroy@kernel.org \
    --cc=nathan@kernel.org \
    --cc=ndesaulniers@google.com \
    --cc=ojeda@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 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.