From patchwork Sat Aug 19 17:54:56 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9910601 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id E5E2C602C8 for ; Sat, 19 Aug 2017 17:55:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D8AA6285A9 for ; Sat, 19 Aug 2017 17:55:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id CD93D28BB1; Sat, 19 Aug 2017 17:55:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 86AB5285A9 for ; Sat, 19 Aug 2017 17:55:25 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752286AbdHSRzM (ORCPT ); Sat, 19 Aug 2017 13:55:12 -0400 Received: from mail-pg0-f65.google.com ([74.125.83.65]:32983 "EHLO mail-pg0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751697AbdHSRzJ (ORCPT ); Sat, 19 Aug 2017 13:55:09 -0400 Received: by mail-pg0-f65.google.com with SMTP id n4so3846034pgn.0; Sat, 19 Aug 2017 10:55:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=PmyP9MmitFRa9+puyaYcgDv81vwdnl8nRbTf85yoPSM=; b=ffzGjZmDB5kT+R6xzrD3zpQ6Pv2PQOy6mGfqZ32WzT1YAnib2LfMX3A9KCqaH0ha/W 7nDeWwR9lrlEbpDB9yPXZJgLn+7Gwolf9eEk2qJm1Ajalq6LHCR3UJACtBXOJ7lVNb3i dcjINDVFnQmkLq2VLNlNxv9VirgmGRRjzntZy0bwGT5BYZahjYCkJlS2ENX3Vd8hMKTP 2GNjpGT5Ke1LZKn7TXrASJDSJLDdrjAl5jcIygSuz4HliZQXF2gU92+hldlpgUwy1ozU d7y+obXdu5G6KUaWOfGAB72wn/vLyw6qXtm1D3Ns1cisK0Kn0cdT4Kwd97ktFDanwNTg zCCg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=PmyP9MmitFRa9+puyaYcgDv81vwdnl8nRbTf85yoPSM=; b=RaP/Cs1/3E+7yX/zN3YBoGO9tNjUc5LtpXWc+vvwqjNO7UQxNmcNrq2Ei93/3OwkZ+ ooNlEN6LihySAu1FgLYa2krdi82b0dG6fSiZQmD03dKBa0G2WrgTgoLsTMXEZGFjkkYF xKZ8dZC9qOc9QoBWuaQ7KqMIZDpBzk4d2MS6bKQgEIGj7EEdLAM2ps72SG8WX7Bpeqwy I0K5eDNnCyFDTbbX3TCXZunGdZ++qJynW21aBIbmL1LfWqgPBWKC9Vj3xtcnmwBG9H8l xwUbOzmZJ9rs/JG0HBk1N7In+Au7UrRPLSwXBVchYURdJKAnYv8Yfl1v+n8IjQ5H28xl yCtQ== X-Gm-Message-State: AHYfb5hsHuQgeQdiORfyRkZ8EM/7tdToyvVt6yy7wMpTxNXIm5rRchSh CFjSgDGzAHFN1g== X-Received: by 10.84.236.9 with SMTP id q9mr13569792plk.345.1503165309349; Sat, 19 Aug 2017 10:55:09 -0700 (PDT) Received: from localhost.localdomain ([103.16.68.146]) by smtp.gmail.com with ESMTPSA id w23sm15593701pfl.40.2017.08.19.10.55.06 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sat, 19 Aug 2017 10:55:08 -0700 (PDT) From: Arvind Yadav To: jejb@linux.vnet.ibm.com, martin.petersen@oracle.com, deller@gmx.de, gregkh@linuxfoundation.org, jslaby@suse.com Cc: linux-kernel@vger.kernel.org, linux-parisc@vger.kernel.org, linux-serial@vger.kernel.org Subject: [PATCH 4/4] tty: mux: constify parisc_device_id Date: Sat, 19 Aug 2017 23:24:56 +0530 Message-Id: <1503165296-31801-2-git-send-email-arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1503165296-31801-1-git-send-email-arvind.yadav.cs@gmail.com> References: <1503165296-31801-1-git-send-email-arvind.yadav.cs@gmail.com> Sender: linux-parisc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-parisc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP parisc_device_id are not supposed to change at runtime. All functions working with parisc_device_id provided by work with const parisc_device_id. So mark the non-const structs as const. Signed-off-by: Arvind Yadav --- drivers/tty/serial/mux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/tty/serial/mux.c b/drivers/tty/serial/mux.c index 8a4be4b..6afe83d 100644 --- a/drivers/tty/serial/mux.c +++ b/drivers/tty/serial/mux.c @@ -536,13 +536,13 @@ static int mux_remove(struct parisc_device *dev) * This table only contains the parisc_device_id of known builtin mux * devices. All other mux cards will be detected by the generic mux_tbl. */ -static struct parisc_device_id builtin_mux_tbl[] = { +static const struct parisc_device_id builtin_mux_tbl[] = { { HPHW_A_DIRECT, HVERSION_REV_ANY_ID, 0x15, 0x0000D }, /* All K-class */ { HPHW_A_DIRECT, HVERSION_REV_ANY_ID, 0x44, 0x0000D }, /* E35, E45, and E55 */ { 0, } }; -static struct parisc_device_id mux_tbl[] = { +static const struct parisc_device_id mux_tbl[] = { { HPHW_A_DIRECT, HVERSION_REV_ANY_ID, HVERSION_ANY_ID, 0x0000D }, { 0, } };