From: Johannes Berg <johannes@sipsolutions.net>
To: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: linux-next@vger.kernel.org, linux-kernel@vger.kernel.org,
Heikki Krogerus <heikki.krogerus@linux.intel.com>
Subject: Re: linux-next: build failure after merge of the mac80211-next tree
Date: Wed, 24 Feb 2016 09:12:41 +0100 [thread overview]
Message-ID: <1456301561.2050.2.camel@sipsolutions.net> (raw)
In-Reply-To: <20160224115927.3fa9161e@canb.auug.org.au>
Hi Stephen,
> [...]
> include/linux/bug.h:74:2: note: in expansion of macro
> 'BUILD_BUG_ON_MSG'
> BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
> ^
> net/rfkill/core.c:647:2: note: in expansion of macro 'BUILD_BUG_ON'
> BUILD_BUG_ON(!rfkill_types[NUM_RFKILL_TYPES - 1]);
> ^
>
> Caused by commit
>
> 1f86443b4ffe ("net: rfkill: add rfkill_find_type function")
Thanks for the heads-up.
> Maybe the compiler version matters? I am using gcc v5.2.0.
Hm. I'm using Debian 5.3.1-8.
> Though, it seems to be that "!rfkill_types[NUM_RFKILL_TYPES - 1]" is
> not a constant expression since
>
> static const char *rfkill_types[NUM_RFKILL_TYPES]
>
> does not stop "rfkill_types[NUM_RFKILL_TYPES - 1]" being modified at
> run time. I think that you might need:
>
> static const char * const rfkill_types[NUM_RFKILL_TYPES]
That's true, but since I can't test it I'll just solve this
differently. We'll never be able to insert anything into the middle, so
we can also just BUILD_BUG_ON() the ARRAY_SIZE() and do the code a bit
differently.
Thanks,
johannes
next prev parent reply other threads:[~2016-02-24 8:12 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-24 0:59 linux-next: build failure after merge of the mac80211-next tree Stephen Rothwell
2016-02-24 8:12 ` Johannes Berg [this message]
2017-12-12 1:58 Stephen Rothwell
2017-12-12 8:46 ` Johannes Berg
[not found] ` <1513068419.26976.86.camel-cdvu00un1VgdHxzADdlk8Q@public.gmane.org>
2017-12-12 8:59 ` Toke Høiland-Jørgensen
2017-12-12 11:45 ` Kalle Valo
2017-12-12 13:24 ` Toke Høiland-Jørgensen
2020-04-28 2:29 Stephen Rothwell
2020-04-28 7:01 ` Johannes Berg
2020-04-28 7:25 ` Sergey Matyukevich
2020-04-28 7:24 ` Johannes Berg
2020-04-28 7:45 ` Sergey Matyukevich
2020-04-28 7:46 ` Johannes Berg
2020-04-28 8:10 ` Sergey Matyukevich
2020-11-11 1:24 Stephen Rothwell
2021-12-21 0:50 Stephen Rothwell
2021-12-21 11:02 ` Johannes Berg
2021-12-21 11:15 ` Stephen Rothwell
2021-12-21 11:17 ` Johannes Berg
2021-12-21 12:31 ` Kalle Valo
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=1456301561.2050.2.camel@sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=heikki.krogerus@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-next@vger.kernel.org \
--cc=sfr@canb.auug.org.au \
/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;
as well as URLs for NNTP newsgroup(s).