public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Joe Simmons-Talbott <joetalbott@gmail.com>
To: Andy Whitcroft <apw@canonical.com>, Joe Perches <joe@perches.com>,
	Dwaipayan Ray <dwaipayanray1@gmail.com>,
	Lukas Bulwahn <lukas.bulwahn@gmail.com>,
	linux-kernel@vger.kernel.org
Subject: Re: checkpatch.pl bug for EXPORT_SYMBOL when struct initialization follows define
Date: Thu, 18 Aug 2022 10:54:29 -0400	[thread overview]
Message-ID: <Yv5Spab6mC0U5w/v@spruce> (raw)
In-Reply-To: <Yrt8XgMe+mMIlHxM@spruce>

On Tue, Jun 28, 2022 at 06:10:41PM -0400, Joe Simmons-Talbott wrote:
> I believe I've found a bug in checkpatch.pl where an EXPORT_SYMBOL for
> an initialized struct following a simple #define without an intervening
> blank line falsely reports that EXPORT_SYMBOL doesn't follow the symbol
> definition.  Here's an example:
> 
> 	#define SOMETHING_ELSE 1
> 	struct blah foo = {
> 		.a = 1
> 	};
> 	EXPORT_SYMBOL(foo);
> 
> You can see from the debug print that the full statement has not been
> identified.
> 
> 	FOO A<+EXPORT_SYMBOL(foo);> stat<+      .a = 1
> 	 };> name<foo>
> 
> Unfortunately my perl skills were not sufficient to find a fix.

I created the following BZ https://bugzilla.kernel.org/show_bug.cgi?id=216374

Thanks,
Joe

      reply	other threads:[~2022-08-18 14:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-28 22:10 checkpatch.pl bug for EXPORT_SYMBOL when struct initialization follows define Joe Simmons-Talbott
2022-08-18 14:54 ` Joe Simmons-Talbott [this message]

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=Yv5Spab6mC0U5w/v@spruce \
    --to=joetalbott@gmail.com \
    --cc=apw@canonical.com \
    --cc=dwaipayanray1@gmail.com \
    --cc=joe@perches.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lukas.bulwahn@gmail.com \
    /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