All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexandre IOOSS <erdnaxe@crans.org>
To: Alistair Francis <alistair23@gmail.com>
Cc: Peter Maydell <peter.maydell@linaro.org>,
	"open list:STM32F100" <qemu-arm@nongnu.org>,
	"open list:All patches CC here" <qemu-devel@nongnu.org>,
	f4bug@amsat.org
Subject: Re: [PATCH 1/2] stm32f100: Add the stm32f100 SoC
Date: Tue, 15 Jun 2021 11:15:56 +0200	[thread overview]
Message-ID: <7e8a01c5-0130-1003-8396-af8d4b45d2c0@crans.org> (raw)
In-Reply-To: <CAKmqyKMETmc0sJbG8FdUokg9Ke_hg5ohZ2YnLzyQO1xwzpXMRA@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 1867 bytes --]



On 6/15/21 10:04 AM, Alistair Francis wrote:
> On Tue, Jun 15, 2021 at 5:50 PM Alexandre IOOSS <erdnaxe@crans.org> wrote:
>>
>> On 6/15/21 9:41 AM, Alistair Francis wrote:
>>> Aren't you missing some timers, like timer[5] 0x4000_0C00?
>>>
>>> Alistair
>>
>> I double-checked using the reference manual and the datasheet and there
>> is not timer[5]:
>> - page 36 of
>> https://www.st.com/resource/en/reference_manual/cd00246267-stm32f100xx-advanced-arm-based-32-bit-mcus-stmicroelectronics.pdf
> 
> Strange, https://www.st.com/resource/en/datasheet/stm32f100rc.pdf
> describes Timer 5 and page 282 of the document you linked talks about
> timer 5 as well.
> 
> Alistair
> 
>> - page 30 of https://www.st.com/resource/en/datasheet/stm32f100cb.pdf
>>
>> I believe ST is skipping numbers to guarantee that timer[n] will have a
>> consistent address on different STM32 SoC.
>>
>> Thanks,
>> -- Alexandre
>>

 From what I understand from other STM32F100xx reference manuals:
I am implementing all peripherals in the STM32F100xx reference manual 
which match with what is actually in the STM32F100RB SoC (used in the 
STM32VLDISCOVERY).

STM32F100RC SoC implements more peripherals (more USART, more 
timers...). Adding these peripherals in stm32f100.c means that the 
STM32VLDISCOVERY machine would have peripherals that does not exist on 
the real target. Do we want to avoid that?

Should we keep stm32f100.c with the common subset of peripherals and 
extend it when a machine is using a variant with more peripherals?

I believe this issue is also linked with what Philippe proposed: we 
could abstract STM32 SoC in the same way ATMEGA is abstracted. This 
would make a lot of sense since the STM32 family has a lot of 
similarities and we don't want to bloat QEMU with N times the same code.

Thanks,
-- Alexandre


[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 840 bytes --]

  reply	other threads:[~2021-06-15  9:17 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-08 16:10 [PATCH 0/2] STM32VLDISCOVERY Machine Model Alexandre Iooss
2021-06-08 16:10 ` [PATCH 1/2] stm32f100: Add the stm32f100 SoC Alexandre Iooss
2021-06-14 16:04   ` Peter Maydell
2021-06-15  7:56     ` Alexandre IOOSS
2021-06-15  7:41   ` Alistair Francis
2021-06-15  7:49     ` Alexandre IOOSS
2021-06-15  8:04       ` Alistair Francis
2021-06-15  9:15         ` Alexandre IOOSS [this message]
2021-06-15 10:40           ` Alistair Francis
2021-06-08 16:10 ` [PATCH 2/2] stm32vldiscovery: Add the STM32VLDISCOVERY Machine Alexandre Iooss
2021-06-14 15:52   ` Peter Maydell
2021-06-15  7:16     ` Alexandre IOOSS
2021-06-15  7:50       ` Alistair Francis
2021-06-15  9:07       ` Peter Maydell
2021-06-14 16:05 ` [PATCH 0/2] STM32VLDISCOVERY Machine Model Peter Maydell
2021-06-14 16:16   ` Philippe Mathieu-Daudé

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7e8a01c5-0130-1003-8396-af8d4b45d2c0@crans.org \
    --to=erdnaxe@crans.org \
    --cc=alistair23@gmail.com \
    --cc=f4bug@amsat.org \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.