Received: by 2002:a89:413:0:b0:1fd:dba5:e537 with SMTP id m19csp1090711lqs; Fri, 14 Jun 2024 15:00:49 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCXlBmK6Ln5FH7EslcmZ4Hjy68K9uGlJYf8h0/AwkufBZYaEL1oxkAXDeKcdH18sg/fY2EEL5NHFctqQDt2CYKM8ApvO1TGYU8vb5OKacw== X-Google-Smtp-Source: AGHT+IFhEYzJXPQyTPTGsDEwLrtmgRqrl4Y8RpLOW6iHLp2RtEH8QrVPX78E6KouBGvqzTKCr4nT X-Received: by 2002:a05:620a:244f:b0:795:5050:eca8 with SMTP id af79cd13be357-798d242f5cfmr463725385a.40.1718402449456; Fri, 14 Jun 2024 15:00:49 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1718402449; cv=pass; d=google.com; s=arc-20160816; b=sYjYLT6uDGACwmMkoBuyPVTLHugh3wEEj/6DrwnGHnNBkRd44w40sHiLPS9mFvhXBM EKY5y0T/1p8KP6xDWk4P+dMaaGHDYB2S3FE4D8DC8/QicXG4J9DIpE4lLfkRSiZDRtEA ZirRPHcVcDBooL7BQsinRLUiZjJCKH86AsGZVoNvePUBO4Whll6ECuPJklzXOswR4uVY NixZN4HPuOC9HSwtGAo3Gjjz9B8zxDN1clWZhEl9Mysg6fHmN4lYiNPjjJ9V+hoGiaS/ lxpCCJda6ssRLhbz0d5Fr8zQjSYIqLjHAW30eSol1spbVZCMqrlcGOTGUqRpOJjsrVr8 VAfg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:date:message-id :dkim-signature; bh=YICLqeWZ7CPWIj9cycB+v+Sx/kefZlyQDl7Jt1GJ9mk=; fh=KRkJxXDFtTtJcIgN9/2chSJEwSaQuDmxRWS2jtXGbgI=; b=PhmdUvnhkKcQfjLIzNFVLGQfjgVW068EfR0cd4/uVcyAT+09/dO6zQNuap2zISAnQI 9tqrEHmtep+Qt/f8qAIYHxN9BYSIxGncXpc00IcWYdw36W/nAMu7rsC0vTLpdZ0rg4a0 RtOxzfoVVujs+nbrS91tYsYLxV8Wpg2xLh5xhrHK5MZ4Zxa7vpmDgZ9NOdnFnxmCX+ny ulfgWVAqIDOzdtooAUF2jREYEY/E8Lk1kBHHIunNSbDtTWtspfv2PtKbow6KmFl3Cw0Z AmeGa3VNthzJ4JddDEllApzoiBui6032hWk+rsiqYTgXl4Zk+U+RqFlZw0owN2MQoH1b d5Bw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b="fMZ/bdWe"; arc=pass (i=1 dkim=pass dkdomain=broadcom.com dmarc=pass fromdomain=broadcom.com); spf=pass (google.com: domain of linux-kernel+bounces-215510-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-215510-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id af79cd13be357-798ab9f948csi493976785a.316.2024.06.14.15.00.49 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 14 Jun 2024 15:00:49 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-215510-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b="fMZ/bdWe"; arc=pass (i=1 dkim=pass dkdomain=broadcom.com dmarc=pass fromdomain=broadcom.com); spf=pass (google.com: domain of linux-kernel+bounces-215510-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-215510-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id C99691C21B95 for ; Fri, 14 Jun 2024 22:00:48 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 73EE3186E2D; Fri, 14 Jun 2024 22:00:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b="fMZ/bdWe" Received: from mail-qv1-f52.google.com (mail-qv1-f52.google.com [209.85.219.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id F184E149C44 for ; Fri, 14 Jun 2024 22:00:20 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.52 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718402422; cv=none; b=ZBtyTviSwMx+5OWJNr//1BBTe8dJ0FPciT7T2WjnkUVVaKxxHMUax5PfCn633bzhRADFp7aH4kKXUaar9kHEEN6EB3tNrLSztVEqt/yIT5WA2SxNjWIJSjCIswZWDtMZf/QJIcoeRlVAMtW8Qfdb3tihJnLBr9EQxqJs2i92S5Y= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718402422; c=relaxed/simple; bh=+5veQkgnVNkMxA9kgPIirgp7ENT3iYRLPKA4QGYdskE=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=Pqni/d4iV3s71j3yJkx5iSJinmVB1dEtaxj2SnRYtJ2vBw2upUZj03jrSQMKU31sA4xtcY/BP+Eu8WymiErMY7ei1zyRaM2avi/GhLYrLiZb1LvzIkggMrZh4nk3heC3cn/Qkz/NQ6m6BDxho39q7VqCON+c/7+OZfitALwm6l8= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com; spf=fail smtp.mailfrom=broadcom.com; dkim=pass (1024-bit key) header.d=broadcom.com header.i=@broadcom.com header.b=fMZ/bdWe; arc=none smtp.client-ip=209.85.219.52 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=broadcom.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=broadcom.com Received: by mail-qv1-f52.google.com with SMTP id 6a1803df08f44-6b065d12dc6so13320286d6.0 for ; Fri, 14 Jun 2024 15:00:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; t=1718402420; x=1719007220; darn=vger.kernel.org; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:from:to:cc:subject:date:message-id:reply-to; bh=YICLqeWZ7CPWIj9cycB+v+Sx/kefZlyQDl7Jt1GJ9mk=; b=fMZ/bdWeaWA7whE83xnLlOq9RJ6cBRTmRFhpaKzURd2VcVLPh9/oyAltab2a2+v78J dT1hxsuCamWxCGFqxXm6iYlhgC7zSck/2+w2+t2cYaDdTXx6CsPdYNW14kEsw+gLFvP2 6yvkui8SLdhQbrcdSylGTRIsMrg2SRjJL+5c8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718402420; x=1719007220; h=content-transfer-encoding:in-reply-to:autocrypt:from :content-language:references:cc:to:subject:user-agent:mime-version :date:message-id:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=YICLqeWZ7CPWIj9cycB+v+Sx/kefZlyQDl7Jt1GJ9mk=; b=WgzT/lale+rRikBhULSWnqzlrYanf9qorJsZY3n1+NLcX8WUipOlxQDRJ8hu/5h1Rz wF8Ex6F5oBk+mvklWrlUKl4KJXXVj4O5xlVqfbapAWjjRI6qa/xIWURbdnRGkZIueWcV jW6QyQDzPGgThqmUtbbpJMZJ/54UfryubY2dNF1AepKngUAV304Z/8XsW8ghKZUI+E7r evjXEK9eleAvQr1uWYtfIZDVK5MrWkHjHiZXz6O6GG1nlJI9TzMC9l/iI6n90iGhpqJ9 wYRZV1Yr22nQNwe1ManaCmh9ZPpKhe0Jk307tGfSh1loGxSmHmOiAvZdZCdAtj2eWGDk B7uw== X-Forwarded-Encrypted: i=1; AJvYcCV1D314QmmCfK6pvLjo3+dokQilGpvdjU1smBa46ZpTC9A+s44SYJmCKE9jV2sWOcbtF7YAjTBL4580r/jPddfi45H4zjYTThr3G6Vs X-Gm-Message-State: AOJu0YzOHptpcf+I1aFGeLkFXWbnRf/RNqTQyoGuZjsjU2UDQXEgfwKq Gwy/ItGqEaWvkceoE4UfFtJZxyGPwKvQVFip8JnT4P1+EKX+NFWD6cOe6Z3D0g== X-Received: by 2002:a0c:d6c7:0:b0:6b2:b251:7d95 with SMTP id 6a1803df08f44-6b2b2517db4mr30028326d6.17.1718402419852; Fri, 14 Jun 2024 15:00:19 -0700 (PDT) Received: from [10.66.192.68] ([192.19.161.250]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6b2a5f05782sm23013906d6.139.2024.06.14.15.00.14 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Fri, 14 Jun 2024 15:00:19 -0700 (PDT) Message-ID: Date: Fri, 14 Jun 2024 15:00:12 -0700 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v11 8/8] x86/vmware: Add TDX hypercall support To: Borislav Petkov Cc: Dave Hansen , linux-kernel@vger.kernel.org, virtualization@lists.linux.dev, hpa@zytor.com, dave.hansen@linux.intel.com, mingo@redhat.com, tglx@linutronix.de, x86@kernel.org, netdev@vger.kernel.org, richardcochran@gmail.com, linux-input@vger.kernel.org, dmitry.torokhov@gmail.com, zackr@vmware.com, linux-graphics-maintainer@vmware.com, pv-drivers@vmware.com, timothym@vmware.com, akaher@vmware.com, dri-devel@lists.freedesktop.org, daniel@ffwll.ch, airlied@gmail.com, tzimmermann@suse.de, mripard@kernel.org, maarten.lankhorst@linux.intel.com, horms@kernel.org, kirill.shutemov@linux.intel.com, Tim Merrifield References: <20240613191650.9913-1-alexey.makhalov@broadcom.com> <20240613191650.9913-9-alexey.makhalov@broadcom.com> <844ef200-aabe-4497-85c9-44fc46c9133a@intel.com> <20240614161404.GCZmxsTNLSoYTqoRoj@fat_crate.local> <74f8300b-3520-4824-81e3-71464e3da3b6@intel.com> <1750e44f-f9a9-4c2a-afb3-f1ae8237ccb0@broadcom.com> <20240614190956.GFZmyVhLGeyLjwvA6X@fat_crate.local> Content-Language: en-US From: Alexey Makhalov Autocrypt: addr=alexey.makhalov@broadcom.com; keydata= xsFNBGVo9lkBEACeouRIm6Q3QTvjcnPczfBqgLffURstVJz5nqjnrNR4T+8dwNrZB8PTgOWA QdGV4bIyqtNG7UHQuZ7sVKr2tx0gYJyQ5uZgncEHB5YIuhQ/CyAHrVmO+5/0/xWCLI0g44rF ZJqsYw2JQ2+vayTWbR65rkOiKL8GOVFNZanDg80BRh6qCmCEMXd/tymxvgnvWpHtxMgukexk 4vV9nV4XhxRVYdpLk8mBxsh+AEbHE+nbWgIuJDrmrZDGI2Dha7JFoB0Mi6hbbYd9BdkcHKQ7 6c+S1xOrZL3jX7OIFhb4NNnEOhh8/+BDlyby478p6YsimNa7TgAUbrygGyfVG8usrZy8SvO+ vUbVQwqjcJaCK1xazK12dfuZm2kSMJUrJqa9ng6OMjkE2/WrtnK8ruFNSCdytzbuheT0nYUJ Uwy84cU4p2K/N2C4vYjcn+IT+l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C6fR1 ZKUOw03+mM/xRzL1be6RVS9AF7R5oDd11RrTOb7k14z0inFqSRrRwzOPKcuMxrApcquar336 3FQuLcJLjBo/SAOh2JatOkkwkw5PZseqdwcAk5+wcCbdYy8J8ttR04iV1FzrdQp8HbVxGNo7 AlDn1qtoHzvJHSQG51tbXWfLIi1ek3tpwJWj08+Zo+M47X6B65g7wdrwCiiFfclhXhI1eJNy fqqZgi3rxgu4sc5lmR846emZ/Tx85/nizqWCv7xUBxQwmhRPZRW+37vS2OLpyrTtBj3/tEM9 m9GMmTZqaJFeK7WCpprJV4jNHpWZuNAsQrdK1MrceIxb0/6wYe0xK79lScxms+zs9pGTrO4U 5RoS4gXK65ECcBH8/mumV6oBmLrNxKUrzTczdo9PnkmRyZcAa6AndbjmQDznwxvTZu2LjMPC EuY0 In-Reply-To: <20240614190956.GFZmyVhLGeyLjwvA6X@fat_crate.local> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 6/14/24 12:09 PM, Borislav Petkov wrote: > On Fri, Jun 14, 2024 at 11:32:16AM -0700, Alexey Makhalov wrote: >> >> >> On 6/14/24 9:19 AM, Dave Hansen wrote: >>> On 6/14/24 09:14, Borislav Petkov wrote: >>>> On Fri, Jun 14, 2024 at 09:03:22AM -0700, Dave Hansen wrote: >>> ... >>>>> You need to zero out all of 'args' somehow. >>>> >>>> You mean like this: >>>> >>>> struct tdx_module_args args = {}; >>>> >>>> ? >>> >>> Yes, or do all the assignments with the initializer. We seem to do it >>> both ways, so whatever works. >> >> Thanks Dave for pointing that out. I missed that at v7. > > Ok, I'll fold this struct initialization oneliner into the last patch. > Thanks!