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:	Mon, 11 Mar 2013 17:59:33 +0530
From:	Vineet Gupta <Vineet.Gupta1@...opsys.com>
To:	Arnd Bergmann <arnd@...db.de>
CC:	James Hogan <james.hogan@...tec.com>, <linux-arch@...r.kernel.org>,
	<linux-kernel@...r.kernel.org>
Subject: SYSV IPC broken for no-legacy syscall kernels (was Re: [RFC PATCH
 v1 26/31] ARC: Build system: Makefiles, Kconfig, Linker script)

Hi Arnd,

On Wednesday 07 November 2012 07:43 PM, Arnd Bergmann wrote:
> On Wednesday 07 November 2012, Vineet Gupta wrote:
>
>> +
>> +config ARC
>> +	def_bool y
>> +	select ARCH_WANT_IPC_PARSE_VERSION
>> +	# ARC Busybox based initramfs absolutely relies on DEVTMPFS for /dev
>> +	# DEVTMPS in turn needs HOTPLUG
>> +	select DEVTMPFS if !INITRAMFS_SOURCE=""
>> +	select GENERIC_ATOMIC64
>> +	select GENERIC_CLOCKEVENTS
>> +	select GENERIC_FIND_FIRST_BIT
>> +	# for now, we don't need GENERIC_IRQ_PROBE, CONFIG_GENERIC_IRQ_CHIP
>> +	select GENERIC_IRQ_SHOW
>> +	select GENERIC_PENDING_IRQ if SMP
>> +	select GENERIC_SMP_IDLE_THREAD
>> +	select HAVE_GENERIC_HARDIRQS
>> +	select HOTPLUG if !INITRAMFS_SOURCE=""
>> +	select MODULES_USE_ELF_RELA
> You should not need ARCH_WANT_IPC_PARSE_VERSION

It seems, we have a small bug in sysV IPC.
A lot of LTP tests have started failing on ARC 3.9-rc1 kernel due to absence of
ARCH_WANT_IPC_PARSE_VERSION.

I'm assuming that for newer arches, msgctl(2) and friends need to have  need to
have @cmd of type 0x01nn where 0x0100 is IPC_64.
However for ! ARCH_WANT_IPC_PARSE_VERSION, ipc/util.h seems to be defining a dummy
version of ipc_parse_version(), which doesn't strip out the 0x0100 from @cmds,
causing the code to not enter the switch block in SYSCALL_DEFINE3(msgctl) making
it fail.
Adding the above item to arch/arc/Kconfig obviously fixes the breakage.

It seems there is some bogosity in the way ipc_parse_version() is defined. Given
the way it is used, to strip out the 0x0100 bit, it seems we always need the
function variant - the IA-64 ish comment in there seems to be bit-rot.

What do you think ?

-Vineet

--
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