@@ -180,9 +180,9 @@ static int _getCryptoResponse(uint8_t* respBuf, uint16_t type,
180180
181181 return header -> rc ;
182182}
183- static int _SendRecieveWithTimeout (whClientContext * ctx ,
184- uint16_t * group , uint16_t * action , uint16_t req_len ,
185- uint16_t * res_len , void * data )
183+ static int _SendRecieveWithTimeout (whClientContext * ctx , uint16_t * group ,
184+ uint16_t * action , uint16_t req_len ,
185+ uint16_t * res_len , void * data )
186186{
187187
188188 int ret = WH_ERROR_OK ;
@@ -202,7 +202,8 @@ static int _SendRecieveWithTimeout(whClientContext *ctx,
202202 int chk = wh_Client_TimeoutCheck (ctx );
203203 if (chk == WH_ERROR_TIMEOUT ) {
204204 return WH_ERROR_TIMEOUT ;
205- } else if (chk < 0 && chk != WH_ERROR_OK ) {
205+ }
206+ else if (chk < 0 && chk != WH_ERROR_OK ) {
206207 return chk ;
207208 }
208209 }
@@ -262,8 +263,8 @@ int wh_Client_RngGenerate(whClientContext* ctx, uint8_t* out, uint32_t size)
262263 /* Send request and get response with Timeout */
263264 if (ret == 0 ) {
264265 do {
265- ret = _SendRecieveWithTimeout (ctx , & group , & action ,
266- req_len , & res_len , dataPtr );
266+ ret = _SendRecieveWithTimeout (ctx , & group , & action , req_len ,
267+ & res_len , dataPtr );
267268 } while (ret == WH_ERROR_NOTREADY );
268269 }
269270 if (ret == WH_ERROR_OK ) {
@@ -443,9 +444,8 @@ int wh_Client_AesCtr(whClientContext* ctx, Aes* aes, int enc, const uint8_t* in,
443444 /* Response packet */
444445 uint16_t res_len = 0 ;
445446 do {
446- ret =
447- _SendRecieveWithTimeout (ctx , & group , & action ,
448- req_len , & res_len , dataPtr );
447+ ret = _SendRecieveWithTimeout (ctx , & group , & action , req_len ,
448+ & res_len , dataPtr );
449449 } while (ret == WH_ERROR_NOTREADY );
450450
451451 if (ret == WH_ERROR_OK ) {
@@ -557,9 +557,8 @@ int wh_Client_AesEcb(whClientContext* ctx, Aes* aes, int enc, const uint8_t* in,
557557 /* Response packet */
558558 uint16_t res_len = 0 ;
559559 do {
560- ret =
561- _SendRecieveWithTimeout (ctx , & group , & action ,
562- req_len , & res_len , dataPtr );
560+ ret = _SendRecieveWithTimeout (ctx , & group , & action , req_len ,
561+ & res_len , dataPtr );
563562 } while (ret == WH_ERROR_NOTREADY );
564563
565564 if (ret == WH_ERROR_OK ) {
@@ -667,9 +666,8 @@ int wh_Client_AesCbc(whClientContext* ctx, Aes* aes, int enc, const uint8_t* in,
667666 /* Response packet */
668667 uint16_t res_len = 0 ;
669668 do {
670- ret =
671- _SendRecieveWithTimeout (ctx , & group , & action ,
672- req_len , & res_len , dataPtr );
669+ ret = _SendRecieveWithTimeout (ctx , & group , & action , req_len ,
670+ & res_len , dataPtr );
673671 } while (ret == WH_ERROR_NOTREADY );
674672
675673 if (ret == WH_ERROR_OK ) {
@@ -789,9 +787,8 @@ int wh_Client_AesGcm(whClientContext* ctx, Aes* aes, int enc, const uint8_t* in,
789787 if (ret == 0 ) {
790788 uint16_t res_len = 0 ;
791789 do {
792- ret =
793- _SendRecieveWithTimeout (ctx , & group , & action ,
794- req_len , & res_len , dataPtr );
790+ ret = _SendRecieveWithTimeout (ctx , & group , & action , req_len ,
791+ & res_len , dataPtr );
795792 } while (ret == WH_ERROR_NOTREADY );
796793
797794 if (ret == WH_ERROR_OK ) {
@@ -988,9 +985,8 @@ int wh_Client_AesGcmDma(whClientContext* ctx, Aes* aes, int enc,
988985 if (ret == 0 ) {
989986 uint16_t resLen = 0 ;
990987 do {
991- ret =
992- _SendRecieveWithTimeout (ctx , & group , & action ,
993- reqLen , & resLen , dataPtr );
988+ ret = _SendRecieveWithTimeout (ctx , & group , & action , reqLen , & resLen ,
989+ dataPtr );
994990 } while (ret == WH_ERROR_NOTREADY );
995991
996992 if (ret == WH_ERROR_OK ) {
0 commit comments