[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190613184631.GO22062@mellanox.com>
Date: Thu, 13 Jun 2019 18:46:36 +0000
From: Jason Gunthorpe <jgg@...lanox.com>
To: Christoph Hellwig <hch@....de>
CC: Dan Williams <dan.j.williams@...el.com>,
Jérôme Glisse <jglisse@...hat.com>,
Ben Skeggs <bskeggs@...hat.com>,
"linux-mm@...ck.org" <linux-mm@...ck.org>,
"nouveau@...ts.freedesktop.org" <nouveau@...ts.freedesktop.org>,
"dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>,
"linux-nvdimm@...ts.01.org" <linux-nvdimm@...ts.01.org>,
"linux-pci@...r.kernel.org" <linux-pci@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 02/22] mm: remove the struct hmm_device infrastructure
On Thu, Jun 13, 2019 at 11:43:05AM +0200, Christoph Hellwig wrote:
> This code is a trivial wrapper around device model helpers, which
> should have been integrated into the driver device model usage from
> the start. Assuming it actually had users, which it never had since
> the code was added more than 1 1/2 years ago.
>
> Signed-off-by: Christoph Hellwig <hch@....de>
> ---
> include/linux/hmm.h | 20 ------------
> mm/hmm.c | 80 ---------------------------------------------
> 2 files changed, 100 deletions(-)
I haven't looked in detail at this device memory stuff.. But I did
check a bit through the mailing list archives for some clue what this
was supposed to be for (wow, this is from 2016!)
The commit that added this says:
This introduce a dummy HMM device class so device driver can use it to
create hmm_device for the sole purpose of registering device memory.
Which I just can't understand at all.
If we need a 'struct device' for some 'device memory' purpose then it
probably ought to be the 'struct pci_device' holding the BAR, not a
fake device.
I also can't comprehend why a supposed fake device would need a
chardev, with a stanadrd 'hmm_deviceX' name, without also defining a
core kernel ABI for that char dev..
If this comes back it needs a proper explanation and review, with a
user.
Reviewed-by: Jason Gunthorpe <jgg@...lanox.com>
Jason
Powered by blists - more mailing lists