search for: _bitsize

Displaying 17 results from an estimated 17 matches for "_bitsize".

Did you mean: d_bitsize
2013 Nov 08
1
[PATCH 2/3] syscalls: Add syscalls needed by arm64
...; + * > + * For 64 bit systems without the open syscall, pass straight > + * through into openat. > + */ > + > +#define _KLIBC_IN_OPEN_C > +#include <unistd.h> > +#include <fcntl.h> > +#include <sys/syscall.h> > + > +#if !defined(__NR_open) && _BITSIZE == 64 > + > +__extern int openat(int, const char *, int, ...); > + > +int open(const char *pathname, int flags, mode_t mode) > +{ > + return openat(AT_FDCWD, pathname, flags, mode); > +} > + > +#endif This applies equally to a 32-bit platform that doesn't define __NR...
2016 Jan 06
0
[klibc:master] Add pread and pwrite 32bit syscall wrappers for parisc
...bc/pread.c b/usr/klibc/pread.c new file mode 100644 index 0000000..0d8c3b1 --- /dev/null +++ b/usr/klibc/pread.c @@ -0,0 +1,29 @@ +/* + * pread.c + * + * Some architectures need to wrap the system call + */ + +#include <endian.h> +#include <sys/syscall.h> + +#if defined(__hppa__) + +#if _BITSIZE == 32 +extern size_t __pread(int, void *, size_t, unsigned int, unsigned int); +#else +extern size_t __pread(int, void *, size_t, off_t); +#endif + +size_t pread(int fd, void *buf, size_t count, off_t offset) +{ +#if _BITSIZE == 32 + unsigned int hi = offset >> 32; + unsigned int lo = (unsign...
2016 Apr 13
0
[PATCH 1/1] x32 support
...4095, %rax + jae 1f + ret +1: + negl %eax + movl %eax, errno(%rip) + or $-1,%rax + ret diff --git a/usr/klibc/lseek.c b/usr/klibc/lseek.c index f262d19..f0faa3b 100644 --- a/usr/klibc/lseek.c +++ b/usr/klibc/lseek.c @@ -11,7 +11,7 @@ #include <sys/syscall.h> #include <bitsize.h> -#if _BITSIZE == 32 +#if _BITSIZE == 32 && !defined(__x86_64__) extern int __llseek(int fd, unsigned long hi, unsigned long lo, off_t * res, int whence); diff --git a/usr/klibc/open.c b/usr/klibc/open.c index 5305c3d..7d11a21 100644 --- a/usr/klibc/open.c +++ b/usr/klibc/open.c @@ -15,7 +15,7 @@...
2019 Jan 21
0
[klibc:master] fcntl: Fix struct flock for 32-bit architectures
...deletions(-) diff --git a/usr/include/fcntl.h b/usr/include/fcntl.h index b08c7c8..ed703a6 100644 --- a/usr/include/fcntl.h +++ b/usr/include/fcntl.h @@ -11,17 +11,30 @@ #include <sys/types.h> #if defined(__mips__) && ! defined(__mips64) # include <klibc/archfcntl.h> +#elif _BITSIZE == 32 +/* We want a struct flock with 64-bit offsets, which we define below */ +# define HAVE_ARCH_STRUCT_FLOCK #endif #include <linux/fcntl.h> #include <bitsize.h> -#if _BITSIZE == 32 +#if !defined(__mips__) && _BITSIZE == 32 -/* This is ugly, but "struct flock&quot...
2005 Dec 17
2
[patch] fix defintion of struct statfs64
...work on alpha. verified to have no regressions on amd64. Signed-off-by: maximilian attems <janitor@sternwelten.at> Signed-off-by: Frederik Sch?ler <fschueler-guest@costa.debian.org> --- klibc-1.1.1.orig/include/sys/vfs.h +++ klibc-1.1.1/include/sys/vfs.h @@ -32,17 +32,17 @@ #else /* _BITSIZE == 64 */ struct statfs { - uint64_t f_type; - uint64_t f_bsize; + uint32_t f_type; + uint32_t f_bsize; uint64_t f_blocks; uint64_t f_bfree; uint64_t f_bavail; uint64_t f_files; uint64_t f_ffree; __kernel_fsid_t f_f...
2019 Jan 18
0
[klibc:master] fcntl: Fix file locking numbers for 64-bit architectures
...1 file changed, 5 insertions(+) diff --git a/usr/include/fcntl.h b/usr/include/fcntl.h index 16128f8..b08c7c8 100644 --- a/usr/include/fcntl.h +++ b/usr/include/fcntl.h @@ -13,6 +13,9 @@ # include <klibc/archfcntl.h> #endif #include <linux/fcntl.h> +#include <bitsize.h> + +#if _BITSIZE == 32 /* This is ugly, but "struct flock" has actually been defined with a long off_t, so it's really "struct flock64". It just happens @@ -35,6 +38,8 @@ # define F_SETLKW F_SETLKW64 #endif +#endif /* _BITSIZE == 32 */ + /* This is defined here as well as in &lt...
2006 Feb 19
0
[patch] openat build with older !openat linux tree
.../ @@ -20,3 +21,4 @@ openat: jmp __syscall_varadic .size openat,.-openat +#endif /* __NR_openat */ diff --git a/klibc/openat.c b/klibc/openat.c index 2975112..e2ce67b 100644 --- a/klibc/openat.c +++ b/klibc/openat.c @@ -10,7 +10,7 @@ #include <fcntl.h> #include <bitsize.h> -#if _BITSIZE == 32 && !defined(__i386__) && defined(__NR_openat) +#if _BITSIZE == 32 && defined(__NR_openat) extern int __openat(int, const char *, int, mode_t);
2006 Jun 02
1
Re: [PATCH] klibc
...(__x86_64__) && !defined(__ia64__) && !defined(__sparc_v9__) > >> +#if !defined(__x86_64__) && !defined(__ia64__) && !defined(__sparc_v9__) && \ > >> + !defined(__powerpc64__) > > > > Why not just !defined(__LP64__) ? > > _BITSIZE == 64 is really the right formula... if I remember correctly, there were some > 64-bit platforms (Alpha?) which didn't conform, though. I will look at this later today. > > -hpa indeed aboves line contains an mistake by an earlier patch of mine. -#if !defined(__x86_64__) &&am...
2016 Jan 06
5
[PATCH klibc 0/5] klibc architecture fixes
Here's an assortment of build and run-time fixes for various architectures that we've applied in Debian. Ben. Aurelien Jarno (1): ppc64: fix struct stat Ben Hutchings (2): MIPS: Update archfcntl.h syscalls: Override detection of direct socket syscalls on i386, m68k, s390 Helge Deller (1): Add pread and pwrite 32bit syscall wrappers for parisc Mauricio Faria de Oliveira
2011 Jan 29
2
another bugfix
Hi, number three, where I first thought it was a GCC bug but is apparently bad code in klibc. Submitted with permission: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47533#c6 Patch attached again (sorry) not just because that is easier with my mail system but also to keep original author intact. bye, //mirabilos -- > emacs als auch vi zum Kotzen finde (joe rules) und pine f?r den einzig >
2013 Nov 12
0
[klibc:master] syscalls: Add syscalls needed by arm64
...ndicate that we're 64-bit safe. + * + * For 64 bit systems without the open syscall, pass straight + * through into openat. */ #define _KLIBC_IN_OPEN_C #include <unistd.h> #include <fcntl.h> #include <bitsize.h> +#include <sys/syscall.h> + +#ifndef __NR_open +#if _BITSIZE == 32 + +extern int __openat(int, const char *, int, mode_t); + +int open(const char *pathname, int flags, mode_t mode) +{ + return __openat(AT_FDCWD, pathname, flags | O_LARGEFILE, mode); +} + +#else + +__extern int openat(int, const char *, int, ...); + +int open(const char *pathname, int flags,...
2012 Jan 29
5
[PATCH 0/2 v3] mkstemp() and m68k support
Hi, after a year, I decided to hack on klibc again. I?ve reworked both the patch to add mkstemp(), discussing to use AT_RANDOM as cheap entropy source on IRC (if there will ever be another entropy consumer, I can quickly write a minimal arc4random() seeded from it, as it has only 16 octets), capable of making a working mksh (static and shared) on amd64/xen, and the m68k support code, leading to
2012 May 15
5
[PATCH 0/5] resubmitting pending patches
Hi, I?ve gone through the mailing list archives and hereby want to resubmit my pending patches. Most are independent of each other, except the m68k patch which will only be complete if sigsuspend is also fixed. (It can be applied before that, though.) http://www.zytor.com/pipermail/klibc/2012-January/003173.html [PATCH] fix m68k support Resubmitted here as 0005. While there was a question from
2006 Aug 08
1
[patch] mips fix statfs
please pull from git://charm.itp.tuwien.ac.at/mattems/klibc/.git branch maks. arch/mips/klibc/archconfig.h | 3 +++ klibc/sysconfig.h | 10 ++++++++++ sys/vfs.h | 17 +++++++++++++++++ 3 files changed, 30 insertions(+)
2013 Nov 11
5
[PATCH V2 0/3] Introduce arm64 support
Hello, Here is V2 of the arm64 support for klibc patch set. Notable changes since the original series: * fp regs dropped from setjmp/longjmp * chmod, lstat and stat re-implemented with *at functions. * open64 merged into open. As with the original, this series is to be applied against the latest klibc, just after 25a66fa README.klibc: update build information V2 has been tested on x86_64
2013 Nov 08
9
[PATCH 0/3] Introduce arm64 support
Hello, This series introduces arm64 support to klibc. I've rebased the work from Neil Williams and Anil Singhar into the following three patches. Most of the code changes are due to new syscall implementations being needed for arm64 as a only a minimal set of syscalls are defined in the arm64 kernel. This series is to be applied against the latest klibc, just after 25a66fa README.klibc:
2013 Nov 08
0
[PATCH 2/3] syscalls: Add syscalls needed by arm64
...sr/klibc/open64.c @@ -0,0 +1,22 @@ +/* + * open64.c + * + * For 64 bit systems without the open syscall, pass straight + * through into openat. + */ + +#define _KLIBC_IN_OPEN_C +#include <unistd.h> +#include <fcntl.h> +#include <sys/syscall.h> + +#if !defined(__NR_open) && _BITSIZE == 64 + +__extern int openat(int, const char *, int, ...); + +int open(const char *pathname, int flags, mode_t mode) +{ + return openat(AT_FDCWD, pathname, flags, mode); +} + +#endif diff --git a/usr/klibc/poll.c b/usr/klibc/poll.c new file mode 100644 index 0000000..69da693 --- /dev/null +++ b/usr...