[PATCH v2 0/5] hw: Replace some magic by definitions

Philippe Mathieu-Daudé posted 5 patches 3 years, 6 months ago
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20201012132017.3423954-1-f4bug@amsat.org
hw/arm/virt.c           |  4 ++--
hw/mips/gt64xxx_pci.c   |  2 +-
hw/pci-host/pam.c       |  2 +-
hw/pci-host/versatile.c | 46 ++++++++++++++++++++++-------------------
tests/qtest/rtc-test.c  |  2 +-
5 files changed, 30 insertions(+), 26 deletions(-)
[PATCH v2 0/5] hw: Replace some magic by definitions
Posted by Philippe Mathieu-Daudé 3 years, 6 months ago
A bunch of trivial cleanups, replacing magic
values by definitions to make the code easier
to review.

Since v1:
- Addressed Peter review comment on versatile PCI controller
- Added Thomas R-b tag

Expected to be merged via qemu-trivial@.

Regards,

Phil.

Philippe Mathieu-Daudé (5):
  hw: Replace magic value by PCI_NUM_PINS definition
  hw/pci-host/pam: Use ARRAY_SIZE() instead of magic value
  hw/pci-host/versatile: Add the MEMORY_WINDOW_COUNT definition
  hw/pci-host/versatile: Add the PCI_BAR_COUNT definition
  tests/qtest: Replace magic value by NANOSECONDS_PER_SECOND definition

 hw/arm/virt.c           |  4 ++--
 hw/mips/gt64xxx_pci.c   |  2 +-
 hw/pci-host/pam.c       |  2 +-
 hw/pci-host/versatile.c | 46 ++++++++++++++++++++++-------------------
 tests/qtest/rtc-test.c  |  2 +-
 5 files changed, 30 insertions(+), 26 deletions(-)

-- 
2.26.2

Re: [PATCH v2 0/5] hw: Replace some magic by definitions
Posted by Richard Henderson 3 years, 6 months ago
On 10/12/20 6:20 AM, Philippe Mathieu-Daudé wrote:
> Philippe Mathieu-Daudé (5):
>   hw: Replace magic value by PCI_NUM_PINS definition
>   hw/pci-host/pam: Use ARRAY_SIZE() instead of magic value
>   hw/pci-host/versatile: Add the MEMORY_WINDOW_COUNT definition
>   hw/pci-host/versatile: Add the PCI_BAR_COUNT definition
>   tests/qtest: Replace magic value by NANOSECONDS_PER_SECOND definition

Reviewed-by: Richard Henderson <richard.henderson@linaro.org>

r~