Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp1611182pxb; Mon, 11 Oct 2021 09:27:07 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyE4XzRaC+gXXAyqyuUik3FGRdJvDl8ZAX7/zsraSTd8dZKzniWQz1S6WfOu88+Me4fOT6x X-Received: by 2002:aa7:83d1:0:b0:44c:654a:be1d with SMTP id j17-20020aa783d1000000b0044c654abe1dmr26281913pfn.68.1633969627601; Mon, 11 Oct 2021 09:27:07 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1633969627; cv=pass; d=google.com; s=arc-20160816; b=RmXOJ2MqSbKjMLJMSLr4MWZiW1BXQ1csvLJdtI4FANp0rhO9mOZnsfKSGhMNJ+5Aib z50P0EsbH+77BkXZg4SEEBmajCj5GpLNXey7PK7ponxwXwGFRWaTpuyfi3SL4MSZ76Uu pLJn74Cbml5wlT5ktks1Ev2s3oVtjDZ7CtEjIIqh1ugfRGbMlgTomBVmQCQc+/Nedy3W okXJ+c9tBPNdlriewtpjUV5Z6pc1tc0dQsEVJgILwDGix7E2x54tNmCkvQebZH2Ol8Nw u2KlRLm2ghiLiTkQNxeSFxghvXgJubj+8w+6GwuljOcMpLrMtPQ0HFL4Ds/1kId4cGbs tfRQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :content-language:in-reply-to:user-agent:date:message-id:from :references:cc:to:subject:dkim-signature; bh=EXwavDZkWHRLbZXRikjxTLkbVNQGgNMch3O4FuSFTl0=; b=ztc2WGm1dqaLaX4tbamwKMKQ0aOos/o8j7LXtWrTvFt4C3iFcdeOFkEjxmSYfNPKeu ak9NMRlR11wcQjZhvaF5jixTv0Brky3ltjBvhqJDMlRMYiePR5v7A/4Q9yNJP3XUK1xQ X00pSbsBFsaQlZJ8xWCuM1P4J57oq2gYYC8APABZh4Jidm9r3rMN/ciL61XamZPRSGmu QYC2Zi1XDdwIVSDza+aOliAc85J6yKjb8BTDr63vOE0KDDTBUcTccGmkyE+7hTlF/tQN LaPD2iDT8AmAJOfRwn2y8xjOr6P7mXx5ihIA+fzSfC0ypvkBQXge00ijSUb70MMcXvBd Wxng== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=EwQevYT8; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e7si8905655pfi.140.2021.10.11.09.26.53; Mon, 11 Oct 2021 09:27:07 -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=@amd.com header.s=selector1 header.b=EwQevYT8; arc=pass (i=1 spf=pass spfdomain=amd.com dkim=pass dkdomain=amd.com dmarc=pass fromdomain=amd.com); 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=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235329AbhJKN3k (ORCPT + 99 others); Mon, 11 Oct 2021 09:29:40 -0400 Received: from mail-sn1anam02on2065.outbound.protection.outlook.com ([40.107.96.65]:11629 "EHLO NAM02-SN1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S235197AbhJKN3j (ORCPT ); Mon, 11 Oct 2021 09:29:39 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=IRSLbtN1949lYJj58QbGg/emFJQFVlt/ubfSs/6ZomDH/aFPfN2cWfi62b7kbhogmyyj5CFTZg8TjBu0Va3Mlx5U48EX4l4amzsteQL1Sq1M3OCpvvx9Ws1eYkrXgZZur2hcPTrA+C2/MGmx7PuQPTNs3zzeiuF8Ig3Oi7c9Qyf1FgejMPSJcBcjB6kvGXW+a/tCArfYvkFD0QHclSsBaXEbDqP0Z8WWJD4T5XJUgQPTrGydhaYkF6B0NjWyfA+mEevuoCoR9dkXJ4wLKbIRujEUHG7Nrj7mJje0mnB/nqqRDJiKxN9uXWaX6RHrOzCAFUkzhejSiBalzl8dMm9PPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=EXwavDZkWHRLbZXRikjxTLkbVNQGgNMch3O4FuSFTl0=; b=nkJfVtm/W7AZO/kX75A3c3YO9msOERd4RXiKgrLNVhgLetrHK84l64Av1I0PBHzfVpyJ0l7PQ45bIifQo308SY6QdfiqGJ8sV1JhPbdjLhT9qnUiRwOVcKgPCTGLJ1GSGh84PWnVr/MDcnRR2LDfNTtHemS6NzYdee2TVkeEvJVU+kxtmEVy86j4/tAByrJegYavaXbZu3OQxfAjwiJQNDq3hFZ42CHqS34JfxNki8vUwjFiIx0OFXOAIijIHqTMoXfZR/cbJEPqoooYdnx5QNN031GJm6AzUrTEpmXkiCdQKG7VnBXQDFIph7ML6ms22Yw8FKdCCX9dwrwoprLOKA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=EXwavDZkWHRLbZXRikjxTLkbVNQGgNMch3O4FuSFTl0=; b=EwQevYT8nVR5ocmc/DB+VLCEnFQfa4KmiGJQ6vB/eXW/inlgZU9ZkcNnsajmdf5W9Hv3N+TwVzXDyqbAqLbVufrLDWC9usDVlr0ZjIxTqDkbs1/Ut419r7laZK4saawmD2JN/m4rOKlYNnUyD2ZDdHIId+Ebo1G8LcGTmUNkATI= Authentication-Results: lists.freedesktop.org; dkim=none (message not signed) header.d=none;lists.freedesktop.org; dmarc=none action=none header.from=amd.com; Received: from DM4PR12MB5229.namprd12.prod.outlook.com (2603:10b6:5:398::12) by DM4PR12MB5150.namprd12.prod.outlook.com (2603:10b6:5:391::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4587.19; Mon, 11 Oct 2021 13:27:38 +0000 Received: from DM4PR12MB5229.namprd12.prod.outlook.com ([fe80::d560:d21:cd59:9418]) by DM4PR12MB5229.namprd12.prod.outlook.com ([fe80::d560:d21:cd59:9418%6]) with mapi id 15.20.4587.026; Mon, 11 Oct 2021 13:27:38 +0000 Subject: Re: `AMD_MEM_ENCRYPT_ACTIVE_BY_DEFAULT=y` causes AMDGPU to fail on Ryzen: amdgpu: SME is not compatible with RAVEN To: Borislav Petkov , Paul Menzel Cc: Alex Deucher , Thomas Gleixner , Ingo Molnar , X86 ML , Dave Hansen , Andy Lutomirski , Peter Zijlstra , LKML , amd-gfx@lists.freedesktop.org References: <8bbacd0e-4580-3194-19d2-a0ecad7df09c@molgen.mpg.de> <96f6dbed-b027-c65e-6888-c0e8630cc006@amd.com> From: Tom Lendacky Message-ID: <87d93314-ba3e-464f-d051-84a8de674b06@amd.com> Date: Mon, 11 Oct 2021 08:27:35 -0500 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.13.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-ClientProxiedBy: SA9P223CA0004.NAMP223.PROD.OUTLOOK.COM (2603:10b6:806:26::9) To DM4PR12MB5229.namprd12.prod.outlook.com (2603:10b6:5:398::12) MIME-Version: 1.0 Received: from [10.236.30.241] (165.204.77.1) by SA9P223CA0004.NAMP223.PROD.OUTLOOK.COM (2603:10b6:806:26::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4587.18 via Frontend Transport; Mon, 11 Oct 2021 13:27:37 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: fb73abfa-3462-4878-d0cf-08d98cbae4a9 X-MS-TrafficTypeDiagnostic: DM4PR12MB5150: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:8882; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: JoOsuCrxc1Rt2dbtgniKo6Kka+tV7XkXtsOqANw1ORlgGKG3C5t6OGSgY4pAhZ0HEJO7qQaUq0HKx9++saGpDkoicJE2yDNnVDjiC0vMmnJvLdBs4W5WAHXEI9sDpH2QQeVGkHwYpIYdyLVDIC5afPFR2Eo+UR6aAYEzIrIX+QcHF43vhplsByt/W4+Pbe6vJ6CUrKliVaH21o3YCGBonfpdYzdfhRdvnSQVixm0C8XALYX5+v1dgUNMbfkYGbdvFrqWPS8YhYVEU90WGL7M+HeuBSwI47rrx+o5/aMXTTeq8166sqFbM9wknYFhb3vgqVmZMQG28He00DHqF5PCdw3P0FiGjGtffQXu8CRvTi7+uoh/IKq3l3TWrdWjvhh8/WFlzxhH7wvS9imfstI+GK0fp9NsGrM09SLQQLd7hjQ44DSsNpFeZ4q7FVvBL9zo7N+YPARU97rCjhkDwTW5YkWY3cJNp3st/HNdeJ1oQvZ/OtiZ6Q/LBFUxHr4aBobc2NJo3yyoOs/0/vqgVCJRP8QuIsd8MZlnOvfg0VlsB4MYZjKg+rYe3hR41yndwVRCut3r9u224CB5wiMTcjdJ/HvQEbe47i08rsUBBZSNB55EDJsfZ3SANw+yGO8mOYEznqOtMNHVldOCU7bO8noJVTGiEjTlFi5bXsCozNseX5KYSZVgP2aw1mcFZLX5dPyZTq4VM1vG6sF92s8BQVwvVArPLE4UMZSbrWMDTg/3xiwJUH5/dwNXB3O9gLOXJe3Q X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM4PR12MB5229.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(366004)(36756003)(8676002)(2906002)(956004)(66476007)(316002)(110136005)(5660300002)(86362001)(66946007)(7416002)(66556008)(26005)(16576012)(54906003)(2616005)(31696002)(4744005)(186003)(38100700002)(31686004)(508600001)(6486002)(53546011)(4326008)(83380400001)(8936002)(81973001)(45980500001)(43740500002);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?QWJYNFdYUWVtdnAvMU5tY21CckNrTEovTERjQzFIdlRKSnZtcitZMFBGNW9a?= =?utf-8?B?VXZ3M01naERVM01NSk00ZkVqa3RrWDJMN1ZHU3pBVnowZGtYQ0daNm5SbUQ4?= =?utf-8?B?SEkrbG51ZW0xNlM4bFlwQ0hWRFNqTytEajZFaHdBdHdYT045bWF5aTN4YVd1?= =?utf-8?B?L3hBM3dvcDlKcm9XaUlCN3dqYnh1OVM0WW1xR2NNNWkyckVaditYUGQ4dElM?= =?utf-8?B?WWlqY24vVmNid1BpR01HSWxGazdreW9sZjBXWDZFY3h1c01SQ3FzeWY4bGpM?= =?utf-8?B?WGtzUUM3SUtldmN1WFlteURMZEorOHJyUEVZbHFieU9yNlFZdGZSRE50M3ZS?= =?utf-8?B?cWZuMlB2QTJH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XdUN1RyK2VVV096UzhmbVJJV0hqNk1EVDFpRm9CMjRycFNCcTFlLzlWRUxQ?= =?utf-8?B?cXRpM3B0TDVoc092bWxqUnF4OGlPWnhtVml5MXpUWEluZlZjNE1DYXdCTm53?= =?utf-8?B?YTRzeUQ2WUo1N0RmMkpPVUc4aEZUODZaeC96RjlGOGFWRytvQ2NnS1hGREZF?= =?utf-8?B?cThJT000K3dNUjBHOWlNTlFOdlZQSXQ0UFlFc2RnTTEzYXRldXJUd0Q4RjVZ?= =?utf-8?B?VTVldVZlbDg3algrUU51YThjRFk4SFczWG9CRlQ1MHpFS0FkK1hkcHpPRTB5?= =?utf-8?B?N1Y0b1FnSkpBUWpJaXpXZlBYcTEzb1VydVUxMFJwNlRDVHpWNlVCNWNuajk3?= =?utf-8?B?cjd0LzhVdTcrdzhpVGs1Q2ZoT1cvR3hSNHpCOERBRUVMU0ltdGJCbGtiVEts?= =?utf-8?B?S0tNdVdhdHA0YUZ0VnNqSjB6MWlITGxhRndKVmFZNkRva2MyQkpRTUZTdGda?= =?utf-8?Q?32x35s4sB4F814brKvsBHHM0pXOK2h5jySlv3fl?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: fb73abfa-3462-4878-d0cf-08d98cbae4a9 X-MS-Exchange-CrossTenant-AuthSource: DM4PR12MB5229.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 11 Oct 2021 13:27:37.9587 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: RICe1CyaXsY6ZcQrShcV5ss80kD4imTSgOp4EOcVy5ZlhHdfQnNOsl4j5Zm+DDftw41+/ngih0iaNdnyS/1NIA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM4PR12MB5150 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/11/21 8:11 AM, Borislav Petkov wrote: > On Mon, Oct 11, 2021 at 03:05:33PM +0200, Paul Menzel wrote: >> I think, the IOMMU is enabled on the MSI B350M MORTAR, but otherwise, yes >> this looks fine. The help text could also be updated to mention problems >> with AMD Raven devices. > > This is not only about Raven GPUs but, as Alex explained, pretty much > about every device which doesn't support a 48 bit DMA mask. I'll expand > that aspect in the changelog. In general, non-GPU devices that don't support a 48-bit DMA mask work fine (assuming they have set their DMA mask appropriately). It really depends on whether SWIOTLB will be able to satisfy the memory requirements of the driver when the IOMMU is not enabled or in passthrough mode. Since GPU devices need/use a lot of memory, that becomes a problem. Thanks, Tom >