]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
platform/chrome: cros_ec_proto: drop unneeded BUG_ON() in prepare_packet()
authorTzung-Bi Shih <tzungbi@kernel.org>
Fri, 13 May 2022 04:41:37 +0000 (12:41 +0800)
committerTzung-Bi Shih <tzungbi@kernel.org>
Mon, 16 May 2022 02:01:51 +0000 (10:01 +0800)
prepare_packet() gets called if `ec_dev->proto_version` > 2.  For now, it
must be equivalent to EC_HOST_REQUEST_VERSION.

Drop the BUG_ON().

Reviewed-by: Guenter Roeck <groeck@chromium.org>
Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org>
Link: https://lore.kernel.org/r/20220513044143.1045728-2-tzungbi@kernel.org
drivers/platform/chrome/cros_ec_proto.c

index ac1419881ff358d705856db96378ca3e4a11a841..db1c8ba431715ae6bc71d764b813ef9d404b9157 100644 (file)
@@ -60,7 +60,6 @@ static int prepare_packet(struct cros_ec_device *ec_dev,
        int i;
        u8 csum = 0;
 
-       BUG_ON(ec_dev->proto_version != EC_HOST_REQUEST_VERSION);
        BUG_ON(msg->outsize + sizeof(*request) > ec_dev->dout_size);
 
        out = ec_dev->dout;