diff options
| author | Tom Rini <[email protected]> | 2026-03-10 08:17:13 -0600 |
|---|---|---|
| committer | Tom Rini <[email protected]> | 2026-03-10 10:07:04 -0600 |
| commit | d93a63acfe701aa07c9223ec454164c88e7eb43d (patch) | |
| tree | d935a44a60fe34eb9989ad72168d9c384cc403d0 /drivers/ram | |
| parent | 045fb42827cd8a24cc1024550421f867d1a954c7 (diff) | |
| parent | cff18cef190684736ff11feff0da6dbd7324ed9d (diff) | |
Merge tag 'u-boot-rockchip-20260309' of https://source.denx.de/u-boot/custodians/u-boot-rockchip into next
CI: https://source.denx.de/u-boot/custodians/u-boot-rockchip/-/pipelines/29452
- New SoC support: RK3506, RK3582;
- New Board support: RK3528 FriendlyElec NanoPi Zero2;
- Other fixes
Diffstat (limited to 'drivers/ram')
| -rw-r--r-- | drivers/ram/rockchip/Makefile | 1 | ||||
| -rw-r--r-- | drivers/ram/rockchip/sdram_rk3506.c | 33 |
2 files changed, 34 insertions, 0 deletions
diff --git a/drivers/ram/rockchip/Makefile b/drivers/ram/rockchip/Makefile index fd94aad0cd4..27921ae4921 100644 --- a/drivers/ram/rockchip/Makefile +++ b/drivers/ram/rockchip/Makefile @@ -13,6 +13,7 @@ obj-$(CONFIG_ROCKCHIP_RK3288) = sdram_rk3288.o obj-$(CONFIG_ROCKCHIP_RK3308) = sdram_rk3308.o obj-$(CONFIG_ROCKCHIP_RK3328) = sdram_rk3328.o sdram_pctl_px30.o sdram_phy_px30.o obj-$(CONFIG_ROCKCHIP_RK3399) += sdram_rk3399.o +obj-$(CONFIG_ROCKCHIP_RK3506) += sdram_rk3506.o obj-$(CONFIG_ROCKCHIP_RK3528) += sdram_rk3528.o obj-$(CONFIG_ROCKCHIP_RK3568) += sdram_rk3568.o obj-$(CONFIG_ROCKCHIP_RK3576) += sdram_rk3576.o diff --git a/drivers/ram/rockchip/sdram_rk3506.c b/drivers/ram/rockchip/sdram_rk3506.c new file mode 100644 index 00000000000..a8396ea8888 --- /dev/null +++ b/drivers/ram/rockchip/sdram_rk3506.c @@ -0,0 +1,33 @@ +// SPDX-License-Identifier: GPL-2.0-or-later +// Copyright Contributors to the U-Boot project. + +#include <dm.h> +#include <ram.h> +#include <asm/arch-rockchip/sdram.h> + +#define PMUGRF_BASE 0xff910000 +#define OS_REG2_REG 0x208 + +static int rk3506_dmc_get_info(struct udevice *dev, struct ram_info *info) +{ + info->base = CFG_SYS_SDRAM_BASE; + info->size = rockchip_sdram_size(PMUGRF_BASE + OS_REG2_REG); + + return 0; +} + +static struct ram_ops rk3506_dmc_ops = { + .get_info = rk3506_dmc_get_info, +}; + +static const struct udevice_id rk3506_dmc_ids[] = { + { .compatible = "rockchip,rk3506-dmc" }, + { } +}; + +U_BOOT_DRIVER(rockchip_rk3506_dmc) = { + .name = "rockchip_rk3506_dmc", + .id = UCLASS_RAM, + .of_match = rk3506_dmc_ids, + .ops = &rk3506_dmc_ops, +}; |
