Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp1009523imu; Thu, 20 Dec 2018 08:41:05 -0800 (PST) X-Google-Smtp-Source: AFSGD/XwepfsMcglGI9MmzY/SscifgiUFYZOLpTuXVKRrmsYl2pBpM8iTDHyw60Gq1zdOwj5zqWP X-Received: by 2002:a17:902:a70b:: with SMTP id w11mr24649772plq.84.1545324065475; Thu, 20 Dec 2018 08:41:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1545324065; cv=none; d=google.com; s=arc-20160816; b=ushQ8HoG4zzEJSatDnRYEvHy4yseO9pv1dEZxP8voBBqlk1xIhbgBuFPowUAOVu8M+ NSS2/Y3AS1fX/bnyi3Mltg33cblnoWJ5v8GZJmeXszEM7lorz6n0rbY5s6Fo8v2mNLfx vl4jZPEpO8LQqYE0jMnv9fFF1hbBK7iYIXss3cFn8LhQ4/50uOo1aY8jL/1p5U+pLTB2 G7R9fHHE3wC7YBQIKuDKJ5rQYW7HFpuYncRCoDhy92XQoQlDOBiIQNRbKnPHP856rLF+ F41CvnqyHdwkvRcPqWmykIYxV1GMoegXxm5LQ92VThkEoFjPZEIwY50q1/QVee4nvieb GHEQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-transfer-encoding:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=IiiofMg/qq/P4WdP5kU2046zbu8hrB+SzVmheSXfIsc=; b=jFfv2KDCMMzd9DgncAqZSPGN1q5jnhD35s2McqHOH3g2KSyU5M0K6pCLc2ou/v06mn LU0yMlrZYqP/4Ua+la4XVXIAut5p4wTSpWt846ltlWxYeF59uU/CqkaorFKPmaeNKjhv BW7wfdh2jq+ST30jhX/qa2aGvZX66UawbkOKRL2fWC23Kq230RJxZ0sbyikGcnB9DJNZ wBUnBLxhIJwlHh1KxerSGGhThH7rUeeAPOQSRxYmjIRgmXqXs2U6E9dCZcUQFBqD7gsP o+5/7VxeuJZexdWlZSIEF1z3tPvB0fSMSn/pX+4jMKBKCnB63F9mT+TlaA9MBnaMzOnl 6WCA== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=lLHUi3LP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id v10si19327755plg.82.2018.12.20.08.40.50; Thu, 20 Dec 2018 08:41:05 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=lLHUi3LP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387839AbeLTPhW (ORCPT + 99 others); Thu, 20 Dec 2018 10:37:22 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:44408 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729447AbeLTPhW (ORCPT ); Thu, 20 Dec 2018 10:37:22 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Transfer-Encoding :Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Sender:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=IiiofMg/qq/P4WdP5kU2046zbu8hrB+SzVmheSXfIsc=; b=lLHUi3LPlLPMZYiEGuP5gYOOdZ lQDs+TwTfXpGoWKQj98M0d4cMWATjB7HFd/GXDAhdRSM2KLclfGQSLwKpofeTyOXm9Z4g5QSRqZQK CGuiRUXw0Gvr6I0xjlXqdY5lyqw9NhxNDMGzuqdDYR75+sZMyCe6kO6O7axyCXnax64T08Mbj47Fp Xy4IEylXmSmA65qOulsUsvccEnEijI0ZjKtEhede8pB8NtTftFaVc/J0SAx5xcvx8lmrfMIacQuip d+M6kBp/Kc2cxKjWufPAfzeinH72IYJgKPVQZRTm5Vu7zxCunJI2CrjdyqldZ+/zi4mqNfaXdPBZE J74y71SQ==; Received: from hch by bombadil.infradead.org with local (Exim 4.90_1 #2 (Red Hat Linux)) id 1ga0Nz-0008RN-Og; Thu, 20 Dec 2018 15:37:19 +0000 Date: Thu, 20 Dec 2018 07:37:19 -0800 From: Christoph Hellwig To: Gerd Hoffmann Cc: Oleksandr Andrushchenko , Noralf =?iso-8859-1?Q?Tr=F8nnes?= , xen-devel@lists.xenproject.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, daniel.vetter@intel.com, jgross@suse.com, boris.ostrovsky@oracle.com, Oleksandr Andrushchenko Subject: Re: [PATCH] drm/xen-front: Make shmem backed display buffer coherent Message-ID: <20181220153719.GB22997@infradead.org> References: <20181127103252.20994-1-andr2000@gmail.com> <17640791-5306-f7e4-8588-dd39c14e975b@tronnes.org> <20181219131452.cehks3kabcwuuk7i@sirius.home.kraxel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20181219131452.cehks3kabcwuuk7i@sirius.home.kraxel.org> User-Agent: Mutt/1.9.2 (2017-12-15) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Dec 19, 2018 at 02:14:52PM +0100, Gerd Hoffmann wrote: > > > > > +??? if (!dma_map_sg(dev->dev, xen_obj->sgt->sgl, xen_obj->sgt->nents, > > > > +??????????? DMA_BIDIRECTIONAL)) { > > > > > > > > > Are you using the DMA streaming API as a way to flush the caches? > > Yes > > > Does this mean that GFP_USER isn't making the buffer coherent? > > > > No, it didn't help. I had a question [1] if there are any other better way > > to achieve the same, but didn't have any response yet. So, I implemented > > it via DMA API which helped. > > set_pages_array_*() ? > > See arch/x86/include/asm/set_memory.h That sounds even more bogus, don't go there.