public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Trond Myklebust <trond.myklebust@fys.uio.no>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: andreas.helke@lionbioscience.com (Andreas Helke),
	linux-kernel@vger.kernel.org, nfs@sourceforge.net,
	sg_info@lionbioscience.com, kirschh@lionbioscienc.com
Subject: Re: :Redhat [Bug 30944] - Kernel 2.4.0 and Kernel 2.2.18: with some programs
Date: 08 Mar 2001 20:49:00 +0100	[thread overview]
Message-ID: <shsy9ug3utv.fsf@charged.uio.no> (raw)
In-Reply-To: <E14ahiC-0001JG-00@the-village.bc.nu>
In-Reply-To: Alan Cox's message of "Wed, 7 Mar 2001 17:26:54 +0000 (GMT)"

>>>>> " " == Alan Cox <alan@lxorguk.ukuu.org.uk> writes:

     > Irix at least used to have an export option to do mappings to
     > keep clients that had 32/64bit inode problems happy. Do those
     > help ?

No. The problem here is a Linux one: NFS uses 32/64-bit unsigned
cookies, whereas glibc expects 64-bit *signed* offsets. Even with the
'32bitclients' export option, IRIX spits out cookies such as
'0xfeebdaed'. These confuse glibc because the VFS exports most of them
as 32-bit offsets that are sign-extended to 64-bits (the one exception
to this rule being the last dirent in the series which gets filled
directly with the 64-bit file->f_pos).

My last patch for this simply ensures that the NFS layer does a
pseudo-'64-bit sign extension' on such cookies:

   cookie --> (0xffffffff00000000 ^ cookie)

This mimics what happens in filldir64() for all cookies, and is of
course reversible due to the use of xor.

I've been testing it out at Connectathon, and it does indeed seem to
work as expected...

Cheers,
  Trond

      parent reply	other threads:[~2001-03-08 19:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-03-07 13:39 :Redhat [Bug 30944] - Kernel 2.4.0 and Kernel 2.2.18: with some programs one file of each directory of NFS shares served by Irix 6.5.9f (and Irix 6.5.8) is missing in directory listings Andreas Helke
2001-03-07 17:26 ` :Redhat [Bug 30944] - Kernel 2.4.0 and Kernel 2.2.18: with some programs Alan Cox
2001-03-07 18:00   ` [NFS] " David Rees
2001-03-08 19:49   ` Trond Myklebust [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=shsy9ug3utv.fsf@charged.uio.no \
    --to=trond.myklebust@fys.uio.no \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=andreas.helke@lionbioscience.com \
    --cc=kirschh@lionbioscienc.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nfs@sourceforge.net \
    --cc=sg_info@lionbioscience.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox