From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 41294C4332F for ; Thu, 13 Oct 2022 17:01:39 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id C69376B0071; Thu, 13 Oct 2022 13:01:38 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id C190F6B0073; Thu, 13 Oct 2022 13:01:38 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B07DB8E0001; Thu, 13 Oct 2022 13:01:38 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0014.hostedemail.com [216.40.44.14]) by kanga.kvack.org (Postfix) with ESMTP id 9E6486B0071 for ; Thu, 13 Oct 2022 13:01:38 -0400 (EDT) Received: from smtpin24.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 6B13C1A0F86 for ; Thu, 13 Oct 2022 17:01:38 +0000 (UTC) X-FDA: 80016542676.24.E1EB472 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by imf25.hostedemail.com (Postfix) with ESMTP id D9FBAA0030 for ; Thu, 13 Oct 2022 17:01:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1665680495; 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=5ehGBuNc1sbQm4mu6rU843gW1LNmhGziTZ5r1rpb2d4=; b=Qfey8R4h8h9N0C2HJ+X647hvUYQ52M8KWGR8KyY7/qLAcCjjBMO6O4VeQWf9VX9unOQLhS VhFORZ5OYpdFyBidIPOHse3RzLRfBBapZCwHWGYWqNpPzancoVjTcacZB+qJpVDMY8GW3f LWjFUiFVcHfW4anHOzPnOxcf5KJzNTM= Received: from mail-wr1-f69.google.com (mail-wr1-f69.google.com [209.85.221.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_128_GCM_SHA256) id us-mta-216-ZEcABfMSPxCp8iHkaVkmEQ-1; Thu, 13 Oct 2022 13:01:34 -0400 X-MC-Unique: ZEcABfMSPxCp8iHkaVkmEQ-1 Received: by mail-wr1-f69.google.com with SMTP id d22-20020adfa356000000b0022e224b21c0so808417wrb.9 for ; Thu, 13 Oct 2022 10:01:33 -0700 (PDT) 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=5ehGBuNc1sbQm4mu6rU843gW1LNmhGziTZ5r1rpb2d4=; b=4/LUsgWdXeEuoPWsrWnXXqLe5thhMTASFFv0L1gRxF4wDHRAVmbYR2QPNnY0QiykrJ 2TpXehNDrErW58mrggueye+t7ks2UUK/GceowhvK2aE5+Swr1hb03pjiWnkwbgn0QQLo cdX701fo7EFx4+8HFGPhwHzGlrHPhvQU6Gd2Vrdv6PiUfdqEBgJD/+SQPk3qVdzhfEoq ElEhLqqtZ97y4Ilum4K1OcWYppa5ksCBiFpEW8mGjur54ve19m/n786EHy3MBrRzGldR naUWE6AGe3E8S+zirChuJJ3eioPblxT8ELfQVToKnytvmSIKwmkVQcV4u/SGu2md5yzJ yhIw== X-Gm-Message-State: ACrzQf17YovTkqsS5sNKiy/2jfxsdBWcG4BjJLJ5MZ37gx8MGaic/MeM ZxMVnE63diwTThIxGJRmt8lqvqIGUqlMat/RQtzxDkP0zXh/FgRVdLPySkWnjJ8bz7NrL35p6x0 mCbqdrOIMB/8= X-Received: by 2002:a05:600c:1da2:b0:3b4:856a:162c with SMTP id p34-20020a05600c1da200b003b4856a162cmr7107162wms.28.1665680490777; Thu, 13 Oct 2022 10:01:30 -0700 (PDT) X-Google-Smtp-Source: AMsMyM5RgE8uXapCGh0/vCpUyQqgrlCKlvZ8P6fv99nBMPLAXaN4ZROUUqZHwjEs1SconnG/p8A44w== X-Received: by 2002:a05:600c:1da2:b0:3b4:856a:162c with SMTP id p34-20020a05600c1da200b003b4856a162cmr7106855wms.28.1665680485817; Thu, 13 Oct 2022 10:01:25 -0700 (PDT) Received: from ?IPV6:2003:cb:c706:9d00:a34c:e448:d59b:831? (p200300cbc7069d00a34ce448d59b0831.dip0.t-ipconnect.de. [2003:cb:c706:9d00:a34c:e448:d59b:831]) by smtp.gmail.com with ESMTPSA id m8-20020adfe0c8000000b0022efc4322a9sm122659wri.10.2022.10.13.10.01.24 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 13 Oct 2022 10:01:25 -0700 (PDT) Message-ID: <7e2e6679-3205-3540-f522-9eaed2940559@redhat.com> Date: Thu, 13 Oct 2022 19:01:24 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.3.1 Subject: Re: hmm_test issues with latest mainline To: Vlastimil Babka , Alex Sierra , Alistair Popple Cc: Jason Gunthorpe , Ralph Campbell , Felix Kuehling , Christoph Hellwig , Jerome Glisse , "linux-mm@kvack.org" , "open list:KERNEL SELFTEST FRAMEWORK" , Shuah Khan References: <26017fe3-5ad7-6946-57db-e5ec48063ceb@suse.cz> From: David Hildenbrand Organization: Red Hat In-Reply-To: <26017fe3-5ad7-6946-57db-e5ec48063ceb@suse.cz> X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Language: en-US Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1665680495; h=from:from:sender: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:dkim-signature; bh=5ehGBuNc1sbQm4mu6rU843gW1LNmhGziTZ5r1rpb2d4=; b=h3bdrKGSNCX4T2sCWfqe/vY+0tdxdCKyOSqrf7gPZguewSJpdn4NgOntmNizhy+U3PkXOb 9Xsp6h45CHLk0yKooIY7ERuLvjysqhH4ZNIIkWEYnOn4Mwf7vFG6hBa7FznLJHBbr7LaWD jcH4I7tghcigTds0eS7/kJ22Wsa/Ano= ARC-Authentication-Results: i=1; imf25.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=Qfey8R4h; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf25.hostedemail.com: domain of david@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=david@redhat.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1665680495; a=rsa-sha256; cv=none; b=KKYzQyqbX8xy+rPW7wU5wyKw4Z5cZPPRZYBtmQsxORijsrN0zeVkYkcESkxW0B490efur2 3RHL4LcrbMZiMQhcJOiJC1VMuGBIo4MlziAaPkan0dKAmZ+VEFiVnmF9d7s9GC0pJj++gG NtmSa/cwVIM9i5w+eEPOa/fh+owAX+E= X-Stat-Signature: hgqyh9aoqpmmzqyrm36ko5id986e3ugk X-Rspamd-Queue-Id: D9FBAA0030 Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=redhat.com header.s=mimecast20190719 header.b=Qfey8R4h; dmarc=pass (policy=none) header.from=redhat.com; spf=pass (imf25.hostedemail.com: domain of david@redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=david@redhat.com X-Rspam-User: X-Rspamd-Server: rspam12 X-HE-Tag: 1665680495-786429 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: On 13.10.22 18:54, Vlastimil Babka wrote: > Hi, > > I've been trying the hmm_tests as of today's commit: > > a185a0995518 ("Merge tag 'linux-kselftest-kunit-6.1-rc1-2' ...) > > and run into several issues that seemed worth reporting. > > First, it seems the FIXTURE_TEARDOWN(hmm) in > tools/testing/selftests/vm/hmm-tests.c > using ASSERT_EQ(ret, 0); can run into an infinite loop of reporting the > assertion failure. Dunno if it's a kselftests issue or it's a bug to > use asserts in teardown. I hacked it up like this locally to proceed: > > --- a/tools/testing/selftests/vm/hmm-tests.c > +++ b/tools/testing/selftests/vm/hmm-tests.c > @@ -154,6 +154,11 @@ FIXTURE_TEARDOWN(hmm) > { > int ret = close(self->fd); > > + if (ret != 0) { > + fprintf(stderr, "close returned (%d) fd is (%d)\n", ret,self->fd); > + exit(1); > + } > + > ASSERT_EQ(ret, 0); > self->fd = -1; > } > > Next, there are some tests that fail (and thus also trigger the issue above) > > # RUN hmm.hmm_device_private.exclusive ... > # hmm-tests.c:1702:exclusive:Expected ret (-16) == 0 (0) > close returned (-1) fd is (3) > # exclusive: Test failed at step #1 > # FAIL hmm.hmm_device_private.exclusive > not ok 20 hmm.hmm_device_private.exclusive > # RUN hmm.hmm_device_private.exclusive_mprotect ... > # hmm-tests.c:1756:exclusive_mprotect:Expected ret (-16) == 0 (0) > close returned (-1) fd is (3) > # exclusive_mprotect: Test failed at step #1 > # FAIL hmm.hmm_device_private.exclusive_mprotect > not ok 21 hmm.hmm_device_private.exclusive_mprotect > # RUN hmm.hmm_device_private.exclusive_cow ... > # hmm-tests.c:1809:exclusive_cow:Expected ret (-16) == 0 (0) > close returned (-1) fd is (3) > # exclusive_cow: Test failed at step #1 > # FAIL hmm.hmm_device_private.exclusive_cow > not ok 22 hmm.hmm_device_private.exclusive_cow > > When did that test start failing? Was it still ok for 6.0? -- Thanks, David / dhildenb