Skip to content

Commit 36d8a3e

Browse files
committed
Merge tag 'for-linus' of https://github.com/openrisc/linux
Pull OpenRISC updates from Stafford Horne: "I have relocated to London so not much work from me while I get settled. Still, OpenRISC picked up two patches in this window: - Fix for kernel page table walking from Jann Horn - MAINTAINER entry cleanup from Palmer Dabbelt" * tag 'for-linus' of https://github.com/openrisc/linux: MAINTAINERS: git://github -> https://github.com for openrisc openrisc: Fix pagewalk usage in arch_dma_{clear, set}_uncached
2 parents 4141096 + 34a0bac commit 36d8a3e

File tree

2 files changed

+9
-9
lines changed

2 files changed

+9
-9
lines changed

MAINTAINERS

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15411,7 +15411,7 @@ M: Stafford Horne <[email protected]>
1541115411
1541215412
S: Maintained
1541315413
W: http://openrisc.io
15414-
T: git git://github.com/openrisc/linux.git
15414+
T: git https://github.com/openrisc/linux.git
1541515415
F: Documentation/devicetree/bindings/openrisc/
1541615416
F: Documentation/openrisc/
1541715417
F: arch/openrisc/

arch/openrisc/kernel/dma.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,10 @@ void *arch_dma_set_uncached(void *cpu_addr, size_t size)
7474
* We need to iterate through the pages, clearing the dcache for
7575
* them and setting the cache-inhibit bit.
7676
*/
77-
mmap_read_lock(&init_mm);
78-
error = walk_page_range(&init_mm, va, va + size, &set_nocache_walk_ops,
79-
NULL);
80-
mmap_read_unlock(&init_mm);
77+
mmap_write_lock(&init_mm);
78+
error = walk_page_range_novma(&init_mm, va, va + size,
79+
&set_nocache_walk_ops, NULL, NULL);
80+
mmap_write_unlock(&init_mm);
8181

8282
if (error)
8383
return ERR_PTR(error);
@@ -88,11 +88,11 @@ void arch_dma_clear_uncached(void *cpu_addr, size_t size)
8888
{
8989
unsigned long va = (unsigned long)cpu_addr;
9090

91-
mmap_read_lock(&init_mm);
91+
mmap_write_lock(&init_mm);
9292
/* walk_page_range shouldn't be able to fail here */
93-
WARN_ON(walk_page_range(&init_mm, va, va + size,
94-
&clear_nocache_walk_ops, NULL));
95-
mmap_read_unlock(&init_mm);
93+
WARN_ON(walk_page_range_novma(&init_mm, va, va + size,
94+
&clear_nocache_walk_ops, NULL, NULL));
95+
mmap_write_unlock(&init_mm);
9696
}
9797

9898
void arch_sync_dma_for_device(phys_addr_t addr, size_t size,

0 commit comments

Comments
 (0)