From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Smith Subject: Re: [PATCH 2/2] Add support for the per-task sem_undo list (v2) Date: Wed, 04 Aug 2010 14:38:47 -0700 Message-ID: <87lj8mkqhk.fsf@caffeine.danplanet.com> References: <1280941345-27566-1-git-send-email-danms@us.ibm.com> <1280941345-27566-3-git-send-email-danms@us.ibm.com> <4C59B625.7000007@cs.columbia.edu> <87pqxyku9j.fsf@caffeine.danplanet.com> <4C59DBD0.1000107@cs.columbia.edu> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <4C59DBD0.1000107-eQaUEPhvms7ENvBUuze7eA@public.gmane.org> (Oren Laadan's message of "Wed\, 04 Aug 2010 17\:29\:52 -0400") List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Oren Laadan Cc: containers-qjLDD68F18O7TbgM5vRIOg@public.gmane.org List-Id: containers.vger.kernel.org OL> In that case, the atomic_inc for the first task should occur OL> earlier - as soon as it is attached to the task _and_ inserted OL> into the objhash. Okay, fair enough. By my calculations, it belongs just a few lines above, in restore_sem_undo() before a successful termination. Then we leave the refcount increment in restore_obj_sem_undo(), but only for second-and-later tasks. Agreed? -- Dan Smith IBM Linux Technology Center email: danms-r/Jw6+rmf7HQT0dZR+AlfA@public.gmane.org