Received: by 2002:a05:6358:a55:b0:ec:fcf4:3ecf with SMTP id 21csp3591003rwb; Mon, 16 Jan 2023 10:00:13 -0800 (PST) X-Google-Smtp-Source: AMrXdXvOxI52/cOycWsfnagHV5GcvNmd5D1P84c03FkqEwXnsaOwYMTX9/VSg90uZwLWtQENRxTR X-Received: by 2002:a17:903:25c3:b0:18f:a5b6:54f9 with SMTP id jc3-20020a17090325c300b0018fa5b654f9mr662612plb.11.1673892013030; Mon, 16 Jan 2023 10:00:13 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1673892013; cv=none; d=google.com; s=arc-20160816; b=YOsmtzB3kSxQKHPHcATElb8A3fspwYYE+eVIL8KCy0EUu6e3wP1uPLo4smiqhtRBoT f7g585lfI8ukrUAo8X7FiYzcF9/ktpv+TIu9eIJZcnTbwbyurNn+dVhvXsl95U5dApzj BR7mF+Q6bdY/P5YYW75GJ1E9cErZZmVZkAoVTuPnIyMAtTNlJAMtwbVr89XUuoMIxSPG 53xyJCh3pHnhd2WjAXZyvtYyp8rW5jPwAhQeZQ4fkwiMrJvdL4XblDdTmgR9zzKgSom+ jP37tVfzquYtu7c82sbE0BrxqD8NJKj3sWo38X59qrhneIL8Nq+MBAEIlyYIUBHoaT5q WtEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :organization:from:references:cc:to:content-language:subject :user-agent:mime-version:date:message-id:dkim-signature; bh=i8TyWaBK0rrh9nu6bilmDzmOvJpbEYXbLFcWBZyCEYc=; b=ilFZVw9Hx2wO2E6idd2ZxM/CCmldAMARj+QrlPNvV8oFEu/nGpbyqBHmZP6GhXX0nD hRiiah83Ji4QGODQSLHPXVZGJjpN00XOZjf3SgFIzEcRJ0TX+mAkSAyr52Jb4oVlvyQ1 qGNzWMtBAzjzyJ3nYPXJvw3Kp1EqwHlndOom0QzGUBxvWzP3gr/PBH2jWB6bFYqq2K4v 8Sjw327KZGFSBQWO6bS7R3WTjcnGxOUtP+tqVV6ZpYQMmtsyBCv4ZIbsrD/SN3tVoHXq KlvT/3BCeY1o5WwNZEPRZTT1Vqd4rWrwyJi0mf7mDj/VhWaWAtgmjUci8p8uAUkt0Pqr STrA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=btYoZW14; 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=redhat.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id a10-20020a170902ecca00b001899477302bsi33738156plh.588.2023.01.16.10.00.06; Mon, 16 Jan 2023 10:00:13 -0800 (PST) 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=@redhat.com header.s=mimecast20190719 header.b=btYoZW14; 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=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234967AbjAPRf0 (ORCPT + 50 others); Mon, 16 Jan 2023 12:35:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56168 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234953AbjAPRek (ORCPT ); Mon, 16 Jan 2023 12:34:40 -0500 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9C95E2A98C for ; Mon, 16 Jan 2023 09:09:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1673888996; 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=i8TyWaBK0rrh9nu6bilmDzmOvJpbEYXbLFcWBZyCEYc=; b=btYoZW14qvAZqTnIweBrT80H7NLy1vP4Mmc93pCM25DWF/kzpPGZ8GibLd7FYmYLq86++L LFSQPEdYPh1dCNUhOBxY0flmPp2UV8Luq0R2Oh7byCwcV0bxAQZa0I/VsJIHMy5cbxZOr1 bljJkDfF/rEwRyIJKKqHa5wXho+zEJg= Received: from mail-wr1-f70.google.com (mail-wr1-f70.google.com [209.85.221.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-65-E8n6tBmjPRSb0tjaLJJOKQ-1; Mon, 16 Jan 2023 12:09:55 -0500 X-MC-Unique: E8n6tBmjPRSb0tjaLJJOKQ-1 Received: by mail-wr1-f70.google.com with SMTP id u15-20020adfa18f000000b002b129dc55bfso5541055wru.11 for ; Mon, 16 Jan 2023 09:09:54 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:in-reply-to:organization:from:references :cc:to:content-language:subject:user-agent:mime-version:date :message-id:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=i8TyWaBK0rrh9nu6bilmDzmOvJpbEYXbLFcWBZyCEYc=; b=SbwcwTJslViJmHoUg9X3FLKN6n5rVnLrUVu4ldmZdJIj0aecK4xyG4IOHpG3mA2WwN /GQCCuyTBMZ63kpc8nDhWagZ5izkH6ORsG+ZIh8NZe45fKgtfpWa1XJBQiN3Cg77THtw Rg9wE60SIVbdMU+rL3T5yunU/XbXPW8FIFHH4Mq8KMeE8rTFtDDiswLR491Jo6GyqVBw uOYYfOEMP77LxSaoEud2FvGkNc+ES+dOSeggJMhYy2l3ljXjhN8RWvaxK9HVQvpKpZUh RaXGVhz/3J1G0K8zC2DdRsHl5vC8rhz7O1XGxDzkUe8n4D7QIbEziLksDgheOnoELMNS iAPA== X-Gm-Message-State: AFqh2kqLnsq0G8P6GP2rSjq93BAFtu8YyJDREnKCinCH/C4ElOAT1mta ASY10xw6/M6N4ELLr2LDm8xWvB5Orcw736Ejfvvyi7SYHscv39+FWSRCzB9W6kopp9gLHGET/k+ BlUkP2Ht1C6cvOrjyDriGHXD9 X-Received: by 2002:adf:e991:0:b0:2b9:1a52:4f50 with SMTP id h17-20020adfe991000000b002b91a524f50mr8239440wrm.6.1673888994007; Mon, 16 Jan 2023 09:09:54 -0800 (PST) X-Received: by 2002:adf:e991:0:b0:2b9:1a52:4f50 with SMTP id h17-20020adfe991000000b002b91a524f50mr8239421wrm.6.1673888993725; Mon, 16 Jan 2023 09:09:53 -0800 (PST) Received: from ?IPV6:2003:cb:c704:1000:21d5:831d:e107:fbd6? (p200300cbc704100021d5831de107fbd6.dip0.t-ipconnect.de. [2003:cb:c704:1000:21d5:831d:e107:fbd6]) by smtp.gmail.com with ESMTPSA id t13-20020adfe10d000000b002b6bcc0b64dsm14372975wrz.4.2023.01.16.09.09.52 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 16 Jan 2023 09:09:53 -0800 (PST) Message-ID: <06185b08-8440-8922-c0aa-f6fb91aa54e0@redhat.com> Date: Mon, 16 Jan 2023 18:09:52 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.6.0 Subject: Re: [PATCH v2] mm: do not try to migrate lru_gen if it's not associated with a memcg Content-Language: en-US To: Yu Zhao , msizanoen1 Cc: Andrew Morton , stable@vger.kernel.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org References: <20230115133330.28420-1-msizanoen@qtmlabs.xyz> <20230115134651.30028-1-msizanoen@qtmlabs.xyz> From: David Hildenbrand Organization: Red Hat In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-2.2 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,NICE_REPLY_A, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_NONE autolearn=ham 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 On 16.01.23 00:13, Yu Zhao wrote: > On Sun, Jan 15, 2023 at 6:47 AM msizanoen1 wrote: >> >> In some cases, memory cgroup migration can be initiated by userspace >> right after a process was created and right before `lru_gen_add_mm()` is >> called (e.g. by some program watching a cgroup and moving away any >> processes it detects[1]), which results in the following sequence of >> WARNs followed by an Oops as the kernel attempts to perform a >> `lru_gen_add_mm()` twice on the same `mm`: > > ... > >> Fix this by simply leaving the lru_gen alone if it has not been >> associated with a memcg yet, as it should eventually be assigned to the >> right cgroup anyway. >> >> [1]: https://gitlab.freedesktop.org/benzea/uresourced/-/blob/master/cgroupify/cgroupify.c >> >> v2: >> Added stable cc tags >> >> Signed-off-by: N/A (patch should not be copyrightable) >> Cc: stable@vger.kernel.org > > Thanks for the fix. Cc'ing stable is the right thing to do. The > commit message and the comment styles could be easily adjusted to > align with the guidelines. > > I don't think the N/A is acceptible though. I fully respect it if you > wish to remain anonymous -- I can send a similar fix crediting you > as the "anonymous user " who reported this bug. Not acceptable: Documentation/process/submitting-patches.rs "using your real name (sorry, no pseudonyms or anonymous contributions.)" -- Thanks, David / dhildenb