From patchwork Tue Aug 2 03:19:18 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: John Stanley X-Patchwork-Id: 1027852 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.4) with ESMTP id p723JPfv025097 for ; Tue, 2 Aug 2011 03:19:25 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752675Ab1HBDTY (ORCPT ); Mon, 1 Aug 2011 23:19:24 -0400 Received: from nm5-vm0.access.bullet.mail.mud.yahoo.com ([66.94.237.155]:27841 "HELO nm5-vm0.access.bullet.mail.mud.yahoo.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with SMTP id S1752548Ab1HBDTX (ORCPT ); Mon, 1 Aug 2011 23:19:23 -0400 Received: from [66.94.237.126] by nm5.access.bullet.mail.mud.yahoo.com with NNFMP; 02 Aug 2011 03:19:22 -0000 Received: from [66.94.237.110] by tm1.access.bullet.mail.mud.yahoo.com with NNFMP; 02 Aug 2011 03:19:22 -0000 Received: from [127.0.0.1] by omp1015.access.mail.mud.yahoo.com with NNFMP; 02 Aug 2011 03:19:22 -0000 X-Yahoo-Newman-Id: 651837.10644.bm@omp1015.access.mail.mud.yahoo.com Received: (qmail 86294 invoked from network); 2 Aug 2011 03:19:22 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1312255162; bh=dMFbyCDtsPsn6gUXXSbFCsQa6tKSLqKkkyIwGrGg5jk=; h=X-Yahoo-Newman-Property:X-YMail-OSG:X-Yahoo-SMTP:Received:Message-ID:Date:From:User-Agent:MIME-Version:To:CC:Subject:References:In-Reply-To:Content-Type; b=puyahoYNwhc1BIBS5x+oRt3TbyFGN1kzWbmMqhOizIT6oH1qO9LGoiJseSiG75dA8DABO3wCvhOJ/DE0XwGUkHaMCj622+fJ23dqzGO2zo4J+yToe68r/gDNRUYnabMRuK+jgs+AuksEhquEuXLeL+Rc3Nz8Lx0g3Bsm4weBqlY= X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: Nwv1rPIVM1lKuNSGf9KN4yDhtxV4mFBmQXjGvbDMwMAMiNz HEt0j_VU397wPD8cwlWCcIfBr_GGjIQeV8NfNoDT6W91I5QkqqHNMrKkRlTn dyMbA4vtNE8YIKlpoerSK3VjaphBbsVCwqUes1JSZ3Obj2KKNY5bfiTDRHm7 cDT_3.G9TSuKBtdPLWKmxOGsIxmTVUyrSZbmLsyWxPCBsNdPWDdeQzRcF605 XqAJnjn7VAhU94GnLhRkYbAhJiYMQ1raxCt.jfkON646onA0J_4MVtQZDuta leqsOh5UWtrw1jw3XS.FJXafPX9Ai.0_U7byjihWq_6tc7D.YqQ-- X-Yahoo-SMTP: vMdlIiuswBDCrJd.52t_ytI_iaWTSggVja27tjT2P0U0lhW1 Received: from [192.168.2.9] (jpsinthemix@151.200.152.203 with plain) by smtp103.vzn.mail.bf1.yahoo.com with SMTP; 01 Aug 2011 20:19:21 -0700 PDT Message-ID: <4E376CB6.4000803@verizon.net> Date: Mon, 01 Aug 2011 23:19:18 -0400 From: John Stanley User-Agent: Mozilla/5.0 (X11; Linux i686; rv:5.0) Gecko/20110624 Thunderbird/5.0 MIME-Version: 1.0 To: Tormod Volden CC: Andrew Morton , linux-fbdev@vger.kernel.org, adaplas@gmail.com, stable@vger.kernel.org Subject: [PATCH] Fix typo in savage4 series definition in linux-3.0.0 References: <4E3528BF.2020601@verizon.net> In-Reply-To: Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter1.kernel.org [140.211.167.41]); Tue, 02 Aug 2011 03:19:26 +0000 (UTC) Thanks Tormod, Attached is the same patch, but with your 'Reviewed-by' added. Yeah, the T22 is rather old, and a bit of a 'Frankenstein PC' at this point, but its quite functional even with Linux-3.0 and KDE-4.7 thanks again, John On 08/01/2011 06:56 PM, Tormod Volden wrote: > On Sun, Jul 31, 2011 at 12:04 PM, John Stanley wrote: >> I have an old T22 Thinkpad with integrated Savage/IX-MV video. As of >> linux-3.0, the video is non-functional; the PC either hard hangs immediately >> or has totally garbled video, and then hard hangs, as soon as I attempt to >> edit a file or cat a file with more than a screen-full of text. The >> foregoing details are actually not important any more as in looking at the >> code changes I discovered a typo in >> linux-3.0.0/drivers/video/savage/savagefb.h and have applied the attached >> patch to fix the issue. > John, you are absolutely correct. My bad, this was from a commit of > mine. You may add my > Reviewed-by: Tormod Volden > to your patch. I'd suggest you change the patch description (mail > subject) to "[PATCH] Fix typo in savage4 series definition" or > something similar. > > The patch should also go into the stable series (by cc'ing > stable@vger.kernel.org if I remember correctly). > >> PLEASE NOTE: >> I realize that the patch does not quite adhere to linux kernel patch >> coding-style conventions (in particular, spaces around logical operators, >> and lines not exceeding 80 chars), but I have simply changed an >> '||' to an'&&' -- and NOT attempted to resolve pre-existing coding-style >> violations. > I also preserved the old coding style, which is the same in the xorg > driver which shares much of this code. We can always change it there > as well if somebody would like to fix it up. > >> thanks much, >> John >> >> P.S. Many, many thanks for lifting the 800x600 resolution limit! I've been >> using a patch/hack to bump the limit to 1024x768 for an very long time... > Glad to hear that! So there are still other savagefb users around :) > My apologies to those who were affected by the typo. > > Cheers, > Tormod > This patch corrects a typo/regression in the savage driver code occurring in going from linux-2.6.39.3 to linux-3.0.0. In linux-2.6.39.3, there were two savage4 variants (S3_SAVAGE4 and S3_PROSAVAGE). Hence, S3_SAVAGE4_SERIES was defined as S3_SAVAGE4 or S3_PROSAVAGE In linux-3.0.0, two additional savage4 variants (S3_TWISTER and S3_PROSAVAGEDDR) have been added. Hence S3_SAVAGE4_SERIES should be defined as S3_SAVAGE4, S3_PROSAVAGE, S3_TWISTER, or S3_PROSAVAGEDDR In going from linux-2.6.39.3 to linux-3.0.0, the define statement for S3_SAVAGE4_SERIES was incompletely modified: the '||' should have been changed to an '&&'; for an '||' will set S3_SAVAGE4_SERIES true for any card. Signed-off-by: John P. Stanley Reviewed-by: Tormod Volden --- linux-3.0.0/drivers/video/savage/savagefb.h.orig 2011-07-21 22:17:23.000000000 -0400 +++ linux-3.0.0/drivers/video/savage/savagefb.h 2011-07-31 05:27:47.314798215 -0400 @@ -55,7 +55,7 @@ #define S3_SAVAGE3D_SERIES(chip) ((chip>=S3_SAVAGE3D) && (chip<=S3_SAVAGE_MX)) -#define S3_SAVAGE4_SERIES(chip) ((chip>=S3_SAVAGE4) || (chip<=S3_PROSAVAGEDDR)) +#define S3_SAVAGE4_SERIES(chip) ((chip>=S3_SAVAGE4) && (chip<=S3_PROSAVAGEDDR)) #define S3_SAVAGE_MOBILE_SERIES(chip) ((chip==S3_SAVAGE_MX) || (chip==S3_SUPERSAVAGE))