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:	Sun, 4 May 2008 23:10:32 +0200
From:	Arnd Bergmann <arnd@...db.de>
To:	monstr@...nam.cz
Cc:	linux-kernel@...r.kernel.org, linux-arch@...r.kernel.org,
	stephen.neuendorffer@...inx.com, John.Linn@...inx.com,
	john.williams@...alogix.com, matthew@....cx, will.newton@...il.com,
	drepper@...hat.com, microblaze-uclinux@...e.uq.edu.au,
	grant.likely@...retlab.ca, Michal Simek <monstr@...str.eu>
Subject: Re: [PATCH 30/56] microblaze_v2: includes SHM*, msgbuf

On Sunday 04 May 2008, monstr@...nam.cz wrote:

>  include/asm-microblaze/msgbuf.h   |   41 +++++++++++++++++++++++++++++
>  include/asm-microblaze/shmbuf.h   |   52 +++++++++++++++++++++++++++++++++++++
>  include/asm-microblaze/shmparam.h |   16 +++++++++++
>  3 files changed, 109 insertions(+), 0 deletions(-)
>  create mode 100644 include/asm-microblaze/msgbuf.h
>  create mode 100644 include/asm-microblaze/shmbuf.h
>  create mode 100644 include/asm-microblaze/shmparam.h

Along with cleaning up the syscall interface, you should create asm-generic
versions of these files, ipcbuf.h and sembuf.h belong in the same category
(sysv IPC).

Unfortunately, most architectures have slightly different versions of them,
few of them really getting it right.
The version you have copied to microblaze is correct for little-endian
32 bit architectures, but not for big-endian architectures. The only
big-endian architectures that correctly implement padding are parisc,
powerpc, sparc, and the only one that gets 32 bit emulation right is
parisc (which, btw is a common scheme: if you want to know how to do
it, look at the parisc code).

I suppose it doesn't really matter much now, because SysV IPC is not
used a lot any more, and people have learned to live with the ill-defined
data structures. Most architectures have made the same mistake by
blindly copying the i386 version, so I'd suggest you take the version
you have and move that to asm-generic/{msg,shm,sem,ipc}buf.h, and
asm-generic/shmparam.h, so that every architecture using a copy of the
i386 headers can move to the generic one.

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