Message ID | 50EFA586.5010508@asianux.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Friday 11 January 2013 11:09 AM, Chen Gang wrote: > > 'omap_dma_reserve_channels' when used is suppose to be from command. > so, it alreay has value before 1st call of omap_system_dma_probe. > and it will never be changed again during running (not from ioctl). > > but 'dma_lch_count' is zero before 1st call of omap_system_dma_probe. > so it will be failed for omap_dma_reserve_channels, when 1st call. > > so, need use 'd->lch_count' instead of 'dma_lch_count' for judging. > > Signed-off-by: Chen Gang <gang.chen@asianux.com> > Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> > --- Looks fine to me. Tony, If you are ok with the patch, can you pick this fix in your non-critical fixes branch ? -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
* Santosh Shilimkar <santosh.shilimkar@ti.com> [130111 03:40]: > On Friday 11 January 2013 11:09 AM, Chen Gang wrote: > > > > 'omap_dma_reserve_channels' when used is suppose to be from command. > > so, it alreay has value before 1st call of omap_system_dma_probe. > > and it will never be changed again during running (not from ioctl). > > > > but 'dma_lch_count' is zero before 1st call of omap_system_dma_probe. > > so it will be failed for omap_dma_reserve_channels, when 1st call. > > > > so, need use 'd->lch_count' instead of 'dma_lch_count' for judging. > > > >Signed-off-by: Chen Gang <gang.chen@asianux.com> > >Signed-off-by: Santosh Shilimkar <santosh.shilimkar@ti.com> > >--- > Looks fine to me. > > Tony, > If you are ok with the patch, can you pick this fix in your > non-critical fixes branch ? Yes applying thanks. Tony -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/arch/arm/plat-omap/dma.c b/arch/arm/plat-omap/dma.c index 4136b20..e06c34b 100644 --- a/arch/arm/plat-omap/dma.c +++ b/arch/arm/plat-omap/dma.c @@ -2019,7 +2019,7 @@ static int omap_system_dma_probe(struct platform_device *pdev) errata = p->errata; if ((d->dev_caps & RESERVE_CHANNEL) && omap_dma_reserve_channels - && (omap_dma_reserve_channels <= dma_lch_count)) + && (omap_dma_reserve_channels < d->lch_count)) d->lch_count = omap_dma_reserve_channels; dma_lch_count = d->lch_count;