Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp4212937pxa; Mon, 10 Aug 2020 04:00:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxTlZZF1jTY3SokdCy5t84GA67RJK44UahBqv/rx+hyq75zRtMwSlqsZrg3Gt6VH+txh4tm X-Received: by 2002:a17:906:7e57:: with SMTP id z23mr20656153ejr.294.1597057204627; Mon, 10 Aug 2020 04:00:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597057204; cv=none; d=google.com; s=arc-20160816; b=ydAP3smoJ2ywqy1sw6SMvWEcGBR41yWi2BhG5u/XkVeawT0h/zGb4grZ/hzM8bYbe2 cRSxgHADt9KRVixNX428EBhwz5DIkaUSSN4kmYXi1EQUhwyQf5QYIuBgoSIQSl00fkXW cv1NDyTRNtvFchvObpSo7HPgSmX+J882iYiYsWXVAwY91gOZOAtlvP5ZqpLwyGMmnEFW 3mu4MGkkkks9bhhOtdgoQsIu8/CQPLAh1cPuE1iuO+Laa7YSd0U2p0IUfEAbkyopP0Zv UoJzxXcrzdB+FtLg0SP28+9vnlwH9L5xp74MRq1gbSbrfIYUVPalyUDkxf8kEaOfikdk xYPw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=quLpcUus8uiQziHs6adRS3EDfAAayFKpjrPdwajKMrc=; b=u7nK/kt2fvLQ6+d1q0IBq/XmrddNR/p52K7M9vKxo03xRhm3k0ueNlyRS/DAelxejY ek2ENSRNu99Ib18ih/ROispWLMgnsYeYbeJ7VuGDWrTau3+55vfThxS6vplP+SaCJWoZ mzaLLMqRUCejhtZ+VXSuhypAe40IG1NFEDxA+4aOgmTsGhoO7p7X/JXoshfyy1p099bB +QCAbkNTgjFVIn/Gu/SQ8SXUCEBWzRifgSt3/rMBT7qwCmeNIoqXX6/G64zrHOgqPghv vQTbmkje7guzhaoKtFIl9XbH4K7ZfT7ZkOC+OZCszw0Oi2OAUSmagwohs33rvyJusWp3 ruEA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rv4si10011701ejb.366.2020.08.10.03.59.42; Mon, 10 Aug 2020 04:00:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726524AbgHJK7B (ORCPT + 99 others); Mon, 10 Aug 2020 06:59:01 -0400 Received: from mail.netline.ch ([148.251.143.178]:41850 "EHLO netline-mail3.netline.ch" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726173AbgHJK7B (ORCPT ); Mon, 10 Aug 2020 06:59:01 -0400 X-Greylist: delayed 489 seconds by postgrey-1.27 at vger.kernel.org; Mon, 10 Aug 2020 06:58:59 EDT Received: from localhost (localhost [127.0.0.1]) by netline-mail3.netline.ch (Postfix) with ESMTP id A582E2A6042; Mon, 10 Aug 2020 12:50:48 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at netline-mail3.netline.ch Received: from netline-mail3.netline.ch ([127.0.0.1]) by localhost (netline-mail3.netline.ch [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Mpbg-h6jHzk1; Mon, 10 Aug 2020 12:50:48 +0200 (CEST) Received: from thor (212.174.63.188.dynamic.wline.res.cust.swisscom.ch [188.63.174.212]) by netline-mail3.netline.ch (Postfix) with ESMTPSA id 9C3F02A6016; Mon, 10 Aug 2020 12:50:46 +0200 (CEST) Received: from [::1] by thor with esmtp (Exim 4.94) (envelope-from ) id 1k55O9-000Uyj-S3; Mon, 10 Aug 2020 12:50:45 +0200 Subject: Re: [PATCH] gpu/drm: Remove TTM_PL_FLAG_WC of VRAM to fix writecombine issue for Loongson64 To: =?UTF-8?Q?Christian_K=c3=b6nig?= , Jiaxun Yang , Thomas Bogendoerfer , Tiezhu Yang Cc: Alex Deucher , Huacai Chen , linux-mips@vger.kernel.org, amd-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org References: <1596871502-3432-1-git-send-email-yangtiezhu@loongson.cn> <20200808134147.GA5772@alpha.franken.de> <38857c24-25c4-cff3-569e-5bcb773bfae6@amd.com> From: =?UTF-8?Q?Michel_D=c3=a4nzer?= Message-ID: <2f3fd325-8093-98e7-5bc8-75490258baac@daenzer.net> Date: Mon, 10 Aug 2020 12:50:45 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.11.0 MIME-Version: 1.0 In-Reply-To: <38857c24-25c4-cff3-569e-5bcb773bfae6@amd.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-CA Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2020-08-09 2:13 p.m., Christian König wrote: > Am 08.08.20 um 15:50 schrieb Jiaxun Yang: >> 在 2020/8/8 下午9:41, Thomas Bogendoerfer 写道: >>> On Sat, Aug 08, 2020 at 03:25:02PM +0800, Tiezhu Yang wrote: >>>> Loongson processors have a writecombine issue that maybe failed to >>>> write back framebuffer used with ATI Radeon or AMD GPU at times, >>>> after commit 8a08e50cee66 ("drm: Permit video-buffers writecombine >>>> mapping for MIPS"), there exists some errors such as blurred screen >>>> and lockup, and so on. >>>> >>>> Remove the flag TTM_PL_FLAG_WC of VRAM to fix writecombine issue for >>>> Loongson64 to work well with ATI Radeon or AMD GPU, and it has no any >>>> influence on the other platforms. >>> well it's not my call to take or reject this patch, but I already >>> indicated it might be better to disable writecombine on the CPU >>> detection side (or do you have other devices where writecombining >>> works ?). Something like below will disbale it for all loongson64 CPUs. >>> If you now find out where it works and where it doesn't, you can even >>> reduce it to the required minium of affected CPUs. >> Hi Tiezhu, Thomas, >> >> Yes, writecombine works well on LS7A's internal GPU.... >> And even works well with some AMD GPUs (in my case, RX550). > > In this case the patch is a clear NAK since you haven't root caused the > issue and are just working around it in a very questionable manner. To be fair though, amdgpu & radeon are already disabling write-combining for system memory pages in 32-bit x86 kernels for similar reasons. -- Earthling Michel Dänzer | https://redhat.com Libre software enthusiast | Mesa and X developer