From: Liu Shixin <liushixin2@huawei.com>
To: Srinivas Pandruvada <srinivas.pandruvada@linux.intel.com>,
Jiri Kosina <jikos@kernel.org>,
Benjamin Tissoires <benjamin.tissoires@redhat.com>
Cc: <linux-input@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
Liu Shixin <liushixin2@huawei.com>
Subject: [PATCH -next] HID: intel-ish-hid: simplify the return expression of ishtp_hid_parse
Date: Mon, 21 Sep 2020 16:24:34 +0800 [thread overview]
Message-ID: <20200921082434.2591357-1-liushixin2@huawei.com> (raw)
Simplify the return expression.
Signed-off-by: Liu Shixin <liushixin2@huawei.com>
---
drivers/hid/intel-ish-hid/ishtp-hid.c | 9 ++-------
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/drivers/hid/intel-ish-hid/ishtp-hid.c b/drivers/hid/intel-ish-hid/ishtp-hid.c
index b8aae69ad15d..edf5ae942508 100644
--- a/drivers/hid/intel-ish-hid/ishtp-hid.c
+++ b/drivers/hid/intel-ish-hid/ishtp-hid.c
@@ -22,14 +22,9 @@ static int ishtp_hid_parse(struct hid_device *hid)
{
struct ishtp_hid_data *hid_data = hid->driver_data;
struct ishtp_cl_data *client_data = hid_data->client_data;
- int rv;
-
- rv = hid_parse_report(hid, client_data->report_descr[hid_data->index],
- client_data->report_descr_size[hid_data->index]);
- if (rv)
- return rv;
- return 0;
+ return hid_parse_report(hid, client_data->report_descr[hid_data->index],
+ client_data->report_descr_size[hid_data->index]);
}
/* Empty callbacks with success return code */
--
2.25.1
reply other threads:[~2020-09-21 8:04 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200921082434.2591357-1-liushixin2@huawei.com \
--to=liushixin2@huawei.com \
--cc=benjamin.tissoires@redhat.com \
--cc=jikos@kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=srinivas.pandruvada@linux.intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).