From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 918A4C433DF for ; Mon, 24 Aug 2020 16:16:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5D3FE20838 for ; Mon, 24 Aug 2020 16:16:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1598285813; bh=sVMIt4NTydSHDJbd1pZCbQ3XabwLEdzIA0ymX2MLdLk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:List-ID:From; b=bnwdKhcQuCQIERzNDmMDK5NqP18BQuwXqK4FpTjOHlEuIv7osmzudZYjo+wFNE6BP Gj5ngreo74fraNXKUxcqTpmLrobVzlLCgWwoVCVkIX800xRfuS0PsksknGo2BBPNSu 8omIPMXKxTjvszpLlb6qKGTpRFfBMK9xzXIi1hHk= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727036AbgHXQQw (ORCPT ); Mon, 24 Aug 2020 12:16:52 -0400 Received: from mail.kernel.org ([198.145.29.99]:53772 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725963AbgHXQQk (ORCPT ); Mon, 24 Aug 2020 12:16:40 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C68AD20838; Mon, 24 Aug 2020 16:16:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1598285800; bh=sVMIt4NTydSHDJbd1pZCbQ3XabwLEdzIA0ymX2MLdLk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=ag88bNqU15b7HjHbHyC63fLBjAE57kPfVIbO9ANW5jawUJxZNIytank8MvdI1zFYC d/iw8fmdkqi88Lq1Pjv5sd0QD3ePFxzMY02q3ufJwON9RK5+1rQMzvYtfJ2uI1vk0k YjwUwoLaPJERrsjcJ/zz6U1uPiA7YXhtr5m0yPks= Date: Mon, 24 Aug 2020 18:16:50 +0200 From: Greg KH To: Will Deacon Cc: linux-kernel@vger.kernel.org, maz@kernel.org, suzuki.poulose@arm.com, james.morse@arm.com, pbonzini@redhat.com, kernel-team@android.com, stable@vger.kernel.org Subject: Re: [PATCH stable-4.4.y backport] KVM: arm/arm64: Don't reschedule in unmap_stage2_range() Message-ID: <20200824161650.GF435319@kroah.com> References: <20200824112854.24651-1-will@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200824112854.24651-1-will@kernel.org> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Aug 24, 2020 at 12:28:54PM +0100, Will Deacon wrote: > Upstream commits fdfe7cbd5880 ("KVM: Pass MMU notifier range flags to > kvm_unmap_hva_range()") and b5331379bc62 ("KVM: arm64: Only reschedule > if MMU_NOTIFIER_RANGE_BLOCKABLE is not set") fix a "sleeping from invalid > context" BUG caused by unmap_stage2_range() attempting to reschedule when > called on the OOM path. > > Unfortunately, these patches rely on the MMU notifier callback being > passed knowledge about whether or not blocking is permitted, which was > introduced in 4.19. Rather than backport this considerable amount of > infrastructure just for KVM on arm, instead just remove the conditional > reschedule. > > Cc: # v4.4 only > Cc: Marc Zyngier > Cc: Suzuki K Poulose > Cc: James Morse > Signed-off-by: Will Deacon Thanks for tall the backports, now queued up. greg k-h