Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp2953774pxk; Mon, 21 Sep 2020 01:06:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyeiE1gC4KywsNkLTSO1sp5zBFAGRF7XvDvuA7QfLKZKWhb733EMwR4nrF+SNnq/Eq3GTZa X-Received: by 2002:a05:6402:1558:: with SMTP id p24mr49738067edx.194.1600675587888; Mon, 21 Sep 2020 01:06:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600675587; cv=none; d=google.com; s=arc-20160816; b=Sy/VocGosjJFF8JNVF6L1DqNmIAl9U8C5w2cz8NGibg+gqzib5kVCr0iWI/lhs0mvl lBjBtH2CpBhIlzSt1dNMfLzf7VE7Sk100UAN+jEK/iC/k6vJ1j9pXbiHQHj2vldDbIdZ aqET11IBHtJttdsFmROsobEbGkDd83evkvQV2nCsHh9IzEt3IVTCirmIFFuyPsv0lTaR L6YHsRQo5anoE1Q7WuDOUC9Glc8Tj3ofPmfnN7DGlLJJNMbTabdFkc/ImmSN0/UDwwOs CPbB5JNCcIIjGPkdUj+Icb0XqHYEa6GuIcwrOH8FH1TlL0TeVaj1gcJTyTTG2Hvh4XOc 3ihg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=MebyFtMuwgNfo4kYe6XJCaLkUtkRspebwg8yngiciQs=; b=Dc9xffzZtKe1sxI/kiL4rX1SXGNd4FNebXDZsPkwcBWKqU10A817CNN/jtwFxj4Zb7 5c53k+mWlrXwJ/vxD1LdcAzLUKdGCa+NqlRi8hYRVQR8sQtweoYiG/k7ge1bPGV+1dmg 2rsfCzv8hAqaWMyE5/J206BMXqyBY1sQ620DQMPMM/aO93RBXK03ApBXwx3zTM1ENpli QdpbTuwYTxv9Q/wiVMzglBNqk9rMxt29Y2y9DEX6WGiboMbub+HkE6Svwd+aZzf4ZuSa 4rhoVVk5uLbRi7jzkO46n+HROilw4B8gpbHX1z0zYalaqETwmBkuAV/TJu6j+7B3jCID gJZw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id oq7si8765186ejb.650.2020.09.21.01.06.05; Mon, 21 Sep 2020 01:06:27 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726774AbgIUID7 (ORCPT + 99 others); Mon, 21 Sep 2020 04:03:59 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:35140 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726566AbgIUICT (ORCPT ); Mon, 21 Sep 2020 04:02:19 -0400 Received: from DGGEMS413-HUB.china.huawei.com (unknown [172.30.72.59]) by Forcepoint Email with ESMTP id 24E51D5E5C3142B64F1A; Mon, 21 Sep 2020 16:02:17 +0800 (CST) Received: from huawei.com (10.175.113.32) by DGGEMS413-HUB.china.huawei.com (10.3.19.213) with Microsoft SMTP Server id 14.3.487.0; Mon, 21 Sep 2020 16:02:10 +0800 From: Liu Shixin To: Srinivas Pandruvada , Jiri Kosina , Benjamin Tissoires CC: , , Liu Shixin Subject: [PATCH -next] HID: intel-ish-hid: simplify the return expression of ishtp_hid_parse Date: Mon, 21 Sep 2020 16:24:34 +0800 Message-ID: <20200921082434.2591357-1-liushixin2@huawei.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.113.32] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Simplify the return expression. Signed-off-by: Liu Shixin --- 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