Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp3038547ybf; Mon, 2 Mar 2020 21:37:47 -0800 (PST) X-Google-Smtp-Source: ADFU+vsiXC1Z7PKBh9+Db8C6XV+Bq0oQAFcNCi1xlKB6op8ojAh7WI3bShBA19LLsHP7WElPWopE X-Received: by 2002:a9d:2264:: with SMTP id o91mr2169257ota.328.1583213867531; Mon, 02 Mar 2020 21:37:47 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583213867; cv=none; d=google.com; s=arc-20160816; b=ONmqcUyozfDZszt2QV8CMb0IWH8fB2pLuL8HuXjUZCHl8H6DMIs0xULEG2Psfpszfn YMPaGa5Y0pcVDDiEt4p7rMVGug4iVWDghGKr0UmNIGOWWnSlagLkMZYrkAkP+XcptCd4 CcBQad24nlJz5L4cB/xEWKb/dv6GpzWvUxpKrko+iBDOvbg/l0ASyyKj7LKfnMv9munX SCqoURK3SWa1uJWk/KxNuaRtLhKLnqWrv1wbYnTxip+5Ayy3QmHu60fq4yJQwYIVFQ4i 6+tDbLtutgV85NYndabeDN/dz6Fwld91wAsfuZBTsPJst4aX+Qg08kvQjnFSPqwO8g0L 82hg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=Q7h1cCQeQsySShjL531MRuvuqG08yOrWzaSUX5IMpsE=; b=EzfkO3e/f74MJ+/lF1GCcVDlvmwN4aT5Zo9KCXddFcubt0/XFjkDJUQ9LP1SRBgwe8 2azNCCwsZ/L8wRumlGX9aZcP98gKKKOWoUY48Azg4zBYILF6SHjF+ncXNua7u1eb1qO5 sprN6Xa2Sno9JCGbdnEhc9nf2SYY5mg9mvTcjKHXEy51gztIUV1hNHTWjtqhIaNFDu5f aZMne3NOoFgM6Gt1waj+La28Kn4Q8bDscBw/93AKbQMJar4xK4kJoAG9MrrgupcDlyKO /mxbNJ45gl+g8AiFM+TpL3pTvQ8w0gunLzw1vCwNjyHwH/KBrEGzQlCsPRjmmZQCzZKc fEIQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=virtuozzo.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i66si1376578oib.237.2020.03.02.21.37.35; Mon, 02 Mar 2020 21:37:47 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=virtuozzo.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726079AbgCCFhZ (ORCPT + 99 others); Tue, 3 Mar 2020 00:37:25 -0500 Received: from relay.sw.ru ([185.231.240.75]:49750 "EHLO relay.sw.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725554AbgCCFhZ (ORCPT ); Tue, 3 Mar 2020 00:37:25 -0500 Received: from vvs-ws.sw.ru ([172.16.24.21]) by relay.sw.ru with esmtp (Exim 4.92.3) (envelope-from ) id 1j90Ek-0002FN-9n; Tue, 03 Mar 2020 08:36:58 +0300 Subject: Re: + seq_read-info-message-about-buggy-next-functions.patch added to -mm tree To: Andrew Morton , Qian Cai Cc: linux-kernel@vger.kernel.org, dave@stgolabs.net, longman@redhat.com, manfred@colorfullife.com, mingo@redhat.com, mm-commits@vger.kernel.org, neilb@suse.com, oberpar@linux.ibm.com, rostedt@goodmis.org, viro@zeniv.linux.org.uk, netfilter-devel@vger.kernel.org, Pablo Neira Ayuso References: <20200226035621.4NlNn738T%akpm@linux-foundation.org> <1583173259.7365.142.camel@lca.pw> <1583177508.7365.144.camel@lca.pw> <20200302124219.eaf3d18422b76ff2196d9ce8@linux-foundation.org> From: Vasily Averin Message-ID: <90db01f0-e8b4-0acb-cd09-d79825f2c03d@virtuozzo.com> Date: Tue, 3 Mar 2020 08:36:57 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: <20200302124219.eaf3d18422b76ff2196d9ce8@linux-foundation.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 3/2/20 11:42 PM, Andrew Morton wrote: > On Mon, 02 Mar 2020 14:31:48 -0500 Qian Cai wrote: > >> On Mon, 2020-03-02 at 13:20 -0500, Qian Cai wrote: >>> This patch spams the console like crazy while reading sysfs, >>> >>> # dmesg | grep 'buggy seq_file' | wc -l >>> 4204 >>> >>> [ 9505.321981] LTP: starting read_all_proc (read_all -d /proc -q -r 10) >>> [ 9508.222934] buggy seq_file .next function xt_match_seq_next [x_tables] did >>> not updated position index >>> [ 9508.223319] buggy seq_file .next function xt_match_seq_next [x_tables] did >>> not updated position index >>> [ 9508.223654] buggy seq_file .next function xt_match_seq_next [x_tables] did >>> not updated position index >>> [ 9508.223994] buggy seq_file .next function xt_match_seq_next [x_tables] did >>> not updated position index >>> [ 9508.224337] buggy seq_file .next function xt_match_seq_next [x_tables] did >>> not updated position index It should be fixed by following patch-set submitted to Netfilter-Devel mailing list [PATCH v2 0/4] netfilter: seq_file .next functions should increase position index https://lore.kernel.org/netfilter-devel/497a82c1-7b6a-adf4-a4ce-df46fe436aae@virtuozzo.com/T/ >>>> --- a/fs/seq_file.c~seq_read-info-message-about-buggy-next-functions >>>> +++ a/fs/seq_file.c >>>> @@ -256,9 +256,12 @@ Fill: >>>> loff_t pos = m->index; >>>> >>>> p = m->op->next(m, p, &m->index); >>>> - if (pos == m->index) >>>> - /* Buggy ->next function */ >>>> + if (pos == m->index) { >>>> + pr_info("buggy seq_file .next function %ps " >>>> + "did not updated position index\n", >>>> + m->op->next); >> >> This? >> >> s/pr_info/pr_info_ratelimited/ >> > > Fair enough - I made that change. >