From mboxrd@z Thu Jan 1 00:00:00 1970 From: acourbot@nvidia.com (Alexandre Courbot) Date: Mon, 11 Apr 2016 16:55:38 +0900 Subject: Nouveau crashes in 4.6-rc on arm64 In-Reply-To: <570B50B4.4020304@nvidia.com> References: <57064992.1060509@arm.com> <570737F5.30105@nvidia.com> <5707FC9F.50905@arm.com> <570B50B4.4020304@nvidia.com> Message-ID: <570B587A.5090509@nvidia.com> To: linux-arm-kernel@lists.infradead.org List-Id: linux-arm-kernel.lists.infradead.org On 04/11/2016 04:22 PM, Alexandre Courbot wrote: > ... or maybe we could just unconditionally sync all buffers and let the > DMA API abstract this away. My concern is that on coherent architectures > we would still need to loop over all the pages for nothing, as I don't > think the loop (see e.g. nouveau_bo_sync_for_cpu in nouveau_bo.c) can be > optimized away by the compiler. Looking at the code it actually turns out we are already calling the sync functions on coherent buses anyway, so maybe we have little reasons to keep this at all? From mboxrd@z Thu Jan 1 00:00:00 1970 From: Alexandre Courbot Subject: Re: Nouveau crashes in 4.6-rc on arm64 Date: Mon, 11 Apr 2016 16:55:38 +0900 Message-ID: <570B587A.5090509@nvidia.com> References: <57064992.1060509@arm.com> <570737F5.30105@nvidia.com> <5707FC9F.50905@arm.com> <570B50B4.4020304@nvidia.com> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8"; Format="flowed" Content-Transfer-Encoding: base64 Return-path: Received: from hkmmgate102.nvidia.com (nat-hk.nvidia.com [203.18.50.4]) by gabe.freedesktop.org (Postfix) with ESMTPS id 92CD46E294 for ; Mon, 11 Apr 2016 07:55:46 +0000 (UTC) In-Reply-To: <570B50B4.4020304@nvidia.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: Robin Murphy , dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: bskeggs@redhat.com List-Id: dri-devel@lists.freedesktop.org T24gMDQvMTEvMjAxNiAwNDoyMiBQTSwgQWxleGFuZHJlIENvdXJib3Qgd3JvdGU6Cj4gLi4uIG9y IG1heWJlIHdlIGNvdWxkIGp1c3QgdW5jb25kaXRpb25hbGx5IHN5bmMgYWxsIGJ1ZmZlcnMgYW5k IGxldCB0aGUKPiBETUEgQVBJIGFic3RyYWN0IHRoaXMgYXdheS4gTXkgY29uY2VybiBpcyB0aGF0 IG9uIGNvaGVyZW50IGFyY2hpdGVjdHVyZXMKPiB3ZSB3b3VsZCBzdGlsbCBuZWVkIHRvIGxvb3Ag b3ZlciBhbGwgdGhlIHBhZ2VzIGZvciBub3RoaW5nLCBhcyBJIGRvbid0Cj4gdGhpbmsgdGhlIGxv b3AgKHNlZSBlLmcuIG5vdXZlYXVfYm9fc3luY19mb3JfY3B1IGluIG5vdXZlYXVfYm8uYykgY2Fu IGJlCj4gb3B0aW1pemVkIGF3YXkgYnkgdGhlIGNvbXBpbGVyLgoKTG9va2luZyBhdCB0aGUgY29k ZSBpdCBhY3R1YWxseSB0dXJucyBvdXQgd2UgYXJlIGFscmVhZHkgY2FsbGluZyB0aGUgCnN5bmMg ZnVuY3Rpb25zIG9uIGNvaGVyZW50IGJ1c2VzIGFueXdheSwgc28gbWF5YmUgd2UgaGF2ZSBsaXR0 bGUgcmVhc29ucyAKdG8ga2VlcCB0aGlzIGF0IGFsbD8KX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX18KZHJpLWRldmVsIG1haWxpbmcgbGlzdApkcmktZGV2ZWxA bGlzdHMuZnJlZWRlc2t0b3Aub3JnCmh0dHBzOi8vbGlzdHMuZnJlZWRlc2t0b3Aub3JnL21haWxt YW4vbGlzdGluZm8vZHJpLWRldmVsCg== From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752834AbcDKHzr (ORCPT ); Mon, 11 Apr 2016 03:55:47 -0400 Received: from nat-hk.nvidia.com ([203.18.50.4]:64095 "EHLO hkmmgate102.nvidia.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752377AbcDKHzq (ORCPT ); Mon, 11 Apr 2016 03:55:46 -0400 X-PGP-Universal: processed; by hkpgpgate101.nvidia.com on Mon, 11 Apr 2016 00:55:43 -0700 Subject: Re: Nouveau crashes in 4.6-rc on arm64 To: Robin Murphy , , , References: <57064992.1060509@arm.com> <570737F5.30105@nvidia.com> <5707FC9F.50905@arm.com> <570B50B4.4020304@nvidia.com> CC: From: Alexandre Courbot Organization: NVIDIA X-Nvconfidentiality: public Message-ID: <570B587A.5090509@nvidia.com> Date: Mon, 11 Apr 2016 16:55:38 +0900 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 MIME-Version: 1.0 In-Reply-To: <570B50B4.4020304@nvidia.com> X-Originating-IP: [10.19.57.128] X-ClientProxiedBy: DRBGMAIL103.nvidia.com (10.18.16.22) To HKMAIL103.nvidia.com (10.18.16.12) Content-Type: text/plain; charset="windows-1252"; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/11/2016 04:22 PM, Alexandre Courbot wrote: > ... or maybe we could just unconditionally sync all buffers and let the > DMA API abstract this away. My concern is that on coherent architectures > we would still need to loop over all the pages for nothing, as I don't > think the loop (see e.g. nouveau_bo_sync_for_cpu in nouveau_bo.c) can be > optimized away by the compiler. Looking at the code it actually turns out we are already calling the sync functions on coherent buses anyway, so maybe we have little reasons to keep this at all?