Received: by 2002:a05:6358:4e97:b0:b3:742d:4702 with SMTP id ce23csp374449rwb; Thu, 11 Aug 2022 03:12:15 -0700 (PDT) X-Google-Smtp-Source: AA6agR79OMamFtfiHvPbVwh7Betf0etuB768WDGgl69yIVChn/df5SYkE0ZEtWlZuwZ5IJ3bIjKk X-Received: by 2002:a05:6402:28c8:b0:43e:8622:1c21 with SMTP id ef8-20020a05640228c800b0043e86221c21mr30116277edb.135.1660212735211; Thu, 11 Aug 2022 03:12:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1660212735; cv=none; d=google.com; s=arc-20160816; b=kmqcMvPebofhz5HaTPqenwCYIW2f1LQP2129fSIa6XEpNpWYoiIoCJrWlpEdpHpUnT RknRC3bS1dRwh4/1XUIyRPeSYqElxTzqvjRm9wMyR1EF6SyMCI4EOYexi+aKGim+4TwF SmkPOh7Fi7CEhK4h/ii12oMakT8we9LarSVpdQxHA8RVpgZ5cpdYcjKqfg2drXAUkO9x rbVDvhhnmijFYIEZ3R5OMQIia6061Moyk2LrCBx64tPXyCRGi3wWxjg0zQ/+SBHF2X8N 8UfoEpxWry36dSvDFpmPsD8RYO1o9KsNP4ykhKsg48+qVdNUVwli55B6JbrPRaHBZJ7Q WiDQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=dWyKzLz2TcBn3/083wwRTF/UnryUhfL0gYj8zALd0ew=; b=ETLXZWQhZ59qFn9qBlMSYZ7Yy5XtFtAANUQymP8dwE8liDq9nUvTPe3sc66JgASFh+ sE1SI5ZQ65fn/Vq5xOPZBQhnTDkVxX9S3FKlDt7LWQfVh1INLQjr1MQ8fqZRrrqUDwkx krhRsL7GUX5502o6NgiGBY9okXhjFvN+T7nAr9jC8hmocrmZtzItQqWfCSSIvNvlautv C8tLp5EmvKu0c2ugwyGBsdKhiCMz+z+ccOr54Yb5ZQdR637CqRe35JK1fHbf64KAmzvS um98acQLhgOnFvXWvwKe72EC8CZjQ+vpCSIbq4we9TEoJ7mP29E4J4spXH+Jktzot/ev comw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=gJjJuFdV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o11-20020a170906974b00b007309303da68si5482737ejy.340.2022.08.11.03.11.48; Thu, 11 Aug 2022 03:12:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=bombadil.20210309 header.b=gJjJuFdV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234133AbiHKJUX (ORCPT + 99 others); Thu, 11 Aug 2022 05:20:23 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33358 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233601AbiHKJUW (ORCPT ); Thu, 11 Aug 2022 05:20:22 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5BFE613DD1; Thu, 11 Aug 2022 02:20:20 -0700 (PDT) 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=dWyKzLz2TcBn3/083wwRTF/UnryUhfL0gYj8zALd0ew=; b=gJjJuFdV+xGUVXS9tK7y5/p+a6 hCBZZ71HXTryrtZ7L4LdpCl8vmnq9R0LSCWOMaj37+tjXCqHrdununHIhZtorepox5aacsMeesbIz cV6+SgkNH9J0ZOoL5eGhzyuI6PsdzaMJrhBHtjtWv73ucLmXVILWSKTxU8VoEFYMJGIINkGEqGPkD Kz7cFX6Lii3B9XpIkpa9gLH8Q7XN4UBRen4n94S+psprhPXiYev1F+qVt8/COvMbvofTp+nEjF+U9 qS+qjCkkvxmy05oNA/iUjlxSFuRchSsjwK1aq18+/5fsW8mubfQy1gg1r5LHude8qGyboGz0cXN4U WSXx94GA==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1oM4MP-00AhVE-AU; Thu, 11 Aug 2022 09:20:13 +0000 Date: Thu, 11 Aug 2022 02:20:13 -0700 From: Christoph Hellwig To: Will McVicker Cc: Jingoo Han , Gustavo Pimentel , Lorenzo Pieralisi , Rob Herring , Krzysztof =?utf-8?Q?Wilczy=C5=84ski?= , Bjorn Helgaas , kernel-team@android.com, Vidya Sagar , linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1 1/2] PCI: dwc: drop dependency on ZONE_DMA32 Message-ID: References: <20220809180051.1063653-1-willmcvicker@google.com> <20220809180051.1063653-2-willmcvicker@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20220809180051.1063653-2-willmcvicker@google.com> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_LOW,SPF_HELO_NONE, SPF_NONE,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Aug 09, 2022 at 06:00:49PM +0000, Will McVicker wrote: > Re-work the msi_msg DMA allocation logic to use dma_alloc_coherent() > which uses the coherent DMA mask to try and return an allocation within > the DMA mask limits. This allows kernel configurations that disable > ZONE_DMA32 to continue supporting a 32-bit DMA mask. Without this patch, > the PCIe host device will fail to probe when ZONE_DMA32 is disabled. > + dma_free_coherent(dev, PAGE_SIZE, pp->msi_page, pp->msi_data); Isn't msi_page a struct page * which should become a void * now? Otherwise this looks good and is what the driver should have done from the very beginning.