[PATCH] perf: remove duplicate block from Makefile

2013-10-05 Thread Ulrich Drepper
This looks like a merge error, the code is duplicated with the first copy doing something else as well. Just remove the second block. Signed-off-by: Ulrich Drepper Makefile |8 1 file changed, 8 deletions(-) Index: perf/config/Makefile

Re: [RFC] apparently broken RLIMIT_CORE

2013-10-06 Thread Ulrich Drepper
On Sun, Oct 6, 2013 at 4:42 PM, Linus Torvalds wrote: > I doubt it is intentional, but I also cannot really feel that we care > deeply. Afaik we don't really honor the size limit exactly anyway, ie > we tend to check only at page boundaries etc. So do we really care? I could imagine in the case A

Re: sendfile and EAGAIN

2013-03-02 Thread Ulrich Drepper
On Mon, Feb 25, 2013 at 2:22 PM, Eric Dumazet wrote: > I don't understand the issue. > > sendfile() returns -EAGAIN only if no bytes were copied to the socket. There is something wrong/unexpected/... I have a program which can use either sendfile or send. When using sendfile to transmit a large

Re: sendfile and EAGAIN

2013-03-02 Thread Ulrich Drepper
On Sat, Mar 2, 2013 at 10:09 PM, Eric Dumazet wrote: > > Using non blocking IO means the sender (and the receiver) must be able > to perform several operations, as long as the whole transfert is not > finished. Certainly, and this is implemented. But the receiver never gets the rest of the data

Re: [PATCH 2/2] perf: use XSI-complaint version of strerror_r() instead of GNU-specific

2012-07-23 Thread Ulrich Drepper
On Mon, Jul 23, 2012 at 11:00 AM, Kirill A. Shutemov wrote: > The right way to fix it is to switch to XSI-compliant version. And why exactly would this be "the right way"? Just fix the use of strerror_r or use strerror_l. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel"

Re: [PATCH 2/2] perf: use XSI-complaint version of strerror_r() instead of GNU-specific

2012-07-23 Thread Ulrich Drepper
On Mon, Jul 23, 2012 at 4:31 PM, Kirill A. Shutemov wrote: > + const char *err = strerror_r(errnum, buf, buflen); > + > + if (err != buf && buflen > 0) { > + size_t len = strlen(err); > + char *c = mempcpy(buf, err, min(buflen

Re: [PATCH 2/2] perf: use XSI-complaint version of strerror_r() instead of GNU-specific

2012-07-23 Thread Ulrich Drepper
On Mon, Jul 23, 2012 at 5:06 PM, Kirill A. Shutemov wrote: > They are bugs. > > Let's fix strerror_r() usage. > > Signed-off-by: Kirill A. Shutemov Acked-by: Ulrich Drepper -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in t

Re: [RFC 0/4] perf tool: Adding ratios support

2013-01-16 Thread Ulrich Drepper
On Tue, Jan 15, 2013 at 8:39 AM, Jiri Olsa wrote: > $ perf stat -f formula.conf:cpi kill > usage: kill [ -s signal | -p ] [ -a ] pid ... > kill -l [ signal ] I do like this proposal. The only comment I have is that perhaps the command line syntax isn't ideal. What you use above is

Re: [RFC 0/4] perf tool: Adding ratios support

2013-01-16 Thread Ulrich Drepper
On Wed, Jan 16, 2013 at 9:25 AM, Jiri Olsa wrote: > I was thinking having config files (global and arch specific) > comming with perf having predefined formulas. All the more reason to not mention the file name or really any source for the definition of the formula in the name, > 1) -e 'ratio/

Re: struct stat{st_blksize} for /dev entries in 2.4.3

2001-04-08 Thread Ulrich Drepper
nd there is no guarantee that any of the _SC_* constants are defined as macros. You'll have to add a configure test. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--&

Re: List of all-zero .data variables in linux-2.4.3 available

2001-04-12 Thread Ulrich Drepper
data. It is a programmer problem. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe

Re: List of all-zero .data variables in linux-2.4.3 available

2001-04-12 Thread Ulrich Drepper
rogrammers to not initialize. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel&qu

Re: PATCH(?): linux-2.4.4-pre2: fork should run child first

2001-04-13 Thread Ulrich Drepper
people apparently want. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the b

Re: light weight user level semaphores

2001-04-18 Thread Ulrich Drepper
cesses. The rest seems OK. Thanks, -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this l

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
r dealing with the common case without syscalls can be applied here as well. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `--

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
lemented using fd = open (name) addr = mmap (..fd..) close (fd) sem_syscall (addr) i.e., it can be mapped to a memory reference again. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
e like the shmfs. > So you have unix file permissions on them ? See above. Permissions are only allowed for named semaphores. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
sions to the file change? The kernel representation of the mutex must not be disassociated from the shared memory region. Even if you all think very little about Solaris, look at the kernel interface for semaphores. -- ---. ,-. 1

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
#x27;t really care what the final implementation will be like. For UP and SMP machines I definitely want to have as much as possible at user-level. If you need a special libpthread for NUMA machines, so be it. -- ---. ,-. 1325 Chesapeake

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
doing this her/himself. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
1 + 1; i = (int *) (m2 + 1); while (1) { ++*i; pthread_mutex_unlock (m1); pthread_mutex_lock (m2); } return 0; } ~~~~~~~~~~~ -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---'

Re: [linux-lvm] 2.4.3-ac{6,7} LVM hang

2001-04-19 Thread Ulrich Drepper
Jens Axboe <[EMAIL PROTECTED]> writes: > Does attached patch fix it? Yes. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' dr

Re: light weight user level semaphores

2001-04-19 Thread Ulrich Drepper
mplement something else I couldn't care less since it's useless for me. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `

Re: BUG: Global FPU corruption in 2.2

2001-04-20 Thread Ulrich Drepper
zes the FPU. This was always the case and necessary to implement the fast lazy FPU saving/restoring. Processes which never use the FPU never initialize it. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyva

Re: BUG: Global FPU corruption in 2.2

2001-04-20 Thread Ulrich Drepper
kernel code and the features of the processor first. The kernel can detect when the FPU is used for the first time. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--'

Re: RFC: changing precision control setting in initial FPU context

2001-03-03 Thread Ulrich Drepper
pid idea. No kernel and no libc modifications necessary. This is the end of the story as far as I'm concerned. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat

Re: [PATCH] new bug report script

2001-01-06 Thread Ulrich Drepper
> +} This is wrong. You cannot execute libc.so.5. This only works with glibc. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `-

Re: [PATCH] new bug report script

2001-01-07 Thread Ulrich Drepper
les there). -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a messag

Re: [PATCH] Re: [PATCH] new bug report script

2001-01-07 Thread Ulrich Drepper
bc5) => /usr/i486-linux-libc5/lib/libc.so.5 and then look in that directory (/usr/i486-linux-libc5/lib). -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `--

Re: [PATCH] new bug report script

2001-01-07 Thread Ulrich Drepper
fi > ;; Why don't you, as the other script suggested, execute libc.so.6? Symlinks can be missing or can be wrong. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 9408

thread group comments

2000-09-01 Thread Ulrich Drepper
plementation. [1] Since Linus says so it must be true. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscrib

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
ase about just that. And I know that there are many other users with this problem. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
problem: you cannot send a signal explicitly to this thread (to implement pthread_kill). The PID of this initial thread is now used as the PID of the thread group. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
ds. That's the whole purpose of this exercise. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
e first clone() but this is solvable. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this l

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
In a second stage where we have m kernel threads and n user-level threads (the ultimate goal) things might be different. But this is beyond what is needed in the 2.4 kernel so lets just skip the SA_NOCLDWAIT stuff for now. -- ---. ,-. 1325

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
g. You have of course to swap before the clone since the new thread will use the stack. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
problems with changing UID/GID It will require some investigation to see whether we can implement the restart semantics correctly without a manager thread. If yes, we should be able to live with the simple loop. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Dr

Re: thread group comments

2000-09-01 Thread Ulrich Drepper
#x27;s see what I have next week. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line &

Re: Question regarding kernel_threads

2000-09-05 Thread Ulrich Drepper
se it this way. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "

Re: [BUG] threaded processes get stuck in rt_sigsuspend/fillonedir/exit_notify

2000-09-11 Thread Ulrich Drepper
already used CLONE_SIGHAND and is not prepared for thread groups all hell breaks loose. I've told Linus several times about this problems but he puts out one test release after the other without this fixed. -- ---. ,-. 1325 Chesapeake Terra

Re: [BUG] threaded processes get stuck in rt_sigsuspend/fillonedir/exit_notify

2000-09-11 Thread Ulrich Drepper
r is someone already working on this? "Fixing" alone won't cut it. I've started a rewrite and send Linus more comments about what is needed but not even got a reply. Seems the short interest span is already over. -- ---.

Re: [BUG] threaded processes get stuck in rt_sigsuspend/fillonedir/exit_notify

2000-09-11 Thread Ulrich Drepper
tely unrelated. The fix for your problem is to change the CLONE_SIGHAND flag back to it's original behavior. Changing linuxthreads to take advantage of the new kernel functionality is on a different plate. -- ---. ,-. 1325 Chesapea

Re: [BUG] threaded processes get stuck in rt_sigsuspend/fillonedir/exit_notify

2000-09-12 Thread Ulrich Drepper
,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a messag

Re: syslog() blocks on glibc 2.1.3 with kernel 2.2.x

2000-10-23 Thread Ulrich Drepper
tion of syslogd. Make it robust. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe l

Re: syslog() blocks on glibc 2.1.3 with kernel 2.2.x

2000-10-23 Thread Ulrich Drepper
d and do it right. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line &quo

Re: Dual XEON - >>SLOW<< on SMP

2000-11-02 Thread Ulrich Drepper
LOC increment on every CPU. CPU0 CPU1 0: 146727 153389IO-APIC-edge timer [...] NMI: 300035 300035 LOC: 300028 300028 -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \

Re: Can EINTR be handled the way BSD handles it? -- a plea from a user-land programmer...

2000-11-03 Thread Ulrich Drepper
errace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] P

Re: Can EINTR be handled the way BSD handles it? -- a plea from a user-land programmer...

2000-11-06 Thread Ulrich Drepper
he time, it's a darned good idea > to do that. > > - Ted > - > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to [EMAIL PROTECTED] > Please read the FAQ at http://www.tux.org/lkml/ &g

Re: Can EINTR be handled the way BSD handles it? -- a plea from a user-land programmer...

2000-11-06 Thread Ulrich Drepper
Ulrich Drepper <[EMAIL PROTECTED]> writes: > "Theodore Y. Ts'o" <[EMAIL PROTECTED]> writes: > > > Arguably though the bug is in glibc, in that if it's using signals > > behinds the scenes, it should have passed SA_RESTART to sigaction. > &

Re: 2.2.18 signal.h

2000-12-15 Thread Ulrich Drepper
-- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kerne

Re: What is up with Redhat 7.0?

2000-09-30 Thread Ulrich Drepper
really have not the slightest idea how you can make something like this up. Go and find somebody who is working on glibc to back up this "statement" and not some idiot like you who has no inside whatsoever. If you cannot find anybody I demand a public apology from you. -- -----

Re: [RFC] Additional pad in struct stat(64)

2000-09-26 Thread Ulrich Drepper
other change necessary. Introducing breakage just to possibily avoid them in future is stupid. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com

Re: [RFC] Additional pad in struct stat(64)

2000-09-26 Thread Ulrich Drepper
; of struct stat (and a new libc to use it), It will need a new libc version anyway. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com `

Re: [PATCH] pcnet32 compilation fix for 2.4.3pre6

2001-03-29 Thread Ulrich Drepper
efully forever signal the gcc semantics. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this lis

Re: [PATCH] devfsd, compiling on glibc22x

2001-01-27 Thread Ulrich Drepper
,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a m

Re: [PATCH] devfsd, compiling on glibc22x

2001-02-04 Thread Ulrich Drepper
wrote the code. -- ---. ,-. 1325 Chesapeake Terrace Ulrich Drepper \,---' \ Sunnyvale, CA 94089 USA Red Hat `--' drepper at redhat.com ` - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the bo

Re: pselect() modifying timeout

2005-08-05 Thread Ulrich Drepper
t from select. The userlevel code will take care of the difference. The kernel code is good as proposed. -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ signature.asc Description: OpenPGP digital signature

Re: sigwait() breaks when straced

2005-07-31 Thread Ulrich Drepper
On 7/30/05, Sanjoy Mahajan <[EMAIL PROTECTED]> wrote: > so the return value should not be 4 (or the docs are not right). This return value simply indicated EINTR (sigwait does not set errno, read the docs). The kernel simply doesn't restart the function in case of a signal. It should do this, th

Re: Fw: sigwait() breaks when straced

2005-08-01 Thread Ulrich Drepper
On 7/31/05, Roland McGrath <[EMAIL PROTECTED]> wrote: > However, there is in fact no bug here. The test program is just wrong. > sigwait returns zero or an error number, as POSIX specifies. No question, no error is detected incorrectly. But sigwait is not a function specified with an EINTR error

Re: Fw: sigwait() breaks when straced

2005-08-01 Thread Ulrich Drepper
On 8/1/05, Jesper Juhl <[EMAIL PROTECTED]> wrote: > I'm not quite sure you are right Ulrich. Given this little bit from > SUSv3 about SA_RESTART in the page describing sigaction ( > http://www.opengroup.org/onlinepubs/009695399/functions/sigaction.html > ) : It's not an official SA_RESTART since t

Re: [PATCH 2.6.13-rc6 1/2] New Syscall: get rlimits of any process (update)

2005-08-22 Thread Ulrich Drepper
On 8/18/05, Alan Cox <[EMAIL PROTECTED]> wrote: > Perhaps those application authors should provide a management interface > to do so within the soft limit range at least. Its not clear to me that > growing the fd array on a process is even safe. Some programs do size > arrays at startup after query

mremap() use is racy

2005-08-23 Thread Ulrich Drepper
ivate, anonymous mappings which have no access permissions (i.e., PROT_NONE with MAP_PRIVATE and MAP_ANON). One explicitly has to allocate such blocks, they don't appear naturally. And the program in any case knows about the address space layout. So, how about adding MREMAP_MAPOVERNONE or so? --

Re: mremap() use is racy

2005-08-23 Thread Ulrich Drepper
ith MREMAP_MAYMOVE is unreliable as it is implemented today. -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ signature.asc Description: OpenPGP digital signature

Re: mremap() use is racy

2005-08-23 Thread Ulrich Drepper
to use mremap() since this makes it clear what should happen but I can live with using the too-large mapping. -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ signature.asc Description: OpenPGP digital signature

Re: Add pselect, ppoll system calls.

2005-08-24 Thread Ulrich Drepper
. while (1) { if (!got_signal) pselect() if (got_signal) { handle signal got_signal = 0; } } ... } -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ signature.asc Description: OpenPGP digital signature

Re: [PATCH] RUSAGE_THREAD

2008-01-18 Thread Ulrich Drepper
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Roland McGrath wrote: > +#define RUSAGE_LWP RUSAGE_THREAD /* Solaris name for same */ No need to clutter the kernel header with this, it'll be in the libc header. Aside from that: Acked-by: Ulrich Drepper <[EMAI

Re: [PATCHv3 0/4] sys_indirect system call

2007-11-19 Thread Ulrich Drepper
in user code, and > only use the substructs for each function. There is no overhead introduced through the union. The only reason the union is there in the first place is to allocate sufficient data in task_struct to cover all cases. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mou

Re: [PATCHv3 0/4] sys_indirect system call

2007-11-19 Thread Ulrich Drepper
e good news is that user programs should never use this syscall directly (just like don't for existing ones). I see no problem at all here. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ -BEGIN PGP SIGNATURE- Version: GnuPG v

Re: [PATCHv3 0/4] sys_indirect system call

2007-11-19 Thread Ulrich Drepper
e limited parameter number. Plus, using sys_indirect could in future be used to transport entire parameters (like a sigset_t) along with other information, thereby saving individual copy operations. I think the sys_indirect approach is the way forward. I'll submit a last version of the patch in a bit.

[PATCHv4 4/6] Allow setting FD_CLOEXEC flag for new sockets

2007-11-19 Thread Ulrich Drepper
This is a first user of sys_indirect. Several of the socket-related system calls which produce a file handle now can be passed an additional parameter to set the FD_CLOEXEC flag. arch/x86/ia32/Makefile|1 + arch/x86/ia32/sys_ia32.c |4 include/asm-x86/ia32_unistd.h |

[PATCHv4 1/6] actual sys_indirect code

2007-11-19 Thread Ulrich Drepper
This is the actual architecture-independent part of the system call implementation. include/linux/indirect.h |6 ++ include/linux/sched.h|4 include/linux/syscalls.h |4 kernel/Makefile |2 +- kernel/indirect.c| 36 +

[PATCHv4 3/6] UML support for sys_indirect

2007-11-19 Thread Ulrich Drepper
This part adds support for sys_indirect for UML. indirect.h |6 ++ 1 file changed, 6 insertions(+) --- /dev/null +++ include/asm-um/indirect.h @@ -0,0 +1,6 @@ +#ifndef __UM_INDIRECT_H +#define __UM_INDIRECT_H + +#include "asm/arch/indirect.h" + +#endif - To unsubscribe from this list: se

[PATCHv4 2/6] x86&x86-64 support for sys_indirect

2007-11-19 Thread Ulrich Drepper
This part adds support for sys_indirect on x86 and x86-64. arch/x86/ia32/ia32entry.S |2 ++ arch/x86/ia32/sys_ia32.c | 31 +++ arch/x86/kernel/syscall_table_32.S |1 + include/asm-x86/indirect.h |5 + include/asm-x86/indirec

[PATCHv4 0/6] sys_indirect system call

2007-11-19 Thread Ulrich Drepper
is"); close (fd); FILL_IN(r, __NR_eventfd, 8); fd = syscall (__NR_indirect, &r, &i, sizeof (i)); int s4 = fcntl (fd, F_GETFD); printf ("eventfd: FD_CLOEXEC %s set\n", s4 == 0 ? "not" : "is"); close (fd); return s1 != 0 || s2 == 0 || t1 !=

[PATCHv4 6/6] FD_CLOEXEC support for eventfd, signalfd, timerfd

2007-11-19 Thread Ulrich Drepper
This patch adds support to set the FD_CLOEXEC flag for the file descriptors returned by eventfd, signalfd, timerfd. fs/anon_inodes.c | 15 +++ fs/eventfd.c |5 +++-- fs/signalfd.c |6 -- fs/timerfd.c |6 +

[PATCHv4 5/6] Allow setting O_NONBLOCK flag for new sockets

2007-11-19 Thread Ulrich Drepper
This patch adds support for setting the O_NONBLOCK flag of the file descriptors returned by socket, socketpair, and accept. socket.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) --- net/socket.c +++ net/socket.c @@ -362,7 +362,7 @@ static int sock_alloc_fd(struct file

Re: [PATCHv4 5/6] Allow setting O_NONBLOCK flag for new sockets

2007-11-20 Thread Ulrich Drepper
PARAM() macro get defined? I do not > see it being defined anywhere in these patches. Defined in : +#define INDIRECT_PARAM(set, name) current->indirect_params.set.name Not my idea, I was following one review comment. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View

Re: [PATCHv4 0/6] sys_indirect system call

2007-11-20 Thread Ulrich Drepper
quot; flag. In the latter case an additional parameter might be needed to indicate the notification mechanism. > And no change in the test program reflecting this 'flags' new param, so > it fails. Yep, sorry, I didn't update the text by including the most recent test program. I

Re: [PATCHv3 0/4] sys_indirect system call

2007-11-20 Thread Ulrich Drepper
#x27;ll find that I explained this. I talked to Andrew and he favored new syscalls. But then I talked to Linus and he favored this approach. Probably especially because it can be used for syslets as well. And it is less code and data than introducing new syscalls. - -- ➧ Ulrich Drepper ➧ Red Hat, I

Re: [PATCHv4 2/6] x86&x86-64 support for sys_indirect

2007-11-20 Thread Ulrich Drepper
mber. That macro wasn't always available. I'll test it. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (GNU/Linux) iD8DBQFHQwdg2ijCOnn/RHQRAmh9AJ9EuthsaoupSHn3kR/x0cWxqR3FoQCfSbmE 8RIDWzPKZ6cv+QVGNl0faw

Re: [PATCHv4 0/6] sys_indirect system call

2007-11-20 Thread Ulrich Drepper
nterface is sufficiently prepared for this and that there is no need to wait adding this initial, synchronous syscall stuff before the syslet stuff is ready. These interface changes are security-relevant and should be added ASAP. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ ---

Re: [PATCHv4 4/6] Allow setting FD_CLOEXEC flag for new sockets

2007-11-20 Thread Ulrich Drepper
ut all members added to the structure can and should be neutral of the word size. We've done this with some syscalls already (like pread64) where we always use the wide form in the parameter list. It's just more simple here since it does not have to split into two 32-bit registers. - -

Re: 2.6.24-rc3: find complains about /proc/net

2007-11-20 Thread Ulrich Drepper
emantics seems to be more useful. So I guess, no change is the way to go here. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (GNU/Linux) Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org iD

[PATCHv5 5/5] FD_CLOEXEC support for eventfd, signalfd, timerfd

2007-11-20 Thread Ulrich Drepper
This patch adds support to set the FD_CLOEXEC flag for the file descriptors returned by eventfd, signalfd, timerfd. fs/anon_inodes.c | 15 +++ fs/eventfd.c |5 +++-- fs/signalfd.c |6 -- fs/timerfd.c |6 +

[PATCHv5 4/5] Allow setting O_NONBLOCK flag for new sockets

2007-11-20 Thread Ulrich Drepper
This patch adds support for setting the O_NONBLOCK flag of the file descriptors returned by socket, socketpair, and accept. socket.c | 15 +-- 1 file changed, 9 insertions(+), 6 deletions(-) --- linux/net/socket.c +++ linux/net/socket.c @@ -362,7 +362,7 @@ static int sock_alloc_fd

[PATCHv5 3/5] Allow setting FD_CLOEXEC flag for new sockets

2007-11-20 Thread Ulrich Drepper
This is a first user of sys_indirect. Several of the socket-related system calls which produce a file handle now can be passed an additional parameter to set the FD_CLOEXEC flag. include/asm-x86/ia32_unistd.h |1 + include/linux/indirect.h | 27 +++ net/socket.

[PATCHv5 1/5] actual sys_indirect code

2007-11-20 Thread Ulrich Drepper
This is the actual architecture-independent part of the system call implementation. include/linux/indirect.h | 17 + include/linux/sched.h|4 include/linux/syscalls.h |4 kernel/Makefile |3 +++ kernel/indirect.c| 40 +

[PATCHv5 0/5] sys_indirect system call

2007-11-20 Thread Ulrich Drepper
CLOEXEC %s set\n", s4 == 0 ? "not" : "is"); close (fd); return s1 != 0 || s2 == 0 || t1 != 0 || t2 == 0 || s3 == 0 || s4 == 0; } Signed-off-by: Ulrich Drepper <[EMAIL PROTECTED]> arch/x86/

[PATCHv5 2/5] x86&x86-64 support for sys_indirect

2007-11-20 Thread Ulrich Drepper
This part adds support for sys_indirect on x86 and x86-64. arch/x86/Kconfig |3 ++ arch/x86/ia32/Makefile |1 arch/x86/ia32/ia32entry.S |2 + arch/x86/ia32/sys_ia32.c | 38 + arch/x86/kernel/syscal

Re: Where is the new timerfd?

2007-11-23 Thread Ulrich Drepper
On Nov 23, 2007 9:29 AM, Davide Libenzi <[EMAIL PROTECTED]> wrote: > Yes, it's disabled, and yes, I'll repost today ... I haven't seen the patch and don't feel like searching. So I say it here: please mak sure you add a flags parameter to the system call itself (instead of adding it on as for eve

Re: [PATCHv5 4/5] Allow setting O_NONBLOCK flag for new sockets

2007-11-23 Thread Ulrich Drepper
es could you remind it to me ? No security issue. But look at any correct network program, all need to set the mode to non-blocking. Adding this support to the syscall comes at almost no cost and it cuts the cost for every program down by one or two syscalls. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 4

Re: [PATCHv5 4/5] Allow setting O_NONBLOCK flag for new sockets

2007-11-24 Thread Ulrich Drepper
On Nov 24, 2007 12:28 AM, Eric Dumazet <[EMAIL PROTECTED]> wrote: > OK, but maybe for consistency, we might accept the two mechanisms. It's not a question of the kernel interface. The issue with all these extensions is the userlevel interface. Ideally no new userlevel interface is needed. This

Re: [PATCHv4 5/6] Allow setting O_NONBLOCK flag for new sockets

2007-11-26 Thread Ulrich Drepper
e sys_indirect approach ain't pretty but it does it jobs, doesn't impact performance, and is expandable in direction we *know* we will want to go very soon. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ -BEGIN PGP SIGNATURE- Version

Re: [PATCHv4 5/6] Allow setting O_NONBLOCK flag for new sockets

2007-11-26 Thread Ulrich Drepper
s like "sys_indirect adds parameters" are not really contested. Yes, that's what sys_indirect does. So what? It does this with almost no cost which outweighs the ugliness factor in my book. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ -BEGIN

Re: [RFC] Per-thread getrusage

2008-01-17 Thread Ulrich Drepper
alled) is the only usage then the syscall should require that the TID parameter is from a thread in the same process which would solve the security problem. - -- ➧ Ulrich Drepper ➧ Red Hat, Inc. ➧ 444 Castro St ➧ Mountain View, CA ❖ -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.7 (GNU/Linux) i

Re: sigwait() and 2.6

2005-02-15 Thread Ulrich Drepper
On Tue, 15 Feb 2005 13:58:28 +0100, Yves Crespin <[EMAIL PROTECTED]> wrote: >ThreadUnblockSignal(); >signo = WaitSignal(); >ThreadBlockSignal(); You expect this to work? Just read the POSIX spec or even the man pages. All signals sigwait() waits for must be blocked before

Re: close-exec flag not working in 2.6.9?

2005-01-31 Thread Ulrich Drepper
On Sun, 30 Jan 2005 23:56:07 -0800, Ben Greear <[EMAIL PROTECTED]> wrote: >flags = fcntl(s, F_GETFL); >flags |= (FD_CLOEXEC); >if (fcntl(s, F_SETFL, flags) < 0) { These have to be F_GETFD and F_SETFD respectively. Note L -> D. - To unsubscribe from this list: send the line "unsubscrib

Re: short read from /dev/urandom

2005-01-15 Thread Ulrich Drepper
: It still means the documented API says there are no short reads. So anyone doing a read() can expect a short read regardless of the fd and is quite clear that reads can be interrupted by signals. "It is not an error". Ever. Of course are signal interruptions wrong if the signal uses SA_

Re: Pollable Semaphores

2005-01-21 Thread Ulrich Drepper
On Fri, 21 Jan 2005 17:17:51 -0600, Brent Casavant <[EMAIL PROTECTED]> wrote: > 2. select/poll on the fd return EWOULDBLOCK if the current value of > the futex is not equal to the value of interest. Otherwise it > behaves as FUTEX_FD currently does. This is the problematic part. The

  1   2   3   4   >