Message ID | 1719903369-35385-1-git-send-email-zhang.chuna@h3c.com (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | mm: fix kmap_high deadlock V2 | expand |
… > this is some deadlock condition. I think it's necessary to give > kmap_lock before call flush_tlb_kernel_range. … How do you think about to improve such a change description another bit? https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.10-rc6#n94 Will the tag “Fixes” become relevant here? The version identifier should be specified at an other place in the message subject. https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/Documentation/process/submitting-patches.rst?h=v6.10-rc6#n668 Regards, Markus
diff --git a/mm/highmem.c b/mm/highmem.c index bd48ba4..841b370 100644 --- a/mm/highmem.c +++ b/mm/highmem.c @@ -220,8 +220,11 @@ static void flush_all_zero_pkmaps(void) set_page_address(page, NULL); need_flush = 1; } - if (need_flush) + if (need_flush) { + spin_unlock(&kmap_lock); flush_tlb_kernel_range(PKMAP_ADDR(0), PKMAP_ADDR(LAST_PKMAP)); + spin_lock(&kmap_lock); + } } void __kmap_flush_unused(void)