adi_v5_swd: Read RDBUFF once after a sequence of AP reads

Increases performance by a factor of two for long reads.

Change-Id: I81a7a83835058560c6a53a43c3cc991100f01766
Signed-off-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
Reviewed-on: http://openocd.zylin.com/1954
Tested-by: jenkins
Reviewed-by: Paul Fertser <fercerpav@gmail.com>
This commit is contained in:
Andreas Fritiofson
2014-02-16 09:29:01 +01:00
parent 9ec211de1c
commit fd909a5e3d
3 changed files with 34 additions and 3 deletions

View File

@@ -187,6 +187,12 @@ struct adiv5_dap {
/* information about current pending SWjDP-AHBAP transaction */
uint8_t ack;
/**
* Holds the pointer to the destination word for the last queued read,
* for use with posted AP read sequence optimization.
*/
uint32_t *last_read;
/**
* Configures how many extra tck clocks are added after starting a
* MEM-AP access before we try to read its status (and/or result).