[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOh2x==Te7MBNrqX-wjaPzso_xTC44rUejMDhs7SW7HJag7j8g@mail.gmail.com>
Date: Tue, 18 Sep 2012 12:09:01 +0530
From: viresh kumar <viresh.kumar@...aro.org>
To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
Cc: Vinod Koul <vinod.koul@...el.com>, spear-devel@...t.st.com,
linux-kernel@...r.kernel.org, Hein Tibosch <hein_tibosch@...oo.es>
Subject: Re: [PATCH 2/7] dw_dmac: fill optional encoded parameters in register structure
On Mon, Sep 17, 2012 at 1:09 PM, Andy Shevchenko
<andriy.shevchenko@...ux.intel.com> wrote:
> diff --git a/drivers/dma/dw_dmac_regs.h b/drivers/dma/dw_dmac_regs.h
> index f6d92d7..4633d39 100644
> --- a/drivers/dma/dw_dmac_regs.h
> +++ b/drivers/dma/dw_dmac_regs.h
> @@ -82,9 +82,28 @@ struct dw_dma_regs {
> DW_REG(ID);
> DW_REG(TEST);
>
> + /* reserved */
> + DW_REG(__reserved0);
> + DW_REG(__reserved1);
> +
> /* optional encoded params, 0x3c8..0x3f7 */
> + u32 __reserved;
> +
> + /* per-channel configuration registers */
> + u32 DWC_PARAMS[DW_DMA_MAX_NR_CHANNELS];
> + u32 MULTI_BLK_TYPE;
> + u32 MAX_BLK_SIZE;
> +
> + /* top-level parameters */
> + u32 DW_PARAMS;
> };
Above is Ok.
> +#define dma_raw_readl(addr, name) \
> + readl((addr) + offsetof(struct dw_dma_regs, name))
> +
> +#define dma_raw_writel(addr, name, val) \
> + writel((val), (addr) + offsetof(struct dw_dma_regs, name))
> +
But why don't you use earlier defined readl/writel macros:
dma_readl and dma_writel?
--
viresh
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists