coresight: take care of tmc etr wrap around & offset calculation

Ensure that buffer pointer points to the right location while
trying to read TMC in ETR circular buffer mode when we wrap
around.

TMC in ETR circular buffer mode tracks the physical address
in the RWP register (in contrast to pure offsets). Hence
subtract it from the base physical address to get the offset.

Change-Id: Ice1170dcd63928dd8304c421800848e036386b88
Signed-off-by: Pratik Patel <pratikp@codeaurora.org>
1 file changed