From: Ingo Molnar <mingo@kernel.org>
To: Andy Shevchenko <andy.shevchenko@gmail.com>
Cc: Saidgani Musaev <cpu808694@gmail.com>,
"H. Peter Anvin" <hpa@zytor.com>,
Thomas Gleixner <tglx@linutronix.de>,
x86@kernel.org,
Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] arch/x86/boot: sizeof macro
Date: Fri, 29 Dec 2017 20:46:14 +0100 [thread overview]
Message-ID: <20171229194614.3iku5zg5oglrd2cl@gmail.com> (raw)
In-Reply-To: <CAHp75Vc0V_ZVsPzhE=78y9gZ91=sE1hXR_98d9-1TNcTHLy0SQ@mail.gmail.com>
* Andy Shevchenko <andy.shevchenko@gmail.com> wrote:
> On Fri, Dec 29, 2017 at 8:30 PM, Saidgani Musaev <cpu808694@gmail.com> wrote:
>
> No changelog, no explanation why...
> No SoB tag...
>
> > - ireg.cx = sizeof buf;
> > + ireg.cx = sizeof(buf);
>
> sizeof is operator, not a function.
> So, what are you trying to achieve?
That's true, but in the kernel coding style we use it as a function:
triton:~/tip> git grep 'sizeof(' | wc -l
116570
triton:~/tip> git grep 'sizeof [:alnum:]' | wc -l
177
Thanks,
Ingo
next prev parent reply other threads:[~2017-12-29 19:46 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-29 18:30 [PATCH] arch/x86/boot: sizeof macro Saidgani Musaev
2017-12-29 18:41 ` Andy Shevchenko
2017-12-29 19:34 ` hacku
2017-12-29 19:46 ` Ingo Molnar [this message]
2017-12-31 11:48 ` Andy Shevchenko
2017-12-31 16:33 ` Joe Perches
2018-01-06 11:50 ` Ingo Molnar
2018-01-08 21:44 ` H. Peter Anvin
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=20171229194614.3iku5zg5oglrd2cl@gmail.com \
--to=mingo@kernel.org \
--cc=andy.shevchenko@gmail.com \
--cc=cpu808694@gmail.com \
--cc=hpa@zytor.com \
--cc=linux-kernel@vger.kernel.org \
--cc=tglx@linutronix.de \
--cc=x86@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