From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id D0ABBC3A5A2 for ; Tue, 3 Sep 2019 08:02:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id AE73622CF8 for ; Tue, 3 Sep 2019 08:02:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727969AbfICICD (ORCPT ); Tue, 3 Sep 2019 04:02:03 -0400 Received: from szxga04-in.huawei.com ([45.249.212.190]:6186 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725888AbfICICD (ORCPT ); Tue, 3 Sep 2019 04:02:03 -0400 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id BB045C3910B109BDEAAD; Tue, 3 Sep 2019 16:02:00 +0800 (CST) Received: from [127.0.0.1] (10.177.29.68) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.439.0; Tue, 3 Sep 2019 16:01:55 +0800 Message-ID: <5D6E1DF2.1000109@huawei.com> Date: Tue, 3 Sep 2019 16:01:54 +0800 From: zhong jiang User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20120428 Thunderbird/12.0.1 MIME-Version: 1.0 To: zhong jiang CC: , , , , Subject: Re: [PATCH] hostap: remove set but not used variable 'copied' in prism2_io_debug_proc_read References: <1567497430-22539-1-git-send-email-zhongjiang@huawei.com> In-Reply-To: <1567497430-22539-1-git-send-email-zhongjiang@huawei.com> Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.177.29.68] X-CFilter-Loop: Reflected Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Please ignore the patch. Because the hostap_proc.c is marked as 'obsolete'. Thanks, zhong jiang On 2019/9/3 15:57, zhong jiang wrote: > Obviously, variable 'copied' is initialized to zero. But it is not used. > hence just remove it. > > Signed-off-by: zhong jiang > --- > drivers/net/wireless/intersil/hostap/hostap_proc.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/net/wireless/intersil/hostap/hostap_proc.c b/drivers/net/wireless/intersil/hostap/hostap_proc.c > index 703d74c..6151d8d 100644 > --- a/drivers/net/wireless/intersil/hostap/hostap_proc.c > +++ b/drivers/net/wireless/intersil/hostap/hostap_proc.c > @@ -234,7 +234,7 @@ static int prism2_io_debug_proc_read(char *page, char **start, off_t off, > { > local_info_t *local = (local_info_t *) data; > int head = local->io_debug_head; > - int start_bytes, left, copy, copied; > + int start_bytes, left, copy; > > if (off + count > PRISM2_IO_DEBUG_SIZE * 4) { > *eof = 1; > @@ -243,7 +243,6 @@ static int prism2_io_debug_proc_read(char *page, char **start, off_t off, > count = PRISM2_IO_DEBUG_SIZE * 4 - off; > } > > - copied = 0; > start_bytes = (PRISM2_IO_DEBUG_SIZE - head) * 4; > left = count; >