Message ID | 20230523122220.1610825-2-j.granados@samsung.com |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp2112990vqo; Tue, 23 May 2023 05:49:08 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7SvL+JjcaWd5MNNw3id3tverF64Kn5XIDHoVjoi7pCBmMDCqrlPagbbtYuiFOVlZF0lFNE X-Received: by 2002:a17:902:f547:b0:1ac:9890:1c49 with SMTP id h7-20020a170902f54700b001ac98901c49mr19686584plf.15.1684846148178; Tue, 23 May 2023 05:49:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684846148; cv=none; d=google.com; s=arc-20160816; b=Yf+Ts+nviikfHlt2mKiqNAHXMUzsBLzvQuR4t4SyXEkrLERu2ongbtthhsugOWR8pD nPGg4mhS1ikTdeEReCb4JO9zNXjIsoG1wnpBjJWshV3810cbp9wePAlcucPrHa2RjmAq YCwRzK+4Lbdh0NeJqt3eWPqokfBPJ714FxU6F0dUDtAT0qQcdAMwmK0WeEOHz2XJ4RY3 7VuutXBAoEF+BXJMIoQ8c+3InnUuA+YGIl5wLyLmUBWZce3pJjw4ZG2Fq5oE2IomfMHZ Xgn6A+xKtuFFkRAzjhIphLXa09yj8o6OkekSnqC34w3Dm29ehfLaUkrenIb6fEFbM8Rn DLyQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:cms-type:content-transfer-encoding :mime-version:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature:dkim-filter; bh=PSEJhzKvpVyR/pqvYhGYpQKS9kejgYF7JkoWjFXjyTo=; b=FnA2ACrk+KyfNrYCr0q4N1csAIDPJvjqQiZ91LQ4diw6RDmBFgHyx8NpObqSHz36MS sOHCyZ1SwRh1xM3TUpfLnn4yv8YONSAhnuzXoJivj+ofg8cyJy1b7PE5DQcFWcpMpjAC SO8y+tKFo4+CpnUG8fLeKCQ5P0bF+yqpF+ZIU6ZokaIrxyFU8njPV639HHNYKcZSK6j8 aPZPnKur4y/bHFfsk7RMrKEG9Oi8YhIgOZJll/vD95DtNFF8IWDZx5ukQLhEDHkr9IxQ yZOrbXT64Q2EYHg+aTtNdIw2QENJz35J7uxhsPoQTeMpa1niM2XxWK+ZrbxlhQdVnqE/ b1eg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b="TsVPzu/g"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q6-20020a17090311c600b001ac893fa8dasi6563441plh.144.2023.05.23.05.48.56; Tue, 23 May 2023 05:49:08 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@samsung.com header.s=mail20170921 header.b="TsVPzu/g"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=samsung.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236819AbjEWMWi (ORCPT <rfc822;ahmedalshaiji.dev@gmail.com> + 99 others); Tue, 23 May 2023 08:22:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50872 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236669AbjEWMWd (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 23 May 2023 08:22:33 -0400 Received: from mailout2.w1.samsung.com (mailout2.w1.samsung.com [210.118.77.12]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 42E53DB for <linux-kernel@vger.kernel.org>; Tue, 23 May 2023 05:22:29 -0700 (PDT) Received: from eucas1p2.samsung.com (unknown [182.198.249.207]) by mailout2.w1.samsung.com (KnoxPortal) with ESMTP id 20230523122226euoutp0284a16b53933e244fc2c3e9fc4cbd7f7c~hxTBO-6mm1935319353euoutp02G for <linux-kernel@vger.kernel.org>; Tue, 23 May 2023 12:22:26 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20230523122226euoutp0284a16b53933e244fc2c3e9fc4cbd7f7c~hxTBO-6mm1935319353euoutp02G DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1684844546; bh=PSEJhzKvpVyR/pqvYhGYpQKS9kejgYF7JkoWjFXjyTo=; h=From:To:CC:Subject:Date:In-Reply-To:References:From; b=TsVPzu/gdpuIbDymwA0yuai6EvAGTVxv9zZCeCtZlweKsNZDXQ5/lO9FJ9Cb58xJa vogW/6zQr8+W3wesETNS2BzT//jkj+zZJJYT0kamB1udzFSYiupuMcLkjkpIEOSiBt pWXzowuq+qvYIm8zQKDZzo3xe/cUHuP6zPyfdzvQ= Received: from eusmges2new.samsung.com (unknown [203.254.199.244]) by eucas1p1.samsung.com (KnoxPortal) with ESMTP id 20230523122226eucas1p1e18f5acfe5110c795265c93f5efcee4f~hxTA3Iiwz2731327313eucas1p14; Tue, 23 May 2023 12:22:26 +0000 (GMT) Received: from eucas1p1.samsung.com ( [182.198.249.206]) by eusmges2new.samsung.com (EUCPMTA) with SMTP id 13.16.11320.200BC646; Tue, 23 May 2023 13:22:26 +0100 (BST) Received: from eusmtrp2.samsung.com (unknown [182.198.249.139]) by eucas1p2.samsung.com (KnoxPortal) with ESMTPA id 20230523122226eucas1p2bc0a2c060f01f460a11e90545f9da9aa~hxTAhQ5iA2886828868eucas1p2C; Tue, 23 May 2023 12:22:26 +0000 (GMT) Received: from eusmgms2.samsung.com (unknown [182.198.249.180]) by eusmtrp2.samsung.com (KnoxPortal) with ESMTP id 20230523122226eusmtrp25d4fcc81b8357666bf232d27fc9b313a~hxTAgcCMZ0635006350eusmtrp2a; Tue, 23 May 2023 12:22:26 +0000 (GMT) X-AuditID: cbfec7f4-993ff70000022c38-7f-646cb0026184 Received: from eusmtip1.samsung.com ( [203.254.199.221]) by eusmgms2.samsung.com (EUCPMTA) with SMTP id 8F.71.14344.100BC646; Tue, 23 May 2023 13:22:26 +0100 (BST) Received: from CAMSVWEXC02.scsc.local (unknown [106.1.227.72]) by eusmtip1.samsung.com (KnoxPortal) with ESMTPA id 20230523122225eusmtip1067406525da12eb8ce270bbec5693002~hxTAU8pIc1745417454eusmtip10; Tue, 23 May 2023 12:22:25 +0000 (GMT) Received: from localhost (106.210.248.82) by CAMSVWEXC02.scsc.local (2002:6a01:e348::6a01:e348) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Tue, 23 May 2023 13:22:25 +0100 From: Joel Granados <j.granados@samsung.com> To: <mcgrof@kernel.org> CC: Christian Brauner <brauner@kernel.org>, Kees Cook <keescook@chromium.org>, Joel Granados <j.granados@samsung.com>, <linux-fsdevel@vger.kernel.org>, <linux-kernel@vger.kernel.org>, Iurii Zaikin <yzaikin@google.com>, Alexander Viro <viro@zeniv.linux.org.uk>, Sudip Mukherjee <sudipm.mukherjee@gmail.com> Subject: [PATCH v4 1/8] parport: Move magic number "15" to a define Date: Tue, 23 May 2023 14:22:13 +0200 Message-ID: <20230523122220.1610825-2-j.granados@samsung.com> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20230523122220.1610825-1-j.granados@samsung.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [106.210.248.82] X-ClientProxiedBy: CAMSVWEXC01.scsc.local (2002:6a01:e347::6a01:e347) To CAMSVWEXC02.scsc.local (2002:6a01:e348::6a01:e348) X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CYrRQVWliK9Oq R2wBVrKCB6wSZy6aa/yr6IfwRb3CiVm+657PPHpXvcywTYmlOCPRUIu5qDgRABQ9P3lYAwAA X-CMS-MailID: 20230523122226eucas1p2bc0a2c060f01f460a11e90545f9da9aa X-Msg-Generator: CA X-RootMTR: 20230523122226eucas1p2bc0a2c060f01f460a11e90545f9da9aa X-EPHeader: CA CMS-TYPE: 201P X-CMS-RootMailID: 20230523122226eucas1p2bc0a2c060f01f460a11e90545f9da9aa References: <20230523122220.1610825-1-j.granados@samsung.com> <CGME20230523122226eucas1p2bc0a2c060f01f460a11e90545f9da9aa@eucas1p2.samsung.com> X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766689235000669070?= X-GMAIL-MSGID: =?utf-8?q?1766689235000669070?= |
Series |
sysctl: Completely remove register_sysctl_table from sources
|
|
Commit Message
Joel Granados
May 23, 2023, 12:22 p.m. UTC
Put the size of a parport name behind a define so we can use it in other files. This is a preparation patch to be able to use this size in parport/procfs.c. Signed-off-by: Joel Granados <j.granados@samsung.com> Reviewed-by: Luis Chamberlain <mcgrof@kernel.org> Signed-off-by: Luis Chamberlain <mcgrof@kernel.org> --- drivers/parport/share.c | 2 +- include/linux/parport.h | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/parport/share.c b/drivers/parport/share.c index 62f8407923d4..2d46b1d4fd69 100644 --- a/drivers/parport/share.c +++ b/drivers/parport/share.c @@ -467,7 +467,7 @@ struct parport *parport_register_port(unsigned long base, int irq, int dma, atomic_set(&tmp->ref_count, 1); INIT_LIST_HEAD(&tmp->full_list); - name = kmalloc(15, GFP_KERNEL); + name = kmalloc(PARPORT_NAME_MAX_LEN, GFP_KERNEL); if (!name) { kfree(tmp); return NULL; diff --git a/include/linux/parport.h b/include/linux/parport.h index a0bc9e0267b7..243c82d7f852 100644 --- a/include/linux/parport.h +++ b/include/linux/parport.h @@ -180,6 +180,8 @@ struct ieee1284_info { struct semaphore irq; }; +#define PARPORT_NAME_MAX_LEN 15 + /* A parallel port */ struct parport { unsigned long base; /* base address */