All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] mailbox: pl320: constify amba_id
@ 2017-08-23 16:38 Arvind Yadav
  2017-08-23 16:38 ` [PATCH] mailbox: arm_mhu: " Arvind Yadav
  0 siblings, 1 reply; 2+ messages in thread
From: Arvind Yadav @ 2017-08-23 16:38 UTC (permalink / raw)
  To: jassisinghbrar; +Cc: linux-kernel

amba_id are not supposed to change at runtime. All functions
working with const amba_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 drivers/mailbox/pl320-ipc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mailbox/pl320-ipc.c b/drivers/mailbox/pl320-ipc.c
index 2dbed87..a80927a 100644
--- a/drivers/mailbox/pl320-ipc.c
+++ b/drivers/mailbox/pl320-ipc.c
@@ -175,7 +175,7 @@ static int pl320_probe(struct amba_device *adev, const struct amba_id *id)
 	return ret;
 }
 
-static struct amba_id pl320_ids[] = {
+static const struct amba_id pl320_ids[] = {
 	{
 		.id	= 0x00041320,
 		.mask	= 0x000fffff,
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [PATCH] mailbox: arm_mhu: constify amba_id
  2017-08-23 16:38 [PATCH] mailbox: pl320: constify amba_id Arvind Yadav
@ 2017-08-23 16:38 ` Arvind Yadav
  0 siblings, 0 replies; 2+ messages in thread
From: Arvind Yadav @ 2017-08-23 16:38 UTC (permalink / raw)
  To: jassisinghbrar; +Cc: linux-kernel

amba_id are not supposed to change at runtime. All functions
working with const amba_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
---
 drivers/mailbox/arm_mhu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mailbox/arm_mhu.c b/drivers/mailbox/arm_mhu.c
index 99befa7..793678c 100644
--- a/drivers/mailbox/arm_mhu.c
+++ b/drivers/mailbox/arm_mhu.c
@@ -171,7 +171,7 @@ static int mhu_remove(struct amba_device *adev)
 	return 0;
 }
 
-static struct amba_id mhu_ids[] = {
+static const struct amba_id mhu_ids[] = {
 	{
 		.id	= 0x1bb098,
 		.mask	= 0xffffff,
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-08-23 16:38 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-08-23 16:38 [PATCH] mailbox: pl320: constify amba_id Arvind Yadav
2017-08-23 16:38 ` [PATCH] mailbox: arm_mhu: " Arvind Yadav

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.