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 8D960C433F5 for ; Mon, 16 May 2022 14:26:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244223AbiEPO0q (ORCPT ); Mon, 16 May 2022 10:26:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36744 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S244540AbiEPO0d (ORCPT ); Mon, 16 May 2022 10:26:33 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 53CFA22B36 for ; Mon, 16 May 2022 07:26:32 -0700 (PDT) Received: from canpemm500005.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4L21jz0Q6QzgYJ3; Mon, 16 May 2022 22:25:11 +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; Mon, 16 May 2022 22:26:30 +0800 Message-ID: <147d2f77-43db-40b7-aa36-a06d558f1813@huawei.com> Date: Mon, 16 May 2022 22:26:29 +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 v2] vt: defkeymap.c_shipped remove unused variables To: Jiri Slaby , CC: References: <20220513015427.569539-1-chris.zjh@huawei.com> <49a7602f-dd79-cac3-e6e0-83c4c41fcd53@kernel.org> From: "zhangjianhua (E)" In-Reply-To: <49a7602f-dd79-cac3-e6e0-83c4c41fcd53@kernel.org> Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.67.110.73] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) 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/5/16 15:00, Jiri Slaby 写道: > On 13. 05. 22, 3:54, Zhang Jianhua wrote: >> The global variables 'funcbufptr' 'funcbufsize' and 'funcbufleft' have >> been initialized but not used, they are redundant and remove them. >> >> Signed-off-by: Zhang Jianhua >> >> --- >> No code changes since v1, only remove the redundant line "--------" in >> v1 commit message. >> --- >>   drivers/tty/vt/defkeymap.c_shipped | 4 ---- > > The file header says: > /* Do not edit this file! It was automatically generated by   */ > /*    loadkeys --mktable defkeymap.map > defkeymap.c */ > > So I'm not sure anyone wants to touch it. This notes will be copied to the file defkeymap.c completely which is automatically generated, so it says to defkeymap.c rather than defkeymap.map > >> --- 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, > >