Linux MIPS Architecture development
 help / color / mirror / Atom feed
From: Ralf Baechle <ralf@linux-mips.org>
To: "Nicholas A. Bellinger" <nab@linux-iscsi.org>
Cc: kbuild test robot <fengguang.wu@intel.com>,
	kbuild-all@01.org, target-devel <target-devel@vger.kernel.org>,
	linux-mips@linux-mips.org
Subject: Re: [target:for-next 51/51] ERROR: "__cmpxchg_called_with_bad_pointer" undefined!
Date: Tue, 4 Feb 2014 19:27:25 +0100	[thread overview]
Message-ID: <20140204182725.GF19285@linux-mips.org> (raw)
In-Reply-To: <1390989698.17325.73.camel@haakon3.risingtidesystems.com>

On Wed, Jan 29, 2014 at 02:01:38AM -0800, Nicholas A. Bellinger wrote:

> On Wed, 2014-01-29 at 14:51 +0800, kbuild test robot wrote:
> > tree:   git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending.git for-next
> > head:   7769401d351d54d5cbcb6400ec60c0b916e87a7e
> > commit: 7769401d351d54d5cbcb6400ec60c0b916e87a7e [51/51] target: Fix percpu_ref_put race in transport_lun_remove_cmd
> > config: make ARCH=mips allmodconfig
> > 
> > All error/warnings:
> > 
> > >> ERROR: "__cmpxchg_called_with_bad_pointer" undefined!
> > 
> 
> So MIPS doesn't like typedef bool as 1-byte char being used for cmpxchg
> -> ll/sc instructions..
> 
> Fixing this up now by making se_cmd->lun_ref_active use a single word
> instead.

Thanks, looking good.

Note that this is a hardware restriction on LL/SC rsp. LLD/SCD which only
operate on natually aligned four rsp. eight byte operands.  Could fixed
but would slow down and inflate every invocation of cmpxchg() which is
currently an inline function and I feel a bit uneasy about hardware
behaviour when mixing LL/SC rsp. LLD/SCD with conventional loads and
stores.

  Ralf

      reply	other threads:[~2014-02-04 18:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <52e8a4ef.ROAJSlpOaZtBxfoG%fengguang.wu@intel.com>
2014-01-29 10:01 ` [target:for-next 51/51] ERROR: "__cmpxchg_called_with_bad_pointer" undefined! Nicholas A. Bellinger
2014-02-04 18:27   ` Ralf Baechle [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=20140204182725.GF19285@linux-mips.org \
    --to=ralf@linux-mips.org \
    --cc=fengguang.wu@intel.com \
    --cc=kbuild-all@01.org \
    --cc=linux-mips@linux-mips.org \
    --cc=nab@linux-iscsi.org \
    --cc=target-devel@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