[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ad80e3b8-4f62-4c58-8dbd-762f0b268713@foss.st.com>
Date: Tue, 6 May 2025 13:16:22 +0200
From: Patrice CHOTARD <patrice.chotard@...s.st.com>
To: Krzysztof Kozlowski <krzk@...nel.org>, Rob Herring <robh@...nel.org>,
Conor Dooley <conor+dt@...nel.org>,
Maxime Coquelin
<mcoquelin.stm32@...il.com>,
Alexandre Torgue <alexandre.torgue@...s.st.com>,
Philipp Zabel <p.zabel@...gutronix.de>,
Krzysztof Kozlowski
<krzk+dt@...nel.org>,
Catalin Marinas <catalin.marinas@....com>,
Will Deacon
<will@...nel.org>
CC: <christophe.kerello@...s.st.com>, <linux-kernel@...r.kernel.org>,
<devicetree@...r.kernel.org>,
<linux-stm32@...md-mailman.stormreply.com>,
<linux-arm-kernel@...ts.infradead.org>
Subject: Re: [PATCH v12 2/3] memory: Add STM32 Octo Memory Manager driver
On 5/6/25 10:02, Krzysztof Kozlowski wrote:
> On 06/05/2025 09:52, Patrice Chotard wrote:
>> Octo Memory Manager driver (OMM) manages:
>> - the muxing between 2 OSPI busses and 2 output ports.
>> There are 4 possible muxing configurations:
>> - direct mode (no multiplexing): OSPI1 output is on port 1 and OSPI2
>> output is on port 2
>> - OSPI1 and OSPI2 are multiplexed over the same output port 1
>> - swapped mode (no multiplexing), OSPI1 output is on port 2,
>> OSPI2 output is on port 1
>> - OSPI1 and OSPI2 are multiplexed over the same output port 2
>> - the split of the memory area shared between the 2 OSPI instances.
>> - chip select selection override.
>> - the time between 2 transactions in multiplexed mode.
>> - check firewall access.
>>
>> Signed-off-by: Christophe Kerello <christophe.kerello@...s.st.com>
>> Signed-off-by: Patrice Chotard <patrice.chotard@...s.st.com>
>> ---
>> drivers/memory/Kconfig | 18 ++
>> drivers/memory/Makefile | 1 +
>> drivers/memory/stm32_omm.c | 476 +++++++++++++++++++++++++++++++++++++++++++++
>> 3 files changed, 495 insertions(+)
>>
>> diff --git a/drivers/memory/Kconfig b/drivers/memory/Kconfig
>> index c82d8d8a16eaf154c247c0dbb9aff428b7c81402..bc7ab46bd8b98a89f0d9173e884a99b778cdc9c4 100644
>> --- a/drivers/memory/Kconfig
>> +++ b/drivers/memory/Kconfig
>> @@ -225,6 +225,24 @@ config STM32_FMC2_EBI
>> devices (like SRAM, ethernet adapters, FPGAs, LCD displays, ...) on
>> SOCs containing the FMC2 External Bus Interface.
>>
>> +config STM32_OMM
>> + tristate "STM32 Octo Memory Manager"
>> + depends on ARCH_STM32 || COMPILE_TEST
>> + depends on SPI_STM32_OSPI
>
> I don't think you tested for the reported issue. I reported that
> firewall symbols are missing and you add dependency on ospi. How is that
> related? How does this solve any problem?
Hi Krzysztof
The dependency with SPI_STM32_OSPI was already present since the beginning.
I just added dependency on ARCH_STM32 on this current version to avoid issue on x86_64 arch.
On my side i tested compilation on arm, arm64 and x86_64 without any issue.
I tried to reproduce your build process:
make -j16 defconfig
HOSTCC scripts/basic/fixdep
HOSTCC scripts/kconfig/conf.o
HOSTCC scripts/kconfig/confdata.o
HOSTCC scripts/kconfig/expr.o
LEX scripts/kconfig/lexer.lex.c
YACC scripts/kconfig/parser.tab.[ch]
HOSTCC scripts/kconfig/menu.o
HOSTCC scripts/kconfig/preprocess.o
HOSTCC scripts/kconfig/symbol.o
HOSTCC scripts/kconfig/util.o
HOSTCC scripts/kconfig/lexer.lex.o
HOSTCC scripts/kconfig/parser.tab.o
HOSTLD scripts/kconfig/conf
*** Default configuration is based on 'x86_64_defconfig'
#
# configuration written to .config
#
scripts/config --file .config -e COMPILE_TEST -e OF -e SRAM -e MEMORY -e PM_DEVFREQ -e FPGA -e FPGA_DFL
scripts/config --file .config -e SAMSUNG_MC
scripts/config --file .config -e EXYNOS5422_DMC
scripts/config --file .config -e EXYNOS_SROM
scripts/config --file .config -e TEGRA_MC
scripts/config --file .config -e TEGRA20_EMC
scripts/config --file .config -e TEGRA30_EMC
scripts/config --file .config -e TEGRA124_EMC
scripts/config --file .config -e TEGRA210_EMC_TABLE
scripts/config --file .config -e TEGRA210_EMC
scripts/config --file .config -e MEMORY
scripts/config --file .config -e DDR
scripts/config --file .config -e ARM_PL172_MPMC
scripts/config --file .config -e ATMEL_EBI
scripts/config --file .config -e BRCMSTB_DPFE
scripts/config --file .config -e BRCMSTB_MEMC
scripts/config --file .config -e BT1_L2_CTL
scripts/config --file .config -e TI_AEMIF
scripts/config --file .config -e TI_EMIF
scripts/config --file .config -e OMAP_GPMC
scripts/config --file .config -e OMAP_GPMC_DEBUG
scripts/config --file .config -e TI_EMIF_SRAM
scripts/config --file .config -e FPGA_DFL_EMIF
scripts/config --file .config -e MVEBU_DEVBUS
scripts/config --file .config -e FSL_CORENET_CF
scripts/config --file .config -e FSL_IFC
scripts/config --file .config -e JZ4780_NEMC
scripts/config --file .config -e MTK_SMI
scripts/config --file .config -e DA8XX_DDRCTL
scripts/config --file .config -e PL353_SMC
scripts/config --file .config -e RENESAS_RPCIF
scripts/config --file .config -e STM32_FMC2_EBI
scripts/config --file .config -e STM32_OMM
make -j16 olddefconfig
#
# configuration written to .config
#
make -j16
SYNC include/config/auto.conf.cmd
GEN arch/x86/include/generated/asm/orc_hash.h
WRAP arch/x86/include/generated/uapi/asm/bpf_perf_event.h
WRAP arch/x86/include/generated/uapi/asm/errno.h
WRAP arch/x86/include/generated/uapi/asm/fcntl.h
WRAP arch/x86/include/generated/uapi/asm/ioctl.h
WRAP arch/x86/include/generated/uapi/asm/ioctls.h
WRAP arch/x86/include/generated/uapi/asm/ipcbuf.h
SYSHDR arch/x86/include/generated/uapi/asm/unistd_32.h
SYSHDR arch/x86/include/generated/uapi/asm/unistd_64.h
WRAP arch/x86/include/generated/uapi/asm/param.h
WRAP arch/x86/include/generated/uapi/asm/poll.h
SYSHDR arch/x86/include/generated/uapi/asm/unistd_x32.h
WRAP arch/x86/include/generated/uapi/asm/resource.h
SYSTBL arch/x86/include/generated/asm/syscalls_32.h
UPD include/generated/uapi/linux/version.h
SYSHDR arch/x86/include/generated/asm/unistd_32_ia32.h
SYSHDR arch/x86/include/generated/asm/unistd_64_x32.h
WRAP arch/x86/include/generated/uapi/asm/socket.h
SYSTBL arch/x86/include/generated/asm/syscalls_64.h
WRAP arch/x86/include/generated/uapi/asm/sockios.h
WRAP arch/x86/include/generated/uapi/asm/termbits.h
UPD arch/x86/include/generated/asm/cpufeaturemasks.h
WRAP arch/x86/include/generated/uapi/asm/termios.h
HOSTCC scripts/dtc/dtc.o
[...]
CC drivers/gpu/drm/i915/i915_vgpu.o
AR drivers/gpu/drm/i915/built-in.a
AR drivers/gpu/drm/built-in.a
AR drivers/gpu/built-in.a
AR drivers/built-in.a
AR built-in.a
AR vmlinux.a
LD vmlinux.o
OBJCOPY modules.builtin.modinfo
GEN modules.builtin
MODPOST Module.symvers
CC .vmlinux.export.o
CC [M] fs/efivarfs/efivarfs.mod.o
CC [M] .module-common.o
CC [M] drivers/thermal/intel/x86_pkg_temp_thermal.mod.o
CC [M] drivers/cpufreq/mediatek-cpufreq-hw.mod.o
CC [M] drivers/perf/thunderx2_pmu.mod.o
CC [M] net/netfilter/xt_mark.mod.o
CC [M] net/netfilter/nf_log_syslog.mod.o
CC [M] net/netfilter/xt_nat.mod.o
CC [M] net/netfilter/xt_LOG.mod.o
CC [M] net/netfilter/xt_MASQUERADE.mod.o
CC [M] net/netfilter/xt_addrtype.mod.o
CC [M] net/ipv4/netfilter/iptable_nat.mod.o
LD [M] fs/efivarfs/efivarfs.ko
LD [M] drivers/cpufreq/mediatek-cpufreq-hw.ko
LD [M] drivers/thermal/intel/x86_pkg_temp_thermal.ko
LD [M] drivers/perf/thunderx2_pmu.ko
LD [M] net/netfilter/xt_mark.ko
LD [M] net/netfilter/nf_log_syslog.ko
LD [M] net/ipv4/netfilter/iptable_nat.ko
LD [M] net/netfilter/xt_MASQUERADE.ko
LD [M] net/netfilter/xt_addrtype.ko
LD [M] net/netfilter/xt_LOG.ko
LD [M] net/netfilter/xt_nat.ko
UPD include/generated/utsversion.h
CC init/version-timestamp.o
KSYMS .tmp_vmlinux0.kallsyms.S
AS .tmp_vmlinux0.kallsyms.o
LD .tmp_vmlinux1
NM .tmp_vmlinux1.syms
KSYMS .tmp_vmlinux1.kallsyms.S
AS .tmp_vmlinux1.kallsyms.o
LD .tmp_vmlinux2
NM .tmp_vmlinux2.syms
KSYMS .tmp_vmlinux2.kallsyms.S
AS .tmp_vmlinux2.kallsyms.o
LD vmlinux.unstripped
NM System.map
SORTTAB vmlinux.unstripped
RSTRIP vmlinux
CC arch/x86/boot/a20.o
AS arch/x86/boot/bioscall.o
CC arch/x86/boot/cmdline.o
AS arch/x86/boot/copy.o
HOSTCC arch/x86/boot/mkcpustr
CC arch/x86/boot/cpuflags.o
CC arch/x86/boot/cpucheck.o
CC arch/x86/boot/edd.o
CC arch/x86/boot/early_serial_console.o
CC arch/x86/boot/main.o
CC arch/x86/boot/memory.o
CC arch/x86/boot/pm.o
AS arch/x86/boot/pmjump.o
CC arch/x86/boot/printf.o
CC arch/x86/boot/regs.o
CC arch/x86/boot/string.o
CC arch/x86/boot/tty.o
CC arch/x86/boot/video.o
CC arch/x86/boot/video-mode.o
CC arch/x86/boot/version.o
CC arch/x86/boot/video-vga.o
CC arch/x86/boot/video-vesa.o
CC arch/x86/boot/video-bios.o
CPUSTR arch/x86/boot/cpustr.h
CC arch/x86/boot/cpu.o
LDS arch/x86/boot/compressed/vmlinux.lds
AS arch/x86/boot/compressed/kernel_info.o
AS arch/x86/boot/compressed/head_64.o
VOFFSET arch/x86/boot/compressed/../voffset.h
CC arch/x86/boot/compressed/string.o
CC arch/x86/boot/compressed/error.o
CC arch/x86/boot/compressed/cmdline.o
OBJCOPY arch/x86/boot/compressed/vmlinux.bin
RELOCS arch/x86/boot/compressed/vmlinux.relocs
HOSTCC arch/x86/boot/compressed/mkpiggy
CC arch/x86/boot/compressed/cpuflags.o
CC arch/x86/boot/compressed/early_serial_console.o
CC arch/x86/boot/compressed/kaslr.o
CC arch/x86/boot/compressed/ident_map_64.o
CC arch/x86/boot/compressed/idt_64.o
AS arch/x86/boot/compressed/idt_handlers_64.o
CC arch/x86/boot/compressed/pgtable_64.o
AS arch/x86/boot/compressed/la57toggle.o
CC arch/x86/boot/compressed/acpi.o
CC arch/x86/boot/compressed/efi.o
GZIP arch/x86/boot/compressed/vmlinux.bin.gz
CC arch/x86/boot/compressed/misc.o
MKPIGGY arch/x86/boot/compressed/piggy.S
AS arch/x86/boot/compressed/piggy.o
LD arch/x86/boot/compressed/vmlinux
ZOFFSET arch/x86/boot/zoffset.h
OBJCOPY arch/x86/boot/vmlinux.bin
AS arch/x86/boot/header.o
LD arch/x86/boot/setup.elf
OBJCOPY arch/x86/boot/setup.bin
BUILD arch/x86/boot/bzImage
Kernel: arch/x86/boot/bzImage is ready (#1)
As shown there is no issue, i don't know what is missing to reproduce the issue ?
Thanks
Patrice
>
> And to be sure, I applied this and obviously - as expected - same errors.
>
> Best regards,
> Krzysztof
Powered by blists - more mailing lists