From patchwork Mon Jul 11 15:50:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Geert Uytterhoeven X-Patchwork-Id: 589577 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 30368CCA483 for ; Mon, 11 Jul 2022 15:51:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231223AbiGKPvA (ORCPT ); Mon, 11 Jul 2022 11:51:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44248 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231234AbiGKPut (ORCPT ); Mon, 11 Jul 2022 11:50:49 -0400 Received: from xavier.telenet-ops.be (xavier.telenet-ops.be [IPv6:2a02:1800:120:4::f00:14]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7A5D277A46 for ; Mon, 11 Jul 2022 08:50:40 -0700 (PDT) Received: from ramsan.of.borg ([84.195.186.194]) by xavier.telenet-ops.be with bizsmtp id trqe270124C55Sk01rqe4s; Mon, 11 Jul 2022 17:50:38 +0200 Received: from rox.of.borg ([192.168.97.57]) by ramsan.of.borg with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.93) (envelope-from ) id 1oAvgD-0036xD-Vl; Mon, 11 Jul 2022 17:50:37 +0200 Received: from geert by rox.of.borg with local (Exim 4.93) (envelope-from ) id 1oAvgD-006shx-2d; Mon, 11 Jul 2022 17:50:37 +0200 From: Geert Uytterhoeven To: Helge Deller Cc: Michael Schmitz , Jonathan Corbet , linux-fbdev@vger.kernel.org, linux-doc@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-m68k@vger.kernel.org, linux-kernel@vger.kernel.org, Geert Uytterhoeven Subject: [PATCH 08/10] video: fbdev: atari: Fix VGA modes Date: Mon, 11 Jul 2022 17:50:32 +0200 Message-Id: X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org The pixclock values in the vga and vga70 modes are wrong, as they should use the 25.175 MHz clock instead of the 32 MHz clock. Swap the left and right margins to match f25.{right,left} (struct pixel_clock declares them in a different order), and update the hsync lengths to match what the driver programs by default. Correct the (wrong) floating-point vrefresh value for the vga mode. 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 528478f6f30857ef..46a00e0ad5e785ac 100644 --- a/drivers/video/fbdev/atafb.c +++ b/drivers/video/fbdev/atafb.c @@ -494,11 +494,11 @@ static struct fb_videomode atafb_modedb[] __initdata = { { /* 640x480, 31 kHz, 60 Hz (VGA) */ - "vga", 63.5, 640, 480, 32000, 18, 42, 31, 11, 96, 3, + "vga", 60, 640, 480, 39721, 42, 18, 31, 11, 100, 3, 0, FB_VMODE_NONINTERLACED }, { /* 640x400, 31 kHz, 70 Hz (VGA) */ - "vga70", 70, 640, 400, 32000, 18, 42, 31, 11, 96, 3, + "vga70", 70, 640, 400, 39721, 42, 18, 31, 11, 100, 3, FB_SYNC_VERT_HIGH_ACT | FB_SYNC_COMP_HIGH_ACT, FB_VMODE_NONINTERLACED },