perf/x86: Add compiler barrier after updating BTS
Since BTS is coherent, simply add a compiler barrier to separate the BTS update and aux_head store. Signed-off-by: Leo Yan <leo.yan@linaro.org> Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org> Link: https://lkml.kernel.org/r/20210809111407.596077-5-leo.yan@linaro.org
This commit is contained in:
parent
4034fb207e
commit
41100833cd
|
@ -209,6 +209,12 @@ static void bts_update(struct bts_ctx *bts)
|
|||
} else {
|
||||
local_set(&buf->data_size, head);
|
||||
}
|
||||
|
||||
/*
|
||||
* Since BTS is coherent, just add compiler barrier to ensure
|
||||
* BTS updating is ordered against bts::handle::event.
|
||||
*/
|
||||
barrier();
|
||||
}
|
||||
|
||||
static int
|
||||
|
|
Loading…
Reference in New Issue