Received: by 2002:a25:1985:0:0:0:0:0 with SMTP id 127csp799558ybz; Wed, 29 Apr 2020 09:34:41 -0700 (PDT) X-Google-Smtp-Source: APiQypIcVZVWGhtGD8/sFDooySJb3HmWjBshQmzlAcTfDfW340O4VKvoiFY/DRx7dtahJKNvK0g8 X-Received: by 2002:a50:e80a:: with SMTP id e10mr3292525edn.204.1588178081054; Wed, 29 Apr 2020 09:34:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1588178081; cv=none; d=google.com; s=arc-20160816; b=KcVpNW4kbquKwqZ/QhXRADerWwSO7apXdZM66JJAaQlKGylcoT/hBeL+Ath/FuDCjN gLbvgctIoC/aTh8H1I/VJnG9TChEEcEuYLBfZH/zr4Lj+wW8tC0pPR9kpcIojZAOQzVw 8p59SRbTCiqZMaBOopFWc1tMyNuo9gE+OcLeqB9/813C7ZtitdxHOeX6MfPfvFNqlsVX eYzGIsfOxhcQ0z3AUOp3HVCrk/qM0MyL0bz2QTNyIKiXPF4Yoiyl7jeOLIwfBm3pawsH CX/Vn84yQbgbI5Wodadh2UXAi/fRItNrxgiyL2+eVwBHRo7EXGI8YOyoUwEqVfa/2j+O qigw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:ironport-sdr :dkim-signature; bh=d6qXVXHPuatxsRdVvPnqKa2Hlx79zK92oUz4izVcbL4=; b=n8oAxdVgSNlc8WS5uU0DSx0pt2CSz/RrM8kT+dEUangwqPdkWfOvwD+mFiU6PmVBZx uGRkt70m1W9FY9VwrakSX2nu7pEj4XPt3NFnKiDahawVryvbuYbfC6OsJWuc4MmwY9Gt emog0CYOHIouzJj7P5Up6N1RVxveI1IfulJQ4bsC7ixCLb9DT/elLTKhnjhkCrOpPxnb yahPs3GLG9liaYW+AlvndnWlhu64uPxaSWtFvG//hSqCS4OzmLhlMFgTGRzcmTcyrS6A wxsnTBYsYURYteVdTAcwF/CDPR/UfdqJ761u7iFN2vp0pFZsRm4rl0YVQqCMpie/L7tY AypA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=WIw9Fqmz; 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=amazon.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rs10si4121336ejb.288.2020.04.29.09.34.13; Wed, 29 Apr 2020 09:34:41 -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=@amazon.com header.s=amazon201209 header.b=WIw9Fqmz; 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=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726822AbgD2QcF (ORCPT + 99 others); Wed, 29 Apr 2020 12:32:05 -0400 Received: from smtp-fw-6001.amazon.com ([52.95.48.154]:33498 "EHLO smtp-fw-6001.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726755AbgD2QcE (ORCPT ); Wed, 29 Apr 2020 12:32:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1588177923; x=1619713923; h=subject:to:cc:references:from:message-id:date: mime-version:in-reply-to:content-transfer-encoding; bh=d6qXVXHPuatxsRdVvPnqKa2Hlx79zK92oUz4izVcbL4=; b=WIw9FqmzfgJltYbrXrUZy/A6Tl4/d1T5YcbbfKgU07FFQL3sKcxRB0RK Lp2SLDNn4omTffcqt/Qp4ghZ5EFqkY2oNfZaRvPIKYktc9W2Mwfo05KpY 7iltgoc+WigK1+Rt1rlaIPDDNf5aUkcD2cVTXmcYjJkAvjGj4oLgt7Gho 4=; IronPort-SDR: XC3FSamRhHQTNPlU5dNn+LT3L/mOS+wSCzOSxNOvLGJGMG8Wh15oXlzP0Osz98qDHVgonz+v+E ABJgXE2PFWXQ== X-IronPort-AV: E=Sophos;i="5.73,332,1583193600"; d="scan'208";a="29290944" Received: from iad12-co-svc-p1-lb1-vlan3.amazon.com (HELO email-inbound-relay-1e-303d0b0e.us-east-1.amazon.com) ([10.43.8.6]) by smtp-border-fw-out-6001.iad6.amazon.com with ESMTP; 29 Apr 2020 16:31:42 +0000 Received: from EX13MTAUEA002.ant.amazon.com (iad55-ws-svc-p15-lb9-vlan3.iad.amazon.com [10.40.159.166]) by email-inbound-relay-1e-303d0b0e.us-east-1.amazon.com (Postfix) with ESMTPS id 8B94CA20D9; Wed, 29 Apr 2020 16:31:40 +0000 (UTC) Received: from EX13D16EUB001.ant.amazon.com (10.43.166.28) by EX13MTAUEA002.ant.amazon.com (10.43.61.77) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 29 Apr 2020 16:31:39 +0000 Received: from 38f9d34ed3b1.ant.amazon.com (10.43.162.53) by EX13D16EUB001.ant.amazon.com (10.43.166.28) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Wed, 29 Apr 2020 16:31:31 +0000 Subject: Re: [PATCH v1 04/15] nitro_enclaves: Init PCI device driver To: Liran Alon , CC: Anthony Liguori , Benjamin Herrenschmidt , Colm MacCarthaigh , Bjoern Doebel , David Woodhouse , Frank van der Linden , Alexander Graf , Martin Pohlack , Matt Wilson , Paolo Bonzini , Balbir Singh , Stewart Smith , Uwe Dannowski , , References: <20200421184150.68011-1-andraprs@amazon.com> <20200421184150.68011-5-andraprs@amazon.com> From: "Paraschiv, Andra-Irina" Message-ID: Date: Wed, 29 Apr 2020 19:31:21 +0300 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: Content-Language: en-US X-Originating-IP: [10.43.162.53] X-ClientProxiedBy: EX13D25UWC002.ant.amazon.com (10.43.162.210) To EX13D16EUB001.ant.amazon.com (10.43.166.28) Content-Type: text/plain; charset="utf-8"; format="flowed" Content-Transfer-Encoding: base64 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org CgpPbiAyNS8wNC8yMDIwIDE3OjI1LCBMaXJhbiBBbG9uIHdyb3RlOgo+Cj4gT24gMjEvMDQvMjAy MCAyMTo0MSwgQW5kcmEgUGFyYXNjaGl2IHdyb3RlOgo+PiArCj4+ICsvKioKPj4gKyAqIG5lX3Nl dHVwX21zaXggLSBTZXR1cCBNU0ktWCB2ZWN0b3JzIGZvciB0aGUgUENJIGRldmljZS4KPj4gKyAq Cj4+ICsgKiBAcGRldjogUENJIGRldmljZSB0byBzZXR1cCB0aGUgTVNJLVggZm9yLgo+PiArICog QG5lX3BjaV9kZXY6IFBDSSBkZXZpY2UgcHJpdmF0ZSBkYXRhIHN0cnVjdHVyZS4KPj4gKyAqCj4+ ICsgKiBAcmV0dXJuczogMCBvbiBzdWNjZXNzLCBuZWdhdGl2ZSByZXR1cm4gdmFsdWUgb24gZmFp bHVyZS4KPj4gKyAqLwo+PiArc3RhdGljIGludCBuZV9zZXR1cF9tc2l4KHN0cnVjdCBwY2lfZGV2 ICpwZGV2LCBzdHJ1Y3QgbmVfcGNpX2RldiAKPj4gKm5lX3BjaV9kZXYpCj4+ICt7Cj4+ICvCoMKg wqAgaW50IG5yX3ZlY3MgPSAwOwo+PiArwqDCoMKgIGludCByYyA9IC1FSU5WQUw7Cj4+ICsKPj4g K8KgwqDCoCBCVUdfT04oIW5lX3BjaV9kZXYpOwo+IFRoaXMga2lu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