Received: by 2002:a25:d783:0:0:0:0:0 with SMTP id o125csp448309ybg; Thu, 19 Mar 2020 02:43:51 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuutjFOpCcmfQ6g/0Jmgk3N5pxt2SaxVdIjh5cwoUm2FSUrlPE2svbVTXgi1OTcomCbQGAI X-Received: by 2002:aca:dc8b:: with SMTP id t133mr1689945oig.98.1584611031043; Thu, 19 Mar 2020 02:43:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584611031; cv=none; d=google.com; s=arc-20160816; b=U1ZV7o04NuIU2TpkO71aG34PbnfPof5z+PQlKaYU34hB/LZm8h1vKo3PAbf/L9L93j UaTS6RcKEe6nOBgFpxv4nG8diJWdiy3CD8+46kF5/fb/HOqADhuvrHkB97wXNTTAMth+ zRB575uUbQ/i+vINJME/y54KX7Ed3L0QebcbG93Uk5dtgsXbH4oLnOkIVjopJemeG9lu uD09lTTVAuUtF/0F27dYsu2okWjzfOAF5D9cFatY1lpQkFHOUPenYtFDZXuYm3kBQib+ 3pmFoCFllNKrHjJITm9L7B//7u0ZpU0+eBz5F4YxsszePceXkpNerp9gADfBB/slnvhe k39w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:user-agent:message-id:subject:to :from:cc:references:in-reply-to:content-transfer-encoding :mime-version; bh=gnU4qKdx+1mzxl07qxrdk+vTozaACRJswS5w3SlKFcQ=; b=YDNGC61w2hpmK9QU2zyrqCL+fFK2s0d/31YOa+qDvzdcnpTuRDRkzbLP9sx7+I+ZZg K2YBXT22HEfwgyquh5mDT5ESixJ401+ilHpXNhFdoUVBeTtQbFcfj65/XY2tvXBunbLw BK/Kh0vlikGXuoDw27IeR2ghvIs7lp4DeYz22AxDTE/wdOZfTpnB2wHNxYGEy0pWl/pT Zu9HNScJH3ZMSzqbjUPNlfr1JEZF0O1Npd8aZBvnFri5ZDxneRhUm6k/Rd3dkVL1G/EH dLJA8gT0NGYUr7Q0bHMwaTSfbEkttODq0BkJEojDRcGDKiaaua3PR24FugGRTSleUGfO TTRg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id p203si807819oic.214.2020.03.19.02.43.37; Thu, 19 Mar 2020 02:43:51 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726901AbgCSJmT convert rfc822-to-8bit (ORCPT + 99 others); Thu, 19 Mar 2020 05:42:19 -0400 Received: from mail.fireflyinternet.com ([109.228.58.192]:59068 "EHLO fireflyinternet.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1725887AbgCSJmT (ORCPT ); Thu, 19 Mar 2020 05:42:19 -0400 X-Default-Received-SPF: pass (skip=forwardok (res=PASS)) x-ip-name=78.156.65.138; Received: from localhost (unverified [78.156.65.138]) by fireflyinternet.com (Firefly Internet (M1)) with ESMTP (TLS) id 20613568-1500050 for multiple; Thu, 19 Mar 2020 09:42:12 +0000 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8BIT In-Reply-To: <20200317103307.316400146@linuxfoundation.org> References: <20200317103259.744774526@linuxfoundation.org> <20200317103307.316400146@linuxfoundation.org> Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Bhupesh Sharma , Matt Fleming , Sai Praneeth Prakhya , Ard Biesheuvel , Wen Yang , Caspar Zhang From: Chris Wilson To: Greg Kroah-Hartman , linux-kernel@vger.kernel.org Subject: Re: [PATCH 4.19 64/89] efi: Make efi_rts_work accessible to efi page fault handler Message-ID: <158461093093.6873.1396457313254708957@build.alporthouse.com> User-Agent: alot/0.8.1 Date: Thu, 19 Mar 2020 09:42:10 +0000 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Quoting Greg Kroah-Hartman (2020-03-17 10:55:13) > From: Sai Praneeth > > commit 9dbbedaa6171247c4c7c40b83f05b200a117c2e0 upstream. > > After the kernel has booted, if any accesses by firmware causes a page > fault, the efi page fault handler would freeze efi_rts_wq and schedules > a new process. To do this, the efi page fault handler needs > efi_rts_work. Hence, make it accessible. > > There will be no race conditions in accessing this structure, because > all the calls to efi runtime services are already serialized. > > Tested-by: Bhupesh Sharma > Suggested-by: Matt Fleming > Based-on-code-from: Ricardo Neri > Signed-off-by: Sai Praneeth Prakhya > Signed-off-by: Ard Biesheuvel > Fixes: 3eb420e70d87 (“efi: Use a work queue to invoke EFI Runtime Services”) > Signed-off-by: Wen Yang > Cc: Caspar Zhang > Signed-off-by: Greg Kroah-Hartman This requires the fix from commit ef1491e791308317bb9851a0ad380c4a68b58d54 Author: Waiman Long Date: Wed Nov 14 09:55:40 2018 -0800 efi: Fix debugobjects warning on 'efi_rts_work' The following commit: 9dbbedaa6171 ("efi: Make efi_rts_work accessible to efi page fault handler") converted 'efi_rts_work' from an auto variable to a global variable. However, when submitting the work, INIT_WORK_ONSTACK() was still used, causing the following complaint from debugobjects: ODEBUG: object 00000000ed27b500 is NOT on stack 00000000c7d38760, but annotated. Change the macro to just INIT_WORK() to eliminate the warning. Signed-off-by: Waiman Long Signed-off-by: Ard Biesheuvel Acked-by: Sai Praneeth Prakhya Cc: Linus Torvalds Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: linux-efi@vger.kernel.org Fixes: 9dbbedaa6171 ("efi: Make efi_rts_work accessible to efi page fault handler") Link: http://lkml.kernel.org/r/20181114175544.12860-2-ard.biesheuvel@linaro.org Signed-off-by: Ingo Molnar