Re: [PATCH] random: Fix kernel panic due to system_wq use before init

From: Matt Fleming
Date: Mon Sep 19 2016 - 05:25:52 EST


On Sun, 18 Sep, at 11:09:08PM, Waiman Long wrote:
>
> I have finally finished bisecting the problem. I was wrong in saying that
> the 4.7.3 kernel had no problem. It did have. There were some slight
> differences between the 4.8 and 4.7 kernel config files that I used. After
> some further testing, it was found that the bootup problem only happened
> when the following kernel config option was defined:
>
> CONFIG_EFI_MIXED=y
>
> Bisecting reviewed that the following 4.6 patch was the first patch that had
> this problem:
>
> c9f2a9a65e4855b74d92cdad688f6ee4a1a323ff
> [PATCH] x86/efi: Hoist page table switching code into efi_call_virt()
>
> I did testing on my test system with three different partition sizes:
> 1) 16-socket Broadwell-EX with 12TB memory
> 2) 8-socket Broadwell-EX with 6TB memory
> 3) 4-socket Broadwell-EX with 3TB memory
>
> Only the 16-socket and 8-socket configurations had this problem. I am not
> sure if over 4TB of main memory is a factor or not.

Yes, I think it's a safe bet that the amount of main memory is a major
factor here. Thanks for the report.

The only real difference when CONFIG_EFI_MIXED is enabled for 64-bit
kernel and 64-bit firmware is that main memory will be mapped into the
EFI page tables at its physical addresses.

I'll go stare at the code and get back to you.