qemu-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-commits] [qemu/qemu] 1e2c22: aspeed: Introduce helper for 32-bit h


From: Alex Bennée
Subject: [Qemu-commits] [qemu/qemu] 1e2c22: aspeed: Introduce helper for 32-bit hosts limitation
Date: Wed, 06 Sep 2023 11:24:09 -0700

  Branch: refs/heads/master
  Home:   https://github.com/qemu/qemu
  Commit: 1e2c22c98fce5c57fbcb179799ff5e4e047e1bd0
      
https://github.com/qemu/qemu/commit/1e2c22c98fce5c57fbcb179799ff5e4e047e1bd0
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/arm/aspeed.c

  Log Message:
  -----------
  aspeed: Introduce helper for 32-bit hosts limitation

On 32-bit hosts, RAM has a 2047 MB limit. Use a macro to define the
default ram size of machines (AST2600 SoC) that can have 2 GB.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Alex Bennée <alex.bennee@linaro.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 97b8aa5ae9ff197394395eda5062ea3681e09c28
      
https://github.com/qemu/qemu/commit/97b8aa5ae9ff197394395eda5062ea3681e09c28
  Author: Hang Yu <francis_yuu@stu.pku.edu.cn>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/i2c/aspeed_i2c.c
    M include/hw/i2c/aspeed_i2c.h

  Log Message:
  -----------
  hw/i2c/aspeed: Fix Tx count and Rx size error in buffer pool mode

Fixed inconsistency between the regisiter bit field definition header file
and the ast2600 datasheet. The reg name is I2CD1C:Pool Buffer Control
Register in old register mode and  I2CC0C: Master/Slave Pool Buffer Control
Register in new register mode. They share bit field
[12:8]:Transmit Data Byte Count and bit field
[29:24]:Actual Received Pool Buffer Size according to the datasheet.
According to the ast2600 datasheet,the actual Tx count is
Transmit Data Byte Count plus 1, and the max Rx size is
Receive Pool Buffer Size plus 1, both in Pool Buffer Control Register.
The version before forgot to plus 1, and mistake Rx count for Rx size.

Signed-off-by: Hang Yu <francis_yuu@stu.pku.edu.cn>
Fixes: 3be3d6ccf2ad ("aspeed: i2c: Migrate to registerfields API")
Reviewed-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 961faf3ddbd8ffcdf776bbcf88af0bc97218114a
      
https://github.com/qemu/qemu/commit/961faf3ddbd8ffcdf776bbcf88af0bc97218114a
  Author: Hang Yu <francis_yuu@stu.pku.edu.cn>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/i2c/aspeed_i2c.c

  Log Message:
  -----------
  hw/i2c/aspeed: Fix TXBUF transmission start position error

According to the ast2600 datasheet and the linux aspeed i2c driver,
the TXBUF transmission start position should be TXBUF[0] instead
of TXBUF[1],so the arg pool_start is useless,and the address is not
included in TXBUF.So even if Tx Count equals zero,there is at least
1 byte data needs to be transmitted,and M_TX_CMD should not be cleared
at this condition.The driver url is:
https://github.com/AspeedTech-BMC/linux/blob/aspeed-master-v5.15/drivers/i2c/busses/i2c-ast2600.c

Signed-off-by: Hang Yu <francis_yuu@stu.pku.edu.cn>
Fixes: 6054fc73e8f4 ("aspeed/i2c: Add support for pool buffer transfers")
Reviewed-by: Cédric Le Goater <clg@kaod.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: acc3d20ab21b1e55619089d15ac29cf26e373fc9
      
https://github.com/qemu/qemu/commit/acc3d20ab21b1e55619089d15ac29cf26e373fc9
  Author: Hang Yu <francis_yuu@stu.pku.edu.cn>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/i2c/aspeed_i2c.c
    M include/hw/i2c/aspeed_i2c.h

  Log Message:
  -----------
  hw/i2c/aspeed: Add support for buffer organization

Added support for the buffer organization option in pool buffer control
register.when set to 1,The buffer is split into two parts: Lower 16 bytes
for Tx and higher 16 bytes for Rx.

Signed-off-by: Hang Yu <francis_yuu@stu.pku.edu.cn>
Reviewed-by: Cédric Le Goater <clg@kaod.org>
[ clg: checkpatch fixes ]
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 9bf9865c5eb4a893b800eade8873b1795b64d555
      
https://github.com/qemu/qemu/commit/9bf9865c5eb4a893b800eade8873b1795b64d555
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M tests/avocado/machine_aspeed.py

  Log Message:
  -----------
  tests/avocado/machine_aspeed.py: Update SDK images

Switch to the latest v8.06 release which introduces interesting
changes for the AST2600 I2C and I3C models. Also take the AST2600 A2
images instead of the default since QEMU tries to model The AST2600 A3
SoC.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 243975c0553a61646e7c24beaa12f4451536ea6b
      
https://github.com/qemu/qemu/commit/243975c0553a61646e7c24beaa12f4451536ea6b
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/ssi/ssi.c
    M include/hw/ssi/ssi.h

  Log Message:
  -----------
  hw/ssi: Add a "cs" property to SSIPeripheral

Boards will use this new property to identify the device CS line and
wire the SPI controllers accordingly.

Cc: Alistair Francis <alistair@alistair23.me>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 8a211fa3b2189735177f3c529dabc8ebc37042fa
      
https://github.com/qemu/qemu/commit/8a211fa3b2189735177f3c529dabc8ebc37042fa
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/ssi/ssi.c
    M include/hw/ssi/ssi.h

  Log Message:
  -----------
  hw/ssi: Introduce a ssi_get_cs() helper

Simple routine to retrieve a DeviceState object on a SPI bus using its
CS index. It will be useful for the board to wire the CS lines.

Cc: Alistair Francis <alistair@alistair23.me>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 27a2c66c92ec1f7a1e6456c8b274ae538d68ae7f
      
https://github.com/qemu/qemu/commit/27a2c66c92ec1f7a1e6456c8b274ae538d68ae7f
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/arm/aspeed.c
    M hw/ssi/aspeed_smc.c

  Log Message:
  -----------
  aspeed/smc: Wire CS lines at reset

Currently, a set of default flash devices is created at machine init
and drives defined on the QEMU command line are associated to the FMC
and SPI controllers in sequence :

   -drive file<file>,format=raw,if=mtd
   -drive file<file1>,format=raw,if=mtd

The CS lines are wired in the same creation loop. This makes a strong
assumption on the ordering and is not very flexible since only a
limited set of flash devices can be defined : 1 FMC + 1 or 2 SPI,
which is less than what the SoC really supports.

A better alternative would be to define the flash devices on the
command line using a blockdev attached to a CS line of a SSI bus :

    -blockdev node-name=fmc0,driver=file,filename=./flash.img
    -device mx66u51235f,cs=0x0,bus=ssi.0,drive=fmc0

However, user created flash devices are not correctly wired to their
SPI controller and consequently can not be used by the machine. Fix
that and wire the CS lines of all available devices when the SSI bus
is reset.

Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: a617e65f43788e08dd390aa41798b0e57b936c6d
      
https://github.com/qemu/qemu/commit/a617e65f43788e08dd390aa41798b0e57b936c6d
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/arm/stellaris.c
    M hw/arm/xilinx_zynq.c
    M hw/arm/xlnx-versal-virt.c
    M hw/arm/xlnx-zcu102.c
    M hw/microblaze/petalogix_ml605_mmu.c
    M hw/ssi/ssi.c

  Log Message:
  -----------
  hw/ssi: Check for duplicate CS indexes

This to avoid indexes conflicts on the same SSI bus. Adapt machines
using multiple devices on the same bus to avoid breakage.

Cc: "Edgar E. Iglesias" <edgar.iglesias@gmail.com>
Cc: Alistair Francis <alistair@alistair23.me>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: c7e313ae510ed037ca68a2861ab870de8042a779
      
https://github.com/qemu/qemu/commit/c7e313ae510ed037ca68a2861ab870de8042a779
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M docs/system/arm/aspeed.rst
    M hw/arm/aspeed.c

  Log Message:
  -----------
  aspeed: Create flash devices only when defaults are enabled

When the -nodefaults option is set, flash devices should be created
with :

    -blockdev node-name=fmc0,driver=file,filename=./flash.img \
    -device mx66u51235f,cs=0x0,bus=ssi.0,drive=fmc0 \

To be noted that in this case, the ROM will not be installed and the
initial boot sequence (U-Boot loading) will fetch instructions using
SPI transactions which is significantly slower. That's exactly how HW
operates though.

Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 9ab26b0eb14c818cf9d32e0881e99009df647076
      
https://github.com/qemu/qemu/commit/9ab26b0eb14c818cf9d32e0881e99009df647076
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/block/m25p80.c
    M include/hw/block/flash.h

  Log Message:
  -----------
  m25p80: Introduce an helper to retrieve the BlockBackend of a device

It will help in getting rid of some drive_get(IF_MTD) calls by
retrieving the BlockBackend directly from the m25p80 device.

Cc: Alistair Francis <alistair@alistair23.me>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 8285490b2b2a2c064e2e85df4b73b58194ce0445
      
https://github.com/qemu/qemu/commit/8285490b2b2a2c064e2e85df4b73b58194ce0445
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/arm/aspeed.c

  Log Message:
  -----------
  aspeed: Get the BlockBackend of FMC0 from the flash device

and get rid of an unnecessary drive_get(IF_MTD) call.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Joel Stanley <joel@jms.id.au>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 24965082a777f8041890c443230f3d0ae555d764
      
https://github.com/qemu/qemu/commit/24965082a777f8041890c443230f3d0ae555d764
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd/sdcard: Return ILLEGAL for CMD19/CMD23 prior SD spec v3.01

CMD19 (SEND_TUNING_BLOCK) and CMD23 (SET_BLOCK_COUNT) were
added in the Physical Layer Simplified Specification v3.01.
When earlier spec version is requested, we should return ILLEGAL.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20220509141320.98374-1-philippe.mathieu.daude@gmail.com>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 132011396f167fbf2199ad880163fe51fd40bd5d
      
https://github.com/qemu/qemu/commit/132011396f167fbf2199ad880163fe51fd40bd5d
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: When card is in wrong state, log which state it is

We report the card is in an inconsistent state, but don't precise
in which state it is. Add this information, as it is useful when
debugging problems.

Since we will reuse this code, extract as sd_invalid_state_for_cmd()
helper.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-2-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 94ef3041d21a00bb2d57c987c87c6eeb8812c488
      
https://github.com/qemu/qemu/commit/94ef3041d21a00bb2d57c987c87c6eeb8812c488
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: When card is in wrong state, log which spec version is used

Add the sd_version_str() helper.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 1b4a234278f04ade4dd358224edc3defcd37fda7
      
https://github.com/qemu/qemu/commit/1b4a234278f04ade4dd358224edc3defcd37fda7
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c
    M include/hw/sd/sd.h

  Log Message:
  -----------
  hw/sd: Move proto_name to SDProto structure

Introduce a new structure to hold the bus protocol specific
fields: SDProto. The first field is the protocol name.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-4-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 46859b6078bbd78c54693799f6ed1b90d1d5e565
      
https://github.com/qemu/qemu/commit/46859b6078bbd78c54693799f6ed1b90d1d5e565
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Introduce sd_cmd_handler type

Add 2 command handler arrays in SDProto, for CMD and ACMD.
Have sd_normal_command() / sd_app_command() use these arrays:
if an command handler is registered, call it, otherwise fall
back to current code base.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-5-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 583204d824c47a3390760c3b05a8c4ec1289139a
      
https://github.com/qemu/qemu/commit/583204d824c47a3390760c3b05a8c4ec1289139a
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_illegal() handler

Log illegal commands as GUEST_ERROR.

Note: we are logging back the SDIO commands (CMD5, CMD52-54).

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-6-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 7ffcbf3e58014f76fe30d81e8b3e5754fc65f640
      
https://github.com/qemu/qemu/commit/7ffcbf3e58014f76fe30d81e8b3e5754fc65f640
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_unimplemented() handler

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
[ clg: Fix redundant assignment of .cmd ]
Message-Id: <20210624142209.1193073-7-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: a6e0f67e77fc61ff9aff6b3ad6c1ed039ff926b2
      
https://github.com/qemu/qemu/commit/a6e0f67e77fc61ff9aff6b3ad6c1ed039ff926b2
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_GO_IDLE_STATE() handler

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-8-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 5c44e820096bbf9b897f668cb6d6dadb44ba5ff8
      
https://github.com/qemu/qemu/commit/5c44e820096bbf9b897f668cb6d6dadb44ba5ff8
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c
    M hw/sd/sdmmc-internal.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_SEND_OP_CMD() handler

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
[ clg: Update cmd_abbrev ]
Message-Id: <20210624142209.1193073-9-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: c4f2d9e150f7aa190dd601eb756e8c6fe196dd9f
      
https://github.com/qemu/qemu/commit/c4f2d9e150f7aa190dd601eb756e8c6fe196dd9f
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_ALL_SEND_CID() handler

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-10-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 41a0349d3ca6fde8d49a32f2c7f8b2bf83035c88
      
https://github.com/qemu/qemu/commit/41a0349d3ca6fde8d49a32f2c7f8b2bf83035c88
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_SEND_RELATIVE_ADDR() handler

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Message-Id: <20210624142209.1193073-11-f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 793d04f495197503d36a7ae4df99f8502e94886e
      
https://github.com/qemu/qemu/commit/793d04f495197503d36a7ae4df99f8502e94886e
  Author: Joel Stanley <joel@jms.id.au>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_SEND_TUNING_BLOCK() handler

Signed-off-by: Joel Stanley <joel@jms.id.au>
Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 6380cd20528bf994d7a8d0cd6660230df217d374
      
https://github.com/qemu/qemu/commit/6380cd20528bf994d7a8d0cd6660230df217d374
  Author: Philippe Mathieu-Daudé <f4bug@amsat.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/sd/sd.c

  Log Message:
  -----------
  hw/sd: Add sd_cmd_SET_BLOCK_COUNT() handler

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: c3287c0f70dae07dd12322c5c8663f7b878826e7
      
https://github.com/qemu/qemu/commit/c3287c0f70dae07dd12322c5c8663f7b878826e7
  Author: Cédric Le Goater <clg@kaod.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M hw/arm/stellaris.c
    M hw/riscv/sifive_u.c
    M hw/sd/sd.c
    M include/hw/sd/sd.h

  Log Message:
  -----------
  hw/sd: Introduce a "sd-card" SPI variant model

and replace the SDState::spi attribute with a test checking the
SDProto array of commands.

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Cédric Le Goater <clg@kaod.org>


  Commit: 90da7d552fbcb19d1fbf68b2051f0f168b8a48f9
      
https://github.com/qemu/qemu/commit/90da7d552fbcb19d1fbf68b2051f0f168b8a48f9
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M include/ui/qemu-pixman.h
    M ui/qemu-pixman.c

  Log Message:
  -----------
  ui: remove qemu_pixman_color() helper

Usage removed in commit e27bd65a72d ("console: switch color_table_rgb to 
pixman_color_t")

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230830093843.3531473-2-marcandre.lureau@redhat.com>


  Commit: 426749a7b79cf735dcd9bd4d134af5224fcf8210
      
https://github.com/qemu/qemu/commit/426749a7b79cf735dcd9bd4d134af5224fcf8210
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M include/ui/qemu-pixman.h
    M ui/qemu-pixman.c

  Log Message:
  -----------
  ui: remove qemu_pixman_linebuf_copy()

Since commit 43c7d8bd449 ("console: add qemu_pixman_linebuf_copy"), it
seems it was never used.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-3-marcandre.lureau@redhat.com>


  Commit: 4f2c765ba6b648f406b7d64ebbf0e4eaedf3d8be
      
https://github.com/qemu/qemu/commit/4f2c765ba6b648f406b7d64ebbf0e4eaedf3d8be
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M include/ui/console.h
    M ui/console.c
    M ui/ui-qmp-cmds.c

  Log Message:
  -----------
  ui/qmp: move screendump to ui-qmp-cmds.c

console.c unit is over-crowded. This code is specific to the handling of
the QMP screendump command, so move it in ui-qmp-cmds.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-4-marcandre.lureau@redhat.com>


  Commit: f1f7a1e2cfee7beee626552744efcc5a3867501f
      
https://github.com/qemu/qemu/commit/f1f7a1e2cfee7beee626552744efcc5a3867501f
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: replace vc_chr_write() with generic qemu_chr_write()

We shouldn't call the callback directly, but use the chardev API, unless
there is a clear reason.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230830093843.3531473-5-marcandre.lureau@redhat.com>


  Commit: 177422789be54447cfc2d770145968058e5d0b5c
      
https://github.com/qemu/qemu/commit/177422789be54447cfc2d770145968058e5d0b5c
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: drop have_text

If there are no "text" listener, the callback will simply be ignored.
The rest of text handling can be done cheaply.

This allows to remove some dependency on DisplayState from VC
implementation.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-6-marcandre.lureau@redhat.com>


  Commit: 074b24094f34c3241956064cf7910bbe11642871
      
https://github.com/qemu/qemu/commit/074b24094f34c3241956064cf7910bbe11642871
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: console_select() regardless of have_gfx

Even if we don't have a gfx listener, we should call
displaychangelistener_display_console() which handle that case correctly.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-7-marcandre.lureau@redhat.com>


  Commit: bc9b8bc93cafee6f3c9f73ef5e8a7379004e8699
      
https://github.com/qemu/qemu/commit/bc9b8bc93cafee6f3c9f73ef5e8a7379004e8699
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: call dpy_gfx_update() regardless of have_gfx

The function will handle the case when no listeners are gfx, without
extra meaningful cost.

This allows to get rid of DisplayState dependency in VC implementation.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-8-marcandre.lureau@redhat.com>


  Commit: cbcf0fa8fd9723ee51af803bf58a8d6d3e6a4194
      
https://github.com/qemu/qemu/commit/cbcf0fa8fd9723ee51af803bf58a8d6d3e6a4194
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: drop have_gfx

All usages have been removed.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-9-marcandre.lureau@redhat.com>


  Commit: 121c8dd69d7fa91558954eadc11bb6ce0474713c
      
https://github.com/qemu/qemu/commit/121c8dd69d7fa91558954eadc11bb6ce0474713c
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    A linux-user/aarch64/target_proc.h
    A linux-user/alpha/target_proc.h
    A linux-user/arm/target_proc.h
    A linux-user/cris/target_proc.h
    A linux-user/hexagon/target_proc.h
    A linux-user/hppa/target_proc.h
    A linux-user/i386/target_proc.h
    A linux-user/loongarch64/target_proc.h
    A linux-user/m68k/target_proc.h
    A linux-user/microblaze/target_proc.h
    A linux-user/mips/target_proc.h
    A linux-user/mips64/target_proc.h
    A linux-user/nios2/target_proc.h
    A linux-user/openrisc/target_proc.h
    A linux-user/ppc/target_proc.h
    A linux-user/riscv/target_proc.h
    A linux-user/s390x/target_proc.h
    A linux-user/sh4/target_proc.h
    A linux-user/sparc/target_proc.h
    M linux-user/syscall.c
    A linux-user/x86_64/target_proc.h
    A linux-user/xtensa/target_proc.h

  Log Message:
  -----------
  linux-user: Split out cpu/target_proc.h

Move the various open_cpuinfo functions into new files.
Move the m68k open_hardware function as well.
All other guest architectures get a boilerplate empty file.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: a55b9e72267085957cadb0af0a8811cfbd7c61a9
      
https://github.com/qemu/qemu/commit/a55b9e72267085957cadb0af0a8811cfbd7c61a9
  Author: Helge Deller <deller@gmx.de>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/aarch64/target_proc.h
    M linux-user/arm/target_proc.h
    M linux-user/elfload.c
    M linux-user/loader.h

  Log Message:
  -----------
  linux-user: Emulate /proc/cpuinfo on aarch64 and arm

Add emulation for /proc/cpuinfo for arm architecture.
The output below mimics output as seen on debian porterboxes.

aarch64 output example:

processor       : 0
model name      : ARMv8 Processor rev 0 (v8l)
BogoMIPS        : 100.00
Features        : swp half thumb fast_mult vfp edsp neon vfpv3 tls vfpv4 idiva 
idivt vfpd32 lpae aes pmull sha1 sha2 crc32
CPU implementer : 0x41
CPU architecture: 8
CPU variant     : 0x1
CPU part        : 0xd07
CPU revision    : 0

arm 32-bit output example:

processor       : 0
model name      : ARMv7 Processor rev 5 (armv7l)
BogoMIPS        : 100.00
Features        : swp half thumb fast_mult vfp edsp thumbee neon vfpv3 tls 
vfpv4 idiva idivt vfpd32 lpae
CPU implementer : 0x41
CPU architecture: 7
CPU variant     : 0x0f
CPU part        : 0xc07
CPU revision    : 5

Signed-off-by: Helge Deller <deller@gmx.de>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20230803214450.647040-3-deller@gmx.de>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 4757e2c771087520578d2a0fb2da5ec196899af7
      
https://github.com/qemu/qemu/commit/4757e2c771087520578d2a0fb2da5ec196899af7
  Author: Helge Deller <deller@gmx.de>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/alpha/target_proc.h

  Log Message:
  -----------
  linux-user: Emulate /proc/cpuinfo for Alpha

Add emulation for /proc/cpuinfo for the alpha architecture.

alpha output example:

(alpha-chroot)root@p100:/# cat /proc/cpuinfo
cpu                     : Alpha
cpu model               : ev67
cpu variation           : 0
cpu revision            : 0
cpu serial number       : JA00000000
system type             : QEMU
system variation        : QEMU_v8.0.92
system revision         : 0
system serial number    : AY00000000
cycle frequency [Hz]    : 250000000
timer frequency [Hz]    : 250.00
page size [bytes]       : 8192
phys. address bits      : 44
max. addr. space #      : 255
BogoMIPS                : 2500.00
platform string         : AlphaServer QEMU user-mode VM
cpus detected           : 8
cpus active             : 4
cpu active mask         : 0000000000000095
L1 Icache               : n/a
L1 Dcache               : n/a
L2 cache                : n/a
L3 cache                : n/a

Signed-off-by: Helge Deller <deller@gmx.de>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Message-Id: <20230803214450.647040-4-deller@gmx.de>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 79be812bdb6d476b35b0a0a9cda5432673b1f5f3
      
https://github.com/qemu/qemu/commit/79be812bdb6d476b35b0a0a9cda5432673b1f5f3
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M include/qemu/selfmap.h
    M linux-user/syscall.c
    M util/selfmap.c

  Log Message:
  -----------
  util/selfmap: Use dev_t and ino_t in MapInfo

Use dev_t instead of a string, and ino_t instead of uint64_t.
The latter is likely to be identical on modern systems but is
more type-correct for usage.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 7b7a3366e142d3baeb3fd1d3660a50e7956c19eb
      
https://github.com/qemu/qemu/commit/7b7a3366e142d3baeb3fd1d3660a50e7956c19eb
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: Use walk_memory_regions for open_self_maps

Replace the by-hand method of region identification with
the official user-exec interface.  Cross-check the region
provided to the callback with the interval tree from
read_self_maps().

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: aec338d63bc28f1f13d5e64c561d7f1dd0e4b07e
      
https://github.com/qemu/qemu/commit/aec338d63bc28f1f13d5e64c561d7f1dd0e4b07e
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/elfload.c

  Log Message:
  -----------
  linux-user: Adjust brk for load_bias

PIE executables are usually linked at offset 0 and are
relocated somewhere during load.  The hiaddr needs to
be adjusted to keep the brk next to the executable.

Cc: qemu-stable@nongnu.org
Fixes: 1f356e8c013 ("linux-user: Adjust initial brk when interpreter is close 
to executable")
Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 92d2a03f045f833fa96d8d1ed909d2bce68cefea
      
https://github.com/qemu/qemu/commit/92d2a03f045f833fa96d8d1ed909d2bce68cefea
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: Show heap address in /proc/pid/maps

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 6467d9eb4923f71d83d41fb603f072b6446be402
      
https://github.com/qemu/qemu/commit/6467d9eb4923f71d83d41fb603f072b6446be402
  Author: Ilya Leoshkevich <iii@linux.ibm.com>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/syscall.c

  Log Message:
  -----------
  linux-user: Emulate the Anonymous: keyword in /proc/self/smaps

Core dumps produced by gdb's gcore when connected to qemu's gdbstub
lack stack. The reason is that gdb includes only anonymous memory in
core dumps, which is distinguished by a non-0 Anonymous: value.

Consider the mappings with PAGE_ANON fully anonymous, and the mappings
without it fully non-anonymous.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Ilya Leoshkevich <iii@linux.ibm.com>
[rth: Update for open_self_maps_* rewrite]
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: f6d45542424f07247c11d074f3504a9eeb79e21c
      
https://github.com/qemu/qemu/commit/f6d45542424f07247c11d074f3504a9eeb79e21c
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/elfload.c
    M linux-user/qemu.h

  Log Message:
  -----------
  linux-user: Remove ELF_START_MMAP and image_info.start_mmap

The start_mmap value is write-only.
Remove the field and the defines that populated it.
Logically, this has been replaced by task_unmapped_base.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 225a206c4474f8344c8f0c13b735c414d0f170c7
      
https://github.com/qemu/qemu/commit/225a206c4474f8344c8f0c13b735c414d0f170c7
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/mmap.c
    M linux-user/syscall.c
    M linux-user/user-mmap.h

  Log Message:
  -----------
  linux-user: Move shmat and shmdt implementations to mmap.c

Rename from do_* to target_*.  Fix some minor checkpatch errors.

Tested-by: Helge Deller <deller@gmx.de>
Tested-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Warner Losh <imp@bsdimp.com>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 69fa2708a216df715ba5102a0f98468b540a464e
      
https://github.com/qemu/qemu/commit/69fa2708a216df715ba5102a0f98468b540a464e
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/mmap.c

  Log Message:
  -----------
  linux-user: Use WITH_MMAP_LOCK_GUARD in target_{shmat,shmdt}

Move the CF_PARALLEL setting outside of the mmap lock.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Helge Deller <deller@gmx.de>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: ceda5688b650646248f269a992c06b11148c5759
      
https://github.com/qemu/qemu/commit/ceda5688b650646248f269a992c06b11148c5759
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/mmap.c

  Log Message:
  -----------
  linux-user: Fix shmdt

If the shm region is not mapped at shmaddr, EINVAL.
Do not unmap the region until the syscall succeeds.
Use mmap_reserve_or_unmap to preserve reserved_va semantics.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 044e95c81e750a0605deb12a20ee23bfde7dc9c8
      
https://github.com/qemu/qemu/commit/044e95c81e750a0605deb12a20ee23bfde7dc9c8
  Author: Richard Henderson <richard.henderson@linaro.org>
  Date:   2023-09-01 (Fri, 01 Sep 2023)

  Changed paths:
    M linux-user/mmap.c

  Log Message:
  -----------
  linux-user: Track shm regions with an interval tree

Remove the fixed size shm_regions[] array.
Remove references when other mappings completely remove
or replace a region.

Tested-by: Helge Deller <deller@gmx.de>
Reviewed-by: Helge Deller <deller@gmx.de>
Signed-off-by: Richard Henderson <richard.henderson@linaro.org>


  Commit: 2fd319cff0ffbc0b54a61a2a34775ec40836e4c4
      
https://github.com/qemu/qemu/commit/2fd319cff0ffbc0b54a61a2a34775ec40836e4c4
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: get the DisplayState from new_console()

There is no obvious reason to defer text console initialization. We can
simply take the global display state in new_console().

This simplify somewhat the code to allow moving the VC to a separate unit.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-10-marcandre.lureau@redhat.com>


  Commit: dc6984bdc3ebe5357b0c1d983ba4e7689a985f2e
      
https://github.com/qemu/qemu/commit/dc6984bdc3ebe5357b0c1d983ba4e7689a985f2e
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: new_console() cannot fail

There is no code path that could allow a NULL return there.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-11-marcandre.lureau@redhat.com>


  Commit: 6657e41cde73597e61c0165da7be7e76f116f342
      
https://github.com/qemu/qemu/commit/6657e41cde73597e61c0165da7be7e76f116f342
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: VC always has a DisplayState now

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-12-marcandre.lureau@redhat.com>


  Commit: 8c63667b25cf377fa6ef46149ac55dc7e9e553db
      
https://github.com/qemu/qemu/commit/8c63667b25cf377fa6ef46149ac55dc7e9e553db
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: move VCChardev declaration at the top

To allow easier refactoring in following patches.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-13-marcandre.lureau@redhat.com>


  Commit: 3be82c6a3a983cd382aad2200fede5ec304dbc1e
      
https://github.com/qemu/qemu/commit/3be82c6a3a983cd382aad2200fede5ec304dbc1e
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: replace variable with static text attributes default

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-14-marcandre.lureau@redhat.com>


  Commit: d7c634aadf83e029b70b5d508fbfda4671e206d6
      
https://github.com/qemu/qemu/commit/d7c634aadf83e029b70b5d508fbfda4671e206d6
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: fold text_update_xy()

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-15-marcandre.lureau@redhat.com>


  Commit: 4c946b7f97e09e625d8c359f06f6b3e1ce937e89
      
https://github.com/qemu/qemu/commit/4c946b7f97e09e625d8c359f06f6b3e1ce937e89
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: pass VCCharDev to VC-specific functions

Even though they actually use more of QemuConsole at this point, it
makes it clearer those functions are only used from the chardev
implementation.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-16-marcandre.lureau@redhat.com>


  Commit: 6505fd8d2390e57c6a2e84f9c07b9e408ad7da76
      
https://github.com/qemu/qemu/commit/6505fd8d2390e57c6a2e84f9c07b9e408ad7da76
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: move VCCharDev specific fields out of QemuConsole

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-17-marcandre.lureau@redhat.com>


  Commit: e265917c77710ef721e4c333bccfecf030c7776c
      
https://github.com/qemu/qemu/commit/e265917c77710ef721e4c333bccfecf030c7776c
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: use OBJECT_DEFINE_TYPE for QemuConsole

The following patch will move some object initialization to the
corresponding handlers.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-18-marcandre.lureau@redhat.com>


  Commit: 098d57e7c0aa347f08f0738e8bd55b9a7faed8d7
      
https://github.com/qemu/qemu/commit/098d57e7c0aa347f08f0738e8bd55b9a7faed8d7
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: change new_console() to use object initialization

Object construction should be done in respective object instance and
class handlers.

Introduce qemu_console_register() to split out the registration logic.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-19-marcandre.lureau@redhat.com>


  Commit: b208f745a8af27344c7c8401560b312a4f4bd539
      
https://github.com/qemu/qemu/commit/b208f745a8af27344c7c8401560b312a4f4bd539
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: introduce different console objects

Boilerplate code to introduce different object types for the different
console types.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-20-marcandre.lureau@redhat.com>


  Commit: c105d60f7fe912cca558ce5ff5680bfd0c1300fa
      
https://github.com/qemu/qemu/commit/c105d60f7fe912cca558ce5ff5680bfd0c1300fa
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: instantiate a specific console type

This will allow to move code/data to the specific console types.

Replace console_type_t with object type check.

QemuConsole can be abstract.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-21-marcandre.lureau@redhat.com>


  Commit: ba0ec5c2931cd6efafc92bde3bd8fc3f99594fd3
      
https://github.com/qemu/qemu/commit/ba0ec5c2931cd6efafc92bde3bd8fc3f99594fd3
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: register the console from qemu_console_init()

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-22-marcandre.lureau@redhat.com>


  Commit: 34b7751574ebac7e19bfdb3ed0f91550c5ed171b
      
https://github.com/qemu/qemu/commit/34b7751574ebac7e19bfdb3ed0f91550c5ed171b
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: remove new_console()

The constructor helper isn't of much used now.

"head" is only specified for graphic console (and default to 0), and we
are going to move it to QemuGraphicConsole next.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-23-marcandre.lureau@redhat.com>


  Commit: f9411aaebd99e1efb04f0d32f01b37467e43b6a0
      
https://github.com/qemu/qemu/commit/f9411aaebd99e1efb04f0d32f01b37467e43b6a0
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M include/ui/console.h
    M ui/console.c

  Log Message:
  -----------
  ui/console: specialize console_lookup_unused()

graphics_console_init() is expected to return a graphic console.

The function doesn't need to be exported.

We are going to specialize further QemuGraphicConsole & QemuTextConsole.
The two will not be interchangeable anymore.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-24-marcandre.lureau@redhat.com>


  Commit: 7fa4b8041b870951642515e0954d274ec4d599b1
      
https://github.com/qemu/qemu/commit/7fa4b8041b870951642515e0954d274ec4d599b1
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: update the head from unused QemuConsole

When recycling unused QemuConsole, we should still set the associated
head number for correct information and lookups.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-25-marcandre.lureau@redhat.com>


  Commit: cfde05d15bbad620f87592edc2882611acbacc53
      
https://github.com/qemu/qemu/commit/cfde05d15bbad620f87592edc2882611acbacc53
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: allocate ui_timer in QemuConsole

Although at this point only QemuGraphicConsole have hw_ops that
implements ui_info() callback, it makes sense to keep the code in the
base QemuConsole, to simplify conditions for the caller.

As of now, the code didn't reach a NULL timer because dpy_set_ui_info()
checks if dpy_ui_info_supported() (hw_ops->ui_info != NULL), which is
false for text_console_ops. This is a bit fragile, let simply allocate
and free the timer in the base class.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-26-marcandre.lureau@redhat.com>


  Commit: b97a76d0355f8fc3856de9ebd4f6929b51ba26fb
      
https://github.com/qemu/qemu/commit/b97a76d0355f8fc3856de9ebd4f6929b51ba26fb
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: move cursor_timer initialization to QemuTextConsole class

The timer is only relevant when a text console exists.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-27-marcandre.lureau@redhat.com>


  Commit: 463c6b19c75313734e6e1b624d6b89dd8eb62516
      
https://github.com/qemu/qemu/commit/463c6b19c75313734e6e1b624d6b89dd8eb62516
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: free more QemuConsole resources

This code path is probably not executed at this point, since console
aren't being released.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-28-marcandre.lureau@redhat.com>


  Commit: b2bb9cc43dbb942a5333a6271629fd6094771bca
      
https://github.com/qemu/qemu/commit/b2bb9cc43dbb942a5333a6271629fd6094771bca
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: move text fields to QemuTextConsole

Now we can instantiate the specific console with its own fields. Pass
the most appropriate type to the various functions, and cast up to
QEMU_CONSOLE as necessary.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-29-marcandre.lureau@redhat.com>


  Commit: 58d5870845c61cea1e7df287b86c2607b2bf48a9
      
https://github.com/qemu/qemu/commit/58d5870845c61cea1e7df287b86c2607b2bf48a9
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: move graphic fields to QemuGraphicConsole

Move fields specific to graphic console to the console subclass.

qemu_console_get_head() is adapated to accomodate QemuTextConsole, and
always returns 0.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-30-marcandre.lureau@redhat.com>


  Commit: 98ee9dab81b2bc75d6ccf86681053ed80f9fc9af
      
https://github.com/qemu/qemu/commit/98ee9dab81b2bc75d6ccf86681053ed80f9fc9af
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: fold text_console_do_init() in vc_chr_open()

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230830093843.3531473-31-marcandre.lureau@redhat.com>


  Commit: 60cb14b4f9d94d750640f42e0f18a1710b8d6c1a
      
https://github.com/qemu/qemu/commit/60cb14b4f9d94d750640f42e0f18a1710b8d6c1a
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: move some text console initialization to qom handlers

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-32-marcandre.lureau@redhat.com>


  Commit: 5e5a30b7d17f207a85af167ba3efdeff2b1f61de
      
https://github.com/qemu/qemu/commit/5e5a30b7d17f207a85af167ba3efdeff2b1f61de
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: simplify getting active_console size

We can get the active console dimension regardless of its kind, by
simply giving NULL as argument. It will fallback with the given value
when the dimensions aren't known.

This will also allow to move the code in a separate unit more easily.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-33-marcandre.lureau@redhat.com>


  Commit: 6ce7b1fa8844db668f0a3c0b37b78b08d331a16a
      
https://github.com/qemu/qemu/commit/6ce7b1fa8844db668f0a3c0b37b78b08d331a16a
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: remove need for g_width/g_height

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-34-marcandre.lureau@redhat.com>


  Commit: 742a6896ea1b83894e68b2dc455b63cea498bafc
      
https://github.com/qemu/qemu/commit/742a6896ea1b83894e68b2dc455b63cea498bafc
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: use common text console surface creation

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-35-marcandre.lureau@redhat.com>


  Commit: 8c6381d84668ff9b6324bf00b91107cbcaf7505f
      
https://github.com/qemu/qemu/commit/8c6381d84668ff9b6324bf00b91107cbcaf7505f
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M include/ui/console.h
    M ui/console.c

  Log Message:
  -----------
  ui/console: declare console types in console.h

We are going to split the console.c unit next, and implement
separately. But we need to check the underlying type in various places.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-36-marcandre.lureau@redhat.com>


  Commit: 1ece6777fe1770f8a26f6887be96b21edfd0e442
      
https://github.com/qemu/qemu/commit/1ece6777fe1770f8a26f6887be96b21edfd0e442
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M include/ui/qemu-pixman.h
    M ui/console.c

  Log Message:
  -----------
  ui/console: use QEMU_PIXMAN_COLOR helpers

QEMU_RGB macro is actually defining a pixman color. Make this explicit
in the macro name. Move it to qemu-pixman.h so it can be used elsewhere,
as done in the following patch. Finally, define
QEMU_PIXMAN_COLOR_{BLACK,GRAY}, to avoid need to look up the VGA color
table from the QemuConsole placeholder surface rendering.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230830093843.3531473-37-marcandre.lureau@redhat.com>


  Commit: b704a8ce0c17f2f9f50a62cbe9053ef587c35db4
      
https://github.com/qemu/qemu/commit/b704a8ce0c17f2f9f50a62cbe9053ef587c35db4
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: rename vga_ functions with qemu_console_

They are not specific to VGA. Let's use the object type name as prefix
instead, to avoid confusion.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230830093843.3531473-38-marcandre.lureau@redhat.com>


  Commit: 0a1642e7ccdadf6c3da670369eeceec410dce058
      
https://github.com/qemu/qemu/commit/0a1642e7ccdadf6c3da670369eeceec410dce058
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: assert(surface) where appropriate

The QemuTextConsole code paths assume a surface is being used as
scanout, let's make this more explicit.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-39-marcandre.lureau@redhat.com>


  Commit: 3f9c21325c4c2005a852744db1016c479d60cb55
      
https://github.com/qemu/qemu/commit/3f9c21325c4c2005a852744db1016c479d60cb55
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: fold text_console_update_cursor_timer

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Message-Id: <20230830093843.3531473-40-marcandre.lureau@redhat.com>


  Commit: 9cb737b77d9cc43a9bed305cbb105928a3dda54b
      
https://github.com/qemu/qemu/commit/9cb737b77d9cc43a9bed305cbb105928a3dda54b
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/vc: skip text console resize when possible

This function is called on invalidate, on each cursor blink.

Avoid the extra copy when the console size didn't change.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-41-marcandre.lureau@redhat.com>


  Commit: 893fe23e7dc675d650a4da710efe62a53c2341ee
      
https://github.com/qemu/qemu/commit/893fe23e7dc675d650a4da710efe62a53c2341ee
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/console.c

  Log Message:
  -----------
  ui/console: minor stylistic changes

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-42-marcandre.lureau@redhat.com>


  Commit: 322dae4bc817fe288a103427f53de2a945daca27
      
https://github.com/qemu/qemu/commit/322dae4bc817fe288a103427f53de2a945daca27
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M include/ui/console.h
    M ui/console.c

  Log Message:
  -----------
  ui/vc: move text console invalidate in helper

This will allow to split the VC code in a separate unit more easily.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-43-marcandre.lureau@redhat.com>


  Commit: 32aa1f8dee3b2e8a4606bc2836a022f1ff5e7f0c
      
https://github.com/qemu/qemu/commit/32aa1f8dee3b2e8a4606bc2836a022f1ff5e7f0c
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M include/chardev/char.h
    M qapi/char.json
    M ui/console.c
    M ui/gtk.c
    M ui/spice-app.c

  Log Message:
  -----------
  ui/vc: do not parse VC-specific options in Spice and GTK

In commit 6f974c843c ("gtk: overwrite the console.c char driver"), I
shared the VC console parse handler with GTK. And later on in commit
d8aec9d9 ("display: add -display spice-app launching a Spice client"),
I also used it to handle spice-app VC.

This is not necessary, the VC console options (width/height/cols/rows)
are specific, and unused by tty-level GTK/Spice VC.

This is not a breaking change, as those options are still being parsed
by QAPI ChardevVC. Adjust the documentation about it.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-44-marcandre.lureau@redhat.com>


  Commit: 9db018ac56119ee8e0a87a1a340276e4c8d86392
      
https://github.com/qemu/qemu/commit/9db018ac56119ee8e0a87a1a340276e4c8d86392
  Author: Marc-André Lureau <marcandre.lureau@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M include/ui/console.h
    M ui/console.c
    M ui/gtk.c
    M ui/sdl2-input.c
    M ui/sdl2.c

  Log Message:
  -----------
  ui/vc: change the argument for QemuTextConsole

Those functions are specifc to text/vc console, make that explicit from
the argument type.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20230830093843.3531473-45-marcandre.lureau@redhat.com>


  Commit: 1663ffb9157e3dc17d14741f6cd6c48bfffde9d0
      
https://github.com/qemu/qemu/commit/1663ffb9157e3dc17d14741f6cd6c48bfffde9d0
  Author: Peter Maydell <peter.maydell@linaro.org>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/spice-display.c

  Log Message:
  -----------
  ui/spice-display: Avoid dynamic stack allocation

Use an autofree heap allocation instead of a variable-length
array on the stack in qemu_spice_create_update().

The codebase has very few VLAs, and if we can get rid of them all we
can make the compiler error on new additions.  This is a defensive
measure against security bugs where an on-stack dynamic allocation
isn't correctly size-checked (e.g.  CVE-2021-3527).

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230818151057.1541189-2-peter.maydell@linaro.org>


  Commit: e12acaf75d1ffadfd527180dac798368716a0001
      
https://github.com/qemu/qemu/commit/e12acaf75d1ffadfd527180dac798368716a0001
  Author: Peter Maydell <peter.maydell@linaro.org>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/vnc-enc-hextile-template.h

  Log Message:
  -----------
  ui/vnc-enc-hextile: Use static rather than dynamic length stack array

In the send_hextile_tile_* function we create a variable length array
data[].  In fact we know that the client_pf.bytes_per_pixel is at
most 4 (enforced by set_pixel_format()), so we can make the array a
compile-time fixed length of 1536 bytes.

The codebase has very few VLAs, and if we can get rid of them all we
can make the compiler error on new additions.  This is a defensive
measure against security bugs where an on-stack dynamic allocation
isn't correctly size-checked (e.g.  CVE-2021-3527).

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>
[ Marc-André - rename BPP to MAX_BYTES_PER_PIXEL ]
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230818151057.1541189-3-peter.maydell@linaro.org>


  Commit: dd0439e1496ad326dcaa7dc67f91f2e6f6c4930b
      
https://github.com/qemu/qemu/commit/dd0439e1496ad326dcaa7dc67f91f2e6f6c4930b
  Author: Philippe Mathieu-Daudé <philmd@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/vnc-enc-tight.c

  Log Message:
  -----------
  ui/vnc-enc-tight: Avoid dynamic stack allocation

Use autofree heap allocation instead of variable-length
array on the stack.

The codebase has very few VLAs, and if we can get rid of them all we
can make the compiler error on new additions.  This is a defensive
measure against security bugs where an on-stack dynamic allocation
isn't correctly size-checked (e.g.  CVE-2021-3527).

Signed-off-by: Philippe Mathieu-Daudé <philmd@redhat.com>
[PMM: expanded commit message]
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Francisco Iglesias <frasse.iglesias@gmail.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230818151057.1541189-4-peter.maydell@linaro.org>


  Commit: cb6ccdc9ca705cd8c3ef50e51c16a3732c2fa734
      
https://github.com/qemu/qemu/commit/cb6ccdc9ca705cd8c3ef50e51c16a3732c2fa734
  Author: Bilal Elmoussaoui <belmouss@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/dbus-console.c

  Log Message:
  -----------
  ui/dbus: Properly dispose touch/mouse dbus objects

Fixes: 142ca628a7 ("ui: add a D-Bus display backend")
Fixes: de9f844ce2 ("ui/dbus: Expose a touch device interface")

Signed-off-by: Bilal Elmoussaoui <belmouss@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230901124507.94087-1-belmouss@redhat.com>


  Commit: 7007e98c4ba443ce5d42acf851daaa1835b18e83
      
https://github.com/qemu/qemu/commit/7007e98c4ba443ce5d42acf851daaa1835b18e83
  Author: Bilal Elmoussaoui <belmouss@redhat.com>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/dbus-listener.c

  Log Message:
  -----------
  ui/dbus: implement damage regions for GL

Currently, when using `-display dbus,gl=on` all updates to the client
become "full scanout" updates, meaning there is no way for the client to
limit damage regions to the display server.

Instead of using an "update count", this patch tracks the damage region
and propagates it to the client.

This was less of an issue when clients were using GtkGLArea for
rendering,
as you'd be doing full-surface redraw. To be efficient, the client needs
both a DMA-BUF and the damage region to be updated.

Co-authored-by: Christian Hergert <chergert@redhat.com>
Signed-off-by: Bilal Elmoussaoui <belmouss@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230814125802.102160-1-belmouss@redhat.com>


  Commit: 1b4fd51656556646b1a0842e596cb606d73e26cf
      
https://github.com/qemu/qemu/commit/1b4fd51656556646b1a0842e596cb606d73e26cf
  Author: Guoyi Tu <tugy@chinatelecom.cn>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/vdagent.c

  Log Message:
  -----------
  ui/vdagent: call vdagent_disconnect() when agent connection is lost

when the agent connection is lost, the input handler of the mouse
doesn't deactivate, which results in unresponsive mouse events in
VNC windows.

To fix this issue, call vdagent_disconnect() to reset the state
each time the frontend disconncect

Signed-off-by: Guoyi Tu <tugy@chinatelecom.cn>
Signed-off-by: dengpengcheng <dengpc12@chinatelecom.cn>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: 
<71fd5a58fd09f10cdb35f167b2edb5669300116e.1692281173.git.tugy@chinatelecom.cn>


  Commit: 878490937c6273f27191e3a195c7a60fa68819b8
      
https://github.com/qemu/qemu/commit/878490937c6273f27191e3a195c7a60fa68819b8
  Author: Guoyi Tu <tugy@chinatelecom.cn>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/vdagent.c

  Log Message:
  -----------
  ui/vdagent: Unregister input handler of mouse during finalization

Input handler resource should be released when
VDAgentChardev object finalize

Signed-off-by: Guoyi Tu <tugy@chinatelecom.cn>
Signed-off-by: dengpengcheng <dengpc12@chinatelecom.cn>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: 
<e7f5e172abf797d454e00a4bbe53af83e4aa4497.1692281173.git.tugy@chinatelecom.cn>


  Commit: e38f4e976dd40c985bfe84230a627de9a108c9d3
      
https://github.com/qemu/qemu/commit/e38f4e976dd40c985bfe84230a627de9a108c9d3
  Author: Dmitry Frolov <frolov@swemel.ru>
  Date:   2023-09-04 (Mon, 04 Sep 2023)

  Changed paths:
    M ui/gtk.c

  Log Message:
  -----------
  ui/gtk: fix leaks found wtih fuzzing

It is true, that there is no problem during runtime
from the first sight, because the memory is lost just
before qemu exits. Nevertheless, this change is necessary,
because AddressSanitizer is not able to recognize this
situation and produces crash-report (which is
false-positive in fact). Lots of False-Positive warnings
are davaluing problems, found with fuzzing, and thus the
whole methodology of dynamic analysis.
This patch eliminates such False-Positive reports,
and makes every problem, found with fuzzing, more valuable.

Fixes: 060ab76356 ("gtk: don't exit early in case gtk init fails")

Signed-off-by: Dmitry Frolov <frolov@swemel.ru>
Reviewed-by: Michael Tokarev <mjt@tls.msk.ru>
Message-Id: <20230825115818.1091936-1-frolov@swemel.ru>


  Commit: 912a9efd6bf4d808b238e17d26de2e4bb9bc4743
      
https://github.com/qemu/qemu/commit/912a9efd6bf4d808b238e17d26de2e4bb9bc4743
  Author: Stefan Hajnoczi <stefanha@redhat.com>
  Date:   2023-09-06 (Wed, 06 Sep 2023)

  Changed paths:
    M docs/system/arm/aspeed.rst
    M hw/arm/aspeed.c
    M hw/arm/stellaris.c
    M hw/arm/xilinx_zynq.c
    M hw/arm/xlnx-versal-virt.c
    M hw/arm/xlnx-zcu102.c
    M hw/block/m25p80.c
    M hw/i2c/aspeed_i2c.c
    M hw/microblaze/petalogix_ml605_mmu.c
    M hw/riscv/sifive_u.c
    M hw/sd/sd.c
    M hw/sd/sdmmc-internal.c
    M hw/ssi/aspeed_smc.c
    M hw/ssi/ssi.c
    M include/hw/block/flash.h
    M include/hw/i2c/aspeed_i2c.h
    M include/hw/sd/sd.h
    M include/hw/ssi/ssi.h
    M tests/avocado/machine_aspeed.py

  Log Message:
  -----------
  Merge tag 'pull-aspeed-20230901' of https://github.com/legoater/qemu into 
staging

aspeed queue:

* Fixes for the Aspeed I2C model
* New SDK image for avocado tests
* blockdev support for flash device definition
* SD refactoring preparing ground for eMMC support

# -----BEGIN PGP SIGNATURE-----
#
# iQIzBAABCAAdFiEEoPZlSPBIlev+awtgUaNDx8/77KEFAmTxsaQACgkQUaNDx8/7
# 7KGXmg//XJNisscl/VWSBaGmH5MbQUAg/QCRalXx1V/lJ8rhE/JqwnWKuoPFd4EN
# iDlh3ufpzxPhHFc9boechuM5ytlrJxpLJoCIJ4sw/4qnO3Dy3Q6BCy1t8Ma62D1u
# oE7cAMHsriJ1uTJNHUTFo72VapTaH2XwFN9lFDuQW45d+WWAXtVJsqvRgFETNmw6
# YYnTTpH2gLTZZFEgOixhWpGLh4Ibc/l8U1VzL0ctQmC11xng0bqk3PAqU9NGzcM5
# MJmEGAxg43CnFu9NJI1nMqC/coi/8PFtrM7HprSwE3H8Jkwncs4ePVT+kZQC+VNQ
# 7EaVkksfEGHlN8XP5+eQDrQ5yT6ve+fbHTLQhwULfeyt0GlQ8h1yewvHCDWo/zw3
# XI1ZyOcNZ2yiaenSUrTPzu0LiqZEJQnzRjPCpgTi1fU08ryEMEaPtr176YDLCguQ
# cpRj4QSZHCrGl/Eo9NlkFP/2rQDKTvCcedKPkYLQtsurSiH/36Oj9YvZycNtZ574
# ortKAtru4YV/rglNX4L8JDhdI+nqvy1liifpJsiS/2KBZDpVFaP8PzGIV40HNy3G
# 8/LVTnaggZaScF3ftHhkg84uQumELS9l2dhsNCL9HqdlrNXLQrVAIR6iuQlpOKBa
# 5S/6h7ZXGOb1qNVQjYp4HCrB7X1KIJYksZ3GdUREf8ot5Ds1FhE=
# =ymmX
# -----END PGP SIGNATURE-----
# gpg: Signature made Fri 01 Sep 2023 05:40:52 EDT
# gpg:                using RSA key A0F66548F04895EBFE6B0B6051A343C7CFFBECA1
# gpg: Good signature from "Cédric Le Goater <clg@redhat.com>" [unknown]
# gpg:                 aka "Cédric Le Goater <clg@kaod.org>" [unknown]
# gpg: WARNING: This key is not certified with a trusted signature!
# gpg:          There is no indication that the signature belongs to the owner.
# Primary key fingerprint: A0F6 6548 F048 95EB FE6B  0B60 51A3 43C7 CFFB ECA1

* tag 'pull-aspeed-20230901' of https://github.com/legoater/qemu: (26 commits)
  hw/sd: Introduce a "sd-card" SPI variant model
  hw/sd: Add sd_cmd_SET_BLOCK_COUNT() handler
  hw/sd: Add sd_cmd_SEND_TUNING_BLOCK() handler
  hw/sd: Add sd_cmd_SEND_RELATIVE_ADDR() handler
  hw/sd: Add sd_cmd_ALL_SEND_CID() handler
  hw/sd: Add sd_cmd_SEND_OP_CMD() handler
  hw/sd: Add sd_cmd_GO_IDLE_STATE() handler
  hw/sd: Add sd_cmd_unimplemented() handler
  hw/sd: Add sd_cmd_illegal() handler
  hw/sd: Introduce sd_cmd_handler type
  hw/sd: Move proto_name to SDProto structure
  hw/sd: When card is in wrong state, log which spec version is used
  hw/sd: When card is in wrong state, log which state it is
  hw/sd/sdcard: Return ILLEGAL for CMD19/CMD23 prior SD spec v3.01
  aspeed: Get the BlockBackend of FMC0 from the flash device
  m25p80: Introduce an helper to retrieve the BlockBackend of a device
  aspeed: Create flash devices only when defaults are enabled
  hw/ssi: Check for duplicate CS indexes
  aspeed/smc: Wire CS lines at reset
  hw/ssi: Introduce a ssi_get_cs() helper
  ...

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>


  Commit: bde438c3ecdb9813038b226c429dd982925d8205
      
https://github.com/qemu/qemu/commit/bde438c3ecdb9813038b226c429dd982925d8205
  Author: Stefan Hajnoczi <stefanha@redhat.com>
  Date:   2023-09-06 (Wed, 06 Sep 2023)

  Changed paths:
    M include/qemu/selfmap.h
    A linux-user/aarch64/target_proc.h
    A linux-user/alpha/target_proc.h
    A linux-user/arm/target_proc.h
    A linux-user/cris/target_proc.h
    M linux-user/elfload.c
    A linux-user/hexagon/target_proc.h
    A linux-user/hppa/target_proc.h
    A linux-user/i386/target_proc.h
    M linux-user/loader.h
    A linux-user/loongarch64/target_proc.h
    A linux-user/m68k/target_proc.h
    A linux-user/microblaze/target_proc.h
    A linux-user/mips/target_proc.h
    A linux-user/mips64/target_proc.h
    M linux-user/mmap.c
    A linux-user/nios2/target_proc.h
    A linux-user/openrisc/target_proc.h
    A linux-user/ppc/target_proc.h
    M linux-user/qemu.h
    A linux-user/riscv/target_proc.h
    A linux-user/s390x/target_proc.h
    A linux-user/sh4/target_proc.h
    A linux-user/sparc/target_proc.h
    M linux-user/syscall.c
    M linux-user/user-mmap.h
    A linux-user/x86_64/target_proc.h
    A linux-user/xtensa/target_proc.h
    M util/selfmap.c

  Log Message:
  -----------
  Merge tag 'pull-lu-20230901' of https://gitlab.com/rth7680/qemu into staging

linux-user: Rewrite and improve /proc/pid/maps
linux-user: Fix shmdt and improve shm region tracking
linux-user: Remove ELF_START_MMAP and image_info.start_mmap

# -----BEGIN PGP SIGNATURE-----
#
# iQFRBAABCgA7FiEEekgeeIaLTbaoWgXAZN846K9+IV8FAmTyTEcdHHJpY2hhcmQu
# aGVuZGVyc29uQGxpbmFyby5vcmcACgkQZN846K9+IV8aZAf/UVKDv0FwEzxn3wzx
# pT+NbP4adHCew5ovDq94In9OpwG4+PtZj3x+EdPCFxAvVb9KdOs001a9zSRYSwWi
# 0p9ZkOgtq58/Wr34dl6C8oPZP8bnw7hfVcXWYwdsBq9K+dmW9Tu4LgZSc92NWYiE
# SGBATB/cF4keLlDJrm1YBfb6cVKmYHdgQzMHr4g4TitBOO3lic8HQglXN8eKvQyd
# ZKuMxFwfSGjaNXsoBLmzPBEqJCLzj5JNtOb8maIN9oPTkkC66XvkBmD/4UrQ7K3x
# aX2QgZpxZYZsyKfWJd4EkrJl+0JZYvGW4vBX1c+vBdIYQZoBHlWwZQBqsi+AMA6J
# ASc3hQ==
# =QWfr
# -----END PGP SIGNATURE-----
# gpg: Signature made Fri 01 Sep 2023 16:40:39 EDT
# gpg:                using RSA key 7A481E78868B4DB6A85A05C064DF38E8AF7E215F
# gpg:                issuer "richard.henderson@linaro.org"
# gpg: Good signature from "Richard Henderson <richard.henderson@linaro.org>" 
[full]
# Primary key fingerprint: 7A48 1E78 868B 4DB6 A85A  05C0 64DF 38E8 AF7E 215F

* tag 'pull-lu-20230901' of https://gitlab.com/rth7680/qemu:
  linux-user: Track shm regions with an interval tree
  linux-user: Fix shmdt
  linux-user: Use WITH_MMAP_LOCK_GUARD in target_{shmat,shmdt}
  linux-user: Move shmat and shmdt implementations to mmap.c
  linux-user: Remove ELF_START_MMAP and image_info.start_mmap
  linux-user: Emulate the Anonymous: keyword in /proc/self/smaps
  linux-user: Show heap address in /proc/pid/maps
  linux-user: Adjust brk for load_bias
  linux-user: Use walk_memory_regions for open_self_maps
  util/selfmap: Use dev_t and ino_t in MapInfo
  linux-user: Emulate /proc/cpuinfo for Alpha
  linux-user: Emulate /proc/cpuinfo on aarch64 and arm
  linux-user: Split out cpu/target_proc.h

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>


  Commit: c152379422a204109f34ca2b43ecc538c7d738ae
      
https://github.com/qemu/qemu/commit/c152379422a204109f34ca2b43ecc538c7d738ae
  Author: Stefan Hajnoczi <stefanha@redhat.com>
  Date:   2023-09-06 (Wed, 06 Sep 2023)

  Changed paths:
    M include/chardev/char.h
    M include/ui/console.h
    M include/ui/qemu-pixman.h
    M qapi/char.json
    M ui/console.c
    M ui/dbus-console.c
    M ui/dbus-listener.c
    M ui/gtk.c
    M ui/qemu-pixman.c
    M ui/sdl2-input.c
    M ui/sdl2.c
    M ui/spice-app.c
    M ui/spice-display.c
    M ui/ui-qmp-cmds.c
    M ui/vdagent.c
    M ui/vnc-enc-hextile-template.h
    M ui/vnc-enc-tight.c

  Log Message:
  -----------
  Merge tag 'ui-pull-request' of https://gitlab.com/marcandre.lureau/qemu into 
staging

UI patch queue

- misc fixes and improvement
- cleanups and refactoring in ui/vc code

# -----BEGIN PGP SIGNATURE-----
#
# iQJQBAABCAA6FiEEh6m9kz+HxgbSdvYt2ujhCXWWnOUFAmT1wuYcHG1hcmNhbmRy
# ZS5sdXJlYXVAcmVkaGF0LmNvbQAKCRDa6OEJdZac5UhmD/wPCVZ/Vipmbexc8eBd
# wbI7i0zR5Hj7szU4D1MV+fvi5Y6Z7PWvPxnQOIoWbmEGuhOm5P73oRz1jlBDXGLP
# Nh1kh2RvuWILF0Vu+QjJHL5FyA0XJcl/Qhsn1tc7pYMbEOBCpPfpmWRiXrEUDc7/
# S1iSPkB2a7YYwuMW6ksPyKlsb4tjGyea/HYz1lTdw8bJxaFVXMFX35lrqz+A5ZGz
# XAk/6OyMtkMbBi8hWcd6IweYyc/DYaK8emqppQLIUenZEz7nKSWlEUIKcXpf9U4n
# 3W+BISACxnw7KbXrrZl2KJf2Bix6LRureoscZTKawnB/D5hV+g7PtEjNMUQsxjg3
# RyV9+zSPsIg5zXunrHIs1rrUtGS5SvdQbIQYqHPNdL86iuWKer+EnwA06vflweLw
# P7FZhuBNvuY3gU2sdCk5Q7My92YT5DRWjoJRHLFGNYTxPA6MYPivIu8RqsBiu+JX
# BvK1FfhG2JsR9XuuOFR968AXLfMc0hOlHfHWvORk3s/9zIpeEWmQbnGxr1sN9El8
# o+rDIkcadELuzcTJcoHCKdCzjFbLdNNKgvbcVQdw3rdp2rvQ6CZalyh+qZEihAy4
# xLVO+hUypxNhRAg/DtZilUW6cPavn0OjoH/3BgY0F0GiwvhFMntyVGN7eBdwnC7c
# sV5s4Xnafmh5xnGf0GS3UyuX9g==
# =JxZP
# -----END PGP SIGNATURE-----
# gpg: Signature made Mon 04 Sep 2023 07:43:34 EDT
# gpg:                using RSA key 87A9BD933F87C606D276F62DDAE8E10975969CE5
# gpg:                issuer "marcandre.lureau@redhat.com"
# gpg: Good signature from "Marc-André Lureau <marcandre.lureau@redhat.com>" 
[full]
# gpg:                 aka "Marc-André Lureau <marcandre.lureau@gmail.com>" 
[full]
# Primary key fingerprint: 87A9 BD93 3F87 C606 D276  F62D DAE8 E109 7596 9CE5

* tag 'ui-pull-request' of https://gitlab.com/marcandre.lureau/qemu: (52 
commits)
  ui/gtk: fix leaks found wtih fuzzing
  ui/vdagent: Unregister input handler of mouse during finalization
  ui/vdagent: call vdagent_disconnect() when agent connection is lost
  ui/dbus: implement damage regions for GL
  ui/dbus: Properly dispose touch/mouse dbus objects
  ui/vnc-enc-tight: Avoid dynamic stack allocation
  ui/vnc-enc-hextile: Use static rather than dynamic length stack array
  ui/spice-display: Avoid dynamic stack allocation
  ui/vc: change the argument for QemuTextConsole
  ui/vc: do not parse VC-specific options in Spice and GTK
  ui/vc: move text console invalidate in helper
  ui/console: minor stylistic changes
  ui/vc: skip text console resize when possible
  ui/console: fold text_console_update_cursor_timer
  ui/console: assert(surface) where appropriate
  ui/console: rename vga_ functions with qemu_console_
  ui/console: use QEMU_PIXMAN_COLOR helpers
  ui/console: declare console types in console.h
  ui/vc: use common text console surface creation
  ui/console: remove need for g_width/g_height
  ...

Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>


Compare: https://github.com/qemu/qemu/compare/2d8fbcb1eecd...c152379422a2



reply via email to

[Prev in Thread] Current Thread [Next in Thread]