Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp2653139pxk; Sun, 4 Oct 2020 07:15:55 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwNulacxdfVgYZEh18olQmL6wf4DzdzoFkpln2Y40j4WoUJNhbXNDojGC4/r5oK3nbcBCU6 X-Received: by 2002:a50:8fa3:: with SMTP id y32mr12928443edy.78.1601820955042; Sun, 04 Oct 2020 07:15:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601820955; cv=none; d=google.com; s=arc-20160816; b=dAr9WZObMnjUCxIXX/78Ns0jtkYBg1BomIa/Gm3KQ5ZWviOSfXw1fYoj7NwDmFIEh0 5zXccOezy5GXAYwFcqXuoHONy0uqPDQW92GgWjAhEGGDrpeMTR/IM7OnLp9dv/aqprUl 1Q0vMxKXdWWVJF5ECUwXUtOnsl9AU9g0tZzu7oU4DIynGswF5BHrQgf+hTcrNnDFYa36 mxlZIDxYttAj+iZjAymrApoFv2PN7eF3Tl/ZDeWKkaz0Rv74gzElGXPbXPY2q2/v1ydZ BXVUqmEb3ZTnxtKEQQE26z80tqJ3QCz5lTI6uMRk0RMs0S5U/zzDWtTCsCDvjLHOTe/0 Q18g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=gnom5efbHWbWKBMa6PTbz/tVLety5Y13FElXySoeHDY=; b=YsW4Gl/cthEHbkz51qEyr1bO+mdZ/Wrkznboay425IGb1iVp+YcKPmu+TvbHiQexHc w0Ju9gWQOz4aZeHDiW4k9GLOuuvGsKizdDDcMIwcNGSOJFR3K78znamCWXJnwpW+kayn jdcfW+QYqNxV805H8rnInd6PRW8m6vwxSeD+Dg1GnNNqqB15E31jdmk6Kf4vTL6eBR+G k6gYMVe8xtIWwKRmMxT6IV+oegdZ37fv73v+ZGJB8OcVEHwAJBCO5fGQX+0gn1+XdChu vvB9oLlQE7hzrTOrRZCMu1zsEze4igj3ihYIuGXXzfAFTLWnru3RRCgncBmBgHHiFBap QIGQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=P945UFAV; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l12si2055207edi.370.2020.10.04.07.15.31; Sun, 04 Oct 2020 07:15:55 -0700 (PDT) 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=@kernel.org header.s=default header.b=P945UFAV; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725854AbgJDOOX (ORCPT + 99 others); Sun, 4 Oct 2020 10:14:23 -0400 Received: from mail.kernel.org ([198.145.29.99]:53784 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725825AbgJDOOX (ORCPT ); Sun, 4 Oct 2020 10:14:23 -0400 Received: from mail-oi1-f174.google.com (mail-oi1-f174.google.com [209.85.167.174]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9D48120797; Sun, 4 Oct 2020 14:14:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1601820862; bh=BeZ+t1FaWcSp8llMlNWxjq6hsTDD7cM2+51ZXd0TNe0=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=P945UFAVftkGTq4bL2DRzNel4cJkVWsAcj0U6NZ/p0ct7Npzsu/lJrlCsRbtGZZhT p/c9XcxxgyHRfDskTczq+rfvQJEjR2I4PsHSQ9DRC1kQo5l7lQsPNkY2MgXBIylxhN TDCC/zKtxb6P+8zVVBCkUFWTMAKUc1zu4tL0tO0M= Received: by mail-oi1-f174.google.com with SMTP id n2so6184039oij.1; Sun, 04 Oct 2020 07:14:22 -0700 (PDT) X-Gm-Message-State: AOAM530u08PqQ27SmzIAqhzRoh6l50M08TBWlj9CtMj/eYWEjK9umB7L HxOKXsYaLeZpeB7Xnjamy357piwmivmIEHr9/gw= X-Received: by 2002:aca:d845:: with SMTP id p66mr5718315oig.47.1601820861944; Sun, 04 Oct 2020 07:14:21 -0700 (PDT) MIME-Version: 1.0 References: <20201003060356.4913-1-xypron.glpk@gmx.de> <20201003194429.GA768061@rani.riverdale.lan> In-Reply-To: <20201003194429.GA768061@rani.riverdale.lan> From: Ard Biesheuvel Date: Sun, 4 Oct 2020 16:14:11 +0200 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 1/1] efi/libstub/x86: simplify efi_is_native() To: Arvind Sankar Cc: Brian Gerst , Heinrich Schuchardt , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "the arch/x86 maintainers" , "H . Peter Anvin" , linux-efi , Linux Kernel Mailing List Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 3 Oct 2020 at 21:44, Arvind Sankar wrote: > > On Sat, Oct 03, 2020 at 01:28:18PM -0400, Brian Gerst wrote: > > On Sat, Oct 3, 2020 at 2:05 AM Heinrich Schuchardt wrote: > > > > > > CONFIG_EFI_MIXED depends on CONFIG_X86_64=y. > > > There is no need to check CONFIG_X86_64 again. > > > > > > Signed-off-by: Heinrich Schuchardt > > > --- > > > arch/x86/include/asm/efi.h | 2 -- > > > 1 file changed, 2 deletions(-) > > > > > > diff --git a/arch/x86/include/asm/efi.h b/arch/x86/include/asm/efi.h > > > index b9c2667ac46c..ab28bf1c74cf 100644 > > > --- a/arch/x86/include/asm/efi.h > > > +++ b/arch/x86/include/asm/efi.h > > > @@ -223,8 +223,6 @@ static inline bool efi_is_64bit(void) > > > > > > static inline bool efi_is_native(void) > > > { > > > - if (!IS_ENABLED(CONFIG_X86_64)) > > > - return true; > > > return efi_is_64bit(); > > > } > > > > This would then return false for native 32-bit. > > > > -- > > Brian Gerst > > 32-bit doesn't use this implementation: it's #define'd to true in > drivers/firmware/efi/libstub/efistub.h. > Yes, and the reason this [now redundant] test exists is because this did not use to be the case before de8c55208c386 efi/libstub: Fix mixed mode boot issue after macro refactor So for this patch Acked-by: Ard Biesheuvel I'll queue this up