From d45784e8891fb05b2800a686b8d481118f9ca3ce Mon Sep 17 00:00:00 2001 From: Baruch Siach Date: Sun, 23 Jun 2019 07:51:01 +0300 Subject: [PATCH] boot/mv-ddr-marvell: fix build with GCC 8 Add upstream patch fixing a build warning that is considered as error. Cc: Sergey Matyukevich Signed-off-by: Baruch Siach Signed-off-by: Thomas Petazzoni --- ...raining_leveling.c-uninitialized-var.patch | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 boot/mv-ddr-marvell/0001-mv_ddr-mv_ddr4_training_leveling.c-uninitialized-var.patch diff --git a/boot/mv-ddr-marvell/0001-mv_ddr-mv_ddr4_training_leveling.c-uninitialized-var.patch b/boot/mv-ddr-marvell/0001-mv_ddr-mv_ddr4_training_leveling.c-uninitialized-var.patch new file mode 100644 index 0000000000..eada18b473 --- /dev/null +++ b/boot/mv-ddr-marvell/0001-mv_ddr-mv_ddr4_training_leveling.c-uninitialized-var.patch @@ -0,0 +1,31 @@ +From 5867fcad6e88af3d843bfa831648d84a53732d57 Mon Sep 17 00:00:00 2001 +From: Heinrich Schuchardt +Date: Wed, 19 Dec 2018 17:17:13 +0100 +Subject: [PATCH] mv_ddr: mv_ddr4_training_leveling.c: uninitialized variable + +With GCC 8.2 uninitialized variables lead to a build error. + +Signed-off-by: Heinrich Schuchardt +Signed-off-by: Baruch Siach +--- +Upstream status: commit 5867fcad6e8 + + mv_ddr4_training_leveling.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/mv_ddr4_training_leveling.c b/mv_ddr4_training_leveling.c +index 144e21a03c01..cb95389f5466 100644 +--- a/mv_ddr4_training_leveling.c ++++ b/mv_ddr4_training_leveling.c +@@ -368,7 +368,7 @@ static int mv_ddr4_dynamic_pb_wl_supp(u32 dev_num, enum mv_wl_supp_mode ecc_mode + u32 subphy_num = ddr3_tip_dev_attr_get(dev_num, MV_ATTR_OCTET_PER_INTERFACE); + u8 compare_result = 0; + u32 orig_phase; +- u32 rd_data, wr_data; ++ u32 rd_data, wr_data = 0; + u32 flag, step; + struct mv_ddr_topology_map *tm = mv_ddr_topology_map_get(); + u32 ecc_phy_access_id; +-- +2.20.1 + -- 2.30.2