coresight: etb10: adjust read pointer only when needed
authorMathieu Poirier <mathieu.poirier@linaro.org>
Tue, 3 May 2016 17:34:01 +0000 (11:34 -0600)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 3 May 2016 21:59:30 +0000 (14:59 -0700)
commitbedffda8cad46bedb6880bb98c23c51c715216c3
treee6dad6cf6f481ba494337240cb05e183148aea02
parentdc2c4ef141c5c14cb8d968ba16c74b4f3c373e2c
coresight: etb10: adjust read pointer only when needed

The read pointer (read_ptr) needs to be adjusted only if its value
has gone beyond the length of the memory buffer.

Reported-by: Suzuki K Poulose <suzuki.poulose@arm.com>
Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hwtracing/coresight/coresight-etb10.c