Message ID | 20240704-mfd-const-regmap_config-v2-12-0c8785b1331d@gmail.com (mailing list archive) |
---|---|
State | New |
Headers | show
Received: from mail-wm1-f45.google.com (mail-wm1-f45.google.com [209.85.128.45]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5DDA913F45B for <imx@lists.linux.dev>; Thu, 4 Jul 2024 17:23:49 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.128.45 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720113831; cv=none; b=MFSa4nBy4t+cRFfLF0vEq94JkqBdDBjBPi7MOliZNg6qJQue1bZtIcDz1WbsrPYLi1A4k/sei+gG5VmuuKoHByVXn/ApP7Q+GHrEbS075qLA5Wa0oVsbZiLpMHkT2NtCwreQd6I+r9EpEpPhgPv5l2xGqwznKVcXsXopuA/bCy0= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1720113831; c=relaxed/simple; bh=6atl/DrZQUwmw6JNwTSf7L3f3VWfEvhmC/OA+w6bvAo=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=lZ0T9bnkCAKSUyOH+k7h+puf0cseNfH2PYoyzSZDNvZOuxcsyGuZHoWDRe9Cg1QAaYvh6JlYbpH/KAXfaKTrIqlZvpDTTjLETjkUGDjQ/IjLy92D6Y3+PwyklCxEQ4Cn09UX2O1G9B5QTdohGXPlplwEm1eM1BQ5B1KsKRsiIKU= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=IrUeDxkC; arc=none smtp.client-ip=209.85.128.45 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="IrUeDxkC" Received: by mail-wm1-f45.google.com with SMTP id 5b1f17b1804b1-4256742f67fso5711195e9.3 for <imx@lists.linux.dev>; Thu, 04 Jul 2024 10:23:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1720113828; x=1720718628; darn=lists.linux.dev; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=F7zE6lHigua1P8ymODDtiJ+ZtxaVQFbo+ktZc42qUis=; b=IrUeDxkCAAy0D6jDn3URp9EuqyPeDiGiac/7Dp3ezsJOfj2To+ZCBEsc2LFNhSHja+ lPNlSGiCgE7SJEkNUIfAyC75wZdHB8uwXjUoiUcP0tTPC+98vFS9zAz1LlSBpusfMA6k lxsHDcDVEIQ/UWzYgHupK3I2V0RPHIcoi3fevs/IYqsG4Ax/k9yKJoSLQxAvZUaLTlia WpYoh+0HLT/Hdfy843V5Tvuuiw9T5LCL86aLexCqV/GPkqXO7ad8zY/hCJ21XRvI3vZA XgmFkDM4tBcwXeKGNE+EjFJpqt5oPmoMvSuybV0NWPTsWblmGkZ66zNXhCyz5dq2fBh3 S95A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720113828; x=1720718628; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=F7zE6lHigua1P8ymODDtiJ+ZtxaVQFbo+ktZc42qUis=; b=EsQNm2WbFdIec/OKhpeW/SMaI86GM5DmfK6EBBLi0munLlQ9FSbLYMsc4pIwx43qnR lYN7iOiV6h41dAtyZYSVuNEe/algbjFJy4D34h/eo4picdcnlrAASnE4H1pe7a5WrrdU tJt6vK9oCKzD7oQdNFbm6N4eHe6uJQ4Fdn9hjSIaj/QL4vJyz6u3Ipw4Q7X5oxDOXriY Uom2NzFh9LGFVkvVyzWHTt8RjBclD0pYRJ+wd7fLsS7DFlpcOlvzaxbI2fvCR79R9czt QXSeqIXxYTVm+ybMf3SpIvOaRuVlQNfDJuF28OGWUA9tafV0WjqcW4PFaOy9xZcRqXZe tOaA== X-Forwarded-Encrypted: i=1; AJvYcCW5s+Hn+zkYZfPeilmeM8fxox9JjWtA3kr2AdBMI+YPkcUvO81iHdZuGwCQ9twRTE5f/harKGu/xGzZYcoyTBkjBH/Q X-Gm-Message-State: AOJu0YxYl22IUX7ghMgq7NuHFnn2KogZBLi3sZ64W4UOcqQBJlNnm/O2 beoSNBuXibDgc11PPFwrXqRKBciQnUWJQKEOcRtRMLkNBuJsFmFp X-Google-Smtp-Source: AGHT+IEV2TScoV5U0gk+JCSE/6TuIOT7gDP7434MPboQsznm8o/auvcGlGGFMv7zURZ24WPzEpCGAg== X-Received: by 2002:a05:600c:4f11:b0:424:ac13:ee3c with SMTP id 5b1f17b1804b1-4264a3e162emr16522515e9.21.1720113827768; Thu, 04 Jul 2024 10:23:47 -0700 (PDT) Received: from [127.0.1.1] (84-115-213-37.cable.dynamic.surfer.at. [84.115.213.37]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-4264a1d6133sm32330965e9.13.2024.07.04.10.23.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 04 Jul 2024 10:23:47 -0700 (PDT) From: Javier Carrasco <javier.carrasco.cruz@gmail.com> Date: Thu, 04 Jul 2024 19:23:22 +0200 Subject: [PATCH v2 12/24] mfd: rk8xx-core: Constify struct regmap_irq_chip Precedence: bulk X-Mailing-List: imx@lists.linux.dev List-Id: <imx.lists.linux.dev> List-Subscribe: <mailto:imx+subscribe@lists.linux.dev> List-Unsubscribe: <mailto:imx+unsubscribe@lists.linux.dev> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20240704-mfd-const-regmap_config-v2-12-0c8785b1331d@gmail.com> References: <20240704-mfd-const-regmap_config-v2-0-0c8785b1331d@gmail.com> In-Reply-To: <20240704-mfd-const-regmap_config-v2-0-0c8785b1331d@gmail.com> To: Support Opensource <support.opensource@diasemi.com>, Lee Jones <lee@kernel.org>, Shawn Guo <shawnguo@kernel.org>, Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix Kernel Team <kernel@pengutronix.de>, Fabio Estevam <festevam@gmail.com>, Matti Vaittinen <mazziesaccount@gmail.com>, Xu Yilun <yilun.xu@intel.com>, Tom Rix <trix@redhat.com>, Marek Vasut <marek.vasut+renesas@gmail.com>, Andy Shevchenko <andy@kernel.org>, Tony Lindgren <tony@atomide.com>, Tim Harvey <tharvey@gateworks.com>, Orson Zhai <orsonzhai@gmail.com>, Baolin Wang <baolin.wang@linux.alibaba.com>, Chunyan Zhang <zhang.lyra@gmail.com> Cc: linux-kernel@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-renesas-soc@vger.kernel.org, linux-omap@vger.kernel.org, Javier Carrasco <javier.carrasco.cruz@gmail.com> X-Mailer: b4 0.14-dev X-Developer-Signature: v=1; a=ed25519-sha256; t=1720113803; l=1375; i=javier.carrasco.cruz@gmail.com; s=20240312; h=from:subject:message-id; bh=6atl/DrZQUwmw6JNwTSf7L3f3VWfEvhmC/OA+w6bvAo=; b=VDrhdvOEM4a21M5C9PzDGgMYkfiGHRI9khEoolwkWfTbvEmLzU/atnVqu8qT3Hl2LPrJolCco DXFklpE9F8dDWYAFZeupXDJc4TJwL3xQ3mFoCfE5s7U6sfosUQiBSR0 X-Developer-Key: i=javier.carrasco.cruz@gmail.com; a=ed25519; pk=lzSIvIzMz0JhJrzLXI0HAdPwsNPSSmEn6RbS+PTS9aQ= |
Series |
mfd: Constify read-only regmap structs
|
expand
|
diff --git a/drivers/mfd/rk8xx-core.c b/drivers/mfd/rk8xx-core.c index 5eda3c0dbbdf..39ab114ea669 100644 --- a/drivers/mfd/rk8xx-core.c +++ b/drivers/mfd/rk8xx-core.c @@ -531,7 +531,7 @@ static const struct regmap_irq rk817_irqs[RK817_IRQ_END] = { REGMAP_IRQ_REG_LINE(23, 8) }; -static struct regmap_irq_chip rk805_irq_chip = { +static const struct regmap_irq_chip rk805_irq_chip = { .name = "rk805", .irqs = rk805_irqs, .num_irqs = ARRAY_SIZE(rk805_irqs), @@ -542,7 +542,7 @@ static struct regmap_irq_chip rk805_irq_chip = { .init_ack_masked = true, }; -static struct regmap_irq_chip rk806_irq_chip = { +static const struct regmap_irq_chip rk806_irq_chip = { .name = "rk806", .irqs = rk806_irqs, .num_irqs = ARRAY_SIZE(rk806_irqs), @@ -578,7 +578,7 @@ static const struct regmap_irq_chip rk816_irq_chip = { .init_ack_masked = true, }; -static struct regmap_irq_chip rk817_irq_chip = { +static const struct regmap_irq_chip rk817_irq_chip = { .name = "rk817", .irqs = rk817_irqs, .num_irqs = ARRAY_SIZE(rk817_irqs),
The regmap_irq_chip structs are not modified and can be declared as const to move their data to a read-only section. Signed-off-by: Javier Carrasco <javier.carrasco.cruz@gmail.com> --- drivers/mfd/rk8xx-core.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)