Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
930a6348
Commit
930a6348
authored
Jul 04, 2017
by
Vinod Koul
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'topic/dw' into for-linus
parents
1326fe64
702fce05
Changes
9
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
93 additions
and
1395 deletions
+93
-1395
drivers/dma/dw/Kconfig
drivers/dma/dw/Kconfig
+1
-6
drivers/dma/dw/core.c
drivers/dma/dw/core.c
+2
-330
drivers/dma/dw/platform.c
drivers/dma/dw/platform.c
+5
-1
drivers/dma/dw/regs.h
drivers/dma/dw/regs.h
+11
-39
include/linux/dma/dw.h
include/linux/dma/dw.h
+0
-21
sound/atmel/Kconfig
sound/atmel/Kconfig
+3
-10
sound/atmel/Makefile
sound/atmel/Makefile
+0
-2
sound/atmel/abdac.c
sound/atmel/abdac.c
+0
-610
sound/atmel/ac97c.c
sound/atmel/ac97c.c
+71
-376
No files found.
drivers/dma/dw/Kconfig
View file @
930a6348
...
...
@@ -6,17 +6,12 @@ config DW_DMAC_CORE
tristate
select DMA_ENGINE
config DW_DMAC_BIG_ENDIAN_IO
bool
config DW_DMAC
tristate "Synopsys DesignWare AHB DMA platform driver"
select DW_DMAC_CORE
select DW_DMAC_BIG_ENDIAN_IO if AVR32
default y if CPU_AT32AP7000
help
Support the Synopsys DesignWare AHB DMA controller. This
can be integrated in chips such as the
Atmel AT32ap7000
.
can be integrated in chips such as the
Intel Cherrytrail
.
config DW_DMAC_PCI
tristate "Synopsys DesignWare AHB DMA PCI driver"
...
...
drivers/dma/dw/core.c
View file @
930a6348
This diff is collapsed.
Click to expand it.
drivers/dma/dw/platform.c
View file @
930a6348
...
...
@@ -306,8 +306,12 @@ static int dw_resume_early(struct device *dev)
{
struct
platform_device
*
pdev
=
to_platform_device
(
dev
);
struct
dw_dma_chip
*
chip
=
platform_get_drvdata
(
pdev
);
int
ret
;
ret
=
clk_prepare_enable
(
chip
->
clk
);
if
(
ret
)
return
ret
;
clk_prepare_enable
(
chip
->
clk
);
return
dw_dma_enable
(
chip
);
}
...
...
drivers/dma/dw/regs.h
View file @
930a6348
...
...
@@ -116,20 +116,6 @@ struct dw_dma_regs {
DW_REG
(
GLOBAL_CFG
);
};
/*
* Big endian I/O access when reading and writing to the DMA controller
* registers. This is needed on some platforms, like the Atmel AVR32
* architecture.
*/
#ifdef CONFIG_DW_DMAC_BIG_ENDIAN_IO
#define dma_readl_native ioread32be
#define dma_writel_native iowrite32be
#else
#define dma_readl_native readl
#define dma_writel_native writel
#endif
/* Bitfields in DW_PARAMS */
#define DW_PARAMS_NR_CHAN 8
/* number of channels */
#define DW_PARAMS_NR_MASTER 11
/* number of AHB masters */
...
...
@@ -280,7 +266,6 @@ struct dw_dma_chan {
unsigned
long
flags
;
struct
list_head
active_list
;
struct
list_head
queue
;
struct
dw_cyclic_desc
*
cdesc
;
unsigned
int
descs_allocated
;
...
...
@@ -302,9 +287,9 @@ __dwc_regs(struct dw_dma_chan *dwc)
}
#define channel_readl(dwc, name) \
dma_readl_native
(&(__dwc_regs(dwc)->name))
readl
(&(__dwc_regs(dwc)->name))
#define channel_writel(dwc, name, val) \
dma_writel_native
((val), &(__dwc_regs(dwc)->name))
writel
((val), &(__dwc_regs(dwc)->name))
static
inline
struct
dw_dma_chan
*
to_dw_dma_chan
(
struct
dma_chan
*
chan
)
{
...
...
@@ -333,9 +318,9 @@ static inline struct dw_dma_regs __iomem *__dw_regs(struct dw_dma *dw)
}
#define dma_readl(dw, name) \
dma_readl_native
(&(__dw_regs(dw)->name))
readl
(&(__dw_regs(dw)->name))
#define dma_writel(dw, name, val) \
dma_writel_native
((val), &(__dw_regs(dw)->name))
writel
((val), &(__dw_regs(dw)->name))
#define idma32_readq(dw, name) \
hi_lo_readq(&(__dw_regs(dw)->name))
...
...
@@ -352,43 +337,30 @@ static inline struct dw_dma *to_dw_dma(struct dma_device *ddev)
return
container_of
(
ddev
,
struct
dw_dma
,
dma
);
}
#ifdef CONFIG_DW_DMAC_BIG_ENDIAN_IO
typedef
__be32
__dw32
;
#else
typedef
__le32
__dw32
;
#endif
/* LLI == Linked List Item; a.k.a. DMA block descriptor */
struct
dw_lli
{
/* values that are not changed by hardware */
__
dw
32
sar
;
__
dw
32
dar
;
__
dw
32
llp
;
/* chain to next lli */
__
dw
32
ctllo
;
__
le
32
sar
;
__
le
32
dar
;
__
le
32
llp
;
/* chain to next lli */
__
le
32
ctllo
;
/* values that may get written back: */
__
dw
32
ctlhi
;
__
le
32
ctlhi
;
/* sstat and dstat can snapshot peripheral register state.
* silicon config may discard either or both...
*/
__
dw
32
sstat
;
__
dw
32
dstat
;
__
le
32
sstat
;
__
le
32
dstat
;
};
struct
dw_desc
{
/* FIRST values the hardware uses */
struct
dw_lli
lli
;
#ifdef CONFIG_DW_DMAC_BIG_ENDIAN_IO
#define lli_set(d, reg, v) ((d)->lli.reg |= cpu_to_be32(v))
#define lli_clear(d, reg, v) ((d)->lli.reg &= ~cpu_to_be32(v))
#define lli_read(d, reg) be32_to_cpu((d)->lli.reg)
#define lli_write(d, reg, v) ((d)->lli.reg = cpu_to_be32(v))
#else
#define lli_set(d, reg, v) ((d)->lli.reg |= cpu_to_le32(v))
#define lli_clear(d, reg, v) ((d)->lli.reg &= ~cpu_to_le32(v))
#define lli_read(d, reg) le32_to_cpu((d)->lli.reg)
#define lli_write(d, reg, v) ((d)->lli.reg = cpu_to_le32(v))
#endif
/* THEN values for driver housekeeping */
struct
list_head
desc_node
;
...
...
include/linux/dma/dw.h
View file @
930a6348
...
...
@@ -50,25 +50,4 @@ static inline int dw_dma_probe(struct dw_dma_chip *chip) { return -ENODEV; }
static
inline
int
dw_dma_remove
(
struct
dw_dma_chip
*
chip
)
{
return
0
;
}
#endif
/* CONFIG_DW_DMAC_CORE */
/* DMA API extensions */
struct
dw_desc
;
struct
dw_cyclic_desc
{
struct
dw_desc
**
desc
;
unsigned
long
periods
;
void
(
*
period_callback
)(
void
*
param
);
void
*
period_callback_param
;
};
struct
dw_cyclic_desc
*
dw_dma_cyclic_prep
(
struct
dma_chan
*
chan
,
dma_addr_t
buf_addr
,
size_t
buf_len
,
size_t
period_len
,
enum
dma_transfer_direction
direction
);
void
dw_dma_cyclic_free
(
struct
dma_chan
*
chan
);
int
dw_dma_cyclic_start
(
struct
dma_chan
*
chan
);
void
dw_dma_cyclic_stop
(
struct
dma_chan
*
chan
);
dma_addr_t
dw_dma_get_src_addr
(
struct
dma_chan
*
chan
);
dma_addr_t
dw_dma_get_dst_addr
(
struct
dma_chan
*
chan
);
#endif
/* _DMA_DW_H */
sound/atmel/Kconfig
View file @
930a6348
menu "Atmel devices (AVR32 and AT91)"
depends on AVR32 || ARCH_AT91
config SND_ATMEL_ABDAC
tristate "Atmel Audio Bitstream DAC (ABDAC) driver"
select SND_PCM
depends on DW_DMAC && AVR32
help
ALSA sound driver for the Atmel Audio Bitstream DAC (ABDAC).
menu "Atmel devices (AT91)"
depends on ARCH_AT91
config SND_ATMEL_AC97C
tristate "Atmel AC97 Controller (AC97C) driver"
select SND_PCM
select SND_AC97_CODEC
depends on
(DW_DMAC && AVR32) ||
ARCH_AT91
depends on ARCH_AT91
help
ALSA sound driver for the Atmel AC97 controller.
...
...
sound/atmel/Makefile
View file @
930a6348
snd-atmel-abdac-objs
:=
abdac.o
snd-atmel-ac97c-objs
:=
ac97c.o
obj-$(CONFIG_SND_ATMEL_ABDAC)
+=
snd-atmel-abdac.o
obj-$(CONFIG_SND_ATMEL_AC97C)
+=
snd-atmel-ac97c.o
sound/atmel/abdac.c
deleted
100644 → 0
View file @
1326fe64
This diff is collapsed.
Click to expand it.
sound/atmel/ac97c.c
View file @
930a6348
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment