public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Lars-Peter Clausen <lars@metafoo.de>
To: Chris Ball <cjb@laptop.org>
Cc: Anton Vorontsov <cbou@mail.ru>,
	Viresh Kumar <viresh.linux@gmail.com>,
	Stephen Warren <swarren@wwwdotorg.org>,
	Mike Rapoport <mike@compulab.co.il>,
	Shawn Guo <shawn.guo@linaro.org>,
	Albert Herranz <albert_herranz@yahoo.es>,
	Kevin Liu <kliu5@marvell.com>,
	linux-mmc@vger.kernel.org, Lars-Peter Clausen <lars@metafoo.de>
Subject: [PATCH v3 2/3] mmc: sdhci-pltfm: Constify the ops field of sdhci_pltfm_data struct
Date: Wed, 13 Mar 2013 19:26:04 +0100	[thread overview]
Message-ID: <1363199165-16211-2-git-send-email-lars@metafoo.de> (raw)
In-Reply-To: <1363199165-16211-1-git-send-email-lars@metafoo.de>

All users of the sdhci_ops struct in the sdhci core already treat it as const.
The sdhci-pltfm code itself never actually looks at the ops field of the
sdhci_pltfm_data struct and merely passes it on to the sdhci core, so make we
can make it const in the sdhci_pltfm_data struct as well. This allows us to
declare sdhci_ops structs as const in drivers using the sdhci-pltfm helper code.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Acked-by: Shawn Guo <shawn.guo@linaro.org>
---
 drivers/mmc/host/sdhci-pltfm.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/host/sdhci-pltfm.h b/drivers/mmc/host/sdhci-pltfm.h
index a3bfc1e..1210ed1 100644
--- a/drivers/mmc/host/sdhci-pltfm.h
+++ b/drivers/mmc/host/sdhci-pltfm.h
@@ -16,7 +16,7 @@
 #include "sdhci.h"
 
 struct sdhci_pltfm_data {
-	struct sdhci_ops *ops;
+	const struct sdhci_ops *ops;
 	unsigned int quirks;
 };
 
-- 
1.8.0


  reply	other threads:[~2013-03-13 18:24 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-03-13 18:26 [PATCH v3 1/3] mmc: sdhci_pltfm: Constify sdhci_pltfm_data Lars-Peter Clausen
2013-03-13 18:26 ` Lars-Peter Clausen [this message]
2013-03-13 18:26 ` [PATCH v3 3/3] mmc: sdhci: Constify sdhci_ops structs where possible Lars-Peter Clausen
2013-03-13 18:29 ` [PATCH v3 1/3] mmc: sdhci_pltfm: Constify sdhci_pltfm_data Stephen Warren
2013-03-22 17:01 ` Chris Ball

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1363199165-16211-2-git-send-email-lars@metafoo.de \
    --to=lars@metafoo.de \
    --cc=albert_herranz@yahoo.es \
    --cc=cbou@mail.ru \
    --cc=cjb@laptop.org \
    --cc=kliu5@marvell.com \
    --cc=linux-mmc@vger.kernel.org \
    --cc=mike@compulab.co.il \
    --cc=shawn.guo@linaro.org \
    --cc=swarren@wwwdotorg.org \
    --cc=viresh.linux@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox