opensource-apple / Apple16X50Serial

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

{\rtf1\mac\ansicpg10000\cocoartf824\cocoasubrtf410
{\fonttbl\f0\fnil\fcharset77 LucidaGrande;\f1\fswiss\fcharset77 Helvetica;\f2\fnil\fcharset77 LucidaGrande-Bold;
}
{\colortbl;\red255\green255\blue255;}
\vieww9000\viewh8400\viewkind0
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\ql\qnatural

\f0\fs24 \cf0 \'a9 Copyright 2002-2006 Apple Computer, Inc. All rights reserved.
\f1 \
\

\f2\b IMPORTANT
\f0\b0 :  This Apple software is supplied to you by Apple Computer, Inc. (\'d2Apple\'d3) in consideration of your agreement to the following terms, and your use, installation, modification or redistribution of this Apple software constitutes acceptance of these terms.  If you do not agree with these terms, please do not use, install, modify or redistribute this Apple software.
\f1 \
\

\f0 In consideration of your agreement to abide by the following terms, and subject to these terms, Apple grants you a personal, non-exclusive license, under Apple\'d5s copyrights in this original Apple software (the \'d2Apple Software\'d3), to use, reproduce, modify and redistribute the Apple Software, with or without modifications, in source and/or binary forms; provided that if you redistribute the Apple Software in its entirety and without modifications, you must retain this notice and the following text and disclaimers in all such redistributions of the Apple Software.  Neither the name, trademarks, service marks or logos of Apple Computer, Inc. may be used to endorse or promote products derived from the Apple Software without specific prior written permission from Apple.  Except as expressly stated in this notice, no other rights or licenses, express or implied, are granted by Apple herein, including but not limited to any patent rights that may be infringed by your derivative works or by other works in which the Apple Software may be incorporated.
\f1 \
\

\f0 The Apple Software is provided by Apple on an "AS IS" basis.  APPLE MAKES NO WARRANTIES, EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, REGARDING THE APPLE SOFTWARE OR ITS USE AND OPERATION ALONE OR IN COMBINATION WITH YOUR PRODUCTS. 
\f1 \
\

\f0 IN NO EVENT SHALL APPLE BE LIABLE FOR ANY SPECIAL, INDIRECT, INCIDENTAL OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ARISING IN ANY WAY OUT OF THE USE, REPRODUCTION, MODIFICATION AND/OR DISTRIBUTION OF THE APPLE SOFTWARE, HOWEVER CAUSED AND WHETHER UNDER THEORY OF CONTRACT, TORT (INCLUDING NEGLIGENCE), STRICT LIABILITY OR OTHERWISE, EVEN IF APPLE HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 \
HISTORY:\
Apple16X50Serial-1
\f1\b0 	
\f2\b (1.0.0d1)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Initial port based on NeXT drvISASerialPort driver
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-2
\f1\b0 	
\f2\b (1.0.0d1)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Significant code restructuring
\f1 \

\f0 \'a5	Changed instance variable naming convention to "fInstanceVariable"
\f1 \

\f0 \'a5	Added Apple16X50PCCard class to match on PCCard serial cards
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-3
\f1\b0 	
\f2\b (1.0.0d1)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Significant development on Apple16X50PCCard
\f1 \

\f0 \'a5	Changed instance variable naming convention back to "InstanceVariable"
\f1 \

\f0 \'a5	Renamed "Apple16X50.h" to "Apple16X50Serial.h"
\f1 \

\f0 \'a5	Renamed "Sample Code Disclaimer.rtf" to "ReadMe.rtf"\
\'a5	Removed "English.lproj/InfoPlist.strings"
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-4	(1.0.0d4)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Cleaned up and improved debug messages
\f1 \

\f0 \'a5	Rewrote dequeueData
\f1 \

\f0 \'a5	Initialized MasterClock instance variable to reasonable default\
\'a5	Added #error into master header so that potential users are forced to see the disclaimer
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-5	(1.0.0d5)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Fixed a few serious bugs; driver seems to be basically working now
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-6	(1.0.0d6)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Additional hang and panic fixes.\
\'a5	Cleaned up probing and starting UARTs in BusInterface class\
	replaced initUART() and publishUART() with probeUART() and startUARTs()
\f1 \
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-7	(1.0.0d7)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Fixed a few unterminating loops in the read path\
\'a5	Added lots of diagnostic information for PCCard modems\
\'a5	Added Copy Phase to install PCCard kext inside of main kext\
\'a5	Added build styles "DEBUG", "ASSERT", and "DEBUG & ASSERT" to simplify building with these options\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-8	(1.0.0a8)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Changed TTY node name scheme to be deterministic and thus NetworkPrefs friendly.  The TTY Base Name is now "pccard-" or "pci-" followed by either "serial" or "modem", as appropriate.  The TTY Suffix is the PCI Device number, or PCCard Socket number, followed by a lower case letter indicating which port on the card.  If there is only one port on the card, then the letter is eliminated from the suffix.  This produces names such as "pccard-modem" in the Network Prefs panel.\
\'a5	Cleaned up some of the debug messages, preparing for wider release\
\'a5	Added RELEASE() macro to safely release objects and null the reference.\
\'a5	Upgraded from "Development" status to "Alpha" status (the build stage in the version number)\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-9	(1.0.0a9)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Fixed minor PB setting that was causing the PCCard subkext to be installed twice (once in Plugins, and once in Resources).\
\'a5	Removed the "Country Codes" logging from the PCCard driver, as it was generating too much info for some cards.\
\'a5	Added support for 16C750 & 16X950 with 128 byte FIFOs.\
\'a5	Increased the "chunk" size in enqueueData/dequeueData to 2KB\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 \
Apple16X50Serial-10	(1.0.0b10)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Moved this ReadMe file from Resources to the top of Source to make it more visible\
\'a5	Removed unnecessary finalize() and terminate() methods\
\'a5	Added master clock frequency determination method\
\'a5	Introduced a new file "Apple16X50UARTTypes.cpp" that will eventually contain all the chip variant detection code\
\'a5	Many changes to the terminate sequence so that sleep/wake and card eject while busy work correctly\
\'a5	Upgraded from "Alpha" status to "Beta" status (the build stage in the version number)\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 \
Apple16X50Serial-10.1	(1.0.0fc1)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Disabled PCI card support for this branch of the driver\
\'a5	Upgraded from "Beta" status to "Final Candidate" status (the build stage in the version number)\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-10.2	(1.0.0fc2)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Cleaned up one case each of IORegistry corruption (object over-release()) in the PCI and PCCard subclasses\
\'a5	Cleaned up some OSString leaks\
\'a5	Update PCI classes to use RELEASE() macro\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-10.3	(1.0.0fc3)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Disabled automatic MasterClock detection on PCCard bus interface because it was causing a hang with Seiko Air H PCCard cellular modems\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-10.4	(1.0.0fc4)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Fixed a problem where connecting, disconnecting, connecting a PPP connection (or changing network locations) caused memory corruption which lead to random kernel panics.\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 \
Apple16X50Serial-10.5	(1.0.5)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.0.5\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-11		(1.1)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.1\
\'a5	Re-enabled PCI card support (disabled in -10.1 for release purposes)\
\'a5	Cleaned up some compiler warnings\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-12		(1.2)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.2\
\'a5	Added support for COM port devices (PNP0501) published by the ACPI platform\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-13		(1.3)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.3\
\'a5	Fixed a reference leak <rdar://problem/3291581>\
\'a5	Fixed a dangling pointer panic <rdar://problem/3161626>\
\'a5	Fixed baud-rate calculation code which was badly rounding some bad rates.\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-14		(1.4)\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0\b0 \cf0 \'a5	Updated CFBundleVersion to 1.4
\f2\b \

\f0\b0 \'a5	Fix for MP panic in DEBUG kernel <rdar://problem/3434850>
\f1 \

\f0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-15		(1.5)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.5\
\'a5	Added retry logic (up to 16 tries at .25 sec intervals) to probeUART() to work around UARTs that come out of reset slowly <rdar://problem/3497548>\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-16		(1.6)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.6\
\'a5	Fixed race that caused kernel threads to leak and an eventual panic <rdar://problem/3548744>\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-17		(1.7)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.7\
\'a5	Minor syntax fix to allow project to build using gcc4.0 <rdar://problem/4005543>\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b Apple16X50Serial-18		(1.8)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.8\
\'a5	Changed ACPI interface to omit port suffix for the primary serial port <rdar://problem/4584055>\
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f2\b \cf0 Apple16X50Serial-19.2		(1.9)
\f1\b0 \
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0 \cf0 \'a5	Updated CFBundleVersion to 1.9\
\'a5	Added power management code to handle machine sleep/wake with the port open <rdar://problem/4673043>\
\'a5	Removed erroneous call to IOWorkLoop->init() which was causing a second workloop thread to be created, resulting in panics: <rdar://problem/4695741>\
\'a5	Removed superfluous call to InterruptSource->enable()\
\'a5	Fixed 4673043 by toggling carrier across sleep/wake\
\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f1 \cf0 \

\f2\b TO DO:\
\pard\tx280\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\li280\fi-280\ql\qnatural

\f0\b0 \cf0 \'a5	Any comment containing "XXX" indicates code that needs cleaning up prior to release, or debug-only code.\
\'a5	Need to improve MasterClock calibration logic - it doesn't work with all UARTs and I'm not sure why yet.\
\'a5	Need to add FIFO depth and trigger level checks - the only way to know for sure is to loop bytes into the RxFIFO and watch as the trigger levels get hit, and then when the FIFO overflows.\
\'a5	Need to improve chipset variant detection logic - it is pretty loose now.  \
\'a5	The plan is to move all the UART detection and validation logic into static functions in Apple16X50UARTTypes.cpp.  These functions will be called once at probe() time for one channel, rather than for each.  The results will be stashed away in properties in the BusInterface object.  Instantiated UART objects will default to those values, or call the static detection functions if those properties are absent.   This will provide reasonable & efficient default behavior, but will allow device-specific subclasses to wire known settings and avoid the cost of detection.  Also, this will prevent the tests being run every time the machine wakes up.
\f1 \
}

About


Languages

Language:C++ 100.0%