From mboxrd@z Thu Jan 1 00:00:00 1970 From: Andrew Cooper Subject: Re: [RFC PATCH] page_alloc: use first half of higher order chunks when halving Date: Wed, 26 Mar 2014 11:45:50 +0000 Message-ID: <5332BDEE.7020306@citrix.com> References: <1395746524-9670-1-git-send-email-msw@linux.com> <20140325121922.GB12931@deinos.phlegethon.org> <20140325132740.GB11708@u109add4315675089e695.ant.amazon.com> <5331E269.9090708@gmail.com> <20140326095533.GA7885@deinos.phlegethon.org> <20140326101746.GA14195@u109add4315675089e695.ant.amazon.com> <5332AF82.2010506@citrix.com> <20140326104836.GB14195@u109add4315675089e695.ant.amazon.com> <1395832429.22808.52.camel@kazak.uk.xensource.com> <20140326114151.GC14195@u109add4315675089e695.ant.amazon.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1WSmHr-0003et-NP for xen-devel@lists.xenproject.org; Wed, 26 Mar 2014 11:46:27 +0000 In-Reply-To: <20140326114151.GC14195@u109add4315675089e695.ant.amazon.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Matt Wilson Cc: Keir Fraser , Ian Campbell , Matthew Rushton , Tim Deegan , Jan Beulich , David Vrabel , Matt Wilson , xen-devel@lists.xenproject.org, Malcolm Crossley List-Id: xen-devel@lists.xenproject.org On 26/03/14 11:41, Matt Wilson wrote: > On Wed, Mar 26, 2014 at 11:13:49AM +0000, Ian Campbell wrote: >> On Wed, 2014-03-26 at 12:48 +0200, Matt Wilson wrote: >>> On Wed, Mar 26, 2014 at 10:44:18AM +0000, David Vrabel wrote: >>>> On 26/03/14 10:17, Matt Wilson wrote: >>>>> Konrad, what's the possibility of fixing this in Linux Xen PV setup >>>>> code? I think it'd be a matter batching up pages and doing larger >>>>> order allocations in linux/arch/x86/xen/setup.c:xen_do_chunk(), >>>>> falling back to smaller pages if allocations fail due to >>>>> fragmentation, etc. >>>> We plan to fix problems caused by non-machine-contiguous memory by >>>> setting up the IOMMU to have 1:1 bus to pseudo-physical mappings. This >>>> would avoid using the swiotlb always[1], regardless of the machine >>>> layout of dom0 or the driver domain. >>>> >>>> I think I would prefer this approach rather than making xen/setup.c even >>>> more horribly complicated. >>> I imagine that some users will not want to run dom0 under an IOMMU. >> Then they have chosen that (for whatever reason) over performance, >> right? > IOMMU is not free, so I imagine that some users would actually be > choosing to avoid it specifically for performance reasons. > > --msw True, but if people are actually looking for performance, they will be turning on features like GRO and more generically scatter/gather which results in drivers using single page DMA mappings at a time, which completely bypass the bouncing in the swiotlb. ~Andrew