Re: [PATCH 2/2] ipc/sem.c: move wake_up_process out of the spinlocksection

From: Manfred Spraul
Date: Wed May 12 2010 - 14:17:25 EST


On 05/12/2010 07:34 PM, Manfred Spraul wrote:

The effect would be that e.g. a semctl(SETALL) operation might change sem_otime.
semctl(SETALL) must only change sem_ctime (and sem_otime only if it causes a wakeup
and the woken up thread modifies the array)

Just for your information: I'm not sure why semctl(SETALL) changes sem_ctime at all.
According to the opengroup, it shouldn't do that.

On FreeBSD, it doesn't.

Any proposals how to fix it?
Should I remove the update to sem_ctime?


> [manfred@cores linux-2.6]$ touch ipc/sem.o
It should have been "touch ipc/sem.c":

> [manfred@cores linux-2.6]$ touch ipc/sem.c
> [manfred@cores linux-2.6]$ make ipc
> CHK include/linux/version.h
> CHK include/generated/utsrelease.h
> CALL scripts/checksyscalls.sh
> CC ipc/sem.o
> LD ipc/built-in.o

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