From patchwork Mon Nov 11 19:22:50 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 179125 Delivered-To: patch@linaro.org Received: by 2002:a92:38d5:0:0:0:0:0 with SMTP id g82csp7084028ilf; Mon, 11 Nov 2019 11:23:44 -0800 (PST) X-Google-Smtp-Source: APXvYqzw9T3fdN9uMpb8GlEzG8NtfaXgkOQ52ygYoIgHVuD5NzorFj3zOiMa1rYneX/LyA85i64F X-Received: by 2002:a65:5a8c:: with SMTP id c12mr30776461pgt.140.1573500224221; Mon, 11 Nov 2019 11:23:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573500224; cv=none; d=google.com; s=arc-20160816; b=NMN/jm+VKWTdFf6ek2/TrdUuSEZlAgE++aasz4toLrH0dxpC03OFZA2JBdQIhiF6G2 oZTN/N7lv0XAZj/lPbQwJx2ZSZ6tiSJCAgRQuTieibBE/q6R7KZIQvREpBOXzPMD5/pX l5s1laa8ADtr/CDFqAGSM5k6EX+Zz7gOSahQK7vMczN6CoOHVN76YJELs/+s/JGqjxM3 m+40a5+4gM8jmn1BdY8tmpqXGwzp7sWA0BIHvQd5yTy8JHWbYL7g64kDXgHgMyfs2dTF SOsV5zjHN29q5eHsuWRY1El7a/0sMt231yAjwmjOfYm0NfD6pMcFLOQWn4t2/0SMxdfL dnUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:cc:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:mime-version:message-id:date:subject:to:from :delivered-to; bh=+iMVKgLr5Up9AkoWCr4TXu4pi2G/I9iELZkHak8J958=; b=1KdliDeIojDVrbdUPPfNqmLoy+67KNI2mTvVw5E0QkeD5AwfWnncjpQxJO+JraVRmM /eRNog0OFgkdPL3OmOnvPsaToGUUgU+11WHXcVqfrEdF/DXKWQZSpw0NBSK2JResrY8l L05FxLoVF5gxW/nRPY4LMOTGodDP+Ktbk0NXu4DiJcHWnMaDD9MqdWaLU/I+qGDsMW5m L3LzXE4lk9+K9NqqhNr8pdskftwvMZy1nmoOHMKSpRrWlharMYknuDfdfC3pu2rHNO4p qMQg4KLndBrVdd48PKmAjb5PQLOVgEyY2OJVm1ri4skQcaP0Hq27t8ydAeuGB5Lm/qWJ zlEA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Return-Path: Received: from gabe.freedesktop.org (gabe.freedesktop.org. [2610:10:20:722:a800:ff:fe36:1795]) by mx.google.com with ESMTPS id n5si19748883pfn.89.2019.11.11.11.23.43 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Mon, 11 Nov 2019 11:23:44 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) client-ip=2610:10:20:722:a800:ff:fe36:1795; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of dri-devel-bounces@lists.freedesktop.org designates 2610:10:20:722:a800:ff:fe36:1795 as permitted sender) smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 35A066E25E; Mon, 11 Nov 2019 19:23:43 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mout.kundenserver.de (mout.kundenserver.de [212.227.126.130]) by gabe.freedesktop.org (Postfix) with ESMTPS id 15E616E25E for ; Mon, 11 Nov 2019 19:23:41 +0000 (UTC) Received: from threadripper.lan ([149.172.19.189]) by mrelayeu.kundenserver.de (mreue011 [212.227.15.129]) with ESMTPA (Nemesis) id 1MTi9N-1iK6p22quT-00Tzhu; Mon, 11 Nov 2019 20:23:05 +0100 From: Arnd Bergmann To: Bartlomiej Zolnierkiewicz Subject: [PATCH] video: fbdev: atyfb: only use ioremap_uc() on i386 and ia64 Date: Mon, 11 Nov 2019 20:22:50 +0100 Message-Id: <20191111192258.2234502-1-arnd@arndb.de> X-Mailer: git-send-email 2.20.0 MIME-Version: 1.0 X-Provags-ID: V03:K1:G7fVZrN2su3CbpdSj/kq71EeeeKTYZoe6x6zvxOtFZEbiSWv0zR Xw+By6rp1RvmAwdIceDuVMJG6W49a4GYU5M7TsOb4PVcuFbmtc4zDHnbboKsEbR9a/vwmVG gMfZ9mqmc9EZcj6sVDak1e2jRHvgU1GfZC4GJJZ+6geK8zKloktS54pQoixLcw3apObAvgo 37ky04f59Xwy19jvSnR4Q== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1; V03:K0:gTxDTasTuXo=:DtDj9YCkmH7bphqvBqN2kc y2HCCFlcKtkkxIT1zvuffgBD/NjjOrR4LAaUWC38J7zAv3ccLY7YoCKr7esjNGTPU4Bm7vfNW 3+Sj80/UK2nG5u3ic8f7jrj5w+4S1r9X4YsEQ+46xyqiQsao7J6xBlOrqgR1IrpM3fwT9OBuB oqdwG3t6hG3AqDJxC09ls/SRfvVndfBmyO3ruCNtKApuxM5M2kjSBPYq1ZCt18nmkxnwNm5h9 48Ra3ulZBQxlDoJJ4ceP+De+h+EU0nZknsRvpNuVJLPZw8nqgksAWCComGiuatMGtr3RsPXrO NxMgDA0DFe2/FUx21eVhAt2TD39hUOHS2W4/RPBFZ1nrffYh6we0SK+AWn75lOjkzTiz5jdBt sFKRUSl2edXQXlZStoDBByKUF7qMwQBvn6ZKt8Q0+Is0FyaGCUyCxVA8QzH5cH87e8eHdKQB/ pXGZpoJGuNGDlhIg7LO38RnKy0xfTlWMsZcFT0CcHuD14fzrXfQ4EJfQi3VlONjX2pMKmTYoy uYRBC9HrfTpInyi+GMPZOE3NoNWZ15CzZC7vEsPxb63kNjQyglrGrjnLHq/z39MNcVvaIY/9G T17lcEpSTAVBSOo85r2PPWOI6B8f9PKLpVlW4lvn8MGWYqz3UMX8v2Y6hMYvCfpjCMMInNxF1 B408DQyNh/c7kt24ojj+STA80/0IuB8tVTbT6BCwyDzwBq615+5FIHAe37/brRYdCA5WJHYhJ aboiguFX21swpruRbFolY595RugViK+R8oN9ovjz9pLuBYx0eF7TMmxkMk9A3LUZTTOK9pRSh KgVlttJjfHZ2lQelvU3AwaGH06fVl23G9NaclTxJ8k1DV1iUcl4W6Y2Cy2WrPO32aqWaY3ZqG QuRPIIlhHo3Yt4D6gr9w== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Fenghua Yu , linux-fbdev@vger.kernel.org, Tony Luck , linux-ia64@vger.kernel.org, Arnd Bergmann , Daniel Vetter , x86@kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Ingo Molnar , Borislav Petkov , Souptick Joarder , "H. Peter Anvin" , Thomas Gleixner , Christoph Hellwig Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" ioremap_uc() is only meaningful on old x86-32 systems with the PAT extension, and on ia64 with its slightly unconventional ioremap() behavior, everywhere else this is the same as ioremap() anyway. Change the only driver that still references ioremap_uc() to only do so on x86-32/ia64 in order to allow removing that interface at some point in the future for the other architectures. On some architectures, ioremap_uc() just returns NULL, changing the driver to call ioremap() means that they now have a chance of working correctly. Signed-off-by: Arnd Bergmann --- drivers/video/fbdev/aty/atyfb_base.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/video/fbdev/aty/atyfb_base.c b/drivers/video/fbdev/aty/atyfb_base.c index 79d548746efd..bdbaca7200b2 100644 --- a/drivers/video/fbdev/aty/atyfb_base.c +++ b/drivers/video/fbdev/aty/atyfb_base.c @@ -3420,11 +3420,15 @@ static int atyfb_setup_generic(struct pci_dev *pdev, struct fb_info *info, } info->fix.mmio_start = raddr; +#if defined(__i386__) || defined(__ia64__) /* * By using strong UC we force the MTRR to never have an * effect on the MMIO region on both non-PAT and PAT systems. */ par->ati_regbase = ioremap_uc(info->fix.mmio_start, 0x1000); +#else + par->ati_regbase = ioremap(info->fix.mmio_start, 0x1000); +#endif if (par->ati_regbase == NULL) return -ENOMEM;