Skip to content

Commit

Permalink
drivers: soc: sunxi: add support for A64 and its SRAM C
Browse files Browse the repository at this point in the history
Allwinner A64's display engine claims the SRAM C section to work.

Add support for the A64 SRAM controller and the SRAM C section of it.

Signed-off-by: Icenowy Zheng <[email protected]>
Signed-off-by: Chen-Yu Tsai <[email protected]>
  • Loading branch information
Icenowy authored and wens committed Aug 18, 2017
1 parent 8fed2ce commit 5e4fb64
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions drivers/soc/sunxi/sunxi_sram.c
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@ static struct sunxi_sram_desc sun4i_a10_sram_d = {
SUNXI_SRAM_MAP(1, 1, "usb-otg")),
};

static struct sunxi_sram_desc sun50i_a64_sram_c = {
.data = SUNXI_SRAM_DATA("C", 0x4, 24, 1,
SUNXI_SRAM_MAP(0, 1, "cpu"),
SUNXI_SRAM_MAP(1, 0, "de2")),
};

static const struct of_device_id sunxi_sram_dt_ids[] = {
{
.compatible = "allwinner,sun4i-a10-sram-a3-a4",
Expand All @@ -78,6 +84,10 @@ static const struct of_device_id sunxi_sram_dt_ids[] = {
.compatible = "allwinner,sun4i-a10-sram-d",
.data = &sun4i_a10_sram_d.data,
},
{
.compatible = "allwinner,sun50i-a64-sram-c",
.data = &sun50i_a64_sram_c.data,
},
{}
};

Expand Down Expand Up @@ -295,6 +305,7 @@ static int sunxi_sram_probe(struct platform_device *pdev)

static const struct of_device_id sunxi_sram_dt_match[] = {
{ .compatible = "allwinner,sun4i-a10-sram-controller" },
{ .compatible = "allwinner,sun50i-a64-sram-controller" },
{ },
};
MODULE_DEVICE_TABLE(of, sunxi_sram_dt_match);
Expand Down

0 comments on commit 5e4fb64

Please sign in to comment.