aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-03-25 10:26:04 +1300
committerSimon Glass <sjg@chromium.org>2021-04-06 16:33:19 +1200
commitaa4ad8bbad9d18c2363565418fc0d6e3dec4e928 (patch)
tree8d25310abf97843833d0612c61d7ff01f85b401b
parent42a2668743b58820392a2cde3c722822daa50db6 (diff)
downloadu-boot-aa4ad8bbad9d18c2363565418fc0d6e3dec4e928.zip
u-boot-aa4ad8bbad9d18c2363565418fc0d6e3dec4e928.tar.gz
u-boot-aa4ad8bbad9d18c2363565418fc0d6e3dec4e928.tar.bz2
dm: core: Use -ENOSPC in acpi_get_path()
Update this function to use -ENOSPC which is more commly used when a buffer runs out of space. Signed-off-by: Simon Glass <sjg@chromium.org>
-rw-r--r--drivers/core/acpi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/core/acpi.c b/drivers/core/acpi.c
index 0901b92..2176d8b 100644
--- a/drivers/core/acpi.c
+++ b/drivers/core/acpi.c
@@ -91,7 +91,7 @@ int acpi_get_path(const struct udevice *dev, char *out_path, int maxlen)
path = dev_read_string(dev, "acpi,path");
if (path) {
if (strlen(path) >= maxlen)
- return -E2BIG;
+ return -ENOSPC;
strcpy(out_path, path);
return 0;
}