public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] dmaengine: pl08x: constify amba_id
@ 2017-08-23 16:27 Arvind Yadav
  2017-08-23 16:27 ` [PATCH] dmaengine: pl330: " Arvind Yadav
  2017-08-28 15:41 ` [PATCH] dmaengine: pl08x: " Vinod Koul
  0 siblings, 2 replies; 3+ messages in thread
From: Arvind Yadav @ 2017-08-23 16:27 UTC (permalink / raw)
  To: dan.j.williams, vinod.koul; +Cc: linux-kernel, dmaengine

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/dma/amba-pl08x.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/dma/amba-pl08x.c b/drivers/dma/amba-pl08x.c
index 13cc95c..b52b0d5 100644
--- a/drivers/dma/amba-pl08x.c
+++ b/drivers/dma/amba-pl08x.c
@@ -3033,7 +3033,7 @@ static struct vendor_data vendor_ftdmac020 = {
 	.max_transfer_size = PL080_CONTROL_TRANSFER_SIZE_MASK,
 };
 
-static struct amba_id pl08x_ids[] = {
+static const struct amba_id pl08x_ids[] = {
 	/* Samsung PL080S variant */
 	{
 		.id	= 0x0a141080,
-- 
2.7.4

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

* [PATCH] dmaengine: pl330: constify amba_id
  2017-08-23 16:27 [PATCH] dmaengine: pl08x: constify amba_id Arvind Yadav
@ 2017-08-23 16:27 ` Arvind Yadav
  2017-08-28 15:41 ` [PATCH] dmaengine: pl08x: " Vinod Koul
  1 sibling, 0 replies; 3+ messages in thread
From: Arvind Yadav @ 2017-08-23 16:27 UTC (permalink / raw)
  To: dan.j.williams, vinod.koul; +Cc: linux-kernel, dmaengine

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/dma/pl330.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/dma/pl330.c b/drivers/dma/pl330.c
index b19ee04..f122c2a 100644
--- a/drivers/dma/pl330.c
+++ b/drivers/dma/pl330.c
@@ -3023,7 +3023,7 @@ static int pl330_remove(struct amba_device *adev)
 	return 0;
 }
 
-static struct amba_id pl330_ids[] = {
+static const struct amba_id pl330_ids[] = {
 	{
 		.id	= 0x00041330,
 		.mask	= 0x000fffff,
-- 
2.7.4

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

* Re: [PATCH] dmaengine: pl08x: constify amba_id
  2017-08-23 16:27 [PATCH] dmaengine: pl08x: constify amba_id Arvind Yadav
  2017-08-23 16:27 ` [PATCH] dmaengine: pl330: " Arvind Yadav
@ 2017-08-28 15:41 ` Vinod Koul
  1 sibling, 0 replies; 3+ messages in thread
From: Vinod Koul @ 2017-08-28 15:41 UTC (permalink / raw)
  To: Arvind Yadav; +Cc: dan.j.williams, linux-kernel, dmaengine

On Wed, Aug 23, 2017 at 09:57:12PM +0530, Arvind Yadav wrote:
> amba_id are not supposed to change at runtime. All functions
> working with const amba_id. So mark the non-const structs as const.

Applied both, thanks

-- 
~Vinod

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

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

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-08-23 16:27 [PATCH] dmaengine: pl08x: constify amba_id Arvind Yadav
2017-08-23 16:27 ` [PATCH] dmaengine: pl330: " Arvind Yadav
2017-08-28 15:41 ` [PATCH] dmaengine: pl08x: " Vinod Koul

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox