From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tony Battersby Subject: Re: [PATCH v2 2/9] dmapool: cleanup error messages Date: Fri, 3 Aug 2018 14:44:54 -0400 Message-ID: <73004881-f6ae-e55e-0a24-5b3dfbd5af88@cybernetics.com> References: <7a943124-c65e-f0ed-cc5c-20b23f021505@cybernetics.com> <20180803162212.GA4718@bombadil.infradead.org> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Content-Language: en-US List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: iommu-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: Andy Shevchenko Cc: linux-scsi , Chaitra P B , Suganath Prabu Subramani , Sathya Prakash , Matthew Wilcox , linux-mm , iommu-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org, MPT-FusionLinux.pdl-dY08KVG/lbpWk0Htik3J/w@public.gmane.org, Christoph Hellwig List-Id: linux-scsi@vger.kernel.org On 08/03/2018 02:38 PM, Andy Shevchenko wrote: > >> dma_alloc_coherent() does appear to support a NULL dev, so it might make >> sense in theory. But I can't find any in-tree callers that actually >> pass a NULL dev to dma_pool_create(). So for one of the dreaded (NULL >> device *) messages to show up, it would take both a new caller that >> passes a NULL dev to dma_pool_create() and a bug to cause the message to >> be printed. Is that worth the special casing? > So, then you need to rephrase the commit message explaining this > ("NULL device is wrong to pass in the first place... bla bla bla"). > Will do. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-qt0-f200.google.com (mail-qt0-f200.google.com [209.85.216.200]) by kanga.kvack.org (Postfix) with ESMTP id 9C2E76B000A for ; Fri, 3 Aug 2018 14:44:57 -0400 (EDT) Received: by mail-qt0-f200.google.com with SMTP id e4-v6so5004919qtj.5 for ; Fri, 03 Aug 2018 11:44:57 -0700 (PDT) Received: from mail.cybernetics.com (mail.cybernetics.com. [173.71.130.66]) by mx.google.com with ESMTPS id d63-v6si979646qva.170.2018.08.03.11.44.56 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 03 Aug 2018 11:44:57 -0700 (PDT) Subject: Re: [PATCH v2 2/9] dmapool: cleanup error messages References: <7a943124-c65e-f0ed-cc5c-20b23f021505@cybernetics.com> <20180803162212.GA4718@bombadil.infradead.org> From: Tony Battersby Message-ID: <73004881-f6ae-e55e-0a24-5b3dfbd5af88@cybernetics.com> Date: Fri, 3 Aug 2018 14:44:54 -0400 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US Sender: owner-linux-mm@kvack.org List-ID: To: Andy Shevchenko Cc: Matthew Wilcox , Christoph Hellwig , Marek Szyprowski , Sathya Prakash , Chaitra P B , Suganath Prabu Subramani , iommu@lists.linux-foundation.org, linux-mm , linux-scsi , MPT-FusionLinux.pdl@broadcom.com On 08/03/2018 02:38 PM, Andy Shevchenko wrote: > >> dma_alloc_coherent() does appear to support a NULL dev, so it might make >> sense in theory. But I can't find any in-tree callers that actually >> pass a NULL dev to dma_pool_create(). So for one of the dreaded (NULL >> device *) messages to show up, it would take both a new caller that >> passes a NULL dev to dma_pool_create() and a bug to cause the message to >> be printed. Is that worth the special casing? > So, then you need to rephrase the commit message explaining this > ("NULL device is wrong to pass in the first place... bla bla bla"). > Will do.