Received: by 2002:a05:6500:1b45:b0:1f5:f2ab:c469 with SMTP id cz5csp352587lqb; Tue, 16 Apr 2024 19:32:05 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVbtkXGCnnAbwFZ+9dMhD15pAKHG4yYuBEYJbGjCBhttb1dLw5NU2X7HOVQxpJfa5Z6t5zyjwYaD1wj06ttOPhEyl5jMiHH4J2AnKF2kQ== X-Google-Smtp-Source: AGHT+IEXRdsydNsLT5zNeGCxruVNfdofclYf2UCf9PuXFVbXp2NE1lK5MWXPErlfI8DaOUgiK0u8 X-Received: by 2002:a05:6a21:328d:b0:1a9:694b:e1f with SMTP id yt13-20020a056a21328d00b001a9694b0e1fmr20295742pzb.2.1713321125383; Tue, 16 Apr 2024 19:32:05 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1713321125; cv=pass; d=google.com; s=arc-20160816; b=f4I8BIShm+porq2RMx6zAbV0ufrpDss4jNvMVps8j/mwysc/IL5sOcoUX1KCgjCQqP zYX+OwkpQ7iHktR2tdWPWU7zUWoXcf+cy/4m5Si4pUUQ10bFlYFqFaoGvLNFISktH1nx jNmIc6AdRrNFdJKfz6SJypVjXB9MCsy+snAXmCxRBB+u92EGWpZMH5ZMyI9+qCaHINNw E0D72jX2luOz63PgeMUVJfcHw+QSRcgP5w7jZg6Ck9L4p3xLWsdUW4K4o20Lihhz9LHy l+ixt/z7vachGZKpPNi54u6ouuCorzxi3SLUvKBl4bzLVp+1edvRWzOWEUxVvCOXYvrd euWg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=user-agent:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :reply-to:message-id:subject:cc:to:from:date:dkim-signature; bh=sLxzFgXT3MHB159K1sbDGa/EUJR7X/HFjnuDr4sEUno=; fh=4jjMOk0EUErUN/11+7M9a+Yqk0fzBy/0P5L8zsidw/g=; b=qb5//UxBN0gz8zdAt3zbb/Eid8EX0lF3qtUKiNGkoJe/DUIFM/yHQIgqY3V0u4pNHB 1bta/NWiTQPgsfUx1i1JBIp1uhZJrIv/6+Ts6KceD2WkUKCIn8h7FX3JSgB/MHZoOevn Rbp7JiLs/b8wL85CCQlRJkdpVYtIlIA6SEJgOZdJtJk5hbU3dqPwKfDJaqV8PQdQsYGE +VCrxCCVzl2GfcY8cwjO1jqeoCcF4TZk/OK9w4JTSbO9gI/Swt2NmF8jHxnQlxmLplhd m70J0g8qM1I0ttJi8CYvM8tca2BhRIupyhzozJfQZP238XqtecxMytZLc2IF+CsG+znW xOCg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=mx4DaGaJ; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-147855-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-147855-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id cd24-20020a056a02079800b005c66a3f3f5bsi10418056pgb.745.2024.04.16.19.32.04 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 16 Apr 2024 19:32:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-147855-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=mx4DaGaJ; arc=pass (i=1 spf=pass spfdomain=gmail.com dkim=pass dkdomain=gmail.com dmarc=pass fromdomain=gmail.com); spf=pass (google.com: domain of linux-kernel+bounces-147855-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-147855-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 49779B210D7 for ; Wed, 17 Apr 2024 02:32:02 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id BFF0663A9; Wed, 17 Apr 2024 02:31:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="mx4DaGaJ" Received: from mail-ed1-f44.google.com (mail-ed1-f44.google.com [209.85.208.44]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 80ECC7F8; Wed, 17 Apr 2024 02:31:51 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.208.44 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713321113; cv=none; b=piAhk+OHFnFhMHQ1mEqTciX9YWwP7V+tmSsBVFM2iVSlsQBF3sr0ddCuXUw6RPcLNlCh0ye9XQY+0g7HsQfD726PT9T0EcP2hPcNr+wcPuEvucNClEFuL3h1cY1nFy76Fco2ei220k8izeJ73VNtwjZI/+F0P6LVzFe8Dv9fdGU= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1713321113; c=relaxed/simple; bh=Bdjzekcy0eGckzdChAQ1WLyEcYZJNaqrGH6nC/2iSUA=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Le62P6pXZZyALnlFrMCMw/UiSQNx1kOXuzJwbMyrWuLWGzcgOSV1ISyJSTYVF+Y/8xOdxCCGgUsrU0reyWcyJ4N6pNVYNaxkfsFAT/4TYGNzPSqGOAHNln9uWgeB0djLLNu40WJGY5IaFaqbyuLX1wGO+KogxHg0oS1d6fFU0rs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=mx4DaGaJ; arc=none smtp.client-ip=209.85.208.44 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ed1-f44.google.com with SMTP id 4fb4d7f45d1cf-570441bc23bso1588346a12.0; Tue, 16 Apr 2024 19:31:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1713321110; x=1713925910; darn=vger.kernel.org; h=user-agent:in-reply-to:content-disposition:mime-version:references :reply-to:message-id:subject:cc:to:from:date:from:to:cc:subject:date :message-id:reply-to; bh=sLxzFgXT3MHB159K1sbDGa/EUJR7X/HFjnuDr4sEUno=; b=mx4DaGaJ7XC4BGfIiWz/ibYYgZX81oYuTM9p8fx0TvPyBiqIAi7TzFADpOivlBGKf+ /1OVn77nh6e7klTCMI+O4y7zLOTL+zfanvTBkfcY3weErhhGS0F3VPWPZphqEhm5lq0+ e9mblRWnOk+uA5kUzRASI/T5IQvDVRIh01WQABom/XOGi7yYlqrmZ09FxfM1YlSp1oTI xTD3q6GSxBlgXhSvLkCMrrdQFMUbC57dQEkOijFEVdddLoWoJ/8To0vFfReIZF4agaCU ffiZfl90KJfIAht4MlTOFq2pIBvmFKONYbJqnv98nIwFIIgKZVAhZViqg3MrRj+wJ+iN 3WWw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1713321110; x=1713925910; h=user-agent:in-reply-to:content-disposition:mime-version:references :reply-to:message-id:subject:cc:to:from:date:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=sLxzFgXT3MHB159K1sbDGa/EUJR7X/HFjnuDr4sEUno=; b=awsPk3f9fbP96dSoYKg2OxXuI9oANyJ0F7NrRIRXZfumLqD3HO/LYHX3v0I41RfvUD 5PXHYkoo/GKEtwNMiK2OQrGn/mNLpFEQaVlPI+pUXx4t5syWbyI+dUe+vrOP7o8R53td f/ki4T+vFMWsNdfDvu6LdAD3OqoyNfHA5yuKVg8xlXPPPOsCaG+sqrSqcUYix2jsTFMO ycg7I/sA77fXh7gO+PzZoF66vuIR1tUn6m6oT+LCpiNPrPoUakDLBIu0gIhRjiBxmv00 9ZB26HDlGyM7i6fEQembQWES6YJVbZfhEe4zA+Qo0pokOKnpEniYAIlmrceLvwhPIWEr Pi3A== X-Forwarded-Encrypted: i=1; AJvYcCUYOeOGXS6oampVWBFEgH5pmfIXiSfUYz+eXCzK9ri8G0fGaCUgZ758qUsCPrhyI6QkemCsBmWY04TFbvrQhugnc2tDaEbkTKrWW0cxnx9x5hgxJ01zIA4ez6KkxLRWRxfUwC22gR9kAQ== X-Gm-Message-State: AOJu0YwgnnEoz1ICSy2vWSi/OR++pA9gdzKCHwnBjIY5yz6YJep5nmra 6RCUD0xSLSQKjK0mjE4j1MnIR+jCo/ksZgAJ37Vy3LWiaX6bWPd+voeP9FOf X-Received: by 2002:a50:c302:0:b0:570:7e4:8e9e with SMTP id a2-20020a50c302000000b0057007e48e9emr7402448edb.15.1713321109214; Tue, 16 Apr 2024 19:31:49 -0700 (PDT) Received: from localhost ([185.92.221.13]) by smtp.gmail.com with ESMTPSA id cn22-20020a0564020cb600b0056e34297cbasm6686274edb.80.2024.04.16.19.31.47 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 16 Apr 2024 19:31:48 -0700 (PDT) Date: Wed, 17 Apr 2024 02:31:47 +0000 From: Wei Yang To: Mike Rapoport Cc: skseofh@gmail.com, robh@kernel.org, saravanak@google.com, akpm@linux-foundation.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, Daero Lee Subject: Re: [PATCH] memblock: add no-map alloc functions Message-ID: <20240417023147.ybefdy6fn5drvq5w@master> Reply-To: Wei Yang References: <20240415142448.333271-1-skseofh@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) On Mon, Apr 15, 2024 at 06:26:55PM +0300, Mike Rapoport wrote: [...] >> + > >This changes behaviour of internal function, what effect will it have on >the users? > >> if (!base) >> return -ENOMEM; >> >> *res_base = base; >> if (nomap) { >> err = memblock_mark_nomap(base, size); Mike One question may not directly relevant to this thread. NOMAP doesn't apply to all arch? I took a look into the direct mapping function on x86, memory_map_top_down(). It seems iterate all available pfn instead of skipping NOMAP range. >> - if (err) >> - memblock_phys_free(base, size); >> } >> >> kmemleak_ignore_phys(base); > >-- >Sincerely yours, >Mike. -- Wei Yang Help you, Help me