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 6FB66CCA473 for ; Wed, 6 Jul 2022 09:03:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230342AbiGFJDd (ORCPT ); Wed, 6 Jul 2022 05:03:33 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:42346 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230296AbiGFJD3 (ORCPT ); Wed, 6 Jul 2022 05:03:29 -0400 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B82B66323; Wed, 6 Jul 2022 02:03:28 -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=MQARnlMToRVEqeLEMG+9wozanL3J51GC/4ROL/yqQsA=; b=tz7RGCpugBXvVFqz6jl03wLVUe OomVJj7+GmEelW2X4/5m9U1uYUtNL4A7HoDzyvoZZw9LUwgoC+hmtVGU0FXZEuqkn0obaHtMeKwcu M9unWnQmfP02x9t+LJukCtXvxQ1XRcHdQaBaU+a9NC4I3YvGujXJR/NiIfJHu1MuItdCfuhUf88xo lAsVQzRv7DRGqszQ6R5CqSkPoDI+uj3qnuDsmUWOD+4hYuMZ9Y9k4SE3ARyz/BR/PZs7geQ3pe5HY UEt/C04JWGAUB/rKxaguwIb1tbE/Te0IMAFutJM8/MlDt+TNuTYBS9gs7JGMnbWr6zfFaclgfQv4P YgEsPKeQ==; Received: from hch by bombadil.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1o90vx-007ayM-Oy; Wed, 06 Jul 2022 09:02:57 +0000 Date: Wed, 6 Jul 2022 02:02:57 -0700 From: Christoph Hellwig To: Tianyu Lan Cc: Christoph Hellwig , corbet@lwn.net, rafael@kernel.org, len.brown@intel.com, pavel@ucw.cz, tglx@linutronix.de, mingo@redhat.com, bp@alien8.de, dave.hansen@linux.intel.com, x86@kernel.org, hpa@zytor.com, m.szyprowski@samsung.com, robin.murphy@arm.com, paulmck@kernel.org, akpm@linux-foundation.org, keescook@chromium.org, songmuchun@bytedance.com, rdunlap@infradead.org, damien.lemoal@opensource.wdc.com, michael.h.kelley@microsoft.com, kys@microsoft.com, Tianyu Lan , iommu@lists.linux-foundation.org, linux-doc@vger.kernel.org, linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org, vkuznets@redhat.com, wei.liu@kernel.org, parri.andrea@gmail.com, thomas.lendacky@amd.com, linux-hyperv@vger.kernel.org, kirill.shutemov@intel.com, andi.kleen@intel.com, Andi Kleen Subject: Re: [PATCH 2/2] x86/ACPI: Set swiotlb area according to the number of lapic entry in MADT Message-ID: References: <20220627153150.106995-1-ltykernel@gmail.com> <20220627153150.106995-3-ltykernel@gmail.com> <10062b7d-f0a6-6724-4ccb-506da09a8533@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <10062b7d-f0a6-6724-4ccb-506da09a8533@gmail.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-pm@vger.kernel.org On Wed, Jul 06, 2022 at 04:57:33PM +0800, Tianyu Lan wrote: > Swiotlb_init() is called in the mem_init() of different architects and > memblock free pages are released to the buddy allocator just after > calling swiotlb_init() via memblock_free_all(). Yes. > The mem_init() is called before smp_init(). But why would that matter? cpu_possible_map is set up from setup_arch(), which is called before that.