Patrick Georgi has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/31613 )
Change subject: ec/google/chromeec: Clarify return value of google_chromeec_command ......................................................................
ec/google/chromeec: Clarify return value of google_chromeec_command
This patch clarifies the definition of google_chromeec_command.
Currently absence of the definition isn't causing any problem because wrapper APIs check 'ret != 0' or wrapper APIs check 'ret < 0' for an interface which returns only negative error codes.
However, there is a chance that a new wrapper API will be addedl which check 'ret < 0' to catch errors, assuming other interfaces behave the same. Or existing wrapper APIs will be broken as soon as they're compiled for another interface.
BUG=chromium:935038 TEST=none
Signed-off-by: Daisuke Nojiri dnojiri@chromium.org Change-Id: I2ce7109b5f2a1d5294f167719730bc1f039ba03f Reviewed-on: https://review.coreboot.org/c/31613 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Julius Werner jwerner@chromium.org --- M src/ec/google/chromeec/ec.h 1 file changed, 6 insertions(+), 0 deletions(-)
Approvals: build bot (Jenkins): Verified Julius Werner: Looks good to me, approved
diff --git a/src/ec/google/chromeec/ec.h b/src/ec/google/chromeec/ec.h index 70b2b52..7a38336 100644 --- a/src/ec/google/chromeec/ec.h +++ b/src/ec/google/chromeec/ec.h @@ -155,6 +155,12 @@ int crosec_command_proto(struct chromeec_command *cec_command, crosec_io_t crosec_io, void *context);
+/** + * Send a command to a CrOS EC + * + * @param cec_command: CrOS EC command to send + * @return 0 for success. Non-zero for error. + */ int google_chromeec_command(struct chromeec_command *cec_command);
struct google_chromeec_event_info {