Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1366765 > unrolled thread
| Started by | John Hubbard <jhubbard@nvidia.com> |
|---|---|
| First post | 2016-03-30 01:00 +0200 |
| Last post | 2016-03-30 01:00 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH v12 07/29] HMM: add per mirror page table v4. John Hubbard <jhubbard@nvidia.com> - 2016-03-30 01:00 +0200
| From | John Hubbard <jhubbard@nvidia.com> |
|---|---|
| Date | 2016-03-30 01:00 +0200 |
| Subject | Re: [PATCH v12 07/29] HMM: add per mirror page table v4. |
| Message-ID | <riaMa-4u5-11@gated-at.bofh.it> |
[Multipart message — attachments visible in raw view] — view raw
On Tue, 8 Mar 2016, Jérôme Glisse wrote:
> This patch add the per mirror page table. It also propagate CPU page
> table update to this per mirror page table using mmu_notifier callback.
> All update are contextualized with an HMM event structure that convey
> all information needed by device driver to take proper actions (update
> its own mmu to reflect changes and schedule proper flushing).
>
> Core HMM is responsible for updating the per mirror page table once
> the device driver is done with its update. Most importantly HMM will
> properly propagate HMM page table dirty bit to underlying page.
>
> Changed since v1:
> - Removed unused fence code to defer it to latter patches.
>
> Changed since v2:
> - Use new bit flag helper for mirror page table manipulation.
> - Differentiate fork event with HMM_FORK from other events.
>
> Changed since v3:
> - Get rid of HMM_ISDIRTY and rely on write protect instead.
> - Adapt to HMM page table changes
>
> Signed-off-by: Jérôme Glisse <jglisse@redhat.com>
> Signed-off-by: Sherry Cheung <SCheung@nvidia.com>
> Signed-off-by: Subhash Gutti <sgutti@nvidia.com>
> Signed-off-by: Mark Hairgrove <mhairgrove@nvidia.com>
> Signed-off-by: John Hubbard <jhubbard@nvidia.com>
> Signed-off-by: Jatin Kumar <jakumar@nvidia.com>
> ---
> include/linux/hmm.h | 83 ++++++++++++++++++++
> mm/hmm.c | 221 ++++++++++++++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 304 insertions(+)
>
> diff --git a/include/linux/hmm.h b/include/linux/hmm.h
> index b559c0b..5488fa9 100644
> --- a/include/linux/hmm.h
> +++ b/include/linux/hmm.h
> @@ -46,6 +46,7 @@
> #include <linux/mmu_notifier.h>
> #include <linux/workqueue.h>
> #include <linux/mman.h>
> +#include <linux/hmm_pt.h>
>
>
> struct hmm_device;
> @@ -53,6 +54,38 @@ struct hmm_mirror;
> struct hmm;
>
>
> +/*
> + * hmm_event - each event is described by a type associated with a struct.
> + */
> +enum hmm_etype {
> + HMM_NONE = 0,
> + HMM_FORK,
> + HMM_MIGRATE,
> + HMM_MUNMAP,
> + HMM_DEVICE_RFAULT,
> + HMM_DEVICE_WFAULT,
Hi Jerome,
Just a tiny thing I noticed, while connecting HMM to NVIDIA's upcoming
device driver: the last two enum items above should probably be named
like this:
HMM_DEVICE_READ_FAULT,
HMM_DEVICE_WRITE_FAULT,
instead of _WFAULT / _RFAULT. (Earlier code reviewers asked for more
clarity on these types of names.)
thanks,
John Hubbard
> + HMM_WRITE_PROTECT,
> +};
> +
Back to top | Article view | linux.kernel
csiph-web