Re: [PATCH 3.4 43/91] perf: Fix a race condition in perf_remove_from_context()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> | diff --git a/kernel/events/core.c b/kernel/events/core.c
> | index 685ce46..c958be1 100644
> | --- a/kernel/events/core.c
> | +++ b/kernel/events/core.c
> | @@ -1702,6 +1702,16 @@ retry:
> |  	 */
> |  	if (ctx->is_active) {
> |  		raw_spin_unlock_irq(&ctx->lock);
> | +		/*
> | +		 * Reload the task pointer, it might have been changed by
> | +		 * a concurrent perf_event_context_sched_out().
> | +		 */
> | +		task = ctx->task;
> | +		/*
> | +		 * Reload the task pointer, it might have been changed by
> | +		 * a concurrent perf_event_context_sched_out().
> | +		 */
> | +		task = ctx->task;
> 
> Something wrong in the way the patch was applied ?
> The lines are identical...
> 
> The original commit, 3577af70, has the change applied in two
> places: perf_event_disable() and perf_remove_from_context().
> 

I guess it's because the two parts of the original patch are identical,
so the patch command wasn't smart enough to do the right work.

It looks to me this won't make things worse than bebore, so I'll fix
it in 3.4.106.

Thanks for spotting this!

--
To unsubscribe from this list: send the line "unsubscribe stable" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel]     [Kernel Development Newbies]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]