# git gc Expanding reachable commits in commit graph: 51120 Expanding reachable commits in commit graph: 106258 Expanding reachable commits in commit graph: 160203 Expanding reachable commits in commit graph: 216632 Expanding reachable commits in commit graph: 269472 Expanding reachable commits in commit graph: 327337 Expanding reachable commits in commit graph: 385250 Expanding reachable commits in commit graph: 442877 Expanding reachable commits in commit graph: 502112 Expanding reachable commits in commit graph: 552847 Expanding reachable commits in commit graph: 613105 Expanding reachable commits in commit graph: 675351 Expanding reachable commits in commit graph: 737489 Expanding reachable commits in commit graph: 801255 Expanding reachable commits in commit graph: 865570 Expanding reachable commits in commit graph: 931234 Expanding reachable commits in commit graph: 998340 Expanding reachable commits in commit graph: 1054839 Expanding reachable commits in commit graph: 1113979 Expanding reachable commits in commit graph: 1184757 Expanding reachable commits in commit graph: 1256308 Expanding reachable commits in commit graph: 1309149, done. Finding extra edges in commit graph: 44% (576450/1309149) Finding extra edges in commit graph: 45% (589118/1309149) Finding extra edges in commit graph: 46% (602209/1309149) Finding extra edges in commit graph: 47% (615301/1309149) Finding extra edges in commit graph: 48% (628392/1309149) Finding extra edges in commit graph: 49% (641484/1309149) Finding extra edges in commit graph: 50% (654575/1309149) Finding extra edges in commit graph: 51% (667666/1309149) Finding extra edges in commit graph: 52% (680758/1309149) Finding extra edges in commit graph: 53% (693849/1309149) Finding extra edges in commit graph: 54% (706941/1309149) Finding extra edges in commit graph: 55% (720032/1309149) Finding extra edges in commit graph: 56% (733124/1309149) Finding extra edges in commit graph: 57% (746215/1309149) Finding extra edges in commit graph: 58% (759307/1309149) Finding extra edges in commit graph: 59% (772398/1309149) Finding extra edges in commit graph: 60% (785490/1309149) Finding extra edges in commit graph: 61% (798581/1309149) Finding extra edges in commit graph: 62% (811673/1309149) Finding extra edges in commit graph: 63% (824764/1309149) Finding extra edges in commit graph: 64% (837856/1309149) Finding extra edges in commit graph: 65% (850947/1309149) Finding extra edges in commit graph: 66% (864039/1309149) Finding extra edges in commit graph: 67% (877130/1309149) Finding extra edges in commit graph: 68% (890222/1309149) Finding extra edges in commit graph: 69% (903313/1309149) Finding extra edges in commit graph: 70% (916405/1309149) Finding extra edges in commit graph: 71% (929496/1309149) Finding extra edges in commit graph: 72% (942588/1309149) Finding extra edges in commit graph: 73% (955679/1309149) Finding extra edges in commit graph: 74% (968771/1309149) Finding extra edges in commit graph: 75% (981862/1309149) Finding extra edges in commit graph: 76% (994954/1309149) Finding extra edges in commit graph: 77% (1008045/1309149) Finding extra edges in commit graph: 78% (1021137/1309149) Finding extra edges in commit graph: 79% (1034228/1309149) Finding extra edges in commit graph: 80% (1047320/1309149) Finding extra edges in commit graph: 81% (1060411/1309149) Finding extra edges in commit graph: 82% (1073503/1309149) Finding extra edges in commit graph: 83% (1086594/1309149) Finding extra edges in commit graph: 84% (1099686/1309149) Finding extra edges in commit graph: 85% (1112777/1309149) Finding extra edges in commit graph: 86% (1125869/1309149) Finding extra edges in commit graph: 87% (1138960/1309149) Finding extra edges in commit graph: 88% (1152052/1309149) Finding extra edges in commit graph: 89% (1165143/1309149) Finding extra edges in commit graph: 90% (1178235/1309149) Finding extra edges in commit graph: 91% (1191326/1309149) Finding extra edges in commit graph: 92% (1204418/1309149) Finding extra edges in commit graph: 93% (1217509/1309149) Finding extra edges in commit graph: 94% (1230601/1309149) Finding extra edges in commit graph: 95% (1243692/1309149) Finding extra edges in commit graph: 96% (1256784/1309149) Finding extra edges in commit graph: 97% (1269875/1309149) Finding extra edges in commit graph: 98% (1282967/1309149) Finding extra edges in commit graph: 99% (1296058/1309149) Finding extra edges in commit graph: 100% (1309149/1309149) Finding extra edges in commit graph: 100% (1309149/1309149), done. Writing out commit graph in 4 passes: 54% (2847756/5236596) Writing out commit graph in 4 passes: 55% (2880128/5236596) Writing out commit graph in 4 passes: 56% (2932494/5236596) Writing out commit graph in 4 passes: 57% (2984860/5236596) Writing out commit graph in 4 passes: 58% (3037226/5236596) Writing out commit graph in 4 passes: 59% (3089592/5236596) Writing out commit graph in 4 passes: 60% (3141958/5236596) Writing out commit graph in 4 passes: 60% (3175725/5236596) Writing out commit graph in 4 passes: 61% (3194324/5236596) Writing out commit graph in 4 passes: 62% (3246690/5236596) Writing out commit graph in 4 passes: 63% (3299056/5236596) Writing out commit graph in 4 passes: 64% (3351422/5236596) Writing out commit graph in 4 passes: 65% (3403788/5236596) Writing out commit graph in 4 passes: 66% (3456154/5236596) Writing out commit graph in 4 passes: 66% (3503984/5236596) Writing out commit graph in 4 passes: 67% (3508520/5236596) Writing out commit graph in 4 passes: 68% (3560886/5236596) Writing out commit graph in 4 passes: 69% (3613252/5236596) Writing out commit graph in 4 passes: 70% (3665618/5236596) Writing out commit graph in 4 passes: 71% (3717984/5236596) Writing out commit graph in 4 passes: 72% (3770350/5236596) Writing out commit graph in 4 passes: 73% (3822716/5236596) Writing out commit graph in 4 passes: 73% (3832226/5236596) Writing out commit graph in 4 passes: 74% (3875082/5236596) Writing out commit graph in 4 passes: 75% (3927447/5236596) Writing out commit graph in 4 passes: 76% (3979813/5236596) Writing out commit graph in 4 passes: 77% (4032179/5236596) Writing out commit graph in 4 passes: 78% (4084545/5236596) Writing out commit graph in 4 passes: 79% (4136911/5236596) Writing out commit graph in 4 passes: 80% (4189277/5236596) Writing out commit graph in 4 passes: 81% (4241643/5236596) Writing out commit graph in 4 passes: 82% (4294009/5236596) Writing out commit graph in 4 passes: 83% (4346375/5236596) Writing out commit graph in 4 passes: 84% (4398741/5236596) Writing out commit graph in 4 passes: 85% (4451107/5236596) Writing out commit graph in 4 passes: 86% (4503473/5236596) Writing out commit graph in 4 passes: 87% (4555839/5236596) Writing out commit graph in 4 passes: 88% (4608205/5236596) Writing out commit graph in 4 passes: 89% (4660571/5236596) Writing out commit graph in 4 passes: 90% (4712937/5236596) Writing out commit graph in 4 passes: 91% (4765303/5236596) Writing out commit graph in 4 passes: 92% (4817669/5236596) Writing out commit graph in 4 passes: 93% (4870035/5236596) Writing out commit graph in 4 passes: 94% (4922401/5236596) Writing out commit graph in 4 passes: 95% (4974767/5236596) Writing out commit graph in 4 passes: 96% (5027133/5236596) Writing out commit graph in 4 passes: 97% (5079499/5236596) Writing out commit graph in 4 passes: 98% (5131865/5236596) Writing out commit graph in 4 passes: 99% (5184231/5236596) Writing out commit graph in 4 passes: 100% (5236596/5236596) Writing out commit graph in 4 passes: 100% (5236596/5236596), done. # git rev-parse -q --verify a373830f96db288a3eb43a8692b6bcd0bd88dfe1^{commit} a373830f96db288a3eb43a8692b6bcd0bd88dfe1 already have revision, skipping fetch # git checkout -q -f -B kisskb a373830f96db288a3eb43a8692b6bcd0bd88dfe1 # git clean -qxdf # < git log -1 # commit a373830f96db288a3eb43a8692b6bcd0bd88dfe1 # Author: Gautam Menghani # Date: Mon Oct 28 14:34:09 2024 +0530 # # KVM: PPC: Book3S HV: Mask off LPCR_MER for a vCPU before running it to avoid spurious interrupts # # Running a L2 vCPU (see [1] for terminology) with LPCR_MER bit set and no # pending interrupts results in that L2 vCPU getting an infinite flood of # spurious interrupts. The 'if check' in kvmhv_run_single_vcpu() sets the # LPCR_MER bit if there are pending interrupts. # # The spurious flood problem can be observed in 2 cases: # 1. Crashing the guest while interrupt heavy workload is running # a. Start a L2 guest and run an interrupt heavy workload (eg: ipistorm) # b. While the workload is running, crash the guest (make sure kdump # is configured) # c. Any one of the vCPUs of the guest will start getting an infinite # flood of spurious interrupts. # # 2. Running LTP stress tests in multiple guests at the same time # a. Start 4 L2 guests. # b. Start running LTP stress tests on all 4 guests at same time. # c. In some time, any one/more of the vCPUs of any of the guests will # start getting an infinite flood of spurious interrupts. # # The root cause of both the above issues is the same: # 1. A NMI is sent to a running vCPU that has LPCR_MER bit set. # 2. In the NMI path, all registers are refreshed, i.e, H_GUEST_GET_STATE # is called for all the registers. # 3. When H_GUEST_GET_STATE is called for LPCR, the vcpu->arch.vcore->lpcr # of that vCPU at L1 level gets updated with LPCR_MER set to 1, and this # new value is always used whenever that vCPU runs, regardless of whether # there was a pending interrupt. # 4. Since LPCR_MER is set, the vCPU in L2 always jumps to the external # interrupt handler, and this cycle never ends. # # Fix the spurious flood by masking off the LPCR_MER bit before running a # L2 vCPU to ensure that it is not set if there are no pending interrupts. # # [1] Terminology: # 1. L0 : PAPR hypervisor running in HV mode # 2. L1 : Linux guest (logical partition) running on top of L0 # 3. L2 : KVM guest running on top of L1 # # Fixes: ec0f6639fa88 ("KVM: PPC: Book3S HV nestedv2: Ensure LPCR_MER bit is passed to the L0") # Cc: stable@vger.kernel.org # v6.8+ # Signed-off-by: Gautam Menghani # Signed-off-by: Madhavan Srinivasan # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux-gcc --version # < /opt/cross/kisskb/korg/gcc-8.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux-ld --version # < git log --format=%s --max-count=1 a373830f96db288a3eb43a8692b6bcd0bd88dfe1 # make -s -j 24 ARCH=powerpc O=/kisskb/build/powerpc-fixes_corenet64_smp_defconfig_powerpc-gcc8.1 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux- corenet64_smp_defconfig Using /kisskb/src/arch/powerpc/configs/corenet_base.config as base Merging /kisskb/src/arch/powerpc/configs/85xx-64bit.config Merging /kisskb/src/arch/powerpc/configs/85xx-smp.config Merging /kisskb/src/arch/powerpc/configs/altivec.config Merging /kisskb/src/arch/powerpc/configs/85xx-hw.config Merging /kisskb/src/arch/powerpc/configs/fsl-emb-nonhw.config Merging /kisskb/src/arch/powerpc/configs/dpaa.config # # merged configuration written to .config (needs make) # # < make -s -j 24 ARCH=powerpc O=/kisskb/build/powerpc-fixes_corenet64_smp_defconfig_powerpc-gcc8.1 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux- help # make -s -j 24 ARCH=powerpc O=/kisskb/build/powerpc-fixes_corenet64_smp_defconfig_powerpc-gcc8.1 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux- olddefconfig # make -s -j 24 ARCH=powerpc O=/kisskb/build/powerpc-fixes_corenet64_smp_defconfig_powerpc-gcc8.1 CROSS_COMPILE=/opt/cross/kisskb/korg/gcc-8.1.0-nolibc/powerpc64-linux/bin/powerpc64-linux- Completed OK # rm -rf /kisskb/build/powerpc-fixes_corenet64_smp_defconfig_powerpc-gcc8.1 # Build took: 0:10:53.165442