Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1334580

Re: [PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line

From Vinod Koul <vinod.koul@intel.com>
Newsgroups linux.kernel
Subject Re: [PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line
Date 2016-02-15 17:40 +0100
Message-ID <r2ulP-3v3-1@gated-at.bofh.it> (permalink)
References <r16Yi-5Zm-13@gated-at.bofh.it> <r16Yj-5Zm-19@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu, Feb 11, 2016 at 10:23:18PM +0100, Robert Jarzmik wrote:
> @@ -1399,13 +1405,17 @@ static int pxad_probe(struct platform_device *op)
>  		return PTR_ERR(pdev->base);
>  
>  	of_id = of_match_device(pxad_dt_ids, &op->dev);
> -	if (of_id)
> +	if (of_id) {
>  		of_property_read_u32(op->dev.of_node, "#dma-channels",
>  				     &dma_channels);
> -	else if (pdata && pdata->dma_channels)
> +		of_property_read_u32(op->dev.of_node, "#requestors",
> +				     &nb_requestors);

I think we should check the return value here. This might be err in case
when we have older DT on platform, but still should work with default in
that case

> +	} else if (pdata && pdata->dma_channels) {
>  		dma_channels = pdata->dma_channels;
> -	else
> +		nb_requestors = pdata->nb_requestors;
> +	} else {
>  		dma_channels = 32;	/* default 32 channel */
> +	}

-- 
~Vinod

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line Robert Jarzmik <robert.jarzmik@free.fr> - 2016-02-11 22:30 +0100
  Re: [PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line Vinod Koul <vinod.koul@intel.com> - 2016-02-15 17:40 +0100
    Re: [PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line Vinod Koul <vinod.koul@intel.com> - 2016-02-15 18:30 +0100
      Re: [PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line Robert Jarzmik <robert.jarzmik@free.fr> - 2016-02-15 19:30 +0100
    Re: [PATCH 4/4] dmaengine: pxa_dma: fix the maximum requestor line Robert Jarzmik <robert.jarzmik@free.fr> - 2016-02-15 18:30 +0100

csiph-web