From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 247E7C433F5 for ; Mon, 24 Jan 2022 09:30:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233802AbiAXJaH (ORCPT ); Mon, 24 Jan 2022 04:30:07 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51612 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233809AbiAXJaF (ORCPT ); Mon, 24 Jan 2022 04:30:05 -0500 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 91728C06173D for ; Mon, 24 Jan 2022 01:30:05 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=+Cbhoao8YGSMbLhLMvHmRWGSewCaoxDNcEjjCdUssKY=; b=G6sqF+8Q7cLOd4wGmirGsKPswL BKg/uDXdGa8RZ7jTwvJQGtb8iZbh2HLDi1ClyvRjkik/iLL3N6JAgQjzmEaO+Yh/N4sfcg1BjnDW+ RARriawQ3akmmVWqwsSY/3T2waQE8FudFuiGrHIW29RUVY66Y+oWfDx9Yl5Mawrn/FuI8yj+/PpIu dEz1meLry+wtMTDeLqG+lW5wIWkD8WHEbOU9y1vYHfyFMQmTwuepUmQseiMWXnJwcyBHvvBIjtM+A 3SrECgTgN19wA0OlVKDbz4RmoZ7PjLEBBTHLZHZDLhEXZ8i08ZdJvedeS4fQG5qbQ6eCM6G0r9vGH Tvscrkpw==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nBvfh-002nXX-9U; Mon, 24 Jan 2022 09:29:57 +0000 Date: Mon, 24 Jan 2022 01:29:57 -0800 From: Christoph Hellwig To: Lu Baolu Cc: Joerg Roedel , Jason Gunthorpe , Christoph Hellwig , Ben Skeggs , Kevin Tian , Ashok Raj , Will Deacon , Robin Murphy , Alex Williamson , Eric Auger , Liu Yi L , Jacob jun Pan , David Airlie , Daniel Vetter , Thierry Reding , Jonathan Hunter , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 5/7] drm/nouveau/device: Get right pgsize_bitmap of iommu_domain Message-ID: References: <20220124071103.2097118-1-baolu.lu@linux.intel.com> <20220124071103.2097118-6-baolu.lu@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220124071103.2097118-6-baolu.lu@linux.intel.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jan 24, 2022 at 03:11:00PM +0800, Lu Baolu wrote: > The supported page sizes of an iommu_domain are saved in the pgsize_bitmap > field. Retrieve the value from the right place. > > Signed-off-by: Lu Baolu > Reviewed-by: Robin Murphy > Link: https://lore.kernel.org/r/20211218074546.1772553-1-baolu.lu@linux.intel.com Looks good: Reviewed-by: Christoph Hellwig Wouldn't it mke sense to remove the pgsize_bitmap in struct iommu_ops and initialize the domain field in the domain_alloc methods? Or am I missing something? From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from smtp2.osuosl.org (smtp2.osuosl.org [140.211.166.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4CCA7C433EF for ; Mon, 24 Jan 2022 09:30:19 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp2.osuosl.org (Postfix) with ESMTP id E676D404AA; Mon, 24 Jan 2022 09:30:18 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from smtp2.osuosl.org ([127.0.0.1]) by localhost (smtp2.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id F5DnKwVb8bIO; Mon, 24 Jan 2022 09:30:13 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by smtp2.osuosl.org (Postfix) with ESMTPS id 0E9D0403CF; Mon, 24 Jan 2022 09:30:12 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id CCF18C0031; Mon, 24 Jan 2022 09:30:12 +0000 (UTC) Received: from smtp1.osuosl.org (smtp1.osuosl.org [140.211.166.138]) by lists.linuxfoundation.org (Postfix) with ESMTP id C211DC002F for ; Mon, 24 Jan 2022 09:30:10 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by smtp1.osuosl.org (Postfix) with ESMTP id A38D582690 for ; Mon, 24 Jan 2022 09:30:10 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Authentication-Results: smtp1.osuosl.org (amavisd-new); dkim=pass (2048-bit key) header.d=infradead.org Received: from smtp1.osuosl.org ([127.0.0.1]) by localhost (smtp1.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id bzQG3PTT-9M6 for ; Mon, 24 Jan 2022 09:30:05 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:e::133]) by smtp1.osuosl.org (Postfix) with ESMTPS id 55A698275C for ; Mon, 24 Jan 2022 09:30:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20210309; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=+Cbhoao8YGSMbLhLMvHmRWGSewCaoxDNcEjjCdUssKY=; b=G6sqF+8Q7cLOd4wGmirGsKPswL BKg/uDXdGa8RZ7jTwvJQGtb8iZbh2HLDi1ClyvRjkik/iLL3N6JAgQjzmEaO+Yh/N4sfcg1BjnDW+ RARriawQ3akmmVWqwsSY/3T2waQE8FudFuiGrHIW29RUVY66Y+oWfDx9Yl5Mawrn/FuI8yj+/PpIu dEz1meLry+wtMTDeLqG+lW5wIWkD8WHEbOU9y1vYHfyFMQmTwuepUmQseiMWXnJwcyBHvvBIjtM+A 3SrECgTgN19wA0OlVKDbz4RmoZ7PjLEBBTHLZHZDLhEXZ8i08ZdJvedeS4fQG5qbQ6eCM6G0r9vGH Tvscrkpw==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1nBvfh-002nXX-9U; Mon, 24 Jan 2022 09:29:57 +0000 Date: Mon, 24 Jan 2022 01:29:57 -0800 From: Christoph Hellwig To: Lu Baolu Subject: Re: [PATCH 5/7] drm/nouveau/device: Get right pgsize_bitmap of iommu_domain Message-ID: References: <20220124071103.2097118-1-baolu.lu@linux.intel.com> <20220124071103.2097118-6-baolu.lu@linux.intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220124071103.2097118-6-baolu.lu@linux.intel.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Cc: Kevin Tian , Ashok Raj , David Airlie , Robin Murphy , iommu@lists.linux-foundation.org, Jonathan Hunter , Christoph Hellwig , Alex Williamson , Thierry Reding , Ben Skeggs , Jason Gunthorpe , Daniel Vetter , Will Deacon , linux-kernel@vger.kernel.org, Jacob jun Pan X-BeenThere: iommu@lists.linux-foundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Development issues for Linux IOMMU support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: iommu-bounces@lists.linux-foundation.org Sender: "iommu" On Mon, Jan 24, 2022 at 03:11:00PM +0800, Lu Baolu wrote: > The supported page sizes of an iommu_domain are saved in the pgsize_bitmap > field. Retrieve the value from the right place. > > Signed-off-by: Lu Baolu > Reviewed-by: Robin Murphy > Link: https://lore.kernel.org/r/20211218074546.1772553-1-baolu.lu@linux.intel.com Looks good: Reviewed-by: Christoph Hellwig Wouldn't it mke sense to remove the pgsize_bitmap in struct iommu_ops and initialize the domain field in the domain_alloc methods? Or am I missing something? _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu