From Alan.Coopersmith@sun.com Wed Apr 30 14:43:33 2008
Received: from sunmail5.uk.sun.com (sunmail5.UK.Sun.COM [129.156.85.165])
	by sac.sfbay.sun.com (8.13.8+Sun/8.13.8) with ESMTP id m3ULhWmk026352
	for <psarc-ext@sac.sfbay.sun.com>; Wed, 30 Apr 2008 14:43:33 -0700 (PDT)
Received: from nwk-avmta-2.sfbay.sun.com (nwk-avmta-2.SFBay.Sun.COM [129.145.155.6])
	by sunmail5.uk.sun.com (8.13.8+Sun/8.13.8/ENSMAIL,v2.2) with ESMTP id m3ULhPwd018158;
	Wed, 30 Apr 2008 22:43:30 +0100 (BST)
Received: from pmxchannel-daemon.nwk-avmta-2.sfbay.sun.com by
 nwk-avmta-2.sfbay.sun.com
 (Sun Java System Messaging Server 6.2-3.04 (built Jul 15 2005))
 id <0K0500C01R0G2Q00@nwk-avmta-2.sfbay.sun.com>; Wed,
 30 Apr 2008 14:43:29 -0700 (PDT)
Received: from almas.sfbay.sun.com ([129.146.106.93])
 by nwk-avmta-2.sfbay.sun.com
 (Sun Java System Messaging Server 6.2-3.04 (built Jul 15 2005))
 with ESMTP id <0K0500859R0GRL60@nwk-avmta-2.sfbay.sun.com>; Wed,
 30 Apr 2008 14:43:28 -0700 (PDT)
Received: from almas.sfbay.sun.com (localhost [127.0.0.1])
	by almas.sfbay.sun.com (8.14.2+Sun/8.14.2) with ESMTP id m3ULhSEK000845; Wed,
 30 Apr 2008 14:43:28 -0700 (PDT)
Received: (from alanc@localhost)
	by almas.sfbay.sun.com (8.14.2+Sun/8.14.2/Submit) id m3ULhSCI000841; Wed,
 30 Apr 2008 14:43:28 -0700 (PDT)
Date: Wed, 30 Apr 2008 14:43:28 -0700 (PDT)
From: Alan Coopersmith <Alan.Coopersmith@sun.com>
Subject: Xorg driver selection based on VIS_GETIDENTIFIER [PSARC/2008/294
 FastTrack timeout 05/07/2008]
To: PSARC-ext@sun.com
Cc: Alan.Coopersmith@sun.com
Message-id: <200804302143.m3ULhSCI000841@almas.sfbay.sun.com>
Content-transfer-encoding: 7BIT
X-PMX-Version: 5.4.1.325704
Status: RO
Content-Length: 3987

I am sponsoring this fast-track for myself and have set the timeout for
next Wednesday, May 7, 2008.    This case requests a micro/patch release
binding.

        -Alan Coopersmith-           alan.coopersmith@sun.com
         Sun Microsystems, Inc. - X Window System Engineering


Template Version: @(#)sac_nextcase 1.66 04/17/08 SMI
This information is Copyright 2008 Sun Microsystems
1. Introduction
    1.1. Project/Component Working Name:
	 Xorg driver selection based on VIS_GETIDENTIFIER
    1.2. Name of Document Author/Supplier:
	 Author:  Alan Coopersmith
    1.3  Date of This Document:
	30 April, 2008
4. Technical Description

Currently when no xorg.conf is present, the Xorg integrated in Solaris
uses these heuristics to generate the list of device drivers to try
running for a specific device - once the list is generated, each is
tried in order until one reports that it successfully loaded and 
initialized the device.

1) The PCI vendor id & device id is mapped to a driver name using heuristics 
   found in the Xorg binary.   This driver may be a module that uses further
   checks to determine a more specific driver to load - for instance, if the
   PCI vendor id is 0x1002, the "ati" module is loaded, which then uses the
   device id to determine whether the "atimisc" (Mach64), "r128" (Rage), or
   "radeon" drivers is most appropriate for this device, without having to
   hardcode all the ATI device ids into the X server.

2) The file specified by -dev command line option ("/dev/fb" if -dev is
   not specified) is opened, and the VIS_GETIDENTIFIER ioctl is called to 
   get the device identifier string from the kernel device driver.

   This string is traditionally an all caps vendor identifier (stock
   ticker symbol or similar) followed by a lower case driver name.

   For most x86 devices this will be "SUNWtext" from the vgatext driver.
   The nvidia accelerated driver on x86 returns "NVDAnvda".   SPARC devices
   include "SUNWffb", "SUNWm64", "SUNWkfb", and other similar names.

   If the string returned is "NVDAnvda", the "nvidia" driver is used instead
   of whatever driver name was found by step 1.

   [This step is a Sun addition, since VIS_GETIDENTIFIER is Solaris specific.]

3) A platform specific list of fallback devices is checked:
	SPARC:	wsfb
	x86: fbdev [not shipped on Solaris], vesa, vga

On the SPARC platform, where unlike x86, all graphics devices have kernel
drivers which can identify them, we need to expand the use of the
VIS_GETIDENTIFIER ioctl to load the right driver module.

This case thus adds to the above step 2 these additional heuristics:

	If the device identifier consists of a sequence of uppercase letters
	followed by non-uppercase-letter characters, the driver string 
	will be	split into two portions - the "vendor" portion 
	consisting of the initial all-uppercase string, and the "device"
	portion consisting of the remainder of the string.

	The Xorg driver module names consisting of the vendor string and
	device string will be used in that order as the list of drivers 
	instead of whatever driver was found in step 1.

For instance, given a VIS_GETIDENTIFIER result of "SUNWm64" on a SPARC
system, the list of driver modules tried will be, in this order:
	SUNW_drv.so
	m64_drv.so
	wsfb_drv.so

The existing hardcoding of NVDAnvda to the nvidia driver module will remain
for compatibility, but no further hardcoded driver names are planned, and
any future x86 kernel video device drivers will be recommended to chose a
VIS_GETIDENTIFIER string that works with the new heuristics.

Imported Interfaces:
--------------------
VIS_GETIDENTIFIER		Uncommitted	PSARC 1993/133 & visual_io(7I)

Exported Interfaces:
--------------------
Autoloading of vendor & device modules			Uncommitted

6. Resources and Schedule
    6.4. Steering Committee requested information
   	6.4.1. Consolidation C-team Name:
		X Consolidation (Desktop C-Team)
    6.5. ARC review type: FastTrack
    6.6. ARC Exposure: open


From Alan.Coopersmith@sun.com Wed May  7 12:39:07 2008
Received: from newsunmail1brm.central.sun.com (newsunmail1brm.Central.Sun.COM [129.147.62.245])
	by sac.sfbay.sun.com (8.13.8+Sun/8.13.8) with ESMTP id m47Jd77O014767
	for <psarc-ext@sac.sfbay.sun.com>; Wed, 7 May 2008 12:39:07 -0700 (PDT)
Received: from nwk-avmta-2.sfbay.sun.com (nwk-avmta-2.SFBay.Sun.COM [129.145.155.6])
	by newsunmail1brm.central.sun.com (8.13.7+Sun/8.13.7/ENSMAIL,v2.2) with ESMTP id m47Jd4YK059982
	for <@sunmail2sca.sfbay.sun.com:PSARC-ext@sun.com>; Wed, 7 May 2008 13:39:07 -0600 (MDT)
Received: from pmxchannel-daemon.nwk-avmta-2.sfbay.sun.com by
 nwk-avmta-2.sfbay.sun.com
 (Sun Java System Messaging Server 6.2-3.04 (built Jul 15 2005))
 id <0K0I0080LJX6OA00@nwk-avmta-2.sfbay.sun.com> for PSARC-ext@sun.com
 (ORCPT PSARC-ext@Sun.COM); Wed, 07 May 2008 12:39:06 -0700 (PDT)
Received: from sca-es-mail-2.sun.com ([192.18.43.133])
 by nwk-avmta-2.sfbay.sun.com
 (Sun Java System Messaging Server 6.2-3.04 (built Jul 15 2005))
 with ESMTP id <0K0I0033AJX58Q90@nwk-avmta-2.sfbay.sun.com> for
 PSARC-ext@sun.com (ORCPT PSARC-ext@Sun.COM); Wed,
 07 May 2008 12:39:05 -0700 (PDT)
Received: from fe-sfbay-09.sun.com ([192.18.43.129])
	by sca-es-mail-2.sun.com (8.13.7+Sun/8.12.9) with ESMTP id m47Jd5OS019375	for
 <PSARC-ext@Sun.COM>; Wed, 07 May 2008 12:39:05 -0700 (PDT)
Received: from conversion-daemon.fe-sfbay-09.sun.com by fe-sfbay-09.sun.com
 (Sun Java System Messaging Server 6.2-8.04 (built Feb 28 2007))
 id <0K0I00J01JT8U800@fe-sfbay-09.sun.com>
 (original mail from Alan.Coopersmith@Sun.COM)
 for PSARC-ext@Sun.COM (ORCPT PSARC-ext@Sun.COM); Wed,
 07 May 2008 12:39:05 -0700 (PDT)
Received: from almas.sfbay.sun.com ([129.146.106.93])
 by fe-sfbay-09.sun.com (Sun Java System Messaging Server 6.2-8.04 (built Feb
 28 2007)) with ESMTPSA id <0K0I0059LJWYQ860@fe-sfbay-09.sun.com> for
 PSARC-ext@Sun.COM (ORCPT PSARC-ext@Sun.COM); Wed,
 07 May 2008 12:38:59 -0700 (PDT)
Date: Wed, 07 May 2008 12:38:58 -0700
From: Alan Coopersmith <Alan.Coopersmith@sun.com>
Subject: Re: Xorg driver selection based on VIS_GETIDENTIFIER [PSARC/2008/294
 FastTrack timeout 05/07/2008]
In-reply-to: <200804302143.m3ULhSCI000841@almas.sfbay.sun.com>
Sender: Alan.Coopersmith@sun.com
To: PSARC-ext@sun.com
Message-id: <48220552.3000902@sun.com>
MIME-version: 1.0
Content-type: text/plain; charset=ISO-8859-1
Content-transfer-encoding: 7BIT
X-PMX-Version: 5.4.1.325704
X-Enigmail-Version: 0.95.1
References: <200804302143.m3ULhSCI000841@almas.sfbay.sun.com>
User-Agent: Thunderbird 2.0.0.6 (X11/20071203)
Status: RO
Content-Length: 360

Alan Coopersmith wrote:
> I am sponsoring this fast-track for myself and have set the timeout for
> next Wednesday, May 7, 2008.    This case requests a micro/patch release
> binding.

This case was approved by PSARC during ARC business today.

-- 
	-Alan Coopersmith-           alan.coopersmith@sun.com
	 Sun Microsystems, Inc. - X Window System Engineering


