linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@mellanox.com>
To: Ralph Campbell <rcampbell@nvidia.com>
Cc: Jerome Glisse <jglisse@redhat.com>,
	John Hubbard <jhubbard@nvidia.com>,
	Christoph Hellwig <hch@lst.de>,
	Andrew Morton <akpm@linux-foundation.org>,
	Shuah Khan <shuah@kernel.org>,
	linux-rdma@vger.kernel.org, linux-mm@kvack.org,
	linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org
Subject: Re: [PATCH v8 0/3] mm/hmm/test: add self tests for HMM
Date: Wed, 15 Apr 2020 11:41:25 -0300	[thread overview]
Message-ID: <20200415144125.GU11945@mellanox.com> (raw)
In-Reply-To: <20200321003108.22941-1-rcampbell@nvidia.com>

On Fri, Mar 20, 2020 at 05:31:05PM -0700, Ralph Campbell wrote:
> This series adds basic self tests for HMM and are intended for Jason
> Gunthorpe's rdma tree which has a number of HMM patches applied.

Here are some hunks I noticed while testing this:

--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -2201,7 +2201,8 @@ config TEST_MEMINIT
 
 config TEST_HMM
 	tristate "Test HMM (Heterogeneous Memory Management)"
-	depends on DEVICE_PRIVATE
+	depends on TRANSPARENT_HUGEPAGE
+	select DEVICE_PRIVATE
 	select HMM_MIRROR
 	select MMU_NOTIFIER
 	help

It fails testing if TRANSPARENT_HUGEPAGE is not on

@@ -1097,6 +1071,7 @@ static int dmirror_device_init(struct dmirror_device *mdevice, int id)
 	spin_lock_init(&mdevice->lock);
 
 	cdev_init(&mdevice->cdevice, &dmirror_fops);
+	mdevice->cdevice.owner = THIS_MODULE;
 	ret = cdev_add(&mdevice->cdevice, dev, 1);
 	if (ret)
 		return ret;

The use of cdev without a struct device is super weird, but it still
needs this

diff --git a/tools/testing/selftests/vm/test_hmm.sh b/tools/testing/selftests/vm/test_hmm.sh
index 461e4a99a362cf..0647b525a62564 100755
--- a/tools/testing/selftests/vm/test_hmm.sh
+++ b/tools/testing/selftests/vm/test_hmm.sh
@@ -59,7 +59,7 @@ run_smoke()
 	echo "Running smoke test. Note, this test provides basic coverage."
 
 	load_driver
-	./hmm-tests
+	$(dirname "${BASH_SOURCE[0]}")/hmm-tests
 	unload_driver
 }

Make it runnably reliably

Jason


  parent reply	other threads:[~2020-04-15 14:41 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-21  0:31 [PATCH v8 0/3] mm/hmm/test: add self tests for HMM Ralph Campbell
2020-03-21  0:31 ` [PATCH v8 1/3] mm/hmm/test: add selftest driver " Ralph Campbell
2020-03-21  0:31 ` [PATCH v8 2/3] mm/hmm/test: add selftests " Ralph Campbell
2020-03-21  0:31 ` [PATCH v8 3/3] MAINTAINERS: add HMM selftests Ralph Campbell
2020-03-21  9:00 ` [PATCH v8 0/3] mm/hmm/test: add self tests for HMM Leon Romanovsky
2020-03-21 17:27   ` Ralph Campbell
2020-03-21 21:55     ` Jason Gunthorpe
2020-03-22  8:10       ` Leon Romanovsky
2020-03-23 18:21         ` Ralph Campbell
2020-03-23 18:25         ` Jason Gunthorpe
2020-03-21 14:43 ` Jason Gunthorpe
2020-04-15 14:41 ` Jason Gunthorpe [this message]
2020-04-15 17:28   ` Ralph Campbell
2020-04-15 19:29     ` Leon Romanovsky
2020-04-15 19:32       ` Jason Gunthorpe
2020-04-15 19:39       ` Ralph Campbell
2020-04-15 19:52         ` Leon Romanovsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200415144125.GU11945@mellanox.com \
    --to=jgg@mellanox.com \
    --cc=akpm@linux-foundation.org \
    --cc=hch@lst.de \
    --cc=jglisse@redhat.com \
    --cc=jhubbard@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=rcampbell@nvidia.com \
    --cc=shuah@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).