summaryrefslogtreecommitdiff
path: root/common/fdt_support.c
diff options
context:
space:
mode:
authorMarek BehĂșn <marek.behun@nic.cz>2021-11-26 14:57:08 +0100
committerStefan Roese <sr@denx.de>2021-12-19 09:50:47 +0100
commit2105cd042124623a7ad64b6955aba67115db83a3 (patch)
treebc5d845f0f95bc1bf2bcd254fb3f09d2f8622dd8 /common/fdt_support.c
parent76f5a72835a0e9a8f6bfc653b4b456a60d1f8800 (diff)
downloadu-boot-2105cd042124623a7ad64b6955aba67115db83a3.tar.gz
u-boot-2105cd042124623a7ad64b6955aba67115db83a3.tar.bz2
u-boot-2105cd042124623a7ad64b6955aba67115db83a3.zip
fdt_support: Remove FDT_STATUS_FAIL_ERROR_CODE
Since no one uses this feature and I am not aware of any parsers of this in Linux, remove it. Signed-off-by: Marek BehĂșn <marek.behun@nic.cz> Reviewed-by: Stefan Roese <sr@denx.de> Cc: Simon Glass <sjg@chromium.org> Cc: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Cc: Pratyush Yadav <p.yadav@ti.com> Cc: Tim Harvey <tharvey@gateworks.com> Cc: Michael Walle <michael@walle.cc> Cc: Priyanka Jain <priyanka.jain@nxp.com> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'common/fdt_support.c')
-rw-r--r--common/fdt_support.c20
1 files changed, 5 insertions, 15 deletions
diff --git a/common/fdt_support.c b/common/fdt_support.c
index be03a87d42..8ac905011c 100644
--- a/common/fdt_support.c
+++ b/common/fdt_support.c
@@ -1541,14 +1541,10 @@ unsigned int fdt_create_phandle(void *fdt, int nodeoffset)
*
* @fdt: ptr to device tree
* @nodeoffset: node to update
- * @status: FDT_STATUS_OKAY, FDT_STATUS_DISABLED,
- * FDT_STATUS_FAIL, FDT_STATUS_FAIL_ERROR_CODE
- * @error_code: optional, only used if status is FDT_STATUS_FAIL_ERROR_CODE
+ * @status: FDT_STATUS_OKAY, FDT_STATUS_DISABLED, FDT_STATUS_FAIL
*/
-int fdt_set_node_status(void *fdt, int nodeoffset,
- enum fdt_status status, unsigned int error_code)
+int fdt_set_node_status(void *fdt, int nodeoffset, enum fdt_status status)
{
- char buf[16];
int ret = 0;
if (nodeoffset < 0)
@@ -1564,10 +1560,6 @@ int fdt_set_node_status(void *fdt, int nodeoffset,
case FDT_STATUS_FAIL:
ret = fdt_setprop_string(fdt, nodeoffset, "status", "fail");
break;
- case FDT_STATUS_FAIL_ERROR_CODE:
- sprintf(buf, "fail-%d", error_code);
- ret = fdt_setprop_string(fdt, nodeoffset, "status", buf);
- break;
default:
printf("Invalid fdt status: %x\n", status);
ret = -1;
@@ -1582,16 +1574,14 @@ int fdt_set_node_status(void *fdt, int nodeoffset,
*
* @fdt: ptr to device tree
* @alias: alias of node to update
- * @status: FDT_STATUS_OKAY, FDT_STATUS_DISABLED,
- * FDT_STATUS_FAIL, FDT_STATUS_FAIL_ERROR_CODE
- * @error_code: optional, only used if status is FDT_STATUS_FAIL_ERROR_CODE
+ * @status: FDT_STATUS_OKAY, FDT_STATUS_DISABLED, FDT_STATUS_FAIL
*/
int fdt_set_status_by_alias(void *fdt, const char* alias,
- enum fdt_status status, unsigned int error_code)
+ enum fdt_status status)
{
int offset = fdt_path_offset(fdt, alias);
- return fdt_set_node_status(fdt, offset, status, error_code);
+ return fdt_set_node_status(fdt, offset, status);
}
#if defined(CONFIG_VIDEO) || defined(CONFIG_LCD)