riscv: sifive: fu540: Use OTP DM driver for serial environment variable

Use the OTP DM driver to set the serial environment variable.

Signed-off-by: Pragnesh Patel <pragnesh.patel@sifive.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
Tested-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Jagan Teki <jagan@amarulasolutions.com>
Tested-by: Jagan Teki <jagan@amarulasolutions.com>
This commit is contained in:
Pragnesh Patel
2020-05-29 11:33:22 +05:30
committed by Andes
parent 05307213c6
commit 88eec6159a
4 changed files with 60 additions and 75 deletions

View File

@@ -0,0 +1,14 @@
// SPDX-License-Identifier: (GPL-2.0 OR MIT)
/*
* (C) Copyright 2019 SiFive, Inc
*/
/ {
soc {
otp: otp@10070000 {
compatible = "sifive,fu540-c000-otp";
reg = <0x0 0x10070000 0x0 0x0FFF>;
fuse-count = <0x1000>;
};
};
};

View File

@@ -3,6 +3,8 @@
* Copyright (C) 2019 Jagan Teki <jagan@amarulasolutions.com>
*/
#include "fu540-c000-u-boot.dtsi"
/ {
aliases {
spi0 = &qspi0;