From patchwork Fri Aug 4 05:03:30 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arvind Yadav X-Patchwork-Id: 9880457 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 7AD35603B4 for ; Fri, 4 Aug 2017 05:04:18 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7128528761 for ; Fri, 4 Aug 2017 05:04:18 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 664282882D; Fri, 4 Aug 2017 05:04:18 +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=-4.1 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_MED, T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 0975D28761 for ; Fri, 4 Aug 2017 05:04:17 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 27DA06E334; Fri, 4 Aug 2017 05:04:17 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mail-pf0-x242.google.com (mail-pf0-x242.google.com [IPv6:2607:f8b0:400e:c00::242]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4EC9A6E334; Fri, 4 Aug 2017 05:04:16 +0000 (UTC) Received: by mail-pf0-x242.google.com with SMTP id t83so778039pfj.3; Thu, 03 Aug 2017 22:04:16 -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=8qS5Kpzf6klPrB4OfuuK1OoAKvZ98SK/JtRBrNrHDeQ=; b=rcne6WEu+cv0A7kPJYJ/NcLAqiRhR994h/+f1HKQ6EE1M2IaGf7etXALinNwyZTJpH dzC1tfR8JQJBIn9NH76nKTOXagKJI4inniOkPgbEY+WkdCtEwkyjQuctGU8ctvJKpfJ9 CIPo9x4gkqG+ftF2k4bTAuGDYKLobM7HJ/AQS3v2IrnAoDTiilX+frX5eox9f5oJ/lc3 PDDhVzsrpJPFnnkoVwYJkLymFhqy/0VwVwhLUsKqYKQmr4Dre/p7CBqh3IZjk/mpF/L/ jw4O6etp0Erb6DE88ZmDFUcaVO0GZ8e4jMlV2SoYUXwCR5xpJyrfWZzwEv8KnHo2qSXL 24sA== 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=8qS5Kpzf6klPrB4OfuuK1OoAKvZ98SK/JtRBrNrHDeQ=; b=Xi+Qqwzlk+qxuKn6ygiFrFL/XLzNJxuLDsDTGPTp5g9Ta2WcdqqHTILpMdtOc7KHkl jXWyjpkFrmWcd9kqMyoIcCY23aqDfbEbL62DK/2FDCXHsIHWfIxPYCLm9p74aVTb/F2A ZxBdaZbslkBEiUc9K1EifjriFyABeLabdc5qkPrAMF+1MJj5U6MhwUJDc/E1uZ8TsnUc GtUCEUr3sDInp2Z/5fdIYRvBnk/XTgycB2LfoKKMoOunW3qYxliTSrnBNABJJWSHxBFl hEAY4dd0s6mS5rDgoYAmFHB8LSKq9xzO37UBpofCMBtMzLYmLs12H1mM6tiziG8GEcHV ryvw== X-Gm-Message-State: AIVw1139CHiOQrbOEvHIT9o0q+ZbHb6TvCmYP08aZYN+SxHNZQELGw8S ieYGb1i0hpvPYA== X-Received: by 10.84.205.70 with SMTP id o6mr1303651plh.51.1501823055941; Thu, 03 Aug 2017 22:04:15 -0700 (PDT) Received: from symbol-HP-Z420-Workstation.zebra.lan ([223.31.70.102]) by smtp.googlemail.com with ESMTPSA id y22sm925977pfi.159.2017.08.03.22.04.13 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 03 Aug 2017 22:04:15 -0700 (PDT) From: Arvind Yadav To: daniel.vetter@intel.com, jani.nikula@linux.intel.com, airlied@linux.ie Date: Fri, 4 Aug 2017 10:33:30 +0530 Message-Id: <1501823016-6779-6-git-send-email-arvind.yadav.cs@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1501823016-6779-1-git-send-email-arvind.yadav.cs@gmail.com> References: <1501823016-6779-1-git-send-email-arvind.yadav.cs@gmail.com> Cc: intel-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [Intel-gfx] [PATCH 05/11] drm: i915: i915_oa_glk: constify attribute_group structures. X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP attribute_group are not supposed to change at runtime. All functions working with attribute_group provided by work with const attribute_group. So mark the non-const structs as const. Signed-off-by: Arvind Yadav --- drivers/gpu/drm/i915/i915_oa_glk.c | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/drivers/gpu/drm/i915/i915_oa_glk.c b/drivers/gpu/drm/i915/i915_oa_glk.c index 2f356d5..a8eea3a 100644 --- a/drivers/gpu/drm/i915/i915_oa_glk.c +++ b/drivers/gpu/drm/i915/i915_oa_glk.c @@ -2119,7 +2119,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_render_basic = { +static const struct attribute_group group_render_basic = { .name = "d72df5c7-5b4a-4274-a43f-00b0fd51fc68", .attrs = attrs_render_basic, }; @@ -2141,7 +2141,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_compute_basic = { +static const struct attribute_group group_compute_basic = { .name = "814285f6-354d-41d2-ba49-e24e622714a0", .attrs = attrs_compute_basic, }; @@ -2163,7 +2163,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_render_pipe_profile = { +static const struct attribute_group group_render_pipe_profile = { .name = "07d397a6-b3e6-49f6-9433-a4f293d55978", .attrs = attrs_render_pipe_profile, }; @@ -2185,7 +2185,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_memory_reads = { +static const struct attribute_group group_memory_reads = { .name = "1a356946-5428-450b-a2f0-89f8783a302d", .attrs = attrs_memory_reads, }; @@ -2207,7 +2207,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_memory_writes = { +static const struct attribute_group group_memory_writes = { .name = "5299be9d-7a61-4c99-9f81-f87e6c5aaca9", .attrs = attrs_memory_writes, }; @@ -2229,7 +2229,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_compute_extended = { +static const struct attribute_group group_compute_extended = { .name = "bc9bcff2-459a-4cbc-986d-a84b077153f3", .attrs = attrs_compute_extended, }; @@ -2251,7 +2251,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_compute_l3_cache = { +static const struct attribute_group group_compute_l3_cache = { .name = "88ec931f-5b4a-453a-9db6-a61232b6143d", .attrs = attrs_compute_l3_cache, }; @@ -2273,7 +2273,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_hdc_and_sf = { +static const struct attribute_group group_hdc_and_sf = { .name = "530d176d-2a18-4014-adf8-1500c6c60835", .attrs = attrs_hdc_and_sf, }; @@ -2295,7 +2295,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_l3_1 = { +static const struct attribute_group group_l3_1 = { .name = "fdee5a5a-f23c-43d1-aa73-f6257c71671d", .attrs = attrs_l3_1, }; @@ -2317,7 +2317,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_rasterizer_and_pixel_backend = { +static const struct attribute_group group_rasterizer_and_pixel_backend = { .name = "6617623e-ca73-4791-b2b7-ddedd0846a0c", .attrs = attrs_rasterizer_and_pixel_backend, }; @@ -2339,7 +2339,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_sampler = { +static const struct attribute_group group_sampler = { .name = "f3b2ea63-e82e-4234-b418-44dd20dd34d0", .attrs = attrs_sampler, }; @@ -2361,7 +2361,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_tdl_1 = { +static const struct attribute_group group_tdl_1 = { .name = "14411d35-cbf6-4f5e-b68b-190faf9a1a83", .attrs = attrs_tdl_1, }; @@ -2383,7 +2383,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_tdl_2 = { +static const struct attribute_group group_tdl_2 = { .name = "ffa3f263-0478-4724-8c9f-c911c5ec0f1d", .attrs = attrs_tdl_2, }; @@ -2405,7 +2405,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_compute_extra = { +static const struct attribute_group group_compute_extra = { .name = "15274c82-27d2-4819-876a-7cb1a2c59ba4", .attrs = attrs_compute_extra, }; @@ -2427,7 +2427,7 @@ int i915_oa_select_metric_set_glk(struct drm_i915_private *dev_priv) NULL, }; -static struct attribute_group group_test_oa = { +static const struct attribute_group group_test_oa = { .name = "dd3fd789-e783-4204-8cd0-b671bbccb0cf", .attrs = attrs_test_oa, };