All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] Fix scpsys on MT6797
@ 2018-09-03 20:06 Jasper Mattsson
  0 siblings, 0 replies; only message in thread
From: Jasper Mattsson @ 2018-09-03 20:06 UTC (permalink / raw)
  To: linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r
  Cc: matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w

Hello,

On MT6797, SCPSYS probe fails due to gaps in the scp_domain_data_mt6797
array. The gaps are due to omitted MFG_* power domains. This could be
solved by rearranging the #defines in dt-bindings, but I'm not sure if
that's allowed as it would break compatibility with existing DTBs.

Audio, VENC, VDEC, and MJC were also missing clocks, which I added.

Additionally, if SCPSYS is started with the power domains initially
disabled (e.g. when booting with kexec), it will hang the system. This
is because all the domains are initially powered on in the order they
are defined in the scp_domain_data array, disregarding any subdomain
dependencies. VENC and VDEC are subdomains of MM, but appear before it
in the array. This makes the system hang. Again, this could be solved by
reordering the #defines, but instead I added the MM clock to the domains
and that fixed things even if the MM domain is not powerd on by SPM.

There *might* be a bug that I did not fix, because I am not sure if it
is a bug at all - MFG_ASYNC does not have any bus protection flags,
but on Android

To properly test this patch, you'll need to apply my previous patch
which fixes some clocks, otherwise the system would not work properly
without clk_ignore_unused. The previous patch shows wrong on Patchwork,
not sure what I messed up (should I re-send?), so here's a link to all
my patches, which should only include this and the clk patch at the time
of writing:

https://patchwork.kernel.org/project/linux-mediatek/list/?submitter=182219


Best regards,
Jasper Mattsson

Jasper Mattsson (3):
  soc: mediatek: Bind missing clocks to scpsys on the MT6797
  soc: mediatek: Allow gaps in SCP PDs
  dts: mediatek: mt6797: Bind audio, mjc, and venc clocks to SCPSYS

 .../bindings/soc/mediatek/scpsys.txt          |  2 +-
 arch/arm64/boot/dts/mediatek/mt6797.dtsi      |  9 +++++---
 drivers/soc/mediatek/mtk-scpsys.c             | 21 ++++++++++++++-----
 3 files changed, 23 insertions(+), 9 deletions(-)

--
2.18.0

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2018-09-03 20:06 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-03 20:06 [PATCH 0/3] Fix scpsys on MT6797 Jasper Mattsson

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.