[Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC UART support

Julia Suvorova via Qemu-devel posted 3 patches 5 years, 5 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20181025005052.27661-1-jusual@mail.ru
Test docker-clang@ubuntu passed
Test checkpatch passed
Test asan passed
Test docker-mingw@fedora failed
Test docker-quick@centos7 passed
hw/arm/microbit.c            |   2 +
hw/arm/nrf51_soc.c           |  20 +++
hw/char/Makefile.objs        |   1 +
hw/char/nrf51_uart.c         | 330 +++++++++++++++++++++++++++++++++++
hw/char/trace-events         |   4 +
include/hw/arm/nrf51_soc.h   |   3 +
include/hw/char/nrf51_uart.h |  78 +++++++++
tests/boot-serial-test.c     |  19 ++
8 files changed, 457 insertions(+)
create mode 100644 hw/char/nrf51_uart.c
create mode 100644 include/hw/char/nrf51_uart.h
[Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC UART support
Posted by Julia Suvorova via Qemu-devel 5 years, 5 months ago
This series adds support for the nRF51 SoC UART, that used in
BBC Micro:bit board, and QTest for it.

v3:
    * serial_hd() moved to the board code
    * sysbus_init_child_obj() used for initialization
    * qemu_chr_fe_accept_input() called after byte popping

v2:
    * Suspend/Enable functionality added
    * Connection to SoC moved to a separate patch
    * Added QTest for checking reception functionality
    * Mini-kernel test changed to fit current implementation
    * Addressed review comments on R_*, uart_can_receive, VMState,
      uart_transmit

Julia Suvorova (3):
  hw/char: Implement nRF51 SoC UART
  hw/arm/nrf51_soc: Connect UART to nRF51 SoC
  tests/boot-serial-test: Add microbit board testcase

 hw/arm/microbit.c            |   2 +
 hw/arm/nrf51_soc.c           |  20 +++
 hw/char/Makefile.objs        |   1 +
 hw/char/nrf51_uart.c         | 330 +++++++++++++++++++++++++++++++++++
 hw/char/trace-events         |   4 +
 include/hw/arm/nrf51_soc.h   |   3 +
 include/hw/char/nrf51_uart.h |  78 +++++++++
 tests/boot-serial-test.c     |  19 ++
 8 files changed, 457 insertions(+)
 create mode 100644 hw/char/nrf51_uart.c
 create mode 100644 include/hw/char/nrf51_uart.h

-- 
2.17.1


Re: [Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC UART support
Posted by Stefan Hajnoczi 5 years, 5 months ago
On Thu, Oct 25, 2018 at 03:50:49AM +0300, Julia Suvorova via Qemu-devel wrote:
> This series adds support for the nRF51 SoC UART, that used in
> BBC Micro:bit board, and QTest for it.
> 
> v3:
>     * serial_hd() moved to the board code
>     * sysbus_init_child_obj() used for initialization
>     * qemu_chr_fe_accept_input() called after byte popping
> 
> v2:
>     * Suspend/Enable functionality added
>     * Connection to SoC moved to a separate patch
>     * Added QTest for checking reception functionality
>     * Mini-kernel test changed to fit current implementation
>     * Addressed review comments on R_*, uart_can_receive, VMState,
>       uart_transmit
> 
> Julia Suvorova (3):
>   hw/char: Implement nRF51 SoC UART
>   hw/arm/nrf51_soc: Connect UART to nRF51 SoC
>   tests/boot-serial-test: Add microbit board testcase
> 
>  hw/arm/microbit.c            |   2 +
>  hw/arm/nrf51_soc.c           |  20 +++
>  hw/char/Makefile.objs        |   1 +
>  hw/char/nrf51_uart.c         | 330 +++++++++++++++++++++++++++++++++++
>  hw/char/trace-events         |   4 +
>  include/hw/arm/nrf51_soc.h   |   3 +
>  include/hw/char/nrf51_uart.h |  78 +++++++++
>  tests/boot-serial-test.c     |  19 ++
>  8 files changed, 457 insertions(+)
>  create mode 100644 hw/char/nrf51_uart.c
>  create mode 100644 include/hw/char/nrf51_uart.h
> 
> -- 
> 2.17.1
> 
> 

Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Re: [Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC UART support
Posted by Peter Maydell 5 years, 5 months ago
On 25 October 2018 at 01:50, Julia Suvorova <jusual@mail.ru> wrote:
> This series adds support for the nRF51 SoC UART, that used in
> BBC Micro:bit board, and QTest for it.
>
> v3:
>     * serial_hd() moved to the board code
>     * sysbus_init_child_obj() used for initialization
>     * qemu_chr_fe_accept_input() called after byte popping
>
> v2:
>     * Suspend/Enable functionality added
>     * Connection to SoC moved to a separate patch
>     * Added QTest for checking reception functionality
>     * Mini-kernel test changed to fit current implementation
>     * Addressed review comments on R_*, uart_can_receive, VMState,
>       uart_transmit
>
> Julia Suvorova (3):
>   hw/char: Implement nRF51 SoC UART
>   hw/arm/nrf51_soc: Connect UART to nRF51 SoC
>   tests/boot-serial-test: Add microbit board testcase

Applied to target-arm.next, thanks.

What's the current status of the 'microbit' board with these
patches? Are we missing anything important? Can we run any
interesting guest programs?

thanks
-- PMM

Re: [Qemu-devel] [PATCH v3 0/3] arm: Add nRF51 SoC UART support
Posted by Stefan Hajnoczi 5 years, 4 months ago
On Mon, Oct 29, 2018 at 02:37:42PM +0000, Peter Maydell wrote:
> On 25 October 2018 at 01:50, Julia Suvorova <jusual@mail.ru> wrote:
> > This series adds support for the nRF51 SoC UART, that used in
> > BBC Micro:bit board, and QTest for it.
> >
> > v3:
> >     * serial_hd() moved to the board code
> >     * sysbus_init_child_obj() used for initialization
> >     * qemu_chr_fe_accept_input() called after byte popping
> >
> > v2:
> >     * Suspend/Enable functionality added
> >     * Connection to SoC moved to a separate patch
> >     * Added QTest for checking reception functionality
> >     * Mini-kernel test changed to fit current implementation
> >     * Addressed review comments on R_*, uart_can_receive, VMState,
> >       uart_transmit
> >
> > Julia Suvorova (3):
> >   hw/char: Implement nRF51 SoC UART
> >   hw/arm/nrf51_soc: Connect UART to nRF51 SoC
> >   tests/boot-serial-test: Add microbit board testcase
> 
> Applied to target-arm.next, thanks.
> 
> What's the current status of the 'microbit' board with these
> patches? Are we missing anything important? Can we run any
> interesting guest programs?

qemu.git/master can't run interesting programs yet.  Missing:

 * Steffen Görtz's patches (rng, timer, uicr, ficr)
 * Julia's serial qtest (this is a prerequisite for the next item)
 * My -kernel vs -device loader fix (currently qemu.git/master is broken
   and cannot load any kernel at all!)

But we're getting there step by step :).

Stefan