From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 060D92FB2 for ; Fri, 25 Jun 2021 17:01:56 +0000 (UTC) Received: from zn.tnic (p200300ec2f0dae00689ae3531874a6f6.dip0.t-ipconnect.de [IPv6:2003:ec:2f0d:ae00:689a:e353:1874:a6f6]) (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 4E9001EC059E; Fri, 25 Jun 2021 19:01:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1624640515; 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=pu13lrRI0VXpD1HEqkvclBljYf9ytk96hnSQt+aGmXw=; b=H1Yh4uzkPMKaMMOc+J9XbxrYO+z86o2WWlQVVxl82WbgjTqaiX3mkttyZllUnBddq7N0N5 Ukg5SxlpmjgUH+BM5DHkGprnwGt82c60n9RwtC8HblbAy8IVmFIKukkbfNCcCN5GRRyjPm wkzuNTYqCqf0MUdFLijx97OgboDYlW8= Date: Fri, 25 Jun 2021 19:01:54 +0200 From: Borislav Petkov To: Brijesh Singh Cc: Michael Roth , "Kuppuswamy, Sathyanarayanan" , Dave Hansen , x86@kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-efi@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-coco@lists.linux.dev, linux-mm@kvack.org, linux-crypto@vger.kernel.org, Thomas Gleixner , Ingo Molnar , Joerg Roedel , Tom Lendacky , "H. Peter Anvin" , Ard Biesheuvel , Paolo Bonzini , Sean Christopherson , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Andy Lutomirski , Sergio Lopez , Peter Gonda , Peter Zijlstra , Srinivas Pandruvada , David Rientjes , tony.luck@intel.com, npmccallum@redhat.com Subject: Re: [PATCH Part1 RFC v3 20/22] x86/boot: Add Confidential Computing address to setup_header Message-ID: References: <162442264313.98837.16983159316116149849@amd.com> <20210624031911.eznpkbgjt4e445xj@amd.com> <20210624123447.zbfkohbtdusey66w@amd.com> <20210624141111.pzvb6gk5lzfelx26@amd.com> <8faad91a-f229-dee3-0e1f-0b613596db17@amd.com> Precedence: bulk X-Mailing-List: linux-coco@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <8faad91a-f229-dee3-0e1f-0b613596db17@amd.com> On Fri, Jun 25, 2021 at 10:24:01AM -0500, Brijesh Singh wrote: > In the case of EFI, the CC blob structure is dynamically allocated > and passed through the EFI configuration table. The grub will not > know what value to pass in the cmdline unless we improve it to read > the EFI configuration table and rebuild the cmdline. Or simply parse the EFI table. To repeat my question: why do you need the CC blob in the boot kernel? Then, how does it work then in the !EFI case? The script glue that starts the lightweight container goes and "prepares" that blob and passes it to guest kernel? In which case setup_data should do the job, methinks. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette 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=-5.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, 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 F2A2CC49EAB for ; Fri, 25 Jun 2021 17:01:58 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D73D461954 for ; Fri, 25 Jun 2021 17:01:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229697AbhFYRES (ORCPT ); Fri, 25 Jun 2021 13:04:18 -0400 Received: from mail.skyhub.de ([5.9.137.197]:47780 "EHLO mail.skyhub.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229630AbhFYRER (ORCPT ); Fri, 25 Jun 2021 13:04:17 -0400 Received: from zn.tnic (p200300ec2f0dae00689ae3531874a6f6.dip0.t-ipconnect.de [IPv6:2003:ec:2f0d:ae00:689a:e353:1874:a6f6]) (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 4E9001EC059E; Fri, 25 Jun 2021 19:01:55 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1624640515; 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=pu13lrRI0VXpD1HEqkvclBljYf9ytk96hnSQt+aGmXw=; b=H1Yh4uzkPMKaMMOc+J9XbxrYO+z86o2WWlQVVxl82WbgjTqaiX3mkttyZllUnBddq7N0N5 Ukg5SxlpmjgUH+BM5DHkGprnwGt82c60n9RwtC8HblbAy8IVmFIKukkbfNCcCN5GRRyjPm wkzuNTYqCqf0MUdFLijx97OgboDYlW8= Date: Fri, 25 Jun 2021 19:01:54 +0200 From: Borislav Petkov To: Brijesh Singh Cc: Michael Roth , "Kuppuswamy, Sathyanarayanan" , Dave Hansen , x86@kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-efi@vger.kernel.org, platform-driver-x86@vger.kernel.org, linux-coco@lists.linux.dev, linux-mm@kvack.org, linux-crypto@vger.kernel.org, Thomas Gleixner , Ingo Molnar , Joerg Roedel , Tom Lendacky , "H. Peter Anvin" , Ard Biesheuvel , Paolo Bonzini , Sean Christopherson , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Andy Lutomirski , Sergio Lopez , Peter Gonda , Peter Zijlstra , Srinivas Pandruvada , David Rientjes , tony.luck@intel.com, npmccallum@redhat.com Subject: Re: [PATCH Part1 RFC v3 20/22] x86/boot: Add Confidential Computing address to setup_header Message-ID: References: <162442264313.98837.16983159316116149849@amd.com> <20210624031911.eznpkbgjt4e445xj@amd.com> <20210624123447.zbfkohbtdusey66w@amd.com> <20210624141111.pzvb6gk5lzfelx26@amd.com> <8faad91a-f229-dee3-0e1f-0b613596db17@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <8faad91a-f229-dee3-0e1f-0b613596db17@amd.com> Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Fri, Jun 25, 2021 at 10:24:01AM -0500, Brijesh Singh wrote: > In the case of EFI, the CC blob structure is dynamically allocated > and passed through the EFI configuration table. The grub will not > know what value to pass in the cmdline unless we improve it to read > the EFI configuration table and rebuild the cmdline. Or simply parse the EFI table. To repeat my question: why do you need the CC blob in the boot kernel? Then, how does it work then in the !EFI case? The script glue that starts the lightweight container goes and "prepares" that blob and passes it to guest kernel? In which case setup_data should do the job, methinks. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette