NetBSD Problem Report #59544

From www@netbsd.org  Tue Jul 22 12:41:41 2025
Return-Path: <www@netbsd.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256
	 client-signature RSA-PSS (2048 bits) client-digest SHA256)
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id F40CE1A9239
	for <gnats-bugs@gnats.NetBSD.org>; Tue, 22 Jul 2025 12:41:40 +0000 (UTC)
Message-Id: <20250722124139.9C9FE1A923C@mollari.NetBSD.org>
Date: Tue, 22 Jul 2025 12:41:39 +0000 (UTC)
From: kolipe.c@exoticsilicon.com
Reply-To: kolipe.c@exoticsilicon.com
To: gnats-bugs@NetBSD.org
Subject: Add support for 256 colours to wscons
X-Send-Pr-Version: www-1.0

>Number:         59544
>Category:       kern
>Synopsis:       Add support for 256 colours to wscons
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Tue Jul 22 12:45:00 +0000 2025
>Last-Modified:  Fri Nov 14 13:15:01 +0000 2025
>Originator:     Crystal Kolipe
>Release:        10.1-release
>Organization:
Exotic Silicon
>Environment:
>Description:
The framebuffer console only supports direct selection of eight colours, with another eight being indirectly selectable using the highlight/bold attribute.

In the case of 32-bit rasops displays, the underlying hardware supports much more.  As a first step, add support for direct selection of the bright colours for both foreground and background, as well as separately increasing the colour palette to 256.
>How-To-Repeat:

>Fix:
I posted a patch to the tech-kern mailing list to implement these two features:

https://mail-index.netbsd.org/tech-kern/2025/07/06/msg030599.html

>Audit-Trail:
From: "Nia Alarie" <nia@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/59544 CVS commit: src/sys/dev
Date: Sun, 2 Nov 2025 22:16:24 +0000

 Module Name:	src
 Committed By:	nia
 Date:		Sun Nov  2 22:16:24 UTC 2025

 Modified Files:
 	src/sys/dev/rasops: rasops.c rasops.h rasops_putchar.h
 	src/sys/dev/wscons: wsdisplayvar.h wsemul_vt100_subr.c

 Log Message:
 wscons(4): Add support for 256 colours to VT100 emulation

 Also implemented are CSI 90-97 and CSI 100-107 to set the bright
 versions of the regular eight colours directly.

 wscons already has full support of 8/16/24/32-bit displays (and
 can take advantage of them for antialiased fonts), but increasingly
 command-line applications are built to take advantage of colours beyond
 the standard 8 provided by the ANSI escape codes. These extensions are
 not generally standardized, but xterm serves as a de-facto standard.

 Patch from Crystal Kolipe, adjusted slightly to work on 16-bit and
 24-bit displays by me.

 PR kern/59544


 To generate a diff of this commit:
 cvs rdiff -u -r1.128 -r1.129 src/sys/dev/rasops/rasops.c
 cvs rdiff -u -r1.51 -r1.52 src/sys/dev/rasops/rasops.h
 cvs rdiff -u -r1.8 -r1.9 src/sys/dev/rasops/rasops_putchar.h
 cvs rdiff -u -r1.57 -r1.58 src/sys/dev/wscons/wsdisplayvar.h
 cvs rdiff -u -r1.34 -r1.35 src/sys/dev/wscons/wsemul_vt100_subr.c

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

From: "Martin Husemann" <martin@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/59544 CVS commit: [netbsd-11] src/sys/dev
Date: Fri, 14 Nov 2025 13:12:27 +0000

 Module Name:	src
 Committed By:	martin
 Date:		Fri Nov 14 13:12:27 UTC 2025

 Modified Files:
 	src/sys/dev/rasops [netbsd-11]: rasops.c rasops.h rasops_putchar.h
 	src/sys/dev/wscons [netbsd-11]: wsdisplayvar.h wsemul_vt100_subr.c

 Log Message:
 Pull up following revision(s) (requested by nia in ticket #81):

 	sys/dev/rasops/rasops.h: revision 1.52
 	sys/dev/wscons/wsemul_vt100_subr.c: revision 1.35
 	sys/dev/rasops/rasops_putchar.h: revision 1.9
 	sys/dev/rasops/rasops.c: revision 1.129
 	sys/dev/wscons/wsdisplayvar.h: revision 1.58

 wscons(4): Add support for 256 colours to VT100 emulation

 Also implemented are CSI 90-97 and CSI 100-107 to set the bright
 versions of the regular eight colours directly.
 wscons already has full support of 8/16/24/32-bit displays (and
 can take advantage of them for antialiased fonts), but increasingly
 command-line applications are built to take advantage of colours beyond
 the standard 8 provided by the ANSI escape codes. These extensions are
 not generally standardized, but xterm serves as a de-facto standard.
 Patch from Crystal Kolipe, adjusted slightly to work on 16-bit and
 24-bit displays by me.

 PR kern/59544


 To generate a diff of this commit:
 cvs rdiff -u -r1.128 -r1.128.12.1 src/sys/dev/rasops/rasops.c
 cvs rdiff -u -r1.51 -r1.51.2.1 src/sys/dev/rasops/rasops.h
 cvs rdiff -u -r1.8 -r1.8.36.1 src/sys/dev/rasops/rasops_putchar.h
 cvs rdiff -u -r1.57 -r1.57.8.1 src/sys/dev/wscons/wsdisplayvar.h
 cvs rdiff -u -r1.34 -r1.34.8.1 src/sys/dev/wscons/wsemul_vt100_subr.c

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.47 2022/09/11 19:34:41 kim Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2025 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.