From: Keith Busch <keith.busch@intel.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
Kirill Shutemov <kirill.shutemov@linux.intel.com>,
Dave Hansen <dave.hansen@intel.com>,
Dan Williams <dan.j.williams@intel.com>
Subject: Re: [PATCH 1/6] mm/gup_benchmark: Time put_page
Date: Wed, 10 Oct 2018 16:28:43 -0600 [thread overview]
Message-ID: <20181010222843.GA11034@localhost.localdomain> (raw)
In-Reply-To: <20181010152655.8510270e5db753f6666f12d3@linux-foundation.org>
On Wed, Oct 10, 2018 at 03:26:55PM -0700, Andrew Morton wrote:
> On Wed, 10 Oct 2018 13:56:00 -0600 Keith Busch <keith.busch@intel.com> wrote:
>
> > We'd like to measure time to unpin user pages, so this adds a second
> > benchmark timer on put_page, separate from get_page.
> >
> > Adding the field will breaks this ioctl ABI, but should be okay since
> > this an in-tree kernel selftest.
> >
> > ...
> >
> > --- a/mm/gup_benchmark.c
> > +++ b/mm/gup_benchmark.c
> > @@ -8,7 +8,8 @@
> > #define GUP_FAST_BENCHMARK _IOWR('g', 1, struct gup_benchmark)
> >
> > struct gup_benchmark {
> > - __u64 delta_usec;
> > + __u64 get_delta_usec;
> > + __u64 put_delta_usec;
> > __u64 addr;
> > __u64 size;
> > __u32 nr_pages_per_call;
>
> If we move put_delta_usec to the end of this struct, the ABI remains
> back-compatible?
If the kernel writes to a new value appended to the end of the struct,
and the application allocated the older sized struct, wouldn't that
corrupt the user memory?
next prev parent reply other threads:[~2018-10-10 22:31 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-10-10 19:56 [PATCH 1/6] mm/gup_benchmark: Time put_page Keith Busch
2018-10-10 19:56 ` [PATCH 2/6] mm/gup_benchmark: Add additional pinning methods Keith Busch
2018-10-10 19:56 ` [PATCH 3/6] tools/gup_benchmark: Fix 'write' flag usage Keith Busch
2018-10-10 19:56 ` [PATCH 4/6] tools/gup_benchmark: Allow user specified file Keith Busch
2018-10-10 22:31 ` Andrew Morton
2018-10-10 22:42 ` Keith Busch
2018-10-10 19:56 ` [PATCH 5/6] tools/gup_benchmark: Add MAP_SHARED option Keith Busch
2018-10-10 19:56 ` [PATCH 6/6] tools/gup_benchmark: Add MAP_HUGETLB option Keith Busch
2018-10-10 22:26 ` [PATCH 1/6] mm/gup_benchmark: Time put_page Andrew Morton
2018-10-10 22:28 ` Keith Busch [this message]
2018-10-10 22:41 ` Andrew Morton
2018-10-10 22:40 ` Keith Busch
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=20181010222843.GA11034@localhost.localdomain \
--to=keith.busch@intel.com \
--cc=akpm@linux-foundation.org \
--cc=dan.j.williams@intel.com \
--cc=dave.hansen@intel.com \
--cc=kirill.shutemov@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.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).