From a20c0b71dc29e1e2d5637366426e7b9ae058f15b Mon Sep 17 00:00:00 2001 From: Christophe Lyon Date: Wed, 4 Jul 2018 17:55:35 +0200 Subject: nptl: Allow sem_open to work on MMU-less systems MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Allow both tmpfs and ramfs for shm devices. * libpthread/nptl/linux_fsinfo.h (SHMFS_SUPER_MAGIC_WITH_MMU): Define. (SHMFS_SUPER_MAGIC_WITHOUT_MMU): Define. * libpthread/nptl/sem_open.c (__where_is_shmfs): Add support for SHMFS_SUPER_MAGIC_WITHOUT_MMU. Signed-off-by: Mickaël Guêné Signed-off-by: Christophe Lyon --- libpthread/nptl/linux_fsinfo.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'libpthread/nptl/linux_fsinfo.h') diff --git a/libpthread/nptl/linux_fsinfo.h b/libpthread/nptl/linux_fsinfo.h index 8537581a2..4abe7920d 100644 --- a/libpthread/nptl/linux_fsinfo.h +++ b/libpthread/nptl/linux_fsinfo.h @@ -126,7 +126,10 @@ #define XENIX_SUPER_MAGIC 0x012ff7b4 /* Constant that identifies the `shm' filesystem. */ -#define SHMFS_SUPER_MAGIC 0x01021994 +/* Mount as tmpfs. */ +#define SHMFS_SUPER_MAGIC_WITH_MMU 0x01021994 +/* The kernel uses a ramfs file system for tmpfs. */ +#define SHMFS_SUPER_MAGIC_WITHOUT_MMU 0x858458f6 /* Constants that identify the `xfs' filesystem. */ #define XFS_SUPER_MAGIC 0x58465342 -- cgit v1.2.3