From patchwork Tue Aug 21 06:09:48 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tomi Valkeinen X-Patchwork-Id: 1352391 Return-Path: X-Original-To: patchwork-linux-omap@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id CB8BEDFB34 for ; Tue, 21 Aug 2012 06:10:41 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753545Ab2HUGKj (ORCPT ); Tue, 21 Aug 2012 02:10:39 -0400 Received: from na3sys009aog108.obsmtp.com ([74.125.149.199]:43707 "EHLO na3sys009aog108.obsmtp.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753505Ab2HUGKh (ORCPT ); Tue, 21 Aug 2012 02:10:37 -0400 Received: from mail-lb0-f179.google.com ([209.85.217.179]) (using TLSv1) by na3sys009aob108.postini.com ([74.125.148.12]) with SMTP ID DSNKUDMmWy3MsFtbnRIFnyN09n/bLumEc2zD@postini.com; Mon, 20 Aug 2012 23:10:37 PDT Received: by lbao2 with SMTP id o2so3113695lba.10 for ; Mon, 20 Aug 2012 23:10:34 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=ickd6cUkwK0NWxo4jAZkrRphEZJsH/Or6yctI2+k8do=; b=UUJpAPerIq8u4nGyqQoZkJ9L8DDRuWA0DCoTSIYfT3AfgxCUX7Lf0S1TFUMUXIQvNS kIRV7i0SsxjR3iNBefaurIWYQ4MkyEbHDwX43KAoZMDLLNh4M1bTT9cFLg4RcgnZVKiV n9TUSx7ipCcbBQkgOwj1fqAka+Vda19VciFIIozhwTCvzJqDpymXfgYAwH5BK4uzdbee 64OV5u+KCsUVH5DCt+u9sTYF0eiiSZeS5vx8DE/kIng4Jd92BbPiXpFauzhj7SBYdGUO DkzMjrk0fEdJ4I0RChGl5aI5aL8WdTD0s3EmI64kqfZfimnoZNhzxHzQ1L9ilnP7J3M+ KU1w== Received: by 10.152.112.234 with SMTP id it10mr16182705lab.36.1345529434012; Mon, 20 Aug 2012 23:10:34 -0700 (PDT) Received: from localhost.localdomain (a91-156-160-115.elisa-laajakaista.fi. [91.156.160.115]) by mx.google.com with ESMTPS id ta2sm562054lab.15.2012.08.20.23.10.32 (version=SSLv3 cipher=OTHER); Mon, 20 Aug 2012 23:10:33 -0700 (PDT) From: Tomi Valkeinen To: Florian Tobias Schandinat Cc: linux-fbdev@vger.kernel.org, linux-omap@vger.kernel.org, Grazvydas Ignotas , Tomi Valkeinen Subject: [PATCH 2/2] OMAPFB: fix framebuffer console colors Date: Tue, 21 Aug 2012 09:09:48 +0300 Message-Id: <1345529388-3509-3-git-send-email-tomi.valkeinen@ti.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1345529388-3509-1-git-send-email-tomi.valkeinen@ti.com> References: <1345529388-3509-1-git-send-email-tomi.valkeinen@ti.com> X-Gm-Message-State: ALoCoQkYdxral6yMBUptCS6rG2hz/QjIj9g1Kx6M0ziWLVkOc/SxjA6S2BaKzdUJ8RuLBtdLaIb6 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org From: Grazvydas Ignotas omapfb does not currently set pseudo palette correctly for color depths above 16bpp, making red text invisible, command like echo -e '\e[0;31mRED' > /dev/tty1 will display nothing on framebuffer console in 24bpp mode. This is because temporary variable is declared incorrectly, fix it. Signed-off-by: Grazvydas Ignotas Cc: stable@vger.kernel.org # v3.x Signed-off-by: Tomi Valkeinen --- drivers/video/omap2/omapfb/omapfb-main.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/video/omap2/omapfb/omapfb-main.c b/drivers/video/omap2/omapfb/omapfb-main.c index 08ec1a7..fc671d3 100644 --- a/drivers/video/omap2/omapfb/omapfb-main.c +++ b/drivers/video/omap2/omapfb/omapfb-main.c @@ -1192,7 +1192,7 @@ static int _setcolreg(struct fb_info *fbi, u_int regno, u_int red, u_int green, break; if (regno < 16) { - u16 pal; + u32 pal; pal = ((red >> (16 - var->red.length)) << var->red.offset) | ((green >> (16 - var->green.length)) <<