From patchwork Mon Oct 16 15:18:48 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bhumika Goyal X-Patchwork-Id: 10008727 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 6DBF4601D5 for ; Mon, 16 Oct 2017 15:23:16 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 5DD8128595 for ; Mon, 16 Oct 2017 15:23:16 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 527D8285DC; Mon, 16 Oct 2017 15:23:16 +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.5 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=unavailable 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 0A1C928595 for ; Mon, 16 Oct 2017 15:23:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754014AbdJPPWz (ORCPT ); Mon, 16 Oct 2017 11:22:55 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:49629 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753856AbdJPPTd (ORCPT ); Mon, 16 Oct 2017 11:19:33 -0400 Received: by mail-wm0-f65.google.com with SMTP id b189so4388253wmd.4; Mon, 16 Oct 2017 08:19:31 -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=vNbhovj+ZgchOjK9zepAXY42xEC4uAg1IujriqlgIYo=; b=l/dRlc3P5GwgNj7knLWoEmRqpk5Olt19K5bT6f8VfjwO3J/2Gx2b3XvtHii42cYHsp oZYRwSJqm5tm3QwIMm0hAw+4PvgnzoI3u4MdNEHWW7yZFg4ovZrtUQG+9BkmYLccKwjI WCv7pT0awpWTRpE0zAVCvdVY8BBJ0IZ4MEm/I6M34+OgOeW4hfIvD8vHr6I5YVsvbowj x3MoAxzfPVaDdxePhkwGtNfd2bWoRsVAfKHTNuPCGFydkMV0/vu8cMyeMkYJ26gsYQFy YHJuHDwlNzxT4xBghGTr2saZC7Hg2Kho0jtopCzno/X/0MC+78UJApwewM96Hqqg3255 u2UQ== 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=vNbhovj+ZgchOjK9zepAXY42xEC4uAg1IujriqlgIYo=; b=EB/FqHRUuYfsNVFM9JE79U6s6IQWPdqyneSgFaFh0GsWrCBVFLRK2cbIAlcDdCf6g5 5RSClC0MjhoNeI2RYRjWfk2Hi3X92AJlQXqH/SLzR3adw7PObzTgHc5v+EKKtklRjWtY y3XjCV0wcAKar29ZdxO9PFhZQqrlJT/M0RiVPVSvgw8FDbyxQd2EjASG96IHU3VrdWGk SG52t30CdftNmclHYJnge/4tKInU6+ZHLAHv+Lty+H2EcbwVygFsbGGvMOEF8LPReWAY YjgaFUKOgigDxpts/9GoanM3DpT6YGKEhFQDv0iLWkqc9PNdNJqPNzKiQtsSgJCHy08M 5UcA== X-Gm-Message-State: AMCzsaX9h2LeKJ87w+I0QTB7rcO3Z4+i+5bauLCDqIfRPfJhRlHtl9Y9 7Hqh9tTwRtFk4589RdA1CEM= X-Google-Smtp-Source: ABhQp+TUYq1m60Tkx8LcOwsxaKcRvhUy1Oz+pUIQ1CZ2AOdRcIxMklz0V/PWYTPQ5z121GeJzlWTOg== X-Received: by 10.223.197.17 with SMTP id q17mr906064wrf.270.1508167171130; Mon, 16 Oct 2017 08:19:31 -0700 (PDT) Received: from gmail.com (dell-goyal.wifi.rsr.lip6.fr. [132.227.77.190]) by smtp.gmail.com with ESMTPSA id f192sm3846750wmg.6.2017.10.16.08.19.28 (version=TLS1 cipher=AES128-SHA bits=128/128); Mon, 16 Oct 2017 08:19:30 -0700 (PDT) Received: by gmail.com (sSMTP sendmail emulation); Mon, 16 Oct 2017 17:19:29 +0200 From: Bhumika Goyal To: julia.lawall@lip6.fr, rjw@rjwysocki.net, lenb@kernel.org, alexander.shishkin@linux.intel.com, jic23@kernel.org, knaack.h@gmx.de, lars@metafoo.de, pmeerw@pmeerw.net, dledford@redhat.com, sean.hefty@intel.com, hal.rosenstock@gmail.com, hch@lst.de, sagi@grimberg.me, kishon@ti.com, bhelgaas@google.com, nab@linux-iscsi.org, balbi@kernel.org, gregkh@linuxfoundation.org, laurent.pinchart@ideasonboard.com, jlbec@evilplan.org, ccaulfie@redhat.com, teigland@redhat.com, mfasheh@versity.com, linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, linux-iio@vger.kernel.org, linux-rdma@vger.kernel.org, netdev@vger.kernel.org, linux-nvme@lists.infradead.org, linux-pci@vger.kernel.org, linux-scsi@vger.kernel.org, target-devel@vger.kernel.org, linux-usb@vger.kernel.org, cluster-devel@redhat.com, ocfs2-devel@oss.oracle.com, linux-fsdevel@vger.kernel.org Cc: Bhumika Goyal Subject: [PATCH v2 09/15] ACPI: configfs: make config_item_type const Date: Mon, 16 Oct 2017 17:18:48 +0200 Message-Id: <1508167134-6243-10-git-send-email-bhumirks@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1508167134-6243-1-git-send-email-bhumirks@gmail.com> References: <1508167134-6243-1-git-send-email-bhumirks@gmail.com> Sender: linux-scsi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-scsi@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Make these structures const as they are either passed to the functions having the argument as const or stored as a reference in the "ci_type" const field of a config_item structure. Done using Coccienlle. Signed-off-by: Bhumika Goyal Acked-by: Rafael J. Wysocki --- * Changes in v2- Combine all the followup patches and the constification patches into a series. drivers/acpi/acpi_configfs.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/acpi/acpi_configfs.c b/drivers/acpi/acpi_configfs.c index 853bc7f..b588503 100644 --- a/drivers/acpi/acpi_configfs.c +++ b/drivers/acpi/acpi_configfs.c @@ -204,7 +204,7 @@ struct configfs_attribute *acpi_table_attrs[] = { NULL, }; -static struct config_item_type acpi_table_type = { +static const struct config_item_type acpi_table_type = { .ct_owner = THIS_MODULE, .ct_bin_attrs = acpi_table_bin_attrs, .ct_attrs = acpi_table_attrs, @@ -237,12 +237,12 @@ struct configfs_group_operations acpi_table_group_ops = { .drop_item = acpi_table_drop_item, }; -static struct config_item_type acpi_tables_type = { +static const struct config_item_type acpi_tables_type = { .ct_owner = THIS_MODULE, .ct_group_ops = &acpi_table_group_ops, }; -static struct config_item_type acpi_root_group_type = { +static const struct config_item_type acpi_root_group_type = { .ct_owner = THIS_MODULE, };