mirror of
https://github.com/torvalds/linux.git
synced 2026-05-30 01:53:29 +02:00
platform/chrome: cros_ec_proto: remove redundant NULL check
send_command() already checks if `ec_dev->pkt_xfer` is NULL. Remove the redundant check. Reviewed-by: Guenter Roeck <groeck@chromium.org> Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org> Link: https://lore.kernel.org/r/20220609084957.3684698-6-tzungbi@kernel.org
This commit is contained in:
parent
e796c0c4b1
commit
8e3991610b
|
|
@ -281,9 +281,6 @@ static int cros_ec_host_command_proto_query(struct cros_ec_device *ec_dev,
|
|||
*/
|
||||
int ret;
|
||||
|
||||
if (!ec_dev->pkt_xfer)
|
||||
return -EPROTONOSUPPORT;
|
||||
|
||||
memset(msg, 0, sizeof(*msg));
|
||||
msg->command = EC_CMD_PASSTHRU_OFFSET(devidx) | EC_CMD_GET_PROTOCOL_INFO;
|
||||
msg->insize = sizeof(struct ec_response_get_protocol_info);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user