From: Arnd Bergmann <arnd@arndb.de>
To: Timur Tabi <timur@codeaurora.org>
Cc: Guenter Roeck <linux@roeck-us.net>,
linux-watchdog@vger.kernel.org,
Ashwin Chaugule <ashwin.chaugule@linaro.org>,
Vipul Gandhi <vgandhi@codeaurora.org>, Fu Wei <fu.wei@linaro.org>,
Al Stone <al.stone@linaro.org>, Wim Van Sebroeck <wim@iguana.be>,
Hanjun Guo <hanjun.guo@linaro.org>,
Graeme Gregory <graeme.gregory@linaro.org>,
linaro-acpi@lists.linaro.org
Subject: Re: [PATCH] [v2] watchdog: introduce the ARM64 SBSA watchdog driver
Date: Fri, 15 May 2015 11:16:47 +0200 [thread overview]
Message-ID: <5740260.iFKebBHUuJ@wuerfel> (raw)
In-Reply-To: <5555347D.7050106@codeaurora.org>
On Thursday 14 May 2015 18:49:17 Timur Tabi wrote:
> Guenter Roeck wrote:
> >
> > We still don't know if the registers are in host byte order or in little
> > endian
> > order. If registers are in host byte order, there is no need for a
> > conversion.
>
> Well, if I compile and boot a big-endian ARM64 kernel, then I don't
> expect the hardware devices to magically switch all their registers into
> big endian. The devices will remain little-endian.
>
> I presume that this is true on all ARM and ARM64 systems. Switching the
> CPU into big-endian mode (when it normally would run in little-endian)
> does not also switch the hardware registers.
>
> Therefore, if we want to support big-endian kernels on ARM64, then every
> readl/writel in every driver must use cpu_to_le32/etc.
>
> I think this conversation has gone off-track. I don't see how the SBSA
> watchdog device is any different from any other device on an ARM64 platform.
>
> I think it's safe to say that the endian order is not specified
> anywhere, but on my hardware, everything is little-endian.
Then please remove the double-swap. If the device works like any other
device in the system, then the byteswap that is implied by readl/writel
will do the right thing, and swapping twice will break big-endian
kernels.
Arnd
next prev parent reply other threads:[~2015-05-15 9:16 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-05-14 16:52 [PATCH] [v2] watchdog: introduce the ARM64 SBSA watchdog driver Timur Tabi
2015-05-14 20:03 ` Arnd Bergmann
2015-05-14 20:15 ` Timur Tabi
2015-05-14 20:45 ` Guenter Roeck
2015-05-14 21:03 ` Timur Tabi
2015-05-14 23:41 ` Guenter Roeck
2015-05-14 23:49 ` Timur Tabi
2015-05-15 9:16 ` Arnd Bergmann [this message]
2015-05-15 12:14 ` Timur Tabi
2015-05-15 13:20 ` [Linaro-acpi] " Arnd Bergmann
2015-05-15 16:21 ` Timur Tabi
2015-05-15 18:57 ` Arnd Bergmann
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=5740260.iFKebBHUuJ@wuerfel \
--to=arnd@arndb.de \
--cc=al.stone@linaro.org \
--cc=ashwin.chaugule@linaro.org \
--cc=fu.wei@linaro.org \
--cc=graeme.gregory@linaro.org \
--cc=hanjun.guo@linaro.org \
--cc=linaro-acpi@lists.linaro.org \
--cc=linux-watchdog@vger.kernel.org \
--cc=linux@roeck-us.net \
--cc=timur@codeaurora.org \
--cc=vgandhi@codeaurora.org \
--cc=wim@iguana.be \
/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