Re: [PATCH 1/3] mm: add vm_insert_mixed_mkwrite()

From: Ross Zwisler
Date: Mon Jun 12 2017 - 00:02:48 EST


On Fri, Jun 09, 2017 at 08:35:08PM -0700, Dan Williams wrote:
> On Fri, Jun 9, 2017 at 8:03 PM, Ross Zwisler
> <ross.zwisler@xxxxxxxxxxxxxxx> wrote:
> > And vm_insert_mixed_mkwrite() and vm_insert_mixed() are redundant with only
> > the insert_pfn() line differing? This doesn't seem better...unless I'm
> > missing something?
> >
> > The way it is, vm_insert_mixed_mkwrite() also closely matches
> > insert_pfn_pmd(), which we use in the PMD case and which also takes a 'write'
> > boolean which works the same as our newly added 'mkwrite'.
>
> Hmm, but now the pfn and pmd cases are inconsistent, if you put the
> flag name in the function then don't add an argument, or make it like
> the pmd case and add an argument to vm_insert_mixed(). I prefer the
> former.

Okay, I'll fix this for v2. Thanks for the review.