Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp173015pxb; Wed, 20 Jan 2021 04:17:47 -0800 (PST) X-Google-Smtp-Source: ABdhPJxPA19LJvQeG2h5JO2oz0DchrIL4aZj2C2Ip2C+Isknm9B0od4w9Nb/MJzZwjvCSAU1dMhA X-Received: by 2002:aa7:cad5:: with SMTP id l21mr6215672edt.96.1611145067780; Wed, 20 Jan 2021 04:17:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611145067; cv=none; d=google.com; s=arc-20160816; b=visz3Sy4fmiifg8gvUEhzM5J8NevVyHaY9YotMk1O00oxR/C/I4s8rLoNXtqoNV74F OcC9ZUJEs/MbcYSYk0MlA59BcF3iTkFpXviyqPwbnWODBVFqW1OOojlTsdj4ASWMQQb4 AGR5eN7CuGTr87m991Hm6TyaveUKqsoxU2NbGANViOOw+0XCHJA3Y5nzFhqzGH+nGSQq 4b9mr+XPfweqKDUWw+ZPY6ayu8qgz0ByUkBwabjohRXy3XryOaKQhw8JOB4fO15FxgfR 5tdudTqemqR24A5nGLnmkxjctsuVZ22Sdnum5oiN+47A+HH+9zAKAF7/nlKZJAxYPVIr etkQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=20LzYZPoh99oMXgfw4CHHwaH/q6GrOZfZD3z4Nnb0wg=; b=Bi5S9rd2RQodUfLmWT7msSbD+zELq2Gl85Gkp0cCXCnGKmgI1I+EwingPCdjptVvKR o9277Ac2qwwLY4PuivCiKw8v5NJOJY/6s4pZ6rCjvJdtrfwlEY6rGu4K/F5/gn8n/BNs uz/dk83M0N91unamF2HeSR8pYd1MWwEMbl7pbIVnyeZdp7id78IGmv5dqSG7hjTlWfIn QueMdzUfXc9rKdDg0pwolwDrs0hZWLIGSmn4U8ll3Y4QjIzj7pxR9zyvI5vqXv9OmjGQ 8aBoo0VN/Y+EyYGzdlzWnu4RtIlPpzOxA4VaZ+qUnhS2gGOeQVKnKuKoScNu+gxjXAkJ 5Eng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=E2E7ATLf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i7si795602edg.300.2021.01.20.04.17.22; Wed, 20 Jan 2021 04:17:47 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=E2E7ATLf; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2389431AbhATMPm (ORCPT + 99 others); Wed, 20 Jan 2021 07:15:42 -0500 Received: from mail.skyhub.de ([5.9.137.197]:45150 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388715AbhATLp3 (ORCPT ); Wed, 20 Jan 2021 06:45:29 -0500 Received: from zn.tnic (p200300ec2f0bb0007fac97ee58c503f0.dip0.t-ipconnect.de [IPv6:2003:ec:2f0b:b000:7fac:97ee:58c5:3f0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 570471EC046E; Wed, 20 Jan 2021 12:44:44 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1611143084; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=20LzYZPoh99oMXgfw4CHHwaH/q6GrOZfZD3z4Nnb0wg=; b=E2E7ATLf7PM0xDk7VFGsC6LxaCDqpTk3/0jmeLtCJRUuWShS5yavgB3rAPVCug/oo+ImsB L6SHAbHQ5zcrqFw5h2IhN5QsZ+AojeGeadBBHW92tAQYfgt2hPULXuYXsJzlpI5Ep/5qia nQ1kpdrk2Y5BIsKRUOm39J/CHZZpmO4= Date: Wed, 20 Jan 2021 12:44:38 +0100 From: Borislav Petkov To: Ard Biesheuvel Cc: Arvind Sankar , Arnd Bergmann , Thomas Gleixner , Ingo Molnar , X86 ML , Nathan Chancellor , Nick Desaulniers , Arnd Bergmann , Darren Hart , Andy Shevchenko , "H. Peter Anvin" , linux-efi , platform-driver-x86@vger.kernel.org, Linux Kernel Mailing List , clang-built-linux , "Kirill A. Shutemov" Subject: Re: [PATCH] x86: efi: avoid BUILD_BUG_ON() for non-constant p4d_index Message-ID: <20210120114438.GD825@zn.tnic> References: <20210107223424.4135538-1-arnd@kernel.org> <20210118202409.GG30090@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 20, 2021 at 10:33:43AM +0100, Ard Biesheuvel wrote: > The churn doesn't seem to be worth it, tbh. > > So could we get rid of the complexity here, and only build_bug() on > the start address of the EFI region being outside the topmost p4d? > That should make the PGD test redundant as well. Yah, makes sense to me. Thx. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette