All of lore.kernel.org
 help / color / mirror / Atom feed
* [RESEND] dmaengine: pxa: add a default requestor policy
@ 2018-05-26  9:54 ` Robert Jarzmik
  0 siblings, 0 replies; 12+ messages in thread
From: Robert Jarzmik @ 2018-05-26  9:54 UTC (permalink / raw)
  To: Daniel Mack, Haojian Zhuang, Robert Jarzmik, Vinod Koul, Vinod Koul
  Cc: linux-arm-kernel, dmaengine, linux-kernel, Arnd Bergmann

As what former drcmr -1 value meant, add a this as a default to each
channel, ie. that by default no requestor line is used.

This is specifically used for network drivers smc91x and smc911x, and
needed for their port to slave maps.

Cc: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
---
 drivers/dma/pxa_dma.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/dma/pxa_dma.c b/drivers/dma/pxa_dma.c
index 9505334f9c6e..604df1bdadf7 100644
--- a/drivers/dma/pxa_dma.c
+++ b/drivers/dma/pxa_dma.c
@@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
 	dma_pool_destroy(chan->desc_pool);
 	chan->desc_pool = NULL;
 
+	chan->drcmr = (u32)-1;
+	chan->prio = PXAD_PRIO_LOWEST;
 }
 
 static void pxad_free_desc(struct virt_dma_desc *vd)
@@ -1386,6 +1388,9 @@ static int pxad_init_dmadev(struct platform_device *op,
 		c = devm_kzalloc(&op->dev, sizeof(*c), GFP_KERNEL);
 		if (!c)
 			return -ENOMEM;
+
+		c->drcmr = (u32)-1;
+		c->prio = PXAD_PRIO_LOWEST;
 		c->vc.desc_free = pxad_free_desc;
 		vchan_init(&c->vc, &pdev->slave);
 		init_waitqueue_head(&c->wq_state);

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

* [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-26  9:54 ` Robert Jarzmik
  0 siblings, 0 replies; 12+ messages in thread
From: Robert Jarzmik @ 2018-05-26  9:54 UTC (permalink / raw)
  To: Daniel Mack, Haojian Zhuang, Robert Jarzmik, Vinod Koul, Vinod Koul
  Cc: linux-arm-kernel, dmaengine, linux-kernel, Arnd Bergmann

As what former drcmr -1 value meant, add a this as a default to each
channel, ie. that by default no requestor line is used.

This is specifically used for network drivers smc91x and smc911x, and
needed for their port to slave maps.

Cc: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
---
 drivers/dma/pxa_dma.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/dma/pxa_dma.c b/drivers/dma/pxa_dma.c
index 9505334f9c6e..604df1bdadf7 100644
--- a/drivers/dma/pxa_dma.c
+++ b/drivers/dma/pxa_dma.c
@@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
 	dma_pool_destroy(chan->desc_pool);
 	chan->desc_pool = NULL;
 
+	chan->drcmr = (u32)-1;
+	chan->prio = PXAD_PRIO_LOWEST;
 }
 
 static void pxad_free_desc(struct virt_dma_desc *vd)
@@ -1386,6 +1388,9 @@ static int pxad_init_dmadev(struct platform_device *op,
 		c = devm_kzalloc(&op->dev, sizeof(*c), GFP_KERNEL);
 		if (!c)
 			return -ENOMEM;
+
+		c->drcmr = (u32)-1;
+		c->prio = PXAD_PRIO_LOWEST;
 		c->vc.desc_free = pxad_free_desc;
 		vchan_init(&c->vc, &pdev->slave);
 		init_waitqueue_head(&c->wq_state);
-- 
2.11.0

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

* [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-26  9:54 ` Robert Jarzmik
  0 siblings, 0 replies; 12+ messages in thread
From: Robert Jarzmik @ 2018-05-26  9:54 UTC (permalink / raw)
  To: linux-arm-kernel

As what former drcmr -1 value meant, add a this as a default to each
channel, ie. that by default no requestor line is used.

This is specifically used for network drivers smc91x and smc911x, and
needed for their port to slave maps.

Cc: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Robert Jarzmik <robert.jarzmik@free.fr>
---
 drivers/dma/pxa_dma.c | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/drivers/dma/pxa_dma.c b/drivers/dma/pxa_dma.c
index 9505334f9c6e..604df1bdadf7 100644
--- a/drivers/dma/pxa_dma.c
+++ b/drivers/dma/pxa_dma.c
@@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
 	dma_pool_destroy(chan->desc_pool);
 	chan->desc_pool = NULL;
 
+	chan->drcmr = (u32)-1;
+	chan->prio = PXAD_PRIO_LOWEST;
 }
 
 static void pxad_free_desc(struct virt_dma_desc *vd)
@@ -1386,6 +1388,9 @@ static int pxad_init_dmadev(struct platform_device *op,
 		c = devm_kzalloc(&op->dev, sizeof(*c), GFP_KERNEL);
 		if (!c)
 			return -ENOMEM;
+
+		c->drcmr = (u32)-1;
+		c->prio = PXAD_PRIO_LOWEST;
 		c->vc.desc_free = pxad_free_desc;
 		vchan_init(&c->vc, &pdev->slave);
 		init_waitqueue_head(&c->wq_state);
-- 
2.11.0

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

* [RESEND] dmaengine: pxa: add a default requestor policy
  2018-05-26  9:54 ` Robert Jarzmik
  (?)
@ 2018-05-29  7:24 ` Vinod
  -1 siblings, 0 replies; 12+ messages in thread
From: Vinod Koul @ 2018-05-29  7:24 UTC (permalink / raw)
  To: Robert Jarzmik
  Cc: Daniel Mack, Haojian Zhuang, Vinod Koul, linux-arm-kernel,
	dmaengine, linux-kernel, Arnd Bergmann

On 26-05-18, 11:54, Robert Jarzmik wrote:
> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
>  	dma_pool_destroy(chan->desc_pool);
>  	chan->desc_pool = NULL;
>  
> +	chan->drcmr = (u32)-1;

why not use U32_MAX for this?

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

* Re: [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-29  7:24 ` Vinod
  0 siblings, 0 replies; 12+ messages in thread
From: Vinod @ 2018-05-29  7:24 UTC (permalink / raw)
  To: Robert Jarzmik
  Cc: Daniel Mack, Haojian Zhuang, Vinod Koul, linux-arm-kernel,
	dmaengine, linux-kernel, Arnd Bergmann

On 26-05-18, 11:54, Robert Jarzmik wrote:
> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
>  	dma_pool_destroy(chan->desc_pool);
>  	chan->desc_pool = NULL;
>  
> +	chan->drcmr = (u32)-1;

why not use U32_MAX for this?

-- 
~Vinod

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

* [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-29  7:24 ` Vinod
  0 siblings, 0 replies; 12+ messages in thread
From: Vinod @ 2018-05-29  7:24 UTC (permalink / raw)
  To: linux-arm-kernel

On 26-05-18, 11:54, Robert Jarzmik wrote:
> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
>  	dma_pool_destroy(chan->desc_pool);
>  	chan->desc_pool = NULL;
>  
> +	chan->drcmr = (u32)-1;

why not use U32_MAX for this?

-- 
~Vinod

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

* [RESEND] dmaengine: pxa: add a default requestor policy
  2018-05-29  7:24 ` Vinod
  (?)
@ 2018-05-29 19:13 ` Robert Jarzmik
  -1 siblings, 0 replies; 12+ messages in thread
From: Robert Jarzmik @ 2018-05-29 19:13 UTC (permalink / raw)
  To: Vinod
  Cc: Daniel Mack, Haojian Zhuang, Vinod Koul, linux-arm-kernel,
	dmaengine, linux-kernel, Arnd Bergmann

Vinod <vkoul@kernel.org> writes:

> On 26-05-18, 11:54, Robert Jarzmik wrote:
>> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
>>  	dma_pool_destroy(chan->desc_pool);
>>  	chan->desc_pool = NULL;
>>  
>> +	chan->drcmr = (u32)-1;
>
> why not use U32_MAX for this?
But of course, anything else you see ?

Cheers.

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

* Re: [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-29 19:13 ` Robert Jarzmik
  0 siblings, 0 replies; 12+ messages in thread
From: Robert Jarzmik @ 2018-05-29 19:13 UTC (permalink / raw)
  To: Vinod
  Cc: Daniel Mack, Haojian Zhuang, Vinod Koul, linux-arm-kernel,
	dmaengine, linux-kernel, Arnd Bergmann

Vinod <vkoul@kernel.org> writes:

> On 26-05-18, 11:54, Robert Jarzmik wrote:
>> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
>>  	dma_pool_destroy(chan->desc_pool);
>>  	chan->desc_pool = NULL;
>>  
>> +	chan->drcmr = (u32)-1;
>
> why not use U32_MAX for this?
But of course, anything else you see ?

Cheers.

-- 
Robert

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

* [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-29 19:13 ` Robert Jarzmik
  0 siblings, 0 replies; 12+ messages in thread
From: Robert Jarzmik @ 2018-05-29 19:13 UTC (permalink / raw)
  To: linux-arm-kernel

Vinod <vkoul@kernel.org> writes:

> On 26-05-18, 11:54, Robert Jarzmik wrote:
>> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
>>  	dma_pool_destroy(chan->desc_pool);
>>  	chan->desc_pool = NULL;
>>  
>> +	chan->drcmr = (u32)-1;
>
> why not use U32_MAX for this?
But of course, anything else you see ?

Cheers.

-- 
Robert

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

* [RESEND] dmaengine: pxa: add a default requestor policy
  2018-05-29 19:13 ` Robert Jarzmik
  (?)
@ 2018-05-30 10:25 ` Vinod
  -1 siblings, 0 replies; 12+ messages in thread
From: Vinod Koul @ 2018-05-30 10:25 UTC (permalink / raw)
  To: Robert Jarzmik
  Cc: Daniel Mack, Haojian Zhuang, Vinod Koul, linux-arm-kernel,
	dmaengine, linux-kernel, Arnd Bergmann

On 29-05-18, 21:13, Robert Jarzmik wrote:
> Vinod <vkoul@kernel.org> writes:
> 
> > On 26-05-18, 11:54, Robert Jarzmik wrote:
> >> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
> >>  	dma_pool_destroy(chan->desc_pool);
> >>  	chan->desc_pool = NULL;
> >>  
> >> +	chan->drcmr = (u32)-1;
> >
> > why not use U32_MAX for this?
> But of course, anything else you see ?

Nope that was the only one :)

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

* Re: [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-30 10:25 ` Vinod
  0 siblings, 0 replies; 12+ messages in thread
From: Vinod @ 2018-05-30 10:25 UTC (permalink / raw)
  To: Robert Jarzmik
  Cc: Daniel Mack, Haojian Zhuang, Vinod Koul, linux-arm-kernel,
	dmaengine, linux-kernel, Arnd Bergmann

On 29-05-18, 21:13, Robert Jarzmik wrote:
> Vinod <vkoul@kernel.org> writes:
> 
> > On 26-05-18, 11:54, Robert Jarzmik wrote:
> >> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
> >>  	dma_pool_destroy(chan->desc_pool);
> >>  	chan->desc_pool = NULL;
> >>  
> >> +	chan->drcmr = (u32)-1;
> >
> > why not use U32_MAX for this?
> But of course, anything else you see ?

Nope that was the only one :)

-- 
~Vinod

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

* [RESEND PATCH] dmaengine: pxa: add a default requestor policy
@ 2018-05-30 10:25 ` Vinod
  0 siblings, 0 replies; 12+ messages in thread
From: Vinod @ 2018-05-30 10:25 UTC (permalink / raw)
  To: linux-arm-kernel

On 29-05-18, 21:13, Robert Jarzmik wrote:
> Vinod <vkoul@kernel.org> writes:
> 
> > On 26-05-18, 11:54, Robert Jarzmik wrote:
> >> @@ -762,6 +762,8 @@ static void pxad_free_chan_resources(struct dma_chan *dchan)
> >>  	dma_pool_destroy(chan->desc_pool);
> >>  	chan->desc_pool = NULL;
> >>  
> >> +	chan->drcmr = (u32)-1;
> >
> > why not use U32_MAX for this?
> But of course, anything else you see ?

Nope that was the only one :)

-- 
~Vinod

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

end of thread, other threads:[~2018-05-30 10:25 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-05-29 19:13 [RESEND] dmaengine: pxa: add a default requestor policy Robert Jarzmik
2018-05-29 19:13 ` [RESEND PATCH] " Robert Jarzmik
2018-05-29 19:13 ` Robert Jarzmik
  -- strict thread matches above, loose matches on Subject: below --
2018-05-30 10:25 [RESEND] " Vinod Koul
2018-05-30 10:25 ` [RESEND PATCH] " Vinod
2018-05-30 10:25 ` Vinod
2018-05-29  7:24 [RESEND] " Vinod Koul
2018-05-29  7:24 ` [RESEND PATCH] " Vinod
2018-05-29  7:24 ` Vinod
2018-05-26  9:54 [RESEND] " Robert Jarzmik
2018-05-26  9:54 ` [RESEND PATCH] " Robert Jarzmik
2018-05-26  9:54 ` Robert Jarzmik

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.