Message ID | 20230831171827.2625016-2-joel@joelfernandes.org (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> 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 E40B2C83F35 for <linux-mm@archiver.kernel.org>; Thu, 31 Aug 2023 17:18:36 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 74D0B8D0001; Thu, 31 Aug 2023 13:18:36 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 6FD0F280002; Thu, 31 Aug 2023 13:18:36 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 5033E8D001D; Thu, 31 Aug 2023 13:18:36 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id 3DD208D0001 for <linux-mm@kvack.org>; Thu, 31 Aug 2023 13:18:36 -0400 (EDT) Received: from smtpin22.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id 0D323C03FC for <linux-mm@kvack.org>; Thu, 31 Aug 2023 17:18:36 +0000 (UTC) X-FDA: 81185059032.22.31E9162 Received: from mail-io1-f41.google.com (mail-io1-f41.google.com [209.85.166.41]) by imf16.hostedemail.com (Postfix) with ESMTP id 31767180008 for <linux-mm@kvack.org>; Thu, 31 Aug 2023 17:18:34 +0000 (UTC) Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=joelfernandes.org header.s=google header.b=p3lksU5a; dmarc=none; spf=pass (imf16.hostedemail.com: domain of joel@joelfernandes.org designates 209.85.166.41 as permitted sender) smtp.mailfrom=joel@joelfernandes.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1693502314; 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-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=j/9/PG9jMlcZB3crQaMzRcArzBV6KYUSerMEBj6hrg8=; b=LrC2kJGo8lVBO3+H5B1fiy7pQRtBoEPiltHvLTdA+NqvzTB0Pgz9d+I0FoSIG+YTAY9uCf kLW5LlaW2dsD2u9pF0Yvk1o7B4XLTa7eUJQVwmAdvz93H5oXWNYUt7RWJcIpwEnp/lFTM4 qppW/mhgDIJdK/X/BQtI3pGKz27gVWQ= ARC-Authentication-Results: i=1; imf16.hostedemail.com; dkim=pass header.d=joelfernandes.org header.s=google header.b=p3lksU5a; dmarc=none; spf=pass (imf16.hostedemail.com: domain of joel@joelfernandes.org designates 209.85.166.41 as permitted sender) smtp.mailfrom=joel@joelfernandes.org ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1693502314; a=rsa-sha256; cv=none; b=jEMVx7hENbuVadR5QyuKyowcr2Cg/Az6HMwsxr9lWrrNMCOi3k8zioN19/tLXseHXHoGv2 0kcTq0l38BxhEo5vlu5IOuvKNQiUPEaYUip8/fPWhzu7LgdY5gO9Pc4fdf5J4ghUijW64f oqunPk4knk6+TUculkT4bBz/5W+mRMg= Received: by mail-io1-f41.google.com with SMTP id ca18e2360f4ac-7927952ca67so38875039f.2 for <linux-mm@kvack.org>; Thu, 31 Aug 2023 10:18:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; t=1693502313; x=1694107113; darn=kvack.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=j/9/PG9jMlcZB3crQaMzRcArzBV6KYUSerMEBj6hrg8=; b=p3lksU5ah9iAUSDpu74O0Ka/+P77QBhTmQxnsSXN5yCYAlrrR9PpYFdGeIOuH8rYU3 qgRTcCm5fUiNFcfjCuMqSoL0cfYYXKuZHIHG29IMXVLeFCVDX+v2xlmVAUF/OQKXujHx 6HA8jimgbG1d3El9IwN7akBbw9hTL6Uria90w= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693502313; x=1694107113; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=j/9/PG9jMlcZB3crQaMzRcArzBV6KYUSerMEBj6hrg8=; b=dWZSWbARpioAPHAYtj2GUqYWvX3GUnD0L0r0u62bVl2ZMPT+cHnSjsLjv45vBa0K1n dWZRs+kdgVjJJznf8qWAPY1FYBhAVFBe1QcXiJkE07JAIgSqgyj9eOBU3UelHjwBz8Gs Ss9UobCCja/LhAk5s8o0zWdxHxH58Kd0m2xM+F1RsKuAnhZmy7Y0Y/dGOpq8lK3ZWeAU zp5RAczhzPjdnlOTAi3OCk5iJxNVSV+hy/Gk6ySLfvjIgqAlB4fIKmvG3ow8P2qLmqlN I9SnKr/SDFFK6WkFaAdBsuQg0OA6qGl3d5Pqs7Cyu2iYbVKVfWF4SS6UZnAk4SO+AZ3s r77A== X-Gm-Message-State: AOJu0YxBduJHWH8XbSmWKSVpJF5sAAgwjWecMbTEXQXmgdaFifkXXRuB 6PU1RoErKlOAM/3mtY8xsN6r/Q== X-Google-Smtp-Source: AGHT+IHcox5PcaIvs7MVFvtB0jCP2GW2W8V6QqMbhxRIywTxp3y1gSk6Bn/EIRCUTsCRwW8btiaIxA== X-Received: by 2002:a05:6602:370a:b0:792:4d29:ecc7 with SMTP id bh10-20020a056602370a00b007924d29ecc7mr6959672iob.15.1693502313379; Thu, 31 Aug 2023 10:18:33 -0700 (PDT) Received: from joelboxx5.c.googlers.com.com (156.190.123.34.bc.googleusercontent.com. [34.123.190.156]) by smtp.gmail.com with ESMTPSA id a16-20020a056638019000b0042af069eeefsm489720jaq.50.2023.08.31.10.18.32 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 31 Aug 2023 10:18:32 -0700 (PDT) From: "Joel Fernandes (Google)" <joel@joelfernandes.org> To: linux-kernel@vger.kernel.org, Andrew Morton <akpm@linux-foundation.org> Cc: Zqiang <qiang.zhang1211@gmail.com>, Zhen Lei <thunder.leizhen@huaweicloud.com>, "Paul E . McKenney" <paulmck@kernel.org>, rcu@vger.kernel.org, Matthew Wilcox <willy@infradead.org>, Joel Fernandes <joel@joelfernandes.org>, linux-mm@kvack.org Subject: [PATCH v2 2/2] rcu: Dump vmalloc memory info safely Date: Thu, 31 Aug 2023 17:18:26 +0000 Message-ID: <20230831171827.2625016-2-joel@joelfernandes.org> X-Mailer: git-send-email 2.42.0.rc2.253.gd59a3bf2b4-goog In-Reply-To: <20230831171827.2625016-1-joel@joelfernandes.org> References: <20230831171827.2625016-1-joel@joelfernandes.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Rspam-User: X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: 31767180008 X-Stat-Signature: mj79kqxohgewkutnpnt4xj7ynjwquutw X-HE-Tag: 1693502314-632617 X-HE-Meta: U2FsdGVkX19ZmxzfOSCaOE+IxajxelId1A/PTh32wC7EXgYE968Wk0ndP+QiQZ4cSU5wUCdInEtdONr6/wm7AXe5pJZmHnikaC+VKdqqLtcicq8XutOnJE7dcTIH5KCSB4qhjCCgKh/zeHnT5o+m/cS8G0JGCXPRBVpDthwerWa+bTGWsYOunUW43YQuDpFzSk5nHlOOJ3XfYfxuocx4aVaCPyvh7dsk6KpcayQBw5JciFIG5Zs2OmS1dbtCgIRCyO7A/2ijvLnXcq8IYGRwiMp9ZSOS52hSDxTIc9HUrr426uGnuEVRa9HNUSeaDgEPbTURt/YBAsjxKO8XXwCPvp7uzhxqscEkJwf3+/X8ugX7Tqon41xKQqKbbV6hNkSWTickXT5+iJFtD8iHGPO4e2UyUnGLVL6swszD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pPTAWFHBc5iJ06/1t/Ih0OPuQoOVjfQO0ynH8Y9ubKEVelz12Y/d/ooVGOsGCjwJaglkUfPB0zUka+pDFP/bhxawBHIHojZGKbBcOKtjHjJczMERxCIOFJdWBa+7qzypPufbxBqkZr5UDqdXoXpCgzmnNUDcheZNmKeLQwF9duykWrK0vg80z30noBqB4/YRaLcj1dLt5f3jvMtLYwG89sbIfw76dL77RW 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: <linux-mm.kvack.org> |
Series |
[v2,1/2] mm/vmalloc: Add a safer version of find_vm_area() for debug
|
expand
|
diff --git a/mm/util.c b/mm/util.c index dd12b9531ac4..406634f26918 100644 --- a/mm/util.c +++ b/mm/util.c @@ -1071,7 +1071,9 @@ void mem_dump_obj(void *object) if (vmalloc_dump_obj(object)) return; - if (virt_addr_valid(object)) + if (is_vmalloc_addr(object)) + type = "vmalloc memory"; + else if (virt_addr_valid(object)) type = "non-slab/vmalloc memory"; else if (object == NULL) type = "NULL pointer";