intel_th: msu: Get rid of the window size limit
authorAlexander Shishkin <alexander.shishkin@linux.intel.com>
Fri, 5 Jul 2019 14:14:23 +0000 (17:14 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 25 Jul 2019 11:03:19 +0000 (13:03 +0200)
commit57b69a1f66486d632e188fb167950fb4bdf84221
tree1fce562bf4ef76384ea9978bdb0d9f67a6248625
parentf220df66f67684246ae1bf4a4e479efc7c2f325a
intel_th: msu: Get rid of the window size limit

Currently, the window size is limited to the maximum number of sg entries
in one table. This is because the code addresses individual blocks within
the window by their numeric index. In reality, though, the blocks most
often are iterated through sequentially. By rewriting the logic to use sg
pointers instead of block indices we loose the necessity to dereference
them directly and gain the ability to use multiple chained tables if
necessary.

Get rid of the limitation by replacing index-based block accesses with
sequential block accesses.

Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20190705141425.19894-4-alexander.shishkin@linux.intel.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/hwtracing/intel_th/msu.c