diff chipsetsw/services/etm/etm_api.c @ 18:4346e5e95d3c

etm_pkt_send() fix from tcs211-c139
author Mychaela Falconia <falcon@freecalypso.org>
date Fri, 23 Sep 2016 06:05:38 +0000
parents 509db1a7b7b8
children
line wrap: on
line diff
--- a/chipsetsw/services/etm/etm_api.c	Fri Sep 23 05:56:21 2016 +0000
+++ b/chipsetsw/services/etm/etm_api.c	Fri Sep 23 06:05:38 2016 +0000
@@ -253,11 +253,12 @@
 int etm_pkt_send(T_ETM_PKT *pkt)
 {
     extern unsigned char etm_trace_user_id; 
-    uint8 *buf, cksum = 0, sendsize, size;
+    uint8 *buf, cksum = 0;
+    uint16 sendsize, size;
     int error = ETM_OK;
 
     buf = (uint8 *) &pkt->mid;
-    sendsize = size = pkt->size + 2; //one for mid, one for status  
+    sendsize = size = pkt->size + 2; //one for mid, one for status
 
     tr_etm(TgTrEtmLow, "ETM API: _pkt_send: size(%d)", sendsize);
 
@@ -269,8 +270,8 @@
     sendsize += 1; // one for checksum
 
     tr_etm_hexdump(TgTrEtmLow, &pkt->mid, sendsize);
-   
-    error = rvt_send_trace_cpy((uint8 *) &pkt->mid, etm_trace_user_id, 
+
+    error = rvt_send_trace_cpy((uint8 *) &pkt->mid, etm_trace_user_id,
                                sendsize, RVT_BINARY_FORMAT);
     if(error < 0)
         tr_etm(TgTrFatal, "ETM API: _pkt_send: ERROR(%d)", error);