diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-01-18 12:50:55 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-01-18 12:50:55 -0800 |
commit | d90f351a9bec6af3e8e7cefbbff94072461c3c9a (patch) | |
tree | 71db07e8820b63a60fefcd7e3d1f044450a4b55d /arch/avr32 | |
parent | c1a198d9235b9e7d6942027374e44f78ebdcb455 (diff) | |
parent | 238d1c6041ebcb5ce7c075b696f6cc9962991e94 (diff) | |
download | linux-d90f351a9bec6af3e8e7cefbbff94072461c3c9a.tar.bz2 |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32
Pull AVR32 updates from Hans-Christian Noren Egtvedt.
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/egtvedt/linux-avr32:
mmc: atmel: get rid of struct mci_dma_data
mmc: atmel-mci: restore dma on AVR32
avr32: wire up missing syscalls
avr32: wire up accept4 syscall
Diffstat (limited to 'arch/avr32')
-rw-r--r-- | arch/avr32/include/uapi/asm/unistd.h | 4 | ||||
-rw-r--r-- | arch/avr32/kernel/syscall_table.S | 4 | ||||
-rw-r--r-- | arch/avr32/mach-at32ap/at32ap700x.c | 31 |
3 files changed, 31 insertions, 8 deletions
diff --git a/arch/avr32/include/uapi/asm/unistd.h b/arch/avr32/include/uapi/asm/unistd.h index bbe2fba565cd..b60132bb27ea 100644 --- a/arch/avr32/include/uapi/asm/unistd.h +++ b/arch/avr32/include/uapi/asm/unistd.h @@ -333,5 +333,9 @@ #define __NR_memfd_create 318 #define __NR_bpf 319 #define __NR_execveat 320 +#define __NR_accept4 321 +#define __NR_userfaultfd 322 +#define __NR_membarrier 323 +#define __NR_mlock2 324 #endif /* _UAPI__ASM_AVR32_UNISTD_H */ diff --git a/arch/avr32/kernel/syscall_table.S b/arch/avr32/kernel/syscall_table.S index c3b593bfc3b3..1915a443b491 100644 --- a/arch/avr32/kernel/syscall_table.S +++ b/arch/avr32/kernel/syscall_table.S @@ -334,4 +334,8 @@ sys_call_table: .long sys_memfd_create .long sys_bpf .long sys_execveat /* 320 */ + .long sys_accept4 + .long sys_userfaultfd + .long sys_membarrier + .long sys_mlock2 .long sys_ni_syscall /* r8 is saturated at nr_syscalls */ diff --git a/arch/avr32/mach-at32ap/at32ap700x.c b/arch/avr32/mach-at32ap/at32ap700x.c index b4cb3bd89d8a..bf445aa48282 100644 --- a/arch/avr32/mach-at32ap/at32ap700x.c +++ b/arch/avr32/mach-at32ap/at32ap700x.c @@ -17,7 +17,6 @@ #include <linux/spi/spi.h> #include <linux/usb/atmel_usba_udc.h> -#include <linux/platform_data/mmc-atmel-mci.h> #include <linux/atmel-mci.h> #include <asm/io.h> @@ -1321,11 +1320,26 @@ static struct clk atmel_mci0_pclk = { .index = 9, }; +static bool at32_mci_dma_filter(struct dma_chan *chan, void *pdata) +{ + struct dw_dma_slave *sl = pdata; + + if (!sl) + return false; + + if (sl->dma_dev == chan->device->dev) { + chan->private = sl; + return true; + } + + return false; +} + struct platform_device *__init at32_add_device_mci(unsigned int id, struct mci_platform_data *data) { struct platform_device *pdev; - struct mci_dma_data *slave; + struct dw_dma_slave *slave; u32 pioa_mask; u32 piob_mask; @@ -1344,17 +1358,18 @@ at32_add_device_mci(unsigned int id, struct mci_platform_data *data) ARRAY_SIZE(atmel_mci0_resource))) goto fail; - slave = kzalloc(sizeof(struct mci_dma_data), GFP_KERNEL); + slave = kzalloc(sizeof(*slave), GFP_KERNEL); if (!slave) goto fail; - slave->sdata.dma_dev = &dw_dmac0_device.dev; - slave->sdata.src_id = 0; - slave->sdata.dst_id = 1; - slave->sdata.src_master = 1; - slave->sdata.dst_master = 0; + slave->dma_dev = &dw_dmac0_device.dev; + slave->src_id = 0; + slave->dst_id = 1; + slave->src_master = 1; + slave->dst_master = 0; data->dma_slave = slave; + data->dma_filter = at32_mci_dma_filter; if (platform_device_add_data(pdev, data, sizeof(struct mci_platform_data))) |