Re: [PATCH v3 2/2] xen/block: add multi-page ring support

2015-05-20 Thread Roger Pau Monné
El 15/05/15 a les 14.06, Bob Liu ha escrit: > > On 05/15/2015 07:13 PM, Roger Pau Monné wrote: >> El 12/05/15 a les 13.01, Bob Liu ha escrit: >>> Extend xen/block to support multi-page ring, so that more requests can be >>> issued >>> by using more tha

Re: [PATCH 1/2] driver: xen-blkfront: move talk_to_blkback to the correct place

2015-05-15 Thread Roger Pau Monné
El 15/05/15 a les 13.35, Bob Liu ha escrit: > > On 05/15/2015 07:14 PM, Roger Pau Monné wrote: >> El 15/05/15 a les 13.03, Bob Liu ha escrit: >>> >>> On 05/15/2015 06:01 PM, Roger Pau Monné wrote: >>>> El 12/05/15 a les 13.01, Bob Liu ha escrit: >

Re: [PATCH 1/2] driver: xen-blkfront: move talk_to_blkback to the correct place

2015-05-15 Thread Roger Pau Monné
El 15/05/15 a les 13.03, Bob Liu ha escrit: > > On 05/15/2015 06:01 PM, Roger Pau Monné wrote: >> El 12/05/15 a les 13.01, Bob Liu ha escrit: >>> The right place for talk_to_blkback() to query backend features and >>> transport >>> parameters is after bac

Re: [PATCH v3 2/2] xen/block: add multi-page ring support

2015-05-15 Thread Roger Pau Monné
El 12/05/15 a les 13.01, Bob Liu ha escrit: > Extend xen/block to support multi-page ring, so that more requests can be > issued > by using more than one pages as the request ring between blkfront and backend. > As a result, the performance can get improved significantly.

Re: [PATCH 1/2] driver: xen-blkfront: move talk_to_blkback to the correct place

2015-05-15 Thread Roger Pau Monné
El 12/05/15 a les 13.01, Bob Liu ha escrit: > The right place for talk_to_blkback() to query backend features and transport > parameters is after backend entered XenbusStateInitWait. There is no problem talk_to_blkback doesn't gather any backend features, it just publishes the features supported b

Re: [Xen-devel] [PATCH] xen: Add __GFP_DMA flag when xen_swiotlb_init gets free pages.

2015-04-21 Thread Roger Pau Monné
El 21/04/15 a les 12.36, Stefano Stabellini ha escrit: > On Tue, 21 Apr 2015, Ian Campbell wrote: >> On Mon, 2015-04-20 at 18:54 +0100, Stefano Stabellini wrote: >>> This should definitely be done only on ARM and ARM64, as on x86 PVH >>> assumes the presence of an IOMMU. We need an ifdef. >>> >>> A

Re: [PATCH v2] xen-blkback: define pr_fmt macro to avoid the duplication of DRV_PFX

2015-04-02 Thread Roger Pau Monné
> And if the pr sentences miss a \n, add it in the end. It will format the > code. > > I apologize for the disturb of wrong patch log. Very looking forward > to your reply. > >> These all make the readability of the code become better. >> >> Signed-off-by: Tao Che

Re: [PATCH] xen-blkback: define pr_fmt macro to avoid the duplication of DRV_PFX

2015-03-31 Thread Roger Pau Monné
El 31/03/15 a les 23.14, Tao Chen ha escrit: > Define pr_fmt macro with {xen-blkback: } prefix, then remove all use > of DRV_PFX in the pr and DPRINTK sentences. It will simplify the code. > > And if the pr sentences miss a \n, add it in the end. If the DPRINTK > sentences have redundant \n, remov

Re: [PATCH v2] xen-blkback: enlarge the array size of blkback name

2015-03-27 Thread Roger Pau Monné
name, so it will be fully shown in any case. > > Signed-off-by: Tao Chen Acked-by: Roger Pau Monné -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/maj

Re: [PATCH 2/2] xen/grant: introduce func gnttab_unmap_refs_async_wait_completion()

2015-03-26 Thread Roger Pau Monné
El 26/03/15 a les 13.16, Bob Liu ha escrit: > There are several place using gnttab async unmap and wait for > completion, so move the common code to a function > gnttab_unmap_refs_async_wait_completion(). > > Signed-off-by: Bob Liu For the blkback parts: Acked-by: Roger Pau M

Re: [PATCH RESEND 1/2] xen/blkback: safely unmap purge persistent grants

2015-03-26 Thread Roger Pau Monné
nt > case. > Purge persistent pages can't be unmapped either unless no longer in use. > > Signed-off-by: Bob Liu AFAICT since this is basically the same patch as what I've sent: Acked-by: Roger Pau Monné -- To unsubscribe from this list: send the line "unsubscribe li

Re: [PATCH] xen-blkback: enlarge the array size of blkback name

2015-03-26 Thread Roger Pau Monné
El 13/03/15 a les 16.52, Tao Chen ha escrit: > The blkback name is like blkback.domid.xvd[a-z], if domid has three digits > (means larger than 100), then the backmost xvd wouldn't be fully shown. > > Define a BLKBACK_NAME_LEN macro which is (TASK_COMM_LEN * 2), enlarge the > array size of blkback

Re: [PATCH] xen/blkback: safely unmap purge persistent grants

2015-03-26 Thread Roger Pau Monné
Hello, El 25/03/15 a les 11.02, Bob Liu ha escrit: > + gnttab_unmap_refs_async(&unmap_data); > + wait_for_completion(&unmap_completion); I think David had a comment about putting this into some kind of common helper since it's used widely (at least in blkback). Could you l

Re: [PATCH 04/10] xen/blkfront: separate ring information to an new struct

2015-02-19 Thread Roger Pau Monné
El 19/02/15 a les 13.06, Felipe Franciosi ha escrit: > > >> -Original Message- >> From: David Vrabel >> Sent: 19 February 2015 11:15 >> To: Roger Pau Monne; Bob Liu; Felipe Franciosi >> Cc: 'Konrad Rzeszutek Wilk'; xen-de...@lists.xen.org;

Re: [PATCH 04/10] xen/blkfront: separate ring information to an new struct

2015-02-19 Thread Roger Pau Monné
El 19/02/15 a les 3.05, Bob Liu ha escrit: > > > On 02/19/2015 02:08 AM, Felipe Franciosi wrote: >>> -Original Message- >>> From: Konrad Rzeszutek Wilk [mailto:konrad.w...@oracle.com] >>> Sent: 18 February 2015 17:38 >>> To: Roger Pau Monne &g

Re: [PATCH 04/10] xen/blkfront: separate ring information to an new struct

2015-02-18 Thread Roger Pau Monné
El 15/02/15 a les 9.18, Bob Liu ha escrit: > A ring is the representation of a hardware queue, this patch separate ring > information from blkfront_info to an new struct blkfront_ring_info to make > preparation for real multi hardware queues supporting. > > Signed-off-by: Arianna Avanzini > Signe

Re: [Xen-devel] 3.19 + xen-devel: kernel BUG at fs/ext4/page-io.c:85!

2015-02-12 Thread Roger Pau Monné
Hello, El 12/02/15 a les 9.54, Sander Eikelenboom ha escrit: > Hi, > > With a 3.19 kernel + xen-devel tree pulled on top i run into this splat below. > It's on a Xen PV-guest running a postgres database and doing a pg_dump at that > moment in time, after running for a while (within 2 days or so).

[GIT PULL] (xen) for-jens-3.20 for v3.20 Xen blk driver updates

2015-02-10 Thread Roger Pau Monné
xen-blkback: default to X86_32 ABI on x86 Roger Pau Monne (2): xen-blkback,xen-blkfront: add myself as maintainer xen-blkfront: fix accounting of reqs when migrating MAINTAINERS| 1 + drivers/block/xen-blkback/common.h | 9 + drivers/block/xen-bl

[PATCH] xen-blkfront: fix accounting of reqs when migrating

2015-02-02 Thread Roger Pau Monne
Current migration code uses blk_put_request in order to finish a request before requeuing it. This function doesn't update the statistics of the queue, which completely screws accounting. Use blk_end_request_all instead which properly updates the statistics of the queue. Signed-off-by: Roge

Re: [PATCH 2/2] drivers: xen/block: add multi-page ring support

2015-02-02 Thread Roger Pau Monné
El 23/01/15 a les 10.14, Bob Liu ha escrit: > Extend xen/block to support multi-page ring. > * xen-blkback notify blkfront with feature-multi-ring-pages > * xen-blkfront write to xenstore about how many pages are used as the ring > > If using 4 pages as the ring, inflight requests inscreased fro

[PATCH] xen-blk: add myself as maintainer of xen-blk{back/front}

2015-01-23 Thread Roger Pau Monne
I've done quite a lot of work in blkfront/blkback, and I usually end up looking at the patches, so add myself as maintainer together with Konrad. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: Boris Ostrovsky Cc: David Vrabel Cc: xen-de...@lists.xenproject.org --- MAINTA

Re: xen-blkfront: weird behavior of "iostat" after VM live-migrate which xen-blkfront module has indirect descriptors

2015-01-23 Thread Roger Pau Monné
you try it and report back? --- commit bb4317c051ca81a2906edb7ccc505cbd6d1d80c7 Author: Roger Pau Monne Date: Fri Jan 23 12:10:51 2015 +0100 xen-blkfront: fix accounting of reqs when migrating Current migration code uses blk_put_request in order to finish a request before reque

Re: [RESEND PATCH] xen/blkfront: increase the default value of xen_blkif_max_segments

2015-01-21 Thread Roger Pau Monné
El 21/01/15 a les 8.56, Bob Liu ha escrit: > The default max-segments of indirect requests was 32, so IO operations with > bigger block size(>32*4k) would be split and make performance drop. > > Nowadays backend device usually support 512k max_sectors_kb on desktop, > and usually larger on server

Re: [PATCH] xen/blkfront: restart request queue when there is enough persistent_gnts_c

2015-01-12 Thread Roger Pau Monné
El 12/01/15 a les 14.04, David Vrabel ha escrit: > On 12/01/15 11:36, Roger Pau Monné wrote: >> El 12/01/15 a les 8.09, Bob Liu ha escrit: >>> >>> On 01/09/2015 11:51 PM, Roger Pau Monné wrote: >>>> El 06/01/15 a les 14.19, Bob Liu ha escrit: &g

Re: [PATCH] xen/blkfront: restart request queue when there is enough persistent_gnts_c

2015-01-12 Thread Roger Pau Monné
El 12/01/15 a les 8.09, Bob Liu ha escrit: > > On 01/09/2015 11:51 PM, Roger Pau Monné wrote: >> El 06/01/15 a les 14.19, Bob Liu ha escrit: >>> When there is no enough free grants, gnttab_alloc_grant_references() >>> will fail and block request queue will stop. &g

Re: [PATCH] xen/blkfront: restart request queue when there is enough persistent_gnts_c

2015-01-09 Thread Roger Pau Monné
El 06/01/15 a les 14.19, Bob Liu ha escrit: > When there is no enough free grants, gnttab_alloc_grant_references() > will fail and block request queue will stop. > If the system is always lack of grants, blkif_restart_queue_callback() can't > be > scheduled and block request queue can't be restart

Re: [Xen-devel] [PATCH] xen/blkfront: increase the default value of xen_blkif_max_segments

2014-12-16 Thread Roger Pau Monné
El 16/12/14 a les 11.11, Bob Liu ha escrit: > The default maximum value of segments in indirect requests was 32, IO > operations with bigger block size(>32*4k) would be split and performance start > to drop. > > Nowadays backend device usually support 512k max_sectors_kb on desktop, and > may larg

Re: [Xen-devel] [PATCH RFC 0/4] Multi-queue support for xen-blkfront and xen-blkback

2014-09-15 Thread Roger Pau Monné
El 22/08/14 a les 13.20, Arianna Avanzini ha escrit: > Hello, [...] > The patchset implements in the backend driver the retrieval of information > about the currently-in-use block layer API for a certain device and about > the number of available submission queues, if the API turns out to be the >

Re: [Xen-devel] [PATCH] xen-blkfront: check feature-persitent on resume

2014-06-13 Thread Roger Pau Monné
Ping? On 23/05/14 20:08, Roger Pau Monné wrote: > On 23/05/14 19:51, Konrad Rzeszutek Wilk wrote: >> On Thu, May 22, 2014 at 04:40:07PM +0200, Roger Pau Monne wrote: >>> We are missing a check to see if the backend supports persistent >>> grants on resume, meaning

Re: [Xen-devel] Backport request to stable of two performance related fixes for xen-blkfront (3.13 fixes to earlier trees)

2014-06-10 Thread Roger Pau Monné
On 10/06/14 15:19, Vitaly Kuznetsov wrote: > Vitaly Kuznetsov writes: > >> Jiri Slaby writes: >> >>> On 06/04/2014 07:48 AM, Greg KH wrote: On Wed, May 14, 2014 at 03:11:22PM -0400, Konrad Rzeszutek Wilk wrote: > Hey Greg > > This email is in regards to backporting two patches t

Re: [Xen-devel] [V1 PATCH] dom0 pvh: map foreign pfns in our p2m for toolstack

2014-05-27 Thread Roger Pau Monné
On 24/05/14 03:33, Mukesh Rathor wrote: > When running as dom0 in pvh mode, foreign pfns that are accessed must be > added to our p2m which is managed by xen. This is done via > XENMEM_add_to_physmap_range hypercall. This is needed for toolstack > building guests and mapping guest memory, xentrace

Re: [PATCH] xen-blkfront: check feature-persitent on resume

2014-05-23 Thread Roger Pau Monné
On 23/05/14 19:51, Konrad Rzeszutek Wilk wrote: > On Thu, May 22, 2014 at 04:40:07PM +0200, Roger Pau Monne wrote: >> We are missing a check to see if the backend supports persistent >> grants on resume, meaning we will always run with the value fetched >> from the firsts ho

[PATCH] xen-blkfront: check feature-persitent on resume

2014-05-22 Thread Roger Pau Monne
We are missing a check to see if the backend supports persistent grants on resume, meaning we will always run with the value fetched from the firsts host on which we run on. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- drivers/block/xen-blkfront.c | 23

Re: Backport request to stable of two performance related fixes for xen-blkfront (3.13 fixes to earlier trees)

2014-05-22 Thread Roger Pau Monné
ou are OK with the backport, I am volunteering Roger and Felipe to assist >> in jamming^H^H^H^Hbackporting the patches into earlier kernels. > > Sure, can you provide backported patches? As-is, they don't apply to > the 3.10-stable kernel. Here are the backported patches to 3

Re: [Xen-devel] Backport request to stable of two performance related fixes for xen-blkfront (3.13 fixes to earlier trees)

2014-05-20 Thread Roger Pau Monné
On 20/05/14 11:54, Vitaly Kuznetsov wrote: > Vitaly Kuznetsov writes: > >> 1) ramdisks (/dev/ram*) (persistent grants and indirect descriptors >> disabled) > > sorry, there was a typo. persistent grants and indirect descriptors are > enabled with ramdisks, otherwise such testing won't make any s

Re: [Xen-devel] [XEN PATCH 1/2] hvm: Support more than 32 VCPUS when migrating.

2014-04-09 Thread Roger Pau Monné
On 09/04/14 10:33, Ian Campbell wrote: > On Tue, 2014-04-08 at 14:53 -0400, Konrad Rzeszutek Wilk wrote: >> On Tue, Apr 08, 2014 at 08:18:48PM +0200, Roger Pau Monné wrote: >>> On 08/04/14 19:25, kon...@kernel.org wrote: >>>> From: Konrad Rzeszutek Wilk >>>

Re: [Xen-devel] [XEN PATCH 1/2] hvm: Support more than 32 VCPUS when migrating.

2014-04-09 Thread Roger Pau Monné
On 08/04/14 20:53, Konrad Rzeszutek Wilk wrote: > On Tue, Apr 08, 2014 at 08:18:48PM +0200, Roger Pau Monné wrote: >> On 08/04/14 19:25, kon...@kernel.org wrote: >>> From: Konrad Rzeszutek Wilk >>> >>> When we migrate an HVM guest, by default our shared_info

Re: [Xen-devel] [XEN PATCH 1/2] hvm: Support more than 32 VCPUS when migrating.

2014-04-08 Thread Roger Pau Monné
On 08/04/14 19:25, kon...@kernel.org wrote: > From: Konrad Rzeszutek Wilk > > When we migrate an HVM guest, by default our shared_info can > only hold up to 32 CPUs. As such the hypercall > VCPUOP_register_vcpu_info was introduced which allowed us to > setup per-page areas for VCPUs. This means w

Re: [PATCH] xen-blkback: only attach blkback if the required features are met

2014-04-04 Thread Roger Pau Monné
On 04/04/14 17:01, David Vrabel wrote: > On 04/04/14 15:41, Roger Pau Monne wrote: >> Blkback cannot work properly on auto-translated guests if Xen doesn't >> update the IOMMU when performing grant maps/unmaps, so only attach if >> the newly introduced XENFEAT_hvm_gntm

[PATCH] xen-blkback: only attach blkback if the required features are met

2014-04-04 Thread Roger Pau Monne
Blkback cannot work properly on auto-translated guests if Xen doesn't update the IOMMU when performing grant maps/unmaps, so only attach if the newly introduced XENFEAT_hvm_gntmap_supports_iommu is found. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel Cc:

Re: [PATCH v2] xen: add support for MSI message groups

2014-02-28 Thread Roger Pau Monné
On 28/02/14 19:00, Boris Ostrovsky wrote: > On 02/28/2014 12:46 PM, Roger Pau Monné wrote: >> On 28/02/14 18:20, Boris Ostrovsky wrote: >>> On 02/27/2014 01:45 PM, Boris Ostrovsky wrote: >>>> On 02/27/2014 01:15 PM, Roger Pau Monne wrote: >>>>> Add supp

Re: [PATCH v2] xen: add support for MSI message groups

2014-02-28 Thread Roger Pau Monné
On 28/02/14 18:20, Boris Ostrovsky wrote: > On 02/27/2014 01:45 PM, Boris Ostrovsky wrote: >> On 02/27/2014 01:15 PM, Roger Pau Monne wrote: >>> Add support for MSI message groups for Xen Dom0 using the >>> MAP_PIRQ_TYPE_MULTI_MSI pirq map type. >>> >>>

[PATCH v2] xen: add support for MSI message groups

2014-02-27 Thread Roger Pau Monne
PHYSDEVOP_unmap_pirq on them, since the unmap must be done with the first pirq in the group. Signed-off-by: Roger Pau Monné Cc: David Vrabel Cc: Boris Ostrovsky --- Tested with an Intel ICH8 AHCI SATA controller. --- Changes since v1: - Add comments reflecting the new usage of entry_nr in

Re: [Xen-devel] [PATCH] xen: add support for MSI message groups

2014-02-27 Thread Roger Pau Monné
On 27/02/14 17:33, Boris Ostrovsky wrote: > On 02/27/2014 10:45 AM, Roger Pau Monné wrote: >>> >>> @@ -291,7 +290,10 @@ static int xen_initdom_setup_msi_irqs(struct >>> pci_dev *dev, int nvec, int type) >>> (pci_domain_nr(dev->bus)

Re: [Xen-devel] [PATCH] xen: add support for MSI message groups

2014-02-27 Thread Roger Pau Monné
On 27/02/14 15:55, Boris Ostrovsky wrote: > On 02/26/2014 11:24 AM, Roger Pau Monne wrote: >> Add support for MSI message groups for Xen Dom0 using the >> MAP_PIRQ_TYPE_MULTI_MSI pirq map type. >> >> In order to keep track of which pirq is the first one in the group al

[PATCH] xen: add support for MSI message groups

2014-02-26 Thread Roger Pau Monne
PHYSDEVOP_unmap_pirq on them, since the unmap must be done with the first pirq in the group. Signed-off-by: Roger Pau Monné --- Tested with an Intel ICH8 AHCI SATA controller. --- arch/x86/pci/xen.c | 29 ++-- drivers/xen/events/events_base.c | 47

Re: [Xen-devel] [GIT PULL] (xen) stable/for-jens-3.14 : NFO: trying to register non-static key. the code is fine but needs lockdep annotation.

2014-02-11 Thread Roger Pau Monné
On 11/02/14 18:52, David Vrabel wrote: > On 11/02/14 17:40, Roger Pau Monné wrote: >> On 11/02/14 17:07, Sander Eikelenboom wrote: >>> >>> Tuesday, February 11, 2014, 4:56:50 PM, you wrote: >>> >>>> On Tue, Feb 11, 2014 at 04:52:15PM

Re: [Xen-devel] [GIT PULL] (xen) stable/for-jens-3.14 : NFO: trying to register non-static key. the code is fine but needs lockdep annotation.

2014-02-11 Thread Roger Pau Monné
aitqueue_head+0x60/0x60 >>> [ 438.029913] [] ? trace_hardirqs_on+0xd/0x10 >>> [ 438.029919] [] ? _raw_spin_unlock_irqrestore+0x81/0x90 >>> [ 438.029925] [] ? xen_blkif_be_int+0x40/0x40 >>> [ 438.029932] [] kthread+0xe4/0x100 >>> [ 438.029938] [] ? _ra

Re: [Xen-devel] [PATCH v2 0/4] xen-blk: bug fixes

2014-02-07 Thread Roger Pau Monné
On 07/02/14 05:24, Matt Wilson wrote: > Just in case the various mailing list software ate Matt's messages, he > sent the following: > > [PATCH v2 2/4] xen-blkback: fix memory leaks > Tested-by: Matt Rushton > Reviewed-by: Matt Rushton > > [PATCH v2 3/4] xen-blkback: fix shutdown race > Tested-

[PATCH v2 1/4] xen-blkback: fix memory leak when persistent grants are used

2014-02-04 Thread Roger Pau Monne
From: Matt Rushton Currently shrink_free_pagepool() is called before the pages used for persistent grants are released via free_persistent_gnts(). This results in a memory leak when a VBD that uses persistent grants is torn down. Cc: Konrad Rzeszutek Wilk Cc: "Roger Pau Monné"

[PATCH v2 0/4] xen-blk: bug fixes

2014-02-04 Thread Roger Pau Monne
This series contain blkback bug fixes for memory leaks (patches 1 and 2) and a race (patch 3). Patch 4 removes blkif_request_segment_aligned since its memory layout is exactly the same as blkif_request_segment and should introduce no functional change. All patches should be backported to stable

[PATCH v2 2/4] xen-blkback: fix memory leaks

2014-02-04 Thread Roger Pau Monne
cleaning everything. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel Cc: Boris Ostrovsky Cc: Matt Rushton Cc: Matt Wilson Cc: Ian Campbell --- drivers/block/xen-blkback/blkback.c | 27 ++- drivers/block/xen-blkback/common.h |1

[PATCH v2 4/4] xen-blkif: drop struct blkif_request_segment_aligned

2014-02-04 Thread Roger Pau Monne
assume PAGE_SIZE == 4096. Signed-off-by: Roger Pau Monné [Description fix by Jan Beulich] Signed-off-by: Jan Beulich Reported-by: Jan Beulich Cc: Konrad Rzeszutek Wilk Cc: David Vrabel Cc: Boris Ostrovsky Cc: Matt Rushton Cc: Matt Wilson --- drivers/block/xen-blkback/blkback.c |2

[PATCH v2 3/4] xen-blkback: fix shutdown race

2014-02-04 Thread Roger Pau Monne
Introduce a new variable to keep track of the number of in-flight requests. We need to make sure that when xen_blkif_put is called the request has already been freed and we can safely free xen_blkif, which was not the case before. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc

Re: [Xen-devel] [PATCH 3/3] xen-blkback: fix shutdown race

2014-02-04 Thread Roger Pau Monné
On 04/02/14 09:31, Jan Beulich wrote: >>>> On 04.02.14 at 09:16, Roger Pau Monné wrote: >> On 04/02/14 09:02, Jan Beulich wrote: >>>>>> On 03.02.14 at 17:58, Roger Pau Monné wrote: >>>> On 29/01/14 09:52, Jan Beulich wrote: >&

Re: [Xen-devel] [PATCH 3/3] xen-blkback: fix shutdown race

2014-02-04 Thread Roger Pau Monné
On 04/02/14 09:02, Jan Beulich wrote: >>>> On 03.02.14 at 17:58, Roger Pau Monné wrote: >> On 29/01/14 09:52, Jan Beulich wrote: >>>>>> On 28.01.14 at 18:43, Roger Pau Monne wrote: >>>> + free_req(blkif, pending_req); >>>> +

Re: [Xen-devel] [PATCH 3/3] xen-blkback: fix shutdown race

2014-02-03 Thread Roger Pau Monné
On 29/01/14 09:52, Jan Beulich wrote: >>>> On 28.01.14 at 18:43, Roger Pau Monne wrote: >> --- a/drivers/block/xen-blkback/blkback.c >> +++ b/drivers/block/xen-blkback/blkback.c >> @@ -985,17 +985,31 @@ static void __end_block_io_op(struct pending_req >> *pe

Re: [PATCH V0] linux PVH: Set CR4 flags

2014-01-30 Thread Roger Pau Monné
On 30/01/14 00:15, Mukesh Rathor wrote: > Konrad, > > The CR4 settings were dropped from my earlier patch because you didn't > wanna enable them. But since you do now, we need to set them in the APs > also. If you decide not too again, please apply my prev patch > "pvh: disable pse feature for now

Re: [Xen-devel] [PATCH 3/3] xen-blkback: fix shutdown race

2014-01-29 Thread Roger Pau Monné
On 29/01/14 08:52, Jan Beulich wrote: >>>> On 28.01.14 at 18:43, Roger Pau Monne wrote: >> --- a/drivers/block/xen-blkback/blkback.c >> +++ b/drivers/block/xen-blkback/blkback.c >> @@ -985,17 +985,31 @@ static void __end_block_io_op(struct pending_req >> *pe

xen-blkback: bug fixes

2014-01-28 Thread Roger Pau Monne
blkback bug fixes for memory leaks (patches 1 and 2) and a race (patch 3). -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at htt

[PATCH 2/3] xen-blkback: fix memory leaks

2014-01-28 Thread Roger Pau Monne
cleaning everything. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel Cc: Boris Ostrovsky Cc: Matt Rushton Cc: Matt Wilson Cc: Ian Campbell --- drivers/block/xen-blkback/blkback.c | 27 ++- drivers/block/xen-blkback/common.h |1

[PATCH 3/3] xen-blkback: fix shutdown race

2014-01-28 Thread Roger Pau Monne
Move the call to xen_blkif_put after we have freed the request, otherwise we have a race between the release of the request and the cleanup done in xen_blkif_free. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel Cc: Boris Ostrovsky Cc: Matt Rushton Cc: Matt Wilson

[PATCH 1/3] xen-blkback: fix memory leak when persistent grants are used

2014-01-28 Thread Roger Pau Monne
From: Matt Rushton Currently shrink_free_pagepool() is called before the pages used for persistent grants are released via free_persistent_gnts(). This results in a memory leak when a VBD that uses persistent grants is torn down. Cc: Konrad Rzeszutek Wilk Cc: "Roger Pau Monné"

Re: [PATCH] xen-blkback: fix memory leaks

2014-01-28 Thread Roger Pau Monné
On 28/01/14 16:37, Konrad Rzeszutek Wilk wrote: > On Tue, Jan 28, 2014 at 01:44:37PM +0100, Roger Pau Monné wrote: >> On 27/01/14 22:21, Konrad Rzeszutek Wilk wrote: >>> On Mon, Jan 27, 2014 at 11:13:41AM +0100, Roger Pau Monne wrote: >>>> @@ -976,17 +983,19 @@ static

Re: [PATCH] xen-blkback: fix memory leaks

2014-01-28 Thread Roger Pau Monné
On 27/01/14 22:21, Konrad Rzeszutek Wilk wrote: > On Mon, Jan 27, 2014 at 11:13:41AM +0100, Roger Pau Monne wrote: >> I've at least identified two possible memory leaks in blkback, both >> related to the shutdown path of a VBD: >> >> - We don't wait for an

Re: [PATCH] xen-blkback: fix memory leaks

2014-01-27 Thread Roger Pau Monné
On 27/01/14 17:09, Konrad Rzeszutek Wilk wrote: > On Mon, Jan 27, 2014 at 11:13:41AM +0100, Roger Pau Monne wrote: >> I've at least identified two possible memory leaks in blkback, both >> related to the shutdown path of a VBD: >> >> - We don't wait for an

[PATCH] xen-blkback: fix memory leaks

2014-01-27 Thread Roger Pau Monne
some checks in xen_blkif_free to make sure we are cleaning everything. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel Cc: Boris Ostrovsky Cc: Matt Rushton Cc: Matt Wilson Cc: Ian Campbell --- This should be applied after the patch: xen-blkback: fix memory leak when pe

Re: [PATCH] xen-blkback: fix memory leak when persistent grants are used

2014-01-24 Thread Roger Pau Monné
down. Good catch. > Cc: Konrad Rzeszutek Wilk > Cc: "Roger Pau Monné" > Cc: Ian Campbell > Cc: David Vrabel > Cc: linux-kernel@vger.kernel.org > Cc: xen-de...@lists.xen.org > Cc: Anthony Liguori > Signed-off-by: Matt Rushton > Signed-off-by: Matt Wils

Re: [PATCH net-next v3 1/9] xen-netback: Introduce TX grant map definitions

2014-01-09 Thread Roger Pau Monné
On 09/01/14 16:30, Wei Liu wrote: > On Wed, Jan 08, 2014 at 12:10:10AM +, Zoltan Kiss wrote: >> This patch contains the new definitions necessary for grant mapping. >> >> v2: >> - move unmapping to separate thread. The NAPI instance has to be scheduled >> even from thread context, which can c

Re: [Xen-devel] [PATCH v2] xen/block: Correctly define structures in public headers on ARM32 and ARM64

2013-12-12 Thread Roger Pau Monné
freezed. >> >> Only one architecture (x86_32) doesn't have 64-bit ABI for the block >> interface. >> Don't add padding if Linux is compiled for this architecture. > > Konrad asked for confirmation that this didn't change x86. I've also tested this u

Re: [Xen-devel] [PATCH RFC] xen-block: correctly define structures in public headers

2013-12-11 Thread Roger Pau Monné
On 11/12/13 17:18, Stefano Stabellini wrote: > On Tue, 3 Dec 2013, Konrad Rzeszutek Wilk wrote: If Konrad and Boris agree that breaking the kernel's ABI in this way is acceptable in this specific case, I'll defer to them. >>> >>> My opinion as Xen on ARM hypervisor maintainer is that this

Re: [Xen-devel] [PATCH RFC] xen-block: correctly define structures in public headers

2013-12-04 Thread Roger Pau Monné
On 04/12/13 10:28, Ian Campbell wrote: > On Tue, 2013-12-03 at 15:11 -0500, Konrad Rzeszutek Wilk wrote: If Konrad and Boris agree that breaking the kernel's ABI in this way is acceptable in this specific case, I'll defer to them. >>> >>> My opinion as Xen on ARM hypervisor maintainer is

Re: [Xen-devel] [PATCH RFC] xen-block: correctly define structures in public headers

2013-12-03 Thread Roger Pau Monné
On 03/12/13 12:14, Jan Beulich wrote: >>>> On 03.12.13 at 11:57, Roger Pau Monne wrote: >> struct blkif_request_rw { >> uint8_tnr_segments; /* number of segments */ >> blkif_vdev_t handle; /* only for read/write

Re: [Xen-devel] [PATCH RFC] xen-block: correctly define structures in public headers

2013-12-03 Thread Roger Pau Monné
On 03/12/13 12:05, Ian Campbell wrote: > On Tue, 2013-12-03 at 11:57 +0100, Roger Pau Monne wrote: >> Using __packed__ on the public interface is not correct, this >> structures should be compiled using the native ABI, and __packed__ >> should only be used in the backend

Re: [PATCH RFC] xen-block: correctly define structures in public headers

2013-12-03 Thread Roger Pau Monné
On 03/12/13 12:01, David Vrabel wrote: > On 03/12/13 10:57, Roger Pau Monne wrote: >> Using __packed__ on the public interface is not correct, this >> structures should be compiled using the native ABI, and __packed__ >> should only be used in the backend counterpart of those

[PATCH RFC] xen-block: correctly define structures in public headers

2013-12-03 Thread Roger Pau Monne
was incorrectly using the X86_32 protocol ABI. This patch fixes it, but also breaks compatibility, so an ARM DomU kernel compiled with this patch will fail to communicate with PV disk devices unless the Dom0 also has this patch. Signed-off-by: Roger Pau Monné Reported-by: Julien Grall Cc: Julien

Re: [PATCH 3.13-rc1] xen-blkfront: Silence pfn maybe-uninitialized warning

2013-11-15 Thread Roger Pau Monné
gt;>^ >> drivers/block/xen-blkfront.c:492:19: note: 'pfn' was declared here >> unsigned long pfn; >> >> Cc: Konrad Rzeszutek Wilk >> Cc: Boris Ostrovsky >> Cc: David Vrabel >> Signed-off-by: Tim Gardner Acked-by: Rog

Re: [Xen-devel] [PATCH] block: xen-blkfront: Fix possible NULL ptr dereference

2013-11-11 Thread Roger Pau Monné
On 09/11/13 16:36, Felipe Pena wrote: > In the blkif_release function the bdget_disk() call might returns > a NULL ptr which might be dereferenced on bdev->bd_openers checking > > Signed-off-by: Felipe Pena > --- > drivers/block/xen-blkfront.c |4 > 1 file changed, 4 insertions(+) > >

Re: [Xen-devel] [PATCH] grant-table: don't set m2p override if kmap_ops is not set

2013-11-05 Thread Roger Pau Monné
On 05/11/13 16:08, Ian Campbell wrote: > On Tue, 2013-11-05 at 16:01 +0100, Roger Pau Monné wrote: >> On 05/11/13 15:56, Konrad Rzeszutek Wilk wrote: >>> On Tue, Nov 05, 2013 at 03:47:08PM +0100, Roger Pau Monné wrote: >>>> On 05/11/13 13:36, David Vrabel wrote: >

Re: [PATCH] grant-table: don't set m2p override if kmap_ops is not set

2013-11-05 Thread Roger Pau Monné
On 05/11/13 15:56, Konrad Rzeszutek Wilk wrote: > On Tue, Nov 05, 2013 at 03:47:08PM +0100, Roger Pau Monné wrote: >> On 05/11/13 13:36, David Vrabel wrote: >>> On 05/11/13 11:24, Roger Pau Monne wrote: >>>> IMHO there's no reason to set a m2p override if the m

Re: [PATCH] grant-table: don't set m2p override if kmap_ops is not set

2013-11-05 Thread Roger Pau Monné
On 05/11/13 13:36, David Vrabel wrote: > On 05/11/13 11:24, Roger Pau Monne wrote: >> IMHO there's no reason to set a m2p override if the mapping is done in >> kernel space, so only set the m2p override when kmap_ops is set. > > Can you provide a more detailed reason

Re: [PATCH] grant-table: don't set m2p override if kmap_ops is not set

2013-11-05 Thread Roger Pau Monné
On 05/11/13 12:24, Roger Pau Monne wrote: > IMHO there's no reason to set a m2p override if the mapping is done in > kernel space, so only set the m2p override when kmap_ops is set. > > When kmap_ops is not set, just set the correct p2m translation, this > avoids touching th

[PATCH] grant-table: don't set m2p override if kmap_ops is not set

2013-11-05 Thread Roger Pau Monne
IMHO there's no reason to set a m2p override if the mapping is done in kernel space, so only set the m2p override when kmap_ops is set. When kmap_ops is not set, just set the correct p2m translation, this avoids touching the m2p lock, reducing contention around it. Signed-off-by: Roger Pau

Re: [Xen-devel] [PATCH v3] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-11-04 Thread Roger Pau Monné
On 04/11/13 16:49, Ian Campbell wrote: > On Mon, 2013-11-04 at 16:38 +0100, Roger Pau Monne wrote: >> The new GNTTABOP_unmap_and_duplicate operation > > I don't see this op in mainline Xen anywhere... > > Was it part of Stefano's original swiotlb for ARM st

[PATCH v3] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-11-04 Thread Roger Pau Monne
The new GNTTABOP_unmap_and_duplicate operation doesn't zero the mapping passed in new_addr, allowing us to perform batch unmaps in p2m code without requiring the use of a multicall. Signed-off-by: Roger Pau Monné Cc: Stefano Stabellini Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- Ch

[PATCH] xen-blkfront: restore the non-persistent data path

2013-10-29 Thread Roger Pau Monne
when it is not actually needed. Signed-off-by: Roger Pau Monné Reported-by: Felipe Franciosi Cc: Felipe Franciosi Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- drivers/block/xen-blkfront.c | 124 ++ 1 files changed, 100 insertions(+), 24 deletions(-

[PATCH v2] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-08-27 Thread Roger Pau Monne
The new GNTTABOP_unmap_and_duplicate operation doesn't zero the mapping passed in new_addr, allowing us to perform batch unmaps in p2m code without requiring the use of a multicall. Signed-off-by: Roger Pau Monné Cc: Stefano Stabellini Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- Ch

Re: [PATCH v1] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-08-27 Thread Roger Pau Monné
On 04/08/13 16:56, Stefano Stabellini wrote: > On Thu, 1 Aug 2013, Roger Pau Monne wrote: >> The new GNTTABOP_unmap_and_duplicate operation doesn't zero the >> mapping passed in new_addr, allowing us to perform batch unmaps in p2m >> code without requiring the use of a m

Re: [Xen-devel] [PATCH] xen-blkback: use bigger array for batch gnt operations

2013-08-26 Thread Roger Pau Monné
On 01/08/13 16:18, Roger Pau Monné wrote: > On 01/08/13 14:30, David Vrabel wrote: >> On 01/08/13 13:08, Roger Pau Monne wrote: >>> Right now the maximum number of grant operations that can be batched >>> in a single request is BLKIF_MAX_SEGMENTS_PER_REQUEST (11). This

Re: [Xen-devel] [PATCH 3/3] xen-blkfront: revoke foreign access for grants not mapped by the backend

2013-08-12 Thread Roger Pau Monné
On 09/08/13 17:08, Konrad Rzeszutek Wilk wrote: > On Thu, Aug 01, 2013 at 11:10:15AM +0100, David Vrabel wrote: >> On 31/07/13 16:00, Roger Pau Monne wrote: >>> There's no need to keep the foreign access in a grant if it is not >>> persistently mapped by the backen

[PATCH v2 1/2] xen-blkfront: improve aproximation of required grants per request

2013-08-12 Thread Roger Pau Monne
. for_each_sg iterates over the DMA addr+len pairs and uses a grant page for each of them. Signed-off-by: Roger Pau Monné Reviewed-by: David Vrabel Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- drivers/block/xen-blkfront.c | 11 +++ 1 files changed, 7 insertions(+), 4 deletions(-) diff

[PATCH v2 2/2] xen-blkfront: revoke foreign access for grants not mapped by the backend

2013-08-12 Thread Roger Pau Monne
same grants as the backend, and it will always try to use grants that are already mapped by the backend. Also the number of persistent grants in blkfront is the same as in blkback (and is controlled by the value in blkback). Signed-off-by: Roger Pau Monné Reviewed-by: David Vrabel Acked-by:

[PATCH v2 0/2] xen-blkfront: fixes for blkfront

2013-08-12 Thread Roger Pau Monne
This series contains a couple of improvements to blkfront to make it work better if there's a shortage on available free grants. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kern

Re: [Xen-devel] [PATCH] xen-blkback: use bigger array for batch gnt operations

2013-08-01 Thread Roger Pau Monné
On 01/08/13 14:30, David Vrabel wrote: > On 01/08/13 13:08, Roger Pau Monne wrote: >> Right now the maximum number of grant operations that can be batched >> in a single request is BLKIF_MAX_SEGMENTS_PER_REQUEST (11). This was >> OK before indirect descriptors because

[PATCH] xen-blkback: use bigger array for batch gnt operations

2013-08-01 Thread Roger Pau Monne
size of batch grant operations and replaces the use of stack memory with pre-allocated memory, that is reserved when the blkback instance is initialized. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- drivers/block/xen-blkback/blkback.c | 29

[PATCH v1] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-08-01 Thread Roger Pau Monne
The new GNTTABOP_unmap_and_duplicate operation doesn't zero the mapping passed in new_addr, allowing us to perform batch unmaps in p2m code without requiring the use of a multicall. Signed-off-by: Roger Pau Monné Cc: Stefano Stabellini Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- Ch

Re: [Xen-devel] [PATCH RFC] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-08-01 Thread Roger Pau Monné
On 01/08/13 11:53, David Vrabel wrote: > On 31/07/13 17:07, Roger Pau Monne wrote: >> The new GNTTABOP_unmap_and_duplicate operation doesn't zero the >> mapping passed in new_addr, allowing us to perform batch unmaps in p2m >> code without requiring the use of a multical

[PATCH RFC] p2m: use GNTTABOP_unmap_and_duplicate if available

2013-07-31 Thread Roger Pau Monne
The new GNTTABOP_unmap_and_duplicate operation doesn't zero the mapping passed in new_addr, allowing us to perform batch unmaps in p2m code without requiring the use of a multicall. Signed-off-by: Roger Pau Monné Cc: Stefano Stabellini Cc: Konrad Rzeszutek Wilk --- I don't currently

[PATCH 1/3] xen-gnt: prevent adding duplicate gnt callbacks

2013-07-31 Thread Roger Pau Monne
ere callback == callback->next. Replace this check with a proper one that iterates over the list to see if the callback has already been added. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- This patch should be backported to stable trees --- drivers/xen/grant-t

[PATCH 2/3] xen-blkfront: improve aproximation of required grants per request

2013-07-31 Thread Roger Pau Monne
. for_each_sg iterates over the DMA addr+len pairs and uses a grant page for each of them. Signed-off-by: Roger Pau Monné Cc: Konrad Rzeszutek Wilk Cc: David Vrabel --- drivers/block/xen-blkfront.c | 11 +++ 1 files changed, 7 insertions(+), 4 deletions(-) diff --git a/drivers/block/xen

<    1   2   3   4   5   6   >