lkml.org 
[lkml]   [2021]   [Jan]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch V3 13/37] mips/mm/highmem: Switch to generic kmap atomic
Hi Thomas,

Le sam. 9 janv. 2021 à 1:33, Thomas Bogendoerfer
<tsbogend@alpha.franken.de> a écrit :
> On Sat, Jan 09, 2021 at 12:58:05AM +0100, Thomas Bogendoerfer wrote:
>> On Fri, Jan 08, 2021 at 08:20:43PM +0000, Paul Cercueil wrote:
>> > Hi Thomas,
>> >
>> > 5.11 does not boot anymore on Ingenic SoCs, I bisected it to this
>> commit.
>> >
>> > Any idea what could be happening?
>>
>> not yet, kernel crash log of a Malta QEMU is below.
>
> update:
>
> This dirty hack lets the Malta QEMU boot again:
>
> diff --git a/mm/highmem.c b/mm/highmem.c
> index c3a9ea7875ef..190cdda1149d 100644
> --- a/mm/highmem.c
> +++ b/mm/highmem.c
> @@ -515,7 +515,7 @@ void *__kmap_local_pfn_prot(unsigned long pfn,
> pgprot_t prot)
> vaddr = __fix_to_virt(FIX_KMAP_BEGIN + idx);
> BUG_ON(!pte_none(*(kmap_pte - idx)));
> pteval = pfn_pte(pfn, prot);
> - set_pte_at(&init_mm, vaddr, kmap_pte - idx, pteval);
> + set_pte(kmap_pte - idx, pteval);
> arch_kmap_local_post_map(vaddr, pteval);
> current->kmap_ctrl.pteval[kmap_local_idx()] = pteval;
> preempt_enable();
>
> set_pte_at() tries to update cache and could do an kmap_atomic()
> there.
> Not sure, if this is allowed at this point.

Yes, I can confirm that your workaround works here too.

Cheers,
-Paul


\
 
 \ /
  Last update: 2021-01-10 12:37    [W:0.085 / U:1.456 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site