From: Tomas Winkler <tomas.winkler@intel.com>
To: gregkh@linuxfoundation.org
Cc: arnd@arndb.de, alan@linux.intel.com,
linux-kernel@vger.kernel.org,
Tomas Winkler <tomas.winkler@intel.com>
Subject: [char-misc-next 1/6] mei: mei_device can be const for mei register access functions
Date: Wed, 4 Jul 2012 19:24:49 +0300 [thread overview]
Message-ID: <1341419094-4204-1-git-send-email-tomas.winkler@intel.com> (raw)
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
---
drivers/misc/mei/mei_dev.h | 13 +++++++------
1 files changed, 7 insertions(+), 6 deletions(-)
diff --git a/drivers/misc/mei/mei_dev.h b/drivers/misc/mei/mei_dev.h
index d60250d..772f74d 100644
--- a/drivers/misc/mei/mei_dev.h
+++ b/drivers/misc/mei/mei_dev.h
@@ -363,7 +363,8 @@ int mei_find_me_client_index(const struct mei_device *dev, uuid_le cuuid);
*
* returns register value (u32)
*/
-static inline u32 mei_reg_read(struct mei_device *dev, unsigned long offset)
+static inline u32 mei_reg_read(const struct mei_device *dev,
+ unsigned long offset)
{
return ioread32(dev->mem_addr + offset);
}
@@ -375,8 +376,8 @@ static inline u32 mei_reg_read(struct mei_device *dev, unsigned long offset)
* @offset: offset from which to write the data
* @value: register value to write (u32)
*/
-static inline void mei_reg_write(struct mei_device *dev,
- unsigned long offset, u32 value)
+static inline void mei_reg_write(const struct mei_device *dev,
+ unsigned long offset, u32 value)
{
iowrite32(value, dev->mem_addr + offset);
}
@@ -388,7 +389,7 @@ static inline void mei_reg_write(struct mei_device *dev,
*
* returns the byte read.
*/
-static inline u32 mei_hcsr_read(struct mei_device *dev)
+static inline u32 mei_hcsr_read(const struct mei_device *dev)
{
return mei_reg_read(dev, H_CSR);
}
@@ -400,7 +401,7 @@ static inline u32 mei_hcsr_read(struct mei_device *dev)
*
* returns ME_CSR_HA register value (u32)
*/
-static inline u32 mei_mecsr_read(struct mei_device *dev)
+static inline u32 mei_mecsr_read(const struct mei_device *dev)
{
return mei_reg_read(dev, ME_CSR_HA);
}
@@ -412,7 +413,7 @@ static inline u32 mei_mecsr_read(struct mei_device *dev)
*
* returns ME_CB_RW register value (u32)
*/
-static inline u32 mei_mecbrw_read(struct mei_device *dev)
+static inline u32 mei_mecbrw_read(const struct mei_device *dev)
{
return mei_reg_read(dev, ME_CB_RW);
}
--
1.7.4.4
next reply other threads:[~2012-07-04 16:25 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-07-04 16:24 Tomas Winkler [this message]
2012-07-04 16:24 ` [char-misc-next 2/6] mei: remove write only wariable wd_due_counter Tomas Winkler
2012-07-04 16:24 ` [char-misc-next 3/6] mei: mei_wd_host_init: update the comment Tomas Winkler
2012-07-04 16:24 ` [char-misc-next 4/6] mei: introduce mei_data2slots wrapper Tomas Winkler
2012-07-04 16:24 ` [char-misc-next 5/6] mei: streamline the _mei_irq_thread_close/ioctol functions Tomas Winkler
2012-07-04 16:24 ` [char-misc-next 6/6] mei: mei_irq_thread_write_handler - line break fix Tomas Winkler
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=1341419094-4204-1-git-send-email-tomas.winkler@intel.com \
--to=tomas.winkler@intel.com \
--cc=alan@linux.intel.com \
--cc=arnd@arndb.de \
--cc=gregkh@linuxfoundation.org \
--cc=linux-kernel@vger.kernel.org \
/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
all inboxes | Powered by JetHome®