mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jeff Moyer <jmoyer@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kernel@vger.kernel.org, linux-aio@kvack.org, zach.brown@oracle.com
Subject: Re: [patch] aio: Don't zero out the pages array inside struct dio
Date: Fri, 30 Oct 2009 17:22:27 -0400	[thread overview]
Message-ID: <x49hbtgr2zw.fsf@segfault.boston.devel.redhat.com> (raw)
In-Reply-To: <20091030141811.1c77571b.akpm@linux-foundation.org> (Andrew Morton's message of "Fri, 30 Oct 2009 14:18:11 -0700")

Andrew Morton <akpm@linux-foundation.org> writes:

> You forgot something:
>
> --- a/fs/direct-io.c~aio-dont-zero-out-the-pages-array-inside-struct-dio-fix
> +++ a/fs/direct-io.c
> @@ -130,6 +130,12 @@ struct dio {
>  	unsigned head;			/* next page to process */
>  	unsigned tail;			/* last valid page + 1 */
>  	int page_errors;		/* errno from get_user_pages() */
> +
> +	/*
> +	 * pages[] (and any fields placed after it) are not zeroed out at
> +	 * allocation time.  Don't add new fields after pages[] unless you
> +	 * wish that they not be zeroed.
> +	 */
>  	struct page *pages[DIO_PAGES];	/* page buffer */
>  };
>  

Yeah, that makes sense.  Thanks for adding it, Andrew.  Oh, and it looks
like I botched the subject line.  It should have read dio, not aio, but
I'm not sure that matters a whole lot.

Cheers,
Jeff

      reply	other threads:[~2009-10-30 21:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-10-30 13:39 Jeff Moyer
2009-10-30 21:18 ` Andrew Morton
2009-10-30 21:22   ` Jeff Moyer [this message]

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=x49hbtgr2zw.fsf@segfault.boston.devel.redhat.com \
    --to=jmoyer@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-aio@kvack.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=zach.brown@oracle.com \
    /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

all inboxes | Powered by JetHome®