qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 1/2] Fix for Haiku


From: Philippe Mathieu-Daudé
Subject: Re: [PATCH 1/2] Fix for Haiku
Date: Sun, 4 Jul 2021 11:03:25 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0

On 7/4/21 12:06 AM, Richard Zak wrote:
> For MIPS (all sub-targets, 64-bit and EL) & xtensa(eb), the compiler
> complains about running out of memory. Best I can see, that's not what
> actually happens, but that's the error message. I was going to
> investigate this later, but this was the error which was causing the
> test with the Haiku VM with that corresponding make target. My desktop &
> laptop have 64 GB, and I'm pretty sure it didn't get to that point.
> 
> /boot/system/develop/tools/bin/../lib/gcc/x86_64-unknown-haiku/8.3.0/../../../../x86_64-unknown-haiku/bin/ld:
> error:
> libqemu-mips-softmmu.fa.p/target_mips_tcg_sysemu_mips-semi.c.o(.rodata)
> is too large (0xffff405a bytes)

This comes the following array from commit 2c44b19c199:

+/* Errno values taken from asm-mips/errno.h */
+static uint16_t host_to_mips_errno[] = {
+    [ENAMETOOLONG] = 78,
+#ifdef EOVERFLOW
+    [EOVERFLOW]    = 79,
+#endif
+#ifdef ELOOP
+    [ELOOP]        = 90,
+#endif
+};

See how Haiku handles POSIX errno:

https://github.com/haiku/haiku/blob/master/headers/os/support/Errors.h

#define B_GENERAL_ERROR_BASE   INT_MIN

#define B_POSIX_ERROR_BASE     (B_GENERAL_ERROR_BASE + 0x7000)

#define B_POSIX_ENOMEM  B_TO_POSIX_ERROR(B_POSIX_ERROR_BASE + 0)
#define E2BIG           B_TO_POSIX_ERROR(B_POSIX_ERROR_BASE + 1)
#define ECHILD          B_TO_POSIX_ERROR(B_POSIX_ERROR_BASE + 2)
...



reply via email to

[Prev in Thread] Current Thread [Next in Thread]