Re: [PATCH] 2.5: task cpu affinity syscalls

From: Anton Blanchard (anton@samba.org)
Date: Thu Apr 11 2002 - 22:34:55 EST


> Attached is a resync to 2.5.8-pre2 of my CPU affinity syscalls for 2.5's
> scheduler.
>
> This patch implements two new syscalls:
>
> int sched_setaffinity(pid_t pid, unsigned int len,
> unsigned long *new_mask_ptr)
>
> int sched_getaffinity(pid_t pid, unsigned int *user_len_ptr,
> unsigned long *user_mask_ptr)

Since this isnt 32/64 bit compatible on big endian machines, can you
write some wrapper functions before all the archs implement it
themselves?

Think of 32 bit userspace passing a big endian bitmask into a 64 bit
kernel:

32 bit:
31-0 63-32 95-64 127-96

64 bit:
63-0 127-64

Anton
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Mon Apr 15 2002 - 22:00:20 EST