Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754838AbcKNQtN (ORCPT ); Mon, 14 Nov 2016 11:49:13 -0500 Received: from mail-cys01nam02on0076.outbound.protection.outlook.com ([104.47.37.76]:55024 "EHLO NAM02-CY1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754733AbcKNQtE (ORCPT ); Mon, 14 Nov 2016 11:49:04 -0500 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Thomas.Lendacky@amd.com; Subject: Re: [RFC PATCH v3 14/20] iommu/amd: Disable AMD IOMMU if memory encryption is active To: Joerg Roedel References: <20161110003426.3280.2999.stgit@tlendack-t1.amdoffice.net> <20161110003731.3280.67205.stgit@tlendack-t1.amdoffice.net> <20161114163204.GA2078@8bytes.org> CC: , , , , , , , , , Rik van Riel , =?UTF-8?B?UmFkaW0gS3LEjW3DocWZ?= , Arnd Bergmann , Jonathan Corbet , Matt Fleming , Konrad Rzeszutek Wilk , Paolo Bonzini , Larry Woodman , Ingo Molnar , Borislav Petkov , Andy Lutomirski , "H. Peter Anvin" , Andrey Ryabinin , Alexander Potapenko , Thomas Gleixner , Dmitry Vyukov From: Tom Lendacky Message-ID: Date: Mon, 14 Nov 2016 10:48:52 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0 MIME-Version: 1.0 In-Reply-To: <20161114163204.GA2078@8bytes.org> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-Originating-IP: [165.204.77.1] X-ClientProxiedBy: BY1PR15CA0010.namprd15.prod.outlook.com (10.162.17.148) To CY4PR12MB1141.namprd12.prod.outlook.com (10.168.163.149) X-Microsoft-Exchange-Diagnostics: 1;CY4PR12MB1141;2:uEIgy3ee+em2mcobArRaRzm5NnkwxfZI8EV2wHxhA0QjbZGokyV0uPLWiM9si+jr7W9UnE3CSbQOe6gTorzrXvNPObbV/4MIEoD4KWGbim8YZUkCLbD7C+MDOF61GIfiKnizf73iermv6dIroBx6aCy9Pigx+xFuiYlj0tukCow=;3:CJGGIYesqGXg9DVU/3I4BDNlwX/heEInTL6fAtNYn7VKalYUz5q9c/F9fQRz7VOcJWMsprETRPba2U8gGYPYavp7ZUWVjKh78y7NyvbAaUhSLUj2bCpZHhhkBsUlRXq+mMGkYe3j1Wri+rfPbtmjVhHDlSAAkKuqS7h/ajVIh0g=;25:wmaBoNvsMaqHxj9A/rlHFxCJvY7JUpwU2ZJI9qFfwe/xjztJXUi3EcWWx4Nsy+qrWtKbvYX6s8LHO0O0XpyzzHF+QFYNKnkRXb4d/T+QTy7YalTCRvXTq2B1aAWVoHlv4qtrdrE4HqOdEASo8lTs1H1mh9R2iNlB213PySSw+tHXiLBGKptdKVpV47a6MCPd462a9V5mh757oVoiInbKi6syxB0dt9eoY3f9BePzW7MhzPa5eEKNM9XYUm7CiHHICipCDdOMhMqQlcH+HANjZisfUhcw+BF+K9ShLHOaovqKr/iUY3UKuhRzcoYcbJBR75a3QeanOZHA77piCt3KUv4QBxeL80MzgPYZaQtjWhF1bkklaINcKgfCVbzzJQggs8RTyY5ptpsrMdCiV1TrBNHgRF3+l+/TAQMxXv4FLDk= X-MS-Office365-Filtering-Correlation-Id: 0f8ad160-8986-4760-2890-08d40cae225c X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001);SRVR:CY4PR12MB1141; X-Microsoft-Exchange-Diagnostics: 1;CY4PR12MB1141;31:9pIQQ1dTu8JipBqaIH9D3rZJDW4oI3HHkJdONJWKgQuz7CZ6VWXTtJHBHrxA1EX62XqfoqPTRNe2A3TH8yGbx09EAutNrYFjShnmZH7WUuv068FjAFGuNoaQdgTE1oeuBAfLWhDGAAgNvAjdJ2BT1usELBEhnb6lv2BA/mKlzXXmBnn+n6NDJ795lAo5keQPL0qk3Pv+b5IMES1aN287186EltGbjfjU87l2fz9AdGWRmzKUNRdNaR/F8UClKPsu;20:i/u5qpk42eFRzAt/Y5aKoUj/GneJmOAZKwUAJvFS8WWKFNWZ3BSbBg4mujeDNTW0rGRPHoDi9xexZY9em6M1slowXy/Vw8Zkpw+DVBy8KenZkiGQcGQ/oIK+eLIyJ3G0HQUHSTH7nWqFwl81kspNu5Qv+D44xb3IKFd39KAVvGgH8T/jpgOFmavNjeDhW/ZleB/b0OAhsFpBw7HL4/p5ysjU68Ym3HnT15Ab3I8GWH57eL+8xLxwb6cfuB0JmcEOvKDVD3kQ6tCCm2YPIjJPhmWkXvgTY99SZlUGpf7An6y0wbrdvzS2PKJNnu2ua6BSeQU2VQX8EGjUlh9bdZ2l0ECvDrHADTBRCgO7F1CNxMt0i5NeZQayiHUzl+Bc4PpGd5LZWjaicjHTyoDYz5uRo9gGELRJ4ESB0xj7Sd883AusCKfVZ7waXB0ge65Z55qN65/ajF8EUAiUYTN7FaoWAa3+kFP7NB5lVEmFvhgoK8bA/HL1EJXt/RflnlSLqQ4H X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6060326)(601004)(2401047)(8121501046)(5005006)(10201501046)(3002001)(6055026)(6061323);SRVR:CY4PR12MB1141;BCL:0;PCL:0;RULEID:;SRVR:CY4PR12MB1141; X-Microsoft-Exchange-Diagnostics: 1;CY4PR12MB1141;4:GgZKr2ZQTD8XwoOkzSHnLVvzhBdGAtVymeKGKpCdm0+80z7m8w4YV2vleWDhHXespbKeGN9Jxd8S3GPMGdkNojpJLCdttlRuXYEp/ex0/PcfA5BGpZFt/qPjp3y9Psa8qmY4G3gYWGl5IlmmzysJ7q7hZpopAXA5ME9+mv2z+rwQ/U0t7UIG+1SgBCtdRI37cQLyIg8dqZxqZB9rkq0sHyENqWvHXqW8JBJGAv/qU8XYcnVSPcLjM1J1bgtOLRunyS05J8OtzkD4AsX6UMStqeqitpAgyWaD3EeIEMrl1UljbgaH1xtNzSvbww57+Ecf9VwjqDorK2HGDlVs/yKFDIcEikSJkQZLdB49/0/Or4O3+Fn9sorNS2iv+cnfFgy4Dycgvsd3g5LmCKoP3efPqr4QImZPkYsv55Uvfuf9rCu6ZXvtgpOuyXfQ7nW6soWp X-Forefront-PRVS: 0126A32F74 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(4630300001)(6049001)(6009001)(7916002)(189002)(199003)(377454003)(24454002)(5660300001)(7846002)(97736004)(50986999)(106356001)(230700001)(31696002)(2906002)(7736002)(54356999)(101416001)(305945005)(81156014)(4001350100001)(76176999)(64126003)(77096005)(50466002)(36756003)(86362001)(4326007)(6666003)(229853002)(586003)(7416002)(8676002)(110136003)(92566002)(105586002)(31686004)(83506001)(68736007)(23746002)(6916009)(81166006)(65826007)(2950100002)(65956001)(65806001)(47776003)(33646002)(42186005)(6116002)(66066001)(3846002)(189998001)(217873001);DIR:OUT;SFP:1101;SCL:1;SRVR:CY4PR12MB1141;H:[10.236.18.82];FPR:;SPF:None;PTR:InfoNoRecords;MX:1;A:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?Windows-1252?Q?1;CY4PR12MB1141;23:3ndXob4jmQTU48xqY9adfcaHcnQmzsKUs8VcN?= =?Windows-1252?Q?uEciavWDBmXGqJv2mYCk7mVAMXfRRduoXRtST0ug/QqHdHLIU3Jr5foF?= =?Windows-1252?Q?fO9vDKFCfiNV5R05fbTacNc859avuhjQ7d0p6Zcf/Itbn2utUw9uEC64?= =?Windows-1252?Q?zQO2IlpN8D1uuAEaqgcly1vR7QQT74xaEnaCQdeiLXfmnu6z1JHD+diK?= =?Windows-1252?Q?ocOQfsIUw0EerC7SyD/bv1Boo43nb5ZaEAU1hulkgvQ1pR0fKP3tpMac?= =?Windows-1252?Q?oKL40LsCDV0sCfPirpSoN9bisbk8N9EJi7/1akW9h66Lf4J51bpuZ3Tc?= =?Windows-1252?Q?t44mO1S7HCw3t4wH4e+9A+/E0KynlOAtvx9lKwbcZ+WbOgctFK55TmvV?= =?Windows-1252?Q?vIs7oB1RpRGPkoJbNispmbJGGlBRBWFXvIJM3/Enxew16kml0yvzLaTg?= =?Windows-1252?Q?GfnCLsxpLL6NEoIIOGyH93ek6CUVgCZZooYdrTFKTQnxWVFx1wUyK0uQ?= =?Windows-1252?Q?rWbuyr52m2UxkHUbgT2iAsHFvKkjuNO9XNzoMh5DsIxlS6Y17U5jjEZk?= =?Windows-1252?Q?EdTexWG4UgcZhHL9rxYJb6SvpSWUtVaiTi1xiNDsfQx2sTmdHsRZZU31?= =?Windows-1252?Q?fgrb7c9C6VOx4Lq+0fzjNOmh0s3aEoYKomMHoVmGSD4s8e/2pRREaJyf?= =?Windows-1252?Q?UcJkZ2fKsviMkPE/zVrC2CdS6WtguAM0pO4IOcOWt7LDZyHCeDWGJhWm?= =?Windows-1252?Q?okncmv0vLx6OV3GglDIEyMLU3mjNwkSXopSESYs1QRe9ChUzr8hlUma2?= =?Windows-1252?Q?FwIhqbQ3DfzG2Na8jgMQhedOdarmw0iMIRr5AhZib2LnJcxCjYVpkNl1?= =?Windows-1252?Q?U5QVwY8UkcnBarGxAi9/LqZIJ5u8Mf5kueJiXGGfuUZWN/QB5aImJl9c?= =?Windows-1252?Q?JNeYFEydc5Lvc95zoWJwpzTAVKDQIvcaSXjnrh93PBA0JRsbu/iEiG/o?= =?Windows-1252?Q?LtVI1U1e5Jdir16D1wT8JvObpsyhVn/qCszIS9Syy4w1a/xk348eb9mS?= =?Windows-1252?Q?uNsXI4C7kpIWUa3Ve9AUtvaRblnkApQNw8emQO/QMW+8iiV4/jWYrfIo?= =?Windows-1252?Q?iVq4vClSbYp6HV8NeXctfjg6teTWRPhYi47lssj3zcIWG5mbB+TB9Y6M?= =?Windows-1252?Q?0iofx48Kw1Pg65L7BAGF3ugJoL3TVuQdtI1KBWDNAjKLM11GeYIHEZr5?= =?Windows-1252?Q?1ep2AhKHxw+sSjq5UDmbGlUwX/nQNhwuZ0XB72hkzhfcIrd/g8Hz/BzA?= =?Windows-1252?Q?n2CS8LzxynUSj+bY2SsWZvwLhadjeWoyAIXhSJMGqjoISCg1TQjxkIuF?= =?Windows-1252?Q?MK/vniP20zTXRMggMA0ScY/zk/hYCRD/shqa4SQHbW5gA7lzbmo57Ob+?= =?Windows-1252?Q?WE1OHx1koITVf9H3wc/?= X-Microsoft-Exchange-Diagnostics: 1;CY4PR12MB1141;6:bFGlIyruyzRZ665yXHHAAZeY6/lDU8HD5RTbZq3pNt3zebYWVVNbfTNH67tcq+U6EnShUFN/PPva7CeaNqATHL6hvNTR5rTgSOfDYNRpxbm3xalDWduIfskNWttJqx6ifFXFGrZrolVD4AcGnxjqoMRL3XGOnaA2dpIzcOLZfTzcDoXtf39JJV1ajJ2KejiUczxrX7fcAO78iGjVIcWCtrRDWsqlJkot0Q7CXTEACtpkUtSb73LWlRXoUxGOf63ecMktW0taz4Lf8D9zRFj7mq2JSqw8QVlseSaU9+K0pt0Ww8hnfP1I9DW2iSbUGYqCIhasGhJ92wWQ5koyM2j9N3ZVw+wVoLTMsh3QIE6mdF5S/MpdGHpdkKCc4O9jSVR9;5:ricM9bYcCc5fYo0NSAsguTNsCFDJMZUAMu5hbGJaVOneovC3Dg1wI2oCbCVebbcBTWuW4EEAQdi2gFLJvu3LIE3UWDROts6kYCA0nPXpgVq8i5eSaAYssy5kx0LFKfpU7ukS9JQfFjVT6MNSt3rBSA==;24:lyShTvAQ/ncdKQQOeUOm/Tbvd3SRtosZbY2aOvnH3LDCa7/66meLGZVNs0G2aLBNZAswsMEVT7lBo6pftpEuB8BDR3vkhVS4UyVh5VNDPtk= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1;CY4PR12MB1141;7:46YyoSdlA/qEFppbguGS04m5xE/nzi59JaWsCVUsRCcfjZ/H3csqAiMNfyahko+CA0prgnEqYlUwyGMsVYsDXzv71kaJqEtaPSMbO7tMdFMxQ7MYqOsq4k/O0TRdWoVPKG+pSeqMjlEqHxCee+zBCU5sW77hCL7Wk+rxuEfa4je+VWD+uQbPbhmbe/b6E+8xdPSW21hBQk09CMrLQXltQmEPhhDDSl7m+l8ySVnZLTHqiFuv/ylxFG+QpqkcwauiM7lBE52XHwTxV1adxO0r0OE2LbWDSDPx75mPz95Oz+7ZzZaMik5VMn44YEX2JNeaVDmCiNmDbI7oWeALoJ6y1VdbbsmYWZeowU3I8komOA0=;20:f3XJ8Pc9ZlOT4Y3LODIYL3dIkehL3FaJwxs2//+uFq7IycNjfTVQnAxzqgcAhyGoq0WMEvX+KxUMylt+c4ESwkLHWZ0Dxk56Zc1ZvyIvK1CKhQ252H1RwN0R0I8L53zfIqPK8sg5IPaHO1YpsE8xvg8g303+dhVgskoX9Q4Lt5W74Af1zPFf5wuERBnz3VQTnCjdRGFjd8b2KUVB9j+Ue+qcYPeLCHWx/PaRfg+UagNnxz3HlQGRh4uNoP5Xa/ZO X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 Nov 2016 16:48:58.4532 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR12MB1141 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 345 Lines: 20 On 11/14/2016 10:32 AM, Joerg Roedel wrote: > On Wed, Nov 09, 2016 at 06:37:32PM -0600, Tom Lendacky wrote: >> + /* For now, disable the IOMMU if SME is active */ >> + if (sme_me_mask) >> + return -ENODEV; >> + > > Please print a message here telling the user why the IOMMU got disabled. Will do. Thanks, Tom > > > Thanks, > > Joerg >