xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: Ian Campbell <Ian.Campbell@citrix.com>
To: Andres Lagar-Cavilla <andreslc@gridcentric.ca>
Cc: "xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>,
	David Vrabel <david.vrabel@citrix.com>,
	Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Subject: Re: [PATCH 2/2] xen/privcmd: add PRIVCMD_MMAPBATCH_V2 ioctl
Date: Fri, 31 Aug 2012 08:02:12 +0100	[thread overview]
Message-ID: <1346396532.5820.1.camel@dagon.hellion.org.uk> (raw)
In-Reply-To: <165680AD-2970-4A8D-BEC0-B02830F8A97F@gridcentric.ca>

On Thu, 2012-08-30 at 19:29 +0100, Andres Lagar-Cavilla wrote:
> On Aug 30, 2012, at 1:04 PM, David Vrabel wrote:
> > You can't access user space pages here while holding
> > current->mm->mmap_sem.  I tried this and it would sometimes deadlock in
> > the page fault handler.
> > 
> > access_ok() only checks if the pointer is in the user space virtual
> > address space - not that a valid mapping exists and is writable.  So
> > BUG_ON(__put_user()) should not be done.
> 
> Very true. Thanks for the pointer. Clearly the reason for the gather_array/traverse_pages structure.

/me has flashbacks to the mammoth debugging session which led to
http://xenbits.xen.org/hg/linux-2.6.18-xen.hg/rev/043dc7488c11.

Ian.

  reply	other threads:[~2012-08-31  7:02 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-30 12:58 [PATCHv3 0/2] xen/privcmd: support for paged-out frames David Vrabel
2012-08-30 12:58 ` [PATCH 1/2] xen/mm: return more precise error from xen_remap_domain_range() David Vrabel
2012-08-30 15:07   ` Andres Lagar-Cavilla
2012-08-30 12:58 ` [PATCH 2/2] xen/privcmd: add PRIVCMD_MMAPBATCH_V2 ioctl David Vrabel
2012-08-30 16:41   ` Andres Lagar-Cavilla
2012-08-30 17:04     ` David Vrabel
2012-08-30 18:29       ` Andres Lagar-Cavilla
2012-08-31  7:02         ` Ian Campbell [this message]
2012-08-30 18:32   ` Andres Lagar-Cavilla
2012-08-31 13:08     ` David Vrabel
2012-08-31 13:13       ` Andres Lagar-Cavilla
2012-09-05 16:17         ` Konrad Rzeszutek Wilk
2012-08-31 13:59   ` Andres Lagar-Cavilla
2012-09-05 16:21     ` Konrad Rzeszutek Wilk
2012-09-05 17:09       ` Andres Lagar-Cavilla
2012-09-05 17:40         ` Konrad Rzeszutek Wilk
2012-09-06 13:41           ` Andres Lagar-Cavilla
2012-09-06 16:20             ` Konrad Rzeszutek Wilk
2012-08-30 20:05 ` [PATCHv3 0/2] xen/privcmd: support for paged-out frames Konrad Rzeszutek Wilk
2012-08-30 20:12   ` Andres Lagar-Cavilla
2012-09-05 18:57     ` Konrad Rzeszutek Wilk
2012-09-05 19:51       ` Andres Lagar-Cavilla
2012-09-05 20:05         ` Konrad Rzeszutek Wilk
  -- strict thread matches above, loose matches on Subject: below --
2012-08-29 13:15 [PATCHv2 " David Vrabel
2012-08-29 13:15 ` [PATCH 2/2] xen/privcmd: add PRIVCMD_MMAPBATCH_V2 ioctl David Vrabel
2012-08-29 16:14   ` Andres Lagar-Cavilla
2012-08-29 16:36     ` David Vrabel
2012-08-29 18:10       ` Andres Lagar-Cavilla

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=1346396532.5820.1.camel@dagon.hellion.org.uk \
    --to=ian.campbell@citrix.com \
    --cc=andreslc@gridcentric.ca \
    --cc=david.vrabel@citrix.com \
    --cc=konrad.wilk@oracle.com \
    --cc=xen-devel@lists.xensource.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;
as well as URLs for NNTP newsgroup(s).