plat/stm32: Implement fdt_read_uint32_default() as a wrapper

The STM32 platform code uses its own set of FDT helper functions,
although some of them are fairly generic.

Remove the implementation of fdt_read_uint32_default() and implement it
on top of the newly introduced fdt_read_uint32() function, then convert
all users over.

This also fixes two callers, which were slightly abusing the "default"
semantic.

Change-Id: I570533362b4846e58dd797a92347de3e0e5abb75
Signed-off-by: Andre Przywara <andre.przywara@arm.com>
diff --git a/common/fdt_wrappers.c b/common/fdt_wrappers.c
index 394f3b0..57e3bcd 100644
--- a/common/fdt_wrappers.c
+++ b/common/fdt_wrappers.c
@@ -56,6 +56,19 @@
 	return fdt_read_uint32_array(dtb, node, prop_name, 1, value);
 }
 
+uint32_t fdt_read_uint32_default(const void *dtb, int node,
+				 const char *prop_name, uint32_t dflt_value)
+{
+	uint32_t ret = dflt_value;
+	int err = fdt_read_uint32(dtb, node, prop_name, &ret);
+
+	if (err < 0) {
+		return dflt_value;
+	}
+
+	return ret;
+}
+
 int fdt_read_uint64(const void *dtb, int node, const char *prop_name,
 		    uint64_t *value)
 {