Re: [PATCH v2 3/3] tests/qtest: Introduce tests for AMD/Xilinx Versal TRNG device

2023-09-26 Thread Francisco Iglesias
trng_generate(true); > +n = trng_collect(prng, cnt); > +g_assert_cmpuint(n, ==, cnt); > + > +/* #2: zero string should match personalization disabled */ > +trng_load(R_TRNG_PER_STRNG_0, NULL); > +trng_reseed(prng_seed); > + > +trng_generate(tr

Re: [PATCH v3 3/3] tests/qtest: Introduce tests for AMD/Xilinx Versal TRNG device

2023-10-04 Thread Francisco Iglesias
On [2023 Oct 04] Wed 07:27:46, Tong Ho wrote: > Signed-off-by: Tong Ho Reviewed-by: Francisco Iglesias > --- > tests/qtest/meson.build | 2 +- > tests/qtest/xlnx-versal-trng-test.c | 490 > 2 files changed, 491 insertions(+), 1 deleti

Re: [PATCH v3 2/3] hw/arm: xlnx-versal-virt: Add AMD/Xilinx TRNG device

2023-10-04 Thread Francisco Iglesias
s not intended for use cases when > cryptograpically strong TRNG is needed. > > Signed-off-by: Tong Ho Reviewed-by: Francisco Iglesias > --- > hw/arm/Kconfig | 1 + > hw/arm/xlnx-versal.c | 16 > include/hw/arm/xlnx-versal.h | 5

Re: [PATCH] xlnx-zynqmp-efuse: hw/nvram: Remove deprecated device reset

2023-10-04 Thread Francisco Iglesias
On [2023 Oct 03] Tue 22:57:13, Tong Ho wrote: > This change implements the ResettableClass interface for the device. > > Signed-off-by: Tong Ho Reviewed-by: Francisco Iglesias > --- > hw/nvram/xlnx-zynqmp-efuse.c | 8 +--- > 1 file changed, 5 insertions(+), 3 deletions(

Re: [PATCH] xlnx-versal-efuse: hw/nvram: Remove deprecated device reset

2023-10-04 Thread Francisco Iglesias
On [2023 Oct 03] Tue 22:53:39, Tong Ho wrote: > This change implements the ResettableClass interface for the device. > > Signed-off-by: Tong Ho Reviewed-by: Francisco Iglesias > --- > hw/nvram/xlnx-versal-efuse-ctrl.c | 8 +--- > 1 file changed, 5 insertions(+), 3 dele

Re: [PATCH] xlnx-bbram: hw/nvram: Use dot in device type name

2023-10-04 Thread Francisco Iglesias
On [2023 Oct 02] Mon 22:21:39, Tong Ho wrote: > This replaces the comma (,) to dot (.) in the device type name > so the name can be used with the 'driver=' command line option. > > Signed-off-by: Tong Ho Reviewed-by: Francisco Iglesias > --- > include/hw/nvram/x

[PATCH v2 0/8] Xilinx Versal CFI support

2023-08-10 Thread Francisco Iglesias
with connecting the models to Xilinx Versal machine. Best regards, Francisco Iglesias References: [1] https://docs.xilinx.com/r/en-US/am011-versal-acap-trm/PSM-Local-Registers Changelog: v1->v2: [PATCH 2] * Use KiB when defining KEYHOLE_STREAM_4K/KEYHOLE_STREAM_256K * Updated to be able

[PATCH v2 1/8] hw/misc: Introduce the Xilinx CFI interface

2023-08-10 Thread Francisco Iglesias
emulating bitstream programming and readback). Signed-off-by: Francisco Iglesias Reviewed-by: Sai Pavan Boddu Acked-by: Edgar E. Iglesias --- MAINTAINERS | 6 hw/misc/meson.build | 1 + hw/misc/xlnx-cfi-if.c | 34 include/hw/misc/xlnx

[PATCH v2 2/8] hw/misc: Introduce a model of Xilinx Versal's CFU_APB

2023-08-10 Thread Francisco Iglesias
Introduce a model of the software programming interface (CFU_APB) of Xilinx Versal's Configuration Frame Unit. Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cfu.c

[PATCH v2 4/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal's CFU_SFR

2023-08-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's Single Frame Read port (CFU_SFR). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cfu.c | 87 +++ include/hw/misc/xlnx-versal-cfu.h | 15 ++ 2 files changed, 102 insertion

[PATCH v2 6/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_BCAST_REG

2023-08-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame broadcast controller (CFRAME_BCAST_REG). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cframe-reg.c | 161 +++ include/hw/misc/xlnx-versal-cframe-reg.h | 17 +++ 2 files changed, 178 inser

[PATCH v2 7/8] hw/arm/xlnx-versal: Connect the CFU_APB, CFU_FDRO and CFU_SFR

2023-08-10 Thread Francisco Iglesias
Connect the Configuration Frame Unit (CFU_APB, CFU_FDRO and CFU_SFR) to the Versal machine. Signed-off-by: Francisco Iglesias Acked-by: Edgar E. Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 42 include/hw/arm/xlnx-versal.h | 16

[PATCH v2 8/8] hw/arm/versal: Connect the CFRAME_REG and CFRAME_BCAST_REG

2023-08-10 Thread Francisco Iglesias
Connect the Configuration Frame controller (CFRAME_REG) and the Configuration Frame broadcast controller (CFRAME_BCAST_REG) to the Versal machine. Signed-off-by: Francisco Iglesias --- hw/arm/xlnx-versal.c | 113 ++- include/hw/arm/xlnx-versal.h | 69

[PATCH v2 3/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal CFU_FDRO

2023-08-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's data out port (CFU_FDRO). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cfu.c | 96 +++ include/hw/misc/xlnx-versal-cfu.h | 12 2 files changed, 108 insertions(+) di

[PATCH v2 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-08-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cframe-reg.c

Re: [PATCH v1 3/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal CFU_FDRO

2023-08-10 Thread Francisco Iglesias
Hi Peter, On 2023-08-03 15:48, Peter Maydell wrote: On Mon, 10 Jul 2023 at 15:03, Francisco Iglesias wrote: Introduce a model of Xilinx Versal's Configuration Frame Unit's data out port (CFU_FDRO). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cfu.c

Re: [PATCH] block/vpc: Avoid dynamic stack allocation

2023-08-18 Thread Francisco Iglesias
size-checked (e.g. CVE-2021-3527). > > Signed-off-by: Philippe Mathieu-Daudé > [PMM: expanded commit message] > Signed-off-by: Peter Maydell Reviewed-by: Francisco Iglesias > --- > block/vpc.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > dif

Re: [PATCH 1/2] audio/jackaudio: Avoid dynamic stack allocation in qjack_client_init

2023-08-21 Thread Francisco Iglesias
27;t correctly size-checked (e.g. CVE-2021-3527). > > Signed-off-by: Peter Maydell Reviewed-by: Francisco Iglesias > --- > audio/jackaudio.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-) > > diff --git a/audio/jackaudio.c b/audio/jackaudio.c > index 5bd

Re: [PATCH 3/3] ui/vnc-enc-tight: Avoid dynamic stack allocation

2023-08-21 Thread Francisco Iglesias
w 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é > [PMM: expanded commit message] > Signed-off-by: Peter Maydell Reviewed-

Re: [PATCH 2/2] audio/jackaudio: Avoid dynamic stack allocation in qjack_process()

2023-08-21 Thread Francisco Iglesias
s 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 Maydel

[PATCH v1 4/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal's CFU_SFR

2023-07-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's Single Frame Read port (CFU_SFR). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cfu.c | 88 +++ include/hw/misc/xlnx-versal-cfu.h | 15 ++ 2 files changed, 103 insertion

[PATCH v1 6/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_BCAST_REG

2023-07-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame broadcast controller (CFRAME_BCAST_REG). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cframe-reg.c | 173 +++ include/hw/misc/xlnx-versal-cframe-reg.h | 17 +++ 2 files changed, 190 inser

[PATCH v1 2/8] hw/misc: Introduce a model of Xilinx Versal's CFU_APB

2023-07-10 Thread Francisco Iglesias
Introduce a model of the software programming interface (CFU_APB) of Xilinx Versal's Configuration Frame Unit. Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cfu.c

[PATCH v1 8/8] hw/arm/versal: Connect the CFRAME_REG and CFRAME_BCAST_REG

2023-07-10 Thread Francisco Iglesias
Connect the Configuration Frame controller (CFRAME_REG) and the Configuration Frame broadcast controller (CFRAME_BCAST_REG) to the Versal machine. Signed-off-by: Francisco Iglesias --- hw/arm/xlnx-versal.c | 116 ++- include/hw/arm/xlnx-versal.h | 69

[PATCH v1 1/8] hw/misc: Introduce the Xilinx CFI interface

2023-07-10 Thread Francisco Iglesias
emulating bitstream programming and readback). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 6 hw/misc/meson.build | 1 + hw/misc/xlnx-cfi-if.c | 34 include/hw/misc/xlnx-cfi-if.h | 59 +++ 4 files

[PATCH v1 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-07-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cframe-reg.c

[PATCH v1 7/8] hw/arm/xlnx-versal: Connect the CFU_APB, CFU_FDRO and CFU_SFR

2023-07-10 Thread Francisco Iglesias
Connect the Configuration Frame Unit (CFU_APB, CFU_FDRO and CFU_SFR) to the Versal machine. Signed-off-by: Francisco Iglesias --- hw/arm/xlnx-versal.c | 42 include/hw/arm/xlnx-versal.h | 16 ++ 2 files changed, 58 insertions(+) diff

[PATCH v1 3/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal CFU_FDRO

2023-07-10 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's data out port (CFU_FDRO). Signed-off-by: Francisco Iglesias --- hw/misc/xlnx-versal-cfu.c | 105 ++ include/hw/misc/xlnx-versal-cfu.h | 11 2 files changed, 116 insertions(+) di

[PATCH v1 0/8] Xilinx Versal CFI support

2023-07-10 Thread Francisco Iglesias
with connecting the models to Xilinx Versal machine. Best regards, Francisco Iglesias References: [1] https://docs.xilinx.com/r/en-US/am011-versal-acap-trm/PSM-Local-Registers Francisco Iglesias (8): hw/misc: Introduce the Xilinx CFI interface hw/misc: Introduce a model of Xilinx Versal&#

Re: [PATCH v2] hw/arm/xlnx: Connect secondary CGEM IRQs

2023-07-10 Thread Francisco Iglesias
+PMM (I think this one might have fallen throught the cracks) Best regards, Francisco Iglesias On [2023 Jun 18] Sun 00:50:47, Philippe Mathieu-Daudé wrote: > On 16/6/23 16:38, Kinsey Moore wrote: > > The Cadence GEM peripherals as configured for Zynq MPSoC and Versal > > pla

Re: [PATCH] hw/arm/xlnx: Connect secondary CGEM IRQs

2023-06-16 Thread Francisco Iglesias
Hi Kinsey, On [2023 Jun 15] Thu 08:48:47, Kinsey Moore wrote: > The Cadence GEM peripherals as configured for Zynq MPSoC and Versal > platforms have two priority queues with separate interrupt sources for > each. If the interrupt source for the second priority queue is not > connected, they work i

Re: [PATCH v2] hw/arm/xlnx: Connect secondary CGEM IRQs

2023-06-16 Thread Francisco Iglesias
k in polling mode only. This change connects the > second interrupt source for platforms where it is available. This patch > has been tested using the lwIP stack with a Xilinx-supplied driver from > their embeddedsw repository. > > Signed-off-by: Kinsey Moore Reviewed-by: Francisco

Re: [PATCH] hw/intc/arm_gicv3: Simplify gicv3_class_name() logic

2023-09-06 Thread Francisco Iglesias
On [2023 Sep 05] Tue 16:56:51, Philippe Mathieu-Daudé wrote: > Simplify gicv3_class_name() logic. No functional change intended. > > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Francisco Iglesias > --- > hw/intc/arm_gicv3_common.c | 9 - > 1 file changed,

Re: [PATCH-for-8.2 v2 1/2] hw/net/can/xlnx-zynqmp: Avoid underflow while popping TX FIFOs

2023-11-22 Thread Francisco Iglesias
g Liu > Fixes: 98e5d7a2b7 ("hw/net/can: Introduce Xilinx ZynqMP CAN controller") > Resolves: https://gitlab.com/qemu-project/qemu/-/issues/1425 > Signed-off-by: Philippe Mathieu-Daudé > Francisco Iglesias -above line +below line Reviewed-by: Francisco Iglesias > --- &

Re: [PATCH-for-8.2 v2 2/2] hw/net/can/xlnx-zynqmp: Avoid underflow while popping RX FIFO

2023-11-22 Thread Francisco Iglesias
tps://gitlab.com/qemu-project/qemu/-/issues/1427 > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Francisco Iglesias > --- > hw/net/can/xlnx-zynqmp-can.c | 17 + > 1 file changed, 9 insertions(+), 8 deletions(-) > > diff --git a/hw/net/can/xlnx-zynqmp-can.c b

Re: [PATCH v1 1/3] hw/ssi/xilinx_spips: fix an out of bound access

2023-11-24 Thread Francisco Iglesias
bytes for zynqmp-qspips) thus it is possible to write out of s->regs[addr] in xilinx_spips_write for spips and qspips. This fixes that wrong behavior. Reviewed-by: Luc Michel Signed-off-by: Frederic Konrad Reviewed-by: Francisco Iglesias --- hw/ssi/xilinx_spips.c

Re: [PATCH v1 2/3] fix some url for amd / xilinx models

2023-11-24 Thread Francisco Iglesias
On 2023-11-24 15:35, Frederic Konrad wrote: It seems that the url changed a bit, and it triggers an error. Fix the URLs so the documentation can be reached again. Signed-off-by: Frederic Konrad Reviewed-by: Francisco Iglesias --- hw/dma/xlnx_csu_dma.c | 2

Re: [PATCH v1 3/3] hw/dma/xlnx_csu_dma: don't throw guest errors when stopping the SRC DMA

2023-11-24 Thread Francisco Iglesias
SIZE register, so remove the LOG_GUEST_ERROR in that case. While at it remove the comment marking the SIZE register as write-only. See: https://docs.xilinx.com/r/en-US/ug1087-zynq-ultrascale-registers/CSUDMA_SRC_SIZE-CSUDMA-Register Signed-off-by: Frederic Konrad Reviewed-by: Francisco Iglesias

Re: [PATCH 1/1] xlnx-versal-ospi: disable reentrancy detection for iomem_dac

2023-12-05 Thread Francisco Iglesias
> the memory region. > > Signed-off-by: Sai Pavan Boddu Reviewed-by: Francisco Iglesias Tested-by: Francisco Iglesias > --- > hw/ssi/xlnx-versal-ospi.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/ssi/xlnx-versal-ospi.c b/hw/ssi/xlnx-versal-ospi.c >

Re: [PATCH 2/2] arm: xlnx-versal-virt: Add machine property ospi-flash

2023-12-05 Thread Francisco Iglesias
On [2023 Dec 05] Tue 15:22:26, Sai Pavan Boddu wrote: > This property allows users to change flash model on command line as > below. > >ex: "-M xlnx-versal-virt,ospi-flash=mt35xu02gbba" > > Signed-off-by: Sai Pavan Boddu Reviewed-by: Francisco Iglesias > -

Re: [PATCH 1/2] block: m25p80: Add support of mt35xu02gbba

2023-12-05 Thread Francisco Iglesias
On [2023 Dec 05] Tue 15:22:25, Sai Pavan Boddu wrote: > Add Micro 2Gb OSPI flash part with sfdp data. > > Signed-off-by: Sai Pavan Boddu Reviewed-by: Francisco Iglesias > --- > hw/block/m25p80_sfdp.h | 1 + > hw/block/m25p80.c | 3 +++ > hw/blo

Re: [PATCH 1/2] docs/system/arm: Fix for rename of type "xlnx.bbram-ctrl"

2023-11-13 Thread Francisco Iglesias
On 2023-11-13 14:43, Markus Armbruster wrote: Fixes: b65b4b7ae3c8 (xlnx-bbram: hw/nvram: Use dot in device type name) Signed-off-by: Markus Armbruster Reviewed-by: Francisco Iglesias --- docs/system/arm/xlnx-versal-virt.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff

Re: [PATCH 2/2] hw: Replace anti-social QOM type names (again)

2023-11-13 Thread Francisco Iglesias
x-FOO", like commit e178113ff64 did. Reported-by: Thomas Huth Signed-off-by: Markus Armbruster Reviewed-by: Francisco Iglesias --- docs/system/arm/xlnx-versal-virt.rst | 2 +- include/hw/misc/xlnx-versal-cframe-reg.h | 2 +- include/hw/misc/xlnx-versal-cfu.h| 6 +++--- incl

Re: [PATCH-for-8.2] hw/net/can/xlnx-zynqmp: Avoid underflow while popping TX FIFO

2023-11-16 Thread Francisco Iglesias
bove minor modification: Reviewed-by: Francisco Iglesias Best regards, Francisco +bool is_txhpb = fifo == &s->txhpb_fifo; + +assert(used > 0); +used %= CAN_FRAME_SIZE; + +/* + * Frame Message Format + * + * Each frame includes four words (16 bytes). Software mus

Re: [PATCH-for-8.2] hw/net/can/xlnx-zynqmp: Avoid underflow while popping TX FIFO

2023-11-16 Thread Francisco Iglesias
Hi Philippe, On 2023-11-16 16:44, Philippe Mathieu-Daudé wrote: Hi Francisco, On 16/11/23 15:17, Francisco Iglesias wrote: Hi Philippe, good catch! Well this was fuzzed by Qiang Liu. On 2023-11-15 16:17, Philippe Mathieu-Daudé wrote: Per https://docs.xilinx.com/r/en-US/ug1085-zynq

[PATCH v3 8/8] hw/arm/versal: Connect the CFRAME_REG and CFRAME_BCAST_REG

2023-08-24 Thread Francisco Iglesias
Connect the Configuration Frame controller (CFRAME_REG) and the Configuration Frame broadcast controller (CFRAME_BCAST_REG) to the Versal machine. Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 113 ++- include/hw

[PATCH v3 3/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal CFU_FDRO

2023-08-24 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's data out port (CFU_FDRO). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cfu.c | 96 +++ include/hw/misc/xlnx-versal-cfu.h | 12 2 files ch

[PATCH v3 0/8] Xilinx Versal CFI support

2023-08-24 Thread Francisco Iglesias
with connecting the models to Xilinx Versal machine. Best regards, Francisco Iglesias References: [1] https://docs.xilinx.com/r/en-US/am011-versal-acap-trm/PSM-Local-Registers Changelog: v2->v3: [PATCH 5] * Swap to store the CFrames in a GTree instead of GArray * Rename new_f to new_f_d

[PATCH v3 2/8] hw/misc: Introduce a model of Xilinx Versal's CFU_APB

2023-08-24 Thread Francisco Iglesias
Introduce a model of the software programming interface (CFU_APB) of Xilinx Versal's Configuration Frame Unit. Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-

[PATCH v3 6/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_BCAST_REG

2023-08-24 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame broadcast controller (CFRAME_BCAST_REG). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cframe-reg.c | 161 +++ include/hw/misc/xlnx-versal-cframe-reg.h | 17 +++ 2

[PATCH v3 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-08-24 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cframe-reg.c

Re: [PATCH v2 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-08-24 Thread Francisco Iglesias
Hi Peter, On 2023-08-21 15:34, Peter Maydell wrote: On Thu, 10 Aug 2023 at 20:16, Francisco Iglesias wrote: Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw

[PATCH v3 1/8] hw/misc: Introduce the Xilinx CFI interface

2023-08-24 Thread Francisco Iglesias
emulating bitstream programming and readback). Signed-off-by: Francisco Iglesias Reviewed-by: Sai Pavan Boddu Acked-by: Edgar E. Iglesias --- MAINTAINERS | 6 hw/misc/meson.build | 1 + hw/misc/xlnx-cfi-if.c | 34 include/hw/misc/xlnx

[PATCH v3 7/8] hw/arm/xlnx-versal: Connect the CFU_APB, CFU_FDRO and CFU_SFR

2023-08-24 Thread Francisco Iglesias
Connect the Configuration Frame Unit (CFU_APB, CFU_FDRO and CFU_SFR) to the Versal machine. Signed-off-by: Francisco Iglesias Acked-by: Edgar E. Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 42 include/hw/arm/xlnx-versal.h | 16

[PATCH v3 4/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal's CFU_SFR

2023-08-24 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's Single Frame Read port (CFU_SFR). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cfu.c | 87 +++ include/hw/misc/xlnx-versal-cfu.h | 15 +

Re: [PATCH 2/4] hw/net/rocker: Avoid variable length array

2023-08-25 Thread Francisco Iglesias
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 Reviewed-by: Francisco Iglesias > --- > hw/net/rocker/rocker_of_dpa.c | 2 +- > 1 file changed, 1 inse

Re: [PATCH 4/4] net/tap: Avoid variable-length array

2023-08-25 Thread Francisco Iglesias
t; 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 Reviewed-by: Francisco Iglesias > --- > net/tap.c | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) >

Re: [PATCH 3/4] net/dump: Avoid variable length array

2023-08-25 Thread Francisco Iglesias
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 Reviewed-by: Francisco Iglesias > --- > net/dump.c | 2 +- > 1 file changed, 1 insertion(+), 1 delet

Re: [PATCH v3 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-08-31 Thread Francisco Iglesias
Hi Peter, On 2023-08-29 18:44, Peter Maydell wrote: On Thu, 24 Aug 2023 at 19:35, Francisco Iglesias wrote: Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias +static void cfrm_fdri_post_write(RegisterInfo *reg, uin

[PATCH v4 0/8] Xilinx Versal CFI support

2023-08-31 Thread Francisco Iglesias
with connecting the models to Xilinx Versal machine. Best regards, Francisco Iglesias References: [1] https://docs.xilinx.com/r/en-US/am011-versal-acap-trm/PSM-Local-Registers Changelog: v3->v4: [PATCH 5] * Swap to pop out the fifo32 data instead of using memcpy * Use g_tree_nnodes inst

[PATCH v4 4/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal's CFU_SFR

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's Single Frame Read port (CFU_SFR). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cfu.c | 87 +++ include/hw/misc/xlnx-versal-cfu.h | 15 +

[PATCH v4 3/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal CFU_FDRO

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's data out port (CFU_FDRO). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cfu.c | 96 +++ include/hw/misc/xlnx-versal-cfu.h | 12 2 files ch

[PATCH v4 2/8] hw/misc: Introduce a model of Xilinx Versal's CFU_APB

2023-08-31 Thread Francisco Iglesias
Introduce a model of the software programming interface (CFU_APB) of Xilinx Versal's Configuration Frame Unit. Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-

[PATCH v4 1/8] hw/misc: Introduce the Xilinx CFI interface

2023-08-31 Thread Francisco Iglesias
emulating bitstream programming and readback). Signed-off-by: Francisco Iglesias Reviewed-by: Sai Pavan Boddu Acked-by: Edgar E. Iglesias --- MAINTAINERS | 6 hw/misc/meson.build | 1 + hw/misc/xlnx-cfi-if.c | 34 include/hw/misc/xlnx

[PATCH v4 7/8] hw/arm/xlnx-versal: Connect the CFU_APB, CFU_FDRO and CFU_SFR

2023-08-31 Thread Francisco Iglesias
Connect the Configuration Frame Unit (CFU_APB, CFU_FDRO and CFU_SFR) to the Versal machine. Signed-off-by: Francisco Iglesias Acked-by: Edgar E. Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 42 include/hw/arm/xlnx-versal.h | 16

[PATCH v4 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cframe-reg.c

[PATCH v4 8/8] hw/arm/versal: Connect the CFRAME_REG and CFRAME_BCAST_REG

2023-08-31 Thread Francisco Iglesias
Connect the Configuration Frame controller (CFRAME_REG) and the Configuration Frame broadcast controller (CFRAME_BCAST_REG) to the Versal machine. Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 113 ++- include/hw

[PATCH v4 6/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_BCAST_REG

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame broadcast controller (CFRAME_BCAST_REG). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cframe-reg.c | 161 +++ include/hw/misc/xlnx-versal-cframe-reg.h | 17 +++ 2

[PATCH v5 0/8] Xilinx Versal CFI support

2023-08-31 Thread Francisco Iglesias
with connecting the models to Xilinx Versal machine. Best regards, Francisco Iglesias References: [1] https://docs.xilinx.com/r/en-US/am011-versal-acap-trm/PSM-Local-Registers Changelog: v4->v5: * Identical to v4 (resend of v4 due to an smtp problem) v3->v4: [PATCH 5] * Swap to pop o

[PATCH v5 1/8] hw/misc: Introduce the Xilinx CFI interface

2023-08-31 Thread Francisco Iglesias
emulating bitstream programming and readback). Signed-off-by: Francisco Iglesias Reviewed-by: Sai Pavan Boddu Acked-by: Edgar E. Iglesias --- MAINTAINERS | 6 hw/misc/meson.build | 1 + hw/misc/xlnx-cfi-if.c | 34 include/hw/misc/xlnx

[PATCH v5 3/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal CFU_FDRO

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's data out port (CFU_FDRO). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cfu.c | 96 +++ include/hw/misc/xlnx-versal-cfu.h | 12 2 files ch

[PATCH v5 8/8] hw/arm/versal: Connect the CFRAME_REG and CFRAME_BCAST_REG

2023-08-31 Thread Francisco Iglesias
Connect the Configuration Frame controller (CFRAME_REG) and the Configuration Frame broadcast controller (CFRAME_BCAST_REG) to the Versal machine. Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 113 ++- include/hw

[PATCH v5 5/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_REG

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame controller (CFRAME_REG). Signed-off-by: Francisco Iglesias --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-cframe-reg.c

[PATCH v5 6/8] hw/misc: Introduce a model of Xilinx Versal's CFRAME_BCAST_REG

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame broadcast controller (CFRAME_BCAST_REG). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cframe-reg.c | 161 +++ include/hw/misc/xlnx-versal-cframe-reg.h | 17 +++ 2

[PATCH v5 2/8] hw/misc: Introduce a model of Xilinx Versal's CFU_APB

2023-08-31 Thread Francisco Iglesias
Introduce a model of the software programming interface (CFU_APB) of Xilinx Versal's Configuration Frame Unit. Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- MAINTAINERS | 2 + hw/misc/meson.build | 1 + hw/misc/xlnx-versal-

[PATCH v5 4/8] hw/misc/xlnx-versal-cfu: Introduce a model of Xilinx Versal's CFU_SFR

2023-08-31 Thread Francisco Iglesias
Introduce a model of Xilinx Versal's Configuration Frame Unit's Single Frame Read port (CFU_SFR). Signed-off-by: Francisco Iglesias Reviewed-by: Peter Maydell --- hw/misc/xlnx-versal-cfu.c | 87 +++ include/hw/misc/xlnx-versal-cfu.h | 15 +

[PATCH v5 7/8] hw/arm/xlnx-versal: Connect the CFU_APB, CFU_FDRO and CFU_SFR

2023-08-31 Thread Francisco Iglesias
Connect the Configuration Frame Unit (CFU_APB, CFU_FDRO and CFU_SFR) to the Versal machine. Signed-off-by: Francisco Iglesias Acked-by: Edgar E. Iglesias Reviewed-by: Peter Maydell --- hw/arm/xlnx-versal.c | 42 include/hw/arm/xlnx-versal.h | 16

[Qemu-devel] [PATCH v3] xilinx_spips: Correct usage of an uninitialized local variable

2018-01-24 Thread Francisco Iglesias
Coverity found that the variable tx_rx in the function xilinx_spips_flush_txfifo was being used uninitialized (CID 1383841). This patch corrects this by always initializing tx_rx to zeros. Signed-off-by: Francisco Iglesias --- v3. Change to report errors on the num_busses property via the Error

Re: [Qemu-devel] [PATCH v3] xilinx_spips: Correct usage of an uninitialized local variable

2018-01-25 Thread francisco iglesias
On Thursday, 25 January 2018, Peter Maydell wrote: > On 24 January 2018 at 21:57, Francisco Iglesias > wrote: > > Coverity found that the variable tx_rx in the function > > xilinx_spips_flush_txfifo was being used uninitialized (CID 1383841). > This > > pa

Re: [Qemu-devel] [PATCH-2.12 v1 1/3] xilinx_spips: Update the QSPI Mod ID reset value

2017-11-29 Thread francisco iglesias
On 28 November 2017 at 23:31, Alistair Francis wrote: > Update the reset value to match the latest ZynqMP register spec. > > Signed-off-by: Alistair Francis > Reviewed-by: Francisco Iglesias > --- > > hw/ssi/xilinx_spips.c | 1 + > 1 file changed, 1 insertion(+)

Re: [Qemu-devel] [PATCH-2.12 v1 3/3] xilinx_spips: Use memset instead of a for loop to zero registers

2017-11-29 Thread francisco iglesias
On 28 November 2017 at 23:31, Alistair Francis wrote: > Use memset() instead of a for loop to zero all of the registers. > > Signed-off-by: Alistair Francis > Reviewed-by: Francisco Iglesias > --- > > hw/ssi/xilinx_spips.c | 11 +++ > 1 file changed, 3 in

Re: [Qemu-devel] [PATCH-2.12 v1 2/3] xilinx_spis: Set all of the reset values

2017-11-29 Thread francisco iglesias
s->regs[R_INTR_STATUS] = R_INTR_STATUS_RESET; > +s->regs[R_GPIO] = 1; > +s->regs[R_LPBK_DLY_ADJ] = R_LPBK_DLY_ADJ_RESET; > +s->regs[R_GQSPI_GFIFO_THRESH] = 0x10; > s->regs[R_GQSPI_IMR] = GQSPI_IXR_MASK; > Also, above row will be overriden below so ma

Re: [Qemu-devel] [PATCH-2.12 v2 2/3] xilinx_spips: Set all of the reset values

2017-12-06 Thread francisco iglesias
(0x110 / 4) > +#define R_GQSPI_IMR_RESET (0xfbe) > #define R_GQSPI_TX_THRESH (0x128 / 4) > #define R_GQSPI_RX_THRESH (0x12c / 4) > +#define R_GQSPI_GPIO_THRESH (0x130 / 4) > According to doc (mentioned in patch 0/3) the address above, 0x130, is "GQSPI GPIO for Writ

Re: [Qemu-devel] [PATCH-2.12 v2 2/3] xilinx_spips: Set all of the reset values

2017-12-11 Thread francisco iglesias
On 11 December 2017 at 18:27, Alistair Francis wrote: > On Wed, Dec 6, 2017 at 3:39 PM, francisco iglesias > wrote: > > Hi Alistair, > > > > On 6 December 2017 at 23:22, Alistair Francis < > alistair.fran...@xilinx.com> > > wrote: > >> > >

Re: [Qemu-devel] [PATCH 3/4] hw/registerfields: add 64-bit extract/deposit macros

2017-12-13 Thread francisco iglesias
On 13 December 2017 at 06:17, Philippe Mathieu-Daudé wrote: > Signed-off-by: Philippe Mathieu-Daudé > --- > include/hw/registerfields.h | 11 +++ > 1 file changed, 11 insertions(+) > > diff --git a/include/hw/registerfields.h b/include/hw/registerfields.h > index ad9d7a82a3..f59e7f47bd

Re: [Qemu-devel] [PATCH v7 11/13] xilinx_spips: Don't set TX FIFO UNDERFLOW at cmd done

2017-11-23 Thread francisco iglesias
Good day Alistair, Thank you very much for reviewing agian! I will update the patch set according to your comments and come back with a new version (v8)! Best regards, Francisco Iglesias On 23 November 2017 at 01:39, Alistair Francis wrote: > On Thu, Nov 2, 2017 at 5:01 PM, Franci

[Qemu-devel] [PATCH v8 01/13] m25p80: Add support for continuous read out of RDSR and READ_FSR

2017-11-24 Thread Francisco Iglesias
Add support for continuous read out of the RDSR and READ_FSR status registers until the chip select is deasserted. This feature is supported by amongst others 1 or more flashtypes manufactured by Numonyx (Micron), Windbond, SST, Gigadevice, Eon and Macronix. Signed-off-by: Francisco Iglesias

[Qemu-devel] [PATCH v8 08/13] xilinx_spips: Make tx/rx_data_bytes more generic and reusable

2017-11-24 Thread Francisco Iglesias
Make tx/rx_data_bytes more generic so they can be reused (when adding support for the Zynqmp Generic QSPI). Signed-off-by: Francisco Iglesias --- hw/ssi/xilinx_spips.c | 64 +-- 1 file changed, 37 insertions(+), 27 deletions(-) diff --git a/hw

[Qemu-devel] [PATCH v8 03/13] m25p80: Add support for BRRD/BRWR and BULK_ERASE (0x60)

2017-11-24 Thread Francisco Iglesias
Add support for the bank address register access commands (BRRD/BRWR) and the BULK_ERASE (0x60) command. Signed-off-by: Francisco Iglesias Acked-by: Marcin Krzemiński --- hw/block/m25p80.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index

[Qemu-devel] [PATCH v8 05/13] xilinx_spips: Move FlashCMD, XilinxQSPIPS and XilinxSPIPSClass

2017-11-24 Thread Francisco Iglesias
: Francisco Iglesias Reviewed-by: Alistair Francis --- hw/ssi/xilinx_spips.c | 35 --- include/hw/ssi/xilinx_spips.h | 34 ++ 2 files changed, 34 insertions(+), 35 deletions(-) diff --git a/hw/ssi/xilinx_spips.c b/hw/ssi

[Qemu-devel] [PATCH v8 00/13] Add support for the ZynqMP Generic QSPI

2017-11-24 Thread Francisco Iglesias
pumping according transfer register and 4 byte LQSPI addresses. Finally it adds support for the ZynqMP Generic QSPI and adds the ZynqMP QSPI to the xlnx-zcu102 board. Best regards, Francisco Iglesias Changelog: v7 -> v8 * Corrected commit messages in the patches 'xilinx_spips: Don'

[Qemu-devel] [PATCH v8 10/13] xilinx_spips: Add support for 4 byte addresses in the LQSPI

2017-11-24 Thread Francisco Iglesias
Add support for 4 byte addresses in the LQSPI and correct LQSPI_CFG_SEP_BUS. Signed-off-by: Francisco Iglesias Reviewed-by: Alistair Francis --- hw/ssi/xilinx_spips.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hw/ssi/xilinx_spips.c b/hw/ssi/xilinx_spips.c index

[Qemu-devel] [PATCH v8 04/13] m25p80: Add support for n25q512a11 and n25q512a13

2017-11-24 Thread Francisco Iglesias
Add support for Micron (Numonyx) n25q512a11 and n25q512a13 flashes. Signed-off-by: Francisco Iglesias Acked-by: Marcin Krzemiński Reviewed-by: Alistair Francis --- hw/block/m25p80.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index 1d0aa1d

[Qemu-devel] [PATCH v8 06/13] xilinx_spips: Update striping to be big-endian bit order

2017-11-24 Thread Francisco Iglesias
: Francisco Iglesias Acked-by: Alistair Francis --- hw/ssi/xilinx_spips.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/hw/ssi/xilinx_spips.c b/hw/ssi/xilinx_spips.c index 559fa79..231aa5b 100644 --- a/hw/ssi/xilinx_spips.c +++ b/hw/ssi/xilinx_spips.c @@ -208,14

[Qemu-devel] [PATCH v8 02/13] m25p80: Add support for SST READ ID 0x90/0xAB commands

2017-11-24 Thread Francisco Iglesias
Add support for SST READ ID 0x90/0xAB commands for reading out the flash manufacuter ID and device ID. Signed-off-by: Francisco Iglesias Acked-by: Alistair Francis Acked-by: Marcin Krzemiński --- hw/block/m25p80.c | 23 +++ 1 file changed, 23 insertions(+) diff --git a/hw

[Qemu-devel] [PATCH v8 11/13] xilinx_spips: Don't set TX FIFO UNDERFLOW at cmd done

2017-11-24 Thread Francisco Iglesias
Don't set TX FIFO UNDERFLOW interrupt after transmitting the commands. Also update interrupts after reading out the interrupt status. Signed-off-by: Francisco Iglesias Acked-by: Alistair Francis --- hw/ssi/xilinx_spips.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git

[Qemu-devel] [PATCH v8 07/13] xilinx_spips: Add support for RX discard and RX drain

2017-11-24 Thread Francisco Iglesias
Add support for the RX discard and RX drain functionality. Also transmit one byte per dummy cycle (to the flash memories) with commands that require these. Signed-off-by: Francisco Iglesias --- hw/ssi/xilinx_spips.c | 167 +- include/hw/ssi

[Qemu-devel] [PATCH v8 09/13] xilinx_spips: Add support for zero pumping

2017-11-24 Thread Francisco Iglesias
Add support for zero pumping according to the transfer size register. Signed-off-by: Francisco Iglesias --- hw/ssi/xilinx_spips.c | 47 --- include/hw/ssi/xilinx_spips.h | 2 ++ 2 files changed, 42 insertions(+), 7 deletions(-) diff --git a/hw

[Qemu-devel] [PATCH v8 13/13] xlnx-zcu102: Add support for the ZynqMP QSPI

2017-11-24 Thread Francisco Iglesias
Add support for the ZynqMP QSPI (consisting of the Generic QSPI and Legacy QSPI) and connect Numonyx n25q512a11 flashes to it. Signed-off-by: Francisco Iglesias Reviewed-by: Alistair Francis --- hw/arm/xlnx-zcu102.c | 23 +++ hw/arm/xlnx-zynqmp.c | 26

[Qemu-devel] [PATCH v8 12/13] xilinx_spips: Add support for the ZynqMP Generic QSPI

2017-11-24 Thread Francisco Iglesias
Add support for the Zynq Ultrascale MPSoc Generic QSPI. Signed-off-by: Francisco Iglesias --- default-configs/arm-softmmu.mak | 2 +- hw/ssi/xilinx_spips.c | 579 include/hw/ssi/xilinx_spips.h | 32 ++- 3 files changed, 564 insertions

<    1   2   3   4   5   6   >