Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp206383pxu; Wed, 2 Dec 2020 20:04:50 -0800 (PST) X-Google-Smtp-Source: ABdhPJybdv6FhHMgdjrkLUmwjBmXWb3Ojyg7pfknnL3Ac9AU9LOC7p0hdc86wUYho2sXw5xJbSXB X-Received: by 2002:a17:906:5841:: with SMTP id h1mr603129ejs.77.1606968290685; Wed, 02 Dec 2020 20:04:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606968290; cv=none; d=google.com; s=arc-20160816; b=PbKCOHq/CI72mkgq4rx6zUxnjzLfb6cUPl7JuhfSDJ4uGqIC3ZE8d5ZpQUIYz6tUKG s+gn50KRBwLy2O+SOQzW5Lt5/0g0+q1llrW0EhbWDrxBi7pevDZ7UDPZuVk7mGmyuxdK gyTi4BGRiLsC2pntt+viwmZtos+E2XT2eBPcf1aOzbAM5OdmBzyyy25iql8qEyAXO9zB 8yGr2IDWwBXIR4yPas417lM2+kY1n1ykEchgRdA1iRp7MU3X1y2AonyDmJJBsHXsAfb+ y/Ag4kNcp0n+IvQ9LMdXJxPemO3nwV4EXSEu99w6MQp9AM7G7XDP7P3kO9gH7/8xPqLN JV+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-language:content-transfer-encoding :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature:ai-spam-status:dkim-signature; bh=VyKWDD4E9hu0Vd8/Dim4jzui3HzSDcuQ/KydUdBasL8=; b=BLDcDaJxbhqz0adZWRWVWjE4U1D7V0rqmfJi5dXVQQ9G1PMptN1MxpXnehjuWsT7aj pZBXBQFmkxXhs2MAjHdrZU9zfLtgJqfu0E3x/ynAnvn6nRtcmcqkInOAvlpdogJvdB5P F7sCJSSC+Dk7XWEim3PMT21Nud7M/HSfMstXSYB3rZQp0vVn7uIRvuUjtWaIQA5ufT8e a0m0q8MJulb9p5O9OZ2Ezle11Nv3H/JbaUhSFBkdEG/TZ8qAhZ6Rkb0wBrctAtdE3W75 5BBhApEpftqItlomw3cgoZs0vic90Nl4ydS0y/uJf8jbiXzTKEOy3V/tVPCPTu8zR8FJ QWuQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@mymailcheap.com header.s=default header.b=WGgMxGVh; dkim=fail header.i=@flygoat.com header.s=default header.b=oLQH0UpH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=flygoat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u19si393735ejf.121.2020.12.02.20.04.27; Wed, 02 Dec 2020 20:04:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=fail header.i=@mymailcheap.com header.s=default header.b=WGgMxGVh; dkim=fail header.i=@flygoat.com header.s=default header.b=oLQH0UpH; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=flygoat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727057AbgLCEBg (ORCPT + 99 others); Wed, 2 Dec 2020 23:01:36 -0500 Received: from relay5.mymailcheap.com ([159.100.248.207]:55192 "EHLO relay5.mymailcheap.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726734AbgLCEBf (ORCPT ); Wed, 2 Dec 2020 23:01:35 -0500 Received: from relay1.mymailcheap.com (relay1.mymailcheap.com [144.217.248.102]) by relay5.mymailcheap.com (Postfix) with ESMTPS id 4E7B3260EB; Thu, 3 Dec 2020 04:00:43 +0000 (UTC) Received: from filter2.mymailcheap.com (filter2.mymailcheap.com [91.134.140.82]) by relay1.mymailcheap.com (Postfix) with ESMTPS id 50CE63F157; Thu, 3 Dec 2020 03:59:11 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by filter2.mymailcheap.com (Postfix) with ESMTP id 8988C2A6DF; Thu, 3 Dec 2020 04:59:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=mymailcheap.com; s=default; t=1606967950; bh=pbHmkiVjEYzqhucLk4DY2TPZHGhnZIDgErghBAhOyf8=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=WGgMxGVhnHTXlAlVTAMlS4oc2GTDgisg5Vs4xVp60rhl1FlSA74S4Bz1tmz0+7mQX hxl04SFA11bzNYZLcnewdZycmDifxpaQN/ZAZpat1SKBMsgVCDZAMUe0P8SQylFneY LWz3E/W3fX0P8hzMC+lK5xwMhqIcHrTkSVJ5VUM4= X-Virus-Scanned: Debian amavisd-new at filter2.mymailcheap.com Received: from filter2.mymailcheap.com ([127.0.0.1]) by localhost (filter2.mymailcheap.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 3rb4s9I0KOpn; Thu, 3 Dec 2020 04:59:08 +0100 (CET) Received: from mail20.mymailcheap.com (mail20.mymailcheap.com [51.83.111.147]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by filter2.mymailcheap.com (Postfix) with ESMTPS; Thu, 3 Dec 2020 04:59:08 +0100 (CET) Received: from [213.133.102.83] (ml.mymailcheap.com [213.133.102.83]) by mail20.mymailcheap.com (Postfix) with ESMTP id 710D6400D5; Thu, 3 Dec 2020 03:59:07 +0000 (UTC) Authentication-Results: mail20.mymailcheap.com; dkim=pass (1024-bit key; unprotected) header.d=flygoat.com header.i=@flygoat.com header.b="oLQH0UpH"; dkim-atps=neutral AI-Spam-Status: Not processed Received: from [0.0.0.0] (li1861-199.members.linode.com [172.105.207.199]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (2048 bits)) (No client certificate requested) by mail20.mymailcheap.com (Postfix) with ESMTPSA id 4C3634100D; Thu, 3 Dec 2020 03:58:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=flygoat.com; s=default; t=1606967937; bh=pbHmkiVjEYzqhucLk4DY2TPZHGhnZIDgErghBAhOyf8=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=oLQH0UpHxt1/yDA8aOWTrRLmCNEilsU84LJd8S9oe81b7ZDwYjlzYdYPIB7/f70Zw L1Z2LFfZhr3+mc7lQdgiAdkiuPPmbok875VSbTrSnU19WjJFQud/qO7PWqq6IJomB1 5GEFIwyiEUat+xMy1hglu1JE6if3wJRHDctM4sXs= Subject: Re: [PATCH 2/2] MIPS: Select ARCH_KEEP_MEMBLOCK to enable sysfs memblock debug To: Tiezhu Yang , Thomas Bogendoerfer Cc: linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org, Xuefeng Li References: <1606965544-22611-1-git-send-email-yangtiezhu@loongson.cn> <1606965544-22611-3-git-send-email-yangtiezhu@loongson.cn> From: Jiaxun Yang Message-ID: <9c9af0de-387b-f113-b0a2-c5767c31c16d@flygoat.com> Date: Thu, 3 Dec 2020 11:58:51 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.4.3 MIME-Version: 1.0 In-Reply-To: <1606965544-22611-3-git-send-email-yangtiezhu@loongson.cn> Content-Type: text/plain; charset=gbk; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Rspamd-Queue-Id: 710D6400D5 X-Spamd-Result: default: False [2.90 / 10.00]; RCVD_VIA_SMTP_AUTH(0.00)[]; RECEIVED_SPAMHAUS_XBL(3.00)[172.105.207.199:received]; R_DKIM_ALLOW(0.00)[flygoat.com:s=default]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; R_SPF_SOFTFAIL(0.00)[~all]; RCPT_COUNT_FIVE(0.00)[5]; ML_SERVERS(-3.10)[213.133.102.83]; DKIM_TRACE(0.00)[flygoat.com:+]; DMARC_POLICY_ALLOW(0.00)[flygoat.com,none]; DMARC_POLICY_ALLOW_WITH_FAILURES(0.00)[]; RCVD_NO_TLS_LAST(0.10)[]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:24940, ipnet:213.133.96.0/19, country:DE]; RCVD_COUNT_TWO(0.00)[2]; MID_RHS_MATCH_FROM(0.00)[]; HFILTER_HELO_BAREIP(3.00)[213.133.102.83,1] X-Rspamd-Server: mail20.mymailcheap.com Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ?? 2020/12/3 ????11:19, Tiezhu Yang ะด??: > In the current code, CONFIG_ARCH_KEEP_MEMBLOCK is not set for MIPS arch, > memblock_discard() will discard memory and reserved arrays if they were > allocated, select ARCH_KEEP_MEMBLOCK to give a chance to track "memory" > and "reserved" memblocks after early boot, with this patch, we can see > the following two sysfs interfaces under DEBUG_FS. > > /sys/kernel/debug/memblock/memory > /sys/kernel/debug/memblock/reserved Is this really necessary? memblock data is not really necessary after boot for non-debug purpose. Given that MIPS is widely used in embedded systems which doesn't have much memory, keeping unused data after boot is kinda unconvincing. If you intend to debug that please do it locally. Thanks. - Jiaxun > > Signed-off-by: Tiezhu Yang > --- > arch/mips/Kconfig | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig > index 44a47ad..f65da197 100644 > --- a/arch/mips/Kconfig > +++ b/arch/mips/Kconfig > @@ -9,6 +9,7 @@ config MIPS > select ARCH_HAS_PTE_SPECIAL if !(32BIT && CPU_HAS_RIXI) > select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST > select ARCH_HAS_UBSAN_SANITIZE_ALL > + select ARCH_KEEP_MEMBLOCK > select ARCH_SUPPORTS_UPROBES > select ARCH_USE_BUILTIN_BSWAP > select ARCH_USE_CMPXCHG_LOCKREF if 64BIT