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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4F96DC19F2D for ; Thu, 11 Aug 2022 07:43:50 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id B515E8E0002; Thu, 11 Aug 2022 03:43:49 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id B012A8E0001; Thu, 11 Aug 2022 03:43:49 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 9F03A8E0002; Thu, 11 Aug 2022 03:43:49 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0012.hostedemail.com [216.40.44.12]) by kanga.kvack.org (Postfix) with ESMTP id 8F9A08E0001 for ; Thu, 11 Aug 2022 03:43:49 -0400 (EDT) Received: from smtpin12.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay02.hostedemail.com (Postfix) with ESMTP id 6736512010D for ; Thu, 11 Aug 2022 07:43:49 +0000 (UTC) X-FDA: 79786522578.12.DF52DFC Received: from verein.lst.de (verein.lst.de [213.95.11.211]) by imf29.hostedemail.com (Postfix) with ESMTP id F23AA12017A for ; Thu, 11 Aug 2022 07:43:48 +0000 (UTC) Received: by verein.lst.de (Postfix, from userid 2407) id 4D67568AA6; Thu, 11 Aug 2022 09:43:46 +0200 (CEST) Date: Thu, 11 Aug 2022 09:43:46 +0200 From: Christoph Hellwig To: Michal Hocko Cc: Baoquan He , Christoph Hellwig , Andrew Morton , John Donnelly , David Hildenbrand , linux-mm@kvack.org, LKML Subject: Re: [PATCH] dma/pool: do not complain if DMA pool is not allocated Message-ID: <20220811074346.GA14956@lst.de> References: <20220325122559.14251-1-mhocko@kernel.org> <20220325164856.GA16800@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.17 (2007-11-01) ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1660203829; a=rsa-sha256; cv=none; b=ppD+EuGb+50uApAL4sYLZyXW+kD+b0EEOBwFlAun8BhsaWxhcW/B13BN1XHhCjSuxNLBjm PqfgV/d7heyxqKew5VylYIq5Or2G0qTZrV8BUQqqN/NknS7yfcXo9YYefIhPGlG9aCamfN xxjM56KuQ+W9jjfKkSfVPjB7PYit1/o= ARC-Authentication-Results: i=1; imf29.hostedemail.com; dkim=none; dmarc=none; spf=none (imf29.hostedemail.com: domain of hch@lst.de has no SPF policy when checking 213.95.11.211) smtp.mailfrom=hch@lst.de ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1660203829; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=c4KKHDV/9WDNnpoPV75aV4+5ioWH1tuosu43BLnKGJY=; b=7+g2UPP8aEAV8DSCIOXOuyHPp2ZTn9O7aTa8aMrRN0lqKzLrn4q7nODuWS6S3ZLqVVMeF7 Dt6hKD9QhUxNsmz2iBcmifa/H4/Ei0WlLt7eP6VwWL15g0IdyXG9lW9HnOr2JTw2XOwLiy crW5kqR3I4FNLGAQj1rSU1THofZXyVI= X-Rspamd-Server: rspam02 X-Rspamd-Queue-Id: F23AA12017A Authentication-Results: imf29.hostedemail.com; dkim=none; dmarc=none; spf=none (imf29.hostedemail.com: domain of hch@lst.de has no SPF policy when checking 213.95.11.211) smtp.mailfrom=hch@lst.de X-Stat-Signature: fdtqamu4u5wqx13wkt4swrb7g6s54icw X-Rspam-User: X-HE-Tag: 1660203828-348087 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On Wed, Aug 03, 2022 at 05:44:16PM +0200, Michal Hocko wrote: > Unfortunately generic kernels cannot really know there is any > crippled device without some code to some checking early boot (and I am > not even sure this would be sufficient). But we can know if we need the pool, which is only when AMD SEV is enabled. So we could add a check and skip allocating all the pools including the GFP_DMA32 and GFP_KERNEL ones. I can look into that.