All of lore.kernel.org
 help / color / mirror / Atom feed
From: Marc Kleine-Budde <mkl@pengutronix.de>
To: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Cc: Oliver Hartkopp <socketcan@hartkopp.net>,
	Rong Chen <rong.a.chen@intel.com>,
	Patrick Menschel <menschel.p@posteo.de>,
	kernel test robot <lkp@intel.com>,
	kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	linux-can <linux-can@vger.kernel.org>
Subject: Re: [kbuild-all] Re: include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(struct canfd_frame, len) || offsetof(struct can_frame, data) != offsetof(struc...
Date: Mon, 29 Mar 2021 09:01:36 +0200	[thread overview]
Message-ID: <20210329070136.xbgjqc7fpuku7d2t@pengutronix.de> (raw)
In-Reply-To: <0a8e8e95-c1a2-ede6-9f87-1ab7a0a155e3@rasmusvillemoes.dk>

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

On 23.03.2021 15:00:55, Rasmus Villemoes wrote:
[...]
> So let us guess that it's the ABI choice -mabi=apcs-gnu
> 
> $ arm-linux-gnueabihf-gcc -O2 -msoft-float -mabi=apcs-gnu -Q
> --help=target | grep struct
>   -mstructure-size-boundary=            32
> 
> Bingo. (-msoft-float is also included just as in the real command line
> because gcc barfs otherwise).
> 
> Now what CONFIG_* knobs are responsible for putting -mabi=apcs-gnu in
> CFLAGS is left as an exercise for the reader. Regardless, it is not a
> bug in the compiler. The error is the assumption that this language

For the record:

If CONFIG_AEABI is not set "-mabi=apcs-gnu" is used, which leads to the
bigger structure size boundary.

| ifeq ($(CONFIG_AEABI),y)
| CFLAGS_ABI      :=-mabi=aapcs-linux -mfpu=vfp
| else
| CFLAGS_ABI      :=$(call cc-option,-mapcs-32,-mabi=apcs-gnu) $(call cc-option,-mno-thumb-interwork,)
| endif

regards,
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde           |
Embedded Linux                   | https://www.pengutronix.de  |
Vertretung West/Dortmund         | Phone: +49-231-2826-924     |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-5555 |

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

WARNING: multiple messages have this Message-ID (diff)
From: Marc Kleine-Budde <mkl@pengutronix.de>
To: kbuild-all@lists.01.org
Subject: Re: include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(struct canfd_frame, len) || offsetof(struct can_frame, data) != offsetof(struc...
Date: Mon, 29 Mar 2021 09:01:36 +0200	[thread overview]
Message-ID: <20210329070136.xbgjqc7fpuku7d2t@pengutronix.de> (raw)
In-Reply-To: <0a8e8e95-c1a2-ede6-9f87-1ab7a0a155e3@rasmusvillemoes.dk>

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

On 23.03.2021 15:00:55, Rasmus Villemoes wrote:
[...]
> So let us guess that it's the ABI choice -mabi=apcs-gnu
> 
> $ arm-linux-gnueabihf-gcc -O2 -msoft-float -mabi=apcs-gnu -Q
> --help=target | grep struct
>   -mstructure-size-boundary=            32
> 
> Bingo. (-msoft-float is also included just as in the real command line
> because gcc barfs otherwise).
> 
> Now what CONFIG_* knobs are responsible for putting -mabi=apcs-gnu in
> CFLAGS is left as an exercise for the reader. Regardless, it is not a
> bug in the compiler. The error is the assumption that this language

For the record:

If CONFIG_AEABI is not set "-mabi=apcs-gnu" is used, which leads to the
bigger structure size boundary.

| ifeq ($(CONFIG_AEABI),y)
| CFLAGS_ABI      :=-mabi=aapcs-linux -mfpu=vfp
| else
| CFLAGS_ABI      :=$(call cc-option,-mapcs-32,-mabi=apcs-gnu) $(call cc-option,-mno-thumb-interwork,)
| endif

regards,
Marc

-- 
Pengutronix e.K.                 | Marc Kleine-Budde           |
Embedded Linux                   | https://www.pengutronix.de  |
Vertretung West/Dortmund         | Phone: +49-231-2826-924     |
Amtsgericht Hildesheim, HRA 2686 | Fax:   +49-5121-206917-5555 |

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  parent reply	other threads:[~2021-03-29  7:20 UTC|newest]

Thread overview: 45+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-20 20:43 include/linux/compiler_types.h:315:38: error: call to '__compiletime_assert_536' declared with attribute error: BUILD_BUG_ON failed: offsetof(struct can_frame, len) != offsetof(struct canfd_frame, len) || offsetof(struct can_frame, data) != offsetof(struc kernel test robot
2021-03-20 20:43 ` kernel test robot
2021-03-21 14:19 ` Oliver Hartkopp
2021-03-21 14:19   ` Oliver Hartkopp
2021-03-22  8:52   ` [kbuild-all] " Rong Chen
2021-03-22  8:52     ` Rong Chen
2021-03-22 16:24     ` [kbuild-all] " Oliver Hartkopp
2021-03-22 16:24       ` Oliver Hartkopp
2021-03-23  2:54       ` [kbuild-all] " Rong Chen
2021-03-23  2:54         ` Rong Chen
2021-03-23  5:46         ` [kbuild-all] " Vincent MAILHOL
2021-03-23  5:46           ` Vincent MAILHOL
2021-03-23  6:06           ` [kbuild-all] " Rong Chen
2021-03-23  6:06             ` Rong Chen
2021-03-23  7:26             ` [kbuild-all] " Patrick Menschel
2021-03-23  7:26               ` Patrick Menschel
2021-03-23  7:34         ` [kbuild-all] " Marc Kleine-Budde
2021-03-23  7:34           ` Marc Kleine-Budde
2021-03-23  7:45           ` [kbuild-all] " Oliver Hartkopp
2021-03-23  7:45             ` Oliver Hartkopp
2021-03-23  8:32             ` [kbuild-all] " Oliver Hartkopp
2021-03-23  8:32               ` Oliver Hartkopp
2021-03-23  8:54               ` [kbuild-all] " Marc Kleine-Budde
2021-03-23  8:54                 ` Marc Kleine-Budde
2021-03-23  8:59                 ` [kbuild-all] " Rong Chen
2021-03-23  8:59                   ` Rong Chen
2021-03-23  9:35                   ` [kbuild-all] " Rong Chen
2021-03-23  9:35                     ` Rong Chen
2021-03-23 11:36             ` [kbuild-all] " Rasmus Villemoes
2021-03-23 11:36               ` Rasmus Villemoes
2021-03-23 12:49               ` [kbuild-all] " Oliver Hartkopp
2021-03-23 12:49                 ` Oliver Hartkopp
2021-03-23 14:00                 ` [kbuild-all] " Rasmus Villemoes
2021-03-23 14:00                   ` Rasmus Villemoes
2021-03-23 18:59                   ` [kbuild-all] " Oliver Hartkopp
2021-03-23 18:59                     ` Oliver Hartkopp
2021-03-23 20:54                     ` [kbuild-all] " Rasmus Villemoes
2021-03-23 20:54                       ` Rasmus Villemoes
2021-03-24  9:09                       ` [kbuild-all] " Oliver Hartkopp
2021-03-24  9:09                         ` Oliver Hartkopp
2021-03-24  9:57                         ` [kbuild-all] " Marc Kleine-Budde
2021-03-24  9:57                           ` Marc Kleine-Budde
2021-03-29  7:01                   ` Marc Kleine-Budde [this message]
2021-03-29  7:01                     ` Marc Kleine-Budde
2021-04-10 10:46                     ` itsapkreach121

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=20210329070136.xbgjqc7fpuku7d2t@pengutronix.de \
    --to=mkl@pengutronix.de \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-can@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@rasmusvillemoes.dk \
    --cc=lkp@intel.com \
    --cc=menschel.p@posteo.de \
    --cc=rong.a.chen@intel.com \
    --cc=socketcan@hartkopp.net \
    /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.