From mboxrd@z Thu Jan 1 00:00:00 1970 From: Simon Glass Date: Tue, 23 Mar 2021 17:14:23 +1300 Subject: [PATCH v2 5/9] tlv_eeprom: Return -ENOSYS when system call is not available In-Reply-To: <20210323041427.3252184-1-sjg@chromium.org> References: <20210323041427.3252184-1-sjg@chromium.org> Message-ID: <20210323041427.3252184-6-sjg@chromium.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de When CMD_TLV_EEPROM is not enabled, use -ENOSYS, which is the correct error code for U-Boot. Signed-off-by: Simon Glass --- (no changes since v1) include/tlv_eeprom.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/tlv_eeprom.h b/include/tlv_eeprom.h index 1de2fe2337c..a2c333e7446 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) */ -- 2.31.0.rc2.261.g7f71774620-goog