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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7D2F3C433F5 for ; Thu, 5 May 2022 03:11:04 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S240581AbiEEDOk (ORCPT ); Wed, 4 May 2022 23:14:40 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44362 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232469AbiEEDOg (ORCPT ); Wed, 4 May 2022 23:14:36 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 10F5720F66 for ; Wed, 4 May 2022 20:10:58 -0700 (PDT) Received: from canpemm500005.china.huawei.com (unknown [172.30.72.57]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4KtzCw6sFkzGpXb; Thu, 5 May 2022 11:08:12 +0800 (CST) Received: from [10.67.110.73] (10.67.110.73) by canpemm500005.china.huawei.com (7.192.104.229) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Thu, 5 May 2022 11:10:56 +0800 Message-ID: <53e36000-ad70-9de7-74ad-16bd81dae530@huawei.com> Date: Thu, 5 May 2022 11:10:55 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.1.0 Subject: Re: [PATCH -next] vt: defkeymap.c_shipped remove unused variables To: Greg KH CC: , References: <20220429014814.988829-1-chris.zjh@huawei.com> From: "zhangjianhua (E)" In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.67.110.73] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To canpemm500005.china.huawei.com (7.192.104.229) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 在 2022/4/29 14:39, Greg KH 写道: > On Fri, Apr 29, 2022 at 09:48:14AM +0800, Zhang Jianhua wrote: >> The global variables 'funcbufptr' 'funcbufsize' and 'funcbufleft' have >> been initialized but not used, they are redundant and remove them. >> >> -------- > Why this extra "------" line? This line "------" means the end of commit message, if it is redundant, I will remove it in next version. >> Signed-off-by: Zhang Jianhua >> --- >> drivers/tty/vt/defkeymap.c_shipped | 4 ---- >> 1 file changed, 4 deletions(-) >> >> diff --git a/drivers/tty/vt/defkeymap.c_shipped b/drivers/tty/vt/defkeymap.c_shipped >> index 094d95bf0005..80dee50bcb7a 100644 >> --- a/drivers/tty/vt/defkeymap.c_shipped >> +++ b/drivers/tty/vt/defkeymap.c_shipped >> @@ -185,10 +185,6 @@ char func_buf[] = { >> '\033', '[', 'P', 0, >> }; >> >> -char *funcbufptr = func_buf; >> -int funcbufsize = sizeof(func_buf); >> -int funcbufleft = 0; /* space left */ >> - >> char *func_table[MAX_NR_FUNC] = { >> func_buf + 0, >> func_buf + 5, >> -- >> 2.31.0 >> > Shouldn't you fix up the loadkeys tool instead? As the top of this file > says, it is auto-generated and is not something to be hand-edited at > all. > > thanks, > > greg k-h > . Thanks, I will read the source code more carefully, and fix up the loadkeys tool if it is indeed a problem.