From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jan Hudec Subject: Re: which dentry a page belongs to Date: Sat, 24 Apr 2004 10:53:54 +0200 Sender: linux-fsdevel-owner@vger.kernel.org Message-ID: <20040424085354.GC7119@vagabond> References: <1082732223.1943.11.camel@zaphod> <20040423151458.GC6300@mail.shareable.org> <1082734938.1943.26.camel@zaphod> <20040423173738.A3812@infradead.org> <1082739174.1943.49.camel@zaphod> <20040423180130.A4255@infradead.org> Mime-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="Fig2xvG2VGoz8o/s" Cc: Shaya Potter , Jamie Lokier , linux-fsdevel@vger.kernel.org Return-path: Received: from cimice4.lam.cz ([212.71.168.94]:39336 "EHLO vagabond.light.src") by vger.kernel.org with ESMTP id S262073AbUDXIzM (ORCPT ); Sat, 24 Apr 2004 04:55:12 -0400 To: Christoph Hellwig Content-Disposition: inline In-Reply-To: <20040423180130.A4255@infradead.org> List-Id: linux-fsdevel.vger.kernel.org --Fig2xvG2VGoz8o/s Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Apr 23, 2004 at 18:01:30 +0100, Christoph Hellwig wrote: > On Fri, Apr 23, 2004 at 12:52:54PM -0400, Shaya Potter wrote: > > > in 2.4 writepage is always the result of data dirtied by mmap. In 2.= 6 it's > > > also for use for data dirtied by write. Even in 2.4 there's no guran= tee > > > the mapping that dirtied the page still exists when the page is writt= en out > > > by the VM. > >=20 > > so the mapping off the page struct will be null? >=20 > No. but i_mmap and i_mmap_shared might be empty. >=20 > > so is that a yes to my understanding of "multiple dentries" i.e. a > > single inode linked into multiple places in the fs. >=20 > Yes. >=20 > > > > > It's also possible to find no dentries at all. > > > >=20 > > > > even if in my fs's writepage() function? > > >=20 > > > Yes. > >=20 > > so the vm_file part of vm_area_struct will be null? >=20 > You won't find a vm_area_struct at all in that case. >=20 > > > You can't do that. > >=20 > > Yes, I know it's evil to do and would never be accepted into the kernel > > proper, the question I'm trying to figure out if it it's possible (with > > a stackable fs) to version files on write. =20 >=20 > It's not evil is's fucking impossible for gods sake. >=20 > you can be in writepage with page->mapping->i_mmap{,shared} beeing empty. > No way in hell you'll ever get to a dentry. page->mapping->host->i_dentries and first item there? Of course, inode can survive it's last dentry. But you can make sure it won't survive dirty! ---------------------------------------------------------------------------= ---- Jan 'Bulb' Hudec --Fig2xvG2VGoz8o/s Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQFAiisiRel1vVwhjGURAoCaAJ0YXGt7orcYuudywrcZSn0KSgE3wQCfXkef 8AvzsTxjBU7IbfoCUZ0g7Z0= =+XHc -----END PGP SIGNATURE----- --Fig2xvG2VGoz8o/s--