On 4/3/23 16:48, Lucas C. Villa Real wrote:
On Mon, Apr 3, 2023 at 10:54 AM Peter Maydell <peter.mayd...@linaro.org <mailto:peter.mayd...@linaro.org>> wrote:On Mon, 3 Apr 2023 at 13:51, Lucas Villa Real <luca...@gmail.com <mailto:luca...@gmail.com>> wrote: > > stm32vldiscovery comes with 8KB of SRAM, which may be too low when > running some workloads on QEMU. The command line argument "-m mem_size" > is not recognized by the current implementation, though, so one cannot > easily override the default memory size. > > This patch fixes that by adding a memory subregion according to the > value provided on that command line argument. If absent, the default > value of 8KB still applies. > > Signed-off-by: Lucas Villa Real <lu...@osdyne.com <mailto:lu...@osdyne.com>> Does the real hardware have (options for) more than 8K of SRAM here ? thanks -- PMMYes, it's possible to add more (p)SRAM via the STM32F10xxx's FSMC (flexible static memory controller). The new memory is mapped to FSMC bank 1 at 0x6000_0000, though (as opposed to the embedded SRAM's fixed address at 0x2000_0000), as I have now realized. I'm happy to send an updated patch so that "-m mem_size" creates a memory subregion at 0x6000_0000 instead.Best regards, Lucas
Looking at the STM32F100xx reference manual page 494 (https://www.st.com/resource/en/reference_manual/rm0041-stm32f100xx-advanced-armbased-32bit-mcus-stmicroelectronics.pdf), FSMC is only present on high-density value line devices only. This is not the case of the STM32VLDISCOVERY which uses a STM32F100RB (low/medium-density value line).
Correct me if I'm wrong, but I believe you cannot buy a STM32VLDISCOVERY that could support FSMC or have more than 8KB of on-chip SRAM.
However, could it be a good idea to implement a generic STM32F100xx machine in QEMU that is "high-density" by default and that could be configured using command line options ? This could cover a wide range of cases with a single machine.
Thanks, -- Alexandre
OpenPGP_signature
Description: OpenPGP digital signature