lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 16 Jan 2008 09:04:56 -0800
From:	Dave Hansen <haveblue@...ibm.com>
To:	Andrew Morton <akpm@...ux-foundation.org>
Cc:	linux-kernel@...r.kernel.org, miklos@...redi.hu, hch@...radead.org,
	Bryn Reeves <breeves@...hat.com>,
	Alasdair G Kergon <agk@...hat.com>
Subject: Re: [PATCH 04/27] kill filp_open()

On Wed, 2008-01-16 at 00:52 -0800, Andrew Morton wrote:
> On Thu, 01 Nov 2007 16:08:31 -0700 Dave Hansen <haveblue@...ibm.com> wrote:
> > Replace all callers with open_namei() directly, and move the
> > nameidata stack allocation into open_namei().
> 
> ftp://ftp.kernel.org/pub/linux/kernel/people/agk/patches/2.6/editing/dm-loop.patch
> is using filp_open() and hence doesn't work very well.
> 
> A shall revert dm-loop.patch and run away.

This one's pretty easy, thank goodness.  Just replace filp_open() with
open_namei():

	/filp_open(/open_namei(AT_FDCWD, /

BTW, why do we need this on top of the existing loopback driver?  Can
they really share no code?

 linux-2.6.git-dave/drivers/md/dm-loop.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN drivers/md/dm-loop.c~fix-dm-loop drivers/md/dm-loop.c
--- linux-2.6.git/drivers/md/dm-loop.c~fix-dm-loop	2008-01-16 09:02:06.000000000 -0800
+++ linux-2.6.git-dave/drivers/md/dm-loop.c	2008-01-16 09:02:06.000000000 -0800
@@ -757,7 +757,7 @@ static int loop_get_file(struct dm_targe
 	int r = 0;
 
 	ti->error = "could not open backing file";
-	filp = filp_open(lc->path, flags, 0);
+	filp = open_namei(AT_FDCWD, lc->path, flags, 0);
 	if (IS_ERR(filp))
 		return PTR_ERR(filp);
 	lc->filp = filp;
_


-- Dave

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ