You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by GitBox <gi...@apache.org> on 2021/04/26 22:17:36 UTC

[GitHub] [incubator-nuttx] gustavonihei commented on issue #3612: RV32: syslog/printf handling of 64-bit integers is broken

gustavonihei commented on issue #3612:
URL: https://github.com/apache/incubator-nuttx/issues/3612#issuecomment-827179402


   I still haven't figured out why, but I am able to get the expected results by applying the following patch:
   ```patch
   diff --git a/arch/risc-v/src/rv32im/riscv_initialstate.c b/arch/risc-v/src/rv32im/riscv_initialstate.c
   index 4106125070..ab60becb1b 100644
   --- a/arch/risc-v/src/rv32im/riscv_initialstate.c
   +++ b/arch/risc-v/src/rv32im/riscv_initialstate.c
   @@ -77,7 +77,7 @@ void up_initial_state(struct tcb_s *tcb)
       * only the start function would do that and we have control over that one
       */
    
   -  xcp->regs[REG_SP]      = (uint32_t)tcb->stack_base_ptr +
   +  xcp->regs[REG_SP]      = (uint32_t)tcb->stack_alloc_ptr +
                                         tcb->adj_stack_size;
    
      /* Save the task entry point */
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org