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: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 1 Jan 2020 11:43:13 +0100
From:   Dominik Brodowski <linux@...inikbrodowski.net>
To:     Arvind Sankar <nivedita@...m.mit.edu>
Cc:     torvalds@...ux-foundation.org, linux-kernel@...r.kernel.org,
        viro@...iv.linux.org.uk, youling257@...il.com
Subject: Re: [PATCH] early init: open /dev/console with O_LARGEFILE

@youling 257: could you test the attached patch, please?

Thanks,
	Dominik

On Tue, Dec 31, 2019 at 07:30:19PM -0500, Arvind Sankar wrote:
> On Tue, Dec 31, 2019 at 04:02:26PM +0100, Dominik Brodowski wrote:
> > If force_o_largefile() is true, /dev/console used to be opened
> > with O_LARGEFILE. Retain that behaviour.
> > 
> 
> One other thing that used to happen is fsnotify_open() -- I don't know
> how that might affect this, but it seems like the only thing left that's
> different.

Suggested-by: Arvind Sankar <nivedita@...m.mit.edu>
Signed-off-by: Dominik Brodowski <linux@...inikbrodowski.net>

diff --git a/init/main.c b/init/main.c
index d12777775cb0..3f4163046200 100644
--- a/init/main.c
+++ b/init/main.c
@@ -94,6 +94,7 @@
 #include <linux/jump_label.h>
 #include <linux/mem_encrypt.h>
 #include <linux/file.h>
+#include <linux/fsnotify.h>
 
 #include <asm/io.h>
 #include <asm/bugs.h>
@@ -1166,6 +1167,7 @@ void console_on_rootfs(void)
 			  O_RDWR | (force_o_largefile() ? O_LARGEFILE : 0), 0);
 	if (IS_ERR(file))
 		goto err_out;
+	fsnotify_open(file);
 
 	/* create stdin/stdout/stderr, this should never fail */
 	for (i = 0; i < 3; i++) {

Powered by blists - more mailing lists