From: Harvey Harrison <harvey.harrison@gmail.com>
To: Richard Purdie <rpurdie@rpsys.net>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
Andrew Morton <akpm@linux-foundation.org>,
LKML <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] lzo: fix possible typo in decompresor
Date: Thu, 10 Apr 2008 15:22:26 -0700 [thread overview]
Message-ID: <1207866146.22001.55.camel@brick> (raw)
In-Reply-To: <1207865888.4969.103.camel@dax.rpnet.com>
On Thu, 2008-04-10 at 23:18 +0100, Richard Purdie wrote:
> On Thu, 2008-04-10 at 13:49 -0700, Linus Torvalds wrote:
> > On Thu, 10 Apr 2008, Harvey Harrison wrote:
> > >
> > > Shift of a le value seems strange, probably meant to shift the cpu-order
> > > variable as in the prvious section of the switch statement.
> >
> > Hmm. This patch looks ObviouslyCorrect(tm), but it worries me that
> > apparently the old broken code has been around since last July, and afaik
> > it can never have worked on big-endian machines.
> >
> > So did nobody ever use it, or why hasn't this ever triggered? How did you
> > find this? A sparse warning?
>
> The heaviest users of the lzo code I know of are little-endian ARM
> devices through jffs2. When the code was merged there was a lot of
> discussion about the best way to handle the endian issues and unaligned
> accesses and whilst I seem to remember someone posting big-endian test
> results it could have been before some of the later changes were made.
>
> So yes its possible its not been run on BE until now or that isn't a
> common code path. I've checked this against the external LZO library its
> based on and the patch is correct
>
> Acked-by: Richard Purdie <rpurdie@rpsys.net>
>
This is one of the reasons I thought about for adding the new api, the
bracketing is just too easy to get wrong when you throw
get/put_unaligned into the mix.
Harvey
prev parent reply other threads:[~2008-04-10 22:22 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-10 20:38 [PATCH] lzo: fix possible typo in decompresor Harvey Harrison
2008-04-10 20:49 ` Linus Torvalds
2008-04-10 20:52 ` Harvey Harrison
2008-04-10 22:18 ` Richard Purdie
2008-04-10 22:22 ` Harvey Harrison [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=1207866146.22001.55.camel@brick \
--to=harvey.harrison@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rpurdie@rpsys.net \
--cc=torvalds@linux-foundation.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