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-next>] [day] [month] [year] [list]
Message-ID: <20071231224558.GA16517@lixom.net>
Date:	Mon, 31 Dec 2007 16:45:58 -0600
From:	Olof Johansson <olof@...om.net>
To:	paulus@...ba.org
Cc:	linuxppc-dev@...abs.org, linux-kernel@...r.kernel.org
Subject: [PATCH] [2.6.24] Add PPC nvram ioctls to compat_ioctl

Fix the following console warning when running 'nvsetenv', and makes
setting of new variables work again:

ioctl32(nvsetenv:4022): Unknown cmd fd(3) cmd(20007043){t:'p';sz:0}
arg(00000003) on /dev/nvram

That's the IOC_NVRAM_SYNC call.


Signed-off-by: Olof Johansson <olof@...om.net>

diff --git a/fs/compat_ioctl.c b/fs/compat_ioctl.c
index e8b7c3a..7be6765 100644
--- a/fs/compat_ioctl.c
+++ b/fs/compat_ioctl.c
@@ -113,6 +113,10 @@
 #include <asm/fbio.h>
 #endif
 
+#ifdef CONFIG_PPC
+#include <asm/nvram.h>
+#endif
+
 static int do_ioctl32_pointer(unsigned int fd, unsigned int cmd,
 			      unsigned long arg, struct file *f)
 {
@@ -2859,6 +2863,13 @@ IGNORE_IOCTL(FBIOGETCMAP32)
 IGNORE_IOCTL(FBIOSCURSOR32)
 IGNORE_IOCTL(FBIOGCURSOR32)
 #endif
+
+#ifdef CONFIG_PPC
+/* PPC-specific NVRAM IOCTLs */
+COMPATIBLE_IOCTL(OBSOLETE_PMAC_NVRAM_GET_OFFSET)
+COMPATIBLE_IOCTL(IOC_NVRAM_GET_OFFSET)
+COMPATIBLE_IOCTL(IOC_NVRAM_SYNC)
+#endif
 };
 
 #define IOCTL_HASHSIZE 256
--
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