Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp1590397rwr; Wed, 26 Apr 2023 18:17:05 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7ds+pJ+tLMckxkGdGVzMh0Z9vVAvdZOGBKQVEBSDZjug77kMhJbD5XkUYJ2WdS6wQ+Mrbx X-Received: by 2002:a17:90b:90b:b0:246:aeee:e61c with SMTP id bo11-20020a17090b090b00b00246aeeee61cmr261385pjb.11.1682558225630; Wed, 26 Apr 2023 18:17:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682558225; cv=none; d=google.com; s=arc-20160816; b=AAwVIVRwBsi4XakmLCqavCnku5i3LJrhlJl6/pfnYoUm+RRvOiPpSyFS+sPj34Iueu NYvIF8Q3SXroEJeyjh50LGy3SwqtNVyeSEOgqJqVyzz3U19uW00pEJMAHPvaDgPlGLja nJfpd4Nrsa6eA9hgMfVi8WIu+8QCFakL9U+vEIsnOB3wxIA2dd9AmJx66VfBPPwbU6No 27x3IY0CchpE7GWSQbo8YpaveZ0Ru8xTm1NUqVbiw+VU4SEwU3ZF1Kyc8uDCWoeTviLr GGSEtTJY0Arpq4PHC+DKquxBiPPmyLCswVVWDXbWIWtze1WleveBvMHZoCOxucCS+1c8 2+wg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=yWxN0HdpqE3nEcb94tpVaWre2EJjXxzqj1V4BeiGr4k=; b=DuvZY5yLMlFjKHa9RUkvv8xJtBNuBDCaaRxOql/zj1mc64xZuOrzk4x/7XhTUySAxn B96aSflOZFFgs6UzEdvBhJ89PX/PKzNY5NSWkhb1FzE49QKGZO6O9WroB9wF03+R2yui KyQ5cQVBQAWeHi/Sdn8el6/9MWKf5wAVmZCUcgTM+o8G7cbacWtdL56/HonPwd90w/Wq YYtFCSSEKidFnrAhV5MYwVkQXd4EDftIJguEqnUFTOpv4vwR8hUoeAiwhSP+Rsm44j4n FQV63NhXrwWb3jDC8fevy0Bn6zM0Bnko+EUMbZMYbFvcMjR8aQIYPN4ctOJvYK4sARSw ok7w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=BrybM128; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id p1-20020a17090ab90100b00247bb17038esi19773945pjr.118.2023.04.26.18.16.54; Wed, 26 Apr 2023 18:17:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=BrybM128; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242772AbjD0BHQ (ORCPT + 99 others); Wed, 26 Apr 2023 21:07:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38576 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242745AbjD0BHP (ORCPT ); Wed, 26 Apr 2023 21:07:15 -0400 Received: from mail-pf1-x42c.google.com (mail-pf1-x42c.google.com [IPv6:2607:f8b0:4864:20::42c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5A33FC0 for ; Wed, 26 Apr 2023 18:07:12 -0700 (PDT) Received: by mail-pf1-x42c.google.com with SMTP id d2e1a72fcca58-64115eef620so1328657b3a.1 for ; Wed, 26 Apr 2023 18:07:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1682557632; x=1685149632; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=yWxN0HdpqE3nEcb94tpVaWre2EJjXxzqj1V4BeiGr4k=; b=BrybM128LAejQm/ZuKmsObyOmzrekJywBAYczMNylmOnjlsv2GAVaZnzT7mtEehlbs edNstU+IQ8nuuM/bsPh5eDUexDY5FDVJYEktDHcOJ/2R7qmryTU4RvyKMs4FwdGWW64y yxgZC7mizG9nQokYNIColNjB55kxHhnxOZIXI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1682557632; x=1685149632; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=yWxN0HdpqE3nEcb94tpVaWre2EJjXxzqj1V4BeiGr4k=; b=iWW7lDlnxKTjRoKMlKPN8puiLDr7UgPnZEVi5vtrS670rtcJPdBInfV5bFBEES/mHs h7pN49nfqZUAVtO47RVVJ/X4WpUQuff6oHEoqANIH8fy41TTA57/jKhQSu0lhJVnOI92 hsghuQQaE0ocK5XbFV33skSwihO7yt5Pyh3o5wxnvQWT2KIB9SmWDdWmSCtEUJIQag5l dOKxTUWc6gMVV7RAOOdr8KmLqxEWdUxKm1Ct7J1IXlpKy89secSCbw31VWmChFLXfUkR sQvu2nV+t+Sfk67r5m9tbPTWm2oo84T+a7uaYZben/rMazk99qg+ymss0CVHh1wLALYR SSnw== X-Gm-Message-State: AC+VfDzjmOMXMldN2MDUidYCP+NfhGvnCqGfphxoyqzHcK7bpdyzblqa o5H4k/KzNEy7ufEQj4wHw7Ij/A== X-Received: by 2002:a17:902:e74e:b0:1a6:7ea8:9f4f with SMTP id p14-20020a170902e74e00b001a67ea89f4fmr153135plf.26.1682557631694; Wed, 26 Apr 2023 18:07:11 -0700 (PDT) Received: from google.com (KD124209188001.ppp-bb.dion.ne.jp. [124.209.188.1]) by smtp.gmail.com with ESMTPSA id q19-20020a170902bd9300b001a5000ba26esm10448485pls.264.2023.04.26.18.07.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 26 Apr 2023 18:07:11 -0700 (PDT) Date: Thu, 27 Apr 2023 10:07:07 +0900 From: Sergey Senozhatsky To: "Liam R. Howlett" Cc: Andrew Morton , linux-kernel@vger.kernel.org, linux-mm@kvack.org, maple-tree@lists.infradead.org, Petr Mladek Subject: Re: [PATCH 18/34] mm: Update vma_iter_store() to use MAS_WARN_ON() Message-ID: <20230427010707.GG1496740@google.com> References: <20230425140955.3834476-1-Liam.Howlett@oracle.com> <20230425140955.3834476-19-Liam.Howlett@oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230425140955.3834476-19-Liam.Howlett@oracle.com> X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FSL_HELO_FAKE, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Cc-ing Petr On (23/04/25 10:09), Liam R. Howlett wrote: > + if (MAS_WARN_ON(&vmi->mas, vmi->mas.node != MAS_START && > + vmi->mas.index > vma->vm_start)) { > + printk("%lx > %lx\n", vmi->mas.index, vma->vm_start); > + printk("store of vma %lx-%lx", vma->vm_start, vma->vm_end); > + printk("into slot %lx-%lx", vmi->mas.index, vmi->mas.last); > } [..] > + if (MAS_WARN_ON(&vmi->mas, vmi->mas.node != MAS_START && > + vmi->mas.last < vma->vm_start)) { > + printk("%lx < %lx\n", vmi->mas.last, vma->vm_start); > + printk("store of vma %lx-%lx", vma->vm_start, vma->vm_end); > + printk("into slot %lx-%lx", vmi->mas.index, vmi->mas.last); > } Any reason for "store of vma" and "into slot" to be two separate printk()-s? It's not guaranteed that these will be printed as a continuous line. A single printk should work fine: pr_foo("store of vma %lx-%lx into slot %lx-%lx", ...); The line probably needs to be terminated with \n unless you expect more pr_cont() printks after this, which doesn't look like a case. Additionally, do you want to pass a specific loglevel? E.g. pr_debug()?