Re: [PATCH 2/2] hw/intc: riscv_imsic: Refresh the CSRs xml after updating the state of the cpu.

2023-05-23 Thread Tommy Wu
Hi Weiwei Li, You're right, it seems that we need to add a check in riscv_imsic.c Thanks for the advice! Best Regards, Tommy On Wed, May 24, 2023 at 10:35 AM Weiwei Li wrote: > > On 2023/5/24 09:51, Tommy Wu wrote: > > Hi Weiwei Li, > > Yes, you're right, `riscv_refresh_dynamic_csr_xml()` can

Re: [PATCH 2/2] hw/intc: riscv_imsic: Refresh the CSRs xml after updating the state of the cpu.

2023-05-23 Thread Weiwei Li
On 2023/5/24 09:51, Tommy Wu wrote: Hi Weiwei Li, Yes, you're right,  `riscv_refresh_dynamic_csr_xml()`  can only be called when cpu->dyn_csr_xml isn't a NULL pointer here. The cpu->dyn_csr_xml will be set when the cpu is realized. Yeah, It will  be set only when Zicsr is supported.  And I

Re: [PATCH 2/2] hw/intc: riscv_imsic: Refresh the CSRs xml after updating the state of the cpu.

2023-05-23 Thread Tommy Wu
Hi Weiwei Li, Yes, you're right, `riscv_refresh_dynamic_csr_xml()` can only be called when cpu->dyn_csr_xml isn't a NULL pointer here. The cpu->dyn_csr_xml will be set when the cpu is realized. Best Regards, Tommy On Tue, May 23, 2023 at 10:44 PM Weiwei Li wrote: > > On 2023/5/23 19:44, Tom

Re: [PATCH 2/2] hw/intc: riscv_imsic: Refresh the CSRs xml after updating the state of the cpu.

2023-05-23 Thread Weiwei Li
On 2023/5/23 19:44, Tommy Wu wrote: Originally, when we set the ext_smaia to true, we still cannot print the AIA CSRs in the remote gdb debugger, because the dynamic CSR xml is generated when the cpu is realized. This patch refreshes the dynamic CSR xml after we update the ext_smaia, so that w

[PATCH 2/2] hw/intc: riscv_imsic: Refresh the CSRs xml after updating the state of the cpu.

2023-05-23 Thread Tommy Wu
Originally, when we set the ext_smaia to true, we still cannot print the AIA CSRs in the remote gdb debugger, because the dynamic CSR xml is generated when the cpu is realized. This patch refreshes the dynamic CSR xml after we update the ext_smaia, so that we can print the AIA CSRs in the remote g