mbox series

[00/18] video: bochs: Remove the x86 limitation

Message ID 20230723044041.1089804-1-bmeng@tinylab.org
Headers show
Series video: bochs: Remove the x86 limitation | expand

Message

Bin Meng July 23, 2023, 4:40 a.m. UTC
The Bochs VGA card emulated by QEMU does not enforce any architecture.
It was first introduced on x86 and indeed the x86 IO instruction is
used to access the legacy VGA IO ports, but that does not mean it has
to be done like this.

The first half of this series enhances the bochs video driver to
remove the x86 limitation.

The second half of this series enables bochs video as the output
console for QEMU RISC-V, to prove that the bochs video driver can
indeed work on a non-x86 architecture. To make it actually useful,
enable a usb keyboard as well, otherwise we can't just type anything :-)

This series is available at u-boot-x86/bochs for testing.


Bin Meng (17):
  dm: video: Cosmetic style fix
  video: bochs: Drop inclusion of <asm/mtrr.h>
  video: bochs: Drop the useless argument of bochs_vga_write()
  video: bochs: Avoid using IO instructions to access VGA IO port
  video: bochs: Remove the x86 dependency
  video: kconfig: Fix wrong text for the PCI default FB size
  video: kconfig: Drop the superfluous dependency
  video: kconfig: Set default FB size for Bochs
  video: bochs: Set the frame buffer size per configuration
  riscv: qemu: Enable Bochs video support
  console: kconfig: Drop the redundant VIDEO dependency
  console: Make stdio_print_current_devices() static
  console: Refactor stdio_print_current_devices() a little bit
  console: Print out complete stdio device list
  riscv: qemu: Enable PRE_CONSOLE_BUFFER
  riscv: qemu: Remove out-of-date "riscv,kernel-start" handling
  riscv: qemu: Enable usb keyboard as an input device

Heinrich Schuchardt (1):
  riscv: define a cache line size for the generic CPU

 arch/riscv/cpu/generic/Kconfig          |  1 +
 board/emulation/qemu-riscv/Kconfig      | 13 ++++++++
 board/emulation/qemu-riscv/qemu-riscv.c | 27 +++------------
 common/Kconfig                          |  2 +-
 common/console.c                        | 44 ++++++++++++++++---------
 doc/board/emulation/qemu-riscv.rst      | 10 ++++++
 drivers/video/Kconfig                   | 15 +++++----
 drivers/video/bochs.c                   | 12 +++----
 drivers/video/bochs.h                   |  7 ++--
 drivers/video/video-uclass.c            |  6 ++--
 include/configs/qemu-riscv.h            | 15 +++------
 include/stdio_dev.h                     |  2 --
 12 files changed, 84 insertions(+), 70 deletions(-)

Comments

Bin Meng July 25, 2023, 4:10 a.m. UTC | #1
Hi Rick,

On Sun, Jul 23, 2023 at 12:40 PM Bin Meng <bmeng@tinylab.org> wrote:
>
> The Bochs VGA card emulated by QEMU does not enforce any architecture.
> It was first introduced on x86 and indeed the x86 IO instruction is
> used to access the legacy VGA IO ports, but that does not mean it has
> to be done like this.
>
> The first half of this series enhances the bochs video driver to
> remove the x86 limitation.
>
> The second half of this series enables bochs video as the output
> console for QEMU RISC-V, to prove that the bochs video driver can
> indeed work on a non-x86 architecture. To make it actually useful,
> enable a usb keyboard as well, otherwise we can't just type anything :-)
>
> This series is available at u-boot-x86/bochs for testing.
>
>
> Bin Meng (17):
>   dm: video: Cosmetic style fix
>   video: bochs: Drop inclusion of <asm/mtrr.h>
>   video: bochs: Drop the useless argument of bochs_vga_write()
>   video: bochs: Avoid using IO instructions to access VGA IO port
>   video: bochs: Remove the x86 dependency
>   video: kconfig: Fix wrong text for the PCI default FB size
>   video: kconfig: Drop the superfluous dependency
>   video: kconfig: Set default FB size for Bochs
>   video: bochs: Set the frame buffer size per configuration
>   riscv: qemu: Enable Bochs video support
>   console: kconfig: Drop the redundant VIDEO dependency
>   console: Make stdio_print_current_devices() static
>   console: Refactor stdio_print_current_devices() a little bit
>   console: Print out complete stdio device list
>   riscv: qemu: Enable PRE_CONSOLE_BUFFER
>   riscv: qemu: Remove out-of-date "riscv,kernel-start" handling
>   riscv: qemu: Enable usb keyboard as an input device

Would you please review patch 10, 15, 17, 18? Thanks!

Regards,
Bin
Bin Meng July 31, 2023, 5:26 a.m. UTC | #2
> On Sun, Jul 23, 2023 at 12:40 PM Bin Meng <bmeng@tinylab.org> wrote:
> >
> > The Bochs VGA card emulated by QEMU does not enforce any architecture.
> > It was first introduced on x86 and indeed the x86 IO instruction is
> > used to access the legacy VGA IO ports, but that does not mean it has
> > to be done like this.
> >
> > The first half of this series enhances the bochs video driver to
> > remove the x86 limitation.
> >
> > The second half of this series enables bochs video as the output
> > console for QEMU RISC-V, to prove that the bochs video driver can
> > indeed work on a non-x86 architecture. To make it actually useful,
> > enable a usb keyboard as well, otherwise we can't just type anything :-)
> >
> > This series is available at u-boot-x86/bochs for testing.
> >
> >
> > Bin Meng (17):
> >   dm: video: Cosmetic style fix
> >   video: bochs: Drop inclusion of <asm/mtrr.h>
> >   video: bochs: Drop the useless argument of bochs_vga_write()
> >   video: bochs: Avoid using IO instructions to access VGA IO port
> >   video: bochs: Remove the x86 dependency
> >   video: kconfig: Fix wrong text for the PCI default FB size
> >   video: kconfig: Drop the superfluous dependency
> >   video: kconfig: Set default FB size for Bochs
> >   video: bochs: Set the frame buffer size per configuration
> >   riscv: qemu: Enable Bochs video support
> >   console: kconfig: Drop the redundant VIDEO dependency
> >   console: Make stdio_print_current_devices() static
> >   console: Refactor stdio_print_current_devices() a little bit
> >   console: Print out complete stdio device list
> >   riscv: qemu: Enable PRE_CONSOLE_BUFFER
> >   riscv: qemu: Remove out-of-date "riscv,kernel-start" handling
> >   riscv: qemu: Enable usb keyboard as an input device
>

Looks the first half is assigned to Anatolij and the second half to Rick.

I guess the first half should go first.

Ping for apply?

Regards,
Bin
Anatolij Gustschin Aug. 1, 2023, 1:03 p.m. UTC | #3
Hi Bin,

On Mon, 31 Jul 2023 13:26:23 +0800
Bin Meng bmeng.cn@gmail.com wrote:
...
> Looks the first half is assigned to Anatolij and the second half to Rick.
> 
> I guess the first half should go first.
> 
> Ping for apply?

I've applied patches 1/18 to 9/18 now, a pull request is pending.

--
Anatolij
Bin Meng Aug. 1, 2023, 1:43 p.m. UTC | #4
On Tue, Aug 1, 2023 at 9:03 PM Anatolij Gustschin <agust@denx.de> wrote:
>
> Hi Bin,
>
> On Mon, 31 Jul 2023 13:26:23 +0800
> Bin Meng bmeng.cn@gmail.com wrote:
> ...
> > Looks the first half is assigned to Anatolij and the second half to Rick.
> >
> > I guess the first half should go first.
> >
> > Ping for apply?
>
> I've applied patches 1/18 to 9/18 now, a pull request is pending.
>

Thank you Anatolij.

Regards,
Bin