From patchwork Fri Aug 18 19:49:45 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ard Biesheuvel X-Patchwork-Id: 110436 Delivered-To: patch@linaro.org Received: by 10.140.95.78 with SMTP id h72csp1344036qge; Fri, 18 Aug 2017 12:50:38 -0700 (PDT) X-Received: by 10.98.68.155 with SMTP id m27mr5991515pfi.215.1503085838037; Fri, 18 Aug 2017 12:50:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1503085838; cv=none; d=google.com; s=arc-20160816; b=icJiNLmS6/MgbnJvSBcPhHPnWXIz7vv+TQQMIItLA8OLvrI4kl+ZxHWTTyVRNjheVt e6pD7qPl91GOU6IpSTZIBb/M59yu5BxgaO3vOD/iyUSJSsYIaGf+Ll+O4TI19K2Gbr1F 4M9q7hh890rhvP7e39QjIcnet4oLc2z7yn3PG0ITNNZE4xdLFDpyzlxFZgGBK3MscEbc 62WK6n/RHc8FxMUPFFi/zN73us9V3Qjmlb7RcTlTdP7d6CE/wJuORM/xZ7myQjfLWYyM 3blw5mKa8pybQqwCIXJ0yOhR/6DEFwAj47nVWMvfZKeG1XuqZd3FqEM+b/HLl0GDvDYK 00pw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=OKMtyUY89mMSWf6DmC7W0XVK+iW6P+jn9wyRegRXa/4=; b=ZIE8jpBjOeOrfcB2nI/DlzxlFsS+Eeu5LUyEllWp62HZENsYnynW9h4snNP7p/XUBI fDClpd8Z5SlDxIyQWkPJr8k855/Y86afhDQetS/FGT6+Iik24dnuYs5sN8QhEfqWPXsg 8rrm8IyX/dD730uiaEQwATQooRTyUBCmwPowdsudhQLk5fnYTlNe8qn0fXYuHoxIim4p AuNMQtzygeRVTVGSEgTXQBVk5YMmPGFp07YmCzr6B77L8z0UF+d9RewPp7BhymfFGG12 t0d0pQitpZjoF/efFX85975JsKlB5qyKHaMPd+XI8YRKkEkYZBX0zP/aXg1puflzTEdW Wl1g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hM/2Dko5; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q7si3971707pgr.186.2017.08.18.12.50.37; Fri, 18 Aug 2017 12:50:38 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=hM/2Dko5; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752628AbdHRTuf (ORCPT + 26 others); Fri, 18 Aug 2017 15:50:35 -0400 Received: from mail-wm0-f52.google.com ([74.125.82.52]:34020 "EHLO mail-wm0-f52.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752523AbdHRTuc (ORCPT ); Fri, 18 Aug 2017 15:50:32 -0400 Received: by mail-wm0-f52.google.com with SMTP id c14so2105121wmh.1 for ; Fri, 18 Aug 2017 12:50:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=OKMtyUY89mMSWf6DmC7W0XVK+iW6P+jn9wyRegRXa/4=; b=hM/2Dko5Pn/1jaXvD1x+E/MTihdGwugKsRivizkTFmHJjrwsJduG9wwGewzIXUGdn2 sx1tySjxU3jrizZKa/rJtzWSK2qi2a+xEULHj6/1g8eVIpVgZ04uxfujQNQKjV6zgJLP Azv21Xp0qZ4kKwFa37PPCh1X7pJWJ4ud1ltvo= 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=OKMtyUY89mMSWf6DmC7W0XVK+iW6P+jn9wyRegRXa/4=; b=jjuOu3M7520qUKkfhfVLrXv1xL8ithX808JU5VMn7iQkYwgD5lHRdnKg77l1zBVGyv V5PrVLdaUVI81Zz5bPt5YFbI6CxMk3cZxFMuSTn3s7ZAvVm6wiO7do/ZbuKlOmCamkmu 6UFRDe0s5PSudg0oOYZ7cv/3ikDxihza35qdnkX5JM4HpbQsZkXmIEwklvzW1+Cn6/ef ABgjG772vVHwCmFuq8A9Eze9NIvijG7CkxRWY69UfcddBstr5InMep5WB7e4AsoXH7fn RQ6cUZ0Efcza4sUp+wutiP5a+K3U2Bfd89rGPtZF5TPb13MbjgSeogaN0Fqev+H6sRer fCNw== X-Gm-Message-State: AHYfb5ggfbVdJd5K2gTqnhpHHv7CCRuBVjg1kgwW+EfCvaRzCKUZl8l+ HH6sAS/6Wm9h+k/H X-Received: by 10.28.35.77 with SMTP id j74mr2298257wmj.168.1503085831076; Fri, 18 Aug 2017 12:50:31 -0700 (PDT) Received: from localhost.localdomain ([154.146.161.128]) by smtp.gmail.com with ESMTPSA id k29sm5571168wrk.56.2017.08.18.12.50.28 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 18 Aug 2017 12:50:30 -0700 (PDT) From: Ard Biesheuvel To: linux-efi@vger.kernel.org, Ingo Molnar , Thomas Gleixner , "H . Peter Anvin" Cc: Arvind Yadav , Ard Biesheuvel , linux-kernel@vger.kernel.org, Matt Fleming , Douglas_Warzecha Subject: [PATCH 12/14] firmware: dcdbas: constify attribute_group structures. Date: Fri, 18 Aug 2017 20:49:45 +0100 Message-Id: <20170818194947.19347-13-ard.biesheuvel@linaro.org> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170818194947.19347-1-ard.biesheuvel@linaro.org> References: <20170818194947.19347-1-ard.biesheuvel@linaro.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Arvind Yadav 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 Cc: Matt Fleming Cc: Douglas_Warzecha Signed-off-by: Ard Biesheuvel --- drivers/firmware/dcdbas.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- 2.11.0 diff --git a/drivers/firmware/dcdbas.c b/drivers/firmware/dcdbas.c index 2fe1a130189f..c16600f30611 100644 --- a/drivers/firmware/dcdbas.c +++ b/drivers/firmware/dcdbas.c @@ -534,7 +534,7 @@ static struct attribute *dcdbas_dev_attrs[] = { NULL }; -static struct attribute_group dcdbas_attr_group = { +static const struct attribute_group dcdbas_attr_group = { .attrs = dcdbas_dev_attrs, .bin_attrs = dcdbas_bin_attrs, };