projects
/
platform
/
kernel
/
u-boot.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge tag 'v2021.01-rc5' into next
[platform/kernel/u-boot.git]
/
drivers
/
misc
/
cros_ec_sandbox.c
diff --git
a/drivers/misc/cros_ec_sandbox.c
b/drivers/misc/cros_ec_sandbox.c
index
9dd6a18
..
b3bb537
100644
(file)
--- a/
drivers/misc/cros_ec_sandbox.c
+++ b/
drivers/misc/cros_ec_sandbox.c
@@
-11,6
+11,7
@@
#include <ec_commands.h>
#include <errno.h>
#include <hash.h>
#include <ec_commands.h>
#include <errno.h>
#include <hash.h>
+#include <log.h>
#include <os.h>
#include <u-boot/sha256.h>
#include <spi.h>
#include <os.h>
#include <u-boot/sha256.h>
#include <spi.h>
@@
-459,6
+460,14
@@
static int process_cmd(struct ec_state *ec,
case EC_CMD_ENTERING_MODE:
len = 0;
break;
case EC_CMD_ENTERING_MODE:
len = 0;
break;
+ case EC_CMD_GET_NEXT_EVENT: {
+ struct ec_response_get_next_event *resp = resp_data;
+
+ resp->event_type = EC_MKBP_EVENT_KEY_MATRIX;
+ cros_ec_keyscan(ec, resp->data.key_matrix);
+ len = sizeof(*resp);
+ break;
+ }
default:
printf(" ** Unknown EC command %#02x\n", req_hdr->command);
return -1;
default:
printf(" ** Unknown EC command %#02x\n", req_hdr->command);
return -1;
@@
-571,11
+580,11
@@
static const struct udevice_id cros_ec_ids[] = {
{ }
};
{ }
};
-U_BOOT_DRIVER(cros_ec_sandbox) = {
- .name = "cros_ec_sandbox",
+U_BOOT_DRIVER(
google_
cros_ec_sandbox) = {
+ .name = "
google_
cros_ec_sandbox",
.id = UCLASS_CROS_EC,
.of_match = cros_ec_ids,
.probe = cros_ec_probe,
.id = UCLASS_CROS_EC,
.of_match = cros_ec_ids,
.probe = cros_ec_probe,
- .priv_auto
_alloc_size
= sizeof(struct ec_state),
+ .priv_auto
= sizeof(struct ec_state),
.ops = &cros_ec_ops,
};
.ops = &cros_ec_ops,
};