linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Baruch Siach <baruch@tkos.co.il>
To: Linus Walleij <linus.walleij@linaro.org>
Cc: "linux-gpio@vger.kernel.org" <linux-gpio@vger.kernel.org>,
	linux-xtensa@linux-xtensa.org
Subject: Re: [PATCH] gpio: xtensa: fix build when XCHAL_HAVE_CP is 0
Date: Thu, 23 Jan 2014 10:59:57 +0200	[thread overview]
Message-ID: <20140123085957.GC12751@tarshish> (raw)
In-Reply-To: <CACRpkdaGjr2CdHkQcv+L1HoGL16Eef0r7T2ru=1giw31_Bu4bA@mail.gmail.com>

Hi Linus,

On Thu, Jan 23, 2014 at 09:46:42AM +0100, Linus Walleij wrote:
> On Thu, Jan 23, 2014 at 7:50 AM, Baruch Siach <baruch@tkos.co.il> wrote:
> > In xtensa coprocessors may exist without coprocessor context, i.e. they 
> > cannot
> > be disabled/enabled. In this case the RSR_CPENABLE/WSR_CPENABLE are undefined,
> > thus breaking the build. Fix the build by adding dummy versions of
> > enable_cp/disable_cp in this case.
> >
> > Reported-by: Fengguang Wu <fengguang.wu@intel.com>
> > Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> 
> Patch applied for fixes, but I really don't like this compile-time
> thing. It'd be better if your Xtensa code would adjust to different
> hardware at runtime rather than compile time. This is the overall
> kernel design pattern these days AFICT.

We are talking about Xtensa here, not ARM. Different Xtensa variants are 
binary incompatible from each other is some very fundamental ways. In most 
cases you even need a different toolchain for each variant. Given that, I'm 
not sure that runtime hardware check is worth it, or even possible is some 
cases.

baruch

-- 
     http://baruch.siach.name/blog/                  ~. .~   Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
   - baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -

      reply	other threads:[~2014-01-23  9:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-01-23  6:50 [PATCH] gpio: xtensa: fix build when XCHAL_HAVE_CP is 0 Baruch Siach
2014-01-23  8:46 ` Linus Walleij
2014-01-23  8:59   ` Baruch Siach [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=20140123085957.GC12751@tarshish \
    --to=baruch@tkos.co.il \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-xtensa@linux-xtensa.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).