search for: grant_map

Displaying 13 results from an estimated 13 matches for "grant_map".

2011 Mar 07
6
[PATCH] xen/gntdev,gntalloc: Remove unneeded VM flags
...TCOPY; - vma->vm_flags |= VM_PFNMAP | VM_PFN_AT_MMAP; vma->vm_ops = &gntalloc_vmops; diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c index 2faf797..69c787a 100644 --- a/drivers/xen/gntdev.c +++ b/drivers/xen/gntdev.c @@ -334,17 +334,26 @@ static int unmap_grant_pages(struct grant_map *map, int offset, int pages) /* ------------------------------------------------------------------ */ +static void gntdev_vma_open(struct vm_area_struct *vma) +{ + struct grant_map *map = vma->vm_private_data; + + pr_debug("gntdev_vma_open %p\n", vma); + atomic_inc(&map->us...
2011 Mar 19
1
[patch 1/2] xen-gntdev: return -EFAULT on copy_to_user failure
...But returning -EFAULT is still cleaner. Signed-off-by: Dan Carpenter <error27 at gmail.com> diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c index 017ce60..b0f9e8f 100644 --- a/drivers/xen/gntdev.c +++ b/drivers/xen/gntdev.c @@ -273,7 +273,7 @@ static int __unmap_grant_pages(struct grant_map *map, int offset, int pages) map->vma->vm_start + map->notify.addr; err = copy_to_user(tmp, &err, 1); if (err) - return err; + return -EFAULT; map->notify.flags &= ~UNMAP_NOTIFY_CLEAR_BYTE; } else if (pgno >= offset && pgno < offset + page...
2011 Mar 19
1
[patch 1/2] xen-gntdev: return -EFAULT on copy_to_user failure
...But returning -EFAULT is still cleaner. Signed-off-by: Dan Carpenter <error27 at gmail.com> diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c index 017ce60..b0f9e8f 100644 --- a/drivers/xen/gntdev.c +++ b/drivers/xen/gntdev.c @@ -273,7 +273,7 @@ static int __unmap_grant_pages(struct grant_map *map, int offset, int pages) map->vma->vm_start + map->notify.addr; err = copy_to_user(tmp, &err, 1); if (err) - return err; + return -EFAULT; map->notify.flags &= ~UNMAP_NOTIFY_CLEAR_BYTE; } else if (pgno >= offset && pgno < offset + page...
2011 Mar 19
1
[patch 1/2] xen-gntdev: return -EFAULT on copy_to_user failure
...But returning -EFAULT is still cleaner. Signed-off-by: Dan Carpenter <error27 at gmail.com> diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c index 017ce60..b0f9e8f 100644 --- a/drivers/xen/gntdev.c +++ b/drivers/xen/gntdev.c @@ -273,7 +273,7 @@ static int __unmap_grant_pages(struct grant_map *map, int offset, int pages) map->vma->vm_start + map->notify.addr; err = copy_to_user(tmp, &err, 1); if (err) - return err; + return -EFAULT; map->notify.flags &= ~UNMAP_NOTIFY_CLEAR_BYTE; } else if (pgno >= offset && pgno < offset + page...
2007 Jun 07
4
blkif_map error starting fourth guest domain
I''m having problems starting more than three domains. It sometimes works fine, but more often than not the 4th domain''s root block device times out and so the domU kernel panics as there''s no /dev/root: XENBUS: Timeout connecting to device: device/vbd/2057 (state 6) XENBUS: Timeout connecting to device: device/vif/0 (state 6) XENBUS: Timeout connecting to device:
2011 Sep 08
1
[PATCH v4 1/2] xen: add an "highmem" parameter to alloc_xenballooned_pages
...rease_reservation(nr_pages - pgno, + highmem ? GFP_HIGHUSER : GFP_USER); if (st != BP_DONE) goto out_undo; } diff --git a/drivers/xen/gntdev.c b/drivers/xen/gntdev.c index f914b26..7b9b1d1 100644 --- a/drivers/xen/gntdev.c +++ b/drivers/xen/gntdev.c @@ -123,7 +123,7 @@ static struct grant_map *gntdev_alloc_map(struct gntdev_priv *priv, int count) NULL == add->pages) goto err; - if (alloc_xenballooned_pages(count, add->pages)) + if (alloc_xenballooned_pages(count, add->pages, false /* lowmem */)) goto err; for (i = 0; i < count; i++) { diff --git a/include/x...
2012 May 11
2
[PATCH] libxc: implement gnttab.set_max_grants for Linux
...plement this IOCTL, + * so ignore the resulting specific failure. + */ + if (errno == ENOTTY) + rc = 0; + else + PERROR("linux_gnttab_set_max_grants: ioctl SET_MAX_GRANTS failed"); + } + + return rc; +} + static void *linux_gnttab_grant_map(xc_gnttab *xch, xc_osdep_handle h, uint32_t count, int flags, int prot, uint32_t *domids, uint32_t *refs, @@ -680,6 +701,7 @@ static struct xc_osdep_ops linux_gnttab_ .close = &linux_gnttab_close, .u.gnttab =...
2013 Aug 29
0
Re: Is fallback vhost_net to qemu for live migrate available?
...Xen specific knowledge would be pretty nasty IMHO. Did you modify the front end driver to do grant table mapping or is this all being done by mapping the domain's memory? > TCP receive throughput of > single vnic from 2.77Gbps up to 6Gps。In VM receive side,I instead grant_copy > with grant_map + memcopy,it efficiently reduce the cost of grant_table > spin_lock of dom0,So the hole server TCP performance from 5.33Gps up to > 9.5Gps。 > > Now I am consider the live migrate of vhost_net on Xen,vhost_net use > vhost_log for live migrate on Kvm,but qemu on Xen havn't manage t...
2007 Apr 18
3
Grant Tables between dom0 and domU?
Hi All, The interface manual says - grant tables provide a generic mechanism sharing between domains. Subsequent lines suggest mechanism sharing between only unpriviliged domains. Can grant tables be used for this capability based shared memory communication between dom0 and domUs? Thanks ~psr -- pradeep singh rautela "proud to be a TUXedo, BSDemons you are a little late" - me
2007 Oct 03
0
[PATCH 3/3] TLB flushing and IO memory mapping
...:08 2007 +0100 +++ b/xen/common/grant_table.c Mon Jul 30 10:28:27 2007 +0100 @@ -199,6 +199,7 @@ __gnttab_map_grant_ref( int handle; unsigned long frame = 0; int rc = GNTST_okay; + int is_iomem = 0; struct active_grant_entry *act; struct grant_mapping *mt; grant_entry_t *sha; @@ -327,34 +328,52 @@ __gnttab_map_grant_ref( spin_unlock(&rd->grant_table->lock); - if ( unlikely(!mfn_valid(frame)) || - unlikely(!((op->flags & GNTMAP_readonly) ? - get_page(mfn_to_page(frame), rd) : -...
2012 May 25
0
[PATCH 3/3] gnttab: cleanup
...int _set_status(unsigned gt_versi } static void mapcount( - struct domain *ld, struct domain *rd, unsigned long mfn, + struct grant_table *lgt, struct domain *rd, unsigned long mfn, unsigned int *wrc, unsigned int *rdc) { - struct grant_table *gt = ld->grant_table; struct grant_mapping *map; grant_handle_t handle; *wrc = *rdc = 0; - for ( handle = 0; handle < gt->maptrack_limit; handle++ ) + for ( handle = 0; handle < lgt->maptrack_limit; handle++ ) { - map = &maptrack_entry(gt, handle); + map = &maptrack_entry(lgt, h...
2013 Apr 26
14
bug in xc_gntshr_munmap?
Hi, Header says: /* * Unmaps the @count pages starting at @start_address, which were mapped by a * call to xc_gntshr_share_*. Never logs. */ int xc_gntshr_munmap(xc_gntshr *xcg, void *start_address, uint32_t count); But implementation calls: static int linux_gntshr_munmap(xc_gntshr *xcg, xc_osdep_handle h, void *start_address, uint32_t count) { return
2007 Mar 20
62
RFC: [0/2] Remove netloop by lazy copying in netback
Hi Keir: These two patches remove the need for netloop by performing the copying in netback and only if it is necessary. The rationale is that most packets will be processed without delay allowing them to be freed without copying at all. So instead of copying every packet destined to dom0 we''ll only copy those that linger longer than a specified amount of time (currently 0.5s). As it