|
From: <zw...@ma...> - 2009-06-02 08:21:55
|
Author: zwelch
Date: 2009-06-02 08:21:49 +0200 (Tue, 02 Jun 2009)
New Revision: 1993
Modified:
trunk/src/jtag/jtag.c
trunk/src/jtag/jtag.h
Log:
More JTAG interface driver cleanup:
- Make interface_jtag_execute_queue call new helper function.
- Add default_interface_jtag_execute_queue to wrap jtag interface access.
This patch may look useless on its own, but it helps to isolate the core
JTAG variables from the interface_jtag_* routines, so the later can be
moved into jtag_driver.c in a pending patch.
Modified: trunk/src/jtag/jtag.c
===================================================================
--- trunk/src/jtag/jtag.c 2009-06-02 05:47:00 UTC (rev 1992)
+++ trunk/src/jtag/jtag.c 2009-06-02 06:21:49 UTC (rev 1993)
@@ -1570,7 +1570,7 @@
return ERROR_FAIL;
}
- retval = jtag->execute_queue();
+ retval = default_interface_jtag_execute_queue();
if (retval == ERROR_OK)
{
@@ -1592,6 +1592,11 @@
}
#endif
+int default_interface_jtag_execute_queue(void)
+{
+ return jtag->execute_queue();
+}
+
void jtag_execute_queue_noclear(void)
{
/* each flush can take as much as 1-2ms on high bandwidth low latency interfaces.
Modified: trunk/src/jtag/jtag.h
===================================================================
--- trunk/src/jtag/jtag.h 2009-06-02 05:47:00 UTC (rev 1992)
+++ trunk/src/jtag/jtag.h 2009-06-02 06:21:49 UTC (rev 1993)
@@ -869,6 +869,13 @@
extern int interface_jtag_add_clocks(int num_cycles);
extern int interface_jtag_execute_queue(void);
+/**
+ * Calls the interface callback to execute the queue. This routine
+ * is used by the JTAG driver layer and should not be called directly.
+ */
+extern int default_interface_jtag_execute_queue(void);
+
+
#endif // INCLUDE_JTAG_MINIDRIVER_H
/* this allows JTAG devices to implement the entire jtag_xxx() layer in hw/sw */
|