From patchwork Wed Jul 3 21:29:11 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Xu X-Patchwork-Id: 13722797 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 59227C2BD09 for ; Wed, 3 Jul 2024 21:29:31 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 486CD6B0088; Wed, 3 Jul 2024 17:29:30 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 40EC46B008A; Wed, 3 Jul 2024 17:29:30 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 2B0586B008C; Wed, 3 Jul 2024 17:29:30 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 059496B0088 for ; Wed, 3 Jul 2024 17:29:29 -0400 (EDT) Received: from smtpin02.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id A30841606D3 for ; Wed, 3 Jul 2024 21:29:29 +0000 (UTC) X-FDA: 82299732858.02.168FBCA Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by imf15.hostedemail.com (Postfix) with ESMTP id 93CB1A0005 for ; Wed, 3 Jul 2024 21:29:26 +0000 (UTC) Authentication-Results: imf15.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b="fesftc6/"; spf=pass (imf15.hostedemail.com: domain of peterx@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=peterx@redhat.com; dmarc=pass (policy=none) header.from=redhat.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1720042142; 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:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=xrFUBbcc9D0ORnx0qoNz81Y3Ewmb+xGo+hBykZs/BiM=; b=2v9GYzbj4Gq+Fjp9O2t/yC03iJQ1xRaLhJcwnqJ3xqrkHbMCCAtmuUFKb2V2pPrz8KAWAR 57y+aVwi1pnAzKUSaFJxbYfBRd2+i0GrG0XVAJgPS0xsum20xv6/cAcxSbBcbkf3yz2UxJ 6wWM9NijYRyOHEJBz7wFZ3WB4CG4fTA= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1720042142; a=rsa-sha256; cv=none; b=3fqvOak7thRchiWcl5mt2BcHNmEfBLpTVvz4TGGiYbfdyuj3+y/U5brolQttbrkYvCQ2yE 1W43ET4Ot5Y+AVDtN873PMfEecyIWLqbYkfjn0vL23hkPJhFaQtWfnMaXfnMBtOkOxIyQU RQJMROsfYXub5mFYxfNlJ36ujnx37aw= ARC-Authentication-Results: i=1; imf15.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b="fesftc6/"; spf=pass (imf15.hostedemail.com: domain of peterx@redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=peterx@redhat.com; dmarc=pass (policy=none) header.from=redhat.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1720042165; h=from:from: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:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=xrFUBbcc9D0ORnx0qoNz81Y3Ewmb+xGo+hBykZs/BiM=; b=fesftc6/Q1IKz3esFPW/XG/zN1kDCswfyRrfI7Wu2mHmRw91mQxvMBIAEI1o4men3YwgPf sfjwCZNLDmyRPe1xi45QUIqwu3IlqyKySckwQyVfITVX2863QFYar7yh0X/8wNbB/f8SWU Rf0eIp3A+094Jn1jy49b+FXPvSqFA6k= Received: from mail-qt1-f198.google.com (mail-qt1-f198.google.com [209.85.160.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-3-zroENq4WM6iNumvo7Rx7eg-1; Wed, 03 Jul 2024 17:29:24 -0400 X-MC-Unique: zroENq4WM6iNumvo7Rx7eg-1 Received: by mail-qt1-f198.google.com with SMTP id d75a77b69052e-446405b39baso4234271cf.0 for ; Wed, 03 Jul 2024 14:29:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720042164; x=1720646964; 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=xrFUBbcc9D0ORnx0qoNz81Y3Ewmb+xGo+hBykZs/BiM=; b=F88ioBV+9v+EGVoJLCTe8/f853I31gZ8CfWOLcdRQrYSVc9x14TUgVgOPgnRZ+dUeb +tPXztAGo6x2sy8pwiNKHgRskVVTWJ8eZ8p4cCOYHAHrL9tY51owoEdA/UYPkpkBivQi CH+cFvy+q5M9/ASCN1X1Yz8ieWKnQskolrcq7mHiTSU4y3ZRn+QjAo9lUtz02YKJdUtP IxvzKFBnAhvp6pKS76D6f0oKFuUdH/tjHjRJCcoH631UFLDGy0QGC30BH/PCziw6Yc/T ahNdiaFumsYi4KoOa/5dWIiNrzXkcIeubW1hzDuaDMt9OZxFY+Bvjix4aK6aIs5KgOkV cM8Q== X-Forwarded-Encrypted: i=1; AJvYcCXKioGm5dnfuuyjfWULf9O1zarGSvRCCr3bMVslLjc2KrbUVkOYjAQkX6p+RaW6ryIrj5CJCkorLa/yVdh0yoD/BrQ= X-Gm-Message-State: AOJu0YxaKaEa1RX9MvNXdoYUY8D3e73sgylV9hG8KSG8A0vXmpJg911l 9nsk+sd4jLZasrd8jPpqg2I25/VGLfL1J4B2J61bmr2aqRFSTEgbMB2G+9/9Lg8QgUmZw2JzVfx VJYoU/4gcZmhnDcIV+eh55/ICgD4K1FKF28pOQs/aMB/iF8b7 X-Received: by 2002:a05:622a:20f:b0:446:395a:37c9 with SMTP id d75a77b69052e-44662e3a591mr137075611cf.4.1720042163850; Wed, 03 Jul 2024 14:29:23 -0700 (PDT) X-Google-Smtp-Source: AGHT+IHMTQtKzW3HcLgwCHDxSHbcORdQ9cM6uS4LGBZ0J8HIBqay3DdOq6gf2nTNP/Qtw7gCSEI+OA== X-Received: by 2002:a05:622a:20f:b0:446:395a:37c9 with SMTP id d75a77b69052e-44662e3a591mr137075451cf.4.1720042163442; Wed, 03 Jul 2024 14:29:23 -0700 (PDT) Received: from x1n.redhat.com (pool-99-254-121-117.cpe.net.cable.rogers.com. [99.254.121.117]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-4465143eb1csm54337481cf.57.2024.07.03.14.29.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 03 Jul 2024 14:29:22 -0700 (PDT) From: Peter Xu To: linux-kernel@vger.kernel.org, linux-mm@kvack.org Cc: Matthew Wilcox , Mel Gorman , Dave Jiang , linuxppc-dev@lists.ozlabs.org, Michael Ellerman , Rik van Riel , Vlastimil Babka , Nicholas Piggin , Christophe Leroy , Andrew Morton , Huang Ying , Oscar Salvador , "Aneesh Kumar K . V" , Thomas Gleixner , Dave Hansen , x86@kernel.org, Ingo Molnar , "Kirill A . Shutemov" , Dan Williams , Borislav Petkov , peterx@redhat.com, Hugh Dickins , Rick P Edgecombe Subject: [PATCH v2 1/8] mm/dax: Dump start address in fault handler Date: Wed, 3 Jul 2024 17:29:11 -0400 Message-ID: <20240703212918.2417843-2-peterx@redhat.com> X-Mailer: git-send-email 2.45.0 In-Reply-To: <20240703212918.2417843-1-peterx@redhat.com> References: <20240703212918.2417843-1-peterx@redhat.com> MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com X-Rspam-User: X-Rspamd-Server: rspam04 X-Rspamd-Queue-Id: 93CB1A0005 X-Stat-Signature: nadp3yx6hpsgbhgbtmxsj4ggdoqfxipn X-HE-Tag: 1720042166-703463 X-HE-Meta: U2FsdGVkX1/+QFwQ2Do/tKYZ3phBlEbvfR8RV5fpWDoiqFI00HUUM1/CDLs+ZZRGy3SBgMC3dGw8YGTmTD50ZybuX0rBTlJh6cL0jpF8UfGiUvvwP+71jzLNa68olyVnoaf1TCKxzBXk9ITAxnixrQsvDUPUJT/2jN5IfiLEbCPm0GIxxIO4o7jGWL9e/vb4oAmfzmHzNGqExN+lTynBkiBawA2dUnBnuVQS9ssdcPIi3ZAwy/M07X8mnaNTwgaIOXiS62S+KYd6GXKAJM1g7Kp0iXNIW5m30JN55p9guANQ77FdhNJKWoB6NGPYvtSlasn8kysapRI3T+7lRRoNZLLxJC1djLKBEhVbOmTgNOdCgsusgioQD7xByhy3+mWtBxveQeUFpRaiU0ejuVi6Zl494j/VSrSEqIHId3FzSkpDDJ+C4VYVkQ/+Dv/UlO1QclA5jAU4yvOdqM2F8LF2y68p212snGf9w/9UPozfq9mhCxpjJx0AH6yEwqoHXgzPwxVgA9N3J54oK+UBdyZPQBZaCvT8mYPEHWxJOxiqZIi/DY9ln+x6E30u9VVcre1r5Tyei92PfUF4Q/CkOiSJmvu6OsfQtYwPFyWBPy77NJvuv4oPEFjidxKNmiBrtvblOHlgnidk8yUC8ee62lUUrfUhjKujVW0puBJvzmBw0rvL6pQF+aE/qIhc40iGvFbyJYuRRElorP3fsFU/QknIRnpBQZVXvWltDGqMcc3cjbEfYBbqFrAPGZ0jLRqEjDHOiM+VAx8WIKu4uiXUISHGGnZ7cA/x+BarT4xt9CTO0Z1O+k8L+E5UIxuEcLDKJZA5nGWkP9Uzrr9bGd+RGdIo21v3QhtcGwqKiGBhIPc7gC1GlHeYxPuzVyz3Boqg4yeFPzS9YWxmKuycCyKwPNcXtcGZs9JxfgRvZ/Pharpb4xQuXcUxyNrt9iag4x7/AYgyRfiryL3HGoKjRzktiLa oTPO0CE7 4cTatIZ6681jZEpB7Pc+HBjRbox0IKBonI54Kxtf2Ka3aIraQYtrZ2fplOJKE8lSM3qTKHQ1JLqI0Sh9s8JKWIRhQpWwZatxdB2Yqx6KiTb82Pooh49WC+RENxPUf0hWR2knPGLgD+tOv6AQBXGSJLfit2zg4/ph0FUX05+Ww8rEE7ImH8hHkI8diZnRCO/onSvtmG2pisCakG8lQ8uk1Ti/9JDoK+iFHTTKkZ+JYRjaHNgV2cmZ/uG53BBNJE8u5nlrp/bI+EkENRioKVqQbg+XzB5EV8ktQk+EMMZbtWdy3TF46SR4GRlMe8bvmdcFSUNsTtA8LNezemjpMfaxi0/AAMg== 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: List-Subscribe: List-Unsubscribe: Currently the dax fault handler dumps the vma range when dynamic debugging enabled. That's mostly not useful. Dump the (aligned) address instead with the order info. Signed-off-by: Peter Xu --- drivers/dax/device.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/dax/device.c b/drivers/dax/device.c index eb61598247a9..714174844ca5 100644 --- a/drivers/dax/device.c +++ b/drivers/dax/device.c @@ -235,9 +235,9 @@ static vm_fault_t dev_dax_huge_fault(struct vm_fault *vmf, unsigned int order) int id; struct dev_dax *dev_dax = filp->private_data; - dev_dbg(&dev_dax->dev, "%s: %s (%#lx - %#lx) order:%d\n", current->comm, - (vmf->flags & FAULT_FLAG_WRITE) ? "write" : "read", - vmf->vma->vm_start, vmf->vma->vm_end, order); + dev_dbg(&dev_dax->dev, "%s: op=%s addr=%#lx order=%d\n", current->comm, + (vmf->flags & FAULT_FLAG_WRITE) ? "write" : "read", + vmf->address & ~((1UL << (order + PAGE_SHIFT)) - 1), order); id = dax_read_lock(); if (order == 0)