linux-sh.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Paul Mundt <lethal@linux-sh.org>
To: linux-sh@vger.kernel.org
Subject: Re: [RFC/PATCH] sh: Remove cast of atomic_t in ATOMIC_INIT macro
Date: Mon, 23 Apr 2012 06:52:58 +0000	[thread overview]
Message-ID: <20120423065258.GH22189@linux-sh.org> (raw)
In-Reply-To: <1335149312-1564-1-git-send-email-nobuhiro.iwamatsu.yj@renesas.com>

On Mon, Apr 23, 2012 at 11:48:32AM +0900, Nobuhiro Iwamatsu wrote:
> Hi,
> 
> By the update of the trace system (enable CONFIG_TRACING), trace build is not made in SH.
> This is macro of trace, and ATOMIC_INIT is used, but becomes the build error with an initialization code.
> 
> ----
> include/trace/events/oom.h:8:13: error: initializer element is not constant
> include/trace/events/oom.h:8:13: error: (near initialization for '__tracepoint_oom_score_adj_update')
> include/trace/events/oom.h:8:13: error: initializer element is not constant
> include/trace/events/oom.h:8:13: error: (near initialization for '__tracepoint_oom_score_adj_update.key')
> ----
> 
> This is caused by that the cast to atomic_t is performed by ATOMIC_INIT of SH.
> However, at almost all the architecture, the cast to atomic_t is not performed by ATOMIC_INIT.

And on other architectures it is. We don't specifically have any need for
using the cast, so dropping it is probably fine, but there are other
architectures that will either have to do the same or the tracing change
that introduced the build failure has to be rethought.

  reply	other threads:[~2012-04-23  6:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-23  2:48 [RFC/PATCH] sh: Remove cast of atomic_t in ATOMIC_INIT macro Nobuhiro Iwamatsu
2012-04-23  6:52 ` Paul Mundt [this message]
2012-04-25  3:11 ` Nobuhiro Iwamatsu
2012-04-27  0:35 ` Paul Mundt
2012-04-27  2:11 ` Simon Horman

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=20120423065258.GH22189@linux-sh.org \
    --to=lethal@linux-sh.org \
    --cc=linux-sh@vger.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;
as well as URLs for NNTP newsgroup(s).