search for: sg_addr

Displaying 20 results from an estimated 28 matches for "sg_addr".

Did you mean: s_addr
2018 Apr 20
2
[PATCH] kvmalloc: always use vmalloc if CONFIG_DEBUG_VM
...pped stacks (and some of our workarounds are hideous -- allocate 4 bytes with kmalloc because we can't DMA onto the stack any more?). We already have a few places which do handle sgs of vmalloced addresses, such as the nx crypto driver: if (is_vmalloc_addr(start_addr)) sg_addr = page_to_phys(vmalloc_to_page(start_addr)) + offset_in_page(sg_addr); else sg_addr = __pa(sg_addr); and videobuf: pg = vmalloc_to_page(virt); if (NULL == pg) goto err; BUG_ON...
2018 Apr 20
2
[PATCH] kvmalloc: always use vmalloc if CONFIG_DEBUG_VM
...pped stacks (and some of our workarounds are hideous -- allocate 4 bytes with kmalloc because we can't DMA onto the stack any more?). We already have a few places which do handle sgs of vmalloced addresses, such as the nx crypto driver: if (is_vmalloc_addr(start_addr)) sg_addr = page_to_phys(vmalloc_to_page(start_addr)) + offset_in_page(sg_addr); else sg_addr = __pa(sg_addr); and videobuf: pg = vmalloc_to_page(virt); if (NULL == pg) goto err; BUG_ON...
2017 Sep 08
2
[PATCH v15 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...; > +static void tell_host_sgs(struct virtio_balloon *vb, > > > + struct virtqueue *vq, > > > + unsigned long page_xb_start, > > > + unsigned long page_xb_end) > > > +{ > > > + unsigned long sg_pfn_start, sg_pfn_end; > > > + void *sg_addr; > > > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > > > + > > > + sg_pfn_start = page_xb_start; > > > + while (sg_pfn_start < page_xb_end) { > > > + sg_pfn_start = xb_find_next_bit(&vb->page_xb, sg_pfn_start, > > &g...
2017 Sep 08
2
[PATCH v15 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...; > +static void tell_host_sgs(struct virtio_balloon *vb, > > > + struct virtqueue *vq, > > > + unsigned long page_xb_start, > > > + unsigned long page_xb_end) > > > +{ > > > + unsigned long sg_pfn_start, sg_pfn_end; > > > + void *sg_addr; > > > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > > > + > > > + sg_pfn_start = page_xb_start; > > > + while (sg_pfn_start < page_xb_end) { > > > + sg_pfn_start = xb_find_next_bit(&vb->page_xb, sg_pfn_start, > > &g...
2017 Sep 29
1
[virtio-dev] Re: [PATCH v15 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...> > > > > + struct virtqueue *vq, > > > > > + unsigned long page_xb_start, > > > > > + unsigned long page_xb_end) > > > > > +{ > > > > > + unsigned long sg_pfn_start, sg_pfn_end; > > > > > + void *sg_addr; > > > > > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > > > > > + > > > > > + sg_pfn_start = page_xb_start; > > > > > + while (sg_pfn_start < page_xb_end) { > > > > > + sg_pfn_start = xb_find_next_b...
2017 Sep 29
1
[virtio-dev] Re: [PATCH v15 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...> > > > > + struct virtqueue *vq, > > > > > + unsigned long page_xb_start, > > > > > + unsigned long page_xb_end) > > > > > +{ > > > > > + unsigned long sg_pfn_start, sg_pfn_end; > > > > > + void *sg_addr; > > > > > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > > > > > + > > > > > + sg_pfn_start = page_xb_start; > > > > > + while (sg_pfn_start < page_xb_end) { > > > > > + sg_pfn_start = xb_find_next_b...
2018 Apr 20
0
[PATCH] kvmalloc: always use vmalloc if CONFIG_DEBUG_VM
...gt; workarounds are hideous -- allocate 4 bytes with kmalloc because we can't > DMA onto the stack any more?). We already have a few places which do > handle sgs of vmalloced addresses, such as the nx crypto driver: > > if (is_vmalloc_addr(start_addr)) > sg_addr = page_to_phys(vmalloc_to_page(start_addr)) > + offset_in_page(sg_addr); > else > sg_addr = __pa(sg_addr); > > and videobuf: > > pg = vmalloc_to_page(virt); > if (NULL == pg) >...
2017 Aug 03
0
[PATCH v13 5/5] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_VQ
..._buf(vq, &len)); + if (busywait) + while (!virtqueue_get_buf(vq, &len) && + !virtqueue_is_broken(vq)) + cpu_relax(); + else + wait_event(vb->acked, virtqueue_get_buf(vq, &len)); } /* @@ -197,11 +210,11 @@ static void tell_host_sgs(struct virtio_balloon *vb, sg_addr = pfn_to_kaddr(sg_pfn_start); sg_len = (sg_pfn_end - sg_pfn_start) << PAGE_SHIFT; while (sg_len > sg_max_len) { - send_one_sg(vb, vq, sg_addr, sg_max_len); + send_one_sg(vb, vq, sg_addr, sg_max_len, 0); sg_addr += sg_max_len; sg_len -= sg_max_len; } - send_one_sg(vb,...
2017 Sep 08
0
[virtio-dev] Re: [PATCH v15 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...ic void tell_host_sgs(struct virtio_balloon *vb, >>>> + struct virtqueue *vq, >>>> + unsigned long page_xb_start, >>>> + unsigned long page_xb_end) >>>> +{ >>>> + unsigned long sg_pfn_start, sg_pfn_end; >>>> + void *sg_addr; >>>> + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); >>>> + >>>> + sg_pfn_start = page_xb_start; >>>> + while (sg_pfn_start < page_xb_end) { >>>> + sg_pfn_start = xb_find_next_bit(&vb->page_xb, sg_pfn_start, &g...
2017 Aug 03
12
[PATCH v13 0/5] Virtio-balloon Enhancement
This patch series enhances the existing virtio-balloon with the following new features: 1) fast ballooning: transfer ballooned pages between the guest and host in chunks using sgs, instead of one by one; and 2) free_page_vq: a new virtqueue to report guest free pages to the host. The second feature can be used to accelerate live migration of VMs. Here are some details: Live migration needs to
2017 Aug 03
12
[PATCH v13 0/5] Virtio-balloon Enhancement
This patch series enhances the existing virtio-balloon with the following new features: 1) fast ballooning: transfer ballooned pages between the guest and host in chunks using sgs, instead of one by one; and 2) free_page_vq: a new virtqueue to report guest free pages to the host. The second feature can be used to accelerate live migration of VMs. Here are some details: Live migration needs to
2017 Aug 03
2
[PATCH v13 5/5] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_VQ
...!virtqueue_is_broken(vq)) > + cpu_relax(); > + else > + wait_event(vb->acked, virtqueue_get_buf(vq, &len)); > } > > /* > @@ -197,11 +210,11 @@ static void tell_host_sgs(struct virtio_balloon *vb, > sg_addr = pfn_to_kaddr(sg_pfn_start); > sg_len = (sg_pfn_end - sg_pfn_start) << PAGE_SHIFT; > while (sg_len > sg_max_len) { > - send_one_sg(vb, vq, sg_addr, sg_max_len); > + send_one_sg(vb, vq, sg_addr, sg_...
2017 Aug 03
2
[PATCH v13 5/5] virtio-balloon: VIRTIO_BALLOON_F_FREE_PAGE_VQ
...!virtqueue_is_broken(vq)) > + cpu_relax(); > + else > + wait_event(vb->acked, virtqueue_get_buf(vq, &len)); > } > > /* > @@ -197,11 +210,11 @@ static void tell_host_sgs(struct virtio_balloon *vb, > sg_addr = pfn_to_kaddr(sg_pfn_start); > sg_len = (sg_pfn_end - sg_pfn_start) << PAGE_SHIFT; > while (sg_len > sg_max_len) { > - send_one_sg(vb, vq, sg_addr, sg_max_len); > + send_one_sg(vb, vq, sg_addr, sg_...
2017 Aug 03
0
[PATCH v13 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
..._start and @page_xb_end form the range of bits in the xbitmap that + * need to be searched. + */ +static void tell_host_sgs(struct virtio_balloon *vb, + struct virtqueue *vq, + unsigned long page_xb_start, + unsigned long page_xb_end) +{ + unsigned long sg_pfn_start, sg_pfn_end; + void *sg_addr; + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); + + sg_pfn_start = page_xb_start; + while (sg_pfn_start < page_xb_end) { + sg_pfn_start = xb_find_next_bit(&vb->page_xb, sg_pfn_start, + page_xb_end, 1); + if (sg_pfn_start == page_xb_end + 1) + break; + sg_pfn_en...
2017 Sep 30
0
[PATCH v16 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
..._start and @page_xb_end form the range of bits in the xbitmap that + * need to be searched. + */ +static void tell_host_sgs(struct virtio_balloon *vb, + struct virtqueue *vq, + unsigned long page_xb_start, + unsigned long page_xb_end) +{ + unsigned long sg_pfn_start, sg_pfn_end; + void *sg_addr; + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); + int err = 0; + + sg_pfn_start = page_xb_start; + while (sg_pfn_start < page_xb_end) { + sg_pfn_start = xb_find_next_set_bit(&vb->page_xb, sg_pfn_start, + page_xb_end); + if (sg_pfn_start == page_xb_end + 1) +...
2017 Nov 03
0
[PATCH v17 4/6] virtio-balloon: VIRTIO_BALLOON_F_SG
..._start and @page_xb_end form the range of bits in the xbitmap that + * need to be searched. + */ +static void tell_host_sgs(struct virtio_balloon *vb, + struct virtqueue *vq, + unsigned long page_xb_start, + unsigned long page_xb_end) +{ + unsigned long sg_pfn_start, sg_pfn_end; + void *sg_addr; + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); + + sg_pfn_start = page_xb_start; + while (sg_pfn_start < page_xb_end) { + sg_pfn_start = xb_find_next_set_bit(&vb->page_xb, sg_pfn_start, + page_xb_end); + if (sg_pfn_start == page_xb_end + 1) + break; + sg_p...
2017 Oct 02
2
[PATCH v16 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...s in the xbitmap that > + * need to be searched. > + */ > +static void tell_host_sgs(struct virtio_balloon *vb, > + struct virtqueue *vq, > + unsigned long page_xb_start, > + unsigned long page_xb_end) > +{ > + unsigned long sg_pfn_start, sg_pfn_end; > + void *sg_addr; > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > + int err = 0; > + > + sg_pfn_start = page_xb_start; > + while (sg_pfn_start < page_xb_end) { > + sg_pfn_start = xb_find_next_set_bit(&vb->page_xb, sg_pfn_start, > + page_xb_end); > +...
2017 Oct 02
2
[PATCH v16 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...s in the xbitmap that > + * need to be searched. > + */ > +static void tell_host_sgs(struct virtio_balloon *vb, > + struct virtqueue *vq, > + unsigned long page_xb_start, > + unsigned long page_xb_end) > +{ > + unsigned long sg_pfn_start, sg_pfn_end; > + void *sg_addr; > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > + int err = 0; > + > + sg_pfn_start = page_xb_start; > + while (sg_pfn_start < page_xb_end) { > + sg_pfn_start = xb_find_next_set_bit(&vb->page_xb, sg_pfn_start, > + page_xb_end); > +...
2017 Aug 03
2
[PATCH v13 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...s in the xbitmap that > + * need to be searched. > + */ > +static void tell_host_sgs(struct virtio_balloon *vb, > + struct virtqueue *vq, > + unsigned long page_xb_start, > + unsigned long page_xb_end) > +{ > + unsigned long sg_pfn_start, sg_pfn_end; > + void *sg_addr; > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > + > + sg_pfn_start = page_xb_start; > + while (sg_pfn_start < page_xb_end) { > + sg_pfn_start = xb_find_next_bit(&vb->page_xb, sg_pfn_start, > + page_xb_end, 1); > + if (sg_pfn_start == page_...
2017 Aug 03
2
[PATCH v13 3/5] virtio-balloon: VIRTIO_BALLOON_F_SG
...s in the xbitmap that > + * need to be searched. > + */ > +static void tell_host_sgs(struct virtio_balloon *vb, > + struct virtqueue *vq, > + unsigned long page_xb_start, > + unsigned long page_xb_end) > +{ > + unsigned long sg_pfn_start, sg_pfn_end; > + void *sg_addr; > + uint32_t sg_len, sg_max_len = round_down(UINT_MAX, PAGE_SIZE); > + > + sg_pfn_start = page_xb_start; > + while (sg_pfn_start < page_xb_end) { > + sg_pfn_start = xb_find_next_bit(&vb->page_xb, sg_pfn_start, > + page_xb_end, 1); > + if (sg_pfn_start == page_...