[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: What is TYPE_TPM_TIS_ISA? (Not an ISA Device)
From: |
Peter Maydell |
Subject: |
Re: What is TYPE_TPM_TIS_ISA? (Not an ISA Device) |
Date: |
Tue, 21 Jul 2020 17:40:27 +0100 |
On Tue, 21 Jul 2020 at 17:07, Philippe Mathieu-Daudé <philmd@redhat.com> wrote:
>
> Hi Stefan,
>
> I'm trying to understand what is modelling the
> TYPE_TPM_TIS_ISA device.
>
> It inherits from TYPE_ISA_DEVICE, so I expected
> to see an ISA device, but then I noticed:
>
> 1/ it doesn't use the ISA I/O space, it directly
> maps the device in the system memory at a fixed
> address that is not addressable by the ISA bus:
>
> #define TPM_TIS_ADDR_BASE 0xFED40000
Why do you think this is mapping to the system memory?
tpm_tis_isa_realizefn() does:
memory_region_add_subregion(isa_address_space(ISA_DEVICE(dev)),
TPM_TIS_ADDR_BASE, &s->mmio);
which puts it into the ISA memory address space.
The weird thing about this is not which AS it's
going in but the fact that the TPM_TIS_ADDR_BASE
is way higher than an actual ISA bus can address
(so for instance it's out of range of the size of
the ISA memory window on the Jazz board).
> 2/ it is not plugged to an ISA BUS (ISABus*)
Won't it autoplug into the ISA bus if you say "-device tpm-tis",
the same as any other ISA device ?
> 3/ no machine plug it using isa_register_ioport()
> (it is not registered to the ISA memory space)
There's no requirement for an ISA device to have IO ports...
thanks
-- PMM