Received: by 2002:a25:b794:0:0:0:0:0 with SMTP id n20csp3838129ybh; Tue, 6 Aug 2019 02:14:43 -0700 (PDT) X-Google-Smtp-Source: APXvYqwDQAI1z/oDHUeqyPDEgzB8C0Fv6Tql0mZU3zF4uKK4zqFpHbRG8Sgkb6QivEZc16dTvXwF X-Received: by 2002:a63:f13:: with SMTP id e19mr2152076pgl.132.1565082883096; Tue, 06 Aug 2019 02:14:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565082883; cv=none; d=google.com; s=arc-20160816; b=Hjp/72LxfYV6Z6GmwO32eju36HGa44fY9u1dTCQTlguZ+v+Xf2PENPo2T2sJPiZ1mu IAmRgaUs2UDu2XusYvXl4sQP8/z6UQlE6jk9Y03fj+NWI8KyWtQWYiZf8dO7qDZaVyac t5p1AhoR6ffzHk315MkqleWnhrRZQ6aDPVfKaUvhdPsYO8eBMv01YY/ndWQHQRU5UVpj jcHcGtzEhXnAGwvU2E7VxetRTgmmP9baK2quSULCYdx3y/OCik+9OtuHec4WGCKbMqyu ar3l+hSJPM/WG5a83ORoe5JbwD3qLb+XqrYrX+/JrcRY5P02rfU6EXRLaTChUCly9sOp OOqg== 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:mime-version :date:cc:to:from:subject:message-id; bh=aZ9l7N/Yt3GDlAVCTUxsmqgXSEFH8nudlYhvJqNyfkk=; b=eRP9JoN/5yav04EluW5tM7HJ3i1S9za/smoMPMZRCgQtL4lnDvphPjiPlLyfuMAx/R A1PdQgqRhb+B4zvhDWNIGshg43Nm3AZ4rHEZpqCxgREyvhowAGyHKl3cbIl4ERlPfZ2D yJsBEfRC4GBxy3sCaqXXae3BacBaaHGxP/NcZGTtslreKekcOGgbtF68wJVgtpvvvHep KnoBC0wfFCWPqOWGXsVwiELWRxgvalfZOsxfnTAJSSi7O2KgRafJZsIW+NV/mxPjTQD7 SpwJ6pS1kzQh+8dYEx5UqhKj568IIZ2WC1xRvRMERars1TeqDximi0tR74G9gSc1SIGR Y7aA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d33si41620461pla.417.2019.08.06.02.14.27; Tue, 06 Aug 2019 02:14:43 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732206AbfHFJNc (ORCPT + 99 others); Tue, 6 Aug 2019 05:13:32 -0400 Received: from metis.ext.pengutronix.de ([85.220.165.71]:40517 "EHLO metis.ext.pengutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726713AbfHFJNb (ORCPT ); Tue, 6 Aug 2019 05:13:31 -0400 Received: from kresse.hi.pengutronix.de ([2001:67c:670:100:1d::2a]) by metis.ext.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1huvX7-00050Y-Ll; Tue, 06 Aug 2019 11:13:29 +0200 Message-ID: <1565082809.2323.24.camel@pengutronix.de> Subject: Regression due to d98849aff879 (dma-direct: handle DMA_ATTR_NO_KERNEL_MAPPING in common code) From: Lucas Stach To: Christoph Hellwig Cc: iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org Date: Tue, 06 Aug 2019 11:13:29 +0200 Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.22.6-1+deb9u2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 2001:67c:670:100:1d::2a X-SA-Exim-Mail-From: l.stach@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Christoph, I just found a regression where my NVMe device is no longer able to set up its HMB. After subject commit dma_direct_alloc_pages() is no longer initializing dma_handle properly when DMA_ATTR_NO_KERNEL_MAPPING is set, as the function is now returning too early. Now this could easily be fixed by adding the phy_to_dma translation to the NO_KERNEL_MAPPING code path, but I'm not sure how this stuff interacts with the memory encryption stuff set up later in the function, so I guess this should be looked at by someone with more experience with this code than me. Regards, Lucas