From patchwork Fri Feb 15 08:58:58 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 10814379 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 66C331390 for ; Fri, 15 Feb 2019 08:59:27 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 09B9A2DBB1 for ; Fri, 15 Feb 2019 08:59:27 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id EC1EA2DBD2; Fri, 15 Feb 2019 08:59:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 774D72DBB1 for ; Fri, 15 Feb 2019 08:59:26 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391773AbfBOI70 (ORCPT ); Fri, 15 Feb 2019 03:59:26 -0500 Received: from xavier.telenet-ops.be ([195.130.132.52]:35244 "EHLO xavier.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727376AbfBOI70 (ORCPT ); Fri, 15 Feb 2019 03:59:26 -0500 Received: from ramsan ([84.194.111.163]) by xavier.telenet-ops.be with bizsmtp id cwzP1z0053XaVaC01wzPAV; Fri, 15 Feb 2019 09:59:23 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan with esmtp (Exim 4.90_1) (envelope-from ) id 1guZL7-0004hQ-Vj; Fri, 15 Feb 2019 09:59:21 +0100 Received: from geert by rox.of.borg with local (Exim 4.90_1) (envelope-from ) id 1guZKo-0005bG-Rc; Fri, 15 Feb 2019 09:59:02 +0100 From: Geert Uytterhoeven To: Bartlomiej Zolnierkiewicz , Michael Schmitz Cc: Paul Gortmaker , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-m68k@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH 1/4] fbdev: atafb: Stop printing virtual screen_base Date: Fri, 15 Feb 2019 09:58:58 +0100 Message-Id: <20190215085901.21479-2-geert@linux-m68k.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190215085901.21479-1-geert@linux-m68k.org> References: <20190215085901.21479-1-geert@linux-m68k.org> Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Printing (hashed) virtual addresses is useless. Signed-off-by: Geert Uytterhoeven --- drivers/video/fbdev/atafb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/video/fbdev/atafb.c b/drivers/video/fbdev/atafb.c index fcd2dd670a658fe3..e9d31a4299ee9901 100644 --- a/drivers/video/fbdev/atafb.c +++ b/drivers/video/fbdev/atafb.c @@ -3175,8 +3175,8 @@ int __init atafb_init(void) kernel_set_cachemode(screen_base, screen_len, IOMAP_WRITETHROUGH); } - printk("atafb: screen_base %p phys_screen_base %lx screen_len %d\n", - screen_base, phys_screen_base, screen_len); + printk("atafb: phys_screen_base %lx screen_len %d\n", + phys_screen_base, screen_len); #ifdef ATAFB_EXT } else { /* Map the video memory (physical address given) to somewhere From patchwork Fri Feb 15 08:58:59 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 10814383 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id EBBEE6C2 for ; Fri, 15 Feb 2019 08:59:31 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 933252DBD2 for ; Fri, 15 Feb 2019 08:59:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 87C0F2DC08; Fri, 15 Feb 2019 08:59:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id EFA7C2DBD6 for ; Fri, 15 Feb 2019 08:59:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391863AbfBOI72 (ORCPT ); Fri, 15 Feb 2019 03:59:28 -0500 Received: from baptiste.telenet-ops.be ([195.130.132.51]:32804 "EHLO baptiste.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391864AbfBOI72 (ORCPT ); Fri, 15 Feb 2019 03:59:28 -0500 Received: from ramsan ([84.194.111.163]) by baptiste.telenet-ops.be with bizsmtp id cwzN1z00c3XaVaC01wzNQc; Fri, 15 Feb 2019 09:59:25 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan with esmtp (Exim 4.90_1) (envelope-from ) id 1guZL7-0004hQ-Nw; Fri, 15 Feb 2019 09:59:21 +0100 Received: from geert by rox.of.borg with local (Exim 4.90_1) (envelope-from ) id 1guZKo-0005bI-SK; Fri, 15 Feb 2019 09:59:02 +0100 From: Geert Uytterhoeven To: Bartlomiej Zolnierkiewicz , Michael Schmitz Cc: Paul Gortmaker , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-m68k@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH 2/4] fbdev: atafb: Remove obsolete module support Date: Fri, 15 Feb 2019 09:58:59 +0100 Message-Id: <20190215085901.21479-3-geert@linux-m68k.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190215085901.21479-1-geert@linux-m68k.org> References: <20190215085901.21479-1-geert@linux-m68k.org> Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP CONFIG_FB_ATARI is bool, hence the Atari frame buffer driver cannot be built as a module. In addition, the module support code refers to a function atafb_deinit(), which never existed. Replace module_init() by device_initcall(). Signed-off-by: Geert Uytterhoeven --- drivers/video/fbdev/atafb.c | 16 +--------------- drivers/video/fbdev/atafb_iplan2p2.c | 23 ----------------------- drivers/video/fbdev/atafb_iplan2p4.c | 23 ----------------------- drivers/video/fbdev/atafb_iplan2p8.c | 23 ----------------------- drivers/video/fbdev/atafb_mfb.c | 23 ----------------------- 5 files changed, 1 insertion(+), 107 deletions(-) diff --git a/drivers/video/fbdev/atafb.c b/drivers/video/fbdev/atafb.c index e9d31a4299ee9901..d82007c113e6303c 100644 --- a/drivers/video/fbdev/atafb.c +++ b/drivers/video/fbdev/atafb.c @@ -47,7 +47,6 @@ #define ATAFB_EXT #define ATAFB_FALCON -#include #include #include #include @@ -3078,14 +3077,11 @@ int __init atafb_init(void) int pad, detected_mode, error; unsigned int defmode = 0; unsigned long mem_req; - -#ifndef MODULE char *option = NULL; if (fb_get_options("atafb", &option)) return -ENODEV; atafb_setup(option); -#endif printk("atafb_init: start\n"); if (!MACH_IS_ATARI) @@ -3251,14 +3247,4 @@ int __init atafb_init(void) return 0; } -module_init(atafb_init); - -#ifdef MODULE -MODULE_LICENSE("GPL"); - -int cleanup_module(void) -{ - unregister_framebuffer(&fb_info); - return atafb_deinit(); -} -#endif /* MODULE */ +device_initcall(atafb_init); diff --git a/drivers/video/fbdev/atafb_iplan2p2.c b/drivers/video/fbdev/atafb_iplan2p2.c index 8cc9c50379d0f036..a1660c24bf3629a5 100644 --- a/drivers/video/fbdev/atafb_iplan2p2.c +++ b/drivers/video/fbdev/atafb_iplan2p2.c @@ -10,7 +10,6 @@ * more details. */ -#include #include #include @@ -269,25 +268,3 @@ void atafb_iplan2p2_linefill(struct fb_info *info, u_long next_line, if (width) fill8_2col((u8 *)dest, fgcolor, bgcolor, *data); } - -#ifdef MODULE -MODULE_LICENSE("GPL"); - -int init_module(void) -{ - return 0; -} - -void cleanup_module(void) -{ -} -#endif /* MODULE */ - - - /* - * Visible symbols for modules - */ - -EXPORT_SYMBOL(atafb_iplan2p2_copyarea); -EXPORT_SYMBOL(atafb_iplan2p2_fillrect); -EXPORT_SYMBOL(atafb_iplan2p2_linefill); diff --git a/drivers/video/fbdev/atafb_iplan2p4.c b/drivers/video/fbdev/atafb_iplan2p4.c index bee0d89463f755a4..663d66582d791c03 100644 --- a/drivers/video/fbdev/atafb_iplan2p4.c +++ b/drivers/video/fbdev/atafb_iplan2p4.c @@ -10,7 +10,6 @@ * more details. */ -#include #include #include @@ -284,25 +283,3 @@ void atafb_iplan2p4_linefill(struct fb_info *info, u_long next_line, if (width) fill8_2col((u8 *)dest, fgcolor, bgcolor, *data); } - -#ifdef MODULE -MODULE_LICENSE("GPL"); - -int init_module(void) -{ - return 0; -} - -void cleanup_module(void) -{ -} -#endif /* MODULE */ - - - /* - * Visible symbols for modules - */ - -EXPORT_SYMBOL(atafb_iplan2p4_copyarea); -EXPORT_SYMBOL(atafb_iplan2p4_fillrect); -EXPORT_SYMBOL(atafb_iplan2p4_linefill); diff --git a/drivers/video/fbdev/atafb_iplan2p8.c b/drivers/video/fbdev/atafb_iplan2p8.c index 356fb52ce4430741..39a6cbbb6ca39db0 100644 --- a/drivers/video/fbdev/atafb_iplan2p8.c +++ b/drivers/video/fbdev/atafb_iplan2p8.c @@ -10,7 +10,6 @@ * more details. */ -#include #include #include @@ -321,25 +320,3 @@ void atafb_iplan2p8_linefill(struct fb_info *info, u_long next_line, if (width) fill8_2col((u8 *)dest, fgcolor, bgcolor, *data); } - -#ifdef MODULE -MODULE_LICENSE("GPL"); - -int init_module(void) -{ - return 0; -} - -void cleanup_module(void) -{ -} -#endif /* MODULE */ - - - /* - * Visible symbols for modules - */ - -EXPORT_SYMBOL(atafb_iplan2p8_copyarea); -EXPORT_SYMBOL(atafb_iplan2p8_fillrect); -EXPORT_SYMBOL(atafb_iplan2p8_linefill); diff --git a/drivers/video/fbdev/atafb_mfb.c b/drivers/video/fbdev/atafb_mfb.c index 6a352d62eecf2b73..384fd3e4d3e13935 100644 --- a/drivers/video/fbdev/atafb_mfb.c +++ b/drivers/video/fbdev/atafb_mfb.c @@ -9,7 +9,6 @@ * more details. */ -#include #include #include @@ -88,25 +87,3 @@ void atafb_mfb_linefill(struct fb_info *info, u_long next_line, *dest++ = *data++; } } - -#ifdef MODULE -MODULE_LICENSE("GPL"); - -int init_module(void) -{ - return 0; -} - -void cleanup_module(void) -{ -} -#endif /* MODULE */ - - - /* - * Visible symbols for modules - */ - -EXPORT_SYMBOL(atafb_mfb_copyarea); -EXPORT_SYMBOL(atafb_mfb_fillrect); -EXPORT_SYMBOL(atafb_mfb_linefill); From patchwork Fri Feb 15 08:59:00 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 10814381 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 814861390 for ; Fri, 15 Feb 2019 08:59:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 290E02DBB1 for ; Fri, 15 Feb 2019 08:59:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1CCE62DBE0; Fri, 15 Feb 2019 08:59:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0ECF52DBB1 for ; Fri, 15 Feb 2019 08:59:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391839AbfBOI71 (ORCPT ); Fri, 15 Feb 2019 03:59:27 -0500 Received: from baptiste.telenet-ops.be ([195.130.132.51]:32796 "EHLO baptiste.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726396AbfBOI71 (ORCPT ); Fri, 15 Feb 2019 03:59:27 -0500 Received: from ramsan ([84.194.111.163]) by baptiste.telenet-ops.be with bizsmtp id cwzN1z00n3XaVaC01wzNQf; Fri, 15 Feb 2019 09:59:25 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan with esmtp (Exim 4.90_1) (envelope-from ) id 1guZL7-0004hQ-TY; Fri, 15 Feb 2019 09:59:21 +0100 Received: from geert by rox.of.borg with local (Exim 4.90_1) (envelope-from ) id 1guZKo-0005bK-T8; Fri, 15 Feb 2019 09:59:02 +0100 From: Geert Uytterhoeven To: Bartlomiej Zolnierkiewicz , Michael Schmitz Cc: Paul Gortmaker , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-m68k@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH 3/4] fbdev: atafb: Fix broken frame buffer after kexec Date: Fri, 15 Feb 2019 09:59:00 +0100 Message-Id: <20190215085901.21479-4-geert@linux-m68k.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190215085901.21479-1-geert@linux-m68k.org> References: <20190215085901.21479-1-geert@linux-m68k.org> Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Falcon, Atari frame buffer initialization relies on preprogrammed register values. These register values are changed to blank the console. Hence when using kexec to boot into a new kernel while the console is blanked, the new kernel cannot determine the current video configuration, and the Atari frame buffer driver fails to initialize: atafb: phys_screen_base 6ce000 screen_len 4096 Fix this by doing a straight-forward conversion of the driver to a platform device driver, and adding a shutdown handler that unblanks the display. Signed-off-by: Geert Uytterhoeven --- drivers/video/fbdev/atafb.c | 34 ++++++++++++++++++++++++++++++---- 1 file changed, 30 insertions(+), 4 deletions(-) diff --git a/drivers/video/fbdev/atafb.c b/drivers/video/fbdev/atafb.c index d82007c113e6303c..4db8166d11b30409 100644 --- a/drivers/video/fbdev/atafb.c +++ b/drivers/video/fbdev/atafb.c @@ -54,6 +54,7 @@ #include #include #include +#include #include #include @@ -3072,7 +3073,7 @@ int __init atafb_setup(char *options) return 0; } -int __init atafb_init(void) +static int __init atafb_probe(struct platform_device *pdev) { int pad, detected_mode, error; unsigned int defmode = 0; @@ -3084,9 +3085,6 @@ int __init atafb_init(void) atafb_setup(option); printk("atafb_init: start\n"); - if (!MACH_IS_ATARI) - return -ENODEV; - do { #ifdef ATAFB_EXT if (external_addr) { @@ -3247,4 +3245,32 @@ int __init atafb_init(void) return 0; } +static void atafb_shutdown(struct platform_device *pdev) +{ + /* Unblank before kexec */ + if (fbhw->blank) + fbhw->blank(0); +} + +static struct platform_driver atafb_driver = { + .shutdown = atafb_shutdown, + .driver = { + .name = "atafb", + }, +}; + +static int __init atafb_init(void) +{ + struct platform_device *pdev; + + if (!MACH_IS_ATARI) + return -ENODEV; + + pdev = platform_device_register_simple("atafb", -1, NULL, 0); + if (IS_ERR(pdev)) + return PTR_ERR(pdev); + + return platform_driver_probe(&atafb_driver, atafb_probe); +} + device_initcall(atafb_init); From patchwork Fri Feb 15 08:59:01 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 10814387 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id D1351188D for ; Fri, 15 Feb 2019 08:59:33 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 798CF2DBDA for ; Fri, 15 Feb 2019 08:59:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6DF082DBE0; Fri, 15 Feb 2019 08:59:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9D7F42DBD2 for ; Fri, 15 Feb 2019 08:59:28 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727376AbfBOI72 (ORCPT ); Fri, 15 Feb 2019 03:59:28 -0500 Received: from baptiste.telenet-ops.be ([195.130.132.51]:32812 "EHLO baptiste.telenet-ops.be" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2391844AbfBOI71 (ORCPT ); Fri, 15 Feb 2019 03:59:27 -0500 Received: from ramsan ([84.194.111.163]) by baptiste.telenet-ops.be with bizsmtp id cwzN1z00i3XaVaC01wzNQd; Fri, 15 Feb 2019 09:59:25 +0100 Received: from rox.of.borg ([192.168.97.57]) by ramsan with esmtp (Exim 4.90_1) (envelope-from ) id 1guZL7-0004hQ-Qh; Fri, 15 Feb 2019 09:59:21 +0100 Received: from geert by rox.of.borg with local (Exim 4.90_1) (envelope-from ) id 1guZKo-0005bP-Uk; Fri, 15 Feb 2019 09:59:02 +0100 From: Geert Uytterhoeven To: Bartlomiej Zolnierkiewicz , Michael Schmitz Cc: Paul Gortmaker , dri-devel@lists.freedesktop.org, linux-fbdev@vger.kernel.org, linux-m68k@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH 4/4] fbdev: atafb: Modernize printing of kernel messages Date: Fri, 15 Feb 2019 09:59:01 +0100 Message-Id: <20190215085901.21479-5-geert@linux-m68k.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190215085901.21479-1-geert@linux-m68k.org> References: <20190215085901.21479-1-geert@linux-m68k.org> Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Now the driver has been converted to a platform driver, the legacy printk() calls without any log level can be replaced by proper dev_*() calls. Signed-off-by: Geert Uytterhoeven --- drivers/video/fbdev/atafb.c | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/drivers/video/fbdev/atafb.c b/drivers/video/fbdev/atafb.c index 4db8166d11b30409..b986af2a80428003 100644 --- a/drivers/video/fbdev/atafb.c +++ b/drivers/video/fbdev/atafb.c @@ -3083,12 +3083,12 @@ static int __init atafb_probe(struct platform_device *pdev) if (fb_get_options("atafb", &option)) return -ENODEV; atafb_setup(option); - printk("atafb_init: start\n"); + dev_dbg(&pdev->dev, "%s: start\n", __func__); do { #ifdef ATAFB_EXT if (external_addr) { - printk("atafb_init: initializing external hw\n"); + dev_dbg(&pdev->dev, "initializing external hw\n"); fbhw = &ext_switch; atafb_ops.fb_setcolreg = &ext_setcolreg; defmode = DEFMODE_EXT; @@ -3097,7 +3097,7 @@ static int __init atafb_probe(struct platform_device *pdev) #endif #ifdef ATAFB_TT if (ATARIHW_PRESENT(TT_SHIFTER)) { - printk("atafb_init: initializing TT hw\n"); + dev_dbg(&pdev->dev, "initializing TT hw\n"); fbhw = &tt_switch; atafb_ops.fb_setcolreg = &tt_setcolreg; defmode = DEFMODE_TT; @@ -3106,7 +3106,7 @@ static int __init atafb_probe(struct platform_device *pdev) #endif #ifdef ATAFB_FALCON if (ATARIHW_PRESENT(VIDEL_SHIFTER)) { - printk("atafb_init: initializing Falcon hw\n"); + dev_dbg(&pdev->dev, "initializing Falcon hw\n"); fbhw = &falcon_switch; atafb_ops.fb_setcolreg = &falcon_setcolreg; error = request_irq(IRQ_AUTO_4, falcon_vbl_switcher, 0, @@ -3121,7 +3121,7 @@ static int __init atafb_probe(struct platform_device *pdev) #ifdef ATAFB_STE if (ATARIHW_PRESENT(STND_SHIFTER) || ATARIHW_PRESENT(EXTD_SHIFTER)) { - printk("atafb_init: initializing ST/E hw\n"); + dev_dbg(&pdev->dev, "initializing ST/E hw\n"); fbhw = &st_switch; atafb_ops.fb_setcolreg = &stste_setcolreg; defmode = DEFMODE_STE; @@ -3129,7 +3129,8 @@ static int __init atafb_probe(struct platform_device *pdev) } fbhw = &st_switch; atafb_ops.fb_setcolreg = &stste_setcolreg; - printk("Cannot determine video hardware; defaulting to ST(e)\n"); + dev_warn(&pdev->dev, + "Cannot determine video hardware; defaulting to ST(e)\n"); #else /* ATAFB_STE */ /* no default driver included */ /* Nobody will ever see this message :-) */ @@ -3169,8 +3170,8 @@ static int __init atafb_probe(struct platform_device *pdev) kernel_set_cachemode(screen_base, screen_len, IOMAP_WRITETHROUGH); } - printk("atafb: phys_screen_base %lx screen_len %d\n", - phys_screen_base, screen_len); + dev_info(&pdev->dev, "phys_screen_base %lx screen_len %d\n", + phys_screen_base, screen_len); #ifdef ATAFB_EXT } else { /* Map the video memory (physical address given) to somewhere @@ -3217,12 +3218,12 @@ static int __init atafb_probe(struct platform_device *pdev) fb_alloc_cmap(&(fb_info.cmap), 1 << fb_info.var.bits_per_pixel, 0); - printk("Determined %dx%d, depth %d\n", - fb_info.var.xres, fb_info.var.yres, fb_info.var.bits_per_pixel); + dev_info(&pdev->dev, "Determined %dx%d, depth %d\n", fb_info.var.xres, + fb_info.var.yres, fb_info.var.bits_per_pixel); if ((fb_info.var.xres != fb_info.var.xres_virtual) || (fb_info.var.yres != fb_info.var.yres_virtual)) - printk(" virtual %dx%d\n", fb_info.var.xres_virtual, - fb_info.var.yres_virtual); + dev_info(&pdev->dev, " virtual %dx%d\n", + fb_info.var.xres_virtual, fb_info.var.yres_virtual); if (register_framebuffer(&fb_info) < 0) { #ifdef ATAFB_EXT