[PATCH v2] memory: mediatek: add DRAM controller driver
Po-Kai Chi
pk.chi at mediatek.com
Fri Apr 16 10:32:14 BST 2021
These patch series introduces the MediaTek DRAM controller driver (DRAMC)
on MT6779 SoC, and enables to be built as a module by default for the
ARM64 builds.
MediaTek DRAMC driver provides cross-platform features as below:
- API provided to other kernel modules for querying DRAM type,
rank count, rank size, channel count and mode register settings.
- Sysfs interface used to pass DRAM mode register settings and current
DRAM data rate to user-space for MediaTek ecosystem.
The API user includes MediaTek External Memory Interface (EMI) and
DVFS Resource Control (DVFSRC), which will be sent to mainline later.
Changes since v1:
- add prefix to vendor properties in device tree, dt-binding and drivers
- fix dt-binding check fail
Po-Kai Chi (4):
dt-bindings: memory: Add binding for MediaTek DRAM Controller
memory: mediatek: add DRAM controller driver
arm64: dts: add DRAMC node for MT6779
arm64: defconfig: Enable MediaTek DRAMC common driver
.../memory-controllers/mediatek,dramc.yaml | 162 ++++
arch/arm64/boot/dts/mediatek/mt6779-evb.dts | 9 +
arch/arm64/boot/dts/mediatek/mt6779.dtsi | 18 +
arch/arm64/configs/defconfig | 1 +
drivers/memory/Kconfig | 1 +
drivers/memory/Makefile | 1 +
drivers/memory/mediatek/Kconfig | 9 +
drivers/memory/mediatek/Makefile | 3 +
drivers/memory/mediatek/mtk-dramc.c | 711 ++++++++++++++++++
include/memory/mediatek/dramc.h | 18 +
10 files changed, 933 insertions(+)
create mode 100644 Documentation/devicetree/bindings/memory-controllers/mediatek,dramc.yaml
create mode 100644 drivers/memory/mediatek/Kconfig
create mode 100644 drivers/memory/mediatek/Makefile
create mode 100644 drivers/memory/mediatek/mtk-dramc.c
create mode 100644 include/memory/mediatek/dramc.h
More information about the Linux-mediatek
mailing list