uart: Clear global counters in the interrupt example

If mulitple uart instances present in the h/w design and when
try to run periphreal test for those design results failure for
the second instance of ip. This patch fixes this issue.

Signed-off-by: Kedareswara rao Appana <appanad@xilinx.com>
This commit is contained in:
Kedareswara rao Appana 2014-10-15 15:59:36 +05:30 committed by Suneel Garapati
parent da1be543e2
commit fd4c714198
2 changed files with 11 additions and 0 deletions

View file

@ -51,6 +51,10 @@
* as per coding guidelines.
* 2.01a ssb 01/11/01 Updated the example to be used with the SCUGIC in
* Zynq.
* 3.2 adk 15/10/14 Clear the global counters.If multiple instance of ip is
* present in the h/w design without clearing these counters
* will result undefined behaviour for the second ip
* instance while running the peripheral tests.
* </pre>
******************************************************************************/
@ -315,6 +319,11 @@ int UartNs550IntrExample(INTC *IntcInstancePtr,
return XST_FAILURE;
}
/* Clear the counters */
TotalErrorCount = 0;
TotalReceivedCount = 0;
TotalSentCount = 0;
return XST_SUCCESS;
}

View file

@ -156,6 +156,8 @@
* 3.1 adk 20/08/14 Fixed CR:816989 Canonical Definition for Multiple
* Instances of UARTSNS550 have the same Device Id.
* Changes are made in the driver tcl file.
* 3.2 adk 15/10/14 Fixed CR:824444 changes are made in the example file
* xuartns550_intr_example.c
* </pre>
*
*****************************************************************************/