Re: [regression] sched_getaffinity fails with EINVAL in 2.6.31-rc4

Steven Rostedt
2009-07-27T17:35:29Z

On Mon, 27 Jul 2009, Gregory Haskins wrote:

> I am not sure when this started, but noticed that sched_getaffinity is
> not working in -rc4.
>
> [pid 6254] sched_getaffinity(0, 128, 0x7f80586b1fe0) = -1 EINVAL
> (Invalid argument)
>
> Here is a simple program for reproduction:

Thanks,

I have a box available in which I can look at this further.

-- Steve

>
> #include <sched.h>
>
> int main(void)
> {
> cpu_set_t mask;
> int ret;
>
> ret = sched_getaffinity(0, sizeof(mask), &mask);
> if (ret < 0)
> perror("getaffinity");
>
> return ret;
> }
>
> If I get time, I will bisect this later today.
>
> Regards,
> -Greg
>
>