Skip to content

Commit

Permalink
Merge remote-tracking branch 'remotes/pmaydell/tags/pull-target-arm-2…
Browse files Browse the repository at this point in the history
…0210413' into staging

target-arm queue:
 * Fix MPC setting for AN524 SRAM block
 * sphinx: qapidoc: Wrap "If" section body in a paragraph node

# gpg: Signature made Tue 13 Apr 2021 13:07:12 BST
# gpg:                using RSA key E1A5C593CD419DE28E8315CF3C2525ED14360CDE
# gpg:                issuer "peter.maydell@linaro.org"
# gpg: Good signature from "Peter Maydell <peter.maydell@linaro.org>" [ultimate]
# gpg:                 aka "Peter Maydell <pmaydell@gmail.com>" [ultimate]
# gpg:                 aka "Peter Maydell <pmaydell@chiark.greenend.org.uk>" [ultimate]
# Primary key fingerprint: E1A5 C593 CD41 9DE2 8E83  15CF 3C25 25ED 1436 0CDE

* remotes/pmaydell/tags/pull-target-arm-20210413:
  sphinx: qapidoc: Wrap "If" section body in a paragraph node
  hw/arm/mps2-tz: Assert if more than one RAM is attached to an MPC
  hw/arm/mps2-tz: Fix MPC setting for AN524 SRAM block

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
  • Loading branch information
pm215 committed Apr 13, 2021
2 parents 2935f6f + 2d18b4c commit 1b66515
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
4 changes: 3 additions & 1 deletion docs/sphinx/qapidoc.py
Expand Up @@ -278,7 +278,9 @@ def _nodes_for_if_section(self, ifcond):
nodelist = []
if ifcond:
snode = self._make_section('If')
snode += self._nodes_for_ifcond(ifcond, with_if=False)
snode += nodes.paragraph(
'', '', *self._nodes_for_ifcond(ifcond, with_if=False)
)
nodelist.append(snode)
return nodelist

Expand Down
10 changes: 7 additions & 3 deletions hw/arm/mps2-tz.c
Expand Up @@ -238,7 +238,7 @@ static const RAMInfo an524_raminfo[] = { {
.name = "sram",
.base = 0x20000000,
.size = 32 * 4 * KiB,
.mpc = 1,
.mpc = -1,
.mrindex = 1,
}, {
/* We don't model QSPI flash yet; for now expose it as simple ROM */
Expand Down Expand Up @@ -306,14 +306,18 @@ static const RAMInfo *find_raminfo_for_mpc(MPS2TZMachineState *mms, int mpc)
{
MPS2TZMachineClass *mmc = MPS2TZ_MACHINE_GET_CLASS(mms);
const RAMInfo *p;
const RAMInfo *found = NULL;

for (p = mmc->raminfo; p->name; p++) {
if (p->mpc == mpc && !(p->flags & IS_ALIAS)) {
return p;
/* There should only be one entry in the array for this MPC */
g_assert(!found);
found = p;
}
}
/* if raminfo array doesn't have an entry for each MPC this is a bug */
g_assert_not_reached();
assert(found);
return found;
}

static MemoryRegion *mr_for_raminfo(MPS2TZMachineState *mms,
Expand Down

0 comments on commit 1b66515

Please sign in to comment.