Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp826044ybv; Thu, 20 Feb 2020 08:00:10 -0800 (PST) X-Google-Smtp-Source: APXvYqwTW7DCLG6sGYGiBJgckcwgh1MJjjUjLYBygnA5iQ1bt9dxe3LPMib7/PdWX6lQf0+AWGoh X-Received: by 2002:aca:c7ca:: with SMTP id x193mr2569987oif.70.1582214409983; Thu, 20 Feb 2020 08:00:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582214409; cv=none; d=google.com; s=arc-20160816; b=mDZe+sxiLHGMXMqJeU70NUmqXrrI/mmUVLYHd8CBSdP8fdaJkD1fybhShEXmpVd+Ph YHbWz7pCFxyrI/1tBXDxZ1r7dv5rorpjG9yrbTv9C8ylNw9HXXp+mICBUrKG9TLgoenf 8HDL3dGgRT9zPdc/ioKY0bst1QQ+hi3/aoI1k9nkAbA/POvN582N/y8QPzoxXqZx3Adj FLOdTCLXqYle7g0h+Nv89iozmeUSQcfTwRw0ncxd14+HN0ZgvSp6t7huCMx8EWCBVf18 jY0KvbVUMrhrk16PatiB6u4erWprKwxGbMbVEXgxzsTJINUXD5FsHKK+bLQ8EbM+bW1w aggA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=VjTJ/CqTwz9ly0k8ataxXtWtP0f+UaLPTurbKPw5QT4=; b=j56ZjAdUJGYqFSy3/P9Ffyp9stg8m7z9O7qAIcxjML6sN6otcE08IPwiQePr2Q8dvQ 0CvOfKvR2KA4dvaNQz2CFHGafxfQRwrBDcdccasONQKvmIL1IJOMD4ewk5EWDnTKbKwm nilUptkUbf7GZPso8uWED7QozdlgHZibfvBMyqD9/cGAbv1W5/s3hjrmcEWPHhCIlK5E UUTCh/FcVDwIeKlKeq6/o7/0cmtOLNFiuc9+BQ4/zRLIWM40Aa9foCzHovZaj6DmaJx0 9IQVMLb3Esi16HwSFPJ0SqVbq+Ef+2ZICyykMtL0EnG2aryteU9TuvHCLfou+oHBex3D fMBQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d20si1928947otq.157.2020.02.20.07.59.57; Thu, 20 Feb 2020 08:00:09 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728698AbgBTP7X (ORCPT + 99 others); Thu, 20 Feb 2020 10:59:23 -0500 Received: from bhuna.collabora.co.uk ([46.235.227.227]:47606 "EHLO bhuna.collabora.co.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728585AbgBTP7V (ORCPT ); Thu, 20 Feb 2020 10:59:21 -0500 Received: from [127.0.0.1] (localhost [127.0.0.1]) (Authenticated sender: eballetbo) with ESMTPSA id 37C272951A9 From: Enric Balletbo i Serra To: linux-kernel@vger.kernel.org Cc: Collabora Kernel ML , groeck@chromium.org, bleung@chromium.org, dtor@chromium.org, gwendal@chromium.org, pmalani@chromium.org Subject: [PATCH 3/8] platform/chrome: cros_ec_vbc: Use cros_ec_cmd_xfer_status helper Date: Thu, 20 Feb 2020 16:58:54 +0100 Message-Id: <20200220155859.906647-4-enric.balletbo@collabora.com> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200220155859.906647-1-enric.balletbo@collabora.com> References: <20200220155859.906647-1-enric.balletbo@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org This patch makes use of cros_ec_cmd_xfer_status() instead of cros_ec_cmd_xfer(). In this case the change is trivial and the only reason to do it is because we want to make cros_ec_cmd_xfer() a private function for the EC protocol and let people only use the cros_ec_cmd_xfer_status() to return Linux standard error codes. Signed-off-by: Enric Balletbo i Serra --- drivers/platform/chrome/cros_ec_vbc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/platform/chrome/cros_ec_vbc.c b/drivers/platform/chrome/cros_ec_vbc.c index 8edae465105c..46482d12cffe 100644 --- a/drivers/platform/chrome/cros_ec_vbc.c +++ b/drivers/platform/chrome/cros_ec_vbc.c @@ -40,7 +40,7 @@ static ssize_t vboot_context_read(struct file *filp, struct kobject *kobj, msg->outsize = para_sz; msg->insize = resp_sz; - err = cros_ec_cmd_xfer(ecdev, msg); + err = cros_ec_cmd_xfer_status(ecdev, msg); if (err < 0) { dev_err(dev, "Error sending read request: %d\n", err); kfree(msg); @@ -83,7 +83,7 @@ static ssize_t vboot_context_write(struct file *filp, struct kobject *kobj, msg->outsize = para_sz; msg->insize = 0; - err = cros_ec_cmd_xfer(ecdev, msg); + err = cros_ec_cmd_xfer_status(ecdev, msg); if (err < 0) { dev_err(dev, "Error sending write request: %d\n", err); kfree(msg); -- 2.25.0