All of lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Sandeen <sandeen@sandeen.net>
To: xfs-masters@oss.sgi.com
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>, Christoph Hellwig <hch@lst.de>,
	xfs@oss.sgi.com, johannes@sipsolutions.net,
	linux-kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [xfs-masters] Re: filesystem corruption on xfs after	2.6.25-rc1 (bisected, powerpc related?)
Date: Tue, 26 Feb 2008 12:05:59 -0800	[thread overview]
Message-ID: <47C47127.7040700@sandeen.net> (raw)
In-Reply-To: <20080226114419.GA5353@soziologie.ch>

Gaudenz Steinlin wrote:
> On Tue, Feb 26, 2008 at 01:13:56AM +0100, Rafael J. Wysocki wrote:
>> On Tuesday, 26 of February 2008, Christoph Hellwig wrote:
>>> On Tue, Feb 26, 2008 at 12:52:56AM +0100, Rafael J. Wysocki wrote:
>>>>> I'm not suggesting a partial revert; I just wonder which part of the
>>>>> change is causing the problem, as part of the debugging process.
> 
> I debuged this a bit further by testing the 4 changed functions
> individually. The problem only occurs with the new version of
> xfs_lowbit64. 

FWIW, Dave & I did some testing/debugging on 32-bit powerpc, and it is
indeed only xfs_lowbit64 which is doing the wrong thing on that arch,
because generic find_next_bit is doing the wrong thing on big-endian
32-bit systems, for sizes > 32 bits, near as I can tell.

Rather than reverting it all, I think just changing xfs_lowbit64 back to:

int
xfs_lowbit64(
       __uint64_t      v)
{
       __uint32_t      w = (__uint32_t)v;
       int             n = 0;

       if (w) {        /* lower bits */
               n = ffs(w);
       } else {        /* upper bits */
               w = (__uint32_t)(v >> 32);
               if (w && (n = ffs(w)))
                       n += 32;
       }
       return n - 1;
}

for now should fix it (this is essentially just ffs64())

-Eric

  parent reply	other threads:[~2008-02-26 20:06 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-25 11:23 filesystem corruption on xfs after 2.6.25-rc1 (bisected, powerpc related?) Gaudenz Steinlin
2008-02-25 11:34 ` Johannes Berg
2008-02-25 18:15 ` [xfs-masters] " Eric Sandeen
2008-02-25 23:42   ` Rafael J. Wysocki
2008-02-25 23:48     ` Eric Sandeen
2008-02-25 23:52       ` Rafael J. Wysocki
2008-02-25 23:57         ` [xfs-masters] " Christoph Hellwig
2008-02-26  0:13           ` Rafael J. Wysocki
2008-02-26  7:34             ` Gaudenz Steinlin
2008-02-26 11:44             ` Gaudenz Steinlin
2008-02-26 18:11               ` Johannes Berg
2008-02-28 14:40                 ` Eric Sandeen
2008-02-26 20:05               ` Eric Sandeen [this message]
2008-02-26 20:59                 ` Mark Goodwin

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=47C47127.7040700@sandeen.net \
    --to=sandeen@sandeen.net \
    --cc=hch@lst.de \
    --cc=johannes@sipsolutions.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rjw@sisk.pl \
    --cc=xfs-masters@oss.sgi.com \
    --cc=xfs@oss.sgi.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.