aboutsummaryrefslogtreecommitdiff
path: root/include/tlv_eeprom.h
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-03-25 10:26:07 +1300
committerSimon Glass <sjg@chromium.org>2021-04-06 16:33:19 +1200
commit2f541aa53c73b00dfb613e0560cc703547233561 (patch)
treeec4870ef454857667bf2e0f5d643cfc0c24114ae /include/tlv_eeprom.h
parent24e3d5d2a9ed4e4cad6aba4694596efaf82c610c (diff)
downloadu-boot-2f541aa53c73b00dfb613e0560cc703547233561.zip
u-boot-2f541aa53c73b00dfb613e0560cc703547233561.tar.gz
u-boot-2f541aa53c73b00dfb613e0560cc703547233561.tar.bz2
tlv_eeprom: Return -ENOSYS when system call is not available
When CMD_TLV_EEPROM is not enabled, use -ENOSYS, which is the correct error code for U-Boot. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'include/tlv_eeprom.h')
-rw-r--r--include/tlv_eeprom.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/tlv_eeprom.h b/include/tlv_eeprom.h
index 1de2fe2..a2c333e 100644
--- a/include/tlv_eeprom.h
+++ b/include/tlv_eeprom.h
@@ -114,19 +114,19 @@ int read_tlvinfo_tlv_eeprom(void *eeprom, struct tlvinfo_header **hdr,
static inline int read_tlv_eeprom(void *eeprom, int offset, int len, int dev)
{
- return -ENOTSUPP;
+ return -ENOSYS;
}
static inline int write_tlv_eeprom(void *eeprom, int len)
{
- return -ENOTSUPP;
+ return -ENOSYS;
}
static inline int
read_tlvinfo_tlv_eeprom(void *eeprom, struct tlvinfo_header **hdr,
struct tlvinfo_tlv **first_entry, int dev)
{
- return -ENOTSUPP;
+ return -ENOSYS;
}
#endif /* CONFIG_IS_ENABLED(CMD_TLV_EEPROM) */