diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2014-02-24 07:58:50 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-02-24 07:58:50 -0800 |
commit | 335d08b86fb48e0445de090de0dacd7404798892 (patch) | |
tree | 507c293991eeecde6aff064b15b7497d897cca1b /arch | |
parent | cfbf8d4857c26a8a307fb7cd258074c9dcd8c691 (diff) | |
parent | 9955e8d15f53e53540aaed7bcef640142e65e900 (diff) | |
download | linux-335d08b86fb48e0445de090de0dacd7404798892.tar.bz2 |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux
Pull s390 bug fixes from Martin Schwidefsky:
"A couple of s390 bug fixes. The PCI segment boundary issue is a nasty
one as it can lead to data corruption"
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux:
s390/cio: Fix missing subchannels after CHPID configure on
s390/pci/dma: use correct segment boundary size
s390/compat: fix sys_sched_getattr compat wrapper
s390/zcrypt: additional check to avoid overflow in msg-type 6 requests
Diffstat (limited to 'arch')
-rw-r--r-- | arch/s390/kernel/compat_wrapper.S | 2 | ||||
-rw-r--r-- | arch/s390/pci/pci_dma.c | 8 |
2 files changed, 6 insertions, 4 deletions
diff --git a/arch/s390/kernel/compat_wrapper.S b/arch/s390/kernel/compat_wrapper.S index 59c8efce1b99..0248949a756d 100644 --- a/arch/s390/kernel/compat_wrapper.S +++ b/arch/s390/kernel/compat_wrapper.S @@ -1421,5 +1421,5 @@ ENTRY(sys_sched_setattr_wrapper) ENTRY(sys_sched_getattr_wrapper) lgfr %r2,%r2 # pid_t llgtr %r3,%r3 # const char __user * - llgfr %r3,%r3 # unsigned int + llgfr %r4,%r4 # unsigned int jg sys_sched_getattr diff --git a/arch/s390/pci/pci_dma.c b/arch/s390/pci/pci_dma.c index 60c11a629d96..f91c03119804 100644 --- a/arch/s390/pci/pci_dma.c +++ b/arch/s390/pci/pci_dma.c @@ -206,11 +206,13 @@ static void dma_cleanup_tables(struct zpci_dev *zdev) zdev->dma_table = NULL; } -static unsigned long __dma_alloc_iommu(struct zpci_dev *zdev, unsigned long start, - int size) +static unsigned long __dma_alloc_iommu(struct zpci_dev *zdev, + unsigned long start, int size) { - unsigned long boundary_size = 0x1000000; + unsigned long boundary_size; + boundary_size = ALIGN(dma_get_seg_boundary(&zdev->pdev->dev) + 1, + PAGE_SIZE) >> PAGE_SHIFT; return iommu_area_alloc(zdev->iommu_bitmap, zdev->iommu_pages, start, size, 0, boundary_size, 0); } |