firmware: dmi_scan: Make dmi_walk and dmi_walk_early return real error codes
Currently they return -1 on error, which will confuse callers if they try to interpret it as a normal negative error code. Signed-off-by: Andy Lutomirski <luto@kernel.org> Signed-off-by: Darren Hart (VMware) <dvhart@infradead.org> Signed-off-by: Jean Delvare <jdelvare@suse.de>
This commit is contained in:

committed by
Jean Delvare

parent
c9aba14362
commit
c926820085
@@ -136,7 +136,7 @@ static inline int dmi_name_in_vendors(const char *s) { return 0; }
|
||||
static inline int dmi_name_in_serial(const char *s) { return 0; }
|
||||
#define dmi_available 0
|
||||
static inline int dmi_walk(void (*decode)(const struct dmi_header *, void *),
|
||||
void *private_data) { return -1; }
|
||||
void *private_data) { return -ENXIO; }
|
||||
static inline bool dmi_match(enum dmi_field f, const char *str)
|
||||
{ return false; }
|
||||
static inline void dmi_memdev_name(u16 handle, const char **bank,
|
||||
|
Reference in New Issue
Block a user