Commit c7e6034
tracing: ctf: take IRQ lock before generating timestamp
CTF tracing relies on all packet timestamps being increasing- if a
timestamp of a later packet is less than the prior packet, the CTF
parser assumes the timestamp field has overflowed and adds to the
overall timestamp to account for this.
When taking a timestamp for a CTF packet, it was possible for an interrupt
to occur before the packet was submitted to the tracing core framework
but after the timestamp was generated. The interrupt itself would
generate a tracing event with a later timestamp then the packet in
question, leading to the packets being recorded out of order.
To resolve this, take an IRQ lock before generating the timestamp and
release it after submitting the packet to the tracing core.
Signed-off-by: Daniel DeGrasse <ddegrasse@tenstorrent.com>1 parent 8240ed9 commit c7e6034
1 file changed
+2
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
52 | 52 | | |
53 | 53 | | |
54 | 54 | | |
| 55 | + | |
55 | 56 | | |
56 | 57 | | |
57 | 58 | | |
| 59 | + | |
58 | 60 | | |
59 | 61 | | |
60 | 62 | | |
| |||
0 commit comments