Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp3855900ybb; Mon, 23 Mar 2020 08:56:41 -0700 (PDT) X-Google-Smtp-Source: ADFU+vtlquEgWffkd1R+9+2OQLTuz7bGI0GZvaI7pHnc+W2w8C2mIyBBkLVWqBJh4ANDv9GIhyzO X-Received: by 2002:a9d:64cd:: with SMTP id n13mr18539020otl.274.1584979001486; Mon, 23 Mar 2020 08:56:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584979001; cv=none; d=google.com; s=arc-20160816; b=OlDAHx8WDlt4sBnXVAJoRkfhBkBZvjEKZWDDSuJ4s8UVvFejEk9qR85+rW4gZLinLW twByacU2rPN9RHXBIkPgpnECpqB6BbJOYbFUjMAzyTqNvtYcnUy7asKSrbo/piG+wgVn E1sL5zRTpIei46zKyK9leeSZQA5IIlK4/AHiH3ZaVH37o+OM4YCxp/YI2tRjh81LNKYn k87dZOB7/orQfn+q/04LQTCLEsXcxG8fnxJg74WzRfYzRzabKJEM2w9Y3TJYPYlPongy 1/ayoLI2/NsQ6x9W4vtT79HYEflSw23X0dZYiB2hqn/ZmHkSCDQDE3JzkpAi3uVOAjOn xKeA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=aONbZkW7VTtlNQ7IX/OP6HCvxPbDTjsQv8h6JUzUnHw=; b=Vgu2FcMVmFY7/8ifMvYAuznIjTKWlYWw126twl60GmJsuciVoG4MyQGOxWQHvDmONE 60dbMSFC6Btqi4Rpq0v6e0lnIbUVb6/sonuxegaMoO9DFWM0ciEbWG0naWKKpkm/p948 D3b5wgJcViSz360jJ8WJX4Jyxi1seF19Sq4jiPjsBlozY3vl/QK0HB0ls7yWr2YBnXLO QzynRwskB1pow3xZidEhYa1sbdK6YQc0AySWkL8nRZqZVxkSKJ5w876Cpoorl2Fyyxay dkCdIDAPlB75u5584dJfcj/fbhvhtCEPx3ezmaU3S0Mszy8JFHBS3Xgi8w2WAo6E2gtr pkMA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=DcupFgfR; 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=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id x50si3541761otb.137.2020.03.23.08.56.26; Mon, 23 Mar 2020 08:56:41 -0700 (PDT) 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; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=DcupFgfR; 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=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727261AbgCWPy7 (ORCPT + 99 others); Mon, 23 Mar 2020 11:54:59 -0400 Received: from us-smtp-delivery-74.mimecast.com ([216.205.24.74]:34442 "EHLO us-smtp-delivery-74.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727202AbgCWPy6 (ORCPT ); Mon, 23 Mar 2020 11:54:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1584978898; 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: in-reply-to:in-reply-to:references:references; bh=aONbZkW7VTtlNQ7IX/OP6HCvxPbDTjsQv8h6JUzUnHw=; b=DcupFgfRD/LTA1e5rN6ma/k+cmMcZNVu9B3iwubyfX2QYPS0gJPH2ivaCgV+FxjXEUZNOM ibBSXqpaxa69SWBGNnJAwAMKRqg3Z2IQVPcWfjkZCleJD9CSJOzA0HNu3lfE5qS//Sto75 rHM5a/Qjed83xCfixnZpCTpttGTJQRE= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-285-8D5ohllOMACo1HLXscfZ1Q-1; Mon, 23 Mar 2020 11:54:56 -0400 X-MC-Unique: 8D5ohllOMACo1HLXscfZ1Q-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id D86F6800D54; Mon, 23 Mar 2020 15:54:54 +0000 (UTC) Received: from optiplex-lnx (unknown [10.33.36.220]) by smtp.corp.redhat.com (Postfix) with ESMTPS id F1CC919C4F; Mon, 23 Mar 2020 15:54:52 +0000 (UTC) Date: Mon, 23 Mar 2020 11:54:49 -0400 From: Rafael Aquini To: Michal Hocko Cc: Shakeel Butt , Andrew Morton , LKML , linux-kselftest@vger.kernel.org, shuah@kernel.org Subject: Re: [PATCH] tools/testing/selftests/vm/mlock2-tests: fix mlock2 false-negative errors Message-ID: <20200323155449.GG23364@optiplex-lnx> References: <20200322020326.GB1068248@t490s> <20200321213142.597e23af955de653fc4db7a1@linux-foundation.org> <20200323075208.GC7524@dhcp22.suse.cz> <20200323144240.GB23364@optiplex-lnx> <20200323145106.GM7524@dhcp22.suse.cz> <20200323150259.GD23364@optiplex-lnx> <20200323151256.GP7524@dhcp22.suse.cz> <20200323154159.GF23364@optiplex-lnx> <20200323155111.GQ7524@dhcp22.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200323155111.GQ7524@dhcp22.suse.cz> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 23, 2020 at 04:51:11PM +0100, Michal Hocko wrote: > On Mon 23-03-20 11:41:59, Rafael Aquini wrote: > > On Mon, Mar 23, 2020 at 04:12:56PM +0100, Michal Hocko wrote: > > > On Mon 23-03-20 11:02:59, Rafael Aquini wrote: > [...] > > > > The selftest also checks the kernel visible effect, via > > > > /proc/kpageflags, and that's where it fails after 9c4e6b1a7027f. > > > > > > I really fail to see your point. Even if you are right that the self > > > test is somehow evaluating the kernel implementation which I am not sure > > > is the scope of the selft thest but anyway. The mere fact that the > > > kernel test fails on a perfectly valid change should just suggest that > > > the test is leading to false positives and therefore should be fixed. > > > Your proposed fix is simply suboptimal because it relies on yet another > > > side effect which might change anytime in the future and still lead to a > > > correctly behaving kernel. See my point? > > > > > > > OK, I concede your point on the bogusness of checking the page flags in > > this particular test and expect certain valuse there, given that no other > > selftest seems to be doing that level of inner kenrel detail scrutiny. > > > > I'll repost this fix suggestion getting rif of those related > > checkpoints. > > Here is what I have after I had to context switch to something else > before finishing it. Feel free to reuse if you feel like. It is likely > to not even compile. > I'm OK with it, if you want to go ahead and do the kill. Thanks -- Rafael