MIPS patches for 2022-06-11
From: Philippe Mathieu-Daudé <[email protected]>
Hi Richard,
In case it is not too late, this v2 includes another fix from Bernhard which was supposed to be in v1. Otherwise it will go in the next PR.
The following changes since commit 30796f556790631c86c733ab06756981be0e1def:
Merge tag 'for_upstream' of git://git.kernel.org/pub/scm/virt/kvm/mst/qemu into staging (2022-06-10 18:15:34 -0700)
are available in the Git repository at:
https://github.com/philmd/qemu.git tags/mips-20220611
for you to fetch changes up to 6e0c18598814bffb67204a90890fb7b34cad288a:
docs/devel: Fix link to developer mailing lists (2022-06-11 23:50:35 +0200)
----------------------------------------------------------------
MIPS patches queue
- Various TCG fixes (Marcin Nowakowski, Ni Hui, Stefan Pejic, Stefan Pejic)
- Sysbus floppy controller fix (Peter Maydell)
- QOM'ification of PIIX southbridge (Mark Cave-Ayland, Bernhard Beschow)
- Various fixes on ISA devices commonly used by x86/mips machines (Bernhard)
- Few cleanups in accel/tcg & documentation (Bernhard)
----------------------------------------------------------------
Bernhard Beschow (24):
hw/southbridge/piix: Aggregate all PIIX southbridge type names hw/isa/piix4: Use object_initialize_child() for embedded struct hw/isa/piix4: Move pci_map_irq_fn' near pci_set_irq_fn hw/isa/piix4: QOM'ify PCI device creation and wiring hw/isa/piix4: Factor out ISABus retrieval from piix4_create() hw/isa/piix4: QOM'ify PIIX4 PM creation
hw/isa/piix4: Inline and remove piix4_create() hw/isa/piix3: Move pci_map_irq_fn near pci_set_irq_fn hw/isa/piix3: QOM'ify PCI device creation and wiring hw/isa/piix3: Factor out ISABus retrieval from piix3_create() hw/isa/piix3: Inline and remove piix3_create() hw/i386/microvm-dt: Force explicit failure if retrieving QOM property
fails
hw/i386/microvm-dt: Determine mc146818rtc's IRQ number from QOM
property
hw/rtc/mc146818rtc: QOM'ify io_base offset
hw: Reuse TYPE_I8042 define
hw/audio/cs4231a: Const'ify global tables
hw/i386/pc: Unexport PC_CPU_MODEL_IDS macro
hw/i386/pc: Unexport functions used only internally hw/i386/pc: Remove orphan declarations hw/net/fsl_etsec/etsec: Remove obsolete and unused etsec_create() hw/mips/boston: Initialize g_autofree pointers accel/tcg/cpu-exec: Unexport dump_drift_info()
accel/tcg: Inline dump_opcount_info() and remove it docs/devel: Fix link to developer mailing lists
Dragan Mladjenovic (4):
target/mips: Fix emulation of nanoMIPS EXTRV_S.H instruction target/mips: Fix emulation of nanoMIPS BPOSGE32C instruction target/mips: Fix emulation of nanoMIPS BNEC[32] instruction target/mips: Fix handling of unaligned memory access for nanoMIPS ISA
Marcin Nowakowski (1):
target/mips: Fix WatchHi.M handling
Mark Cave-Ayland (11):
hw/acpi/piix4: move xen_enabled() logic from piix4_pm_init() to
piix4_pm_realize()
hw/acpi/piix4: change smm_enabled from int to bool
hw/acpi/piix4: convert smm_enabled bool to qdev property
hw/acpi/piix4: move PIIX4PMState into separate piix4.h header
hw/acpi/piix4: alter piix4_pm_init() to return PIIX4PMState
hw/acpi/piix4: rename piix4_pm_init() to piix4_pm_initfn()
hw/acpi/piix4: use qdev gpio to wire up sci_irq
hw/acpi/piix4: use qdev gpio to wire up smi_irq
hw/i386/pc_piix: create PIIX4_PM device directly instead of using
piix4_pm_initfn()
hw/isa/piix4.c: create PIIX4_PM device directly instead of using
piix4_pm_initfn() hw/acpi/piix4: remove unused piix4_pm_initfn() function
Ni Hui (6):
target/mips: Fix SAT_S trans helper
target/mips: Fix df_extract_val() and df_extract_df() dfe lookup target/mips: Fix msa checking condition in trans_msa_elm_fn() target/mips: Do not treat msa INSERT as NOP when wd is zero target/mips: Fix store adress of high 64bit in helper_msa_st_b() target/mips: Fix FTRUNC_S and FTRUNC_U trans helper
Peter Maydell (1):
hw/block/fdc-sysbus: Always mark sysbus floppy controllers as not
having DMA
Stefan Pejic (3):
target/mips: Fix emulation of nanoMIPS MTHLIP instruction target/mips: Add missing default cases for some nanoMIPS pools target/mips: Undeprecate nanoMIPS ISA support in QEMU
MAINTAINERS | 3 +- accel/tcg/cpu-exec.c | 4 +- accel/tcg/translate-all.c | 5 - docs/about/deprecated.rst | 30 ------ docs/devel/submitting-a-patch.rst | 6 +- hw/acpi/piix4.c | 77 +++------------ hw/audio/cs4231a.c | 8 +- hw/block/fdc-sysbus.c | 16 +++- hw/i386/acpi-build.c | 1 + hw/i386/microvm-dt.c | 9 +- hw/i386/pc.c | 17 +++- hw/i386/pc_piix.c | 23 +++-- hw/isa/piix3.c | 98 ++++++++++--------- hw/isa/piix4.c | 116 ++++++++++++----------- hw/mips/boston.c | 3 +- hw/mips/jazz.c | 2 +- hw/mips/malta.c | 9 +- hw/net/fsl_etsec/etsec.c | 23 ----- hw/net/fsl_etsec/etsec.h | 7 -- hw/rtc/mc146818rtc.c | 9 +- hw/sparc64/sun4u.c | 2 +- include/exec/cpu-all.h | 3 - include/hw/acpi/piix4.h | 75 +++++++++++++++ include/hw/block/fdc.h | 3 +- include/hw/i386/pc.h | 14 --- include/hw/isa/isa.h | 2 - include/hw/rtc/mc146818rtc.h | 2 +- include/hw/southbridge/piix.h | 12 +-- target/mips/cpu.c | 2 +- target/mips/cpu.h | 3 +- target/mips/tcg/msa_helper.c | 2 +- target/mips/tcg/msa_translate.c | 29 +++--- target/mips/tcg/nanomips_translate.c.inc | 33 ++++++- target/mips/tcg/sysemu/cp0_helper.c | 3 +- target/mips/tcg/translate.c | 5 +- 35 files changed, 335 insertions(+), 321 deletions(-) create mode 100644 include/hw/acpi/piix4.h
Signature · 1 line
2.36.1
[PULL v2 47/50] hw/mips/boston: Initialize g_autofree pointers
From: Bernhard Beschow <[email protected]>
Fixes compilation due to false positives with -Werror:
In file included from /usr/include/glib-2.0/glib.h:114,
from qemu/src/include/glib-compat.h:32,
from qemu/src/include/qemu/osdep.h:144,
from ../src/hw/mips/boston.c:20:
In function ‘g_autoptr_cleanup_generic_gfree’,
inlined from ‘boston_mach_init’ at ../src/hw/mips/boston.c:790:52:
/usr/include/glib-2.0/glib/glib-autocleanups.h:28:3: error: ‘dtb_load_data’ may be used uninitialized [-Werror=maybe-uninitialized]
28 | g_free (*pp);
| ^~~~~~~~~~~~
../src/hw/mips/boston.c: In function ‘boston_mach_init’:
../src/hw/mips/boston.c:790:52: note: ‘dtb_load_data’ was declared here
790 | g_autofree const void *dtb_file_data, *dtb_load_data;
| ^~~~~~~~~~~~~
In function ‘g_autoptr_cleanup_generic_gfree’,
inlined from ‘boston_mach_init’ at ../src/hw/mips/boston.c:790:36:
/usr/include/glib-2.0/glib/glib-autocleanups.h:28:3: error: ‘dtb_file_data’ may be used uninitialized [-Werror=maybe-uninitialized]
28 | g_free (*pp);
| ^~~~~~~~~~~~
../src/hw/mips/boston.c: In function ‘boston_mach_init’:
../src/hw/mips/boston.c:790:36: note: ‘dtb_file_data’ was declared here
790 | g_autofree const void *dtb_file_data, *dtb_load_data;
| ^~~~~~~~~~~~~cc1: all warnings being treated as errors
Message-Id: <[email protected]>
--- hw/mips/boston.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
hw/mips/boston.c +2 -1
@@ -787,7 +787,8 @@ static void boston_mach_init(MachineState *machine)if (kernel_size >0 ) {int dt_size; - g_autofree const void *dtb_file_data, *dtb_load_data; + g_autofree const void *dtb_file_data = NULL; + g_autofree const void *dtb_load_data = NULL;hwaddr dtb_paddr =QEMU_ALIGN_UP (kernel_high,64 * KiB);hwaddr dtb_vaddr =cpu_mips_phys_to_kseg0 (NULL , dtb_paddr);
Signature · 1 line
2.36.1
Quoted 6 lines · Philippe Mathieu-Daudé
From: Philippe Mathieu-Daudé <[email protected]>
Hi Richard,
In case it is not too late, this v2 includes another fix from Bernhard which was supposed to be in v1. Otherwise it will go in the next PR.
The second PR merged well with the first, so I have applied this too.
r~
Quoted 132 lines
The following changes since commit
30796f556790631c86c733ab06756981be0e1def:Merge tag 'for_upstream' of git://git.kernel.org/pub/scm/virt/kvm/mst/qemu into staging (2022-06-10 18:15:34 -0700)are available in the Git repository at:
https://github.com/philmd/qemu.git tags/mips-20220611for you to fetch changes up to
6e0c18598814bffb67204a90890fb7b34cad288a:docs/devel: Fix link to developer mailing lists (2022-06-11 23:50:35 +0200)
----------------------------------------------------------------
MIPS patches queue- Various TCG fixes (Marcin Nowakowski, Ni Hui, Stefan Pejic, Stefan Pejic)
- Sysbus floppy controller fix (Peter Maydell)
- QOM'ification of PIIX southbridge (Mark Cave-Ayland, Bernhard Beschow)
- Various fixes on ISA devices commonly used by x86/mips machines (Bernhard)
- Few cleanups in accel/tcg & documentation (Bernhard)----------------------------------------------------------------
Bernhard Beschow (24):
hw/southbridge/piix: Aggregate all PIIX southbridge type names hw/isa/piix4: Useobject_initialize_child()for embedded struct hw/isa/piix4: Movepci_map_irq_fn' nearpci_set_irq_fnhw/isa/piix4: QOM'ify PCI device creation and wiring hw/isa/piix4: Factor out ISABus retrieval frompiix4_create()hw/isa/piix4: QOM'ify PIIX4 PM creation
hw/isa/piix4: Inline and removepiix4_create()hw/isa/piix3: Movepci_map_irq_fnnearpci_set_irq_fnhw/isa/piix3: QOM'ify PCI device creation and wiring hw/isa/piix3: Factor out ISABus retrieval frompiix3_create()hw/isa/piix3: Inline and removepiix3_create()hw/i386/microvm-dt: Force explicit failure if retrieving QOM property
fails
hw/i386/microvm-dt: Determine mc146818rtc's IRQ number from QOM
property
hw/rtc/mc146818rtc: QOM'ifyio_baseoffset
hw: ReuseTYPE_I8042define
hw/audio/cs4231a: Const'ify global tables
hw/i386/pc: UnexportPC_CPU_MODEL_IDSmacro
hw/i386/pc: Unexport functions used only internally hw/i386/pc: Remove orphan declarations hw/net/fsl_etsec/etsec: Remove obsolete and unusedetsec_create()hw/mips/boston: Initializeg_autofreepointers accel/tcg/cpu-exec: Unexportdump_drift_info()
accel/tcg: Inlinedump_opcount_info()and remove it docs/devel: Fix link to developer mailing listsDragan Mladjenovic (4):
target/mips: Fix emulation of nanoMIPS EXTRV_S.H instruction target/mips: Fix emulation of nanoMIPS BPOSGE32C instruction target/mips: Fix emulation of nanoMIPS BNEC[32] instruction target/mips: Fix handling of unaligned memory access for nanoMIPS ISAMarcin Nowakowski (1):
target/mips: Fix WatchHi.M handlingMark Cave-Ayland (11):
hw/acpi/piix4: movexen_enabled()logic frompiix4_pm_init()topiix4_pm_realize() hw/acpi/piix4: change smm_enabled from int to bool hw/acpi/piix4: convert smm_enabled bool to qdev property hw/acpi/piix4: move PIIX4PMState into separate piix4.h header hw/acpi/piix4: alter piix4_pm_init() to return PIIX4PMState hw/acpi/piix4: rename piix4_pm_init() to piix4_pm_initfn() hw/acpi/piix4: use qdev gpio to wire up sci_irq hw/acpi/piix4: use qdev gpio to wire up smi_irq hw/i386/pc_piix: create PIIX4_PM device directly instead of using piix4_pm_initfn() hw/isa/piix4.c: create PIIX4_PM device directly instead of using piix4_pm_initfn()hw/acpi/piix4: remove unused
piix4_pm_initfn()functionNi Hui (6):
target/mips: FixSAT_Strans helper
target/mips: Fixdf_extract_val()anddf_extract_df()dfe lookup target/mips: Fix msa checking condition intrans_msa_elm_fn()target/mips: Do not treat msa INSERT as NOP when wd is zero target/mips: Fix store adress of high 64bit inhelper_msa_st_b()target/mips: FixFTRUNC_SandFTRUNC_Utrans helperPeter Maydell (1):
hw/block/fdc-sysbus: Always mark sysbus floppy controllers as not
having DMAStefan Pejic (3):
target/mips: Fix emulation of nanoMIPS MTHLIP instruction target/mips: Add missing default cases for some nanoMIPS pools target/mips: Undeprecate nanoMIPS ISA support in QEMUMAINTAINERS | 3 +- accel/tcg/cpu-exec.c | 4 +- accel/tcg/translate-all.c | 5 - docs/about/deprecated.rst | 30 ------ docs/devel/submitting-a-patch.rst | 6 +- hw/acpi/piix4.c | 77 +++------------ hw/audio/cs4231a.c | 8 +- hw/block/fdc-sysbus.c | 16 +++- hw/i386/acpi-build.c | 1 + hw/i386/microvm-dt.c | 9 +- hw/i386/pc.c | 17 +++- hw/i386/pc_piix.c | 23 +++-- hw/isa/piix3.c | 98 ++++++++++--------- hw/isa/piix4.c | 116 ++++++++++++----------- hw/mips/boston.c | 3 +- hw/mips/jazz.c | 2 +- hw/mips/malta.c | 9 +- hw/net/fsl_etsec/etsec.c | 23 ----- hw/net/fsl_etsec/etsec.h | 7 -- hw/rtc/mc146818rtc.c | 9 +- hw/sparc64/sun4u.c | 2 +- include/exec/cpu-all.h | 3 - include/hw/acpi/piix4.h | 75 +++++++++++++++ include/hw/block/fdc.h | 3 +- include/hw/i386/pc.h | 14 --- include/hw/isa/isa.h | 2 - include/hw/rtc/mc146818rtc.h | 2 +- include/hw/southbridge/piix.h | 12 +-- target/mips/cpu.c | 2 +- target/mips/cpu.h | 3 +- target/mips/tcg/msa_helper.c | 2 +- target/mips/tcg/msa_translate.c | 29 +++--- target/mips/tcg/nanomips_translate.c.inc | 33 ++++++- target/mips/tcg/sysemu/cp0_helper.c | 3 +- target/mips/tcg/translate.c | 5 +- 35 files changed, 335 insertions(+), 321 deletions(-)create mode 100644
include/hw/acpi/piix4.h