Received: by 2002:a05:7412:2a8c:b0:e2:908c:2ebd with SMTP id u12csp3514624rdh; Thu, 28 Sep 2023 14:08:38 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGE4oeNAcZ7FKsQfxMdX10FRmporDDjTi/x+9Ndir9GdgpdUMogr0Z2KQNDvqLoiKSQuDYh X-Received: by 2002:a9d:6a50:0:b0:6b9:c49f:1af7 with SMTP id h16-20020a9d6a50000000b006b9c49f1af7mr2587687otn.20.1695935318029; Thu, 28 Sep 2023 14:08:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695935317; cv=none; d=google.com; s=arc-20160816; b=GvNmn//01xTqBcpmP+PJjo6eZ8NEl6P/FXsxfANhSWllc42r3CI/5QE2irPmMLhy/2 GK2nfM2CbRBiIJu34AAeCn61IVk7yDJ9j+mcAHopRCwK5DDhNZAJZsUh9izBwM9RojhP RD/6T87v4l0Nt6a7g18rLh7dqfJkI+71O38czyvB2NrA9C18+2R7taL8L2OSDHF2ztgs BtkM5ZzYTTHRndJQLZgJZweylM4PDocx8FoQqYJ10Vxby9I0kG0kBwNt9lcgymybU9Y3 Wds78NSh2aIpf+jGOMYf7nCRO1s1NtVQqAdz8hAs39/Ke7WuMsHNjGJB425XBk6Xfi/Y qInw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=9zsbTfF9OJEO+DfaDPeAgMafTqHcue+0P2xvo3pdbwg=; fh=pKN56LdaWVaD9tFSQohga6DG5zF2kRkEH9UyH6oIiUI=; b=p22Wxk+CVABI1aE7AHKE81FMXWGYcS5Pua8DE+CTNOGcpTfaAP1OBtSsNd+uoVbSbn HNdiwsg0RoxAn5NX+0kDO4YmF29KGRgfoE8KZuTJqbYqcjcP/IjwlBavkxRAEo5//TYR 5VsgMa5FBlqs0lu7Ode7qw45d72PkmIiSJ4aAEKJ1n9LSH/ErymeKQ3CLCQ93GPMVknY HzeeiDhKzpFzNCE91Y8HJJFIODrIpn1qlthT4utkbAAskCqnOEVrH0asMka6hvwm7XqB 4XRjR3bV4lhDXBK8UHOpOfP6tCOaYjHIcVpZsNHeDO895T1pclwQEEPftrxHGYlZKxK1 DYVA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=uP6mOVzO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from groat.vger.email (groat.vger.email. [23.128.96.35]) by mx.google.com with ESMTPS id cu9-20020a056a00448900b00690b8833ccbsi19300929pfb.270.2023.09.28.14.08.37 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 28 Sep 2023 14:08:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) client-ip=23.128.96.35; Authentication-Results: mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=uP6mOVzO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.35 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by groat.vger.email (Postfix) with ESMTP id D3C1383472EF; Wed, 27 Sep 2023 10:14:30 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at groat.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229542AbjI0ROO (ORCPT + 99 others); Wed, 27 Sep 2023 13:14:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49122 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229450AbjI0RON (ORCPT ); Wed, 27 Sep 2023 13:14:13 -0400 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 51AA3A1; Wed, 27 Sep 2023 10:14:12 -0700 (PDT) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 888CDC433C8; Wed, 27 Sep 2023 17:14:11 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1695834851; bh=bTgktVSYX5Ufv9Td8sPF03LeSvA3mKcRwebt1XzVdvc=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=uP6mOVzO86iIZFGZxtuWQQ8i3ED5mEK1L01WNXAg6ZLNKlX1ERE6csTZku3F2GKkg rKY/e9ZqNnAezwK/wZtoQnueVrtsBPAp+F/uyPlr4D+QYbIFtDnY4zsp5YAdxMAINs RZfZyTiDk0Cj+1vv7MRuwM3s4OlVKB226Qzs3irg= Date: Wed, 27 Sep 2023 10:14:10 -0700 From: Andrew Morton To: "Liam R. Howlett" Cc: maple-tree@lists.infradead.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Jann Horn , Lorenzo Stoakes , Vlastimil Babka , Suren Baghdasaryan , Matthew Wilcox , stable@vger.kernel.org Subject: Re: [PATCH 1/3] mmap: Fix vma_iterator in error path of vma_merge() Message-Id: <20230927101410.920fd8a88d2453f5c530aff3@linux-foundation.org> In-Reply-To: <20230927160746.1928098-2-Liam.Howlett@oracle.com> References: <20230927160746.1928098-1-Liam.Howlett@oracle.com> <20230927160746.1928098-2-Liam.Howlett@oracle.com> X-Mailer: Sylpheed 3.8.0beta1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.3 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, NICE_REPLY_A,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on groat.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (groat.vger.email [0.0.0.0]); Wed, 27 Sep 2023 10:14:31 -0700 (PDT) On Wed, 27 Sep 2023 12:07:44 -0400 "Liam R. Howlett" wrote: > When merging of the previous VMA fails after the vma iterator has been > moved to the previous entry, the vma iterator must be advanced to ensure > the caller takes the correct action on the next vma iterator event. Fix > this by adding a vma_next() call to the error path. > > Users may experience higher CPU usage, most likely in very low memory > situations. Looking through this thread: > Closes: https://lore.kernel.org/linux-mm/CAG48ez12VN1JAOtTNMY+Y2YnsU45yL5giS-Qn=ejtiHpgJAbdQ@mail.gmail.com/ I'm seeing no indication that the effect is CPU consumption? Jann is excpecting bogus oom-killing?