lkml.org 
[lkml]   [2013]   [Jan]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH v3] dw_dmac: don't exceed AHB master number in dwc_get_data_width
From
Date
On Wed, 2013-01-16 at 19:37 +0530, Viresh Kumar wrote: 
> On Wed, Jan 16, 2013 at 7:18 PM, Andy Shevchenko
> <andriy.shevchenko@linux.intel.com> wrote:
> > +static inline unsigned int dwc_get_master(struct dma_chan *chan, int master)
> > +{
> > + struct dw_dma *dw = to_dw_dma(chan->device);
> > + struct dw_dma_slave *dws = chan->private;
> > + unsigned int m = 0;
>
> :(

There a protection of wrong master parameter.

In the code I did
if ()
m = ...
else if ()
m = ...

Otherwise it would be 0.


--
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy


\
 
 \ /
  Last update: 2013-01-16 16:44    [W:0.046 / U:1.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site