qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fsl-imx6ul: Add various missing unimplemented devices
@ 2024-01-20  0:53 Guenter Roeck
  2024-01-20 11:19 ` Philippe Mathieu-Daudé
  2024-01-22 16:43 ` Peter Maydell
  0 siblings, 2 replies; 3+ messages in thread
From: Guenter Roeck @ 2024-01-20  0:53 UTC (permalink / raw)
  To: Peter Maydell; +Cc: qemu-arm, qemu-devel, Guenter Roeck, Jean-Christophe Dubois

Add MMDC, OCOTP, SQPI, CAAM, and USBMISC as unimplemented devices.

This allows operating systems such as Linux to run emulations such as
mcimx6ul-evk.

Before commit 0cd4926b85 ("Refactor i.MX6UL processor code"), the affected
memory ranges were covered by the unimplemented DAP device. The commit
reduced the DAP address range from 0x100000 to 4kB, and the emulation
thus no longer covered the various unimplemented devices in the affected
address range.

Fixes: 0cd4926b85 ("Refactor i.MX6UL processor code")
Cc: Jean-Christophe Dubois <jcd@tribudubois.net>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
---
This patch is necessary to boot mcimx6ul-evk with Linux v6.7.

My apologies for the noise if a similar patch has already been submitted
and I missed it.

 hw/arm/fsl-imx6ul.c         | 30 ++++++++++++++++++++++++++++++
 include/hw/arm/fsl-imx6ul.h |  2 ++
 2 files changed, 32 insertions(+)

diff --git a/hw/arm/fsl-imx6ul.c b/hw/arm/fsl-imx6ul.c
index e37b69a5e1..7d2ee0df6e 100644
--- a/hw/arm/fsl-imx6ul.c
+++ b/hw/arm/fsl-imx6ul.c
@@ -192,6 +192,36 @@ static void fsl_imx6ul_realize(DeviceState *dev, Error **errp)
     create_unimplemented_device("a7mpcore-dap", FSL_IMX6UL_A7MPCORE_DAP_ADDR,
                                 FSL_IMX6UL_A7MPCORE_DAP_SIZE);
 
+    /*
+     * MMDC
+     */
+    create_unimplemented_device("a7mpcore-mmdc", FSL_IMX6UL_MMDC_CFG_ADDR,
+                                FSL_IMX6UL_MMDC_CFG_SIZE);
+
+    /*
+     * OCOTP
+     */
+    create_unimplemented_device("a7mpcore-ocotp", FSL_IMX6UL_OCOTP_CTRL_ADDR,
+                                FSL_IMX6UL_OCOTP_CTRL_SIZE);
+
+    /*
+     * QSPI
+     */
+    create_unimplemented_device("a7mpcore-qspi", FSL_IMX6UL_QSPI_ADDR,
+                                FSL_IMX6UL_QSPI_SIZE);
+
+    /*
+     * CAAM
+     */
+    create_unimplemented_device("a7mpcore-qspi", FSL_IMX6UL_CAAM_ADDR,
+                                FSL_IMX6UL_CAAM_SIZE);
+
+    /*
+     * USBMISC
+     */
+    create_unimplemented_device("a7mpcore-usbmisc", FSL_IMX6UL_USBO2_USBMISC_ADDR,
+                                FSL_IMX6UL_USBO2_USBMISC_SIZE);
+
     /*
      * GPTs
      */
diff --git a/include/hw/arm/fsl-imx6ul.h b/include/hw/arm/fsl-imx6ul.h
index 14390f6014..8277b0e8b2 100644
--- a/include/hw/arm/fsl-imx6ul.h
+++ b/include/hw/arm/fsl-imx6ul.h
@@ -182,6 +182,8 @@ enum FslIMX6ULMemoryMap {
     FSL_IMX6UL_ENET1_ADDR           = 0x02188000,
 
     FSL_IMX6UL_USBO2_USBMISC_ADDR   = 0x02184800,
+    FSL_IMX6UL_USBO2_USBMISC_SIZE   = 0x200,
+
     FSL_IMX6UL_USBO2_USB1_ADDR      = 0x02184000,
     FSL_IMX6UL_USBO2_USB2_ADDR      = 0x02184200,
 
-- 
2.39.2



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] fsl-imx6ul: Add various missing unimplemented devices
  2024-01-20  0:53 [PATCH] fsl-imx6ul: Add various missing unimplemented devices Guenter Roeck
@ 2024-01-20 11:19 ` Philippe Mathieu-Daudé
  2024-01-22 16:43 ` Peter Maydell
  1 sibling, 0 replies; 3+ messages in thread
From: Philippe Mathieu-Daudé @ 2024-01-20 11:19 UTC (permalink / raw)
  To: Guenter Roeck, Peter Maydell; +Cc: qemu-arm, qemu-devel, Jean-Christophe Dubois

On 20/1/24 01:53, Guenter Roeck wrote:
> Add MMDC, OCOTP, SQPI, CAAM, and USBMISC as unimplemented devices.
> 
> This allows operating systems such as Linux to run emulations such as
> mcimx6ul-evk.
> 
> Before commit 0cd4926b85 ("Refactor i.MX6UL processor code"), the affected
> memory ranges were covered by the unimplemented DAP device. The commit
> reduced the DAP address range from 0x100000 to 4kB, and the emulation
> thus no longer covered the various unimplemented devices in the affected
> address range.
> 
> Fixes: 0cd4926b85 ("Refactor i.MX6UL processor code")
> Cc: Jean-Christophe Dubois <jcd@tribudubois.net>
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
> ---
> This patch is necessary to boot mcimx6ul-evk with Linux v6.7.
> 
> My apologies for the noise if a similar patch has already been submitted
> and I missed it.
> 
>   hw/arm/fsl-imx6ul.c         | 30 ++++++++++++++++++++++++++++++
>   include/hw/arm/fsl-imx6ul.h |  2 ++
>   2 files changed, 32 insertions(+)

Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] fsl-imx6ul: Add various missing unimplemented devices
  2024-01-20  0:53 [PATCH] fsl-imx6ul: Add various missing unimplemented devices Guenter Roeck
  2024-01-20 11:19 ` Philippe Mathieu-Daudé
@ 2024-01-22 16:43 ` Peter Maydell
  1 sibling, 0 replies; 3+ messages in thread
From: Peter Maydell @ 2024-01-22 16:43 UTC (permalink / raw)
  To: Guenter Roeck; +Cc: qemu-arm, qemu-devel, Jean-Christophe Dubois

On Sat, 20 Jan 2024 at 00:54, Guenter Roeck <linux@roeck-us.net> wrote:
>
> Add MMDC, OCOTP, SQPI, CAAM, and USBMISC as unimplemented devices.
>
> This allows operating systems such as Linux to run emulations such as
> mcimx6ul-evk.
>
> Before commit 0cd4926b85 ("Refactor i.MX6UL processor code"), the affected
> memory ranges were covered by the unimplemented DAP device. The commit
> reduced the DAP address range from 0x100000 to 4kB, and the emulation
> thus no longer covered the various unimplemented devices in the affected
> address range.
>
> Fixes: 0cd4926b85 ("Refactor i.MX6UL processor code")
> Cc: Jean-Christophe Dubois <jcd@tribudubois.net>
> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
> ---
> This patch is necessary to boot mcimx6ul-evk with Linux v6.7.
>
> My apologies for the noise if a similar patch has already been submitted
> and I missed it.



Applied to target-arm.next, thanks.

-- PMM


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2024-01-22 16:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-01-20  0:53 [PATCH] fsl-imx6ul: Add various missing unimplemented devices Guenter Roeck
2024-01-20 11:19 ` Philippe Mathieu-Daudé
2024-01-22 16:43 ` Peter Maydell

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).