Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-29 Thread Max Filippov
On Wed, Jun 29, 2022 at 3:14 AM Alex Bennée wrote: > Max Filippov writes: > > There's no notion of 'serial hardware' for the xtensa-sim, all it has is > > the three standard stdio file descriptors. > > Which are accessed via semihosting calls? Yes. > Are they implicitly mapped to > 3 chardev

Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-29 Thread Alex Bennée
Max Filippov writes: > On Wed, Jun 29, 2022 at 1:09 AM Alex Bennée wrote: >> Richard Henderson writes: >> > On 6/28/22 19:08, Max Filippov wrote: >> >> On Tue, Jun 28, 2022 at 4:43 AM Richard Henderson >> >> wrote: > >> >>> } >> >>> -if (serial_hd(0)) { >> >>> -

Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-29 Thread Max Filippov
On Wed, Jun 29, 2022 at 1:09 AM Alex Bennée wrote: > Richard Henderson writes: > > On 6/28/22 19:08, Max Filippov wrote: > >> On Tue, Jun 28, 2022 at 4:43 AM Richard Henderson > >> wrote: > >>> } > >>> -if (serial_hd(0)) { > >>> -xtensa_sim_open_console(serial_hd(0)); > >>> -

Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-29 Thread Max Filippov
On Tue, Jun 28, 2022 at 5:36 PM Richard Henderson wrote: > On 6/28/22 19:08, Max Filippov wrote: > > On Tue, Jun 28, 2022 at 4:43 AM Richard Henderson > > wrote: ... > >> diff --git a/hw/xtensa/sim.c b/hw/xtensa/sim.c > >> index 946c71cb5b..5cca6a170e 100644 > >> --- a/hw/xtensa/sim.c > >> +++

Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-29 Thread Alex Bennée
Richard Henderson writes: > On 6/28/22 19:08, Max Filippov wrote: >> On Tue, Jun 28, 2022 at 4:43 AM Richard Henderson >> wrote: >>> >>> This separates guest file descriptors from host file descriptors, >>> and utilizes shared infrastructure for integration with gdbstub. >>> Remove the xtensa

Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-28 Thread Richard Henderson
On 6/28/22 19:08, Max Filippov wrote: On Tue, Jun 28, 2022 at 4:43 AM Richard Henderson wrote: This separates guest file descriptors from host file descriptors, and utilizes shared infrastructure for integration with gdbstub. Remove the xtensa custom console handing and rely on the generic

Re: [PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-28 Thread Max Filippov
On Tue, Jun 28, 2022 at 4:43 AM Richard Henderson wrote: > > This separates guest file descriptors from host file descriptors, > and utilizes shared infrastructure for integration with gdbstub. > Remove the xtensa custom console handing and rely on the > generic -semihosting-config handling of

[PATCH v5 2/2] target/xtensa: Use semihosting/syscalls.h

2022-06-28 Thread Richard Henderson
This separates guest file descriptors from host file descriptors, and utilizes shared infrastructure for integration with gdbstub. Remove the xtensa custom console handing and rely on the generic -semihosting-config handling of chardevs. Signed-off-by: Richard Henderson --- target/xtensa/cpu.h