diff options
author | John Crispin <blogic@openwrt.org> | 2012-11-09 11:16:14 (GMT) |
---|---|---|
committer | John Crispin <blogic@openwrt.org> | 2012-11-11 17:47:26 (GMT) |
commit | b8b3acbe6077b4736f641ec445be8a42cdd1f08b (patch) | |
tree | af6e1f61033b5d79626bdfcc02696acb4fc703d6 /arch | |
parent | 15753b6586710d788f36cfd5fbb98d0805b390ab (diff) | |
download | linux-b8b3acbe6077b4736f641ec445be8a42cdd1f08b.tar.xz |
MIPS: lantiq: verbose init of dma core
Print the hardware revision and port/channel info when starting the dma core.
Signed-off-by: John Crispin <blogic@openwrt.org>
Patchwork: http://patchwork.linux-mips.org/patch/4520
Diffstat (limited to 'arch')
-rw-r--r-- | arch/mips/lantiq/xway/dma.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/arch/mips/lantiq/xway/dma.c b/arch/mips/lantiq/xway/dma.c index 55d2c4f..b5d76d1 100644 --- a/arch/mips/lantiq/xway/dma.c +++ b/arch/mips/lantiq/xway/dma.c @@ -25,6 +25,7 @@ #include <lantiq_soc.h> #include <xway_dma.h> +#define LTQ_DMA_ID 0x08 #define LTQ_DMA_CTRL 0x10 #define LTQ_DMA_CPOLL 0x14 #define LTQ_DMA_CS 0x18 @@ -214,6 +215,7 @@ ltq_dma_init(struct platform_device *pdev) { struct clk *clk; struct resource *res; + unsigned id; int i; res = platform_get_resource(pdev, IORESOURCE_MEM, 0); @@ -243,7 +245,12 @@ ltq_dma_init(struct platform_device *pdev) ltq_dma_w32(DMA_POLL | DMA_CLK_DIV4, LTQ_DMA_CPOLL); ltq_dma_w32_mask(DMA_CHAN_ON, 0, LTQ_DMA_CCTRL); } - dev_info(&pdev->dev, "init done\n"); + + id = ltq_dma_r32(LTQ_DMA_ID); + dev_info(&pdev->dev, + "Init done - hw rev: %X, ports: %d, channels: %d\n", + id & 0x1f, (id >> 16) & 0xf, id >> 20); + return 0; } |