Commit de0818e9 authored by Georgi Djakov's avatar Georgi Djakov
Browse files

Merge branch 'icc-mtk' into icc-next

MediaTek DVFSRC Bus Bandwidth and Regulator knobs

This series adds support for the MediaTek Dynamic Voltage and Frequency
Scaling Resource Controller (DVFSRC), found on many MediaTek SoCs.

This hardware collects requests from both software and the various remote
processors embededd into the SoC, and decides about a minimum operating
voltage and a minimum DRAM frequency to fulfill those requests, in an
effort to provide the best achievable performance per watt.

Such hardware IP is capable of transparently performing direct register
R/W on all of the DVFSRC-controlled regulators and SoC bandwidth knobs.

Summarizing how the DVFSRC works for Interconnect:

             ICC provider         ICC Nodes
                              ----          ----
             _________       |CPU |   |--- |VPU |
    _____   |         |-----  ----    |     ----
   |     |->|  DRAM   |       ----    |     ----
   |DRAM |->|scheduler|----- |GPU |   |--- |DISP|
   |     |->|  (EMI)  |       ----    |     ----
   |_____|->|_________|---.   -----   |     ----
               /|\         `-|MMSYS|--|--- |VDEC|
                |             -----   |     ----
                |                     |     ----
                | change DRAM freq    |--- |VENC|
             --------                 |     ----
    SMC --> | DVFSRC |                |     ----
             --------                 |--- |IMG |
                                      |     ----
                                      |     ----
                                      |--- |CAM |
                                            ----

* icc-mtk
  dt-bindings: interconnect: Add MediaTek EMI Interconnect bindings
  interconnect: mediatek: Add MediaTek MT8183/8195 EMI Interconnect driver
  interconnect: mediatek: remove unneeded semicolon

Link: https://lore.kernel.org/r/20240610085735.147134-1-angelogioacchino.delregno@collabora.com


Signed-off-by: default avatarGeorgi Djakov <djakov@kernel.org>
parents b14aa62c 9265ea04
Loading
Loading
Loading
Loading
+51 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
%YAML 1.2
---
$id: http://devicetree.org/schemas/interconnect/mediatek,mt8183-emi.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: MediaTek External Memory Interface (EMI) Interconnect

maintainers:
  - AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>

description: |
  EMI interconnect providers support system bandwidth requirements through
  Dynamic Voltage Frequency Scaling Resource Collector (DVFSRC) hardware.
  The provider is able to communicate with the DVFSRC through Secure Monitor
  Call (SMC).

             ICC provider         ICC Nodes
                              ----          ----
             _________       |CPU |   |--- |VPU |
    _____   |         |-----  ----    |     ----
   |     |->|  DRAM   |       ----    |     ----
   |DRAM |->|scheduler|----- |GPU |   |--- |DISP|
   |     |->|  (EMI)  |       ----    |     ----
   |_____|->|_________|---.   -----   |     ----
               /|\         `-|MMSYS|--|--- |VDEC|
                |             -----   |     ----
                |                     |     ----
                | change DRAM freq    |--- |VENC|
             --------                 |     ----
    SMC --> | DVFSRC |                |     ----
             --------                 |--- |IMG |
                                      |     ----
                                      |     ----
                                      |--- |CAM |
                                            ----

properties:
  compatible:
    enum:
      - mediatek,mt8183-emi
      - mediatek,mt8195-emi

  '#interconnect-cells':
    const: 1

required:
  - compatible
  - '#interconnect-cells'

unevaluatedProperties: false
+1 −0
Original line number Diff line number Diff line
@@ -12,6 +12,7 @@ menuconfig INTERCONNECT
if INTERCONNECT

source "drivers/interconnect/imx/Kconfig"
source "drivers/interconnect/mediatek/Kconfig"
source "drivers/interconnect/qcom/Kconfig"
source "drivers/interconnect/samsung/Kconfig"

+1 −0
Original line number Diff line number Diff line
@@ -5,6 +5,7 @@ icc-core-objs := core.o bulk.o debugfs-client.o

obj-$(CONFIG_INTERCONNECT)		+= icc-core.o
obj-$(CONFIG_INTERCONNECT_IMX)		+= imx/
obj-$(CONFIG_INTERCONNECT_MTK)		+= mediatek/
obj-$(CONFIG_INTERCONNECT_QCOM)		+= qcom/
obj-$(CONFIG_INTERCONNECT_SAMSUNG)	+= samsung/

+29 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0-only

config INTERCONNECT_MTK
	bool "MediaTek interconnect drivers"
	depends on ARCH_MEDIATEK || COMPILE_TEST
	help
	  Support for MediaTek's bus interconnect hardware.

config INTERCONNECT_MTK_DVFSRC_EMI
	tristate "MediaTek DVFSRC EMI interconnect driver"
	depends on INTERCONNECT_MTK && MTK_DVFSRC
	help
	  This is a driver for the MediaTek External Memory Interface
	  interconnect on SoCs equipped with the integrated Dynamic
	  Voltage Frequency Scaling Resource Collector (DVFSRC) MCU

config INTERCONNECT_MTK_MT8183
	tristate "MediaTek MT8183 interconnect driver"
	depends on INTERCONNECT_MTK_DVFSRC_EMI
	help
	  This is a driver for the MediaTek bus interconnect on MT8183-based
	  platforms.

config INTERCONNECT_MTK_MT8195
	tristate "MediaTek MT8195 interconnect driver"
	depends on INTERCONNECT_MTK_DVFSRC_EMI
	help
	  This is a driver for the MediaTek bus interconnect on MT8195-based
	  platforms.
+5 −0
Original line number Diff line number Diff line
# SPDX-License-Identifier: GPL-2.0

obj-$(CONFIG_INTERCONNECT_MTK_DVFSRC_EMI) += icc-emi.o
obj-$(CONFIG_INTERCONNECT_MTK_MT8183) += mt8183.o
obj-$(CONFIG_INTERCONNECT_MTK_MT8195) += mt8195.o
Loading