[PATCH v3 2/2] Use O_IGNORE_CTTY where appropriate

2023-06-04 Thread Sergey Bugaev
* getpt, openpty: Opening an unused pty, which can't be our ctty * shm_open, sem_open: These don't work with ttys * opendir: Directories are unlikely to be ttys Signed-off-by: Sergey Bugaev --- catgets/open_catalog.c | 4 ++-- elf/dl-load.c | 2 +- elf/dl-misc.c

[PATCH v3 1/2] include/fcntl.h: Define O_IGNORE_CTTY

2023-06-04 Thread Sergey Bugaev
This internal definition makes it possible to use O_IGNORE_CTTY in the glibc codebase unconditionally, no matter whether the current port provides it or not (i.e. both on Hurd and on Linux). Along with the definition, this adds a small guide on when O_IGNORE_CTTY is to be used. The following commi

[PATCH v3 0/2] O_IGNORE_CTTY everywhere

2023-06-04 Thread Sergey Bugaev
Hello, this is the v3 of the "O_IGNORE_CTTY everywhere" patchset. Please see the v1 cover letter [0] for an explanation of what O_IGNORE_CTTY is and does. [0]: https://sourceware.org/pipermail/libc-alpha/2023-April/147355.html Changes since v2: 1. Dropped the already commited patches. 2. Dropp

[PATCH] hurd: Exclude more headers when generating errno.h

2023-06-04 Thread Sergey Bugaev
This both works around ordering issues, and removes an x86-specific file from the list. Suggested-by: Joseph Myers Signed-off-by: Sergey Bugaev --- We could maybe clean this up even further, but -- diminishing returns :| sysdeps/mach/hurd/bits/errno.h | 4 sysdeps/mach/hurd/errnos.awk |

Re: 64bit startup

2023-06-04 Thread Samuel Thibault
Sergey Bugaev, le dim. 04 juin 2023 20:40:54 +0300, a ecrit: > On Sun, Jun 4, 2023 at 8:21 PM Samuel Thibault > wrote: > > It seems so indeed. But it's not only the stack guard, but various TLS > > accesses. > > What would be an easy way for me to reproduce this? Basically all I'm trying to do

Re: 64bit startup

2023-06-04 Thread Sergey Bugaev
On Sun, Jun 4, 2023 at 8:21 PM Samuel Thibault wrote: > It seems so indeed. But it's not only the stack guard, but various TLS > accesses. What would be an easy way for me to reproduce this? Sergey

Re: 64bit startup

2023-06-04 Thread Samuel Thibault
Hello, Sergey Bugaev, le sam. 03 juin 2023 20:20:24 +0300, a ecrit: > I'm attaching a patch that does that and also documents the pitfalls > (and also removes an extra block scope / level of indentation). It's > untested, but it builds and the generated code looks OK (sc_reply_port > gets loaded s