From laffer1 at midnightbsd.org Thu Jan 1 12:32:00 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 1 Jan 2009 12:32:00 -0500 (EST) Subject: [Midnightbsd-cvs] src: param.h: Don't make this octal. Message-ID: <200901011732.n01HW09D019691@stargazer.midnightbsd.org> Log Message: ----------- Don't make this octal. Tags: ---- RELENG_0_2 Modified Files: -------------- src/sys/sys: param.h (r1.8.2.6 -> r1.8.2.7) -------------- next part -------------- Index: param.h =================================================================== RCS file: /home/cvs/src/sys/sys/param.h,v retrieving revision 1.8.2.6 retrieving revision 1.8.2.7 diff -L sys/sys/param.h -L sys/sys/param.h -u -r1.8.2.6 -r1.8.2.7 --- sys/sys/param.h +++ sys/sys/param.h @@ -61,7 +61,7 @@ #define __FreeBSD_version 601000 /* Master, propagated to newvers */ #undef __MidnightBSD_version -#define __MidnightBSD_version 002008 +#define __MidnightBSD_version 2008 #ifndef LOCORE #include From laffer1 at midnightbsd.org Thu Jan 1 12:49:43 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 1 Jan 2009 12:49:43 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: donation link Message-ID: <200901011749.n01Hnhpl021622@stargazer.midnightbsd.org> Log Message: ----------- donation link Modified Files: -------------- www/donate: index.html (r1.4 -> r1.5) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/donate/index.html,v retrieving revision 1.4 retrieving revision 1.5 diff -L donate/index.html -L donate/index.html -u -r1.4 -r1.5 --- donate/index.html +++ donate/index.html @@ -34,6 +34,16 @@

Please email luke@midnightbsd.org to make a request or when a request is filled, so that we may update this page. Requestors on this page should have at least one accepted contribution to MidnightBSD.

Donors, please contact the requestor directly and CC the above address. The MidnightBSD project cannot assist with aranging delivery and is not responsible for any transactions.

Check with your local post office for requirements to send out of the country if needed.

+ + +
+

+ + + +

+

@@ -74,4 +84,4 @@ - \ No newline at end of file + From ctriv at midnightbsd.org Thu Jan 1 15:25:30 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Thu, 1 Jan 2009 15:25:30 -0500 (EST) Subject: [Midnightbsd-cvs] mports: x11/xorg-cf-files: Force UseElfFormat to YES. Message-ID: <200901012025.n01KPUEr037398@stargazer.midnightbsd.org> Log Message: ----------- Force UseElfFormat to YES. mbsd has always been elf, and this fixes breakage in -CURRENT Modified Files: -------------- mports/x11/xorg-cf-files: Makefile (r1.2 -> r1.3) mports/x11/xorg-cf-files/files: patch-FreeBSD.cf (r1.2 -> r1.3) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/x11/xorg-cf-files/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L x11/xorg-cf-files/Makefile -L x11/xorg-cf-files/Makefile -u -r1.2 -r1.3 --- x11/xorg-cf-files/Makefile +++ x11/xorg-cf-files/Makefile @@ -8,7 +8,7 @@ PORTNAME= xorg-cf-files PORTVERSION= 1.0.2 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= x11 MAINTAINER= ports at MidnightBSD.org Index: patch-FreeBSD.cf =================================================================== RCS file: /home/cvs/mports/x11/xorg-cf-files/files/patch-FreeBSD.cf,v retrieving revision 1.2 retrieving revision 1.3 diff -L x11/xorg-cf-files/files/patch-FreeBSD.cf -L x11/xorg-cf-files/files/patch-FreeBSD.cf -u -r1.2 -r1.3 --- x11/xorg-cf-files/files/patch-FreeBSD.cf +++ x11/xorg-cf-files/files/patch-FreeBSD.cf @@ -1,6 +1,17 @@ ---- ./FreeBSD.cf.orig Tue Oct 16 22:57:20 2007 -+++ ./FreeBSD.cf Tue Oct 16 23:09:35 2007 -@@ -47,19 +47,10 @@ +--- ./FreeBSD.cf.orig 2005-05-04 00:14:57 -0400 ++++ ./FreeBSD.cf 2008-12-25 00:22:56 -0500 +@@ -5,9 +5,7 @@ + XCOMM + XCOMM platform: $XFree86: xc/config/cf/FreeBSD.cf,v 3.147 2004/01/28 01:46:21 dawes Exp $ + +-#ifndef UseElfFormat +-#define UseElfFormat DefaultToElfFormat +-#endif ++#define UseElfFormat YES + + #if UseElfFormat + #define OSBinaryFormat [ELF] +@@ -47,19 +45,10 @@ #define HasNdbm YES #define HasPutenv YES #define HasSnprintf YES @@ -22,7 +33,7 @@ #ifndef HasLibCrypt # define HasLibCrypt YES #endif -@@ -74,63 +65,28 @@ +@@ -74,63 +63,28 @@ #ifndef BuildPDFdocs # define BuildPDFdocs NO #endif @@ -94,7 +105,7 @@ #define AvoidNullMakeCommand YES #define StripInstalledPrograms YES -@@ -155,22 +111,9 @@ +@@ -155,22 +109,9 @@ #endif #ifndef HasMktemp @@ -117,7 +128,7 @@ #ifndef CcCmd #define CcCmd cc -@@ -195,41 +138,12 @@ +@@ -195,41 +136,12 @@ GccWarningOptions #endif #endif @@ -160,7 +171,7 @@ #endif /* -@@ -237,17 +151,14 @@ +@@ -237,17 +149,14 @@ * mechanism for specifying a subset of drivers in the OS.cf files yet. */ #ifndef BuildXF86DRI @@ -179,7 +190,7 @@ #define HasAgpGart YES #endif #if (defined(AlphaArchitecture) || defined(ia64Architecture) || \ -@@ -260,8 +171,7 @@ +@@ -260,8 +169,7 @@ * SSE and 3DNow will be autodetected, so binutils is the only * requirement for enabling this. By 4.2 they were all supported. */ @@ -189,7 +200,7 @@ # define HasX86Support YES # define HasMMXSupport YES # define Has3DNowSupport YES -@@ -311,8 +221,6 @@ +@@ -311,8 +219,6 @@ # define UseRpath YES #endif @@ -198,7 +209,7 @@ # ifndef RpathLoadFlags # if UseRpath # if UseElfFormat -@@ -333,7 +241,6 @@ +@@ -333,7 +239,6 @@ # endif # endif @@ -206,7 +217,7 @@ #ifndef LibraryRpathLoadFlags # if UseRpath -@@ -359,20 +266,13 @@ +@@ -359,20 +264,13 @@ #define GnuMallocLibrary -lgnumalloc #endif @@ -227,7 +238,7 @@ /* There are two options for building. One is to assume that the system has * many of the dependencies provided by the ports tree. The other is to just -@@ -449,7 +349,6 @@ +@@ -449,7 +347,6 @@ #define StandardDefines -DCSRG_BASED @@ -235,7 +246,7 @@ #define ServerOSDefines XFree86ServerOSDefines -DDDXTIME #define XawI18nDefines -DUSE_XWCHAR_STRING #define HasMakefileSafeInclude YES -@@ -462,17 +361,11 @@ +@@ -462,17 +359,11 @@ #define ForceNormalLib YES #endif #define HasMkstemp YES @@ -253,7 +264,7 @@ #ifdef i386Architecture # define OptimizedCDebugFlags DefaultGcc2i386Opt -@@ -507,9 +400,7 @@ +@@ -507,9 +398,7 @@ # define CompressManPages YES #endif @@ -263,7 +274,7 @@ #ifndef StaticLibrary #define StaticLibrary(libpath,libname) -Wl,-Bstatic Concat(-L,libpath) Concat(-l,libname) -Wl,-Bdynamic -@@ -561,13 +452,9 @@ +@@ -561,13 +450,9 @@ #ifndef HasCookieMaker /* Which versions have /dev/urandom? */ From laffer1 at midnightbsd.org Thu Jan 1 17:00:27 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 1 Jan 2009 17:00:27 -0500 (EST) Subject: [Midnightbsd-cvs] src: share/zoneinfo: 2008i Message-ID: <200901012200.n01M0RQM046333@stargazer.midnightbsd.org> Log Message: ----------- 2008i Modified Files: -------------- src/share/zoneinfo: MidnightBSD-upgrade (r1.3 -> r1.4) africa (r1.4 -> r1.5) asia (r1.4 -> r1.5) australasia (r1.4 -> r1.5) backward (r1.4 -> r1.5) europe (r1.4 -> r1.5) leapseconds (r1.4 -> r1.5) northamerica (r1.4 -> r1.5) southamerica (r1.4 -> r1.5) zone.tab (r1.4 -> r1.5) -------------- next part -------------- Index: australasia =================================================================== RCS file: /home/cvs/src/share/zoneinfo/australasia,v retrieving revision 1.4 retrieving revision 1.5 diff -L share/zoneinfo/australasia -L share/zoneinfo/australasia -u -r1.4 -r1.5 --- share/zoneinfo/australasia +++ share/zoneinfo/australasia @@ -1,4 +1,4 @@ -# @(#)australasia 8.8 +# @(#)australasia 8.9 #
 
 # This file also includes Pacific islands.
@@ -1346,7 +1346,7 @@
 # * Tonga will introduce DST in November
 #
 # I was given this link by John Letts:
-# 
+# 
 # http://news.bbc.co.uk/hi/english/world/asia-pacific/newsid_424000/424764.stm
 # 
 #
@@ -1356,7 +1356,7 @@
 # (12 + 1 hour DST).
 
 # From Arthur David Olson (1999-09-20):
-# According to 
 # http://www.tongaonline.com/news/sept1799.html
 # :
 # "Daylight Savings Time will take effect on Oct. 2 through April 15, 2000
Index: backward
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/backward,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/backward -L share/zoneinfo/backward -u -r1.4 -r1.5
--- share/zoneinfo/backward
+++ share/zoneinfo/backward
@@ -1,4 +1,4 @@
-# @(#)backward	8.4
+# @(#)backward	8.6
 
 # This file provides links between current names for time zones
 # and their old names.  Many names changed in late 1993.
@@ -24,8 +24,10 @@
 Link	Asia/Ashgabat		Asia/Ashkhabad
 Link	Asia/Chongqing		Asia/Chungking
 Link	Asia/Dhaka		Asia/Dacca
+Link	Asia/Kolkata		Asia/Calcutta
 Link	Asia/Macau		Asia/Macao
 Link	Asia/Jerusalem		Asia/Tel_Aviv
+Link	Asia/Ho_Chi_Minh	Asia/Saigon
 Link	Asia/Thimphu		Asia/Thimbu
 Link	Asia/Makassar		Asia/Ujung_Pandang
 Link	Asia/Ulaanbaatar	Asia/Ulan_Bator
Index: leapseconds
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/leapseconds,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/leapseconds -L share/zoneinfo/leapseconds -u -r1.4 -r1.5
--- share/zoneinfo/leapseconds
+++ share/zoneinfo/leapseconds
@@ -1,4 +1,4 @@
-# @(#)leapseconds	8.4
+# @(#)leapseconds	8.6
 
 # Allowance for leapseconds added to each timezone file.
 
@@ -44,8 +44,10 @@
 Leap	1997	Jun	30	23:59:60	+	S
 Leap	1998	Dec	31	23:59:60	+	S
 Leap	2005	Dec	31	23:59:60	+	S
+Leap	2008	Dec	31	23:59:60	+	S
 
 # INTERNATIONAL EARTH ROTATION AND REFERENCE SYSTEMS SERVICE (IERS)
+#
 # SERVICE INTERNATIONAL DE LA ROTATION TERRESTRE ET DES SYSTEMES DE REFERENCE
 #
 # SERVICE DE LA ROTATION TERRESTRE
@@ -53,30 +55,38 @@
 # 61, Av. de l'Observatoire 75014 PARIS (France)
 # Tel.      : 33 (0) 1 40 51 22 26
 # FAX       : 33 (0) 1 40 51 22 91
-# Internet  : services.iers at obspm.fr
+# e-mail    : services.iers at obspm.fr
+# http://hpiers.obspm.fr/eop-pc
 #
-# Paris, 28 June 2007
+# Paris, 4 July 2008
 #
-# Bulletin C 34
+# Bulletin C 36
 #
 # To authorities responsible
 # for the measurement and
 # distribution of time
 #
-# INFORMATION ON UTC - TAI
+# UTC TIME STEP
+# on the 1st of January 2009
+#
+# A positive leap second will be introduced at the end of December 2008.
+# The sequence of dates of the UTC second markers will be:		
+#
+# 2008 December 31,     23h 59m 59s
+# 2008 December 31,     23h 59m 60s
+# 2009 January   1,      0h  0m  0s
 #
-# NO positive leap second will be introduced at the end of December 2007.
-# The difference between Coordinated Universal Time UTC and the
-# International Atomic Time TAI is :		
+# The difference between UTC and the International Atomic Time TAI is:
 #
-# from 2006 January 1, 0h UTC, until further notice : UTC-TAI = -33 s
+# from 2006 January 1, 0h UTC, to 2009 January 1  0h UTC  : UTC-TAI = - 33s
+# from 2009 January 1, 0h UTC, until further notice       : UTC-TAI = - 34s
 #
 # Leap seconds can be introduced in UTC at the end of the months of December
-# or June,  depending on the evolution of UT1-TAI. Bulletin C is mailed every
-# six months, either to announce a time step in UTC, or to confirm that there
+# or June, depending on the evolution of UT1-TAI. Bulletin C is mailed every
+# six months, either to announce a time step in UTC or to confirm that there
 # will be no time step at the next possible date.
 #
 # Daniel GAMBIS
-# Director			
+# Head		
 # Earth Orientation Center of IERS
 # Observatoire de Paris, France
Index: zone.tab
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/zone.tab,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/zone.tab -L share/zoneinfo/zone.tab -u -r1.4 -r1.5
--- share/zoneinfo/zone.tab
+++ share/zoneinfo/zone.tab
@@ -1,4 +1,4 @@
-# @(#)zone.tab	8.13
+# @(#)zone.tab	8.21
 #
 # TZ zone descriptions
 #
@@ -42,13 +42,15 @@
 AQ	-6640+14001	Antarctica/DumontDUrville	Dumont-d'Urville Station, Terre Adelie
 AQ	-690022+0393524	Antarctica/Syowa	Syowa Station, E Ongul I
 AR	-3436-05827	America/Argentina/Buenos_Aires	Buenos Aires (BA, CF)
-AR	-3124-06411	America/Argentina/Cordoba	most locations (CB, CC, CN, ER, FM, LP, MN, NQ, RN, SA, SE, SF, SL)
+AR	-3124-06411	America/Argentina/Cordoba	most locations (CB, CC, CN, ER, FM, MN, SE, SF)
+AR	-2447-06525	America/Argentina/Salta	(SA, LP, NQ, RN)
 AR	-2411-06518	America/Argentina/Jujuy	Jujuy (JY)
 AR	-2649-06513	America/Argentina/Tucuman	Tucuman (TM)
 AR	-2828-06547	America/Argentina/Catamarca	Catamarca (CT), Chubut (CH)
 AR	-2926-06651	America/Argentina/La_Rioja	La Rioja (LR)
 AR	-3132-06831	America/Argentina/San_Juan	San Juan (SJ)
 AR	-3253-06849	America/Argentina/Mendoza	Mendoza (MZ)
+AR	-3319-06621	America/Argentina/San_Luis	San Luis (SL)
 AR	-5138-06913	America/Argentina/Rio_Gallegos	Santa Cruz (SC)
 AR	-5448-06818	America/Argentina/Ushuaia	Tierra del Fuego (TF)
 AS	-1416-17042	Pacific/Pago_Pago
@@ -91,7 +93,8 @@
 BR	-2332-04637	America/Sao_Paulo	S & SE Brazil (GO, DF, MG, ES, RJ, SP, PR, SC, RS)
 BR	-2027-05437	America/Campo_Grande	Mato Grosso do Sul
 BR	-1535-05605	America/Cuiaba	Mato Grosso
-BR	-0846-06354	America/Porto_Velho	W Para, Rondonia
+BR	-0226-05452	America/Santarem	W Para
+BR	-0846-06354	America/Porto_Velho	Rondonia
 BR	+0249-06040	America/Boa_Vista	Roraima
 BR	-0308-06001	America/Manaus	E Amazonas
 BR	-0640-06952	America/Eirunepe	W Amazonas
@@ -209,7 +212,7 @@
 IE	+5320-00615	Europe/Dublin
 IL	+3146+03514	Asia/Jerusalem
 IM	+5409-00428	Europe/Isle_of_Man
-IN	+2232+08822	Asia/Calcutta
+IN	+2232+08822	Asia/Kolkata
 IO	-0720+07225	Indian/Chagos
 IQ	+3321+04425	Asia/Baghdad
 IR	+3540+05126	Asia/Tehran
@@ -291,7 +294,7 @@
 NO	+5955+01045	Europe/Oslo
 NP	+2743+08519	Asia/Katmandu
 NR	-0031+16655	Pacific/Nauru
-NU	-1901+16955	Pacific/Niue
+NU	-1901-16955	Pacific/Niue
 NZ	-3652+17446	Pacific/Auckland	most locations
 NZ	-4357-17633	Pacific/Chatham	Chatham Islands
 OM	+2336+05835	Asia/Muscat
@@ -382,13 +385,13 @@
 US	+364947-0845057	America/Kentucky/Monticello	Eastern Time - Kentucky - Wayne County
 US	+394606-0860929	America/Indiana/Indianapolis	Eastern Time - Indiana - most locations
 US	+384038-0873143	America/Indiana/Vincennes	Eastern Time - Indiana - Daviess, Dubois, Knox & Martin Counties
-US	+411745-0863730	America/Indiana/Knox	Eastern Time - Indiana - Starke County
 US	+410305-0863611	America/Indiana/Winamac	Eastern Time - Indiana - Pulaski County
 US	+382232-0862041	America/Indiana/Marengo	Eastern Time - Indiana - Crawford County
+US	+382931-0871643	America/Indiana/Petersburg	Eastern Time - Indiana - Pike County
 US	+384452-0850402	America/Indiana/Vevay	Eastern Time - Indiana - Switzerland County
 US	+415100-0873900	America/Chicago	Central Time
 US	+375711-0864541	America/Indiana/Tell_City	Central Time - Indiana - Perry County
-US	+382931-0871643	America/Indiana/Petersburg	Central Time - Indiana - Pike County
+US	+411745-0863730	America/Indiana/Knox	Central Time - Indiana - Starke County
 US	+450628-0873651	America/Menominee	Central Time - Michigan - Dickinson, Gogebic, Iron & Menominee Counties
 US	+470659-1011757	America/North_Dakota/Center	Central Time - North Dakota - Oliver County
 US	+465042-1012439	America/North_Dakota/New_Salem	Central Time - North Dakota - Morton County (except Mandan area)
@@ -411,7 +414,7 @@
 VE	+1030-06656	America/Caracas
 VG	+1827-06437	America/Tortola
 VI	+1821-06456	America/St_Thomas
-VN	+1045+10640	Asia/Saigon
+VN	+1045+10640	Asia/Ho_Chi_Minh
 VU	-1740+16825	Pacific/Efate
 WF	-1318-17610	Pacific/Wallis
 WS	-1350-17144	Pacific/Apia
Index: africa
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/africa,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/africa -L share/zoneinfo/africa -u -r1.4 -r1.5
--- share/zoneinfo/africa
+++ share/zoneinfo/africa
@@ -1,4 +1,4 @@
-# @(#)africa	8.10
+# @(#)africa	8.17
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -387,9 +387,88 @@
 			 0:00	-	GMT
 
 # Mauritius
+
+# From Steffen Thorsen (2008-06-25):
+# Mauritius plans to observe DST from 2008-11-01 to 2009-03-31 on a trial
+# basis....
+# It seems that Mauritius observed daylight saving time from 1982-10-10 to 
+# 1983-03-20 as well, but that was not successful....
+# http://www.timeanddate.com/news/time/mauritius-daylight-saving-time.html
+
+# From Alex Krivenyshev (2008-06-25):
+# http://economicdevelopment.gov.mu/portal/site/Mainhomepage/menuitem.a42b24128104d9845dabddd154508a0c/?content_id=0a7cee8b5d69a110VgnVCM1000000a04a8c0RCRD
+
+# From Arthur David Olson (2008-06-30):
+# The www.timeanddate.com article cited by Steffen Thorsen notes that "A
+# final decision has yet to be made on the times that daylight saving
+# would begin and end on these dates." As a place holder, use midnight.
+
+# From Paul Eggert (2008-06-30):
+# Follow Thorsen on DST in 1982/1983, instead of Shanks & Pottenger.
+
+# From Steffen Thorsen (2008-07-10):
+# According to
+# 
+# http://www.lexpress.mu/display_article.php?news_id=111216
+# 
+# (in French), Mauritius will start and end their DST a few days earlier
+# than previously announced (2008-11-01 to 2009-03-31).  The new start
+# date is 2008-10-26 at 02:00 and the new end date is 2009-03-27 (no time
+# given, but it is probably at either 2 or 3 wall clock time).
+# 
+# A little strange though, since the article says that they moved the date 
+# to align itself with Europe and USA which also change time on that date, 
+# but that means they have not paid attention to what happened in 
+# USA/Canada last year (DST ends first Sunday in November). I also wonder 
+# why that they end on a Friday, instead of aligning with Europe which 
+# changes two days later.
+
+# From Alex Krivenyshev (2008-07-11):
+# Seems that English language article "The revival of daylight saving
+# time:  Energy conservation?"-# No. 16578 (07/11/2008) was originally
+# published on Monday, June 30, 2008...
+#
+# I guess that article in French "Le gouvernement avance l'introduction
+# de l'heure d'ete" stating that DST in Mauritius starting on October 26
+# and ending on March 27, 2009 is the most recent one.
+# ...
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_mauritius02.html
+# 
+
+# From Riad M. Hossen Ally (2008-08-03):
+# The Government of Mauritius weblink
+# 
+# http://www.gov.mu/portal/site/pmosite/menuitem.4ca0efdee47462e7440a600248a521ca/?content_id=3D4728ca68b2a5b110VgnVCM1000000a04a8c0RCRD
+# 
+# Cabinet Decision of July 18th, 2008 states as follows:
+#
+# 4. ...Cabinet has agreed to the introduction into the National Assembly
+# of the Time Bill which provides for the introduction of summer time in
+# Mauritius. The summer time period which will be of one hour ahead of
+# the standard time, will be aligned with that in Europe and the United
+# States of America. It will start at two o'clock in the morning on the
+# last Sunday of October and will end at two o'clock in the morning on
+# the last Sunday of March the following year. The summer time for the
+# year 2008 - 2009 will, therefore, be effective as from 26 October 2008
+# and end on 29 March 2009.
+
+# From Ed Maste (2008-10-07):
+# THE TIME BILL (No. XXVII of 2008) Explanatory Memorandum states the
+# beginning / ending of summer time is 2 o'clock standard time in the
+# morning of the last Sunday of October / last Sunday of March.
+# 
+# http://www.gov.mu/portal/goc/assemblysite/file/bill2708.pdf
+# 
+
+# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
+Rule Mauritius	1982	only	-	Oct	10	0:00	1:00	S
+Rule Mauritius	1983	only	-	Mar	21	0:00	0	-
+Rule Mauritius	2008	max	-	Oct	lastSun	2:00s	1:00	S
+Rule Mauritius	2009	max	-	Mar	lastSun	2:00s	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone Indian/Mauritius	3:50:00 -	LMT	1907		# Port Louis
-			4:00	-	MUT	# Mauritius Time
+			4:00 Mauritius	MU%sT	# Mauritius Time
 # Agalega Is, Rodriguez
 # no information; probably like Indian/Mauritius
 
@@ -400,7 +479,93 @@
 
 # Morocco
 # See the `europe' file for Spanish Morocco (Africa/Ceuta).
+
+# From Alex Krivenyshev (2008-05-09):
+# Here is an article that Morocco plan to introduce Daylight Saving Time between
+# 1 June, 2008 and 27 September, 2008.
+#
+# "... Morocco is to save energy by adjusting its clock during summer so it will
+# be one hour ahead of GMT between 1 June and 27 September, according to
+# Communication Minister and Gov ernment Spokesman, Khalid Naciri...."
+#
+# 
+# http://www.worldtimezone.net/dst_news/dst_news_morocco01.html
+# 
+# OR
+# 
+# http://en.afrik.com/news11892.html
+# 
+
+# From Alex Krivenyshev (2008-05-09):
+# The Morocco time change can be confirmed on Morocco web site Maghreb Arabe Presse:
+# 
+# http://www.map.ma/eng/sections/box3/morocco_shifts_to_da/view
+# 
+#
+# Morocco shifts to daylight time on June 1st through September 27, Govt.
+# spokesman.
+
+# From Patrice Scattolin (2008-05-09):
+# According to this article:
+# 
+# http://www.avmaroc.com/actualite/heure-dete-comment-a127896.html
+# 
+# (and republished here:
+# 
+# http://www.actu.ma/heure-dete-comment_i127896_0.html
+# 
+# )
+# the changes occurs at midnight:
+#
+# saturday night may 31st at midnight (which in french is to be
+# intrepreted as the night between saturday and sunday)
+# sunday night the 28th  at midnight
+#
+# Seeing that the 28th is monday, I am guessing that she intends to say
+# the midnight of the 28th which is the midnight between sunday and
+# monday, which jives with other sources that say that it's inclusive
+# june1st to sept 27th.
+#
+# The decision was taken by decree *2-08-224 *but I can't find the decree
+# published on the web.
+#
+# It's also confirmed here:
+# 
+# http://www.maroc.ma/NR/exeres/FACF141F-D910-44B0-B7FA-6E03733425D1.htm
+# 
+# on a government portal as being  between june 1st and sept 27th (not yet
+# posted in english).
+#
+# The following google query will generate many relevant hits:
+# 
+# http://www.google.com/search?hl=en&q=Conseil+de+gouvernement+maroc+heure+avance&btnG=Search
+# 
+
+# From Alex Krivenyshev (2008-05-09):
+# Is Western Sahara (part which administrated by Morocco) going to follow
+# Morocco DST changes?  Any information?  What about other part of
+# Western Sahara - under administration of POLISARIO Front (also named
+# SADR Saharawi Arab Democratic Republic)?
+
+# From Arthur David Olson (2008-05-09):
+# XXX--guess that it is only Morocco for now; guess only 2008 for now.
+
+# From Steffen Thorsen (2008-08-27):
+# Morocco will change the clocks back on the midnight between August 31 
+# and September 1. They originally planned to observe DST to near the end 
+# of September:
+#
+# One article about it (in French):
+# 
+# http://www.menara.ma/fr/Actualites/Maroc/Societe/ci.retour_a_l_heure_gmt_a_partir_du_dimanche_31_aout_a_minuit_officiel_.default
+# 
+#
+# We have some further details posted here:
+# 
+# http://www.timeanddate.com/news/time/morocco-ends-dst-early-2008.html
+# 
 # RULE	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
+
 Rule	Morocco	1939	only	-	Sep	12	 0:00	1:00	S
 Rule	Morocco	1939	only	-	Nov	19	 0:00	0	-
 Rule	Morocco	1940	only	-	Feb	25	 0:00	1:00	S
@@ -416,11 +581,13 @@
 Rule	Morocco	1977	only	-	Sep	28	 0:00	0	-
 Rule	Morocco	1978	only	-	Jun	 1	 0:00	1:00	S
 Rule	Morocco	1978	only	-	Aug	 4	 0:00	0	-
+Rule	Morocco	2008	only	-	Jun	 1	 0:00	1:00	S
+Rule	Morocco	2008	only	-	Sep	 1	 0:00	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone Africa/Casablanca	-0:30:20 -	LMT	1913 Oct 26
 			 0:00	Morocco	WE%sT	1984 Mar 16
 			 1:00	-	CET	1986
-			 0:00	-	WET
+			 0:00	Morocco	WE%sT
 # Western Sahara
 Zone Africa/El_Aaiun	-0:52:48 -	LMT	1934 Jan
 			-1:00	-	WAT	1976 Apr 14
Index: MidnightBSD-upgrade
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/MidnightBSD-upgrade,v
retrieving revision 1.3
retrieving revision 1.4
diff -L share/zoneinfo/MidnightBSD-upgrade -L share/zoneinfo/MidnightBSD-upgrade -u -r1.3 -r1.4
--- share/zoneinfo/MidnightBSD-upgrade
+++ share/zoneinfo/MidnightBSD-upgrade
@@ -18,6 +18,6 @@
 
 __
 
-Last updated with tzdata2007k
+Last updated with tzdata2008i
 
 $MidnightBSD$
Index: southamerica
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/southamerica,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/southamerica -L share/zoneinfo/southamerica -u -r1.4 -r1.5
--- share/zoneinfo/southamerica
+++ share/zoneinfo/southamerica
@@ -1,4 +1,4 @@
-# @(#)southamerica	8.15
+# @(#)southamerica	8.33
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -164,9 +164,58 @@
 # From Paul Eggert (2007-12-22):
 # For dates after mid-2008, the following rules are my guesses and
 # are quite possibly wrong, but are more likely than no DST at all.
+
+# From Alexander Krivenyshev (2008-09-05):
+# As per message from Carlos Alberto Fonseca Arauz (Nicaragua),
+# Argentina will start DST on Sunday October 19, 2008.
+#
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_argentina03.html
+# 
+# OR
+# 
+# http://www.impulsobaires.com.ar/nota.php?id=57832 (in spanish)
+# 
+
+# From Rodrigo Severo (2008-10-06):
+# Here is some info available at a Gentoo bug related to TZ on Argentina's DST:
+# ...
+# ------- Comment #1 from [jmdocile]  2008-10-06 16:28 0000 -------
+# Hi, there is a problem with timezone-data-2008e and maybe with
+# timezone-data-2008f
+# Argentinian law [Number] 25.155 is no longer valid.
+# 
+# http://www.infoleg.gov.ar/infolegInternet/anexos/60000-64999/60036/norma.htm
+# 
+# The new one is law [Number] 26.350
+# 
+# http://www.infoleg.gov.ar/infolegInternet/anexos/135000-139999/136191/norma.htm
+# 
+# So there is no summer time in Argentina for now.
+
+# From Mariano Absatz (2008-10-20):
+# Decree 1693/2008 applies Law 26.350 for the summer 2008/2009 establishing DST in Argentina
+# From 2008-10-19 until 2009-03-15
+# 
+# http://www.boletinoficial.gov.ar/Bora.Portal/CustomControls/PdfContent.aspx?fp=16102008&pi=3&pf=4&s=0&sec=01
+# 
+#
+# Decree 1705/2008 excepting 12 Provinces from applying DST in the summer 2008/2009:
+# Catamarca, La Rioja, Mendoza, Salta, San Juan, San Luis, La Pampa, Neuquen, Rio Negro, Chubut, Santa Cruz
+# and Tierra del Fuego
+# 
+# http://www.boletinoficial.gov.ar/Bora.Portal/CustomControls/PdfContent.aspx?fp=17102008&pi=1&pf=1&s=0&sec=01
+# 
+#
+# Press release 235 dated Saturday October 18th, from the Government of the Province of Jujuy saying
+# it will not apply DST either (even when it was not included in Decree 1705/2008)
+# 
+# http://www.jujuy.gov.ar/index2/partes_prensa/18_10_08/235-181008.doc
+# 
+
 Rule	Arg	2007	only	-	Dec	30	0:00	1:00	S
 Rule	Arg	2008	max	-	Mar	Sun>=15	0:00	0	-
-Rule	Arg	2008	max	-	Oct	Sun>=1	0:00	1:00	S
+Rule	Arg	2008	max	-	Oct	Sun>=15	0:00	1:00	S
  
 # From Mariano Absatz (2004-05-21):
 # Today it was officially published that the Province of Mendoza is changing
@@ -228,10 +277,80 @@
 # http://www.sanjuan.gov.ar/prensa/archivo/000426.html
 # http://www.sanjuan.gov.ar/prensa/archivo/000441.html
 
+# From Alex Krivenyshev (2008-01-17):
+# Here are articles that Argentina Province San Luis is planning to end DST
+# as earlier as upcoming Monday January 21, 2008 or February 2008:
+#
+# Provincia argentina retrasa reloj y marca diferencia con resto del pais
+# (Argentine Province delayed clock and mark difference with the rest of the
+# country)
+# 
+# http://cl.invertia.com/noticias/noticia.aspx?idNoticia=200801171849_EFE_ET4373&idtel
+# 
+#
+# Es inminente que en San Luis atrasen una hora los relojes
+# (It is imminent in San Luis clocks one hour delay)
+# 
+# http://www.lagaceta.com.ar/vernotae.asp?id_nota=253414
+# 
+#
+# 
+# http://www.worldtimezone.net/dst_news/dst_news_argentina02.html
+# 
+
+# From Jesper Norgaard Welen (2008-01-18):
+# The page of the San Luis provincial government
+# 
+# http://www.sanluis.gov.ar/notas.asp?idCanal=0&id=22812
+# 
+# confirms what Alex Krivenyshev has earlier sent to the tz
+# emailing list about that San Luis plans to return to standard
+# time much earlier than the rest of the country. It also
+# confirms that upon request the provinces San Juan and Mendoza 
+# refused to follow San Luis in this change. 
+# 
+# The change is supposed to take place Monday the 21.st at 0:00
+# hours. As far as I understand it if this goes ahead, we need
+# a new timezone for San Luis (although there are also documented
+# independent changes in the southamerica file of San Luis in
+# 1990 and 1991 which has not been confirmed).
+
+# From Jesper Norgaard Welen (2008-01-25):
+# Unfortunately the below page has become defunct, about the San Luis
+# time change. Perhaps because it now is part of a group of pages "Most
+# important pages of 2008."
+#
+# You can use
+# 
+# http://www.sanluis.gov.ar/notas.asp?idCanal=8141&id=22834
+# 
+# instead it seems. Or use "Buscador" from the main page of the San Luis
+# government, and fill in "huso" and click OK, and you will get 3 pages
+# from which the first one is identical to the above.
+
+# From Mariano Absatz (2008-01-28):
+# I can confirm that the Province of San Luis (and so far only that
+# province) decided to go back to UTC-3 effective midnight Jan 20th 2008
+# (that is, Monday 21st at 0:00 is the time the clocks were delayed back
+# 1 hour), and they intend to keep UTC-3 as their timezone all year round
+# (that is, unless they change their mind any minute now).
+#
+# So we'll have to add yet another city to 'southamerica' (I think San
+# Luis city is the mos populated city in the Province, so it'd be
+# America/Argentina/San_Luis... of course I can't remember if San Luis's
+# history of particular changes goes along with Mendoza or San Juan :-(
+# (I only remember not being able to collect hard facts about San Luis
+# back in 2004, when these provinces changed to UTC-4 for a few days, I
+# mailed them personally and never got an answer).
+
+# From Paul Eggert (2008-06-30):
 # Unless otherwise specified, data are from Shanks & Pottenger through 1992,
 # from the IATA otherwise.  As noted below, Shanks & Pottenger say that
-# America/Cordoba split into 6 subregions during 1991/1992, but we
-# haven't verified this yet so for now we'll keep it a single region.
+# America/Cordoba split into 6 subregions during 1991/1992, one of which
+# was America/San_Luis, but we haven't verified this yet so for now we'll
+# keep America/Cordoba a single region rather than splitting it into the
+# other 5 subregions.
+
 #
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 #
@@ -244,16 +363,13 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	Arg	AR%sT
 #
-# Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN), Chaco (CC),
-# Formosa (FM), Salta (SA), Santiago del Estero (SE), Cordoba (CB),
-# San Luis (SL), La Pampa (LP), Neuquen (NQ), Rio Negro (RN)
+# Cordoba (CB), Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN),
+# Chaco (CC), Formosa (FM), Santiago del Estero (SE)
 #
 # Shanks & Pottenger also make the following claims, which we haven't verified:
 # - Formosa switched to -3:00 on 1991-01-07.
 # - Misiones switched to -3:00 on 1990-12-29.
 # - Chaco switched to -3:00 on 1991-01-04.
-# - San Luis switched to -4:00 on 1990-03-14, then to -3:00 on 1990-10-15,
-#   then to -4:00 on 1991-03-01, then to -3:00 on 1991-06-01.
 # - Santiago del Estero switched to -4:00 on 1991-04-01,
 #   then to -3:00 on 1991-04-26.
 #
@@ -267,6 +383,18 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	Arg	AR%sT
 #
+# Salta (SA), La Pampa (LP), Neuquen (NQ), Rio Negro (RN)
+Zone America/Argentina/Salta -4:21:40 - LMT	1894 Oct 31
+			-4:16:48 -	CMT	1920 May
+			-4:00	-	ART	1930 Dec
+			-4:00	Arg	AR%sT	1969 Oct  5
+			-3:00	Arg	AR%sT	1991 Mar  3
+			-4:00	-	WART	1991 Oct 20
+			-3:00	Arg	AR%sT	1999 Oct  3
+			-4:00	Arg	AR%sT	2000 Mar  3
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
+#
 # Tucuman (TM)
 Zone America/Argentina/Tucuman -4:20:52 - LMT	1894 Oct 31
 			-4:16:48 -	CMT	1920 May
@@ -291,7 +419,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 Jun  1
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # San Juan (SJ)
 Zone America/Argentina/San_Juan -4:34:04 - LMT	1894 Oct 31
@@ -304,7 +433,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 May 31
 			-4:00	-	WART	2004 Jul 25
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Jujuy (JY)
 Zone America/Argentina/Jujuy -4:21:12 -	LMT	1894 Oct 31
@@ -318,7 +448,8 @@
 			-3:00	1:00	ARST	1992
 			-3:00	Arg	AR%sT	1999 Oct  3
 			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Catamarca (CT), Chubut (CH)
 Zone America/Argentina/Catamarca -4:23:08 - LMT	1894 Oct 31
@@ -331,7 +462,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 Jun  1
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Mendoza (MZ)
 Zone America/Argentina/Mendoza -4:35:16 - LMT	1894 Oct 31
@@ -348,7 +480,25 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 May 23
 			-4:00	-	WART	2004 Sep 26
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
+#
+# San Luis (SL)
+Zone America/Argentina/San_Luis -4:25:24 - LMT	1894 Oct 31
+			-4:16:48 -	CMT	1920 May
+			-4:00	-	ART	1930 Dec
+			-4:00	Arg	AR%sT	1969 Oct  5
+			-3:00	Arg	AR%sT	1990
+			-3:00	1:00	ARST	1990 Mar 14
+			-4:00	-	WART	1990 Oct 15
+			-4:00	1:00	WARST	1991 Mar  1
+			-4:00	-	WART	1991 Jun  1
+			-3:00	-	ART	1999 Oct  3
+			-4:00	1:00	WARST	2000 Mar  3
+			-3:00	-	ART	2004 May 31
+			-4:00	-	WART	2004 Jul 25
+			-3:00	Arg	AR%sT	2008 Jan 21
+			-3:00	-	ART
 #
 # Santa Cruz (SC)
 Zone America/Argentina/Rio_Gallegos -4:36:52 - LMT 1894 Oct 31
@@ -359,7 +509,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 Jun  1
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Tierra del Fuego, Antartida e Islas del Atlantico Sur (TF)
 Zone America/Argentina/Ushuaia -4:33:12 - LMT 1894 Oct 31
@@ -370,7 +521,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 May 30
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 
 # Aruba
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
@@ -456,12 +608,86 @@
 # Brazil will start DST on 2007-10-14 00:00 and end on 2008-02-17 00:00:
 # http://www.mme.gov.br/site/news/detail.do;jsessionid=BBA06811AFCAAC28F0285210913513DA?newsId=13975
 
+# From Paul Schulze (2008-06-24):
+# ...by law number 11.662 of April 24, 2008 (published in the "Diario
+# Oficial da Uniao"...) in Brazil there are changes in the timezones,
+# effective today (00:00am at June 24, 2008) as follows:
+#
+# a) The timezone UTC+5 is e[x]tinguished, with all the Acre state and the
+# part of the Amazonas state that had this timezone now being put to the
+# timezone UTC+4
+# b) The whole Para state now is put at timezone UTC+3, instead of just
+# part of it, as was before.
+#
+# This change follows a proposal of senator Tiao Viana of Acre state, that
+# proposed it due to concerns about open television channels displaying
+# programs inappropriate to youths in the states that had the timezone
+# UTC+5 too early in the night. In the occasion, some more corrections
+# were proposed, trying to unify the timezones of any given state. This
+# change modifies timezone rules defined in decree 2.784 of 18 June,
+# 1913.
+
+# From Rodrigo Severo (2008-06-24):
+# Just correcting the URL:
+# 
+# https://www.in.gov.br/imprensa/visualiza/index.jsp?jornal=3Ddo&secao=3D1&pagina=3D1&data=3D25/04/2008
+# 
+#
+# As a result of the above Decree I believe the America/Rio_Branco
+# timezone shall be modified from UTC-5 to UTC-4 and a new timezone shall
+# be created to represent the the west side of the Para State. I
+# suggest this new timezone be called Santarem as the most
+# important/populated city in the affected area.
+#
+# This new timezone would be the same as the Rio_Branco timezone up to
+# the 2008/06/24 change which would be to UTC-3 instead of UTC-4.
+
+# From Alex Krivenyshev (2008-06-24):
+# This is a quick reference page for New and Old Brazil Time Zones map.
+# 
+# http://www.worldtimezone.com/brazil-time-new-old.php
+# 
+#
+# - 4 time zones replaced by 3 time zones-eliminating time zone UTC- 05
+# (state Acre and the part of the Amazonas will be UTC/GMT- 04) - western
+# part of Par state is moving to one timezone UTC- 03 (from UTC -04).
+
 # From Paul Eggert (2002-10-10):
 # The official decrees referenced below are mostly taken from
 # 
 # Decretos sobre o Horario de Verao no Brasil
 # .
 
+# From Steffen Thorsen (2008-08-29):
+# As announced by the government and many newspapers in Brazil late
+# yesterday, Brazil will start DST on 2008-10-19 (need to change rule) and
+# it will end on 2009-02-15 (current rule for Brazil is fine). Based on
+# past years experience with the elections, there was a good chance that
+# the start was postponed to November, but it did not happen this year.
+#
+# It has not yet been posted to http://pcdsh01.on.br/DecHV.html
+#
+# An official page about it:
+# 
+# http://www.mme.gov.br/site/news/detail.do?newsId=16722
+# 
+# Note that this link does not always work directly, but must be accessed
+# by going to
+# 
+# http://www.mme.gov.br/first
+# 
+#
+# One example link that works directly:
+# 
+# http://jornale.com.br/index.php?option=com_content&task=view&id=13530&Itemid=54
+# (Portuguese)
+# 
+#
+# We have a written a short article about it as well:
+# 
+# http://www.timeanddate.com/news/time/brazil-dst-2008-2009.html
+# 
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 # Decree 20,466 (1931-10-01)
 # Decree 21,896 (1932-01-10)
@@ -578,13 +804,13 @@
 Rule	Brazil	2000	2001	-	Oct	Sun>=8	 0:00	1:00	S
 Rule	Brazil	2001	2006	-	Feb	Sun>=15	 0:00	0	-
 # Decree 4,399 (2002-10-01) repeals DST in AL, CE, MA, PB, PE, PI, RN, SE.
-# 
+# 4,399
 Rule	Brazil	2002	only	-	Nov	 3	 0:00	1:00	S
 # Decree 4,844 (2003-09-24; corrected 2003-09-26) repeals DST in BA, MT, TO.
-# 
+# 4,844
 Rule	Brazil	2003	only	-	Oct	19	 0:00	1:00	S
 # Decree 5,223 (2004-10-01) reestablishes DST in MT.
-# 
+# 5,223
 Rule	Brazil	2004	only	-	Nov	 2	 0:00	1:00	S
 # Decree 5,539 (2005-09-19),
 # adopted by the same states as before.
@@ -593,16 +819,36 @@
 # adopted by the same states as before.
 Rule	Brazil	2006	only	-	Nov	 5	 0:00	1:00	S
 Rule	Brazil	2007	only	-	Feb	25	 0:00	0	-
-# (Decree number not yet known)
-# http://www.brasil.gov.br/noticias/ultimas_noticias/horario_verao070920/
-# (2007-09-20) after a heads-up from Steffen Thorsen:
-Rule	Brazil	2007	max	-	Oct	Sun>=8	 0:00	1:00	S
-Rule	Brazil	2008	max	-	Feb	Sun>=15	 0:00	0	-
+# Decree 6,212 (2007-09-26),
+# adopted by the same states as before.
+Rule	Brazil	2007	only	-	Oct	Sun>=8	 0:00	1:00	S
+# From Frederico A. C. Neves (2008-09-10):
+# Acording to this decree
+# 
+# http://www.planalto.gov.br/ccivil_03/_Ato2007-2010/2008/Decreto/D6558.htm
+# 
+# [t]he DST period in Brazil now on will be from the 3rd Oct Sunday to the
+# 3rd Feb Sunday. There is an exception on the return date when this is
+# the Carnival Sunday then the return date will be the next Sunday...
+Rule	Brazil	2008	max	-	Oct	Sun>=15	0:00	1:00	S
+Rule	Brazil	2008	2011	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2012	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2013	2014	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2015	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2016	2022	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2023	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2024	2025	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2026	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2027	2033	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2034	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2035	2036	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2037	only	-	Feb	Sun>=22	0:00	0	-
+# From Arthur David Olson (2008-09-29):
+# The next is wrong in some years but is better than nothing.
+Rule	Brazil	2038	max	-	Feb	Sun>=15	0:00	0	-
+
 # The latest ruleset listed above says that the following states observe DST:
 # DF, ES, GO, MG, MS, MT, PR, RJ, RS, SC, SP.
-# For dates after mid-2008, the above rules with TO="max" are guesses
-# and are quite possibly wrong, but are more likely than no DST at all.
-
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 #
@@ -629,6 +875,13 @@
 			-3:00	Brazil	BR%sT	1988 Sep 12
 			-3:00	-	BRT
 #
+# west Para (PA)
+# West Para includes Altamira, Oribidos, Prainha, Oriximina, and Santarem.
+Zone America/Santarem	-3:38:48 -	LMT	1914
+			-4:00	Brazil	AM%sT	1988 Sep 12
+			-4:00	-	AMT	2008 Jun 24 00:00
+			-3:00	-	BRT
+#
 # Maranhao (MA), Piaui (PI), Ceara (CE), Rio Grande do Norte (RN),
 # Paraiba (PB)
 Zone America/Fortaleza	-2:34:00 -	LMT	1914
@@ -691,8 +944,7 @@
 			-4:00	-	AMT	2004 Oct  1
 			-4:00	Brazil	AM%sT
 #
-# west Para (PA), Rondonia (RO)
-# West Para includes Altamira, Oribidos, Prainha, Oriximina, and Santarem.
+# Rondonia (RO)
 Zone America/Porto_Velho -4:15:36 -	LMT	1914
 			-4:00	Brazil	AM%sT	1988 Sep 12
 			-4:00	-	AMT
@@ -719,13 +971,14 @@
 			-5:00	Brazil	AC%sT	1988 Sep 12
 			-5:00	-	ACT	1993 Sep 28
 			-5:00	Brazil	AC%sT	1994 Sep 22
-			-5:00	-	ACT
+			-5:00	-	ACT	2008 Jun 24 00:00
+			-4:00	-	AMT
 #
 # Acre (AC)
 Zone America/Rio_Branco	-4:31:12 -	LMT	1914
 			-5:00	Brazil	AC%sT	1988 Sep 12
-			-5:00	-	ACT
-
+			-5:00	-	ACT	2008 Jun 24 00:00
+			-4:00	-	AMT
 
 # Chile
 
@@ -759,6 +1012,26 @@
 # America/Santiago.  The pre-1980 Pacific/Easter data are dubious,
 # but we have no other source.
 
+# From German Poo-Caaman~o (2008-03-03):
+# Due to drought, Chile extends Daylight Time in three weeks.  This
+# is one-time change (Saturday 3/29 at 24:00 for America/Santiago
+# and Saturday 3/29 at 22:00 for Pacific/Easter)
+# The Supreme Decree is located at 
+# 
+# http://www.shoa.cl/servicios/supremo316.pdf
+# 
+# and the instructions for 2008 are located in:
+# 
+# http://www.horaoficial.cl/cambio.htm
+# .
+
+# From Jose Miguel Garrido (2008-03-05):
+# ...
+# You could see the announces of the change on 
+# 
+# http://www.shoa.cl/noticias/2008/04hora/hora.htm
+# .
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Chile	1927	1932	-	Sep	 1	0:00	1:00	S
 Rule	Chile	1928	1932	-	Apr	 1	0:00	0	-
@@ -789,7 +1062,11 @@
 Rule	Chile	1998	only	-	Sep	27	4:00u	1:00	S
 Rule	Chile	1999	only	-	Apr	 4	3:00u	0	-
 Rule	Chile	1999	max	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	2000	max	-	Mar	Sun>=9	3:00u	0	-
+Rule	Chile	2000	2007	-	Mar	Sun>=9	3:00u	0	-
+# N.B.: the end of March 29 in Chile is March 30 in Universal time,
+# which is used below in specifying the transition.
+Rule	Chile	2008	only	-	Mar	30	3:00u	0	-
+Rule	Chile	2009	max	-	Mar	Sun>=9	3:00u	0	-
 # IATA SSIM anomalies: (1992-02) says 1992-03-14;
 # (1996-09) says 1998-03-08.  Ignore these.
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
Index: asia
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/asia,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/asia -L share/zoneinfo/asia -u -r1.4 -r1.5
--- share/zoneinfo/asia
+++ share/zoneinfo/asia
@@ -1,4 +1,4 @@
-# @(#)asia	8.14
+# @(#)asia	8.24
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -229,6 +229,28 @@
 # (could be true), for the moment I am assuming that those two
 # counties are mistakes in the astro.com data.
 
+# From Paul Eggert (2008-02-11):
+# I just now checked Google News for western news sources that talk
+# about China's single time zone, and couldn't find anything before 1986
+# talking about China being in one time zone.  (That article was: Jim
+# Mann, "A clumsy embrace for another western custom: China on daylight
+# time--sort of", Los Angeles Times, 1986-05-05.  By the way, this
+# article confirms the tz database's data claiming that China began
+# observing daylight saving time in 1986.
+#
+# From Thomas S. Mullaney (2008-02-11):
+# I think you're combining two subjects that need to treated 
+# separately: daylight savings (which, you're correct, wasn't 
+# implemented until the 1980s) and the unified time zone centered near 
+# Beijing (which was implemented in 1949). Briefly, there was also a 
+# "Lhasa Time" in Tibet and "Urumqi Time" in Xinjiang. The first was 
+# ceased, and the second eventually recognized (again, in the 1980s).
+#
+# From Paul Eggert (2008-06-30):
+# There seems to be a good chance China switched to a single time zone in 1949
+# rather than in 1980 as Shanks & Pottenger have it, but we don't have a
+# reliable documentary source saying so yet, so for now we still go with
+# Shanks & Pottenger.
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 # Changbai Time ("Long-white Time", Long-white = Heilongjiang area)
@@ -446,13 +468,13 @@
 
 # India
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Calcutta	5:53:28 -	LMT	1880	# Kolkata
+Zone	Asia/Kolkata	5:53:28 -	LMT	1880	# Kolkata
 			5:53:20	-	HMT	1941 Oct    # Howrah Mean Time?
 			6:30	-	BURT	1942 May 15 # Burma Time
 			5:30	-	IST	1942 Sep
 			5:30	1:00	IST	1945 Oct 15
 			5:30	-	IST
-# The following are like Asia/Calcutta:
+# The following are like Asia/Kolkata:
 #	Andaman Is
 #	Lakshadweep (Laccadive, Minicoy and Amindivi Is)
 #	Nicobar Is
@@ -660,6 +682,21 @@
 #
 # So we'll ignore the Economist's claim.
 
+# From Steffen Thorsen (2008-03-10):
+# The cabinet in Iraq abolished DST last week, according to the following
+# news sources (in Arabic):
+# 
+# http://www.aljeeran.net/wesima_articles/news-20080305-98602.html
+# 
+# 
+# http://www.aswataliraq.info/look/article.tpl?id=2047&IdLanguage=17&IdPublication=4&NrArticle=71743&NrIssue=1&NrSection=10
+# 
+#
+# We have published a short article in English about the change:
+# 
+# http://www.timeanddate.com/news/time/iraq-dumps-daylight-saving.html
+# 
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Iraq	1982	only	-	May	1	0:00	1:00	D
 Rule	Iraq	1982	1984	-	Oct	1	0:00	0	S
@@ -670,8 +707,8 @@
 # IATA SSIM (1991/1996) says Apr 1 12:01am UTC; guess the `:01' is a typo.
 # Shanks & Pottenger say Iraq did not observe DST 1992/1997; ignore this.
 #
-Rule	Iraq	1991	max	-	Apr	 1	3:00s	1:00	D
-Rule	Iraq	1991	max	-	Oct	 1	3:00s	0	S
+Rule	Iraq	1991	2007	-	Apr	 1	3:00s	1:00	D
+Rule	Iraq	1991	2007	-	Oct	 1	3:00s	0	S
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Baghdad	2:57:40	-	LMT	1890
 			2:57:36	-	BMT	1918	    # Baghdad Mean Time?
@@ -1361,6 +1398,42 @@
 # They decided not to adopt daylight-saving time....
 # http://www.mongolnews.mn/index.php?module=unuudur&sec=view&id=15742
 
+# From Deborah Goldsmith (2008-03-30):
+# We received a bug report claiming that the tz database UTC offset for
+# Asia/Choibalsan (GMT+09:00) is incorrect, and that it should be GMT
+# +08:00 instead. Different sources appear to disagree with the tz
+# database on this, e.g.:
+#
+# 
+# http://www.timeanddate.com/worldclock/city.html?n=1026
+# 
+# 
+# http://www.worldtimeserver.com/current_time_in_MN.aspx
+# 
+#
+# both say GMT+08:00.
+
+# From Steffen Thorsen (2008-03-31):
+# eznis airways, which operates several domestic flights, has a flight
+# schedule here:
+# 
+# http://www.eznis.com/Container.jsp?id=112
+# 
+# (click the English flag for English)
+#
+# There it appears that flights between Choibalsan and Ulaanbatar arrive
+# about 1:35 - 1:50 hours later in local clock time, no matter the
+# direction, while Ulaanbaatar-Khvod takes 2 hours in the Eastern
+# direction and 3:35 back, which indicates that Ulaanbatar and Khvod are
+# in different time zones (like we know about), while Choibalsan and
+# Ulaanbatar are in the same time zone (correction needed).
+
+# From Arthur David Olson (2008-05-19):
+# Assume that Choibalsan is indeed offset by 8:00.
+# XXX--in the absence of better information, assume that transition
+# was at the start of 2008-03-31 (the day of Steffen Thorsen's report);
+# this is almost surely wrong.
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Mongol	1983	1984	-	Apr	1	0:00	1:00	S
 Rule	Mongol	1983	only	-	Oct	1	0:00	0	-
@@ -1396,7 +1469,8 @@
 Zone	Asia/Choibalsan	7:38:00 -	LMT	1905 Aug
 			7:00	-	ULAT	1978
 			8:00	-	ULAT	1983 Apr
-			9:00	Mongol	CHO%sT	# Choibalsan Time
+			9:00	Mongol	CHO%sT	2008 Mar 31 # Choibalsan Time
+			8:00	Mongol	CHO%sT
 
 # Nepal
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
@@ -1446,10 +1520,45 @@
 # The minister told a news conference that the experiment had rather
 # shown 8 per cent higher consumption of electricity.
 
+# From Alex Krivenyshev (2008-05-15):
+# 
+# Here is an article that Pakistan plan to introduce Daylight Saving Time 
+# on June 1, 2008 for 3 months.
+# 
+# "... The federal cabinet on Wednesday announced a new conservation plan to help 
+# reduce load shedding by approving the closure of commercial centres at 9pm and 
+# moving clocks forward by one hour for the next three months. 
+# ...."
+# 
+# 
+# http://www.worldtimezone.net/dst_news/dst_news_pakistan01.html
+# 
+# OR
+# 
+# http://www.dailytimes.com.pk/default.asp?page=2008%5C05%5C15%5Cstory_15-5-2008_pg1_4
+# 
+
+# From Arthur David Olson (2008-05-19):
+# XXX--midnight transitions is a guess; 2008 only is a guess.
+
+# From Alexander Krivenyshev (2008-08-28):
+# Pakistan government has decided to keep the watches one-hour advanced
+# for another 2 months--plan to return to Standard Time on October 31
+# instead of August 31.
+#
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_pakistan02.html
+# 
+# OR
+# 
+# http://dailymailnews.com/200808/28/news/dmbrn03.html
+# 
 
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule Pakistan	2002	only	-	Apr	Sun>=2	0:01	1:00	S
 Rule Pakistan	2002	only	-	Oct	Sun>=2	0:01	0	-
+Rule Pakistan	2008	only	-	Jun	1	0:00	1:00	S
+Rule Pakistan	2008	only	-	Nov	1	0:00	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Karachi	4:28:12 -	LMT	1907
 			5:30	-	IST	1942 Sep
@@ -1569,6 +1678,23 @@
 # For lack of better information, predict that future changes will be
 # the 2nd Thursday of September at 02:00.
 
+# From Alexander Krivenyshev (2008-08-28):
+# Here is an article, that Mideast running on different clocks at Ramadan.
+#
+# Gaza Strip (as Egypt) ended DST at midnight Thursday (Aug 28, 2008), while
+# the West Bank will end Daylight Saving Time at midnight Sunday (Aug 31, 2008).
+#
+# 
+# http://www.guardian.co.uk/world/feedarticle/7759001
+# 
+# 
+# http://www.abcnews.go.com/International/wireStory?id=5676087
+# 
+# or
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_gazastrip01.html
+# 
+
 # The rules for Egypt are stolen from the `africa' file.
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule EgyptAsia	1957	only	-	May	10	0:00	1:00	S
@@ -1584,7 +1710,8 @@
 Rule Palestine	2005	only	-	Oct	 4	2:00	0	-
 Rule Palestine	2006	max	-	Apr	 1	0:00	1:00	S
 Rule Palestine	2006	only	-	Sep	22	0:00	0	-
-Rule Palestine	2007	max	-	Sep	Thu>=8	2:00	0	-
+Rule Palestine	2007	only	-	Sep	Thu>=8	2:00	0	-
+Rule Palestine	2008	max	-	Aug	lastThu	2:00	0	-
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Gaza	2:17:52	-	LMT	1900 Oct
@@ -1687,7 +1814,7 @@
 # kept their clocks set five and a half hours ahead of Greenwich Mean
 # Time (GMT), in line with neighbor India.
 # From Paul Eggert (2006-04-18):
-# People who live in regions under Tamil control can use TZ='Asia/Calcutta',
+# People who live in regions under Tamil control can use [TZ='Asia/Kolkata'],
 # as that zone has agreed with the Tamil areas since our cutoff date of 1970.
 
 # From K Sethu (2006-04-25):
@@ -1777,9 +1904,7 @@
 # From Paul Eggert (2007-03-29):
 # Today the AP reported "Syria will switch to summertime at midnight Thursday."
 # http://www.iht.com/articles/ap/2007/03/29/africa/ME-GEN-Syria-Time-Change.php
-# For lack of better info, assume the rule changed to "last Friday in March"
-# this year.
-Rule	Syria	2007	max	-	Mar	lastFri	0:00	1:00	S
+Rule	Syria	2007	only	-	Mar	lastFri	0:00	1:00	S
 # From Jesper Norgard (2007-10-27):
 # The sister center ICARDA of my work CIMMYT is confirming that Syria DST will
 # not take place 1.st November at 0:00 o'clock but 1.st November at 24:00 or
@@ -1801,10 +1926,52 @@
 # Council of Ministers also approved the commencement of work on 
 # identifying the winter time as of Friday, 2/11/2007 where the 60th 
 # minute delay at midnight Thursday 1/11/2007.
+Rule	Syria	2007	only	-	Nov	 Fri>=1	0:00	0	-
+
+# From Stephen Colebourne (2008-03-17):
+# For everyone's info, I saw an IATA time zone change for [Syria] for
+# this month (March 2008) in the last day or so...This is the data IATA
+# are now using:
+# Country     Time Standard   --- DST Start ---   --- DST End ---  DST
+# Name        Zone Variation   Time    Date        Time    Date
+# Variation
+# Syrian Arab
+# Republic    SY    +0200      2200  03APR08       2100  30SEP08   +0300
+#                              2200  02APR09       2100  30SEP09   +0300
+#                              2200  01APR10       2100  30SEP10   +0300
+
+# From Arthur David Olson (2008-03-17):
+# Here's a link to English-language coverage by the Syrian Arab News
+# Agency (SANA)...
+# 
+# http://www.sana.sy/eng/21/2008/03/11/165173.htm
+# ...which reads (in part) "The Cabinet approved the suggestion of the
+# Ministry of Electricity to begin daylight savings time on Friday April
+# 4th, advancing clocks one hour ahead on midnight of Thursday April 3rd."
+# Since Syria is two hours east of UTC, the 2200 and 2100 transition times
+# shown above match up with midnight in Syria.
+
+# From Arthur David Olson (2008-03-18):
+# My buest guess at a Syrian rule is "the Friday nearest April 1";
+# coding that involves either using a "Mar Fri>=29" construct that old time zone
+# compilers can't handle  or having multiple Rules (a la Israel).
+# For now, use "Apr Fri>=1", and go with IATA on a uniform Sep 30 end.
+
+# From Steffen Thorsen (2008-10-07):
+# Syria has now officially decided to end DST on 2008-11-01 this year,
+# according to the following article in the Syrian Arab News Agency (SANA).
+#
+# The article is in Arabic, and seems to tell that they will go back to
+# winter time on 2008-11-01 at 00:00 local daylight time (delaying/setting
+# clocks back 60 minutes).
 #
-# From Arthur David Olson (2007-10-30):
-# My best guess for the future is first Friday in November.
-Rule	Syria	2007	max	-	Nov	 Fri>=1	0:00	0	-
+# 
+# http://sana.sy/ara/2/2008/10/07/195459.htm
+# 
+
+Rule	Syria	2008	max	-	Apr	Fri>=1	0:00	1:00	S
+Rule	Syria	2008	max	-	Nov	1	0:00	0	-
+
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Damascus	2:25:12 -	LMT	1920	# Dimashq
 			2:00	Syria	EE%sT
@@ -1858,13 +2025,13 @@
 
 # Vietnam
 
-# From Paul Eggert (1993-11-18):
-# Saigon's official name is Thanh-Pho Ho Chi Minh, but it's too long.
-# We'll stick with the traditional name for now.
+# From Arthur David Olson (2008-03-18):
+# The English-language name of Vietnam's most populous city is "Ho Chi Min City";
+# we use Ho_Chi_Minh below to avoid a name of more than 14 characters.
 
 # From Shanks & Pottenger:
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Saigon	7:06:40 -	LMT	1906 Jun  9
+Zone	Asia/Ho_Chi_Minh	7:06:40 -	LMT	1906 Jun  9
 			7:06:20	-	SMT	1911 Mar 11 0:01 # Saigon MT?
 			7:00	-	ICT	1912 May
 			8:00	-	ICT	1931 May
Index: europe
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/europe,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/europe -L share/zoneinfo/europe -u -r1.4 -r1.5
--- share/zoneinfo/europe
+++ share/zoneinfo/europe
@@ -1,4 +1,4 @@
-# @(#)europe	8.12
+# @(#)europe	8.18
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -457,7 +457,7 @@
 Rule	EU	1981	max	-	Mar	lastSun	 1:00u	1:00	S
 Rule	EU	1996	max	-	Oct	lastSun	 1:00u	0	-
 # The most recent directive covers the years starting in 2002.  See:
-# 
 # Directive 2000/84/EC of the European Parliament and of the Council
 # of 19 January 2001 on summer-time arrangements.
 # 
@@ -480,9 +480,48 @@
 Rule	C-Eur	1942	only	-	Nov	 2	 2:00s	0	-
 Rule	C-Eur	1943	only	-	Mar	29	 2:00s	1:00	S
 Rule	C-Eur	1943	only	-	Oct	 4	 2:00s	0	-
-Rule	C-Eur	1944	only	-	Apr	 3	 2:00s	1:00	S
+Rule	C-Eur	1944	1945	-	Apr	Mon>=1	 2:00s	1:00	S
 # Whitman gives 1944 Oct 7; go with Shanks & Pottenger.
 Rule	C-Eur	1944	only	-	Oct	 2	 2:00s	0	-
+# From Jesper Norgaard Welen (2008-07-13):
+#
+# I found what is probably a typo of 2:00 which should perhaps be 2:00s
+# in the C-Eur rule from tz database version 2008d (this part was
+# corrected in version 2008d). The circumstancial evidence is simply the
+# tz database itself, as seen below:
+#
+# Zone Europe/Paris 0:09:21 - LMT 1891 Mar 15  0:01
+#    0:00 France WE%sT 1945 Sep 16  3:00
+#
+# Zone Europe/Monaco 0:29:32 - LMT 1891 Mar 15
+#    0:00 France WE%sT 1945 Sep 16 3:00
+#
+# Zone Europe/Belgrade 1:22:00 - LMT 1884
+#    1:00 1:00 CEST 1945 Sep 16  2:00s
+#
+# Rule France 1945 only - Sep 16  3:00 0 -
+# Rule Belgium 1945 only - Sep 16  2:00s 0 -
+# Rule Neth 1945 only - Sep 16 2:00s 0 -
+#
+# The rule line to be changed is:
+#
+# Rule C-Eur 1945 only - Sep 16  2:00 0 -
+#
+# It seems that Paris, Monaco, Rule France, Rule Belgium all agree on
+# 2:00 standard time, e.g. 3:00 local time.  However there are no
+# countries that use C-Eur rules in September 1945, so the only items
+# affected are apparently these ficticious zones that translates acronyms
+# CET and MET:
+#
+# Zone CET  1:00 C-Eur CE%sT
+# Zone MET  1:00 C-Eur ME%sT
+#
+# It this is right then the corrected version would look like:
+#
+# Rule C-Eur 1945 only - Sep 16  2:00s 0 -
+#
+# A small step for mankind though 8-)
+Rule	C-Eur	1945	only	-	Sep	16	 2:00s	0	-
 Rule	C-Eur	1977	1980	-	Apr	Sun>=1	 2:00s	1:00	S
 Rule	C-Eur	1977	only	-	Sep	lastSun	 2:00s	0	-
 Rule	C-Eur	1978	only	-	Oct	 1	 2:00s	0	-
@@ -725,7 +764,8 @@
 Zone	Europe/Sofia	1:33:16 -	LMT	1880
 			1:56:56	-	IMT	1894 Nov 30 # Istanbul MT?
 			2:00	-	EET	1942 Nov  2  3:00
-			1:00	C-Eur	CE%sT	1945 Apr  2  3:00
+			1:00	C-Eur	CE%sT	1945
+			1:00	-	CET	1945 Apr 2 3:00
 			2:00	-	EET	1979 Mar 31 23:00
 			2:00	Bulg	EE%sT	1982 Sep 26  2:00
 			2:00	C-Eur	EE%sT	1991
@@ -1093,33 +1133,40 @@
 # [See tz-link.htm for the URL.]
 
 # From Joerg Schilling (2002-10-23):
-# In 1945, Berlin was switched to Moscow Summer time (GMT+4) by 
+# In 1945, Berlin was switched to Moscow Summer time (GMT+4) by
+# 
 # General [Nikolai] Bersarin.
 
 # From Paul Eggert (2003-03-08):
 # 
+# http://www.parlament-berlin.de/pds-fraktion.nsf/727459127c8b66ee8525662300459099/defc77cb784f180ac1256c2b0030274b/$FILE/bersarint.pdf
+# 
 # says that Bersarin issued an order to use Moscow time on May 20.
 # However, Moscow did not observe daylight saving in 1945, so
 # this was equivalent to CEMT (GMT+3), not GMT+4.
 
 
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Germany	1945	only	-	Apr	 2	2:00s	1:00	S
-Rule	Germany	1945	only	-	May	24	2:00	2:00	M # Midsummer
-Rule	Germany	1945	only	-	Sep	24	3:00	1:00	S
-Rule	Germany	1945	only	-	Nov	18	2:00s	0	-
 Rule	Germany	1946	only	-	Apr	14	2:00s	1:00	S
 Rule	Germany	1946	only	-	Oct	 7	2:00s	0	-
 Rule	Germany	1947	1949	-	Oct	Sun>=1	2:00s	0	-
-Rule	Germany	1947	only	-	Apr	 6	2:00s	1:00	S
+# http://www.ptb.de/de/org/4/44/441/salt.htm says the following transition
+# occurred at 3:00 MEZ, not the 2:00 MEZ given in Shanks & Pottenger.
+# Go with the PTB.
+Rule	Germany	1947	only	-	Apr	 6	3:00s	1:00	S
 Rule	Germany	1947	only	-	May	11	2:00s	2:00	M
 Rule	Germany	1947	only	-	Jun	29	3:00	1:00	S
 Rule	Germany	1948	only	-	Apr	18	2:00s	1:00	S
 Rule	Germany	1949	only	-	Apr	10	2:00s	1:00	S
+
+Rule SovietZone	1945	only	-	May	24	2:00	2:00	M # Midsummer
+Rule SovietZone	1945	only	-	Sep	24	3:00	1:00	S
+Rule SovietZone	1945	only	-	Nov	18	2:00s	0	-
+
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Europe/Berlin	0:53:28 -	LMT	1893 Apr
-			1:00	C-Eur	CE%sT	1945 Apr 2 2:00
+			1:00	C-Eur	CE%sT	1945 May 24 2:00
+			1:00 SovietZone	CE%sT	1946
 			1:00	Germany	CE%sT	1980
 			1:00	EU	CE%sT
 
@@ -1196,7 +1243,7 @@
 Zone	Europe/Budapest	1:16:20 -	LMT	1890 Oct
 			1:00	C-Eur	CE%sT	1918
 			1:00	Hungary	CE%sT	1941 Apr  6  2:00
-			1:00	C-Eur	CE%sT	1945 May  1 23:00
+			1:00	C-Eur	CE%sT	1945
 			1:00	Hungary	CE%sT	1980 Sep 28  2:00s
 			1:00	EU	CE%sT
 
@@ -2113,7 +2160,8 @@
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Europe/Belgrade	1:22:00	-	LMT	1884
 			1:00	-	CET	1941 Apr 18 23:00
-			1:00	C-Eur	CE%sT	1945 May  8  2:00s
+			1:00	C-Eur	CE%sT	1945
+			1:00	-	CET	1945 May 8 2:00s
 			1:00	1:00	CEST	1945 Sep 16  2:00s
 # Metod Kozelj reports that the legal date of
 # transition to EU rules was 1982-11-27, for all of Yugoslavia at the time.
@@ -2305,6 +2353,27 @@
 # (on a non-government server though) describing dates between 2002 and 2006:
 # http://www.alomaliye.com/bkk_2002_3769.htm
 
+# From Sue Williams (2008-08-11):
+# I spotted this news article about a potential change in Turkey.
+#
+# 
+# http://www.hurriyet.com.tr/english/domestic/9626174.asp?scr=1
+# 
+
+# From Sue Williams (2008-08-20):
+# This article says that around the end of March 2011, Turkey wants to
+# adjust the clocks forward by 1/2 hour and stay that way permanently.
+# The article indicates that this is a change in timezone offset in addition
+# to stopping observance of DST.
+# This proposal has not yet been approved.
+#
+# Read more here...
+#
+# Turkey to abandon daylight saving time in 2011
+# 
+# http://www.turkishdailynews.com.tr/article.php?enewsid=112989
+# 
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Turkey	1916	only	-	May	 1	0:00	1:00	S
 Rule	Turkey	1916	only	-	Oct	 1	0:00	0	-
Index: northamerica
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/northamerica,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/northamerica -L share/zoneinfo/northamerica -u -r1.4 -r1.5
--- share/zoneinfo/northamerica
+++ share/zoneinfo/northamerica
@@ -1,4 +1,4 @@
-# @(#)northamerica	8.20
+# @(#)northamerica	8.24
 # 
 
 # also includes Central America and the Caribbean
@@ -2076,8 +2076,8 @@
 # http://www.jonesbahamas.com/?c=45&a=10412
 
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Bahamas	1964	2006	-	Oct	lastSun	2:00	0	S
-Rule	Bahamas	1964	1986	-	Apr	lastSun	2:00	1:00	D
+Rule	Bahamas	1964	1975	-	Oct	lastSun	2:00	0	S
+Rule	Bahamas	1964	1975	-	Apr	lastSun	2:00	1:00	D
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	America/Nassau	-5:09:24 -	LMT	1912 Mar 2
 			-5:00	Bahamas	E%sT	1976
@@ -2205,6 +2205,52 @@
 # 
 # http://www.worldtimezone.com/dst_news/dst_news_cuba03.html
 
+# From Arthur David Olson (2008-03-09):
+# I'm in Maryland which is now observing United States Eastern Daylight
+# Time. At 9:44 local time I used RealPlayer to listen to
+# 
+# http://media.enet.cu/radioreloj
+# , a Cuban information station, and heard
+# the time announced as "ocho cuarenta y cuatro" ("eight forty-four"),
+# indicating that Cuba is still on standard time.
+
+# From Steffen Thorsen (2008-03-12):
+# It seems that Cuba will start DST on Sunday, 2007-03-16...
+# It was announced yesterday, according to this source (in Spanish):
+# 
+# http://www.nnc.cubaweb.cu/marzo-2008/cien-1-11-3-08.htm
+# 
+#
+# Some more background information is posted here:
+# 
+# http://www.timeanddate.com/news/time/cuba-starts-dst-march-16.html
+# 
+#
+# The article also says that Cuba has been observing DST since 1963,
+# while Shanks (and tzdata) has 1965 as the first date (except in the
+# 1940's). Many other web pages in Cuba also claim that it has been
+# observed since 1963, but with the exception of 1970 - an exception
+# which is not present in tzdata/Shanks. So there is a chance we need to
+# change some historic records as well.
+#
+# One example:
+# 
+# http://www.radiohc.cu/espanol/noticias/mar07/11mar/hor.htm
+# 
+
+# From Jesper Norgaard Welen (2008-03-13):
+# The Cuban time change has just been confirmed on the most authoritative
+# web site, the Granma.  Please check out
+# 
+# http://www.granma.cubaweb.cu/2008/03/13/nacional/artic10.html
+# 
+#
+# Basically as expected after Steffen Thorsens information, the change
+# will take place midnight between Saturday and Sunday.
+
+# From Arthur David Olson (2008-03-12):
+# Assume Sun>=15 (third Sunday) going forward.
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Cuba	1928	only	-	Jun	10	0:00	1:00	D
 Rule	Cuba	1928	only	-	Oct	10	0:00	0	S
@@ -2236,7 +2282,8 @@
 Rule	Cuba	1998	2003	-	Oct	lastSun	0:00s	0	S
 Rule	Cuba	2000	2006	-	Apr	Sun>=1	0:00s	1:00	D
 Rule	Cuba	2006	max	-	Oct	lastSun	0:00s	0	S
-Rule	Cuba	2007	max	-	Mar	Sun>=8	0:00s	1:00	D
+Rule	Cuba	2007	only	-	Mar	Sun>=8	0:00s	1:00	D
+Rule	Cuba	2008	max	-	Mar	Sun>=15	0:00s	1:00	D
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	America/Havana	-5:29:28 -	LMT	1890

From laffer1 at midnightbsd.org  Thu Jan  1 17:52:48 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 17:52:48 -0500 (EST)
Subject: [Midnightbsd-cvs] src: UPDATING: timezones are fun
Message-ID: <200901012252.n01Mqmck050859@stargazer.midnightbsd.org>

Log Message:
-----------
timezones are fun

Modified Files:
--------------
    src:
        UPDATING (r1.46 -> r1.47)

-------------- next part --------------
Index: UPDATING
===================================================================
RCS file: /home/cvs/src/UPDATING,v
retrieving revision 1.46
retrieving revision 1.47
diff -L UPDATING -L UPDATING -u -r1.46 -r1.47
--- UPDATING
+++ UPDATING
@@ -3,6 +3,9 @@
 Items affecting the mports and packages system can be found in
 /usr/mports/UPDATING. 
 
+20080101:
+	Update time zone data to 2008i.
+
 20081231:
 	Correct a problem where bluetooth and netgraph sockets are not
 	properly initialized.

From laffer1 at midnightbsd.org  Thu Jan  1 18:28:15 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 18:28:15 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: lang/php5: work in progress..
Message-ID: <200901012328.n01NSFE9053770@stargazer.midnightbsd.org>

Log Message:
-----------
work in progress.. upgrade php to 5.2.8

Modified Files:
--------------
    mports/lang/php5:
        Makefile (r1.21 -> r1.22)
        Makefile.ext (r1.10 -> r1.11)
        distinfo (r1.9 -> r1.10)
    mports/lang/php5/files:
        patch-configure.in (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile.ext
===================================================================
RCS file: /home/cvs/mports/lang/php5/Makefile.ext,v
retrieving revision 1.10
retrieving revision 1.11
diff -L lang/php5/Makefile.ext -L lang/php5/Makefile.ext -u -r1.10 -r1.11
--- lang/php5/Makefile.ext
+++ lang/php5/Makefile.ext
@@ -74,6 +74,10 @@
 CONFIGURE_ARGS+=--enable-exif
 .endif
 
+.if ${PHP_MODNAME} == "filter"
+CONFIGURE_ARGS+=--enable-filter
+.endif
+
 .if ${PHP_MODNAME} == "ftp"
 CONFIGURE_ARGS+=--enable-ftp \
 		--with-openssl-dir=${OPENSSLBASE}
@@ -118,6 +122,10 @@
 CONFIGURE_ARGS+=--with-gmp=${LOCALBASE}
 .endif
 
+.if ${PHP_MODNAME} == "hash"
+CONFIGURE_ARGS+=--enable-hash
+.endif
+
 .if ${PHP_MODNAME} == "iconv"
 CONFIGURE_ARGS+=--with-iconv=${LOCALBASE} \
 		--with-iconv-dir=${LOCALBASE}
@@ -140,10 +148,13 @@
 .if ${PHP_MODNAME} == "interbase"
 CONFIGURE_ARGS+=--with-interbase=${LOCALBASE}
 
-USE_GCC=	3.4+
 USE_FIREBIRD=	yes
 .endif
 
+.if ${PHP_MODNAME} == "json"
+CONFIGURE_ARGS+=--enable-json
+.endif
+
 .if ${PHP_MODNAME} == "ldap"
 CONFIGURE_ARGS+=--with-ldap=${LOCALBASE}
 
@@ -224,8 +235,7 @@
 .endif
 
 .if ${PHP_MODNAME} == "openssl"
-CONFIGURE_ARGS+=--with-openssl=${OPENSSLBASE} \
-		--with-openssl-dir=${OPENSSLBASE}
+CONFIGURE_ARGS+=--with-openssl=${OPENSSLBASE}
 
 LDFLAGS+=	-L${OPENSSLLIB} -lcrypto -lssl
 USE_OPENSSL=	yes
@@ -260,7 +270,6 @@
 USE_PHP=	pdo
 USE_PHP_BUILD=	yes
 
-USE_GCC=	3.4+
 USE_FIREBIRD=	yes
 .endif
 
@@ -373,7 +382,6 @@
 		--with-libxml-dir=${LOCALBASE}
 
 USE_GNOME=	libxml2
-USE_GCC=	3.4+
 
 USE_PHP=	session
 USE_PHP_BUILD=	yes
@@ -490,6 +498,11 @@
 USE_PHP_BUILD=	yes
 .endif
 
+.if ${PHP_MODNAME} == "zip"
+CONFIGURE_ARGS+=--enable-zip \
+		--with-zlib-dir=/usr
+.endif
+
 .if ${PHP_MODNAME} == "zlib"
 CONFIGURE_ARGS+=--with-zlib=/usr
 .endif
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/lang/php5/Makefile,v
retrieving revision 1.21
retrieving revision 1.22
diff -L lang/php5/Makefile -L lang/php5/Makefile -u -r1.21 -r1.22
--- lang/php5/Makefile
+++ lang/php5/Makefile
@@ -7,8 +7,8 @@
 #
 
 PORTNAME=	php5
-PORTVERSION=	5.2.6
-PORTREVISION?=	4
+PORTVERSION=	5.2.8
+PORTREVISION?=	0
 CATEGORIES?=	lang devel www
 MASTER_SITES=	${MASTER_SITE_PHP:S/$/:release/}
 MASTER_SITE_SUBDIR=	distributions/:release
@@ -56,7 +56,7 @@
 .include 
 
 .if !defined(WITHOUT_SUHOSIN)
-PATCHFILES+=	suhosin-patch-${PORTVERSION}-0.9.6.2.patch.gz:suhosin
+PATCHFILES+=	suhosin-patch-5.2.7-0.9.6.3.patch.gz:suhosin
 PATCH_SITES+=	http://download.suhosin.org/:suhosin
 PATCH_DIST_STRIP=	-p1
 PLIST_SUB+=	SUHOSIN=""
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/lang/php5/distinfo,v
retrieving revision 1.9
retrieving revision 1.10
diff -L lang/php5/distinfo -L lang/php5/distinfo -u -r1.9 -r1.10
--- lang/php5/distinfo
+++ lang/php5/distinfo
@@ -1,9 +1,9 @@
-MD5 (php-5.2.6.tar.bz2) = 7380ffecebd95c6edb317ef861229ebd
-SHA256 (php-5.2.6.tar.bz2) = 1892b2dd50b56ae2c9aec027fcd9035b76673f113555bc2bc1007bab8ae4db81
-SIZE (php-5.2.6.tar.bz2) = 9571312
-MD5 (suhosin-patch-5.2.6-0.9.6.2.patch.gz) = f2ec986341a314c271259dbe4d940858
-SHA256 (suhosin-patch-5.2.6-0.9.6.2.patch.gz) = dfdae803778e6ed6854ea3ad2948bbfedbfffc5a32dbc75a657b99092a9cc5e4
-SIZE (suhosin-patch-5.2.6-0.9.6.2.patch.gz) = 22986
-MD5 (php-5.2.6-mail-header.patch) = eb26be2469a173a3476220342c5fcd58
-SHA256 (php-5.2.6-mail-header.patch) = 7e546c22a19386c4d93bebddfb64ace9447774f748070794c7c41419c5c474ac
-SIZE (php-5.2.6-mail-header.patch) = 3420
+MD5 (php-5.2.8.tar.bz2) = 8760a833cf10433d3e72271ab0d0eccf
+SHA256 (php-5.2.8.tar.bz2) = a70600e13410213a637f1c9825e9c0d45c64de8cefb1929f8f5aa761b20b2b67
+SIZE (php-5.2.8.tar.bz2) = 9827180
+MD5 (suhosin-patch-5.2.7-0.9.6.3.patch.gz) = d455c3dd5b652046dbac2951a58f64fa
+SHA256 (suhosin-patch-5.2.7-0.9.6.3.patch.gz) = 85e6262f53014e393977d1efed2d3a7e686767a07f96b14b2c3f126f694aee46
+SIZE (suhosin-patch-5.2.7-0.9.6.3.patch.gz) = 23125
+MD5 (php-5.2.8-mail-header.patch) = 74bf3a2a123c284f908c4f5483ebe886
+SHA256 (php-5.2.8-mail-header.patch) = 9bd306145153a371f619d89996cb329bdc36791b22a50daf4afe7cc69c46dccb
+SIZE (php-5.2.8-mail-header.patch) = 3381
Index: patch-configure.in
===================================================================
RCS file: /home/cvs/mports/lang/php5/files/patch-configure.in,v
retrieving revision 1.2
retrieving revision 1.3
diff -L lang/php5/files/patch-configure.in -L lang/php5/files/patch-configure.in -u -r1.2 -r1.3
--- lang/php5/files/patch-configure.in
+++ lang/php5/files/patch-configure.in
@@ -1,6 +1,6 @@
---- configure.in.orig	Mon Jun  4 08:08:43 2007
-+++ configure.in	Mon Jun  4 08:13:47 2007
-@@ -233,7 +233,6 @@
+--- configure.in.orig	2008-12-05 07:58:47.000000000 +0100
++++ configure.in	2008-12-05 08:02:26.000000000 +0100
+@@ -270,7 +270,6 @@
  dnl .
  dnl -------------------------------------------------------------------------
  
@@ -8,7 +8,7 @@
  PHP_HELP_SEPARATOR([SAPI modules:])
  PHP_SHLIB_SUFFIX_NAMES
  PHP_SAPI=default
-@@ -258,7 +257,6 @@
+@@ -295,7 +294,6 @@
  
  if test "$enable_maintainer_zts" = "yes"; then
    PTHREADS_ASSIGN_VARS
@@ -16,7 +16,7 @@
  fi
  
  divert(3)
-@@ -1123,7 +1121,7 @@
+@@ -1136,7 +1134,7 @@
  EXPANDED_DATADIR=$datadir
  EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
  EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
@@ -25,13 +25,13 @@
  
  exec_prefix=$old_exec_prefix
  libdir=$old_libdir
-@@ -1295,22 +1293,19 @@
+@@ -1344,22 +1342,19 @@
  INLINE_CFLAGS="$INLINE_CFLAGS $standard_libtool_flag"
  CXXFLAGS="$CXXFLAGS $standard_libtool_flag"
  
--all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_CLI_TARGET)"
+-all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_ZEND_EX) \$(PHP_CLI_TARGET)"
 -install_targets="$install_modules install-build install-headers install-programs $install_pear"
-+all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_CLI_TARGET) \$(PHP_CGI_TARGET)"
++all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_ZEND_EX) \$(PHP_CLI_TARGET) \$(PHP_CGI_TARGET)"
 +install_targets="$PHP_INSTALL_CLI_TARGET $PHP_INSTALL_CGI_TARGET $install_modules install-build install-headers install-programs $install_pear"
  
  case $PHP_SAPI in

From laffer1 at midnightbsd.org  Thu Jan  1 18:29:20 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 18:29:20 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: patch-main_safe_mode.c: remove outdated
	patch
Message-ID: <200901012329.n01NTKPF053844@stargazer.midnightbsd.org>

Log Message:
-----------
remove outdated patch

Removed Files:
-------------
    mports/lang/php5/files:
        patch-main_safe_mode.c

-------------- next part --------------
--- lang/php5/files/patch-main_safe_mode.c
+++ /dev/null
@@ -1,17 +0,0 @@
---- main/safe_mode.c.orig	2008-09-04 15:52:19.000000000 +0200
-+++ main/safe_mode.c	2008-09-04 15:52:35.000000000 +0200
-@@ -74,14 +74,6 @@
- 		}
- 	}
- 
--	/* 
--	 * If given filepath is a URL, allow - safe mode stuff
--	 * related to URL's is checked in individual functions
--	 */
--	wrapper = php_stream_locate_url_wrapper(filename, NULL, STREAM_LOCATE_WRAPPERS_ONLY TSRMLS_CC);
--	if (wrapper != NULL)
--		return 1;
--		
- 	/* First we see if the file is owned by the same user...
- 	 * If that fails, passthrough and check directory...
- 	 */

From laffer1 at midnightbsd.org  Thu Jan  1 18:49:21 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 18:49:21 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: We don't support php 4
Message-ID: <200901012349.n01NnLst055525@stargazer.midnightbsd.org>

Log Message:
-----------
We don't support php 4

Modified Files:
--------------
    mports/lang/php5-extensions:
        Makefile (r1.5 -> r1.6)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/lang/php5-extensions/Makefile,v
retrieving revision 1.5
retrieving revision 1.6
diff -L lang/php5-extensions/Makefile -L lang/php5-extensions/Makefile -u -r1.5 -r1.6
--- lang/php5-extensions/Makefile
+++ lang/php5-extensions/Makefile
@@ -19,7 +19,6 @@
 LICENSE=	agg
 
 DEFAULT_PHP_VER=5
-IGNORE_WITH_PHP=4
 USE_PHP_BUILD=	yes
 
 NO_BUILD=	yes

From laffer1 at midnightbsd.org  Thu Jan  1 19:26:38 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 19:26:38 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: x11/xterm: update to 237
Message-ID: <200901020026.n020QcD1058841@stargazer.midnightbsd.org>

Log Message:
-----------
update to 237

Modified Files:
--------------
    mports/x11/xterm:
        Makefile (r1.9 -> r1.10)
        distinfo (r1.8 -> r1.9)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/x11/xterm/Makefile,v
retrieving revision 1.9
retrieving revision 1.10
diff -L x11/xterm/Makefile -L x11/xterm/Makefile -u -r1.9 -r1.10
--- x11/xterm/Makefile
+++ x11/xterm/Makefile
@@ -7,7 +7,7 @@
 #
 
 PORTNAME=	xterm
-PORTVERSION=	235
+PORTVERSION=	237
 CATEGORIES=	x11
 MASTER_SITES=	ftp://invisible-island.net/xterm/ \
 		http://voodoo.bawue.com/download/
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/x11/xterm/distinfo,v
retrieving revision 1.8
retrieving revision 1.9
diff -L x11/xterm/distinfo -L x11/xterm/distinfo -u -r1.8 -r1.9
--- x11/xterm/distinfo
+++ x11/xterm/distinfo
@@ -1,3 +1,3 @@
-MD5 (xterm-235.tgz) = 5060cab9cef0ea09a24928f3c7fbde2b
-SHA256 (xterm-235.tgz) = c8a7ccb515b967a11dc2ac1061943cddbf0b6640de89f72590b1ff79e69a49cf
-SIZE (xterm-235.tgz) = 857714
+MD5 (xterm-237.tgz) = 6d5f9e124fd3e09487f47c66da8c7345
+SHA256 (xterm-237.tgz) = f3be160c230fcb38fba0824cf8a4334e8ff0bb93938e5e325be5e949cd2b3476
+SIZE (xterm-237.tgz) = 860424

From laffer1 at midnightbsd.org  Thu Jan  1 19:48:42 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 19:48:42 -0500 (EST)
Subject: [Midnightbsd-cvs] src: Makefile: geeze,
	fix the build/install of liblwres
Message-ID: <200901020048.n020mgAI060772@stargazer.midnightbsd.org>

Log Message:
-----------
geeze, fix the build/install of liblwres

Modified Files:
--------------
    src/lib/bind/lwres:
        Makefile (r1.6 -> r1.7)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/src/lib/bind/lwres/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L lib/bind/lwres/Makefile -L lib/bind/lwres/Makefile -u -r1.6 -r1.7
--- lib/bind/lwres/Makefile
+++ lib/bind/lwres/Makefile
@@ -10,7 +10,7 @@
 
 # Unlike other BIND libs, this should be installed unless the user says NO.
 .if ${MK_BIND_LIBS_LWRES} != "no"
-WITH_BIND_LIBS=
+MK_BIND_LIBS=	yes
 .endif
 
 .include	"${LIB_BIND_DIR}/config.mk"

From laffer1 at midnightbsd.org  Thu Jan  1 19:59:49 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 19:59:49 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: emulators/kqemu-kmod: Fix a few bugs with
	kqemu
Message-ID: <200901020059.n020xnF4061929@stargazer.midnightbsd.org>

Log Message:
-----------
Fix a few bugs with kqemu

Modified Files:
--------------
    mports/emulators/kqemu-kmod:
        Makefile (r1.3 -> r1.4)
    mports/emulators/kqemu-kmod/files:
        patch-kqemu-freebsd.c (r1.1 -> r1.2)

Added Files:
-----------
    mports/emulators/kqemu-kmod/files:
        patch-common-Makefile (r1.1)
        patch-fpucontext (r1.1)
        patch-tssworkaround (r1.1)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/emulators/kqemu-kmod/Makefile,v
retrieving revision 1.3
retrieving revision 1.4
diff -L emulators/kqemu-kmod/Makefile -L emulators/kqemu-kmod/Makefile -u -r1.3 -r1.4
--- emulators/kqemu-kmod/Makefile
+++ emulators/kqemu-kmod/Makefile
@@ -8,10 +8,10 @@
 
 PORTNAME=	kqemu
 PORTVERSION=	1.3.0.p11
+PORTREVISION=	1
 CATEGORIES=	emulators
-MASTER_SITES=	http://qemu.org/ \
-		http://fabrice.bellard.free.fr/qemu/ \
-		${MASTER_SITE_LOCAL}
+MASTER_SITES=	http://bellard.org/qemu/ \
+		${MASTER_SITE_FREEBSD_LOCAL}
 MASTER_SITE_SUBDIR=	nox
 PKGNAMESUFFIX=	-kmod
 DISTNAME=	${PORTNAME}-${PORTVERSION:C/.p/pre/}
@@ -24,10 +24,8 @@
 ONLY_FOR_ARCHS=	i386 amd64
 HAS_CONFIGURE=	yes
 USE_GMAKE=	yes
-USE_GCC=	3.4
 CONFIGURE_ARGS+=	--prefix=${PREFIX} --cc=${CC}
 
-
 USE_RC_SUBR=	kqemu
 
 .include 
--- /dev/null
+++ emulators/kqemu-kmod/files/patch-tssworkaround
@@ -0,0 +1,112 @@
+Index: kqemu-freebsd.c
+@@ -38,6 +38,14 @@
+ #else
+ #include 
+ #endif
++#ifdef __x86_64__
++#include 
++#include 
++#include 
++#include 
++#include 
++#include 
++#endif
+ 
+ #include "kqemu-kernel.h"
+ 
+@@ -248,6 +256,57 @@
+     va_end(ap);
+ }
+ 
++#ifdef __x86_64__
++int kqemu_cpu0gdtfixed;
++int kqemu_gdts_used;
++struct user_segment_descriptor *kqemu_gdts;
++struct region_descriptor kqemu_r_newgdt;
++extern  struct pcpu __pcpu[];
++
++/* called with interrupts disabled */
++void CDECL kqemu_tss_fixup(unsigned long kerngdtbase)
++{
++    int gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
++    unsigned cpuid = PCPU_GET(cpuid);
++    struct user_segment_descriptor *newgdt = gdt;
++
++    if (mp_ncpus <= 1 || kerngdtbase != (unsigned long)gdt)
++	/* UP host or gdt already moved, nothing to do */
++	return;
++    if (cpuid) {
++	/* move gdts of all but first cpu */
++	if (!kqemu_gdts)
++	    /*
++	     * XXX gdt is allocated as
++	     *	struct user_segment_descriptor gdt[NGDT * MAXCPU];
++	     * so it has room for the moved copies; need to allocate at
++	     * kldload (and only free if kqemu_gdts_used is zero) should this
++	     * change in the future
++	     */
++	    kqemu_gdts = &gdt[NGDT];
++	++kqemu_gdts_used;
++	newgdt = &kqemu_gdts[NGDT * (cpuid - 1)];
++	bcopy(gdt, newgdt, NGDT * sizeof(gdt[0]));
++	kqemu_r_newgdt.rd_limit = NGDT * sizeof(gdt[0]) - 1;
++	kqemu_r_newgdt.rd_base = (long) newgdt;
++    } else {
++	if (kqemu_cpu0gdtfixed)
++	    return;
++	++kqemu_cpu0gdtfixed;
++    }
++    gdt_segs[GPROC0_SEL].ssd_base = (long) &common_tss[cpuid];
++    ssdtosyssd(&gdt_segs[GPROC0_SEL],
++       (struct system_segment_descriptor *)&newgdt[GPROC0_SEL]);
++    if (cpuid) {
++	lgdt(&kqemu_r_newgdt);
++	wrmsr(MSR_GSBASE, (u_int64_t)&__pcpu[cpuid]);
++	wrmsr(MSR_KGSBASE, curthread->td_pcb->pcb_gsbase);
++	wrmsr(MSR_FSBASE, curthread->td_pcb->pcb_fsbase);
++    }
++    ltr(gsel_tss);
++}
++#endif
++
+ struct kqemu_instance { 
+ #if __FreeBSD_version >= 500000
+     TAILQ_ENTRY(kqemu_instance) kqemu_ent;
+Index: common/kernel.c
+@@ -1025,6 +1025,9 @@
+ #ifdef __x86_64__
+     uint16_t saved_ds, saved_es;
+     unsigned long fs_base, gs_base;
++#ifdef __FreeBSD__
++    struct kqemu_global_state *g = s->global_state;
++#endif
+ #endif
+     
+ #ifdef PROFILE
+@@ -1096,6 +1099,14 @@
+             apic_nmi_mask = apic_save_and_disable_nmi(s);
+         }
+ 
++#ifdef __FreeBSD__
++#ifdef __x86_64__
++        spin_lock(&g->lock);
++        asm volatile ("sgdt %0" : : "m" (s->kernel_gdt));
++        kqemu_tss_fixup(s->kernel_gdt.base);
++        spin_unlock(&g->lock);
++#endif
++#endif
+         /* load breakpoint registers and avoid setting them if in the
+            monitor address space. We suppose that no breakpoints are
+            set by the host OS for this process */
+Index: kqemu-kernel.h
+@@ -48,4 +48,10 @@
+ 
+ void CDECL kqemu_log(const char *fmt, ...);
+ 
++#ifdef __FreeBSD__
++#ifdef __x86_64__
++void CDECL kqemu_tss_fixup(unsigned long kerngdtbase);
++#endif
++#endif
++
+ #endif /* KQEMU_KERNEL_H */
--- /dev/null
+++ emulators/kqemu-kmod/files/patch-common-Makefile
@@ -0,0 +1,22 @@
+Index: common/Makefile
+@@ -47,9 +47,9 @@
+ ifeq ($(ARCH), x86_64)
+ COMMON_CFLAGS+=-mno-red-zone
+ endif
+-CFLAGS=$(COMMON_CFLAGS)
++CFLAGS=$(COMMON_CFLAGS) ${DEBUG_FLAGS}
+ MON_CFLAGS=$(COMMON_CFLAGS)
+-KERNEL_CFLAGS=$(COMMON_CFLAGS)
++KERNEL_CFLAGS=$(COMMON_CFLAGS) ${DEBUG_FLAGS}
+ 
+ # Disable SSP if GCC supports it
+ MON_CFLAGS+=$(call cc-option,$(MON_CC),-fno-stack-protector,)
+@@ -119,7 +119,7 @@
+ 	$(CC) $(CFLAGS) $(DEFINES) $(INCLUDES) -c -o $@ $<
+ 
+ %.o: %.S
+-	$(CC) $(DEFINES) $(INCLUDES) -D__ASSEMBLY__ -c -o $@ $<
++	$(CC) ${DEBUG_FLAGS} $(DEFINES) $(INCLUDES) -D__ASSEMBLY__ -c -o $@ $<
+ 
+ clean:
+ 	rm -f *.o *~ monitor-image.h genoffsets genmon monitor_def.h \
--- /dev/null
+++ emulators/kqemu-kmod/files/patch-fpucontext
@@ -0,0 +1,78 @@
+Index: common/kernel.c
+@@ -1240,6 +1240,11 @@
+             case MON_REQ_EXCEPTION:
+                 exec_exception(s->arg0);
+                 break;
++#ifdef __FreeBSD__
++            case MON_REQ_LOADFPUCONTEXT:
++                kqemu_loadfpucontext(s->arg0);
++                break;
++#endif
+             default:
+                 kqemu_log("invalid mon request: %d\n", s->mon_req);
+                 break;
+Index: common/kqemu_int.h
+@@ -523,6 +523,7 @@
+     MON_REQ_LOCK_USER_PAGE,
+     MON_REQ_UNLOCK_USER_PAGE,
+     MON_REQ_EXCEPTION,
++    MON_REQ_LOADFPUCONTEXT,
+ } MonitorRequest;
+ 
+ #define INTERRUPT_ENTRY_SIZE 16
+Index: common/monitor.c
+@@ -1995,8 +1995,13 @@
+         raise_exception_err(s, EXCP07_PREX, 0);
+     } else {
+         /* the host needs to restore the FPU state for us */
++#ifndef __FreeBSD__
+         s->mon_req = MON_REQ_EXCEPTION;
+         s->arg0 = 0x07;
++#else
++        s->mon_req = MON_REQ_LOADFPUCONTEXT;
++        s->arg0 = (unsigned long)s->cpu_state.cpl;
++#endif
+         monitor2kernel1(s);
+     }
+ }
+Index: kqemu-freebsd.c
+@@ -33,6 +33,11 @@
+ 
+ #include 
+ #include 
++#ifdef __x86_64__
++#include 
++#else
++#include 
++#endif
+ 
+ #include "kqemu-kernel.h"
+ 
+@@ -172,6 +177,15 @@
+ {
+ }
+ 
++void CDECL kqemu_loadfpucontext(unsigned long cpl)
++{
++#ifdef __x86_64__
++    fpudna();
++#else
++    npxdna();
++#endif
++}
++
+ #if __FreeBSD_version < 500000
+ static int
+ curpriority_cmp(struct proc *p)
+Index: kqemu-kernel.h
+@@ -40,6 +40,10 @@
+ void * CDECL kqemu_io_map(unsigned long page_index, unsigned int size);
+ void CDECL kqemu_io_unmap(void *ptr, unsigned int size);
+ 
++#ifdef __FreeBSD__
++void CDECL kqemu_loadfpucontext(unsigned long cpl);
++#endif
++
+ int CDECL kqemu_schedule(void);
+ 
+ void CDECL kqemu_log(const char *fmt, ...);
Index: patch-kqemu-freebsd.c
===================================================================
RCS file: /home/cvs/mports/emulators/kqemu-kmod/files/patch-kqemu-freebsd.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -L emulators/kqemu-kmod/files/patch-kqemu-freebsd.c -L emulators/kqemu-kmod/files/patch-kqemu-freebsd.c -u -r1.1 -r1.2
--- emulators/kqemu-kmod/files/patch-kqemu-freebsd.c
+++ emulators/kqemu-kmod/files/patch-kqemu-freebsd.c
@@ -1,12 +1,69 @@
 Index: kqemu-freebsd.c
-@@ -321,6 +321,9 @@
+@@ -222,9 +222,17 @@
+ int CDECL kqemu_schedule(void)
+ {
+     /* kqemu_log("kqemu_schedule\n"); */
++#if __FreeBSD_version < 700044
+     mtx_lock_spin(&sched_lock);
+     mi_switch(SW_VOL, NULL);
+     mtx_unlock_spin(&sched_lock);
++#else
++    /* -current no longer uses sched_lock */
++    struct thread *td = curthread;
++    thread_lock(td);
++    mi_switch(SW_VOL, NULL);
++    thread_unlock(td);
++#endif
+     return SIGPENDING(curthread);
+ }
+ #endif
+@@ -258,6 +266,10 @@
+ static struct clonedevs *kqemuclones;
+ static TAILQ_HEAD(,kqemu_instance) kqemuhead = TAILQ_HEAD_INITIALIZER(kqemuhead);
+ static eventhandler_tag clonetag;
++#ifndef D_NEEDMINOR
++/* see http://svn.freebsd.org/viewvc/base?view=revision&revision=179726 */
++#define D_NEEDMINOR 0
++#endif
+ #endif
+ 
+ static d_close_t kqemu_close;
+@@ -282,7 +294,7 @@
+ 	/* bmaj */	-1
+ #else
+ 	.d_version =	D_VERSION,
+-	.d_flags =	D_NEEDGIANT,
++	.d_flags =	D_NEEDGIANT | D_NEEDMINOR,
+ 	.d_open =	kqemu_open,
+ 	.d_ioctl =	kqemu_ioctl,
+ 	.d_close =	kqemu_close,
+@@ -334,8 +346,15 @@
  #if __FreeBSD_version >= 500000
      dev->si_drv1 = NULL;
      TAILQ_REMOVE(&kqemuhead, ks, kqemu_ent);
++#if __FreeBSD_version >= 700051
++    destroy_dev_sched(dev);
++#else
 +#if __FreeBSD_version >= 700024
 +    dev_relthread(dev); 
 +#endif
      destroy_dev(dev);
  #endif
++#endif
      free(ks, M_KQEMU);
-
+     --kqemu_ref_count;
+ }
+@@ -514,7 +533,13 @@
+ 	while ((ks = TAILQ_FIRST(&kqemuhead)) != NULL) {
+ 	    kqemu_destroy(ks);
+ 	}
++#if __FreeBSD_version >= 700051
++	drain_dev_clone_events();
++#endif
+ 	clone_cleanup(&kqemuclones);
++#if __FreeBSD_version >= 700051
++	destroy_dev_drain(&kqemu_cdevsw);
++#endif
+ #endif
+         kqemu_global_delete(kqemu_gs);
+         kqemu_gs = NULL;

From laffer1 at midnightbsd.org  Thu Jan  1 20:06:29 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:06:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: osversion assumption for
	__FreeBSD_version
Message-ID: <200901020106.n0216To2062810@stargazer.midnightbsd.org>

Log Message:
-----------
osversion assumption for __FreeBSD_version

Modified Files:
--------------
    mports/emulators/pearpc:
        Makefile (r1.4 -> r1.5)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/emulators/pearpc/Makefile,v
retrieving revision 1.4
retrieving revision 1.5
diff -L emulators/pearpc/Makefile -L emulators/pearpc/Makefile -u -r1.4 -r1.5
--- emulators/pearpc/Makefile
+++ emulators/pearpc/Makefile
@@ -8,7 +8,7 @@
 
 PORTNAME=	pearpc
 PORTVERSION=	0.4
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	emulators
 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 MASTER_SITE_SUBDIR=	${PORTNAME}
@@ -85,6 +85,11 @@
 post-extract:
 	@${REINPLACE_CMD} -e 's|-g -O2||;s|-O2||' ${WRKSRC}/configure
 
+pre-configure:
+# Assumes __FreeBSD_version value.  Change when current switches over.
+.if ${OSVERSION} > 700000
+	@${REINPLACE_CMD} -e 's|clock_settime\ ()|foobar()|' ${WRKSRC}/configure
+.endif
 
 post-configure:
 	@${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/Makefile

From laffer1 at midnightbsd.org  Thu Jan  1 20:19:16 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:19:16 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: security/vlock: update to 2.2.2
Message-ID: <200901020119.n021JG4x063964@stargazer.midnightbsd.org>

Log Message:
-----------
update to 2.2.2

Modified Files:
--------------
    mports/security/vlock:
        Makefile (r1.2 -> r1.3)
        distinfo (r1.1 -> r1.2)
        pkg-descr (r1.1 -> r1.2)

Added Files:
-----------
    mports/security/vlock/files:
        patch-configure (r1.1)

Removed Files:
-------------
    mports/security/vlock/files:
        patch-aa
        patch-ab
        patch-ac
        patch-ad
        patch-ae

-------------- next part --------------
Index: pkg-descr
===================================================================
RCS file: /home/cvs/mports/security/vlock/pkg-descr,v
retrieving revision 1.1
retrieving revision 1.2
diff -L security/vlock/pkg-descr -L security/vlock/pkg-descr -u -r1.1 -r1.2
--- security/vlock/pkg-descr
+++ security/vlock/pkg-descr
@@ -1,5 +1,4 @@
 This is a utility which locks a terminal so it can only be unlocked with the
 user's password (or the root password).  It uses PAM authentication by default.
 
-- George Reid
-services at nevernet.net
+WWW: http://freshmeat.net/projects/vlock
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/security/vlock/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L security/vlock/Makefile -L security/vlock/Makefile -u -r1.2 -r1.3
--- security/vlock/Makefile
+++ security/vlock/Makefile
@@ -2,22 +2,86 @@
 # Date created:		08 Oct 2000
 # Whom:			George Reid 
 #
-# $FreeBSD: ports/security/vlock/Makefile,v 1.5 2004/02/05 20:37:48 trevor Exp $
 # $MidnightBSD$
-#
+# $FreeBSD: ports/security/vlock/Makefile,v 1.9 2008/06/19 19:35:54 pav Exp $
 
 PORTNAME=	vlock
-PORTVERSION=	1.3
-PORTREVISION=	1
+PORTVERSION=	2.2.2
 CATEGORIES=	security
-MASTER_SITES=	${MASTER_SITE_SUNSITE}
-MASTER_SITE_SUBDIR=	utils/console
+MASTER_SITES=	http://cthulhu.c3d2.de/~toidinamai/vlock/archive/
 
 MAINTAINER=	ports at MidnightBSD.org
 COMMENT=	Locks a terminal
 LICENSE=	gpl2
 
+USE_GMAKE=	yes
+HAS_CONFIGURE=	yes
+CONFIGURE_ARGS=	--enable-plugins --enable-pam \
+		--prefix=${PREFIX} \
+		--mandir=${MANPREFIX}/man \
+		--with-modules="${VLOCKMODULES}" \
+		--with-scripts="${VLOCKSCRIPTS}" \
+		VLOCK_GROUP="${VLOCKGRP}" \
+		VLOCK_MODE="0750" \
+		EXTRA_CFLAGS="-I${LOCALBASE}/include" \
+		EXTRA_LDFLAGS="-L${LOCALBASE}/lib"
+
+OPTIONS=	ROOTPWD "Enable unlock using root password" on \
+		VLOCKSCRIPTS "Install sample hook scripts" off \
+		CACASAVER "Enable libcaca screensaver" off
+
+MANLANG=	""
 MAN1=		vlock.1
-PLIST_FILES=	bin/vlock
+MAN5=		vlock-plugins.5
+MAN8=		vlock-main.8
+
+# Default scripts/modules
+VLOCKSCRIPTS=
+VLOCKMODULES=	all.so new.so
+
+# Vlock group = vlock:*:129:
+VLOCKGRP=	vlock
+VLOCKGID=	129
+
+.include 
+
+.if !defined(WITHOUT_ROOTPWD)
+CONFIGURE_ARGS+=	--enable-root-password
+.else
+CONFIGURE_ARGS+=	--disable-root-password
+.endif
+
+.if !defined(WITHOUT_VLOCKSCRIPTS)
+VLOCKSCRIPTS+=	amarok.sh example_script.sh mplayer.sh
+PLIST_SUB+=	PL_VLOCKSCRIPTS=""
+.else
+PLIST_SUB+=	PL_VLOCKSCRIPTS="@comment "
+.endif
+
+.if !defined(WITHOUT_CACASAVER)
+BUILD_DEPENDS+=	${LOCALBASE}/lib/libcaca.a:${PORTSDIR}/graphics/libcaca
+VLOCKMODULES+=	caca.so
+PLIST_SUB+=	PL_CACASAVER=""
+.else
+PLIST_SUB+=	PL_CACASAVER="@comment "
+.endif
+
+post-patch:
+	@${REINPLACE_CMD} -e 's|-lncurses|-lm|' ${WRKSRC}/modules/Makefile
+
+pre-install:
+	if ! pw groupshow ${VLOCKGRP}; then pw groupadd ${VLOCKGRP} -g ${VLOCKGID}; fi
+
+post-install:
+.if !defined(NOPORTDOCS)
+	@${MKDIR} ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/COPYING ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/ChangeLog ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/PLUGINS ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README.X11 ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/SECURITY ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/TODO ${DOCSDIR}
+.endif
 
-.include 
+.include 
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/security/vlock/distinfo,v
retrieving revision 1.1
retrieving revision 1.2
diff -L security/vlock/distinfo -L security/vlock/distinfo -u -r1.1 -r1.2
--- security/vlock/distinfo
+++ security/vlock/distinfo
@@ -1,3 +1,3 @@
-MD5 (vlock-1.3.tar.gz) = d04076f9c5f12aadc4d5fbbabf8a0c12
-SHA256 (vlock-1.3.tar.gz) = 700b8f45b6b7cdaac2185a4796870ac378015db18a7414eebee5e5b6a4131daf
-SIZE (vlock-1.3.tar.gz) = 17188
+MD5 (vlock-2.2.2.tar.gz) = 51c389ee4ef814bf59063bc367437eb8
+SHA256 (vlock-2.2.2.tar.gz) = ea875250cad150872583b6ed2436470bc5e9c3a580d85554e31a2d5ae1d92fad
+SIZE (vlock-2.2.2.tar.gz) = 54732
--- security/vlock/files/patch-ac
+++ /dev/null
@@ -1,11 +0,0 @@
---- terminal.c.orig	Sun Oct  8 18:03:19 2000
-+++ terminal.c		Sun Oct  8 18:03:24 2000
-@@ -15,7 +15,7 @@
- #include 
- #include 
- #include 
--#include 
-+#include 
- #include "vlock.h"
- 
- 
--- /dev/null
+++ security/vlock/files/patch-configure
@@ -0,0 +1,25 @@
+--- configure.orig	2008-05-18 05:10:54 -0400
++++ configure	2009-01-01 20:16:02 -0500
+@@ -220,7 +220,8 @@
+   MODULEDIR="\$(LIBDIR)/vlock/modules"
+ 
+   CC=gcc
+-  DEFAULT_CFLAGS="-O2 -Wall -W -pedantic -std=gnu99"
++  #DEFAULT_CFLAGS="-O2 -Wall -W -pedantic -std=gnu99"
++  DEFAULT_CFLAGS="-pedantic -std=gnu99"
+   DEBUG_CFLAGS="-O0 -g -Wall -W -pedantic -std=gnu99"
+   CFLAGS="${DEFAULT_CFLAGS}"
+   LD=ld
+@@ -266,6 +267,12 @@
+       CRYPT_LIB=''
+       MODULES="all.so new.so"
+     ;;
++    MidnightBSD)
++      PAM_LIBS='-lpam'
++      DL_LIB=''
++      CRYPT_LIB=''
++      MODULES="all.so new.so"
++    ;;
+   esac
+ }
+ 
--- security/vlock/files/patch-ab
+++ /dev/null
@@ -1,11 +0,0 @@
---- signals.c.orig	Sun Oct  8 18:03:19 2000
-+++ signals.c		Sun Oct  8 18:03:24 2000
-@@ -16,7 +16,7 @@
- #include 
- #include 
- #include 
--#include 
-+#include 
- #include "vlock.h"
- 
- 
--- security/vlock/files/patch-ae
+++ /dev/null
@@ -1,39 +0,0 @@
---- input.c.orig	Thu Jan 14 03:19:14 1999
-+++ input.c	Fri Feb 28 13:48:38 2003
-@@ -60,11 +60,27 @@
- #error "Shadow and PAM don't mix!"
- #endif
- 
-+#if (__FreeBSD__ == 0)            /* 1.0 did not define __FreeBSD__ */
-+#define __FreeBSD_version 199401
-+#elsif __FreeBSD__ == 1          /* 1.1 defined it to be 1 */
-+#define __FreeBSD_version 199405
-+#else                           /* 2.0 and higher define it to be 2 */
-+#include           /* and this works */
-+#endif
-+
- #include 
-+#if defined (__FreeBSD_version) && (__FreeBSD_version > 500030)
-+#include 
-+#else
- #include 
-+#endif
- 
- static struct pam_conv PAM_conversation = {
-+#if defined (__FreeBSD_version) && (__FreeBSD_version > 500030)
-+    openpam_ttyconv,
-+#else
-     &misc_conv,
-+#endif
-     NULL
- };
- 
-@@ -291,7 +307,7 @@
-   setuid(getuid());
-   setgid(getgid());
- 
--  sprintf(prompt, "%s's password: ", username);
-+  snprintf(prompt, 99, "%s's password: ", username);
- #endif /* !USE_PAM */
- }
- 
--- security/vlock/files/patch-ad
+++ /dev/null
@@ -1,46 +0,0 @@
---- vlock.c.orig	Sun Oct  8 18:03:19 2000
-+++ vlock.c		Sun Oct  8 18:03:24 2000
-@@ -14,12 +14,10 @@
- #include 
- #include 
- #include 
--#include 
- #include 
- #include 
--#include 
--#include 
- #include 
-+#include 
- #include "vlock.h"
- #include "version.h"
- 
-@@ -37,20 +35,12 @@
- 
- int main(int argc, char **argv) {
- 
--  static struct option long_options[] = { /* For parsing long arguments */
--    {"current", 0, &o_lock_all, 0},
--    {"all", 0, &o_lock_all, 1},
--    {"version", no_argument, 0, O_VERSION},
--    {"help", no_argument, 0, O_HELP},
--    {0, 0, 0, 0},
--  };
-   int option_index; /* Unused */
-   int c;
-   struct vt_mode vtm;
- 
-   /* First we parse all the command line arguments */
--  while ((c = getopt_long(argc, argv, "acvh",
--			  long_options, &option_index)) != -1) {
-+  while ((c = getopt(argc, argv, "acvh")) != -1) {
-     switch(c) {
-     case 'c':
-       o_lock_all = 0;
-@@ -107,6 +97,7 @@
-     vtm.mode = VT_PROCESS;
-     vtm.relsig = SIGUSR1; /* handled by release_vt() */
-     vtm.acqsig = SIGUSR2; /* handled by acquire_vt() */
-+    vtm.frsig = SIGUSR1;  /* needed by FreeBSD */
-     ioctl(vfd, VT_SETMODE, &vtm);
-   }
- 
--- security/vlock/files/patch-aa
+++ /dev/null
@@ -1,36 +0,0 @@
---- Makefile.orig	Thu Jan 14 01:19:14 1999
-+++ Makefile	Wed Jun 16 17:23:34 2004
-@@ -1,24 +1,19 @@
- # vlock makefile
- 
--CC = gcc
--# remove the -DUSE_PAM, -ldl, and -lpam if you aren't using PAM
--RPM_OPT_FLAGS=-O2
--CFLAGS = $(RPM_OPT_FLAGS) -DUSE_PAM
--LDFLAGS = -ldl -lpam -lpam_misc
-+CFLAGS += -DUSE_PAM
-+LDFLAGS = -lpam
- 
- OBJS = vlock.o signals.o help.o terminal.o input.o
- 
--vlock: $(OBJS)
-+all:	vlock
- 
--vlock.man: vlock.1
--	groff -man -Tascii vlock.1 > vlock.man
-+vlock:	$(OBJS)
-+	cc $(OBJS) $(LDFLAGS) -o vlock
- 
--vlock.o: vlock.h version.h
--signals.o: vlock.h
--help.o: vlock.h
--terminal.o: vlock.h
--input.o: vlock.h
-+install:
-+	/usr/bin/install -c -s -o root -g wheel -m 4555 vlock ${PREFIX}/bin
-+	/usr/bin/install -c -o root -g wheel -m 444 vlock.1 ${MANPREFIX}/man/man1
- 
- clean:
--	rm -f $(OBJS) vlock core core.vlock
-+	rm -f $(OBJS) vlock vlock.core
- 

From laffer1 at midnightbsd.org  Thu Jan  1 20:19:31 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:19:31 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: pkg-plist: update to 2.2.2
Message-ID: <200901020119.n021JV9m064023@stargazer.midnightbsd.org>

Log Message:
-----------
update to 2.2.2

Added Files:
-----------
    mports/security/vlock:
        pkg-plist (r1.1)

-------------- next part --------------
--- /dev/null
+++ security/vlock/pkg-plist
@@ -0,0 +1,20 @@
+bin/vlock
+sbin/vlock-main
+lib/vlock/modules/all.so
+lib/vlock/modules/new.so
+%%PL_CACASAVER%%lib/vlock/modules/caca.so
+ at dirrm lib/vlock/modules
+%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/amarok
+%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/example_script
+%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/mplayer
+%%PL_VLOCKSCRIPTS%%@dirrm lib/vlock/scripts
+ at dirrm lib/vlock
+%%PORTDOCS%%%%DOCSDIR%%/COPYING
+%%PORTDOCS%%%%DOCSDIR%%/ChangeLog
+%%PORTDOCS%%%%DOCSDIR%%/PLUGINS
+%%PORTDOCS%%%%DOCSDIR%%/README
+%%PORTDOCS%%%%DOCSDIR%%/README.X11
+%%PORTDOCS%%%%DOCSDIR%%/SECURITY
+%%PORTDOCS%%%%DOCSDIR%%/TODO
+%%PORTDOCS%%@dirrm %%DOCSDIR%%
+ at exec if ! pw groupshow vlock 2>/dev/null; then pw groupadd vlock -g 129; fi

From ctriv at midnightbsd.org  Thu Jan  1 20:33:18 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:33:18 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: bsd.mport.mk: Change OSVERSION to refer
	to the MidnightBSD
Message-ID: <200901020133.n021XI8r065447@stargazer.midnightbsd.org>

Log Message:
-----------
Change OSVERSION to refer to the MidnightBSD version, not the FreeBSD version.
Don't check for param.h in src, it could be version that isn't at all related to 
the actual system.  Check param.h in /usr/include, and if that fails, use sysctl.

Modified Files:
--------------
    mports/Mk:
        bsd.mport.mk (r1.131 -> r1.132)

-------------- next part --------------
Index: bsd.mport.mk
===================================================================
RCS file: /home/cvs/mports/Mk/bsd.mport.mk,v
retrieving revision 1.131
retrieving revision 1.132
diff -L Mk/bsd.mport.mk -L Mk/bsd.mport.mk -u -r1.131 -r1.132
--- Mk/bsd.mport.mk
+++ Mk/bsd.mport.mk
@@ -118,12 +118,10 @@
 OSREL!=	${UNAME} -r | ${SED} -e 's/[-(].*//'
 .endif
 
-# Get __FreeBSD_version
+# Get __MidnightBSD_version
 .if !defined(OSVERSION)
 .if exists(${DESTDIR}/usr/include/sys/param.h)
-OSVERSION!=	${AWK} '/^\#define[[:blank:]]__FreeBSD_version/ {print $$3}' < ${DESTDIR}/usr/include/sys/param.h
-.elif exists(${DESTDIR}/usr/src/sys/sys/param.h)
-OSVERSION!=	${AWK} '/^\#define[[:blank:]]__FreeBSD_version/ {print $$3}' < ${DESTDIR}/usr/src/sys/sys/param.h
+OSVERSION!=	${AWK} '/^\#define[[:blank:]]__MidnightBSD_version/ {print $$3}' < ${DESTDIR}/usr/include/sys/param.h
 .else
 OSVERSION!=	${SYSCTL} -n kern.osreldate
 .endif

From ctriv at midnightbsd.org  Thu Jan  1 20:34:04 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:34:04 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020134.n021Y4hp065513@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/astro/boinc-milkyway:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/astro/boinc-milkyway/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L astro/boinc-milkyway/Makefile -L astro/boinc-milkyway/Makefile -u -r1.2 -r1.3
--- astro/boinc-milkyway/Makefile
+++ astro/boinc-milkyway/Makefile
@@ -22,7 +22,7 @@
 
 ONLY_FOR_ARCHS=	i386 amd64
 
-.if ${OSVERSION} >= 700000
+.if ${OSVERSION} >= 3000
 LIB_DEPENDS+=	c.6:${PORTSDIR}/misc/compat6x
 .endif
 

From ctriv at midnightbsd.org  Thu Jan  1 20:35:46 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:35:46 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: gcc.mk: Fix OSVERSION.
Message-ID: <200901020135.n021Zkna065882@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/Mk/extensions:
        gcc.mk (r1.1 -> r1.2)

-------------- next part --------------
Index: gcc.mk
===================================================================
RCS file: /home/cvs/mports/Mk/extensions/gcc.mk,v
retrieving revision 1.1
retrieving revision 1.2
diff -L Mk/extensions/gcc.mk -L Mk/extensions/gcc.mk -u -r1.1 -r1.2
--- Mk/extensions/gcc.mk
+++ Mk/extensions/gcc.mk
@@ -40,7 +40,7 @@
 # the base system.
 # The third field is the version as USE_GCC would use.
 #
-GCCVERSION_030402=	502126 999999 3.4
+GCCVERSION_030402=	2000 999999 3.4
 GCCVERSION_040100=	999999 999999 4.1
 GCCVERSION_040200=	999999 999999 4.2
 GCCVERSION_040300=	999999 999999 4.3

From ctriv at midnightbsd.org  Thu Jan  1 20:36:29 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:36:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: bsd.mport.mk.pod: Clean up version
	variable documentation.
Message-ID: <200901020136.n021aT1g065949@stargazer.midnightbsd.org>

Log Message:
-----------
Clean up version variable documentation.

Modified Files:
--------------
    mports/Mk/docs:
        bsd.mport.mk.pod (r1.7 -> r1.8)

-------------- next part --------------
Index: bsd.mport.mk.pod
===================================================================
RCS file: /home/cvs/mports/Mk/docs/bsd.mport.mk.pod,v
retrieving revision 1.7
retrieving revision 1.8
diff -L Mk/docs/bsd.mport.mk.pod -L Mk/docs/bsd.mport.mk.pod -u -r1.7 -r1.8
--- Mk/docs/bsd.mport.mk.pod
+++ Mk/docs/bsd.mport.mk.pod
@@ -244,10 +244,6 @@
 
 The value of __MidnightBSD_version.
 
-=item FREEBSDVERSION 
-
-The version of FreeBSD closest to your version of MidnightBSD.
-
 =item PORTOBJFORMAT
 
 The object format ("aout" or "elf").

From ctriv at midnightbsd.org  Thu Jan  1 20:37:30 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:37:30 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020137.n021bUcj066045@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/devel/ZendOptimizer:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/devel/ZendOptimizer/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L devel/ZendOptimizer/Makefile -L devel/ZendOptimizer/Makefile -u -r1.2 -r1.3
--- devel/ZendOptimizer/Makefile
+++ devel/ZendOptimizer/Makefile
@@ -26,7 +26,7 @@
 .include 
 
 VER=		6.0
-.if ${OSVERSION} >= 700043
+.if ${OSVERSION} >= 3000
 LIB_DEPENDS+=	m.4:${PORTSDIR}/misc/compat6x
 .endif
 

From ctriv at midnightbsd.org  Thu Jan  1 20:42:02 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:42:02 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: devel/gvfs: We've always had libarchive,
	don't check OSVERSION
Message-ID: <200901020142.n021g22G066541@stargazer.midnightbsd.org>

Log Message:
-----------
We've always had libarchive, don't check OSVERSION to decide to use it.

Modified Files:
--------------
    mports/devel/gvfs:
        Makefile (r1.6 -> r1.7)
        pkg-plist (r1.1 -> r1.2)

-------------- next part --------------
Index: pkg-plist
===================================================================
RCS file: /home/cvs/mports/devel/gvfs/pkg-plist,v
retrieving revision 1.1
retrieving revision 1.2
diff -L devel/gvfs/pkg-plist -L devel/gvfs/pkg-plist -u -r1.1 -r1.2
--- devel/gvfs/pkg-plist
+++ devel/gvfs/pkg-plist
@@ -28,7 +28,7 @@
 lib/libgvfscommon.so.0
 %%FUSE%%libexec/gvfs-fuse-daemon
 libexec/gvfsd
-%%ARCHIVE%%libexec/gvfsd-archive
+libexec/gvfsd-archive
 libexec/gvfsd-burn
 %%CDDA%%libexec/gvfsd-cdda
 libexec/gvfsd-computer
@@ -44,7 +44,7 @@
 %%SMB%%libexec/gvfsd-smb-browse
 libexec/gvfsd-trash
 share/dbus-1/services/gvfs-daemon.service
-%%ARCHIVE%%share/gvfs/mounts/archive.mount
+share/gvfs/mounts/archive.mount
 share/gvfs/mounts/burn.mount
 %%CDDA%%share/gvfs/mounts/cdda.mount
 share/gvfs/mounts/computer.mount
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/devel/gvfs/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L devel/gvfs/Makefile -L devel/gvfs/Makefile -u -r1.6 -r1.7
--- devel/gvfs/Makefile
+++ devel/gvfs/Makefile
@@ -73,11 +73,4 @@
 PLIST_SUB+=	GPHOTO2="@comment "
 .endif
 
-.if ${OSVERSION} < 602112
-CONFIGURE_ARGS+=	--disable-archive
-PLIST_SUB+=	ARCHIVE="@comment "
-.else
-PLIST_SUB+=	ARCHIVE=""
-.endif
-
 .include 

From laffer1 at midnightbsd.org  Thu Jan  1 20:44:11 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:44:11 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: freebsd local not ours,
	add license
Message-ID: <200901020144.n021iB2m066666@stargazer.midnightbsd.org>

Log Message:
-----------
freebsd local not ours, add license

Modified Files:
--------------
    mports/graphics/wmicons:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/graphics/wmicons/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L graphics/wmicons/Makefile -L graphics/wmicons/Makefile -u -r1.2 -r1.3
--- graphics/wmicons/Makefile
+++ graphics/wmicons/Makefile
@@ -10,7 +10,7 @@
 PORTVERSION=	1.0
 PORTREVISION=   1
 CATEGORIES=	graphics windowmaker
-MASTER_SITES=	${MASTER_SITE_LOCAL:S|%SUBDIR%|kiri/wmicons|} \
+MASTER_SITES=	${MASTER_SITE_FREEBSD_LOCAL:S|%SUBDIR%|kiri/wmicons|} \
 		${MASTER_SITE_WINDOWMAKER} \
 		${MASTER_SITE_PORTS_JP} \
 		http://www.itlb.te.noda.tus.ac.jp/~manome/wmaker/archive/
@@ -24,6 +24,7 @@
 
 MAINTAINER=	ports at MidnightBSD.org
 COMMENT=	Icons mainly for use in Window Maker
+LICENSE=	unknown
 
 GNU_CONFIGURE=	yes
 

From ctriv at midnightbsd.org  Thu Jan  1 20:45:33 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:45:33 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020145.n021jXXR067035@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/devel/qt4-corelib:
        Makefile (r1.4 -> r1.5)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/devel/qt4-corelib/Makefile,v
retrieving revision 1.4
retrieving revision 1.5
diff -L devel/qt4-corelib/Makefile -L devel/qt4-corelib/Makefile -u -r1.4 -r1.5
--- devel/qt4-corelib/Makefile
+++ devel/qt4-corelib/Makefile
@@ -69,9 +69,10 @@
 	${HEAD} -n 27 ${WRKSRC}/global/qconfig.h > ${WRKDIR}/qconfig.tmp
 	${CHMOD} 644 ${WRKSRC}/global/qconfig.h
 	${CAT} ${WRKDIR}/qconfig.tmp ${FILESDIR}/qconfig.h.in > ${WRKSRC}/global/qconfig.h
-.if ${OSVERSION} >= 700042
-	${ECHO_CMD} "#define QT_VISIBILITY_AVAILABLE" >> ${WRKSRC}/global/qconfig.h
-.endif
+# this looks to be a newer GCC thing.
+#.if ${OSVERSION} >= 3000
+#	${ECHO_CMD} "#define QT_VISIBILITY_AVAILABLE" >> ${WRKSRC}/global/qconfig.h
+#.endif
 
 
 post-install:

From ctriv at midnightbsd.org  Thu Jan  1 20:46:08 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:46:08 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020146.n021k8gn067095@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/editors/zile:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/editors/zile/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L editors/zile/Makefile -L editors/zile/Makefile -u -r1.2 -r1.3
--- editors/zile/Makefile
+++ editors/zile/Makefile
@@ -25,11 +25,7 @@
 
 .include 
 
-.if ${OSVERSION} > 502010
 GNU_REGEX_H=	gnu/regex.h
-.else
-GNU_REGEX_H=	gnuregex.h
-.endif
 
 post-patch:
 	@${REINPLACE_CMD} -e \

From ctriv at midnightbsd.org  Thu Jan  1 21:31:29 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:31:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: patch-aa: Fix OSVERSION.
Message-ID: <200901020231.n022VTLB071392@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/graphics/png/files:
        patch-aa (r1.4 -> r1.5)

-------------- next part --------------
Index: patch-aa
===================================================================
RCS file: /home/cvs/mports/graphics/png/files/patch-aa,v
retrieving revision 1.4
retrieving revision 1.5
diff -L graphics/png/files/patch-aa -L graphics/png/files/patch-aa -u -r1.4 -r1.5
--- graphics/png/files/patch-aa
+++ graphics/png/files/patch-aa
@@ -1,17 +1,13 @@
---- scripts/makefile.freebsd.orig	2007-06-21 02:10:26.000000000 +0400
-+++ scripts/makefile.freebsd	2007-10-13 17:24:24.000000000 +0400
-@@ -8,26 +8,27 @@
+--- ./scripts/makefile.freebsd.orig	2007-06-20 18:10:26 -0400
++++ ./scripts/makefile.freebsd	2009-01-01 21:27:38 -0500
+@@ -8,26 +8,22 @@
  LIB=		png
  SHLIB_MAJOR=	${SHLIB_VER}
  SHLIB_MINOR=	0
 -NOPROFILE=	YES
-+.if (${OSVERSION} > 600007)
+-NOOBJ=          YES
 +NO_PROFILE=     YES
 +NO_OBJ=         YES
-+.else
-+NOPROFILE=      YES
- NOOBJ=          YES
-+.endif
  
  # where make install puts libpng.a and png.h
 -DESTDIR=	${PREFIX}
@@ -36,7 +32,7 @@
  
  SRCS=	png.c pngset.c pngget.c pngrutil.c pngtrans.c pngwutil.c \
  	pngread.c pngrio.c pngwio.c pngwrite.c pngrtran.c \
-@@ -45,4 +46,22 @@
+@@ -45,4 +41,22 @@
  writelock:
  	chmod a-w *.[ch35] $(DOCS) scripts/*
  

From ctriv at midnightbsd.org  Thu Jan  1 21:33:30 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:33:30 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020233.n022XUih071570@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/java/diablo-jre16:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/java/diablo-jre16/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L java/diablo-jre16/Makefile -L java/diablo-jre16/Makefile -u -r1.2 -r1.3
--- java/diablo-jre16/Makefile
+++ java/diablo-jre16/Makefile
@@ -51,15 +51,15 @@
 
 .include 
 
-.if ${OSVERSION} >= 700000
+.if ${OSVERSION} >= 3000
 JRE_OSREL=	freebsd7
 PLIST_SUB+=	RELEASENOTE="@comment "
-.elif ${OSVERSION} >= 600000
+.elif ${OSVERSION} >= 1000
 BROKEN=		required gethostbyname_r
 JRE_OSREL=	freebsd6
 PLIST_SUB+=	RELEASENOTE=""
 .else
-IGNORE=		only available for FreeBSD 6.x/i386 and FreeBSD 6.x/amd64 and later
+IGNORE=		Somehow, you have a copy of MidnightBSD 0.0.0.  Well done!
 .endif
 
 .if ${ARCH} == "i386"

From ctriv at midnightbsd.org  Thu Jan  1 21:37:45 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:37:45 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020237.n022bjif072095@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/lang/mono:
        Makefile (r1.6 -> r1.7)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/lang/mono/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L lang/mono/Makefile -L lang/mono/Makefile -u -r1.6 -r1.7
--- lang/mono/Makefile
+++ lang/mono/Makefile
@@ -77,12 +77,8 @@
 		${WRKSRC}/mcs/class/Managed.Windows.Forms/build-csproj \
 		${WRKSRC}/mcs/class/Managed.Windows.Forms/build-csproj2k5
 
-.if ${OSVERSION} >= 700000
-	@${REINPLACE_CMD} -e 's|freebsd6|freebsd7|g' \
-		${WRKSRC}/configure ${WRKSRC}/libgc/configure
-.endif
 
-tests: build
+test: build
 	@${ECHO_MSG} "===> Running mono regression tests"
 	@(cd ${WRKSRC}/mono/tests && ${SETENV} ${MAKE_ENV} ${GMAKE} \
 		${MAKE_FLAGS} Makefile ${MAKE_ARGS} test)

From ctriv at midnightbsd.org  Thu Jan  1 21:42:14 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:42:14 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: makefile.lib: Fix OSVERSION.
Message-ID: <200901020242.n022gE40072622@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/math/blas/files:
        makefile.lib (r1.3 -> r1.4)

-------------- next part --------------
Index: makefile.lib
===================================================================
RCS file: /home/cvs/mports/math/blas/files/makefile.lib,v
retrieving revision 1.3
retrieving revision 1.4
diff -L math/blas/files/makefile.lib -L math/blas/files/makefile.lib -u -r1.3 -r1.4
--- math/blas/files/makefile.lib
+++ math/blas/files/makefile.lib
@@ -2,11 +2,7 @@
 FFLAGS=	@FFLAGS@
 
 LIBDIR= ${PREFIX}/lib
-.if (${OSVERSION} > 600007)
 NO_PROFILE= no
-.else
-NOPROFILE= no
-.endif
 
 SHLIB_MAJOR= 2
 

From ctriv at midnightbsd.org  Thu Jan  1 22:01:29 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:01:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020301.n0231TAb074649@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/multimedia/ffmpeg:
        Makefile (r1.1 -> r1.2)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/multimedia/ffmpeg/Makefile,v
retrieving revision 1.1
retrieving revision 1.2
diff -L multimedia/ffmpeg/Makefile -L multimedia/ffmpeg/Makefile -u -r1.1 -r1.2
--- multimedia/ffmpeg/Makefile
+++ multimedia/ffmpeg/Makefile
@@ -244,12 +244,9 @@
 	@${REINPLACE_CMD} -e 's|faacD|NeAACD|' ${WRKSRC}/libavcodec/libfaad.c
 # {C,LD}FLAGS safeness
 # fix x264 math, use correct log base 2 from math(3)
-.if ${OSVERSION} <= 601000
 	@${REINPLACE_CMD} -E \
 		-e 's| log2| log|' \
 		${WRKSRC}/libavcodec/libx264.c
-.endif
-
 	${REINPLACE_CMD} -e 's|$$(libdir)/pkgconfig|${FAKE_DESTDIR}${PREFIX}/libdata/pkgconfig|' \
 		${WRKSRC}/common.mak ${WRKSRC}/subdir.mak
 	@${REINPLACE_CMD} -e 's|/etc/ffserver.conf|${PREFIX}/etc/ffserver.conf|' \

From ctriv at midnightbsd.org  Thu Jan  1 22:03:28 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:03:28 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020303.n0233S8d074791@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/net/iwi-firmware:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/net/iwi-firmware/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L net/iwi-firmware/Makefile -L net/iwi-firmware/Makefile -u -r1.2 -r1.3
--- net/iwi-firmware/Makefile
+++ net/iwi-firmware/Makefile
@@ -30,6 +30,6 @@
 		ipw-${PORTVERSION}-sniffer.fw:${DRIVERNAME}-sniffer.fw \
 		ipw-${PORTVERSION}-sniffer_ucode.fw:${DRIVERNAME}-ucode-sniffer.fw
 
-MIN7OSVERSION=	700006
+MIN7OSVERSION=	3000
 
 .include "${MASTERDIR}/Makefile"

From ctriv at midnightbsd.org  Thu Jan  1 22:05:51 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:05:51 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020305.n0235pQL075186@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/sysutils/hal:
        Makefile (r1.8 -> r1.9)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/sysutils/hal/Makefile,v
retrieving revision 1.8
retrieving revision 1.9
diff -L sysutils/hal/Makefile -L sysutils/hal/Makefile -u -r1.8 -r1.9
--- sysutils/hal/Makefile
+++ sysutils/hal/Makefile
@@ -72,15 +72,11 @@
 
 .include 
 
-.if ${OSVERSION} < 505000
-IGNORE=	not supported on FreeBSD prior to 5.5-RELEASE
-.endif
-
 .if (${ARCH}=="i386" || ${ARCH}=="amd64" || ${ARCH}=="ia64")
 RUN_DEPENDS+=	dmidecode:${PORTSDIR}/sysutils/dmidecode
 .endif
 
-.if ${OSVERSION} <= 601100
+.if ${OSVERSION} <= 3000
 NEEDS_MEDIA=	yes
 PLIST_SUB+=	MEDIA=""
 .else

From ctriv at midnightbsd.org  Thu Jan  1 22:06:56 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:06:56 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020306.n0236uAC075296@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/textproc/enchant:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/textproc/enchant/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L textproc/enchant/Makefile -L textproc/enchant/Makefile -u -r1.2 -r1.3
--- textproc/enchant/Makefile
+++ textproc/enchant/Makefile
@@ -71,11 +71,9 @@
 post-patch:
 	@${REINPLACE_CMD} -e 's|MKDIRPROG-mkdir|MKDIRPROG-mkdir -p|g' \
 		${WRKSRC}/install-sh
-.if ${OSVERSION} < 700042
 	@${REINPLACE_CMD} -E -e "s|-Wunsafe-loop-optimizations ||g" \
 		-e "s|-Wno-missing-field-initializers ||g" \
 		-e "s|-Wno-attributes ||g" \
 			${WRKSRC}/configure
-.endif
 
 .include 

From ctriv at midnightbsd.org  Thu Jan  1 22:08:17 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:08:17 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020308.n0238Hqs075391@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/www/squid:
        Makefile (r1.5 -> r1.6)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/www/squid/Makefile,v
retrieving revision 1.5
retrieving revision 1.6
diff -L www/squid/Makefile -L www/squid/Makefile -u -r1.5 -r1.6
--- www/squid/Makefile
+++ www/squid/Makefile
@@ -254,10 +254,9 @@
 storage_schemes=	ufs diskd null
 .if defined(WITH_SQUID_AUFS)
 storage_schemes+=	aufs
-.if ${OSVERSION}>=501000
-# Only document libmap.conf where it is available:
+
 EXTRA_PATCHES+=		${PATCHDIR}/extra-patch-src-cf.data.pre.aufs
-.endif
+
 # Nil aufs threads is default, set any other value via SQUID_CONFIGURE_ARGS
 CONFIGURE_ARGS+=	--with-pthreads
 CFLAGS+=	${PTHREAD_CFLAGS}
@@ -337,9 +336,6 @@
 .endif
 .if defined(WITH_SQUID_PF)
 CONFIGURE_ARGS+=	--enable-pf-transparent
-.if ${OSVERSION} < 502106
-IGNORE=		pf available only in FreeBSD 5.3 and newer
-.endif
 .endif
 
 .if defined(WITH_SQUID_IPFILTER)

From ctriv at midnightbsd.org  Thu Jan  1 22:10:03 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:10:03 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020310.n023A3np075614@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/x11/gnome-panel:
        Makefile (r1.4 -> r1.5)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/x11/gnome-panel/Makefile,v
retrieving revision 1.4
retrieving revision 1.5
diff -L x11/gnome-panel/Makefile -L x11/gnome-panel/Makefile -u -r1.4 -r1.5
--- x11/gnome-panel/Makefile
+++ x11/gnome-panel/Makefile
@@ -70,12 +70,6 @@
 	@${FIND} ${WRKSRC} -type f | \
 		${XARGS} -n 10 ${REINPLACE_CMD} -e \
 		's|"applications.menu"|"gnome-applications.menu"|'
-.if ( ${OSVERSION} > 600000 && ${OSVERSION} < 600006 ) || \
-	( ${OSVERSION} < 503101 )
-.for po in da.po it.po zh_CN.po zh_TW.po
-	@${REINPLACE_CMD} -e 's|%-|%|g' ${WRKSRC}/po/${po}
-.endfor
-.endif
 
 post-install:
 	${MKDIR} ${PREFIX}/share/gnome-panel

From ctriv at midnightbsd.org  Thu Jan  1 22:11:55 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:11:55 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020311.n023Bt6e075907@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/x11/nvidia-driver:
        Makefile (r1.6 -> r1.7)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/x11/nvidia-driver/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L x11/nvidia-driver/Makefile -L x11/nvidia-driver/Makefile -u -r1.6 -r1.7
--- x11/nvidia-driver/Makefile
+++ x11/nvidia-driver/Makefile
@@ -79,13 +79,8 @@
 post-patch: .SILENT
 # We should support -CURRENT: kill the check
 	${REINPLACE_CMD} '24,26d' ${WRKSRC}/src/nv-freebsd.h
-# Fix `agpvar.h' location on recent -CURRENT
-.if ${OSVERSION} >= 800004
-	${REINPLACE_CMD} -e 's,pci/agpvar\.h,dev/agp/agpvar.h,' \
-		${WRKSRC}/src/nv-freebsd.h
-.endif
 # Building with -Werror requires prototype for suser() which was moved
-.if ${OSVERSION} >= 700048
+.if ${OSVERSION} >= 3000
 	${REINPLACE_CMD} -e '15s,^,#include ,' \
 		${WRKSRC}/src/nvidia_os.c
 .endif

From ctriv at midnightbsd.org  Thu Jan  1 22:17:31 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:17:31 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Cleanup linking with sqlite.
Message-ID: <200901020317.n023HV33076423@stargazer.midnightbsd.org>

Log Message:
-----------
Cleanup linking with sqlite.  Use the system sqlite unless it's an old version
of mbsd.

Modified Files:
--------------
    mports/databases/qt4-sqlite3-plugin:
        Makefile (r1.3 -> r1.4)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/databases/qt4-sqlite3-plugin/Makefile,v
retrieving revision 1.3
retrieving revision 1.4
diff -L databases/qt4-sqlite3-plugin/Makefile -L databases/qt4-sqlite3-plugin/Makefile -u -r1.3 -r1.4
--- databases/qt4-sqlite3-plugin/Makefile
+++ databases/qt4-sqlite3-plugin/Makefile
@@ -21,8 +21,6 @@
 
 FAKE_OPTS=	trueprefix
 
-LIB_DEPENDS+=	sqlite3:${PORTSDIR}/databases/sqlite3
-
 USE_QT_VER=	4
 QT_COMPONENTS=	moc_build sql
 QT_NONSTANDARD=	yes
@@ -34,13 +32,25 @@
 		${DISTNAME}/include/QtSql \
 		${DISTNAME}/src/sql/kernel
 MAKEFILE=	${FILESDIR}/Makefile.bsd
+
+PLIST_SUB=	DB=${DB}
+
+
+.include 
+
+
+# old mbsd versions didn't come with sqlite in core.
+.if ${OSVERSION} < 2000
+LIB_DEPENDS+=	sqlite3:${PORTSDIR}/databases/sqlite3
+.endif
+
 MAKE_ENV+=	DB="${DB}" DRIVER="${DRIVER}" MOC="${MOC}" \
 		PLUGIN="${PLUGIN}" \
 		PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
 		PTHREAD_LIBS="${PTHREAD_LIBS}"
-PLIST_SUB=	DB=${DB}
 
-pre-fake:
-	@${MKDIR} ${FAKE_DESTDIR}${PREFIX}/lib/qt4/plugins/sqldrivers
+pre-install:
+	@${MKDIR} ${PREFIX}/lib/qt4/plugins/sqldrivers
+
 
-.include 
+.include 
\ No newline at end of file

From ctriv at midnightbsd.org  Fri Jan  2 21:13:12 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:13:12 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: graphics/poppler-qt4: add poppler-qt4
Message-ID: <200901030213.n032DCOx010668@stargazer.midnightbsd.org>

Log Message:
-----------
add poppler-qt4

Added Files:
-----------
    mports/graphics/poppler-qt4:
        Makefile (r1.1)
        pkg-plist (r1.1)

-------------- next part --------------
--- /dev/null
+++ graphics/poppler-qt4/pkg-plist
@@ -0,0 +1,12 @@
+ at comment $MidnightBSD: mports/graphics/poppler-qt4/pkg-plist,v 1.1 2009/01/03 02:13:12 ctriv Exp $
+include/poppler/qt4/poppler-qt4.h
+include/poppler/qt4/poppler-link.h
+include/poppler/qt4/poppler-annotation.h
+include/poppler/qt4/poppler-form.h
+include/poppler/qt4/poppler-page-transition.h
+lib/libpoppler-qt4.so.2
+lib/libpoppler-qt4.so
+lib/libpoppler-qt4.la
+lib/libpoppler-qt4.a
+libdata/pkgconfig/poppler-qt4.pc
+ at dirrm include/poppler/qt4
--- /dev/null
+++ graphics/poppler-qt4/Makefile
@@ -0,0 +1,19 @@
+# New ports collection makefile for:	poppler-qt4
+# Date created:		June 26, 2007
+# Whom:			Michael Johnson 
+#
+# $FreeBSD: ports/graphics/poppler-qt4/Makefile,v 1.9 2008/08/04 02:28:00 mezz Exp $
+#   $MCom: ports-stable/graphics/poppler-qt4/Makefile,v 1.3 2008/06/20 17:48:14 mezz Exp $
+#
+
+PORTREVISION=	0
+PKGNAMESUFFIX=	-qt4
+
+MAINTAINER=	gnome at FreeBSD.org
+COMMENT=	Qt4 bindings to poppler
+
+MASTERDIR=	${.CURDIR}/../../graphics/poppler
+SLAVEPORT=	qt4
+PLIST=		${.CURDIR}/pkg-plist
+
+.include "${MASTERDIR}/Makefile"

From ctriv at midnightbsd.org  Fri Jan  2 21:15:15 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:15:15 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: add poppler-qt4
Message-ID: <200901030215.n032FFF8011065@stargazer.midnightbsd.org>

Log Message:
-----------
add poppler-qt4

Modified Files:
--------------
    mports/graphics:
        Makefile (r1.83 -> r1.84)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/graphics/Makefile,v
retrieving revision 1.83
retrieving revision 1.84
diff -L graphics/Makefile -L graphics/Makefile -u -r1.83 -r1.84
--- graphics/Makefile
+++ graphics/Makefile
@@ -93,6 +93,7 @@
     SUBDIR += poppler-data
     SUBDIR += poppler-gtk
     SUBDIR += poppler-qt
+    SUBDIR += poppler-qt4
     SUBDIR += poppler-utils
     SUBDIR += popplerkit
     SUBDIR += py-cairo

From ctriv at midnightbsd.org  Fri Jan  2 21:23:14 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:23:14 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: misc/chmlib: Added chmlib-0.39
Message-ID: <200901030223.n032NE8R011764@stargazer.midnightbsd.org>

Log Message:
-----------
Added chmlib-0.39

Added Files:
-----------
    mports/misc/chmlib:
        Makefile (r1.1)
        distinfo (r1.1)
        pkg-descr (r1.1)
        pkg-plist (r1.1)
    mports/misc/chmlib/files:
        patch-chm_lib.c (r1.1)
        patch-chm_lib.h (r1.1)
        patch-ltmain.sh (r1.1)

-------------- next part --------------
--- /dev/null
+++ misc/chmlib/pkg-descr
@@ -0,0 +1,7 @@
+CHMLIB is a library for dealing with Microsoft ITSS/CHM format files. Right
+now, it is a very simple library, but sufficient for dealing with all of the
+.chm files I've come across. Due to the fairly well-designed indexing built
+into this particular file format, even a small library is able to gain
+reasonably good performance indexing into ITSS archives.
+
+WWW: http://morte.jedrea.com/~jedwin/projects/chmlib/
--- /dev/null
+++ misc/chmlib/pkg-plist
@@ -0,0 +1,9 @@
+bin/chm_http
+bin/enum_chmLib
+bin/enumdir_chmLib
+bin/extract_chmLib
+bin/test_chmLib
+include/chm_lib.h
+include/lzx.h
+lib/libchm.so
+lib/libchm.so.0
--- /dev/null
+++ misc/chmlib/Makefile
@@ -0,0 +1,24 @@
+# ex:ts=8
+#
+# $MidnightBSD: mports/misc/chmlib/Makefile,v 1.1 2009/01/03 02:23:12 ctriv Exp $
+#
+
+PORTNAME=	chmlib
+PORTVERSION=	0.39
+CATEGORIES=	misc
+MASTER_SITES=	http://www.jedrea.com/chmlib/
+
+MAINTAINER=	ports at MidnightBSD.org
+COMMENT=	A library for dealing with Microsoft ITSS/CHM format files
+LICENSE=	lgpl
+
+USE_BZIP2=	yes
+GNU_CONFIGURE=	yes
+CONFIGURE_ARGS=	--disable-io64 --disable-pread --exec-prefix=${PREFIX} --disable-static --enable-examples
+USE_GMAKE=	yes
+USE_LDCONFIG=	yes
+
+post-patch:
+	@${REINPLACE_CMD} -e "s,-lpthread,${PTHREAD_LIBS}," ${WRKSRC}/configure
+
+.include 
--- /dev/null
+++ misc/chmlib/distinfo
@@ -0,0 +1,3 @@
+MD5 (chmlib-0.39.tar.bz2) = debed1a0bdded7a12d3d967e497cea9c
+SHA256 (chmlib-0.39.tar.bz2) = d2305d449eb5a2922ed3e61714074b09aae2491aa0cdbb783ab33a1744e0ff41
+SIZE (chmlib-0.39.tar.bz2) = 263013
--- /dev/null
+++ misc/chmlib/files/patch-ltmain.sh
@@ -0,0 +1,15 @@
+--- ltmain.sh.orig	Mon Jun 19 09:26:24 2006
++++ ltmain.sh	Mon Jun 19 09:26:40 2006
+@@ -6003,10 +6003,12 @@
+ 	fi
+ 
+ 	# Install the pseudo-library for information purposes.
++	if /usr/bin/false ; then
+ 	name=`$echo "X$file" | $Xsed -e 's%^.*/%%'`
+ 	instname="$dir/$name"i
+ 	$show "$install_prog $instname $destdir/$name"
+ 	$run eval "$install_prog $instname $destdir/$name" || exit $?
++	fi
+ 
+ 	# Maybe install the static library, too.
+ 	test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library"
--- /dev/null
+++ misc/chmlib/files/patch-chm_lib.h
@@ -0,0 +1,25 @@
+--- src/chm_lib.h.orig	Fri Feb 25 21:26:09 2005
++++ src/chm_lib.h	Fri Feb 25 21:26:57 2005
+@@ -78,6 +78,12 @@
+     char               path[CHM_MAX_PATHLEN+1];
+ };
+ 
++typedef struct chmUnitInfo chmUnitInfo;
++typedef struct chm_dir {
++  int nentries;
++  char **info;
++} chm_dir;
++
+ /* open an ITS archive */
+ #ifdef PPC_BSTR
+ /* RWE 6/12/2003 */
+@@ -133,6 +139,7 @@
+                       CHM_ENUMERATOR e,
+                       void *context);
+ 
++chm_dir get_names(struct chmFile *h);
+ #ifdef __cplusplus
+ }
+ #endif
+
+
--- /dev/null
+++ misc/chmlib/files/patch-chm_lib.c
@@ -0,0 +1,20 @@
+--- src/chm_lib.c.orig	Tue Apr  8 10:33:30 2003
++++ src/chm_lib.c	Tue Apr  8 10:40:56 2003
+@@ -156,6 +156,17 @@
+ typedef __int64                 Int64;
+ typedef unsigned __int64        UInt64;
+ 
++/* FreeBSD */
++#elif __FreeBSD__
++#include 
++typedef unsigned char           UChar;
++typedef int16_t                 Int16;
++typedef uint16_t                UInt16;
++typedef int32_t                 Int32;
++typedef uint32_t                UInt32;
++typedef int64_t                 Int64;
++typedef uint64_t                UInt64;
++
+ /* I386, 32-bit, non-Windows */
+ /* Sparc        */
+ /* MIPS         */

From ctriv at midnightbsd.org  Fri Jan  2 21:23:28 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:23:28 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: added: chmlib,
	koffice-i18n-sr@Latn, wmweather+.
Message-ID: <200901030223.n032NSbS011814@stargazer.midnightbsd.org>

Log Message:
-----------
added: chmlib, koffice-i18n-sr at Latn, wmweather+.

Modified Files:
--------------
    mports/misc:
        Makefile (r1.52 -> r1.53)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/misc/Makefile,v
retrieving revision 1.52
retrieving revision 1.53
diff -L misc/Makefile -L misc/Makefile -u -r1.52 -r1.53
--- misc/Makefile
+++ misc/Makefile
@@ -4,6 +4,7 @@
     COMMENT = Miscellaneous utilities
 
     SUBDIR += brs
+    SUBDIR += chmlib
     SUBDIR += compat4x
     SUBDIR += compat5x
     SUBDIR += cpuid

From smultron at midnightbsd.org  Fri Jan  2 21:23:35 2009
From: smultron at midnightbsd.org (smultron at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:23:35 -0500 (EST)
Subject: [Midnightbsd-cvs] www: /www: add xfce to featured
Message-ID: <200901030223.n032NZhl011884@stargazer.midnightbsd.org>

Log Message:
-----------
add xfce to featured

Modified Files:
--------------
    www:
        index.html (r1.62 -> r1.63)
    www/images/ports:
        001.png (r1.1 -> r1.2)
    www/featured:
        index.html (r1.6 -> r1.7)

-------------- next part --------------
Index: index.html
===================================================================
RCS file: /home/cvs/www/index.html,v
retrieving revision 1.62
retrieving revision 1.63
diff -L index.html -L index.html -u -r1.62 -r1.63
--- index.html
+++ index.html
@@ -49,6 +49,7 @@
 				
 				
Index: index.html =================================================================== RCS file: /home/cvs/www/featured/index.html,v retrieving revision 1.6 retrieving revision 1.7 diff -L featured/index.html -L featured/index.html -u -r1.6 -r1.7 --- featured/index.html +++ featured/index.html @@ -29,6 +29,13 @@

Featured Ports

+ -

Software descriptions taken from their respective Wikipedia articles


From ctriv at midnightbsd.org Fri Jan 2 21:40:53 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Fri, 2 Jan 2009 21:40:53 -0500 (EST) Subject: [Midnightbsd-cvs] mports: graphics/djvulibre-nox11: Added djvulibre-nox11-3.5.21 Message-ID: <200901030240.n032erHg013723@stargazer.midnightbsd.org> Log Message: ----------- Added djvulibre-nox11-3.5.21 Added Files: ----------- mports/graphics/djvulibre-nox11: Makefile (r1.1) distinfo (r1.1) pkg-descr (r1.1) pkg-plist (r1.1) mports/graphics/djvulibre-nox11/files: patch-config_ltmain.sh (r1.1) patch-configure (r1.1) patch-desktopfiles_Makefile.in (r1.1) patch-tools_any2djvu (r1.1) -------------- next part -------------- --- /dev/null +++ graphics/djvulibre-nox11/pkg-descr @@ -0,0 +1,14 @@ +DjVu is a web-centric format and software platform for distributing +documents and images. DjVu was originally developped at AT&T +Labs-Research. In March 2000, AT&T sold DjVu to LizardTech Inc. who +now distributes Windows/Mac plug-ins, and commercial encoders (mostly +on Windows) + +The LizardTech released the reference implementation of DjVu under +the GNU GPL in October 2000. DjVuLibre (which means free DjVu), is +an enhanced version of that code maintained by the original inventors +of DjVu. It is compatible with version 3.5 of the LizardTech DjVu +software suite. + +Author: Leon Bottou +WWW: http://djvu.sourceforge.net/ --- /dev/null +++ graphics/djvulibre-nox11/pkg-plist @@ -0,0 +1,62 @@ +%%ANY2DJVU%%bin/any2djvu +bin/bzz +bin/c44 +bin/cjb2 +bin/cpaldjvu +bin/csepdjvu +bin/ddjvu +bin/djvm +bin/djvmcvt +bin/djvudigital +bin/djvudump +bin/djvuextract +bin/djvumake +bin/djvups +bin/djvused +bin/djvuserve +bin/djvutoxml +bin/djvutxt +bin/djvuxmlparser +include/libdjvu/ddjvuapi.h +include/libdjvu/miniexp.h +lib/libdjvulibre.so +lib/libdjvulibre.so.21 +libdata/pkgconfig/ddjvuapi.pc +share/djvu/osi/cs/messages.xml +share/djvu/osi/de/libdjvu++.xml +share/djvu/osi/de/messages.xml +share/djvu/osi/desktop/djvulibre-mime.xml +share/djvu/osi/desktop/hi22-djvu.png +share/djvu/osi/desktop/hi32-djvu.png +share/djvu/osi/desktop/hi48-djvu.png +share/djvu/osi/desktop/register-djvu-mime +share/djvu/osi/en/djvutools-reference.xml +share/djvu/osi/en/libdjvu++.xml +share/djvu/osi/en/messages.xml +share/djvu/osi/en/unixgui-shared.xml +share/djvu/osi/en/unixgui-viewer.xml +share/djvu/osi/fr/libdjvu++.xml +share/djvu/osi/fr/messages.xml +share/djvu/osi/ja/libdjvu++.xml +share/djvu/osi/ja/messages.xml +share/djvu/osi/languages.xml +share/djvu/osi/zh/libdjvu++.xml +share/djvu/osi/zh/messages.xml +share/djvu/pubtext/DjVuMessages.dtd +share/djvu/pubtext/DjVuOCR.dtd +share/djvu/pubtext/DjVuXML-s.dtd + at dirrm share/djvu/pubtext + at dirrm share/djvu/osi/zh + at dirrm share/djvu/osi/ja + at dirrm share/djvu/osi/fr + at dirrm share/djvu/osi/en + at dirrm share/djvu/osi/desktop + at dirrm share/djvu/osi/de + at dirrm share/djvu/osi/cs + at dirrm share/djvu/osi + at dirrmtry share/djvu + at dirrmtry man/fr/man1 + at dirrmtry man/fr + at dirrmtry man/de/man1 + at dirrmtry man/de + at dirrm include/libdjvu --- /dev/null +++ graphics/djvulibre-nox11/Makefile @@ -0,0 +1,82 @@ +# Date Created: 20 July 1999 +# +# $MidnightBSD: mports/graphics/djvulibre-nox11/Makefile,v 1.1 2009/01/03 02:40:50 ctriv Exp $ +# + +PORTNAME= djvulibre +PORTVERSION= 3.5.21 +PORTREVISION= 0 +CATEGORIES= graphics www +MASTER_SITES= SF/djvu +PKGNAMESUFFIX= -nox11 + +MAINTAINER= ports at MidnightBSD.org +COMMENT= DjVu base libraries and utilities +LICENSE= gpl2 + +LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg \ + tiff.4:${PORTSDIR}/graphics/tiff + +USE_ICONV= yes +USE_GNOME= gnomehack gnometarget +GNU_CONFIGURE= yes +CONFIGURE_ENV= JPEG_CFLAGS="-I${LOCALBASE}/include" \ + JPEG_LIBS="-L${LOCALBASE}/lib -ljpeg" \ + TIFF_CFLAGS="-I${LOCALBASE}/include" \ + TIFF_LIBS="-L${LOCALBASE}/lib -ltiff" \ + PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \ + PTHREAD_LIBS="${PTHREAD_LIBS}" \ + LOCALBASE="${LOCALBASE}" \ + CXX="${CXX}" +CONFIGURE_ARGS= --enable-threads=pthread --enable-shared +USE_LDCONFIG= yes + +OPTIONS= ANY2DJVU "Install any2djvu script (requires curl)" off + +MANLANG= "" ja +MAN1= bzz.1 c44.1 cjb2.1 cpaldjvu.1 csepdjvu.1 ddjvu.1 djvm.1 \ + djvmcvt.1 djvu.1 djvudump.1 djvuextract.1 djvumake.1 djvups.1 \ + djvused.1 djvuserve.1 djvutxt.1 +MAN1_EN= djvutoxml.1 djvuxml.1 djvuxmlparser.1 djvudigital.1 + +PORTDOCS= djvu2spec.djvu lizard2002.djvu + +CONFIGURE_ARGS+= --disable-djview --without-x + +.include + +.if defined(WITH_ANY2DJVU) +MAN1_EN+= any2djvu.1 +RUN_DEPENDS+= curl:${PORTSDIR}/ftp/curl +PLIST_SUB+= ANY2DJVU="" +.else +PLIST_SUB+= ANY2DJVU="@comment " +.endif + +post-patch: + @${REINPLACE_CMD} -e \ + 's|$${libdir}/pkgconfig|${PREFIX}/libdata/pkgconfig|' \ + ${WRKSRC}/libdjvu/Makefile.in + @${REINPLACE_CMD} -e '/-O\*/d ; \ + s|$$OPTS -O3|$$OPTS|g ; \ + s|$$OPTS -O2|$$OPTS|g ; \ + s|$$OPTS $$opt|$$OPTS|g' ${WRKSRC}/configure + @${FIND} ${WRKSRC} -name "Makefile.in" | ${XARGS} ${REINPLACE_CMD} -e \ + 's|= @CPPFLAGS|= $${FLAGS} @CPPFLAGS|g ; \ + s|@ $${FLAGS}|@|g ; \ + s|} $${FLAGS}|}|g ; \ + s|/netscape/|/djvulibre/|g ; \ + s|eucjp|eucJP|g ; \ + s|_PROGRAM} -m|} -m|g' +.if !defined(WITH_ANY2DJVU) + @${REINPLACE_CMD} -e 's,any2djvu,,' ${WRKSRC}/tools/Makefile.in +.endif + + +post-install: +.if !defined(NOPORTDOCS) + @${MKDIR} ${DOCSDIR} + ${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/doc/,} ${DOCSDIR}/ +.endif + +.include --- /dev/null +++ graphics/djvulibre-nox11/distinfo @@ -0,0 +1,3 @@ +MD5 (djvulibre-3.5.21.tar.gz) = 4c6f3eb03ffbd067b6d2fe2344b0d9ad +SHA256 (djvulibre-3.5.21.tar.gz) = 39f80c1810be22c5ea7f6a44bbb449c3e29902895dcff9da6a8440891a67b8b4 +SIZE (djvulibre-3.5.21.tar.gz) = 2993718 --- /dev/null +++ graphics/djvulibre-nox11/files/patch-tools_any2djvu @@ -0,0 +1,95 @@ +--- tools/any2djvu.orig 2008-02-17 20:18:08.000000000 +0300 ++++ tools/any2djvu 2008-02-17 20:20:31.000000000 +0300 +@@ -1,11 +1,11 @@ +-#! /bin/bash -f ++#!/bin/sh + # CVS version control block - do not edit manually + # $RCSfile: any2djvu,v $ + # $Revision: 1.3 $ + # $Date: 2007/08/10 08:08:55 $ + # $Source: /cvsroot/djvu/djvulibre-3.5/tools/any2djvu,v $ + +-function copyright() ++copyright() + { + echo "Copyright (C) 2002 David Kreil " + echo "Modified by Barak A. Pearlmutter " +@@ -14,7 +14,7 @@ + echo "Released under the GNU GPL v2, 21-Oct-2002." + } + +-function warranty() ++warranty() + { + echo "This program is distributed in the hope that it will be useful," + echo "but WITHOUT ANY WARRANTY; without even the implied warranty of" +@@ -22,7 +22,7 @@ + echo "GNU General Public License for more details." + } + +-function disclaimer() ++disclaimer() + { + echo "By using this tool you accept the following disclaimer:" + echo " Because the any2djvu service is free of charge, there is no" +@@ -40,7 +40,7 @@ + ocr=1 + docformat=2 + +-function warn() ++warn() + { + echo "Notes:" + echo " - Internet connection is required." +@@ -53,7 +53,7 @@ + echo " - This software comes with NO WARRANTY." + } + +-function format_help() ++format_help() + { + echo "Codes for the formats of the input documents to use with -f" + echo " 1 - DjVu Document (for verification or OCR)" +@@ -67,7 +67,7 @@ + echo " 9 - Scanned Document - Color/Mixed - >400 dpi" + } + +-function usage() ++usage() + { + echo "Convert files from .ps/.ps.gz/.pdf to .djvu" + echo "Usage: $0 [options] [url] {filename(s)}" +@@ -123,13 +123,13 @@ + fi + + # check OCR option +-if [ ! "x$ocr" == x0 ] && [ ! "x$ocr" == x1 ]; then ++if [ ! "x$ocr" = x0 ] && [ ! "x$ocr" = x1 ]; then + echo 'error: -o OCR must be 0 or 1' + exit 2 + fi + + # if help is requested or docformat is not specified right - show help +-if [ "x$docformat" == x'help' ]; then ++if [ "x$docformat" = x'help' ]; then + format_help + exit 0 + fi +@@ -215,7 +215,7 @@ + -F ocr=$ocr -F legal=1 "$rurl/$rcgi" \ + | eval tee "'$log'" $shellopts + else +- wget $wgetopts -O - "$rurl/$rcgi?urlupload=$lurl/$in$cgiopts" \ ++ /usr/bin/fetch$wgetopts -o - "$rurl/$rcgi?urlupload=$lurl/$in$cgiopts" \ + | eval tee "'$log'" $shellopts + fi + l=`egrep 'href=djvu/.*\.djvu' "$log"` +@@ -225,7 +225,7 @@ + echo "error: something got wrong. check log file" + exit 1 + fi +- wget $wgetopts -O "$b.djvu" "$rurl/$l" ++ /usr/bin/fetch $wgetopts -o $b.djvu "$rurl/$l" + + [ -z "$doclean" ] || rm "$log" + [ -z $silent ] && ls -l "$b.djvu" --- /dev/null +++ graphics/djvulibre-nox11/files/patch-desktopfiles_Makefile.in @@ -0,0 +1,28 @@ +--- desktopfiles/Makefile.in.orig 2007-09-10 20:23:30.000000000 +0400 ++++ desktopfiles/Makefile.in 2007-09-10 20:55:26.000000000 +0400 +@@ -29,6 +29,7 @@ + + INSTALL = @INSTALL@ + INSTALL_PROGRAM = @INSTALL_PROGRAM@ ++INSTALL_SCRIPT = @INSTALL_SCRIPT@ + INSTALL_DATA = @INSTALL_DATA@ + XDG_MIME = @XDG_MIME@ + XDG_ICON_RESOURCE = @XDG_ICON_RESOURCE@ +@@ -71,7 +72,7 @@ + + install-djvu-files: FORCE + ${INSTALL} -d ${DESTDIR}${datadir_djvu} +- ${INSTALL_PROGRAM} register-djvu-mime ${DESTDIR}${datadir_djvu} ++ ${INSTALL_SCRIPT} register-djvu-mime ${DESTDIR}${datadir_djvu} + ${INSTALL_DATA} ${srcdir}/*djvu.png ${DESTDIR}${datadir_djvu} + ${INSTALL_DATA} ${srcdir}/*mime.xml ${DESTDIR}${datadir_djvu} + - at echo "Run ${datadir_djvu}/register-djvu-mime install" +@@ -79,7 +80,7 @@ + + install-djview-files: FORCE + ${INSTALL} -d ${DESTDIR}${datadir_djview} +- ${INSTALL_PROGRAM} register-djview-menu ${DESTDIR}${datadir_djview} ++ ${INSTALL_SCRIPT} register-djview-menu ${DESTDIR}${datadir_djview} + ${INSTALL_DATA} ${srcdir}/*djview3.png ${DESTDIR}${datadir_djview} + ${INSTALL_DATA} ${srcdir}/*djview3.desktop ${DESTDIR}${datadir_djview} + - at echo "Run ${datadir_djview}/register-djview-menu install" --- /dev/null +++ graphics/djvulibre-nox11/files/patch-configure @@ -0,0 +1,10 @@ +--- configure.orig 2008-08-26 14:48:20.000000000 +0400 ++++ configure 2008-08-26 14:48:36.000000000 +0400 +@@ -21689,6 +21689,7 @@ + __sync_lock_test_and_set(&l,1); + __sync_lock_release(&l); + __sync_add_and_fetch(&l,1); ++ __sync_bool_compare_and_swap(&l,&l,1); + return 0; + ; + return 0; --- /dev/null +++ graphics/djvulibre-nox11/files/patch-config_ltmain.sh @@ -0,0 +1,17 @@ +--- config/ltmain.sh.orig 2008-08-26 16:13:33.000000000 +0400 ++++ config/ltmain.sh 2008-08-26 16:14:40.000000000 +0400 +@@ -6002,14 +6002,6 @@ + IFS="$save_ifs" + fi + +- # Install the pseudo-library for information purposes. +- name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` +- instname="$dir/$name"i +- $show "$install_prog $instname $destdir/$name" +- $run eval "$install_prog $instname $destdir/$name" || exit $? +- +- # Maybe install the static library, too. +- test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" + ;; + + *.lo) From ctriv at midnightbsd.org Fri Jan 2 21:42:35 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Fri, 2 Jan 2009 21:42:35 -0500 (EST) Subject: [Midnightbsd-cvs] mports: Makefile: add djvulibre-nox11 Message-ID: <200901030242.n032gZZp013837@stargazer.midnightbsd.org> Log Message: ----------- add djvulibre-nox11 Modified Files: -------------- mports/graphics: Makefile (r1.84 -> r1.85) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/graphics/Makefile,v retrieving revision 1.84 retrieving revision 1.85 diff -L graphics/Makefile -L graphics/Makefile -u -r1.84 -r1.85 --- graphics/Makefile +++ graphics/Makefile @@ -11,6 +11,7 @@ SUBDIR += cairo SUBDIR += cairomm SUBDIR += dia + SUBDIR += djvulibre-nox11 SUBDIR += dri SUBDIR += eog SUBDIR += etoile-distributedview From ctriv at midnightbsd.org Fri Jan 2 21:47:18 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Fri, 2 Jan 2009 21:47:18 -0500 (EST) Subject: [Midnightbsd-cvs] mports: bsd.mport.mk: Display the various stage messages in bold. Message-ID: <200901030247.n032lIf8014295@stargazer.midnightbsd.org> Log Message: ----------- Display the various stage messages in bold. Modified Files: -------------- mports/Mk: bsd.mport.mk (r1.132 -> r1.133) -------------- next part -------------- Index: bsd.mport.mk =================================================================== RCS file: /home/cvs/mports/Mk/bsd.mport.mk,v retrieving revision 1.132 retrieving revision 1.133 diff -L Mk/bsd.mport.mk -L Mk/bsd.mport.mk -u -r1.132 -r1.133 --- Mk/bsd.mport.mk +++ Mk/bsd.mport.mk @@ -2919,25 +2919,25 @@ .ORDER: ${_INSTALL_DEP} ${_INSTALL_SEQ} extract-message: - @${ECHO_MSG} "===> Extracting for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Extracting for ${PKGNAME}\033[0m" patch-message: - @${ECHO_MSG} "===> Patching for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Patching for ${PKGNAME}\033[0m" configure-message: - @${ECHO_MSG} "===> Configuring for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Configuring for ${PKGNAME}\033[0m" build-message: - @${ECHO_MSG} "===> Building for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Building for ${PKGNAME}\033[0m" fake-message: - @${ECHO_MSG} "===> Faking install for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Faking install for ${PKGNAME}\033[0m" install-message: .if !defined(DESTDIR) - @${ECHO_MSG} "===> Installing ${PKGFILE}" + @${ECHO_MSG} -e "\033[1m===> Installing ${PKGFILE}\033[0m" .else - @${ECHO_MSG} "===> Installing ${PKGFILE} into ${DESTDIR}" + @${ECHO_MSG} -e "\033[1m===> Installing ${PKGFILE} into ${DESTDIR}\033[0m" .endif package-message: - @${ECHO_MSG} "===> Building package for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Building package for ${PKGNAME}\033[0m" done-message: - @${ECHO_MSG} "===> Done." + @${ECHO_MSG} -e "\033[1m===> Done.\033[0m" # Empty pre-* and post-* targets From smultron at midnightbsd.org Fri Jan 2 21:56:10 2009 From: smultron at midnightbsd.org (smultron at midnightbsd.org) Date: Fri, 2 Jan 2009 21:56:10 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: corrected description Message-ID: <200901030256.n032uAYs015278@stargazer.midnightbsd.org> Log Message: ----------- corrected description Modified Files: -------------- www/featured: index.html (r1.7 -> r1.8) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/featured/index.html,v retrieving revision 1.7 retrieving revision 1.8 diff -L featured/index.html -L featured/index.html -u -r1.7 -r1.8 --- featured/index.html +++ featured/index.html @@ -34,7 +34,7 @@ -

is a free software desktop environment for Unix and other Unix-like platforms, such as Linux, Solaris and BSD. It aims to be fast and lightweight, while still being visually appealing and easy to use. It is based on the GTK+ 2 toolkit (as is GNOME). It uses the Xfwm window manager, described below. Its configuration is entirely mouse-driven, and the configuration files are hidden from the casual user.

+

Xfce is a free software desktop environment for Unix and other Unix-like platforms, such as Linux, Solaris and BSD. It aims to be fast and lightweight, while still being visually appealing and easy to use. It is based on the GTK+ 2 toolkit (as is GNOME). It uses the Xfwm window manager, described below. Its configuration is entirely mouse-driven, and the configuration files are hidden from the casual user.

+ + + + + From laffer1 at midnightbsd.org Sat Jan 10 21:25:50 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:25:50 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: use footer include Message-ID: <200901110225.n0B2PoLD086588@stargazer.midnightbsd.org> Log Message: ----------- use footer include Modified Files: -------------- www: index.html (r1.63 -> r1.64) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/index.html,v retrieving revision 1.63 retrieving revision 1.64 diff -L index.html -L index.html -u -r1.63 -r1.64 --- index.html +++ index.html @@ -63,10 +63,10 @@

Security »

-

December 31, 2008

-

Correct a problem where bluetooth and netgraph sockets...

-

Read more...

-
+

December 31, 2008

+

Correct a problem where bluetooth and netgraph sockets...

+

Read more...

+

November 24, 2008

Correct a problem in arc4random which causes the device...

@@ -74,42 +74,6 @@
-

-
- - - - - - - + From laffer1 at midnightbsd.org Sat Jan 10 21:31:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:31:19 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: Add new security advisory. Message-ID: <200901110231.n0B2VJQq087128@stargazer.midnightbsd.org> Log Message: ----------- Add new security advisory. Fix footer. Modified Files: -------------- www/security: index.html (r1.12 -> r1.13) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/security/index.html,v retrieving revision 1.12 retrieving revision 1.13 diff -L security/index.html -L security/index.html -u -r1.12 -r1.13 --- security/index.html +++ security/index.html @@ -14,13 +14,19 @@
-
+

Security Updates

+
+

January 10, 2009

+

Fix two issues with MidnightBSD 0.2.1 and 0.3-CURRENT. The first is in OpenSSL and would allow applications that use OpenSSL to interpret an + invalid certificate as valid. The second is in lukemftpd(8) + that could allow long commands to be split into multiple commands.

+
-

December 31, 2008

-

Correct a problem where bluetooth and netgraph sockets were not initialized properly. This is available in RELENG_0_2, RELENG_0_1, and current.

-
+

December 31, 2008

+

Correct a problem where bluetooth and netgraph sockets were not initialized properly. This is available in RELENG_0_2, RELENG_0_1, and current.

+

November 24, 2008

Correct a problem in arc4random which causes the device not to get enough entropy for system services. ?Geom classes initialized at startup will still have problems. Update your system to @@ -114,42 +120,6 @@

A "symlink" exploit was found in the MidnightBSD jail system. A fix was made available. Please update your /etc/rc.d/jail file from cvs. Patches will not be created until our first release.

-

-
- -
- - - - - + From laffer1 at midnightbsd.org Sat Jan 10 21:40:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:40:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/netinet6: IPV6 and arc4random Message-ID: <200901110240.n0B2etoc088157@stargazer.midnightbsd.org> Log Message: ----------- IPV6 and arc4random Modified Files: -------------- src/sys/dev/random: randomdev.c (r1.2 -> r1.3) randomdev_soft.c (r1.4 -> r1.5) src/sys/netinet6: in6.h (r1.5 -> r1.6) in6_proto.c (r1.4 -> r1.5) nd6.h (r1.3 -> r1.4) nd6_nbr.c (r1.3 -> r1.4) -------------- next part -------------- Index: randomdev.c =================================================================== RCS file: /home/cvs/src/sys/dev/random/randomdev.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/random/randomdev.c -L sys/dev/random/randomdev.c -u -r1.2 -r1.3 --- sys/dev/random/randomdev.c +++ sys/dev/random/randomdev.c @@ -90,6 +90,7 @@ && (securelevel_gt(td->td_ucred, 0) == 0)) { (*random_systat.reseed)(); random_systat.seeded = 1; + arc4rand(NULL, 0, 1); /* Reseed arc4random as well. */ } return (0); Index: randomdev_soft.c =================================================================== RCS file: /home/cvs/src/sys/dev/random/randomdev_soft.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/random/randomdev_soft.c -L sys/dev/random/randomdev_soft.c -u -r1.4 -r1.5 --- sys/dev/random/randomdev_soft.c +++ sys/dev/random/randomdev_soft.c @@ -61,6 +61,7 @@ u_int, u_int, enum esource); static int random_yarrow_poll(int event,struct thread *td); static int random_yarrow_block(int flag); +static void random_yarrow_flush_reseed(void); struct random_systat random_yarrow = { .ident = "Software, Yarrow", @@ -70,7 +71,7 @@ .read = random_yarrow_read, .write = random_yarrow_write, .poll = random_yarrow_poll, - .reseed = random_yarrow_reseed, + .reseed = random_yarrow_flush_reseed, .seeded = 1, }; @@ -96,7 +97,7 @@ /* Harvested entropy */ static struct entropyfifo harvestfifo[ENTROPYSOURCE]; -/* <0 to end the kthread, 0 to let it run */ +/* <0 to end the kthread, 0 to let it run, 1 to flush the harvest queues */ static int random_kthread_control = 0; static struct proc *random_kthread_proc; @@ -241,7 +242,7 @@ local_count = 0; /* Process until told to stop */ - for (; random_kthread_control == 0;) { + for (; random_kthread_control >= 0;) { active = 0; @@ -276,6 +277,13 @@ KASSERT(local_count == 0, ("random_kthread: local_count %d", local_count)); + /* + * If a queue flush was commanded, it has now happened, + * and we can mark this by resetting the command. + */ + if (random_kthread_control == 1) + random_kthread_control = 0; + /* Found nothing, so don't belabour the issue */ if (!active) pause("-", hz / 10); @@ -400,3 +408,15 @@ return error; } + +/* Helper routine to perform explicit reseeds */ +static void +random_yarrow_flush_reseed(void) +{ + /* Command a entropy queue flush and wait for it to finish */ + random_kthread_control = 1; + while (random_kthread_control) + pause("-", hz / 10); + + random_yarrow_reseed(); +} Index: in6_proto.c =================================================================== RCS file: /home/cvs/src/sys/netinet6/in6_proto.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/netinet6/in6_proto.c -L sys/netinet6/in6_proto.c -u -r1.4 -r1.5 --- sys/netinet6/in6_proto.c +++ sys/netinet6/in6_proto.c @@ -393,6 +393,7 @@ #ifdef IPSTEALTH int ip6stealth = 0; #endif +int nd6_onlink_ns_rfc4861 = 0; /* allow 'on-link' nd6 NS (as in RFC 4861) */ /* icmp6 */ /* @@ -566,3 +567,6 @@ nd6_maxnudhint, CTLFLAG_RW, &nd6_maxnudhint, 0, ""); SYSCTL_INT(_net_inet6_icmp6, ICMPV6CTL_ND6_DEBUG, nd6_debug, CTLFLAG_RW, &nd6_debug, 0, ""); +SYSCTL_INT(_net_inet6_icmp6, ICMPV6CTL_ND6_ONLINKNSRFC4861, + nd6_onlink_ns_rfc4861, CTLFLAG_RW, &nd6_onlink_ns_rfc4861, 0, + "Accept 'on-link' nd6 NS in compliance with RFC 4861."); Index: in6.h =================================================================== RCS file: /home/cvs/src/sys/netinet6/in6.h,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/netinet6/in6.h -L sys/netinet6/in6.h -u -r1.5 -r1.6 --- sys/netinet6/in6.h +++ sys/netinet6/in6.h @@ -600,7 +600,9 @@ /* New entries should be added here from current IPV6CTL_MAXID value. */ /* to define items, should talk with KAME guys first, for *BSD compatibility */ #define IPV6CTL_STEALTH 45 -#define IPV6CTL_MAXID 46 + +#define ICMPV6CTL_ND6_ONLINKNSRFC4861 47 +#define IPV6CTL_MAXID 48 #endif /* __BSD_VISIBLE */ /* Index: nd6_nbr.c =================================================================== RCS file: /home/cvs/src/sys/netinet6/nd6_nbr.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/netinet6/nd6_nbr.c -L sys/netinet6/nd6_nbr.c -u -r1.3 -r1.4 --- sys/netinet6/nd6_nbr.c +++ sys/netinet6/nd6_nbr.c @@ -144,6 +144,24 @@ "(wrong ip6 dst)\n")); goto bad; } + } else if (!nd6_onlink_ns_rfc4861) { + struct sockaddr_in6 src_sa6; + + /* + * According to recent IETF discussions, it is not a good idea + * to accept a NS from an address which would not be deemed + * to be a neighbor otherwise. This point is expected to be + * clarified in future revisions of the specification. + */ + bzero(&src_sa6, sizeof(src_sa6)); + src_sa6.sin6_family = AF_INET6; + src_sa6.sin6_len = sizeof(src_sa6); + src_sa6.sin6_addr = saddr6; + if (!nd6_is_addr_neighbor(&src_sa6, ifp)) { + nd6log((LOG_INFO, "nd6_ns_input: " + "NS packet from non-neighbor\n")); + goto bad; + } } if (IN6_IS_ADDR_MULTICAST(&taddr6)) { Index: nd6.h =================================================================== RCS file: /home/cvs/src/sys/netinet6/nd6.h,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/netinet6/nd6.h -L sys/netinet6/nd6.h -u -r1.3 -r1.4 --- sys/netinet6/nd6.h +++ sys/netinet6/nd6.h @@ -340,6 +340,7 @@ extern struct nd_drhead nd_defrouter; extern struct nd_prhead nd_prefix; extern int nd6_debug; +extern int nd6_onlink_ns_rfc4861; #define nd6log(x) do { if (nd6_debug) log x; } while (/*CONSTCOND*/ 0) From laffer1 at midnightbsd.org Sat Jan 10 21:41:57 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:41:57 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/netinet6: icmp ipv6 Message-ID: <200901110241.n0B2fvlI088249@stargazer.midnightbsd.org> Log Message: ----------- icmp ipv6 Modified Files: -------------- src/sys/netinet6: icmp6.c (r1.4 -> r1.5) icmp6.c.orig (r1.1 -> r1.2) -------------- next part -------------- Index: icmp6.c.orig =================================================================== RCS file: /home/cvs/src/sys/netinet6/icmp6.c.orig,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/netinet6/icmp6.c.orig -L sys/netinet6/icmp6.c.orig -u -r1.1 -r1.2 --- sys/netinet6/icmp6.c.orig +++ sys/netinet6/icmp6.c.orig @@ -1,3 +1,4 @@ +/* $MidnightBSD$ */ /* $FreeBSD: src/sys/netinet6/icmp6.c,v 1.80 2007/07/05 16:29:39 delphij Exp $ */ /* $KAME: icmp6.c,v 1.211 2001/04/04 05:56:20 itojun Exp $ */ Index: icmp6.c =================================================================== RCS file: /home/cvs/src/sys/netinet6/icmp6.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/netinet6/icmp6.c -L sys/netinet6/icmp6.c -u -r1.4 -r1.5 --- sys/netinet6/icmp6.c +++ sys/netinet6/icmp6.c @@ -1118,6 +1118,15 @@ if (!validated) return; + /* + * In case the suggested mtu is less than IPV6_MMTU, we + * only need to remember that it was for above mentioned + * "alwaysfrag" case. + * Try to be as close to the spec as possible. + */ + if (mtu < IPV6_MMTU) + mtu = IPV6_MMTU - 8; + bzero(&inc, sizeof(inc)); inc.inc_flags = 1; /* IPv6 */ inc.inc6_faddr = *dst; From laffer1 at midnightbsd.org Sat Jan 10 21:42:32 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:42:32 -0500 (EST) Subject: [Midnightbsd-cvs] src: icmp6.c.orig: doh Message-ID: <200901110242.n0B2gWZN088329@stargazer.midnightbsd.org> Log Message: ----------- doh Removed Files: ------------- src/sys/netinet6: icmp6.c.orig -------------- next part -------------- --- sys/netinet6/icmp6.c.orig +++ /dev/null @@ -1,2785 +0,0 @@ -/* $MidnightBSD: src/sys/netinet6/icmp6.c.orig,v 1.2 2009/01/11 02:41:57 laffer1 Exp $ */ -/* $FreeBSD: src/sys/netinet6/icmp6.c,v 1.80 2007/07/05 16:29:39 delphij Exp $ */ -/* $KAME: icmp6.c,v 1.211 2001/04/04 05:56:20 itojun Exp $ */ - -/*- - * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the project nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -/*- - * Copyright (c) 1982, 1986, 1988, 1993 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#)ip_icmp.c 8.2 (Berkeley) 1/4/94 - */ - -#include "opt_inet.h" -#include "opt_inet6.h" -#include "opt_ipsec.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#ifdef IPSEC -#include -#include -#endif - -extern struct domain inet6domain; - -struct icmp6stat icmp6stat; - -extern struct inpcbinfo ripcbinfo; -extern struct inpcbhead ripcb; -extern int icmp6errppslim; -static int icmp6errpps_count = 0; -static struct timeval icmp6errppslim_last; -extern int icmp6_nodeinfo; - -static void icmp6_errcount __P((struct icmp6errstat *, int, int)); -static int icmp6_rip6_input __P((struct mbuf **, int)); -static int icmp6_ratelimit __P((const struct in6_addr *, const int, const int)); -static const char *icmp6_redirect_diag __P((struct in6_addr *, - struct in6_addr *, struct in6_addr *)); -static struct mbuf *ni6_input __P((struct mbuf *, int)); -static struct mbuf *ni6_nametodns __P((const char *, int, int)); -static int ni6_dnsmatch __P((const char *, int, const char *, int)); -static int ni6_addrs __P((struct icmp6_nodeinfo *, struct mbuf *, - struct ifnet **, struct in6_addr *)); -static int ni6_store_addrs __P((struct icmp6_nodeinfo *, struct icmp6_nodeinfo *, - struct ifnet *, int)); -static int icmp6_notify_error __P((struct mbuf **, int, int, int)); - - -void -icmp6_init(void) -{ - - mld6_init(); -} - -static void -icmp6_errcount(struct icmp6errstat *stat, int type, int code) -{ - switch (type) { - case ICMP6_DST_UNREACH: - switch (code) { - case ICMP6_DST_UNREACH_NOROUTE: - stat->icp6errs_dst_unreach_noroute++; - return; - case ICMP6_DST_UNREACH_ADMIN: - stat->icp6errs_dst_unreach_admin++; - return; - case ICMP6_DST_UNREACH_BEYONDSCOPE: - stat->icp6errs_dst_unreach_beyondscope++; - return; - case ICMP6_DST_UNREACH_ADDR: - stat->icp6errs_dst_unreach_addr++; - return; - case ICMP6_DST_UNREACH_NOPORT: - stat->icp6errs_dst_unreach_noport++; - return; - } - break; - case ICMP6_PACKET_TOO_BIG: - stat->icp6errs_packet_too_big++; - return; - case ICMP6_TIME_EXCEEDED: - switch (code) { - case ICMP6_TIME_EXCEED_TRANSIT: - stat->icp6errs_time_exceed_transit++; - return; - case ICMP6_TIME_EXCEED_REASSEMBLY: - stat->icp6errs_time_exceed_reassembly++; - return; - } - break; - case ICMP6_PARAM_PROB: - switch (code) { - case ICMP6_PARAMPROB_HEADER: - stat->icp6errs_paramprob_header++; - return; - case ICMP6_PARAMPROB_NEXTHEADER: - stat->icp6errs_paramprob_nextheader++; - return; - case ICMP6_PARAMPROB_OPTION: - stat->icp6errs_paramprob_option++; - return; - } - break; - case ND_REDIRECT: - stat->icp6errs_redirect++; - return; - } - stat->icp6errs_unknown++; -} - -/* - * A wrapper function for icmp6_error() necessary when the erroneous packet - * may not contain enough scope zone information. - */ -void -icmp6_error2(struct mbuf *m, int type, int code, int param, - struct ifnet *ifp) -{ - struct ip6_hdr *ip6; - - if (ifp == NULL) - return; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, sizeof(struct ip6_hdr), ); -#else - if (m->m_len < sizeof(struct ip6_hdr)) { - m = m_pullup(m, sizeof(struct ip6_hdr)); - if (m == NULL) - return; - } -#endif - - ip6 = mtod(m, struct ip6_hdr *); - - if (in6_setscope(&ip6->ip6_src, ifp, NULL) != 0) - return; - if (in6_setscope(&ip6->ip6_dst, ifp, NULL) != 0) - return; - - icmp6_error(m, type, code, param); -} - -/* - * Generate an error packet of type error in response to bad IP6 packet. - */ -void -icmp6_error(struct mbuf *m, int type, int code, int param) -{ - struct ip6_hdr *oip6, *nip6; - struct icmp6_hdr *icmp6; - u_int preplen; - int off; - int nxt; - - icmp6stat.icp6s_error++; - - /* count per-type-code statistics */ - icmp6_errcount(&icmp6stat.icp6s_outerrhist, type, code); - -#ifdef M_DECRYPTED /*not openbsd*/ - if (m->m_flags & M_DECRYPTED) { - icmp6stat.icp6s_canterror++; - goto freeit; - } -#endif - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, sizeof(struct ip6_hdr), ); -#else - if (m->m_len < sizeof(struct ip6_hdr)) { - m = m_pullup(m, sizeof(struct ip6_hdr)); - if (m == NULL) - return; - } -#endif - oip6 = mtod(m, struct ip6_hdr *); - - /* - * If the destination address of the erroneous packet is a multicast - * address, or the packet was sent using link-layer multicast, - * we should basically suppress sending an error (RFC 2463, Section - * 2.4). - * We have two exceptions (the item e.2 in that section): - * - the Pakcet Too Big message can be sent for path MTU discovery. - * - the Parameter Problem Message that can be allowed an icmp6 error - * in the option type field. This check has been done in - * ip6_unknown_opt(), so we can just check the type and code. - */ - if ((m->m_flags & (M_BCAST|M_MCAST) || - IN6_IS_ADDR_MULTICAST(&oip6->ip6_dst)) && - (type != ICMP6_PACKET_TOO_BIG && - (type != ICMP6_PARAM_PROB || - code != ICMP6_PARAMPROB_OPTION))) - goto freeit; - - /* - * RFC 2463, 2.4 (e.5): source address check. - * XXX: the case of anycast source? - */ - if (IN6_IS_ADDR_UNSPECIFIED(&oip6->ip6_src) || - IN6_IS_ADDR_MULTICAST(&oip6->ip6_src)) - goto freeit; - - /* - * If we are about to send ICMPv6 against ICMPv6 error/redirect, - * don't do it. - */ - nxt = -1; - off = ip6_lasthdr(m, 0, IPPROTO_IPV6, &nxt); - if (off >= 0 && nxt == IPPROTO_ICMPV6) { - struct icmp6_hdr *icp; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, off + sizeof(struct icmp6_hdr), ); - icp = (struct icmp6_hdr *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(icp, struct icmp6_hdr *, m, off, - sizeof(*icp)); - if (icp == NULL) { - icmp6stat.icp6s_tooshort++; - return; - } -#endif - if (icp->icmp6_type < ICMP6_ECHO_REQUEST || - icp->icmp6_type == ND_REDIRECT) { - /* - * ICMPv6 error - * Special case: for redirect (which is - * informational) we must not send icmp6 error. - */ - icmp6stat.icp6s_canterror++; - goto freeit; - } else { - /* ICMPv6 informational - send the error */ - } - } else { - /* non-ICMPv6 - send the error */ - } - - oip6 = mtod(m, struct ip6_hdr *); /* adjust pointer */ - - /* Finally, do rate limitation check. */ - if (icmp6_ratelimit(&oip6->ip6_src, type, code)) { - icmp6stat.icp6s_toofreq++; - goto freeit; - } - - /* - * OK, ICMP6 can be generated. - */ - - if (m->m_pkthdr.len >= ICMPV6_PLD_MAXLEN) - m_adj(m, ICMPV6_PLD_MAXLEN - m->m_pkthdr.len); - - preplen = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr); - M_PREPEND(m, preplen, M_DONTWAIT); - if (m && m->m_len < preplen) - m = m_pullup(m, preplen); - if (m == NULL) { - nd6log((LOG_DEBUG, "ENOBUFS in icmp6_error %d\n", __LINE__)); - return; - } - - nip6 = mtod(m, struct ip6_hdr *); - nip6->ip6_src = oip6->ip6_src; - nip6->ip6_dst = oip6->ip6_dst; - - in6_clearscope(&oip6->ip6_src); - in6_clearscope(&oip6->ip6_dst); - - icmp6 = (struct icmp6_hdr *)(nip6 + 1); - icmp6->icmp6_type = type; - icmp6->icmp6_code = code; - icmp6->icmp6_pptr = htonl((u_int32_t)param); - - /* - * icmp6_reflect() is designed to be in the input path. - * icmp6_error() can be called from both input and output path, - * and if we are in output path rcvif could contain bogus value. - * clear m->m_pkthdr.rcvif for safety, we should have enough scope - * information in ip header (nip6). - */ - m->m_pkthdr.rcvif = NULL; - - icmp6stat.icp6s_outhist[type]++; - icmp6_reflect(m, sizeof(struct ip6_hdr)); /* header order: IPv6 - ICMPv6 */ - - return; - - freeit: - /* - * If we can't tell whether or not we can generate ICMP6, free it. - */ - m_freem(m); -} - -/* - * Process a received ICMP6 message. - */ -int -icmp6_input(struct mbuf **mp, int *offp, int proto) -{ - struct mbuf *m = *mp, *n; - struct ip6_hdr *ip6, *nip6; - struct icmp6_hdr *icmp6, *nicmp6; - int off = *offp; - int icmp6len = m->m_pkthdr.len - *offp; - int code, sum, noff; - char ip6bufs[INET6_ADDRSTRLEN], ip6bufd[INET6_ADDRSTRLEN]; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, sizeof(struct icmp6_hdr), IPPROTO_DONE); - /* m might change if M_LOOP. So, call mtod after this */ -#endif - - /* - * Locate icmp6 structure in mbuf, and check - * that not corrupted and of at least minimum length - */ - - ip6 = mtod(m, struct ip6_hdr *); - if (icmp6len < sizeof(struct icmp6_hdr)) { - icmp6stat.icp6s_tooshort++; - goto freeit; - } - - /* - * calculate the checksum - */ -#ifndef PULLDOWN_TEST - icmp6 = (struct icmp6_hdr *)((caddr_t)ip6 + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, sizeof(*icmp6)); - if (icmp6 == NULL) { - icmp6stat.icp6s_tooshort++; - return IPPROTO_DONE; - } -#endif - code = icmp6->icmp6_code; - - if ((sum = in6_cksum(m, IPPROTO_ICMPV6, off, icmp6len)) != 0) { - nd6log((LOG_ERR, - "ICMP6 checksum error(%d|%x) %s\n", - icmp6->icmp6_type, sum, - ip6_sprintf(ip6bufs, &ip6->ip6_src))); - icmp6stat.icp6s_checksum++; - goto freeit; - } - - if (faithprefix_p != NULL && (*faithprefix_p)(&ip6->ip6_dst)) { - /* - * Deliver very specific ICMP6 type only. - * This is important to deliver TOOBIG. Otherwise PMTUD - * will not work. - */ - switch (icmp6->icmp6_type) { - case ICMP6_DST_UNREACH: - case ICMP6_PACKET_TOO_BIG: - case ICMP6_TIME_EXCEEDED: - break; - default: - goto freeit; - } - } - - icmp6stat.icp6s_inhist[icmp6->icmp6_type]++; - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_msg); - if (icmp6->icmp6_type < ICMP6_INFOMSG_MASK) - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_error); - - switch (icmp6->icmp6_type) { - case ICMP6_DST_UNREACH: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_dstunreach); - switch (code) { - case ICMP6_DST_UNREACH_NOROUTE: - code = PRC_UNREACH_NET; - break; - case ICMP6_DST_UNREACH_ADMIN: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_adminprohib); - code = PRC_UNREACH_PROTOCOL; /* is this a good code? */ - break; - case ICMP6_DST_UNREACH_ADDR: - code = PRC_HOSTDEAD; - break; - case ICMP6_DST_UNREACH_BEYONDSCOPE: - /* I mean "source address was incorrect." */ - code = PRC_PARAMPROB; - break; - case ICMP6_DST_UNREACH_NOPORT: - code = PRC_UNREACH_PORT; - break; - default: - goto badcode; - } - goto deliver; - break; - - case ICMP6_PACKET_TOO_BIG: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_pkttoobig); - - /* validation is made in icmp6_mtudisc_update */ - - code = PRC_MSGSIZE; - - /* - * Updating the path MTU will be done after examining - * intermediate extension headers. - */ - goto deliver; - break; - - case ICMP6_TIME_EXCEEDED: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_timeexceed); - switch (code) { - case ICMP6_TIME_EXCEED_TRANSIT: - code = PRC_TIMXCEED_INTRANS; - break; - case ICMP6_TIME_EXCEED_REASSEMBLY: - code = PRC_TIMXCEED_REASS; - break; - default: - goto badcode; - } - goto deliver; - break; - - case ICMP6_PARAM_PROB: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_paramprob); - switch (code) { - case ICMP6_PARAMPROB_NEXTHEADER: - code = PRC_UNREACH_PROTOCOL; - break; - case ICMP6_PARAMPROB_HEADER: - case ICMP6_PARAMPROB_OPTION: - code = PRC_PARAMPROB; - break; - default: - goto badcode; - } - goto deliver; - break; - - case ICMP6_ECHO_REQUEST: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_echo); - if (code != 0) - goto badcode; - if ((n = m_copy(m, 0, M_COPYALL)) == NULL) { - /* Give up remote */ - break; - } - if ((n->m_flags & M_EXT) != 0 - || n->m_len < off + sizeof(struct icmp6_hdr)) { - struct mbuf *n0 = n; - const int maxlen = sizeof(*nip6) + sizeof(*nicmp6); - int n0len; - - MGETHDR(n, M_DONTWAIT, n0->m_type); - n0len = n0->m_pkthdr.len; /* save for use below */ - if (n) - M_MOVE_PKTHDR(n, n0); - if (n && maxlen >= MHLEN) { - MCLGET(n, M_DONTWAIT); - if ((n->m_flags & M_EXT) == 0) { - m_free(n); - n = NULL; - } - } - if (n == NULL) { - /* Give up remote */ - m_freem(n0); - break; - } - /* - * Copy IPv6 and ICMPv6 only. - */ - nip6 = mtod(n, struct ip6_hdr *); - bcopy(ip6, nip6, sizeof(struct ip6_hdr)); - nicmp6 = (struct icmp6_hdr *)(nip6 + 1); - bcopy(icmp6, nicmp6, sizeof(struct icmp6_hdr)); - noff = sizeof(struct ip6_hdr); - /* new mbuf contains only ipv6+icmpv6 headers */ - n->m_len = noff + sizeof(struct icmp6_hdr); - /* - * Adjust mbuf. ip6_plen will be adjusted in - * ip6_output(). - */ - m_adj(n0, off + sizeof(struct icmp6_hdr)); - /* recalculate complete packet size */ - n->m_pkthdr.len = n0len + (noff - off); - n->m_next = n0; - } else { - nip6 = mtod(n, struct ip6_hdr *); - IP6_EXTHDR_GET(nicmp6, struct icmp6_hdr *, n, off, - sizeof(*nicmp6)); - noff = off; - } - nicmp6->icmp6_type = ICMP6_ECHO_REPLY; - nicmp6->icmp6_code = 0; - if (n) { - icmp6stat.icp6s_reflect++; - icmp6stat.icp6s_outhist[ICMP6_ECHO_REPLY]++; - icmp6_reflect(n, noff); - } - break; - - case ICMP6_ECHO_REPLY: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_echoreply); - if (code != 0) - goto badcode; - break; - - case MLD_LISTENER_QUERY: - case MLD_LISTENER_REPORT: - if (icmp6len < sizeof(struct mld_hdr)) - goto badlen; - if (icmp6->icmp6_type == MLD_LISTENER_QUERY) /* XXX: ugly... */ - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_mldquery); - else - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_mldreport); - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - mld6_input(m, off); - m = NULL; - goto freeit; - } - mld6_input(n, off); - /* m stays. */ - break; - - case MLD_LISTENER_DONE: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_mlddone); - if (icmp6len < sizeof(struct mld_hdr)) /* necessary? */ - goto badlen; - break; /* nothing to be done in kernel */ - - case MLD_MTRACE_RESP: - case MLD_MTRACE: - /* XXX: these two are experimental. not officially defined. */ - /* XXX: per-interface statistics? */ - break; /* just pass it to applications */ - - case ICMP6_WRUREQUEST: /* ICMP6_FQDN_QUERY */ - { - enum { WRU, FQDN } mode; - - if (!icmp6_nodeinfo) - break; - - if (icmp6len == sizeof(struct icmp6_hdr) + 4) - mode = WRU; - else if (icmp6len >= sizeof(struct icmp6_nodeinfo)) - mode = FQDN; - else - goto badlen; - -#define hostnamelen strlen(hostname) - if (mode == FQDN) { -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, sizeof(struct icmp6_nodeinfo), - IPPROTO_DONE); -#endif - n = m_copy(m, 0, M_COPYALL); - if (n) - n = ni6_input(n, off); - /* XXX meaningless if n == NULL */ - noff = sizeof(struct ip6_hdr); - } else { - u_char *p; - int maxlen, maxhlen; - - /* - * XXX: this combination of flags is pointless, - * but should we keep this for compatibility? - */ - if ((icmp6_nodeinfo & 5) != 5) - break; - - if (code != 0) - goto badcode; - maxlen = sizeof(*nip6) + sizeof(*nicmp6) + 4; - if (maxlen >= MCLBYTES) { - /* Give up remote */ - break; - } - MGETHDR(n, M_DONTWAIT, m->m_type); - if (n && maxlen > MHLEN) { - MCLGET(n, M_DONTWAIT); - if ((n->m_flags & M_EXT) == 0) { - m_free(n); - n = NULL; - } - } - if (n && !m_dup_pkthdr(n, m, M_DONTWAIT)) { - /* - * Previous code did a blind M_COPY_PKTHDR - * and said "just for rcvif". If true, then - * we could tolerate the dup failing (due to - * the deep copy of the tag chain). For now - * be conservative and just fail. - */ - m_free(n); - n = NULL; - } - if (n == NULL) { - /* Give up remote */ - break; - } - n->m_pkthdr.rcvif = NULL; - n->m_len = 0; - maxhlen = M_TRAILINGSPACE(n) - maxlen; - if (maxhlen > hostnamelen) - maxhlen = hostnamelen; - /* - * Copy IPv6 and ICMPv6 only. - */ - nip6 = mtod(n, struct ip6_hdr *); - bcopy(ip6, nip6, sizeof(struct ip6_hdr)); - nicmp6 = (struct icmp6_hdr *)(nip6 + 1); - bcopy(icmp6, nicmp6, sizeof(struct icmp6_hdr)); - p = (u_char *)(nicmp6 + 1); - bzero(p, 4); - bcopy(hostname, p + 4, maxhlen); /* meaningless TTL */ - noff = sizeof(struct ip6_hdr); - n->m_pkthdr.len = n->m_len = sizeof(struct ip6_hdr) + - sizeof(struct icmp6_hdr) + 4 + maxhlen; - nicmp6->icmp6_type = ICMP6_WRUREPLY; - nicmp6->icmp6_code = 0; - } -#undef hostnamelen - if (n) { - icmp6stat.icp6s_reflect++; - icmp6stat.icp6s_outhist[ICMP6_WRUREPLY]++; - icmp6_reflect(n, noff); - } - break; - } - - case ICMP6_WRUREPLY: - if (code != 0) - goto badcode; - break; - - case ND_ROUTER_SOLICIT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_routersolicit); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_router_solicit)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_rs_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_rs_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_ROUTER_ADVERT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_routeradvert); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_router_advert)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_ra_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_ra_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_NEIGHBOR_SOLICIT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_neighborsolicit); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_neighbor_solicit)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_ns_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_ns_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_NEIGHBOR_ADVERT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_neighboradvert); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_neighbor_advert)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_na_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_na_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_REDIRECT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_redirect); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_redirect)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - icmp6_redirect_input(m, off); - m = NULL; - goto freeit; - } - icmp6_redirect_input(n, off); - /* m stays. */ - break; - - case ICMP6_ROUTER_RENUMBERING: - if (code != ICMP6_ROUTER_RENUMBERING_COMMAND && - code != ICMP6_ROUTER_RENUMBERING_RESULT) - goto badcode; - if (icmp6len < sizeof(struct icmp6_router_renum)) - goto badlen; - break; - - default: - nd6log((LOG_DEBUG, - "icmp6_input: unknown type %d(src=%s, dst=%s, ifid=%d)\n", - icmp6->icmp6_type, ip6_sprintf(ip6bufs, &ip6->ip6_src), - ip6_sprintf(ip6bufd, &ip6->ip6_dst), - m->m_pkthdr.rcvif ? m->m_pkthdr.rcvif->if_index : 0)); - if (icmp6->icmp6_type < ICMP6_ECHO_REQUEST) { - /* ICMPv6 error: MUST deliver it by spec... */ - code = PRC_NCMDS; - /* deliver */ - } else { - /* ICMPv6 informational: MUST not deliver */ - break; - } - deliver: - if (icmp6_notify_error(&m, off, icmp6len, code)) { - /* In this case, m should've been freed. */ - return (IPPROTO_DONE); - } - break; - - badcode: - icmp6stat.icp6s_badcode++; - break; - - badlen: - icmp6stat.icp6s_badlen++; - break; - } - - /* deliver the packet to appropriate sockets */ - icmp6_rip6_input(&m, *offp); - - return IPPROTO_DONE; - - freeit: - m_freem(m); - return IPPROTO_DONE; -} - -static int -icmp6_notify_error(struct mbuf **mp, int off, int icmp6len, int code) -{ - struct mbuf *m = *mp; - struct icmp6_hdr *icmp6; - struct ip6_hdr *eip6; - u_int32_t notifymtu; - struct sockaddr_in6 icmp6src, icmp6dst; - - if (icmp6len < sizeof(struct icmp6_hdr) + sizeof(struct ip6_hdr)) { - icmp6stat.icp6s_tooshort++; - goto freeit; - } -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, - sizeof(struct icmp6_hdr) + sizeof(struct ip6_hdr), -1); - icmp6 = (struct icmp6_hdr *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, - sizeof(*icmp6) + sizeof(struct ip6_hdr)); - if (icmp6 == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - eip6 = (struct ip6_hdr *)(icmp6 + 1); - - /* Detect the upper level protocol */ - { - void (*ctlfunc) __P((int, struct sockaddr *, void *)); - u_int8_t nxt = eip6->ip6_nxt; - int eoff = off + sizeof(struct icmp6_hdr) + - sizeof(struct ip6_hdr); - struct ip6ctlparam ip6cp; - struct in6_addr *finaldst = NULL; - int icmp6type = icmp6->icmp6_type; - struct ip6_frag *fh; - struct ip6_rthdr *rth; - struct ip6_rthdr0 *rth0; - int rthlen; - - while (1) { /* XXX: should avoid infinite loop explicitly? */ - struct ip6_ext *eh; - - switch (nxt) { - case IPPROTO_HOPOPTS: - case IPPROTO_DSTOPTS: - case IPPROTO_AH: -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, - eoff + sizeof(struct ip6_ext), -1); - eh = (struct ip6_ext *)(mtod(m, caddr_t) + eoff); -#else - IP6_EXTHDR_GET(eh, struct ip6_ext *, m, - eoff, sizeof(*eh)); - if (eh == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - - if (nxt == IPPROTO_AH) - eoff += (eh->ip6e_len + 2) << 2; - else - eoff += (eh->ip6e_len + 1) << 3; - nxt = eh->ip6e_nxt; - break; - case IPPROTO_ROUTING: - /* - * When the erroneous packet contains a - * routing header, we should examine the - * header to determine the final destination. - * Otherwise, we can't properly update - * information that depends on the final - * destination (e.g. path MTU). - */ -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, eoff + sizeof(*rth), -1); - rth = (struct ip6_rthdr *) - (mtod(m, caddr_t) + eoff); -#else - IP6_EXTHDR_GET(rth, struct ip6_rthdr *, m, - eoff, sizeof(*rth)); - if (rth == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - rthlen = (rth->ip6r_len + 1) << 3; - /* - * XXX: currently there is no - * officially defined type other - * than type-0. - * Note that if the segment left field - * is 0, all intermediate hops must - * have been passed. - */ - if (rth->ip6r_segleft && - rth->ip6r_type == IPV6_RTHDR_TYPE_0) { - int hops; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, eoff + rthlen, -1); - rth0 = (struct ip6_rthdr0 *) - (mtod(m, caddr_t) + eoff); -#else - IP6_EXTHDR_GET(rth0, - struct ip6_rthdr0 *, m, - eoff, rthlen); - if (rth0 == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - /* just ignore a bogus header */ - if ((rth0->ip6r0_len % 2) == 0 && - (hops = rth0->ip6r0_len/2)) - finaldst = (struct in6_addr *)(rth0 + 1) + (hops - 1); - } - eoff += rthlen; - nxt = rth->ip6r_nxt; - break; - case IPPROTO_FRAGMENT: -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, eoff + - sizeof(struct ip6_frag), -1); - fh = (struct ip6_frag *)(mtod(m, caddr_t) + - eoff); -#else - IP6_EXTHDR_GET(fh, struct ip6_frag *, m, - eoff, sizeof(*fh)); - if (fh == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - /* - * Data after a fragment header is meaningless - * unless it is the first fragment, but - * we'll go to the notify label for path MTU - * discovery. - */ - if (fh->ip6f_offlg & IP6F_OFF_MASK) - goto notify; - - eoff += sizeof(struct ip6_frag); - nxt = fh->ip6f_nxt; - break; - default: - /* - * This case includes ESP and the No Next - * Header. In such cases going to the notify - * label does not have any meaning - * (i.e. ctlfunc will be NULL), but we go - * anyway since we might have to update - * path MTU information. - */ - goto notify; - } - } - notify: -#ifndef PULLDOWN_TEST - icmp6 = (struct icmp6_hdr *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, - sizeof(*icmp6) + sizeof(struct ip6_hdr)); - if (icmp6 == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - - /* - * retrieve parameters from the inner IPv6 header, and convert - * them into sockaddr structures. - * XXX: there is no guarantee that the source or destination - * addresses of the inner packet are in the same scope as - * the addresses of the icmp packet. But there is no other - * way to determine the zone. - */ - eip6 = (struct ip6_hdr *)(icmp6 + 1); - - bzero(&icmp6dst, sizeof(icmp6dst)); - icmp6dst.sin6_len = sizeof(struct sockaddr_in6); - icmp6dst.sin6_family = AF_INET6; - if (finaldst == NULL) - icmp6dst.sin6_addr = eip6->ip6_dst; - else - icmp6dst.sin6_addr = *finaldst; - if (in6_setscope(&icmp6dst.sin6_addr, m->m_pkthdr.rcvif, NULL)) - goto freeit; - bzero(&icmp6src, sizeof(icmp6src)); - icmp6src.sin6_len = sizeof(struct sockaddr_in6); - icmp6src.sin6_family = AF_INET6; - icmp6src.sin6_addr = eip6->ip6_src; - if (in6_setscope(&icmp6src.sin6_addr, m->m_pkthdr.rcvif, NULL)) - goto freeit; - icmp6src.sin6_flowinfo = - (eip6->ip6_flow & IPV6_FLOWLABEL_MASK); - - if (finaldst == NULL) - finaldst = &eip6->ip6_dst; - ip6cp.ip6c_m = m; - ip6cp.ip6c_icmp6 = icmp6; - ip6cp.ip6c_ip6 = (struct ip6_hdr *)(icmp6 + 1); - ip6cp.ip6c_off = eoff; - ip6cp.ip6c_finaldst = finaldst; - ip6cp.ip6c_src = &icmp6src; - ip6cp.ip6c_nxt = nxt; - - if (icmp6type == ICMP6_PACKET_TOO_BIG) { - notifymtu = ntohl(icmp6->icmp6_mtu); - ip6cp.ip6c_cmdarg = (void *)¬ifymtu; - icmp6_mtudisc_update(&ip6cp, 1); /*XXX*/ - } - - ctlfunc = (void (*) __P((int, struct sockaddr *, void *))) - (inet6sw[ip6_protox[nxt]].pr_ctlinput); - if (ctlfunc) { - (void) (*ctlfunc)(code, (struct sockaddr *)&icmp6dst, - &ip6cp); - } - } - *mp = m; - return (0); - - freeit: - m_freem(m); - return (-1); -} - -void -icmp6_mtudisc_update(struct ip6ctlparam *ip6cp, int validated) -{ - struct in6_addr *dst = ip6cp->ip6c_finaldst; - struct icmp6_hdr *icmp6 = ip6cp->ip6c_icmp6; - struct mbuf *m = ip6cp->ip6c_m; /* will be necessary for scope issue */ - u_int mtu = ntohl(icmp6->icmp6_mtu); - struct in_conninfo inc; - -#if 0 - /* - * RFC2460 section 5, last paragraph. - * even though minimum link MTU for IPv6 is IPV6_MMTU, - * we may see ICMPv6 too big with mtu < IPV6_MMTU - * due to packet translator in the middle. - * see ip6_output() and ip6_getpmtu() "alwaysfrag" case for - * special handling. - */ - if (mtu < IPV6_MMTU) - return; -#endif - - /* - * we reject ICMPv6 too big with abnormally small value. - * XXX what is the good definition of "abnormally small"? - */ - if (mtu < sizeof(struct ip6_hdr) + sizeof(struct ip6_frag) + 8) - return; - - if (!validated) - return; - - bzero(&inc, sizeof(inc)); - inc.inc_flags = 1; /* IPv6 */ - inc.inc6_faddr = *dst; - if (in6_setscope(&inc.inc6_faddr, m->m_pkthdr.rcvif, NULL)) - return; - - if (mtu < tcp_maxmtu6(&inc, NULL)) { - tcp_hc_updatemtu(&inc, mtu); - icmp6stat.icp6s_pmtuchg++; - } -} - -/* - * Process a Node Information Query packet, based on - * draft-ietf-ipngwg-icmp-name-lookups-07. - * - * Spec incompatibilities: - * - IPv6 Subject address handling - * - IPv4 Subject address handling support missing - * - Proxy reply (answer even if it's not for me) - * - joins NI group address at in6_ifattach() time only, does not cope - * with hostname changes by sethostname(3) - */ -#define hostnamelen strlen(hostname) -static struct mbuf * -ni6_input(struct mbuf *m, int off) -{ - struct icmp6_nodeinfo *ni6, *nni6; - struct mbuf *n = NULL; - u_int16_t qtype; - int subjlen; - int replylen = sizeof(struct ip6_hdr) + sizeof(struct icmp6_nodeinfo); - struct ni_reply_fqdn *fqdn; - int addrs; /* for NI_QTYPE_NODEADDR */ - struct ifnet *ifp = NULL; /* for NI_QTYPE_NODEADDR */ - struct in6_addr in6_subj; /* subject address */ - struct ip6_hdr *ip6; - int oldfqdn = 0; /* if 1, return pascal string (03 draft) */ - char *subj = NULL; - struct in6_ifaddr *ia6 = NULL; - - ip6 = mtod(m, struct ip6_hdr *); -#ifndef PULLDOWN_TEST - ni6 = (struct icmp6_nodeinfo *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(ni6, struct icmp6_nodeinfo *, m, off, sizeof(*ni6)); - if (ni6 == NULL) { - /* m is already reclaimed */ - return (NULL); - } -#endif - - /* - * Validate IPv6 source address. - * The default configuration MUST be to refuse answering queries from - * global-scope addresses according to RFC4602. - * Notes: - * - it's not very clear what "refuse" means; this implementation - * simply drops it. - * - it's not very easy to identify global-scope (unicast) addresses - * since there are many prefixes for them. It should be safer - * and in practice sufficient to check "all" but loopback and - * link-local (note that site-local unicast was deprecated and - * ULA is defined as global scope-wise) - */ - if ((icmp6_nodeinfo & ICMP6_NODEINFO_GLOBALOK) == 0 && - !IN6_IS_ADDR_LOOPBACK(&ip6->ip6_src) && - !IN6_IS_ADDR_LINKLOCAL(&ip6->ip6_src)) - goto bad; - - /* - * Validate IPv6 destination address. - * - * The Responder must discard the Query without further processing - * unless it is one of the Responder's unicast or anycast addresses, or - * a link-local scope multicast address which the Responder has joined. - * [RFC4602, Section 5.] - */ - if (IN6_IS_ADDR_MULTICAST(&ip6->ip6_dst)) { - if (!IN6_IS_ADDR_MC_LINKLOCAL(&ip6->ip6_dst)) - goto bad; - /* else it's a link-local multicast, fine */ - } else { /* unicast or anycast */ - if ((ia6 = ip6_getdstifaddr(m)) == NULL) - goto bad; /* XXX impossible */ - - if ((ia6->ia6_flags & IN6_IFF_TEMPORARY) && - !(icmp6_nodeinfo & ICMP6_NODEINFO_TMPADDROK)) { - nd6log((LOG_DEBUG, "ni6_input: ignore node info to " - "a temporary address in %s:%d", - __FILE__, __LINE__)); - goto bad; - } - } - - /* validate query Subject field. */ - qtype = ntohs(ni6->ni_qtype); - subjlen = m->m_pkthdr.len - off - sizeof(struct icmp6_nodeinfo); - switch (qtype) { - case NI_QTYPE_NOOP: - case NI_QTYPE_SUPTYPES: - /* 07 draft */ - if (ni6->ni_code == ICMP6_NI_SUBJ_FQDN && subjlen == 0) - break; - /* FALLTHROUGH */ - case NI_QTYPE_FQDN: - case NI_QTYPE_NODEADDR: - case NI_QTYPE_IPV4ADDR: - switch (ni6->ni_code) { - case ICMP6_NI_SUBJ_IPV6: -#if ICMP6_NI_SUBJ_IPV6 != 0 - case 0: -#endif - /* - * backward compatibility - try to accept 03 draft - * format, where no Subject is present. - */ - if (qtype == NI_QTYPE_FQDN && ni6->ni_code == 0 && - subjlen == 0) { - oldfqdn++; - break; - } -#if ICMP6_NI_SUBJ_IPV6 != 0 - if (ni6->ni_code != ICMP6_NI_SUBJ_IPV6) - goto bad; -#endif - - if (subjlen != sizeof(struct in6_addr)) - goto bad; - - /* - * Validate Subject address. - * - * Not sure what exactly "address belongs to the node" - * means in the spec, is it just unicast, or what? - * - * At this moment we consider Subject address as - * "belong to the node" if the Subject address equals - * to the IPv6 destination address; validation for - * IPv6 destination address should have done enough - * check for us. - * - * We do not do proxy at this moment. - */ - /* m_pulldown instead of copy? */ - m_copydata(m, off + sizeof(struct icmp6_nodeinfo), - subjlen, (caddr_t)&in6_subj); - if (in6_setscope(&in6_subj, m->m_pkthdr.rcvif, NULL)) - goto bad; - - subj = (char *)&in6_subj; - if (IN6_ARE_ADDR_EQUAL(&ip6->ip6_dst, &in6_subj)) - break; - - /* - * XXX if we are to allow other cases, we should really - * be careful about scope here. - * basically, we should disallow queries toward IPv6 - * destination X with subject Y, - * if scope(X) > scope(Y). - * if we allow scope(X) > scope(Y), it will result in - * information leakage across scope boundary. - */ - goto bad; - - case ICMP6_NI_SUBJ_FQDN: - /* - * Validate Subject name with gethostname(3). - * - * The behavior may need some debate, since: - * - we are not sure if the node has FQDN as - * hostname (returned by gethostname(3)). - * - the code does wildcard match for truncated names. - * however, we are not sure if we want to perform - * wildcard match, if gethostname(3) side has - * truncated hostname. - */ - n = ni6_nametodns(hostname, hostnamelen, 0); - if (!n || n->m_next || n->m_len == 0) - goto bad; - IP6_EXTHDR_GET(subj, char *, m, - off + sizeof(struct icmp6_nodeinfo), subjlen); - if (subj == NULL) - goto bad; - if (!ni6_dnsmatch(subj, subjlen, mtod(n, const char *), - n->m_len)) { - goto bad; - } - m_freem(n); - n = NULL; - break; - - case ICMP6_NI_SUBJ_IPV4: /* XXX: to be implemented? */ - default: - goto bad; - } - break; - } - - /* refuse based on configuration. XXX ICMP6_NI_REFUSED? */ - switch (qtype) { - case NI_QTYPE_FQDN: - if ((icmp6_nodeinfo & ICMP6_NODEINFO_FQDNOK) == 0) - goto bad; - break; - case NI_QTYPE_NODEADDR: - case NI_QTYPE_IPV4ADDR: - if ((icmp6_nodeinfo & ICMP6_NODEINFO_NODEADDROK) == 0) - goto bad; - break; - } - - /* guess reply length */ - switch (qtype) { - case NI_QTYPE_NOOP: - break; /* no reply data */ - case NI_QTYPE_SUPTYPES: - replylen += sizeof(u_int32_t); - break; - case NI_QTYPE_FQDN: - /* XXX will append an mbuf */ - replylen += offsetof(struct ni_reply_fqdn, ni_fqdn_namelen); - break; - case NI_QTYPE_NODEADDR: - addrs = ni6_addrs(ni6, m, &ifp, (struct in6_addr *)subj); - if ((replylen += addrs * (sizeof(struct in6_addr) + - sizeof(u_int32_t))) > MCLBYTES) - replylen = MCLBYTES; /* XXX: will truncate pkt later */ - break; - case NI_QTYPE_IPV4ADDR: - /* unsupported - should respond with unknown Qtype? */ - break; - default: - /* - * XXX: We must return a reply with the ICMP6 code - * `unknown Qtype' in this case. However we regard the case - * as an FQDN query for backward compatibility. - * Older versions set a random value to this field, - * so it rarely varies in the defined qtypes. - * But the mechanism is not reliable... - * maybe we should obsolete older versions. - */ - qtype = NI_QTYPE_FQDN; - /* XXX will append an mbuf */ - replylen += offsetof(struct ni_reply_fqdn, ni_fqdn_namelen); - oldfqdn++; - break; - } - - /* allocate an mbuf to reply. */ - MGETHDR(n, M_DONTWAIT, m->m_type); - if (n == NULL) { - m_freem(m); - return (NULL); - } - M_MOVE_PKTHDR(n, m); /* just for recvif */ - if (replylen > MHLEN) { - if (replylen > MCLBYTES) { - /* - * XXX: should we try to allocate more? But MCLBYTES - * is probably much larger than IPV6_MMTU... - */ - goto bad; - } - MCLGET(n, M_DONTWAIT); - if ((n->m_flags & M_EXT) == 0) { - goto bad; - } - } - n->m_pkthdr.len = n->m_len = replylen; - - /* copy mbuf header and IPv6 + Node Information base headers */ - bcopy(mtod(m, caddr_t), mtod(n, caddr_t), sizeof(struct ip6_hdr)); - nni6 = (struct icmp6_nodeinfo *)(mtod(n, struct ip6_hdr *) + 1); - bcopy((caddr_t)ni6, (caddr_t)nni6, sizeof(struct icmp6_nodeinfo)); - - /* qtype dependent procedure */ - switch (qtype) { - case NI_QTYPE_NOOP: - nni6->ni_code = ICMP6_NI_SUCCESS; - nni6->ni_flags = 0; - break; - case NI_QTYPE_SUPTYPES: - { - u_int32_t v; - nni6->ni_code = ICMP6_NI_SUCCESS; - nni6->ni_flags = htons(0x0000); /* raw bitmap */ - /* supports NOOP, SUPTYPES, FQDN, and NODEADDR */ - v = (u_int32_t)htonl(0x0000000f); - bcopy(&v, nni6 + 1, sizeof(u_int32_t)); - break; - } - case NI_QTYPE_FQDN: - nni6->ni_code = ICMP6_NI_SUCCESS; - fqdn = (struct ni_reply_fqdn *)(mtod(n, caddr_t) + - sizeof(struct ip6_hdr) + sizeof(struct icmp6_nodeinfo)); - nni6->ni_flags = 0; /* XXX: meaningless TTL */ - fqdn->ni_fqdn_ttl = 0; /* ditto. */ - /* - * XXX do we really have FQDN in variable "hostname"? - */ - n->m_next = ni6_nametodns(hostname, hostnamelen, oldfqdn); - if (n->m_next == NULL) - goto bad; - /* XXX we assume that n->m_next is not a chain */ - if (n->m_next->m_next != NULL) - goto bad; - n->m_pkthdr.len += n->m_next->m_len; - break; - case NI_QTYPE_NODEADDR: - { - int lenlim, copied; - - nni6->ni_code = ICMP6_NI_SUCCESS; - n->m_pkthdr.len = n->m_len = - sizeof(struct ip6_hdr) + sizeof(struct icmp6_nodeinfo); - lenlim = M_TRAILINGSPACE(n); - copied = ni6_store_addrs(ni6, nni6, ifp, lenlim); - /* XXX: reset mbuf length */ - n->m_pkthdr.len = n->m_len = sizeof(struct ip6_hdr) + - sizeof(struct icmp6_nodeinfo) + copied; - break; - } - default: - break; /* XXX impossible! */ - } - - nni6->ni_type = ICMP6_NI_REPLY; - m_freem(m); - return (n); - - bad: - m_freem(m); - if (n) - m_freem(n); - return (NULL); -} -#undef hostnamelen - -/* - * make a mbuf with DNS-encoded string. no compression support. - * - * XXX names with less than 2 dots (like "foo" or "foo.section") will be - * treated as truncated name (two \0 at the end). this is a wild guess. - * - * old - return pascal string if non-zero - */ -static struct mbuf * -ni6_nametodns(const char *name, int namelen, int old) -{ - struct mbuf *m; - char *cp, *ep; - const char *p, *q; - int i, len, nterm; - - if (old) - len = namelen + 1; - else - len = MCLBYTES; - - /* because MAXHOSTNAMELEN is usually 256, we use cluster mbuf */ - MGET(m, M_DONTWAIT, MT_DATA); - if (m && len > MLEN) { - MCLGET(m, M_DONTWAIT); - if ((m->m_flags & M_EXT) == 0) - goto fail; - } - if (!m) - goto fail; - m->m_next = NULL; - - if (old) { - m->m_len = len; - *mtod(m, char *) = namelen; - bcopy(name, mtod(m, char *) + 1, namelen); - return m; - } else { - m->m_len = 0; - cp = mtod(m, char *); - ep = mtod(m, char *) + M_TRAILINGSPACE(m); - - /* if not certain about my name, return empty buffer */ - if (namelen == 0) - return m; - - /* - * guess if it looks like shortened hostname, or FQDN. - * shortened hostname needs two trailing "\0". - */ - i = 0; - for (p = name; p < name + namelen; p++) { - if (*p && *p == '.') - i++; - } - if (i < 2) - nterm = 2; - else - nterm = 1; - - p = name; - while (cp < ep && p < name + namelen) { - i = 0; - for (q = p; q < name + namelen && *q && *q != '.'; q++) - i++; - /* result does not fit into mbuf */ - if (cp + i + 1 >= ep) - goto fail; - /* - * DNS label length restriction, RFC1035 page 8. - * "i == 0" case is included here to avoid returning - * 0-length label on "foo..bar". - */ - if (i <= 0 || i >= 64) - goto fail; - *cp++ = i; - bcopy(p, cp, i); - cp += i; - p = q; - if (p < name + namelen && *p == '.') - p++; - } - /* termination */ - if (cp + nterm >= ep) - goto fail; - while (nterm-- > 0) - *cp++ = '\0'; - m->m_len = cp - mtod(m, char *); - return m; - } - - panic("should not reach here"); - /* NOTREACHED */ - - fail: - if (m) - m_freem(m); - return NULL; -} - -/* - * check if two DNS-encoded string matches. takes care of truncated - * form (with \0\0 at the end). no compression support. - * XXX upper/lowercase match (see RFC2065) - */ -static int -ni6_dnsmatch(const char *a, int alen, const char *b, int blen) -{ - const char *a0, *b0; - int l; - - /* simplest case - need validation? */ - if (alen == blen && bcmp(a, b, alen) == 0) - return 1; - - a0 = a; - b0 = b; - - /* termination is mandatory */ - if (alen < 2 || blen < 2) - return 0; - if (a0[alen - 1] != '\0' || b0[blen - 1] != '\0') - return 0; - alen--; - blen--; - - while (a - a0 < alen && b - b0 < blen) { - if (a - a0 + 1 > alen || b - b0 + 1 > blen) - return 0; - - if ((signed char)a[0] < 0 || (signed char)b[0] < 0) - return 0; - /* we don't support compression yet */ - if (a[0] >= 64 || b[0] >= 64) - return 0; - - /* truncated case */ - if (a[0] == 0 && a - a0 == alen - 1) - return 1; - if (b[0] == 0 && b - b0 == blen - 1) - return 1; - if (a[0] == 0 || b[0] == 0) - return 0; - - if (a[0] != b[0]) - return 0; - l = a[0]; - if (a - a0 + 1 + l > alen || b - b0 + 1 + l > blen) - return 0; - if (bcmp(a + 1, b + 1, l) != 0) - return 0; - - a += 1 + l; - b += 1 + l; - } - - if (a - a0 == alen && b - b0 == blen) - return 1; - else - return 0; -} - -/* - * calculate the number of addresses to be returned in the node info reply. - */ -static int -ni6_addrs(struct icmp6_nodeinfo *ni6, struct mbuf *m, struct ifnet **ifpp, - struct in6_addr *subj) -{ - struct ifnet *ifp; - struct in6_ifaddr *ifa6; - struct ifaddr *ifa; - int addrs = 0, addrsofif, iffound = 0; - int niflags = ni6->ni_flags; - - if ((niflags & NI_NODEADDR_FLAG_ALL) == 0) { - switch (ni6->ni_code) { - case ICMP6_NI_SUBJ_IPV6: - if (subj == NULL) /* must be impossible... */ - return (0); - break; - default: - /* - * XXX: we only support IPv6 subject address for - * this Qtype. - */ - return (0); - } - } - - IFNET_RLOCK(); - for (ifp = TAILQ_FIRST(&ifnet); ifp; ifp = TAILQ_NEXT(ifp, if_list)) { - addrsofif = 0; - TAILQ_FOREACH(ifa, &ifp->if_addrlist, ifa_list) { - if (ifa->ifa_addr->sa_family != AF_INET6) - continue; - ifa6 = (struct in6_ifaddr *)ifa; - - if ((niflags & NI_NODEADDR_FLAG_ALL) == 0 && - IN6_ARE_ADDR_EQUAL(subj, &ifa6->ia_addr.sin6_addr)) - iffound = 1; - - /* - * IPv4-mapped addresses can only be returned by a - * Node Information proxy, since they represent - * addresses of IPv4-only nodes, which perforce do - * not implement this protocol. - * [icmp-name-lookups-07, Section 5.4] - * So we don't support NI_NODEADDR_FLAG_COMPAT in - * this function at this moment. - */ - - /* What do we have to do about ::1? */ - switch (in6_addrscope(&ifa6->ia_addr.sin6_addr)) { - case IPV6_ADDR_SCOPE_LINKLOCAL: - if ((niflags & NI_NODEADDR_FLAG_LINKLOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_SITELOCAL: - if ((niflags & NI_NODEADDR_FLAG_SITELOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_GLOBAL: - if ((niflags & NI_NODEADDR_FLAG_GLOBAL) == 0) - continue; - break; - default: - continue; - } - - /* - * check if anycast is okay. - * XXX: just experimental. not in the spec. - */ - if ((ifa6->ia6_flags & IN6_IFF_ANYCAST) != 0 && - (niflags & NI_NODEADDR_FLAG_ANYCAST) == 0) - continue; /* we need only unicast addresses */ - if ((ifa6->ia6_flags & IN6_IFF_TEMPORARY) != 0 && - (icmp6_nodeinfo & ICMP6_NODEINFO_TMPADDROK) == 0) { - continue; - } - addrsofif++; /* count the address */ - } - if (iffound) { - *ifpp = ifp; - IFNET_RUNLOCK(); - return (addrsofif); - } - - addrs += addrsofif; - } - IFNET_RUNLOCK(); - - return (addrs); -} - -static int -ni6_store_addrs(struct icmp6_nodeinfo *ni6, struct icmp6_nodeinfo *nni6, - struct ifnet *ifp0, int resid) -{ - struct ifnet *ifp = ifp0 ? ifp0 : TAILQ_FIRST(&ifnet); - struct in6_ifaddr *ifa6; - struct ifaddr *ifa; - struct ifnet *ifp_dep = NULL; - int copied = 0, allow_deprecated = 0; - u_char *cp = (u_char *)(nni6 + 1); - int niflags = ni6->ni_flags; - u_int32_t ltime; - - if (ifp0 == NULL && !(niflags & NI_NODEADDR_FLAG_ALL)) - return (0); /* needless to copy */ - - IFNET_RLOCK(); - again: - - for (; ifp; ifp = TAILQ_NEXT(ifp, if_list)) { - for (ifa = ifp->if_addrlist.tqh_first; ifa; - ifa = ifa->ifa_list.tqe_next) { - if (ifa->ifa_addr->sa_family != AF_INET6) - continue; - ifa6 = (struct in6_ifaddr *)ifa; - - if ((ifa6->ia6_flags & IN6_IFF_DEPRECATED) != 0 && - allow_deprecated == 0) { - /* - * prefererred address should be put before - * deprecated addresses. - */ - - /* record the interface for later search */ - if (ifp_dep == NULL) - ifp_dep = ifp; - - continue; - } else if ((ifa6->ia6_flags & IN6_IFF_DEPRECATED) == 0 && - allow_deprecated != 0) - continue; /* we now collect deprecated addrs */ - - /* What do we have to do about ::1? */ - switch (in6_addrscope(&ifa6->ia_addr.sin6_addr)) { - case IPV6_ADDR_SCOPE_LINKLOCAL: - if ((niflags & NI_NODEADDR_FLAG_LINKLOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_SITELOCAL: - if ((niflags & NI_NODEADDR_FLAG_SITELOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_GLOBAL: - if ((niflags & NI_NODEADDR_FLAG_GLOBAL) == 0) - continue; - break; - default: - continue; - } - - /* - * check if anycast is okay. - * XXX: just experimental. not in the spec. - */ - if ((ifa6->ia6_flags & IN6_IFF_ANYCAST) != 0 && - (niflags & NI_NODEADDR_FLAG_ANYCAST) == 0) - continue; - if ((ifa6->ia6_flags & IN6_IFF_TEMPORARY) != 0 && - (icmp6_nodeinfo & ICMP6_NODEINFO_TMPADDROK) == 0) { - continue; - } - - /* now we can copy the address */ - if (resid < sizeof(struct in6_addr) + - sizeof(u_int32_t)) { - /* - * We give up much more copy. - * Set the truncate flag and return. - */ - nni6->ni_flags |= NI_NODEADDR_FLAG_TRUNCATE; - IFNET_RUNLOCK(); - return (copied); - } - - /* - * Set the TTL of the address. - * The TTL value should be one of the following - * according to the specification: - * - * 1. The remaining lifetime of a DHCP lease on the - * address, or - * 2. The remaining Valid Lifetime of a prefix from - * which the address was derived through Stateless - * Autoconfiguration. - * - * Note that we currently do not support stateful - * address configuration by DHCPv6, so the former - * case can't happen. - */ - if (ifa6->ia6_lifetime.ia6t_expire == 0) - ltime = ND6_INFINITE_LIFETIME; - else { - if (ifa6->ia6_lifetime.ia6t_expire > - time_second) - ltime = htonl(ifa6->ia6_lifetime.ia6t_expire - time_second); - else - ltime = 0; - } - - bcopy(<ime, cp, sizeof(u_int32_t)); - cp += sizeof(u_int32_t); - - /* copy the address itself */ - bcopy(&ifa6->ia_addr.sin6_addr, cp, - sizeof(struct in6_addr)); - in6_clearscope((struct in6_addr *)cp); /* XXX */ - cp += sizeof(struct in6_addr); - - resid -= (sizeof(struct in6_addr) + sizeof(u_int32_t)); - copied += (sizeof(struct in6_addr) + sizeof(u_int32_t)); - } - if (ifp0) /* we need search only on the specified IF */ - break; - } - - if (allow_deprecated == 0 && ifp_dep != NULL) { - ifp = ifp_dep; - allow_deprecated = 1; - - goto again; - } - - IFNET_RUNLOCK(); - - return (copied); -} - -/* - * XXX almost dup'ed code with rip6_input. - */ -static int -icmp6_rip6_input(struct mbuf **mp, int off) -{ - struct mbuf *m = *mp; - struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *); - struct in6pcb *in6p; - struct in6pcb *last = NULL; - struct sockaddr_in6 fromsa; - struct icmp6_hdr *icmp6; - struct mbuf *opts = NULL; - -#ifndef PULLDOWN_TEST - /* this is assumed to be safe. */ - icmp6 = (struct icmp6_hdr *)((caddr_t)ip6 + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, sizeof(*icmp6)); - if (icmp6 == NULL) { - /* m is already reclaimed */ - return (IPPROTO_DONE); - } -#endif - - /* - * XXX: the address may have embedded scope zone ID, which should be - * hidden from applications. - */ - bzero(&fromsa, sizeof(fromsa)); - fromsa.sin6_family = AF_INET6; - fromsa.sin6_len = sizeof(struct sockaddr_in6); - fromsa.sin6_addr = ip6->ip6_src; - if (sa6_recoverscope(&fromsa)) { - m_freem(m); - return (IPPROTO_DONE); - } - - INP_INFO_RLOCK(&ripcbinfo); - LIST_FOREACH(in6p, &ripcb, inp_list) { - INP_LOCK(in6p); - if ((in6p->inp_vflag & INP_IPV6) == 0) { - docontinue: - INP_UNLOCK(in6p); - continue; - } - if (in6p->in6p_ip6_nxt != IPPROTO_ICMPV6) - goto docontinue; - if (!IN6_IS_ADDR_UNSPECIFIED(&in6p->in6p_laddr) && - !IN6_ARE_ADDR_EQUAL(&in6p->in6p_laddr, &ip6->ip6_dst)) - goto docontinue; - if (!IN6_IS_ADDR_UNSPECIFIED(&in6p->in6p_faddr) && - !IN6_ARE_ADDR_EQUAL(&in6p->in6p_faddr, &ip6->ip6_src)) - goto docontinue; - if (in6p->in6p_icmp6filt - && ICMP6_FILTER_WILLBLOCK(icmp6->icmp6_type, - in6p->in6p_icmp6filt)) - goto docontinue; - if (last) { - struct mbuf *n = NULL; - - /* - * Recent network drivers tend to allocate a single - * mbuf cluster, rather than to make a couple of - * mbufs without clusters. Also, since the IPv6 code - * path tries to avoid m_pullup(), it is highly - * probable that we still have an mbuf cluster here - * even though the necessary length can be stored in an - * mbuf's internal buffer. - * Meanwhile, the default size of the receive socket - * buffer for raw sockets is not so large. This means - * the possibility of packet loss is relatively higher - * than before. To avoid this scenario, we copy the - * received data to a separate mbuf that does not use - * a cluster, if possible. - * XXX: it is better to copy the data after stripping - * intermediate headers. - */ - if ((m->m_flags & M_EXT) && m->m_next == NULL && - m->m_len <= MHLEN) { - MGET(n, M_DONTWAIT, m->m_type); - if (n != NULL) { - if (m_dup_pkthdr(n, m, M_NOWAIT)) { - bcopy(m->m_data, n->m_data, - m->m_len); - n->m_len = m->m_len; - } else { - m_free(n); - n = NULL; - } - } - } - if (n != NULL || - (n = m_copy(m, 0, (int)M_COPYALL)) != NULL) { - if (last->in6p_flags & IN6P_CONTROLOPTS) - ip6_savecontrol(last, n, &opts); - /* strip intermediate headers */ - m_adj(n, off); - SOCKBUF_LOCK(&last->in6p_socket->so_rcv); - if (sbappendaddr_locked( - &last->in6p_socket->so_rcv, - (struct sockaddr *)&fromsa, n, opts) - == 0) { - /* should notify about lost packet */ - m_freem(n); - if (opts) { - m_freem(opts); - } - SOCKBUF_UNLOCK( - &last->in6p_socket->so_rcv); - } else - sorwakeup_locked(last->in6p_socket); - opts = NULL; - } - INP_UNLOCK(last); - } - last = in6p; - } - if (last) { - if (last->in6p_flags & IN6P_CONTROLOPTS) - ip6_savecontrol(last, m, &opts); - /* strip intermediate headers */ - m_adj(m, off); - - /* avoid using mbuf clusters if possible (see above) */ - if ((m->m_flags & M_EXT) && m->m_next == NULL && - m->m_len <= MHLEN) { - struct mbuf *n; - - MGET(n, M_DONTWAIT, m->m_type); - if (n != NULL) { - if (m_dup_pkthdr(n, m, M_NOWAIT)) { - bcopy(m->m_data, n->m_data, m->m_len); - n->m_len = m->m_len; - - m_freem(m); - m = n; - } else { - m_freem(n); - n = NULL; - } - } - } - SOCKBUF_LOCK(&last->in6p_socket->so_rcv); - if (sbappendaddr_locked(&last->in6p_socket->so_rcv, - (struct sockaddr *)&fromsa, m, opts) == 0) { - m_freem(m); - if (opts) - m_freem(opts); - SOCKBUF_UNLOCK(&last->in6p_socket->so_rcv); - } else - sorwakeup_locked(last->in6p_socket); - INP_UNLOCK(last); - } else { - m_freem(m); - ip6stat.ip6s_delivered--; - } - INP_INFO_RUNLOCK(&ripcbinfo); - return IPPROTO_DONE; -} - -/* - * Reflect the ip6 packet back to the source. - * OFF points to the icmp6 header, counted from the top of the mbuf. - */ -void -icmp6_reflect(struct mbuf *m, size_t off) -{ - struct ip6_hdr *ip6; - struct icmp6_hdr *icmp6; - struct in6_ifaddr *ia; - int plen; - int type, code; - struct ifnet *outif = NULL; - struct in6_addr origdst, *src = NULL; - - /* too short to reflect */ - if (off < sizeof(struct ip6_hdr)) { - nd6log((LOG_DEBUG, - "sanity fail: off=%lx, sizeof(ip6)=%lx in %s:%d\n", - (u_long)off, (u_long)sizeof(struct ip6_hdr), - __FILE__, __LINE__)); - goto bad; - } - - /* - * If there are extra headers between IPv6 and ICMPv6, strip - * off that header first. - */ -#ifdef DIAGNOSTIC - if (sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr) > MHLEN) - panic("assumption failed in icmp6_reflect"); -#endif - if (off > sizeof(struct ip6_hdr)) { - size_t l; - struct ip6_hdr nip6; - - l = off - sizeof(struct ip6_hdr); - m_copydata(m, 0, sizeof(nip6), (caddr_t)&nip6); - m_adj(m, l); - l = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr); - if (m->m_len < l) { - if ((m = m_pullup(m, l)) == NULL) - return; - } - bcopy((caddr_t)&nip6, mtod(m, caddr_t), sizeof(nip6)); - } else /* off == sizeof(struct ip6_hdr) */ { - size_t l; - l = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr); - if (m->m_len < l) { - if ((m = m_pullup(m, l)) == NULL) - return; - } - } - plen = m->m_pkthdr.len - sizeof(struct ip6_hdr); - ip6 = mtod(m, struct ip6_hdr *); - ip6->ip6_nxt = IPPROTO_ICMPV6; - icmp6 = (struct icmp6_hdr *)(ip6 + 1); - type = icmp6->icmp6_type; /* keep type for statistics */ - code = icmp6->icmp6_code; /* ditto. */ - - origdst = ip6->ip6_dst; - /* - * ip6_input() drops a packet if its src is multicast. - * So, the src is never multicast. - */ - ip6->ip6_dst = ip6->ip6_src; - - /* - * If the incoming packet was addressed directly to us (i.e. unicast), - * use dst as the src for the reply. - * The IN6_IFF_NOTREADY case should be VERY rare, but is possible - * (for example) when we encounter an error while forwarding procedure - * destined to a duplicated address of ours. - * Note that ip6_getdstifaddr() may fail if we are in an error handling - * procedure of an outgoing packet of our own, in which case we need - * to search in the ifaddr list. - */ - if (!IN6_IS_ADDR_MULTICAST(&origdst)) { - if ((ia = ip6_getdstifaddr(m))) { - if (!(ia->ia6_flags & - (IN6_IFF_ANYCAST|IN6_IFF_NOTREADY))) - src = &ia->ia_addr.sin6_addr; - } else { - struct sockaddr_in6 d; - - bzero(&d, sizeof(d)); - d.sin6_family = AF_INET6; - d.sin6_len = sizeof(d); - d.sin6_addr = origdst; - ia = (struct in6_ifaddr *) - ifa_ifwithaddr((struct sockaddr *)&d); - if (ia && - !(ia->ia6_flags & - (IN6_IFF_ANYCAST|IN6_IFF_NOTREADY))) { - src = &ia->ia_addr.sin6_addr; - } - } - } - - if (src == NULL) { - int e; - struct sockaddr_in6 sin6; - struct route_in6 ro; - - /* - * This case matches to multicasts, our anycast, or unicasts - * that we do not own. Select a source address based on the - * source address of the erroneous packet. - */ - bzero(&sin6, sizeof(sin6)); - sin6.sin6_family = AF_INET6; - sin6.sin6_len = sizeof(sin6); - sin6.sin6_addr = ip6->ip6_dst; /* zone ID should be embedded */ - - bzero(&ro, sizeof(ro)); - src = in6_selectsrc(&sin6, NULL, NULL, &ro, NULL, &outif, &e); - if (ro.ro_rt) - RTFREE(ro.ro_rt); /* XXX: we could use this */ - if (src == NULL) { - char ip6buf[INET6_ADDRSTRLEN]; - nd6log((LOG_DEBUG, - "icmp6_reflect: source can't be determined: " - "dst=%s, error=%d\n", - ip6_sprintf(ip6buf, &sin6.sin6_addr), e)); - goto bad; - } - } - - ip6->ip6_src = *src; - ip6->ip6_flow = 0; - ip6->ip6_vfc &= ~IPV6_VERSION_MASK; - ip6->ip6_vfc |= IPV6_VERSION; - ip6->ip6_nxt = IPPROTO_ICMPV6; - if (outif) - ip6->ip6_hlim = ND_IFINFO(outif)->chlim; - else if (m->m_pkthdr.rcvif) { - /* XXX: This may not be the outgoing interface */ - ip6->ip6_hlim = ND_IFINFO(m->m_pkthdr.rcvif)->chlim; - } else - ip6->ip6_hlim = ip6_defhlim; - - icmp6->icmp6_cksum = 0; - icmp6->icmp6_cksum = in6_cksum(m, IPPROTO_ICMPV6, - sizeof(struct ip6_hdr), plen); - - /* - * XXX option handling - */ - - m->m_flags &= ~(M_BCAST|M_MCAST); - - ip6_output(m, NULL, NULL, 0, NULL, &outif, NULL); - if (outif) - icmp6_ifoutstat_inc(outif, type, code); - - return; - - bad: - m_freem(m); - return; -} - -void -icmp6_fasttimo(void) -{ - - return; -} - -static const char * -icmp6_redirect_diag(struct in6_addr *src6, struct in6_addr *dst6, - struct in6_addr *tgt6) -{ - static char buf[1024]; - char ip6bufs[INET6_ADDRSTRLEN]; - char ip6bufd[INET6_ADDRSTRLEN]; - char ip6buft[INET6_ADDRSTRLEN]; - snprintf(buf, sizeof(buf), "(src=%s dst=%s tgt=%s)", - ip6_sprintf(ip6bufs, src6), ip6_sprintf(ip6bufd, dst6), - ip6_sprintf(ip6buft, tgt6)); - return buf; -} - -void -icmp6_redirect_input(struct mbuf *m, int off) -{ - struct ifnet *ifp; - struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *); - struct nd_redirect *nd_rd; - int icmp6len = ntohs(ip6->ip6_plen); - char *lladdr = NULL; - int lladdrlen = 0; - u_char *redirhdr = NULL; - int redirhdrlen = 0; - struct rtentry *rt = NULL; - int is_router; - int is_onlink; - struct in6_addr src6 = ip6->ip6_src; - struct in6_addr redtgt6; - struct in6_addr reddst6; - union nd_opts ndopts; - char ip6buf[INET6_ADDRSTRLEN]; - - if (!m) - return; - - ifp = m->m_pkthdr.rcvif; - - if (!ifp) - return; - - /* XXX if we are router, we don't update route by icmp6 redirect */ - if (ip6_forwarding) - goto freeit; - if (!icmp6_rediraccept) - goto freeit; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, icmp6len,); - nd_rd = (struct nd_redirect *)((caddr_t)ip6 + off); -#else - IP6_EXTHDR_GET(nd_rd, struct nd_redirect *, m, off, icmp6len); - if (nd_rd == NULL) { - icmp6stat.icp6s_tooshort++; - return; - } -#endif - redtgt6 = nd_rd->nd_rd_target; - reddst6 = nd_rd->nd_rd_dst; - - if (in6_setscope(&redtgt6, m->m_pkthdr.rcvif, NULL) || - in6_setscope(&reddst6, m->m_pkthdr.rcvif, NULL)) { - goto freeit; - } - - /* validation */ - if (!IN6_IS_ADDR_LINKLOCAL(&src6)) { - nd6log((LOG_ERR, - "ICMP6 redirect sent from %s rejected; " - "must be from linklocal\n", - ip6_sprintf(ip6buf, &src6))); - goto bad; - } - if (ip6->ip6_hlim != 255) { - nd6log((LOG_ERR, - "ICMP6 redirect sent from %s rejected; " - "hlim=%d (must be 255)\n", - ip6_sprintf(ip6buf, &src6), ip6->ip6_hlim)); - goto bad; - } - { - /* ip6->ip6_src must be equal to gw for icmp6->icmp6_reddst */ - struct sockaddr_in6 sin6; - struct in6_addr *gw6; - - bzero(&sin6, sizeof(sin6)); - sin6.sin6_family = AF_INET6; - sin6.sin6_len = sizeof(struct sockaddr_in6); - bcopy(&reddst6, &sin6.sin6_addr, sizeof(reddst6)); - rt = rtalloc1((struct sockaddr *)&sin6, 0, 0UL); - if (rt) { - if (rt->rt_gateway == NULL || - rt->rt_gateway->sa_family != AF_INET6) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; no route " - "with inet6 gateway found for redirect dst: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - RTFREE_LOCKED(rt); - goto bad; - } - - gw6 = &(((struct sockaddr_in6 *)rt->rt_gateway)->sin6_addr); - if (bcmp(&src6, gw6, sizeof(struct in6_addr)) != 0) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "not equal to gw-for-src=%s (must be same): " - "%s\n", - ip6_sprintf(ip6buf, gw6), - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - RTFREE_LOCKED(rt); - goto bad; - } - } else { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "no route found for redirect dst: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - RTFREE_LOCKED(rt); - rt = NULL; - } - if (IN6_IS_ADDR_MULTICAST(&reddst6)) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "redirect dst must be unicast: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - - is_router = is_onlink = 0; - if (IN6_IS_ADDR_LINKLOCAL(&redtgt6)) - is_router = 1; /* router case */ - if (bcmp(&redtgt6, &reddst6, sizeof(redtgt6)) == 0) - is_onlink = 1; /* on-link destination case */ - if (!is_router && !is_onlink) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "neither router case nor onlink case: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - /* validation passed */ - - icmp6len -= sizeof(*nd_rd); - nd6_option_init(nd_rd + 1, icmp6len, &ndopts); - if (nd6_options(&ndopts) < 0) { - nd6log((LOG_INFO, "icmp6_redirect_input: " - "invalid ND option, rejected: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - /* nd6_options have incremented stats */ - goto freeit; - } - - if (ndopts.nd_opts_tgt_lladdr) { - lladdr = (char *)(ndopts.nd_opts_tgt_lladdr + 1); - lladdrlen = ndopts.nd_opts_tgt_lladdr->nd_opt_len << 3; - } - - if (ndopts.nd_opts_rh) { - redirhdrlen = ndopts.nd_opts_rh->nd_opt_rh_len; - redirhdr = (u_char *)(ndopts.nd_opts_rh + 1); /* xxx */ - } - - if (lladdr && ((ifp->if_addrlen + 2 + 7) & ~7) != lladdrlen) { - nd6log((LOG_INFO, - "icmp6_redirect_input: lladdrlen mismatch for %s " - "(if %d, icmp6 packet %d): %s\n", - ip6_sprintf(ip6buf, &redtgt6), - ifp->if_addrlen, lladdrlen - 2, - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - - /* RFC 2461 8.3 */ - nd6_cache_lladdr(ifp, &redtgt6, lladdr, lladdrlen, ND_REDIRECT, - is_onlink ? ND_REDIRECT_ONLINK : ND_REDIRECT_ROUTER); - - if (!is_onlink) { /* better router case. perform rtredirect. */ - /* perform rtredirect */ - struct sockaddr_in6 sdst; - struct sockaddr_in6 sgw; - struct sockaddr_in6 ssrc; - - bzero(&sdst, sizeof(sdst)); - bzero(&sgw, sizeof(sgw)); - bzero(&ssrc, sizeof(ssrc)); - sdst.sin6_family = sgw.sin6_family = ssrc.sin6_family = AF_INET6; - sdst.sin6_len = sgw.sin6_len = ssrc.sin6_len = - sizeof(struct sockaddr_in6); - bcopy(&redtgt6, &sgw.sin6_addr, sizeof(struct in6_addr)); - bcopy(&reddst6, &sdst.sin6_addr, sizeof(struct in6_addr)); - bcopy(&src6, &ssrc.sin6_addr, sizeof(struct in6_addr)); - rtredirect((struct sockaddr *)&sdst, (struct sockaddr *)&sgw, - (struct sockaddr *)NULL, RTF_GATEWAY | RTF_HOST, - (struct sockaddr *)&ssrc); - } - /* finally update cached route in each socket via pfctlinput */ - { - struct sockaddr_in6 sdst; - - bzero(&sdst, sizeof(sdst)); - sdst.sin6_family = AF_INET6; - sdst.sin6_len = sizeof(struct sockaddr_in6); - bcopy(&reddst6, &sdst.sin6_addr, sizeof(struct in6_addr)); - pfctlinput(PRC_REDIRECT_HOST, (struct sockaddr *)&sdst); -#ifdef IPSEC - key_sa_routechange((struct sockaddr *)&sdst); -#endif /* IPSEC */ - } - - freeit: - m_freem(m); - return; - - bad: - icmp6stat.icp6s_badredirect++; - m_freem(m); -} - -void -icmp6_redirect_output(struct mbuf *m0, struct rtentry *rt) -{ - struct ifnet *ifp; /* my outgoing interface */ - struct in6_addr *ifp_ll6; - struct in6_addr *router_ll6; - struct ip6_hdr *sip6; /* m0 as struct ip6_hdr */ - struct mbuf *m = NULL; /* newly allocated one */ - struct ip6_hdr *ip6; /* m as struct ip6_hdr */ - struct nd_redirect *nd_rd; - size_t maxlen; - u_char *p; - struct ifnet *outif = NULL; - struct sockaddr_in6 src_sa; - - icmp6_errcount(&icmp6stat.icp6s_outerrhist, ND_REDIRECT, 0); - - /* if we are not router, we don't send icmp6 redirect */ - if (!ip6_forwarding) - goto fail; - - /* sanity check */ - if (!m0 || !rt || !(rt->rt_flags & RTF_UP) || !(ifp = rt->rt_ifp)) - goto fail; - - /* - * Address check: - * the source address must identify a neighbor, and - * the destination address must not be a multicast address - * [RFC 2461, sec 8.2] - */ - sip6 = mtod(m0, struct ip6_hdr *); - bzero(&src_sa, sizeof(src_sa)); - src_sa.sin6_family = AF_INET6; - src_sa.sin6_len = sizeof(src_sa); - src_sa.sin6_addr = sip6->ip6_src; - if (nd6_is_addr_neighbor(&src_sa, ifp) == 0) - goto fail; - if (IN6_IS_ADDR_MULTICAST(&sip6->ip6_dst)) - goto fail; /* what should we do here? */ - - /* rate limit */ - if (icmp6_ratelimit(&sip6->ip6_src, ND_REDIRECT, 0)) - goto fail; - - /* - * Since we are going to append up to 1280 bytes (= IPV6_MMTU), - * we almost always ask for an mbuf cluster for simplicity. - * (MHLEN < IPV6_MMTU is almost always true) - */ -#if IPV6_MMTU >= MCLBYTES -# error assumption failed about IPV6_MMTU and MCLBYTES -#endif - MGETHDR(m, M_DONTWAIT, MT_HEADER); - if (m && IPV6_MMTU >= MHLEN) - MCLGET(m, M_DONTWAIT); - if (!m) - goto fail; - m->m_pkthdr.rcvif = NULL; - m->m_len = 0; - maxlen = M_TRAILINGSPACE(m); - maxlen = min(IPV6_MMTU, maxlen); - /* just for safety */ - if (maxlen < sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr) + - ((sizeof(struct nd_opt_hdr) + ifp->if_addrlen + 7) & ~7)) { - goto fail; - } - - { - /* get ip6 linklocal address for ifp(my outgoing interface). */ - struct in6_ifaddr *ia; - if ((ia = in6ifa_ifpforlinklocal(ifp, - IN6_IFF_NOTREADY| - IN6_IFF_ANYCAST)) == NULL) - goto fail; - ifp_ll6 = &ia->ia_addr.sin6_addr; - } - - /* get ip6 linklocal address for the router. */ - if (rt->rt_gateway && (rt->rt_flags & RTF_GATEWAY)) { - struct sockaddr_in6 *sin6; - sin6 = (struct sockaddr_in6 *)rt->rt_gateway; - router_ll6 = &sin6->sin6_addr; - if (!IN6_IS_ADDR_LINKLOCAL(router_ll6)) - router_ll6 = (struct in6_addr *)NULL; - } else - router_ll6 = (struct in6_addr *)NULL; - - /* ip6 */ - ip6 = mtod(m, struct ip6_hdr *); - ip6->ip6_flow = 0; - ip6->ip6_vfc &= ~IPV6_VERSION_MASK; - ip6->ip6_vfc |= IPV6_VERSION; - /* ip6->ip6_plen will be set later */ - ip6->ip6_nxt = IPPROTO_ICMPV6; - ip6->ip6_hlim = 255; - /* ip6->ip6_src must be linklocal addr for my outgoing if. */ - bcopy(ifp_ll6, &ip6->ip6_src, sizeof(struct in6_addr)); - bcopy(&sip6->ip6_src, &ip6->ip6_dst, sizeof(struct in6_addr)); - - /* ND Redirect */ - nd_rd = (struct nd_redirect *)(ip6 + 1); - nd_rd->nd_rd_type = ND_REDIRECT; - nd_rd->nd_rd_code = 0; - nd_rd->nd_rd_reserved = 0; - if (rt->rt_flags & RTF_GATEWAY) { - /* - * nd_rd->nd_rd_target must be a link-local address in - * better router cases. - */ - if (!router_ll6) - goto fail; - bcopy(router_ll6, &nd_rd->nd_rd_target, - sizeof(nd_rd->nd_rd_target)); - bcopy(&sip6->ip6_dst, &nd_rd->nd_rd_dst, - sizeof(nd_rd->nd_rd_dst)); - } else { - /* make sure redtgt == reddst */ - bcopy(&sip6->ip6_dst, &nd_rd->nd_rd_target, - sizeof(nd_rd->nd_rd_target)); - bcopy(&sip6->ip6_dst, &nd_rd->nd_rd_dst, - sizeof(nd_rd->nd_rd_dst)); - } - - p = (u_char *)(nd_rd + 1); - - if (!router_ll6) - goto nolladdropt; - - { - /* target lladdr option */ - struct rtentry *rt_router = NULL; - int len; - struct sockaddr_dl *sdl; - struct nd_opt_hdr *nd_opt; - char *lladdr; - - rt_router = nd6_lookup(router_ll6, 0, ifp); - if (!rt_router) - goto nolladdropt; - len = sizeof(*nd_opt) + ifp->if_addrlen; - len = (len + 7) & ~7; /* round by 8 */ - /* safety check */ - if (len + (p - (u_char *)ip6) > maxlen) - goto nolladdropt; - if (!(rt_router->rt_flags & RTF_GATEWAY) && - (rt_router->rt_flags & RTF_LLINFO) && - (rt_router->rt_gateway->sa_family == AF_LINK) && - (sdl = (struct sockaddr_dl *)rt_router->rt_gateway) && - sdl->sdl_alen) { - nd_opt = (struct nd_opt_hdr *)p; - nd_opt->nd_opt_type = ND_OPT_TARGET_LINKADDR; - nd_opt->nd_opt_len = len >> 3; - lladdr = (char *)(nd_opt + 1); - bcopy(LLADDR(sdl), lladdr, ifp->if_addrlen); - p += len; - } - } -nolladdropt:; - - m->m_pkthdr.len = m->m_len = p - (u_char *)ip6; - - /* just to be safe */ -#ifdef M_DECRYPTED /*not openbsd*/ - if (m0->m_flags & M_DECRYPTED) - goto noredhdropt; -#endif - if (p - (u_char *)ip6 > maxlen) - goto noredhdropt; - - { - /* redirected header option */ - int len; - struct nd_opt_rd_hdr *nd_opt_rh; - - /* - * compute the maximum size for icmp6 redirect header option. - * XXX room for auth header? - */ - len = maxlen - (p - (u_char *)ip6); - len &= ~7; - - /* This is just for simplicity. */ - if (m0->m_pkthdr.len != m0->m_len) { - if (m0->m_next) { - m_freem(m0->m_next); - m0->m_next = NULL; - } - m0->m_pkthdr.len = m0->m_len; - } - - /* - * Redirected header option spec (RFC2461 4.6.3) talks nothing - * about padding/truncate rule for the original IP packet. - * From the discussion on IPv6imp in Feb 1999, - * the consensus was: - * - "attach as much as possible" is the goal - * - pad if not aligned (original size can be guessed by - * original ip6 header) - * Following code adds the padding if it is simple enough, - * and truncates if not. - */ - if (m0->m_next || m0->m_pkthdr.len != m0->m_len) - panic("assumption failed in %s:%d", __FILE__, - __LINE__); - - if (len - sizeof(*nd_opt_rh) < m0->m_pkthdr.len) { - /* not enough room, truncate */ - m0->m_pkthdr.len = m0->m_len = len - - sizeof(*nd_opt_rh); - } else { - /* enough room, pad or truncate */ - size_t extra; - - extra = m0->m_pkthdr.len % 8; - if (extra) { - /* pad if easy enough, truncate if not */ - if (8 - extra <= M_TRAILINGSPACE(m0)) { - /* pad */ - m0->m_len += (8 - extra); - m0->m_pkthdr.len += (8 - extra); - } else { - /* truncate */ - m0->m_pkthdr.len -= extra; - m0->m_len -= extra; - } - } - len = m0->m_pkthdr.len + sizeof(*nd_opt_rh); - m0->m_pkthdr.len = m0->m_len = len - - sizeof(*nd_opt_rh); - } - - nd_opt_rh = (struct nd_opt_rd_hdr *)p; - bzero(nd_opt_rh, sizeof(*nd_opt_rh)); - nd_opt_rh->nd_opt_rh_type = ND_OPT_REDIRECTED_HEADER; - nd_opt_rh->nd_opt_rh_len = len >> 3; - p += sizeof(*nd_opt_rh); - m->m_pkthdr.len = m->m_len = p - (u_char *)ip6; - - /* connect m0 to m */ - m_tag_delete_chain(m0, NULL); - m0->m_flags &= ~M_PKTHDR; - m->m_next = m0; - m->m_pkthdr.len = m->m_len + m0->m_len; - m0 = NULL; - } -noredhdropt:; - if (m0) { - m_freem(m0); - m0 = NULL; - } - - /* XXX: clear embedded link IDs in the inner header */ - in6_clearscope(&sip6->ip6_src); - in6_clearscope(&sip6->ip6_dst); - in6_clearscope(&nd_rd->nd_rd_target); - in6_clearscope(&nd_rd->nd_rd_dst); - - ip6->ip6_plen = htons(m->m_pkthdr.len - sizeof(struct ip6_hdr)); - - nd_rd->nd_rd_cksum = 0; - nd_rd->nd_rd_cksum = in6_cksum(m, IPPROTO_ICMPV6, - sizeof(*ip6), ntohs(ip6->ip6_plen)); - - /* send the packet to outside... */ - ip6_output(m, NULL, NULL, 0, NULL, &outif, NULL); - if (outif) { - icmp6_ifstat_inc(outif, ifs6_out_msg); - icmp6_ifstat_inc(outif, ifs6_out_redirect); - } - icmp6stat.icp6s_outhist[ND_REDIRECT]++; - - return; - -fail: - if (m) - m_freem(m); - if (m0) - m_freem(m0); -} - -/* - * ICMPv6 socket option processing. - */ -int -icmp6_ctloutput(struct socket *so, struct sockopt *sopt) -{ - int error = 0; - int optlen; - struct inpcb *inp = sotoinpcb(so); - int level, op, optname; - - if (sopt) { - level = sopt->sopt_level; - op = sopt->sopt_dir; - optname = sopt->sopt_name; - optlen = sopt->sopt_valsize; - } else - level = op = optname = optlen = 0; - - if (level != IPPROTO_ICMPV6) { - return EINVAL; - } - - switch (op) { - case PRCO_SETOPT: - switch (optname) { - case ICMP6_FILTER: - { - struct icmp6_filter *p; - - if (optlen != sizeof(*p)) { - error = EMSGSIZE; - break; - } - if (inp->in6p_icmp6filt == NULL) { - error = EINVAL; - break; - } - error = sooptcopyin(sopt, inp->in6p_icmp6filt, optlen, - optlen); - break; - } - - default: - error = ENOPROTOOPT; - break; - } - break; - - case PRCO_GETOPT: - switch (optname) { - case ICMP6_FILTER: - { - if (inp->in6p_icmp6filt == NULL) { - error = EINVAL; - break; - } - error = sooptcopyout(sopt, inp->in6p_icmp6filt, - sizeof(struct icmp6_filter)); - break; - } - - default: - error = ENOPROTOOPT; - break; - } - break; - } - - return (error); -} - -/* - * Perform rate limit check. - * Returns 0 if it is okay to send the icmp6 packet. - * Returns 1 if the router SHOULD NOT send this icmp6 packet due to rate - * limitation. - * - * XXX per-destination/type check necessary? - * - * dst - not used at this moment - * type - not used at this moment - * code - not used at this moment - */ -static int -icmp6_ratelimit(const struct in6_addr *dst, const int type, - const int code) -{ - int ret; - - ret = 0; /* okay to send */ - - /* PPS limit */ - if (!ppsratecheck(&icmp6errppslim_last, &icmp6errpps_count, - icmp6errppslim)) { - /* The packet is subject to rate limit */ - ret++; - } - - return ret; -} From laffer1 at midnightbsd.org Sat Jan 10 21:43:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:43:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: vfs_mount.c: prevent nmount(2) local arbitrary code execution Message-ID: <200901110243.n0B2hVCU088421@stargazer.midnightbsd.org> Log Message: ----------- prevent nmount(2) local arbitrary code execution Modified Files: -------------- src/sys/kern: vfs_mount.c (r1.5 -> r1.6) -------------- next part -------------- Index: vfs_mount.c =================================================================== RCS file: /home/cvs/src/sys/kern/vfs_mount.c,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/kern/vfs_mount.c -L sys/kern/vfs_mount.c -u -r1.5 -r1.6 --- sys/kern/vfs_mount.c +++ sys/kern/vfs_mount.c @@ -1830,7 +1830,8 @@ } if (*t != NULL) continue; - sprintf(errmsg, "mount option <%s> is unknown", p); + snprintf(errmsg, sizeof(errmsg), + "mount option <%s> is unknown", p); printf("%s\n", errmsg); ret = EINVAL; } From laffer1 at midnightbsd.org Sat Jan 10 21:45:04 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:45:04 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/netinet: fix incorrect tcp padding on options Message-ID: <200901110245.n0B2j4bl088692@stargazer.midnightbsd.org> Log Message: ----------- fix incorrect tcp padding on options Modified Files: -------------- src/sys/netinet: tcp.h (r1.3 -> r1.4) tcp_output.c (r1.5 -> r1.6) -------------- next part -------------- Index: tcp_output.c =================================================================== RCS file: /home/cvs/src/sys/netinet/tcp_output.c,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/netinet/tcp_output.c -L sys/netinet/tcp_output.c -u -r1.5 -r1.6 --- sys/netinet/tcp_output.c +++ sys/netinet/tcp_output.c @@ -1281,12 +1281,16 @@ for (mask = 1; mask < TOF_MAXOPT; mask <<= 1) { if ((to->to_flags & mask) != mask) continue; + if (optlen == TCP_MAXOLEN) + break; switch (to->to_flags & mask) { case TOF_MSS: while (optlen % 4) { optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_MAXSEG) + continue; optlen += TCPOLEN_MAXSEG; *optp++ = TCPOPT_MAXSEG; *optp++ = TCPOLEN_MAXSEG; @@ -1299,6 +1303,8 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_WINDOW) + continue; optlen += TCPOLEN_WINDOW; *optp++ = TCPOPT_WINDOW; *optp++ = TCPOLEN_WINDOW; @@ -1309,6 +1315,8 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_SACK_PERMITTED) + continue; optlen += TCPOLEN_SACK_PERMITTED; *optp++ = TCPOPT_SACK_PERMITTED; *optp++ = TCPOLEN_SACK_PERMITTED; @@ -1318,6 +1326,8 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_TIMESTAMP) + continue; optlen += TCPOLEN_TIMESTAMP; *optp++ = TCPOPT_TIMESTAMP; *optp++ = TCPOLEN_TIMESTAMP; @@ -1356,7 +1366,7 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } - if (TCP_MAXOLEN - optlen < 2 + TCPOLEN_SACK) + if (TCP_MAXOLEN - optlen < TCPOLEN_SACKHDR + TCPOLEN_SACK) continue; optlen += TCPOLEN_SACKHDR; *optp++ = TCPOPT_SACK; @@ -1387,9 +1397,15 @@ optlen += TCPOLEN_EOL; *optp++ = TCPOPT_EOL; } + /* + * According to RFC 793 (STD0007): + * "The content of the header beyond the End-of-Option option + * must be header padding (i.e., zero)." + * and later: "The padding is composed of zeros." + */ while (optlen % 4) { - optlen += TCPOLEN_NOP; - *optp++ = TCPOPT_NOP; + optlen += TCPOLEN_PAD; + *optp++ = TCPOPT_PAD; } KASSERT(optlen <= TCP_MAXOLEN, ("%s: TCP options too long", __func__)); Index: tcp.h =================================================================== RCS file: /home/cvs/src/sys/netinet/tcp.h,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/netinet/tcp.h -L sys/netinet/tcp.h -u -r1.3 -r1.4 --- sys/netinet/tcp.h +++ sys/netinet/tcp.h @@ -79,6 +79,8 @@ #define TCPOPT_EOL 0 #define TCPOLEN_EOL 1 +#define TCPOPT_PAD 0 /* padding after EOL */ +#define TCPOLEN_PAD 1 #define TCPOPT_NOP 1 #define TCPOLEN_NOP 1 #define TCPOPT_MAXSEG 2 From laffer1 at midnightbsd.org Mon Jan 12 17:31:34 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 17:31:34 -0500 (EST) Subject: [Midnightbsd-cvs] mports: net/GeoIP: update to 1.4.5, add free database update script Message-ID: <200901122231.n0CMVYqT032441@stargazer.midnightbsd.org> Log Message: ----------- update to 1.4.5, add free database update script Modified Files: -------------- mports/net/GeoIP: Makefile (r1.1 -> r1.2) distinfo (r1.1 -> r1.2) pkg-plist (r1.1 -> r1.2) Added Files: ----------- mports/net/GeoIP/files: geoipupdate.sh (r1.1) -------------- next part -------------- Index: pkg-plist =================================================================== RCS file: /home/cvs/mports/net/GeoIP/pkg-plist,v retrieving revision 1.1 retrieving revision 1.2 diff -L net/GeoIP/pkg-plist -L net/GeoIP/pkg-plist -u -r1.1 -r1.2 --- net/GeoIP/pkg-plist +++ net/GeoIP/pkg-plist @@ -1,5 +1,7 @@ bin/geoiplookup +bin/geoiplookup6 bin/geoipupdate +bin/geoipupdate.sh @unexec if cmp -s %D/etc/GeoIP.conf %D/etc/GeoIP.conf.default; then rm -f %D/etc/GeoIP.conf; fi etc/GeoIP.conf.default include/GeoIP.h Index: Makefile =================================================================== RCS file: /home/cvs/mports/net/GeoIP/Makefile,v retrieving revision 1.1 retrieving revision 1.2 diff -L net/GeoIP/Makefile -L net/GeoIP/Makefile -u -r1.1 -r1.2 --- net/GeoIP/Makefile +++ net/GeoIP/Makefile @@ -6,9 +6,10 @@ # PORTNAME= GeoIP -PORTVERSION= 1.4.4 +PORTVERSION= 1.4.5 CATEGORIES= net geography -MASTER_SITES= http://www.maxmind.com/download/geoip/api/c/ +MASTER_SITES= http://www.maxmind.com/download/geoip/api/c/ \ + http://mirror.mcx2.org/ MAINTAINER= ports at MidnightBSD.org COMMENT= Find the country that any IP address or hostname originates from @@ -21,4 +22,7 @@ MAN1= geoiplookup.1 geoipupdate.1 +post-install: + ${INSTALL_SCRIPT} ${FILESDIR}/geoipupdate.sh ${PREFIX}/bin/ + .include Index: distinfo =================================================================== RCS file: /home/cvs/mports/net/GeoIP/distinfo,v retrieving revision 1.1 retrieving revision 1.2 diff -L net/GeoIP/distinfo -L net/GeoIP/distinfo -u -r1.1 -r1.2 --- net/GeoIP/distinfo +++ net/GeoIP/distinfo @@ -1,3 +1,3 @@ -MD5 (GeoIP-1.4.4.tar.gz) = 27c1320e41e67b9ddcf4118e4eaccd1d -SHA256 (GeoIP-1.4.4.tar.gz) = a5b2ee9298eaf8c160ccab5b3e2ecc1c38cf67d9dd4e97419427f89d08cfb78e -SIZE (GeoIP-1.4.4.tar.gz) = 944698 +MD5 (GeoIP-1.4.5.tar.gz) = d95c34cf8ebd48e357b1812db5d75cf1 +SHA256 (GeoIP-1.4.5.tar.gz) = cd62034fe0206be243cbb43723520987978d8e55ee61872f34fd60a31f5c6b18 +SIZE (GeoIP-1.4.5.tar.gz) = 986844 --- /dev/null +++ net/GeoIP/files/geoipupdate.sh @@ -0,0 +1,5 @@ +#!/bin/sh +cd /tmp +fetch http://64.246.48.99/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz +gunzip GeoIP.dat.gz +mv -f GeoIP.dat /usr/local/share/GeoIP From laffer1 at midnightbsd.org Mon Jan 12 17:38:05 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 17:38:05 -0500 (EST) Subject: [Midnightbsd-cvs] mports: net/rsync: update to 3.0.5 Message-ID: <200901122238.n0CMc5gx040000@stargazer.midnightbsd.org> Log Message: ----------- update to 3.0.5 Modified Files: -------------- mports/net/rsync: Makefile (r1.9 -> r1.10) distinfo (r1.5 -> r1.6) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/net/rsync/Makefile,v retrieving revision 1.9 retrieving revision 1.10 diff -L net/rsync/Makefile -L net/rsync/Makefile -u -r1.9 -r1.10 --- net/rsync/Makefile +++ net/rsync/Makefile @@ -7,7 +7,7 @@ # PORTNAME= rsync -PORTVERSION= 3.0.4 +PORTVERSION= 3.0.5 CATEGORIES= net ipv6 MASTER_SITES= http://rsync.samba.org/ftp/%SUBDIR%/ \ ftp://ftp.samba.org/pub/%SUBDIR%/ \ Index: distinfo =================================================================== RCS file: /home/cvs/mports/net/rsync/distinfo,v retrieving revision 1.5 retrieving revision 1.6 diff -L net/rsync/distinfo -L net/rsync/distinfo -u -r1.5 -r1.6 --- net/rsync/distinfo +++ net/rsync/distinfo @@ -1,6 +1,6 @@ -MD5 (rsync-3.0.4.tar.gz) = 2b2d159c9bd1b5f8adfd8b13da3a1f3f -SHA256 (rsync-3.0.4.tar.gz) = 743a49cf01d2e4cf57be7bfbb02e04c0b20e7b7ec58195c20df710b991cede51 -SIZE (rsync-3.0.4.tar.gz) = 773083 -MD5 (rsync-patches-3.0.4.tar.gz) = a7697d7002f7789faede7109b420b94c -SHA256 (rsync-patches-3.0.4.tar.gz) = 5d654231fbf38ec0cec76989d466c7e8eaa72caacae2758817ca842a21777d2e -SIZE (rsync-patches-3.0.4.tar.gz) = 159292 +MD5 (rsync-3.0.5.tar.gz) = a130e736c011572cb423b6245e97fc4b +SHA256 (rsync-3.0.5.tar.gz) = 40ac20af81d4bc19ed82381371d731f7fb5a26fe4c1e4d4461b1255db63743cb +SIZE (rsync-3.0.5.tar.gz) = 776613 +MD5 (rsync-patches-3.0.5.tar.gz) = ada27361a483f7366b9bb3dab4cba0d0 +SHA256 (rsync-patches-3.0.5.tar.gz) = 64d98f844645832c3ed749c5508db2b0653fad52b4f67a78e3e7934924ee5cae +SIZE (rsync-patches-3.0.5.tar.gz) = 161055 From laffer1 at midnightbsd.org Mon Jan 12 20:01:11 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 20:01:11 -0500 (EST) Subject: [Midnightbsd-cvs] mports: www/moinmoin: update to 1.7.3 Message-ID: <200901130101.n0D11BXf056198@stargazer.midnightbsd.org> Log Message: ----------- update to 1.7.3 Modified Files: -------------- mports/www/moinmoin: Makefile (r1.3 -> r1.4) distinfo (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/www/moinmoin/Makefile,v retrieving revision 1.3 retrieving revision 1.4 diff -L www/moinmoin/Makefile -L www/moinmoin/Makefile -u -r1.3 -r1.4 --- www/moinmoin/Makefile +++ www/moinmoin/Makefile @@ -7,7 +7,7 @@ # PORTNAME= moinmoin -PORTVERSION= 1.7.1 +PORTVERSION= 1.7.3 CATEGORIES= www python MASTER_SITES= http://static.moinmo.in/files/ DISTNAME= moin-${PORTVERSION} Index: distinfo =================================================================== RCS file: /home/cvs/mports/www/moinmoin/distinfo,v retrieving revision 1.3 retrieving revision 1.4 diff -L www/moinmoin/distinfo -L www/moinmoin/distinfo -u -r1.3 -r1.4 --- www/moinmoin/distinfo +++ www/moinmoin/distinfo @@ -1,3 +1,3 @@ -MD5 (moin-1.7.1.tar.gz) = 871337b8171c91f9a6803e5376857e8d -SHA256 (moin-1.7.1.tar.gz) = f2818bf700257c240962a4861b4cb1bc200ee51aa7390f90fdd345db8e8d79d7 -SIZE (moin-1.7.1.tar.gz) = 5468224 +MD5 (moin-1.7.3.tar.gz) = 871e2b0f7f449eb280e39799d94c152d +SHA256 (moin-1.7.3.tar.gz) = 96dee7627eabcd9738ae3ff0e7ab2305ce940b5c616b7360da550d9d0fdbc580 +SIZE (moin-1.7.3.tar.gz) = 5519733 From laffer1 at midnightbsd.org Mon Jan 12 21:52:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 21:52:38 -0500 (EST) Subject: [Midnightbsd-cvs] mports: mail/linux-thunderbird: 2.0.0.19 Message-ID: <200901130252.n0D2qcFK066736@stargazer.midnightbsd.org> Log Message: ----------- 2.0.0.19 Modified Files: -------------- mports/mail/linux-thunderbird: Makefile (r1.17 -> r1.18) distinfo (r1.14 -> r1.15) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/mail/linux-thunderbird/Makefile,v retrieving revision 1.17 retrieving revision 1.18 diff -L mail/linux-thunderbird/Makefile -L mail/linux-thunderbird/Makefile -u -r1.17 -r1.18 --- mail/linux-thunderbird/Makefile +++ mail/linux-thunderbird/Makefile @@ -7,7 +7,7 @@ # PORTNAME= thunderbird -PORTVERSION= 2.0.0.18 +PORTVERSION= 2.0.0.19 CATEGORIES= mail MASTER_SITE_SUBDIR?= ${PORTNAME}/releases/${PORTVERSION}/linux-i686/en-US Index: distinfo =================================================================== RCS file: /home/cvs/mports/mail/linux-thunderbird/distinfo,v retrieving revision 1.14 retrieving revision 1.15 diff -L mail/linux-thunderbird/distinfo -L mail/linux-thunderbird/distinfo -u -r1.14 -r1.15 --- mail/linux-thunderbird/distinfo +++ mail/linux-thunderbird/distinfo @@ -1,3 +1,3 @@ -MD5 (thunderbird-2.0.0.18.tar.gz) = dfa9df28bcfab6306998f6cfc9e6f077 -SHA256 (thunderbird-2.0.0.18.tar.gz) = 9ad998b83481e04781b2f80c737a58cdf919e3cda6974afb3105044e4220dc86 -SIZE (thunderbird-2.0.0.18.tar.gz) = 11482752 +MD5 (thunderbird-2.0.0.19.tar.gz) = 3f09642db3493d38ddde83470ce8d422 +SHA256 (thunderbird-2.0.0.19.tar.gz) = fbb9f4394c03d0c0054baeebb047420f2240eb1a5cf8a8f5cc9cd7b57bdb2e9a +SIZE (thunderbird-2.0.0.19.tar.gz) = 11484804 From laffer1 at midnightbsd.org Tue Jan 13 02:22:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 13 Jan 2009 02:22:19 -0500 (EST) Subject: [Midnightbsd-cvs] mports: databases/mysql51-server: update ot mysql 5.1.30 Message-ID: <200901130722.n0D7MJch092306@stargazer.midnightbsd.org> Log Message: ----------- update ot mysql 5.1.30 Modified Files: -------------- mports/databases/mysql51-server: Makefile (r1.11 -> r1.12) distinfo (r1.7 -> r1.8) mports/databases/mysql51-server/files: mysql-server.sh.in (r1.3 -> r1.4) patch-extra_yassl_Makefile.in (r1.2 -> r1.3) patch-extra_yassl_taocrypt_Makefile.in (r1.2 -> r1.3) patch-mysys_default.c (r1.4 -> r1.5) Removed Files: ------------- mports/databases/mysql51-server/files: patch-client_mysql_upgrade.c -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/Makefile,v retrieving revision 1.11 retrieving revision 1.12 diff -L databases/mysql51-server/Makefile -L databases/mysql51-server/Makefile -u -r1.11 -r1.12 --- databases/mysql51-server/Makefile +++ databases/mysql51-server/Makefile @@ -7,13 +7,13 @@ # PORTNAME?= mysql -PORTVERSION= 5.1.26 +PORTVERSION= 5.1.30 PORTREVISION= 0 CATEGORIES= databases MASTER_SITES= ${MASTER_SITE_MYSQL} MASTER_SITE_SUBDIR= MySQL-5.1 PKGNAMESUFFIX?= -server -DISTNAME= ${PORTNAME}-${PORTVERSION}-rc +DISTNAME= ${PORTNAME}-${PORTVERSION} MAINTAINER= ports at MidnightBSD.org COMMENT= Multithreaded SQL database (server) Index: distinfo =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/distinfo,v retrieving revision 1.7 retrieving revision 1.8 diff -L databases/mysql51-server/distinfo -L databases/mysql51-server/distinfo -u -r1.7 -r1.8 --- databases/mysql51-server/distinfo +++ databases/mysql51-server/distinfo @@ -1,3 +1,3 @@ -MD5 (mysql-5.1.26-rc.tar.gz) = db4b30ef40493e0bfe9ca17dd8220cf5 -SHA256 (mysql-5.1.26-rc.tar.gz) = 3a782d85b1aa5b2a47e67e80021e022c06c9d429f8afbc6cde1333d0bcb97dc6 -SIZE (mysql-5.1.26-rc.tar.gz) = 28111441 +MD5 (mysql-5.1.30.tar.gz) = b658e58887a74dce65224ae0fc8ee06a +SHA256 (mysql-5.1.30.tar.gz) = cca90f5209808829e5bc811c5c017a054a4f75188e939b1c1c8b270d0514f624 +SIZE (mysql-5.1.30.tar.gz) = 29050568 Index: patch-extra_yassl_Makefile.in =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/patch-extra_yassl_Makefile.in,v retrieving revision 1.2 retrieving revision 1.3 diff -L databases/mysql51-server/files/patch-extra_yassl_Makefile.in -L databases/mysql51-server/files/patch-extra_yassl_Makefile.in -u -r1.2 -r1.3 --- databases/mysql51-server/files/patch-extra_yassl_Makefile.in +++ databases/mysql51-server/files/patch-extra_yassl_Makefile.in @@ -1,11 +1,11 @@ ---- extra/yassl/Makefile.in.orig Thu Oct 26 14:02:58 2006 -+++ extra/yassl/Makefile.in Tue Nov 7 08:17:34 2006 -@@ -351,7 +351,7 @@ +--- extra/yassl/Makefile.in.orig 2008-10-11 23:58:20.000000000 +0200 ++++ extra/yassl/Makefile.in 2008-10-31 08:14:13.000000000 +0100 +@@ -355,7 +355,7 @@ yassl_libs = @yassl_libs@ yassl_taocrypt_extra_cxxflags = @yassl_taocrypt_extra_cxxflags@ zlib_dir = @zlib_dir@ -SUBDIRS = taocrypt src testsuite +SUBDIRS = taocrypt src - EXTRA_DIST = yassl.dsp yassl.dsw yassl.vcproj \ - CMakeLists.txt + EXTRA_DIST = CMakeLists.txt + all: all-recursive Index: patch-mysys_default.c =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/patch-mysys_default.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L databases/mysql51-server/files/patch-mysys_default.c -L databases/mysql51-server/files/patch-mysys_default.c -u -r1.4 -r1.5 --- databases/mysql51-server/files/patch-mysys_default.c +++ databases/mysql51-server/files/patch-mysys_default.c @@ -1,6 +1,6 @@ ---- mysys/default.c.orig 2008-04-08 13:23:13.000000000 +0200 -+++ mysys/default.c 2008-04-21 19:20:44.000000000 +0200 -@@ -623,7 +623,7 @@ +--- mysys/default.c.orig 2008-08-28 17:40:47.000000000 +0200 ++++ mysys/default.c 2008-09-16 08:20:23.000000000 +0200 +@@ -638,7 +638,7 @@ { MY_STAT stat_info; if (!my_stat(name,&stat_info,MYF(0))) @@ -9,11 +9,14 @@ /* Ignore world-writable regular files. This is mainly done to protect us to not read a file created by -@@ -1105,6 +1105,7 @@ - #ifdef DEFAULT_SYSCONFDIR +@@ -1091,7 +1091,10 @@ + + #if defined(DEFAULT_SYSCONFDIR) if (DEFAULT_SYSCONFDIR != "") - ADD_DIRECTORY(DEFAULT_SYSCONFDIR); -+ ADD_DIRECTORY(DEFAULT_SYSCONFDIR "/mysql/"); ++ { + errors += add_directory(alloc, DEFAULT_SYSCONFDIR, dirs); ++ errors += add_directory(alloc, DEFAULT_SYSCONFDIR "/mysql", dirs); ++ } + #endif /* DEFAULT_SYSCONFDIR */ + #endif - ADD_COMMON_DIRECTORIES(); - ADD_DIRECTORY("~/"); Index: mysql-server.sh.in =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/mysql-server.sh.in,v retrieving revision 1.3 retrieving revision 1.4 diff -L databases/mysql51-server/files/mysql-server.sh.in -L databases/mysql51-server/files/mysql-server.sh.in -u -r1.3 -r1.4 --- databases/mysql51-server/files/mysql-server.sh.in +++ databases/mysql51-server/files/mysql-server.sh.in @@ -1,8 +1,6 @@ #!/bin/sh # # $MidnightBSD$ -# $FreeBSD: ports/databases/mysql51-server/files/mysql-server.sh.in,v 1.4 2007/05/20 08:31:37 ale Exp $ -# # PROVIDE: mysql # REQUIRE: LOGIN @@ -37,9 +35,10 @@ mysql_limits_args="-e -U ${mysql_user}" pidfile="${mysql_dbdir}/`/bin/hostname`.pid" command="%%PREFIX%%/bin/mysqld_safe" -command_args="--defaults-extra-file=${mysql_dbdir}/my.cnf --user=${mysql_user} --datadir=${mysql_dbdir} --pid-file=${pidfile} ${mysql_args} > /dev/null &" +command_args="--defaults-extra-file=${mysql_dbdir}/my.cnf --user=${mysql_user} --datadir=${mysql_dbdir} --pid-file=${pidfile} ${mysql_args} > /dev/null 2>&1 &" procname="%%PREFIX%%/libexec/mysqld" start_precmd="${name}_prestart" +start_postcmd="${name}_poststart" mysql_install_db="%%PREFIX%%/bin/mysql_install_db" mysql_install_db_args="--ldata=${mysql_dbdir}" @@ -61,4 +60,14 @@ fi } +mysql_poststart() +{ + local timeout=15 + while [ ! -f "${pidfile}" -a ${timeout} -gt 0 ]; do + timeout=$(( timeout - 1 )) + sleep 1 + done + return 0 +} + run_rc_command "$1" Index: patch-extra_yassl_taocrypt_Makefile.in =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in,v retrieving revision 1.2 retrieving revision 1.3 diff -L databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in -L databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in -u -r1.2 -r1.3 --- databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in +++ databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in @@ -1,11 +1,11 @@ ---- extra/yassl/taocrypt/Makefile.in.orig Thu Oct 26 14:02:59 2006 -+++ extra/yassl/taocrypt/Makefile.in Tue Nov 7 08:18:38 2006 -@@ -351,7 +351,7 @@ +--- extra/yassl/taocrypt/Makefile.in.orig 2008-10-11 23:58:20.000000000 +0200 ++++ extra/yassl/taocrypt/Makefile.in 2008-10-31 08:15:56.000000000 +0100 +@@ -355,7 +355,7 @@ yassl_libs = @yassl_libs@ yassl_taocrypt_extra_cxxflags = @yassl_taocrypt_extra_cxxflags@ zlib_dir = @zlib_dir@ -SUBDIRS = src test benchmark +SUBDIRS = src - EXTRA_DIST = taocrypt.dsw taocrypt.dsp taocrypt.vcproj CMakeLists.txt $(wildcard mySTL/*.hpp) + EXTRA_DIST = CMakeLists.txt $(wildcard mySTL/*.hpp) all: all-recursive --- databases/mysql51-server/files/patch-client_mysql_upgrade.c +++ /dev/null @@ -1,13 +0,0 @@ ---- client/mysql_upgrade.c.orig 2008-01-29 22:42:00.000000000 +0100 -+++ client/mysql_upgrade.c 2008-02-14 08:29:52.000000000 +0100 -@@ -427,10 +427,6 @@ - - verbose("Looking for '%s' in: %s", tool_name, tool_path); - -- /* Make sure the tool exists */ -- if (my_access(tool_path, F_OK) != 0) -- die("Can't find '%s'", tool_path); -- - /* - Make sure it can be executed - */ From laffer1 at midnightbsd.org Tue Jan 13 02:22:34 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 13 Jan 2009 02:22:34 -0500 (EST) Subject: [Midnightbsd-cvs] mports: patch-client_mysql.cc: Message-ID: <200901130722.n0D7MYTK092361@stargazer.midnightbsd.org> Log Message: ----------- Added Files: ----------- mports/databases/mysql51-server/files: patch-client_mysql.cc (r1.1) -------------- next part -------------- --- /dev/null +++ databases/mysql51-server/files/patch-client_mysql.cc @@ -0,0 +1,27 @@ +--- client/mysql.cc.orig 2007-11-13 13:29:42 +0000 ++++ client/mysql.cc 2008-05-01 19:16:09 +0000 +@@ -2636,9 +2636,12 @@ + { + while((field = mysql_fetch_field(result))) + { +- tee_fprintf(PAGER, "%s", (field->name ? +- (field->name[0] ? field->name : +- "   ") : "NULL")); ++ tee_fputs("", PAGER); ++ if (field->name && field->name[0]) ++ xmlencode_print(field->name, field->name_length); ++ else ++ tee_fputs(field->name ? "   " : "NULL", PAGER); ++ tee_fputs("", PAGER); + } + (void) tee_fputs("", PAGER); + } +@@ -2651,7 +2654,7 @@ + for (uint i=0; i < mysql_num_fields(result); i++) + { + (void) tee_fputs("", PAGER); +- safe_put_field(cur[i],lengths[i]); ++ xmlencode_print(cur[i], lengths[i]); + (void) tee_fputs("", PAGER); + } + (void) tee_fputs("", PAGER); From laffer1 at midnightbsd.org Thu Jan 15 11:16:49 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 11:16:49 -0500 (EST) Subject: [Midnightbsd-cvs] src: /src: MidnightBSD 0.2.1-p6: Bind security update Message-ID: <200901151616.n0FGGnoD028092@stargazer.midnightbsd.org> Log Message: ----------- MidnightBSD 0.2.1-p6: Bind security update Tags: ---- RELENG_0_2 Modified Files: -------------- src: UPDATING (r1.38.2.14 -> r1.38.2.15) src/sys/conf: newvers.sh (r1.3.2.8 -> r1.3.2.9) src/contrib/bind9/lib/dns: openssldsa_link.c (r1.1.1.4 -> r1.1.1.4.2.1) opensslrsa_link.c (r1.1.1.4 -> r1.1.1.4.2.1) -------------- next part -------------- Index: newvers.sh =================================================================== RCS file: /home/cvs/src/sys/conf/newvers.sh,v retrieving revision 1.3.2.8 retrieving revision 1.3.2.9 diff -L sys/conf/newvers.sh -L sys/conf/newvers.sh -u -r1.3.2.8 -r1.3.2.9 --- sys/conf/newvers.sh +++ sys/conf/newvers.sh @@ -33,7 +33,7 @@ TYPE="MidnightBSD" REVISION="0.2.1" -BRANCH="RELEASE-p5" +BRANCH="RELEASE-p6" if [ "X${BRANCH_OVERRIDE}" != "X" ]; then BRANCH=${BRANCH_OVERRIDE} fi Index: UPDATING =================================================================== RCS file: /home/cvs/src/UPDATING,v retrieving revision 1.38.2.14 retrieving revision 1.38.2.15 diff -L UPDATING -L UPDATING -u -r1.38.2.14 -r1.38.2.15 --- UPDATING +++ UPDATING @@ -3,6 +3,12 @@ Items affecting the mports and packages system can be found in /usr/mports/UPDATING. +20090115: + MidnightBSD 0.2.1-RELEASE-p6 + + Correct an issue with BIND that allows for DNSSEC spoofing + attacks. + 20090110: MidnightBSD 0.2.1-RELEASE-p5 Index: opensslrsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/opensslrsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.1.1.4.2.1 diff -L contrib/bind9/lib/dns/opensslrsa_link.c -L contrib/bind9/lib/dns/opensslrsa_link.c -u -r1.1.1.4 -r1.1.1.4.2.1 --- contrib/bind9/lib/dns/opensslrsa_link.c +++ contrib/bind9/lib/dns/opensslrsa_link.c @@ -246,7 +246,7 @@ status = RSA_verify(type, digest, digestlen, sig->base, RSA_size(rsa), rsa); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); Index: openssldsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/openssldsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.1.1.4.2.1 diff -L contrib/bind9/lib/dns/openssldsa_link.c -L contrib/bind9/lib/dns/openssldsa_link.c -u -r1.1.1.4 -r1.1.1.4.2.1 --- contrib/bind9/lib/dns/openssldsa_link.c +++ contrib/bind9/lib/dns/openssldsa_link.c @@ -133,7 +133,7 @@ status = DSA_do_verify(digest, ISC_SHA1_DIGESTLENGTH, dsasig, dsa); DSA_SIG_free(dsasig); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); From laffer1 at midnightbsd.org Thu Jan 15 11:20:39 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 11:20:39 -0500 (EST) Subject: [Midnightbsd-cvs] src: lib/dns: bind security update with DNSSEC Message-ID: <200901151620.n0FGKckY028481@stargazer.midnightbsd.org> Log Message: ----------- bind security update with DNSSEC Modified Files: -------------- src/contrib/bind9/lib/dns: openssldsa_link.c (r1.1.1.4 -> r1.2) opensslrsa_link.c (r1.1.1.4 -> r1.2) -------------- next part -------------- Index: opensslrsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/opensslrsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.2 diff -L contrib/bind9/lib/dns/opensslrsa_link.c -L contrib/bind9/lib/dns/opensslrsa_link.c -u -r1.1.1.4 -r1.2 --- contrib/bind9/lib/dns/opensslrsa_link.c +++ contrib/bind9/lib/dns/opensslrsa_link.c @@ -246,7 +246,7 @@ status = RSA_verify(type, digest, digestlen, sig->base, RSA_size(rsa), rsa); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); Index: openssldsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/openssldsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.2 diff -L contrib/bind9/lib/dns/openssldsa_link.c -L contrib/bind9/lib/dns/openssldsa_link.c -u -r1.1.1.4 -r1.2 --- contrib/bind9/lib/dns/openssldsa_link.c +++ contrib/bind9/lib/dns/openssldsa_link.c @@ -133,7 +133,7 @@ status = DSA_do_verify(digest, ISC_SHA1_DIGESTLENGTH, dsasig, dsa); DSA_SIG_free(dsasig); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); From laffer1 at midnightbsd.org Thu Jan 15 14:35:09 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 14:35:09 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: bind sec update Message-ID: <200901151935.n0FJZ9G6045359@stargazer.midnightbsd.org> Log Message: ----------- bind sec update Modified Files: -------------- www/security: index.html (r1.13 -> r1.14) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/security/index.html,v retrieving revision 1.13 retrieving revision 1.14 diff -L security/index.html -L security/index.html -u -r1.13 -r1.14 --- security/index.html +++ security/index.html @@ -17,6 +17,11 @@

Security Updates

+
+

January 15, 2009

+

Prevent a DNSSEC attack with BIND. This was corrected in 0.2.1 and 0.3-CURRENT. 0.1.x is no longer receiving security patches. It + is recommended that you upgrade to 0.2.1-RELEASE when possible.

+

January 10, 2009

Fix two issues with MidnightBSD 0.2.1 and 0.3-CURRENT. The first is in OpenSSL and would allow applications that use OpenSSL to interpret an From laffer1 at midnightbsd.org Thu Jan 15 14:38:51 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 14:38:51 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: add sec updates Message-ID: <200901151938.n0FJcpBO045543@stargazer.midnightbsd.org> Log Message: ----------- add sec updates Modified Files: -------------- www: index.html (r1.64 -> r1.65) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/index.html,v retrieving revision 1.64 retrieving revision 1.65 diff -L index.html -L index.html -u -r1.64 -r1.65 --- index.html +++ index.html @@ -63,14 +63,15 @@

Security »

-

December 31, 2008

-

Correct a problem where bluetooth and netgraph sockets...

-

Read more...

+

January 15, 2009

+

Prevent a DNSSEC attack with BIND. This was corrected in 0.2.1 and 0.3... +

+

Read more...

-

November 24, 2008

-

Correct a problem in arc4random which causes the device...

-

Read more...

+

January 10, 2009

+

Fix two issues with MidnightBSD 0.2.1 and 0.3-CURRENT. The first is in OpenSSL...

+

Read more...

From laffer1 at midnightbsd.org Thu Jan 15 18:20:54 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 18:20:54 -0500 (EST) Subject: [Midnightbsd-cvs] src: usr.sbin/boot0cfg: fix man page and add directions to go back to Message-ID: <200901152320.n0FNKs8R066717@stargazer.midnightbsd.org> Log Message: ----------- fix man page and add directions to go back to standard boot Modified Files: -------------- src/usr.sbin/boot0cfg: Makefile (r1.1.1.1 -> r1.2) boot0cfg.8 (r1.1.1.1 -> r1.2) boot0cfg.c (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: boot0cfg.c =================================================================== RCS file: /home/cvs/src/usr.sbin/boot0cfg/boot0cfg.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L usr.sbin/boot0cfg/boot0cfg.c -L usr.sbin/boot0cfg/boot0cfg.c -u -r1.1.1.1 -r1.2 --- usr.sbin/boot0cfg/boot0cfg.c +++ usr.sbin/boot0cfg/boot0cfg.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.c,v 1.19.2.1 2005/08/16 22:45:33 phk Exp $"); +__FBSDID("$FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.c,v 1.20 2005/07/15 08:04:32 phk Exp $"); #include #include Index: boot0cfg.8 =================================================================== RCS file: /home/cvs/src/usr.sbin/boot0cfg/boot0cfg.8,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L usr.sbin/boot0cfg/boot0cfg.8 -L usr.sbin/boot0cfg/boot0cfg.8 -u -r1.1.1.1 -r1.2 --- usr.sbin/boot0cfg/boot0cfg.8 +++ usr.sbin/boot0cfg/boot0cfg.8 @@ -22,9 +22,9 @@ .\" OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, .\" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.8,v 1.29 2005/04/07 20:04:55 scottl Exp $ +.\" $FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.8,v 1.32 2007/06/07 07:43:04 pav Exp $ .\" -.Dd February 21, 1999 +.Dd June 7, 2007 .Dt BOOT0CFG 8 .Os .Sh NAME @@ -43,7 +43,7 @@ .Ar disk .Sh DESCRIPTION The -.Fx +.Mx .Sq boot0 boot manager permits the operator to select from which disk and slice an i386 machine (PC) is booted. @@ -163,6 +163,13 @@ To enable just slices 1 and 2 in the menu: .Pp .Dl "boot0cfg -m 0x3 ad0" +.Pp +To go back to non-interactive booting, use +.Xr fdisk 8 +to install the default MBR: +.Pp +.Dl "fdisk -B ad0" +.Pp .Sh SEE ALSO .Xr geom 4 , .Xr boot 8 , Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.sbin/boot0cfg/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L usr.sbin/boot0cfg/Makefile -L usr.sbin/boot0cfg/Makefile -u -r1.1.1.1 -r1.2 --- usr.sbin/boot0cfg/Makefile +++ usr.sbin/boot0cfg/Makefile @@ -1,4 +1,4 @@ -# $FreeBSD: src/usr.sbin/boot0cfg/Makefile,v 1.8.12.1 2005/08/16 22:45:33 phk Exp $ +# $FreeBSD: src/usr.sbin/boot0cfg/Makefile,v 1.9 2005/07/15 08:04:32 phk Exp $ PROG= boot0cfg MAN= boot0cfg.8 From laffer1 at midnightbsd.org Thu Jan 15 23:21:33 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:21:33 -0500 (EST) Subject: [Midnightbsd-cvs] src: UPDATING: DNSSEC bind update. Message-ID: <200901160421.n0G4LXMi095273@stargazer.midnightbsd.org> Log Message: ----------- DNSSEC bind update. Modified Files: -------------- src: UPDATING (r1.50 -> r1.51) -------------- next part -------------- Index: UPDATING =================================================================== RCS file: /home/cvs/src/UPDATING,v retrieving revision 1.50 retrieving revision 1.51 diff -L UPDATING -L UPDATING -u -r1.50 -r1.51 --- UPDATING +++ UPDATING @@ -3,7 +3,10 @@ Items affecting the mports and packages system can be found in /usr/mports/UPDATING. -20080110: +20090115: + Fix a problem with DNSSEC and BIND. + +20090110: For applications using OpenSSL for SSL connections, an invalid SSL certificate may be interpreted as valid. This could for example be used by an attacker to perform a man-in-the-middle attack. @@ -13,10 +16,10 @@ Stop cross site request forgery attacks in lukemftpd -20080104: +20090104: Import GNU libreadline 5.2 -20080101: +20090101: Update time zone data to 2008i. 20081231: From laffer1 at midnightbsd.org Thu Jan 15 23:26:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:26:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: install-iso2img.sh: Make some needed changes. Message-ID: <200901160426.n0G4QVT2095746@stargazer.midnightbsd.org> Log Message: ----------- Make some needed changes. Switch to pax. Modified Files: -------------- src/nrelease: install-iso2img.sh (r1.2 -> r1.3) -------------- next part -------------- Index: install-iso2img.sh =================================================================== RCS file: /home/cvs/src/nrelease/install-iso2img.sh,v retrieving revision 1.2 retrieving revision 1.3 diff -L nrelease/install-iso2img.sh -L nrelease/install-iso2img.sh -u -r1.2 -r1.3 --- nrelease/install-iso2img.sh +++ nrelease/install-iso2img.sh @@ -1,7 +1,5 @@ #!/bin/sh # beerware license, written by Dario Freni (saturnero at freesbie.org) -# -# You can set some variables here. Edit them to fit your needs. # Set serial variable to 0 if you don't want serial console at all, # 1 if you want comconsole and 2 if you want comconsole and vidconsole @@ -41,9 +39,7 @@ mount /dev/${imgdev}a ${tmpdir}/img echo "Copying files to the image..." -( cd ${tmpdir}/iso && find . -print -depth | gcpio -dump ${tmpdir}/img ) -#bzcat ${tmpdir}/iso/dist/root.dist.bz2 | mtree -PUr -p ${tmpdir}/img 2>&= -#1 > /dev/null +( cd ${tmpdir}/iso && pax -rw . ${tmpdir}/img ) #echo "/dev/ufs/${UFS_LABEL} / ufs ro 1 1" > ${tmpdir}/img/etc/fstab From laffer1 at midnightbsd.org Thu Jan 15 23:40:21 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:40:21 -0500 (EST) Subject: [Midnightbsd-cvs] src: pf_table.c: MidnightBSDize Message-ID: <200901160440.n0G4eLVW097094@stargazer.midnightbsd.org> Log Message: ----------- MidnightBSDize Modified Files: -------------- src/sys/contrib/pf/net: pf_table.c (r1.2 -> r1.3) -------------- next part -------------- Index: pf_table.c =================================================================== RCS file: /home/cvs/src/sys/contrib/pf/net/pf_table.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/contrib/pf/net/pf_table.c -L sys/contrib/pf/net/pf_table.c -u -r1.2 -r1.3 --- sys/contrib/pf/net/pf_table.c +++ sys/contrib/pf/net/pf_table.c @@ -30,7 +30,7 @@ * */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #include "opt_inet.h" #include "opt_inet6.h" @@ -43,7 +43,7 @@ #include #include #include -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #include #endif @@ -51,8 +51,10 @@ #include #include #ifndef __FreeBSD__ +#ifndef __MidnightBSD__ #include #endif +#endif #include @@ -63,7 +65,7 @@ return (EINVAL); \ } while (0) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) static inline int _copyin(const void *uaddr, void *kaddr, size_t len) { @@ -176,7 +178,7 @@ #define senderr(e) do { rv = (e); goto _bad; } while (0) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) uma_zone_t pfr_ktable_pl; uma_zone_t pfr_kentry_pl; uma_zone_t pfr_kentry_pl2; @@ -248,6 +250,7 @@ pfr_initialize(void) { #ifndef __FreeBSD__ +#ifndef __MidnightBSD__ pool_init(&pfr_ktable_pl, sizeof(struct pfr_ktable), 0, 0, 0, "pfrktable", &pool_allocator_oldnointr); pool_init(&pfr_kentry_pl, sizeof(struct pfr_kentry), 0, 0, 0, @@ -255,6 +258,7 @@ pool_init(&pfr_kentry_pl2, sizeof(struct pfr_kentry), 0, 0, 0, "pfrkentry2", NULL); #endif +#endif pfr_sin.sin_len = sizeof(pfr_sin); pfr_sin.sin_family = AF_INET; @@ -641,13 +645,13 @@ w.pfrw_addr = addr; w.pfrw_free = kt->pfrkt_cnt; w.pfrw_flags = flags; -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rv = rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #endif if (!rv) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else @@ -693,13 +697,13 @@ w.pfrw_flags = flags; if (flags & PFR_FLAG_ATOMIC) s = splsoftnet(); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rv = rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #endif if (!rv) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else @@ -819,7 +823,7 @@ w.pfrw_op = sweep ? PFRW_SWEEP : PFRW_ENQUEUE; w.pfrw_workq = workq; if (kt->pfrkt_ip4 != NULL) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w)) #else @@ -827,7 +831,7 @@ #endif printf("pfr_enqueue_addrs: IPv4 walktree failed.\n"); if (kt->pfrkt_ip6 != NULL) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w)) #else @@ -845,13 +849,13 @@ bzero(&w, sizeof(w)); w.pfrw_op = PFRW_MARK; -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w)) #else if (rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w)) #endif printf("pfr_mark_addrs: IPv4 walktree failed.\n"); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w)) #else if (rn_walktree(kt->pfrkt_ip6, pfr_walktree, &w)) @@ -879,7 +883,7 @@ if (ADDR_NETWORK(ad)) { pfr_prepare_network(&mask, ad->pfra_af, ad->pfra_net); s = splsoftnet(); /* rn_lookup makes use of globals */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) PF_ASSERT(MA_OWNED); #endif ke = (struct pfr_kentry *)rn_lookup(&sa, &mask, head); @@ -1080,7 +1084,7 @@ head = kt->pfrkt_ip6; s = splsoftnet(); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) PF_ASSERT(MA_OWNED); #endif if (KENTRY_NETWORK(ke)) { @@ -1107,18 +1111,18 @@ head = kt->pfrkt_ip6; s = splsoftnet(); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) PF_ASSERT(MA_OWNED); #endif if (KENTRY_NETWORK(ke)) { pfr_prepare_network(&mask, ke->pfrke_af, ke->pfrke_net); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rn = rn_delete(&ke->pfrke_sa, &mask, head); #else rn = rn_delete(&ke->pfrke_sa, &mask, head, NULL); #endif } else -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rn = rn_delete(&ke->pfrke_sa, NULL, head); #else rn = rn_delete(&ke->pfrke_sa, NULL, head, NULL); @@ -2044,7 +2048,7 @@ pfr_clean_node_mask(kt, &addrq); pfr_destroy_kentries(&addrq); } -#if defined(__FreeBSD__) && (__FreeBSD_version >= 500100) +#if defined(__MidnightBSD__) || (defined(__FreeBSD__) && (__FreeBSD_version >= 500100)) if (kt->pfrkt_ip4 != NULL) { RADIX_NODE_HEAD_DESTROY(kt->pfrkt_ip4); free((caddr_t)kt->pfrkt_ip4, M_RTABLE); @@ -2309,7 +2313,7 @@ switch (af) { #ifdef INET case AF_INET: -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); @@ -2318,7 +2322,7 @@ #endif /* INET */ #ifdef INET6 case AF_INET6: -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip6, pfr_walktree, &w); @@ -2344,13 +2348,13 @@ dyn->pfid_acnt4 = 0; dyn->pfid_acnt6 = 0; if (!dyn->pfid_af || dyn->pfid_af == AF_INET) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #endif if (!dyn->pfid_af || dyn->pfid_af == AF_INET6) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip6, pfr_walktree, &w); From laffer1 at midnightbsd.org Thu Jan 15 23:43:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:43:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: pf_osfp.c: midnightbsdize Message-ID: <200901160443.n0G4htet097284@stargazer.midnightbsd.org> Log Message: ----------- midnightbsdize Modified Files: -------------- src/sys/contrib/pf/net: pf_osfp.c (r1.2 -> r1.3) -------------- next part -------------- Index: pf_osfp.c =================================================================== RCS file: /home/cvs/src/sys/contrib/pf/net/pf_osfp.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/contrib/pf/net/pf_osfp.c -L sys/contrib/pf/net/pf_osfp.c -u -r1.2 -r1.3 --- sys/contrib/pf/net/pf_osfp.c +++ sys/contrib/pf/net/pf_osfp.c @@ -17,7 +17,7 @@ * */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #include __FBSDID("$FreeBSD: src/sys/contrib/pf/net/pf_osfp.c,v 1.6 2007/07/03 12:16:07 mlaier Exp $"); #endif @@ -46,7 +46,7 @@ # define DPFPRINTF(format, x...) \ if (pf_status.debug >= PF_DEBUG_NOISY) \ printf(format , ##x) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) typedef uma_zone_t pool_t; #else typedef struct pool pool_t; @@ -66,7 +66,7 @@ # define pool_put(pool, item) free(item) # define pool_init(pool, size, a, ao, f, m, p) (*(pool)) = (size) -# ifdef __FreeBSD__ +# if defined(__FreeBSD__) || defined(__MidnightBSD__) # define NTOHS(x) (x) = ntohs((u_int16_t)(x)) # endif @@ -301,14 +301,14 @@ } /* Initialize the OS fingerprint system */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) int #else void #endif pf_osfp_initialize(void) { -#if defined(__FreeBSD__) && defined(_KERNEL) +#if (defined(__MidnightBSD__) || defined(__FreeBSD__)) && defined(_KERNEL) int error = ENOMEM; do { @@ -324,7 +324,7 @@ "pfosfp", &pool_allocator_nointr); #endif SLIST_INIT(&pf_osfp_list); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #ifdef _KERNEL return (error); #else @@ -333,7 +333,7 @@ #endif } -#if defined(__FreeBSD__) && (_KERNEL) +#if (defined(__MidnightBSD__) || defined(__FreeBSD__)) && (_KERNEL) void pf_osfp_cleanup(void) { From laffer1 at midnightbsd.org Thu Jan 15 23:49:24 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:49:24 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Update for newer pf Message-ID: <200901160449.n0G4nOfm097867@stargazer.midnightbsd.org> Log Message: ----------- Update for newer pf Modified Files: -------------- src/sys/modules/pf: Makefile (r1.2 -> r1.3) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/pf/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/modules/pf/Makefile -L sys/modules/pf/Makefile -u -r1.2 -r1.3 --- sys/modules/pf/Makefile +++ sys/modules/pf/Makefile @@ -1,12 +1,16 @@ -# $FreeBSD: src/sys/modules/pf/Makefile,v 1.7.2.2 2006/03/22 15:56:32 yar Exp $ +# $MidnightBSD$ +# $FreeBSD: src/sys/modules/pf/Makefile,v 1.13 2007/07/03 12:46:06 mlaier Exp $ + +.include .PATH: ${.CURDIR}/../../contrib/pf/net .PATH: ${.CURDIR}/../../contrib/pf/netinet KMOD= pf SRCS = pf.c pf_if.c pf_subr.c pf_osfp.c pf_ioctl.c pf_norm.c pf_table.c \ + pf_ruleset.c \ in4_cksum.c \ - opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h + opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h opt_mac.h CFLAGS+= -I${.CURDIR}/../../contrib/pf @@ -14,13 +18,18 @@ opt_inet.h: echo "#define INET 1" > opt_inet.h -.if !defined(NO_INET6) +.if ${MK_INET6_SUPPORT} != "no" opt_inet6.h: echo "#define INET6 1" > opt_inet6.h .endif opt_bpf.h: echo "#define DEV_BPF 1" > opt_bpf.h + +# pflog can be loaded as a module, have the additional checks turned on +opt_pf.h: + echo "#define DEV_PF 1" > opt_pf.h + echo "#define DEF_PFLOG 1" >> opt_pf.h .endif .include From laffer1 at midnightbsd.org Fri Jan 16 21:49:13 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Fri, 16 Jan 2009 21:49:13 -0500 (EST) Subject: [Midnightbsd-cvs] src: make.conf: Document mport maintainer mode. Message-ID: <200901170249.n0H2nDmB027971@stargazer.midnightbsd.org> Log Message: ----------- Document mport maintainer mode. Modified Files: -------------- src/share/examples/etc: make.conf (r1.4 -> r1.5) -------------- next part -------------- Index: make.conf =================================================================== RCS file: /home/cvs/src/share/examples/etc/make.conf,v retrieving revision 1.4 retrieving revision 1.5 diff -L share/examples/etc/make.conf -L share/examples/etc/make.conf -u -r1.4 -r1.5 --- share/examples/etc/make.conf +++ share/examples/etc/make.conf @@ -244,6 +244,11 @@ #SUPFILE= /usr/share/examples/cvsup/standard-supfile #PORTSSUPFILE= /usr/share/examples/cvsup/mports-supfile # +# +# mports developers may want to use mport maintainer mode to +# catch problems with plists +#MPORT_MAINTAINER_MODE=yes +# # top(1) uses a hash table for the user names. The size of this hash # can be tuned to match the number of local users. The table size should # be a prime number approximately twice as large as the number of lines in From laffer1 at midnightbsd.org Sat Jan 17 11:25:06 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 11:25:06 -0500 (EST) Subject: [Midnightbsd-cvs] src: network.subr: Emit a warning when the network_interfaces variable Message-ID: <200901171625.n0HGP6j3027336@stargazer.midnightbsd.org> Log Message: ----------- Emit a warning when the network_interfaces variable is not set to AUTO and change wpa_supplicant to down the interface at the start of the init routine. wpa_supplicant expects that it has exclusive access to the net80211 state. This stops errors trying to scan when it's already scanning causing a problem connecting. This was an issue for firmware based cards in particular. Do not bother ifconfig up(ing) the interface since it is downed again Modified Files: -------------- src/etc: network.subr (r1.2 -> r1.3) -------------- next part -------------- Index: network.subr =================================================================== RCS file: /home/cvs/src/etc/network.subr,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/network.subr -L etc/network.subr -u -r1.2 -r1.3 --- etc/network.subr +++ etc/network.subr @@ -23,7 +23,7 @@ # SUCH DAMAGE. # # $MidnightBSD$ -# $FreeBSD: src/etc/network.subr,v 1.164.2.2 2005/12/10 02:20:13 brooks Exp $ +# $FreeBSD: src/etc/network.subr,v 1.180.2.1 2007/11/08 05:52:23 thompsa Exp $ # # @@ -45,14 +45,11 @@ ifconfig_args=`ifconfig_getargs $1` if [ -n "${ifconfig_args}" ]; then ifconfig $1 up - eval "ifconfig $1 ${ifconfig_args}" + ifconfig $1 ${ifconfig_args} _cfg=0 fi if wpaif $1; then - if [ $_cfg -ne 0 ] ; then - ifconfig $1 up - fi /etc/rc.d/wpa_supplicant start $1 _cfg=0 # XXX: not sure this should count fi @@ -61,7 +58,9 @@ if [ $_cfg -ne 0 ] ; then ifconfig $1 up fi - /etc/rc.d/dhclient start $1 + if syncdhcpif $1; then + /etc/rc.d/dhclient start $1 + fi _cfg=0 fi @@ -69,33 +68,14 @@ } # ifconfig_down if -# Remove all inet entries from the $if interface. It returns -# 0 if inet entries were found and removed. It returns 1 if -# no entries were found or they could not be removed. +# returns 1 if wpa_supplicant or dhclient was stopped or +# the interface exists. # ifconfig_down() { [ -z "$1" ] && return 1 - _ifs="^" _cfg=1 - inetList="`ifconfig $1 | grep 'inet ' | tr "\n" "$_ifs"`" - - oldifs="$IFS" - IFS="$_ifs" - for _inet in $inetList ; do - # get rid of extraneous line - [ -z "$_inet" ] && break - - _inet=`expr "$_inet" : '.*\(inet \([0-9]\{1,3\}\.\)\{3\}[0-9]\{1,3\}\).*'` - - IFS="$oldifs" - ifconfig $1 ${_inet} delete - IFS="$_ifs" - _cfg=0 - done - IFS="$oldifs" - if wpaif $1; then /etc/rc.d/wpa_supplicant stop $1 _cfg=0 @@ -106,9 +86,39 @@ _cfg=0 fi + if ifexists $1; then + ifconfig $1 down + _cfg=0 + fi + return $_cfg } +# get_if_var if var [default] +# Return the value of the pseudo-hash corresponding to $if where +# $var is a string containg the sub-string "IF" which will be +# replaced with $if after the characters defined in _punct are +# replaced with '_'. If the variable is unset, replace it with +# $default if given. +get_if_var() +{ + if [ $# -ne 2 -a $# -ne 3 ]; then + err 3 'USAGE: get_if_var name var [default]' + fi + + _if=$1 + _punct=". - / +" + for _punct_c in $_punct; do + _if=`ltr ${_if} ${_punct_c} '_'` + done + _var=$2 + _default=$3 + + prefix=${_var%%IF*} + suffix=${_var##*IF} + eval echo \${${prefix}${_if}${suffix}-${_default}} +} + # _ifconfig_getargs if # Echos the arguments for the supplied interface to stdout. # returns 1 if empty. In general, ifconfig_getargs should be used @@ -120,9 +130,7 @@ return 1 fi - eval _args=\${ifconfig_$1-$ifconfig_DEFAULT} - - echo "$_args" + get_if_var $_ifn ifconfig_IF "$ifconfig_DEFAULT" } # ifconfig_getargs if @@ -138,12 +146,11 @@ for _arg in $_tmpargs; do case $_arg in - [Dd][Hh][Cc][Pp]) - ;; - [Nn][Oo][Aa][Uu][Tt][Oo]) - ;; - [Ww][Pp][Aa]) - ;; + [Dd][Hh][Cc][Pp]) ;; + [Nn][Oo][Aa][Uu][Tt][Oo]) ;; + [Nn][Oo][Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) ;; + [Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) ;; + [Ww][Pp][Aa]) ;; *) _args="$_args $_arg" ;; @@ -179,11 +186,40 @@ [Dd][Hh][Cc][Pp]) return 0 ;; + [Nn][Oo][Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 0 + ;; + [Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 0 + ;; esac done return 1 } +# syncdhcpif +# Returns 0 if the interface should be configured synchronously and +# 1 otherwise. +syncdhcpif() +{ + _tmpargs=`_ifconfig_getargs $1` + for _arg in $_tmpargs; do + case $_arg in + [Nn][Oo][Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 1 + ;; + [Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 0 + ;; + esac + done + if checkyesno synchronous_dhclient; then + return 0 + else + return 1 + fi +} + # wpaif if # Returns 0 if the interface is a WPA interface and 1 otherwise. wpaif() @@ -199,6 +235,37 @@ return 1 } +# ipv6if if +# Returns 0 if the interface should be configured for IPv6 and +# 1 otherwise. +ipv6if() +{ + if ! checkyesno ipv6_enable; then + return 1 + fi + case "${ipv6_network_interfaces}" in + [Aa][Uu][Tt][Oo]) + return 0 + ;; + ''|[Nn][Oo][Nn][Ee]) + return 1 + ;; + esac + for v6if in ${ipv6_network_interfaces}; do + if [ "${v6if}" = "${1}" ]; then + return 0 + fi + done + return 1 +} + +# ifexists if +# Returns 0 if the interface exists and 1 otherwise. +ifexists() +{ + ifconfig -n $1 > /dev/null 2>&1 +} + # ipv4_up if # add IPv4 addresses to the interface $if ipv4_up() @@ -213,8 +280,32 @@ ipv4_down() { _if=$1 - ifalias_down ${_if} - ipv4_addrs_common ${_if} -alias + _ifs="^" + _ret=1 + + ifexists ${_if} || return 1 + + inetList="`ifconfig ${_if} | grep 'inet ' | tr "\n" "$_ifs"`" + + oldifs="$IFS" + IFS="$_ifs" + for _inet in $inetList ; do + # get rid of extraneous line + [ -z "$_inet" ] && break + + _inet=`expr "$_inet" : '.*\(inet \([0-9]\{1,3\}\.\)\{3\}[0-9]\{1,3\}\).*'` + + IFS="$oldifs" + ifconfig ${_if} ${_inet} delete + IFS="$_ifs" + _ret=0 + done + IFS="$oldifs" + + ifalias_down ${_if} && _ret=0 + ipv4_addrs_common ${_if} -alias && _ret=0 + + return $_ret } # ipv4_addrs_common if action @@ -227,7 +318,7 @@ _action=$2 # get ipv4-addresses - eval cidr_addr=\${ipv4_addrs_${_if}} + cidr_addr=`get_if_var $_if ipv4_addrs_IF` for _cidr in ${cidr_addr}; do _ipaddr=${_cidr%%/*} @@ -267,7 +358,7 @@ _ret=1 alias=0 while : ; do - eval ifconfig_args=\$ifconfig_$1_alias${alias} + ifconfig_args=`get_if_var $1 ifconfig_IF_alias${alias}` if [ -n "${ifconfig_args}" ]; then ifconfig $1 ${ifconfig_args} alias alias=$((${alias} + 1)) @@ -289,7 +380,7 @@ _ret=1 alias=0 while : ; do - eval ifconfig_args=\$ifconfig_$1_alias${alias} + ifconfig_args=`get_if_var $1 ifconfig_IF_alias${alias}` if [ -n "${ifconfig_args}" ]; then ifconfig $1 ${ifconfig_args} -alias alias=$((${alias} + 1)) @@ -362,26 +453,89 @@ debug "Destroyed clones: ${_list}" } +# Create netgraph nodes. +# +ng_mkpeer() { + ngctl -f - 2> /dev/null </dev/null 2>&1 + ifconfig $i tunnel ${peers} + ifconfig $i up + ;; + esac + done +} + +# ng_fec_create ifn +# Configure Fast EtherChannel for interface $ifn. Returns 0 if FEC +# arguments were found and configured; returns !0 otherwise. +ng_fec_create() { + local req_iface iface bogus + req_iface="$1" + + ngctl shutdown ${req_iface}: > /dev/null 2>&1 + + bogus="" + while true; do + iface=`ng_create_one fec dummy fec` + if [ -z "${iface}" ]; then + exit 2 + fi + if [ "${iface}" = "${req_iface}" ]; then + break + fi + bogus="${bogus} ${iface}" + done + + for iface in ${bogus}; do + ngctl shutdown ${iface}: + done +} + +fec_up() { + for i in ${fec_interfaces}; do + ng_fec_create $i + for j in `get_if_var $i fecconfig_IF`; do + case ${j} in '') continue ;; *) - ifconfig $i create >/dev/null 2>&1 - ifconfig $i tunnel ${peers} - ifconfig $i up + ngctl msg ${i}: add_iface "\"${j}\"" ;; esac done - ;; - esac + done } # @@ -392,7 +546,7 @@ ipx_up() { ifn="$1" - eval ifconfig_args=\$ifconfig_${ifn}_ipx + ifconfig_args=`get_if_var $ifn ifconfig_IF_ipx` if [ -n "${ifconfig_args}" ]; then ifconfig ${ifn} ${ifconfig_args} return 0 @@ -410,6 +564,8 @@ _ifs="^" _ret=1 + ifexists $1 || return 1 + ipxList="`ifconfig $1 | grep 'ipx ' | tr "\n" "$_ifs"`" oldifs="$IFS" @@ -439,7 +595,7 @@ _ifn_list="`ifconfig -l`" [ -z "$_ifn_list" ] && return 0 for _if in ${_ifn_list} ; do - eval _ifname=\$ifconfig_${_if}_name + _ifname=`get_if_var $_if ifconfig_IF_name` if [ ! -z "$_ifname" ]; then ifconfig $_if name $_ifname fi @@ -483,6 +639,10 @@ _tmplist="${_lo}${_tmplist}" ;; *) + if [ -z "$type" ]; then + warn "Values of network_interfaces other than"\ + "AUTO are deprecated" + fi _tmplist="${network_interfaces} ${cloned_interfaces}" ;; esac @@ -500,7 +660,7 @@ if dhcpif $_if; then _dhcplist="${_dhcplist}${_aprefix}${_if}" [ -z "$_aprefix" ] && _aprefix=' ' - elif [ -n "`_ifconfig_getargs $if`" ]; then + elif [ -n "`_ifconfig_getargs $_if`" ]; then _nodhcplist="${_nodhcplist}${_bprefix}${_if}" [ -z "$_bprefix" ] && _bprefix=' ' fi @@ -565,7 +725,7 @@ esac for i in $interfaces; do rtsol_interface=yes - eval prefix=\$ipv6_prefix_$i + prefix=`get_if_var $i ipv6_prefix_IF` if [ -n "${prefix}" ]; then rtsol_available=no rtsol_interface=no @@ -585,7 +745,7 @@ esac done fi - eval ipv6_ifconfig=\$ipv6_ifconfig_$i + ipv6_ifconfig=`get_if_var $i ipv6_ifconfig_IF` if [ -n "${ipv6_ifconfig}" ]; then rtsol_available=no rtsol_interface=no @@ -595,7 +755,7 @@ if [ ${rtsol_available} = yes -a ${rtsol_interface} = yes ] then case ${i} in - lo0|gif[0-9]*|stf[0-9]*|faith[0-9]*|lp[0-9]*|sl[0-9]*|tun[0-9]*) + lo0|gif[0-9]*|stf[0-9]*|faith[0-9]*|lp[0-9]*|sl[0-9]*|tun[0-9]*|pflog[0-9]*|pfsync[0-9]*) ;; *) rtsol_interfaces="${rtsol_interfaces} ${i}" @@ -620,7 +780,7 @@ for i in $interfaces; do alias=0 while : ; do - eval ipv6_ifconfig=\$ipv6_ifconfig_${i}_alias${alias} + ipv6_ifconfig=`get_if_var $i ipv6_ifconfig_IF_alias${alias}` if [ -z "${ipv6_ifconfig}" ]; then break; fi @@ -696,7 +856,7 @@ ;; *) for i in ${ipv6_static_routes}; do - eval ipv6_route_args=\$ipv6_route_${i} + ipv6_route_args=`get_if_var $i ipv6_route_IF` route add -inet6 ${ipv6_route_args} done ;; From laffer1 at midnightbsd.org Sat Jan 17 11:31:35 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 11:31:35 -0500 (EST) Subject: [Midnightbsd-cvs] src: src/etc: Remove pccard Message-ID: <200901171631.n0HGVZNv028010@stargazer.midnightbsd.org> Log Message: ----------- Remove pccard Modified Files: -------------- src/etc: netstart (r1.2 -> r1.3) src/etc/rc.d: Makefile (r1.10 -> r1.11) netif (r1.3 -> r1.4) Removed Files: ------------- src/etc/rc.d: pccard -------------- next part -------------- Index: netstart =================================================================== RCS file: /home/cvs/src/etc/netstart,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/netstart -L etc/netstart -u -r1.2 -r1.3 --- etc/netstart +++ etc/netstart @@ -38,7 +38,6 @@ . /etc/rc.subr load_rc_config 'XXX' -/etc/rc.d/pccard start /etc/rc.d/devd start /etc/rc.d/hostname start /etc/rc.d/ipmon start --- etc/rc.d/pccard +++ /dev/null @@ -1,71 +0,0 @@ -#!/bin/sh -# -# Copyright (c) 1996 The FreeBSD Project -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/etc/rc.d/pccard,v 1.30 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD: src/etc/rc.d/pccard,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: pccard -# REQUIRE: mountcritlocal -# KEYWORD: nojail - -. /etc/rc.subr - -name="pccard" -start_cmd="pccard_start" -stop_cmd=":" - -pccard_start() -{ - if [ ! -c /dev/card0 ]; then - exit 0 - fi - if checkyesno pccard_enable; then - echo -n 'Setup PC-CARD:' - - case ${pccard_mem} in - [Dd][Ee][Ff][Aa][Uu][Ll][Tt]) - pccardc pccardmem 0xd0000 1>/dev/null && echo -n ' memory' - ;; - *) - pccardc pccardmem ${pccard_mem} 1>/dev/null && echo -n ' memory' - ;; - esac - - if [ -n "${pccard_beep}" ]; then - pccardc beep ${pccard_beep} && echo -n ' beep' - fi - - if [ -n "${pccard_conf}" ]; then - pccardd_flags="${pccardd_flags} -f ${pccard_conf}" - fi - - pccardd ${pccardd_flags} && echo -n ' pccardd' - echo '.' - fi -} - -load_rc_config $name -run_rc_command "$1" Index: netif =================================================================== RCS file: /home/cvs/src/etc/rc.d/netif,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/netif -L etc/rc.d/netif -u -r1.3 -r1.4 --- etc/rc.d/netif +++ etc/rc.d/netif @@ -26,7 +26,7 @@ # $MidnightBSD$ # PROVIDE: netif -# REQUIRE: atm1 cleanvar ipfilter FILESYSTEMS pccard serial sppp sysctl +# REQUIRE: atm1 cleanvar ipfilter FILESYSTEMS serial sppp sysctl # KEYWORD: nojail . /etc/rc.subr Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.10 retrieving revision 1.11 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.10 -r1.11 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -27,7 +27,7 @@ network_ipv6 newsyslog nfsclient nfsd \ nfslocking nfsserver nisdomain nsswitch ntpd \ othermta \ - pccard pf pflog pfsync \ + pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ quota \ ramdisk ramdisk-own random rarpd rdate resolv root \ From laffer1 at midnightbsd.org Sat Jan 17 11:40:42 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 11:40:42 -0500 (EST) Subject: [Midnightbsd-cvs] src: netoptions: Add several new friendly net options. Message-ID: <200901171640.n0HGegk6029041@stargazer.midnightbsd.org> Log Message: ----------- Add several new friendly net options. Modified Files: -------------- src/etc/rc.d: netoptions (r1.3 -> r1.4) -------------- next part -------------- Index: netoptions =================================================================== RCS file: /home/cvs/src/etc/rc.d/netoptions,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/netoptions -L etc/rc.d/netoptions -u -r1.3 -r1.4 --- etc/rc.d/netoptions +++ etc/rc.d/netoptions @@ -5,14 +5,13 @@ # PROVIDE: netoptions # REQUIRE: FILESYSTEMS -# BEFORE: securelevel # KEYWORD: nojail . /etc/rc.subr load_rc_config 'XXX' -echo -n 'Additional TCP options:' +echo -n 'Additional IP options:' case ${log_in_vain} in [Nn][Oo] | '') log_in_vain=0 @@ -33,4 +32,46 @@ sysctl net.inet.tcp.log_in_vain="${log_in_vain}" >/dev/null sysctl net.inet.udp.log_in_vain="${log_in_vain}" >/dev/null ) + +case ${tcp_extensions} in +[Yy][Ee][Ss] | '') + ;; +*) + echo -n ' tcp extensions=NO' + sysctl net.inet.tcp.rfc1323=0 >/dev/null + ;; +esac + +case ${tcp_keepalive} in +[Nn][Oo]) + echo -n ' TCP keepalive=NO' + sysctl net.inet.tcp.always_keepalive=0 >/dev/null + ;; +esac + +case ${tcp_drop_synfin} in +[Yy][Ee][Ss]) + echo -n ' drop SYN+FIN packets=YES' + sysctl net.inet.tcp.drop_synfin=1 >/dev/null + ;; +esac + +case ${ip_portrange_first} in +[Nn][Oo] | '') + ;; +*) + echo -n " ip_portrange_first=$ip_portrange_first" + sysctl net.inet.ip.portrange.first=$ip_portrange_first >/dev/null + ;; +esac + +case ${ip_portrange_last} in +[Nn][Oo] | '') + ;; +*) + echo -n " ip_portrange_last=$ip_portrange_last" + sysctl net.inet.ip.portrange.last=$ip_portrange_last >/dev/null + ;; +esac + echo '.' From laffer1 at midnightbsd.org Sat Jan 17 12:16:42 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:16:42 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: change the name of pidfile not to conflict Message-ID: <200901171716.n0HHGgJ0032541@stargazer.midnightbsd.org> Log Message: ----------- change the name of pidfile not to conflict Modified Files: -------------- src/etc/rc.d: netif (r1.4 -> r1.5) wpa_supplicant (r1.3 -> r1.4) -------------- next part -------------- Index: wpa_supplicant =================================================================== RCS file: /home/cvs/src/etc/rc.d/wpa_supplicant,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/wpa_supplicant -L etc/rc.d/wpa_supplicant -u -r1.3 -r1.4 --- etc/rc.d/wpa_supplicant +++ etc/rc.d/wpa_supplicant @@ -32,8 +32,8 @@ load_rc_config $name -pidfile="/var/run/${name}/${ifn}.pid" -command_args="-B -q -i $ifn -c $conf_file -D $driver -P $pidfile" +pid_file="/var/run/${name}/${ifn}.pid" +command_args="-B -q -i $ifn -c $conf_file -D $driver -P $pid_file" required_files=$conf_file run_rc_command "$1" Index: netif =================================================================== RCS file: /home/cvs/src/etc/rc.d/netif,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/netif -L etc/rc.d/netif -u -r1.4 -r1.5 --- etc/rc.d/netif +++ etc/rc.d/netif @@ -38,15 +38,15 @@ cloneup_cmd="clone_up" clonedown_cmd="clone_down" extra_commands="cloneup clonedown" -_cmdifn= +cmdifn= network_start() { # Set the list of interfaces to work on. # - _cmdifn=$* + cmdifn=$* - if [ -z "$_cmdifn" ]; then + if [ -z "$cmdifn" ]; then # # We're operating as a general network start routine. # @@ -57,6 +57,9 @@ # Create cloned interfaces clone_up + # Create Fast EtherChannel interfaces + fec_up + # Create IPv6<-->IPv4 tunnels gif_up @@ -71,13 +74,16 @@ # Resync ipfilter /etc/rc.d/ipfilter resync fi + if [ -f /etc/rc.d/bridge -a -n "$cmdifn" ] ; then + /etc/rc.d/bridge start $cmdifn + fi } network_stop() { # Set the list of interfaces to work on. # - _cmdifn=$* + cmdifn=$* echo -n "Stopping network:" @@ -95,6 +101,8 @@ # configured interface(s). network_common() { + local _cooked_list _fail _func _verbose + _func= _verbose= @@ -108,15 +116,16 @@ # Set the scope of the command (all interfaces or just one). # _cooked_list= - if [ -n "$_cmdifn" ]; then + if [ -n "$cmdifn" ]; then # Don't check that the interfaces exist. We need to run # the down code even when the interface doesn't exist to # kill off wpa_supplicant. - _cooked_list="$_cmdifn" + _cooked_list="$cmdifn" else _cooked_list="`list_net_interfaces`" fi + _fail= for ifn in ${_cooked_list}; do if ${_func} ${ifn} ; then eval showstat_$ifn=1 From laffer1 at midnightbsd.org Sat Jan 17 12:20:22 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:20:22 -0500 (EST) Subject: [Midnightbsd-cvs] src: routing: Remove some of these options as they were moved to Message-ID: <200901171720.n0HHKMDf032955@stargazer.midnightbsd.org> Log Message: ----------- Remove some of these options as they were moved to netoptions Modified Files: -------------- src/etc/rc.d: routing (r1.2 -> r1.3) -------------- next part -------------- Index: routing =================================================================== RCS file: /home/cvs/src/etc/rc.d/routing,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/routing -L etc/rc.d/routing -u -r1.2 -r1.3 --- etc/rc.d/routing +++ etc/rc.d/routing @@ -3,7 +3,7 @@ # Configure routing and miscellaneous network tunables # # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/routing,v 1.141.2.1 2006/01/21 22:42:43 yar Exp $ +# $FreeBSD: src/etc/rc.d/routing,v 1.143 2007/05/02 15:49:30 mtm Exp $ # # PROVIDE: routing @@ -62,15 +62,6 @@ options_start() { echo -n 'Additional routing options:' - case ${tcp_extensions} in - [Yy][Ee][Ss] | '') - ;; - *) - echo -n ' tcp extensions=NO' - sysctl net.inet.tcp.rfc1323=0 >/dev/null - ;; - esac - case ${icmp_bmcastecho} in [Yy][Ee][Ss]) echo -n ' broadcast ping responses=YES' @@ -113,20 +104,6 @@ ;; esac - case ${tcp_keepalive} in - [Nn][Oo]) - echo -n ' TCP keepalive=NO' - sysctl net.inet.tcp.always_keepalive=0 >/dev/null - ;; - esac - - case ${tcp_drop_synfin} in - [Yy][Ee][Ss]) - echo -n ' drop SYN+FIN packets=YES' - sysctl net.inet.tcp.drop_synfin=1 >/dev/null - ;; - esac - case ${ipxgateway_enable} in [Yy][Ee][Ss]) echo -n ' IPX gateway=YES' @@ -141,24 +118,6 @@ ;; esac - case ${ip_portrange_first} in - [Nn][Oo] | '') - ;; - *) - echo -n " ip_portrange_first=$ip_portrange_first" - sysctl net.inet.ip.portrange.first=$ip_portrange_first >/dev/null - ;; - esac - - case ${ip_portrange_last} in - [Nn][Oo] | '') - ;; - *) - echo -n " ip_portrange_last=$ip_portrange_last" - sysctl net.inet.ip.portrange.last=$ip_portrange_last >/dev/null - ;; - esac - echo '.' } From laffer1 at midnightbsd.org Sat Jan 17 12:21:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:21:48 -0500 (EST) Subject: [Midnightbsd-cvs] src: pppoed: Make local Message-ID: <200901171721.n0HHLmEO033025@stargazer.midnightbsd.org> Log Message: ----------- Make local Modified Files: -------------- src/etc/rc.d: pppoed (r1.2 -> r1.3) -------------- next part -------------- Index: pppoed =================================================================== RCS file: /home/cvs/src/etc/rc.d/pppoed,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/pppoed -L etc/rc.d/pppoed -u -r1.2 -r1.3 --- etc/rc.d/pppoed +++ etc/rc.d/pppoed @@ -18,6 +18,7 @@ pppoed_start() { + local _opts if [ -n "${pppoed_provider}" ]; then pppoed_flags="${pppoed_flags} -p ${pppoed_provider}" fi From laffer1 at midnightbsd.org Sat Jan 17 12:24:51 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:24:51 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: Whack ppp-user... Message-ID: <200901171724.n0HHOpDC033141@stargazer.midnightbsd.org> Log Message: ----------- Whack ppp-user... merge and cleanup ppp Modified Files: -------------- src/etc/rc.d: ppp (r1.2 -> r1.3) Removed Files: ------------- src/etc/rc.d: ppp-user -------------- next part -------------- --- etc/rc.d/ppp-user +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -# -# $FreeBSD: src/etc/rc.d/ppp-user,v 1.7 2004/12/15 12:39:28 brian Exp $ -# $MidnightBSD: src/etc/rc.d/ppp-user,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: ppp-user -# REQUIRE: netif isdnd -# KEYWORD: nojail - -. /etc/rc.subr - -name="ppp" -rcvar=`set_rcvar` -start_precmd="ppp_precmd" -start_postcmd="ppp_postcmd" - -ppp_precmd() -{ - # Establish ppp mode. - # - if [ "${ppp_mode}" != "ddial" -a "${ppp_mode}" != "direct" \ - -a "${ppp_mode}" != "dedicated" \ - -a "${ppp_mode}" != "background" ]; then - ppp_mode="auto" - fi - - rc_flags="$rc_flags -quiet -${ppp_mode}" - - # Switch on NAT mode? - # - case ${ppp_nat} in - [Yy][Ee][Ss]) - rc_flags="$rc_flags -nat" - ;; - esac - - rc_flags="$rc_flags ${ppp_profile}" -} - -ppp_postcmd() -{ - # Re-Sync ipfilter so it picks up any new network interfaces - # - /etc/rc.d/ipfilter resync -} - -load_rc_config $name -run_rc_command "$1" Index: ppp =================================================================== RCS file: /home/cvs/src/etc/rc.d/ppp,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/ppp -L etc/rc.d/ppp -u -r1.2 -r1.3 --- etc/rc.d/ppp +++ etc/rc.d/ppp @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ppp,v 1.11.2.1 2006/01/21 22:42:43 yar Exp $ +# $FreeBSD: src/etc/rc.d/ppp,v 1.13.2.1 2007/10/31 16:42:41 emax Exp $ # $MidnightBSD$ # PROVIDE: ppp @@ -12,38 +12,106 @@ name="ppp" rcvar=`set_rcvar` command="/usr/sbin/${name}" -start_precmd="ppp_precmd" -start_postcmd="ppp_postcmd" +start_cmd="ppp_start" +stop_cmd="ppp_stop" +start_postcmd="ppp_poststart" -ppp_precmd() +ppp_start_profile() { + local _ppp_profile _ppp_mode _ppp_nat + + _ppp_profile=$1 + + # Check for ppp profile mode override. + # + eval _ppp_mode=\$ppp_${_ppp_profile}_mode + if [ -z "$_ppp_mode" ]; then + _ppp_mode=$ppp_mode + fi + + # Check for ppp profile nat override. + # + eval _ppp_nat=\$ppp_${_ppp_profile}_nat + if [ -z "$_ppp_nat" ]; then + _ppp_nat=$ppp_nat + fi + # Establish ppp mode. # - if [ "${ppp_mode}" != "ddial" -a "${ppp_mode}" != "direct" \ - -a "${ppp_mode}" != "dedicated" \ - -a "${ppp_mode}" != "background" ]; then - ppp_mode="auto" + if [ "${_ppp_mode}" != "ddial" -a "${_ppp_mode}" != "direct" \ + -a "${_ppp_mode}" != "dedicated" \ + -a "${_ppp_mode}" != "background" ]; then + _ppp_mode="auto" fi - rc_flags="$rc_flags -quiet -${ppp_mode}" + rc_flags="-quiet -${_ppp_mode}" # Switch on NAT mode? # - case ${ppp_nat} in + case ${_ppp_nat} in [Yy][Ee][Ss]) rc_flags="$rc_flags -nat" ;; esac - rc_flags="$rc_flags ${ppp_profile}" + # Run! + # + su -m $ppp_user -c "$command ${rc_flags} ${_ppp_profile}" +} + +ppp_start() +{ + local _ppp_profile _p + + _ppp_profile=$* + if [ -z "${_ppp_profile}" ]; then + _ppp_profile=$ppp_profile + fi + + echo -n "Starting PPP profile:" + + for _p in $_ppp_profile; do + echo -n " $_p" + ppp_start_profile $_p + done + + echo "." } -ppp_postcmd() +ppp_poststart() { - # Re-Sync ipfilter so it picks up any new network interfaces + # Re-Sync ipfilter and pf so they pick up any new network interfaces # /etc/rc.d/ipfilter resync + /etc/rc.d/pf resync +} + +ppp_stop_profile() { + local _ppp_profile + + _ppp_profile=$1 + + /bin/pkill -f "^${command}.*[[:space:]]${_ppp_profile}\$" || \ + echo -n "(not running)" +} + +ppp_stop() { + local _ppp_profile _p + + _ppp_profile=$* + if [ -z "${_ppp_profile}" ]; then + _ppp_profile=$ppp_profile + fi + + echo -n "Stopping PPP profile:" + + for _p in $_ppp_profile; do + echo -n " $_p" + ppp_stop_profile $_p + done + + echo "." } load_rc_config $name -run_rc_command "$1" +run_rc_command $* From laffer1 at midnightbsd.org Sat Jan 17 12:30:25 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:30:25 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add idmapd Message-ID: <200901171730.n0HHUPhT033873@stargazer.midnightbsd.org> Log Message: ----------- add idmapd Modified Files: -------------- src/etc/rc.d: Makefile (r1.11 -> r1.12) pf (r1.3 -> r1.4) pflog (r1.4 -> r1.5) pfsync (r1.3 -> r1.4) Added Files: ----------- src/etc/rc.d: hostid (r1.1) -------------- next part -------------- Index: pfsync =================================================================== RCS file: /home/cvs/src/etc/rc.d/pfsync,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/pfsync -L etc/rc.d/pfsync -u -r1.3 -r1.4 --- etc/rc.d/pfsync +++ etc/rc.d/pfsync @@ -1,7 +1,7 @@ #!/bin/sh # # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/pfsync,v 1.1.2.1 2005/10/08 03:32:54 yar Exp $ +# $FreeBSD: src/etc/rc.d/pfsync,v 1.5 2007/04/10 16:42:13 keramida Exp $ # # PROVIDE: pfsync @@ -15,33 +15,35 @@ start_precmd="pfsync_prestart" start_cmd="pfsync_start" stop_cmd="pfsync_stop" +required_modules="pf" pfsync_prestart() { + # XXX Currently pfsync cannot be a module as it must register + # a network protocol in a static kernel table. + if ! kldstat -q -m pfsync; then + warn "pfsync(4) must be statically compiled in the kernel." + return 1 + fi + case "$pfsync_syncdev" in '') warn "pfsync_syncdev is not set." return 1 ;; esac - - # load pf kernel module if needed - if ! kldstat -q -m pf ; then - if kldload pf ; then - info "pf module loaded." - else - warn "pf module failed to load." - return 1 - fi - fi - return 0 } pfsync_start() { + local _syncpeer + echo "Enabling pfsync." - ifconfig pfsync0 syncdev $pfsync_syncdev $pfsync_ifconfig up + if [ -n "${pfsync_syncpeer}" ]; then + _syncpeer="syncpeer ${pfsync_syncpeer}" + fi + ifconfig pfsync0 $_syncpeer syncdev $pfsync_syncdev $pfsync_ifconfig up } pfsync_stop() Index: pf =================================================================== RCS file: /home/cvs/src/etc/rc.d/pf,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/pf -L etc/rc.d/pf -u -r1.3 -r1.4 --- etc/rc.d/pf +++ etc/rc.d/pf @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/pf,v 1.7.2.4 2006/01/22 13:45:28 yar Exp $ +# $FreeBSD: src/etc/rc.d/pf,v 1.16 2007/04/09 08:53:40 des Exp $ # $MidnightBSD$ # PROVIDE: pf @@ -13,7 +13,6 @@ name="pf" rcvar=`set_rcvar` load_rc_config $name -start_precmd="pf_prestart" start_cmd="pf_start" stop_cmd="pf_stop" check_cmd="pf_check" @@ -22,25 +21,12 @@ status_cmd="pf_status" extra_commands="check reload resync status" required_files="$pf_rules" - -pf_prestart() -{ - # load pf kernel module if needed - if ! kldstat -q -m pf ; then - if kldload pf ; then - info 'pf module loaded.' - else - warn 'pf module failed to load.' - return 1 - fi - fi - return 0 -} +required_modules="pf" pf_start() { echo "Enabling pf." - $pf_program -Fall > /dev/null 2>&1 + $pf_program -F all > /dev/null 2>&1 $pf_program -f "$pf_rules" $pf_flags if ! $pf_program -s info | grep -q "Enabled" ; then $pf_program -e Index: pflog =================================================================== RCS file: /home/cvs/src/etc/rc.d/pflog,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/pflog -L etc/rc.d/pflog -u -r1.4 -r1.5 --- etc/rc.d/pflog +++ etc/rc.d/pflog @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/pflog,v 1.5.2.1 2006/01/22 13:40:47 yar Exp $ +# $FreeBSD: src/etc/rc.d/pflog,v 1.12 2007/04/09 08:53:40 des Exp $ # $MidnightBSD$ # PROVIDE: pflog @@ -22,19 +22,11 @@ pflog_prestart() { - # load pflog kernel module if needed - if ! kldstat -q -m pflog; then - if kldload pflog; then - info 'pflog module loaded.' - else - warn 'pflog module failed to load.' - return 1 - fi - fi + load_kld pflog || return 1 # set pflog0 interface to up state if ! ifconfig pflog0 up; then - warn 'could not not bring up pflog0.' + warn 'could not bring up pflog0.' return 1 fi --- /dev/null +++ etc/rc.d/hostid @@ -0,0 +1,98 @@ +#!/bin/sh +# +# Copyright (c) 2007 Pawel Jakub Dawidek +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $MidnightBSD: src/etc/rc.d/hostid,v 1.1 2009/01/17 17:30:24 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/hostid,v 1.7 2007/05/22 13:53:59 rse Exp $ +# + +# PROVIDE: hostid +# REQUIRE: root +# BEFORE: mountcritlocal +# KEYWORD: nojail + +. /etc/rc.subr + +name="hostid" +start_cmd="hostid_start" +stop_cmd=":" +reset_cmd="hostid_reset" +extra_commands="reset" +rcvar="hostid_enable" + +hostid_set() +{ + uuid=$1 + # Generate hostid based on hostuuid - take first four bytes from md5(uuid). + id=`echo -n $uuid | md5` + id="0x${id%????????????????????????}" + # Set both kern.hostuuid and kern.hostid. + echo "Setting hostuuid: ${uuid}." + ${SYSCTL_W} kern.hostuuid="${uuid}" >/dev/null + echo "Setting hostid: ${id}." + ${SYSCTL_W} kern.hostid=${id} >/dev/null +} + +hostid_hardware() +{ + uuid=`kenv smbios.system.uuid 2>/dev/null` + x="[0-9a-f]" + y=$x$x$x$x + case "${uuid}" in + $y$y-$y-$y-$y-$y$y$y) + echo "${uuid}" + ;; + esac +} + +hostid_reset() +{ + # First look for UUID in hardware. + uuid=`hostid_hardware` + if [ -z ${uuid} ]; then + # If not found, fall back to software-generated UUID. + uuid=`uuidgen` + fi + # Store newly generated UUID in ${hostid_file}. + echo $uuid > ${hostid_file} + if [ $? -ne 0 ]; then + warn "could not store hostuuid in ${hostid_file}." + fi + hostid_set $uuid +} + +hostid_start() +{ + # If ${hostid_file} already exists, we take UUID from there. + if [ -r ${hostid_file} ]; then + hostid_set `cat ${hostid_file}` + else + # No hostid file, generate UUID. + hostid_reset + fi +} + +load_rc_config $name +run_rc_command "$1" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.11 retrieving revision 1.12 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.11 -r1.12 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -13,9 +13,9 @@ firstboot fsck ftp-proxy ftpd \ gbde geli geli2 \ hcsecd \ - hostapd hostname \ + hostapd hostid hostname \ ike \ - inetd initrandom \ + idmapd inetd initrandom \ ip6addrctl ip6fw ipfilter ipfs ipfw ipmon \ ipnat ipsec ipxrouted isdnd \ jail \ From laffer1 at midnightbsd.org Sat Jan 17 12:30:42 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:30:42 -0500 (EST) Subject: [Midnightbsd-cvs] src: idmapd: Message-ID: <200901171730.n0HHUg6T033925@stargazer.midnightbsd.org> Log Message: ----------- Added Files: ----------- src/etc/rc.d: idmapd (r1.1) -------------- next part -------------- --- /dev/null +++ etc/rc.d/idmapd @@ -0,0 +1,19 @@ +#!/bin/sh +# +# $MidnightBSD: src/etc/rc.d/idmapd,v 1.1 2009/01/17 17:30:41 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/idmapd,v 1.1 2006/10/15 14:19:06 ceri Exp $ +# + +# PROVIDE: idmapd +# REQUIRE: rpcbind +# KEYWORD: nojail + +. /etc/rc.subr + +name="idmapd" + +load_rc_config $name +rcvar="idmapd_enable" +command="${idmapd:-/sbin/${name}}" +eval ${name}_flags=\"${idmapd_flags}\" +run_rc_command "$1" From laffer1 at midnightbsd.org Sat Jan 17 12:32:59 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:32:59 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add kernel Message-ID: <200901171732.n0HHWxJX034036@stargazer.midnightbsd.org> Log Message: ----------- add kernel Modified Files: -------------- src/etc/rc.d: Makefile (r1.12 -> r1.13) Added Files: ----------- src/etc/rc.d: kernel (r1.1) -------------- next part -------------- --- /dev/null +++ etc/rc.d/kernel @@ -0,0 +1,28 @@ +#!/bin/sh +# +# $MidnightBSD: src/etc/rc.d/kernel,v 1.1 2009/01/17 17:32:59 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/kernel,v 1.2 2006/07/30 12:54:37 mckay Exp $ +# + +# PROVIDE: kernel +# REQUIRE: mountcritremote +# KEYWORD: nojail + +. /etc/rc.subr + +name="kernel" +start_cmd="kernel_start" +stop_cmd=":" + +kernel_start() +{ + bootdir=$(dirname $(sysctl -n kern.bootfile)) + if [ "$bootdir" != /boot/kernel ] ; then + if [ ! -e /boot/kernel -o -h /boot/kernel ] ; then + ln -hfs ${bootdir} /boot/kernel + fi + fi +} + +load_rc_config $name +run_rc_command "$1" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.12 retrieving revision 1.13 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.12 -r1.13 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -19,7 +19,7 @@ ip6addrctl ip6fw ipfilter ipfs ipfw ipmon \ ipnat ipsec ipxrouted isdnd \ jail \ - kadmind kerberos keyserv kldxref kpasswdd \ + kadmind kerberos kernel keyserv kldxref kpasswdd \ ldconfig local localpkg lpd \ mixer motd mountcritlocal mountcritremote \ mountd moused mroute6d mrouted msgs \ From laffer1 at midnightbsd.org Sat Jan 17 12:35:27 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:35:27 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: Rename nfslocking -> lockd Message-ID: <200901171735.n0HHZRAO034420@stargazer.midnightbsd.org> Log Message: ----------- Rename nfslocking -> lockd Modified Files: -------------- src/etc/rc.d: Makefile (r1.13 -> r1.14) Added Files: ----------- src/etc/rc.d: lockd (r1.1) Removed Files: ------------- src/etc/rc.d: nfslocking -------------- next part -------------- --- /dev/null +++ etc/rc.d/lockd @@ -0,0 +1,43 @@ +#!/bin/sh +# +# FreeBSD History: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm +# $FreeBSD: src/etc/rc.d/lockd,v 1.18.6.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD: src/etc/rc.d/lockd,v 1.1 2009/01/17 17:35:26 laffer1 Exp $ + +# PROVIDE: lockd +# REQUIRE: nfsserver nfsclient nfsd rpcbind statd +# BEFORE: DAEMON +# KEYWORD: nojail + +. /etc/rc.subr + +name="lockd" +rcvar=rpc_lockd_enable +command="/usr/sbin/rpc.${name}" +start_precmd='lockd_precmd' +stop_precmd='checkyesno nfs_server_enable || checkyesno nfs_client_enable' +status_precmd=$stop_precmd + +# Make sure that we are either an NFS client or server, and that we get +# the correct flags from rc.conf(5). +# +lockd_precmd() +{ + local ret + ret=0 + + if ! checkyesno nfs_server_enable && ! checkyesno nfs_client_enable + then + ret=1 + fi + if ! checkyesno rpcbind_enable && \ + ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1 + then + force_depend rpcbind || ret=1 + fi + rc_flags=${rpc_lockd_flags} + return ${ret} +} + +load_rc_config $name +run_rc_command $1 --- etc/rc.d/nfslocking +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# -# $FreeBSD: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD: src/etc/rc.d/nfslocking,v 1.3 2007/09/28 22:17:23 laffer1 Exp $ - -# PROVIDE: nfslocking -# REQUIRE: nfsserver nfsclient nfsd -# BEFORE: DAEMON -# KEYWORD: nojail - -. /etc/rc.subr - -# Save the (one) commandline argument in case it gets clobbered. -arg=$1 - -# Either NFS client or server must be enabled or this must be a 'forcestart' -# for either of the daemons to start. -# -start_precmd='checkyesno nfs_server_enable || checkyesno nfs_client_enable || - [ -n "$rc_force" ]' -stop_precmd=$start_precmd -status_precmd=$start_precmd - -# rpc.statd -# -name="statd" -rcvar=rpc_statd_enable -command="/usr/sbin/rpc.${name}" -load_rc_config $name -run_rc_command "$arg" - -# rpc.lockd -# -name="lockd" -rcvar=rpc_lockd_enable -command="/usr/sbin/rpc.${name}" -load_rc_config $name -run_rc_command "$arg" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.13 retrieving revision 1.14 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.13 -r1.14 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -20,12 +20,12 @@ ipnat ipsec ipxrouted isdnd \ jail \ kadmind kerberos kernel keyserv kldxref kpasswdd \ - ldconfig local localpkg lpd \ + ldconfig local localpkg lockd lpd \ mixer motd mountcritlocal mountcritremote \ mountd moused mroute6d mrouted msgs \ named natd netif netoptions \ network_ipv6 newsyslog nfsclient nfsd \ - nfslocking nfsserver nisdomain nsswitch ntpd \ + nfsserver nisdomain nsswitch ntpd \ othermta \ pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ From laffer1 at midnightbsd.org Sat Jan 17 12:37:02 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:37:02 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add mountlate Message-ID: <200901171737.n0HHb2Q9034521@stargazer.midnightbsd.org> Log Message: ----------- add mountlate Modified Files: -------------- src/etc/rc.d: Makefile (r1.14 -> r1.15) Added Files: ----------- src/etc/rc.d: mountlate (r1.1) -------------- next part -------------- --- /dev/null +++ etc/rc.d/mountlate @@ -0,0 +1,37 @@ +#!/bin/sh +# +# $MidnightBSD: src/etc/rc.d/mountlate,v 1.1 2009/01/17 17:37:02 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/mountlate,v 1.2 2007/05/18 12:04:41 mtm Exp $ +# + +# PROVIDE: mountlate +# REQUIRE: DAEMON +# BEFORE: LOGIN +# KEYWORD: nojail + +. /etc/rc.subr + +name="mountlate" +start_cmd="mountlate_start" +stop_cmd=":" + +mountlate_start() +{ + # Mount "late" filesystems. + echo -n 'Mounting late file systems:' + mount -a -l + echo '.' + + case $? in + 0) + ;; + *) + echo 'Mounting /etc/fstab filesystems failed,' \ + ' startup aborted' + stop_boot true + ;; + esac +} + +load_rc_config $name +run_rc_command "$1" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.14 retrieving revision 1.15 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.14 -r1.15 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -21,7 +21,7 @@ jail \ kadmind kerberos kernel keyserv kldxref kpasswdd \ ldconfig local localpkg lockd lpd \ - mixer motd mountcritlocal mountcritremote \ + mixer motd mountcritlocal mountcritremote mountlate \ mountd moused mroute6d mrouted msgs \ named natd netif netoptions \ network_ipv6 newsyslog nfsclient nfsd \ From laffer1 at midnightbsd.org Sat Jan 17 12:38:07 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:38:07 -0500 (EST) Subject: [Midnightbsd-cvs] src: mountcritlocal: add friendly message, remove netbsd tag Message-ID: <200901171738.n0HHc7Ka034581@stargazer.midnightbsd.org> Log Message: ----------- add friendly message, remove netbsd tag Modified Files: -------------- src/etc/rc.d: mountcritlocal (r1.3 -> r1.4) -------------- next part -------------- Index: mountcritlocal =================================================================== RCS file: /home/cvs/src/etc/rc.d/mountcritlocal,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/mountcritlocal -L etc/rc.d/mountcritlocal -u -r1.3 -r1.4 --- etc/rc.d/mountcritlocal +++ etc/rc.d/mountcritlocal @@ -1,8 +1,7 @@ #!/bin/sh # -# $NetBSD: mountcritlocal,v 1.7 2002/04/29 12:29:53 lukem Exp $ -# $FreeBSD: src/etc/rc.d/mountcritlocal,v 1.12 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/mountcritlocal,v 1.14.4.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD: src/etc/rc.d/mountcritlocal,v 1.3 2007/10/26 15:20:25 laffer1 # PROVIDE: mountcritlocal # REQUIRE: root @@ -27,6 +26,7 @@ esac # Mount everything except nfs filesystems. + echo -n 'Mounting local file systems:' mount_excludes='no' for i in ${netfs_types}; do fstype=${i%:*} @@ -34,6 +34,7 @@ done mount_excludes=${mount_excludes%,} mount -a -t ${mount_excludes} + echo '.' case $? in 0) From laffer1 at midnightbsd.org Sat Jan 17 12:39:28 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:39:28 -0500 (EST) Subject: [Midnightbsd-cvs] src: mountcritremote: fix some problems with this script Message-ID: <200901171739.n0HHdSpS034671@stargazer.midnightbsd.org> Log Message: ----------- fix some problems with this script Modified Files: -------------- src/etc/rc.d: mountcritremote (r1.4 -> r1.5) -------------- next part -------------- Index: mountcritremote =================================================================== RCS file: /home/cvs/src/etc/rc.d/mountcritremote,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/mountcritremote -L etc/rc.d/mountcritremote -u -r1.4 -r1.5 --- etc/rc.d/mountcritremote +++ etc/rc.d/mountcritremote @@ -1,6 +1,6 @@ -#/bin/sh +#!/bin/sh # -# $FreeBSD: src/etc/rc.d/mountcritremote,v 1.11.2.2 2006/01/08 09:21:53 rse Exp $ +# $FreeBSD: src/etc/rc.d/mountcritremote,v 1.16.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: mountcritremote @@ -26,11 +26,7 @@ case "`mount -d -a -t nfs 2> /dev/null`" in *mount_nfs*) # Handle absent nfs client support - if ! sysctl vfs.nfs >/dev/null 2>&1; then - kldload nfsclient || { warn 'nfs mount ' \ - 'requested, but no nfs client in kernel'; \ - return 1; } - fi + load_kld -m nfs nfsclient || return 1 ;; esac return 0 From laffer1 at midnightbsd.org Sat Jan 17 12:40:45 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:40:45 -0500 (EST) Subject: [Midnightbsd-cvs] src: mountd: add zfs support Message-ID: <200901171740.n0HHejvN035004@stargazer.midnightbsd.org> Log Message: ----------- add zfs support Modified Files: -------------- src/etc/rc.d: mountd (r1.2 -> r1.3) -------------- next part -------------- Index: mountd =================================================================== RCS file: /home/cvs/src/etc/rc.d/mountd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/mountd -L etc/rc.d/mountd -u -r1.2 -r1.3 --- etc/rc.d/mountd +++ etc/rc.d/mountd @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: mountd,v 1.11 2002/01/31 01:26:06 lukem Exp $ -# $FreeBSD: src/etc/rc.d/mountd,v 1.15.2.1 2005/09/21 20:27:50 rodrigc Exp $ +# $FreeBSD: src/etc/rc.d/mountd,v 1.19.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: mountd @@ -13,6 +12,7 @@ name="mountd" rcvar=`set_rcvar` command="/usr/sbin/${name}" +pidfile="/var/run/${name}.pid" required_files="/etc/exports" start_precmd="mountd_precmd" extra_commands="reload" @@ -36,6 +36,11 @@ checkyesno weak_mountd_authentication && rc_flags="-n" fi fi + + if checkyesno zfs_enable; then + rc_flags="${rc_flags} /etc/exports /etc/zfs/exports" + fi + rm -f /var/db/mountdtab ( umask 022 ; > /var/db/mountdtab ) return 0 From laffer1 at midnightbsd.org Sat Jan 17 12:41:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:41:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: FILESYSTEMS: add zfs support Message-ID: <200901171741.n0HHfVnu035064@stargazer.midnightbsd.org> Log Message: ----------- add zfs support Modified Files: -------------- src/etc/rc.d: FILESYSTEMS (r1.1 -> r1.2) -------------- next part -------------- Index: FILESYSTEMS =================================================================== RCS file: /home/cvs/src/etc/rc.d/FILESYSTEMS,v retrieving revision 1.1 retrieving revision 1.2 diff -L etc/rc.d/FILESYSTEMS -L etc/rc.d/FILESYSTEMS -u -r1.1 -r1.2 --- etc/rc.d/FILESYSTEMS +++ etc/rc.d/FILESYSTEMS @@ -4,7 +4,7 @@ # $MidnightBSD$ # PROVIDE: FILESYSTEMS -# REQUIRE: root mountcritlocal +# REQUIRE: root mountcritlocal zfs # This is a dummy dependency, for services which require file systems # to be mounted before starting. It also serves as the default early / From laffer1 at midnightbsd.org Sat Jan 17 12:42:15 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:42:15 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: remove netbsd tags Message-ID: <200901171742.n0HHgFrC035137@stargazer.midnightbsd.org> Log Message: ----------- remove netbsd tags Modified Files: -------------- src/etc/rc.d: DAEMON (r1.2 -> r1.3) SERVERS (r1.3 -> r1.4) -------------- next part -------------- Index: SERVERS =================================================================== RCS file: /home/cvs/src/etc/rc.d/SERVERS,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/SERVERS -L etc/rc.d/SERVERS -u -r1.3 -r1.4 --- etc/rc.d/SERVERS +++ etc/rc.d/SERVERS @@ -1,6 +1,5 @@ #!/bin/sh # -# $NetBSD: SERVERS,v 1.9 2002/03/22 04:33:57 thorpej Exp $ # $FreeBSD: src/etc/rc.d/SERVERS,v 1.5 2004/10/07 13:55:25 mtm Exp $ # $MidnightBSD$ Index: DAEMON =================================================================== RCS file: /home/cvs/src/etc/rc.d/DAEMON,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/DAEMON -L etc/rc.d/DAEMON -u -r1.2 -r1.3 --- etc/rc.d/DAEMON +++ etc/rc.d/DAEMON @@ -1,6 +1,5 @@ #!/bin/sh # -# $NetBSD: DAEMON,v 1.8 2002/03/22 04:33:57 thorpej Exp $ # $FreeBSD: src/etc/rc.d/DAEMON,v 1.5 2004/10/07 13:55:25 mtm Exp $ # $MidnightBSD$ From laffer1 at midnightbsd.org Sat Jan 17 13:26:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:26:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: add sync dhclient Message-ID: <200901171826.n0HIQc0V038715@stargazer.midnightbsd.org> Log Message: ----------- add sync dhclient Modified Files: -------------- src/etc/defaults: rc.conf (r1.20 -> r1.21) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.20 retrieving revision 1.21 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.20 -r1.21 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -100,6 +100,9 @@ dhclient_program="/sbin/dhclient" # Path to dhcp client program. dhclient_flags="" # Additional flags to pass to dhcp client. background_dhclient="NO" # Start dhcp client in the background. +#background_dhclient_fxp0="YES" # Start dhcp client on fxp0 in the background. +synchronous_dhclient="YES" # Start dhclient directly on configured + # interfaces during startup. firewall_enable="YES" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="DESKTOP" # Firewall type (see /etc/rc.firewall) From laffer1 at midnightbsd.org Sat Jan 17 13:37:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:37:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: Add defaults for several daemons. Message-ID: <200901171837.n0HIbcbK039532@stargazer.midnightbsd.org> Log Message: ----------- Add defaults for several daemons. Modified Files: -------------- src/etc/defaults: rc.conf (r1.21 -> r1.22) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.21 retrieving revision 1.22 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.21 -r1.22 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -77,7 +77,7 @@ #geli_da1_autodetach="NO" #geli_mirror_home_flags="-k /etc/geli/home.keys" -geli_swap_flags="-a aes -l 256 -s 4096 -d" # Options for GELI-encrypted +geli_swap_flags="-e aes -l 256 -s 4096 -d" # Options for GELI-encrypted # swap partitions. root_rw_mount="YES" # Set to NO to inhibit remounting root read-write. @@ -98,7 +98,8 @@ hostid_file="/etc/hostid" # File with hostuuid. nisdomainname="NO" # Set to NIS domain if using NIS (or NO). dhclient_program="/sbin/dhclient" # Path to dhcp client program. -dhclient_flags="" # Additional flags to pass to dhcp client. +dhclient_flags="" # Extra flags to pass to dhcp client. +#dhclient_flags_fxp0="" # Extra dhclient flags for fxp0 only background_dhclient="NO" # Start dhcp client in the background. #background_dhclient_fxp0="YES" # Start dhcp client on fxp0 in the background. synchronous_dhclient="YES" # Start dhclient directly on configured @@ -106,9 +107,19 @@ firewall_enable="YES" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="DESKTOP" # Firewall type (see /etc/rc.firewall) -firewall_quiet="YES" # Set to YES to suppress rule display +firewall_quiet="NO" # Set to YES to suppress rule display firewall_logging="NO" # Set to YES to enable events logging firewall_flags="" # Flags passed to ipfw when type is a file +firewall_myservices="" # List of TCP ports on which this host + # offers services +firewall_allowservices="" # List of IPs which has access to + # $firewall_myservices +firewall_trusted="" # List of IPs which has full access to this host +firewall_logdeny="NO" # Set to YES to log default denied incoming + # packets. +firewall_nologports="135-139,445 1026,1027 1433,1434" # List of TCP/UDP ports + # for which denied incoming packets are not + # logged. ip_portrange_first="NO" # Set first dynamically allocated port ip_portrange_last="NO" # Set last dynamically allocated port ike_enable="NO" # Enable IKE daemon (usually racoon or isakmpd) @@ -148,12 +159,11 @@ ftpproxy_flags="" # additional flags for ftp-proxy(8) pfsync_enable="NO" # Expose pf state to other hosts for syncing pfsync_syncdev="" # Interface for pfsync to work through +pfsync_syncpeer="" # IP address of pfsync peer host pfsync_ifconfig="" # Additional options to ifconfig(8) for pfsync tcp_extensions="YES" # Set to NO to turn off RFC1323 extensions. log_in_vain="0" # >=1 to log connects to ports w/o listeners. tcp_keepalive="YES" # Enable stale TCP connection timeout (or NO). -# For the following option you need to have TCP_DROP_SYNFIN set in your -# kernel. Please refer to LINT and NOTES for details. tcp_drop_synfin="NO" # Set to YES to drop TCP packets with SYN+FIN # NOTE: this violates the TCP specification icmp_drop_redirect="NO" # Set to YES to ignore ICMP REDIRECT packets @@ -167,6 +177,9 @@ #ifconfig_fxp0_name="net0" # Change interface name from fxp0 to net0. #ipv4_addrs_fxp0="192.168.0.1/24 192.168.1.1-5/28" # example IPv4 address entry. # +#autobridge_interfaces="bridge0" # List of bridges to check +#autobridge_bridge0="tap* vlan0" # Interface glob to automatically add to the bridge +# # If you have any sppp(4) interfaces above, you might also want to set # the following parameters. Refer to spppcontrol(8) for their meaning. sppp_interfaces="" # List of sppp interfaces. @@ -177,6 +190,10 @@ # Choose correct tunnel addrs. #gifconfig_gif0="10.1.1.1 10.1.2.1" # Examples typically for a router. #gifconfig_gif1="10.1.1.2 10.1.2.2" # Examples typically for a router. +fec_interfaces="" # List of Fast EtherChannels. +#fec_interfaces="fec0 fec1" +#fecconfig_fec0="fxp0 dc0" # Examples typically for two NICs +#fecconfig_fec1="em0 em1 bge0 bge1" # Examples typically for four NICs # User ppp configuration. ppp_enable="NO" # Start user-ppp (or NO). @@ -187,6 +204,12 @@ ppp_profile="papchap" # Which profile to use from /etc/ppp/ppp.conf. ppp_user="root" # Which user to run ppp as +# Start multiple instances of ppp at boot time +#ppp_profile="profile1 profile2 profile3" # Which profiles to use +#ppp_profile1_mode="ddial" # Override ppp mode for profile1 +#ppp_profile2_nat="NO" # Override nat mode for profile2 +# profile3 uses default ppp_mode and ppp_nat + ### Network daemon (miscellaneous) ### hostapd_enable="NO" # Run hostap daemon. syslogd_enable="YES" # Run syslog daemon (or NO). @@ -239,19 +262,24 @@ ### Network daemon (NFS): All need rpcbind_enable="YES" ### amd_enable="NO" # Run amd service with $amd_flags (or NO). +amd_program="/usr/sbin/amd" # path to amd, if you want a different one. amd_flags="-a /.amd_mnt -l syslog /host /etc/amd.map /net /etc/amd.map" amd_map_program="NO" # Can be set to "ypcat -k amd.master" nfs_client_enable="NO" # This host is an NFS client (or NO). nfs_access_cache="60" # Client cache timeout in seconds nfs_server_enable="NO" # This host is an NFS server (or NO). nfs_server_flags="-u -t -n 4" # Flags to nfsd (if enabled). +idmapd_enable="NO" # Run the NFS4 id mapper (YES/NO). +idmapd_flags="" # Additional flags for idmapd. mountd_enable="NO" # Run mountd (or NO). mountd_flags="-r" # Flags to mountd (if NFS server enabled). weak_mountd_authentication="NO" # Allow non-root mount requests to be served. nfs_reserved_port_only="NO" # Provide NFS only on secure port (or NO). nfs_bufpackets="" # bufspace (in packets) for client rpc_lockd_enable="NO" # Run NFS rpc.lockd needed for client/server. +rpc_lockd_flags="" # Flags to rpc.lockd (if enabled). rpc_statd_enable="NO" # Run NFS rpc.statd needed for client/server. +rpc_statd_flags="" # Flags to rpc.statd (if enabled). rpcbind_enable="NO" # Run the portmapper service (YES/NO). rpcbind_program="/usr/sbin/rpcbind" # path to rpcbind, if you want a different one. rpcbind_flags="" # Flags to rpcbind (if enabled). @@ -295,7 +323,11 @@ router_enable="NO" # Set to YES to enable a routing daemon. router="/sbin/routed" # Name of routing daemon to use if enabled. router_flags="-q" # Flags for routing daemon. -mrouted_enable="NO" # Do multicast routing (see /etc/mrouted.conf). +mrouted_enable="NO" # Do IPv4 multicast routing. +mrouted_program="/usr/sbin/mrouted" # Name of IPv4 multicast + # routing daemon. You need to + # install it from package or + # port. mrouted_flags="" # Flags for multicast routing daemon. ipxgateway_enable="NO" # Set to YES to enable IPX routing. ipxrouted_enable="NO" # Set to YES to run the IPX routing daemon. @@ -334,8 +366,8 @@ sdpd_username="nobody" # it initializes bthidd_enable="NO" # Enable bthidd(8) (or NO) -bthidd_config="/etc/bluetooth/bthidd.conf" # bthidd(8) configuration file -bthidd_hids="/var/db/bthidd.hids" # bthidd(8) known HID devices file +bthidd_config="/etc/bluetooth/bthidd.conf" # bthidd(8) configuration file +bthidd_hids="/var/db/bthidd.hids" # bthidd(8) known HID devices file ### Miscellaneous network options: ### icmp_bmcastecho="NO" # respond to broadcast ping packets @@ -424,18 +456,16 @@ saver="NO" # screen saver: Uses /boot/kernel/${saver}_saver.ko moused_nondefault_enable="YES" # Treat non-default mice as enabled unless # specifically overriden in rc.conf(5). -moused_enable="YES" # Run the mouse daemon. +moused_enable="NO" # Run the mouse daemon. moused_type="auto" # See man page for rc.conf(5) for available settings. moused_port="/dev/psm0" # Set to your mouse port. moused_flags="" # Any additional flags to moused. mousechar_start="NO" # if 0xd0-0xd3 default range is occupied in your # language code table, specify alternative range # start like mousechar_start=3, see vidcontrol(1) -allscreens_flags="-t off" # Set this vidcontrol mode for all virtual - # screens +allscreens_flags="" # Set this vidcontrol mode for all virtual screens allscreens_kbdflags="" # Set this kbdcontrol mode for all virtual screens - ############################################################## ### Mail Transfer Agent (MTA) options ###################### ############################################################## @@ -455,7 +485,7 @@ sendmail_msp_queue_enable="YES" # Dequeue stuck clientmqueue mail (YES/NO). sendmail_msp_queue_flags="-L sm-msp-queue -Ac -q30m" # Flags for sendmail_msp_queue daemon. -sendmail_rebuild_aliases="NO" # will not rebuild aliases on startup automatically +sendmail_rebuild_aliases="NO" # Run newaliases if necessary (YES/NO). ############################################################## @@ -469,17 +499,20 @@ cron_program="/usr/sbin/cron" # Which cron executable to run (if enabled). cron_dst="YES" # Handle DST transitions intelligently (YES/NO) cron_flags="" # Which options to pass to the cron daemon. -nscd_enable="NO" # Run the nsswitch caching daemon. lpd_enable="NO" # Run the line printer daemon. lpd_program="/usr/sbin/lpd" # path to lpd, if you want a different one. lpd_flags="" # Flags to lpd (if enabled). +nscd_enable="NO" # Run the nsswitch caching daemon. chkprintcap_enable="NO" # Run chkprintcap(8) before running lpd. chkprintcap_flags="-d" # Create missing directories by default. -dumpdev="NO" # Device to crashdump to (device name, AUTO, or NO). +dumpdev="AUTO" # Device to crashdump to (device name, AUTO, or NO). dumpdir="/var/crash" # Directory where crash dumps are to be stored savecore_flags="" # Used if dumpdev is enabled above, and present. enable_quotas="NO" # turn on quotas on startup (or NO). check_quotas="YES" # Check quotas on startup (or NO). +quotaon_flags="-a" # Turn quotas on for all file systems (if enabled) +quotaoff_flags="-a" # Turn quotas off for all file systems at shutdown +quotacheck_flags="-a" # Check all file system quotas (if enabled) accounting_enable="NO" # Turn on process accounting (or NO). ibcs2_enable="NO" # Ibcs2 (SCO) emulation loaded at startup (or NO). ibcs2_loaders="coff" # List of additional Ibcs2 loaders (or NO). @@ -547,12 +580,19 @@ # # To use rc's built-in jail infrastructure create entries for # each jail, specified in jail_list, with the following variables. -# NOTE: replace 'example' with the jail's name. +# NOTES: +# - replace 'example' with the jail's name. +# - except rootdir, hostname and ip, all of the following variables may be made +# global jail variables if you don't specify a jail name (ie. jail_interface). # #jail_example_rootdir="/usr/jail/default" # Jail's root directory #jail_example_hostname="default.domain.com" # Jail's hostname #jail_example_ip="192.168.0.10" # Jail's IP number +#jail_example_interface="" # Interface to create the IP alias on #jail_example_exec_start="/bin/sh /etc/rc" # command to execute in jail for starting +#jail_example_exec_afterstart0="/bin/sh command" # command to execute after the one for + # starting the jail. More than one can be + # specified using a trailing number #jail_example_exec_stop="/bin/sh /etc/rc.shutdown" # command to execute in jail for stopping #jail_example_devfs_enable="NO" # mount devfs in the jail #jail_example_fdescfs_enable="NO" # mount fdescfs in the jail From laffer1 at midnightbsd.org Sat Jan 17 13:42:03 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:42:03 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: Make the firewall quiet Message-ID: <200901171842.n0HIg3wh040053@stargazer.midnightbsd.org> Log Message: ----------- Make the firewall quiet Modified Files: -------------- src/etc/defaults: rc.conf (r1.22 -> r1.23) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.22 retrieving revision 1.23 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.22 -r1.23 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -107,7 +107,7 @@ firewall_enable="YES" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="DESKTOP" # Firewall type (see /etc/rc.firewall) -firewall_quiet="NO" # Set to YES to suppress rule display +firewall_quiet="YES" # Set to YES to suppress rule display firewall_logging="NO" # Set to YES to enable events logging firewall_flags="" # Flags passed to ipfw when type is a file firewall_myservices="" # List of TCP ports on which this host From laffer1 at midnightbsd.org Sat Jan 17 13:43:39 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:43:39 -0500 (EST) Subject: [Midnightbsd-cvs] src: sbin/gpt: update gpt(8) Message-ID: <200901171843.n0HIhdbL040175@stargazer.midnightbsd.org> Log Message: ----------- update gpt(8) Modified Files: -------------- src/sbin/gpt: Makefile (r1.1.1.1 -> r1.2) add.c (r1.1.1.1 -> r1.2) create.c (r1.1.1.1 -> r1.2) destroy.c (r1.1.1.1 -> r1.2) gpt.8 (r1.1.1.1 -> r1.2) gpt.c (r1.1.1.1 -> r1.2) gpt.h (r1.1.1.1 -> r1.2) label.c (r1.1.1.1 -> r1.2) map.c (r1.1.1.1 -> r1.2) map.h (r1.1.1.1 -> r1.2) migrate.c (r1.1.1.1 -> r1.2) recover.c (r1.1.1.1 -> r1.2) remove.c (r1.1.1.1 -> r1.2) show.c (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: show.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/show.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/show.c -L sbin/gpt/show.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/show.c +++ sbin/gpt/show.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/show.c,v 1.11.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/show.c,v 1.14 2006/06/22 22:22:32 marcel Exp $"); #include @@ -57,6 +57,7 @@ static uuid_t efi_slice = GPT_ENT_TYPE_EFI; static uuid_t mslinux = GPT_ENT_TYPE_MS_BASIC_DATA; static uuid_t freebsd = GPT_ENT_TYPE_FREEBSD; + static uuid_t hfs = GPT_ENT_TYPE_APPLE_HFS; static uuid_t linuxswap = GPT_ENT_TYPE_LINUX_SWAP; static uuid_t msr = GPT_ENT_TYPE_MS_RESERVED; static uuid_t swap = GPT_ENT_TYPE_FREEBSD_SWAP; @@ -85,6 +86,8 @@ return ("Linux swap"); if (uuid_equal(t, &msr, NULL)) return ("Windows reserved"); + if (uuid_equal(t, &hfs, NULL)) + return ("Apple HFS"); unfriendly: uuid_to_string(t, &s, NULL); Index: create.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/create.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/create.c -L sbin/gpt/create.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/create.c +++ sbin/gpt/create.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/create.c,v 1.10.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/create.c,v 1.11 2005/08/31 01:47:19 marcel Exp $"); #include Index: gpt.h =================================================================== RCS file: /home/cvs/src/sbin/gpt/gpt.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/gpt.h -L sbin/gpt/gpt.h -u -r1.1.1.1 -r1.2 --- sbin/gpt/gpt.h +++ sbin/gpt/gpt.h @@ -23,7 +23,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sbin/gpt/gpt.h,v 1.7.2.1 2005/09/06 23:59:01 marcel Exp $ + * $FreeBSD: src/sbin/gpt/gpt.h,v 1.11 2006/06/22 22:05:28 marcel Exp $ */ #ifndef _GPT_H_ @@ -36,6 +36,7 @@ void le_uuid_dec(void const *, uuid_t *); void le_uuid_enc(void *, uuid_t const *); +int parse_uuid(const char *, uuid_t *); struct mbr_part { uint8_t part_flag; /* bootstrap flags */ Index: map.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/map.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/map.c -L sbin/gpt/map.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/map.c +++ sbin/gpt/map.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/map.c,v 1.5.8.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/map.c,v 1.6 2005/08/31 01:47:19 marcel Exp $"); #include #include Index: label.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/label.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/label.c -L sbin/gpt/label.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/label.c +++ sbin/gpt/label.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/label.c,v 1.1.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/label.c,v 1.3 2006/10/04 18:20:25 marcel Exp $"); #include @@ -172,7 +172,6 @@ { char *p; int ch, fd; - uint32_t status; /* Get the label options */ while ((ch = getopt(argc, argv, "ab:f:i:l:s:t:")) != -1) { @@ -185,7 +184,7 @@ case 'b': if (block > 0) usage_label(); - block = strtol(optarg, &p, 10); + block = strtoll(optarg, &p, 10); if (*p != 0 || block < 1) usage_label(); break; @@ -209,31 +208,15 @@ case 's': if (size > 0) usage_label(); - size = strtol(optarg, &p, 10); + size = strtoll(optarg, &p, 10); if (*p != 0 || size < 1) usage_label(); break; case 't': if (!uuid_is_nil(&type, NULL)) usage_label(); - uuid_from_string(optarg, &type, &status); - if (status != uuid_s_ok) { - if (strcmp(optarg, "efi") == 0) { - uuid_t efi = GPT_ENT_TYPE_EFI; - type = efi; - } else if (strcmp(optarg, "swap") == 0) { - uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; - type = sw; - } else if (strcmp(optarg, "ufs") == 0) { - uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; - type = ufs; - } else if (strcmp(optarg, "linux") == 0 || - strcmp(optarg, "windows") == 0) { - uuid_t m = GPT_ENT_TYPE_MS_BASIC_DATA; - type = m; - } else - usage_label(); - } + if (parse_uuid(optarg, &type) != 0) + usage_label(); break; default: usage_label(); Index: remove.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/remove.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/remove.c -L sbin/gpt/remove.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/remove.c +++ sbin/gpt/remove.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/remove.c,v 1.4.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/remove.c,v 1.10 2006/10/04 18:20:25 marcel Exp $"); #include @@ -143,7 +143,6 @@ { char *p; int ch, fd; - uint32_t status; /* Get the remove options */ while ((ch = getopt(argc, argv, "ab:i:s:t:")) != -1) { @@ -156,7 +155,7 @@ case 'b': if (block > 0) usage_remove(); - block = strtol(optarg, &p, 10); + block = strtoll(optarg, &p, 10); if (*p != 0 || block < 1) usage_remove(); break; @@ -170,31 +169,15 @@ case 's': if (size > 0) usage_remove(); - size = strtol(optarg, &p, 10); + size = strtoll(optarg, &p, 10); if (*p != 0 || size < 1) usage_remove(); break; case 't': if (!uuid_is_nil(&type, NULL)) usage_remove(); - uuid_from_string(optarg, &type, &status); - if (status != uuid_s_ok) { - if (strcmp(optarg, "efi") == 0) { - uuid_t efi = GPT_ENT_TYPE_EFI; - type = efi; - } else if (strcmp(optarg, "swap") == 0) { - uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; - type = sw; - } else if (strcmp(optarg, "ufs") == 0) { - uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; - type = ufs; - } else if (strcmp(optarg, "linux") == 0 || - strcmp(optarg, "windows") == 0) { - uuid_t m = GPT_ENT_TYPE_MS_BASIC_DATA; - type = m; - } else - usage_remove(); - } + if (parse_uuid(optarg, &type) != 0) + usage_remove(); break; default: usage_remove(); Index: gpt.8 =================================================================== RCS file: /home/cvs/src/sbin/gpt/gpt.8,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/gpt.8 -L sbin/gpt/gpt.8 -u -r1.1.1.1 -r1.2 --- sbin/gpt/gpt.8 +++ sbin/gpt/gpt.8 @@ -22,9 +22,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/sbin/gpt/gpt.8,v 1.13.2.1 2005/09/06 23:59:01 marcel Exp $ +.\" $FreeBSD: src/sbin/gpt/gpt.8,v 1.17 2006/06/22 22:22:32 marcel Exp $ .\" -.Dd August 31, 2005 +.Dd June 22, 2006 .Os .Dt GPT 8 .Sh NAME @@ -130,7 +130,7 @@ The type is given as an UUID, but .Nm accepts -.Cm efi , swap , ufs , linux +.Cm efi , swap , ufs , hfs , linux and .Cm windows as aliases for the most commonly used partition types. @@ -224,7 +224,9 @@ option is used to read the label from the specified file. Only the first line is read from the file and the trailing newline character is stripped. -If the file name is the dash or minus sign (-), the label is read from +If the file name is the dash or minus sign +.Pq Fl , +the label is read from the standard input. The .Fl l Ar label @@ -286,7 +288,7 @@ The option has no effect on non-GPT partitions. With the .Fl u -option the GPT partition type is displayed as an UUID instead of in an +option the GPT partition type is displayed as an UUID instead of in a user friendly form. The .Fl l Index: gpt.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/gpt.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/gpt.c -L sbin/gpt/gpt.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/gpt.c +++ sbin/gpt/gpt.c @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/gpt.c,v 1.10.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/gpt.c,v 1.16.2.1 2007/11/09 02:29:43 jhb Exp $"); #include #include @@ -258,6 +258,62 @@ p[10 + i] = uuid->node[i]; } +int +parse_uuid(const char *s, uuid_t *uuid) +{ + uint32_t status; + + uuid_from_string(s, uuid, &status); + if (status == uuid_s_ok) + return (0); + + switch (*s) { + case 'e': + if (strcmp(s, "efi") == 0) { + uuid_t efi = GPT_ENT_TYPE_EFI; + *uuid = efi; + return (0); + } + break; + case 'h': + if (strcmp(s, "hfs") == 0) { + uuid_t hfs = GPT_ENT_TYPE_APPLE_HFS; + *uuid = hfs; + return (0); + } + break; + case 'l': + if (strcmp(s, "linux") == 0) { + uuid_t lnx = GPT_ENT_TYPE_MS_BASIC_DATA; + *uuid = lnx; + return (0); + } + break; + case 's': + if (strcmp(s, "swap") == 0) { + uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; + *uuid = sw; + return (0); + } + break; + case 'u': + if (strcmp(s, "ufs") == 0) { + uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; + *uuid = ufs; + return (0); + } + break; + case 'w': + if (strcmp(s, "windows") == 0) { + uuid_t win = GPT_ENT_TYPE_MS_BASIC_DATA; + *uuid = win; + return (0); + } + break; + } + return (EINVAL); +} + void* gpt_read(int fd, off_t lba, size_t count) { @@ -529,10 +585,16 @@ if (gpt_mbr(fd, 0LL) == -1) goto close; - if (gpt_gpt(fd, 1LL) == -1) - goto close; - if (gpt_gpt(fd, mediasz / secsz - 1LL) == -1) - goto close; + + /* + * Don't look for a GPT unless we have a valid PMBR. + */ + if (map_find(MAP_TYPE_PMBR) != NULL) { + if (gpt_gpt(fd, 1LL) == -1) + goto close; + if (gpt_gpt(fd, mediasz / secsz - 1LL) == -1) + goto close; + } return (fd); Index: recover.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/recover.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/recover.c -L sbin/gpt/recover.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/recover.c +++ sbin/gpt/recover.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/recover.c,v 1.7.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/recover.c,v 1.8 2005/08/31 01:47:19 marcel Exp $"); #include Index: map.h =================================================================== RCS file: /home/cvs/src/sbin/gpt/map.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/map.h -L sbin/gpt/map.h -u -r1.1.1.1 -r1.2 --- sbin/gpt/map.h +++ sbin/gpt/map.h @@ -23,7 +23,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sbin/gpt/map.h,v 1.5.8.1 2005/09/06 23:59:01 marcel Exp $ + * $FreeBSD: src/sbin/gpt/map.h,v 1.6 2005/08/31 01:47:19 marcel Exp $ */ #ifndef _MAP_H_ Index: migrate.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/migrate.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/migrate.c -L sbin/gpt/migrate.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/migrate.c +++ sbin/gpt/migrate.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/migrate.c,v 1.13.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/migrate.c,v 1.16 2005/09/01 02:42:52 marcel Exp $"); #include #include Index: Makefile =================================================================== RCS file: /home/cvs/src/sbin/gpt/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/Makefile -L sbin/gpt/Makefile -u -r1.1.1.1 -r1.2 --- sbin/gpt/Makefile +++ sbin/gpt/Makefile @@ -1,4 +1,4 @@ -# $FreeBSD: src/sbin/gpt/Makefile,v 1.6.8.1 2005/09/06 23:59:01 marcel Exp $ +# $FreeBSD: src/sbin/gpt/Makefile,v 1.7 2005/09/01 02:49:20 marcel Exp $ PROG= gpt SRCS= add.c create.c destroy.c gpt.c label.c map.c migrate.c recover.c \ Index: add.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/add.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/add.c -L sbin/gpt/add.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/add.c +++ sbin/gpt/add.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/add.c,v 1.11.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/add.c,v 1.15 2006/10/04 18:20:25 marcel Exp $"); #include @@ -156,7 +156,6 @@ { char *p; int ch, fd; - uint32_t status; /* Get the migrate options */ while ((ch = getopt(argc, argv, "b:i:s:t:")) != -1) { @@ -164,7 +163,7 @@ case 'b': if (block > 0) usage_add(); - block = strtol(optarg, &p, 10); + block = strtoll(optarg, &p, 10); if (*p != 0 || block < 1) usage_add(); break; @@ -178,31 +177,15 @@ case 's': if (size > 0) usage_add(); - size = strtol(optarg, &p, 10); + size = strtoll(optarg, &p, 10); if (*p != 0 || size < 1) usage_add(); break; case 't': if (!uuid_is_nil(&type, NULL)) usage_add(); - uuid_from_string(optarg, &type, &status); - if (status != uuid_s_ok) { - if (strcmp(optarg, "efi") == 0) { - uuid_t efi = GPT_ENT_TYPE_EFI; - type = efi; - } else if (strcmp(optarg, "swap") == 0) { - uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; - type = sw; - } else if (strcmp(optarg, "ufs") == 0) { - uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; - type = ufs; - } else if (strcmp(optarg, "linux") == 0 || - strcmp(optarg, "windows") == 0) { - uuid_t m = GPT_ENT_TYPE_MS_BASIC_DATA; - type = m; - } else - usage_add(); - } + if (parse_uuid(optarg, &type) != 0) + usage_add(); break; default: usage_add(); Index: destroy.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/destroy.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/destroy.c -L sbin/gpt/destroy.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/destroy.c +++ sbin/gpt/destroy.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/destroy.c,v 1.5.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/destroy.c,v 1.6 2005/08/31 01:47:19 marcel Exp $"); #include From laffer1 at midnightbsd.org Sat Jan 17 17:23:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 17:23:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: ramdisk and ramdisk-own -> mdconfig and mdconfig2 statd Message-ID: <200901172223.n0HMNtmP058758@stargazer.midnightbsd.org> Log Message: ----------- ramdisk and ramdisk-own -> mdconfig and mdconfig2 statd is from nfslocking Modified Files: -------------- src/etc/rc.d: Makefile (r1.15 -> r1.16) Added Files: ----------- src/etc/rc.d: mdconfig (r1.1) mdconfig2 (r1.1) statd (r1.1) Removed Files: ------------- src/etc/rc.d: ramdisk ramdisk-own -------------- next part -------------- --- etc/rc.d/ramdisk +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2004 The FreeBSD Project -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/etc/rc.d/ramdisk,v 1.4 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD: src/etc/rc.d/ramdisk,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: ramdisk -# REQUIRE: localswap -# BEFORE: mountcritlocal - -. /etc/rc.subr - -name="ramdisk" -stop_cmd="ramdisk_stop" -start_cmd="ramdisk_start" - -ramdisk_start() -{ - for unit in $ramdisk_units; do - eval mdoptions=\$ramdisk_${unit}_config - if [ "$mdoptions" = "${mdoptions##-t}" ]; then - echo "Type not specified for md$unit" - continue - fi - eval fsoptions=\$ramdisk_${unit}_newfs - - mdconfig -a $mdoptions -u $unit - newfs $fsoptions /dev/md$unit - done -} - -ramdisk_stop() -{ - for unit in $ramdisk_units - do - if [ -c /dev/md$unit ]; then - umount -f /dev/md$unit > /dev/null 2>&1 - mdconfig -d -u $unit - fi - done -} - -load_rc_config $name -run_rc_command "$1" - --- /dev/null +++ etc/rc.d/statd @@ -0,0 +1,43 @@ +#!/bin/sh +# +# FreeBSD History: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm Exp +# $FreeBSD: src/etc/rc.d/statd,v 1.17.6.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD: src/etc/rc.d/statd,v 1.1 2009/01/17 22:23:54 laffer1 Exp $ + +# PROVIDE: statd +# REQUIRE: nfsserver nfsclient nfsd rpcbind +# BEFORE: DAEMON +# KEYWORD: nojail + +. /etc/rc.subr + +name="statd" +rcvar=rpc_statd_enable +command="/usr/sbin/rpc.${name}" +start_precmd='statd_precmd' +stop_precmd='checkyesno nfs_server_enable || checkyesno nfs_client_enable' +status_precmd=$stop_precmd + +# Make sure that we are either an NFS client or server, and that we get +# the correct flags from rc.conf(5). +# +statd_precmd() +{ + local ret + ret=0 + + if ! checkyesno nfs_server_enable && ! checkyesno nfs_client_enable + then + ret=1 + fi + if ! checkyesno rpcbind_enable && \ + ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1 + then + force_depend rpcbind || ret=1 + fi + rc_flags=${rpc_statd_flags} + return ${ret} +} + +load_rc_config $name +run_rc_command $1 --- /dev/null +++ etc/rc.d/mdconfig @@ -0,0 +1,198 @@ +#!/bin/sh +# +# Copyright (c) 2006 The FreeBSD Project +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $FreeBSD: src/etc/rc.d/mdconfig,v 1.5 2007/08/25 00:19:17 matteo Exp $ +# $MidnightBSD: src/etc/rc.d/mdconfig,v 1.1 2009/01/17 22:23:54 laffer1 Exp $ + +# PROVIDE: mdconfig +# REQUIRE: localswap +# BEFORE: mountcritlocal + +. /etc/rc.subr + +name="mdconfig" +stop_cmd="mdconfig_stop" +start_cmd="mdconfig_start" +start_precmd='[ -n "${_mdconfig_list}" ]' +required_modules="geom_md:g_md" + +is_readonly() +{ + local _mp _ret + + _mp=$1 + _ret=`mount | while read _line; do + case ${_line} in + *" ${_mp} "*read-only*) + echo "yes" + ;; + + *) + ;; + esac; + done` + + if [ -n "${_ret}" ]; then + return 0 + else + return 1 + fi +} + +init_variables() +{ + local _i + + _fs="" + _mp="" + _dev="/dev/${_md}" + eval _config=\$mdconfig_${_md} + eval _newfs=\$mdconfig_${_md}_newfs + + _type=${_config##*-t\ } + _type=${_type%%\ *} + if [ -z "${_type}" ]; then + err 1 "You need to specify \"-t \" in mdconfig_${_md}" + fi + + if [ "${_type}" = "vnode" ]; then + _file=${_config##*-f\ } + _file=${_file%%\ *} + if [ -z "${_file}" ]; then + err 2 "You need to specify \"-f \" in mdconfig_${_md} for vnode devices" + fi + if [ "${_file}" != "${_file%.uzip}" ]; then + _dev="/dev/${_md}.uzip" + fi + for _i in `df ${_file} 2>/dev/null`; do _fs=${_i}; done + fi + + # Debugging help. + debug "${_md} config: ${_config}" + debug "${_md} type: ${_type}" + debug "${_md} dev: ${_dev}" + debug "${_md} file: ${_file}" + debug "${_md} fs: ${_fs}" + debug "${_md} newfs flags: ${_newfs}" +} + +mdconfig_start() +{ + local _md _mp _config _type _dev _file _fs _newfs _fsck_cmd + + for _md in ${_mdconfig_list}; do + init_variables ${_md} + # Create md(4) devices of types swap, malloc and vnode if the + # file is on the root partition. + if [ "${_type}" != "vnode" -o "${_fs}" = "/" ]; then + if [ "${_type}" = "vnode" ]; then + if is_readonly ${_fs}; then + warn "${_fs} is mounted read-only, skipping ${_md}." + continue + fi + if [ "${_file}" != "${_file%.uzip}" ]; then + load_kld -m g_uzip geom_uzip || return 3 + # sleep a bit to allow creation of /dev/mdX.uzip + sleep 2 + fi + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + err 3 "${_md} already exists" + fi + echo "Creating ${_md} device (${_type})." + if ! mdconfig -a ${_config} -u ${_md}; then + echo "Creating ${_md} device failed, moving on." + continue + fi + # Skip fsck for uzip devices. + if [ "${_type}" = "vnode" ]; then + if [ "${_file}" != "${_file%.uzip}" ]; then + _fsck_cmd=":" + elif checkyesno background_fsck; then + _fsck_cmd="fsck -F" + else + _fsck_cmd="fsck" + fi + if ! eval ${_fsck_cmd} -p ${_dev} >/dev/null; then + echo "Fsck failed on ${_dev}, not mounting the filesystem." + continue + + fi + else + newfs ${_newfs} ${_dev} >/dev/null + fi + if mount -d ${_dev} 2>&1 >/dev/null; then + echo "Mounting ${_dev}." + mount ${_dev} + fi + fi + done +} + +mdconfig_stop() +{ + local _md _mp _config _type _dev _file _fs _newfs _i + + for _md in ${_mdconfig_list}; do + init_variables ${_md} + if [ "${_type}" != "vnode" -o "${_fs}" = "/" ]; then + for _i in `df ${_dev} 2>/dev/null`; do _mp=${_i}; done + if [ -z "${_mp}" -o "${_mp}" != "${_mp%%%}" ]; then + echo "Device ${_dev} isn't mounted." + else + echo "Umounting ${_dev}." + umount ${_dev} + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + echo "Destroying ${_md}." + mdconfig -d -u ${_md} + fi + fi + done +} + +_mdconfig_cmd="$1" +if [ $# -gt 0 ]; then + shift +fi +[ -n "$*" ] && _mdconfig_list="$*" + +load_rc_config $name + +_mdconfig_unit=0 +if [ -z "${_mdconfig_list}" ]; then + while :; do + eval _mdconfig_config=\$mdconfig_md${_mdconfig_unit} + if [ -z "${_mdconfig_config}" ]; then + break + else + _mdconfig_list="${_mdconfig_list}${_mdconfig_list:+ }md${_mdconfig_unit}" + _mdconfig_unit=$((${_mdconfig_unit} + 1)) + fi + done +fi + +run_rc_command "${_mdconfig_cmd}" --- etc/rc.d/ramdisk-own +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2004 The FreeBSD Project -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/etc/rc.d/ramdisk-own,v 1.4 2004/11/16 04:14:28 wes Exp $ -# $MidnightBSD: src/etc/rc.d/ramdisk-own,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: ramdisk-own -# REQUIRE: ramdisk mountcritlocal -# BEFORE: SERVERS - -. /etc/rc.subr - -name="ramdisk" -stop_cmd=":" -start_cmd="ramdisk_own_start" - -ramdisk_own_start() -{ - for unit in $ramdisk_units; do - device="/dev/md$unit" - dir=`mount | grep $device | cut -d' ' -f3` - - eval owner=\$ramdisk_${unit}_owner - eval perms=\$ramdisk_${unit}_perms - - [ "X$owner" != "X" ] && chown -f "$owner" $device $dir - [ "X$perms" != "X" ] && chmod -f "$perms" /dev/md$unit $dir - done -} - -load_rc_config $name -run_rc_command "$1" - Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.15 -r1.16 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -22,7 +22,7 @@ kadmind kerberos kernel keyserv kldxref kpasswdd \ ldconfig local localpkg lockd lpd \ mixer motd mountcritlocal mountcritremote mountlate \ - mountd moused mroute6d mrouted msgs \ + mdconfig mdconfig2 mountd moused mroute6d mrouted msgs \ named natd netif netoptions \ network_ipv6 newsyslog nfsclient nfsd \ nfsserver nisdomain nsswitch ntpd \ @@ -30,10 +30,10 @@ pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ quota \ - ramdisk ramdisk-own random rarpd rdate resolv root \ + random rarpd rdate resolv root \ route6d routed routing rpcbind rtadvd rwho \ savecore sdpd securelevel sendmail \ - serial sound sppp swap1 \ + serial sound sppp statd swap1 \ syscons sysctl syslogd \ timed tmp \ ugidfw \ --- /dev/null +++ etc/rc.d/mdconfig2 @@ -0,0 +1,227 @@ +#!/bin/sh +# +# Copyright (c) 2006 The FreeBSD Project +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $FreeBSD: src/etc/rc.d/mdconfig2,v 1.4 2006/12/31 10:37:18 yar Exp $ +# $MidnightBSD: src/etc/rc.d/mdconfig2,v 1.1 2009/01/17 22:23:54 laffer1 Exp $ + +# PROVIDE: mdconfig2 +# REQUIRE: mountcritremote +# BEFORE: SERVERS + +. /etc/rc.subr + +name="mdconfig2" +stop_cmd="mdconfig2_stop" +start_cmd="mdconfig2_start" +start_precmd='[ -n "${_mdconfig2_list}" ]' +required_modules="geom_md:g_md" + +is_readonly() +{ + local _mp _ret + + _mp=$1 + _ret=`mount | while read _line; do + case ${_line} in + *" ${_mp} "*read-only*) + echo "yes" + ;; + + *) + ;; + esac; + done` + + if [ -n "${_ret}" ]; then + return 0 + else + return 1 + fi +} + +init_variables() +{ + local _i + + _fs="" + _mp="" + _mounted="no" + _dev="/dev/${_md}" + eval _config=\$mdconfig_${_md} + eval _owner=\$mdconfig_${_md}_owner + eval _perms=\$mdconfig_${_md}_perms + eval _files=\$mdconfig_${_md}_files + eval _populate=\$mdconfig_${_md}_cmd + + _type=${_config##*-t\ } + _type=${_type%%\ *} + if [ -z "${_type}" ]; then + err 1 "You need to specify \"-t \" in mdconfig_${_md}" + fi + + if [ "${_type}" = "vnode" ]; then + _file=${_config##*-f\ } + _file=${_file%%\ *} + if [ -z "${_file}" ]; then + err 2 "You need to specify \"-f \" in mdconfig_${_md} for vnode devices" + fi + + if [ "${_file}" != "${_file%.uzip}" ]; then + _dev="/dev/${_md}.uzip" + fi + for _i in `df ${_file} 2>/dev/null`; do _fs=${_i}; done + fi + + # Debugging help. + debug "${_md} config: ${_config}" + debug "${_md} type: ${_type}" + debug "${_md} dev: ${_dev}" + debug "${_md} file: ${_file}" + debug "${_md} fs: ${_fs}" + debug "${_md} owner: ${_owner}" + debug "${_md} perms: ${_perms}" + debug "${_md} files: ${_files}" + debug "${_md} populate cmd: ${_populate}" +} + +mdconfig2_start() +{ + local _md _fs _mp _mounted _dev _config _type _file _owner _perms _files _populate _fsck_cmd _i + + for _md in ${_mdconfig2_list}; do + init_variables ${_md} + if [ ! -r ${_file} ]; then + err 3 "${_file} doesn't exist" + continue + fi + # First pass: create md(4) vnode devices from files stored on + # non-root partition. Swap and malloc md(4) devices have already + # been created. + if [ "${_type}" = "vnode" -a "${_fs}" != "/" ]; then + if [ "${_file}" != "${_file%.uzip}" ]; then + load_kld -m g_uzip geom_uzip || return 3 + fi + if is_readonly ${_fs}; then + warn "${_fs} is mounted read-only, skipping ${_md}." + continue + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + err 3 "${_md} already exists" + fi + echo "Creating ${_md} device (${_type})." + if ! mdconfig -a ${_config} -u ${_md}; then + echo "Creating ${_md} device failed, moving on." + continue + fi + # Skip fsck for uzip devices. + if [ "${_file}" != "${_file%.uzip}" ]; then + _fsck_cmd=":" + elif checkyesno background_fsck; then + _fsck_cmd="fsck -F" + else + _fsck_cmd="fsck" + fi + if ! eval ${_fsck_cmd} -p ${_dev} >/dev/null; then + echo "Fsck failed on ${_dev}, not mounting the filesystem." + continue + fi + if mount -d ${_dev} >/dev/null 2>&1; then + echo "Mounting ${_dev}." + mount ${_dev} + fi + fi + + for _i in `df ${_dev} 2>/dev/null`; do _mp=${_i}; done + if [ ! -z "${_mp}" -a "${_mp}" = "${_mp%%%}" ]; then + _mounted="yes" + fi + + if checkyesno _mounted; then + # Second pass: change permissions and ownership. + [ -z "${_owner}" ] || chown -f ${_owner} ${_dev} ${_mp} + [ -z "${_perms}" ] || chmod -f ${_perms} ${_dev} ${_mp} + + # Third pass: populate with foreign files. + if [ -n "${_files}" -o -n "${_populate}" ]; then + echo "Populating ${_dev}." + fi + if [ -n "${_files}" ]; then + cp -Rp ${_files} ${_mp} + fi + if [ -n "${_populate}" ]; then + eval ${_populate} + fi + fi + done +} + +mdconfig2_stop() +{ + local _md _fs _mp _mounted _dev _config _type _file _owner _perms _files _populate + + for _md in ${_mdconfig2_list}; do + init_variables ${_md} + if [ "${_type}" = "vnode" ]; then + for i in `df ${_dev} 2>/dev/null`; do _mp=$i; done + if [ ! -r "${_file}" -o "${_fs}" = "/" ]; then + continue + fi + if [ -z "${_mp}" -o "${_mp}" != "${_mp%%%}" ]; then + echo "Device ${_dev} isn't mounted." + else + echo "Umounting ${_dev}." + umount ${_dev} + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + echo "Destroying ${_md}." + mdconfig -d -u ${_md} + fi + fi + done +} + +_mdconfig2_cmd="$1" +if [ $# -gt 0 ]; then + shift +fi +[ -n "$*" ] && _mdconfig2_list="$*" + +load_rc_config $name + +_mdconfig2_unit=0 +if [ -z "${_mdconfig2_list}" ]; then + while :; do + eval _mdconfig2_config=\$mdconfig_md${_mdconfig2_unit} + if [ -z "${_mdconfig2_config}" ]; then + break + else + _mdconfig2_list="${_mdconfig2_list}${_mdconfig2_list:+ }md${_mdconfig2_unit}" + _mdconfig2_unit=$((${_mdconfig2_unit} + 1)) + fi + done +fi + +run_rc_command "${_mdconfig2_cmd}" From laffer1 at midnightbsd.org Sat Jan 17 19:00:27 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:00:27 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: disable dumpdev since we encrypt swap. Message-ID: <200901180000.n0I00RZZ067541@stargazer.midnightbsd.org> Log Message: ----------- disable dumpdev since we encrypt swap. (regression fix) Modified Files: -------------- src/etc/defaults: rc.conf (r1.23 -> r1.24) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.23 retrieving revision 1.24 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.23 -r1.24 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -505,7 +505,7 @@ nscd_enable="NO" # Run the nsswitch caching daemon. chkprintcap_enable="NO" # Run chkprintcap(8) before running lpd. chkprintcap_flags="-d" # Create missing directories by default. -dumpdev="AUTO" # Device to crashdump to (device name, AUTO, or NO). +dumpdev="NO" # Device to crashdump to (device name, AUTO, or NO). dumpdir="/var/crash" # Directory where crash dumps are to be stored savecore_flags="" # Used if dumpdev is enabled above, and present. enable_quotas="NO" # turn on quotas on startup (or NO). From laffer1 at midnightbsd.org Sat Jan 17 19:02:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:02:19 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: tag Message-ID: <200901180002.n0I02Jfx067618@stargazer.midnightbsd.org> Log Message: ----------- tag Modified Files: -------------- src/sys/modules/ibcs2: Makefile (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/ibcs2/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/modules/ibcs2/Makefile -L sys/modules/ibcs2/Makefile -u -r1.1.1.1 -r1.2 --- sys/modules/ibcs2/Makefile +++ sys/modules/ibcs2/Makefile @@ -1,3 +1,4 @@ +# $MidnightBSD$ # $FreeBSD: src/sys/modules/ibcs2/Makefile,v 1.34 2002/08/12 07:20:15 alfred Exp $ .PATH: ${.CURDIR}/../../i386/ibcs2 From laffer1 at midnightbsd.org Sat Jan 17 19:04:40 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:04:40 -0500 (EST) Subject: [Midnightbsd-cvs] src: sysctl: enclose in quotes Message-ID: <200901180004.n0I04eJE067703@stargazer.midnightbsd.org> Log Message: ----------- enclose in quotes Modified Files: -------------- src/etc/rc.d: sysctl (r1.3 -> r1.4) -------------- next part -------------- Index: sysctl =================================================================== RCS file: /home/cvs/src/etc/rc.d/sysctl,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/sysctl -L etc/rc.d/sysctl -u -r1.3 -r1.4 --- etc/rc.d/sysctl +++ etc/rc.d/sysctl @@ -36,7 +36,7 @@ ${val}) ;; *) - sysctl ${var} + sysctl "${var}" ;; esac elif [ "$1" = "last" ]; then From laffer1 at midnightbsd.org Sat Jan 17 19:08:33 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:08:33 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add stop command and fix lowest power profile testing Message-ID: <200901180008.n0I08Xp7068092@stargazer.midnightbsd.org> Log Message: ----------- add stop command and fix lowest power profile testing Modified Files: -------------- src/etc/rc.d: ipnat (r1.2 -> r1.3) power_profile (r1.3 -> r1.4) -------------- next part -------------- Index: power_profile =================================================================== RCS file: /home/cvs/src/etc/rc.d/power_profile,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/power_profile -L etc/rc.d/power_profile -u -r1.3 -r1.4 --- etc/rc.d/power_profile +++ etc/rc.d/power_profile @@ -16,6 +16,7 @@ . /etc/rc.subr name="power_profile" +stop_cmd=':' LOGGER="logger -t power_profile -p daemon.notice" # Set a given sysctl node to a value. @@ -77,7 +78,7 @@ # Set the various sysctls based on the profile's values. node="hw.acpi.cpu.cx_lowest" highest_value="C1" -lowest_value="`(sysctl -n hw.acpi.cpu.cx_supported | \ +lowest_value="`(sysctl -n dev.cpu.0.cx_supported | \ awk '{ print "C" split($0, a) }' -) 2> /dev/null`" eval value=\$${profile}_cx_lowest sysctl_set Index: ipnat =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipnat,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/ipnat -L etc/rc.d/ipnat -u -r1.2 -r1.3 --- etc/rc.d/ipnat +++ etc/rc.d/ipnat @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: ipnat,v 1.6 2000/09/19 13:04:38 lukem Exp $ -# $FreeBSD: src/etc/rc.d/ipnat,v 1.14 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/ipnat,v 1.15.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: ipnat @@ -14,31 +13,15 @@ name="ipnat" rcvar=`set_rcvar` load_rc_config $name -start_precmd="ipnat_precmd" start_cmd="ipnat_start" stop_cmd="${ipnat_program} -F -C" reload_cmd="${ipnat_program} -F -C -f ${ipnat_rules}" extra_commands="reload" - -ipnat_precmd() -{ - # Make sure ipfilter is loaded before continuing - if ! ${SYSCTL} net.inet.ipf.fr_pass >/dev/null 2>&1; then - if kldload ipl; then - info 'IP-filter module loaded.' - else - err 1 'IP-filter module failed to load.' - fi - fi - return 0 -} +required_files="${ipnat_rules}" +required_modules="ipl:ipfilter" ipnat_start() { - if [ ! -f ${ipnat_rules} ]; then - warn 'NO IPNAT RULES' - return 0 - fi echo "Installing NAT rules." ${ipnat_program} -CF -f ${ipnat_rules} ${ipnat_flags} } From laffer1 at midnightbsd.org Sat Jan 17 19:16:14 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:16:14 -0500 (EST) Subject: [Midnightbsd-cvs] src: ipsec: remove unneeded commands on ipsec reload Message-ID: <200901180016.n0I0GEsx068877@stargazer.midnightbsd.org> Log Message: ----------- remove unneeded commands on ipsec reload Modified Files: -------------- src/etc/rc.d: ipsec (r1.3 -> r1.4) -------------- next part -------------- Index: ipsec =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipsec,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ipsec -L etc/rc.d/ipsec -u -r1.3 -r1.4 --- etc/rc.d/ipsec +++ etc/rc.d/ipsec @@ -1,6 +1,5 @@ #!/bin/sh # -# $NetBSD: ipsec,v 1.7 2002/03/22 04:33:58 thorpej Exp $ # $FreeBSD: src/etc/rc.d/ipsec,v 1.11.2.2 2006/01/31 00:28:01 pjd Exp $ # $MidnightBSD$ @@ -53,8 +52,6 @@ ipsec_reload() { echo "Reloading ipsec manual keys/policies." - ${ipsec_program} -F - ${ipsec_program} -FP ${ipsec_program} -f "$ipsec_file" } From laffer1 at midnightbsd.org Sat Jan 17 19:17:36 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:17:36 -0500 (EST) Subject: [Midnightbsd-cvs] src: ipfw: Change the way ipfw module is loaded. Message-ID: <200901180017.n0I0Ha40068954@stargazer.midnightbsd.org> Log Message: ----------- Change the way ipfw module is loaded. Modified Files: -------------- src/etc/rc.d: ipfw (r1.5 -> r1.6) -------------- next part -------------- Index: ipfw =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipfw,v retrieving revision 1.5 retrieving revision 1.6 diff -L etc/rc.d/ipfw -L etc/rc.d/ipfw -u -r1.5 -r1.6 --- etc/rc.d/ipfw +++ etc/rc.d/ipfw @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ipfw,v 1.10.2.1 2006/01/21 22:42:43 yar Exp $ +# $FreeBSD: src/etc/rc.d/ipfw,v 1.15 2007/04/02 15:38:53 mtm Exp $ # $MidnightBSD$ # PROVIDE: ipfw @@ -14,20 +14,8 @@ name="ipfw" rcvar="firewall_enable" start_cmd="ipfw_start" -start_precmd="ipfw_precmd" stop_cmd="ipfw_stop" - -ipfw_precmd() -{ - if ! ${SYSCTL} net.inet.ip.fw.enable > /dev/null 2>&1; then - if ! kldload ipfw; then - warn unable to load firewall module. - return 1 - fi - fi - - return 0 -} +required_modules="ipfw" ipfw_start() { From laffer1 at midnightbsd.org Sat Jan 17 19:36:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:36:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.subr: Add kld loader functions and make several changes with Message-ID: <200901180036.n0I0ac7N070577@stargazer.midnightbsd.org> Log Message: ----------- Add kld loader functions and make several changes with mounting Modified Files: -------------- src/etc: rc.subr (r1.10 -> r1.11) -------------- next part -------------- Index: rc.subr =================================================================== RCS file: /home/cvs/src/etc/rc.subr,v retrieving revision 1.10 retrieving revision 1.11 diff -L etc/rc.subr -L etc/rc.subr -u -r1.10 -r1.11 --- etc/rc.subr +++ etc/rc.subr @@ -41,6 +41,7 @@ # : ${rcvar_manpage:='rc.conf(5)'} +: ${RC_PID:=$$}; export RC_PID # # Operating System dependent/independent variables @@ -55,7 +56,8 @@ CMD_OSTYPE="${SYSCTL_N} kern.ostype" OSTYPE=`${CMD_OSTYPE}` ID="/usr/bin/id" -JID=`ps -p $$ -o jid=` +PS="/bin/ps -ww" +JID=`$PS -p $$ -o jid=` IDCMD="if [ -x $ID ]; then $ID -un; fi" SYSCTL_W="${SYSCTL}" @@ -144,6 +146,27 @@ echo $_revlist } +# stop_boot always +# If booting directly to multiuser or $always is enabled, +# send SIGTERM to the parent (/etc/rc) to abort the boot. +# Otherwise just exit. +# +stop_boot() +{ + local always + + if [ -n "$1" ] && checkyesno $1; then + always=true + else + always=false + fi + if [ "$autoboot" = yes -o "$always" = true ]; then + echo "ERROR: ABORTING BOOT (sending SIGTERM to parent)!" + kill -TERM ${RC_PID} + fi + exit 1 +} + # # mount_critical_filesystems type # Go through the list of critical filesystems as provided in @@ -244,16 +267,30 @@ _pref= if [ $_interpreter != "." ]; then # an interpreted script - read _interp < $_procname # read interpreter name - _interp=${_interp#\#!} # strip #! - set -- $_interp - case $1 in - */bin/env) - shift #drop env to get real name - ;; - esac - if [ $_interpreter != $1 ]; then - warn "\$command_interpreter $_interpreter != $1" + _script=${_chroot}${_chroot:+"/"}$_procname + if [ -r $_script ]; then + read _interp < $_script # read interpreter name + case "$_interp" in + \#!*) + _interp=${_interp#\#!} # strip #! + set -- $_interp + case $1 in + */bin/env) + shift # drop env to get real name + ;; + esac + if [ $_interpreter != $1 ]; then + warn "\$command_interpreter $_interpreter != $1" + fi + ;; + *) + warn "no shebang line in $_script" + set -- $_interpreter + ;; + esac + else + warn "cannot read shebang line from $_script" + set -- $_interpreter fi _interp="$* $_procname" # cleanup spaces, add _procname _interpbn=${1##*/} @@ -267,13 +304,10 @@ $_procname|$_procnamebn|${_procnamebn}:|"(${_procnamebn})"|"[${_procnamebn}]")' fi - _proccheck=' - ps 2>/dev/null -o "pid,jid,command" '"$_psargs"' | + _proccheck="\ + $PS 2>/dev/null -o pid= -o jid= -o command= $_psargs"' | while read _npid _jid '"$_fp_args"'; do - case "$_npid" in - PID) - continue;; - esac; '"$_fp_match"' + '"$_fp_match"' if [ "$JID" -eq "$_jid" ]; then echo -n "$_pref$_npid"; _pref=" "; @@ -399,12 +433,25 @@ # returned a zero exit code. # # required_dirs n If set, check for the existence of the given -# directories before running the default -# (re)start command. +# directories before running a (re)start command. # # required_files n If set, check for the readability of the given -# files before running the default (re)start -# command. +# files before running a (re)start command. +# +# required_modules n If set, ensure the given kernel modules are +# loaded before running a (re)start command. +# The check and possible loads are actually +# done after start_precmd so that the modules +# aren't loaded in vain, should the precmd +# return a non-zero status to indicate a error. +# If a word in the list looks like "foo:bar", +# "foo" is the KLD file name and "bar" is the +# module name. If a word looks like "foo~bar", +# "foo" is the KLD file name and "bar" is a +# egrep(1) pattern matching the module name. +# Otherwise the module name is assumed to be +# the same as the KLD file name, which is most +# common. See load_kld(). # # required_vars n If set, perform checkyesno on each of the # listed variables before running the default @@ -553,49 +600,31 @@ if [ "$_elem" != "$rc_arg" ]; then continue fi - # if there's a custom ${XXX_cmd}, # run that instead of the default # - eval _cmd=\$${rc_arg}_cmd _precmd=\$${rc_arg}_precmd \ - _postcmd=\$${rc_arg}_postcmd + eval _cmd=\$${rc_arg}_cmd \ + _precmd=\$${rc_arg}_precmd \ + _postcmd=\$${rc_arg}_postcmd + if [ -n "$_cmd" ]; then - # if the precmd failed and force - # isn't set, exit - # - if [ -n "$_precmd" ]; then - debug "run_rc_command: evaluating ${_precmd}()." - eval $_precmd $rc_extra_args - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi - - if [ -n "$_cmd" ]; then - debug "run_rc_command: evaluating ${_cmd}()." - eval $_cmd $rc_extra_args - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi - - if [ -n "$_postcmd" ]; then - debug "run_rc_command: evaluating ${_postcmd}()." - eval $_postcmd $rc_extra_args - _return=$? - fi + _run_rc_precmd || return 1 + _run_rc_doit "$_cmd $rc_extra_args" || return 1 + _run_rc_postcmd return $_return fi case "$rc_arg" in # default operations... status) + _run_rc_precmd || return 1 if [ -n "$rc_pid" ]; then echo "${name} is running as pid $rc_pid." else echo "${name} is not running." return 1 fi + _run_rc_postcmd ;; start) @@ -604,51 +633,14 @@ return 1 fi - if [ ! -x ${_chroot}${command} ]; then - info "run_rc_command: cannot run ($command)." + if [ ! -x ${_chroot}${_chroot:+"/"}${command} ]; then + warn "run_rc_command: cannot run $command" return 1 fi - # check for required variables, - # directories, and files - # - for _f in $required_vars; do - if ! checkyesno $_f; then - warn "\$${_f} is not enabled." - if [ -z "$rc_force" ]; then - return 1 - fi - fi - done - for _f in $required_dirs; do - if [ ! -d "${_f}/." ]; then - warn "${_f} is not a directory." - if [ -z "$rc_force" ]; then - return 1 - fi - fi - done - for _f in $required_files; do - if [ ! -r "${_f}" ]; then - warn "${_f} is not readable." - if [ -z "$rc_force" ]; then - return 1 - fi - fi - done - - # if the precmd failed and force - # isn't set, exit - # - if [ -n "${_precmd}" ]; then - debug "run_rc_command: evaluating ${_precmd}()." - eval $_precmd - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi + _run_rc_precmd || return 1 - # setup the command to run, and run it + # setup the full command to run # echo "Starting ${name}." if [ -n "$_chroot" ]; then @@ -671,105 +663,52 @@ fi fi - # if the cmd failed and force - # isn't set, exit + # run the full command # - debug "run_rc_command: _doit: $_doit" - eval $_doit - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 + _run_rc_doit "$_doit" || return 1 # finally, run postcmd # - if [ -n "${_postcmd}" ]; then - debug "run_rc_command: evaluating ${_postcmd}()." - eval $_postcmd - fi + _run_rc_postcmd ;; stop) if [ -z "$rc_pid" ]; then [ -n "$rc_fast" ] && return 0 - if [ -n "$pidfile" ]; then - echo 1>&2 \ - "${name} not running? (check $pidfile)." - else - echo 1>&2 "${name} not running?" - fi + _run_rc_notrunning return 1 fi - # if the precmd failed and force - # isn't set, exit - # - if [ -n "$_precmd" ]; then - eval $_precmd - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi + _run_rc_precmd || return 1 # send the signal to stop # echo "Stopping ${name}." - _doit="kill -${sig_stop:-TERM} $rc_pid" - if [ -n "$_user" ]; then - _doit="su -m $_user -c 'sh -c \"$_doit\"'" - fi - - # if the stop cmd failed and force - # isn't set, exit - # - eval $_doit - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 + _doit=$(_run_rc_killcmd "${sig_stop:-TERM}") + _run_rc_doit "$_doit" || return 1 # wait for the command to exit, # and run postcmd. wait_for_pids $rc_pid - if [ -n "$_postcmd" ]; then - eval $_postcmd - _return=$? - fi + + _run_rc_postcmd ;; reload) if [ -z "$rc_pid" ]; then - if [ -n "$pidfile" ]; then - echo 1>&2 \ - "${name} not running? (check $pidfile)." - else - echo 1>&2 "${name} not running?" - fi + _run_rc_notrunning return 1 fi - echo "Reloading ${name} config files." - if [ -n "$_precmd" ]; then - eval $_precmd - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi - _doit="kill -${sig_reload:-HUP} $rc_pid" - if [ -n "$_user" ]; then - _doit="su -m $_user -c 'sh -c \"$_doit\"'" - fi - eval $_doit - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 - if [ -n "$_postcmd" ]; then - eval $_postcmd - _return=$? - fi + + _run_rc_precmd || return 1 + + _doit=$(_run_rc_killcmd "${sig_reload:-HUP}") + _run_rc_doit "$_doit" || return 1 + + _run_rc_postcmd ;; restart) - if [ -n "$_precmd" ]; then - eval $_precmd $rc_extra_args - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi # prevent restart being called more # than once by any given script # @@ -778,29 +717,32 @@ fi _rc_restart_done=true - # run stop in a subshell to keep variables for start + _run_rc_precmd || return 1 + + # run those in a subshell to keep global variables ( run_rc_command ${_rc_prefix}stop $rc_extra_args ) - run_rc_command ${_rc_prefix}start $rc_extra_args + ( run_rc_command ${_rc_prefix}start $rc_extra_args ) + _return=$? + [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 - if [ -n "$_postcmd" ]; then - eval $_postcmd $rc_extra_args - _return=$? - fi + _run_rc_postcmd ;; poll) + _run_rc_precmd || return 1 if [ -n "$rc_pid" ]; then wait_for_pids $rc_pid fi + _run_rc_postcmd ;; rcvar) echo "# $name" if [ -n "$rcvar" ]; then if checkyesno ${rcvar}; then - echo "\$${rcvar}=YES" + echo "${rcvar}=YES" else - echo "\$${rcvar}=NO" + echo "${rcvar}=NO" fi fi ;; @@ -819,6 +761,83 @@ } # +# Helper functions for run_rc_command: common code. +# They use such global variables besides the exported rc_* ones: +# +# name R/W +# ------------------ +# _precmd R +# _postcmd R +# _return W +# +_run_rc_precmd() +{ + check_required_before "$rc_arg" || return 1 + + if [ -n "$_precmd" ]; then + debug "run_rc_command: ${rc_arg}_precmd: $_precmd $rc_extra_args" + eval "$_precmd $rc_extra_args" + _return=$? + + # If precmd failed and force isn't set, request exit. + if [ $_return -ne 0 ] && [ -z "$rc_force" ]; then + return 1 + fi + fi + + check_required_after "$rc_arg" || return 1 + + return 0 +} + +_run_rc_postcmd() +{ + if [ -n "$_postcmd" ]; then + debug "run_rc_command: ${rc_arg}_postcmd: $_postcmd $rc_extra_args" + eval "$_postcmd $rc_extra_args" + _return=$? + fi + return 0 +} + +_run_rc_doit() +{ + debug "run_rc_command: doit: $*" + eval "$@" + _return=$? + + # If command failed and force isn't set, request exit. + if [ $_return -ne 0 ] && [ -z "$rc_force" ]; then + return 1 + fi + + return 0 +} + +_run_rc_notrunning() +{ + local _pidmsg + + if [ -n "$pidfile" ]; then + _pidmsg=" (check $pidfile)." + else + _pidmsg= + fi + echo 1>&2 "${name} not running?${_pidmsg}" +} + +_run_rc_killcmd() +{ + local _cmd + + _cmd="kill -$1 $rc_pid" + if [ -n "$_user" ]; then + _cmd="su -m ${_user} -c 'sh -c \"${_cmd}\"'" + fi + echo "$_cmd" +} + +# # run_rc_script file arg # Start the script `file' with `arg', and correctly handle the # return value from the script. If `file' ends with `.sh', it's @@ -1094,7 +1113,7 @@ return 1 fi if [ ! -d "$linkdir" ]; then - warn "$_me: the directory $linkdir does not exist" + warn "$_me: the directory $linkdir does not exist." return 1 fi if ! ln -sf $src $link; then @@ -1309,6 +1328,53 @@ /sbin/mdmfs $flags -s $1 md $2 } +# Code common to scripts that need to load a kernel module +# if it isn't in the kernel yet. Syntax: +# load_kld [-e regex] [-m module] file +# where -e or -m chooses the way to check if the module +# is already loaded: +# regex is egrep'd in the output from `kldstat -v', +# module is passed to `kldstat -m'. +# The default way is as though `-m file' were specified. +load_kld() +{ + local _loaded _mod _opt _re + + while getopts "e:m:" _opt; do + case "$_opt" in + e) _re="$OPTARG" ;; + m) _mod="$OPTARG" ;; + *) err 3 'USAGE: load_kld [-e regex] [-m module] file' ;; + esac + done + shift $(($OPTIND - 1)) + if [ $# -ne 1 ]; then + err 3 'USAGE: load_kld [-e regex] [-m module] file' + fi + _mod=${_mod:-$1} + _loaded=false + if [ -n "$_re" ]; then + if kldstat -v | egrep -q -e "$_re"; then + _loaded=true + fi + else + if kldstat -q -m "$_mod"; then + _loaded=true + fi + fi + if ! $_loaded; then + if ! kldload "$1"; then + warn "Unable to load kernel module $1" + return 1 + else + info "$1 kernel module loaded." + fi + else + debug "load_kld: $1 kernel module already loaded." + fi + return 0 +} + # ltr str src dst # Change every $src in $str to $dst. # Useful when /usr is not yet mounted and we cannot use tr(1), sed(1) nor @@ -1413,6 +1479,74 @@ done } +# check_required_{before|after} command +# Check for things required by the command before and after its precmd, +# respectively. The two separate functions are needed because some +# conditions should prevent precmd from being run while other things +# depend on precmd having already been run. +# +check_required_before() +{ + local _f + + case "$1" in + start) + for _f in $required_vars; do + if ! checkyesno $_f; then + warn "\$${_f} is not enabled." + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + + for _f in $required_dirs; do + if [ ! -d "${_f}/." ]; then + warn "${_f} is not a directory." + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + + for _f in $required_files; do + if [ ! -r "${_f}" ]; then + warn "${_f} is not readable." + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + ;; + esac + + return 0 +} + +check_required_after() +{ + local _f _args + + case "$1" in + start) + for _f in $required_modules; do + case "${_f}" in + *~*) _args="-e ${_f#*~} ${_f%%~*}" ;; + *:*) _args="-m ${_f#*:} ${_f%%:*}" ;; + *) _args="${_f}" ;; + esac + if ! load_kld ${_args}; then + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + ;; + esac + + return 0 +} + fi _rc_subr_loaded=: From laffer1 at midnightbsd.org Sat Jan 17 19:52:21 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:52:21 -0500 (EST) Subject: [Midnightbsd-cvs] src: modules/ndis: Message-ID: <200901180052.n0I0qLQM071817@stargazer.midnightbsd.org> Log Message: ----------- Modified Files: -------------- src/sys/modules/if_ndis: Makefile (r1.1.1.1 -> r1.2) src/sys/modules/ndis: Makefile (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/if_ndis/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/modules/if_ndis/Makefile -L sys/modules/if_ndis/Makefile -u -r1.1.1.1 -r1.2 --- sys/modules/if_ndis/Makefile +++ sys/modules/if_ndis/Makefile @@ -1,10 +1,10 @@ -# $FreeBSD: src/sys/modules/if_ndis/Makefile,v 1.5 2005/04/24 20:21:22 wpaul Exp $ +# $FreeBSD: src/sys/modules/if_ndis/Makefile,v 1.6 2005/09/27 18:10:35 mlaier Exp $ .PATH: ${.CURDIR}/../../dev/if_ndis KMOD= if_ndis SRCS= if_ndis.c if_ndis_pci.c if_ndis_pccard.c if_ndis_usb.c -SRCS+= opt_bdg.h device_if.h bus_if.h pci_if.h card_if.h pccarddevs.h +SRCS+= device_if.h bus_if.h pci_if.h card_if.h pccarddevs.h SRCS+= opt_usb.h usbdevs.h .include Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/ndis/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/modules/ndis/Makefile -L sys/modules/ndis/Makefile -u -r1.1.1.1 -r1.2 --- sys/modules/ndis/Makefile +++ sys/modules/ndis/Makefile @@ -1,11 +1,11 @@ -# $FreeBSD: src/sys/modules/ndis/Makefile,v 1.10 2005/04/11 02:02:35 wpaul Exp $ +# $FreeBSD: src/sys/modules/ndis/Makefile,v 1.11 2005/09/27 18:10:36 mlaier Exp $ .PATH: ${.CURDIR}/../../compat/ndis KMOD= ndis SRCS= subr_pe.c subr_ndis.c subr_hal.c subr_ntoskrnl.c kern_ndis.c SRCS+= kern_windrv.c subr_usbd.c -SRCS+= opt_bdg.h device_if.h bus_if.h pci_if.h vnode_if.h +SRCS+= device_if.h bus_if.h pci_if.h vnode_if.h .if ${MACHINE_ARCH} == "amd64" SRCS+= winx64_wrap.S From laffer1 at midnightbsd.org Sat Jan 17 20:07:56 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 20:07:56 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: merge rc changes Message-ID: <200901180107.n0I17uqJ073168@stargazer.midnightbsd.org> Log Message: ----------- merge rc changes Modified Files: -------------- src/etc/rc.d: abi (r1.6 -> r1.7) accounting (r1.2 -> r1.3) amd (r1.5 -> r1.6) archdep (r1.3 -> r1.4) atm1 (r1.2 -> r1.3) bluetooth (r1.2 -> r1.3) cleanvar (r1.2 -> r1.3) dmesg (r1.2 -> r1.3) geli (r1.2 -> r1.3) hcsecd (r1.2 -> r1.3) hostname (r1.3 -> r1.4) ip6addrctl (r1.3 -> r1.4) ip6fw (r1.3 -> r1.4) Removed Files: ------------- src/etc/rc.d: bootconf.sh -------------- next part -------------- Index: dmesg =================================================================== RCS file: /home/cvs/src/etc/rc.d/dmesg,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/dmesg -L etc/rc.d/dmesg -u -r1.2 -r1.3 --- etc/rc.d/dmesg +++ etc/rc.d/dmesg @@ -7,7 +7,7 @@ # PROVIDE: dmesg # REQUIRE: mountcritremote cleanvar # BEFORE: DAEMON -# KEYWORD: Daemon nojail +# KEYWORD: nojail . /etc/rc.subr Index: abi =================================================================== RCS file: /home/cvs/src/etc/rc.d/abi,v retrieving revision 1.6 retrieving revision 1.7 diff -L etc/rc.d/abi -L etc/rc.d/abi -u -r1.6 -r1.7 --- etc/rc.d/abi +++ etc/rc.d/abi @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/abi,v 1.4.2.1 2006/01/17 06:37:48 dougb Exp $ +# $FreeBSD: src/etc/rc.d/abi,v 1.11 2006/12/30 22:53:19 yar Exp $ # $MidnightBSD$ # PROVIDE: abi @@ -16,21 +16,21 @@ sysv_start() { echo -n ' sysvipc' - kldload sysvmsg >/dev/null 2>&1 - kldload sysvsem >/dev/null 2>&1 - kldload sysvshm >/dev/null 2>&1 + load_kld sysvmsg + load_kld sysvsem + load_kld sysvshm } linux_start() { + local _tmpdir + echo -n ' linux' - if ! kldstat -v | grep -E 'linux(aout|elf)' > /dev/null; then - kldload linux > /dev/null 2>&1 - fi - if [ -x /compat/linux/sbin/ldconfig ]; then + load_kld -e 'linux(aout|elf)' linux + if [ -x /compat/linux/sbin/ldconfigDisabled ]; then _tmpdir=`mktemp -d -t linux-ldconfig` /compat/linux/sbin/ldconfig -C ${_tmpdir}/ld.so.cache - if ! cmp -s ${_tmpdir}/ld.so.cache /compat/linux/etc/ld.so.cache; then + if ! cmp -s ${_tmpdir}/ld.so.cache /compat/linux/etc/ld.so.cache; then cat ${_tmpdir}/ld.so.cache > /compat/linux/etc/ld.so.cache fi rm -rf ${_tmpdir} @@ -40,7 +40,7 @@ svr4_start() { echo -n ' svr4' - kldload svr4 > /dev/null 2>&1 + load_kld -m svr4elf svr4 } abi_start() Index: hostname =================================================================== RCS file: /home/cvs/src/etc/rc.d/hostname,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/hostname -L etc/rc.d/hostname -u -r1.3 -r1.4 --- etc/rc.d/hostname +++ etc/rc.d/hostname @@ -23,7 +23,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.d/hostname,v 1.8 2004/10/07 13:55:25 mtm Exp $ +# $FreeBSD: src/etc/rc.d/hostname,v 1.12 2007/04/02 22:53:07 des Exp $ # $MidnightBSD$ # PROVIDE: hostname @@ -31,6 +31,7 @@ # BEFORE: netif . /etc/rc.subr +. /etc/network.subr name="hostname" start_cmd="hostname_start" @@ -58,8 +59,21 @@ fi fi - /bin/hostname ${hostname} - echo "Setting hostname: `hostname`." + # Have we got a hostname yet? + # + if [ -z "${hostname}" ]; then + # Null hostname is probably OK if DHCP is in use. + # + if [ -z "`list_net_interfaces dhcp`" ]; then + warn "\$hostname is not set -- see ${rcvar_manpage}." + fi + return + fi + + # All right, it is safe to invoke hostname(1) now. + # + echo "Setting hostname: ${hostname}." + /bin/hostname "${hostname}" } load_rc_config $name Index: cleanvar =================================================================== RCS file: /home/cvs/src/etc/rc.d/cleanvar,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/cleanvar -L etc/rc.d/cleanvar -u -r1.2 -r1.3 --- etc/rc.d/cleanvar +++ etc/rc.d/cleanvar @@ -4,7 +4,7 @@ # $MidnightBSD$ # PROVIDE: cleanvar -# REQUIRE: mountcritlocal var +# REQUIRE: FILESYSTEMS var . /etc/rc.subr @@ -59,7 +59,7 @@ if [ -d /var/run -a ! -f /var/run/clean_var ]; then purgedir /var/run # And an initial utmp file - (cd /var/run && cp /dev/null utmp && chmod 644 utmp;) + (cd /var/run && cp /dev/null utmp && chmod 644 utmp) >/var/run/clean_var fi if [ -d /var/spool/lock -a ! -f /var/spool/lock/clean_var ]; then Index: hcsecd =================================================================== RCS file: /home/cvs/src/etc/rc.d/hcsecd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/hcsecd -L etc/rc.d/hcsecd -u -r1.2 -r1.3 --- etc/rc.d/hcsecd +++ etc/rc.d/hcsecd @@ -1,7 +1,8 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/hcsecd,v 1.4.2.1 2005/11/23 18:03:33 emax Exp $ # $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/hcsecd,v 1.5 2006/12/31 10:37:18 yar Exp $ +# # PROVIDE: hcsecd # REQUIRE: DAEMON @@ -14,21 +15,7 @@ command="/usr/sbin/${name}" pidfile="/var/run/${name}.pid" rcvar=`set_rcvar` -start_precmd="hcsecd_prestart" - -hcsecd_prestart() -{ - if ! kldstat -q -m ng_btsocket ; then - if kldload ng_btsocket > /dev/null 2>&1 ; then - info 'ng_btsocket module loaded' - else - warn 'ng_btsocket module failed to load' - return 1 - fi - fi - - return 0 -} +required_modules="ng_btsocket" load_rc_config $name config="${hcsecd_config:-/etc/bluetooth/${name}.conf}" Index: atm1 =================================================================== RCS file: /home/cvs/src/etc/rc.d/atm1,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/atm1 -L etc/rc.d/atm1 -u -r1.2 -r1.3 --- etc/rc.d/atm1 +++ etc/rc.d/atm1 @@ -24,9 +24,8 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # +# $FreeBSD: src/etc/rc.d/atm1,v 1.16 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/atm1,v 1.15 2004/10/07 13:55:25 mtm Exp $ -# # PROVIDE: atm1 # REQUIRE: root @@ -49,7 +48,7 @@ { if [ -n "${natm_interfaces}" ] ; then # Load the HARP pseudo interface - kldstat -v | grep -q if_harp || kldload if_harp + load_kld if_harp || return 1 # Load all the NATM drivers that we need for natm in ${natm_interfaces} ; do @@ -59,7 +58,7 @@ # Load loadable HARP drivers for dev in ${atm_load} ; do - kldstat -v | grep -q ${dev} || kldload ${dev} + load_kld ${dev} || return 1 done # Locate all probed ATM adapters Index: ip6addrctl =================================================================== RCS file: /home/cvs/src/etc/rc.d/ip6addrctl,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ip6addrctl -L etc/rc.d/ip6addrctl -u -r1.3 -r1.4 --- etc/rc.d/ip6addrctl +++ etc/rc.d/ip6addrctl @@ -4,7 +4,7 @@ # $MidnightBSD$ # PROVIDE: ip6addrctl -# REQUIRE: FILESYSTEMS netif +# REQUIRE: FILESYSTEMS netif # BEFORE: network_ipv6 # KEYWORD: nojail Index: archdep =================================================================== RCS file: /home/cvs/src/etc/rc.d/archdep,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/archdep -L etc/rc.d/archdep -u -r1.3 -r1.4 --- etc/rc.d/archdep +++ etc/rc.d/archdep @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/archdep,v 1.7.2.2 2006/01/17 07:12:38 dougb Exp $ +# $FreeBSD: src/etc/rc.d/archdep,v 1.14 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: archdep @@ -19,13 +19,13 @@ { if checkyesno ibcs2_enable; then echo -n ' ibcs2' - kldload ibcs2 > /dev/null 2>&1 + load_kld ibcs2 case ${ibcs2_loaders} in [Nn][Oo]) ;; *) for i in ${ibcs2_loaders}; do - kldload ibcs2_$i > /dev/null 2>&1 + load_kld ibcs2_$i done ;; esac @@ -34,6 +34,8 @@ archdep_start() { + local _arch + _arch=`${SYSCTL_N} hw.machine_arch` echo -n "Initial $_arch initialization:" case $_arch in Index: amd =================================================================== RCS file: /home/cvs/src/etc/rc.d/amd,v retrieving revision 1.5 retrieving revision 1.6 diff -L etc/rc.d/amd -L etc/rc.d/amd -u -r1.5 -r1.6 --- etc/rc.d/amd +++ etc/rc.d/amd @@ -47,7 +47,7 @@ ;; *) rc_flags="-p ${rc_flags}" - command_args=" > /var/run/amd.pid 2> /dev/null" + command_args="> /var/run/amd.pid 2> /dev/null" ;; esac return 0 Index: accounting =================================================================== RCS file: /home/cvs/src/etc/rc.d/accounting,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/accounting -L etc/rc.d/accounting -u -r1.2 -r1.3 --- etc/rc.d/accounting +++ etc/rc.d/accounting @@ -20,6 +20,8 @@ accounting_start() { + local _dir + _dir=`dirname "$accounting_file"` if [ ! -d `dirname "$_dir"` ]; then if ! mkdir -p "$_dir"; then Index: ip6fw =================================================================== RCS file: /home/cvs/src/etc/rc.d/ip6fw,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ip6fw -L etc/rc.d/ip6fw -u -r1.3 -r1.4 --- etc/rc.d/ip6fw +++ etc/rc.d/ip6fw @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ip6fw,v 1.6 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/ip6fw,v 1.9 2007/04/02 15:38:53 mtm Exp $ # $MidnightBSD$ # PROVIDE: ip6fw @@ -13,21 +13,8 @@ name="ip6fw" rcvar=`set_rcvar ipv6_firewall` start_cmd="ip6fw_start" -start_precmd="ip6fw_prestart" stop_cmd="${SYSCTL_W} net.inet6.ip6.fw.enable=0" - -ip6fw_prestart() -{ - # Load IPv6 firewall module, if not already loaded - if ! ${SYSCTL} net.inet6.ip6.fw.enable > /dev/null 2>&1; then - kldload ip6fw && { - debug 'Kernel IPv6 firewall module loaded.' - return 0 - } - warn 'IPv6 firewall kernel module failed to load.' - return 1 - fi -} +required_modules="ipfw" ip6fw_start() { @@ -41,7 +28,7 @@ if [ -r "${ipv6_firewall_script}" ]; then /bin/sh "${ipv6_firewall_script}" echo 'IPv6 Firewall rules loaded.' - elif [ "`ip6fw l 65535`" = "65535 deny ipv6 from any to any" ]; then + elif [ "`ipfw show 65535`" = "65535 deny ip from any to any" ]; then warn 'IPv6 firewall rules have not been loaded. Default' \ ' to DENY all access.' fi @@ -50,7 +37,7 @@ # if checkyesno ipv6_firewall_logging; then echo 'IPv6 Firewall logging=YES' - sysctl net.inet6.ip6.fw.verbose=1 >/dev/null + sysctl net.inet.ip.fw.verbose=1 >/dev/null fi # Enable the firewall Index: geli =================================================================== RCS file: /home/cvs/src/etc/rc.d/geli,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/geli -L etc/rc.d/geli -u -r1.2 -r1.3 --- etc/rc.d/geli +++ etc/rc.d/geli @@ -24,8 +24,9 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.d/geli,v 1.2.2.2 2005/12/15 23:32:35 pjd Exp $ # $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/geli,v 1.4 2006/12/31 10:37:18 yar Exp $ +# # PROVIDE: disks # REQUIRE: initrandom @@ -34,20 +35,15 @@ . /etc/rc.subr name="geli" +start_precmd='[ -n "$(geli_make_list)" ]' start_cmd="geli_start" stop_cmd="geli_stop" +required_modules="geom_eli:g_eli" geli_start() { devices=`geli_make_list` - # If there are no devices return before loading geom_eli.ko. - if [ -z "${devices}" ]; then - return - fi - - kldstat -q -m g_eli || geli load || err 1 'geom_eli module failed to load.' - if [ -z "${geli_tries}" ]; then if [ -n "${geli_attach_attempts}" ]; then # Compatibility with rc.d/gbde. Index: bluetooth =================================================================== RCS file: /home/cvs/src/etc/rc.d/bluetooth,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/bluetooth -L etc/rc.d/bluetooth -u -r1.2 -r1.3 --- etc/rc.d/bluetooth +++ etc/rc.d/bluetooth @@ -24,8 +24,8 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/bluetooth,v 1.1.2.1 2005/11/23 18:03:33 emax Exp $ +# $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/bluetooth,v 1.3 2006/12/31 10:37:18 yar Exp $ # PROVIDE: bluetooth # REQUIRE: DAEMON @@ -37,6 +37,7 @@ rcvar= start_cmd="bluetooth_start" stop_cmd="bluetooth_stop" +required_modules="ng_bluetooth ng_hci ng_l2cap ng_btsocket" ############################################################################## # Read and parse Bluetooth device configuration file @@ -44,6 +45,8 @@ bluetooth_read_conf() { + local _err _file _line _namespace + _file=$1 _namespace=$2 _err=0 @@ -226,19 +229,15 @@ bluetooth_start() { - dev=$1 + local _file - # Automatically load modules - kldload ng_bluetooth > /dev/null 2>&1 - kldload ng_hci > /dev/null 2>&1 - kldload ng_l2cap > /dev/null 2>&1 - kldload ng_btsocket > /dev/null 2>&1 + dev=$1 # Try to figure out device type by looking at device name case "${dev}" in # sioX - serial/UART Bluetooth device sio*) - kldload ng_h4 > /dev/null 2>&1 + load_kld ng_h4 || return 1 hook="hook" --- etc/rc.d/bootconf.sh +++ /dev/null @@ -1,82 +0,0 @@ -#!/bin/sh -# -# $NetBSD: bootconf.sh,v 1.5 2002/03/25 03:22:10 wiz Exp $ -# $FreeBSD: src/etc/rc.d/bootconf.sh,v 1.4 2002/10/12 10:31:31 schweikh Exp $ -# $MidnightBSD: src/etc/rc.d/bootconf.sh,v 1.3 2007/10/26 14:12:39 laffer1 Exp $ - -# PROVIDE: bootconf -# REQUIRE: FILESYSTEMS - -bootconf_start() -{ - # Refer to newbtconf(8) for more information - # - - if [ ! -e /etc/etc.current ]; then - return 0 - fi - if [ -L /etc/etc.default ]; then - def=`ls -ld /etc/etc.default 2>&1` - default="${def##*-> etc.}" - else - default=current - fi - if [ "$default" = "current" ]; then - def=`ls -ld /etc/etc.current 2>&1` - default="${def##*-> etc.}" - fi - - spc="" - for i in /etc/etc.*; do - name="${i##/etc/etc.}" - case $name in - current|default|\*) - continue - ;; - *) - if [ "$name" = "$default" ]; then - echo -n "${spc}[${name}]" - else - echo -n "${spc}${name}" - fi - spc=" " - ;; - esac - done - echo - master=$$ - _DUMMY=/etc/passwd - conf=${_DUMMY} - while [ ! -d /etc/etc.$conf/. ]; do - trap "conf=$default; echo; echo Using default of $conf" ALRM - echo -n "Which configuration [$default] ? " - (sleep 30 && kill -ALRM $master) >/dev/null 2>&1 & - read conf - trap : ALRM - if [ -z $conf ]; then - conf=$default - fi - if [ ! -d /etc/etc.$conf/. ]; then - conf=${_DUMMY} - fi - done - - case $conf in - current|default) - ;; - *) - rm -f /etc/etc.current - ln -s /etc/etc.$conf /etc/etc.current - ;; - esac - - if [ -f /etc/rc.conf ]; then - . /etc/rc.conf - fi -} - -case "$1" in -*start) - bootconf_start - ;; -esac From laffer1 at midnightbsd.org Sat Jan 17 20:19:30 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 20:19:30 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: merge rc changes Message-ID: <200901180119.n0I1JUgj074003@stargazer.midnightbsd.org> Log Message: ----------- merge rc changes Modified Files: -------------- src/etc/rc.d: ipfilter (r1.3 -> r1.4) isdnd (r1.4 -> r1.5) jail (r1.5 -> r1.6) kerberos (r1.2 -> r1.3) ldconfig (r1.2 -> r1.3) localpkg (r1.2 -> r1.3) lpd (r1.2 -> r1.3) natd (r1.2 -> r1.3) nfsclient (r1.2 -> r1.3) nfsserver (r1.2 -> r1.3) nsswitch (r1.3 -> r1.4) powerd (r1.3 -> r1.4) -------------- next part -------------- Index: kerberos =================================================================== RCS file: /home/cvs/src/etc/rc.d/kerberos,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/kerberos -L etc/rc.d/kerberos -u -r1.2 -r1.3 --- etc/rc.d/kerberos +++ etc/rc.d/kerberos @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/kerberos,v 1.4.2.1 2005/09/25 18:45:56 rwatson Exp $ +# $FreeBSD: src/etc/rc.d/kerberos,v 1.6.4.2 2008/01/29 07:15:46 mtm Exp $ # $MidnightBSD$ # PROVIDE: kerberos @@ -9,9 +9,9 @@ . /etc/rc.subr name="kerberos5" -load_rc_config $name rcvar="kerberos5_server_enable" -command="${kerberos5_server}" -command_args="${kerberos5_server_flags} &" +load_rc_config $name +command="${kerberos5_server}" +kerberos5_flags="${kerberos5_server_flags}" run_rc_command "$1" Index: isdnd =================================================================== RCS file: /home/cvs/src/etc/rc.d/isdnd,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/isdnd -L etc/rc.d/isdnd -u -r1.4 -r1.5 --- etc/rc.d/isdnd +++ etc/rc.d/isdnd @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: isdnd,v 1.9 2002/04/10 23:37:13 martin Exp $ -# $FreeBSD: src/etc/rc.d/isdnd,v 1.20 2005/01/16 03:12:03 obrien Exp $ +# $FreeBSD: src/etc/rc.d/isdnd,v 1.23.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # # Mostly based on original script (/etc/rc.isdn) written by Hellmuth Michaelis @@ -23,16 +22,6 @@ { echo -n 'ISDN subsystem setup:' - # Check for pcvt driver (VT100/VT220 emulator) - # - if [ -x /usr/sbin/ispcvt ]; then - if /usr/sbin/ispcvt; then - # No vidcontrol if we are using pcvt - # - isdn_screenflags=NO - fi - fi - # Start isdnd # echo -n ' isdnd' Index: nfsclient =================================================================== RCS file: /home/cvs/src/etc/rc.d/nfsclient,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/nfsclient -L etc/rc.d/nfsclient -u -r1.2 -r1.3 --- etc/rc.d/nfsclient +++ etc/rc.d/nfsclient @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/nfsclient,v 1.5 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/nfsclient,v 1.6 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: nfsclient @@ -12,20 +12,8 @@ name="nfsclient" rcvar="nfs_client_enable" start_cmd="nfsclient_start" -start_precmd="nfsclient_precmd" stop_cmd="unmount_all" - -# Load nfs module if it was not compiled into the kernel -nfsclient_precmd() -{ - if ! sysctl vfs.nfs >/dev/null 2>&1; then - if ! kldload nfsclient; then - warn 'Could not load nfs client module' - return 1 - fi - fi - return 0 -} +required_modules="nfsclient:nfs" nfsclient_start() { Index: lpd =================================================================== RCS file: /home/cvs/src/etc/rc.d/lpd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/lpd -L etc/rc.d/lpd -u -r1.2 -r1.3 --- etc/rc.d/lpd +++ etc/rc.d/lpd @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: lpd,v 1.5 2002/03/22 04:33:59 thorpej Exp $ -# $FreeBSD: src/etc/rc.d/lpd,v 1.7 2005/03/02 02:46:47 brooks Exp $ +# $FreeBSD: src/etc/rc.d/lpd,v 1.8.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: lpd @@ -14,9 +13,9 @@ rcvar=`set_rcvar` command="/usr/sbin/${name}" required_files="/etc/printcap" -start_precmd="_chkprintcap" +start_precmd="chkprintcap" -_chkprintcap() +chkprintcap() { if checkyesno chkprintcap_enable ; then /usr/sbin/chkprintcap ${chkprintcap_flags} Index: ldconfig =================================================================== RCS file: /home/cvs/src/etc/rc.d/ldconfig,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/ldconfig -L etc/rc.d/ldconfig -u -r1.2 -r1.3 --- etc/rc.d/ldconfig +++ etc/rc.d/ldconfig @@ -1,8 +1,7 @@ #!/bin/sh # -# $NetBSD: ldconfig,v 1.5 2002/03/22 04:33:58 thorpej Exp $ -# $FreeBSD: src/etc/rc.d/ldconfig,v 1.14.2.1 2006/01/17 06:53:17 dougb Exp $ -# $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/ldconfig,v 1.17.2.1.2.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD$ # PROVIDE: ldconfig # REQUIRE: mountcritremote cleanvar @@ -17,6 +16,8 @@ ldconfig_start() { + local _files _ins + _ins= ldconfig=${ldconfig_command} checkyesno ldconfig_insecure && _ins="-i" @@ -24,7 +25,10 @@ _LDC="/lib /usr/lib" for i in ${ldconfig_local_dirs}; do if [ -d "${i}" ]; then - ldconfig_paths="${ldconfig_paths} `find ${i} -type f`" + _files=`find ${i} -type f` + if [ -n "${_files}" ]; then + ldconfig_paths="${ldconfig_paths} `cat ${_files} | sort -u`" + fi fi done for i in ${ldconfig_paths} /etc/ld-elf.so.conf; do @@ -39,11 +43,20 @@ amd64) for i in ${ldconfig_local32_dirs}; do if [ -d "${i}" ]; then - ldconfig32_paths="${ldconfig32_paths} `find ${i} -type f`" + _files=`find ${i} -type f` + if [ -n "${_files}" ]; then + ldconfig32_paths="${ldconfig32_paths} `cat ${_files} | sort -u`" + fi + fi + done + _LDC="" + for i in ${ldconfig32_paths}; do + if [ -r "${i}" ]; then + _LDC="${_LDC} ${i}" fi done - echo '32-bit compatibility ldconfig path:' ${ldconfig32_paths} - ${ldconfig} -32 -m ${_ins} ${ldconfig32_paths} + echo '32-bit compatibility ldconfig path:' ${_LDC} + ${ldconfig} -32 -m ${_ins} ${_LDC} ;; esac Index: natd =================================================================== RCS file: /home/cvs/src/etc/rc.d/natd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/natd -L etc/rc.d/natd -u -r1.2 -r1.3 --- etc/rc.d/natd +++ etc/rc.d/natd @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/natd,v 1.3 2004/10/22 19:36:03 andre Exp $ +# $FreeBSD: src/etc/rc.d/natd,v 1.5 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: natd @@ -12,43 +12,31 @@ name="natd" rcvar=`set_rcvar` command="/sbin/${name}" +pidfile="/var/run/${name}.pid" start_precmd="natd_precmd" -start_cmd="natd_start" +required_modules="ipdivert" natd_precmd() { - if ! ${SYSCTL} net.inet.divert > /dev/null 2>&1; then - if ! kldload ipdivert; then - warn unable to load IPDIVERT module. - return 1 - fi - fi - - return 0 -} - -natd_start() -{ - dhcp_list="`list_net_interfaces dhcp`" - for ifn in ${dhcp_list}; do - case ${natd_interface} in - ${ifn}) - natd_flags="$natd_flags -dynamic" - ;; - *) - ;; - esac - done if [ -n "${natd_interface}" ]; then - if echo ${natd_interface} | \ - grep -q -E '^[0-9]+(\.[0-9]+){0,3}$'; then - natd_flags="$natd_flags -a ${natd_interface}" + dhcp_list="`list_net_interfaces dhcp`" + for ifn in ${dhcp_list}; do + case "${natd_interface}" in + ${ifn}) + rc_flags="$rc_flags -dynamic" + ;; + esac + done + + if echo "${natd_interface}" | \ + grep -q -E '^[0-9]+(\.[0-9]+){0,3}$'; then + rc_flags="$rc_flags -a ${natd_interface}" else - natd_flags="$natd_flags -n ${natd_interface}" + rc_flags="$rc_flags -n ${natd_interface}" fi fi - echo -n ' natd' - ${natd_program:-/sbin/natd} ${natd_flags} ${natd_ifarg} + + return 0 } load_rc_config $name Index: powerd =================================================================== RCS file: /home/cvs/src/etc/rc.d/powerd,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/powerd -L etc/rc.d/powerd -u -r1.3 -r1.4 --- etc/rc.d/powerd +++ etc/rc.d/powerd @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/powerd,v 1.2.2.1 2005/12/16 01:42:54 dougb Exp $ +# $FreeBSD: src/etc/rc.d/powerd,v 1.4 2006/08/27 11:04:39 cperciva Exp $ # $MidnightBSD$ # PROVIDE: powerd @@ -13,6 +13,13 @@ name="powerd" rcvar=`set_rcvar` command="/usr/sbin/${name}" +stop_postcmd=powerd_poststop + +powerd_poststop() +{ + sysctl dev.cpu.0.freq=`sysctl -n dev.cpu.0.freq_levels | + sed -e 's:/.*::'` > /dev/null +} load_rc_config $name run_rc_command "$1" Index: nsswitch =================================================================== RCS file: /home/cvs/src/etc/rc.d/nsswitch,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/nsswitch -L etc/rc.d/nsswitch -u -r1.3 -r1.4 --- etc/rc.d/nsswitch +++ etc/rc.d/nsswitch @@ -24,7 +24,7 @@ # SUCH DAMAGE. # # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/nsswitch,v 1.5.2.1 2006/04/04 14:27:55 flz Exp $ +# $FreeBSD: src/etc/rc.d/nsswitch,v 1.12 2006/12/30 22:53:20 yar Exp $ # # PROVIDE: nsswitch @@ -37,52 +37,10 @@ start_cmd="nsswitch_start" stop_cmd=":" -convert_host_conf() -{ - host_conf=$1; shift; - nsswitch_conf=$1; shift; - - while read line; do - line=${line##[ ]} - case $line in - hosts|local|file) - _nsswitch="${_nsswitch}${_nsswitch+ }files" - ;; - dns|bind) - _nsswitch="${_nsswitch}${_nsswitch+ }dns" - ;; - nis) - _nsswitch="${_nsswitch}${_nsswitch+ }nis" - ;; - '#'*) - ;; - *) - printf "Warning: unrecognized line [%s]", $line > "/dev/stderr" - ;; - - esac - done < $host_conf - - echo "hosts: $_nsswitch" > $nsswitch_conf -} - -generate_nsswitch_conf() -{ - nsswitch_conf=$1; shift; - - cat >$nsswitch_conf < $host_conf + echo "# Auto-generated from nsswitch.conf" > $host_conf for _s in ${_sources}; do case $_s in files) @@ -131,25 +89,11 @@ nsswitch_start() { - # Convert host.conf to nsswitch.conf if necessary - # - if [ -f "/etc/host.conf" -a ! -f "/etc/nsswitch.conf" ]; then - echo '' - echo 'Warning: /etc/host.conf is no longer used' - echo ' /etc/nsswitch.conf will be created for you' - convert_host_conf /etc/host.conf /etc/nsswitch.conf - fi - - # Generate default nsswitch.conf if none exists - # - if [ ! -f "/etc/nsswitch.conf" ]; then - echo 'Generating nsswitch.conf.' - generate_nsswitch_conf /etc/nsswitch.conf - fi - # Generate host.conf for compatibility # - if [ ! -f "/etc/host.conf" ]; then + if [ ! -f "/etc/host.conf" -o \ + "/etc/host.conf" -ot "/etc/nsswitch.conf" ] + then echo 'Generating host.conf.' generate_host_conf /etc/nsswitch.conf /etc/host.conf fi Index: jail =================================================================== RCS file: /home/cvs/src/etc/rc.d/jail,v retrieving revision 1.5 retrieving revision 1.6 diff -L etc/rc.d/jail -L etc/rc.d/jail -u -r1.5 -r1.6 --- etc/rc.d/jail +++ etc/rc.d/jail @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/jail,v 1.23.2.2 2005/08/16 08:43:06 pjd Exp $ +# $FreeBSD: src/etc/rc.d/jail,v 1.37.4.1 2008/01/29 00:22:33 dougb Exp $ # $MidnightBSD$ # PROVIDE: jail @@ -8,6 +8,12 @@ # BEFORE: securelevel # KEYWORD: nojail shutdown +# WARNING: This script deals with untrusted data (the data and +# processes inside the jails) and care must be taken when changing the +# code related to this! If you have any doubt whether a change is +# correct and have security impact, please get the patch reviewed by +# laffer1@ or ctriv@ prior to commit. + . /etc/rc.subr name="jail" @@ -27,66 +33,101 @@ return fi - eval jail_rootdir=\"\$jail_${_j}_rootdir\" - jail_devdir="${jail_rootdir}/dev" - jail_fdescdir="${jail_devdir}/fd" - jail_procdir="${jail_rootdir}/proc" - eval jail_hostname=\"\$jail_${_j}_hostname\" - eval jail_ip=\"\$jail_${_j}_ip\" - eval jail_exec=\"\$jail_${_j}_exec\" - eval jail_exec_start=\"\$jail_${_j}_exec_start\" - eval jail_exec_stop=\"\$jail_${_j}_exec_stop\" - if [ -n "${jail_exec}" ]; then + eval _rootdir=\"\$jail_${_j}_rootdir\" + _devdir="${_rootdir}/dev" + _fdescdir="${_devdir}/fd" + _procdir="${_rootdir}/proc" + eval _hostname=\"\$jail_${_j}_hostname\" + eval _ip=\"\$jail_${_j}_ip\" + eval _interface=\"\${jail_${_j}_interface:-${jail_interface}}\" + eval _exec=\"\$jail_${_j}_exec\" + eval _exec_start=\"\${jail_${_j}_exec_start:-${jail_exec_start}}\" + + i=1 + while [ true ]; do + eval _exec_afterstart${i}=\"\${jail_${_j}_exec_afterstart${i}:-\${jail_exec_afterstart${i}}}\" + [ -z "$(eval echo \"\$_exec_afterstart${i}\")" ] && break + i=$((i + 1)) + done + + eval _exec_stop=\"\${jail_${_j}_exec_stop:-${jail_exec_stop}}\" + if [ -n "${_exec}" ]; then # simple/backward-compatible execution - jail_exec_start="${jail_exec}" - jail_exec_stop="" + _exec_start="${_exec}" + _exec_stop="" else # flexible execution - if [ -z "${jail_exec_start}" ]; then - jail_exec_start="/bin/sh /etc/rc" - if [ -z "${jail_exec_stop}" ]; then - jail_exec_stop="/bin/sh /etc/rc.shutdown" + if [ -z "${_exec_start}" ]; then + _exec_start="/bin/sh /etc/rc" + if [ -z "${_exec_stop}" ]; then + _exec_stop="/bin/sh /etc/rc.shutdown" fi fi fi # The default jail ruleset will be used by rc.subr if none is specified. - eval jail_ruleset=\"\$jail_${_j}_devfs_ruleset\" - eval jail_devfs=\"\$jail_${_j}_devfs_enable\" - [ -z "${jail_devfs}" ] && jail_devfs="NO" - eval jail_fdescfs=\"\$jail_${_j}_fdescfs_enable\" - [ -z "${jail_fdescfs}" ] && jail_fdescfs="NO" - eval jail_procfs=\"\$jail_${_j}_procfs_enable\" - [ -z "${jail_procfs}" ] && jail_procfs="NO" + eval _ruleset=\"\${jail_${_j}_devfs_ruleset:-${jail_devfs_ruleset}}\" + eval _devfs=\"\${jail_${_j}_devfs_enable:-${jail_devfs_enable}}\" + [ -z "${_devfs}" ] && _devfs="NO" + eval _fdescfs=\"\${jail_${_j}_fdescfs_enable:-${jail_fdescfs_enable}}\" + [ -z "${_fdescfs}" ] && _fdescfs="NO" + eval _procfs=\"\${jail_${_j}_procfs_enable:-${jail_procfs_enable}}\" + [ -z "${_procfs}" ] && _procfs="NO" - eval jail_mount=\"\$jail_${_j}_mount_enable\" - [ -z "${jail_mount}" ] && jail_mount="NO" + eval _mount=\"\${jail_${_j}_mount_enable:-${jail_mount_enable}}\" + [ -z "${_mount}" ] && _mount="NO" # "/etc/fstab.${_j}" will be used for {,u}mount(8) if none is specified. - eval jail_fstab=\"\$jail_${_j}_fstab\" - [ -z "${jail_fstab}" ] && jail_fstab="/etc/fstab.${_j}" - eval jail_flags=\"\$jail_${_j}_flags\" - [ -z "${jail_flags}" ] && jail_flags="-l -U root" + eval _fstab=\"\${jail_${_j}_fstab:-${jail_fstab}}\" + [ -z "${_fstab}" ] && _fstab="/etc/fstab.${_j}" + eval _flags=\"\${jail_${_j}_flags:-${jail_flags}}\" + [ -z "${_flags}" ] && _flags="-l -U root" eval _consolelog=\"\${jail_${_j}_consolelog:-${jail_consolelog}}\" [ -z "${_consolelog}" ] && _consolelog="/var/log/jail_${_j}_console.log" # Debugging aid # - debug "$_j devfs enable: $jail_devfs" - debug "$_j fdescfs enable: $jail_fdescfs" - debug "$_j procfs enable: $jail_procfs" - debug "$_j mount enable: $jail_mount" - debug "$_j hostname: $jail_hostname" - debug "$_j ip: $jail_ip" - debug "$_j root: $jail_rootdir" - debug "$_j devdir: $jail_devdir" - debug "$_j fdescdir: $jail_fdescdir" - debug "$_j procdir: $jail_procdir" - debug "$_j ruleset: $jail_ruleset" - debug "$_j fstab: $jail_fstab" - debug "$_j exec start: $jail_exec_start" - debug "$_j exec stop: $jail_exec_stop" - debug "$_j flags: $jail_flags" + debug "$_j devfs enable: $_devfs" + debug "$_j fdescfs enable: $_fdescfs" + debug "$_j procfs enable: $_procfs" + debug "$_j mount enable: $_mount" + debug "$_j hostname: $_hostname" + debug "$_j ip: $_ip" + debug "$_j interface: $_interface" + debug "$_j root: $_rootdir" + debug "$_j devdir: $_devdir" + debug "$_j fdescdir: $_fdescdir" + debug "$_j procdir: $_procdir" + debug "$_j ruleset: $_ruleset" + debug "$_j fstab: $_fstab" + debug "$_j exec start: $_exec_start" + debug "$_j consolelog: $_consolelog" + + i=1 + while [ true ]; do + eval out=\"\${_exec_afterstart${i}:-''}\" + + if [ -z "$out" ]; then + break; + fi + + debug "$_j exec after start #${i}: ${out}" + i=$((i + 1)) + done + + debug "$_j exec stop: $_exec_stop" + debug "$_j flags: $_flags" debug "$_j consolelog: $_consolelog" + + if [ -z "${_hostname}" ]; then + err 3 "$name: No hostname has been defined for ${_j}" + fi + if [ -z "${_rootdir}" ]; then + err 3 "$name: No root directory has been defined for ${_j}" + fi + if [ -z "${_ip}" ]; then + err 3 "$name: No IP address has been defined for ${_j}" + fi + } # set_sysctl rc_knob mib msg @@ -175,24 +216,24 @@ { local _device _mountpt _rest - if checkyesno jail_fdescfs; then - if [ -d "${jail_fdescdir}" ] ; then - secure_umount ${jail_fdescdir} + if checkyesno _fdescfs; then + if [ -d "${_fdescdir}" ] ; then + secure_umount ${_fdescdir} fi fi - if checkyesno jail_devfs; then - if [ -d "${jail_devdir}" ] ; then - secure_umount ${jail_devdir} + if checkyesno _devfs; then + if [ -d "${_devdir}" ] ; then + secure_umount ${_devdir} fi fi - if checkyesno jail_procfs; then - if [ -d "${jail_procdir}" ] ; then - secure_umount ${jail_procdir} + if checkyesno _procfs; then + if [ -d "${_procdir}" ] ; then + secure_umount ${_procdir} fi fi - if checkyesno jail_mount; then - [ -f "${jail_fstab}" ] || warn "${jail_fstab} does not exist" - tail -r ${jail_fstab} | while read _device _mountpt _rest; do + if checkyesno _mount; then + [ -f "${_fstab}" ] || warn "${_fstab} does not exist" + tail -r ${_fstab} | while read _device _mountpt _rest; do case ":${_device}" in :#* | :) continue @@ -225,11 +266,11 @@ ;; esac if is_symlinked_mountpoint ${_mountpt}; then - warn "${_mountpt} has symlink as parent - not mounting from ${jail_fstab}" + warn "${_mountpt} has symlink as parent - not mounting from ${_fstab}" return fi - done <${jail_fstab} - mount -a -F "${jail_fstab}" + done <${_fstab} + mount -a -F "${_fstab}" } jail_start() @@ -250,30 +291,33 @@ do init_variables $_jail if [ -f /var/run/jail_${_jail}.id ]; then - echo -n " [${jail_hostname} already running (/var/run/jail_${_jail}.id exists)]" + echo -n " [${_hostname} already running (/var/run/jail_${_jail}.id exists)]" continue; fi - if checkyesno jail_mount; then - info "Mounting fstab for jail ${_jail} (${jail_fstab})" - if [ ! -f "${jail_fstab}" ]; then - err 3 "$name: ${jail_fstab} does not exist" + if [ -n "${_interface}" ]; then + ifconfig ${_interface} alias ${_ip} netmask 255.255.255.255 + fi + if checkyesno _mount; then + info "Mounting fstab for jail ${_jail} (${_fstab})" + if [ ! -f "${_fstab}" ]; then + err 3 "$name: ${_fstab} does not exist" fi jail_mount_fstab fi - if checkyesno jail_devfs; then + if checkyesno _devfs; then # If devfs is already mounted here, skip it. - df -t devfs "${jail_devdir}" >/dev/null + df -t devfs "${_devdir}" >/dev/null if [ $? -ne 0 ]; then - if is_symlinked_mountpoint ${jail_devdir}; then - warn "${jail_devdir} has symlink as parent - not starting jail ${_jail}" + if is_symlinked_mountpoint ${_devdir}; then + warn "${_devdir} has symlink as parent - not starting jail ${_jail}" continue fi - info "Mounting devfs on ${jail_devdir}" - devfs_mount_jail "${jail_devdir}" ${jail_ruleset} + info "Mounting devfs on ${_devdir}" + devfs_mount_jail "${_devdir}" ${_ruleset} # Transitional symlink for old binaries - if [ ! -L "${jail_devdir}/log" ]; then + if [ ! -L "${_devdir}/log" ]; then __pwd="`pwd`" - cd "${jail_devdir}" + cd "${_devdir}" ln -sf ../var/run/log log cd "$__pwd" fi @@ -283,36 +327,58 @@ # is a devfs(5) device of the same name. # Jail console output # __pwd="`pwd`" - # cd "${jail_devdir}" + # cd "${_devdir}" # ln -sf ../var/log/console console # cd "$__pwd" fi - if checkyesno jail_fdescfs; then - if is_symlinked_mountpoint ${jail_fdescdir}; then - warn "${jail_fdescdir} has symlink as parent, not mounting" - else - info "Mounting fdescfs on ${jail_fdescdir}" - mount -t fdescfs fdesc "${jail_fdescdir}" + if checkyesno _fdescfs; then + if is_symlinked_mountpoint ${_fdescdir}; then + warn "${_fdescdir} has symlink as parent, not mounting" + else + info "Mounting fdescfs on ${_fdescdir}" + mount -t fdescfs fdesc "${_fdescdir}" fi fi - if checkyesno jail_procfs; then - if is_symlinked_mountpoint ${jail_procdir}; then - warn "${jail_procdir} has symlink as parent, not mounting" + if checkyesno _procfs; then + if is_symlinked_mountpoint ${_procdir}; then + warn "${_procdir} has symlink as parent, not mounting" else - info "Mounting procfs onto ${jail_procdir}" - if [ -d "${jail_procdir}" ] ; then - mount -t procfs proc "${jail_procdir}" + info "Mounting procfs onto ${_procdir}" + if [ -d "${_procdir}" ] ; then + mount -t procfs proc "${_procdir}" fi fi fi _tmp_jail=${_tmp_dir}/jail.$$ - eval jail ${jail_flags} -i ${jail_rootdir} ${jail_hostname} \ - ${jail_ip} ${jail_exec_start} > ${_tmp_jail} 2>&1 - [ "$?" -eq 0 ] && echo -n " $jail_hostname" - _jail_id=$(head -1 ${_tmp_jail}) - tail +2 ${_tmp_jail} >${_consolelog} + eval jail ${_flags} -i ${_rootdir} ${_hostname} \ + ${_ip} ${_exec_start} > ${_tmp_jail} 2>&1 + + if [ "$?" -eq 0 ] ; then + _jail_id=$(head -1 ${_tmp_jail}) + i=1 + while [ true ]; do + eval out=\"\${_exec_afterstart${i}:-''}\" + + if [ -z "$out" ]; then + break; + fi + + jexec "${_jail_id}" ${out} + i=$((i + 1)) + done + + echo -n " $_hostname" + tail +2 ${_tmp_jail} >${_consolelog} + echo ${_jail_id} > /var/run/jail_${_jail}.id + else + jail_umount_fs + if [ -n "${_interface}" ]; then + ifconfig ${_interface} -alias ${_ip} + fi + echo " cannot start jail \"${_jail}\": " + tail +2 ${_tmp_jail} + fi rm -f ${_tmp_jail} - echo ${_jail_id} > /var/run/jail_${_jail}.id done rmdir ${_tmp_dir} echo '.' @@ -327,19 +393,22 @@ _jail_id=$(cat /var/run/jail_${_jail}.id) if [ ! -z "${_jail_id}" ]; then init_variables $_jail - if [ -n "${jail_exec_stop}" ]; then - eval env -i /usr/sbin/jexec ${_jail_id} ${jail_exec_stop} \ + if [ -n "${_exec_stop}" ]; then + eval env -i /usr/sbin/jexec ${_jail_id} ${_exec_stop} \ >> ${_consolelog} 2>&1 fi killall -j ${_jail_id} -TERM > /dev/null 2>&1 sleep 1 killall -j ${_jail_id} -KILL > /dev/null 2>&1 jail_umount_fs - echo -n " $jail_hostname" + echo -n " $_hostname" + fi + if [ -n "${_interface}" ]; then + ifconfig ${_interface} -alias ${_ip} fi rm /var/run/jail_${_jail}.id else - echo "cannot stop jail ${_jail}. No jail id in /var/run" + echo " cannot stop jail ${_jail}. No jail id in /var/run" fi done echo '.' Index: ipfilter =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipfilter,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ipfilter -L etc/rc.d/ipfilter -u -r1.3 -r1.4 --- etc/rc.d/ipfilter +++ etc/rc.d/ipfilter @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: ipfilter,v 1.10 2001/02/28 17:03:50 lukem Exp $ -# $FreeBSD: src/etc/rc.d/ipfilter,v 1.24 2005/07/07 05:59:44 jkim Exp $ +# $FreeBSD: src/etc/rc.d/ipfilter,v 1.28.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: ipfilter @@ -16,7 +15,7 @@ load_rc_config $name stop_precmd="test -f ${ipfilter_rules} -o -f ${ipv6_ipfilter_rules}" -start_precmd="ipfilter_prestart" +start_precmd="$stop_precmd" start_cmd="ipfilter_start" stop_cmd="ipfilter_stop" reload_precmd="$stop_precmd" @@ -26,35 +25,7 @@ status_precmd="$stop_precmd" status_cmd="ipfilter_status" extra_commands="reload resync status" - -ipfilter_loaded() -{ - if ! kldstat -v | grep "ipfilter$" > /dev/null 2>&1; then - return 1 - else - return 0 - fi -} - -ipfilter_prestart() -{ - # load ipfilter kernel module if needed - if ! ipfilter_loaded; then - if kldload ipl; then - info 'IP-filter module loaded.' - else - err 1 'IP-filter module failed to load.' - fi - fi - - # check for ipfilter rules - if [ ! -r "${ipfilter_rules}" ] && [ ! -r "${ipv6_ipfilter_rules}" ] - then - warn 'IP-filter: NO IPF RULES' - return 1 - fi - return 0 -} +required_modules="ipl:ipfilter" ipfilter_start() { @@ -93,11 +64,17 @@ if [ -r "${ipfilter_rules}" ]; then ${ipfilter_program:-/sbin/ipf} -I \ -f "${ipfilter_rules}" ${ipfilter_flags} + if [ $? -ne 0 ]; then + err 1 'Load of rules into alternate set failed; aborting reload' + fi fi ${ipfilter_program:-/sbin/ipf} -I -6 -Fa if [ -r "${ipv6_ipfilter_rules}" ]; then ${ipfilter_program:-/sbin/ipf} -I -6 \ -f "${ipv6_ipfilter_rules}" ${ipfilter_flags} + if [ $? -ne 0 ]; then + err 1 'Load of IPv6 rules into alternate set failed; aborting reload' + fi fi ${ipfilter_program:-/sbin/ipf} -s @@ -105,10 +82,6 @@ ipfilter_resync() { - # Don't resync if ipfilter is not loaded - if ! ipfilter_loaded; then - return - fi ${ipfilter_program:-/sbin/ipf} -y ${ipfilter_flags} } Index: localpkg =================================================================== RCS file: /home/cvs/src/etc/rc.d/localpkg,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/localpkg -L etc/rc.d/localpkg -u -r1.2 -r1.3 --- etc/rc.d/localpkg +++ etc/rc.d/localpkg @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/localpkg,v 1.5.2.2 2005/12/21 07:11:34 dougb Exp $ +# $FreeBSD: src/etc/rc.d/localpkg,v 1.8 2006/02/12 10:04:56 matteo Exp $ # $MidnightBSD$ # PROVIDE: localpkg @@ -48,6 +48,9 @@ find_local_scripts_old for script in `reverse_list ${slist} ${zlist}`; do if [ -x "${script}" ]; then + if [ `sysctl -n debug.bootverbose` -eq 1 ]; then + echo "==>" ${script} + fi (set -T trap 'exit 1' 2 ${script} stop) Index: nfsserver =================================================================== RCS file: /home/cvs/src/etc/rc.d/nfsserver,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/nfsserver -L etc/rc.d/nfsserver -u -r1.2 -r1.3 --- etc/rc.d/nfsserver +++ etc/rc.d/nfsserver @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/nfsserver,v 1.4 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/nfsserver,v 1.5 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: nfsserver @@ -11,20 +11,9 @@ name="nfsserver" rcvar="nfs_server_enable" -start_cmd="nfsserver_start" +start_cmd=":" stop_cmd=":" - -# Load nfs modules if they were not compiled into the kernel -nfsserver_start() -{ - if ! sysctl vfs.nfsrv >/dev/null 2>&1; then - if ! kldload nfsserver; then - warn 'Could not load NFS server module' - return 1 - fi - fi - return 0 -} +required_modules="nfsserver" load_rc_config $name run_rc_command "$1" From laffer1 at midnightbsd.org Sun Jan 18 14:28:02 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 18 Jan 2009 14:28:02 -0500 (EST) Subject: [Midnightbsd-cvs] src: compat/ndis: remove legacy freebsd version support. Message-ID: <200901181928.n0IJS28j085178@stargazer.midnightbsd.org> Log Message: ----------- remove legacy freebsd version support. Modified Files: -------------- src/sys/compat/ndis: kern_ndis.c (r1.3 -> r1.4) subr_ndis.c (r1.3 -> r1.4) subr_ntoskrnl.c (r1.3 -> r1.4) -------------- next part -------------- Index: subr_ndis.c =================================================================== RCS file: /home/cvs/src/sys/compat/ndis/subr_ndis.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/compat/ndis/subr_ndis.c -L sys/compat/ndis/subr_ndis.c -u -r1.3 -r1.4 --- sys/compat/ndis/subr_ndis.c +++ sys/compat/ndis/subr_ndis.c @@ -1,4 +1,3 @@ -/* $MidnightBSD$ */ /*- * Copyright (c) 2003 * Bill Paul . All rights reserved. @@ -648,11 +647,7 @@ * See if registry key is already in a list of known keys * included with the driver. */ -#if __FreeBSD_version < 502113 - TAILQ_FOREACH(e, &sc->ndis_ctx, link) { -#else TAILQ_FOREACH(e, device_get_sysctl_ctx(sc->ndis_dev), link) { -#endif oidp = e->entry; if (strcasecmp(oidp->oid_name, keystr) == 0) { if (strcmp((char *)oidp->oid_arg1, "UNSET") == 0) { @@ -757,11 +752,7 @@ /* See if the key already exists. */ -#if __FreeBSD_version < 502113 - TAILQ_FOREACH(e, &sc->ndis_ctx, link) { -#else TAILQ_FOREACH(e, device_get_sysctl_ctx(sc->ndis_dev), link) { -#endif oidp = e->entry; if (strcasecmp(oidp->oid_name, keystr) == 0) { /* Found it, set the value. */ @@ -1361,23 +1352,11 @@ block = (ndis_miniport_block *)adapter; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); -#ifdef IFP2ENADDR - if (bcmp(IFP2ENADDR(sc->ifp), empty, ETHER_ADDR_LEN) == 0) -#elif __FreeBSD_version >= 700000 if (sc->ifp->if_addr == NULL || bcmp(IF_LLADDR(sc->ifp), empty, ETHER_ADDR_LEN) == 0) -#else - if (bcmp(sc->arpcom.ac_enaddr, empty, ETHER_ADDR_LEN) == 0) -#endif *status = NDIS_STATUS_FAILURE; else { -#ifdef IFP2ENADDR - *addr = IFP2ENADDR(sc->ifp); -#elif __FreeBSD_version >= 700000 *addr = IF_LLADDR(sc->ifp); -#else - *addr = sc->arpcom.ac_enaddr; -#endif *addrlen = ETHER_ADDR_LEN; *status = NDIS_STATUS_SUCCESS; } Index: kern_ndis.c =================================================================== RCS file: /home/cvs/src/sys/compat/ndis/kern_ndis.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/compat/ndis/kern_ndis.c -L sys/compat/ndis/kern_ndis.c -u -r1.3 -r1.4 --- sys/compat/ndis/kern_ndis.c +++ sys/compat/ndis/kern_ndis.c @@ -295,15 +295,6 @@ TAILQ_INIT(&sc->ndis_cfglist_head); -#if __FreeBSD_version < 502113 - /* Create the sysctl tree. */ - - sc->ndis_tree = SYSCTL_ADD_NODE(&sc->ndis_ctx, - SYSCTL_STATIC_CHILDREN(_hw), OID_AUTO, - device_get_nameunit(sc->ndis_dev), CTLFLAG_RD, 0, - device_get_desc(sc->ndis_dev)); - -#endif /* Add the driver-specific registry keys. */ while(1) { @@ -318,11 +309,7 @@ /* See if we already have a sysctl with this name */ oidp = NULL; -#if __FreeBSD_version < 502113 - TAILQ_FOREACH(e, &sc->ndis_ctx, link) { -#else TAILQ_FOREACH(e, device_get_sysctl_ctx(sc->ndis_dev), link) { -#endif oidp = e->entry; if (strcasecmp(oidp->oid_name, vals->nc_cfgkey) == 0) break; @@ -403,18 +390,11 @@ TAILQ_INSERT_TAIL(&sc->ndis_cfglist_head, cfg, link); cfg->ndis_oid = -#if __FreeBSD_version < 502113 - SYSCTL_ADD_STRING(&sc->ndis_ctx, SYSCTL_CHILDREN(sc->ndis_tree), - OID_AUTO, cfg->ndis_cfg.nc_cfgkey, flag, - cfg->ndis_cfg.nc_val, sizeof(cfg->ndis_cfg.nc_val), - cfg->ndis_cfg.nc_cfgdesc); -#else SYSCTL_ADD_STRING(device_get_sysctl_ctx(sc->ndis_dev), SYSCTL_CHILDREN(device_get_sysctl_tree(sc->ndis_dev)), OID_AUTO, cfg->ndis_cfg.nc_cfgkey, flag, cfg->ndis_cfg.nc_val, sizeof(cfg->ndis_cfg.nc_val), cfg->ndis_cfg.nc_cfgdesc); -#endif return(0); } @@ -436,11 +416,7 @@ sc = arg; -#if __FreeBSD_version < 502113 - clist = &sc->ndis_ctx; -#else clist = device_get_sysctl_ctx(sc->ndis_dev); -#endif while (!TAILQ_EMPTY(&sc->ndis_cfglist_head)) { cfg = TAILQ_FIRST(&sc->ndis_cfglist_head); @@ -568,20 +544,12 @@ device_t dev; struct resource_list *brl; struct resource_list_entry *brle; -#if __FreeBSD_version < 600022 - struct resource_list brl_rev; - struct resource_list_entry *n; -#endif int error = 0; sc = arg; block = sc->ndis_block; dev = sc->ndis_dev; -#if __FreeBSD_version < 600022 - SLIST_INIT(&brl_rev); -#endif - rl = malloc(sizeof(ndis_resource_list) + (sizeof(cm_partial_resource_desc) * (sc->ndis_rescnt - 1)), M_DEVBUF, M_NOWAIT|M_ZERO); @@ -598,37 +566,7 @@ if (brl != NULL) { -#if __FreeBSD_version < 600022 - /* - * We have a small problem. Some PCI devices have - * multiple I/O ranges. Windows orders them starting - * from lowest numbered BAR to highest. We discover - * them in that order too, but insert them into a singly - * linked list head first, which means when time comes - * to traverse the list, we enumerate them in reverse - * order. This screws up some drivers which expect the - * BARs to be in ascending order so that they can choose - * the "first" one as their register space. Unfortunately, - * in order to fix this, we have to create our own - * temporary list with the entries in reverse order. - */ - - SLIST_FOREACH(brle, brl, link) { - n = malloc(sizeof(struct resource_list_entry), - M_TEMP, M_NOWAIT); - if (n == NULL) { - error = ENOMEM; - goto bad; - } - bcopy((char *)brle, (char *)n, - sizeof(struct resource_list_entry)); - SLIST_INSERT_HEAD(&brl_rev, n, link); - } - - SLIST_FOREACH(brle, &brl_rev, link) { -#else STAILQ_FOREACH(brle, brl, link) { -#endif switch (brle->type) { case SYS_RES_IOPORT: prd->cprd_type = CmResourceTypePort; @@ -672,16 +610,6 @@ block->nmb_rlist = rl; -#if __FreeBSD_version < 600022 -bad: - - while (!SLIST_EMPTY(&brl_rev)) { - n = SLIST_FIRST(&brl_rev); - SLIST_REMOVE_HEAD(&brl_rev, link); - free (n, M_TEMP); - } -#endif - return(error); } Index: subr_ntoskrnl.c =================================================================== RCS file: /home/cvs/src/sys/compat/ndis/subr_ntoskrnl.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/compat/ndis/subr_ntoskrnl.c -L sys/compat/ndis/subr_ntoskrnl.c -u -r1.3 -r1.4 --- sys/compat/ndis/subr_ntoskrnl.c +++ sys/compat/ndis/subr_ntoskrnl.c @@ -45,9 +45,7 @@ #include #include -#if __FreeBSD_version > 502113 #include -#endif #include #include #include @@ -2703,11 +2701,7 @@ rl = BUS_GET_RESOURCE_LIST(device_get_parent(dev), dev); if (rl != NULL) { -#if __FreeBSD_version < 600022 - SLIST_FOREACH(rle, rl, link) { -#else STAILQ_FOREACH(rle, rl, link) { -#endif r = rle->res; if (r == NULL) @@ -2799,9 +2793,6 @@ KeReleaseSpinLock(&kq->kq_lock, irql); } -#if __FreeBSD_version < 502113 - mtx_lock(&Giant); -#endif kthread_exit(0); return; /* notreached */ } @@ -3560,9 +3551,6 @@ ntoskrnl_kth--; -#if __FreeBSD_version < 502113 - mtx_lock(&Giant); -#endif kthread_exit(0); return(0); /* notreached */ } @@ -3584,11 +3572,7 @@ DbgBreakPoint(void) { -#if __FreeBSD_version < 502113 - Debugger("DbgBreakPoint(): breakpoint"); -#else kdb_enter("DbgBreakPoint(): breakpoint"); -#endif } static void @@ -3829,14 +3813,9 @@ thread_lock(curthread); #ifdef NTOSKRNL_MULTIPLE_DPCS -#if __FreeBSD_version >= 502102 sched_bind(curthread, kq->kq_cpu); #endif -#endif sched_prio(curthread, PRI_MIN_KERN); -#if __FreeBSD_version < 600000 - curthread->td_base_pri = PRI_MIN_KERN; -#endif thread_unlock(curthread); while (1) { @@ -3869,9 +3848,6 @@ KeSetEvent(&kq->kq_done, IO_NO_INCREMENT, FALSE); } -#if __FreeBSD_version < 502113 - mtx_lock(&Giant); -#endif kthread_exit(0); return; /* notreached */ } From laffer1 at midnightbsd.org Sun Jan 18 14:29:08 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 18 Jan 2009 14:29:08 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/wi: Remove legacy freebsd support. Message-ID: <200901181929.n0IJT8u8085297@stargazer.midnightbsd.org> Log Message: ----------- Remove legacy freebsd support. Switch to "MidnightBSD" os name. Modified Files: -------------- src/sys/dev/aha: aha.c (r1.2 -> r1.3) src/sys/dev/ahb: ahb.c (r1.4 -> r1.5) src/sys/dev/aic: aic.c (r1.2 -> r1.3) src/sys/dev/aic7xxx: aic79xx.c (r1.1.1.3 -> r1.2) aic79xx_osm.h (r1.1.1.3 -> r1.2) aic7xxx.c (r1.1.1.3 -> r1.2) aic7xxx_osm.h (r1.1.1.3 -> r1.2) aic_osm_lib.c (r1.1.1.3 -> r1.2) aic_osm_lib.h (r1.1.1.3 -> r1.2) src/sys/dev/wds: wd7000.c (r1.2 -> r1.3) src/sys/dev/wi: if_wireg.h (r1.2 -> r1.3) -------------- next part -------------- Index: ahb.c =================================================================== RCS file: /home/cvs/src/sys/dev/ahb/ahb.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/ahb/ahb.c -L sys/dev/ahb/ahb.c -u -r1.4 -r1.5 --- sys/dev/ahb/ahb.c +++ sys/dev/ahb/ahb.c @@ -1229,7 +1229,7 @@ cpi->initiator_id = ahb->scsi_id; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "Adaptec", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: aic.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic/aic.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/aic/aic.c -L sys/dev/aic/aic.c -u -r1.2 -r1.3 --- sys/dev/aic/aic.c +++ sys/dev/aic/aic.c @@ -287,7 +287,7 @@ cpi->initiator_id = aic->initiator; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "Adaptec", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: aic_osm_lib.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic_osm_lib.c,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic_osm_lib.c -L sys/dev/aic7xxx/aic_osm_lib.c -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic_osm_lib.c +++ sys/dev/aic7xxx/aic_osm_lib.c @@ -131,23 +131,6 @@ void aic_calc_geometry(struct ccb_calc_geometry *ccg, int extended) { -#if __FreeBSD_version >= 500000 cam_calc_geometry(ccg, extended); -#else - uint32_t size_mb; - uint32_t secs_per_cylinder; - - size_mb = ccg->volume_size / ((1024L * 1024L) / ccg->block_size); - if (size_mb > 1024 && extended) { - ccg->heads = 255; - ccg->secs_per_track = 63; - } else { - ccg->heads = 64; - ccg->secs_per_track = 32; - } - secs_per_cylinder = ccg->heads * ccg->secs_per_track; - ccg->cylinders = ccg->volume_size / secs_per_cylinder; - ccg->ccb_h.status = CAM_REQ_CMP; -#endif } Index: aic79xx_osm.h =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic79xx_osm.h,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic79xx_osm.h -L sys/dev/aic7xxx/aic79xx_osm.h -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic79xx_osm.h +++ sys/dev/aic7xxx/aic79xx_osm.h @@ -43,9 +43,7 @@ #include #include #include /* For device_t */ -#if __FreeBSD_version >= 500000 #include -#endif #include #include #include @@ -59,13 +57,8 @@ #include -#if __FreeBSD_version >= 500000 #include #include -#else -#include -#include -#endif #include #include Index: aic7xxx_osm.h =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic7xxx_osm.h,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic7xxx_osm.h -L sys/dev/aic7xxx/aic7xxx_osm.h -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic7xxx_osm.h +++ sys/dev/aic7xxx/aic7xxx_osm.h @@ -42,20 +42,14 @@ #include #include #include /* For device_t */ -#if __FreeBSD_version >= 500000 #include -#endif #include #include #include #include #include -#if __FreeBSD_version < 500000 -#include -#else #define NPCI 1 -#endif #if NPCI > 0 #define AIC_PCI_CONFIG 1 @@ -67,13 +61,8 @@ #include #if NPCI > 0 -#if __FreeBSD_version >= 500000 #include #include -#else -#include -#include -#endif #endif #include Index: aic79xx.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic79xx.c,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic79xx.c -L sys/dev/aic7xxx/aic79xx.c -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic79xx.c +++ sys/dev/aic7xxx/aic79xx.c @@ -2234,7 +2234,6 @@ printerror = 0; } else if (ahd_sent_msg(ahd, AHDMSG_1B, MSG_BUS_DEV_RESET, TRUE)) { -#ifdef __FreeBSD__ /* * Don't mark the user's request for this BDR * as completing with CAM_BDR_SENT. CAM3 @@ -2246,7 +2245,6 @@ CAM_LUN_WILDCARD, SCB_LIST_NULL, ROLE_INITIATOR)) aic_set_transaction_status(scb, CAM_REQ_CMP); -#endif ahd_handle_devreset(ahd, &devinfo, CAM_LUN_WILDCARD, CAM_BDR_SENT, "Bus Device Reset", /*verbose_level*/0); @@ -5225,23 +5223,11 @@ { struct ahd_softc *ahd; -#ifndef __FreeBSD__ - ahd = malloc(sizeof(*ahd), M_DEVBUF, M_NOWAIT); - if (!ahd) { - printf("aic7xxx: cannot malloc softc!\n"); - free(name, M_DEVBUF); - return NULL; - } -#else ahd = device_get_softc((device_t)platform_arg); -#endif memset(ahd, 0, sizeof(*ahd)); ahd->seep_config = malloc(sizeof(*ahd->seep_config), M_DEVBUF, M_NOWAIT); if (ahd->seep_config == NULL) { -#ifndef __FreeBSD__ - free(ahd, M_DEVBUF); -#endif free(name, M_DEVBUF); return (NULL); } @@ -5427,9 +5413,6 @@ free(ahd->seep_config, M_DEVBUF); if (ahd->saved_stack != NULL) free(ahd->saved_stack, M_DEVBUF); -#ifndef __FreeBSD__ - free(ahd, M_DEVBUF); -#endif return; } Index: aic7xxx.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic7xxx.c,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic7xxx.c -L sys/dev/aic7xxx/aic7xxx.c -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic7xxx.c +++ sys/dev/aic7xxx/aic7xxx.c @@ -1280,7 +1280,6 @@ printerror = 0; } else if (ahc_sent_msg(ahc, AHCMSG_1B, MSG_BUS_DEV_RESET, TRUE)) { -#ifdef __FreeBSD__ /* * Don't mark the user's request for this BDR * as completing with CAM_BDR_SENT. CAM3 @@ -1294,7 +1293,6 @@ ROLE_INITIATOR)) { aic_set_transaction_status(scb, CAM_REQ_CMP); } -#endif ahc_compile_devinfo(&devinfo, initiator_role_id, target, @@ -3903,23 +3901,11 @@ struct ahc_softc *ahc; int i; -#ifndef __FreeBSD__ - ahc = malloc(sizeof(*ahc), M_DEVBUF, M_NOWAIT); - if (!ahc) { - printf("aic7xxx: cannot malloc softc!\n"); - free(name, M_DEVBUF); - return NULL; - } -#else ahc = device_get_softc((device_t)platform_arg); -#endif memset(ahc, 0, sizeof(*ahc)); ahc->seep_config = malloc(sizeof(*ahc->seep_config), M_DEVBUF, M_NOWAIT); if (ahc->seep_config == NULL) { -#ifndef __FreeBSD__ - free(ahc, M_DEVBUF); -#endif free(name, M_DEVBUF); return (NULL); } @@ -4112,9 +4098,6 @@ free(ahc->name, M_DEVBUF); if (ahc->seep_config != NULL) free(ahc->seep_config, M_DEVBUF); -#ifndef __FreeBSD__ - free(ahc, M_DEVBUF); -#endif return; } Index: aic_osm_lib.h =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic_osm_lib.h,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic_osm_lib.h -L sys/dev/aic7xxx/aic_osm_lib.h -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic_osm_lib.h +++ sys/dev/aic7xxx/aic_osm_lib.h @@ -36,9 +36,7 @@ */ /******************************** OS Includes *********************************/ -#if __FreeBSD_version >= 500000 #include -#endif /*************************** Library Symbol Mapping ***************************/ #define AIC_LIB_ENTRY_CONCAT(x, prefix) prefix ## x @@ -71,7 +69,6 @@ #define AIC_SHUTDOWN_RECOVERY AIC_CONST_ENTRY(_SHUTDOWN_RECOVERY) /********************************* Byte Order *********************************/ -#if __FreeBSD_version >= 500000 #define aic_htobe16(x) htobe16(x) #define aic_htobe32(x) htobe32(x) #define aic_htobe64(x) htobe64(x) @@ -85,21 +82,6 @@ #define aic_le16toh(x) le16toh(x) #define aic_le32toh(x) le32toh(x) #define aic_le64toh(x) le64toh(x) -#else -#define aic_htobe16(x) (x) -#define aic_htobe32(x) (x) -#define aic_htobe64(x) (x) -#define aic_htole16(x) (x) -#define aic_htole32(x) (x) -#define aic_htole64(x) (x) - -#define aic_be16toh(x) (x) -#define aic_be32toh(x) (x) -#define aic_be64toh(x) (x) -#define aic_le16toh(x) (x) -#define aic_le32toh(x) (x) -#define aic_le64toh(x) (x) -#endif /************************* Forward Declarations *******************************/ typedef device_t aic_dev_softc_t; @@ -125,17 +107,11 @@ } /****************************** Kernel Threads ********************************/ -#if __FreeBSD_version > 500005 #define aic_kthread_create(func, farg, proc_ptr, flags, stackpgs, fmtstr, arg) \ kthread_create(func, farg, proc_ptr, flags, stackpgs, fmtstr, arg) -#else -#define aic_kthread_create(func, farg, proc_ptr, flags, stackpgs, fmtstr, arg) \ - kthread_create(func, farg, proc_ptr, fmtstr, arg) -#endif /******************************* Bus Space/DMA ********************************/ -#if __FreeBSD_version >= 501102 #define aic_dma_tag_create(aic, parent_tag, alignment, boundary, \ lowaddr, highaddr, filter, filterarg, \ maxsize, nsegments, maxsegsz, flags, \ @@ -145,16 +121,6 @@ maxsize, nsegments, maxsegsz, flags, \ busdma_lock_mutex, &aic->platform_data->mtx, \ dma_tagp) -#else -#define aic_dma_tag_create(aic, parent_tag, alignment, boundary, \ - lowaddr, highaddr, filter, filterarg, \ - maxsize, nsegments, maxsegsz, flags, \ - dma_tagp) \ - bus_dma_tag_create(parent_tag, alignment, boundary, \ - lowaddr, highaddr, filter, filterarg, \ - maxsize, nsegments, maxsegsz, flags, \ - dma_tagp) -#endif #define aic_dma_tag_destroy(aic, tag) \ bus_dma_tag_destroy(tag) @@ -186,11 +152,7 @@ #include AIC_CORE_INCLUDE /***************************** Timer Facilities *******************************/ -#if __FreeBSD_version >= 500000 #define aic_timer_init(timer) callout_init(timer, /*mpsafe*/1) -#else -#define aic_timer_init callout_init -#endif #define aic_timer_stop callout_stop static __inline void aic_timer_reset(aic_timer_t *, u_int, Index: wd7000.c =================================================================== RCS file: /home/cvs/src/sys/dev/wds/wd7000.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/wds/wd7000.c -L sys/dev/wds/wd7000.c -u -r1.2 -r1.3 --- sys/dev/wds/wd7000.c +++ sys/dev/wds/wd7000.c @@ -1225,7 +1225,7 @@ cpi->hba_misc = 0; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "WD/FDC", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: aha.c =================================================================== RCS file: /home/cvs/src/sys/dev/aha/aha.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/aha/aha.c -L sys/dev/aha/aha.c -u -r1.2 -r1.3 --- sys/dev/aha/aha.c +++ sys/dev/aha/aha.c @@ -993,7 +993,7 @@ cpi->initiator_id = aha->scsi_id; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "Adaptec", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: if_wireg.h =================================================================== RCS file: /home/cvs/src/sys/dev/wi/if_wireg.h,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/wi/if_wireg.h -L sys/dev/wi/if_wireg.h -u -r1.2 -r1.3 --- sys/dev/wi/if_wireg.h +++ sys/dev/wi/if_wireg.h @@ -84,12 +84,12 @@ #ifdef __NetBSD__ #define OS_STRING_NAME "NetBSD" #endif -#ifdef __FreeBSD__ -#define OS_STRING_NAME "FreeBSD" -#endif #ifdef __OpenBSD__ #define OS_STRING_NAME "OpenBSD" #endif +#ifdef __MidnightBSD__ +#define OS_STRING_NAME "MidnightBSD" +#endif #define WI_DEFAULT_NODENAME OS_STRING_NAME " WaveLAN/IEEE node" From laffer1 at midnightbsd.org Sun Jan 18 14:27:18 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 18 Jan 2009 14:27:18 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/if_ndis: Remove the legacy freebsd version support. Message-ID: <200901181927.n0IJRIXZ085130@stargazer.midnightbsd.org> Log Message: ----------- Remove the legacy freebsd version support. Fix the mode setting for 48. Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.1.1.2 -> r1.2) if_ndis_pci.c (r1.1.1.1 -> r1.2) if_ndisvar.h (r1.1.1.2 -> r1.2) -------------- next part -------------- Index: if_ndis_pci.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis_pci.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/dev/if_ndis/if_ndis_pci.c -L sys/dev/if_ndis/if_ndis_pci.c -u -r1.1.1.1 -r1.2 --- sys/dev/if_ndis/if_ndis_pci.c +++ sys/dev/if_ndis/if_ndis_pci.c @@ -187,11 +187,7 @@ rl = BUS_GET_RESOURCE_LIST(device_get_parent(dev), dev); if (rl != NULL) { -#if __FreeBSD_version < 600022 - SLIST_FOREACH(rle, rl, link) { -#else STAILQ_FOREACH(rle, rl, link) { -#endif switch (rle->type) { case SYS_RES_IOPORT: sc->ndis_io_rid = rle->rid; Index: if_ndisvar.h =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndisvar.h,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L sys/dev/if_ndis/if_ndisvar.h -L sys/dev/if_ndis/if_ndisvar.h -u -r1.1.1.2 -r1.2 --- sys/dev/if_ndis/if_ndisvar.h +++ sys/dev/if_ndis/if_ndisvar.h @@ -32,7 +32,7 @@ * $FreeBSD: src/sys/dev/if_ndis/if_ndisvar.h,v 1.27 2007/07/12 02:54:05 thompsa Exp $ */ -#define NDIS_DEFAULT_NODENAME "FreeBSD NDIS node" +#define NDIS_DEFAULT_NODENAME "MidnightBSD NDIS node" #define NDIS_NODENAME_LEN 32 /* For setting/getting OIDs from userspace. */ @@ -89,10 +89,6 @@ #define NDIS_INC(x) \ (x)->ndis_txidx = ((x)->ndis_txidx + 1) % NDIS_TXPKTS -#if __FreeBSD_version < 600007 -#define arpcom ic.ic_ac -#endif - #define NDIS_EVENTS 4 #define NDIS_EVTINC(x) (x) = ((x) + 1) % NDIS_EVENTS @@ -150,10 +146,6 @@ int ndis_if_flags; int ndis_skip; -#if __FreeBSD_version < 502113 - struct sysctl_ctx_list ndis_ctx; - struct sysctl_oid *ndis_tree; -#endif int ndis_devidx; interface_type ndis_iftype; driver_object *ndis_dobj; @@ -176,9 +168,6 @@ kspin_lock ndis_rxlock; struct taskqueue *ndis_tq; /* private task queue */ -#if __FreeBSD_version < 700000 - struct proc *ndis_tqproc; -#endif struct task ndis_scantask; int (*ndis_newstate)(struct ieee80211com *, enum ieee80211_state, int); Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.1.1.2 -r1.2 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -72,10 +72,6 @@ #include #include -#if __FreeBSD_version < 700046 -#include -#endif - #include #include @@ -144,10 +140,6 @@ static void ndis_resettask (device_object *, void *); static void ndis_inputtask (device_object *, void *); static int ndis_ioctl (struct ifnet *, u_long, caddr_t); -#if __FreeBSD_version < 700046 -static int ndis_wi_ioctl_get (struct ifnet *, u_long, caddr_t); -static int ndis_wi_ioctl_set (struct ifnet *, u_long, caddr_t); -#endif static int ndis_80211_ioctl_get (struct ifnet *, u_long, caddr_t); static int ndis_80211_ioctl_set (struct ifnet *, u_long, caddr_t); static int ndis_newstate (struct ieee80211com *, enum ieee80211_state, @@ -534,16 +526,11 @@ int i; sc = device_get_softc(dev); -#if __FreeBSD_version < 600031 - sc->ifp = &sc->arpcom.ac_if; - ifp = sc->ifp; -#else ifp = sc->ifp = if_alloc(IFT_ETHER); if (ifp == NULL) { error = ENOSPC; goto fail; } -#endif ifp->if_softc = sc; KeInitializeSpinLock(&sc->ndis_spinlock); @@ -559,10 +546,6 @@ } } -#if __FreeBSD_version < 502113 - sysctl_ctx_init(&sc->ndis_ctx); -#endif - /* Create sysctl registry nodes */ ndis_create_sysctls(sc); @@ -699,14 +682,6 @@ /* Check for task offload support. */ ndis_probe_offload(sc); -#if __FreeBSD_version < 502109 - /* - * An NDIS device was detected. Inform the world. - */ - device_printf(dev, "%s address: %6D\n", - sc->ndis_80211 ? "802.11" : "Ethernet", eaddr, ":"); -#endif - if_initname(ifp, device_get_name(dev), device_get_unit(dev)); ifp->if_mtu = ETHERMTU; ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; @@ -715,13 +690,9 @@ ifp->if_watchdog = ndis_watchdog; ifp->if_init = ndis_init; ifp->if_baudrate = 10000000; -#if __FreeBSD_version < 502114 - ifp->if_snd.ifq_maxlen = 50; -#else IFQ_SET_MAXLEN(&ifp->if_snd, 50); ifp->if_snd.ifq_drv_maxlen = 25; IFQ_SET_READY(&ifp->if_snd); -#endif ifp->if_capenable = ifp->if_capabilities; ifp->if_hwassist = sc->ndis_hwassist; @@ -733,22 +704,13 @@ uint32_t arg; int r; -#if __FreeBSD_version >= 700000 sc->ndis_tq = taskqueue_create("nids_taskq", M_NOWAIT | M_ZERO, taskqueue_thread_enqueue, &sc->ndis_tq); taskqueue_start_threads(&sc->ndis_tq, 1, PI_NET, "%s taskq", device_get_nameunit(dev)); -#else - sc->ndis_tq = taskqueue_create("ndis_taskq", M_NOWAIT | M_ZERO, - taskqueue_thread_enqueue, &sc->ndis_tq, &sc->sc_tqproc); - kthread_create(taskqueue_thread_loop, &sc->ndis_tq, &sc->sc_tqproc, - 0, 0, "%s taskq", device_get_nameunit(dev)); -#endif TASK_INIT(&sc->ndis_scantask, 0, ndis_scan, sc); -#if __FreeBSD_version >= 600007 ic->ic_ifp = ifp; -#endif ic->ic_phytype = IEEE80211_T_DS; ic->ic_opmode = IEEE80211_M_STA; ic->ic_caps = IEEE80211_C_IBSS; @@ -867,13 +829,13 @@ IEEE80211_RATE_BASIC|22); } if (isset(ic->ic_modecaps, IEEE80211_MODE_11G)) { - TESTSETRATE(IEEE80211_MODE_11G, 47); + TESTSETRATE(IEEE80211_MODE_11G, 48); TESTSETRATE(IEEE80211_MODE_11G, 72); TESTSETRATE(IEEE80211_MODE_11G, 96); TESTSETRATE(IEEE80211_MODE_11G, 108); } if (isset(ic->ic_modecaps, IEEE80211_MODE_11A)) { - TESTSETRATE(IEEE80211_MODE_11A, 47); + TESTSETRATE(IEEE80211_MODE_11A, 48); TESTSETRATE(IEEE80211_MODE_11A, 72); TESTSETRATE(IEEE80211_MODE_11A, 96); TESTSETRATE(IEEE80211_MODE_11A, 108); @@ -933,15 +895,9 @@ if (r == 0) ic->ic_caps |= IEEE80211_C_PMGT; bcopy(eaddr, &ic->ic_myaddr, sizeof(eaddr)); -#if __FreeBSD_version < 600007 - ieee80211_ifattach(ifp); - ieee80211_media_init(ifp, ieee80211_media_change, - ndis_media_status); -#else ieee80211_ifattach(ic); ieee80211_media_init(ic, ieee80211_media_change, ndis_media_status); -#endif ic->ic_scan_start = ndis_scan_start; ic->ic_scan_end = ndis_scan_end; ic->ic_set_channel = ndis_set_channel; @@ -1004,11 +960,7 @@ NDIS_UNLOCK(sc); ndis_stop(sc); if (sc->ndis_80211) -#if __FreeBSD_version < 600007 - ieee80211_ifdetach(ifp); -#else ieee80211_ifdetach(&sc->ic); -#endif else ether_ifdetach(ifp); } else @@ -1040,10 +992,8 @@ bus_release_resource(dev, SYS_RES_MEMORY, sc->ndis_altmem_rid, sc->ndis_res_altmem); -#if __FreeBSD_version >= 600031 if (ifp != NULL) if_free(ifp); -#endif if (sc->ndis_iftype == PCMCIABus) ndis_free_amem(sc); @@ -1076,9 +1026,6 @@ bus_dma_tag_destroy(sc->ndis_parent_tag); taskqueue_free(sc->ndis_tq); -#if __FreeBSD_version < 502113 - sysctl_ctx_free(&sc->ndis_ctx); -#endif return(0); } @@ -1699,13 +1646,8 @@ } NDIS_LOCK(sc); #ifdef LINK_STATE_UP -#if __FreeBSD_version > 600006 if_link_state_change(sc->ifp, LINK_STATE_UP); #else - sc->ifp->if_link_state = LINK_STATE_UP; - rt_ifmsg(sc->ifp); -#endif -#else device_printf(sc->ndis_dev, "link state changed to UP\n"); #endif /* LINK_STATE_UP */ } @@ -1716,13 +1658,8 @@ if (sc->ndis_80211) ieee80211_new_state(ic, IEEE80211_S_SCAN, 0); #ifdef LINK_STATE_DOWN -#if __FreeBSD_version > 600006 if_link_state_change(sc->ifp, LINK_STATE_DOWN); #else - sc->ifp->if_link_state = LINK_STATE_DOWN; - rt_ifmsg(sc->ifp); -#endif -#else device_printf(sc->ndis_dev, "link state changed to DOWN\n"); #endif /* LINK_STATE_DOWN */ } @@ -1768,11 +1705,7 @@ ifp = arg; -#if __FreeBSD_version < 502114 - if (ifp->if_snd.ifq_head != NULL) -#else if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) -#endif ndis_start(ifp); return; } @@ -1812,11 +1745,7 @@ p0 = &sc->ndis_txarray[sc->ndis_txidx]; while(sc->ndis_txpending) { -#if __FreeBSD_version < 502114 - IF_DEQUEUE(&ifp->if_snd, m); -#else IFQ_DRV_DEQUEUE(&ifp->if_snd, m); -#endif if (m == NULL) break; @@ -1827,13 +1756,8 @@ break; if (ndis_mtop(m, &sc->ndis_txarray[sc->ndis_txidx])) { -#if __FreeBSD_version >= 502114 IFQ_DRV_PREPEND(&ifp->if_snd, m); -#endif NDIS_UNLOCK(sc); -#if __FreeBSD_version < 502114 - IF_PREPEND(&ifp->if_snd, m); -#endif return; } @@ -2002,12 +1926,7 @@ sc->ndis_link = 0; #ifdef LINK_STATE_UNKNOWN -#if __FreeBSD_version > 600006 if_link_state_change(sc->ifp, LINK_STATE_UNKNOWN); -#else - sc->ifp->if_link_state = LINK_STATE_DOWN; - rt_ifmsg(sc->ifp); -#endif #endif /* LINK_STATE_UNKNOWN */ if (ic->ic_opmode != IEEE80211_M_MONITOR) { @@ -2334,15 +2253,10 @@ /* Set WEP */ -#if __FreeBSD_version < 600007 - if (ic->ic_flags & IEEE80211_F_WEPON) { -#else if (ic->ic_flags & IEEE80211_F_PRIVACY && !(ic->ic_flags & IEEE80211_F_WPA)) { -#endif int keys_set = 0; -#if __FreeBSD_version >= 600007 if (ic->ic_bss->ni_authmode == IEEE80211_AUTH_SHARED) { len = sizeof(arg); arg = NDIS_80211_AUTHMODE_SHARED; @@ -2350,14 +2264,11 @@ ndis_set_info(sc, OID_802_11_AUTHENTICATION_MODE, &arg, &len); } -#endif for (i = 0; i < IEEE80211_WEP_NKID; i++) { if (ic->ic_nw_keys[i].wk_keylen) { -#if __FreeBSD_version >= 600007 if (ic->ic_nw_keys[i].wk_cipher->ic_cipher != IEEE80211_CIPHER_WEP) continue; -#endif bzero((char *)&wep, sizeof(wep)); wep.nw_keylen = ic->ic_nw_keys[i].wk_keylen; @@ -2755,7 +2666,6 @@ * reporting isn't supported prior to FreeBSD 6.x. */ -#if __FreeBSD_version >= 600007 len = sizeof(arg); rval = ndis_get_info(sc, OID_802_11_AUTHENTICATION_MODE, &arg, &len); if (rval) @@ -2789,7 +2699,6 @@ break; } } -#endif len = sizeof(arg); rval = ndis_get_info(sc, OID_802_11_WEP_STATUS, &arg, &len); @@ -2798,19 +2707,11 @@ device_printf (sc->ndis_dev, "get wep status failed: %d\n", rval); -#if __FreeBSD_version < 600007 - if (arg == NDIS_80211_WEPSTAT_ENABLED) - ic->ic_flags |= IEEE80211_F_WEPON; - else - ic->ic_flags &= ~IEEE80211_F_WEPON; -#else if (arg == NDIS_80211_WEPSTAT_ENABLED) ic->ic_flags |= IEEE80211_F_PRIVACY|IEEE80211_F_DROPUNENC; else ic->ic_flags &= ~(IEEE80211_F_PRIVACY|IEEE80211_F_DROPUNENC); -#endif - return; } @@ -2867,11 +2768,7 @@ case SIOCGIFMEDIA: case SIOCSIFMEDIA: if (sc->ndis_80211) { -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif if (error == ENETRESET) { ndis_setstate_80211(sc); /*ndis_init(sc);*/ @@ -3003,28 +2900,11 @@ NDIS_EVTINC(sc->ndis_evtcidx); NDIS_UNLOCK(sc); break; -#if __FreeBSD_version < 700046 - case SIOCGIFGENERIC: - case SIOCSIFGENERIC: - if (sc->ndis_80211 && NDIS_INITIALIZED(sc)) { - if (command == SIOCGIFGENERIC) - error = ndis_wi_ioctl_get(ifp, command, data); - else - error = ndis_wi_ioctl_set(ifp, command, data); - } else - error = ENOTTY; - if (error != ENOTTY) - break; -#endif default: do_80211: sc->ndis_skip = 1; if (sc->ndis_80211) { -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif if (error == ENETRESET) { ndis_setstate_80211(sc); error = 0; @@ -3040,126 +2920,6 @@ return(error); } -#if __FreeBSD_version < 700046 -static int -ndis_wi_ioctl_get(ifp, command, data) - struct ifnet *ifp; - u_long command; - caddr_t data; -{ - struct wi_req wreq; - struct ifreq *ifr; - struct ndis_softc *sc; - ndis_80211_bssid_list_ex *bl; - ndis_wlan_bssid_ex *wb; - struct wi_apinfo *api; - int error, i, j, len, maxaps; - - sc = ifp->if_softc; - ifr = (struct ifreq *)data; - error = copyin(ifr->ifr_data, &wreq, sizeof(wreq)); - if (error) - return (error); - - switch (wreq.wi_type) { - case WI_RID_READ_APS: - len = 0; - error = ndis_set_info(sc, OID_802_11_BSSID_LIST_SCAN, - NULL, &len); - if (error == 0) - tsleep(&error, PPAUSE|PCATCH, "ssidscan", hz * 2); - len = 0; - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, NULL, &len); - if (error != ENOSPC) - len = 65536; - bl = malloc(len, M_DEVBUF, M_NOWAIT|M_ZERO); - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); - if (error) { - free(bl, M_DEVBUF); - break; - } - maxaps = (2 * wreq.wi_len - sizeof(int)) / sizeof(*api); - maxaps = MIN(maxaps, bl->nblx_items); - wreq.wi_len = (maxaps * sizeof(*api) + sizeof(int)) / 2; - *(int *)&wreq.wi_val = maxaps; - api = (struct wi_apinfo *)&((int *)&wreq.wi_val)[1]; - wb = bl->nblx_bssid; - while (maxaps--) { - bzero(api, sizeof(*api)); - bcopy(&wb->nwbx_macaddr, &api->bssid, - sizeof(api->bssid)); - api->namelen = wb->nwbx_ssid.ns_ssidlen; - bcopy(&wb->nwbx_ssid.ns_ssid, &api->name, api->namelen); - if (wb->nwbx_privacy) - api->capinfo |= IEEE80211_CAPINFO_PRIVACY; - /* XXX Where can we get noise information? */ - api->signal = wb->nwbx_rssi + 149; /* XXX */ - api->quality = api->signal; - api->channel = - ieee80211_mhz2ieee(wb->nwbx_config.nc_dsconfig / - 1000, 0); - /* In "auto" infrastructure mode, this is useless. */ - if (wb->nwbx_netinfra == NDIS_80211_NET_INFRA_IBSS) - api->capinfo |= IEEE80211_CAPINFO_IBSS; - if (wb->nwbx_len > sizeof(ndis_wlan_bssid)) { - j = sizeof(ndis_80211_rates_ex); - /* handle other extended things */ - } else - j = sizeof(ndis_80211_rates); - for (i = api->rate = 0; i < j; i++) - api->rate = MAX(api->rate, 5 * - (wb->nwbx_supportedrates[i] & 0x7f)); - api++; - wb = (ndis_wlan_bssid_ex *)((char *)wb + wb->nwbx_len); - } - free(bl, M_DEVBUF); - error = copyout(&wreq, ifr->ifr_data, sizeof(wreq)); - break; - default: - error = ENOTTY; - break; - } - return (error); -} - -static int -ndis_wi_ioctl_set(ifp, command, data) - struct ifnet *ifp; - u_long command; - caddr_t data; -{ - struct wi_req wreq; - struct ifreq *ifr; - struct ndis_softc *sc; - uint32_t foo; - int error, len; - - error = priv_check(curthread, PRIV_DRIVER); - if (error) - return (error); - - sc = ifp->if_softc; - ifr = (struct ifreq *)data; - error = copyin(ifr->ifr_data, &wreq, sizeof(wreq)); - if (error) - return (error); - - switch (wreq.wi_type) { - case WI_RID_SCAN_APS: - case WI_RID_SCAN_REQ: /* arguments ignored */ - len = sizeof(foo); - foo = 0; - error = ndis_set_info(sc, OID_802_11_BSSID_LIST_SCAN, &foo, - &len); - break; - default: - error = ENOTTY; - break; - } - return (error); -} -#endif - static int ndis_80211_ioctl_get(struct ifnet *ifp, u_long command, caddr_t data) { @@ -3195,11 +2955,7 @@ RtlFreeAnsiString(&as); break; default: -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif break; } @@ -3362,11 +3118,7 @@ RtlFreeUnicodeString(&us); break; default: -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif if (error == ENETRESET) { ndis_setstate_80211(sc); error = 0; From laffer1 at midnightbsd.org Mon Jan 19 17:02:26 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:02:26 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/bwi: Add bwi to MidnightBSD. Message-ID: <200901192202.n0JM2QYs074527@stargazer.midnightbsd.org> Log Message: ----------- Add bwi to MidnightBSD. bwi is a very limited broadcom wireless nic adapter from DragonFly, NetBSD, and OpenBSD. This is not connected to the build and requires a firmware which is hard to come by. Added Files: ----------- src/sys/dev/bwi: bitops.h (r1.1) bwimac.c (r1.1) bwimac.h (r1.1) bwiphy.c (r1.1) bwiphy.h (r1.1) bwirf.c (r1.1) bwirf.h (r1.1) if_bwi.c (r1.1) if_bwi_pci.c (r1.1) if_bwireg.h (r1.1) if_bwivar.h (r1.1) -------------- next part -------------- --- /dev/null +++ sys/dev/bwi/bwiphy.h @@ -0,0 +1,224 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwiphy.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwiphy.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BWI_PHY_H +#define _BWI_PHY_H + +struct bwi_gains { + int16_t tbl_gain1; + int16_t tbl_gain2; + int16_t phy_gain; +}; + +int bwi_phy_attach(struct bwi_mac *); +void bwi_phy_clear_state(struct bwi_phy *); + +int bwi_phy_calibrate(struct bwi_mac *); +void bwi_phy_set_bbp_atten(struct bwi_mac *, uint16_t); + +void bwi_set_gains(struct bwi_mac *, const struct bwi_gains *); +int16_t bwi_nrssi_read(struct bwi_mac *, uint16_t); +void bwi_nrssi_write(struct bwi_mac *, uint16_t, int16_t); + +uint16_t bwi_phy_read(struct bwi_mac *, uint16_t); +void bwi_phy_write(struct bwi_mac *, uint16_t, uint16_t); + +static __inline void +bwi_phy_init(struct bwi_mac *_mac) +{ + _mac->mac_phy.phy_init(_mac); +} + +#define PHY_WRITE(mac, ctrl, val) bwi_phy_write((mac), (ctrl), (val)) +#define PHY_READ(mac, ctrl) bwi_phy_read((mac), (ctrl)) + +#define PHY_SETBITS(mac, ctrl, bits) \ + PHY_WRITE((mac), (ctrl), PHY_READ((mac), (ctrl)) | (bits)) +#define PHY_CLRBITS(mac, ctrl, bits) \ + PHY_WRITE((mac), (ctrl), PHY_READ((mac), (ctrl)) & ~(bits)) +#define PHY_FILT_SETBITS(mac, ctrl, filt, bits) \ + PHY_WRITE((mac), (ctrl), (PHY_READ((mac), (ctrl)) & (filt)) | (bits)) + +#define BWI_PHYR_NRSSI_THR_11B 0x020 +#define BWI_PHYR_BBP_ATTEN 0x060 +#define BWI_PHYR_TBL_CTRL_11A 0x072 +#define BWI_PHYR_TBL_DATA_LO_11A 0x073 +#define BWI_PHYR_TBL_DATA_HI_11A 0x074 +#define BWI_PHYR_TBL_CTRL_11G 0x472 +#define BWI_PHYR_TBL_DATA_LO_11G 0x473 +#define BWI_PHYR_TBL_DATA_HI_11G 0x474 +#define BWI_PHYR_NRSSI_THR_11G 0x48a +#define BWI_PHYR_NRSSI_CTRL 0x803 +#define BWI_PHYR_NRSSI_DATA 0x804 +#define BWI_PHYR_RF_LO 0x810 + +/* + * PHY Tables + */ +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/FineFrequency + * G PHY + */ +#define BWI_PHY_FREQ_11G_REV1 \ + 0x0089, 0x02e9, 0x0409, 0x04e9, 0x05a9, 0x0669, 0x0709, 0x0789, \ + 0x0829, 0x08a9, 0x0929, 0x0989, 0x0a09, 0x0a69, 0x0ac9, 0x0b29, \ + 0x0ba9, 0x0be9, 0x0c49, 0x0ca9, 0x0d09, 0x0d69, 0x0da9, 0x0e09, \ + 0x0e69, 0x0ea9, 0x0f09, 0x0f49, 0x0fa9, 0x0fe9, 0x1029, 0x1089, \ + 0x10c9, 0x1109, 0x1169, 0x11a9, 0x11e9, 0x1229, 0x1289, 0x12c9, \ + 0x1309, 0x1349, 0x1389, 0x13c9, 0x1409, 0x1449, 0x14a9, 0x14e9, \ + 0x1529, 0x1569, 0x15a9, 0x15e9, 0x1629, 0x1669, 0x16a9, 0x16e8, \ + 0x1728, 0x1768, 0x17a8, 0x17e8, 0x1828, 0x1868, 0x18a8, 0x18e8, \ + 0x1928, 0x1968, 0x19a8, 0x19e8, 0x1a28, 0x1a68, 0x1aa8, 0x1ae8, \ + 0x1b28, 0x1b68, 0x1ba8, 0x1be8, 0x1c28, 0x1c68, 0x1ca8, 0x1ce8, \ + 0x1d28, 0x1d68, 0x1dc8, 0x1e08, 0x1e48, 0x1e88, 0x1ec8, 0x1f08, \ + 0x1f48, 0x1f88, 0x1fe8, 0x2028, 0x2068, 0x20a8, 0x2108, 0x2148, \ + 0x2188, 0x21c8, 0x2228, 0x2268, 0x22c8, 0x2308, 0x2348, 0x23a8, \ + 0x23e8, 0x2448, 0x24a8, 0x24e8, 0x2548, 0x25a8, 0x2608, 0x2668, \ + 0x26c8, 0x2728, 0x2787, 0x27e7, 0x2847, 0x28c7, 0x2947, 0x29a7, \ + 0x2a27, 0x2ac7, 0x2b47, 0x2be7, 0x2ca7, 0x2d67, 0x2e47, 0x2f67, \ + 0x3247, 0x3526, 0x3646, 0x3726, 0x3806, 0x38a6, 0x3946, 0x39e6, \ + 0x3a66, 0x3ae6, 0x3b66, 0x3bc6, 0x3c45, 0x3ca5, 0x3d05, 0x3d85, \ + 0x3de5, 0x3e45, 0x3ea5, 0x3ee5, 0x3f45, 0x3fa5, 0x4005, 0x4045, \ + 0x40a5, 0x40e5, 0x4145, 0x4185, 0x41e5, 0x4225, 0x4265, 0x42c5, \ + 0x4305, 0x4345, 0x43a5, 0x43e5, 0x4424, 0x4464, 0x44c4, 0x4504, \ + 0x4544, 0x4584, 0x45c4, 0x4604, 0x4644, 0x46a4, 0x46e4, 0x4724, \ + 0x4764, 0x47a4, 0x47e4, 0x4824, 0x4864, 0x48a4, 0x48e4, 0x4924, \ + 0x4964, 0x49a4, 0x49e4, 0x4a24, 0x4a64, 0x4aa4, 0x4ae4, 0x4b23, \ + 0x4b63, 0x4ba3, 0x4be3, 0x4c23, 0x4c63, 0x4ca3, 0x4ce3, 0x4d23, \ + 0x4d63, 0x4da3, 0x4de3, 0x4e23, 0x4e63, 0x4ea3, 0x4ee3, 0x4f23, \ + 0x4f63, 0x4fc3, 0x5003, 0x5043, 0x5083, 0x50c3, 0x5103, 0x5143, \ + 0x5183, 0x51e2, 0x5222, 0x5262, 0x52a2, 0x52e2, 0x5342, 0x5382, \ + 0x53c2, 0x5402, 0x5462, 0x54a2, 0x5502, 0x5542, 0x55a2, 0x55e2, \ + 0x5642, 0x5682, 0x56e2, 0x5722, 0x5782, 0x57e1, 0x5841, 0x58a1, \ + 0x5901, 0x5961, 0x59c1, 0x5a21, 0x5aa1, 0x5b01, 0x5b81, 0x5be1, \ + 0x5c61, 0x5d01, 0x5d80, 0x5e20, 0x5ee0, 0x5fa0, 0x6080, 0x61c0 + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/noise_table + */ +/* G PHY Revision 1 */ +#define BWI_PHY_NOISE_11G_REV1 \ + 0x013c, 0x01f5, 0x031a, 0x0631, 0x0001, 0x0001, 0x0001, 0x0001 +/* G PHY generic */ +#define BWI_PHY_NOISE_11G \ + 0x5484, 0x3c40, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/rotor_table + * G PHY Revision 1 + */ +#define BWI_PHY_ROTOR_11G_REV1 \ + 0xfeb93ffd, 0xfec63ffd, 0xfed23ffd, 0xfedf3ffd, \ + 0xfeec3ffe, 0xfef83ffe, 0xff053ffe, 0xff113ffe, \ + 0xff1e3ffe, 0xff2a3fff, 0xff373fff, 0xff443fff, \ + 0xff503fff, 0xff5d3fff, 0xff693fff, 0xff763fff, \ + 0xff824000, 0xff8f4000, 0xff9b4000, 0xffa84000, \ + 0xffb54000, 0xffc14000, 0xffce4000, 0xffda4000, \ + 0xffe74000, 0xfff34000, 0x00004000, 0x000d4000, \ + 0x00194000, 0x00264000, 0x00324000, 0x003f4000, \ + 0x004b4000, 0x00584000, 0x00654000, 0x00714000, \ + 0x007e4000, 0x008a3fff, 0x00973fff, 0x00a33fff, \ + 0x00b03fff, 0x00bc3fff, 0x00c93fff, 0x00d63fff, \ + 0x00e23ffe, 0x00ef3ffe, 0x00fb3ffe, 0x01083ffe, \ + 0x01143ffe, 0x01213ffd, 0x012e3ffd, 0x013a3ffd, \ + 0x01473ffd + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/noise_scale_table + */ +/* G PHY Revision [0,2] */ +#define BWI_PHY_NOISE_SCALE_11G_REV2 \ + 0x6c77, 0x5162, 0x3b40, 0x3335, 0x2f2d, 0x2a2a, 0x2527, 0x1f21, \ + 0x1a1d, 0x1719, 0x1616, 0x1414, 0x1414, 0x1400, 0x1414, 0x1614, \ + 0x1716, 0x1a19, 0x1f1d, 0x2521, 0x2a27, 0x2f2a, 0x332d, 0x3b35, \ + 0x5140, 0x6c62, 0x0077 +/* G PHY Revsion 7 */ +#define BWI_PHY_NOISE_SCALE_11G_REV7 \ + 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, \ + 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa400, 0xa4a4, 0xa4a4, \ + 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, \ + 0xa4a4, 0xa4a4, 0x00a4 +/* G PHY generic */ +#define BWI_PHY_NOISE_SCALE_11G \ + 0xd8dd, 0xcbd4, 0xbcc0, 0xb6b7, 0xb2b0, 0xadad, 0xa7a9, 0x9fa1, \ + 0x969b, 0x9195, 0x8f8f, 0x8a8a, 0x8a8a, 0x8a00, 0x8a8a, 0x8f8a, \ + 0x918f, 0x9695, 0x9f9b, 0xa7a1, 0xada9, 0xb2ad, 0xb6b0, 0xbcb7, \ + 0xcbc0, 0xd8d4, 0x00dd + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/sigma_square_table + */ +/* G PHY Revision 2 */ +#define BWI_PHY_SIGMA_SQ_11G_REV2 \ + 0x007a, 0x0075, 0x0071, 0x006c, 0x0067, 0x0063, 0x005e, 0x0059, \ + 0x0054, 0x0050, 0x004b, 0x0046, 0x0042, 0x003d, 0x003d, 0x003d, \ + 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, \ + 0x003d, 0x003d, 0x0000, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, \ + 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, \ + 0x0042, 0x0046, 0x004b, 0x0050, 0x0054, 0x0059, 0x005e, 0x0063, \ + 0x0067, 0x006c, 0x0071, 0x0075, 0x007a +/* G PHY Revision (2,7] */ +#define BWI_PHY_SIGMA_SQ_11G_REV7 \ + 0x00de, 0x00dc, 0x00da, 0x00d8, 0x00d6, 0x00d4, 0x00d2, 0x00cf, \ + 0x00cd, 0x00ca, 0x00c7, 0x00c4, 0x00c1, 0x00be, 0x00be, 0x00be, \ + 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, \ + 0x00be, 0x00be, 0x0000, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, \ + 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, \ + 0x00c1, 0x00c4, 0x00c7, 0x00ca, 0x00cd, 0x00cf, 0x00d2, 0x00d4, \ + 0x00d6, 0x00d8, 0x00da, 0x00dc, 0x00de + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/retard_table + * G PHY + */ +#define BWI_PHY_DELAY_11G_REV1 \ + 0xdb93cb87, 0xd666cf64, 0xd1fdd358, 0xcda6d826, \ + 0xca38dd9f, 0xc729e2b4, 0xc469e88e, 0xc26aee2b, \ + 0xc0def46c, 0xc073fa62, 0xc01d00d5, 0xc0760743, \ + 0xc1560d1e, 0xc2e51369, 0xc4ed18ff, 0xc7ac1ed7, \ + 0xcb2823b2, 0xcefa28d9, 0xd2f62d3f, 0xd7bb3197, \ + 0xdce53568, 0xe1fe3875, 0xe7d13b35, 0xed663d35, \ + 0xf39b3ec4, 0xf98e3fa7, 0x00004000, 0x06723fa7, \ + 0x0c653ec4, 0x129a3d35, 0x182f3b35, 0x1e023875, \ + 0x231b3568, 0x28453197, 0x2d0a2d3f, 0x310628d9, \ + 0x34d823b2, 0x38541ed7, 0x3b1318ff, 0x3d1b1369, \ + 0x3eaa0d1e, 0x3f8a0743, 0x3fe300d5, 0x3f8dfa62, \ + 0x3f22f46c, 0x3d96ee2b, 0x3b97e88e, 0x38d7e2b4, \ + 0x35c8dd9f, 0x325ad826, 0x2e03d358, 0x299acf64, \ + 0x246dcb87 + +#endif /* !_BWI_PHY_H */ --- /dev/null +++ sys/dev/bwi/bwirf.c @@ -0,0 +1,2497 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwirf.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwirf.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" +#include "bwiphy.h" + +#define RF_LO_WRITE(mac, lo) bwi_rf_lo_write((mac), (lo)) + +#define BWI_RF_2GHZ_CHAN(chan) \ + (ieee80211_ieee2mhz((chan), IEEE80211_CHAN_2GHZ) - 2400) + +#define BWI_DEFAULT_IDLE_TSSI 52 + +struct rf_saveregs { + uint16_t phy_15; + uint16_t phy_2a; + uint16_t phy_35; + uint16_t phy_60; + uint16_t phy_429; + uint16_t phy_802; + uint16_t phy_811; + uint16_t phy_812; + uint16_t phy_814; + uint16_t phy_815; + + uint16_t rf_43; + uint16_t rf_52; + uint16_t rf_7a; +}; + +#define SAVE_RF_REG(mac, regs, n) (regs)->rf_##n = RF_READ((mac), 0x##n) +#define RESTORE_RF_REG(mac, regs, n) RF_WRITE((mac), 0x##n, (regs)->rf_##n) + +#define SAVE_PHY_REG(mac, regs, n) (regs)->phy_##n = PHY_READ((mac), 0x##n) +#define RESTORE_PHY_REG(mac, regs, n) PHY_WRITE((mac), 0x##n, (regs)->phy_##n) + +static int bwi_rf_calc_txpower(int8_t *, uint8_t, const int16_t[]); +static void bwi_rf_work_around(struct bwi_mac *, u_int); +static int bwi_rf_gain_max_reached(struct bwi_mac *, int); +static uint16_t bwi_rf_calibval(struct bwi_mac *); +static uint16_t bwi_rf_get_tp_ctrl2(struct bwi_mac *); +static uint32_t bwi_rf_lo_devi_measure(struct bwi_mac *, uint16_t); +static void bwi_rf_lo_measure(struct bwi_mac *, + const struct bwi_rf_lo *, struct bwi_rf_lo *, uint8_t); +static uint8_t _bwi_rf_lo_update(struct bwi_mac *, uint16_t); + +static void bwi_rf_lo_write(struct bwi_mac *, const struct bwi_rf_lo *); + +static void bwi_rf_set_nrssi_ofs_11g(struct bwi_mac *); +static void bwi_rf_calc_nrssi_slope_11b(struct bwi_mac *); +static void bwi_rf_calc_nrssi_slope_11g(struct bwi_mac *); +static void bwi_rf_set_nrssi_thr_11b(struct bwi_mac *); +static void bwi_rf_set_nrssi_thr_11g(struct bwi_mac *); + +static void bwi_rf_init_sw_nrssi_table(struct bwi_mac *); + +static int bwi_rf_calc_rssi_bcm2050(struct bwi_mac *, + const struct bwi_rxbuf_hdr *); +static int bwi_rf_calc_rssi_bcm2053(struct bwi_mac *, + const struct bwi_rxbuf_hdr *); +static int bwi_rf_calc_rssi_bcm2060(struct bwi_mac *, + const struct bwi_rxbuf_hdr *); + +static void bwi_rf_on_11a(struct bwi_mac *); +static void bwi_rf_on_11bg(struct bwi_mac *); + +static void bwi_rf_off_11a(struct bwi_mac *); +static void bwi_rf_off_11bg(struct bwi_mac *); +static void bwi_rf_off_11g_rev5(struct bwi_mac *); + +static const int8_t bwi_txpower_map_11b[BWI_TSSI_MAX] = + { BWI_TXPOWER_MAP_11B }; +static const int8_t bwi_txpower_map_11g[BWI_TSSI_MAX] = + { BWI_TXPOWER_MAP_11G }; + +static __inline int16_t +bwi_nrssi_11g(struct bwi_mac *mac) +{ + int16_t val; + +#define NRSSI_11G_MASK __BITS(13, 8) + + val = (int16_t)__SHIFTOUT(PHY_READ(mac, 0x47f), NRSSI_11G_MASK); + if (val >= 32) + val -= 64; + return val; + +#undef NRSSI_11G_MASK +} + +static __inline struct bwi_rf_lo * +bwi_get_rf_lo(struct bwi_mac *mac, uint16_t rf_atten, uint16_t bbp_atten) +{ + int n; + + n = rf_atten + (14 * (bbp_atten / 2)); + KASSERT(n < BWI_RFLO_MAX, ("n %d", n)); + + return &mac->mac_rf.rf_lo[n]; +} + +static __inline int +bwi_rf_lo_isused(struct bwi_mac *mac, const struct bwi_rf_lo *lo) +{ + struct bwi_rf *rf = &mac->mac_rf; + int idx; + + idx = lo - rf->rf_lo; + KASSERT(idx >= 0 && idx < BWI_RFLO_MAX, ("idx %d", idx)); + + return isset(rf->rf_lo_used, idx); +} + +void +bwi_rf_write(struct bwi_mac *mac, uint16_t ctrl, uint16_t data) +{ + struct bwi_softc *sc = mac->mac_sc; + + CSR_WRITE_2(sc, BWI_RF_CTRL, ctrl); + CSR_WRITE_2(sc, BWI_RF_DATA_LO, data); +} + +uint16_t +bwi_rf_read(struct bwi_mac *mac, uint16_t ctrl) +{ + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_softc *sc = mac->mac_sc; + + ctrl |= rf->rf_ctrl_rd; + if (rf->rf_ctrl_adj) { + /* XXX */ + if (ctrl < 0x70) + ctrl += 0x80; + else if (ctrl < 0x80) + ctrl += 0x70; + } + + CSR_WRITE_2(sc, BWI_RF_CTRL, ctrl); + return CSR_READ_2(sc, BWI_RF_DATA_LO); +} + +int +bwi_rf_attach(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t type, manu; + uint8_t rev; + + /* + * Get RF manufacture/type/revision + */ + if (sc->sc_bbp_id == BWI_BBPID_BCM4317) { + /* + * Fake a BCM2050 RF + */ + manu = BWI_RF_MANUFACT_BCM; + type = BWI_RF_T_BCM2050; + if (sc->sc_bbp_rev == 0) + rev = 3; + else if (sc->sc_bbp_rev == 1) + rev = 4; + else + rev = 5; + } else { + uint32_t val; + + CSR_WRITE_2(sc, BWI_RF_CTRL, BWI_RF_CTRL_RFINFO); + val = CSR_READ_2(sc, BWI_RF_DATA_HI); + val <<= 16; + + CSR_WRITE_2(sc, BWI_RF_CTRL, BWI_RF_CTRL_RFINFO); + val |= CSR_READ_2(sc, BWI_RF_DATA_LO); + + manu = __SHIFTOUT(val, BWI_RFINFO_MANUFACT_MASK); + type = __SHIFTOUT(val, BWI_RFINFO_TYPE_MASK); + rev = __SHIFTOUT(val, BWI_RFINFO_REV_MASK); + } + device_printf(sc->sc_dev, "RF: manu 0x%03x, type 0x%04x, rev %u\n", + manu, type, rev); + + /* + * Verify whether the RF is supported + */ + rf->rf_ctrl_rd = 0; + rf->rf_ctrl_adj = 0; + switch (mac->mac_phy.phy_mode) { + case IEEE80211_MODE_11A: + if (manu != BWI_RF_MANUFACT_BCM || + type != BWI_RF_T_BCM2060 || + rev != 1) { + device_printf(sc->sc_dev, "only BCM2060 rev 1 RF " + "is supported for 11A PHY\n"); + return ENXIO; + } + rf->rf_ctrl_rd = BWI_RF_CTRL_RD_11A; + rf->rf_on = bwi_rf_on_11a; + rf->rf_off = bwi_rf_off_11a; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2060; + break; + case IEEE80211_MODE_11B: + if (type == BWI_RF_T_BCM2050) { + rf->rf_ctrl_rd = BWI_RF_CTRL_RD_11BG; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2050; + } else if (type == BWI_RF_T_BCM2053) { + rf->rf_ctrl_adj = 1; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2053; + } else { + device_printf(sc->sc_dev, "only BCM2050/BCM2053 RF " + "is supported for 11B PHY\n"); + return ENXIO; + } + rf->rf_on = bwi_rf_on_11bg; + rf->rf_off = bwi_rf_off_11bg; + rf->rf_calc_nrssi_slope = bwi_rf_calc_nrssi_slope_11b; + rf->rf_set_nrssi_thr = bwi_rf_set_nrssi_thr_11b; + break; + case IEEE80211_MODE_11G: + if (type != BWI_RF_T_BCM2050) { + device_printf(sc->sc_dev, "only BCM2050 RF " + "is supported for 11G PHY\n"); + return ENXIO; + } + rf->rf_ctrl_rd = BWI_RF_CTRL_RD_11BG; + rf->rf_on = bwi_rf_on_11bg; + if (mac->mac_rev >= 5) + rf->rf_off = bwi_rf_off_11g_rev5; + else + rf->rf_off = bwi_rf_off_11bg; + rf->rf_calc_nrssi_slope = bwi_rf_calc_nrssi_slope_11g; + rf->rf_set_nrssi_thr = bwi_rf_set_nrssi_thr_11g; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2050; + break; + default: + device_printf(sc->sc_dev, "unsupported PHY mode\n"); + return ENXIO; + } + + rf->rf_type = type; + rf->rf_rev = rev; + rf->rf_manu = manu; + rf->rf_curchan = IEEE80211_CHAN_ANY; + rf->rf_ant_mode = BWI_ANT_MODE_AUTO; + return 0; +} + +void +bwi_rf_set_chan(struct bwi_mac *mac, u_int chan, int work_around) +{ + struct bwi_softc *sc = mac->mac_sc; + + if (chan == IEEE80211_CHAN_ANY) + return; + + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_CHAN, chan); + + /* TODO: 11A */ + + if (work_around) + bwi_rf_work_around(mac, chan); + + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(chan)); + + if (chan == 14) { + if (sc->sc_locale == BWI_SPROM_LOCALE_JAPAN) + HFLAGS_CLRBITS(mac, BWI_HFLAG_NOT_JAPAN); + else + HFLAGS_SETBITS(mac, BWI_HFLAG_NOT_JAPAN); + CSR_SETBITS_2(sc, BWI_RF_CHAN_EX, (1 << 11)); /* XXX */ + } else { + CSR_CLRBITS_2(sc, BWI_RF_CHAN_EX, 0x840); /* XXX */ + } + DELAY(8000); /* DELAY(2000); */ + + mac->mac_rf.rf_curchan = chan; +} + +void +bwi_rf_get_gains(struct bwi_mac *mac) +{ +#define SAVE_PHY_MAX 15 +#define SAVE_RF_MAX 3 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x52, 0x43, 0x7a }; + static const uint16_t save_phy_regs[SAVE_PHY_MAX] = { + 0x0429, 0x0001, 0x0811, 0x0812, + 0x0814, 0x0815, 0x005a, 0x0059, + 0x0058, 0x000a, 0x0003, 0x080f, + 0x0810, 0x002b, 0x0015 + }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t save_phy[SAVE_PHY_MAX]; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t trsw; + int i, j, loop1_max, loop1, loop2; + + /* + * Save PHY/RF registers for later restoration + */ + for (i = 0; i < SAVE_PHY_MAX; ++i) + save_phy[i] = PHY_READ(mac, save_phy_regs[i]); + PHY_READ(mac, 0x2d); /* dummy read */ + + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + + PHY_CLRBITS(mac, 0x429, 0xc000); + PHY_SETBITS(mac, 0x1, 0x8000); + + PHY_SETBITS(mac, 0x811, 0x2); + PHY_CLRBITS(mac, 0x812, 0x2); + PHY_SETBITS(mac, 0x811, 0x1); + PHY_CLRBITS(mac, 0x812, 0x1); + + PHY_SETBITS(mac, 0x814, 0x1); + PHY_CLRBITS(mac, 0x815, 0x1); + PHY_SETBITS(mac, 0x814, 0x2); + PHY_CLRBITS(mac, 0x815, 0x2); + + PHY_SETBITS(mac, 0x811, 0xc); + PHY_SETBITS(mac, 0x812, 0xc); + PHY_SETBITS(mac, 0x811, 0x30); + PHY_FILT_SETBITS(mac, 0x812, 0xffcf, 0x10); + + PHY_WRITE(mac, 0x5a, 0x780); + PHY_WRITE(mac, 0x59, 0xc810); + PHY_WRITE(mac, 0x58, 0xd); + PHY_SETBITS(mac, 0xa, 0x2000); + + PHY_SETBITS(mac, 0x814, 0x4); + PHY_CLRBITS(mac, 0x815, 0x4); + + PHY_FILT_SETBITS(mac, 0x3, 0xff9f, 0x40); + + if (rf->rf_rev == 8) { + loop1_max = 15; + RF_WRITE(mac, 0x43, loop1_max); + } else { + loop1_max = 9; + RF_WRITE(mac, 0x52, 0x0); + RF_FILT_SETBITS(mac, 0x43, 0xfff0, loop1_max); + } + + bwi_phy_set_bbp_atten(mac, 11); + + if (phy->phy_rev >= 3) + PHY_WRITE(mac, 0x80f, 0xc020); + else + PHY_WRITE(mac, 0x80f, 0x8020); + PHY_WRITE(mac, 0x810, 0); + + PHY_FILT_SETBITS(mac, 0x2b, 0xffc0, 0x1); + PHY_FILT_SETBITS(mac, 0x2b, 0xc0ff, 0x800); + PHY_SETBITS(mac, 0x811, 0x100); + PHY_CLRBITS(mac, 0x812, 0x3000); + + if ((sc->sc_card_flags & BWI_CARD_F_EXT_LNA) && + phy->phy_rev >= 7) { + PHY_SETBITS(mac, 0x811, 0x800); + PHY_SETBITS(mac, 0x812, 0x8000); + } + RF_CLRBITS(mac, 0x7a, 0xff08); + + /* + * Find out 'loop1/loop2', which will be used to calculate + * max loopback gain later + */ + j = 0; + for (i = 0; i < loop1_max; ++i) { + for (j = 0; j < 16; ++j) { + RF_WRITE(mac, 0x43, i); + + if (bwi_rf_gain_max_reached(mac, j)) + goto loop1_exit; + } + } +loop1_exit: + loop1 = i; + loop2 = j; + + /* + * Find out 'trsw', which will be used to calculate + * TRSW(TX/RX switch) RX gain later + */ + if (loop2 >= 8) { + PHY_SETBITS(mac, 0x812, 0x30); + trsw = 0x1b; + for (i = loop2 - 8; i < 16; ++i) { + trsw -= 3; + if (bwi_rf_gain_max_reached(mac, i)) + break; + } + } else { + trsw = 0x18; + } + + /* + * Restore saved PHY/RF registers + */ + /* First 4 saved PHY registers need special processing */ + for (i = 4; i < SAVE_PHY_MAX; ++i) + PHY_WRITE(mac, save_phy_regs[i], save_phy[i]); + + bwi_phy_set_bbp_atten(mac, mac->mac_tpctl.bbp_atten); + + for (i = 0; i < SAVE_RF_MAX; ++i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + PHY_WRITE(mac, save_phy_regs[2], save_phy[2] | 0x3); + DELAY(10); + PHY_WRITE(mac, save_phy_regs[2], save_phy[2]); + PHY_WRITE(mac, save_phy_regs[3], save_phy[3]); + PHY_WRITE(mac, save_phy_regs[0], save_phy[0]); + PHY_WRITE(mac, save_phy_regs[1], save_phy[1]); + + /* + * Calculate gains + */ + rf->rf_lo_gain = (loop2 * 6) - (loop1 * 4) - 11; + rf->rf_rx_gain = trsw * 2; + DPRINTF(mac->mac_sc, "lo gain: %u, rx gain: %u\n", + rf->rf_lo_gain, rf->rf_rx_gain); + +#undef SAVE_RF_MAX +#undef SAVE_PHY_MAX +} + +void +bwi_rf_init(struct bwi_mac *mac) +{ + struct bwi_rf *rf = &mac->mac_rf; + + if (rf->rf_type == BWI_RF_T_BCM2060) { + /* TODO: 11A */ + } else { + if (rf->rf_flags & BWI_RF_F_INITED) + RF_WRITE(mac, 0x78, rf->rf_calib); + else + bwi_rf_init_bcm2050(mac); + } +} + +static void +bwi_rf_off_11a(struct bwi_mac *mac) +{ + RF_WRITE(mac, 0x4, 0xff); + RF_WRITE(mac, 0x5, 0xfb); + + PHY_SETBITS(mac, 0x10, 0x8); + PHY_SETBITS(mac, 0x11, 0x8); + + PHY_WRITE(mac, 0x15, 0xaa00); +} + +static void +bwi_rf_off_11bg(struct bwi_mac *mac) +{ + PHY_WRITE(mac, 0x15, 0xaa00); +} + +static void +bwi_rf_off_11g_rev5(struct bwi_mac *mac) +{ + PHY_SETBITS(mac, 0x811, 0x8c); + PHY_CLRBITS(mac, 0x812, 0x8c); +} + +static void +bwi_rf_work_around(struct bwi_mac *mac, u_int chan) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + + if (chan == IEEE80211_CHAN_ANY) { + device_printf(sc->sc_dev, "%s invalid channel!!\n", __func__); + return; + } + + if (rf->rf_type != BWI_RF_T_BCM2050 || rf->rf_rev >= 6) + return; + + if (chan <= 10) + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(chan + 4)); + else + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(1)); + DELAY(1000); + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(chan)); +} + +static __inline struct bwi_rf_lo * +bwi_rf_lo_find(struct bwi_mac *mac, const struct bwi_tpctl *tpctl) +{ + uint16_t rf_atten, bbp_atten; + int remap_rf_atten; + + remap_rf_atten = 1; + if (tpctl == NULL) { + bbp_atten = 2; + rf_atten = 3; + } else { + if (tpctl->tp_ctrl1 == 3) + remap_rf_atten = 0; + + bbp_atten = tpctl->bbp_atten; + rf_atten = tpctl->rf_atten; + + if (bbp_atten > 6) + bbp_atten = 6; + } + + if (remap_rf_atten) { +#define MAP_MAX 10 + static const uint16_t map[MAP_MAX] = + { 11, 10, 11, 12, 13, 12, 13, 12, 13, 12 }; + +#if 0 + KASSERT(rf_atten < MAP_MAX, ("rf_atten %d", rf_atten)); + rf_atten = map[rf_atten]; +#else + if (rf_atten >= MAP_MAX) { + rf_atten = 0; /* XXX */ + } else { + rf_atten = map[rf_atten]; + } +#endif +#undef MAP_MAX + } + + return bwi_get_rf_lo(mac, rf_atten, bbp_atten); +} + +void +bwi_rf_lo_adjust(struct bwi_mac *mac, const struct bwi_tpctl *tpctl) +{ + const struct bwi_rf_lo *lo; + + lo = bwi_rf_lo_find(mac, tpctl); + RF_LO_WRITE(mac, lo); +} + +static void +bwi_rf_lo_write(struct bwi_mac *mac, const struct bwi_rf_lo *lo) +{ + uint16_t val; + + val = (uint8_t)lo->ctrl_lo; + val |= ((uint8_t)lo->ctrl_hi) << 8; + + PHY_WRITE(mac, BWI_PHYR_RF_LO, val); +} + +static int +bwi_rf_gain_max_reached(struct bwi_mac *mac, int idx) +{ + PHY_FILT_SETBITS(mac, 0x812, 0xf0ff, idx << 8); + PHY_FILT_SETBITS(mac, 0x15, 0xfff, 0xa000); + PHY_SETBITS(mac, 0x15, 0xf000); + + DELAY(20); + + return (PHY_READ(mac, 0x2d) >= 0xdfc); +} + +/* XXX use bitmap array */ +static __inline uint16_t +bitswap4(uint16_t val) +{ + uint16_t ret; + + ret = (val & 0x8) >> 3; + ret |= (val & 0x4) >> 1; + ret |= (val & 0x2) << 1; + ret |= (val & 0x1) << 3; + return ret; +} + +static __inline uint16_t +bwi_phy812_value(struct bwi_mac *mac, uint16_t lpd) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t lo_gain, ext_lna, loop; + + if ((phy->phy_flags & BWI_PHY_F_LINKED) == 0) + return 0; + + lo_gain = rf->rf_lo_gain; + if (rf->rf_rev == 8) + lo_gain += 0x3e; + else + lo_gain += 0x26; + + if (lo_gain >= 0x46) { + lo_gain -= 0x46; + ext_lna = 0x3000; + } else if (lo_gain >= 0x3a) { + lo_gain -= 0x3a; + ext_lna = 0x1000; + } else if (lo_gain >= 0x2e) { + lo_gain -= 0x2e; + ext_lna = 0x2000; + } else { + lo_gain -= 0x10; + ext_lna = 0; + } + + for (loop = 0; loop < 16; ++loop) { + lo_gain -= (6 * loop); + if (lo_gain < 6) + break; + } + + if (phy->phy_rev >= 7 && (sc->sc_card_flags & BWI_CARD_F_EXT_LNA)) { + if (ext_lna) + ext_lna |= 0x8000; + ext_lna |= (loop << 8); + switch (lpd) { + case 0x011: + return 0x8f92; + case 0x001: + return (0x8092 | ext_lna); + case 0x101: + return (0x2092 | ext_lna); + case 0x100: + return (0x2093 | ext_lna); + default: + panic("unsupported lpd\n"); + } + } else { + ext_lna |= (loop << 8); + switch (lpd) { + case 0x011: + return 0xf92; + case 0x001: + case 0x101: + return (0x92 | ext_lna); + case 0x100: + return (0x93 | ext_lna); + default: + panic("unsupported lpd\n"); + } + } + + panic("never reached\n"); + return 0; +} + +void +bwi_rf_init_bcm2050(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 3 +#define SAVE_PHY_COMM_MAX 4 +#define SAVE_PHY_11G_MAX 6 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x0043, 0x0051, 0x0052 }; + static const uint16_t save_phy_regs_comm[SAVE_PHY_COMM_MAX] = + { 0x0015, 0x005a, 0x0059, 0x0058 }; + static const uint16_t save_phy_regs_11g[SAVE_PHY_11G_MAX] = + { 0x0811, 0x0812, 0x0814, 0x0815, 0x0429, 0x0802 }; + + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy_comm[SAVE_PHY_COMM_MAX]; + uint16_t save_phy_11g[SAVE_PHY_11G_MAX]; + uint16_t phyr_35, phyr_30 = 0, rfr_78, phyr_80f = 0, phyr_810 = 0; + uint16_t bphy_ctrl = 0, bbp_atten, rf_chan_ex; + uint16_t phy812_val; + uint16_t calib; + uint32_t test_lim, test; + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + int i; + + /* + * Save registers for later restoring + */ + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + save_phy_comm[i] = PHY_READ(mac, save_phy_regs_comm[i]); + + if (phy->phy_mode == IEEE80211_MODE_11B) { + phyr_30 = PHY_READ(mac, 0x30); + bphy_ctrl = CSR_READ_2(sc, BWI_BPHY_CTRL); + + PHY_WRITE(mac, 0x30, 0xff); + CSR_WRITE_2(sc, BWI_BPHY_CTRL, 0x3f3f); + } else if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + for (i = 0; i < SAVE_PHY_11G_MAX; ++i) { + save_phy_11g[i] = + PHY_READ(mac, save_phy_regs_11g[i]); + } + + PHY_SETBITS(mac, 0x814, 0x3); + PHY_CLRBITS(mac, 0x815, 0x3); + PHY_CLRBITS(mac, 0x429, 0x8000); + PHY_CLRBITS(mac, 0x802, 0x3); + + phyr_80f = PHY_READ(mac, 0x80f); + phyr_810 = PHY_READ(mac, 0x810); + + if (phy->phy_rev >= 3) + PHY_WRITE(mac, 0x80f, 0xc020); + else + PHY_WRITE(mac, 0x80f, 0x8020); + PHY_WRITE(mac, 0x810, 0); + + phy812_val = bwi_phy812_value(mac, 0x011); + PHY_WRITE(mac, 0x812, phy812_val); + if (phy->phy_rev < 7 || + (sc->sc_card_flags & BWI_CARD_F_EXT_LNA) == 0) + PHY_WRITE(mac, 0x811, 0x1b3); + else + PHY_WRITE(mac, 0x811, 0x9b3); + } + CSR_SETBITS_2(sc, BWI_RF_ANTDIV, 0x8000); + + phyr_35 = PHY_READ(mac, 0x35); + PHY_CLRBITS(mac, 0x35, 0x80); + + bbp_atten = CSR_READ_2(sc, BWI_BBP_ATTEN); + rf_chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + if (phy->phy_version == 0) { + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0x122); + } else { + if (phy->phy_version >= 2) + PHY_FILT_SETBITS(mac, 0x3, 0xffbf, 0x40); + CSR_SETBITS_2(sc, BWI_RF_CHAN_EX, 0x2000); + } + + calib = bwi_rf_calibval(mac); + + if (phy->phy_mode == IEEE80211_MODE_11B) + RF_WRITE(mac, 0x78, 0x26); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x011); + PHY_WRITE(mac, 0x812, phy812_val); + } + + PHY_WRITE(mac, 0x15, 0xbfaf); + PHY_WRITE(mac, 0x2b, 0x1403); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x001); + PHY_WRITE(mac, 0x812, phy812_val); + } + + PHY_WRITE(mac, 0x15, 0xbfa0); + + RF_SETBITS(mac, 0x51, 0x4); + if (rf->rf_rev == 8) { + RF_WRITE(mac, 0x43, 0x1f); + } else { + RF_WRITE(mac, 0x52, 0); + RF_FILT_SETBITS(mac, 0x43, 0xfff0, 0x9); + } + + test_lim = 0; + PHY_WRITE(mac, 0x58, 0); + for (i = 0; i < 16; ++i) { + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0xc810); + + PHY_WRITE(mac, 0x58, 0xd); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xefb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x100); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xfff0); + DELAY(20); + + test_lim += PHY_READ(mac, 0x2d); + + PHY_WRITE(mac, 0x58, 0); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + } + ++test_lim; + test_lim >>= 9; + + DELAY(10); + + test = 0; + PHY_WRITE(mac, 0x58, 0); + for (i = 0; i < 16; ++i) { + int j; + + rfr_78 = (bitswap4(i) << 1) | 0x20; + RF_WRITE(mac, 0x78, rfr_78); + DELAY(10); + + /* NB: This block is slight different than the above one */ + for (j = 0; j < 16; ++j) { + PHY_WRITE(mac, 0x5a, 0xd80); + PHY_WRITE(mac, 0x59, 0xc810); + + PHY_WRITE(mac, 0x58, 0xd); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xefb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x100); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xfff0); + DELAY(10); + + test += PHY_READ(mac, 0x2d); + + PHY_WRITE(mac, 0x58, 0); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + } + + ++test; + test >>= 8; + + if (test > test_lim) + break; + } + if (i > 15) + rf->rf_calib = rfr_78; + else + rf->rf_calib = calib; + if (rf->rf_calib != 0xffff) { + DPRINTF(sc, "RF calibration value: 0x%04x\n", rf->rf_calib); + rf->rf_flags |= BWI_RF_F_INITED; + } + + /* + * Restore trashes registers + */ + PHY_WRITE(mac, save_phy_regs_comm[0], save_phy_comm[0]); + + for (i = 0; i < SAVE_RF_MAX; ++i) { + int pos = (i + 1) % SAVE_RF_MAX; + + RF_WRITE(mac, save_rf_regs[pos], save_rf[pos]); + } + for (i = 1; i < SAVE_PHY_COMM_MAX; ++i) + PHY_WRITE(mac, save_phy_regs_comm[i], save_phy_comm[i]); + + CSR_WRITE_2(sc, BWI_BBP_ATTEN, bbp_atten); + if (phy->phy_version != 0) + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, rf_chan_ex); + + PHY_WRITE(mac, 0x35, phyr_35); + bwi_rf_work_around(mac, rf->rf_curchan); + + if (phy->phy_mode == IEEE80211_MODE_11B) { + PHY_WRITE(mac, 0x30, phyr_30); + CSR_WRITE_2(sc, BWI_BPHY_CTRL, bphy_ctrl); + } else if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + /* XXX Spec only says when PHY is linked (gmode) */ + CSR_CLRBITS_2(sc, BWI_RF_ANTDIV, 0x8000); + + for (i = 0; i < SAVE_PHY_11G_MAX; ++i) { + PHY_WRITE(mac, save_phy_regs_11g[i], + save_phy_11g[i]); + } + + PHY_WRITE(mac, 0x80f, phyr_80f); + PHY_WRITE(mac, 0x810, phyr_810); + } + +#undef SAVE_PHY_11G_MAX +#undef SAVE_PHY_COMM_MAX +#undef SAVE_RF_MAX +} + +static uint16_t +bwi_rf_calibval(struct bwi_mac *mac) +{ + /* http://bcm-specs.sipsolutions.net/RCCTable */ + static const uint16_t rf_calibvals[] = { + 0x2, 0x3, 0x1, 0xf, 0x6, 0x7, 0x5, 0xf, + 0xa, 0xb, 0x9, 0xf, 0xe, 0xf, 0xd, 0xf + }; + uint16_t val, calib; + int idx; + + val = RF_READ(mac, BWI_RFR_BBP_ATTEN); + idx = __SHIFTOUT(val, BWI_RFR_BBP_ATTEN_CALIB_IDX); + KASSERT(idx < (int)(sizeof(rf_calibvals) / sizeof(rf_calibvals[0])), + ("idx %d", idx)); + + calib = rf_calibvals[idx] << 1; + if (val & BWI_RFR_BBP_ATTEN_CALIB_BIT) + calib |= 0x1; + calib |= 0x20; + + return calib; +} + +static __inline int32_t +_bwi_adjust_devide(int32_t num, int32_t den) +{ + if (num < 0) + return (num / den); + else + return (num + den / 2) / den; +} + +/* + * http://bcm-specs.sipsolutions.net/TSSI_to_DBM_Table + * "calculating table entries" + */ +static int +bwi_rf_calc_txpower(int8_t *txpwr, uint8_t idx, const int16_t pa_params[]) +{ + int32_t m1, m2, f, dbm; + int i; + + m1 = _bwi_adjust_devide(16 * pa_params[0] + idx * pa_params[1], 32); + m2 = imax(_bwi_adjust_devide(32768 + idx * pa_params[2], 256), 1); + +#define ITER_MAX 16 + + f = 256; + for (i = 0; i < ITER_MAX; ++i) { + int32_t q, d; + + q = _bwi_adjust_devide( + f * 4096 - _bwi_adjust_devide(m2 * f, 16) * f, 2048); + d = abs(q - f); + f = q; + + if (d < 2) + break; + } + if (i == ITER_MAX) + return EINVAL; + +#undef ITER_MAX + + dbm = _bwi_adjust_devide(m1 * f, 8192); + if (dbm < -127) + dbm = -127; + else if (dbm > 128) + dbm = 128; + + *txpwr = dbm; + return 0; +} + +int +bwi_rf_map_txpower(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t sprom_ofs, val, mask; + int16_t pa_params[3]; + int error = 0, i, ant_gain, reg_txpower_max; + + /* + * Find out max TX power + */ + val = bwi_read_sprom(sc, BWI_SPROM_MAX_TXPWR); + if (phy->phy_mode == IEEE80211_MODE_11A) { + rf->rf_txpower_max = __SHIFTOUT(val, + BWI_SPROM_MAX_TXPWR_MASK_11A); + } else { + rf->rf_txpower_max = __SHIFTOUT(val, + BWI_SPROM_MAX_TXPWR_MASK_11BG); + + if ((sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) && + phy->phy_mode == IEEE80211_MODE_11G) + rf->rf_txpower_max -= 3; + } + if (rf->rf_txpower_max <= 0) { + device_printf(sc->sc_dev, "invalid max txpower in sprom\n"); + rf->rf_txpower_max = 74; + } + DPRINTF(sc, "max txpower from sprom: %d dBm\n", rf->rf_txpower_max); + + /* + * Find out region/domain max TX power, which is adjusted + * by antenna gain and 1.5 dBm fluctuation as mentioned + * in v3 spec. + */ + val = bwi_read_sprom(sc, BWI_SPROM_ANT_GAIN); + if (phy->phy_mode == IEEE80211_MODE_11A) + ant_gain = __SHIFTOUT(val, BWI_SPROM_ANT_GAIN_MASK_11A); + else + ant_gain = __SHIFTOUT(val, BWI_SPROM_ANT_GAIN_MASK_11BG); + if (ant_gain == 0xff) { + device_printf(sc->sc_dev, "invalid antenna gain in sprom\n"); + ant_gain = 2; + } + ant_gain *= 4; + DPRINTF(sc, "ant gain %d dBm\n", ant_gain); + + reg_txpower_max = 90 - ant_gain - 6; /* XXX magic number */ + DPRINTF(sc, "region/domain max txpower %d dBm\n", reg_txpower_max); + + /* + * Force max TX power within region/domain TX power limit + */ + if (rf->rf_txpower_max > reg_txpower_max) + rf->rf_txpower_max = reg_txpower_max; + DPRINTF(sc, "max txpower %d dBm\n", rf->rf_txpower_max); + + /* + * Create TSSI to TX power mapping + */ + + if (sc->sc_bbp_id == BWI_BBPID_BCM4301 && + rf->rf_type != BWI_RF_T_BCM2050) { + rf->rf_idle_tssi0 = BWI_DEFAULT_IDLE_TSSI; + bcopy(bwi_txpower_map_11b, rf->rf_txpower_map0, + sizeof(rf->rf_txpower_map0)); + goto back; + } + +#define IS_VALID_PA_PARAM(p) ((p) != 0 && (p) != -1) +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + + /* + * Extract PA parameters + */ + if (phy->phy_mode == IEEE80211_MODE_11A) + sprom_ofs = BWI_SPROM_PA_PARAM_11A; + else + sprom_ofs = BWI_SPROM_PA_PARAM_11BG; + for (i = 0; i < N(pa_params); ++i) + pa_params[i] = (int16_t)bwi_read_sprom(sc, sprom_ofs + (i * 2)); + + for (i = 0; i < N(pa_params); ++i) { + /* + * If one of the PA parameters from SPROM is not valid, + * fall back to the default values, if there are any. + */ + if (!IS_VALID_PA_PARAM(pa_params[i])) { + const int8_t *txpower_map; + + if (phy->phy_mode == IEEE80211_MODE_11A) { + device_printf(sc->sc_dev, + "no tssi2dbm table for 11a PHY\n"); + return ENXIO; + } + + if (phy->phy_mode == IEEE80211_MODE_11G) { + DPRINTF(sc, "%s\n", "use default 11g TSSI map"); + txpower_map = bwi_txpower_map_11g; + } else { + txpower_map = bwi_txpower_map_11b; + } + + rf->rf_idle_tssi0 = BWI_DEFAULT_IDLE_TSSI; + bcopy(txpower_map, rf->rf_txpower_map0, + sizeof(rf->rf_txpower_map0)); + goto back; + } + } + +#undef N + + /* + * All of the PA parameters from SPROM are valid. + */ + + /* + * Extract idle TSSI from SPROM. + */ + val = bwi_read_sprom(sc, BWI_SPROM_IDLE_TSSI); + DPRINTF(sc, "sprom idle tssi: 0x%04x\n", val); + + if (phy->phy_mode == IEEE80211_MODE_11A) + mask = BWI_SPROM_IDLE_TSSI_MASK_11A; + else + mask = BWI_SPROM_IDLE_TSSI_MASK_11BG; + + rf->rf_idle_tssi0 = (int)__SHIFTOUT(val, mask); + if (!IS_VALID_PA_PARAM(rf->rf_idle_tssi0)) + rf->rf_idle_tssi0 = 62; + +#undef IS_VALID_PA_PARAM + + /* + * Calculate TX power map, which is indexed by TSSI + */ + device_printf(sc->sc_dev, "TSSI-TX power map:\n"); + for (i = 0; i < BWI_TSSI_MAX; ++i) { + error = bwi_rf_calc_txpower(&rf->rf_txpower_map0[i], i, + pa_params); + if (error) { + device_printf(sc->sc_dev, + "bwi_rf_calc_txpower failed\n"); + break; + } + if (i != 0 && i % 8 == 0) + printf("\n"); + printf("%d ", rf->rf_txpower_map0[i]); + } + printf("\n"); +back: + DPRINTF(sc, "idle tssi0: %d\n", rf->rf_idle_tssi0); + return error; +} + +void +bwi_rf_lo_update(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_tpctl *tpctl = &mac->mac_tpctl; + struct rf_saveregs regs; + uint16_t ant_div, chan_ex; + uint8_t devi_ctrl; + u_int orig_chan; + + /* + * Save RF/PHY registers for later restoration + */ + orig_chan = rf->rf_curchan; + bzero(®s, sizeof(regs)); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + SAVE_PHY_REG(mac, ®s, 429); + SAVE_PHY_REG(mac, ®s, 802); + + PHY_WRITE(mac, 0x429, regs.phy_429 & 0x7fff); + PHY_WRITE(mac, 0x802, regs.phy_802 & 0xfffc); + } + + ant_div = CSR_READ_2(sc, BWI_RF_ANTDIV); + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div | 0x8000); + chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + SAVE_PHY_REG(mac, ®s, 15); + SAVE_PHY_REG(mac, ®s, 2a); + SAVE_PHY_REG(mac, ®s, 35); + SAVE_PHY_REG(mac, ®s, 60); + SAVE_RF_REG(mac, ®s, 43); + SAVE_RF_REG(mac, ®s, 7a); + SAVE_RF_REG(mac, ®s, 52); + if (phy->phy_flags & BWI_PHY_F_LINKED) { + SAVE_PHY_REG(mac, ®s, 811); + SAVE_PHY_REG(mac, ®s, 812); + SAVE_PHY_REG(mac, ®s, 814); + SAVE_PHY_REG(mac, ®s, 815); + } + + /* Force to channel 6 */ + bwi_rf_set_chan(mac, 6, 0); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x429, regs.phy_429 & 0x7fff); + PHY_WRITE(mac, 0x802, regs.phy_802 & 0xfffc); + bwi_mac_dummy_xmit(mac); + } + RF_WRITE(mac, 0x43, 0x6); + + bwi_phy_set_bbp_atten(mac, 2); + + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, 0); + + PHY_WRITE(mac, 0x2e, 0x7f); + PHY_WRITE(mac, 0x80f, 0x78); + PHY_WRITE(mac, 0x35, regs.phy_35 & 0xff7f); + RF_WRITE(mac, 0x7a, regs.rf_7a & 0xfff0); + PHY_WRITE(mac, 0x2b, 0x203); + PHY_WRITE(mac, 0x2a, 0x8a3); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x814, regs.phy_814 | 0x3); + PHY_WRITE(mac, 0x815, regs.phy_815 & 0xfffc); + PHY_WRITE(mac, 0x811, 0x1b3); + PHY_WRITE(mac, 0x812, 0xb2); + } + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + tpctl->tp_ctrl2 = bwi_rf_get_tp_ctrl2(mac); + PHY_WRITE(mac, 0x80f, 0x8078); + + /* + * Measure all RF LO + */ + devi_ctrl = _bwi_rf_lo_update(mac, regs.rf_7a); + + /* + * Restore saved RF/PHY registers + */ + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x15, 0xe300); + PHY_WRITE(mac, 0x812, (devi_ctrl << 8) | 0xa0); + DELAY(5); + PHY_WRITE(mac, 0x812, (devi_ctrl << 8) | 0xa2); + DELAY(2); + PHY_WRITE(mac, 0x812, (devi_ctrl << 8) | 0xa3); + } else { + PHY_WRITE(mac, 0x15, devi_ctrl | 0xefa0); + } + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + tpctl = NULL; + bwi_rf_lo_adjust(mac, tpctl); + + PHY_WRITE(mac, 0x2e, 0x807f); + if (phy->phy_flags & BWI_PHY_F_LINKED) + PHY_WRITE(mac, 0x2f, 0x202); + else + PHY_WRITE(mac, 0x2f, 0x101); + + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, chan_ex); + + RESTORE_PHY_REG(mac, ®s, 15); + RESTORE_PHY_REG(mac, ®s, 2a); + RESTORE_PHY_REG(mac, ®s, 35); + RESTORE_PHY_REG(mac, ®s, 60); + + RESTORE_RF_REG(mac, ®s, 43); + RESTORE_RF_REG(mac, ®s, 7a); + + regs.rf_52 &= 0xf0; + regs.rf_52 |= (RF_READ(mac, 0x52) & 0xf); + RF_WRITE(mac, 0x52, regs.rf_52); + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + RESTORE_PHY_REG(mac, ®s, 811); + RESTORE_PHY_REG(mac, ®s, 812); + RESTORE_PHY_REG(mac, ®s, 814); + RESTORE_PHY_REG(mac, ®s, 815); + RESTORE_PHY_REG(mac, ®s, 429); + RESTORE_PHY_REG(mac, ®s, 802); + } + + bwi_rf_set_chan(mac, orig_chan, 1); +} + +static uint32_t +bwi_rf_lo_devi_measure(struct bwi_mac *mac, uint16_t ctrl) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint32_t devi = 0; + int i; + + if (phy->phy_flags & BWI_PHY_F_LINKED) + ctrl <<= 8; + + for (i = 0; i < 8; ++i) { + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x15, 0xe300); + PHY_WRITE(mac, 0x812, ctrl | 0xb0); + DELAY(5); + PHY_WRITE(mac, 0x812, ctrl | 0xb2); + DELAY(2); + PHY_WRITE(mac, 0x812, ctrl | 0xb3); + DELAY(4); + PHY_WRITE(mac, 0x15, 0xf300); + } else { + PHY_WRITE(mac, 0x15, ctrl | 0xefa0); + DELAY(2); + PHY_WRITE(mac, 0x15, ctrl | 0xefe0); + DELAY(4); + PHY_WRITE(mac, 0x15, ctrl | 0xffe0); + } + DELAY(8); + devi += PHY_READ(mac, 0x2d); + } + return devi; +} + +static uint16_t +bwi_rf_get_tp_ctrl2(struct bwi_mac *mac) +{ + uint32_t devi_min; + uint16_t tp_ctrl2 = 0; + int i; + + RF_WRITE(mac, 0x52, 0); + DELAY(10); + devi_min = bwi_rf_lo_devi_measure(mac, 0); + + for (i = 0; i < 16; ++i) { + uint32_t devi; + + RF_WRITE(mac, 0x52, i); + DELAY(10); + devi = bwi_rf_lo_devi_measure(mac, 0); + + if (devi < devi_min) { + devi_min = devi; + tp_ctrl2 = i; + } + } + return tp_ctrl2; +} + +static uint8_t +_bwi_rf_lo_update(struct bwi_mac *mac, uint16_t orig_rf7a) +{ +#define RF_ATTEN_LISTSZ 14 +#define BBP_ATTEN_MAX 4 /* half */ + + static const int rf_atten_list[RF_ATTEN_LISTSZ] = + { 3, 1, 5, 7, 9, 2, 0, 4, 6, 8, 1, 2, 3, 4 }; + static const int rf_atten_init_list[RF_ATTEN_LISTSZ] = + { 0, 3, 1, 5, 7, 3, 2, 0, 4, 6, -1, -1, -1, -1 }; + static const int rf_lo_measure_order[RF_ATTEN_LISTSZ] = + { 3, 1, 5, 7, 9, 2, 0, 4, 6, 8, 10, 11, 12, 13 }; + + struct ifnet *ifp = mac->mac_sc->sc_ic.ic_ifp; + struct bwi_rf_lo lo_save, *lo; + uint8_t devi_ctrl = 0; + int idx, adj_rf7a = 0; + + bzero(&lo_save, sizeof(lo_save)); + for (idx = 0; idx < RF_ATTEN_LISTSZ; ++idx) { + int init_rf_atten = rf_atten_init_list[idx]; + int rf_atten = rf_atten_list[idx]; + int bbp_atten; + + for (bbp_atten = 0; bbp_atten < BBP_ATTEN_MAX; ++bbp_atten) { + uint16_t tp_ctrl2, rf7a; + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + if (idx == 0) { + bzero(&lo_save, sizeof(lo_save)); + } else if (init_rf_atten < 0) { + lo = bwi_get_rf_lo(mac, + rf_atten, 2 * bbp_atten); + bcopy(lo, &lo_save, sizeof(lo_save)); + } else { + lo = bwi_get_rf_lo(mac, + init_rf_atten, 0); + bcopy(lo, &lo_save, sizeof(lo_save)); + } + + devi_ctrl = 0; + adj_rf7a = 0; + + /* + * XXX + * Linux driver overflows 'val' + */ + if (init_rf_atten >= 0) { + int val; + + val = rf_atten * 2 + bbp_atten; + if (val > 14) { + adj_rf7a = 1; + if (val > 17) + devi_ctrl = 1; + if (val > 19) + devi_ctrl = 2; + } + } + } else { + lo = bwi_get_rf_lo(mac, + rf_atten, 2 * bbp_atten); + if (!bwi_rf_lo_isused(mac, lo)) + continue; + bcopy(lo, &lo_save, sizeof(lo_save)); + + devi_ctrl = 3; + adj_rf7a = 0; + } + + RF_WRITE(mac, BWI_RFR_ATTEN, rf_atten); + + tp_ctrl2 = mac->mac_tpctl.tp_ctrl2; + if (init_rf_atten < 0) + tp_ctrl2 |= (3 << 4); + RF_WRITE(mac, BWI_RFR_TXPWR, tp_ctrl2); + + DELAY(10); + + bwi_phy_set_bbp_atten(mac, bbp_atten * 2); + + rf7a = orig_rf7a & 0xfff0; + if (adj_rf7a) + rf7a |= 0x8; + RF_WRITE(mac, 0x7a, rf7a); + + lo = bwi_get_rf_lo(mac, + rf_lo_measure_order[idx], bbp_atten * 2); + bwi_rf_lo_measure(mac, &lo_save, lo, devi_ctrl); + } + } + return devi_ctrl; + +#undef RF_ATTEN_LISTSZ +#undef BBP_ATTEN_MAX +} + +static void +bwi_rf_lo_measure(struct bwi_mac *mac, const struct bwi_rf_lo *src_lo, + struct bwi_rf_lo *dst_lo, uint8_t devi_ctrl) +{ +#define LO_ADJUST_MIN 1 +#define LO_ADJUST_MAX 8 +#define LO_ADJUST(hi, lo) { .ctrl_hi = hi, .ctrl_lo = lo } + static const struct bwi_rf_lo rf_lo_adjust[LO_ADJUST_MAX] = { + LO_ADJUST(1, 1), + LO_ADJUST(1, 0), + LO_ADJUST(1, -1), + LO_ADJUST(0, -1), + LO_ADJUST(-1, -1), + LO_ADJUST(-1, 0), + LO_ADJUST(-1, 1), + LO_ADJUST(0, 1) + }; +#undef LO_ADJUST + + struct bwi_rf_lo lo_min; + uint32_t devi_min; + int found, loop_count, adjust_state; + + bcopy(src_lo, &lo_min, sizeof(lo_min)); + RF_LO_WRITE(mac, &lo_min); + devi_min = bwi_rf_lo_devi_measure(mac, devi_ctrl); + + loop_count = 12; /* XXX */ + adjust_state = 0; + do { + struct bwi_rf_lo lo_base; + int i, fin; + + found = 0; + if (adjust_state == 0) { + i = LO_ADJUST_MIN; + fin = LO_ADJUST_MAX; + } else if (adjust_state % 2 == 0) { + i = adjust_state - 1; + fin = adjust_state + 1; + } else { + i = adjust_state - 2; + fin = adjust_state + 2; + } + + if (i < LO_ADJUST_MIN) + i += LO_ADJUST_MAX; + KASSERT(i <= LO_ADJUST_MAX && i >= LO_ADJUST_MIN, ("i %d", i)); + + if (fin > LO_ADJUST_MAX) + fin -= LO_ADJUST_MAX; + KASSERT(fin <= LO_ADJUST_MAX && fin >= LO_ADJUST_MIN, + ("fin %d", fin)); + + bcopy(&lo_min, &lo_base, sizeof(lo_base)); + for (;;) { + struct bwi_rf_lo lo; + + lo.ctrl_hi = lo_base.ctrl_hi + + rf_lo_adjust[i - 1].ctrl_hi; + lo.ctrl_lo = lo_base.ctrl_lo + + rf_lo_adjust[i - 1].ctrl_lo; + + if (abs(lo.ctrl_lo) < 9 && abs(lo.ctrl_hi) < 9) { + uint32_t devi; + + RF_LO_WRITE(mac, &lo); + devi = bwi_rf_lo_devi_measure(mac, devi_ctrl); + if (devi < devi_min) { + devi_min = devi; + adjust_state = i; + found = 1; + bcopy(&lo, &lo_min, sizeof(lo_min)); + } + } + if (i == fin) + break; + if (i == LO_ADJUST_MAX) + i = LO_ADJUST_MIN; + else + ++i; + } + } while (loop_count-- && found); + + bcopy(&lo_min, dst_lo, sizeof(*dst_lo)); + +#undef LO_ADJUST_MIN +#undef LO_ADJUST_MAX +} + +static void +bwi_rf_calc_nrssi_slope_11b(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 3 +#define SAVE_PHY_MAX 8 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x7a, 0x52, 0x43 }; + static const uint16_t save_phy_regs[SAVE_PHY_MAX] = + { 0x30, 0x26, 0x15, 0x2a, 0x20, 0x5a, 0x59, 0x58 }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy[SAVE_PHY_MAX]; + uint16_t ant_div, bbp_atten, chan_ex; + int16_t nrssi[2]; + int i; + + /* + * Save RF/PHY registers for later restoration + */ + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + for (i = 0; i < SAVE_PHY_MAX; ++i) + save_phy[i] = PHY_READ(mac, save_phy_regs[i]); + + ant_div = CSR_READ_2(sc, BWI_RF_ANTDIV); + bbp_atten = CSR_READ_2(sc, BWI_BBP_ATTEN); + chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + /* + * Calculate nrssi0 + */ + if (phy->phy_rev >= 5) + RF_CLRBITS(mac, 0x7a, 0xff80); + else + RF_CLRBITS(mac, 0x7a, 0xfff0); + PHY_WRITE(mac, 0x30, 0xff); + + CSR_WRITE_2(sc, BWI_BPHY_CTRL, 0x7f7f); + + PHY_WRITE(mac, 0x26, 0); + PHY_SETBITS(mac, 0x15, 0x20); + PHY_WRITE(mac, 0x2a, 0x8a3); + RF_SETBITS(mac, 0x7a, 0x80); + + nrssi[0] = (int16_t)PHY_READ(mac, 0x27); + + /* + * Calculate nrssi1 + */ + RF_CLRBITS(mac, 0x7a, 0xff80); + if (phy->phy_version >= 2) + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0x40); + else if (phy->phy_version == 0) + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0x122); + else + CSR_CLRBITS_2(sc, BWI_RF_CHAN_EX, 0xdfff); + + PHY_WRITE(mac, 0x20, 0x3f3f); + PHY_WRITE(mac, 0x15, 0xf330); + + RF_WRITE(mac, 0x5a, 0x60); + RF_CLRBITS(mac, 0x43, 0xff0f); + + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0x810); + PHY_WRITE(mac, 0x58, 0xd); + + DELAY(20); + + nrssi[1] = (int16_t)PHY_READ(mac, 0x27); + + /* + * Restore saved RF/PHY registers + */ + PHY_WRITE(mac, save_phy_regs[0], save_phy[0]); + RF_WRITE(mac, save_rf_regs[0], save_rf[0]); + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div); + + for (i = 1; i < 4; ++i) + PHY_WRITE(mac, save_phy_regs[i], save_phy[i]); + + bwi_rf_work_around(mac, rf->rf_curchan); + + if (phy->phy_version != 0) + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, chan_ex); + + for (; i < SAVE_PHY_MAX; ++i) + PHY_WRITE(mac, save_phy_regs[i], save_phy[i]); + + for (i = 1; i < SAVE_RF_MAX; ++i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + /* + * Install calculated narrow RSSI values + */ + if (nrssi[0] == nrssi[1]) + rf->rf_nrssi_slope = 0x10000; + else + rf->rf_nrssi_slope = 0x400000 / (nrssi[0] - nrssi[1]); + if (nrssi[0] <= -4) { + rf->rf_nrssi[0] = nrssi[0]; + rf->rf_nrssi[1] = nrssi[1]; + } + +#undef SAVE_RF_MAX +#undef SAVE_PHY_MAX +} + +static void +bwi_rf_set_nrssi_ofs_11g(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 2 +#define SAVE_PHY_COMM_MAX 10 +#define SAVE_PHY6_MAX 8 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x7a, 0x43 }; + static const uint16_t save_phy_comm_regs[SAVE_PHY_COMM_MAX] = { + 0x0001, 0x0811, 0x0812, 0x0814, + 0x0815, 0x005a, 0x0059, 0x0058, + 0x000a, 0x0003 + }; + static const uint16_t save_phy6_regs[SAVE_PHY6_MAX] = { + 0x002e, 0x002f, 0x080f, 0x0810, + 0x0801, 0x0060, 0x0014, 0x0478 + }; + + struct bwi_phy *phy = &mac->mac_phy; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy_comm[SAVE_PHY_COMM_MAX]; + uint16_t save_phy6[SAVE_PHY6_MAX]; + uint16_t rf7b = 0xffff; + int16_t nrssi; + int i, phy6_idx = 0; + + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + save_phy_comm[i] = PHY_READ(mac, save_phy_comm_regs[i]); + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + + PHY_CLRBITS(mac, 0x429, 0x8000); + PHY_FILT_SETBITS(mac, 0x1, 0x3fff, 0x4000); + PHY_SETBITS(mac, 0x811, 0xc); + PHY_FILT_SETBITS(mac, 0x812, 0xfff3, 0x4); + PHY_CLRBITS(mac, 0x802, 0x3); + + if (phy->phy_rev >= 6) { + for (i = 0; i < SAVE_PHY6_MAX; ++i) + save_phy6[i] = PHY_READ(mac, save_phy6_regs[i]); + + PHY_WRITE(mac, 0x2e, 0); + PHY_WRITE(mac, 0x2f, 0); + PHY_WRITE(mac, 0x80f, 0); + PHY_WRITE(mac, 0x810, 0); + PHY_SETBITS(mac, 0x478, 0x100); + PHY_SETBITS(mac, 0x801, 0x40); + PHY_SETBITS(mac, 0x60, 0x40); + PHY_SETBITS(mac, 0x14, 0x200); + } + + RF_SETBITS(mac, 0x7a, 0x70); + RF_SETBITS(mac, 0x7a, 0x80); + + DELAY(30); + + nrssi = bwi_nrssi_11g(mac); + if (nrssi == 31) { + for (i = 7; i >= 4; --i) { + RF_WRITE(mac, 0x7b, i); + DELAY(20); + nrssi = bwi_nrssi_11g(mac); + if (nrssi < 31 && rf7b == 0xffff) + rf7b = i; + } + if (rf7b == 0xffff) + rf7b = 4; + } else { + struct bwi_gains gains; + + RF_CLRBITS(mac, 0x7a, 0xff80); + + PHY_SETBITS(mac, 0x814, 0x1); + PHY_CLRBITS(mac, 0x815, 0x1); + PHY_SETBITS(mac, 0x811, 0xc); + PHY_SETBITS(mac, 0x812, 0xc); + PHY_SETBITS(mac, 0x811, 0x30); + PHY_SETBITS(mac, 0x812, 0x30); + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0x810); + PHY_WRITE(mac, 0x58, 0xd); + if (phy->phy_version == 0) + PHY_WRITE(mac, 0x3, 0x122); + else + PHY_SETBITS(mac, 0xa, 0x2000); + PHY_SETBITS(mac, 0x814, 0x4); + PHY_CLRBITS(mac, 0x815, 0x4); + PHY_FILT_SETBITS(mac, 0x3, 0xff9f, 0x40); + RF_SETBITS(mac, 0x7a, 0xf); + + bzero(&gains, sizeof(gains)); + gains.tbl_gain1 = 3; + gains.tbl_gain2 = 0; + gains.phy_gain = 1; + bwi_set_gains(mac, &gains); + + RF_FILT_SETBITS(mac, 0x43, 0xf0, 0xf); + DELAY(30); + + nrssi = bwi_nrssi_11g(mac); + if (nrssi == -32) { + for (i = 0; i < 4; ++i) { + RF_WRITE(mac, 0x7b, i); + DELAY(20); + nrssi = bwi_nrssi_11g(mac); + if (nrssi > -31 && rf7b == 0xffff) + rf7b = i; + } + if (rf7b == 0xffff) + rf7b = 3; + } else { + rf7b = 0; + } + } + RF_WRITE(mac, 0x7b, rf7b); + + /* + * Restore saved RF/PHY registers + */ + if (phy->phy_rev >= 6) { + for (phy6_idx = 0; phy6_idx < 4; ++phy6_idx) { + PHY_WRITE(mac, save_phy6_regs[phy6_idx], + save_phy6[phy6_idx]); + } + } + + /* Saved PHY registers 0, 1, 2 are handled later */ + for (i = 3; i < SAVE_PHY_COMM_MAX; ++i) + PHY_WRITE(mac, save_phy_comm_regs[i], save_phy_comm[i]); + + for (i = SAVE_RF_MAX - 1; i >= 0; --i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + PHY_SETBITS(mac, 0x802, 0x3); + PHY_SETBITS(mac, 0x429, 0x8000); + + bwi_set_gains(mac, NULL); + + if (phy->phy_rev >= 6) { + for (; phy6_idx < SAVE_PHY6_MAX; ++phy6_idx) { + PHY_WRITE(mac, save_phy6_regs[phy6_idx], + save_phy6[phy6_idx]); + } + } + + PHY_WRITE(mac, save_phy_comm_regs[0], save_phy_comm[0]); + PHY_WRITE(mac, save_phy_comm_regs[2], save_phy_comm[2]); + PHY_WRITE(mac, save_phy_comm_regs[1], save_phy_comm[1]); + +#undef SAVE_RF_MAX +#undef SAVE_PHY_COMM_MAX +#undef SAVE_PHY6_MAX +} + +static void +bwi_rf_calc_nrssi_slope_11g(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 3 +#define SAVE_PHY_COMM_MAX 4 +#define SAVE_PHY3_MAX 8 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x7a, 0x52, 0x43 }; + static const uint16_t save_phy_comm_regs[SAVE_PHY_COMM_MAX] = + { 0x15, 0x5a, 0x59, 0x58 }; + static const uint16_t save_phy3_regs[SAVE_PHY3_MAX] = { + 0x002e, 0x002f, 0x080f, 0x0810, + 0x0801, 0x0060, 0x0014, 0x0478 + }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy_comm[SAVE_PHY_COMM_MAX]; + uint16_t save_phy3[SAVE_PHY3_MAX]; + uint16_t ant_div, bbp_atten, chan_ex; + struct bwi_gains gains; + int16_t nrssi[2]; + int i, phy3_idx = 0; + + if (rf->rf_rev >= 9) + return; + else if (rf->rf_rev == 8) + bwi_rf_set_nrssi_ofs_11g(mac); + + PHY_CLRBITS(mac, 0x429, 0x8000); + PHY_CLRBITS(mac, 0x802, 0x3); + + /* + * Save RF/PHY registers for later restoration + */ + ant_div = CSR_READ_2(sc, BWI_RF_ANTDIV); + CSR_SETBITS_2(sc, BWI_RF_ANTDIV, 0x8000); + + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + save_phy_comm[i] = PHY_READ(mac, save_phy_comm_regs[i]); + + bbp_atten = CSR_READ_2(sc, BWI_BBP_ATTEN); + chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + if (phy->phy_rev >= 3) { + for (i = 0; i < SAVE_PHY3_MAX; ++i) + save_phy3[i] = PHY_READ(mac, save_phy3_regs[i]); + + PHY_WRITE(mac, 0x2e, 0); + PHY_WRITE(mac, 0x810, 0); + + if (phy->phy_rev == 4 || phy->phy_rev == 6 || + phy->phy_rev == 7) { + PHY_SETBITS(mac, 0x478, 0x100); + PHY_SETBITS(mac, 0x810, 0x40); + } else if (phy->phy_rev == 3 || phy->phy_rev == 5) { + PHY_CLRBITS(mac, 0x810, 0x40); + } + + PHY_SETBITS(mac, 0x60, 0x40); + PHY_SETBITS(mac, 0x14, 0x200); + } + + /* + * Calculate nrssi0 + */ + RF_SETBITS(mac, 0x7a, 0x70); + + bzero(&gains, sizeof(gains)); + gains.tbl_gain1 = 0; + gains.tbl_gain2 = 8; + gains.phy_gain = 0; + bwi_set_gains(mac, &gains); + + RF_CLRBITS(mac, 0x7a, 0xff08); + if (phy->phy_rev >= 2) { + PHY_FILT_SETBITS(mac, 0x811, 0xffcf, 0x30); + PHY_FILT_SETBITS(mac, 0x812, 0xffcf, 0x10); + } + + RF_SETBITS(mac, 0x7a, 0x80); + DELAY(20); + nrssi[0] = bwi_nrssi_11g(mac); + + /* + * Calculate nrssi1 + */ + RF_CLRBITS(mac, 0x7a, 0xff80); + if (phy->phy_version >= 2) + PHY_FILT_SETBITS(mac, 0x3, 0xff9f, 0x40); + CSR_SETBITS_2(sc, BWI_RF_CHAN_EX, 0x2000); + + RF_SETBITS(mac, 0x7a, 0xf); + PHY_WRITE(mac, 0x15, 0xf330); + if (phy->phy_rev >= 2) { + PHY_FILT_SETBITS(mac, 0x812, 0xffcf, 0x20); + PHY_FILT_SETBITS(mac, 0x811, 0xffcf, 0x20); + } + + bzero(&gains, sizeof(gains)); + gains.tbl_gain1 = 3; + gains.tbl_gain2 = 0; + gains.phy_gain = 1; + bwi_set_gains(mac, &gains); + + if (rf->rf_rev == 8) { + RF_WRITE(mac, 0x43, 0x1f); + } else { + RF_FILT_SETBITS(mac, 0x52, 0xff0f, 0x60); + RF_FILT_SETBITS(mac, 0x43, 0xfff0, 0x9); + } + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0x810); + PHY_WRITE(mac, 0x58, 0xd); + DELAY(20); + + nrssi[1] = bwi_nrssi_11g(mac); + + /* + * Install calculated narrow RSSI values + */ + if (nrssi[1] == nrssi[0]) + rf->rf_nrssi_slope = 0x10000; + else + rf->rf_nrssi_slope = 0x400000 / (nrssi[0] - nrssi[1]); + if (nrssi[0] >= -4) { + rf->rf_nrssi[0] = nrssi[1]; + rf->rf_nrssi[1] = nrssi[0]; + } + + /* + * Restore saved RF/PHY registers + */ + if (phy->phy_rev >= 3) { + for (phy3_idx = 0; phy3_idx < 4; ++phy3_idx) { + PHY_WRITE(mac, save_phy3_regs[phy3_idx], + save_phy3[phy3_idx]); + } + } + if (phy->phy_rev >= 2) { + PHY_CLRBITS(mac, 0x812, 0x30); + PHY_CLRBITS(mac, 0x811, 0x30); + } + + for (i = 0; i < SAVE_RF_MAX; ++i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div); + CSR_WRITE_2(sc, BWI_BBP_ATTEN, bbp_atten); + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, chan_ex); + + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + PHY_WRITE(mac, save_phy_comm_regs[i], save_phy_comm[i]); + + bwi_rf_work_around(mac, rf->rf_curchan); + PHY_SETBITS(mac, 0x802, 0x3); + bwi_set_gains(mac, NULL); + PHY_SETBITS(mac, 0x429, 0x8000); + + if (phy->phy_rev >= 3) { + for (; phy3_idx < SAVE_PHY3_MAX; ++phy3_idx) { + PHY_WRITE(mac, save_phy3_regs[phy3_idx], + save_phy3[phy3_idx]); + } + } + + bwi_rf_init_sw_nrssi_table(mac); + bwi_rf_set_nrssi_thr_11g(mac); + +#undef SAVE_RF_MAX +#undef SAVE_PHY_COMM_MAX +#undef SAVE_PHY3_MAX +} + +static void +bwi_rf_init_sw_nrssi_table(struct bwi_mac *mac) +{ + struct bwi_rf *rf = &mac->mac_rf; + int d, i; + + d = 0x1f - rf->rf_nrssi[0]; + for (i = 0; i < BWI_NRSSI_TBLSZ; ++i) { + int val; + + val = (((i - d) * rf->rf_nrssi_slope) / 0x10000) + 0x3a; + if (val < 0) + val = 0; + else if (val > 0x3f) + val = 0x3f; + + rf->rf_nrssi_table[i] = val; + } +} + +void +bwi_rf_init_hw_nrssi_table(struct bwi_mac *mac, uint16_t adjust) +{ + int i; + + for (i = 0; i < BWI_NRSSI_TBLSZ; ++i) { + int16_t val; + + val = bwi_nrssi_read(mac, i); + + val -= adjust; + if (val < -32) + val = -32; + else if (val > 31); + val = 31; + + bwi_nrssi_write(mac, i, val); + } +} + +static void +bwi_rf_set_nrssi_thr_11b(struct bwi_mac *mac) +{ + struct bwi_rf *rf = &mac->mac_rf; + int32_t thr; + + if (rf->rf_type != BWI_RF_T_BCM2050 || + (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) == 0) + return; + + /* + * Calculate nrssi threshold + */ + if (rf->rf_rev >= 6) { + thr = (rf->rf_nrssi[1] - rf->rf_nrssi[0]) * 32; + thr += 20 * (rf->rf_nrssi[0] + 1); + thr /= 40; + } else { + thr = rf->rf_nrssi[1] - 5; + } + if (thr < 0) + thr = 0; + else if (thr > 0x3e) + thr = 0x3e; + + PHY_READ(mac, BWI_PHYR_NRSSI_THR_11B); /* dummy read */ + PHY_WRITE(mac, BWI_PHYR_NRSSI_THR_11B, (((uint16_t)thr) << 8) | 0x1c); + + if (rf->rf_rev >= 6) { + PHY_WRITE(mac, 0x87, 0xe0d); + PHY_WRITE(mac, 0x86, 0xc0b); + PHY_WRITE(mac, 0x85, 0xa09); + PHY_WRITE(mac, 0x84, 0x808); + PHY_WRITE(mac, 0x83, 0x808); + PHY_WRITE(mac, 0x82, 0x604); + PHY_WRITE(mac, 0x81, 0x302); + PHY_WRITE(mac, 0x80, 0x100); + } +} + +static __inline int32_t +_nrssi_threshold(const struct bwi_rf *rf, int32_t val) +{ + val *= (rf->rf_nrssi[1] - rf->rf_nrssi[0]); + val += (rf->rf_nrssi[0] << 6); + if (val < 32) + val += 31; + else + val += 32; + val >>= 6; + if (val < -31) + val = -31; + else if (val > 31) + val = 31; + return val; +} + +static void +bwi_rf_set_nrssi_thr_11g(struct bwi_mac *mac) +{ + int32_t thr1, thr2; + uint16_t thr; + + /* + * Find the two nrssi thresholds + */ + if ((mac->mac_phy.phy_flags & BWI_PHY_F_LINKED) == 0 || + (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) == 0) { + int16_t nrssi; + + nrssi = bwi_nrssi_read(mac, 0x20); + if (nrssi >= 32) + nrssi -= 64; + + if (nrssi < 3) { + thr1 = 0x2b; + thr2 = 0x27; + } else { + thr1 = 0x2d; + thr2 = 0x2b; + } + } else { + /* TODO Interfere mode */ + thr1 = _nrssi_threshold(&mac->mac_rf, 0x11); + thr2 = _nrssi_threshold(&mac->mac_rf, 0xe); + } + +#define NRSSI_THR1_MASK __BITS(5, 0) +#define NRSSI_THR2_MASK __BITS(11, 6) + + thr = __SHIFTIN((uint32_t)thr1, NRSSI_THR1_MASK) | + __SHIFTIN((uint32_t)thr2, NRSSI_THR2_MASK); + PHY_FILT_SETBITS(mac, BWI_PHYR_NRSSI_THR_11G, 0xf000, thr); + +#undef NRSSI_THR1_MASK +#undef NRSSI_THR2_MASK +} + +void +bwi_rf_clear_tssi(struct bwi_mac *mac) +{ + /* XXX use function pointer */ + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11A) { + /* TODO:11A */ + } else { + uint16_t val; + int i; + + val = __SHIFTIN(BWI_INVALID_TSSI, BWI_LO_TSSI_MASK) | + __SHIFTIN(BWI_INVALID_TSSI, BWI_HI_TSSI_MASK); + + for (i = 0; i < 2; ++i) { + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, + BWI_COMM_MOBJ_TSSI_DS + (i * 2), val); + } + + for (i = 0; i < 2; ++i) { + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, + BWI_COMM_MOBJ_TSSI_OFDM + (i * 2), val); + } + } +} + +void +bwi_rf_clear_state(struct bwi_rf *rf) +{ + int i; + + rf->rf_flags &= ~BWI_RF_CLEAR_FLAGS; + bzero(rf->rf_lo, sizeof(rf->rf_lo)); + bzero(rf->rf_lo_used, sizeof(rf->rf_lo_used)); + + rf->rf_nrssi_slope = 0; + rf->rf_nrssi[0] = BWI_INVALID_NRSSI; + rf->rf_nrssi[1] = BWI_INVALID_NRSSI; + + for (i = 0; i < BWI_NRSSI_TBLSZ; ++i) + rf->rf_nrssi_table[i] = i; + + rf->rf_lo_gain = 0; + rf->rf_rx_gain = 0; + + bcopy(rf->rf_txpower_map0, rf->rf_txpower_map, + sizeof(rf->rf_txpower_map)); + rf->rf_idle_tssi = rf->rf_idle_tssi0; +} + +static void +bwi_rf_on_11a(struct bwi_mac *mac) +{ + /* TODO:11A */ +} + +static void +bwi_rf_on_11bg(struct bwi_mac *mac) +{ + struct bwi_phy *phy = &mac->mac_phy; + + PHY_WRITE(mac, 0x15, 0x8000); + PHY_WRITE(mac, 0x15, 0xcc00); + if (phy->phy_flags & BWI_PHY_F_LINKED) + PHY_WRITE(mac, 0x15, 0xc0); + else + PHY_WRITE(mac, 0x15, 0); + + bwi_rf_set_chan(mac, 6 /* XXX */, 1); +} + +void +bwi_rf_set_ant_mode(struct bwi_mac *mac, int ant_mode) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t val; + + KASSERT(ant_mode == BWI_ANT_MODE_0 || + ant_mode == BWI_ANT_MODE_1 || + ant_mode == BWI_ANT_MODE_AUTO, ("ant_mode %d", ant_mode)); + + HFLAGS_CLRBITS(mac, BWI_HFLAG_AUTO_ANTDIV); + + if (phy->phy_mode == IEEE80211_MODE_11B) { + /* NOTE: v4/v3 conflicts, take v3 */ + if (mac->mac_rev == 2) + val = BWI_ANT_MODE_AUTO; + else + val = ant_mode; + val <<= 7; + PHY_FILT_SETBITS(mac, 0x3e2, 0xfe7f, val); + } else { /* 11a/g */ + /* XXX reg/value naming */ + val = ant_mode << 7; + PHY_FILT_SETBITS(mac, 0x401, 0x7e7f, val); + + if (ant_mode == BWI_ANT_MODE_AUTO) + PHY_CLRBITS(mac, 0x42b, 0x100); + + if (phy->phy_mode == IEEE80211_MODE_11A) { + /* TODO:11A */ + } else { /* 11g */ + if (ant_mode == BWI_ANT_MODE_AUTO) + PHY_SETBITS(mac, 0x48c, 0x2000); + else + PHY_CLRBITS(mac, 0x48c, 0x2000); + + if (phy->phy_rev >= 2) { + PHY_SETBITS(mac, 0x461, 0x10); + PHY_FILT_SETBITS(mac, 0x4ad, 0xff00, 0x15); + if (phy->phy_rev == 2) { + PHY_WRITE(mac, 0x427, 0x8); + } else { + PHY_FILT_SETBITS(mac, 0x427, + 0xff00, 0x8); + } + + if (phy->phy_rev >= 6) + PHY_WRITE(mac, 0x49b, 0xdc); + } + } + } + + /* XXX v4 set AUTO_ANTDIV unconditionally */ + if (ant_mode == BWI_ANT_MODE_AUTO) + HFLAGS_SETBITS(mac, BWI_HFLAG_AUTO_ANTDIV); + + val = ant_mode << 8; + MOBJ_FILT_SETBITS_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_TX_BEACON, + 0xfc3f, val); + MOBJ_FILT_SETBITS_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_TX_ACK, + 0xfc3f, val); + MOBJ_FILT_SETBITS_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_TX_PROBE_RESP, + 0xfc3f, val); + + /* XXX what's these */ + if (phy->phy_mode == IEEE80211_MODE_11B) + CSR_SETBITS_2(sc, 0x5e, 0x4); + + CSR_WRITE_4(sc, 0x100, 0x1000000); + if (mac->mac_rev < 5) + CSR_WRITE_4(sc, 0x10c, 0x1000000); + + mac->mac_rf.rf_ant_mode = ant_mode; +} + +int +bwi_rf_get_latest_tssi(struct bwi_mac *mac, int8_t tssi[], uint16_t ofs) +{ + int i; + + for (i = 0; i < 4; ) { + uint16_t val; + + val = MOBJ_READ_2(mac, BWI_COMM_MOBJ, ofs + i); + tssi[i++] = (int8_t)__SHIFTOUT(val, BWI_LO_TSSI_MASK); + tssi[i++] = (int8_t)__SHIFTOUT(val, BWI_HI_TSSI_MASK); + } + + for (i = 0; i < 4; ++i) { + if (tssi[i] == BWI_INVALID_TSSI) + return EINVAL; + } + return 0; +} + +int +bwi_rf_tssi2dbm(struct bwi_mac *mac, int8_t tssi, int8_t *txpwr) +{ + struct bwi_rf *rf = &mac->mac_rf; + int pwr_idx; + + pwr_idx = rf->rf_idle_tssi + (int)tssi - rf->rf_base_tssi; +#if 0 + if (pwr_idx < 0 || pwr_idx >= BWI_TSSI_MAX) + return EINVAL; +#else + if (pwr_idx < 0) + pwr_idx = 0; + else if (pwr_idx >= BWI_TSSI_MAX) + pwr_idx = BWI_TSSI_MAX - 1; +#endif + + *txpwr = rf->rf_txpower_map[pwr_idx]; + return 0; +} + +static int +bwi_rf_calc_rssi_bcm2050(struct bwi_mac *mac, const struct bwi_rxbuf_hdr *hdr) +{ + uint16_t flags1, flags3; + int rssi, lna_gain; + + rssi = hdr->rxh_rssi; + flags1 = le16toh(hdr->rxh_flags1); + flags3 = le16toh(hdr->rxh_flags3); + +#define NEW_BCM2050_RSSI +#ifdef NEW_BCM2050_RSSI + if (flags1 & BWI_RXH_F1_OFDM) { + if (rssi > 127) + rssi -= 256; + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 17; + else + rssi -= 4; + return rssi; + } + + if (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) { + struct bwi_rf *rf = &mac->mac_rf; + + if (rssi >= BWI_NRSSI_TBLSZ) + rssi = BWI_NRSSI_TBLSZ - 1; + + rssi = ((31 - (int)rf->rf_nrssi_table[rssi]) * -131) / 128; + rssi -= 67; + } else { + rssi = ((31 - rssi) * -149) / 128; + rssi -= 68; + } + + if (mac->mac_phy.phy_mode != IEEE80211_MODE_11G) + return rssi; + + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 20; + + lna_gain = __SHIFTOUT(le16toh(hdr->rxh_phyinfo), + BWI_RXH_PHYINFO_LNAGAIN); +#if 0 + DPRINTF(mac->mac_sc, "lna_gain %d, phyinfo 0x%04x\n", + lna_gain, le16toh(hdr->rxh_phyinfo)); +#endif + switch (lna_gain) { + case 0: + rssi += 27; + break; + case 1: + rssi += 6; + break; + case 2: + rssi += 12; + break; + case 3: + /* + * XXX + * According to v3 spec, we should do _nothing_ here, + * but it seems that the result RSSI will be too low + * (relative to what ath(4) says). Raise it a little + * bit. + */ + rssi += 5; + break; + default: + panic("impossible lna gain %d", lna_gain); + } +#else /* !NEW_BCM2050_RSSI */ + lna_gain = 0; /* shut up gcc warning */ + + if (flags1 & BWI_RXH_F1_OFDM) { + if (rssi > 127) + rssi -= 256; + rssi = (rssi * 73) / 64; + + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 25; + else + rssi -= 3; + return rssi; + } + + if (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) { + struct bwi_rf *rf = &mac->mac_rf; + + if (rssi >= BWI_NRSSI_TBLSZ) + rssi = BWI_NRSSI_TBLSZ - 1; + + rssi = ((31 - (int)rf->rf_nrssi_table[rssi]) * -131) / 128; + rssi -= 57; + } else { + rssi = ((31 - rssi) * -149) / 128; + rssi -= 68; + } + + if (mac->mac_phy.phy_mode != IEEE80211_MODE_11G) + return rssi; + + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 25; +#endif /* NEW_BCM2050_RSSI */ + return rssi; +} + +static int +bwi_rf_calc_rssi_bcm2053(struct bwi_mac *mac, const struct bwi_rxbuf_hdr *hdr) +{ + uint16_t flags1; + int rssi; + + rssi = (((int)hdr->rxh_rssi - 11) * 103) / 64; + + flags1 = le16toh(hdr->rxh_flags1); + if (flags1 & BWI_RXH_F1_BCM2053_RSSI) + rssi -= 109; + else + rssi -= 83; + return rssi; +} + +static int +bwi_rf_calc_rssi_bcm2060(struct bwi_mac *mac, const struct bwi_rxbuf_hdr *hdr) +{ + int rssi; + + rssi = hdr->rxh_rssi; + if (rssi > 127) + rssi -= 256; + return rssi; +} --- /dev/null +++ sys/dev/bwi/bitops.h @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2004, 2005 David Young. All rights reserved. + * + * Programmed for NetBSD by David Young. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of David Young may not be used to endorse or promote + * products derived from this software without specific prior + * written permission. + * + * THIS SOFTWARE IS PROVIDED BY David Young ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A + * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL David + * Young BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED + * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY + * OF SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bitops.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bitops.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BITOPS_H +#define _BITOPS_H + +/* + * __BIT(n): Return a bitmask with bit m set, where the least + * significant bit is bit 0. + * + * __BITS(m, n): Return a bitmask with bits m through n, inclusive, + * set. It does not matter whether m>n or m<=n. The + * least significant bit is bit 0. + * + * A "bitfield" is a span of consecutive bits defined by a bitmask, + * where 1s select the bits in the bitfield. __SHIFTIN, __SHIFTOUT, + * and SHIFTOUT_MASK help read and write bitfields from device registers. + * + * __SHIFTIN(v, mask): Left-shift bits `v' into the bitfield + * defined by `mask', and return them. No + * side-effects. + * + * __SHIFTOUT(v, mask): Extract and return the bitfield selected + * by `mask' from `v', right-shifting the + * bits so that the rightmost selected bit + * is at bit 0. No side-effects. + * + * __SHIFTOUT_MASK(mask): Right-shift the bits in `mask' so that + * the rightmost non-zero bit is at bit + * 0. This is useful for finding the + * greatest unsigned value that a bitfield + * can hold. No side-effects. Note that + * SHIFTOUT_MASK(m) = SHIFTOUT(m, m). + */ + +/* __BIT(n): nth bit, where __BIT(0) == 0x1. */ +#define __BIT(__n) (((__n) == 32) ? 0 : ((uint32_t)1 << (__n))) + +/* __BITS(m, n): bits m through n, m < n. */ +#define __BITS(__m, __n) \ + ((__BIT(MAX((__m), (__n)) + 1) - 1) ^ (__BIT(MIN((__m), (__n))) - 1)) + +/* Find least significant bit that is set */ +#define __LOWEST_SET_BIT(__mask) ((((__mask) - 1) & (__mask)) ^ (__mask)) + +#define __SHIFTOUT(__x, __mask) (((__x) & (__mask)) / __LOWEST_SET_BIT(__mask)) +#define __SHIFTIN(__x, __mask) ((__x) * __LOWEST_SET_BIT(__mask)) +#define __SHIFTOUT_MASK(__mask) __SHIFTOUT((__mask), (__mask)) + +#endif /* !_BITOPS_H */ --- /dev/null +++ sys/dev/bwi/if_bwi_pci.c @@ -0,0 +1,283 @@ +/*- + * Copyright (c) 2002-2007 Sam Leffler, Errno Consulting + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer, + * without modification. + * 2. Redistributions in binary form must reproduce at minimum a disclaimer + * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any + * redistribution must be conditioned upon including a substantially + * similar Disclaimer requirement for further binary redistribution. + * + * NO WARRANTY + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, + * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER + * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF + * THE POSSIBILITY OF SUCH DAMAGES. + */ + +#include + +/* + * PCI/Cardbus front-end for the Broadcom Wireless LAN controller driver. + */ + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include + +#include +#include +#include + +#include +#include +#include + +#include +#include + +#include "if_bwivar.h" +#include "if_bwireg.h" +#include "bitops.h" + +/* + * PCI glue. + */ + +struct bwi_pci_softc { + struct bwi_softc sc_sc; +}; + +#define BS_BAR 0x10 +#define PCIR_RETRY_TIMEOUT 0x41 + +static const struct bwi_dev { + uint16_t vid; + uint16_t did; + const char *desc; +} bwi_devices[] = { + { PCI_VENDOR_BROADCOM, 0x4301,"Broadcom BCM4301 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4307,"Broadcom BCM4307 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4311,"Broadcom BCM4311 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4312,"Broadcom BCM4312 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4320,"Broadcom BCM4306v1 802.11 Wireless Lan"}, + { PCI_VENDOR_BROADCOM, 0x4321,"Broadcom BCM4306v2 802.11 Wireless Lan"}, + { PCI_VENDOR_BROADCOM, 0x4325,"Broadcom BCM4306v3 802.11 Wireless Lan"}, + { PCI_VENDOR_BROADCOM, 0x4324,"Broadcom BCM4309 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4318,"Broadcom BCM4318 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4319,"Broadcom BCM4319 802.11 Wireless Lan" } +}; + +static int +bwi_pci_probe(device_t dev) +{ + const struct bwi_dev *b; + uint16_t did, vid; + + did = pci_get_device(dev); + vid = pci_get_vendor(dev); + + for (b = bwi_devices; b->desc != NULL; ++b) { + if (b->did == did && b->vid == vid) { + device_set_desc(dev, b->desc); + return BUS_PROBE_DEFAULT; + } + } + return ENXIO; +} + +static u_int32_t +bwi_pci_setup(device_t dev) +{ + u_int32_t cmd; + + /* + * Enable memory mapping and bus mastering. + */ + cmd = pci_read_config(dev, PCIR_COMMAND, 4); + cmd |= PCIM_CMD_MEMEN | PCIM_CMD_BUSMASTEREN; + pci_write_config(dev, PCIR_COMMAND, cmd, 4); + cmd = pci_read_config(dev, PCIR_COMMAND, 4); + if ((cmd & PCIM_CMD_MEMEN) == 0) { + device_printf(dev, "failed to enable memory mapping\n"); + return 0; + } + if ((cmd & PCIM_CMD_BUSMASTEREN) == 0) { + device_printf(dev, "failed to enable bus mastering\n"); + return 0; + } + + /* + * Disable retry timeout to keep PCI Tx retries from + * interfering with C3 CPU state. + */ + pci_write_config(dev, PCIR_RETRY_TIMEOUT, 0, 1); + + return 1; +} + +static int +bwi_pci_attach(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + struct bwi_softc *sc = &psc->sc_sc; + int error = ENXIO; + + sc->sc_dev = dev; + + if (!bwi_pci_setup(dev)) + goto bad; + + /* + * Setup memory-mapping of PCI registers. + */ + sc->sc_mem_rid = BWI_PCIR_BAR; + sc->sc_mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, + &sc->sc_mem_rid, RF_ACTIVE); + if (sc->sc_mem_res == NULL) { + device_printf(dev, "cannot map register space\n"); + goto bad; + } + sc->sc_mem_bt = rman_get_bustag(sc->sc_mem_res); + sc->sc_mem_bh = rman_get_bushandle(sc->sc_mem_res); + /* + * Mark device invalid so any interrupts (shared or otherwise) + * that arrive before the card is setup are discarded. + */ + sc->sc_invalid = 1; + + /* + * Arrange interrupt line. + */ + sc->sc_irq_rid = 0; + sc->sc_irq_res = bus_alloc_resource_any(dev, SYS_RES_IRQ, + &sc->sc_irq_rid, + RF_SHAREABLE|RF_ACTIVE); + if (sc->sc_irq_res == NULL) { + device_printf(dev, "could not map interrupt\n"); + goto bad1; + } + if (bus_setup_intr(dev, sc->sc_irq_res, + INTR_TYPE_NET | INTR_MPSAFE, + NULL, bwi_intr, sc, &sc->sc_irq_handle)) { + device_printf(dev, "could not establish interrupt\n"); + goto bad2; + } + + /* Get more PCI information */ + sc->sc_pci_did = pci_get_device(dev); + sc->sc_pci_revid = pci_get_revid(dev); + sc->sc_pci_subvid = pci_get_subvendor(dev); + sc->sc_pci_subdid = pci_get_subdevice(dev); + + error = bwi_attach(sc); + if (error == 0) /* success */ + return 0; + + bus_teardown_intr(dev, sc->sc_irq_res, sc->sc_irq_handle); +bad2: + bus_release_resource(dev, SYS_RES_IRQ, 0, sc->sc_irq_res); +bad1: + bus_release_resource(dev, SYS_RES_MEMORY, BS_BAR, sc->sc_mem_res); +bad: + return (error); +} + +static int +bwi_pci_detach(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + struct bwi_softc *sc = &psc->sc_sc; + + /* check if device was removed */ + sc->sc_invalid = !bus_child_present(dev); + + bwi_detach(sc); + + bus_generic_detach(dev); + bus_teardown_intr(dev, sc->sc_irq_res, sc->sc_irq_handle); + bus_release_resource(dev, SYS_RES_IRQ, 0, sc->sc_irq_res); + + bus_release_resource(dev, SYS_RES_MEMORY, BS_BAR, sc->sc_mem_res); + + return (0); +} + +static int +bwi_pci_shutdown(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + + bwi_shutdown(&psc->sc_sc); + return (0); +} + +static int +bwi_pci_suspend(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + + bwi_suspend(&psc->sc_sc); + + return (0); +} + +static int +bwi_pci_resume(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + + if (!bwi_pci_setup(dev)) + return ENXIO; + + bwi_resume(&psc->sc_sc); + + return (0); +} + +static device_method_t bwi_pci_methods[] = { + /* Device interface */ + DEVMETHOD(device_probe, bwi_pci_probe), + DEVMETHOD(device_attach, bwi_pci_attach), + DEVMETHOD(device_detach, bwi_pci_detach), + DEVMETHOD(device_shutdown, bwi_pci_shutdown), + DEVMETHOD(device_suspend, bwi_pci_suspend), + DEVMETHOD(device_resume, bwi_pci_resume), + + { 0,0 } +}; +static driver_t bwi_driver = { + "bwi", + bwi_pci_methods, + sizeof (struct bwi_pci_softc) +}; +static devclass_t bwi_devclass; +DRIVER_MODULE(if_bwi, pci, bwi_driver, bwi_devclass, 0, 0); +DRIVER_MODULE(bwi, cardbus, bwi_driver, bwi_devclass, 0, 0); +MODULE_VERSION(if_bwi, 1); +MODULE_DEPEND(if_bwi, wlan, 1, 1, 1); /* 802.11 media layer */ +MODULE_DEPEND(if_bwi, firmware, 1, 1, 1); /* firmware support */ +MODULE_DEPEND(if_bwi, wlan_amrr, 1, 1, 1); --- /dev/null +++ sys/dev/bwi/bwirf.h @@ -0,0 +1,149 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwirf.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwirf.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BWI_RF_H +#define _BWI_RF_H + +int bwi_rf_attach(struct bwi_mac *); +void bwi_rf_clear_state(struct bwi_rf *); + +int bwi_rf_map_txpower(struct bwi_mac *); +void bwi_rf_lo_adjust(struct bwi_mac *, const struct bwi_tpctl *); +void bwi_rf_set_chan(struct bwi_mac *, u_int, int); +void bwi_rf_get_gains(struct bwi_mac *); +void bwi_rf_init(struct bwi_mac *); +void bwi_rf_init_bcm2050(struct bwi_mac *); +void bwi_rf_lo_update(struct bwi_mac *); +void bwi_rf_init_hw_nrssi_table(struct bwi_mac *, uint16_t); +void bwi_rf_set_ant_mode(struct bwi_mac *, int); + +void bwi_rf_clear_tssi(struct bwi_mac *); +int bwi_rf_get_latest_tssi(struct bwi_mac *, int8_t[], uint16_t); +int bwi_rf_tssi2dbm(struct bwi_mac *, int8_t, int8_t *); + +void bwi_rf_write(struct bwi_mac *, uint16_t, uint16_t); +uint16_t bwi_rf_read(struct bwi_mac *, uint16_t); + +static __inline void +bwi_rf_off(struct bwi_mac *_mac) +{ + _mac->mac_rf.rf_off(_mac); + /* TODO:LED */ + + _mac->mac_rf.rf_flags &= ~BWI_RF_F_ON; +} + +static __inline void +bwi_rf_on(struct bwi_mac *_mac) +{ + if (_mac->mac_rf.rf_flags & BWI_RF_F_ON) + return; + + _mac->mac_rf.rf_on(_mac); + /* TODO: LED */ + + _mac->mac_rf.rf_flags |= BWI_RF_F_ON; +} + +static __inline void +bwi_rf_calc_nrssi_slope(struct bwi_mac *_mac) +{ + _mac->mac_rf.rf_calc_nrssi_slope(_mac); +} + +static __inline void +bwi_rf_set_nrssi_thr(struct bwi_mac *_mac) +{ + _mac->mac_rf.rf_set_nrssi_thr(_mac); +} + +static __inline int +bwi_rf_calc_rssi(struct bwi_mac *_mac, const struct bwi_rxbuf_hdr *_hdr) +{ + return _mac->mac_rf.rf_calc_rssi(_mac, _hdr); +} + +#define RF_WRITE(mac, ofs, val) bwi_rf_write((mac), (ofs), (val)) +#define RF_READ(mac, ofs) bwi_rf_read((mac), (ofs)) + +#define RF_SETBITS(mac, ofs, bits) \ + RF_WRITE((mac), (ofs), RF_READ((mac), (ofs)) | (bits)) +#define RF_CLRBITS(mac, ofs, bits) \ + RF_WRITE((mac), (ofs), RF_READ((mac), (ofs)) & ~(bits)) +#define RF_FILT_SETBITS(mac, ofs, filt, bits) \ + RF_WRITE((mac), (ofs), (RF_READ((mac), (ofs)) & (filt)) | (bits)) + +#define BWI_RFR_ATTEN 0x43 + +#define BWI_RFR_TXPWR 0x52 +#define BWI_RFR_TXPWR1_MASK __BITS(6, 4) + +#define BWI_RFR_BBP_ATTEN 0x60 +#define BWI_RFR_BBP_ATTEN_CALIB_BIT __BIT(0) +#define BWI_RFR_BBP_ATTEN_CALIB_IDX __BITS(4, 1) + +/* + * TSSI -- TX power maps + */ +/* + * http://bcm-specs.sipsolutions.net/TSSI_to_DBM_Table + * B PHY + */ +#define BWI_TXPOWER_MAP_11B \ + 0x4d, 0x4c, 0x4b, 0x4a, 0x4a, 0x49, 0x48, 0x47, \ + 0x47, 0x46, 0x45, 0x45, 0x44, 0x43, 0x42, 0x42, \ + 0x41, 0x40, 0x3f, 0x3e, 0x3d, 0x3c, 0x3b, 0x3a, \ + 0x39, 0x38, 0x37, 0x36, 0x35, 0x34, 0x32, 0x31, \ + 0x30, 0x2f, 0x2d, 0x2c, 0x2b, 0x29, 0x28, 0x26, \ + 0x25, 0x23, 0x21, 0x1f, 0x1d, 0x1a, 0x17, 0x14, \ + 0x10, 0x0c, 0x06, 0x00, -7, -7, -7, -7, \ + -7, -7, -7, -7, -7, -7, -7, -7 +/* + * http://bcm-specs.sipsolutions.net/TSSI_to_DBM_Table + * G PHY + */ +#define BWI_TXPOWER_MAP_11G \ + 77, 77, 77, 76, 76, 76, 75, 75, \ + 74, 74, 73, 73, 73, 72, 72, 71, \ + 71, 70, 70, 69, 68, 68, 67, 67, \ + 66, 65, 65, 64, 63, 63, 62, 61, \ + 60, 59, 58, 57, 56, 55, 54, 53, \ + 52, 50, 49, 47, 45, 43, 40, 37, \ + 33, 28, 22, 14, 5, -7, -20, -20, \ + -20, -20, -20, -20, -20, -20, -20, -20 + +#endif /* !_BWI_RF_H */ --- /dev/null +++ sys/dev/bwi/bwiphy.c @@ -0,0 +1,962 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwiphy.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwiphy.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" +#include "bwiphy.h" + +static void bwi_phy_init_11a(struct bwi_mac *); +static void bwi_phy_init_11g(struct bwi_mac *); +static void bwi_phy_init_11b_rev2(struct bwi_mac *); +static void bwi_phy_init_11b_rev4(struct bwi_mac *); +static void bwi_phy_init_11b_rev5(struct bwi_mac *); +static void bwi_phy_init_11b_rev6(struct bwi_mac *); + +static void bwi_phy_config_11g(struct bwi_mac *); +static void bwi_phy_config_agc(struct bwi_mac *); + +static void bwi_tbl_write_2(struct bwi_mac *mac, uint16_t, uint16_t); +static void bwi_tbl_write_4(struct bwi_mac *mac, uint16_t, uint32_t); + +#define SUP_BPHY(num) { .rev = num, .init = bwi_phy_init_11b_rev##num } + +static const struct { + uint8_t rev; + void (*init)(struct bwi_mac *); +} bwi_sup_bphy[] = { + SUP_BPHY(2), + SUP_BPHY(4), + SUP_BPHY(5), + SUP_BPHY(6) +}; + +#undef SUP_BPHY + +#define BWI_PHYTBL_WRSSI 0x1000 +#define BWI_PHYTBL_NOISE_SCALE 0x1400 +#define BWI_PHYTBL_NOISE 0x1800 +#define BWI_PHYTBL_ROTOR 0x2000 +#define BWI_PHYTBL_DELAY 0x2400 +#define BWI_PHYTBL_RSSI 0x4000 +#define BWI_PHYTBL_SIGMA_SQ 0x5000 +#define BWI_PHYTBL_WRSSI_REV1 0x5400 +#define BWI_PHYTBL_FREQ 0x5800 + +static const uint16_t bwi_phy_freq_11g_rev1[] = + { BWI_PHY_FREQ_11G_REV1 }; +static const uint16_t bwi_phy_noise_11g_rev1[] = + { BWI_PHY_NOISE_11G_REV1 }; +static const uint16_t bwi_phy_noise_11g[] = + { BWI_PHY_NOISE_11G }; +static const uint32_t bwi_phy_rotor_11g_rev1[] = + { BWI_PHY_ROTOR_11G_REV1 }; +static const uint16_t bwi_phy_noise_scale_11g_rev2[] = + { BWI_PHY_NOISE_SCALE_11G_REV2 }; +static const uint16_t bwi_phy_noise_scale_11g_rev7[] = + { BWI_PHY_NOISE_SCALE_11G_REV7 }; +static const uint16_t bwi_phy_noise_scale_11g[] = + { BWI_PHY_NOISE_SCALE_11G }; +static const uint16_t bwi_phy_sigma_sq_11g_rev2[] = + { BWI_PHY_SIGMA_SQ_11G_REV2 }; +static const uint16_t bwi_phy_sigma_sq_11g_rev7[] = + { BWI_PHY_SIGMA_SQ_11G_REV7 }; +static const uint32_t bwi_phy_delay_11g_rev1[] = + { BWI_PHY_DELAY_11G_REV1 }; + +void +bwi_phy_write(struct bwi_mac *mac, uint16_t ctrl, uint16_t data) +{ + struct bwi_softc *sc = mac->mac_sc; + + /* TODO: 11A */ + CSR_WRITE_2(sc, BWI_PHY_CTRL, ctrl); + CSR_WRITE_2(sc, BWI_PHY_DATA, data); +} + +uint16_t +bwi_phy_read(struct bwi_mac *mac, uint16_t ctrl) +{ + struct bwi_softc *sc = mac->mac_sc; + + /* TODO: 11A */ + CSR_WRITE_2(sc, BWI_PHY_CTRL, ctrl); + return CSR_READ_2(sc, BWI_PHY_DATA); +} + +int +bwi_phy_attach(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + uint8_t phyrev, phytype, phyver; + uint16_t val; + int i; + + /* Get PHY type/revision/version */ + val = CSR_READ_2(sc, BWI_PHYINFO); + phyrev = __SHIFTOUT(val, BWI_PHYINFO_REV_MASK); + phytype = __SHIFTOUT(val, BWI_PHYINFO_TYPE_MASK); + phyver = __SHIFTOUT(val, BWI_PHYINFO_VER_MASK); + device_printf(sc->sc_dev, "PHY: type %d, rev %d, ver %d\n", + phytype, phyrev, phyver); + + /* + * Verify whether the revision of the PHY type is supported + * Convert PHY type to ieee80211_phymode + */ + switch (phytype) { + case BWI_PHYINFO_TYPE_11A: + if (phyrev >= 4) { + device_printf(sc->sc_dev, "unsupported 11A PHY, " + "rev %u\n", phyrev); + return ENXIO; + } + phy->phy_init = bwi_phy_init_11a; + phy->phy_mode = IEEE80211_MODE_11A; + phy->phy_tbl_ctrl = BWI_PHYR_TBL_CTRL_11A; + phy->phy_tbl_data_lo = BWI_PHYR_TBL_DATA_LO_11A; + phy->phy_tbl_data_hi = BWI_PHYR_TBL_DATA_HI_11A; + device_printf(sc->sc_dev, "PHY: 802.11A attach\n"); + break; + case BWI_PHYINFO_TYPE_11B: +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + for (i = 0; i < N(bwi_sup_bphy); ++i) { + if (phyrev == bwi_sup_bphy[i].rev) { + phy->phy_init = bwi_sup_bphy[i].init; + break; + } + } + if (i == N(bwi_sup_bphy)) { + device_printf(sc->sc_dev, "unsupported 11B PHY, " + "rev %u\n", phyrev); + return ENXIO; + } +#undef N + phy->phy_mode = IEEE80211_MODE_11B; + device_printf(sc->sc_dev, "PHY: 802.11B attach\n"); + break; + case BWI_PHYINFO_TYPE_11G: + if (phyrev > 8) { + device_printf(sc->sc_dev, "unsupported 11G PHY, " + "rev %u\n", phyrev); + return ENXIO; + } + phy->phy_init = bwi_phy_init_11g; + phy->phy_mode = IEEE80211_MODE_11G; + phy->phy_tbl_ctrl = BWI_PHYR_TBL_CTRL_11G; + phy->phy_tbl_data_lo = BWI_PHYR_TBL_DATA_LO_11G; + phy->phy_tbl_data_hi = BWI_PHYR_TBL_DATA_HI_11G; + device_printf(sc->sc_dev, "PHY: 802.11G attach\n"); + break; + default: + device_printf(sc->sc_dev, "unsupported PHY type %d\n", + phytype); + return ENXIO; + } + phy->phy_rev = phyrev; + phy->phy_version = phyver; + return 0; +} + +void +bwi_phy_set_bbp_atten(struct bwi_mac *mac, uint16_t bbp_atten) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint16_t mask = __BITS(3, 0); + + if (phy->phy_version == 0) { + CSR_FILT_SETBITS_2(mac->mac_sc, BWI_BBP_ATTEN, ~mask, + __SHIFTIN(bbp_atten, mask)); + } else { + if (phy->phy_version > 1) + mask <<= 2; + else + mask <<= 3; + PHY_FILT_SETBITS(mac, BWI_PHYR_BBP_ATTEN, ~mask, + __SHIFTIN(bbp_atten, mask)); + } +} + +int +bwi_phy_calibrate(struct bwi_mac *mac) +{ + struct bwi_phy *phy = &mac->mac_phy; + + /* Dummy read */ + CSR_READ_4(mac->mac_sc, BWI_MAC_STATUS); + + /* Don't re-init */ + if (phy->phy_flags & BWI_PHY_F_CALIBRATED) + return 0; + + if (phy->phy_mode == IEEE80211_MODE_11G && phy->phy_rev == 1) { + bwi_mac_reset(mac, 0); + bwi_phy_init_11g(mac); + bwi_mac_reset(mac, 1); + } + + phy->phy_flags |= BWI_PHY_F_CALIBRATED; + return 0; +} + +static void +bwi_tbl_write_2(struct bwi_mac *mac, uint16_t ofs, uint16_t data) +{ + struct bwi_phy *phy = &mac->mac_phy; + + KASSERT(phy->phy_tbl_ctrl != 0 && phy->phy_tbl_data_lo != 0, + ("phy_tbl_ctrl %d phy_tbl_data_lo %d", + phy->phy_tbl_ctrl, phy->phy_tbl_data_lo)); + PHY_WRITE(mac, phy->phy_tbl_ctrl, ofs); + PHY_WRITE(mac, phy->phy_tbl_data_lo, data); +} + +static void +bwi_tbl_write_4(struct bwi_mac *mac, uint16_t ofs, uint32_t data) +{ + struct bwi_phy *phy = &mac->mac_phy; + + KASSERT(phy->phy_tbl_data_lo != 0 && phy->phy_tbl_data_hi != 0 && + phy->phy_tbl_ctrl != 0, + ("phy_tbl_data_lo %d phy_tbl_data_hi %d phy_tbl_ctrl %d", + phy->phy_tbl_data_lo, phy->phy_tbl_data_hi, phy->phy_tbl_ctrl)); + + PHY_WRITE(mac, phy->phy_tbl_ctrl, ofs); + PHY_WRITE(mac, phy->phy_tbl_data_hi, data >> 16); + PHY_WRITE(mac, phy->phy_tbl_data_lo, data & 0xffff); +} + +void +bwi_nrssi_write(struct bwi_mac *mac, uint16_t ofs, int16_t data) +{ + PHY_WRITE(mac, BWI_PHYR_NRSSI_CTRL, ofs); + PHY_WRITE(mac, BWI_PHYR_NRSSI_DATA, (uint16_t)data); +} + +int16_t +bwi_nrssi_read(struct bwi_mac *mac, uint16_t ofs) +{ + PHY_WRITE(mac, BWI_PHYR_NRSSI_CTRL, ofs); + return (int16_t)PHY_READ(mac, BWI_PHYR_NRSSI_DATA); +} + +static void +bwi_phy_init_11a(struct bwi_mac *mac) +{ + /* TODO:11A */ +} + +static void +bwi_phy_init_11g(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + const struct bwi_tpctl *tpctl = &mac->mac_tpctl; + + if (phy->phy_rev == 1) + bwi_phy_init_11b_rev5(mac); + else + bwi_phy_init_11b_rev6(mac); + + if (phy->phy_rev >= 2 || (phy->phy_flags & BWI_PHY_F_LINKED)) + bwi_phy_config_11g(mac); + + if (phy->phy_rev >= 2) { + PHY_WRITE(mac, 0x814, 0); + PHY_WRITE(mac, 0x815, 0); + + if (phy->phy_rev == 2) { + PHY_WRITE(mac, 0x811, 0); + PHY_WRITE(mac, 0x15, 0xc0); + } else if (phy->phy_rev > 5) { + PHY_WRITE(mac, 0x811, 0x400); + PHY_WRITE(mac, 0x15, 0xc0); + } + } + + if (phy->phy_rev >= 2 || (phy->phy_flags & BWI_PHY_F_LINKED)) { + uint16_t val; + + val = PHY_READ(mac, 0x400) & 0xff; + if (val == 3 || val == 5) { + PHY_WRITE(mac, 0x4c2, 0x1816); + PHY_WRITE(mac, 0x4c3, 0x8006); + if (val == 5) { + PHY_FILT_SETBITS(mac, 0x4cc, + 0xff, 0x1f00); + } + } + } + + if ((phy->phy_rev <= 2 && (phy->phy_flags & BWI_PHY_F_LINKED)) || + phy->phy_rev >= 2) + PHY_WRITE(mac, 0x47e, 0x78); + + if (rf->rf_rev == 8) { + PHY_SETBITS(mac, 0x801, 0x80); + PHY_SETBITS(mac, 0x43e, 0x4); + } + + if (phy->phy_rev >= 2 && (phy->phy_flags & BWI_PHY_F_LINKED)) + bwi_rf_get_gains(mac); + + if (rf->rf_rev != 8) + bwi_rf_init(mac); + + if (tpctl->tp_ctrl2 == 0xffff) { + bwi_rf_lo_update(mac); + } else { + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev == 8) { + RF_WRITE(mac, 0x52, + (tpctl->tp_ctrl1 << 4) | tpctl->tp_ctrl2); + } else { + RF_FILT_SETBITS(mac, 0x52, 0xfff0, tpctl->tp_ctrl1); + } + + if (phy->phy_rev >= 6) { + PHY_FILT_SETBITS(mac, 0x36, 0xfff, + tpctl->tp_ctrl2 << 12); + } + + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) + PHY_WRITE(mac, 0x2e, 0x8075); + else + PHY_WRITE(mac, 0x2e, 0x807f); + + if (phy->phy_rev < 2) + PHY_WRITE(mac, 0x2f, 0x101); + else + PHY_WRITE(mac, 0x2f, 0x202); + } + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + bwi_rf_lo_adjust(mac, tpctl); + PHY_WRITE(mac, 0x80f, 0x8078); + } + + if ((sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) == 0) { + bwi_rf_init_hw_nrssi_table(mac, 0xffff /* XXX */); + bwi_rf_set_nrssi_thr(mac); + } else if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + if (rf->rf_nrssi[0] == BWI_INVALID_NRSSI) { + KASSERT(rf->rf_nrssi[1] == BWI_INVALID_NRSSI, + ("rf_nrssi[1] %d", rf->rf_nrssi[1])); + bwi_rf_calc_nrssi_slope(mac); + } else { + KASSERT(rf->rf_nrssi[1] != BWI_INVALID_NRSSI, + ("rf_nrssi[1] %d", rf->rf_nrssi[1])); + bwi_rf_set_nrssi_thr(mac); + } + } + + if (rf->rf_rev == 8) + PHY_WRITE(mac, 0x805, 0x3230); + + bwi_mac_init_tpctl_11bg(mac); + + if (sc->sc_bbp_id == BWI_BBPID_BCM4306 && sc->sc_bbp_pkg == 2) { + PHY_CLRBITS(mac, 0x429, 0x4000); + PHY_CLRBITS(mac, 0x4c3, 0x8000); + } +} + +static void +bwi_phy_init_11b_rev2(struct bwi_mac *mac) +{ + /* TODO:11B */ + if_printf(mac->mac_sc->sc_ic.ic_ifp, + "%s is not implemented yet\n", __func__); +} + +static void +bwi_phy_init_11b_rev4(struct bwi_mac *mac) +{ + /* TODO:11B */ + if_printf(mac->mac_sc->sc_ic.ic_ifp, + "%s is not implemented yet\n", __func__); +} + +static void +bwi_phy_init_11b_rev5(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + u_int orig_chan; + + if (phy->phy_version == 1) + RF_SETBITS(mac, 0x7a, 0x50); + + if (sc->sc_pci_subvid != PCI_VENDOR_BROADCOM && + sc->sc_pci_subdid != BWI_PCI_SUBDEVICE_BU4306) { + uint16_t ofs, val; + + val = 0x2120; + for (ofs = 0xa8; ofs < 0xc7; ++ofs) { + PHY_WRITE(mac, ofs, val); + val += 0x202; + } + } + + PHY_FILT_SETBITS(mac, 0x35, 0xf0ff, 0x700); + + if (rf->rf_type == BWI_RF_T_BCM2050) + PHY_WRITE(mac, 0x38, 0x667); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + if (rf->rf_type == BWI_RF_T_BCM2050) { + RF_SETBITS(mac, 0x7a, 0x20); + RF_SETBITS(mac, 0x51, 0x4); + } + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, 0); + + PHY_SETBITS(mac, 0x802, 0x100); + PHY_SETBITS(mac, 0x42b, 0x2000); + PHY_WRITE(mac, 0x1c, 0x186a); + + PHY_FILT_SETBITS(mac, 0x13, 0xff, 0x1900); + PHY_FILT_SETBITS(mac, 0x35, 0xffc0, 0x64); + PHY_FILT_SETBITS(mac, 0x5d, 0xff80, 0xa); + } + + /* TODO: bad_frame_preempt? */ + + if (phy->phy_version == 1) { + PHY_WRITE(mac, 0x26, 0xce00); + PHY_WRITE(mac, 0x21, 0x3763); + PHY_WRITE(mac, 0x22, 0x1bc3); + PHY_WRITE(mac, 0x23, 0x6f9); + PHY_WRITE(mac, 0x24, 0x37e); + } else { + PHY_WRITE(mac, 0x26, 0xcc00); + } + PHY_WRITE(mac, 0x30, 0xc6); + + CSR_WRITE_2(sc, BWI_BPHY_CTRL, BWI_BPHY_CTRL_INIT); + + if (phy->phy_version == 1) + PHY_WRITE(mac, 0x20, 0x3e1c); + else + PHY_WRITE(mac, 0x20, 0x301c); + + if (phy->phy_version == 0) + CSR_WRITE_2(sc, BWI_PHY_MAGIC_REG1, BWI_PHY_MAGIC_REG1_VAL1); + + /* Force to channel 7 */ + orig_chan = rf->rf_curchan; + bwi_rf_set_chan(mac, 7, 0); + + if (rf->rf_type != BWI_RF_T_BCM2050) { + RF_WRITE(mac, 0x75, 0x80); + RF_WRITE(mac, 0x79, 0x81); + } + + RF_WRITE(mac, 0x50, 0x20); + RF_WRITE(mac, 0x50, 0x23); + + if (rf->rf_type == BWI_RF_T_BCM2050) { + RF_WRITE(mac, 0x50, 0x20); + RF_WRITE(mac, 0x5a, 0x70); + } + + RF_WRITE(mac, 0x5b, 0x7b); + RF_WRITE(mac, 0x5c, 0xb0); + RF_SETBITS(mac, 0x7a, 0x7); + + bwi_rf_set_chan(mac, orig_chan, 0); + + PHY_WRITE(mac, 0x14, 0x80); + PHY_WRITE(mac, 0x32, 0xca); + PHY_WRITE(mac, 0x2a, 0x88a3); + + bwi_mac_set_tpctl_11bg(mac, NULL); + + if (rf->rf_type == BWI_RF_T_BCM2050) + RF_WRITE(mac, 0x5d, 0xd); + + CSR_FILT_SETBITS_2(sc, BWI_PHY_MAGIC_REG1, 0xffc0, 0x4); +} + +static void +bwi_phy_init_11b_rev6(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t val, ofs; + u_int orig_chan; + + PHY_WRITE(mac, 0x3e, 0x817a); + RF_SETBITS(mac, 0x7a, 0x58); + + if (rf->rf_rev == 4 || rf->rf_rev == 5) { + RF_WRITE(mac, 0x51, 0x37); + RF_WRITE(mac, 0x52, 0x70); + RF_WRITE(mac, 0x53, 0xb3); + RF_WRITE(mac, 0x54, 0x9b); + RF_WRITE(mac, 0x5a, 0x88); + RF_WRITE(mac, 0x5b, 0x88); + RF_WRITE(mac, 0x5d, 0x88); + RF_WRITE(mac, 0x5e, 0x88); + RF_WRITE(mac, 0x7d, 0x88); + HFLAGS_SETBITS(mac, BWI_HFLAG_MAGIC1); + } else if (rf->rf_rev == 8) { + RF_WRITE(mac, 0x51, 0); + RF_WRITE(mac, 0x52, 0x40); + RF_WRITE(mac, 0x53, 0xb7); + RF_WRITE(mac, 0x54, 0x98); + RF_WRITE(mac, 0x5a, 0x88); + RF_WRITE(mac, 0x5b, 0x6b); + RF_WRITE(mac, 0x5c, 0xf); + if (sc->sc_card_flags & BWI_CARD_F_ALT_IQ) { + RF_WRITE(mac, 0x5d, 0xfa); + RF_WRITE(mac, 0x5e, 0xd8); + } else { + RF_WRITE(mac, 0x5d, 0xf5); + RF_WRITE(mac, 0x5e, 0xb8); + } + RF_WRITE(mac, 0x73, 0x3); + RF_WRITE(mac, 0x7d, 0xa8); + RF_WRITE(mac, 0x7c, 0x1); + RF_WRITE(mac, 0x7e, 0x8); + } + + val = 0x1e1f; + for (ofs = 0x88; ofs < 0x98; ++ofs) { + PHY_WRITE(mac, ofs, val); + val -= 0x202; + } + + val = 0x3e3f; + for (ofs = 0x98; ofs < 0xa8; ++ofs) { + PHY_WRITE(mac, ofs, val); + val -= 0x202; + } + + val = 0x2120; + for (ofs = 0xa8; ofs < 0xc8; ++ofs) { + PHY_WRITE(mac, ofs, (val & 0x3f3f)); + val += 0x202; + } + + if (phy->phy_mode == IEEE80211_MODE_11G) { + RF_SETBITS(mac, 0x7a, 0x20); + RF_SETBITS(mac, 0x51, 0x4); + PHY_SETBITS(mac, 0x802, 0x100); + PHY_SETBITS(mac, 0x42b, 0x2000); + PHY_WRITE(mac, 0x5b, 0); + PHY_WRITE(mac, 0x5c, 0); + } + + /* Force to channel 7 */ + orig_chan = rf->rf_curchan; + if (orig_chan >= 8) + bwi_rf_set_chan(mac, 1, 0); + else + bwi_rf_set_chan(mac, 13, 0); + + RF_WRITE(mac, 0x50, 0x20); + RF_WRITE(mac, 0x50, 0x23); + + DELAY(40); + + if (rf->rf_rev < 6 || rf->rf_rev == 8) { + RF_SETBITS(mac, 0x7c, 0x2); + RF_WRITE(mac, 0x50, 0x20); + } + if (rf->rf_rev <= 2) { + RF_WRITE(mac, 0x7c, 0x20); + RF_WRITE(mac, 0x5a, 0x70); + RF_WRITE(mac, 0x5b, 0x7b); + RF_WRITE(mac, 0x5c, 0xb0); + } + + RF_FILT_SETBITS(mac, 0x7a, 0xf8, 0x7); + + bwi_rf_set_chan(mac, orig_chan, 0); + + PHY_WRITE(mac, 0x14, 0x200); + if (rf->rf_rev >= 6) + PHY_WRITE(mac, 0x2a, 0x88c2); + else + PHY_WRITE(mac, 0x2a, 0x8ac0); + PHY_WRITE(mac, 0x38, 0x668); + + bwi_mac_set_tpctl_11bg(mac, NULL); + + if (rf->rf_rev <= 5) { + PHY_FILT_SETBITS(mac, 0x5d, 0xff80, 0x3); + if (rf->rf_rev <= 2) + RF_WRITE(mac, 0x5d, 0xd); + } + + if (phy->phy_version == 4) { + CSR_WRITE_2(sc, BWI_PHY_MAGIC_REG1, BWI_PHY_MAGIC_REG1_VAL2); + PHY_CLRBITS(mac, 0x61, 0xf000); + } else { + PHY_FILT_SETBITS(mac, 0x2, 0xffc0, 0x4); + } + + if (phy->phy_mode == IEEE80211_MODE_11B) { + CSR_WRITE_2(sc, BWI_BBP_ATTEN, BWI_BBP_ATTEN_MAGIC2); + PHY_WRITE(mac, 0x16, 0x410); + PHY_WRITE(mac, 0x17, 0x820); + PHY_WRITE(mac, 0x62, 0x7); + + bwi_rf_init_bcm2050(mac); + bwi_rf_lo_update(mac); + if (sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) { + bwi_rf_calc_nrssi_slope(mac); + bwi_rf_set_nrssi_thr(mac); + } + bwi_mac_init_tpctl_11bg(mac); + } else { + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0); + } +} + +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + +static void +bwi_phy_config_11g(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + const uint16_t *tbl; + uint16_t wrd_ofs1, wrd_ofs2; + int i, n; + + if (phy->phy_rev == 1) { + PHY_WRITE(mac, 0x406, 0x4f19); + PHY_FILT_SETBITS(mac, 0x429, 0xfc3f, 0x340); + PHY_WRITE(mac, 0x42c, 0x5a); + PHY_WRITE(mac, 0x427, 0x1a); + + /* Fill frequency table */ + for (i = 0; i < N(bwi_phy_freq_11g_rev1); ++i) { + bwi_tbl_write_2(mac, BWI_PHYTBL_FREQ + i, + bwi_phy_freq_11g_rev1[i]); + } + + /* Fill noise table */ + for (i = 0; i < N(bwi_phy_noise_11g_rev1); ++i) { + bwi_tbl_write_2(mac, BWI_PHYTBL_NOISE + i, + bwi_phy_noise_11g_rev1[i]); + } + + /* Fill rotor table */ + for (i = 0; i < N(bwi_phy_rotor_11g_rev1); ++i) { + /* NB: data length is 4 bytes */ + bwi_tbl_write_4(mac, BWI_PHYTBL_ROTOR + i, + bwi_phy_rotor_11g_rev1[i]); + } + } else { + bwi_nrssi_write(mac, 0xba98, (int16_t)0x7654); /* XXX */ + + if (phy->phy_rev == 2) { + PHY_WRITE(mac, 0x4c0, 0x1861); + PHY_WRITE(mac, 0x4c1, 0x271); + } else if (phy->phy_rev > 2) { + PHY_WRITE(mac, 0x4c0, 0x98); + PHY_WRITE(mac, 0x4c1, 0x70); + PHY_WRITE(mac, 0x4c9, 0x80); + } + PHY_SETBITS(mac, 0x42b, 0x800); + + /* Fill RSSI table */ + for (i = 0; i < 64; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_RSSI + i, i); + + /* Fill noise table */ + for (i = 0; i < sizeof(bwi_phy_noise_11g); ++i) { + bwi_tbl_write_2(mac, BWI_PHYTBL_NOISE + i, + bwi_phy_noise_11g[i]); + } + } + + /* + * Fill noise scale table + */ + if (phy->phy_rev <= 2) { + tbl = bwi_phy_noise_scale_11g_rev2; + n = N(bwi_phy_noise_scale_11g_rev2); + } else if (phy->phy_rev >= 7 && (PHY_READ(mac, 0x449) & 0x200)) { + tbl = bwi_phy_noise_scale_11g_rev7; + n = N(bwi_phy_noise_scale_11g_rev7); + } else { + tbl = bwi_phy_noise_scale_11g; + n = N(bwi_phy_noise_scale_11g); + } + for (i = 0; i < n; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_NOISE_SCALE + i, tbl[i]); + + /* + * Fill sigma square table + */ + if (phy->phy_rev == 2) { + tbl = bwi_phy_sigma_sq_11g_rev2; + n = N(bwi_phy_sigma_sq_11g_rev2); + } else if (phy->phy_rev > 2 && phy->phy_rev <= 8) { + tbl = bwi_phy_sigma_sq_11g_rev7; + n = N(bwi_phy_sigma_sq_11g_rev7); + } else { + tbl = NULL; + n = 0; + } + for (i = 0; i < n; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_SIGMA_SQ + i, tbl[i]); + + if (phy->phy_rev == 1) { + /* Fill delay table */ + for (i = 0; i < N(bwi_phy_delay_11g_rev1); ++i) { + bwi_tbl_write_4(mac, BWI_PHYTBL_DELAY + i, + bwi_phy_delay_11g_rev1[i]); + } + + /* Fill WRSSI (Wide-Band RSSI) table */ + for (i = 4; i < 20; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_WRSSI_REV1 + i, 0x20); + + bwi_phy_config_agc(mac); + + wrd_ofs1 = 0x5001; + wrd_ofs2 = 0x5002; + } else { + /* Fill WRSSI (Wide-Band RSSI) table */ + for (i = 0; i < 0x20; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_WRSSI + i, 0x820); + + bwi_phy_config_agc(mac); + + PHY_READ(mac, 0x400); /* Dummy read */ + PHY_WRITE(mac, 0x403, 0x1000); + bwi_tbl_write_2(mac, 0x3c02, 0xf); + bwi_tbl_write_2(mac, 0x3c03, 0x14); + + wrd_ofs1 = 0x401; + wrd_ofs2 = 0x402; + } + + if (!(BWI_IS_BRCM_BU4306(sc) && sc->sc_pci_revid == 0x17)) { + bwi_tbl_write_2(mac, wrd_ofs1, 0x2); + bwi_tbl_write_2(mac, wrd_ofs2, 0x1); + } + + /* phy->phy_flags & BWI_PHY_F_LINKED ? */ + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) + PHY_WRITE(mac, 0x46e, 0x3cf); +} + +#undef N + +/* + * Configure Automatic Gain Controller + */ +static void +bwi_phy_config_agc(struct bwi_mac *mac) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint16_t ofs; + + ofs = phy->phy_rev == 1 ? 0x4c00 : 0; + + bwi_tbl_write_2(mac, ofs, 0xfe); + bwi_tbl_write_2(mac, ofs + 1, 0xd); + bwi_tbl_write_2(mac, ofs + 2, 0x13); + bwi_tbl_write_2(mac, ofs + 3, 0x19); + + if (phy->phy_rev == 1) { + bwi_tbl_write_2(mac, 0x1800, 0x2710); + bwi_tbl_write_2(mac, 0x1801, 0x9b83); + bwi_tbl_write_2(mac, 0x1802, 0x9b83); + bwi_tbl_write_2(mac, 0x1803, 0xf8d); + PHY_WRITE(mac, 0x455, 0x4); + } + + PHY_FILT_SETBITS(mac, 0x4a5, 0xff, 0x5700); + PHY_FILT_SETBITS(mac, 0x41a, 0xff80, 0xf); + PHY_FILT_SETBITS(mac, 0x41a, 0xc07f, 0x2b80); + PHY_FILT_SETBITS(mac, 0x48c, 0xf0ff, 0x300); + + RF_SETBITS(mac, 0x7a, 0x8); + + PHY_FILT_SETBITS(mac, 0x4a0, 0xfff0, 0x8); + PHY_FILT_SETBITS(mac, 0x4a1, 0xf0ff, 0x600); + PHY_FILT_SETBITS(mac, 0x4a2, 0xf0ff, 0x700); + PHY_FILT_SETBITS(mac, 0x4a0, 0xf0ff, 0x100); + + if (phy->phy_rev == 1) + PHY_FILT_SETBITS(mac, 0x4a2, 0xfff0, 0x7); + + PHY_FILT_SETBITS(mac, 0x488, 0xff00, 0x1c); + PHY_FILT_SETBITS(mac, 0x488, 0xc0ff, 0x200); + PHY_FILT_SETBITS(mac, 0x496, 0xff00, 0x1c); + PHY_FILT_SETBITS(mac, 0x489, 0xff00, 0x20); + PHY_FILT_SETBITS(mac, 0x489, 0xc0ff, 0x200); + PHY_FILT_SETBITS(mac, 0x482, 0xff00, 0x2e); + PHY_FILT_SETBITS(mac, 0x496, 0xff, 0x1a00); + PHY_FILT_SETBITS(mac, 0x481, 0xff00, 0x28); + PHY_FILT_SETBITS(mac, 0x481, 0xff, 0x2c00); + + if (phy->phy_rev == 1) { + PHY_WRITE(mac, 0x430, 0x92b); + PHY_FILT_SETBITS(mac, 0x41b, 0xffe1, 0x2); + } else { + PHY_CLRBITS(mac, 0x41b, 0x1e); + PHY_WRITE(mac, 0x41f, 0x287a); + PHY_FILT_SETBITS(mac, 0x420, 0xfff0, 0x4); + + if (phy->phy_rev >= 6) { + PHY_WRITE(mac, 0x422, 0x287a); + PHY_FILT_SETBITS(mac, 0x420, 0xfff, 0x3000); + } + } + + PHY_FILT_SETBITS(mac, 0x4a8, 0x8080, 0x7874); + PHY_WRITE(mac, 0x48e, 0x1c00); + + if (phy->phy_rev == 1) { + PHY_FILT_SETBITS(mac, 0x4ab, 0xf0ff, 0x600); + PHY_WRITE(mac, 0x48b, 0x5e); + PHY_FILT_SETBITS(mac, 0x48c, 0xff00, 0x1e); + PHY_WRITE(mac, 0x48d, 0x2); + } + + bwi_tbl_write_2(mac, ofs + 0x800, 0); + bwi_tbl_write_2(mac, ofs + 0x801, 7); + bwi_tbl_write_2(mac, ofs + 0x802, 16); + bwi_tbl_write_2(mac, ofs + 0x803, 28); + + if (phy->phy_rev >= 6) { + PHY_CLRBITS(mac, 0x426, 0x3); + PHY_CLRBITS(mac, 0x426, 0x1000); + } +} + +void +bwi_set_gains(struct bwi_mac *mac, const struct bwi_gains *gains) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint16_t tbl_gain_ofs1, tbl_gain_ofs2, tbl_gain; + int i; + + if (phy->phy_rev <= 1) { + tbl_gain_ofs1 = 0x5000; + tbl_gain_ofs2 = tbl_gain_ofs1 + 16; + } else { + tbl_gain_ofs1 = 0x400; + tbl_gain_ofs2 = tbl_gain_ofs1 + 8; + } + + for (i = 0; i < 4; ++i) { + if (gains != NULL) { + tbl_gain = gains->tbl_gain1; + } else { + /* Bit swap */ + tbl_gain = (i & 0x1) << 1; + tbl_gain |= (i & 0x2) >> 1; + } + bwi_tbl_write_2(mac, tbl_gain_ofs1 + i, tbl_gain); + } + + for (i = 0; i < 16; ++i) { + if (gains != NULL) + tbl_gain = gains->tbl_gain2; + else + tbl_gain = i; + bwi_tbl_write_2(mac, tbl_gain_ofs2 + i, tbl_gain); + } + + if (gains == NULL || (gains != NULL && gains->phy_gain != -1)) { + uint16_t phy_gain1, phy_gain2; + + if (gains != NULL) { + phy_gain1 = + ((uint16_t)gains->phy_gain << 14) | + ((uint16_t)gains->phy_gain << 6); + phy_gain2 = phy_gain1; + } else { + phy_gain1 = 0x4040; + phy_gain2 = 0x4000; + } + PHY_FILT_SETBITS(mac, 0x4a0, 0xbfbf, phy_gain1); + PHY_FILT_SETBITS(mac, 0x4a1, 0xbfbf, phy_gain1); + PHY_FILT_SETBITS(mac, 0x4a2, 0xbfbf, phy_gain2); + } + bwi_mac_dummy_xmit(mac); +} + +void +bwi_phy_clear_state(struct bwi_phy *phy) +{ + phy->phy_flags &= ~BWI_CLEAR_PHY_FLAGS; +} --- /dev/null +++ sys/dev/bwi/if_bwivar.h @@ -0,0 +1,679 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/if_bwivar.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/if_bwivar.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _IF_BWIVAR_H +#define _IF_BWIVAR_H + +#define BWI_ALIGN 0x1000 +#define BWI_RING_ALIGN BWI_ALIGN +#define BWI_BUS_SPACE_MAXADDR 0x3fffffff + +#define BWI_TX_NRING 6 +#define BWI_TXRX_NRING 6 +#define BWI_TX_NDESC 128 +#define BWI_RX_NDESC 64 +#define BWI_TXSTATS_NDESC 64 +#define BWI_TX_NSPRDESC 2 +#define BWI_TX_DATA_RING 1 + +/* XXX Onoe/Sample/AMRR probably need different configuration */ +#define BWI_SHRETRY 7 +#define BWI_LGRETRY 4 +#define BWI_SHRETRY_FB 3 +#define BWI_LGRETRY_FB 2 + +#define BWI_NOISE_FLOOR -95 /* TODO: noise floor calc */ +#define BWI_FRAME_MIN_LEN(hdr) \ + ((hdr) + sizeof(struct ieee80211_frame_ack) + IEEE80211_CRC_LEN) + +#define CSR_READ_4(sc, reg) \ + bus_space_read_4((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg)) +#define CSR_READ_2(sc, reg) \ + bus_space_read_2((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg)) + +#define CSR_WRITE_4(sc, reg, val) \ + bus_space_write_4((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg), (val)) +#define CSR_WRITE_2(sc, reg, val) \ + bus_space_write_2((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg), (val)) + +#define CSR_SETBITS_4(sc, reg, bits) \ + CSR_WRITE_4((sc), (reg), CSR_READ_4((sc), (reg)) | (bits)) +#define CSR_SETBITS_2(sc, reg, bits) \ + CSR_WRITE_2((sc), (reg), CSR_READ_2((sc), (reg)) | (bits)) + +#define CSR_FILT_SETBITS_4(sc, reg, filt, bits) \ + CSR_WRITE_4((sc), (reg), (CSR_READ_4((sc), (reg)) & (filt)) | (bits)) +#define CSR_FILT_SETBITS_2(sc, reg, filt, bits) \ + CSR_WRITE_2((sc), (reg), (CSR_READ_2((sc), (reg)) & (filt)) | (bits)) + +#define CSR_CLRBITS_4(sc, reg, bits) \ + CSR_WRITE_4((sc), (reg), CSR_READ_4((sc), (reg)) & ~(bits)) +#define CSR_CLRBITS_2(sc, reg, bits) \ + CSR_WRITE_2((sc), (reg), CSR_READ_2((sc), (reg)) & ~(bits)) + +#define BWI_DEBUG +#ifdef BWI_DEBUG +#define DPRINTF(sc, fmt, ...) device_printf(sc->sc_dev, fmt, __VA_ARGS__) +#else +#define DPRINTF(sc, fmt, ...) ((void)0) +#endif + +struct bwi_desc32 { + /* Little endian */ + uint32_t ctrl; + uint32_t addr; /* BWI_DESC32_A_ */ +} __packed; + +#define BWI_DESC32_A_FUNC_TXRX 0x1 +#define BWI_DESC32_A_FUNC_MASK __BITS(31, 30) +#define BWI_DESC32_A_ADDR_MASK __BITS(29, 0) + +#define BWI_DESC32_C_BUFLEN_MASK __BITS(12, 0) +#define BWI_DESC32_C_ADDRHI_MASK __BITS(17, 16) +#define BWI_DESC32_C_EOR __BIT(28) +#define BWI_DESC32_C_INTR __BIT(29) +#define BWI_DESC32_C_FRAME_END __BIT(30) +#define BWI_DESC32_C_FRAME_START __BIT(31) + +struct bwi_desc64 { + /* Little endian */ + uint32_t ctrl0; + uint32_t ctrl1; + uint32_t addr_lo; + uint32_t addr_hi; +} __packed; + +struct bwi_rxbuf_hdr { + /* Little endian */ + uint16_t rxh_buflen; /* exclude bwi_rxbuf_hdr */ + uint8_t rxh_pad1[2]; + uint16_t rxh_flags1; /* BWI_RXH_F1_ */ + uint8_t rxh_rssi; + uint8_t rxh_sq; + uint16_t rxh_phyinfo; /* BWI_RXH_PHYINFO_ */ + uint16_t rxh_flags3; /* BWI_RXH_F3_ */ + uint16_t rxh_flags2; /* BWI_RXH_F2_ */ + uint16_t rxh_tsf; + uint8_t rxh_pad3[14]; /* Padded to 30bytes */ +} __packed; + +#define BWI_RXH_F1_BCM2053_RSSI __BIT(14) +#define BWI_RXH_F1_SHPREAMBLE __BIT(7) +#define BWI_RXH_F1_OFDM __BIT(0) + +#define BWI_RXH_F2_TYPE2FRAME __BIT(2) + +#define BWI_RXH_F3_BCM2050_RSSI __BIT(10) + +#define BWI_RXH_PHYINFO_LNAGAIN __BITS(15, 14) + +struct bwi_txbuf_hdr { + /* Little endian */ + uint32_t txh_mac_ctrl; /* BWI_TXH_MAC_C_ */ + uint8_t txh_fc[2]; + uint16_t txh_unknown1; + uint16_t txh_phy_ctrl; /* BWI_TXH_PHY_C_ */ + uint8_t txh_ivs[16]; + uint8_t txh_addr1[IEEE80211_ADDR_LEN]; + uint16_t txh_unknown2; + uint8_t txh_rts_fb_plcp[4]; + uint16_t txh_rts_fb_duration; + uint8_t txh_fb_plcp[4]; + uint16_t txh_fb_duration; + uint8_t txh_pad2[2]; + uint16_t txh_id; /* BWI_TXH_ID_ */ + uint16_t txh_unknown3; + uint8_t txh_rts_plcp[6]; + uint8_t txh_rts_fc[2]; + uint16_t txh_rts_duration; + uint8_t txh_rts_ra[IEEE80211_ADDR_LEN]; + uint8_t txh_rts_ta[IEEE80211_ADDR_LEN]; + uint8_t txh_pad3[2]; + uint8_t txh_plcp[6]; +} __packed; + +#define BWI_TXH_ID_RING_MASK __BITS(15, 13) +#define BWI_TXH_ID_IDX_MASK __BITS(12, 0) + +#define BWI_TXH_PHY_C_OFDM __BIT(0) +#define BWI_TXH_PHY_C_SHPREAMBLE __BIT(4) +#define BWI_TXH_PHY_C_ANTMODE_MASK __BITS(9, 8) + +#define BWI_TXH_MAC_C_ACK __BIT(0) +#define BWI_TXH_MAC_C_FIRST_FRAG __BIT(3) +#define BWI_TXH_MAC_C_HWSEQ __BIT(4) +#define BWI_TXH_MAC_C_FB_OFDM __BIT(8) + +struct bwi_txstats { + /* Little endian */ + uint8_t txs_pad1[4]; + uint16_t txs_id; + uint8_t txs_flags; /* BWI_TXS_F_ */ + uint8_t txs_txcnt; /* BWI_TXS_TXCNT_ */ + uint8_t txs_pad2[2]; + uint16_t txs_seq; + uint16_t txs_unknown; + uint8_t txs_pad3[2]; /* Padded to 16bytes */ +} __packed; + +#define BWI_TXS_TXCNT_DATA __BITS(7, 4) + +#define BWI_TXS_F_ACKED __BIT(0) +#define BWI_TXS_F_PENDING __BIT(5) + +struct bwi_ring_data { + uint32_t rdata_txrx_ctrl; + bus_dmamap_t rdata_dmap; + bus_addr_t rdata_paddr; + void *rdata_desc; +}; + +struct bwi_txbuf { + struct mbuf *tb_mbuf; + bus_dmamap_t tb_dmap; + + struct ieee80211_node *tb_ni; + int tb_rate_idx[2]; +}; + +struct bwi_txbuf_data { + struct bwi_txbuf tbd_buf[BWI_TX_NDESC]; + int tbd_used; + int tbd_idx; +}; + +struct bwi_rxbuf { + struct mbuf *rb_mbuf; + bus_addr_t rb_paddr; + bus_dmamap_t rb_dmap; +}; + +struct bwi_rxbuf_data { + struct bwi_rxbuf rbd_buf[BWI_RX_NDESC]; + bus_dmamap_t rbd_tmp_dmap; + int rbd_idx; +}; + +struct bwi_txstats_data { + bus_dma_tag_t stats_ring_dtag; + bus_dmamap_t stats_ring_dmap; + bus_addr_t stats_ring_paddr; + void *stats_ring; + + bus_dma_tag_t stats_dtag; + bus_dmamap_t stats_dmap; + bus_addr_t stats_paddr; + struct bwi_txstats *stats; + + uint32_t stats_ctrl_base; + int stats_idx; +}; + +struct bwi_fwhdr { + /* Big endian */ + uint8_t fw_type; /* BWI_FW_T_ */ + uint8_t fw_gen; /* BWI_FW_GEN */ + uint8_t fw_pad[2]; + uint32_t fw_size; +#define fw_iv_cnt fw_size +} __packed; + +#define BWI_FWHDR_SZ sizeof(struct bwi_fwhdr) + +#define BWI_FW_T_UCODE 'u' +#define BWI_FW_T_PCM 'p' +#define BWI_FW_T_IV 'i' + +#define BWI_FW_GEN_1 1 + +#define BWI_FW_VERSION3 3 +#define BWI_FW_VERSION4 4 +#define BWI_FW_VERSION3_REVMAX 0x128 + +#define BWI_FW_PATH "bwi_v%d_" +#define BWI_FW_UCODE_PATH BWI_FW_PATH "ucode%d" +#define BWI_FW_PCM_PATH BWI_FW_PATH "pcm%d" +#define BWI_FW_IV_PATH BWI_FW_PATH "b0g0initvals%d" +#define BWI_FW_IV_EXT_PATH BWI_FW_PATH "b0g0bsinitvals%d" + +struct bwi_fw_iv { + /* Big endian */ + uint16_t iv_ofs; + union { + uint32_t val32; + uint16_t val16; + } iv_val; +} __packed; + +#define BWI_FW_IV_OFS_MASK __BITS(14, 0) +#define BWI_FW_IV_IS_32BIT __BIT(15) + +struct bwi_led { + uint8_t l_flags; /* BWI_LED_F_ */ + uint8_t l_act; /* BWI_LED_ACT_ */ +}; + +#define BWI_LED_F_ACTLOW 0x1 + +enum bwi_clock_mode { + BWI_CLOCK_MODE_SLOW, + BWI_CLOCK_MODE_FAST, + BWI_CLOCK_MODE_DYN +}; + +struct bwi_regwin { + uint32_t rw_flags; /* BWI_REGWIN_F_ */ + uint16_t rw_type; /* BWI_REGWIN_T_ */ + uint8_t rw_id; + uint8_t rw_rev; +}; + +#define BWI_REGWIN_F_EXIST 0x1 + +#define BWI_CREATE_REGWIN(rw, id, type, rev) \ +do { \ + (rw)->rw_flags = BWI_REGWIN_F_EXIST; \ + (rw)->rw_type = (type); \ + (rw)->rw_id = (id); \ + (rw)->rw_rev = (rev); \ +} while (0) + +#define BWI_REGWIN_EXIST(rw) ((rw)->rw_flags & BWI_REGWIN_F_EXIST) +#define BWI_GPIO_REGWIN(sc) \ + (BWI_REGWIN_EXIST(&(sc)->sc_com_regwin) ? \ + &(sc)->sc_com_regwin : &(sc)->sc_bus_regwin) + +struct bwi_mac; + +struct bwi_phy { + enum ieee80211_phymode phy_mode; + int phy_rev; + int phy_version; + + uint32_t phy_flags; /* BWI_PHY_F_ */ + uint16_t phy_tbl_ctrl; + uint16_t phy_tbl_data_lo; + uint16_t phy_tbl_data_hi; + + void (*phy_init)(struct bwi_mac *); +}; + +#define BWI_PHY_F_CALIBRATED 0x1 +#define BWI_PHY_F_LINKED 0x2 +#define BWI_CLEAR_PHY_FLAGS (BWI_PHY_F_CALIBRATED) + +/* TX power control */ +struct bwi_tpctl { + uint16_t bbp_atten; /* BBP attenuation: 4bits */ + uint16_t rf_atten; /* RF attenuation */ + uint16_t tp_ctrl1; /* ??: 3bits */ + uint16_t tp_ctrl2; /* ??: 4bits */ +}; + +#define BWI_RF_ATTEN_FACTOR 4 +#define BWI_RF_ATTEN_MAX0 9 +#define BWI_RF_ATTEN_MAX1 31 +#define BWI_BBP_ATTEN_MAX 11 +#define BWI_TPCTL1_MAX 7 + +struct bwi_rf_lo { + int8_t ctrl_lo; + int8_t ctrl_hi; +}; + +struct bwi_rf { + uint16_t rf_type; /* BWI_RF_T_ */ + uint16_t rf_manu; + int rf_rev; + + uint32_t rf_flags; /* BWI_RF_F_ */ + +#define BWI_RFLO_MAX 56 + struct bwi_rf_lo rf_lo[BWI_RFLO_MAX]; + uint8_t rf_lo_used[8]; + +#define BWI_INVALID_NRSSI -1000 + int16_t rf_nrssi[2]; /* Narrow RSSI */ + int32_t rf_nrssi_slope; + +#define BWI_NRSSI_TBLSZ 64 + int8_t rf_nrssi_table[BWI_NRSSI_TBLSZ]; + + uint16_t rf_lo_gain; /* loopback gain */ + uint16_t rf_rx_gain; /* TRSW RX gain */ + + uint16_t rf_calib; /* RF calibration value */ + u_int rf_curchan; /* current channel */ + + uint16_t rf_ctrl_rd; + int rf_ctrl_adj; + void (*rf_off)(struct bwi_mac *); + void (*rf_on)(struct bwi_mac *); + + void (*rf_set_nrssi_thr)(struct bwi_mac *); + void (*rf_calc_nrssi_slope)(struct bwi_mac *); + int (*rf_calc_rssi) + (struct bwi_mac *, + const struct bwi_rxbuf_hdr *); + +#define BWI_TSSI_MAX 64 + int8_t rf_txpower_map0[BWI_TSSI_MAX]; + /* Indexed by TSSI */ + int rf_idle_tssi0; + + int8_t rf_txpower_map[BWI_TSSI_MAX]; + int rf_idle_tssi; + + int rf_base_tssi; + + int rf_txpower_max; /* dBm */ + + int rf_ant_mode; /* BWI_ANT_MODE_ */ +}; + +#define BWI_RF_F_INITED 0x1 +#define BWI_RF_F_ON 0x2 +#define BWI_RF_CLEAR_FLAGS (BWI_RF_F_INITED) + +#define BWI_ANT_MODE_0 0 +#define BWI_ANT_MODE_1 1 +#define BWI_ANT_MODE_UNKN 2 +#define BWI_ANT_MODE_AUTO 3 + +struct bwi_softc; +struct firmware; + +struct bwi_mac { + struct bwi_regwin mac_regwin; /* MUST be first field */ +#define mac_rw_flags mac_regwin.rw_flags +#define mac_type mac_regwin.rw_type +#define mac_id mac_regwin.rw_id +#define mac_rev mac_regwin.rw_rev + + struct bwi_softc *mac_sc; + + struct bwi_phy mac_phy; /* PHY I/F */ + struct bwi_rf mac_rf; /* RF I/F */ + + struct bwi_tpctl mac_tpctl; /* TX power control */ + uint32_t mac_flags; /* BWI_MAC_F_ */ + + const struct firmware *mac_ucode; + const struct firmware *mac_pcm; + const struct firmware *mac_iv; + const struct firmware *mac_iv_ext; +}; + +#define BWI_MAC_F_BSWAP 0x1 +#define BWI_MAC_F_TPCTL_INITED 0x2 +#define BWI_MAC_F_HAS_TXSTATS 0x4 +#define BWI_MAC_F_INITED 0x8 +#define BWI_MAC_F_ENABLED 0x10 +#define BWI_MAC_F_LOCKED 0x20 /* for debug */ +#define BWI_MAC_F_TPCTL_ERROR 0x40 + +#define BWI_CREATE_MAC(mac, sc, id, rev) \ +do { \ + BWI_CREATE_REGWIN(&(mac)->mac_regwin, \ + (id), \ + BWI_REGWIN_T_D11, \ + (rev)); \ + (mac)->mac_sc = (sc); \ +} while (0) + +#define BWI_MAC_MAX 2 +#define BWI_LED_MAX 4 + +enum bwi_bus_space { + BWI_BUS_SPACE_30BIT = 1, + BWI_BUS_SPACE_32BIT, + BWI_BUS_SPACE_64BIT +}; + +#define BWI_TX_RADIOTAP_PRESENT \ + ((1 << IEEE80211_RADIOTAP_FLAGS) | \ + (1 << IEEE80211_RADIOTAP_RATE) | \ + (1 << IEEE80211_RADIOTAP_CHANNEL)) + +struct bwi_tx_radiotap_hdr { + struct ieee80211_radiotap_header wt_ihdr; + uint8_t wt_flags; + uint8_t wt_rate; + uint16_t wt_chan_freq; + uint16_t wt_chan_flags; +}; + +#define BWI_RX_RADIOTAP_PRESENT \ + ((1 << IEEE80211_RADIOTAP_TSFT) | \ + (1 << IEEE80211_RADIOTAP_FLAGS) | \ + (1 << IEEE80211_RADIOTAP_RATE) | \ + (1 << IEEE80211_RADIOTAP_CHANNEL) | \ + (1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL) | \ + (1 << IEEE80211_RADIOTAP_DBM_ANTNOISE)) + +struct bwi_rx_radiotap_hdr { + struct ieee80211_radiotap_header wr_ihdr; + uint64_t wr_tsf; + uint8_t wr_flags; + uint8_t wr_rate; + uint16_t wr_chan_freq; + uint16_t wr_chan_flags; + int8_t wr_antsignal; + int8_t wr_antnoise; + /* TODO: sq */ +}; + +struct bwi_node { + struct ieee80211_node ni; /* must be the first */ + struct ieee80211_amrr_node amn; +}; + +struct bwi_softc { + struct ifnet *sc_ifp; + struct ieee80211com sc_ic; + struct ieee80211_amrr sc_amrr; + uint32_t sc_flags; /* BWI_F_ */ + device_t sc_dev; + struct mtx sc_mtx; + int sc_invalid; + + uint32_t sc_cap; /* BWI_CAP_ */ + uint16_t sc_bbp_id; /* BWI_BBPID_ */ + uint8_t sc_bbp_rev; + uint8_t sc_bbp_pkg; + + uint8_t sc_pci_revid; + uint16_t sc_pci_did; + uint16_t sc_pci_subvid; + uint16_t sc_pci_subdid; + + uint16_t sc_card_flags; /* BWI_CARD_F_ */ + uint16_t sc_pwron_delay; + int sc_locale; + + int sc_irq_rid; + struct resource *sc_irq_res; + void *sc_irq_handle; + + int sc_mem_rid; + struct resource *sc_mem_res; + bus_space_tag_t sc_mem_bt; + bus_space_handle_t sc_mem_bh; + + struct callout sc_calib_ch; + struct callout sc_amrr_ch; + + struct bwi_regwin *sc_cur_regwin; + struct bwi_regwin sc_com_regwin; + struct bwi_regwin sc_bus_regwin; + + int sc_nmac; + struct bwi_mac sc_mac[BWI_MAC_MAX]; + + struct bwi_led sc_leds[BWI_LED_MAX]; + + enum bwi_bus_space sc_bus_space; + bus_dma_tag_t sc_parent_dtag; + + bus_dma_tag_t sc_buf_dtag; + struct bwi_txbuf_data sc_tx_bdata[BWI_TX_NRING]; + struct bwi_rxbuf_data sc_rx_bdata; + + bus_dma_tag_t sc_txring_dtag; + struct bwi_ring_data sc_tx_rdata[BWI_TX_NRING]; + bus_dma_tag_t sc_rxring_dtag; + struct bwi_ring_data sc_rx_rdata; + + struct bwi_txstats_data *sc_txstats; + + int sc_tx_timer; + + struct bpf_if *sc_drvbpf; + struct bwi_tx_radiotap_hdr sc_tx_th; + int sc_tx_th_len; + struct bwi_rx_radiotap_hdr sc_rx_th; + int sc_rx_th_len; + + int (*sc_newstate) + (struct ieee80211com *, + enum ieee80211_state, int); + + int (*sc_init_tx_ring)(struct bwi_softc *, int); + void (*sc_free_tx_ring)(struct bwi_softc *, int); + + int (*sc_init_rx_ring)(struct bwi_softc *); + void (*sc_free_rx_ring)(struct bwi_softc *); + + int (*sc_init_txstats)(struct bwi_softc *); + void (*sc_free_txstats)(struct bwi_softc *); + + void (*sc_setup_rxdesc) + (struct bwi_softc *, int, bus_addr_t, int); + void (*sc_rxeof)(struct bwi_softc *); + + void (*sc_setup_txdesc) + (struct bwi_softc *, struct bwi_ring_data *, + int, bus_addr_t, int); + void (*sc_start_tx) + (struct bwi_softc *, uint32_t, int); + + void (*sc_txeof_status)(struct bwi_softc *); + + /* Sysctl variables */ + int sc_fw_version; /* BWI_FW_VERSION[34] */ + int sc_dwell_time; /* milliseconds */ +}; + +#define BWI_F_BUS_INITED 0x1 +#define BWI_F_PROMISC 0x2 + +#define BWI_LOCK_INIT(sc) \ + mtx_init(&(sc)->sc_mtx, device_get_nameunit((sc)->sc_dev), \ + MTX_NETWORK_LOCK, MTX_DEF | MTX_RECURSE); +#define BWI_LOCK_DESTROY(sc) mtx_destroy(&(sc)->sc_mtx) +#define BWI_LOCK(sc) mtx_lock(&sc->sc_mtx) +#define BWI_UNLOCK(sc) mtx_unlock(&sc->sc_mtx) +#define BWI_LOCK_ASSERT(sc) mtx_assert(&sc->sc_mtx, MA_OWNED) + +int bwi_attach(struct bwi_softc *); +int bwi_detach(struct bwi_softc *); +void bwi_suspend(struct bwi_softc *); +void bwi_resume(struct bwi_softc *); +int bwi_shutdown(struct bwi_softc *); +void bwi_intr(void *); + +int bwi_bus_init(struct bwi_softc *, struct bwi_mac *mac); + +uint16_t bwi_read_sprom(struct bwi_softc *, uint16_t); +int bwi_regwin_switch(struct bwi_softc *, struct bwi_regwin *, + struct bwi_regwin **); +int bwi_regwin_is_enabled(struct bwi_softc *, struct bwi_regwin *); +void bwi_regwin_enable(struct bwi_softc *, struct bwi_regwin *, + uint32_t); +void bwi_regwin_disable(struct bwi_softc *, struct bwi_regwin *, + uint32_t); +uint8_t bwi_rate2plcp(uint8_t); /* XXX belongs to 802.11 */ + +#define abs(a) __builtin_abs(a) + +enum ieee80211_modtype { + IEEE80211_MODTYPE_DS, + IEEE80211_MODTYPE_PBCC, + IEEE80211_MODTYPE_OFDM +}; +#define IEEE80211_MODTYPE_CCK IEEE80211_MODTYPE_DS + +/* + * Contention window (slots). + */ +#define IEEE80211_CW_MAX 1023 /* aCWmax */ +#define IEEE80211_CW_MIN_0 31 /* DS/CCK aCWmin, ERP aCWmin(0) */ +#define IEEE80211_CW_MIN_1 15 /* OFDM aCWmin, ERP aCWmin(1) */ + +/* + * SIFS (microseconds). + */ +#define IEEE80211_DUR_SIFS 10 /* DS/CCK/ERP SIFS */ +#define IEEE80211_DUR_OFDM_SIFS 16 /* OFDM SIFS */ + +/* + * Slot time (microseconds). + */ +#define IEEE80211_DUR_SLOT 20 /* DS/CCK slottime, ERP long slottime */ +#define IEEE80211_DUR_SHSLOT 9 /* ERP short slottime */ +#define IEEE80211_DUR_OFDM_SLOT 9 /* OFDM slottime */ + +/* + * DIFS (microseconds). + */ +#define IEEE80211_DUR_DIFS(sifs, slot) ((sifs) + 2 * (slot)) + +/* XXX does not belong here */ +struct ieee80211_ds_plcp_hdr { + uint8_t i_signal; + uint8_t i_service; + uint16_t i_length; + uint16_t i_crc; +} __packed; + +enum ieee80211_modtype ieee80211_rate2modtype(uint8_t rate); +uint8_t ieee80211_ack_rate(struct ieee80211_node *ni, uint8_t rate); +uint16_t ieee80211_txtime(struct ieee80211_node *ni, u_int len, + uint8_t rs_rate, uint32_t flags); +uint8_t ieee80211_plcp2rate(uint8_t, int); + +#endif /* !_IF_BWIVAR_H */ --- /dev/null +++ sys/dev/bwi/bwimac.c @@ -0,0 +1,1901 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwimac.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwimac.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" +#include "bwiphy.h" + +struct bwi_retry_lim { + uint16_t shretry; + uint16_t shretry_fb; + uint16_t lgretry; + uint16_t lgretry_fb; +}; + +static int bwi_mac_test(struct bwi_mac *); +static int bwi_mac_get_property(struct bwi_mac *); + +static void bwi_mac_set_retry_lim(struct bwi_mac *, + const struct bwi_retry_lim *); +static void bwi_mac_set_ackrates(struct bwi_mac *, + const struct ieee80211_rateset *); + +static int bwi_mac_gpio_init(struct bwi_mac *); +static int bwi_mac_gpio_fini(struct bwi_mac *); +static void bwi_mac_opmode_init(struct bwi_mac *); +static void bwi_mac_hostflags_init(struct bwi_mac *); +static void bwi_mac_bss_param_init(struct bwi_mac *); + +static int bwi_mac_fw_alloc(struct bwi_mac *); +static void bwi_mac_fw_free(struct bwi_mac *); +static int bwi_mac_fw_load(struct bwi_mac *); +static int bwi_mac_fw_init(struct bwi_mac *); +static int bwi_mac_fw_load_iv(struct bwi_mac *, const struct firmware *); + +static void bwi_mac_setup_tpctl(struct bwi_mac *); +static void bwi_mac_adjust_tpctl(struct bwi_mac *, int, int); + +static void bwi_mac_lock(struct bwi_mac *); +static void bwi_mac_unlock(struct bwi_mac *); + +static const uint8_t bwi_sup_macrev[] = { 2, 4, 5, 6, 7, 9, 10 }; + +void +bwi_tmplt_write_4(struct bwi_mac *mac, uint32_t ofs, uint32_t val) +{ + struct bwi_softc *sc = mac->mac_sc; + + if (mac->mac_flags & BWI_MAC_F_BSWAP) + val = bswap32(val); + + CSR_WRITE_4(sc, BWI_MAC_TMPLT_CTRL, ofs); + CSR_WRITE_4(sc, BWI_MAC_TMPLT_DATA, val); +} + +void +bwi_hostflags_write(struct bwi_mac *mac, uint64_t flags) +{ + uint64_t val; + + val = flags & 0xffff; + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_LO, val); + + val = (flags >> 16) & 0xffff; + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_MI, val); + + /* HI has unclear meaning, so leave it as it is */ +} + +uint64_t +bwi_hostflags_read(struct bwi_mac *mac) +{ + uint64_t flags, val; + + /* HI has unclear meaning, so don't touch it */ + flags = 0; + + val = MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_MI); + flags |= val << 16; + + val = MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_LO); + flags |= val; + + return flags; +} + +uint16_t +bwi_memobj_read_2(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t data_reg; + int ofs; + + data_reg = BWI_MOBJ_DATA; + ofs = ofs0 / 4; + + if (ofs0 % 4 != 0) + data_reg = BWI_MOBJ_DATA_UNALIGN; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + return CSR_READ_2(sc, data_reg); +} + +uint32_t +bwi_memobj_read_4(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0) +{ + struct bwi_softc *sc = mac->mac_sc; + int ofs; + + ofs = ofs0 / 4; + if (ofs0 % 4 != 0) { + uint32_t ret; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + ret = CSR_READ_2(sc, BWI_MOBJ_DATA_UNALIGN); + ret <<= 16; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(obj_id, ofs + 1)); + ret |= CSR_READ_2(sc, BWI_MOBJ_DATA); + + return ret; + } else { + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + return CSR_READ_4(sc, BWI_MOBJ_DATA); + } +} + +void +bwi_memobj_write_2(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0, + uint16_t v) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t data_reg; + int ofs; + + data_reg = BWI_MOBJ_DATA; + ofs = ofs0 / 4; + + if (ofs0 % 4 != 0) + data_reg = BWI_MOBJ_DATA_UNALIGN; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + CSR_WRITE_2(sc, data_reg, v); +} + +void +bwi_memobj_write_4(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0, + uint32_t v) +{ + struct bwi_softc *sc = mac->mac_sc; + int ofs; + + ofs = ofs0 / 4; + if (ofs0 % 4 != 0) { + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + CSR_WRITE_2(sc, BWI_MOBJ_DATA_UNALIGN, v >> 16); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(obj_id, ofs + 1)); + CSR_WRITE_2(sc, BWI_MOBJ_DATA, v & 0xffff); + } else { + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + CSR_WRITE_4(sc, BWI_MOBJ_DATA, v); + } +} + +int +bwi_mac_lateattach(struct bwi_mac *mac) +{ + int error; + + if (mac->mac_rev >= 5) + CSR_READ_4(mac->mac_sc, BWI_STATE_HI); /* dummy read */ + + bwi_mac_reset(mac, 1); + + error = bwi_phy_attach(mac); + if (error) + return error; + + error = bwi_rf_attach(mac); + if (error) + return error; + + /* Link 11B/G PHY, unlink 11A PHY */ + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11A) + bwi_mac_reset(mac, 0); + else + bwi_mac_reset(mac, 1); + + error = bwi_mac_test(mac); + if (error) + return error; + + error = bwi_mac_get_property(mac); + if (error) + return error; + + error = bwi_rf_map_txpower(mac); + if (error) + return error; + + bwi_rf_off(mac); + CSR_WRITE_2(mac->mac_sc, BWI_BBP_ATTEN, BWI_BBP_ATTEN_MAGIC); + bwi_regwin_disable(mac->mac_sc, &mac->mac_regwin, 0); + + return 0; +} + +int +bwi_mac_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + int error, i; + + /* Clear MAC/PHY/RF states */ + bwi_mac_setup_tpctl(mac); + bwi_rf_clear_state(&mac->mac_rf); + bwi_phy_clear_state(&mac->mac_phy); + + /* Enable MAC and linked it to PHY */ + if (!bwi_regwin_is_enabled(sc, &mac->mac_regwin)) + bwi_mac_reset(mac, 1); + + /* Initialize backplane */ + error = bwi_bus_init(sc, mac); + if (error) + return error; + + /* XXX work around for hardware bugs? */ + if (sc->sc_bus_regwin.rw_rev <= 5 && + sc->sc_bus_regwin.rw_type != BWI_REGWIN_T_PCIE) { + CSR_SETBITS_4(sc, BWI_CONF_LO, + __SHIFTIN(BWI_CONF_LO_SERVTO, BWI_CONF_LO_SERVTO_MASK) | + __SHIFTIN(BWI_CONF_LO_REQTO, BWI_CONF_LO_REQTO_MASK)); + } + + /* Calibrate PHY */ + error = bwi_phy_calibrate(mac); + if (error) { + device_printf(sc->sc_dev, "PHY calibrate failed\n"); + return error; + } + + /* Prepare to initialize firmware */ + CSR_WRITE_4(sc, BWI_MAC_STATUS, + BWI_MAC_STATUS_UCODE_JUMP0 | + BWI_MAC_STATUS_IHREN); + + /* + * Load and initialize firmwares + */ + error = bwi_mac_fw_alloc(mac); + if (error) + return error; + + error = bwi_mac_fw_load(mac); + if (error) + return error; + + error = bwi_mac_gpio_init(mac); + if (error) + return error; + + error = bwi_mac_fw_init(mac); + if (error) + return error; + + /* + * Turn on RF + */ + bwi_rf_on(mac); + + /* TODO: LED, hardware rf enabled is only related to LED setting */ + + /* + * Initialize PHY + */ + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0); + bwi_phy_init(mac); + + /* TODO: interference mitigation */ + + /* + * Setup antenna mode + */ + bwi_rf_set_ant_mode(mac, mac->mac_rf.rf_ant_mode); + + /* + * Initialize operation mode (RX configuration) + */ + bwi_mac_opmode_init(mac); + + /* XXX what's these */ + if (mac->mac_rev < 3) { + CSR_WRITE_2(sc, 0x60e, 0); + CSR_WRITE_2(sc, 0x610, 0x8000); + CSR_WRITE_2(sc, 0x604, 0); + CSR_WRITE_2(sc, 0x606, 0x200); + } else { + CSR_WRITE_4(sc, 0x188, 0x80000000); + CSR_WRITE_4(sc, 0x18c, 0x2000000); + } + + /* + * Initialize TX/RX interrupts' mask + */ + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, BWI_INTR_TIMER1); + for (i = 0; i < BWI_TXRX_NRING; ++i) { + uint32_t intrs; + + if (BWI_TXRX_IS_RX(i)) + intrs = BWI_TXRX_RX_INTRS; + else + intrs = BWI_TXRX_TX_INTRS; + CSR_WRITE_4(sc, BWI_TXRX_INTR_MASK(i), intrs); + } + + /* XXX what's this */ + CSR_SETBITS_4(sc, BWI_STATE_LO, 0x100000); + + /* Setup MAC power up delay */ + CSR_WRITE_2(sc, BWI_MAC_POWERUP_DELAY, sc->sc_pwron_delay); + + /* Set MAC regwin revision */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_MACREV, mac->mac_rev); + + /* + * Initialize host flags + */ + bwi_mac_hostflags_init(mac); + + /* + * Initialize BSS parameters + */ + bwi_mac_bss_param_init(mac); + + /* + * Initialize TX rings + */ + for (i = 0; i < BWI_TX_NRING; ++i) { + error = sc->sc_init_tx_ring(sc, i); + if (error) { + device_printf(sc->sc_dev, + "can't initialize %dth TX ring\n", i); + return error; + } + } + + /* + * Initialize RX ring + */ + error = sc->sc_init_rx_ring(sc); + if (error) { + device_printf(sc->sc_dev, "can't initialize RX ring\n"); + return error; + } + + /* + * Initialize TX stats if the current MAC uses that + */ + if (mac->mac_flags & BWI_MAC_F_HAS_TXSTATS) { + error = sc->sc_init_txstats(sc); + if (error) { + device_printf(sc->sc_dev, + "can't initialize TX stats ring\n"); + return error; + } + } + + /* XXX what's these */ + CSR_WRITE_2(sc, 0x612, 0x50); /* Force Pre-TBTT to 80? */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, 0x416, 0x50); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, 0x414, 0x1f4); + + mac->mac_flags |= BWI_MAC_F_INITED; + return 0; +} + +void +bwi_mac_reset(struct bwi_mac *mac, int link_phy) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t flags, state_lo, status; + + flags = BWI_STATE_LO_FLAG_PHYRST | BWI_STATE_LO_FLAG_PHYCLKEN; + if (link_phy) + flags |= BWI_STATE_LO_FLAG_PHYLNK; + bwi_regwin_enable(sc, &mac->mac_regwin, flags); + DELAY(2000); + + state_lo = CSR_READ_4(sc, BWI_STATE_LO); + state_lo |= BWI_STATE_LO_GATED_CLOCK; + state_lo &= ~__SHIFTIN(BWI_STATE_LO_FLAG_PHYRST, + BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1000); + + state_lo &= ~BWI_STATE_LO_GATED_CLOCK; + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1000); + + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0); + + status = CSR_READ_4(sc, BWI_MAC_STATUS); + status |= BWI_MAC_STATUS_IHREN; + if (link_phy) + status |= BWI_MAC_STATUS_PHYLNK; + else + status &= ~BWI_MAC_STATUS_PHYLNK; + CSR_WRITE_4(sc, BWI_MAC_STATUS, status); + + if (link_phy) { + DPRINTF(sc, "%s\n", "PHY is linked"); + mac->mac_phy.phy_flags |= BWI_PHY_F_LINKED; + } else { + DPRINTF(sc, "%s\n", "PHY is unlinked"); + mac->mac_phy.phy_flags &= ~BWI_PHY_F_LINKED; + } +} + +void +bwi_mac_set_tpctl_11bg(struct bwi_mac *mac, const struct bwi_tpctl *new_tpctl) +{ + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_tpctl *tpctl = &mac->mac_tpctl; + + if (new_tpctl != NULL) { + KASSERT(new_tpctl->bbp_atten <= BWI_BBP_ATTEN_MAX, + ("bbp_atten %d", new_tpctl->bbp_atten)); + KASSERT(new_tpctl->rf_atten <= + (rf->rf_rev < 6 ? BWI_RF_ATTEN_MAX0 + : BWI_RF_ATTEN_MAX1), + ("rf_atten %d", new_tpctl->rf_atten)); + KASSERT(new_tpctl->tp_ctrl1 <= BWI_TPCTL1_MAX, + ("tp_ctrl1 %d", new_tpctl->tp_ctrl1)); + + tpctl->bbp_atten = new_tpctl->bbp_atten; + tpctl->rf_atten = new_tpctl->rf_atten; + tpctl->tp_ctrl1 = new_tpctl->tp_ctrl1; + } + + /* Set BBP attenuation */ + bwi_phy_set_bbp_atten(mac, tpctl->bbp_atten); + + /* Set RF attenuation */ + RF_WRITE(mac, BWI_RFR_ATTEN, tpctl->rf_atten); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_RF_ATTEN, + tpctl->rf_atten); + + /* Set TX power */ + if (rf->rf_type == BWI_RF_T_BCM2050) { + RF_FILT_SETBITS(mac, BWI_RFR_TXPWR, ~BWI_RFR_TXPWR1_MASK, + __SHIFTIN(tpctl->tp_ctrl1, BWI_RFR_TXPWR1_MASK)); + } + + /* Adjust RF Local Oscillator */ + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11G) + bwi_rf_lo_adjust(mac, tpctl); +} + +static int +bwi_mac_test(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t orig_val, val; + +#define TEST_VAL1 0xaa5555aa +#define TEST_VAL2 0x55aaaa55 + + /* Save it for later restoring */ + orig_val = MOBJ_READ_4(mac, BWI_COMM_MOBJ, 0); + + /* Test 1 */ + MOBJ_WRITE_4(mac, BWI_COMM_MOBJ, 0, TEST_VAL1); + val = MOBJ_READ_4(mac, BWI_COMM_MOBJ, 0); + if (val != TEST_VAL1) { + device_printf(sc->sc_dev, "TEST1 failed\n"); + return ENXIO; + } + + /* Test 2 */ + MOBJ_WRITE_4(mac, BWI_COMM_MOBJ, 0, TEST_VAL2); + val = MOBJ_READ_4(mac, BWI_COMM_MOBJ, 0); + if (val != TEST_VAL2) { + device_printf(sc->sc_dev, "TEST2 failed\n"); + return ENXIO; + } + + /* Restore to the original value */ + MOBJ_WRITE_4(mac, BWI_COMM_MOBJ, 0, orig_val); + + val = CSR_READ_4(sc, BWI_MAC_STATUS); + if ((val & ~BWI_MAC_STATUS_PHYLNK) != BWI_MAC_STATUS_IHREN) { + device_printf(sc->sc_dev, "%s failed, MAC status 0x%08x\n", + __func__, val); + return ENXIO; + } + + val = CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + if (val != 0) { + device_printf(sc->sc_dev, "%s failed, intr status %08x\n", + __func__, val); + return ENXIO; + } + +#undef TEST_VAL2 +#undef TEST_VAL1 + + return 0; +} + +static void +bwi_mac_setup_tpctl(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_tpctl *tpctl = &mac->mac_tpctl; + + /* Calc BBP attenuation */ + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev < 6) + tpctl->bbp_atten = 0; + else + tpctl->bbp_atten = 2; + + /* Calc TX power CTRL1?? */ + tpctl->tp_ctrl1 = 0; + if (rf->rf_type == BWI_RF_T_BCM2050) { + if (rf->rf_rev == 1) + tpctl->tp_ctrl1 = 3; + else if (rf->rf_rev < 6) + tpctl->tp_ctrl1 = 2; + else if (rf->rf_rev == 8) + tpctl->tp_ctrl1 = 1; + } + + /* Empty TX power CTRL2?? */ + tpctl->tp_ctrl2 = 0xffff; + + /* + * Calc RF attenuation + */ + if (phy->phy_mode == IEEE80211_MODE_11A) { + tpctl->rf_atten = 0x60; + goto back; + } + + if (BWI_IS_BRCM_BCM4309G(sc) && sc->sc_pci_revid < 0x51) { + tpctl->rf_atten = sc->sc_pci_revid < 0x43 ? 2 : 3; + goto back; + } + + tpctl->rf_atten = 5; + + if (rf->rf_type != BWI_RF_T_BCM2050) { + if (rf->rf_type == BWI_RF_T_BCM2053 && rf->rf_rev == 1) + tpctl->rf_atten = 6; + goto back; + } + + /* + * NB: If we reaches here and the card is BRCM_BCM4309G, + * then the card's PCI revision must >= 0x51 + */ + + /* BCM2050 RF */ + switch (rf->rf_rev) { + case 1: + if (phy->phy_mode == IEEE80211_MODE_11G) { + if (BWI_IS_BRCM_BCM4309G(sc) || BWI_IS_BRCM_BU4306(sc)) + tpctl->rf_atten = 3; + else + tpctl->rf_atten = 1; + } else { + if (BWI_IS_BRCM_BCM4309G(sc)) + tpctl->rf_atten = 7; + else + tpctl->rf_atten = 6; + } + break; + case 2: + if (phy->phy_mode == IEEE80211_MODE_11G) { + /* + * NOTE: Order of following conditions is critical + */ + if (BWI_IS_BRCM_BCM4309G(sc)) + tpctl->rf_atten = 3; + else if (BWI_IS_BRCM_BU4306(sc)) + tpctl->rf_atten = 5; + else if (sc->sc_bbp_id == BWI_BBPID_BCM4320) + tpctl->rf_atten = 4; + else + tpctl->rf_atten = 3; + } else { + tpctl->rf_atten = 6; + } + break; + case 4: + case 5: + tpctl->rf_atten = 1; + break; + case 8: + tpctl->rf_atten = 0x1a; + break; + } +back: + DPRINTF(sc, "bbp atten: %u, rf atten: %u, ctrl1: %u, ctrl2: %u\n", + tpctl->bbp_atten, tpctl->rf_atten, + tpctl->tp_ctrl1, tpctl->tp_ctrl2); +} + +void +bwi_mac_dummy_xmit(struct bwi_mac *mac) +{ +#define PACKET_LEN 5 + static const uint32_t packet_11a[PACKET_LEN] = + { 0x000201cc, 0x00d40000, 0x00000000, 0x01000000, 0x00000000 }; + static const uint32_t packet_11bg[PACKET_LEN] = + { 0x000b846e, 0x00d40000, 0x00000000, 0x01000000, 0x00000000 }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + const uint32_t *packet; + uint16_t val_50c; + int wait_max, i; + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11A) { + wait_max = 30; + packet = packet_11a; + val_50c = 1; + } else { + wait_max = 250; + packet = packet_11bg; + val_50c = 0; + } + + for (i = 0; i < PACKET_LEN; ++i) + TMPLT_WRITE_4(mac, i * 4, packet[i]); + + CSR_READ_4(sc, BWI_MAC_STATUS); /* dummy read */ + + CSR_WRITE_2(sc, 0x568, 0); + CSR_WRITE_2(sc, 0x7c0, 0); + CSR_WRITE_2(sc, 0x50c, val_50c); + CSR_WRITE_2(sc, 0x508, 0); + CSR_WRITE_2(sc, 0x50a, 0); + CSR_WRITE_2(sc, 0x54c, 0); + CSR_WRITE_2(sc, 0x56a, 0x14); + CSR_WRITE_2(sc, 0x568, 0x826); + CSR_WRITE_2(sc, 0x500, 0); + CSR_WRITE_2(sc, 0x502, 0x30); + + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev <= 5) + RF_WRITE(mac, 0x51, 0x17); + + for (i = 0; i < wait_max; ++i) { + if (CSR_READ_2(sc, 0x50e) & 0x80) + break; + DELAY(10); + } + for (i = 0; i < 10; ++i) { + if (CSR_READ_2(sc, 0x50e) & 0x400) + break; + DELAY(10); + } + for (i = 0; i < 10; ++i) { + if ((CSR_READ_2(sc, 0x690) & 0x100) == 0) + break; + DELAY(10); + } + + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev <= 5) + RF_WRITE(mac, 0x51, 0x37); +#undef PACKET_LEN +} + +void +bwi_mac_init_tpctl_11bg(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_tpctl tpctl_orig; + int restore_tpctl = 0; + + KASSERT(phy->phy_mode != IEEE80211_MODE_11A, + ("phy_mode %d", phy->phy_mode)); + + if (BWI_IS_BRCM_BU4306(sc)) + return; + + PHY_WRITE(mac, 0x28, 0x8018); + CSR_CLRBITS_2(sc, BWI_BBP_ATTEN, 0x20); + + if (phy->phy_mode == IEEE80211_MODE_11G) { + if ((phy->phy_flags & BWI_PHY_F_LINKED) == 0) + return; + PHY_WRITE(mac, 0x47a, 0xc111); + } + if (mac->mac_flags & BWI_MAC_F_TPCTL_INITED) + return; + + if (phy->phy_mode == IEEE80211_MODE_11B && phy->phy_rev >= 2 && + rf->rf_type == BWI_RF_T_BCM2050) { + RF_SETBITS(mac, 0x76, 0x84); + } else { + struct bwi_tpctl tpctl; + + /* Backup original TX power control variables */ + bcopy(&mac->mac_tpctl, &tpctl_orig, sizeof(tpctl_orig)); + restore_tpctl = 1; + + bcopy(&mac->mac_tpctl, &tpctl, sizeof(tpctl)); + tpctl.bbp_atten = 11; + tpctl.tp_ctrl1 = 0; +#ifdef notyet + if (rf->rf_rev >= 6 && rf->rf_rev <= 8) + tpctl.rf_atten = 31; + else +#endif + tpctl.rf_atten = 9; + + bwi_mac_set_tpctl_11bg(mac, &tpctl); + } + + bwi_mac_dummy_xmit(mac); + + mac->mac_flags |= BWI_MAC_F_TPCTL_INITED; + rf->rf_base_tssi = PHY_READ(mac, 0x29); + DPRINTF(sc, "base tssi %d\n", rf->rf_base_tssi); + + if (abs(rf->rf_base_tssi - rf->rf_idle_tssi) >= 20) { + device_printf(sc->sc_dev, "base tssi measure failed\n"); + mac->mac_flags |= BWI_MAC_F_TPCTL_ERROR; + } + + if (restore_tpctl) + bwi_mac_set_tpctl_11bg(mac, &tpctl_orig); + else + RF_CLRBITS(mac, 0x76, 0x84); + + bwi_rf_clear_tssi(mac); +} + +void +bwi_mac_detach(struct bwi_mac *mac) +{ + bwi_mac_fw_free(mac); +} + +static __inline int +bwi_fwimage_is_valid(struct bwi_softc *sc, const struct firmware *fw, + uint8_t fw_type) +{ + const struct bwi_fwhdr *hdr; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + + if (fw->datasize < sizeof(*hdr)) { + if_printf(ifp, "invalid firmware (%s): invalid size %zu\n", + fw->name, fw->datasize); + return 0; + } + + hdr = (const struct bwi_fwhdr *)fw->data; + + if (fw_type != BWI_FW_T_IV) { + /* + * Don't verify IV's size, it has different meaning + */ + if (be32toh(hdr->fw_size) != fw->datasize - sizeof(*hdr)) { + if_printf(ifp, "invalid firmware (%s): size mismatch, " + "fw %u, real %zu\n", fw->name, + be32toh(hdr->fw_size), + fw->datasize - sizeof(*hdr)); + return 0; + } + } + + if (hdr->fw_type != fw_type) { + if_printf(ifp, "invalid firmware (%s): type mismatch, " + "fw \'%c\', target \'%c\'\n", fw->name, + hdr->fw_type, fw_type); + return 0; + } + + if (hdr->fw_gen != BWI_FW_GEN_1) { + if_printf(ifp, "invalid firmware (%s): wrong generation, " + "fw %d, target %d\n", fw->name, + hdr->fw_gen, BWI_FW_GEN_1); + return 0; + } + return 1; +} + +/* + * XXX Error cleanup + */ +static int +bwi_mac_fw_alloc(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + char fwname[64]; + int idx; + + if (mac->mac_ucode == NULL) { + snprintf(fwname, sizeof(fwname), BWI_FW_UCODE_PATH, + sc->sc_fw_version, + mac->mac_rev >= 5 ? 5 : mac->mac_rev); + + mac->mac_ucode = firmware_get(fwname); + if (mac->mac_ucode == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + + if (!bwi_fwimage_is_valid(sc, mac->mac_ucode, BWI_FW_T_UCODE)) + return EINVAL; + } + + if (mac->mac_pcm == NULL) { + snprintf(fwname, sizeof(fwname), BWI_FW_PCM_PATH, + sc->sc_fw_version, + mac->mac_rev < 5 ? 4 : 5); + + mac->mac_pcm = firmware_get(fwname); + if (mac->mac_pcm == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + + if (!bwi_fwimage_is_valid(sc, mac->mac_pcm, BWI_FW_T_PCM)) + return EINVAL; + } + + if (mac->mac_iv == NULL) { + /* TODO: 11A */ + if (mac->mac_rev == 2 || mac->mac_rev == 4) { + idx = 2; + } else if (mac->mac_rev >= 5 && mac->mac_rev <= 10) { + idx = 5; + } else { + if_printf(ifp, "no suitible IV for MAC rev %d\n", + mac->mac_rev); + return ENODEV; + } + + snprintf(fwname, sizeof(fwname), BWI_FW_IV_PATH, + sc->sc_fw_version, idx); + + mac->mac_iv = firmware_get(fwname); + if (mac->mac_iv == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + if (!bwi_fwimage_is_valid(sc, mac->mac_iv, BWI_FW_T_IV)) + return EINVAL; + } + + if (mac->mac_iv_ext == NULL) { + /* TODO: 11A */ + if (mac->mac_rev == 2 || mac->mac_rev == 4 || + mac->mac_rev >= 11) { + /* No extended IV */ + goto back; + } else if (mac->mac_rev >= 5 && mac->mac_rev <= 10) { + idx = 5; + } else { + if_printf(ifp, "no suitible ExtIV for MAC rev %d\n", + mac->mac_rev); + return ENODEV; + } + + snprintf(fwname, sizeof(fwname), BWI_FW_IV_EXT_PATH, + sc->sc_fw_version, idx); + + mac->mac_iv_ext = firmware_get(fwname); + if (mac->mac_iv_ext == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + if (!bwi_fwimage_is_valid(sc, mac->mac_iv_ext, BWI_FW_T_IV)) + return EINVAL; + } +back: + return 0; +} + +static void +bwi_mac_fw_free(struct bwi_mac *mac) +{ + if (mac->mac_ucode != NULL) { + firmware_put(mac->mac_ucode, FIRMWARE_UNLOAD); + mac->mac_ucode = NULL; + } + + if (mac->mac_pcm != NULL) { + firmware_put(mac->mac_pcm, FIRMWARE_UNLOAD); + mac->mac_pcm = NULL; + } + + if (mac->mac_iv != NULL) { + firmware_put(mac->mac_iv, FIRMWARE_UNLOAD); + mac->mac_iv = NULL; + } + + if (mac->mac_iv_ext != NULL) { + firmware_put(mac->mac_iv_ext, FIRMWARE_UNLOAD); + mac->mac_iv_ext = NULL; + } +} + +static int +bwi_mac_fw_load(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + const uint32_t *fw; + uint16_t fw_rev; + int fw_len, i; + + /* + * Load ucode image + */ + fw = (const uint32_t *) + ((const uint8_t *)mac->mac_ucode->data + BWI_FWHDR_SZ); + fw_len = (mac->mac_ucode->datasize - BWI_FWHDR_SZ) / sizeof(uint32_t); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL( + BWI_FW_UCODE_MOBJ | BWI_WR_MOBJ_AUTOINC, 0)); + for (i = 0; i < fw_len; ++i) { + CSR_WRITE_4(sc, BWI_MOBJ_DATA, be32toh(fw[i])); + DELAY(10); + } + + /* + * Load PCM image + */ + fw = (const uint32_t *) + ((const uint8_t *)mac->mac_pcm->data + BWI_FWHDR_SZ); + fw_len = (mac->mac_pcm->datasize - BWI_FWHDR_SZ) / sizeof(uint32_t); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(BWI_FW_PCM_MOBJ, 0x01ea)); + CSR_WRITE_4(sc, BWI_MOBJ_DATA, 0x4000); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(BWI_FW_PCM_MOBJ, 0x01eb)); + for (i = 0; i < fw_len; ++i) { + CSR_WRITE_4(sc, BWI_MOBJ_DATA, be32toh(fw[i])); + DELAY(10); + } + + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, BWI_ALL_INTRS); + CSR_WRITE_4(sc, BWI_MAC_STATUS, + BWI_MAC_STATUS_UCODE_START | + BWI_MAC_STATUS_IHREN | + BWI_MAC_STATUS_INFRA); + +#define NRETRY 200 + + for (i = 0; i < NRETRY; ++i) { + uint32_t intr_status; + + intr_status = CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + if (intr_status == BWI_INTR_READY) + break; + DELAY(10); + } + if (i == NRETRY) { + if_printf(ifp, "firmware (ucode&pcm) loading timed out\n"); + return ETIMEDOUT; + } + +#undef NRETRY + + CSR_READ_4(sc, BWI_MAC_INTR_STATUS); /* dummy read */ + + fw_rev = MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_FWREV); + if (fw_rev > BWI_FW_VERSION3_REVMAX) { + if_printf(ifp, "firmware version 4 is not supported yet\n"); + return ENODEV; + } + + if_printf(ifp, "firmware rev 0x%04x, patch level 0x%04x\n", fw_rev, + MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_FWPATCHLV)); + return 0; +} + +static int +bwi_mac_gpio_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_regwin *old, *gpio_rw; + uint32_t filt, bits; + int error; + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_GPOSEL_MASK); + /* TODO:LED */ + + CSR_SETBITS_2(sc, BWI_MAC_GPIO_MASK, 0xf); + + filt = 0x1f; + bits = 0xf; + if (sc->sc_bbp_id == BWI_BBPID_BCM4301) { + filt |= 0x60; + bits |= 0x60; + } + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) { + CSR_SETBITS_2(sc, BWI_MAC_GPIO_MASK, 0x200); + filt |= 0x200; + bits |= 0x200; + } + + gpio_rw = BWI_GPIO_REGWIN(sc); + error = bwi_regwin_switch(sc, gpio_rw, &old); + if (error) + return error; + + CSR_FILT_SETBITS_4(sc, BWI_GPIO_CTRL, filt, bits); + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_mac_gpio_fini(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_regwin *old, *gpio_rw; + int error; + + gpio_rw = BWI_GPIO_REGWIN(sc); + error = bwi_regwin_switch(sc, gpio_rw, &old); + if (error) + return error; + + CSR_WRITE_4(sc, BWI_GPIO_CTRL, 0); + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_mac_fw_load_iv(struct bwi_mac *mac, const struct firmware *fw) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + const struct bwi_fwhdr *hdr; + const struct bwi_fw_iv *iv; + int n, i, iv_img_size; + + /* Get the number of IVs in the IV image */ + hdr = (const struct bwi_fwhdr *)fw->data; + n = be32toh(hdr->fw_iv_cnt); + DPRINTF(sc, "IV count %d\n", n); + + /* Calculate the IV image size, for later sanity check */ + iv_img_size = fw->datasize - sizeof(*hdr); + + /* Locate the first IV */ + iv = (const struct bwi_fw_iv *) + ((const uint8_t *)fw->data + sizeof(*hdr)); + + for (i = 0; i < n; ++i) { + uint16_t iv_ofs, ofs; + int sz = 0; + + if (iv_img_size < sizeof(iv->iv_ofs)) { + if_printf(ifp, "invalid IV image, ofs\n"); + return EINVAL; + } + iv_img_size -= sizeof(iv->iv_ofs); + sz += sizeof(iv->iv_ofs); + + iv_ofs = be16toh(iv->iv_ofs); + + ofs = __SHIFTOUT(iv_ofs, BWI_FW_IV_OFS_MASK); + if (ofs >= 0x1000) { + if_printf(ifp, "invalid ofs (0x%04x) " + "for %dth iv\n", ofs, i); + return EINVAL; + } + + if (iv_ofs & BWI_FW_IV_IS_32BIT) { + uint32_t val32; + + if (iv_img_size < sizeof(iv->iv_val.val32)) { + if_printf(ifp, "invalid IV image, val32\n"); + return EINVAL; + } + iv_img_size -= sizeof(iv->iv_val.val32); + sz += sizeof(iv->iv_val.val32); + + val32 = be32toh(iv->iv_val.val32); + CSR_WRITE_4(sc, ofs, val32); + } else { + uint16_t val16; + + if (iv_img_size < sizeof(iv->iv_val.val16)) { + if_printf(ifp, "invalid IV image, val16\n"); + return EINVAL; + } + iv_img_size -= sizeof(iv->iv_val.val16); + sz += sizeof(iv->iv_val.val16); + + val16 = be16toh(iv->iv_val.val16); + CSR_WRITE_2(sc, ofs, val16); + } + + iv = (const struct bwi_fw_iv *)((const uint8_t *)iv + sz); + } + + if (iv_img_size != 0) { + if_printf(ifp, "invalid IV image, size left %d\n", iv_img_size); + return EINVAL; + } + return 0; +} + +static int +bwi_mac_fw_init(struct bwi_mac *mac) +{ + struct ifnet *ifp = mac->mac_sc->sc_ic.ic_ifp; + int error; + + error = bwi_mac_fw_load_iv(mac, mac->mac_iv); + if (error) { + if_printf(ifp, "load IV failed\n"); + return error; + } + + if (mac->mac_iv_ext != NULL) { + error = bwi_mac_fw_load_iv(mac, mac->mac_iv_ext); + if (error) + if_printf(ifp, "load ExtIV failed\n"); + } + return error; +} + +static void +bwi_mac_opmode_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ieee80211com *ic = &sc->sc_ic; + uint32_t mac_status; + uint16_t pre_tbtt; + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_INFRA); + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_INFRA); + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_PASS_BCN); + + /* Set probe resp timeout to infinite */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_PROBE_RESP_TO, 0); + + /* + * TODO: factor out following part + */ + + mac_status = CSR_READ_4(sc, BWI_MAC_STATUS); + mac_status &= ~(BWI_MAC_STATUS_OPMODE_HOSTAP | + BWI_MAC_STATUS_PASS_CTL | + BWI_MAC_STATUS_PASS_BADPLCP | + BWI_MAC_STATUS_PASS_BADFCS | + BWI_MAC_STATUS_PROMISC); + mac_status |= BWI_MAC_STATUS_INFRA; + + /* Always turn on PROMISC on old hardware */ + if (mac->mac_rev < 5) + mac_status |= BWI_MAC_STATUS_PROMISC; + + switch (ic->ic_opmode) { + case IEEE80211_M_IBSS: + mac_status &= ~BWI_MAC_STATUS_INFRA; + break; + case IEEE80211_M_HOSTAP: + mac_status |= BWI_MAC_STATUS_OPMODE_HOSTAP; + break; + case IEEE80211_M_MONITOR: +#if 0 + /* Do you want data from your microwave oven? */ + mac_status |= BWI_MAC_STATUS_PASS_CTL | + BWI_MAC_STATUS_PASS_BADPLCP | + BWI_MAC_STATUS_PASS_BADFCS; +#else + mac_status |= BWI_MAC_STATUS_PASS_CTL; +#endif + /* Promisc? */ + break; + default: + break; + } + + if (ic->ic_ifp->if_flags & IFF_PROMISC) + mac_status |= BWI_MAC_STATUS_PROMISC; + + CSR_WRITE_4(sc, BWI_MAC_STATUS, mac_status); + + if (ic->ic_opmode != IEEE80211_M_IBSS && + ic->ic_opmode != IEEE80211_M_HOSTAP) { + if (sc->sc_bbp_id == BWI_BBPID_BCM4306 && sc->sc_bbp_rev == 3) + pre_tbtt = 100; + else + pre_tbtt = 50; + } else { + pre_tbtt = 2; + } + CSR_WRITE_2(sc, BWI_MAC_PRE_TBTT, pre_tbtt); +} + +static void +bwi_mac_hostflags_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint64_t host_flags; + + if (phy->phy_mode == IEEE80211_MODE_11A) + return; + + host_flags = HFLAGS_READ(mac); + host_flags |= BWI_HFLAG_SYM_WA; + + if (phy->phy_mode == IEEE80211_MODE_11G) { + if (phy->phy_rev == 1) + host_flags |= BWI_HFLAG_GDC_WA; + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) + host_flags |= BWI_HFLAG_OFDM_PA; + } else if (phy->phy_mode == IEEE80211_MODE_11B) { + if (phy->phy_rev >= 2 && rf->rf_type == BWI_RF_T_BCM2050) + host_flags &= ~BWI_HFLAG_GDC_WA; + } else { + panic("unknown PHY mode %u\n", phy->phy_mode); + } + + HFLAGS_WRITE(mac, host_flags); +} + +static void +bwi_mac_bss_param_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_retry_lim lim; + uint16_t cw_min; + + /* + * Set short/long retry limits + */ + bzero(&lim, sizeof(lim)); + lim.shretry = BWI_SHRETRY; + lim.shretry_fb = BWI_SHRETRY_FB; + lim.lgretry = BWI_LGRETRY; + lim.lgretry_fb = BWI_LGRETRY_FB; + bwi_mac_set_retry_lim(mac, &lim); + + /* + * Implicitly prevent firmware from sending probe response + * by setting its "probe response timeout" to 1us. + */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_PROBE_RESP_TO, 1); + + /* + * XXX MAC level acknowledge and CW min/max should depend + * on the char rateset of the IBSS/BSS to join. + */ + + /* + * Set MAC level acknowledge rates + */ + bwi_mac_set_ackrates(mac, &sc->sc_ic.ic_sup_rates[phy->phy_mode]); + + /* + * Set CW min + */ + if (phy->phy_mode == IEEE80211_MODE_11B) + cw_min = IEEE80211_CW_MIN_0; + else + cw_min = IEEE80211_CW_MIN_1; + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_CWMIN, cw_min); + + /* + * Set CW max + */ + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_CWMAX, + IEEE80211_CW_MAX); +} + +static void +bwi_mac_set_retry_lim(struct bwi_mac *mac, const struct bwi_retry_lim *lim) +{ + /* Short/Long retry limit */ + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_SHRETRY, + lim->shretry); + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_LGRETRY, + lim->lgretry); + + /* Short/Long retry fallback limit */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_SHRETRY_FB, + lim->shretry_fb); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_LGRETEY_FB, + lim->lgretry_fb); +} + +static void +bwi_mac_set_ackrates(struct bwi_mac *mac, const struct ieee80211_rateset *rs) +{ + int i; + + /* XXX not standard conforming */ + for (i = 0; i < rs->rs_nrates; ++i) { + enum ieee80211_modtype modtype; + uint16_t ofs; + + modtype = ieee80211_rate2modtype(rs->rs_rates[i]); + switch (modtype) { + case IEEE80211_MODTYPE_DS: + ofs = 0x4c0; + break; + case IEEE80211_MODTYPE_OFDM: + ofs = 0x480; + break; + default: + panic("unsupported modtype %u\n", modtype); + } + ofs += (bwi_rate2plcp(rs->rs_rates[i]) & 0xf) * 2; + + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, ofs + 0x20, + MOBJ_READ_2(mac, BWI_COMM_MOBJ, ofs)); + } +} + +int +bwi_mac_start(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_ENABLE); + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, BWI_INTR_READY); + + /* Flush pending bus writes */ + CSR_READ_4(sc, BWI_MAC_STATUS); + CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + + return bwi_mac_config_ps(mac); +} + +int +bwi_mac_stop(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + int error, i; + + error = bwi_mac_config_ps(mac); + if (error) + return error; + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_ENABLE); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_MAC_STATUS); + +#define NRETRY 10000 + for (i = 0; i < NRETRY; ++i) { + if (CSR_READ_4(sc, BWI_MAC_INTR_STATUS) & BWI_INTR_READY) + break; + DELAY(1); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "can't stop MAC\n"); + return ETIMEDOUT; + } +#undef NRETRY + + return 0; +} + +int +bwi_mac_config_ps(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t status; + + status = CSR_READ_4(sc, BWI_MAC_STATUS); + + status &= ~BWI_MAC_STATUS_HW_PS; + status |= BWI_MAC_STATUS_WAKEUP; + CSR_WRITE_4(sc, BWI_MAC_STATUS, status); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_MAC_STATUS); + + if (mac->mac_rev >= 5) { + int i; + +#define NRETRY 100 + for (i = 0; i < NRETRY; ++i) { + if (MOBJ_READ_2(mac, BWI_COMM_MOBJ, + BWI_COMM_MOBJ_UCODE_STATE) != BWI_UCODE_STATE_PS) + break; + DELAY(10); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "config PS failed\n"); + return ETIMEDOUT; + } +#undef NRETRY + } + return 0; +} + +void +bwi_mac_reset_hwkeys(struct bwi_mac *mac) +{ + /* TODO: firmware crypto */ + MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_KEYTABLE_OFS); +} + +void +bwi_mac_shutdown(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + int i; + + if (mac->mac_flags & BWI_MAC_F_HAS_TXSTATS) + sc->sc_free_txstats(sc); + + sc->sc_free_rx_ring(sc); + + for (i = 0; i < BWI_TX_NRING; ++i) + sc->sc_free_tx_ring(sc, i); + + bwi_rf_off(mac); + + /* TODO:LED */ + + bwi_mac_gpio_fini(mac); + + bwi_rf_off(mac); /* XXX again */ + CSR_WRITE_2(sc, BWI_BBP_ATTEN, BWI_BBP_ATTEN_MAGIC); + bwi_regwin_disable(sc, &mac->mac_regwin, 0); + + mac->mac_flags &= ~BWI_MAC_F_INITED; +} + +static int +bwi_mac_get_property(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + enum bwi_bus_space old_bus_space; + uint32_t val; + + /* + * Byte swap + */ + val = CSR_READ_4(sc, BWI_MAC_STATUS); + if (val & BWI_MAC_STATUS_BSWAP) { + DPRINTF(sc, "%s\n", "need byte swap"); + mac->mac_flags |= BWI_MAC_F_BSWAP; + } + + /* + * DMA address space + */ + old_bus_space = sc->sc_bus_space; + + val = CSR_READ_4(sc, BWI_STATE_HI); + if (__SHIFTOUT(val, BWI_STATE_HI_FLAGS_MASK) & + BWI_STATE_HI_FLAG_64BIT) { + /* 64bit address */ + sc->sc_bus_space = BWI_BUS_SPACE_64BIT; + DPRINTF(sc, "%s\n", "64bit bus space"); + } else { + uint32_t txrx_reg = BWI_TXRX_CTRL_BASE + BWI_TX32_CTRL; + + CSR_WRITE_4(sc, txrx_reg, BWI_TXRX32_CTRL_ADDRHI_MASK); + if (CSR_READ_4(sc, txrx_reg) & BWI_TXRX32_CTRL_ADDRHI_MASK) { + /* 32bit address */ + sc->sc_bus_space = BWI_BUS_SPACE_32BIT; + DPRINTF(sc, "%s\n", "32bit bus space"); + } else { + /* 30bit address */ + sc->sc_bus_space = BWI_BUS_SPACE_30BIT; + DPRINTF(sc, "%s\n", "30bit bus space"); + } + } + + if (old_bus_space != 0 && old_bus_space != sc->sc_bus_space) { + device_printf(sc->sc_dev, "MACs bus space mismatch!\n"); + return ENXIO; + } + return 0; +} + +void +bwi_mac_updateslot(struct bwi_mac *mac, int shslot) +{ + uint16_t slot_time; + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11B) + return; + + if (shslot) + slot_time = IEEE80211_DUR_SHSLOT; + else + slot_time = IEEE80211_DUR_SLOT; + + CSR_WRITE_2(mac->mac_sc, BWI_MAC_SLOTTIME, + slot_time + BWI_MAC_SLOTTIME_ADJUST); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_SLOTTIME, slot_time); +} + +int +bwi_mac_attach(struct bwi_softc *sc, int id, uint8_t rev) +{ + struct bwi_mac *mac; + int i; + + KASSERT(sc->sc_nmac <= BWI_MAC_MAX && sc->sc_nmac >= 0, + ("sc_nmac %d", sc->sc_nmac)); + + if (sc->sc_nmac == BWI_MAC_MAX) { + device_printf(sc->sc_dev, "too many MACs\n"); + return 0; + } + + /* + * More than one MAC is only supported by BCM4309 + */ + if (sc->sc_nmac != 0 && + sc->sc_pci_did != PCI_PRODUCT_BROADCOM_BCM4309) { + DPRINTF(sc, "%s\n", "ignore second MAC"); + return 0; + } + + mac = &sc->sc_mac[sc->sc_nmac]; + + /* XXX will this happen? */ + if (BWI_REGWIN_EXIST(&mac->mac_regwin)) { + device_printf(sc->sc_dev, "%dth MAC already attached\n", + sc->sc_nmac); + return 0; + } + + /* + * Test whether the revision of this MAC is supported + */ +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + for (i = 0; i < N(bwi_sup_macrev); ++i) { + if (bwi_sup_macrev[i] == rev) + break; + } + if (i == N(bwi_sup_macrev)) { + device_printf(sc->sc_dev, "MAC rev %u is " + "not supported\n", rev); + return ENXIO; + } +#undef N + + BWI_CREATE_MAC(mac, sc, id, rev); + sc->sc_nmac++; + + if (mac->mac_rev < 5) { + mac->mac_flags |= BWI_MAC_F_HAS_TXSTATS; + DPRINTF(sc, "%s\n", "has TX stats"); + } + + device_printf(sc->sc_dev, "MAC: rev %u\n", rev); + return 0; +} + +static __inline void +bwi_mac_balance_atten(int *bbp_atten0, int *rf_atten0) +{ + int bbp_atten, rf_atten, rf_atten_lim = -1; + + bbp_atten = *bbp_atten0; + rf_atten = *rf_atten0; + + /* + * RF attenuation affects TX power BWI_RF_ATTEN_FACTOR times + * as much as BBP attenuation, so we try our best to keep RF + * attenuation within range. BBP attenuation will be clamped + * later if it is out of range during balancing. + * + * BWI_RF_ATTEN_MAX0 is used as RF attenuation upper limit. + */ + + /* + * Use BBP attenuation to balance RF attenuation + */ + if (rf_atten < 0) + rf_atten_lim = 0; + else if (rf_atten > BWI_RF_ATTEN_MAX0) + rf_atten_lim = BWI_RF_ATTEN_MAX0; + + if (rf_atten_lim >= 0) { + bbp_atten += (BWI_RF_ATTEN_FACTOR * (rf_atten - rf_atten_lim)); + rf_atten = rf_atten_lim; + } + + /* + * If possible, use RF attenuation to balance BBP attenuation + * NOTE: RF attenuation is still kept within range. + */ + while (rf_atten < BWI_RF_ATTEN_MAX0 && bbp_atten > BWI_BBP_ATTEN_MAX) { + bbp_atten -= BWI_RF_ATTEN_FACTOR; + ++rf_atten; + } + while (rf_atten > 0 && bbp_atten < 0) { + bbp_atten += BWI_RF_ATTEN_FACTOR; + --rf_atten; + } + + /* RF attenuation MUST be within range */ + KASSERT(rf_atten >= 0 && rf_atten <= BWI_RF_ATTEN_MAX0, + ("rf_atten %d", rf_atten)); + + /* + * Clamp BBP attenuation + */ + if (bbp_atten < 0) + bbp_atten = 0; + else if (bbp_atten > BWI_BBP_ATTEN_MAX) + bbp_atten = BWI_BBP_ATTEN_MAX; + + *rf_atten0 = rf_atten; + *bbp_atten0 = bbp_atten; +} + +static void +bwi_mac_adjust_tpctl(struct bwi_mac *mac, int rf_atten_adj, int bbp_atten_adj) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_tpctl tpctl; + int bbp_atten, rf_atten, tp_ctrl1; + + bcopy(&mac->mac_tpctl, &tpctl, sizeof(tpctl)); + + /* NOTE: Use signed value to do calulation */ + bbp_atten = tpctl.bbp_atten; + rf_atten = tpctl.rf_atten; + tp_ctrl1 = tpctl.tp_ctrl1; + + bbp_atten += bbp_atten_adj; + rf_atten += rf_atten_adj; + + bwi_mac_balance_atten(&bbp_atten, &rf_atten); + + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev == 2) { + if (rf_atten <= 1) { + if (tp_ctrl1 == 0) { + tp_ctrl1 = 3; + bbp_atten += 2; + rf_atten += 2; + } else if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) { + bbp_atten += + (BWI_RF_ATTEN_FACTOR * (rf_atten - 2)); + rf_atten = 2; + } + } else if (rf_atten > 4 && tp_ctrl1 != 0) { + tp_ctrl1 = 0; + if (bbp_atten < 3) { + bbp_atten += 2; + rf_atten -= 3; + } else { + bbp_atten -= 2; + rf_atten -= 2; + } + } + bwi_mac_balance_atten(&bbp_atten, &rf_atten); + } + + tpctl.bbp_atten = bbp_atten; + tpctl.rf_atten = rf_atten; + tpctl.tp_ctrl1 = tp_ctrl1; + + bwi_mac_lock(mac); + bwi_mac_set_tpctl_11bg(mac, &tpctl); + bwi_mac_unlock(mac); +} + +/* + * http://bcm-specs.sipsolutions.net/RecalculateTransmissionPower + */ +void +bwi_mac_calibrate_txpower(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + int8_t tssi[4], tssi_avg, cur_txpwr; + int error, i, ofdm_tssi; + int txpwr_diff, rf_atten_adj, bbp_atten_adj; + + if (mac->mac_flags & BWI_MAC_F_TPCTL_ERROR) { + DPRINTF(sc, "%s\n", "tpctl error happened, can't set txpower"); + return; + } + + if (BWI_IS_BRCM_BU4306(sc)) { + DPRINTF(sc, "%s\n", "BU4306, can't set txpower"); + return; + } + + /* + * Save latest TSSI and reset the related memory objects + */ + ofdm_tssi = 0; + error = bwi_rf_get_latest_tssi(mac, tssi, BWI_COMM_MOBJ_TSSI_DS); + if (error) { + DPRINTF(sc, "%s\n", "no DS tssi"); + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11B) + return; + + error = bwi_rf_get_latest_tssi(mac, tssi, + BWI_COMM_MOBJ_TSSI_OFDM); + if (error) { + DPRINTF(sc, "%s\n", "no OFDM tssi"); + return; + } + + for (i = 0; i < 4; ++i) { + tssi[i] += 0x20; + tssi[i] &= 0x3f; + } + ofdm_tssi = 1; + } + bwi_rf_clear_tssi(mac); + + DPRINTF(sc, "tssi0 %d, tssi1 %d, tssi2 %d, tssi3 %d\n", + tssi[0], tssi[1], tssi[2], tssi[3]); + + /* + * Calculate RF/BBP attenuation adjustment based on + * the difference between desired TX power and sampled + * TX power. + */ + /* +8 == "each incremented by 1/2" */ + tssi_avg = (tssi[0] + tssi[1] + tssi[2] + tssi[3] + 8) / 4; + if (ofdm_tssi && (HFLAGS_READ(mac) & BWI_HFLAG_PWR_BOOST_DS)) + tssi_avg -= 13; + + DPRINTF(sc, "tssi avg %d\n", tssi_avg); + + error = bwi_rf_tssi2dbm(mac, tssi_avg, &cur_txpwr); + if (error) + return; + DPRINTF(sc, "current txpower %d\n", cur_txpwr); + + txpwr_diff = rf->rf_txpower_max - cur_txpwr; /* XXX ni_txpower */ + + rf_atten_adj = -howmany(txpwr_diff, 8); + bbp_atten_adj = -(txpwr_diff / 2) - + (BWI_RF_ATTEN_FACTOR * rf_atten_adj); + + if (rf_atten_adj == 0 && bbp_atten_adj == 0) { + DPRINTF(sc, "%s\n", "no need to adjust RF/BBP attenuation"); + /* TODO: LO */ + return; + } + + DPRINTF(sc, "rf atten adjust %d, bbp atten adjust %d\n", + rf_atten_adj, bbp_atten_adj); + bwi_mac_adjust_tpctl(mac, rf_atten_adj, bbp_atten_adj); + /* TODO: LO */ +} + +static void +bwi_mac_lock(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ieee80211com *ic = &sc->sc_ic; + + KASSERT((mac->mac_flags & BWI_MAC_F_LOCKED) == 0, + ("mac_flags 0x%x", mac->mac_flags)); + + if (mac->mac_rev < 3) + bwi_mac_stop(mac); + else if (ic->ic_opmode != IEEE80211_M_HOSTAP) + bwi_mac_config_ps(mac); + + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_RFLOCK); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_MAC_STATUS); + DELAY(10); + + mac->mac_flags |= BWI_MAC_F_LOCKED; +} + +static void +bwi_mac_unlock(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ieee80211com *ic = &sc->sc_ic; + + KASSERT(mac->mac_flags & BWI_MAC_F_LOCKED, + ("mac_flags 0x%x", mac->mac_flags)); + + CSR_READ_2(sc, BWI_PHYINFO); /* dummy read */ + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_RFLOCK); + + if (mac->mac_rev < 3) + bwi_mac_start(mac); + else if (ic->ic_opmode != IEEE80211_M_HOSTAP) + bwi_mac_config_ps(mac); + + mac->mac_flags &= ~BWI_MAC_F_LOCKED; +} + +void +bwi_mac_set_promisc(struct bwi_mac *mac, int promisc) +{ + struct bwi_softc *sc = mac->mac_sc; + + if (mac->mac_rev < 5) /* Promisc is always on */ + return; + + if (promisc) + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_PROMISC); + else + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_PROMISC); +} --- /dev/null +++ sys/dev/bwi/if_bwireg.h @@ -0,0 +1,503 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/if_bwireg.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/if_bwireg.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _IF_BWIREG_H +#define _IF_BWIREG_H + +/* + * Registers for all of the register windows + */ +#define BWI_FLAGS 0xf18 +#define BWI_FLAGS_INTR_MASK __BITS(5, 0) + +#define BWI_IMSTATE 0xf90 +#define BWI_IMSTATE_INBAND_ERR __BIT(17) +#define BWI_IMSTATE_TIMEOUT __BIT(18) + +#define BWI_INTRVEC 0xf94 + +#define BWI_STATE_LO 0xf98 +#define BWI_STATE_LO_RESET __BIT(0) +#define BWI_STATE_LO_DISABLE1 __BIT(1) +#define BWI_STATE_LO_DISABLE2 __BIT(2) +#define BWI_STATE_LO_CLOCK __BIT(16) +#define BWI_STATE_LO_GATED_CLOCK __BIT(17) +#define BWI_STATE_LO_FLAG_PHYCLKEN __BIT(0) +#define BWI_STATE_LO_FLAG_PHYRST __BIT(1) +#define BWI_STATE_LO_FLAG_PHYLNK __BIT(11) +#define BWI_STATE_LO_FLAGS_MASK __BITS(29, 18) + +#define BWI_STATE_HI 0xf9c +#define BWI_STATE_HI_SERROR __BIT(0) +#define BWI_STATE_HI_BUSY __BIT(2) +#define BWI_STATE_HI_FLAG_MAGIC1 0x1 +#define BWI_STATE_HI_FLAG_MAGIC2 0x2 +#define BWI_STATE_HI_FLAG_64BIT 0x1000 +#define BWI_STATE_HI_FLAGS_MASK __BITS(28, 16) + +#define BWI_CONF_LO 0xfa8 +#define BWI_CONF_LO_SERVTO_MASK __BITS(2, 0) /* service timeout */ +#define BWI_CONF_LO_SERVTO 2 +#define BWI_CONF_LO_REQTO_MASK __BITS(6, 4) /* request timeout */ +#define BWI_CONF_LO_REQTO 3 + + +#define BWI_ID_LO 0xff8 +#define BWI_ID_LO_BUSREV_MASK __BITS(31, 28) +/* Bus revision */ +#define BWI_BUSREV_0 0 +#define BWI_BUSREV_1 1 + +#define BWI_ID_HI 0xffc +#define BWI_ID_HI_REGWIN_REV(v) (((v) & 0xf) | (((v) & 0x7000) >> 8)) +#define BWI_ID_HI_REGWIN_TYPE(v) (((v) & 0x8ff0) >> 4) +#define BWI_ID_HI_REGWIN_VENDOR_MASK __BITS(31, 16) + +/* + * Registers for common register window + */ +#define BWI_INFO 0x0 +#define BWI_INFO_BBPID_MASK __BITS(15, 0) +#define BWI_INFO_BBPREV_MASK __BITS(19, 16) +#define BWI_INFO_BBPPKG_MASK __BITS(23, 20) +#define BWI_INFO_NREGWIN_MASK __BITS(27, 24) + +#define BWI_CAPABILITY 0x4 +#define BWI_CAP_CLKMODE __BIT(18) + +#define BWI_CONTROL 0x28 +#define BWI_CONTROL_MAGIC0 0x3a4 +#define BWI_CONTROL_MAGIC1 0xa4 +#define BWI_PLL_ON_DELAY 0xb0 +#define BWI_FREQ_SEL_DELAY 0xb4 + +#define BWI_CLOCK_CTRL 0xb8 +#define BWI_CLOCK_CTRL_CLKSRC __BITS(2, 0) +#define BWI_CLOCK_CTRL_SLOW __BIT(11) +#define BWI_CLOCK_CTRL_IGNPLL __BIT(12) +#define BWI_CLOCK_CTRL_NODYN __BIT(13) +#define BWI_CLOCK_CTRL_FDIV __BITS(31, 16) /* freq divisor */ + +/* Possible values for BWI_CLOCK_CTRL_CLKSRC */ +#define BWI_CLKSRC_LP_OSC 0 /* Low power oscillator */ +#define BWI_CLKSRC_CS_OSC 1 /* Crystal oscillator */ +#define BWI_CLKSRC_PCI 2 +#define BWI_CLKSRC_MAX 3 /* Maximum of clock source */ +/* Min/Max frequency for given clock source */ +#define BWI_CLKSRC_LP_OSC_FMIN 25000 +#define BWI_CLKSRC_LP_OSC_FMAX 43000 +#define BWI_CLKSRC_CS_OSC_FMIN 19800000 +#define BWI_CLKSRC_CS_OSC_FMAX 20200000 +#define BWI_CLKSRC_PCI_FMIN 25000000 +#define BWI_CLKSRC_PCI_FMAX 34000000 + +#define BWI_CLOCK_INFO 0xc0 +#define BWI_CLOCK_INFO_FDIV __BITS(31, 16) /* freq divisor */ + +/* + * Registers for bus register window + */ +#define BWI_BUS_ADDR 0x50 +#define BWI_BUS_ADDR_MAGIC 0xfd8 + +#define BWI_BUS_DATA 0x54 + +#define BWI_BUS_CONFIG 0x108 +#define BWI_BUS_CONFIG_PREFETCH __BIT(2) +#define BWI_BUS_CONFIG_BURST __BIT(3) +#define BWI_BUS_CONFIG_MRM __BIT(5) + +/* + * Register for MAC + */ +#define BWI_TXRX_INTR_STATUS_BASE 0x20 +#define BWI_TXRX_INTR_MASK_BASE 0x24 +#define BWI_TXRX_INTR_STATUS(i) (BWI_TXRX_INTR_STATUS_BASE + ((i) * 8)) +#define BWI_TXRX_INTR_MASK(i) (BWI_TXRX_INTR_MASK_BASE + ((i) * 8)) + +#define BWI_MAC_STATUS 0x120 +#define BWI_MAC_STATUS_ENABLE __BIT(0) +#define BWI_MAC_STATUS_UCODE_START __BIT(1) +#define BWI_MAC_STATUS_UCODE_JUMP0 __BIT(2) +#define BWI_MAC_STATUS_IHREN __BIT(10) +#define BWI_MAC_STATUS_GPOSEL_MASK __BITS(15, 14) +#define BWI_MAC_STATUS_BSWAP __BIT(16) +#define BWI_MAC_STATUS_INFRA __BIT(17) +#define BWI_MAC_STATUS_OPMODE_HOSTAP __BIT(18) +#define BWI_MAC_STATUS_RFLOCK __BIT(19) +#define BWI_MAC_STATUS_PASS_BCN __BIT(20) +#define BWI_MAC_STATUS_PASS_BADPLCP __BIT(21) +#define BWI_MAC_STATUS_PASS_CTL __BIT(22) +#define BWI_MAC_STATUS_PASS_BADFCS __BIT(23) +#define BWI_MAC_STATUS_PROMISC __BIT(24) +#define BWI_MAC_STATUS_HW_PS __BIT(25) +#define BWI_MAC_STATUS_WAKEUP __BIT(26) +#define BWI_MAC_STATUS_PHYLNK __BIT(31) + +#define BWI_MAC_INTR_STATUS 0x128 +#define BWI_MAC_INTR_MASK 0x12c + +#define BWI_MAC_TMPLT_CTRL 0x130 +#define BWI_MAC_TMPLT_DATA 0x134 + +#define BWI_MAC_PS_STATUS 0x140 + +#define BWI_MOBJ_CTRL 0x160 +#define BWI_MOBJ_CTRL_VAL(objid, ofs) ((objid) << 16 | (ofs)) +#define BWI_MOBJ_DATA 0x164 +#define BWI_MOBJ_DATA_UNALIGN 0x166 +/* + * Memory object IDs + */ +#define BWI_WR_MOBJ_AUTOINC 0x100 /* Auto-increment wr */ +#define BWI_RD_MOBJ_AUTOINC 0x200 /* Auto-increment rd */ +/* Firmware ucode object */ +#define BWI_FW_UCODE_MOBJ 0x0 +/* Common object */ +#define BWI_COMM_MOBJ 0x1 +#define BWI_COMM_MOBJ_FWREV 0x0 +#define BWI_COMM_MOBJ_FWPATCHLV 0x2 +#define BWI_COMM_MOBJ_SLOTTIME 0x10 +#define BWI_COMM_MOBJ_MACREV 0x16 +#define BWI_COMM_MOBJ_TX_ACK 0x22 +#define BWI_COMM_MOBJ_UCODE_STATE 0x40 +#define BWI_COMM_MOBJ_SHRETRY_FB 0x44 +#define BWI_COMM_MOBJ_LGRETEY_FB 0x46 +#define BWI_COMM_MOBJ_TX_BEACON 0x54 +#define BWI_COMM_MOBJ_KEYTABLE_OFS 0x56 +#define BWI_COMM_MOBJ_TSSI_DS 0x58 +#define BWI_COMM_MOBJ_HFLAGS_LO 0x5e +#define BWI_COMM_MOBJ_HFLAGS_MI 0x60 +#define BWI_COMM_MOBJ_HFLAGS_HI 0x62 +#define BWI_COMM_MOBJ_RF_ATTEN 0x64 +#define BWI_COMM_MOBJ_TSSI_OFDM 0x70 +#define BWI_COMM_MOBJ_PROBE_RESP_TO 0x74 +#define BWI_COMM_MOBJ_CHAN 0xa0 +#define BWI_COMM_MOBJ_KEY_ALGO 0x100 +#define BWI_COMM_MOBJ_TX_PROBE_RESP 0x188 +#define BWI_HFLAG_AUTO_ANTDIV 0x1ULL +#define BWI_HFLAG_SYM_WA 0x2ULL /* ??? SYM work around */ +#define BWI_HFLAG_PWR_BOOST_DS 0x8ULL +#define BWI_HFLAG_GDC_WA 0x20ULL /* ??? GDC work around */ +#define BWI_HFLAG_OFDM_PA 0x40ULL +#define BWI_HFLAG_NOT_JAPAN 0x80ULL +#define BWI_HFLAG_MAGIC1 0x200ULL +#define BWI_UCODE_STATE_PS 4 +#define BWI_LO_TSSI_MASK __BITS(7, 0) +#define BWI_HI_TSSI_MASK __BITS(15, 8) +#define BWI_INVALID_TSSI 0x7f +/* 802.11 object */ +#define BWI_80211_MOBJ 0x2 +#define BWI_80211_MOBJ_CWMIN 0xc +#define BWI_80211_MOBJ_CWMAX 0x10 +#define BWI_80211_MOBJ_SHRETRY 0x18 +#define BWI_80211_MOBJ_LGRETRY 0x1c +/* Firmware PCM object */ +#define BWI_FW_PCM_MOBJ 0x3 +/* MAC address of pairwise keys */ +#define BWI_PKEY_ADDR_MOBJ 0x4 + +#define BWI_TXSTATUS0 0x170 +#define BWI_TXSTATUS0_VALID __BIT(0) +#define BWI_TXSTATUS0_ACKED __BIT(1) +#define BWI_TXSTATUS0_FREASON_MASK __BITS(4, 2) /* Failure reason */ +#define BWI_TXSTATUS0_AMPDU __BIT(5) +#define BWI_TXSTATUS0_PENDING __BIT(6) +#define BWI_TXSTATUS0_PM __BIT(7) +#define BWI_TXSTATUS0_RTS_TXCNT_MASK __BITS(11, 8) +#define BWI_TXSTATUS0_DATA_TXCNT_MASK __BITS(15, 12) +#define BWI_TXSTATUS0_TXID_MASK __BITS(31, 16) +#define BWI_TXSTATUS1 0x174 + +#define BWI_TXRX_CTRL_BASE 0x200 +#define BWI_TX32_CTRL 0x0 +#define BWI_TX32_RINGINFO 0x4 +#define BWI_TX32_INDEX 0x8 +#define BWI_TX32_STATUS 0xc +#define BWI_TX32_STATUS_STATE_MASK __BITS(15, 12) +#define BWI_TX32_STATUS_STATE_DISABLED 0 +#define BWI_TX32_STATUS_STATE_IDLE 2 +#define BWI_TX32_STATUS_STATE_STOPPED 3 +#define BWI_RX32_CTRL 0x10 +#define BWI_RX32_CTRL_HDRSZ_MASK __BITS(7, 1) +#define BWI_RX32_RINGINFO 0x14 +#define BWI_RX32_INDEX 0x18 +#define BWI_RX32_STATUS 0x1c +#define BWI_RX32_STATUS_INDEX_MASK __BITS(11, 0) +#define BWI_RX32_STATUS_STATE_MASK __BITS(15, 12) +#define BWI_RX32_STATUS_STATE_DISABLED 0 +/* Shared by 32bit TX/RX CTRL */ +#define BWI_TXRX32_CTRL_ENABLE __BIT(0) +#define BWI_TXRX32_CTRL_ADDRHI_MASK __BITS(17, 16) +/* Shared by 32bit TX/RX RINGINFO */ +#define BWI_TXRX32_RINGINFO_FUNC_TXRX 0x1 +#define BWI_TXRX32_RINGINFO_FUNC_MASK __BITS(31, 30) +#define BWI_TXRX32_RINGINFO_ADDR_MASK __BITS(29, 0) + +#define BWI_PHYINFO 0x3e0 +#define BWI_PHYINFO_REV_MASK __BITS(3, 0) +#define BWI_PHYINFO_TYPE_MASK __BITS(11, 8) +#define BWI_PHYINFO_TYPE_11A 0 +#define BWI_PHYINFO_TYPE_11B 1 +#define BWI_PHYINFO_TYPE_11G 2 +#define BWI_PHYINFO_TYPE_11N 4 +#define BWI_PHYINFO_TYPE_11LP 5 +#define BWI_PHYINFO_VER_MASK __BITS(15, 12) + +#define BWI_RF_ANTDIV 0x3e2 /* Antenna Diversity?? */ + +#define BWI_PHY_MAGIC_REG1 0x3e4 +#define BWI_PHY_MAGIC_REG1_VAL1 0x3000 +#define BWI_PHY_MAGIC_REG1_VAL2 0x9 + +#define BWI_BBP_ATTEN 0x3e6 +#define BWI_BBP_ATTEN_MAGIC 0xf4 +#define BWI_BBP_ATTEN_MAGIC2 0x8140 + +#define BWI_BPHY_CTRL 0x3ec +#define BWI_BPHY_CTRL_INIT 0x3f22 + +#define BWI_RF_CHAN 0x3f0 +#define BWI_RF_CHAN_EX 0x3f4 + +#define BWI_RF_CTRL 0x3f6 +/* Register values for BWI_RF_CTRL */ +#define BWI_RF_CTRL_RFINFO 0x1 +/* XXX extra bits for reading from radio */ +#define BWI_RF_CTRL_RD_11A 0x40 +#define BWI_RF_CTRL_RD_11BG 0x80 +#define BWI_RF_DATA_HI 0x3f8 +#define BWI_RF_DATA_LO 0x3fa +/* Values read from BWI_RF_DATA_{HI,LO} after BWI_RF_CTRL_RFINFO */ +#define BWI_RFINFO_MANUFACT_MASK __BITS(11, 0) +#define BWI_RF_MANUFACT_BCM 0x17f /* XXX */ +#define BWI_RFINFO_TYPE_MASK __BITS(27, 12) +#define BWI_RF_T_BCM2050 0x2050 +#define BWI_RF_T_BCM2053 0x2053 +#define BWI_RF_T_BCM2060 0x2060 +#define BWI_RFINFO_REV_MASK __BITS(31, 28) + +#define BWI_PHY_CTRL 0x3fc +#define BWI_PHY_DATA 0x3fe + +#define BWI_ADDR_FILTER_CTRL 0x420 +#define BWI_ADDR_FILTER_CTRL_SET 0x20 +#define BWI_ADDR_FILTER_MYADDR 0 +#define BWI_ADDR_FILTER_BSSID 3 +#define BWI_ADDR_FILTER_DATA 0x422 + +#define BWI_MAC_GPIO_CTRL 0x49c +#define BWI_MAC_GPIO_MASK 0x49e +#define BWI_MAC_PRE_TBTT 0x612 +#define BWI_MAC_SLOTTIME 0x684 +#define BWI_MAC_SLOTTIME_ADJUST 510 +#define BWI_MAC_POWERUP_DELAY 0x6a8 + +/* + * Special registers + */ +/* + * GPIO control + * If common regwin exists, then it is within common regwin, + * else it is in bus regwin. + */ +#define BWI_GPIO_CTRL 0x6c + +#define PCI_VENDOR_BROADCOM 0x14e4 /* Broadcom */ +#define PCI_PRODUCT_BROADCOM_BCM4309 0x4324 + +/* + * Extended PCI registers + */ +#define BWI_PCIR_BAR PCIR_BAR(0) +#define BWI_PCIR_SEL_REGWIN 0x80 +/* Register value for BWI_PCIR_SEL_REGWIN */ +#define BWI_PCIM_REGWIN(id) (((id) * 0x1000) + 0x18000000) +#define BWI_PCIR_GPIO_IN 0xb0 +#define BWI_PCIR_GPIO_OUT 0xb4 +#define BWI_PCIM_GPIO_OUT_CLKSRC __BIT(4) +#define BWI_PCIR_GPIO_ENABLE 0xb8 +/* Register values for BWI_PCIR_GPIO_{IN,OUT,ENABLE} */ +#define BWI_PCIM_GPIO_PWR_ON __BIT(6) +#define BWI_PCIM_GPIO_PLL_PWR_OFF __BIT(7) +#define BWI_PCIR_INTCTL 0x94 + +/* + * PCI subdevice IDs + */ +#define BWI_PCI_SUBDEVICE_BU4306 0x416 +#define BWI_PCI_SUBDEVICE_BCM4309G 0x421 + +#define BWI_IS_BRCM_BU4306(sc) \ + ((sc)->sc_pci_subvid == PCI_VENDOR_BROADCOM && \ + (sc)->sc_pci_subdid == BWI_PCI_SUBDEVICE_BU4306) +#define BWI_IS_BRCM_BCM4309G(sc) \ + ((sc)->sc_pci_subvid == PCI_VENDOR_BROADCOM && \ + (sc)->sc_pci_subdid == BWI_PCI_SUBDEVICE_BCM4309G) + +/* + * EEPROM start address + */ +#define BWI_SPROM_START 0x1000 +#define BWI_SPROM_11BG_EADDR 0x48 +#define BWI_SPROM_11A_EADDR 0x54 +#define BWI_SPROM_CARD_INFO 0x5c +#define BWI_SPROM_CARD_INFO_LOCALE __BITS(11, 8) +#define BWI_SPROM_LOCALE_JAPAN 5 +#define BWI_SPROM_PA_PARAM_11BG 0x5e +#define BWI_SPROM_GPIO01 0x64 +#define BWI_SPROM_GPIO_0 __BITS(7, 0) +#define BWI_SPROM_GPIO_1 __BITS(15, 8) +#define BWI_SPROM_GPIO23 0x66 +#define BWI_SPROM_GPIO_2 __BITS(7, 0) +#define BWI_SPROM_GPIO_3 __BITS(15, 8) +#define BWI_SPROM_MAX_TXPWR 0x68 +#define BWI_SPROM_MAX_TXPWR_MASK_11BG __BITS(7, 0) /* XXX */ +#define BWI_SPROM_MAX_TXPWR_MASK_11A __BITS(15, 8) /* XXX */ +#define BWI_SPROM_PA_PARAM_11A 0x6a +#define BWI_SPROM_IDLE_TSSI 0x70 +#define BWI_SPROM_IDLE_TSSI_MASK_11BG __BITS(7, 0) /* XXX */ +#define BWI_SPROM_IDLE_TSSI_MASK_11A __BITS(15, 8) /* XXX */ +#define BWI_SPROM_CARD_FLAGS 0x72 +#define BWI_SPROM_ANT_GAIN 0x74 +#define BWI_SPROM_ANT_GAIN_MASK_11A __BITS(7, 0) +#define BWI_SPROM_ANT_GAIN_MASK_11BG __BITS(15, 8) + +/* + * SPROM card flags + */ +#define BWI_CARD_F_BT_COEXIST __BIT(0) /* Bluetooth coexist */ +#define BWI_CARD_F_PA_GPIO9 __BIT(1) /* GPIO 9 controls PA */ +#define BWI_CARD_F_SW_NRSSI __BIT(3) +#define BWI_CARD_F_NO_SLOWCLK __BIT(5) /* no slow clock */ +#define BWI_CARD_F_EXT_LNA __BIT(12) /* external LNA */ +#define BWI_CARD_F_ALT_IQ __BIT(15) /* alternate I/Q */ + +/* + * SPROM GPIO + */ +#define BWI_LED_ACT_LOW __BIT(7) +#define BWI_LED_ACT_MASK __BITS(6, 0) +#define BWI_LED_ACT_OFF 0 +#define BWI_LED_ACT_ON 1 +#define BWI_LED_ACT_ACTIVE 2 +#define BWI_LED_ACT_RFEN 3 +#define BWI_LED_ACT_5GHZ 4 +#define BWI_LED_ACT_2GHZ 5 +#define BWI_LED_ACT_11G 6 +#define BWI_LED_ACT_MID 7 +#define BWI_LED_ACT_FAST 8 +#define BWI_LED_ACT_UNKN 9 +#define BWI_LED_ACT_RUN 10 +#define BWI_LED_ACT_NULL 11 + +/* + * BBP IDs + */ +#define BWI_BBPID_BCM4301 0x4301 +#define BWI_BBPID_BCM4306 0x4306 +#define BWI_BBPID_BCM4317 0x4317 +#define BWI_BBPID_BCM4320 0x4320 +#define BWI_BBPID_BCM4321 0x4321 + +/* + * Register window types + */ +#define BWI_REGWIN_T_CC 0x800 //CC +#define BWI_REGWIN_T_ILINE20 0x801 +#define BWI_REGWIN_T_SDRAM 0x803 +#define BWI_REGWIN_T_PCI 0x804 //BUSPCI +#define BWI_REGWIN_T_MIPS 0x805 +#define BWI_REGWIN_T_ENET 0x806 +#define BWI_REGWIN_T_CODEC 0x807 +#define BWI_REGWIN_T_USB 0x808 +#define BWI_REGWIN_T_ADSL 0x809 +#define BWI_REGWIN_T_ILINE100 0x80a +#define BWI_REGWIN_T_IPSEC 0x80b +#define BWI_REGWIN_T_PCMCIA 0x80d +#define BWI_REGWIN_T_SOCRAM 0x80e +#define BWI_REGWIN_T_MEMC 0x80f +#define BWI_REGWIN_T_EXTIF 0x811 +#define BWI_REGWIN_T_D11 0x812 //MAC +#define BWI_REGWIN_T_MIPS33 0x816 +#define BWI_REGWIN_T_USB11H 0x817 +#define BWI_REGWIN_T_USB11D 0x818 +#define BWI_REGWIN_T_USB20H 0x819 +#define BWI_REGWIN_T_USB20D 0x81a +#define BWI_REGWIN_T_SDIOH 0x81b +#define BWI_REGWIN_T_ROBO 0x81c +#define BWI_REGWIN_T_ATA100 0x81d +#define BWI_REGWIN_T_SATAXOR 0x81e +#define BWI_REGWIN_T_GIGETH 0x81f +#define BWI_REGWIN_T_PCIE 0x820 +#define BWI_REGWIN_T_SRAMC 0x822 +#define BWI_REGWIN_T_MINIMAC 0x823 + +/* + * MAC interrupts + */ +#define BWI_INTR_READY __BIT(0) +#define BWI_INTR_BEACON __BIT(1) +#define BWI_INTR_TBTT __BIT(2) +#define BWI_INTR_EO_ATIM __BIT(5) /* End of ATIM */ +#define BWI_INTR_PMQ __BIT(6) /* XXX?? */ +#define BWI_INTR_MAC_TXERR __BIT(9) +#define BWI_INTR_PHY_TXERR __BIT(11) +#define BWI_INTR_TIMER1 __BIT(14) +#define BWI_INTR_RX_DONE __BIT(15) +#define BWI_INTR_TX_FIFO __BIT(16) /* XXX?? */ +#define BWI_INTR_NOISE __BIT(18) +#define BWI_INTR_RF_DISABLED __BIT(28) +#define BWI_INTR_TX_DONE __BIT(29) + +#define BWI_INIT_INTRS \ + (BWI_INTR_READY | BWI_INTR_BEACON | BWI_INTR_TBTT | \ + BWI_INTR_EO_ATIM | BWI_INTR_PMQ | BWI_INTR_MAC_TXERR | \ + BWI_INTR_PHY_TXERR | BWI_INTR_RX_DONE | BWI_INTR_TX_FIFO | \ + BWI_INTR_NOISE | BWI_INTR_RF_DISABLED | BWI_INTR_TX_DONE) +#define BWI_ALL_INTRS 0xffffffff + +/* + * TX/RX interrupts + */ +#define BWI_TXRX_INTR_ERROR (__BIT(15) | __BIT(14) | __BITS(12, 10)) +#define BWI_TXRX_INTR_RX __BIT(16) +#define BWI_TXRX_TX_INTRS BWI_TXRX_INTR_ERROR +#define BWI_TXRX_RX_INTRS (BWI_TXRX_INTR_ERROR | BWI_TXRX_INTR_RX) +#define BWI_TXRX_IS_RX(i) ((i) % 3 == 0) + +#endif /* !_IF_BWIREG_H */ --- /dev/null +++ sys/dev/bwi/if_bwi.c @@ -0,0 +1,3838 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/if_bwi.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/if_bwi.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include + +#ifdef INET +#include +#include +#endif + +#include + +#include +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" + +struct bwi_clock_freq { + u_int clkfreq_min; + u_int clkfreq_max; +}; + +struct bwi_myaddr_bssid { + uint8_t myaddr[IEEE80211_ADDR_LEN]; + uint8_t bssid[IEEE80211_ADDR_LEN]; +} __packed; + +static void bwi_init(void *); +static int bwi_ioctl(struct ifnet *, u_long, caddr_t); +static void bwi_start(struct ifnet *); +static void bwi_watchdog(struct ifnet *); +static void bwi_scan_start(struct ieee80211com *); +static void bwi_set_channel(struct ieee80211com *); +static void bwi_scan_end(struct ieee80211com *); +static int bwi_newstate(struct ieee80211com *, enum ieee80211_state, int); +static void bwi_updateslot(struct ifnet *); +static struct ieee80211_node *bwi_node_alloc(struct ieee80211_node_table *); +static void bwi_newassoc(struct ieee80211_node *, int); +static void bwi_amrr_timeout(void *); +static int bwi_media_change(struct ifnet *); + +static void bwi_calibrate(void *); + +static int bwi_calc_rssi(struct bwi_softc *, const struct bwi_rxbuf_hdr *); +static __inline uint8_t bwi_ofdm_plcp2rate(const uint32_t *); +static __inline uint8_t bwi_ds_plcp2rate(const struct ieee80211_ds_plcp_hdr *); +static void bwi_rx_radiotap(struct bwi_softc *, struct mbuf *, + struct bwi_rxbuf_hdr *, const void *, int); + +static void bwi_stop(struct bwi_softc *); +static int bwi_newbuf(struct bwi_softc *, int, int); +static int bwi_encap(struct bwi_softc *, int, struct mbuf *, + struct ieee80211_node *); + +static void bwi_init_rxdesc_ring32(struct bwi_softc *, uint32_t, + bus_addr_t, int, int); +static void bwi_reset_rx_ring32(struct bwi_softc *, uint32_t); + +static int bwi_init_tx_ring32(struct bwi_softc *, int); +static int bwi_init_rx_ring32(struct bwi_softc *); +static int bwi_init_txstats32(struct bwi_softc *); +static void bwi_free_tx_ring32(struct bwi_softc *, int); +static void bwi_free_rx_ring32(struct bwi_softc *); +static void bwi_free_txstats32(struct bwi_softc *); +static void bwi_setup_rx_desc32(struct bwi_softc *, int, bus_addr_t, int); +static void bwi_setup_tx_desc32(struct bwi_softc *, struct bwi_ring_data *, + int, bus_addr_t, int); +static void bwi_rxeof32(struct bwi_softc *); +static void bwi_start_tx32(struct bwi_softc *, uint32_t, int); +static void bwi_txeof_status32(struct bwi_softc *); + +static int bwi_init_tx_ring64(struct bwi_softc *, int); +static int bwi_init_rx_ring64(struct bwi_softc *); +static int bwi_init_txstats64(struct bwi_softc *); +static void bwi_free_tx_ring64(struct bwi_softc *, int); +static void bwi_free_rx_ring64(struct bwi_softc *); +static void bwi_free_txstats64(struct bwi_softc *); +static void bwi_setup_rx_desc64(struct bwi_softc *, int, bus_addr_t, int); +static void bwi_setup_tx_desc64(struct bwi_softc *, struct bwi_ring_data *, + int, bus_addr_t, int); +static void bwi_rxeof64(struct bwi_softc *); +static void bwi_start_tx64(struct bwi_softc *, uint32_t, int); +static void bwi_txeof_status64(struct bwi_softc *); + +static void bwi_rxeof(struct bwi_softc *, int); +static void _bwi_txeof(struct bwi_softc *, uint16_t, int, int); +static void bwi_txeof(struct bwi_softc *); +static void bwi_txeof_status(struct bwi_softc *, int); +static void bwi_enable_intrs(struct bwi_softc *, uint32_t); +static void bwi_disable_intrs(struct bwi_softc *, uint32_t); + +static int bwi_dma_alloc(struct bwi_softc *); +static void bwi_dma_free(struct bwi_softc *); +static int bwi_dma_ring_alloc(struct bwi_softc *, bus_dma_tag_t, + struct bwi_ring_data *, bus_size_t, + uint32_t); +static int bwi_dma_mbuf_create(struct bwi_softc *); +static void bwi_dma_mbuf_destroy(struct bwi_softc *, int, int); +static int bwi_dma_txstats_alloc(struct bwi_softc *, uint32_t, bus_size_t); +static void bwi_dma_txstats_free(struct bwi_softc *); +static void bwi_dma_ring_addr(void *, bus_dma_segment_t *, int, int); +static void bwi_dma_buf_addr(void *, bus_dma_segment_t *, int, + bus_size_t, int); + +static void bwi_power_on(struct bwi_softc *, int); +static int bwi_power_off(struct bwi_softc *, int); +static int bwi_set_clock_mode(struct bwi_softc *, enum bwi_clock_mode); +static int bwi_set_clock_delay(struct bwi_softc *); +static void bwi_get_clock_freq(struct bwi_softc *, struct bwi_clock_freq *); +static int bwi_get_pwron_delay(struct bwi_softc *sc); +static void bwi_set_addr_filter(struct bwi_softc *, uint16_t, + const uint8_t *); +static void bwi_set_bssid(struct bwi_softc *, const uint8_t *); +static int bwi_set_chan(struct bwi_softc *, struct ieee80211_channel *); + +static void bwi_get_card_flags(struct bwi_softc *); +static void bwi_get_eaddr(struct bwi_softc *, uint16_t, uint8_t *); + +static int bwi_bus_attach(struct bwi_softc *); +static int bwi_bbp_attach(struct bwi_softc *); +static int bwi_bbp_power_on(struct bwi_softc *, enum bwi_clock_mode); +static void bwi_bbp_power_off(struct bwi_softc *); + +static const char *bwi_regwin_name(const uint16_t type); +static uint32_t bwi_regwin_disable_bits(struct bwi_softc *); +static void bwi_regwin_info(struct bwi_softc *, uint16_t *, uint8_t *); +static int bwi_regwin_select(struct bwi_softc *, int); + +static void bwi_led_attach(struct bwi_softc *); +static void bwi_led_newstate(struct bwi_softc *, enum ieee80211_state); + +static const struct { + uint16_t did_min; + uint16_t did_max; + uint16_t bbp_id; +} bwi_bbpid_map[] = { + { 0x4301, 0x4301, 0x4301 }, + { 0x4305, 0x4307, 0x4307 }, + { 0x4403, 0x4403, 0x4402 }, + { 0x4610, 0x4615, 0x4610 }, + { 0x4710, 0x4715, 0x4710 }, + { 0x4720, 0x4725, 0x4309 } +}; + +static const struct { + uint16_t bbp_id; + int nregwin; +} bwi_regwin_count[] = { + { 0x4301, 5 }, + { 0x4306, 6 }, + { 0x4307, 5 }, + { 0x4310, 8 }, + { 0x4401, 3 }, + { 0x4402, 3 }, + { 0x4610, 9 }, + { 0x4704, 9 }, + { 0x4710, 9 }, + { 0x5365, 7 } +}; + +#define CLKSRC(src) \ +[BWI_CLKSRC_ ## src] = { \ + .freq_min = BWI_CLKSRC_ ##src## _FMIN, \ + .freq_max = BWI_CLKSRC_ ##src## _FMAX \ +} + +static const struct { + u_int freq_min; + u_int freq_max; +} bwi_clkfreq[BWI_CLKSRC_MAX] = { + CLKSRC(LP_OSC), + CLKSRC(CS_OSC), + CLKSRC(PCI) +}; + +#undef CLKSRC + +static const uint8_t bwi_zero_addr[IEEE80211_ADDR_LEN]; + +uint16_t +bwi_read_sprom(struct bwi_softc *sc, uint16_t ofs) +{ + return CSR_READ_2(sc, ofs + BWI_SPROM_START); +} + +static __inline void +bwi_setup_desc32(struct bwi_softc *sc, struct bwi_desc32 *desc_array, + int ndesc, int desc_idx, bus_addr_t paddr, int buf_len, + int tx) +{ + struct bwi_desc32 *desc = &desc_array[desc_idx]; + uint32_t ctrl, addr, addr_hi, addr_lo; + + addr_lo = __SHIFTOUT(paddr, BWI_DESC32_A_ADDR_MASK); + addr_hi = __SHIFTOUT(paddr, BWI_DESC32_A_FUNC_MASK); + + addr = __SHIFTIN(addr_lo, BWI_DESC32_A_ADDR_MASK) | + __SHIFTIN(BWI_DESC32_A_FUNC_TXRX, BWI_DESC32_A_FUNC_MASK); + + ctrl = __SHIFTIN(buf_len, BWI_DESC32_C_BUFLEN_MASK) | + __SHIFTIN(addr_hi, BWI_DESC32_C_ADDRHI_MASK); + if (desc_idx == ndesc - 1) + ctrl |= BWI_DESC32_C_EOR; + if (tx) { + /* XXX */ + ctrl |= BWI_DESC32_C_FRAME_START | + BWI_DESC32_C_FRAME_END | + BWI_DESC32_C_INTR; + } + + desc->addr = htole32(addr); + desc->ctrl = htole32(ctrl); +} + +int +bwi_attach(struct bwi_softc *sc) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp; + struct bwi_mac *mac; + struct bwi_phy *phy; + int i, error, bands; + + BWI_LOCK_INIT(sc); + + bwi_power_on(sc, 1); + + error = bwi_bbp_attach(sc); + if (error) + goto fail; + + error = bwi_bbp_power_on(sc, BWI_CLOCK_MODE_FAST); + if (error) + goto fail; + + if (BWI_REGWIN_EXIST(&sc->sc_com_regwin)) { + error = bwi_set_clock_delay(sc); + if (error) + goto fail; + + error = bwi_set_clock_mode(sc, BWI_CLOCK_MODE_FAST); + if (error) + goto fail; + + error = bwi_get_pwron_delay(sc); + if (error) + goto fail; + } + + error = bwi_bus_attach(sc); + if (error) + goto fail; + + bwi_get_card_flags(sc); + + bwi_led_attach(sc); + + for (i = 0; i < sc->sc_nmac; ++i) { + struct bwi_regwin *old; + + mac = &sc->sc_mac[i]; + error = bwi_regwin_switch(sc, &mac->mac_regwin, &old); + if (error) + goto fail; + + error = bwi_mac_lateattach(mac); + if (error) + goto fail; + + error = bwi_regwin_switch(sc, old, NULL); + if (error) + goto fail; + } + + /* + * XXX First MAC is known to exist + * TODO2 + */ + mac = &sc->sc_mac[0]; + phy = &mac->mac_phy; + + bwi_bbp_power_off(sc); + + error = bwi_dma_alloc(sc); + if (error) + goto fail; + + ifp = sc->sc_ifp = if_alloc(IFT_ETHER); + if (ifp == NULL) { + device_printf(sc->sc_dev, "can not if_alloc()\n"); + error = ENOSPC; + goto fail; + } + + /* set these up early for if_printf use */ + if_initname(ifp, device_get_name(sc->sc_dev), + device_get_unit(sc->sc_dev)); + + callout_init(&sc->sc_calib_ch, CALLOUT_MPSAFE); + callout_init(&sc->sc_amrr_ch, CALLOUT_MPSAFE); + + ifp->if_softc = sc; + ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; + ifp->if_init = bwi_init; + ifp->if_ioctl = bwi_ioctl; + ifp->if_start = bwi_start; + ifp->if_watchdog = bwi_watchdog; + IFQ_SET_MAXLEN(&ifp->if_snd, IFQ_MAXLEN); + ifp->if_snd.ifq_drv_maxlen = IFQ_MAXLEN; + IFQ_SET_READY(&ifp->if_snd); + + /* Get locale */ + sc->sc_locale = __SHIFTOUT(bwi_read_sprom(sc, BWI_SPROM_CARD_INFO), + BWI_SPROM_CARD_INFO_LOCALE); + DPRINTF(sc, "locale: %d\n", sc->sc_locale); + + /* + * Setup ratesets, phytype, channels and get MAC address + */ + bands = 0; + if (phy->phy_mode == IEEE80211_MODE_11B || + phy->phy_mode == IEEE80211_MODE_11G) { + + if (phy->phy_mode == IEEE80211_MODE_11B) { + setbit(&bands, IEEE80211_MODE_11B); + ic->ic_phytype = IEEE80211_T_DS; + } else { + ic->ic_phytype = IEEE80211_T_OFDM; + setbit(&bands, IEEE80211_MODE_11G); + } + + bwi_get_eaddr(sc, BWI_SPROM_11BG_EADDR, ic->ic_myaddr); + if (IEEE80211_IS_MULTICAST(ic->ic_myaddr)) { + bwi_get_eaddr(sc, BWI_SPROM_11A_EADDR, ic->ic_myaddr); + if (IEEE80211_IS_MULTICAST(ic->ic_myaddr)) { + device_printf(sc->sc_dev, + "invalid MAC address: %6D\n", + ic->ic_myaddr, ":"); + } + } + } else if (phy->phy_mode == IEEE80211_MODE_11A) { + /* TODO:11A */ + setbit(&bands, IEEE80211_MODE_11A); + error = ENXIO; + goto fail; + } else { + panic("unknown phymode %d\n", phy->phy_mode); + } + /* XXX use locale */ + ieee80211_init_channels(ic, 0, CTRY_DEFAULT, bands, 0, 1); + + sc->sc_fw_version = BWI_FW_VERSION3; + + ic->ic_ifp = ifp; + ic->ic_caps = IEEE80211_C_SHSLOT | + IEEE80211_C_SHPREAMBLE | + IEEE80211_C_WPA | + IEEE80211_C_MONITOR; + ic->ic_state = IEEE80211_S_INIT; + ic->ic_opmode = IEEE80211_M_STA; + + ic->ic_updateslot = bwi_updateslot; + + ieee80211_ifattach(ic); + + ic->ic_headroom = sizeof(struct bwi_txbuf_hdr); + ic->ic_flags_ext |= IEEE80211_FEXT_SWBMISS; + + /* override default methods */ + sc->sc_newstate = ic->ic_newstate; + ic->ic_newstate = bwi_newstate; + ic->ic_scan_start = bwi_scan_start; + ic->ic_scan_end = bwi_scan_end; + ic->ic_set_channel = bwi_set_channel; + ic->ic_node_alloc = bwi_node_alloc; + ic->ic_newassoc = bwi_newassoc; + /* complete initialization */ + ieee80211_media_init(ic, bwi_media_change, ieee80211_media_status); + ieee80211_amrr_init(&sc->sc_amrr, ic, + IEEE80211_AMRR_MIN_SUCCESS_THRESHOLD, + IEEE80211_AMRR_MAX_SUCCESS_THRESHOLD); + + /* + * Attach radio tap + */ + bpfattach2(ifp, DLT_IEEE802_11_RADIO, + sizeof(struct ieee80211_frame) + sizeof(sc->sc_tx_th), + &sc->sc_drvbpf); + + sc->sc_tx_th_len = roundup(sizeof(sc->sc_tx_th), sizeof(uint32_t)); + sc->sc_tx_th.wt_ihdr.it_len = htole16(sc->sc_tx_th_len); + sc->sc_tx_th.wt_ihdr.it_present = htole32(BWI_TX_RADIOTAP_PRESENT); + + sc->sc_rx_th_len = roundup(sizeof(sc->sc_rx_th), sizeof(uint32_t)); + sc->sc_rx_th.wr_ihdr.it_len = htole16(sc->sc_rx_th_len); + sc->sc_rx_th.wr_ihdr.it_present = htole32(BWI_RX_RADIOTAP_PRESENT); + + if (bootverbose) + ieee80211_announce(ic); + + return (0); +fail: + BWI_LOCK_DESTROY(sc); + return (error); +} + +int +bwi_detach(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ifp; + int i; + + bwi_stop(sc); + callout_stop(&sc->sc_amrr_ch); + ieee80211_ifdetach(&sc->sc_ic); + + for (i = 0; i < sc->sc_nmac; ++i) + bwi_mac_detach(&sc->sc_mac[i]); + bwi_dma_free(sc); + if_free(ifp); + + BWI_LOCK_DESTROY(sc); + + return (0); +} + +void +bwi_suspend(struct bwi_softc *sc) +{ + bwi_stop(sc); +} + +void +bwi_resume(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ifp; + + if (ifp->if_flags & IFF_UP) { + bwi_init(sc); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + bwi_start(ifp); + } +} + +int +bwi_shutdown(struct bwi_softc *sc) +{ + bwi_stop(sc); + return 0; +} + +static void +bwi_power_on(struct bwi_softc *sc, int with_pll) +{ + uint32_t gpio_in, gpio_out, gpio_en; + uint16_t status; + + gpio_in = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_IN, 4); + if (gpio_in & BWI_PCIM_GPIO_PWR_ON) + goto back; + + gpio_out = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, 4); + gpio_en = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, 4); + + gpio_out |= BWI_PCIM_GPIO_PWR_ON; + gpio_en |= BWI_PCIM_GPIO_PWR_ON; + if (with_pll) { + /* Turn off PLL first */ + gpio_out |= BWI_PCIM_GPIO_PLL_PWR_OFF; + gpio_en |= BWI_PCIM_GPIO_PLL_PWR_OFF; + } + + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, gpio_out, 4); + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, gpio_en, 4); + DELAY(1000); + + if (with_pll) { + /* Turn on PLL */ + gpio_out &= ~BWI_PCIM_GPIO_PLL_PWR_OFF; + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, gpio_out, 4); + DELAY(5000); + } + +back: + /* Clear "Signaled Target Abort" */ + status = pci_read_config(sc->sc_dev, PCIR_STATUS, 2); + status &= ~PCIM_STATUS_STABORT; + pci_write_config(sc->sc_dev, PCIR_STATUS, status, 2); +} + +static int +bwi_power_off(struct bwi_softc *sc, int with_pll) +{ + uint32_t gpio_out, gpio_en; + + pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_IN, 4); /* dummy read */ + gpio_out = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, 4); + gpio_en = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, 4); + + gpio_out &= ~BWI_PCIM_GPIO_PWR_ON; + gpio_en |= BWI_PCIM_GPIO_PWR_ON; + if (with_pll) { + gpio_out |= BWI_PCIM_GPIO_PLL_PWR_OFF; + gpio_en |= BWI_PCIM_GPIO_PLL_PWR_OFF; + } + + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, gpio_out, 4); + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, gpio_en, 4); + return 0; +} + +int +bwi_regwin_switch(struct bwi_softc *sc, struct bwi_regwin *rw, + struct bwi_regwin **old_rw) +{ + int error; + + if (old_rw != NULL) + *old_rw = NULL; + + if (!BWI_REGWIN_EXIST(rw)) + return EINVAL; + + if (sc->sc_cur_regwin != rw) { + error = bwi_regwin_select(sc, rw->rw_id); + if (error) { + device_printf(sc->sc_dev, "can't select regwin %d\n", + rw->rw_id); + return error; + } + } + + if (old_rw != NULL) + *old_rw = sc->sc_cur_regwin; + sc->sc_cur_regwin = rw; + return 0; +} + +static int +bwi_regwin_select(struct bwi_softc *sc, int id) +{ + uint32_t win = BWI_PCIM_REGWIN(id); + int i; + +#define RETRY_MAX 50 + for (i = 0; i < RETRY_MAX; ++i) { + pci_write_config(sc->sc_dev, BWI_PCIR_SEL_REGWIN, win, 4); + if (pci_read_config(sc->sc_dev, BWI_PCIR_SEL_REGWIN, 4) == win) + return 0; + DELAY(10); + } +#undef RETRY_MAX + + return ENXIO; +} + +static void +bwi_regwin_info(struct bwi_softc *sc, uint16_t *type, uint8_t *rev) +{ + uint32_t val; + + val = CSR_READ_4(sc, BWI_ID_HI); + *type = BWI_ID_HI_REGWIN_TYPE(val); + *rev = BWI_ID_HI_REGWIN_REV(val); + + DPRINTF(sc, "regwin: %s (0x%03x), rev %d, vendor 0x%04x\n", + bwi_regwin_name(*type), *type, *rev, __SHIFTOUT(val, BWI_ID_HI_REGWIN_VENDOR_MASK)); +} + +static int +bwi_bbp_attach(struct bwi_softc *sc) +{ +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + uint16_t bbp_id, rw_type; + uint8_t rw_rev; + uint32_t info; + int error, nregwin, i; + + /* + * Get 0th regwin information + * NOTE: 0th regwin should exist + */ + error = bwi_regwin_select(sc, 0); + if (error) { + device_printf(sc->sc_dev, "can't select regwin 0\n"); + return error; + } + bwi_regwin_info(sc, &rw_type, &rw_rev); + + /* + * Find out BBP id + */ + bbp_id = 0; + info = 0; + if (rw_type == BWI_REGWIN_T_CC) { + info = CSR_READ_4(sc, BWI_INFO); + bbp_id = __SHIFTOUT(info, BWI_INFO_BBPID_MASK); + + BWI_CREATE_REGWIN(&sc->sc_com_regwin, 0, rw_type, rw_rev); + + sc->sc_cap = CSR_READ_4(sc, BWI_CAPABILITY); + } else { + for (i = 0; i < N(bwi_bbpid_map); ++i) { + if (sc->sc_pci_did >= bwi_bbpid_map[i].did_min && + sc->sc_pci_did <= bwi_bbpid_map[i].did_max) { + bbp_id = bwi_bbpid_map[i].bbp_id; + break; + } + } + if (bbp_id == 0) { + device_printf(sc->sc_dev, "no BBP id for device id " + "0x%04x\n", sc->sc_pci_did); + return ENXIO; + } + + info = __SHIFTIN(sc->sc_pci_revid, BWI_INFO_BBPREV_MASK) | + __SHIFTIN(0, BWI_INFO_BBPPKG_MASK); + } + + /* + * Find out number of regwins + */ + nregwin = 0; + if (rw_type == BWI_REGWIN_T_CC && rw_rev >= 4) { + nregwin = __SHIFTOUT(info, BWI_INFO_NREGWIN_MASK); + } else { + for (i = 0; i < N(bwi_regwin_count); ++i) { + if (bwi_regwin_count[i].bbp_id == bbp_id) { + nregwin = bwi_regwin_count[i].nregwin; + break; + } + } + if (nregwin == 0) { + device_printf(sc->sc_dev, "no number of win for " + "BBP id 0x%04x\n", bbp_id); + return ENXIO; + } + } + + /* Record BBP id/rev for later using */ + sc->sc_bbp_id = bbp_id; + sc->sc_bbp_rev = __SHIFTOUT(info, BWI_INFO_BBPREV_MASK); + sc->sc_bbp_pkg = __SHIFTOUT(info, BWI_INFO_BBPPKG_MASK); + device_printf(sc->sc_dev, "BBP: id 0x%04x, rev 0x%x, pkg %d\n", + sc->sc_bbp_id, sc->sc_bbp_rev, sc->sc_bbp_pkg); + + DPRINTF(sc, "nregwin %d, cap 0x%08x\n", nregwin, sc->sc_cap); + + /* + * Create rest of the regwins + */ + + /* Don't re-create common regwin, if it is already created */ + i = BWI_REGWIN_EXIST(&sc->sc_com_regwin) ? 1 : 0; + + for (; i < nregwin; ++i) { + /* + * Get regwin information + */ + error = bwi_regwin_select(sc, i); + if (error) { + device_printf(sc->sc_dev, + "can't select regwin %d\n", i); + return error; + } + bwi_regwin_info(sc, &rw_type, &rw_rev); + + /* + * Try attach: + * 1) Bus (PCI/PCIE) regwin + * 2) MAC regwin + * Ignore rest types of regwin + */ + if (rw_type == BWI_REGWIN_T_PCI || + rw_type == BWI_REGWIN_T_PCIE) { + if (BWI_REGWIN_EXIST(&sc->sc_bus_regwin)) { + device_printf(sc->sc_dev, + "bus regwin already exists\n"); + } else { + BWI_CREATE_REGWIN(&sc->sc_bus_regwin, i, + rw_type, rw_rev); + } + } else if (rw_type == BWI_REGWIN_T_D11) { + /* XXX ignore return value */ + bwi_mac_attach(sc, i, rw_rev); + } + } + + /* At least one MAC shold exist */ + if (!BWI_REGWIN_EXIST(&sc->sc_mac[0].mac_regwin)) { + device_printf(sc->sc_dev, "no MAC was found\n"); + return ENXIO; + } + KASSERT(sc->sc_nmac > 0, ("no mac's")); + + /* Bus regwin must exist */ + if (!BWI_REGWIN_EXIST(&sc->sc_bus_regwin)) { + device_printf(sc->sc_dev, "no bus regwin was found\n"); + return ENXIO; + } + + /* Start with first MAC */ + error = bwi_regwin_switch(sc, &sc->sc_mac[0].mac_regwin, NULL); + if (error) + return error; + + return 0; +#undef N +} + +int +bwi_bus_init(struct bwi_softc *sc, struct bwi_mac *mac) +{ + struct bwi_regwin *old, *bus; + uint32_t val; + int error; + + bus = &sc->sc_bus_regwin; + KASSERT(sc->sc_cur_regwin == &mac->mac_regwin, ("not cur regwin")); + + /* + * Tell bus to generate requested interrupts + */ + if (bus->rw_rev < 6 && bus->rw_type == BWI_REGWIN_T_PCI) { + /* + * NOTE: Read BWI_FLAGS from MAC regwin + */ + val = CSR_READ_4(sc, BWI_FLAGS); + + error = bwi_regwin_switch(sc, bus, &old); + if (error) + return error; + + CSR_SETBITS_4(sc, BWI_INTRVEC, (val & BWI_FLAGS_INTR_MASK)); + } else { + uint32_t mac_mask; + + mac_mask = 1 << mac->mac_id; + + error = bwi_regwin_switch(sc, bus, &old); + if (error) + return error; + + val = pci_read_config(sc->sc_dev, BWI_PCIR_INTCTL, 4); + val |= mac_mask << 8; + pci_write_config(sc->sc_dev, BWI_PCIR_INTCTL, val, 4); + } + + if (sc->sc_flags & BWI_F_BUS_INITED) + goto back; + + if (bus->rw_type == BWI_REGWIN_T_PCI) { + /* + * Enable prefetch and burst + */ + CSR_SETBITS_4(sc, BWI_BUS_CONFIG, + BWI_BUS_CONFIG_PREFETCH | BWI_BUS_CONFIG_BURST); + + if (bus->rw_rev < 5) { + struct bwi_regwin *com = &sc->sc_com_regwin; + + /* + * Configure timeouts for bus operation + */ + + /* + * Set service timeout and request timeout + */ + CSR_SETBITS_4(sc, BWI_CONF_LO, + __SHIFTIN(BWI_CONF_LO_SERVTO, BWI_CONF_LO_SERVTO_MASK) | + __SHIFTIN(BWI_CONF_LO_REQTO, BWI_CONF_LO_REQTO_MASK)); + + /* + * If there is common regwin, we switch to that regwin + * and switch back to bus regwin once we have done. + */ + if (BWI_REGWIN_EXIST(com)) { + error = bwi_regwin_switch(sc, com, NULL); + if (error) + return error; + } + + /* Let bus know what we have changed */ + CSR_WRITE_4(sc, BWI_BUS_ADDR, BWI_BUS_ADDR_MAGIC); + CSR_READ_4(sc, BWI_BUS_ADDR); /* Flush */ + CSR_WRITE_4(sc, BWI_BUS_DATA, 0); + CSR_READ_4(sc, BWI_BUS_DATA); /* Flush */ + + if (BWI_REGWIN_EXIST(com)) { + error = bwi_regwin_switch(sc, bus, NULL); + if (error) + return error; + } + } else if (bus->rw_rev >= 11) { + /* + * Enable memory read multiple + */ + CSR_SETBITS_4(sc, BWI_BUS_CONFIG, BWI_BUS_CONFIG_MRM); + } + } else { + /* TODO:PCIE */ + } + + sc->sc_flags |= BWI_F_BUS_INITED; +back: + return bwi_regwin_switch(sc, old, NULL); +} + +static void +bwi_get_card_flags(struct bwi_softc *sc) +{ +#define PCI_VENDOR_APPLE 0x106b +#define PCI_VENDOR_DELL 0x1028 + sc->sc_card_flags = bwi_read_sprom(sc, BWI_SPROM_CARD_FLAGS); + if (sc->sc_card_flags == 0xffff) + sc->sc_card_flags = 0; + + if (sc->sc_pci_subvid == PCI_VENDOR_DELL && + sc->sc_bbp_id == BWI_BBPID_BCM4301 && + sc->sc_pci_revid == 0x74) + sc->sc_card_flags |= BWI_CARD_F_BT_COEXIST; + + if (sc->sc_pci_subvid == PCI_VENDOR_APPLE && + sc->sc_pci_subdid == 0x4e && /* XXX */ + sc->sc_pci_revid > 0x40) + sc->sc_card_flags |= BWI_CARD_F_PA_GPIO9; + + DPRINTF(sc, "card flags 0x%04x\n", sc->sc_card_flags); +#undef PCI_VENDOR_DELL +#undef PCI_VENDOR_APPLE +} + +static void +bwi_get_eaddr(struct bwi_softc *sc, uint16_t eaddr_ofs, uint8_t *eaddr) +{ + int i; + + for (i = 0; i < 3; ++i) { + *((uint16_t *)eaddr + i) = + htobe16(bwi_read_sprom(sc, eaddr_ofs + 2 * i)); + } +} + +static void +bwi_get_clock_freq(struct bwi_softc *sc, struct bwi_clock_freq *freq) +{ + struct bwi_regwin *com; + uint32_t val; + u_int div; + int src; + + bzero(freq, sizeof(*freq)); + com = &sc->sc_com_regwin; + + KASSERT(BWI_REGWIN_EXIST(com), ("regwin does not exist")); + KASSERT(sc->sc_cur_regwin == com, ("wrong regwin")); + KASSERT(sc->sc_cap & BWI_CAP_CLKMODE, ("wrong clock mode")); + + /* + * Calculate clock frequency + */ + src = -1; + div = 0; + if (com->rw_rev < 6) { + val = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, 4); + if (val & BWI_PCIM_GPIO_OUT_CLKSRC) { + src = BWI_CLKSRC_PCI; + div = 64; + } else { + src = BWI_CLKSRC_CS_OSC; + div = 32; + } + } else if (com->rw_rev < 10) { + val = CSR_READ_4(sc, BWI_CLOCK_CTRL); + + src = __SHIFTOUT(val, BWI_CLOCK_CTRL_CLKSRC); + if (src == BWI_CLKSRC_LP_OSC) { + div = 1; + } else { + div = (__SHIFTOUT(val, BWI_CLOCK_CTRL_FDIV) + 1) << 2; + + /* Unknown source */ + if (src >= BWI_CLKSRC_MAX) + src = BWI_CLKSRC_CS_OSC; + } + } else { + val = CSR_READ_4(sc, BWI_CLOCK_INFO); + + src = BWI_CLKSRC_CS_OSC; + div = (__SHIFTOUT(val, BWI_CLOCK_INFO_FDIV) + 1) << 2; + } + + KASSERT(src >= 0 && src < BWI_CLKSRC_MAX, ("bad src %d", src)); + KASSERT(div != 0, ("div zero")); + + DPRINTF(sc, "clksrc %s\n", + src == BWI_CLKSRC_PCI ? "PCI" : + (src == BWI_CLKSRC_LP_OSC ? "LP_OSC" : "CS_OSC")); + + freq->clkfreq_min = bwi_clkfreq[src].freq_min / div; + freq->clkfreq_max = bwi_clkfreq[src].freq_max / div; + + DPRINTF(sc, "clkfreq min %u, max %u\n", + freq->clkfreq_min, freq->clkfreq_max); +} + +static int +bwi_set_clock_mode(struct bwi_softc *sc, enum bwi_clock_mode clk_mode) +{ + struct bwi_regwin *old, *com; + uint32_t clk_ctrl, clk_src; + int error, pwr_off = 0; + + com = &sc->sc_com_regwin; + if (!BWI_REGWIN_EXIST(com)) + return 0; + + if (com->rw_rev >= 10 || com->rw_rev < 6) + return 0; + + /* + * For common regwin whose rev is [6, 10), the chip + * must be capable to change clock mode. + */ + if ((sc->sc_cap & BWI_CAP_CLKMODE) == 0) + return 0; + + error = bwi_regwin_switch(sc, com, &old); + if (error) + return error; + + if (clk_mode == BWI_CLOCK_MODE_FAST) + bwi_power_on(sc, 0); /* Don't turn on PLL */ + + clk_ctrl = CSR_READ_4(sc, BWI_CLOCK_CTRL); + clk_src = __SHIFTOUT(clk_ctrl, BWI_CLOCK_CTRL_CLKSRC); + + switch (clk_mode) { + case BWI_CLOCK_MODE_FAST: + clk_ctrl &= ~BWI_CLOCK_CTRL_SLOW; + clk_ctrl |= BWI_CLOCK_CTRL_IGNPLL; + break; + case BWI_CLOCK_MODE_SLOW: + clk_ctrl |= BWI_CLOCK_CTRL_SLOW; + break; + case BWI_CLOCK_MODE_DYN: + clk_ctrl &= ~(BWI_CLOCK_CTRL_SLOW | + BWI_CLOCK_CTRL_IGNPLL | + BWI_CLOCK_CTRL_NODYN); + if (clk_src != BWI_CLKSRC_CS_OSC) { + clk_ctrl |= BWI_CLOCK_CTRL_NODYN; + pwr_off = 1; + } + break; + } + CSR_WRITE_4(sc, BWI_CLOCK_CTRL, clk_ctrl); + + if (pwr_off) + bwi_power_off(sc, 0); /* Leave PLL as it is */ + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_set_clock_delay(struct bwi_softc *sc) +{ + struct bwi_regwin *old, *com; + int error; + + com = &sc->sc_com_regwin; + if (!BWI_REGWIN_EXIST(com)) + return 0; + + error = bwi_regwin_switch(sc, com, &old); + if (error) + return error; + + if (sc->sc_bbp_id == BWI_BBPID_BCM4321) { + if (sc->sc_bbp_rev == 0) + CSR_WRITE_4(sc, BWI_CONTROL, BWI_CONTROL_MAGIC0); + else if (sc->sc_bbp_rev == 1) + CSR_WRITE_4(sc, BWI_CONTROL, BWI_CONTROL_MAGIC1); + } + + if (sc->sc_cap & BWI_CAP_CLKMODE) { + if (com->rw_rev >= 10) { + CSR_FILT_SETBITS_4(sc, BWI_CLOCK_INFO, 0xffff, 0x40000); + } else { + struct bwi_clock_freq freq; + + bwi_get_clock_freq(sc, &freq); + CSR_WRITE_4(sc, BWI_PLL_ON_DELAY, + howmany(freq.clkfreq_max * 150, 1000000)); + CSR_WRITE_4(sc, BWI_FREQ_SEL_DELAY, + howmany(freq.clkfreq_max * 15, 1000000)); + } + } + + return bwi_regwin_switch(sc, old, NULL); +} + +static void +bwi_init(void *xsc) +{ + struct bwi_softc *sc = xsc; + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp = ic->ic_ifp; + struct bwi_mac *mac; + int error; + + BWI_LOCK(sc); + + DPRINTF(sc, "%s\n", __func__); + + bwi_stop(sc); + + bwi_bbp_power_on(sc, BWI_CLOCK_MODE_FAST); + + /* TODO: 2 MAC */ + + mac = &sc->sc_mac[0]; + error = bwi_regwin_switch(sc, &mac->mac_regwin, NULL); + if (error) + goto back; + + error = bwi_mac_init(mac); + if (error) + goto back; + + bwi_bbp_power_on(sc, BWI_CLOCK_MODE_DYN); + + bcopy(IF_LLADDR(ifp), ic->ic_myaddr, sizeof(ic->ic_myaddr)); + + bwi_set_bssid(sc, bwi_zero_addr); /* Clear BSSID */ + bwi_set_addr_filter(sc, BWI_ADDR_FILTER_MYADDR, ic->ic_myaddr); + + bwi_mac_reset_hwkeys(mac); + + if ((mac->mac_flags & BWI_MAC_F_HAS_TXSTATS) == 0) { + int i; + +#define NRETRY 1000 + /* + * Drain any possible pending TX status + */ + for (i = 0; i < NRETRY; ++i) { + if ((CSR_READ_4(sc, BWI_TXSTATUS0) & + BWI_TXSTATUS0_VALID) == 0) + break; + CSR_READ_4(sc, BWI_TXSTATUS1); + } + if (i == NRETRY) + if_printf(ifp, "can't drain TX status\n"); +#undef NRETRY + } + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11G) + bwi_mac_updateslot(mac, 1); + + /* Start MAC */ + error = bwi_mac_start(mac); + if (error) + goto back; + + /* Enable intrs */ + bwi_enable_intrs(sc, BWI_INIT_INTRS); + + ifp->if_drv_flags |= IFF_DRV_RUNNING; + ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; + + if (ic->ic_opmode != IEEE80211_M_MONITOR) { + if (ic->ic_roaming != IEEE80211_ROAMING_MANUAL) + ieee80211_new_state(ic, IEEE80211_S_SCAN, -1); + } else { + ieee80211_new_state(ic, IEEE80211_S_RUN, -1); + } +back: + if (error) + bwi_stop(sc); + BWI_UNLOCK(sc); +} + +static int +bwi_ioctl(struct ifnet *ifp, u_long cmd, caddr_t req) +{ +#define IS_RUNNING(ifp) \ + ((ifp->if_flags & IFF_UP) && (ifp->if_drv_flags & IFF_DRV_RUNNING)) + struct bwi_softc *sc = ifp->if_softc; + int error = 0; + + BWI_LOCK(sc); + + switch (cmd) { + case SIOCSIFFLAGS: + if (IS_RUNNING(ifp)) { + struct bwi_mac *mac; + int promisc = -1; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", + sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + if ((ifp->if_flags & IFF_PROMISC) && + (sc->sc_flags & BWI_F_PROMISC) == 0) { + promisc = 1; + sc->sc_flags |= BWI_F_PROMISC; + } else if ((ifp->if_flags & IFF_PROMISC) == 0 && + (sc->sc_flags & BWI_F_PROMISC)) { + promisc = 0; + sc->sc_flags &= ~BWI_F_PROMISC; + } + + if (promisc >= 0) + bwi_mac_set_promisc(mac, promisc); + } + + if (ifp->if_flags & IFF_UP) { + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + bwi_init(sc); + } else { + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + bwi_stop(sc); + } + break; + default: + error = ieee80211_ioctl(&sc->sc_ic, cmd, req); + break; + } + + if (error == ENETRESET) { + if (IS_RUNNING(ifp)) + bwi_init(sc); + error = 0; + } + BWI_UNLOCK(sc); + + return error; +#undef IS_RUNNING +} + +static void +bwi_start(struct ifnet *ifp) +{ + struct bwi_softc *sc = ifp->if_softc; + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[BWI_TX_DATA_RING]; + struct ieee80211_frame *wh; + struct ieee80211_node *ni; + struct ether_header *eh; + struct ieee80211_key *k; + struct mbuf *m; + int trans, idx; + + BWI_LOCK(sc); + if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) || + (ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + BWI_UNLOCK(sc); + return; + } + + trans = 0; + idx = tbd->tbd_idx; + + while (tbd->tbd_buf[idx].tb_mbuf == NULL) { + IF_DEQUEUE(&ic->ic_mgtq, m); + if (m != NULL) { + ni = (struct ieee80211_node *)m->m_pkthdr.rcvif; + m->m_pkthdr.rcvif = NULL; + } else { + if (ic->ic_state != IEEE80211_S_RUN) + break; + + IFQ_DRV_DEQUEUE(&ifp->if_snd, m); /* XXX: LOCK */ + if (m == NULL) + break; + + if (m->m_len < sizeof(*eh)) { + m = m_pullup(m, sizeof(*eh)); + if (m == NULL) { + ifp->if_oerrors++; + continue; + } + } + eh = mtod(m, struct ether_header *); + + ni = ieee80211_find_txnode(ic, eh->ether_dhost); + if (ni == NULL) { + m_freem(m); + ifp->if_oerrors++; + continue; + } + + /* TODO: PS */ + + BPF_MTAP(ifp, m); + + m = ieee80211_encap(ic, m, ni); + if (m == NULL) { + ieee80211_free_node(ni); + ifp->if_oerrors++; + continue; + } + } + + if (ic->ic_rawbpf != NULL) + bpf_mtap(ic->ic_rawbpf, m); + + wh = mtod(m, struct ieee80211_frame *); + if (wh->i_fc[1] & IEEE80211_FC1_WEP) { + k = ieee80211_crypto_encap(ic, ni, m); + if (k == NULL) { + ieee80211_free_node(ni); + m_freem(m); + ifp->if_oerrors++; + continue; + } + } + wh = NULL; /* Catch any invalid use */ + + if (bwi_encap(sc, idx, m, ni) != 0) { + /* 'm' is freed in bwi_encap() if we reach here */ + if (ni != NULL) + ieee80211_free_node(ni); + ifp->if_oerrors++; + continue; + } + + trans = 1; + tbd->tbd_used++; + idx = (idx + 1) % BWI_TX_NDESC; + + if (tbd->tbd_used + BWI_TX_NSPRDESC >= BWI_TX_NDESC) { + ifp->if_drv_flags |= IFF_DRV_OACTIVE; + break; + } + } + tbd->tbd_idx = idx; + + if (trans) + sc->sc_tx_timer = 5; + ifp->if_timer = 1; + BWI_UNLOCK(sc); +} + +static void +bwi_watchdog(struct ifnet *ifp) +{ + struct bwi_softc *sc = ifp->if_softc; + + BWI_LOCK(sc); + ifp->if_timer = 0; + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) && sc->sc_tx_timer) { + if (--sc->sc_tx_timer == 0) { + if_printf(ifp, "watchdog timeout\n"); + ifp->if_oerrors++; + /* TODO */ + } else { + ifp->if_timer = 1; + } + } + BWI_UNLOCK(sc); +} + +static void +bwi_stop(struct bwi_softc *sc) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp = ic->ic_ifp; + struct bwi_mac *mac; + int i, error, pwr_off = 0; + + BWI_LOCK(sc); + + DPRINTF(sc, "%s\n", __func__); + + ieee80211_new_state(ic, IEEE80211_S_INIT, -1); + + if (ifp->if_drv_flags & IFF_DRV_RUNNING) { + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + bwi_disable_intrs(sc, BWI_ALL_INTRS); + CSR_READ_4(sc, BWI_MAC_INTR_MASK); + bwi_mac_stop(mac); + } + + for (i = 0; i < sc->sc_nmac; ++i) { + struct bwi_regwin *old_rw; + + mac = &sc->sc_mac[i]; + if ((mac->mac_flags & BWI_MAC_F_INITED) == 0) + continue; + + error = bwi_regwin_switch(sc, &mac->mac_regwin, &old_rw); + if (error) + continue; + + bwi_mac_shutdown(mac); + pwr_off = 1; + + bwi_regwin_switch(sc, old_rw, NULL); + } + + if (pwr_off) + bwi_bbp_power_off(sc); + + sc->sc_tx_timer = 0; + ifp->if_timer = 0; + ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE); + BWI_UNLOCK(sc); +} + +void +bwi_intr(void *xsc) +{ + struct bwi_softc *sc = xsc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + uint32_t intr_status; + uint32_t txrx_intr_status[BWI_TXRX_NRING]; + int i, txrx_error; + + BWI_LOCK(sc); + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + BWI_UNLOCK(sc); + return; + } + /* + * Get interrupt status + */ + intr_status = CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + if (intr_status == 0xffffffff) { /* Not for us */ + BWI_UNLOCK(sc); + return; + } + +#if 0 + if_printf(ifp, "intr status 0x%08x\n", intr_status); +#endif + + intr_status &= CSR_READ_4(sc, BWI_MAC_INTR_MASK); + if (intr_status == 0) { /* Nothing is interesting */ + BWI_UNLOCK(sc); + return; + } + + txrx_error = 0; +#if 0 + if_printf(ifp, "TX/RX intr"); +#endif + for (i = 0; i < BWI_TXRX_NRING; ++i) { + uint32_t mask; + + if (BWI_TXRX_IS_RX(i)) + mask = BWI_TXRX_RX_INTRS; + else + mask = BWI_TXRX_TX_INTRS; + + txrx_intr_status[i] = + CSR_READ_4(sc, BWI_TXRX_INTR_STATUS(i)) & mask; + +#if 0 + printf(", %d 0x%08x", i, txrx_intr_status[i]); +#endif + + if (txrx_intr_status[i] & BWI_TXRX_INTR_ERROR) { + if_printf(ifp, "intr fatal TX/RX (%d) error 0x%08x\n", + i, txrx_intr_status[i]); + txrx_error = 1; + } + } +#if 0 + printf("\n"); +#endif + + /* + * Acknowledge interrupt + */ + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, intr_status); + + for (i = 0; i < BWI_TXRX_NRING; ++i) + CSR_WRITE_4(sc, BWI_TXRX_INTR_STATUS(i), txrx_intr_status[i]); + + /* Disable all interrupts */ + bwi_disable_intrs(sc, BWI_ALL_INTRS); + + if (intr_status & BWI_INTR_PHY_TXERR) + if_printf(ifp, "intr PHY TX error\n"); + + if (txrx_error) { + /* TODO: reset device */ + } + + if (intr_status & BWI_INTR_TBTT) { + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + bwi_mac_config_ps((struct bwi_mac *)sc->sc_cur_regwin); + } + + if (intr_status & BWI_INTR_EO_ATIM) + if_printf(ifp, "EO_ATIM\n"); + + if (intr_status & BWI_INTR_PMQ) { + for (;;) { + if ((CSR_READ_4(sc, BWI_MAC_PS_STATUS) & 0x8) == 0) + break; + } + CSR_WRITE_2(sc, BWI_MAC_PS_STATUS, 0x2); + } + + if (intr_status & BWI_INTR_NOISE) + if_printf(ifp, "intr noise\n"); + + if (txrx_intr_status[0] & BWI_TXRX_INTR_RX) + sc->sc_rxeof(sc); + + if (txrx_intr_status[3] & BWI_TXRX_INTR_RX) + sc->sc_txeof_status(sc); + + if (intr_status & BWI_INTR_TX_DONE) + bwi_txeof(sc); + + /* TODO:LED */ + + /* Re-enable interrupts */ + bwi_enable_intrs(sc, BWI_INIT_INTRS); + BWI_UNLOCK(sc); +} + +static void +bwi_scan_start(struct ieee80211com *ic) +{ +} + +static void +bwi_set_channel(struct ieee80211com *ic) +{ + struct ifnet *ifp = ic->ic_ifp; + struct bwi_softc *sc = ifp->if_softc; + int error; + + BWI_LOCK(sc); + error = bwi_set_chan(sc, ic->ic_curchan); + if (error) + if_printf(ifp, "can't set channel to %u\n", + ieee80211_chan2ieee(ic, ic->ic_curchan)); + BWI_UNLOCK(sc); +} + +static void +bwi_scan_end(struct ieee80211com *ic) +{ +} + +static int +bwi_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg) +{ + struct ifnet *ifp = ic->ic_ifp; + struct bwi_softc *sc = ifp->if_softc; + struct bwi_mac *mac; + struct ieee80211_node *ni; + int error; + + BWI_LOCK(sc); + + callout_stop(&sc->sc_calib_ch); + callout_stop(&sc->sc_amrr_ch); + + bwi_led_newstate(sc, nstate); + + if (nstate == IEEE80211_S_INIT) + goto back; + + if (ic->ic_opmode == IEEE80211_M_MONITOR) { + /* Nothing to do */ + } else if (nstate == IEEE80211_S_RUN) { + ni = ic->ic_bss; + + bwi_set_bssid(sc, ic->ic_bss->ni_bssid); + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + /* Initial TX power calibration */ + bwi_mac_calibrate_txpower(mac); + + if (ic->ic_opmode == IEEE80211_M_STA) { + /* fake a join to init the tx rate */ + bwi_newassoc(ni, 1); + } + + if (ic->ic_opmode != IEEE80211_M_MONITOR) { + /* start automatic rate control timer */ + if (ic->ic_fixed_rate == IEEE80211_FIXED_RATE_NONE) + callout_reset(&sc->sc_amrr_ch, hz / 2, + bwi_amrr_timeout, sc); + } + } else { + bwi_set_bssid(sc, bwi_zero_addr); + } + +back: + error = sc->sc_newstate(ic, nstate, arg); + + if (nstate == IEEE80211_S_RUN) { + /* XXX 15 seconds */ + callout_reset(&sc->sc_calib_ch, hz * 15, bwi_calibrate, sc); + } + BWI_UNLOCK(sc); + + return error; +} + +/* ARGUSED */ +static struct ieee80211_node * +bwi_node_alloc(struct ieee80211_node_table *nt __unused) +{ + struct bwi_node *bn; + + bn = malloc(sizeof(struct bwi_node), M_80211_NODE, M_NOWAIT | M_ZERO); + return bn != NULL ? &bn->ni : NULL; +} + +static void +bwi_newassoc(struct ieee80211_node *ni, int isnew) +{ + struct bwi_softc *sc = ni->ni_ic->ic_ifp->if_softc; + int i; + + ieee80211_amrr_node_init(&sc->sc_amrr, &((struct bwi_node *)ni)->amn); + + /* set rate to some reasonable initial value */ + for (i = ni->ni_rates.rs_nrates - 1; + i > 0 && (ni->ni_rates.rs_rates[i] & IEEE80211_RATE_VAL) > 72; + i--); + ni->ni_txrate = i; +} + +static void +bwi_iter_func(void *arg, struct ieee80211_node *ni) +{ + struct bwi_softc *sc = arg; + struct bwi_node *bn = (struct bwi_node *)ni; + + ieee80211_amrr_choose(&sc->sc_amrr, ni, &bn->amn); +} + +static void +bwi_amrr_timeout(void *arg) +{ + struct bwi_softc *sc = arg; + struct ieee80211com *ic = &sc->sc_ic; + + BWI_LOCK(sc); + if (ic->ic_opmode == IEEE80211_M_STA) + bwi_iter_func(sc, ic->ic_bss); + else + ieee80211_iterate_nodes(&ic->ic_sta, bwi_iter_func, sc); + BWI_UNLOCK(sc); + + callout_reset(&sc->sc_amrr_ch, hz / 2, bwi_amrr_timeout, sc); +} + +static int +bwi_media_change(struct ifnet *ifp) +{ +#define IS_RUNNING(ifp) \ + ((ifp->if_flags & IFF_UP) && (ifp->if_drv_flags & IFF_DRV_RUNNING)) + struct bwi_softc *sc = ifp->if_softc; + + BWI_LOCK(sc); + if (ieee80211_media_change(ifp) == ENETRESET && IS_RUNNING(ifp)) + bwi_init(ifp->if_softc); + BWI_UNLOCK(sc); + + return 0; +#undef IS_RUNNING +} + +static int +bwi_dma_alloc(struct bwi_softc *sc) +{ + int error, i, has_txstats; + bus_addr_t lowaddr = 0; + bus_size_t tx_ring_sz, rx_ring_sz, desc_sz = 0; + uint32_t txrx_ctrl_step = 0; + + has_txstats = 0; + for (i = 0; i < sc->sc_nmac; ++i) { + if (sc->sc_mac[i].mac_flags & BWI_MAC_F_HAS_TXSTATS) { + has_txstats = 1; + break; + } + } + + switch (sc->sc_bus_space) { + case BWI_BUS_SPACE_30BIT: + case BWI_BUS_SPACE_32BIT: + if (sc->sc_bus_space == BWI_BUS_SPACE_30BIT) + lowaddr = BWI_BUS_SPACE_MAXADDR; + else + lowaddr = BUS_SPACE_MAXADDR_32BIT; + desc_sz = sizeof(struct bwi_desc32); + txrx_ctrl_step = 0x20; + + sc->sc_init_tx_ring = bwi_init_tx_ring32; + sc->sc_free_tx_ring = bwi_free_tx_ring32; + sc->sc_init_rx_ring = bwi_init_rx_ring32; + sc->sc_free_rx_ring = bwi_free_rx_ring32; + sc->sc_setup_rxdesc = bwi_setup_rx_desc32; + sc->sc_setup_txdesc = bwi_setup_tx_desc32; + sc->sc_rxeof = bwi_rxeof32; + sc->sc_start_tx = bwi_start_tx32; + if (has_txstats) { + sc->sc_init_txstats = bwi_init_txstats32; + sc->sc_free_txstats = bwi_free_txstats32; + sc->sc_txeof_status = bwi_txeof_status32; + } + break; + + case BWI_BUS_SPACE_64BIT: + lowaddr = BUS_SPACE_MAXADDR; /* XXX */ + desc_sz = sizeof(struct bwi_desc64); + txrx_ctrl_step = 0x40; + + sc->sc_init_tx_ring = bwi_init_tx_ring64; + sc->sc_free_tx_ring = bwi_free_tx_ring64; + sc->sc_init_rx_ring = bwi_init_rx_ring64; + sc->sc_free_rx_ring = bwi_free_rx_ring64; + sc->sc_setup_rxdesc = bwi_setup_rx_desc64; + sc->sc_setup_txdesc = bwi_setup_tx_desc64; + sc->sc_rxeof = bwi_rxeof64; + sc->sc_start_tx = bwi_start_tx64; + if (has_txstats) { + sc->sc_init_txstats = bwi_init_txstats64; + sc->sc_free_txstats = bwi_free_txstats64; + sc->sc_txeof_status = bwi_txeof_status64; + } + break; + } + + KASSERT(lowaddr != 0, ("lowaddr zero")); + KASSERT(desc_sz != 0, ("desc_sz zero")); + KASSERT(txrx_ctrl_step != 0, ("txrx_ctrl_step zero")); + + tx_ring_sz = roundup(desc_sz * BWI_TX_NDESC, BWI_RING_ALIGN); + rx_ring_sz = roundup(desc_sz * BWI_RX_NDESC, BWI_RING_ALIGN); + + /* + * Create top level DMA tag + */ + error = bus_dma_tag_create(bus_get_dma_tag(sc->sc_dev), /* parent */ + BWI_ALIGN, 0, /* alignment, bounds */ + lowaddr, /* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + MAXBSIZE, /* maxsize */ + BUS_SPACE_UNRESTRICTED, /* nsegments */ + BUS_SPACE_MAXSIZE_32BIT, /* maxsegsize */ + BUS_DMA_ALLOCNOW, /* flags */ + NULL, NULL, /* lockfunc, lockarg */ + &sc->sc_parent_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create parent DMA tag\n"); + return error; + } + +#define TXRX_CTRL(idx) (BWI_TXRX_CTRL_BASE + (idx) * txrx_ctrl_step) + + /* + * Create TX ring DMA stuffs + */ + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_RING_ALIGN, 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + tx_ring_sz, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &sc->sc_txring_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create TX ring DMA tag\n"); + return error; + } + + for (i = 0; i < BWI_TX_NRING; ++i) { + error = bwi_dma_ring_alloc(sc, sc->sc_txring_dtag, + &sc->sc_tx_rdata[i], tx_ring_sz, + TXRX_CTRL(i)); + if (error) { + device_printf(sc->sc_dev, "%dth TX ring " + "DMA alloc failed\n", i); + return error; + } + } + + /* + * Create RX ring DMA stuffs + */ + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_RING_ALIGN, 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + rx_ring_sz, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &sc->sc_rxring_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create RX ring DMA tag\n"); + return error; + } + + error = bwi_dma_ring_alloc(sc, sc->sc_rxring_dtag, &sc->sc_rx_rdata, + rx_ring_sz, TXRX_CTRL(0)); + if (error) { + device_printf(sc->sc_dev, "RX ring DMA alloc failed\n"); + return error; + } + + if (has_txstats) { + error = bwi_dma_txstats_alloc(sc, TXRX_CTRL(3), desc_sz); + if (error) { + device_printf(sc->sc_dev, + "TX stats DMA alloc failed\n"); + return error; + } + } + +#undef TXRX_CTRL + + return bwi_dma_mbuf_create(sc); +} + +static void +bwi_dma_free(struct bwi_softc *sc) +{ + if (sc->sc_txring_dtag != NULL) { + int i; + + for (i = 0; i < BWI_TX_NRING; ++i) { + struct bwi_ring_data *rd = &sc->sc_tx_rdata[i]; + + if (rd->rdata_desc != NULL) { + bus_dmamap_unload(sc->sc_txring_dtag, + rd->rdata_dmap); + bus_dmamem_free(sc->sc_txring_dtag, + rd->rdata_desc, + rd->rdata_dmap); + } + } + bus_dma_tag_destroy(sc->sc_txring_dtag); + } + + if (sc->sc_rxring_dtag != NULL) { + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + + if (rd->rdata_desc != NULL) { + bus_dmamap_unload(sc->sc_rxring_dtag, rd->rdata_dmap); + bus_dmamem_free(sc->sc_rxring_dtag, rd->rdata_desc, + rd->rdata_dmap); + } + bus_dma_tag_destroy(sc->sc_rxring_dtag); + } + + bwi_dma_txstats_free(sc); + bwi_dma_mbuf_destroy(sc, BWI_TX_NRING, 1); + + if (sc->sc_parent_dtag != NULL) + bus_dma_tag_destroy(sc->sc_parent_dtag); +} + +static int +bwi_dma_ring_alloc(struct bwi_softc *sc, bus_dma_tag_t dtag, + struct bwi_ring_data *rd, bus_size_t size, + uint32_t txrx_ctrl) +{ + int error; + + error = bus_dmamem_alloc(dtag, &rd->rdata_desc, + BUS_DMA_WAITOK | BUS_DMA_ZERO, + &rd->rdata_dmap); + if (error) { + device_printf(sc->sc_dev, "can't allocate DMA mem\n"); + return error; + } + + error = bus_dmamap_load(dtag, rd->rdata_dmap, rd->rdata_desc, size, + bwi_dma_ring_addr, &rd->rdata_paddr, + BUS_DMA_WAITOK); + if (error) { + device_printf(sc->sc_dev, "can't load DMA mem\n"); + bus_dmamem_free(dtag, rd->rdata_desc, rd->rdata_dmap); + rd->rdata_desc = NULL; + return error; + } + + rd->rdata_txrx_ctrl = txrx_ctrl; + return 0; +} + +static int +bwi_dma_txstats_alloc(struct bwi_softc *sc, uint32_t ctrl_base, + bus_size_t desc_sz) +{ + struct bwi_txstats_data *st; + bus_size_t dma_size; + int error; + + st = malloc(sizeof(*st), M_DEVBUF, M_WAITOK | M_ZERO); + sc->sc_txstats = st; + + /* + * Create TX stats descriptor DMA stuffs + */ + dma_size = roundup(desc_sz * BWI_TXSTATS_NDESC, BWI_RING_ALIGN); + + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_RING_ALIGN, + 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + dma_size, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &st->stats_ring_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create txstats ring " + "DMA tag\n"); + return error; + } + + error = bus_dmamem_alloc(st->stats_ring_dtag, &st->stats_ring, + BUS_DMA_WAITOK | BUS_DMA_ZERO, + &st->stats_ring_dmap); + if (error) { + device_printf(sc->sc_dev, "can't allocate txstats ring " + "DMA mem\n"); + bus_dma_tag_destroy(st->stats_ring_dtag); + st->stats_ring_dtag = NULL; + return error; + } + + error = bus_dmamap_load(st->stats_ring_dtag, st->stats_ring_dmap, + st->stats_ring, dma_size, + bwi_dma_ring_addr, &st->stats_ring_paddr, + BUS_DMA_WAITOK); + if (error) { + device_printf(sc->sc_dev, "can't load txstats ring DMA mem\n"); + bus_dmamem_free(st->stats_ring_dtag, st->stats_ring, + st->stats_ring_dmap); + bus_dma_tag_destroy(st->stats_ring_dtag); + st->stats_ring_dtag = NULL; + return error; + } + + /* + * Create TX stats DMA stuffs + */ + dma_size = roundup(sizeof(struct bwi_txstats) * BWI_TXSTATS_NDESC, + BWI_ALIGN); + + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_ALIGN, + 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + dma_size, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &st->stats_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create txstats DMA tag\n"); + return error; + } + + error = bus_dmamem_alloc(st->stats_dtag, (void **)&st->stats, + BUS_DMA_WAITOK | BUS_DMA_ZERO, + &st->stats_dmap); + if (error) { + device_printf(sc->sc_dev, "can't allocate txstats DMA mem\n"); + bus_dma_tag_destroy(st->stats_dtag); + st->stats_dtag = NULL; + return error; + } + + error = bus_dmamap_load(st->stats_dtag, st->stats_dmap, st->stats, + dma_size, bwi_dma_ring_addr, &st->stats_paddr, + BUS_DMA_WAITOK); + if (error) { + device_printf(sc->sc_dev, "can't load txstats DMA mem\n"); + bus_dmamem_free(st->stats_dtag, st->stats, st->stats_dmap); + bus_dma_tag_destroy(st->stats_dtag); + st->stats_dtag = NULL; + return error; + } + + st->stats_ctrl_base = ctrl_base; + return 0; +} + +static void +bwi_dma_txstats_free(struct bwi_softc *sc) +{ + struct bwi_txstats_data *st; + + if (sc->sc_txstats == NULL) + return; + st = sc->sc_txstats; + + if (st->stats_ring_dtag != NULL) { + bus_dmamap_unload(st->stats_ring_dtag, st->stats_ring_dmap); + bus_dmamem_free(st->stats_ring_dtag, st->stats_ring, + st->stats_ring_dmap); + bus_dma_tag_destroy(st->stats_ring_dtag); + } + + if (st->stats_dtag != NULL) { + bus_dmamap_unload(st->stats_dtag, st->stats_dmap); + bus_dmamem_free(st->stats_dtag, st->stats, st->stats_dmap); + bus_dma_tag_destroy(st->stats_dtag); + } + + free(st, M_DEVBUF); +} + +static void +bwi_dma_ring_addr(void *arg, bus_dma_segment_t *seg, int nseg, int error) +{ + KASSERT(nseg == 1, ("too many segments\n")); + *((bus_addr_t *)arg) = seg->ds_addr; +} + +static int +bwi_dma_mbuf_create(struct bwi_softc *sc) +{ + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + int i, j, k, ntx, error; + + /* + * Create TX/RX mbuf DMA tag + */ + error = bus_dma_tag_create(sc->sc_parent_dtag, + 1, + 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + MCLBYTES, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &sc->sc_buf_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create mbuf DMA tag\n"); + return error; + } + + ntx = 0; + + /* + * Create TX mbuf DMA map + */ + for (i = 0; i < BWI_TX_NRING; ++i) { + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[i]; + + for (j = 0; j < BWI_TX_NDESC; ++j) { + error = bus_dmamap_create(sc->sc_buf_dtag, 0, + &tbd->tbd_buf[j].tb_dmap); + if (error) { + device_printf(sc->sc_dev, "can't create " + "%dth tbd, %dth DMA map\n", i, j); + + ntx = i; + for (k = 0; k < j; ++k) { + bus_dmamap_destroy(sc->sc_buf_dtag, + tbd->tbd_buf[k].tb_dmap); + } + goto fail; + } + } + } + ntx = BWI_TX_NRING; + + /* + * Create RX mbuf DMA map and a spare DMA map + */ + error = bus_dmamap_create(sc->sc_buf_dtag, 0, + &rbd->rbd_tmp_dmap); + if (error) { + device_printf(sc->sc_dev, + "can't create spare RX buf DMA map\n"); + goto fail; + } + + for (j = 0; j < BWI_RX_NDESC; ++j) { + error = bus_dmamap_create(sc->sc_buf_dtag, 0, + &rbd->rbd_buf[j].rb_dmap); + if (error) { + device_printf(sc->sc_dev, "can't create %dth " + "RX buf DMA map\n", j); + + for (k = 0; k < j; ++k) { + bus_dmamap_destroy(sc->sc_buf_dtag, + rbd->rbd_buf[j].rb_dmap); + } + bus_dmamap_destroy(sc->sc_buf_dtag, + rbd->rbd_tmp_dmap); + goto fail; + } + } + + return 0; +fail: + bwi_dma_mbuf_destroy(sc, ntx, 0); + return error; +} + +static void +bwi_dma_mbuf_destroy(struct bwi_softc *sc, int ntx, int nrx) +{ + int i, j; + + if (sc->sc_buf_dtag == NULL) + return; + + for (i = 0; i < ntx; ++i) { + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[i]; + + for (j = 0; j < BWI_TX_NDESC; ++j) { + struct bwi_txbuf *tb = &tbd->tbd_buf[j]; + + if (tb->tb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, + tb->tb_dmap); + m_freem(tb->tb_mbuf); + } + if (tb->tb_ni != NULL) + ieee80211_free_node(tb->tb_ni); + bus_dmamap_destroy(sc->sc_buf_dtag, tb->tb_dmap); + } + } + + if (nrx) { + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + + bus_dmamap_destroy(sc->sc_buf_dtag, rbd->rbd_tmp_dmap); + for (j = 0; j < BWI_RX_NDESC; ++j) { + struct bwi_rxbuf *rb = &rbd->rbd_buf[j]; + + if (rb->rb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, + rb->rb_dmap); + m_freem(rb->rb_mbuf); + } + bus_dmamap_destroy(sc->sc_buf_dtag, rb->rb_dmap); + } + } + + bus_dma_tag_destroy(sc->sc_buf_dtag); + sc->sc_buf_dtag = NULL; +} + +static void +bwi_enable_intrs(struct bwi_softc *sc, uint32_t enable_intrs) +{ + CSR_SETBITS_4(sc, BWI_MAC_INTR_MASK, enable_intrs); +} + +static void +bwi_disable_intrs(struct bwi_softc *sc, uint32_t disable_intrs) +{ + CSR_CLRBITS_4(sc, BWI_MAC_INTR_MASK, disable_intrs); +} + +static int +bwi_init_tx_ring32(struct bwi_softc *sc, int ring_idx) +{ + struct bwi_ring_data *rd; + struct bwi_txbuf_data *tbd; + uint32_t val, addr_hi, addr_lo; + + KASSERT(ring_idx < BWI_TX_NRING, ("ring_idx %d", ring_idx)); + rd = &sc->sc_tx_rdata[ring_idx]; + tbd = &sc->sc_tx_bdata[ring_idx]; + + tbd->tbd_idx = 0; + tbd->tbd_used = 0; + + bzero(rd->rdata_desc, sizeof(struct bwi_desc32) * BWI_TX_NDESC); + bus_dmamap_sync(sc->sc_txring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); + + addr_lo = __SHIFTOUT(rd->rdata_paddr, BWI_TXRX32_RINGINFO_ADDR_MASK); + addr_hi = __SHIFTOUT(rd->rdata_paddr, BWI_TXRX32_RINGINFO_FUNC_MASK); + + val = __SHIFTIN(addr_lo, BWI_TXRX32_RINGINFO_ADDR_MASK) | + __SHIFTIN(BWI_TXRX32_RINGINFO_FUNC_TXRX, + BWI_TXRX32_RINGINFO_FUNC_MASK); + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_RINGINFO, val); + + val = __SHIFTIN(addr_hi, BWI_TXRX32_CTRL_ADDRHI_MASK) | + BWI_TXRX32_CTRL_ENABLE; + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_CTRL, val); + + return 0; +} + +static void +bwi_init_rxdesc_ring32(struct bwi_softc *sc, uint32_t ctrl_base, + bus_addr_t paddr, int hdr_size, int ndesc) +{ + uint32_t val, addr_hi, addr_lo; + + addr_lo = __SHIFTOUT(paddr, BWI_TXRX32_RINGINFO_ADDR_MASK); + addr_hi = __SHIFTOUT(paddr, BWI_TXRX32_RINGINFO_FUNC_MASK); + + val = __SHIFTIN(addr_lo, BWI_TXRX32_RINGINFO_ADDR_MASK) | + __SHIFTIN(BWI_TXRX32_RINGINFO_FUNC_TXRX, + BWI_TXRX32_RINGINFO_FUNC_MASK); + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_RINGINFO, val); + + val = __SHIFTIN(hdr_size, BWI_RX32_CTRL_HDRSZ_MASK) | + __SHIFTIN(addr_hi, BWI_TXRX32_CTRL_ADDRHI_MASK) | + BWI_TXRX32_CTRL_ENABLE; + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_CTRL, val); + + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_INDEX, + (ndesc - 1) * sizeof(struct bwi_desc32)); +} + +static int +bwi_init_rx_ring32(struct bwi_softc *sc) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + int i, error; + + sc->sc_rx_bdata.rbd_idx = 0; + + for (i = 0; i < BWI_RX_NDESC; ++i) { + error = bwi_newbuf(sc, i, 1); + if (error) { + device_printf(sc->sc_dev, + "can't allocate %dth RX buffer\n", i); + return error; + } + } + bus_dmamap_sync(sc->sc_rxring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); + + bwi_init_rxdesc_ring32(sc, rd->rdata_txrx_ctrl, rd->rdata_paddr, + sizeof(struct bwi_rxbuf_hdr), BWI_RX_NDESC); + return 0; +} + +static int +bwi_init_txstats32(struct bwi_softc *sc) +{ + struct bwi_txstats_data *st = sc->sc_txstats; + bus_addr_t stats_paddr; + int i; + + bzero(st->stats, BWI_TXSTATS_NDESC * sizeof(struct bwi_txstats)); + bus_dmamap_sync(st->stats_dtag, st->stats_dmap, BUS_DMASYNC_PREWRITE); + + st->stats_idx = 0; + + stats_paddr = st->stats_paddr; + for (i = 0; i < BWI_TXSTATS_NDESC; ++i) { + bwi_setup_desc32(sc, st->stats_ring, BWI_TXSTATS_NDESC, i, + stats_paddr, sizeof(struct bwi_txstats), 0); + stats_paddr += sizeof(struct bwi_txstats); + } + bus_dmamap_sync(st->stats_ring_dtag, st->stats_ring_dmap, + BUS_DMASYNC_PREWRITE); + + bwi_init_rxdesc_ring32(sc, st->stats_ctrl_base, + st->stats_ring_paddr, 0, BWI_TXSTATS_NDESC); + return 0; +} + +static void +bwi_setup_rx_desc32(struct bwi_softc *sc, int buf_idx, bus_addr_t paddr, + int buf_len) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + + KASSERT(buf_idx < BWI_RX_NDESC, ("buf_idx %d", buf_idx)); + bwi_setup_desc32(sc, rd->rdata_desc, BWI_RX_NDESC, buf_idx, + paddr, buf_len, 0); +} + +static void +bwi_setup_tx_desc32(struct bwi_softc *sc, struct bwi_ring_data *rd, + int buf_idx, bus_addr_t paddr, int buf_len) +{ + KASSERT(buf_idx < BWI_TX_NDESC, ("buf_idx %d", buf_idx)); + bwi_setup_desc32(sc, rd->rdata_desc, BWI_TX_NDESC, buf_idx, + paddr, buf_len, 1); +} + +static int +bwi_init_tx_ring64(struct bwi_softc *sc, int ring_idx) +{ + /* TODO:64 */ + return EOPNOTSUPP; +} + +static int +bwi_init_rx_ring64(struct bwi_softc *sc) +{ + /* TODO:64 */ + return EOPNOTSUPP; +} + +static int +bwi_init_txstats64(struct bwi_softc *sc) +{ + /* TODO:64 */ + return EOPNOTSUPP; +} + +static void +bwi_setup_rx_desc64(struct bwi_softc *sc, int buf_idx, bus_addr_t paddr, + int buf_len) +{ + /* TODO:64 */ +} + +static void +bwi_setup_tx_desc64(struct bwi_softc *sc, struct bwi_ring_data *rd, + int buf_idx, bus_addr_t paddr, int buf_len) +{ + /* TODO:64 */ +} + +static void +bwi_dma_buf_addr(void *arg, bus_dma_segment_t *seg, int nseg, + bus_size_t mapsz __unused, int error) +{ + if (!error) { + KASSERT(nseg == 1, ("too many segments(%d)\n", nseg)); + *((bus_addr_t *)arg) = seg->ds_addr; + } +} + +static int +bwi_newbuf(struct bwi_softc *sc, int buf_idx, int init) +{ + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + struct bwi_rxbuf *rxbuf = &rbd->rbd_buf[buf_idx]; + struct bwi_rxbuf_hdr *hdr; + bus_dmamap_t map; + bus_addr_t paddr; + struct mbuf *m; + int error; + + KASSERT(buf_idx < BWI_RX_NDESC, ("buf_idx %d", buf_idx)); + + m = m_getcl(init ? M_WAIT : M_DONTWAIT, MT_DATA, M_PKTHDR); + if (m == NULL) { + error = ENOBUFS; + + /* + * If the NIC is up and running, we need to: + * - Clear RX buffer's header. + * - Restore RX descriptor settings. + */ + if (init) + return error; + else + goto back; + } + m->m_len = m->m_pkthdr.len = MCLBYTES; + + /* + * Try to load RX buf into temporary DMA map + */ + error = bus_dmamap_load_mbuf(sc->sc_buf_dtag, rbd->rbd_tmp_dmap, m, + bwi_dma_buf_addr, &paddr, + init ? BUS_DMA_WAITOK : BUS_DMA_NOWAIT); + if (error) { + m_freem(m); + + /* + * See the comment above + */ + if (init) + return error; + else + goto back; + } + + if (!init) + bus_dmamap_unload(sc->sc_buf_dtag, rxbuf->rb_dmap); + rxbuf->rb_mbuf = m; + rxbuf->rb_paddr = paddr; + + /* + * Swap RX buf's DMA map with the loaded temporary one + */ + map = rxbuf->rb_dmap; + rxbuf->rb_dmap = rbd->rbd_tmp_dmap; + rbd->rbd_tmp_dmap = map; + +back: + /* + * Clear RX buf header + */ + hdr = mtod(rxbuf->rb_mbuf, struct bwi_rxbuf_hdr *); + bzero(hdr, sizeof(*hdr)); + bus_dmamap_sync(sc->sc_buf_dtag, rxbuf->rb_dmap, BUS_DMASYNC_PREWRITE); + + /* + * Setup RX buf descriptor + */ + sc->sc_setup_rxdesc(sc, buf_idx, rxbuf->rb_paddr, + rxbuf->rb_mbuf->m_len - sizeof(*hdr)); + return error; +} + +static void +bwi_set_addr_filter(struct bwi_softc *sc, uint16_t addr_ofs, + const uint8_t *addr) +{ + int i; + + CSR_WRITE_2(sc, BWI_ADDR_FILTER_CTRL, + BWI_ADDR_FILTER_CTRL_SET | addr_ofs); + + for (i = 0; i < (IEEE80211_ADDR_LEN / 2); ++i) { + uint16_t addr_val; + + addr_val = (uint16_t)addr[i * 2] | + (((uint16_t)addr[(i * 2) + 1]) << 8); + CSR_WRITE_2(sc, BWI_ADDR_FILTER_DATA, addr_val); + } +} + +static int +bwi_set_chan(struct bwi_softc *sc, struct ieee80211_channel *c) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_mac *mac; + uint16_t flags; + u_int chan; + + BWI_LOCK(sc); + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + chan = ieee80211_chan2ieee(ic, c); + + bwi_rf_set_chan(mac, chan, 0); + + /* + * Setup radio tap channel freq and flags + */ + if (IEEE80211_IS_CHAN_G(c)) + flags = IEEE80211_CHAN_G; + else + flags = IEEE80211_CHAN_B; + + sc->sc_tx_th.wt_chan_freq = sc->sc_rx_th.wr_chan_freq = + htole16(c->ic_freq); + sc->sc_tx_th.wt_chan_flags = sc->sc_rx_th.wr_chan_flags = + htole16(flags); + + BWI_UNLOCK(sc); + + return 0; +} + +static void +bwi_rxeof(struct bwi_softc *sc, int end_idx) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp = ic->ic_ifp; + int idx; + + idx = rbd->rbd_idx; + while (idx != end_idx) { + struct bwi_rxbuf *rb = &rbd->rbd_buf[idx]; + struct bwi_rxbuf_hdr *hdr; + struct ieee80211_frame_min *wh; + struct ieee80211_node *ni; + struct mbuf *m; + const uint8_t *plcp; + uint16_t flags2; + int buflen, wh_ofs, hdr_extra, rssi; + + m = rb->rb_mbuf; + bus_dmamap_sync(sc->sc_buf_dtag, rb->rb_dmap, + BUS_DMASYNC_POSTREAD); + + if (bwi_newbuf(sc, idx, 0)) { + ifp->if_ierrors++; + goto next; + } + + hdr = mtod(m, struct bwi_rxbuf_hdr *); + flags2 = le16toh(hdr->rxh_flags2); + + hdr_extra = 0; + if (flags2 & BWI_RXH_F2_TYPE2FRAME) + hdr_extra = 2; + wh_ofs = hdr_extra + 6; /* XXX magic number */ + + buflen = le16toh(hdr->rxh_buflen); + if (buflen < BWI_FRAME_MIN_LEN(wh_ofs)) { + if_printf(ifp, "zero length data, hdr_extra %d\n", + hdr_extra); + ifp->if_ierrors++; + m_freem(m); + goto next; + } + + plcp = ((const uint8_t *)(hdr + 1) + hdr_extra); + rssi = bwi_calc_rssi(sc, hdr); + + m->m_pkthdr.rcvif = ifp; + m->m_len = m->m_pkthdr.len = buflen + sizeof(*hdr); + m_adj(m, sizeof(*hdr) + wh_ofs); + + /* RX radio tap */ + if (sc->sc_drvbpf != NULL) + bwi_rx_radiotap(sc, m, hdr, plcp, rssi); + + m_adj(m, -IEEE80211_CRC_LEN); + + wh = mtod(m, struct ieee80211_frame_min *); + ni = ieee80211_find_rxnode(ic, wh); + + ieee80211_input(ic, m, ni, rssi - BWI_NOISE_FLOOR, + BWI_NOISE_FLOOR, le16toh(hdr->rxh_tsf)); + ieee80211_free_node(ni); +next: + idx = (idx + 1) % BWI_RX_NDESC; + } + + rbd->rbd_idx = idx; + bus_dmamap_sync(sc->sc_rxring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); +} + +static void +bwi_rxeof32(struct bwi_softc *sc) +{ + uint32_t val, rx_ctrl; + int end_idx; + + rx_ctrl = sc->sc_rx_rdata.rdata_txrx_ctrl; + + val = CSR_READ_4(sc, rx_ctrl + BWI_RX32_STATUS); + end_idx = __SHIFTOUT(val, BWI_RX32_STATUS_INDEX_MASK) / + sizeof(struct bwi_desc32); + + bwi_rxeof(sc, end_idx); + + CSR_WRITE_4(sc, rx_ctrl + BWI_RX32_INDEX, + end_idx * sizeof(struct bwi_desc32)); +} + +static void +bwi_rxeof64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +bwi_reset_rx_ring32(struct bwi_softc *sc, uint32_t rx_ctrl) +{ + int i; + + CSR_WRITE_4(sc, rx_ctrl + BWI_RX32_CTRL, 0); + +#define NRETRY 10 + + for (i = 0; i < NRETRY; ++i) { + uint32_t status; + + status = CSR_READ_4(sc, rx_ctrl + BWI_RX32_STATUS); + if (__SHIFTOUT(status, BWI_RX32_STATUS_STATE_MASK) == + BWI_RX32_STATUS_STATE_DISABLED) + break; + + DELAY(1000); + } + if (i == NRETRY) + device_printf(sc->sc_dev, "reset rx ring timedout\n"); + +#undef NRETRY + + CSR_WRITE_4(sc, rx_ctrl + BWI_RX32_RINGINFO, 0); +} + +static void +bwi_free_txstats32(struct bwi_softc *sc) +{ + bwi_reset_rx_ring32(sc, sc->sc_txstats->stats_ctrl_base); +} + +static void +bwi_free_rx_ring32(struct bwi_softc *sc) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + int i; + + bwi_reset_rx_ring32(sc, rd->rdata_txrx_ctrl); + + for (i = 0; i < BWI_RX_NDESC; ++i) { + struct bwi_rxbuf *rb = &rbd->rbd_buf[i]; + + if (rb->rb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, rb->rb_dmap); + m_freem(rb->rb_mbuf); + rb->rb_mbuf = NULL; + } + } +} + +static void +bwi_free_tx_ring32(struct bwi_softc *sc, int ring_idx) +{ + struct bwi_ring_data *rd; + struct bwi_txbuf_data *tbd; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + uint32_t state, val; + int i; + + KASSERT(ring_idx < BWI_TX_NRING, ("ring_idx %d", ring_idx)); + rd = &sc->sc_tx_rdata[ring_idx]; + tbd = &sc->sc_tx_bdata[ring_idx]; + +#define NRETRY 10 + + for (i = 0; i < NRETRY; ++i) { + val = CSR_READ_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_STATUS); + state = __SHIFTOUT(val, BWI_TX32_STATUS_STATE_MASK); + if (state == BWI_TX32_STATUS_STATE_DISABLED || + state == BWI_TX32_STATUS_STATE_IDLE || + state == BWI_TX32_STATUS_STATE_STOPPED) + break; + + DELAY(1000); + } + if (i == NRETRY) { + if_printf(ifp, "wait for TX ring(%d) stable timed out\n", + ring_idx); + } + + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_CTRL, 0); + for (i = 0; i < NRETRY; ++i) { + val = CSR_READ_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_STATUS); + state = __SHIFTOUT(val, BWI_TX32_STATUS_STATE_MASK); + if (state == BWI_TX32_STATUS_STATE_DISABLED) + break; + + DELAY(1000); + } + if (i == NRETRY) + if_printf(ifp, "reset TX ring (%d) timed out\n", ring_idx); + +#undef NRETRY + + DELAY(1000); + + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_RINGINFO, 0); + + for (i = 0; i < BWI_TX_NDESC; ++i) { + struct bwi_txbuf *tb = &tbd->tbd_buf[i]; + + if (tb->tb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, tb->tb_dmap); + m_freem(tb->tb_mbuf); + tb->tb_mbuf = NULL; + } + if (tb->tb_ni != NULL) { + ieee80211_free_node(tb->tb_ni); + tb->tb_ni = NULL; + } + } +} + +static void +bwi_free_txstats64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +bwi_free_rx_ring64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +bwi_free_tx_ring64(struct bwi_softc *sc, int ring_idx) +{ + /* TODO:64 */ +} + +/* XXX does not belong here */ +uint8_t +bwi_rate2plcp(uint8_t rate) +{ + rate &= IEEE80211_RATE_VAL; + + switch (rate) { + case 2: return 0xa; + case 4: return 0x14; + case 11: return 0x37; + case 22: return 0x6e; + case 44: return 0xdc; + + case 12: return 0xb; + case 18: return 0xf; + case 24: return 0xa; + case 36: return 0xe; + case 48: return 0x9; + case 72: return 0xd; + case 96: return 0x8; + case 108: return 0xc; + + default: + panic("unsupported rate %u\n", rate); + } +} + +/* XXX does not belong here */ +#define IEEE80211_OFDM_PLCP_RATE_MASK __BITS(3, 0) +#define IEEE80211_OFDM_PLCP_LEN_MASK __BITS(16, 5) + +static __inline void +bwi_ofdm_plcp_header(uint32_t *plcp0, int pkt_len, uint8_t rate) +{ + uint32_t plcp; + + plcp = __SHIFTIN(bwi_rate2plcp(rate), IEEE80211_OFDM_PLCP_RATE_MASK) | + __SHIFTIN(pkt_len, IEEE80211_OFDM_PLCP_LEN_MASK); + *plcp0 = htole32(plcp); +} + +#define IEEE80211_DS_PLCP_SERVICE_LOCKED 0x04 +#define IEEE80211_DS_PLCL_SERVICE_PBCC 0x08 +#define IEEE80211_DS_PLCP_SERVICE_LENEXT5 0x20 +#define IEEE80211_DS_PLCP_SERVICE_LENEXT6 0x40 +#define IEEE80211_DS_PLCP_SERVICE_LENEXT7 0x80 + +static __inline void +bwi_ds_plcp_header(struct ieee80211_ds_plcp_hdr *plcp, int pkt_len, + uint8_t rate) +{ + int len, service, pkt_bitlen; + + pkt_bitlen = pkt_len * NBBY; + len = howmany(pkt_bitlen * 2, rate); + + service = IEEE80211_DS_PLCP_SERVICE_LOCKED; + if (rate == (11 * 2)) { + int pkt_bitlen1; + + /* + * PLCP service field needs to be adjusted, + * if TX rate is 11Mbytes/s + */ + pkt_bitlen1 = len * 11; + if (pkt_bitlen1 - pkt_bitlen >= NBBY) + service |= IEEE80211_DS_PLCP_SERVICE_LENEXT7; + } + + plcp->i_signal = bwi_rate2plcp(rate); + plcp->i_service = service; + plcp->i_length = htole16(len); + /* NOTE: do NOT touch i_crc */ +} + +static __inline void +bwi_plcp_header(void *plcp, int pkt_len, uint8_t rate) +{ + enum ieee80211_modtype modtype; + + /* + * Assume caller has zeroed 'plcp' + */ + + modtype = ieee80211_rate2modtype(rate); + if (modtype == IEEE80211_MODTYPE_OFDM) + bwi_ofdm_plcp_header(plcp, pkt_len, rate); + else if (modtype == IEEE80211_MODTYPE_DS) + bwi_ds_plcp_header(plcp, pkt_len, rate); + else + panic("unsupport modulation type %u\n", modtype); +} + +static int +bwi_encap(struct bwi_softc *sc, int idx, struct mbuf *m, + struct ieee80211_node *ni) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_ring_data *rd = &sc->sc_tx_rdata[BWI_TX_DATA_RING]; + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[BWI_TX_DATA_RING]; + struct bwi_txbuf *tb = &tbd->tbd_buf[idx]; + struct bwi_mac *mac; + struct bwi_txbuf_hdr *hdr; + struct ieee80211_frame *wh; + uint8_t rate, rate_fb; + uint32_t mac_ctrl; + uint16_t phy_ctrl; + bus_addr_t paddr; + int pkt_len, error; +#if 0 + const uint8_t *p; + int i; +#endif + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + wh = mtod(m, struct ieee80211_frame *); + + /* Get 802.11 frame len before prepending TX header */ + pkt_len = m->m_pkthdr.len + IEEE80211_CRC_LEN; + + /* + * Find TX rate + */ + bzero(tb->tb_rate_idx, sizeof(tb->tb_rate_idx)); + if (IEEE80211_IS_MULTICAST(wh->i_addr1)) + rate = rate_fb = ic->ic_mcast_rate; + else if (ic->ic_fixed_rate == IEEE80211_FIXED_RATE_NONE) { + rate = ni->ni_rates.rs_rates[ni->ni_txrate] & IEEE80211_RATE_VAL; + rate_fb = (ni->ni_txrate > 0) ? + ni->ni_rates.rs_rates[ni->ni_txrate-1] & IEEE80211_RATE_VAL : rate; + } else + rate = rate_fb = ic->ic_fixed_rate; + + /* + * TX radio tap + */ + if (bpf_peers_present(sc->sc_drvbpf)) { + sc->sc_tx_th.wt_flags = 0; + if (wh->i_fc[1] & IEEE80211_FC1_WEP) + sc->sc_tx_th.wt_flags |= IEEE80211_RADIOTAP_F_WEP; + if (ieee80211_rate2modtype(rate) == IEEE80211_MODTYPE_DS && + (ic->ic_flags & IEEE80211_F_SHPREAMBLE) && + rate != (1 * 2)) { + sc->sc_tx_th.wt_flags |= IEEE80211_RADIOTAP_F_SHORTPRE; + } + sc->sc_tx_th.wt_rate = rate; + + bpf_mtap2(sc->sc_drvbpf, &sc->sc_tx_th, sc->sc_tx_th_len, m); + } + + /* + * Setup the embedded TX header + */ + M_PREPEND(m, sizeof(*hdr), M_DONTWAIT); + if (m == NULL) { + if_printf(ic->ic_ifp, "prepend TX header failed\n"); + return ENOBUFS; + } + hdr = mtod(m, struct bwi_txbuf_hdr *); + + bzero(hdr, sizeof(*hdr)); + + bcopy(wh->i_fc, hdr->txh_fc, sizeof(hdr->txh_fc)); + bcopy(wh->i_addr1, hdr->txh_addr1, sizeof(hdr->txh_addr1)); + + if (!IEEE80211_IS_MULTICAST(wh->i_addr1)) { + uint16_t dur; + uint8_t ack_rate; + + ack_rate = ieee80211_ack_rate(ni, rate_fb); + dur = ieee80211_txtime(ni, + sizeof(struct ieee80211_frame_ack) + IEEE80211_CRC_LEN, + ack_rate, ic->ic_flags & ~IEEE80211_F_SHPREAMBLE); + + hdr->txh_fb_duration = htole16(dur); + } + + hdr->txh_id = __SHIFTIN(BWI_TX_DATA_RING, BWI_TXH_ID_RING_MASK) | + __SHIFTIN(idx, BWI_TXH_ID_IDX_MASK); + + bwi_plcp_header(hdr->txh_plcp, pkt_len, rate); + bwi_plcp_header(hdr->txh_fb_plcp, pkt_len, rate_fb); + + phy_ctrl = __SHIFTIN(mac->mac_rf.rf_ant_mode, + BWI_TXH_PHY_C_ANTMODE_MASK); + if (ieee80211_rate2modtype(rate) == IEEE80211_MODTYPE_OFDM) + phy_ctrl |= BWI_TXH_PHY_C_OFDM; + else if ((ic->ic_flags & IEEE80211_F_SHPREAMBLE) && rate != (2 * 1)) + phy_ctrl |= BWI_TXH_PHY_C_SHPREAMBLE; + + mac_ctrl = BWI_TXH_MAC_C_HWSEQ | BWI_TXH_MAC_C_FIRST_FRAG; + if (!IEEE80211_IS_MULTICAST(wh->i_addr1)) + mac_ctrl |= BWI_TXH_MAC_C_ACK; + if (ieee80211_rate2modtype(rate_fb) == IEEE80211_MODTYPE_OFDM) + mac_ctrl |= BWI_TXH_MAC_C_FB_OFDM; + + hdr->txh_mac_ctrl = htole32(mac_ctrl); + hdr->txh_phy_ctrl = htole16(phy_ctrl); + + /* Catch any further usage */ + hdr = NULL; + wh = NULL; + + /* DMA load */ + error = bus_dmamap_load_mbuf(sc->sc_buf_dtag, tb->tb_dmap, m, + bwi_dma_buf_addr, &paddr, BUS_DMA_NOWAIT); + if (error && error != EFBIG) { + if_printf(ic->ic_ifp, "can't load TX buffer (1) %d\n", error); + goto back; + } + + if (error) { /* error == EFBIG */ + struct mbuf *m_new; + + m_new = m_defrag(m, M_DONTWAIT); + if (m_new == NULL) { + if_printf(ic->ic_ifp, "can't defrag TX buffer\n"); + error = ENOBUFS; + goto back; + } else { + m = m_new; + } + + error = bus_dmamap_load_mbuf(sc->sc_buf_dtag, tb->tb_dmap, m, + bwi_dma_buf_addr, &paddr, + BUS_DMA_NOWAIT); + if (error) { + if_printf(ic->ic_ifp, "can't load TX buffer (2) %d\n", + error); + goto back; + } + } + error = 0; + + bus_dmamap_sync(sc->sc_buf_dtag, tb->tb_dmap, BUS_DMASYNC_PREWRITE); + + tb->tb_mbuf = m; + tb->tb_ni = ni; + +#if 0 + p = mtod(m, const uint8_t *); + for (i = 0; i < m->m_pkthdr.len; ++i) { + if (i != 0 && i % 8 == 0) + printf("\n"); + printf("%02x ", p[i]); + } + printf("\n"); + + if_printf(ic->ic_ifp, "idx %d, pkt_len %d, buflen %d\n", + idx, pkt_len, m->m_pkthdr.len); +#endif + + /* Setup TX descriptor */ + sc->sc_setup_txdesc(sc, rd, idx, paddr, m->m_pkthdr.len); + bus_dmamap_sync(sc->sc_txring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); + + /* Kick start */ + sc->sc_start_tx(sc, rd->rdata_txrx_ctrl, idx); + +back: + if (error) + m_freem(m); + return error; +} + +static void +bwi_start_tx32(struct bwi_softc *sc, uint32_t tx_ctrl, int idx) +{ + idx = (idx + 1) % BWI_TX_NDESC; + CSR_WRITE_4(sc, tx_ctrl + BWI_TX32_INDEX, + idx * sizeof(struct bwi_desc32)); +} + +static void +bwi_start_tx64(struct bwi_softc *sc, uint32_t tx_ctrl, int idx) +{ + /* TODO:64 */ +} + +static void +bwi_txeof_status32(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ic.ic_ifp; + uint32_t val, ctrl_base; + int end_idx; + + ctrl_base = sc->sc_txstats->stats_ctrl_base; + + val = CSR_READ_4(sc, ctrl_base + BWI_RX32_STATUS); + end_idx = __SHIFTOUT(val, BWI_RX32_STATUS_INDEX_MASK) / + sizeof(struct bwi_desc32); + + bwi_txeof_status(sc, end_idx); + + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_INDEX, + end_idx * sizeof(struct bwi_desc32)); + + if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) == 0) + ifp->if_start(ifp); +} + +static void +bwi_txeof_status64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +_bwi_txeof(struct bwi_softc *sc, uint16_t tx_id, int acked, int data_txcnt) +{ + struct ifnet *ifp = sc->sc_ic.ic_ifp; + struct bwi_txbuf_data *tbd; + struct bwi_txbuf *tb; + int ring_idx, buf_idx; + struct ieee80211_node *ni; + + if (tx_id == 0) { + if_printf(ifp, "zero tx id\n"); + return; + } + +#if 0 + if_printf(ifp, "acked %d, data_txcnt %d\n", acked, data_txcnt); +#endif + + ring_idx = __SHIFTOUT(tx_id, BWI_TXH_ID_RING_MASK); + buf_idx = __SHIFTOUT(tx_id, BWI_TXH_ID_IDX_MASK); + + KASSERT(ring_idx == BWI_TX_DATA_RING, ("ring_idx %d", ring_idx)); + KASSERT(buf_idx < BWI_TX_NDESC, ("buf_idx %d", buf_idx)); +#if 0 + if_printf(ifp, "txeof idx %d\n", buf_idx); +#endif + + tbd = &sc->sc_tx_bdata[ring_idx]; + KASSERT(tbd->tbd_used > 0, ("tbd_used %d", tbd->tbd_used)); + tbd->tbd_used--; + + tb = &tbd->tbd_buf[buf_idx]; + + bus_dmamap_unload(sc->sc_buf_dtag, tb->tb_dmap); + + ni = tb->tb_ni; + if (tb->tb_ni != NULL) { + struct bwi_node *bn = (struct bwi_node *) tb->tb_ni; + + /* XXX only for unicast frames */ + /* Feed back 'acked and data_txcnt' */ + if (acked) + bn->amn.amn_success++; + bn->amn.amn_txcnt++; + bn->amn.amn_retrycnt += data_txcnt-1; + + /* + * Do any tx complete callback. Note this must + * be done before releasing the node reference. + */ + if (tb->tb_mbuf->m_flags & M_TXCB) + ieee80211_process_callback(ni, tb->tb_mbuf, !acked); + + ieee80211_free_node(tb->tb_ni); + tb->tb_ni = NULL; + } + m_freem(tb->tb_mbuf); + tb->tb_mbuf = NULL; + + if (tbd->tbd_used == 0) + sc->sc_tx_timer = 0; + + ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; +} + +static void +bwi_txeof_status(struct bwi_softc *sc, int end_idx) +{ + struct bwi_txstats_data *st = sc->sc_txstats; + int idx; + + bus_dmamap_sync(st->stats_dtag, st->stats_dmap, BUS_DMASYNC_POSTREAD); + + idx = st->stats_idx; + while (idx != end_idx) { + const struct bwi_txstats *stats = &st->stats[idx]; + + if ((stats->txs_flags & BWI_TXS_F_PENDING) == 0) { + int data_txcnt; + + data_txcnt = __SHIFTOUT(stats->txs_txcnt, + BWI_TXS_TXCNT_DATA); + _bwi_txeof(sc, le16toh(stats->txs_id), + stats->txs_flags & BWI_TXS_F_ACKED, + data_txcnt); + } + idx = (idx + 1) % BWI_TXSTATS_NDESC; + } + st->stats_idx = idx; +} + +static void +bwi_txeof(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ic.ic_ifp; + + for (;;) { + uint32_t tx_status0, tx_status1; + uint16_t tx_id; + int data_txcnt; + + tx_status0 = CSR_READ_4(sc, BWI_TXSTATUS0); + if ((tx_status0 & BWI_TXSTATUS0_VALID) == 0) + break; + tx_status1 = CSR_READ_4(sc, BWI_TXSTATUS1); + + tx_id = __SHIFTOUT(tx_status0, BWI_TXSTATUS0_TXID_MASK); + data_txcnt = __SHIFTOUT(tx_status0, + BWI_TXSTATUS0_DATA_TXCNT_MASK); + + if (tx_status0 & (BWI_TXSTATUS0_AMPDU | BWI_TXSTATUS0_PENDING)) + continue; + + _bwi_txeof(sc, le16toh(tx_id), tx_status0 & BWI_TXSTATUS0_ACKED, + data_txcnt); + } + + if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) == 0) + ifp->if_start(ifp); +} + +static int +bwi_bbp_power_on(struct bwi_softc *sc, enum bwi_clock_mode clk_mode) +{ + bwi_power_on(sc, 1); + return bwi_set_clock_mode(sc, clk_mode); +} + +static void +bwi_bbp_power_off(struct bwi_softc *sc) +{ + bwi_set_clock_mode(sc, BWI_CLOCK_MODE_SLOW); + bwi_power_off(sc, 1); +} + +static int +bwi_get_pwron_delay(struct bwi_softc *sc) +{ + struct bwi_regwin *com, *old; + struct bwi_clock_freq freq; + uint32_t val; + int error; + + com = &sc->sc_com_regwin; + KASSERT(BWI_REGWIN_EXIST(com), ("no regwin")); + + if ((sc->sc_cap & BWI_CAP_CLKMODE) == 0) + return 0; + + error = bwi_regwin_switch(sc, com, &old); + if (error) + return error; + + bwi_get_clock_freq(sc, &freq); + + val = CSR_READ_4(sc, BWI_PLL_ON_DELAY); + sc->sc_pwron_delay = howmany((val + 2) * 1000000, freq.clkfreq_min); + DPRINTF(sc, "power on delay %u\n", sc->sc_pwron_delay); + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_bus_attach(struct bwi_softc *sc) +{ + struct bwi_regwin *bus, *old; + int error; + + bus = &sc->sc_bus_regwin; + + error = bwi_regwin_switch(sc, bus, &old); + if (error) + return error; + + if (!bwi_regwin_is_enabled(sc, bus)) + bwi_regwin_enable(sc, bus, 0); + + /* Disable interripts */ + CSR_WRITE_4(sc, BWI_INTRVEC, 0); + + return bwi_regwin_switch(sc, old, NULL); +} +//kir+ +static const char * +bwi_regwin_name(const uint16_t type) +{ + switch (type) { + case BWI_REGWIN_T_CC: + return "chipcommon"; + case BWI_REGWIN_T_ILINE20: + return "iline20"; + case BWI_REGWIN_T_SDRAM: + return "sdram"; + case BWI_REGWIN_T_PCI: + return "pci"; + case BWI_REGWIN_T_MIPS: + return "mips"; + case BWI_REGWIN_T_ENET: + return "enet mac"; + case BWI_REGWIN_T_CODEC: + return "v90 codec"; + case BWI_REGWIN_T_USB: + return "usb 1.1 host/device"; + case BWI_REGWIN_T_ADSL: + return "ADSL"; + case BWI_REGWIN_T_ILINE100: + return "iline100"; + case BWI_REGWIN_T_IPSEC: + return "ipsec"; + case BWI_REGWIN_T_PCMCIA: + return "pcmcia"; + case BWI_REGWIN_T_SOCRAM: + return "internal memory"; + case BWI_REGWIN_T_MEMC: + return "memc sdram"; + case BWI_REGWIN_T_EXTIF: + return "external interface"; + case BWI_REGWIN_T_D11: + return "802.11 MAC"; + case BWI_REGWIN_T_MIPS33: + return "mips3302"; + case BWI_REGWIN_T_USB11H: + return "usb 1.1 host"; + case BWI_REGWIN_T_USB11D: + return "usb 1.1 device"; + case BWI_REGWIN_T_USB20H: + return "usb 2.0 host"; + case BWI_REGWIN_T_USB20D: + return "usb 2.0 device"; + case BWI_REGWIN_T_SDIOH: + return "sdio host"; + case BWI_REGWIN_T_ROBO: + return "roboswitch"; + case BWI_REGWIN_T_ATA100: + return "parallel ATA"; + case BWI_REGWIN_T_SATAXOR: + return "serial ATA & XOR DMA"; + case BWI_REGWIN_T_GIGETH: + return "gigabit ethernet"; + case BWI_REGWIN_T_PCIE: + return "pci express"; + case BWI_REGWIN_T_SRAMC: + return "SRAM controller"; + case BWI_REGWIN_T_MINIMAC: + return "MINI MAC/phy"; + } + return "unknown"; +} + +static uint32_t +bwi_regwin_disable_bits(struct bwi_softc *sc) +{ + uint32_t busrev; + + /* XXX cache this */ + busrev = __SHIFTOUT(CSR_READ_4(sc, BWI_ID_LO), BWI_ID_LO_BUSREV_MASK); + DPRINTF(sc, "bus rev %u\n", busrev); + + if (busrev == BWI_BUSREV_0) + return BWI_STATE_LO_DISABLE1; + else if (busrev == BWI_BUSREV_1) + return BWI_STATE_LO_DISABLE2; + else + return (BWI_STATE_LO_DISABLE1 | BWI_STATE_LO_DISABLE2); +} + +int +bwi_regwin_is_enabled(struct bwi_softc *sc, struct bwi_regwin *rw) +{ + uint32_t val, disable_bits; + + disable_bits = bwi_regwin_disable_bits(sc); + val = CSR_READ_4(sc, BWI_STATE_LO); + + if ((val & (BWI_STATE_LO_CLOCK | + BWI_STATE_LO_RESET | + disable_bits)) == BWI_STATE_LO_CLOCK) { + DPRINTF(sc, "%s is enabled\n", bwi_regwin_name(rw->rw_type)); + return 1; + } else { + DPRINTF(sc, "%s is disabled\n", bwi_regwin_name(rw->rw_type)); + return 0; + } +} + +void +bwi_regwin_disable(struct bwi_softc *sc, struct bwi_regwin *rw, uint32_t flags) +{ + uint32_t state_lo, disable_bits; + int i; + + state_lo = CSR_READ_4(sc, BWI_STATE_LO); + + /* + * If current regwin is in 'reset' state, it was already disabled. + */ + if (state_lo & BWI_STATE_LO_RESET) { + DPRINTF(sc, "%s was already disabled\n", bwi_regwin_name(rw->rw_type)); + return; + } + + disable_bits = bwi_regwin_disable_bits(sc); + + /* + * Disable normal clock + */ + state_lo = BWI_STATE_LO_CLOCK | disable_bits; + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* + * Wait until normal clock is disabled + */ +#define NRETRY 1000 + for (i = 0; i < NRETRY; ++i) { + state_lo = CSR_READ_4(sc, BWI_STATE_LO); + if (state_lo & disable_bits) + break; + DELAY(10); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "%s disable clock timeout\n", + bwi_regwin_name(rw->rw_type)); + } + + for (i = 0; i < NRETRY; ++i) { + uint32_t state_hi; + + state_hi = CSR_READ_4(sc, BWI_STATE_HI); + if ((state_hi & BWI_STATE_HI_BUSY) == 0) + break; + DELAY(10); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "%s wait BUSY unset timeout\n", + bwi_regwin_name(rw->rw_type)); + } +#undef NRETRY + + /* + * Reset and disable regwin with gated clock + */ + state_lo = BWI_STATE_LO_RESET | disable_bits | + BWI_STATE_LO_CLOCK | BWI_STATE_LO_GATED_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); + + /* Reset and disable regwin */ + state_lo = BWI_STATE_LO_RESET | disable_bits | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); +} + +void +bwi_regwin_enable(struct bwi_softc *sc, struct bwi_regwin *rw, uint32_t flags) +{ + uint32_t state_lo, state_hi, imstate; + + bwi_regwin_disable(sc, rw, flags); + + /* Reset regwin with gated clock */ + state_lo = BWI_STATE_LO_RESET | + BWI_STATE_LO_CLOCK | + BWI_STATE_LO_GATED_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); + + state_hi = CSR_READ_4(sc, BWI_STATE_HI); + if (state_hi & BWI_STATE_HI_SERROR) + CSR_WRITE_4(sc, BWI_STATE_HI, 0); + + imstate = CSR_READ_4(sc, BWI_IMSTATE); + if (imstate & (BWI_IMSTATE_INBAND_ERR | BWI_IMSTATE_TIMEOUT)) { + imstate &= ~(BWI_IMSTATE_INBAND_ERR | BWI_IMSTATE_TIMEOUT); + CSR_WRITE_4(sc, BWI_IMSTATE, imstate); + } + + /* Enable regwin with gated clock */ + state_lo = BWI_STATE_LO_CLOCK | + BWI_STATE_LO_GATED_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); + + /* Enable regwin with normal clock */ + state_lo = BWI_STATE_LO_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); +} + +static void +bwi_set_bssid(struct bwi_softc *sc, const uint8_t *bssid) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_mac *mac; + struct bwi_myaddr_bssid buf; + const uint8_t *p; + uint32_t val; + int n, i; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + bwi_set_addr_filter(sc, BWI_ADDR_FILTER_BSSID, bssid); + + bcopy(ic->ic_myaddr, buf.myaddr, sizeof(buf.myaddr)); + bcopy(bssid, buf.bssid, sizeof(buf.bssid)); + + n = sizeof(buf) / sizeof(val); + p = (const uint8_t *)&buf; + for (i = 0; i < n; ++i) { + int j; + + val = 0; + for (j = 0; j < sizeof(val); ++j) + val |= ((uint32_t)(*p++)) << (j * 8); + + TMPLT_WRITE_4(mac, 0x20 + (i * sizeof(val)), val); + } +} + +static void +bwi_updateslot(struct ifnet *ifp) +{ + struct bwi_softc *sc = ifp->if_softc; + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_mac *mac; + + BWI_LOCK(sc); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) { + DPRINTF(sc, "%s\n", __func__); + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + bwi_mac_updateslot(mac, (ic->ic_flags & IEEE80211_F_SHSLOT)); + } + BWI_UNLOCK(sc); +} + +static void +bwi_calibrate(void *xsc) +{ + struct bwi_softc *sc = xsc; + struct ieee80211com *ic = &sc->sc_ic; + + if (ic->ic_state == IEEE80211_S_RUN) { + struct bwi_mac *mac; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + if (ic->ic_opmode != IEEE80211_M_MONITOR) + bwi_mac_calibrate_txpower(mac); + + /* XXX 15 seconds */ + callout_reset(&sc->sc_calib_ch, hz * 15, bwi_calibrate, sc); + } +} + +static int +bwi_calc_rssi(struct bwi_softc *sc, const struct bwi_rxbuf_hdr *hdr) +{ + struct bwi_mac *mac; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + return bwi_rf_calc_rssi(mac, hdr); +} + +static __inline uint8_t +bwi_ofdm_plcp2rate(const uint32_t *plcp0) +{ + uint32_t plcp; + uint8_t plcp_rate; + + plcp = le32toh(*plcp0); + plcp_rate = __SHIFTOUT(plcp, IEEE80211_OFDM_PLCP_RATE_MASK); + return ieee80211_plcp2rate(plcp_rate, 1); +} + +static __inline uint8_t +bwi_ds_plcp2rate(const struct ieee80211_ds_plcp_hdr *hdr) +{ + return ieee80211_plcp2rate(hdr->i_signal, 0); +} + +static void +bwi_rx_radiotap(struct bwi_softc *sc, struct mbuf *m, + struct bwi_rxbuf_hdr *hdr, const void *plcp, int rssi) +{ + const struct ieee80211_frame_min *wh; + uint16_t flags1; + uint8_t rate; + + flags1 = htole16(hdr->rxh_flags1); + if (flags1 & BWI_RXH_F1_OFDM) + rate = bwi_ofdm_plcp2rate(plcp); + else + rate = bwi_ds_plcp2rate(plcp); + + sc->sc_rx_th.wr_flags = IEEE80211_RADIOTAP_F_FCS; + if (flags1 & BWI_RXH_F1_SHPREAMBLE) + sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_SHORTPRE; + + wh = mtod(m, const struct ieee80211_frame_min *); + if (wh->i_fc[1] & IEEE80211_FC1_WEP) + sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_WEP; + + sc->sc_rx_th.wr_tsf = hdr->rxh_tsf; /* No endian convertion */ + sc->sc_rx_th.wr_rate = rate; + sc->sc_rx_th.wr_antsignal = rssi; + sc->sc_rx_th.wr_antnoise = BWI_NOISE_FLOOR; + + bpf_mtap2(sc->sc_drvbpf, &sc->sc_rx_th, sc->sc_rx_th_len, m); +} + +static void +bwi_led_attach(struct bwi_softc *sc) +{ +#define PCI_VENDOR_COMPAQ 0x0e11 + const static uint8_t led_default_act[BWI_LED_MAX] = { + BWI_LED_ACT_ACTIVE, + BWI_LED_ACT_2GHZ, + BWI_LED_ACT_5GHZ, + BWI_LED_ACT_OFF + }; + + uint16_t gpio, val[BWI_LED_MAX]; + int i; + + gpio = bwi_read_sprom(sc, BWI_SPROM_GPIO01); + val[0] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_0); + val[1] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_1); + + gpio = bwi_read_sprom(sc, BWI_SPROM_GPIO23); + val[2] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_2); + val[3] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_3); + + for (i = 0; i < BWI_LED_MAX; ++i) { + struct bwi_led *led = &sc->sc_leds[i]; + + if (val[i] == 0xff) { + led->l_act = led_default_act[i]; + if (i == 0 && sc->sc_pci_subvid == PCI_VENDOR_COMPAQ) + led->l_act = BWI_LED_ACT_RFEN; + } else { + if (val[i] & BWI_LED_ACT_LOW) + led->l_flags |= BWI_LED_F_ACTLOW; + led->l_act = __SHIFTOUT(val[i], BWI_LED_ACT_MASK); + } + + DPRINTF(sc, "%dth led, act %d, lowact %d\n", + i, led->l_act, led->l_flags & BWI_LED_F_ACTLOW); + } +#undef PCI_VENDOR_COMPAQ +} + +static void +bwi_led_newstate(struct bwi_softc *sc, enum ieee80211_state nstate) +{ + struct ieee80211com *ic = &sc->sc_ic; + uint16_t val; + int i; + + if ((ic->ic_ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + return; + + val = CSR_READ_2(sc, BWI_MAC_GPIO_CTRL); + for (i = 0; i < BWI_LED_MAX; ++i) { + struct bwi_led *led = &sc->sc_leds[i]; + int on; + + if (led->l_act == BWI_LED_ACT_UNKN || + led->l_act == BWI_LED_ACT_NULL) { + /* Don't touch it */ + continue; + } + + switch (led->l_act) { + case BWI_LED_ACT_ON: /* Always on */ + on = 1; + break; + case BWI_LED_ACT_OFF: /* Always off */ + case BWI_LED_ACT_5GHZ: /* TODO: 11A */ + case BWI_LED_ACT_MID: /* Blinking ones */ + case BWI_LED_ACT_FAST: + on = 0; + break; + default: + on = 1; + switch (nstate) { + case IEEE80211_S_INIT: + on = 0; + break; + case IEEE80211_S_RUN: + if (led->l_act == BWI_LED_ACT_11G && + ic->ic_curmode != IEEE80211_MODE_11G) + on = 0; + break; + default: + if (led->l_act == BWI_LED_ACT_RUN || + led->l_act == BWI_LED_ACT_ACTIVE) + on = 0; + break; + } + break; + } + + if (led->l_flags & BWI_LED_F_ACTLOW) + on = !on; + + if (on) + val |= (1 << i); + else + val &= ~(1 << i); + } + CSR_WRITE_2(sc, BWI_MAC_GPIO_CTRL, val); +} + +/* + * Covert PLCP signal/rate field to net80211 rate (.5Mbits/s) + */ +uint8_t +ieee80211_plcp2rate(uint8_t plcp, int ofdm) +{ + if (!ofdm) { + switch (plcp) { + /* IEEE Std 802.11b-1999 page 15, subclause 18.2.3.3 */ + case 0x0a: + case 0x14: + case 0x37: + case 0x6e: + /* IEEE Std 802.11g-2003 page 19, subclause 19.3.2.1 */ + case 0xdc: + return plcp / 5; + } + } else { +#define _OFDM_PLCP2RATE_MAX 16 + + /* IEEE Std 802.11a-1999 page 14, subclause 17.3.4.1 */ + static const uint8_t ofdm_plcp2rate[_OFDM_PLCP2RATE_MAX] = { + [0xb] = 12, + [0xf] = 18, + [0xa] = 24, + [0xe] = 36, + [0x9] = 48, + [0xd] = 72, + [0x8] = 96, + [0xc] = 108 + }; + if (plcp < _OFDM_PLCP2RATE_MAX) + return ofdm_plcp2rate[plcp]; + +#undef _OFDM_PLCP2RATE_MAX + } + return 0; +} + +enum ieee80211_modtype +ieee80211_rate2modtype(uint8_t rate) +{ + rate &= IEEE80211_RATE_VAL; + if (rate == 22 || rate < 12) + return IEEE80211_MODTYPE_DS; + else if (rate == 44) + return IEEE80211_MODTYPE_PBCC; + else + return IEEE80211_MODTYPE_OFDM; +} + +uint8_t +ieee80211_ack_rate(struct ieee80211_node *ni, uint8_t rate) +{ + const struct ieee80211_rateset *rs = &ni->ni_rates; + uint8_t ack_rate = 0; + enum ieee80211_modtype modtype; + int i; + + rate &= IEEE80211_RATE_VAL; + + modtype = ieee80211_rate2modtype(rate); + + for (i = 0; i < rs->rs_nrates; ++i) { + uint8_t rate1 = rs->rs_rates[i] & IEEE80211_RATE_VAL; + + if (rate1 > rate) { + if (ack_rate != 0) + return ack_rate; + else + break; + } + + if ((rs->rs_rates[i] & IEEE80211_RATE_BASIC) && + ieee80211_rate2modtype(rate1) == modtype) + ack_rate = rate1; + } + + switch (rate) { + /* CCK */ + case 2: + case 4: + case 11: + case 22: + ack_rate = rate; + break; + + /* PBCC */ + case 44: + ack_rate = 22; + break; + + /* OFDM */ + case 12: + case 18: + ack_rate = 12; + break; + case 24: + case 36: + ack_rate = 24; + break; + case 48: + case 72: + case 96: + case 108: + ack_rate = 48; + break; + default: + panic("unsupported rate %d\n", rate); + } + return ack_rate; +} + +/* IEEE Std 802.11a-1999, page 9, table 79 */ +#define IEEE80211_OFDM_SYM_TIME 4 +#define IEEE80211_OFDM_PREAMBLE_TIME 16 +#define IEEE80211_OFDM_SIGNAL_TIME 4 +/* IEEE Std 802.11g-2003, page 44 */ +#define IEEE80211_OFDM_SIGNAL_EXT_TIME 6 + +/* IEEE Std 802.11a-1999, page 7, figure 107 */ +#define IEEE80211_OFDM_PLCP_SERVICE_NBITS 16 +#define IEEE80211_OFDM_TAIL_NBITS 6 + +#define IEEE80211_OFDM_NBITS(frmlen) \ + (IEEE80211_OFDM_PLCP_SERVICE_NBITS + \ + ((frmlen) * NBBY) + \ + IEEE80211_OFDM_TAIL_NBITS) + +#define IEEE80211_OFDM_NBITS_PER_SYM(kbps) \ + (((kbps) * IEEE80211_OFDM_SYM_TIME) / 1000) + +#define IEEE80211_OFDM_NSYMS(kbps, frmlen) \ + howmany(IEEE80211_OFDM_NBITS((frmlen)), \ + IEEE80211_OFDM_NBITS_PER_SYM((kbps))) + +#define IEEE80211_OFDM_TXTIME(kbps, frmlen) \ + (IEEE80211_OFDM_PREAMBLE_TIME + \ + IEEE80211_OFDM_SIGNAL_TIME + \ + (IEEE80211_OFDM_NSYMS((kbps), (frmlen)) * IEEE80211_OFDM_SYM_TIME)) + +/* IEEE Std 802.11b-1999, page 28, subclause 18.3.4 */ +#define IEEE80211_CCK_PREAMBLE_LEN 144 +#define IEEE80211_CCK_PLCP_HDR_TIME 48 +#define IEEE80211_CCK_SHPREAMBLE_LEN 72 +#define IEEE80211_CCK_SHPLCP_HDR_TIME 24 + +#define IEEE80211_CCK_NBITS(frmlen) ((frmlen) * NBBY) +#define IEEE80211_CCK_TXTIME(kbps, frmlen) \ + (((IEEE80211_CCK_NBITS((frmlen)) * 1000) + (kbps) - 1) / (kbps)) + +uint16_t +ieee80211_txtime(struct ieee80211_node *ni, u_int len, uint8_t rs_rate, + uint32_t flags) +{ + struct ieee80211com *ic = ni->ni_ic; + enum ieee80211_modtype modtype; + uint16_t txtime; + int rate; + + rs_rate &= IEEE80211_RATE_VAL; + + rate = rs_rate * 500; /* ieee80211 rate -> kbps */ + + modtype = ieee80211_rate2modtype(rs_rate); + if (modtype == IEEE80211_MODTYPE_OFDM) { + /* + * IEEE Std 802.11a-1999, page 37, equation (29) + * IEEE Std 802.11g-2003, page 44, equation (42) + */ + txtime = IEEE80211_OFDM_TXTIME(rate, len); + if (ic->ic_curmode == IEEE80211_MODE_11G) + txtime += IEEE80211_OFDM_SIGNAL_EXT_TIME; + } else { + /* + * IEEE Std 802.11b-1999, page 28, subclause 18.3.4 + * IEEE Std 802.11g-2003, page 45, equation (43) + */ + if (modtype == IEEE80211_MODTYPE_PBCC) + ++len; + txtime = IEEE80211_CCK_TXTIME(rate, len); + + /* + * Short preamble is not applicable for DS 1Mbits/s + */ + if (rs_rate != 2 && (flags & IEEE80211_F_SHPREAMBLE)) { + txtime += IEEE80211_CCK_SHPREAMBLE_LEN + + IEEE80211_CCK_SHPLCP_HDR_TIME; + } else { + txtime += IEEE80211_CCK_PREAMBLE_LEN + + IEEE80211_CCK_PLCP_HDR_TIME; + } + } + return txtime; +} --- /dev/null +++ sys/dev/bwi/bwimac.h @@ -0,0 +1,99 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwimac.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwimac.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BWI_MAC_H +#define _BWI_MAC_H + +int bwi_mac_attach(struct bwi_softc *, int, uint8_t); +int bwi_mac_lateattach(struct bwi_mac *); +void bwi_mac_detach(struct bwi_mac *); +int bwi_mac_init(struct bwi_mac *); +void bwi_mac_reset(struct bwi_mac *, int); +int bwi_mac_start(struct bwi_mac *); +int bwi_mac_stop(struct bwi_mac *); +void bwi_mac_shutdown(struct bwi_mac *); +void bwi_mac_updateslot(struct bwi_mac *, int); +void bwi_mac_set_promisc(struct bwi_mac *, int); + +void bwi_mac_calibrate_txpower(struct bwi_mac *); +void bwi_mac_set_tpctl_11bg(struct bwi_mac *, + const struct bwi_tpctl *); +void bwi_mac_init_tpctl_11bg(struct bwi_mac *); +void bwi_mac_dummy_xmit(struct bwi_mac *); +void bwi_mac_reset_hwkeys(struct bwi_mac *); +int bwi_mac_config_ps(struct bwi_mac *); + +uint16_t bwi_memobj_read_2(struct bwi_mac *, uint16_t, uint16_t); +uint32_t bwi_memobj_read_4(struct bwi_mac *, uint16_t, uint16_t); +void bwi_memobj_write_2(struct bwi_mac *, uint16_t, uint16_t, + uint16_t); +void bwi_memobj_write_4(struct bwi_mac *, uint16_t, uint16_t, + uint32_t); +void bwi_tmplt_write_4(struct bwi_mac *, uint32_t, uint32_t); +void bwi_hostflags_write(struct bwi_mac *, uint64_t); +uint64_t bwi_hostflags_read(struct bwi_mac *); + +#define MOBJ_WRITE_2(mac, objid, ofs, val) \ + bwi_memobj_write_2((mac), (objid), (ofs), (val)) +#define MOBJ_WRITE_4(mac, objid, ofs, val) \ + bwi_memobj_write_4((mac), (objid), (ofs), (val)) +#define MOBJ_READ_2(mac, objid, ofs) \ + bwi_memobj_read_2((mac), (objid), (ofs)) +#define MOBJ_READ_4(mac, objid, ofs) \ + bwi_memobj_read_4((mac), (objid), (ofs)) + +#define MOBJ_SETBITS_4(mac, objid, ofs, bits) \ + MOBJ_WRITE_4((mac), (objid), (ofs), \ + MOBJ_READ_4((mac), (objid), (ofs)) | (bits)) +#define MOBJ_CLRBITS_4(mac, objid, ofs, bits) \ + MOBJ_WRITE_4((mac), (objid), (ofs), \ + MOBJ_READ_4((mac), (objid), (ofs)) & ~(bits)) + +#define MOBJ_FILT_SETBITS_2(mac, objid, ofs, filt, bits) \ + MOBJ_WRITE_2((mac), (objid), (ofs), \ + (MOBJ_READ_2((mac), (objid), (ofs)) & (filt)) | (bits)) + +#define TMPLT_WRITE_4(mac, ofs, val) bwi_tmplt_write_4((mac), (ofs), (val)) + +#define HFLAGS_WRITE(mac, flags) bwi_hostflags_write((mac), (flags)) +#define HFLAGS_READ(mac) bwi_hostflags_read((mac)) +#define HFLAGS_CLRBITS(mac, bits) \ + HFLAGS_WRITE((mac), HFLAGS_READ((mac)) | (bits)) +#define HFLAGS_SETBITS(mac, bits) \ + HFLAGS_WRITE((mac), HFLAGS_READ((mac)) & ~(bits)) + +#endif /* !_BWI_MAC_H */ From laffer1 at midnightbsd.org Mon Jan 19 17:03:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:03:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: add bwi Message-ID: <200901192203.n0JM3t5K074676@stargazer.midnightbsd.org> Log Message: ----------- add bwi Added Files: ----------- src/sys/modules/bwi: Makefile (r1.1) -------------- next part -------------- --- /dev/null +++ sys/modules/bwi/Makefile @@ -0,0 +1,14 @@ +# $MidnightBSD: src/sys/modules/bwi/Makefile,v 1.1 2009/01/19 22:03:55 laffer1 Exp $ + +.PATH: ${.CURDIR}/../../dev/bwi + +KMOD= if_bwi + +SRCS= if_bwi.c if_bwi_pci.c bwimac.c bwiphy.c bwirf.c +SRCS+= device_if.h bus_if.h pci_if.h opt_inet.h opt_bwi.h + +opt_bwi.h: + echo '#define BWI_DEBUG 1' > opt_bwi.h + echo '#define BWI_DEBUG_VERBOSE 1' >> opt_bwi.h + +.include From laffer1 at midnightbsd.org Mon Jan 19 17:10:33 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:10:33 -0500 (EST) Subject: [Midnightbsd-cvs] src: README: Describe firmware situation. Message-ID: <200901192210.n0JMAXHi075701@stargazer.midnightbsd.org> Log Message: ----------- Describe firmware situation. (damn binary blobs) Added Files: ----------- src/sys/contrib/dev/bwi: README (r1.1) -------------- next part -------------- --- /dev/null +++ sys/contrib/dev/bwi/README @@ -0,0 +1,16 @@ +The bwi firmware is not available for distribution +with MidnightBSD. You must find it on the Internet. + +Look for v3 firmware. v4 will not work. Any device +requiring the newer firmware is not supported. + +One might find files like: + +a0g0bsinitvals2.fw b0g0bsinitvals2.fw ucode11.fw +a0g0bsinitvals5.fw b0g0bsinitvals5.fw ucode2.fw +a0g0initvals2.fw b0g0initvals2.fw ucode4.fw +a0g0initvals5.fw b0g0initvals5.fw ucode5.fw +a0g1bsinitvals5.fw pcm4.fw +a0g1initvals5.fw pcm5.fw + +$MidnightBSD: src/sys/contrib/dev/bwi/README,v 1.1 2009/01/19 22:10:32 laffer1 Exp $ From laffer1 at midnightbsd.org Mon Jan 19 17:11:08 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:11:08 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Add firmware makefile Message-ID: <200901192211.n0JMB8e8075798@stargazer.midnightbsd.org> Log Message: ----------- Add firmware makefile Added Files: ----------- src/sys/modules/bwifw: Makefile (r1.1) -------------- next part -------------- --- /dev/null +++ sys/modules/bwifw/Makefile @@ -0,0 +1,35 @@ +# $MidnightBSD: src/sys/modules/bwifw/Makefile,v 1.1 2009/01/19 22:11:07 laffer1 Exp $ + +.PATH: ${.CURDIR}/../../contrib/dev/bwi + +FWNAME= bwi_v3 +FWFILE= wl_apsta.o +_FWIMGS=ucode11 ucode2 ucode4 ucode5 \ + a0g0bsinitvals2 a0g0bsinitvals5 a0g0initvals2 \ + a0g0initvals5 a0g1bsinitvals5 a0g1initvals5 \ + b0g0bsinitvals2 b0g0bsinitvals5 b0g0initvals2 b0g0initvals5 \ + pcm4 pcm5 +FWIMGS= ${_FWIMGS:C/.*/&.fw/} +#CLEANFILES+=${FWFILE} ${FWIMGS} v3 + +#SUBDIR= fwcutter +#FWCUTTER= fwcutter/b43-fwcutter + +KMOD= ${FWNAME} +FIRMWS= ${_FWIMGS:C/.*/&.fw:${KMOD}_&/} + +bwi_v3: ${FWIMGS} + +# NB: the cutter has v3/v4 pathname prefixes built-in; yech +#${FWIMGS}: ${FWCUTTER} ${FWFILE} +# ln -s . v3; ${FWCUTTER} -w . ${FWFILE}; rm v3 + +${FWCUTTER}: fwcutter + +# NB: can't get make to use .PATH so do it explicitly +#BWI = ${.CURDIR}/../../contrib/dev/bwi + +#${FWFILE}: ${FWFILE}.uu +# uudecode -p < ${BWI}/${FWFILE}.uu > ${.TARGET} + +.include From laffer1 at midnightbsd.org Mon Jan 19 17:19:40 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:19:40 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/conf: Add bwi Message-ID: <200901192219.n0JMJeJB076487@stargazer.midnightbsd.org> Log Message: ----------- Add bwi Modified Files: -------------- src/sys/conf: files (r1.13 -> r1.14) options (r1.7 -> r1.8) -------------- next part -------------- Index: options =================================================================== RCS file: /home/cvs/src/sys/conf/options,v retrieving revision 1.7 retrieving revision 1.8 diff -L sys/conf/options -L sys/conf/options -u -r1.7 -r1.8 --- sys/conf/options +++ sys/conf/options @@ -723,6 +723,10 @@ ATH_DIAGAPI opt_ath.h ATH_TX99_DIAG opt_ath.h +# options for Broadcom wireless driver +BWI_DEBUG opt_bwi.h +BWI_DEBUG_VERBOSE opt_bwi.h + # dcons options DCONS_BUF_SIZE opt_dcons.h DCONS_POLL_HZ opt_dcons.h Index: files =================================================================== RCS file: /home/cvs/src/sys/conf/files,v retrieving revision 1.13 retrieving revision 1.14 diff -L sys/conf/files -L sys/conf/files -u -r1.13 -r1.14 --- sys/conf/files +++ sys/conf/files @@ -493,6 +493,11 @@ dev/bktr/bktr_os.c optional bktr pci dev/bktr/bktr_tuner.c optional bktr pci dev/bktr/msp34xx.c optional bktr pci +dev/bwi/if_bwi.c optional bwi +dev/bwi/if_bwi_pci.c optional bwi pci +dev/bwi/bwimac.c optional bwi +dev/bwi/bwiphy.c optional bwi +dev/bwi/bwirf.c optional bwi dev/buslogic/bt.c optional bt dev/buslogic/bt_eisa.c optional bt eisa dev/buslogic/bt_isa.c optional bt isa From laffer1 at midnightbsd.org Mon Jan 19 17:22:52 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:22:52 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/bwi: don't enable BWI_DEBUG here, use the opt_bwi.h for that. Message-ID: <200901192222.n0JMMqkY076958@stargazer.midnightbsd.org> Log Message: ----------- don't enable BWI_DEBUG here, use the opt_bwi.h for that. Modified Files: -------------- src/sys/dev/bwi: bwimac.c (r1.1 -> r1.2) bwirf.c (r1.1 -> r1.2) if_bwi.c (r1.1 -> r1.2) if_bwivar.h (r1.1 -> r1.2) -------------- next part -------------- Index: if_bwivar.h =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/if_bwivar.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/if_bwivar.h -L sys/dev/bwi/if_bwivar.h -u -r1.1 -r1.2 --- sys/dev/bwi/if_bwivar.h +++ sys/dev/bwi/if_bwivar.h @@ -85,7 +85,6 @@ #define CSR_CLRBITS_2(sc, reg, bits) \ CSR_WRITE_2((sc), (reg), CSR_READ_2((sc), (reg)) & ~(bits)) -#define BWI_DEBUG #ifdef BWI_DEBUG #define DPRINTF(sc, fmt, ...) device_printf(sc->sc_dev, fmt, __VA_ARGS__) #else Index: bwirf.c =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/bwirf.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/bwirf.c -L sys/dev/bwi/bwirf.c -u -r1.1 -r1.2 --- sys/dev/bwi/bwirf.c +++ sys/dev/bwi/bwirf.c @@ -38,6 +38,7 @@ #include #include "opt_inet.h" +#include "opt_bwi.h" #include #include Index: bwimac.c =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/bwimac.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/bwimac.c -L sys/dev/bwi/bwimac.c -u -r1.1 -r1.2 --- sys/dev/bwi/bwimac.c +++ sys/dev/bwi/bwimac.c @@ -38,6 +38,7 @@ #include #include "opt_inet.h" +#include "opt_bwi.h" #include #include Index: if_bwi.c =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/if_bwi.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/if_bwi.c -L sys/dev/bwi/if_bwi.c -u -r1.1 -r1.2 --- sys/dev/bwi/if_bwi.c +++ sys/dev/bwi/if_bwi.c @@ -38,6 +38,7 @@ #include #include "opt_inet.h" +#include "opt_bwi.h" #include #include From laffer1 at midnightbsd.org Mon Jan 19 17:28:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:28:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: man/man4: Add bwi.4 (initial man page) from DragonFly Message-ID: <200901192228.n0JMScgs077623@stargazer.midnightbsd.org> Log Message: ----------- Add bwi.4 (initial man page) from DragonFly Modified Files: -------------- src/share/man/man4: Makefile (r1.11 -> r1.12) Added Files: ----------- src/share/man/man4: bwi.4 (r1.1) -------------- next part -------------- --- /dev/null +++ share/man/man4/bwi.4 @@ -0,0 +1,123 @@ +.\" +.\" Copyright (c) 2007 The DragonFly Project. All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in +.\" the documentation and/or other materials provided with the +.\" distribution. +.\" 3. Neither the name of The DragonFly Project nor the names of its +.\" contributors may be used to endorse or promote products derived +.\" from this software without specific, prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +.\" LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +.\" FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +.\" COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, +.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +.\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +.\" AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +.\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +.\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $MidnightBSD: src/share/man/man4/bwi.4,v 1.1 2009/01/19 22:28:38 laffer1 Exp $ +.\" $DragonFly: src/share/man/man4/bwi.4,v 1.8 2008/05/01 12:34:06 sephe Exp $ +.\" +.Dd January 19, 2009 +.Dt BWI 4 +.Os +.Sh NAME +.Nm bwi +.Nd Broadcom BCM430x/4318 IEEE 802.11b/g wireless network driver +.Sh SYNOPSIS +To load the driver as a module at boot time, place the +following line in +.Pa /boot/loader.conf : +.Bd -literal -offset indent +if_bwi_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for Broadcom BCM430x/4318 wireless network adapters. +For more information on configuring this device, see +.Xr ifconfig 8 . +.Ss MIB Variables +The following per-interface variables are implemented in the +.Va hw.bwi Ns Em X +branch of the +.Xr sysctl 3 +MIB. +.Bl -tag -width ".Va txpwr_calib" +.It Va debug +Debug flags. +.It Va dwell_time +Channel dwell time during scan (msec). +.It Va fw_version +Firmware version. +.It Va led_idle +Number of ticks before LED enters idle state. +.It Va led_blink +Allow LED to blink. +.It Va txpwr_calib +Enable software TX power calibration. +.El +.Sh HARDWARE +The following cards are among those supported by the +.Nm +driver: +.Pp +.Bl -column -compact "Buffalo WLI-PCI-G54S" "BCM4318" "CardBus" "b/g" -offset 6n +.Em "Card Chip Bus Standard" +Linksys WPC54Gv3 BCM4318 CardBus b/g +Linksys WPC54GSv2 BCM4318 CardBus b/g +Buffalo WLI-CB-G54S BCM4318 CardBus b/g +Buffalo WLI-PCI-G54S BCM4306 PCI b/g +Dell Wireless 1470 BCM4318 Mini PCI b/g +Dell Truemobile 1400 BCM4309 Mini PCI b/g +.El +.Sh FILES +The firmware for the adapter is not shipped with +.Dx +and must be obtained separately. +An archive with firmware files that are known to work can be found at: +.Bd -literal -offset indent +http://leaf.dragonflybsd.org/~sephe/bwi/v3.tbz +.Ed +.Pp +The firmware files have to reside in +.Pa /etc/firmware/bwi +and will be loaded when the interface is brought up. +.Sh SEE ALSO +.Xr arp 4 , +.Xr cardbus 4 , +.Xr ifmedia 4 , +.Xr pci 4 , +.Xr wlan_ratectl 4 , +.Xr ifconfig 8 , +.Xr wpa_supplicant 8 +.Sh HISTORY +The +.Nm +driver first appeared in +.Dx 1.11 . +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Sepherosa Ziehau . +.Pp +The hardware specification was reverse engineered by the people at +.Pa http://bcm-specs.sipsolutions.net . +Thanks go also to johill and mb on the #bcm-specs channel. +.Sh BUGS +BCM4306 and BCM4309 chips do not work properly on channel 1, 2 and 3. Index: Makefile =================================================================== RCS file: /home/cvs/src/share/man/man4/Makefile,v retrieving revision 1.11 retrieving revision 1.12 diff -L share/man/man4/Makefile -L share/man/man4/Makefile -u -r1.11 -r1.12 --- share/man/man4/Makefile +++ share/man/man4/Makefile @@ -39,6 +39,7 @@ bpf.4 \ bridge.4 \ bt.4 \ + bwi.4 \ cardbus.4 \ carp.4 \ ccd.4 \ From laffer1 at midnightbsd.org Mon Jan 19 17:40:09 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:40:09 -0500 (EST) Subject: [Midnightbsd-cvs] src: bwi.4: Document the "temporary" firmware installation procedure and Message-ID: <200901192240.n0JMe9oK079005@stargazer.midnightbsd.org> Log Message: ----------- Document the "temporary" firmware installation procedure and make a few other adjustments for MidnightBSD. This must get better. Modified Files: -------------- src/share/man/man4: bwi.4 (r1.1 -> r1.2) -------------- next part -------------- Index: bwi.4 =================================================================== RCS file: /home/cvs/src/share/man/man4/bwi.4,v retrieving revision 1.1 retrieving revision 1.2 diff -L share/man/man4/bwi.4 -L share/man/man4/bwi.4 -u -r1.1 -r1.2 --- share/man/man4/bwi.4 +++ share/man/man4/bwi.4 @@ -86,16 +86,20 @@ .El .Sh FILES The firmware for the adapter is not shipped with -.Dx +.Mx and must be obtained separately. An archive with firmware files that are known to work can be found at: .Bd -literal -offset indent http://leaf.dragonflybsd.org/~sephe/bwi/v3.tbz .Ed .Pp -The firmware files have to reside in -.Pa /etc/firmware/bwi -and will be loaded when the interface is brought up. +The firmware files are built as part of the bwifw module and +must be loaded for +.Nm +to work. Place the files in +.Pa /usr/src/sys/contrib/dev/bwi +and build bwifw in +.Pa /usr/src/sys/modules/bwifw .Sh SEE ALSO .Xr arp 4 , .Xr cardbus 4 , @@ -108,13 +112,21 @@ The .Nm driver first appeared in -.Dx 1.11 . +.Dx 1.11 +and +.Mx 0.3 .Sh AUTHORS .An -nosplit The .Nm driver was written by .An Sepherosa Ziehau . +It was later ported to +.Fx 7.0 , +then brought into +.Mx 0.3 +by +.An Lucas Holt . .Pp The hardware specification was reverse engineered by the people at .Pa http://bcm-specs.sipsolutions.net . From laffer1 at midnightbsd.org Tue Jan 20 10:32:52 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 10:32:52 -0500 (EST) Subject: [Midnightbsd-cvs] mports: Makefile: science was missing Message-ID: <200901201532.n0KFWqBX088628@stargazer.midnightbsd.org> Log Message: ----------- science was missing Modified Files: -------------- mports: Makefile (r1.39 -> r1.40) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/Makefile,v retrieving revision 1.39 retrieving revision 1.40 diff -L Makefile -L Makefile -u -r1.39 -r1.40 --- Makefile +++ Makefile @@ -35,6 +35,7 @@ SUBDIR += palm SUBDIR += ports-mgmt SUBDIR += print +SUBDIR += science SUBDIR += security SUBDIR += shells SUBDIR += sysutils From laffer1 at midnightbsd.org Tue Jan 20 10:33:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 10:33:48 -0500 (EST) Subject: [Midnightbsd-cvs] mports: Makefile: tweak whitespace Message-ID: <200901201533.n0KFXmev088736@stargazer.midnightbsd.org> Log Message: ----------- tweak whitespace Modified Files: -------------- mports/science: Makefile (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/science/Makefile,v retrieving revision 1.3 retrieving revision 1.4 diff -L science/Makefile -L science/Makefile -u -r1.3 -r1.4 --- science/Makefile +++ science/Makefile @@ -1,8 +1,8 @@ # $MidnightBSD$ - COMMENT= science +COMMENT= science - SUBDIR += cfitsio - SUBDIR += openbabel +SUBDIR += cfitsio +SUBDIR += openbabel .include From laffer1 at midnightbsd.org Tue Jan 20 10:35:13 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 10:35:13 -0500 (EST) Subject: [Midnightbsd-cvs] mports: mports/dns: Change the description to something a little more Message-ID: <200901201535.n0KFZDHr089139@stargazer.midnightbsd.org> Log Message: ----------- Change the description to something a little more reasonable. Modified Files: -------------- mports/dns: Makefile (r1.15 -> r1.16) mports/science: Makefile (r1.4 -> r1.5) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/dns/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -L dns/Makefile -L dns/Makefile -u -r1.15 -r1.16 --- dns/Makefile +++ dns/Makefile @@ -1,22 +1,21 @@ # $MidnightBSD$ -# - COMMENT = Domain Name Service tools +COMMENT = Domain Name Service tools - SUBDIR += ares - SUBDIR += bind9 - SUBDIR += bind94 - SUBDIR += bind95 - SUBDIR += bindgraph - SUBDIR += c-ares - SUBDIR += ddclient - SUBDIR += ez-ipupdate - SUBDIR += inadyn - SUBDIR += libidn - SUBDIR += mdnsd - SUBDIR += nslint - SUBDIR += p5-Net-DNS - SUBDIR += p5-Net-DNS-Resolver-Programmable - SUBDIR += pdnsd +SUBDIR += ares +SUBDIR += bind9 +SUBDIR += bind94 +SUBDIR += bind95 +SUBDIR += bindgraph +SUBDIR += c-ares +SUBDIR += ddclient +SUBDIR += ez-ipupdate +SUBDIR += inadyn +SUBDIR += libidn +SUBDIR += mdnsd +SUBDIR += nslint +SUBDIR += p5-Net-DNS +SUBDIR += p5-Net-DNS-Resolver-Programmable +SUBDIR += pdnsd .include Index: Makefile =================================================================== RCS file: /home/cvs/mports/science/Makefile,v retrieving revision 1.4 retrieving revision 1.5 diff -L science/Makefile -L science/Makefile -u -r1.4 -r1.5 --- science/Makefile +++ science/Makefile @@ -1,6 +1,6 @@ # $MidnightBSD$ -COMMENT= science +COMMENT= Scientific applications SUBDIR += cfitsio SUBDIR += openbabel From laffer1 at midnightbsd.org Tue Jan 20 11:32:51 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 11:32:51 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Disable debugging by default, but leave the option handy Message-ID: <200901201632.n0KGWpIQ047056@stargazer.midnightbsd.org> Log Message: ----------- Disable debugging by default, but leave the option handy for me. Modified Files: -------------- src/sys/modules/bwi: Makefile (r1.1 -> r1.2) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/bwi/Makefile,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/modules/bwi/Makefile -L sys/modules/bwi/Makefile -u -r1.1 -r1.2 --- sys/modules/bwi/Makefile +++ sys/modules/bwi/Makefile @@ -8,7 +8,7 @@ SRCS+= device_if.h bus_if.h pci_if.h opt_inet.h opt_bwi.h opt_bwi.h: - echo '#define BWI_DEBUG 1' > opt_bwi.h - echo '#define BWI_DEBUG_VERBOSE 1' >> opt_bwi.h + echo '#define BWI_DEBUG 0' > opt_bwi.h +# echo '#define BWI_DEBUG_VERBOSE 1' >> opt_bwi.h .include From laffer1 at midnightbsd.org Tue Jan 20 12:39:35 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 12:39:35 -0500 (EST) Subject: [Midnightbsd-cvs] src: NOTES: add bwi(4) Message-ID: <200901201739.n0KHdZ15055454@stargazer.midnightbsd.org> Log Message: ----------- add bwi(4) Modified Files: -------------- src/sys/i386/conf: NOTES (r1.7 -> r1.8) -------------- next part -------------- Index: NOTES =================================================================== RCS file: /home/cvs/src/sys/i386/conf/NOTES,v retrieving revision 1.7 retrieving revision 1.8 diff -L sys/i386/conf/NOTES -L sys/i386/conf/NOTES -u -r1.7 -r1.8 --- sys/i386/conf/NOTES +++ sys/i386/conf/NOTES @@ -574,6 +574,7 @@ # (requires sppp) # arl: Aironet Arlan 655 wireless adapters. # ath: Atheros a/b/g WiFi adapters (requires ath_hal and wlan) +# bwi: Broadcom WiFi adapters. # ce: Cronyx Tau-PCI/32 sync single/dual port G.703/E1 serial adaptor # with 32 HDLC subchannels (requires sppp (default), or NETGRAPH if # NETGRAPH_CRONYX is configured) @@ -683,6 +684,8 @@ device ath_rate_sample # SampleRate rate control for the ath driver #device wlan # 802.11 layer +device bwi # Broadcom wireless 430x + # # ATA raid adapters # From laffer1 at midnightbsd.org Tue Jan 20 12:40:39 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 12:40:39 -0500 (EST) Subject: [Midnightbsd-cvs] src: DEFAULTS: Midnightize this Message-ID: <200901201740.n0KHedAL055815@stargazer.midnightbsd.org> Log Message: ----------- Midnightize this Modified Files: -------------- src/sys/i386/conf: DEFAULTS (r1.2 -> r1.3) -------------- next part -------------- Index: DEFAULTS =================================================================== RCS file: /home/cvs/src/sys/i386/conf/DEFAULTS,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/i386/conf/DEFAULTS -L sys/i386/conf/DEFAULTS -u -r1.2 -r1.3 --- sys/i386/conf/DEFAULTS +++ sys/i386/conf/DEFAULTS @@ -1,6 +1,7 @@ # -# DEFAULTS -- Default kernel configuration file for FreeBSD/i386 +# DEFAULTS -- Default kernel configuration file for MidnightBSD/i386 # +# $MidnightBSD$ # $FreeBSD: src/sys/i386/conf/DEFAULTS,v 1.10 2007/06/11 00:38:06 marcel Exp $ machine i386 From laffer1 at midnightbsd.org Tue Jan 20 12:45:25 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 12:45:25 -0500 (EST) Subject: [Midnightbsd-cvs] src: GENERIC: add commented out bwi(4) Message-ID: <200901201745.n0KHjPHV056426@stargazer.midnightbsd.org> Log Message: ----------- add commented out bwi(4) Modified Files: -------------- src/sys/i386/conf: GENERIC (r1.16 -> r1.17) -------------- next part -------------- Index: GENERIC =================================================================== RCS file: /home/cvs/src/sys/i386/conf/GENERIC,v retrieving revision 1.16 retrieving revision 1.17 diff -L sys/i386/conf/GENERIC -L sys/i386/conf/GENERIC -u -r1.16 -r1.17 --- sys/i386/conf/GENERIC +++ sys/i386/conf/GENERIC @@ -251,6 +251,8 @@ device ath_hal # Atheros Hardwar Abstraction Layer device ath_rate_sample # Atheros rate sampling. device awi # BayStack 660 and others +#device bwi # Broadcom Wireless 4300 +#device bwifw # Broadcom Wireless firmware (normally module) device ral # Ralink Technology RT2500 wireless NICs. device wi # WaveLAN/Intersil/Symbol 802.11 wireless NICs. #device wl # Older non 802.11 Wavelan wireless NIC. From laffer1 at midnightbsd.org Tue Jan 20 13:18:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 13:18:19 -0500 (EST) Subject: [Midnightbsd-cvs] src: GENERIC: Switch to new wiki page for documenation on kernel Message-ID: <200901201818.n0KIIJuf059867@stargazer.midnightbsd.org> Log Message: ----------- Switch to new wiki page for documenation on kernel Modified Files: -------------- src/sys/i386/conf: GENERIC (r1.17 -> r1.18) -------------- next part -------------- Index: GENERIC =================================================================== RCS file: /home/cvs/src/sys/i386/conf/GENERIC,v retrieving revision 1.17 retrieving revision 1.18 diff -L sys/i386/conf/GENERIC -L sys/i386/conf/GENERIC -u -r1.17 -r1.18 --- sys/i386/conf/GENERIC +++ sys/i386/conf/GENERIC @@ -1,10 +1,7 @@ # # GENERIC -- Generic kernel configuration file for MidnightBSD/i386 # -# The FreeBSD handbook is a good reference for kernel configuration information -# until we write our own documentation. -# -# http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html +# http://www.midnightbsd.org/wiki/KernelConfig # # An exhaustive list of options and more detailed explanations of the # device lines is also present in the ../../conf/NOTES and NOTES files. From laffer1 at midnightbsd.org Tue Jan 20 13:50:01 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 13:50:01 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/usb: add HUAWEI E220 Modem Message-ID: <200901201850.n0KIo13p063514@stargazer.midnightbsd.org> Log Message: ----------- add HUAWEI E220 Modem Modified Files: -------------- src/sys/dev/usb: ubsa.c (r1.3 -> r1.4) usbdevs (r1.4 -> r1.5) -------------- next part -------------- Index: usbdevs =================================================================== RCS file: /home/cvs/src/sys/dev/usb/usbdevs,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/usb/usbdevs -L sys/dev/usb/usbdevs -u -r1.4 -r1.5 --- sys/dev/usb/usbdevs +++ sys/dev/usb/usbdevs @@ -1382,6 +1382,7 @@ /* HUAWEI products */ product HUAWEI MOBILE 0x1001 Huawei Mobile +product HUAWEI E220 0x1003 Huawei E220 HSDPA USB Modem /* HUAWEI 3com products */ product HUAWEI3COM WUB320G 0x0009 Aolynk WUB320g Index: ubsa.c =================================================================== RCS file: /home/cvs/src/sys/dev/usb/ubsa.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/dev/usb/ubsa.c -L sys/dev/usb/ubsa.c -u -r1.3 -r1.4 --- sys/dev/usb/ubsa.c +++ sys/dev/usb/ubsa.c @@ -235,6 +235,8 @@ { USB_VENDOR_OPTION, USB_PRODUCT_OPTION_GT3GPLUS }, /* Huawei Mobile */ { USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_MOBILE }, + /* Huawei E220 USB Modem */ + { USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_E220 }, { 0, 0 } }; From laffer1 at midnightbsd.org Tue Jan 20 13:51:43 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 13:51:43 -0500 (EST) Subject: [Midnightbsd-cvs] src: ubsa.4: add Huawei Technologies Mobile and E220 G3 Modem Message-ID: <200901201851.n0KIphNO063915@stargazer.midnightbsd.org> Log Message: ----------- add Huawei Technologies Mobile and E220 G3 Modem Modified Files: -------------- src/share/man/man4: ubsa.4 (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: ubsa.4 =================================================================== RCS file: /home/cvs/src/share/man/man4/ubsa.4,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man4/ubsa.4 -L share/man/man4/ubsa.4 -u -r1.1.1.1 -r1.2 --- share/man/man4/ubsa.4 +++ share/man/man4/ubsa.4 @@ -71,6 +71,8 @@ .It Peracom single port serial adapter .It +Huawei Technologies Mobile and E220 G3 Modem +.It Vodafone Mobile Connect 3G datacard .El .Sh SEE ALSO From laffer1 at midnightbsd.org Tue Jan 20 14:29:07 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:29:07 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: use pause(9) instead of a tsleep() on a stack variable Message-ID: <200901201929.n0KJT7gR067802@stargazer.midnightbsd.org> Log Message: ----------- use pause(9) instead of a tsleep() on a stack variable Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.2 -> r1.3) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.2 -r1.3 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -3291,7 +3291,7 @@ return; } - tsleep(&error, PWAIT, "ssidscan", hz * 3); + pause("ssidscan", hz * 3); if (!NDIS_INITIALIZED(sc)) /* The interface was downed while we were sleeping */ return; From laffer1 at midnightbsd.org Tue Jan 20 14:32:22 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:32:22 -0500 (EST) Subject: [Midnightbsd-cvs] src: man/man9: remove old man pages Message-ID: <200901201932.n0KJWMrA068604@stargazer.midnightbsd.org> Log Message: ----------- remove old man pages Removed Files: ------------- src/share/man/man9: MUTEX_PROFILING.9 VFS_VPTOFH.9 devsw.9 vm_page_unmanage.9 -------------- next part -------------- --- share/man/man9/vm_page_unmanage.9 +++ /dev/null @@ -1,57 +0,0 @@ -.\" -.\" Copyright (C) 2001 Chad David . All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice(s), this list of conditions and the following disclaimer as -.\" the first lines of this file unmodified other than the possible -.\" addition of one or more copyright notices. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice(s), this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY -.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY -.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -.\" DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/vm_page_unmanage.9,v 1.3 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD: src/share/man/man9/vm_page_unmanage.9,v 1.2 2006/12/27 03:04:25 laffer1 Exp $ -.\" -.Dd July 17, 2001 -.Dt VM_PAGE_UNMANAGE 9 -.Os -.Sh NAME -.Nm vm_page_unmanage -.Nd "make a page unmanaged" -.Sh SYNOPSIS -.In sys/param.h -.In vm/vm.h -.In vm/vm_page.h -.Ft void -.Fn vm_page_unmanage "vm_page_t m" -.Sh DESCRIPTION -The -.Fn vm_page_unmanage -function flags that the page should no longer be managed by the VM system like -other pages. -The page is removed from any page queue it may be on, and after its -.Dv PG_UNMANAGED -flag is set, the page daemon will ignore it (if the page is -currently wired, it will not be removed from its current queue). -.Pp -Unmanaged pages are used by -.Dv OBJT_PHYS -objects to provide physical memory backed storage. -.Sh AUTHORS -This manual page was written by -.An Chad David Aq davidc at acns.ab.ca . --- share/man/man9/devsw.9 +++ /dev/null @@ -1,76 +0,0 @@ -.\" -.\" Copyright (C) 2001 Chad David . All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice(s), this list of conditions and the following disclaimer as -.\" the first lines of this file unmodified other than the possible -.\" addition of one or more copyright notices. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice(s), this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY -.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY -.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -.\" DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/devsw.9,v 1.7 2005/06/28 20:15:18 hmp Exp $ -.\" -.Dd July 9, 2001 -.Dt DEVSW 9 -.Os -.Sh NAME -.Nm devsw -.Nd returns the -.Vt cdevsw -structure -.Sh SYNOPSIS -.In sys/param.h -.In sys/conf.h -.Ft "struct cdevsw *" -.Fn devsw "dev_t dev" -.Sh DESCRIPTION -The -.Fn devsw -function returns a pointer to the -.Vt cdevsw -structure associated -with this character device ID. -If -.Fa dev->si_cdevsw -is set it is -returned; otherwise, the -.Xr major 9 -offset into the -.Va cdevsw -array is returned. -.Pp -Its argument is: -.Bl -tag -width ".Fa dev" -.It Fa dev -The device whose -.Vt cdevsw -entry should be returned. -.El -.Sh RETURN VALUES -A pointer to a -.Vt cdevsw -structure. -.Sh SEE ALSO -.Xr major 9 , -.Xr minor 9 , -.Xr umajor 9 , -.Xr uminor 9 -.Sh AUTHORS -This manual page was written by -.An Chad David Aq davidc at acns.ab.ca . --- share/man/man9/MUTEX_PROFILING.9 +++ /dev/null @@ -1,189 +0,0 @@ -.\"- -.\" Copyright (c) 2004 Dag-Erling Co?dan Sm?rgrav -.\" Copyright (c) 2005 Robert N. M. Watson -.\" All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice, this list of conditions and the following disclaimer. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice, this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" 3. The name of the author may not be used to endorse or promote products -.\" derived from this software without specific prior written permission. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -.\" SUCH DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/MUTEX_PROFILING.9,v 1.11 2005/06/15 13:31:23 ru Exp $ -.\" -.Dd January 7, 2005 -.Dt MUTEX_PROFILING 9 -.Os -.Sh NAME -.Nm MUTEX_PROFILING -.Nd kernel mutex profiling support -.Sh SYNOPSIS -.Cd "options MUTEX_PROFILING" -.Sh DESCRIPTION -The -.Dv MUTEX_PROFILING -kernel option adds support for measuring and reporting mutex use and -contention statistics. -These statistics are collated by -.Dq acquisition point . -Acquisition points are -distinct places in the kernel source code (identified by source file -name and line number) where a mutex is acquired. -.Pp -For each acquisition point, the following statistics are accumulated: -.Bl -bullet -.It -The total number of non-recursive acquisitions. -.It -The total time the mutex was held after being acquired at this point. -.It -The longest time the mutex was ever continuously held after being -acquired at this point. -.It -The total number of times the mutex was already held by another thread -when this point was reached, requiring a spin or a sleep. -.It -The total number of time another thread tried to acquire the mutex -while it was held after having been acquired at this point. -.El -.Pp -In addition, the average hold time is derived from the total hold time -and the number of acquisitions. -.Pp -The -.Dv MUTEX_PROFILING -kernel option also adds the following -.Xr sysctl 8 -variables to control and monitor the profiling code: -.Bl -tag -width indent -.It Va debug.mutex.prof.enable -Enable or disable the mutex profiling code. -This defaults to 0 (off). -.It Va debug.mutex.prof.reset -Reset the current mutex profiling buffers. -.It Va debug.mutex.prof.acquisitions -The total number of mutex acquisitions recorded. -.It Va debug.mutex.prof.records -The total number of acquisition points recorded. -Note that only active acquisition points (i.e., points that have been -reached at least once) are counted. -.It Va debug.mutex.prof.maxrecords -The maximum number of acquisition points the profiling code is capable -of monitoring. -Since it would not be possible to call -.Xr malloc 9 -from within the mutex profiling code, this is a static limit. -The number of records can be changed with the -.Dv MPROF_BUFFERS -kernel option. -.It Va debug.mutex.prof.rejected -The number of acquisition points that were ignored after the table -filled up. -.It Va debug.mutex.prof.hashsize -The size of the hash table used to map acquisition points to -statistics records. -The hash size can be changed with the -.Dv MPROF_HASH_SIZE -kernel option. -.It Va debug.mutex.prof.collisions -The number of hash collisions in the acquisition point hash table. -.It Va debug.mutex.prof.stats -The actual profiling statistics in plain text. -The columns are as follows, from left to right: -.Bl -tag -width ".Va cnt_hold" -.It Va max -The longest continuous hold time in microseconds. -.It Va total -The total (accumulated) hold time in microseconds. -.It Va count -The total number of acquisitions. -.It Va avg -The average hold time in microseconds, derived from the total hold time -and the number of acquisitions. -.It Va cnt_hold -The number of times the mutex was held and another thread attempted to -lock the mutex. -.It Va cnt_lock -The number of times the mutex was already locked when this point was -reached. -.It Va name -The name of the acquisition point, derived from the source file name -and line number, followed by the name of the mutex in parentheses. -.El -.El -.Sh SEE ALSO -.Xr sysctl 8 , -.Xr mutex 9 -.Sh HISTORY -Mutex profiling support appeared in -.Fx 5.0 . -.Sh AUTHORS -.An -nosplit -The -.Nm -code was written by -.An Eivind Eklund Aq eivind at FreeBSD.org , -.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org -and -.An Robert Watson Aq rwatson at FreeBSD.org . -This manual page was written by -.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org . -.Sh NOTES -The -.Dv MUTEX_PROFILING -option increases the size of -.Vt "struct mtx" , -so a kernel built with that option will not work with modules built -without it. -.Pp -The -.Dv MUTEX_PROFILING -option also prevents inlining of the mutex code, which results in a -fairly severe performance penalty. -It should therefore only be enabled on systems where mutex profiling -is actually needed. -.Dv MUTEX_PROFILING -will introduce a substantial performance overhead that is easily -monitorable using other profiling tools, so combining profiling tools -with -.Dv MUTEX_PROFILING -is not recommended. -.Pp -Measurements are made and stored in nanoseconds using -.Xr nanotime 9 , -but are presented in microseconds. -This should still be sufficient for the locks one would be most -interested in profiling (those that are held long and/or acquired -often). -.Pp -.Dv MUTEX_PROFILING -should generally not be used in combination with other debugging options, as -the results may be strongly affected by interactions between the features. -In particular, -.Dv MUTEX_PROFILING -will report higher than normal -.Xr uma 9 -lock contention when run with -.Dv INVARIANTS -due to extra locking that occurs when -.Dv INVARIANTS -is present; likewise, using it in combination with -.Dv WITNESS -will lead to much higher lock hold times and contention in profiling output. --- share/man/man9/VFS_VPTOFH.9 +++ /dev/null @@ -1,61 +0,0 @@ -.\" -*- nroff -*- -.\" -.\" Copyright (c) 1996 Doug Rabson -.\" -.\" All rights reserved. -.\" -.\" This program is free software. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice, this list of conditions and the following disclaimer. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice, this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR -.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES -.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, -.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT -.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF -.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/VFS_VPTOFH.9,v 1.9 2003/10/23 06:24:55 hmp Exp $ -.\" -.Dd July 24, 1996 -.Os -.Dt VFS_VPTOFH 9 -.Sh NAME -.Nm VFS_VPTOFH -.Nd turn a vnode into an NFS filehandle -.Sh SYNOPSIS -.In sys/param.h -.In sys/mount.h -.In sys/vnode.h -.Ft int -.Fn VFS_VPTOFH "struct vnode *vp" "struct fid *fhp" -.Sh DESCRIPTION -This is used by the NFS server to create an opaque filehandle which -uniquely identifies the file and which can be used by an NFS client -to access the file in the future. -.Pp -Its arguments are: -.Bl -tag -width fhp -.It Fa vp -The vnode to make a filehandle for. -.It Fa fhp -Return parameter for the filehandle. -.El -.Sh SEE ALSO -.Xr VFS 9 , -.Xr VFS_FHTOVP 9 , -.Xr vnode 9 -.Sh AUTHORS -This manual page was written by -.An Doug Rabson . From laffer1 at midnightbsd.org Tue Jan 20 14:37:49 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:37:49 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: stop kernel panics when ndis fails to attach and it's Message-ID: <200901201937.n0KJbn4c069182@stargazer.midnightbsd.org> Log Message: ----------- stop kernel panics when ndis fails to attach and it's not a wifi device Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.3 -> r1.4) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.3 -r1.4 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -966,7 +966,8 @@ } else NDIS_UNLOCK(sc); - taskqueue_drain(sc->ndis_tq, &sc->ndis_scantask); + if (sc->ndis_80211) + taskqueue_drain(sc->ndis_tq, &sc->ndis_scantask); if (sc->ndis_tickitem != NULL) IoFreeWorkItem(sc->ndis_tickitem); @@ -1025,7 +1026,8 @@ if (sc->ndis_iftype == PCIBus) bus_dma_tag_destroy(sc->ndis_parent_tag); - taskqueue_free(sc->ndis_tq); + if (sc->ndis_80211) + taskqueue_free(sc->ndis_tq); return(0); } From laffer1 at midnightbsd.org Tue Jan 20 14:40:54 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:40:54 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: Fix a problem with broadcom and marvell wifi using ndis. Message-ID: <200901201940.n0KJes3q069600@stargazer.midnightbsd.org> Log Message: ----------- Fix a problem with broadcom and marvell wifi using ndis. Scan results are not stored properly as some do not give a desired buffer length. Make a default. This fixes problems with some macbooks too Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.4 -> r1.5) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.4 -r1.5 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -2544,13 +2544,20 @@ return(ENOENT); } - len = 4; - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, NULL, &len); - if (error != ENOSPC) - len = 65536; + len = sizeof(uint32_t) + (sizeof(ndis_wlan_bssid_ex) * 16); + bl = malloc(len, M_TEMP, M_NOWAIT | M_ZERO); + if (bl == NULL) + return (ENOMEM); - bl = malloc(len, M_TEMP, M_NOWAIT|M_ZERO); error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + if (error == ENOSPC) { + free(bl, M_TEMP); + bl = malloc(len, M_TEMP, M_NOWAIT | M_ZERO); + if (bl == NULL) + return (ENOMEM); + + error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + } if (error) { free(bl, M_TEMP); device_printf(sc->ndis_dev, "bssid_list failed\n"); @@ -3317,13 +3324,22 @@ uint8_t rates[2+IEEE80211_RATE_MAXSIZE]; uint8_t *frm, *efrm; - len = 0; noise = -96; - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, NULL, &len); - if (error != ENOSPC) - len = 65536; + + len = sizeof(uint32_t) + (sizeof(ndis_wlan_bssid_ex) * 16); bl = malloc(len, M_DEVBUF, M_NOWAIT | M_ZERO); + if (bl == NULL) + return; + error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + if (error == ENOSPC) { + free(bl, M_DEVBUF); + bl = malloc(len, M_DEVBUF, M_NOWAIT | M_ZERO); + if (bl == NULL) + return; + + error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + } if (error) { DPRINTF(("%s: failed to read\n", __func__)); free(bl, M_DEVBUF); From laffer1 at midnightbsd.org Tue Jan 20 14:44:28 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:44:28 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: cast to printf properly Message-ID: <200901201944.n0KJiSKa069813@stargazer.midnightbsd.org> Log Message: ----------- cast to printf properly Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.5 -> r1.6) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.5 -r1.6 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -2432,7 +2432,7 @@ else bcopy(ifp->if_broadcastaddr, bssid, len); - DPRINTF(("Setting BSSID to %6D\n", &bssid, ":")); + DPRINTF(("Setting BSSID to %6D\n", (uint8_t *)&bssid, ":")); rval = ndis_set_info(sc, OID_802_11_BSSID, &bssid, &len); if (rval) device_printf(sc->ndis_dev, From laffer1 at midnightbsd.org Tue Jan 20 14:53:11 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:53:11 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: This fix was found in freebsd pr 124225 Description: Message-ID: <200901201953.n0KJrB2Q070766@stargazer.midnightbsd.org> Log Message: ----------- This fix was found in freebsd pr 124225 Description: Normally, when packets are queued to the ndis network interface, ndis_start() is called to move packets from the interface send queue to the underlying NDIS driver. If the network link is down or the underlying driver is busy transmitting data, ndis_start() just returns. When the link goes up, ndis_starttask() is supposed to be called after ndis_ticktask() in order to transmit already queued packets. After a watchdog timeout, ndis_starttask() is likewise supposed to be called after ndis_resettask(). Unfortunately, work items used for triggering calls to ndis_ticktask(), ndis_starttask() and ndis_resettask() are placed on separarate task lists which are handled by separate kernel processes, thus losing ordering information about when the tasks should be performed in relation to each other. If the interface send queue is full after a watchdog timeout or link up event and the tasks were handled in the wrong order then further attempts to send packets via the interface results in ENOBUFS ("No buffer space available"). How-To-Repeat: Use the ndis driver for a wireless network card in an area with many APs on nearby channels and on a machine with many active tcp connections, causing link to temporarily go down every few hours, and the interface send queue to be filled while the link is temporarily down. Fix: A proper fix is to ensure that related tasks are handled in the correct order. The following kludge justs add extra attempts at scheduling calls to ndis_starttask() as part of the processing of ndis_ticktask() and ndis_resettask(). It depends on defensive coding in IoQueueWorkItem(), i.e. that nothing is done if the work item is already queued. Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.6 -> r1.7) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.6 retrieving revision 1.7 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.6 -r1.7 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -1564,6 +1564,7 @@ IoQueueWorkItem(sc->ndis_tickitem, (io_workitem_func)ndis_ticktask_wrap, WORKQUEUE_CRITICAL, sc); + /* XXX: startitem might be handled before tickitem */ IoQueueWorkItem(sc->ndis_startitem, (io_workitem_func)ndis_starttask_wrap, WORKQUEUE_CRITICAL, ifp); @@ -1647,6 +1648,11 @@ ieee80211_new_state(ic, IEEE80211_S_RUN, -1); } NDIS_LOCK(sc); + /* XXX: Start kludge */ + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_starttask_wrap, + WORKQUEUE_CRITICAL, sc->ifp); + /* XXX: End kludge */ #ifdef LINK_STATE_UP if_link_state_change(sc->ifp, LINK_STATE_UP); #else @@ -3146,6 +3152,11 @@ sc = arg; ndis_reset_nic(sc); + /* XXX: Start kludge */ + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_starttask_wrap, + WORKQUEUE_CRITICAL, sc->ifp); + /* XXX: End kludge */ return; } @@ -3165,6 +3176,7 @@ IoQueueWorkItem(sc->ndis_resetitem, (io_workitem_func)ndis_resettask_wrap, WORKQUEUE_CRITICAL, sc); + /* XXX: startitem might be handled before resetitem */ IoQueueWorkItem(sc->ndis_startitem, (io_workitem_func)ndis_starttask_wrap, WORKQUEUE_CRITICAL, ifp); From laffer1 at midnightbsd.org Tue Jan 20 14:31:08 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:31:08 -0500 (EST) Subject: [Midnightbsd-cvs] src: man/man9: update section 9 of the manual Message-ID: <200901201931.n0KJV8qA068473@stargazer.midnightbsd.org> Log Message: ----------- update section 9 of the manual Modified Files: -------------- src/share/man/man9: BUS_SETUP_INTR.9 (r1.1.1.1 -> r1.2) DECLARE_GEOM_CLASS.9 (r1.1.1.1 -> r1.2) EVENTHANDLER.9 (r1.1.1.1 -> r1.2) Makefile (r1.2 -> r1.3) SYSCALL_MODULE.9 (r1.1.1.1 -> r1.2) VFS.9 (r1.1.1.1 -> r1.2) VFS_LOCK_GIANT.9 (r1.1.1.1 -> r1.2) VFS_ROOT.9 (r1.1.1.1 -> r1.2) VFS_SET.9 (r1.1.1.1 -> r1.2) VFS_SYNC.9 (r1.1.1.1 -> r1.2) VOP_FSYNC.9 (r1.1.1.1 -> r1.2) VOP_LISTEXTATTR.9 (r1.1.1.1 -> r1.2) VOP_OPENCLOSE.9 (r1.1.1.1 -> r1.2) VOP_REMOVE.9 (r1.1.1.1 -> r1.2) VOP_RENAME.9 (r1.1.1.1 -> r1.2) acl.9 (r1.1.1.1 -> r1.2) alloc_unr.9 (r1.1.1.2 -> r1.2) atomic.9 (r1.1.1.1 -> r1.2) bios.9 (r1.1.1.1 -> r1.2) bpf.9 (r1.1.1.1 -> r1.2) buf.9 (r1.1.1.1 -> r1.2) bus_alloc_resource.9 (r1.1.1.1 -> r1.2) bus_dma.9 (r1.1.1.1 -> r1.2) bus_space.9 (r1.1.1.1 -> r1.2) condvar.9 (r1.1.1.1 -> r1.2) contigmalloc.9 (r1.1.1.1 -> r1.2) critical_enter.9 (r1.1.1.1 -> r1.2) crypto.9 (r1.1.1.1 -> r1.2) device_add_child.9 (r1.1.1.1 -> r1.2) device_get_softc.9 (r1.1.1.1 -> r1.2) device_set_driver.9 (r1.1.1.1 -> r1.2) disk.9 (r1.1.1.1 -> r1.2) driver.9 (r1.1.1.1 -> r1.2) extattr.9 (r1.1.1.1 -> r1.2) firmware.9 (r1.2 -> r1.3) g_bio.9 (r1.1.1.1 -> r1.2) g_consumer.9 (r1.1.1.1 -> r1.2) hash.9 (r1.1 -> r1.2) hashinit.9 (r1.1.1.1 -> r1.2) ieee80211_ioctl.9 (r1.1.1.2 -> r1.2) ifnet.9 (r1.1.1.1 -> r1.2) ithread.9 (r1.1.1.1 -> r1.2) kobj.9 (r1.1.1.1 -> r1.2) ktr.9 (r1.1.1.1 -> r1.2) lock.9 (r1.1.1.1 -> r1.2) mac.9 (r1.1.1.1 -> r1.2) make_dev.9 (r1.1.1.1 -> r1.2) mbuf.9 (r1.2 -> r1.3) memguard.9 (r1.1.1.1 -> r1.2) mi_switch.9 (r1.1.1.1 -> r1.2) microtime.9 (r1.1.1.1 -> r1.2) module.9 (r1.1.1.1 -> r1.2) mtx_pool.9 (r1.1.1.1 -> r1.2) mutex.9 (r1.1.1.2 -> r1.2) namei.9 (r1.1.1.1 -> r1.2) p_candebug.9 (r1.1.1.1 -> r1.2) pci.9 (r1.1.1.1 -> r1.2) pfil.9 (r1.1.1.1 -> r1.2) pmap_extract.9 (r1.1.1.1 -> r1.2) pmap_remove.9 (r1.1.1.1 -> r1.2) pmap_zero_page.9 (r1.2 -> r1.3) printf.9 (r1.1.1.1 -> r1.2) pseudofs.9 (r1.1.1.1 -> r1.2) rman.9 (r1.1.1.1 -> r1.2) rtentry.9 (r1.1.1.1 -> r1.2) sbuf.9 (r1.1.1.1 -> r1.2) securelevel_gt.9 (r1.1.1.1 -> r1.2) selrecord.9 (r1.1.1.1 -> r1.2) sema.9 (r1.1.1.1 -> r1.2) sleep.9 (r1.2 -> r1.3) sleepqueue.9 (r1.1.1.1 -> r1.2) style.9 (r1.1.1.1 -> r1.2) suser.9 (r1.1.1.1 -> r1.2) sx.9 (r1.1.1.1 -> r1.2) sysctl_add_oid.9 (r1.1.1.1 -> r1.2) sysctl_ctx_init.9 (r1.1.1.1 -> r1.2) taskqueue.9 (r1.1.1.1 -> r1.2) thread_exit.9 (r1.1.1.1 -> r1.2) time.9 (r1.1.1.1 -> r1.2) timeout.9 (r1.1.1.1 -> r1.2) uio.9 (r1.1.1.1 -> r1.2) utopia.9 (r1.1.1.1 -> r1.2) vflush.9 (r1.1.1.1 -> r1.2) vgone.9 (r1.1.1.1 -> r1.2) vhold.9 (r1.1.1.1 -> r1.2) vm_map.9 (r1.1.1.1 -> r1.2) vm_map_stack.9 (r1.1.1.1 -> r1.2) vm_page_deactivate.9 (r1.1.1.1 -> r1.2) vm_page_free.9 (r1.2 -> r1.3) vm_page_grab.9 (r1.2 -> r1.3) vm_page_hold.9 (r1.2 -> r1.3) vm_page_insert.9 (r1.2 -> r1.3) vm_page_io.9 (r1.2 -> r1.3) vm_page_lookup.9 (r1.2 -> r1.3) vm_page_protect.9 (r1.2 -> r1.3) vm_page_rename.9 (r1.2 -> r1.3) vm_page_sleep_busy.9 (r1.2 -> r1.3) vm_page_wakeup.9 (r1.2 -> r1.3) vm_page_wire.9 (r1.2 -> r1.3) vm_page_zero_fill.9 (r1.2 -> r1.3) vm_set_page_size.9 (r1.2 -> r1.3) vn_fullpath.9 (r1.2 -> r1.3) vn_isdisk.9 (r1.2 -> r1.3) vnode.9 (r1.2 -> r1.3) vput.9 (r1.2 -> r1.3) vref.9 (r1.2 -> r1.3) vrele.9 (r1.2 -> r1.3) vslock.9 (r1.2 -> r1.3) watchdog.9 (r1.2 -> r1.3) zero_copy.9 (r1.2 -> r1.3) zone.9 (r1.2 -> r1.3) Added Files: ----------- src/share/man/man9: LOCK_PROFILING.9 (r1.1) VOP_VPTOFH.9 (r1.1) config_intrhook.9 (r1.1) cr_cansee.9 (r1.1) device_get_sysctl.9 (r1.1) kqueue.9 (r1.1) locking.9 (r1.1) p_cansee.9 (r1.1) priv.9 (r1.1) redzone.9 (r1.1) rwlock.9 (r1.1) sf_buf.9 (r1.1) socket.9 (r1.1) stack.9 (r1.1) sysctl.9 (r1.1) usbdi.9 (r1.1) vfs_getopt.9 (r1.1) -------------- next part -------------- Index: printf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/printf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/printf.9 -L share/man/man9/printf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/printf.9 +++ share/man/man9/printf.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/printf.9,v 1.6.2.1 2005/08/18 15:01:24 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/printf.9,v 1.8 2006/09/08 14:05:03 ru Exp $ .\" -.Dd August 10, 2004 +.Dd September 8, 2006 .Dt PRINTF 9 .Os .Sh NAME @@ -90,7 +90,7 @@ for example, \e10 gives octal and \e20 gives hexadecimal. The arguments are made up of a sequence of bit identifiers. Each bit identifier begins with an integer value which is the number of the -bit this identifier describes. +bit (starting from 1) this identifier describes. The rest of the identifier is a string of characters containing the name of the bit. The string is terminated by either the bit number at the start of the next @@ -140,7 +140,11 @@ .Fn uprintf functions return the number of characters displayed. .Sh EXAMPLES -This example demonstrates the use of the \&%b and \&%D conversion specifiers. +This example demonstrates the use of the +.Cm \&%b +and +.Cm \&%D +conversion specifiers. The function .Bd -literal -offset indent void Index: vm_page_hold.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_hold.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_hold.9 -L share/man/man9/vm_page_hold.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_hold.9 +++ share/man/man9/vm_page_hold.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_hold.9,v 1.4 2002/04/05 08:05:11 davidc Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_HOLD 9 Index: contigmalloc.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/contigmalloc.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/contigmalloc.9 -L share/man/man9/contigmalloc.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/contigmalloc.9 +++ share/man/man9/contigmalloc.9 @@ -23,9 +23,9 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/contigmalloc.9,v 1.6 2005/02/22 17:20:20 brueffer Exp $ +.\" $FreeBSD: src/share/man/man9/contigmalloc.9,v 1.7 2007/07/19 17:23:20 alc Exp $ .\" -.Dd August 10, 2004 +.Dd July 19, 2007 .Dt CONTIGMALLOC 9 .Os .Sh NAME @@ -77,7 +77,14 @@ .Bl -tag -width indent .It Dv M_ZERO Causes the allocated physical memory to be zero filled. +.It Dv M_NOWAIT +Causes +.Fn contigmalloc +to return +.Dv NULL +if the request cannot be immediately fulfilled due to resource shortage. .El +.Pp Other flags (if present) are ignored. .Pp The @@ -88,10 +95,11 @@ The .Fn contigmalloc function does not sleep waiting for memory resources to be freed up, -but instead scans available physical memory a small number of times -for a suitably sized free address range before giving up. -Memory allocation is done on a first-fit basis, starting from the -top of the provided address range. +but instead actively reclaims pages before giving up. +However, unless +.Dv M_NOWAIT +is specified, it may select a page for reclamation that must first be +written to backing storage, causing it to sleep. .Sh RETURN VALUES The .Fn contigmalloc --- /dev/null +++ share/man/man9/vfs_getopt.9 @@ -0,0 +1,198 @@ +.\" +.\" Copyright (C) 2007 Chad David . All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/vfs_getopt.9,v 1.2 2007/03/04 19:04:39 ru Exp $ +.\" +.Dd February 28, 2007 +.Dt VFS_GETOPT 9 +.Os +.Sh NAME +.Nm vfs_getopt , +.Nm vfs_getopts , +.Nm vfs_flagopt , +.Nm vfs_scanopt , +.Nm vfs_copyopt , +.Nm vfs_filteropt +.Nd "manipulate mount options and their values" +.Sh SYNOPSIS +.In sys/param.h +.In sys/mount.h +.Ft int +.Fo vfs_getopt +.Fa "struct vfsoptlist *opts" "const char *name" "void **buf" "int *len" +.Fc +.Ft "char *" +.Fn vfs_getops "struct vfsoptlist *opts" "const char *name" "int *error" +.Ft int +.Fo vfs_flagopt +.Fa "struct vfsoptlist *opts" "const char *name" "u_int *flags" "u_int flag" +.Fc +.Ft int +.Fo vfs_scanopt +.Fa "struct vfsoptlist *opts" "const char *name" "const char *fmt" ... +.Fc +.Ft int +.Fo vfs_copyopt +.Fa "struct vfsoptlist *opts" "const char *name" "void *dest" "int len" +.Fc +.Ft int +.Fo vfs_filteropt +.Fa "struct vfsoptlist *opts" "const char **legal" +.Fc +.Sh DESCRIPTION +The +.Fn vfs_getopt +function sets +.Fa buf +to point to the value of the named mount option, and sets +.Fa len +to the length of the value if it is not +.Dv NULL . +The +.Fa buf +argument +will point to the actual value, and does not need to be freed or released +(and probably should not be modified). +.Pp +The +.Fn vfs_getopts +function +returns the value of the specified option if it is a string (i.e., +.Dv NUL +terminated). +.Pp +The +.Fn vfs_flagopt +function determines if an option exists. +If the option does exist, and +.Fa flags +is not +.Dv NULL , +.Fa flag +is added to those already set in +.Fa flags . +If the option does not exist, and +.Fa flags +is not +.Dv NULL , +.Fa flag +is removed from those already set in +.Fa flags . +An example of typical usage is: +.Bd -literal +if (vfs_flagopt(mp->mnt_optnew, "wormlike", NULL, 0)) + vfs_flagopt(mp->mnt_optnew, "appendok", &(mp->flags), F_APPENDOK); +.Ed +.Pp +The +.Fn vfs_scanopt +function performs a +.Xr vsscanf 3 +with the options value, using the given format, +into the specified variable arguments. +The value must be a string (i.e., +.Dv NUL +terminated). +.Pp +The +.Fn vfs_copyopt +function creates a copy of the options value. +The +.Fa len +argument must match the length of the options value exactly +(i.e., a larger buffer will still cause +.Fn vfs_copyout +to fail with +.Er EINVAL ) . +.Pp +The +.Fn vfs_filteropt +function ensures that no unknown options were specified. +A option is valid if its name matches one of the names in the +list of legal names. +An option may be prefixed with 'no', and still be considered valid. +.Sh RETURN VALUES +The +.Fn vfs_getopt +function returns 0 if the option was found; otherwise, +.Er ENOENT +is returned. +.Pp +The +.Fn vfs_getops +function returns the specified option if it is found, and is +.Dv NUL +terminated. +If the option was found, but is not +.Dv NUL +terminated, +.Fa error +is set to +.Er EINVAL +and +.Dv NULL +is returned. +If the option was not found, +.Fa error +is set to 0, and +.Dv NULL +is returned. +.Pp +The +.Fn vfs_flagopt +function returns 1 if the option was found, and 0 if it was not. +.Pp +The +.Fn vfs_scanopt +function returns 0 if the option was not found, or was not +.Dv NUL +terminated; otherwise, the return value of +.Xr vsscanf 3 +is returned. +If +.Xr vsscanf 3 +returns 0, it will be returned unchanged; therefore, a return value of 0 does +not always mean the option does not exist, or is not a valid string. +.Pp +The +.Fn vfs_copyopt +function returns 0 if the copy was successful, +.Er EINVAL +if the option was found but the lengths did not match, and +.Er ENOENT +if the option was not found. +.Pp +The +.Fn vfs_filteropt +function returns 0 if all of the options are legal; otherwise, +.Er EINVAL +is returned. +.Sh AUTHORS +.An -nosplit +This manual page was written by +.An Chad David Aq davidc at FreeBSD.org +and +.An Ruslan Ermilov Aq ru at FreeBSD.org . Index: device_add_child.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/device_add_child.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/device_add_child.9 -L share/man/man9/device_add_child.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/device_add_child.9 +++ share/man/man9/device_add_child.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/device_add_child.9,v 1.19 2004/07/03 18:29:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/device_add_child.9,v 1.25 2006/09/12 15:48:22 imp Exp $ .\" -.Dd May 13, 2004 +.Dd September 12, 2006 .Dt DEVICE_ADD_CHILD 9 .Os .Sh NAME @@ -67,8 +67,8 @@ as PCI) to allow each driver to check each device instance for a match. For busses which rely on supplied probe hints where only one -driver can have a change of probing the device, the driver name should -specified as the device name. +driver can have a chance of probing the device, the driver name should +be specified as the device name. .Pp Normally unit numbers will be chosen automatically by the system and a unit number of @@ -96,8 +96,10 @@ .Pp When adding a device in the context of .Xr DEVICE_IDENTIFY 9 -routine, some care must be taken to ensure that the device has not -already been added to the tree. +routine, the +.Xr device_find_child 9 +routine should be used to ensure that the device has not already been +added to the tree. Because the device name and .Vt devclass_t are associated at probe time (not child addition time), previous @@ -106,10 +108,18 @@ Authors of bus drivers must likewise be careful when adding children when they are loaded and unloaded to avoid duplication of children devices. +.Pp +Identify routines should use +.Xr BUS_ADD_CHILD 9 +instead of +.Xr device_add_child 9 . .Sh RETURN VALUES The new device if successful, NULL otherwise. .Sh SEE ALSO -.Xr device 9 +.Xr BUS_ADD_CHILD 9 , +.Xr device 9 , +.Xr device_find_child 9 , +.Xr DEVICE_IDENTIFY 9 .Sh AUTHORS This manual page was written by .An Doug Rabson . Index: sysctl_ctx_init.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sysctl_ctx_init.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sysctl_ctx_init.9 -L share/man/man9/sysctl_ctx_init.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sysctl_ctx_init.9 +++ share/man/man9/sysctl_ctx_init.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sysctl_ctx_init.9,v 1.12 2004/07/03 18:29:24 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sysctl_ctx_init.9,v 1.14 2007/07/27 19:55:42 remko Exp $ .\" .Dd July 15, 2000 .Dt SYSCTL_CTX_INIT 9 @@ -135,7 +135,8 @@ as the oid number when creating an oid. However, during registration of the oid in the tree, this number is changed to the first available number -greater than 99. +greater than or equal to +.Dv CTL_AUTO_START . If the first step of context deletion fails, re-registration of the oid does not change the already assigned oid number (which is different from OID_AUTO). @@ -225,6 +226,7 @@ .Sh SEE ALSO .Xr queue 3 , .Xr sysctl 8 , +.Xr sysctl 9 , .Xr sysctl_add_oid 9 , .Xr sysctl_remove_oid 9 .Sh HISTORY Index: extattr.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/extattr.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/extattr.9 -L share/man/man9/extattr.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/extattr.9 +++ share/man/man9/extattr.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/extattr.9,v 1.15 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/extattr.9,v 1.17 2007/03/06 08:13:21 mckusick Exp $ .\" .Dd December 23, 1999 .Os Index: securelevel_gt.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/securelevel_gt.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/securelevel_gt.9 -L share/man/man9/securelevel_gt.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/securelevel_gt.9 +++ share/man/man9/securelevel_gt.9 @@ -24,9 +24,9 @@ .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. -.\" $FreeBSD: src/share/man/man9/securelevel_gt.9,v 1.1 2004/03/07 15:22:08 josef Exp $ +.\" $FreeBSD: src/share/man/man9/securelevel_gt.9,v 1.2 2007/06/02 20:15:59 remko Exp $ .\" -.Dd March 6, 2004 +.Dd June 2, 2007 .Dt SECURELEVEL_GT 9 .Os .Sh NAME @@ -68,4 +68,4 @@ .Er EPERM if condition evaluated to true, and 0 otherwise. .Sh SEE ALSO -.Xr securelevel 8 +.Xr securelevel 7 Index: vm_page_zero_fill.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_zero_fill.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_zero_fill.9 -L share/man/man9/vm_page_zero_fill.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_zero_fill.9 +++ share/man/man9/vm_page_zero_fill.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_zero_fill.9,v 1.3 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_ZERO_FILL 9 Index: pseudofs.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pseudofs.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pseudofs.9 -L share/man/man9/pseudofs.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pseudofs.9 +++ share/man/man9/pseudofs.9 @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pseudofs.9,v 1.5 2004/07/03 18:29:24 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pseudofs.9,v 1.6 2007/04/20 15:38:06 brueffer Exp $ .\" -.Dd September 30, 2001 +.Dd April 20, 2007 .Dt PSEUDOFS 9 .Os .Sh NAME @@ -54,6 +54,7 @@ .\" Insert more info here .Sh SEE ALSO .Xr linprocfs 5 , +.Xr linsysfs 5 , .Xr procfs 5 , .Xr sbuf 9 , .Xr vnode 9 Index: VFS_SET.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_SET.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_SET.9 -L share/man/man9/VFS_SET.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_SET.9 +++ share/man/man9/VFS_SET.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_SET.9,v 1.9 2005/01/18 20:37:11 ru Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_SET.9,v 1.11 2007/04/05 21:17:52 pjd Exp $ .\" -.Dd December 2, 2001 +.Dd April 5, 2007 .Dt VFS_SET 9 .Os .Sh NAME @@ -70,6 +70,11 @@ Loopback file system layer. .It Dv VFCF_UNICODE File names are stored as Unicode. +.It Dv VFCF_JAIL +can be mounted from within a jail if +.Va security.jail.mount_allowed +sysctl is set to +.Dv 1 . .El .Sh PSEUDOCODE .Bd -literal @@ -96,6 +101,8 @@ VFS_SET(myfs_vfsops, skelfs, 0); .Ed .Sh SEE ALSO +.Xr jail 2 , +.Xr jail 8 , .Xr DECLARE_MODULE 9 , .Xr vfsconf 9 , .Xr vfs_modevent 9 --- /dev/null +++ share/man/man9/VOP_VPTOFH.9 @@ -0,0 +1,60 @@ +.\" -*- nroff -*- +.\" +.\" Copyright (c) 1996 Doug Rabson +.\" +.\" All rights reserved. +.\" +.\" This program is free software. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/VOP_VPTOFH.9,v 1.10 2007/02/16 14:27:59 pjd Exp $ +.\" +.Dd February 16, 2007 +.Os +.Dt VOP_VPTOFH 9 +.Sh NAME +.Nm VOP_VPTOFH +.Nd turn a vnode into an NFS filehandle +.Sh SYNOPSIS +.In sys/param.h +.In sys/vnode.h +.Ft int +.Fn VOP_VPTOFH "struct vnode *vp" "struct fid *fhp" +.Sh DESCRIPTION +This is used by the NFS server to create an opaque filehandle which +uniquely identifies the file and which can be used by an NFS client +to access the file in the future. +.Pp +Its arguments are: +.Bl -tag -width fhp +.It Fa vp +The vnode to make a filehandle for. +.It Fa fhp +Return parameter for the filehandle. +.El +.Sh SEE ALSO +.Xr VFS 9 , +.Xr VFS_FHTOVP 9 , +.Xr vnode 9 +.Sh AUTHORS +This manual page was written by +.An Doug Rabson . Index: pfil.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pfil.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pfil.9 -L share/man/man9/pfil.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pfil.9 +++ share/man/man9/pfil.9 @@ -26,7 +26,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pfil.9,v 1.20 2005/01/21 08:36:40 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pfil.9,v 1.22 2006/09/18 15:24:20 ru Exp $ .\" .Dd September 29, 2004 .Dt PFIL 9 @@ -145,7 +145,7 @@ might sleep! .Sh SEE ALSO .Xr bpf 4 , -.Xr bridge 4 +.Xr if_bridge 4 .Sh HISTORY The .Nm @@ -196,10 +196,12 @@ host byte order contrary to the above statements. .Pp The -.Xr bridge 4 -diverts inbound +.Xr if_bridge 4 +diverts .Dv AF_INET -traffic, but contrary to the above +and +.Dv AF_INET6 +traffic according to its sysctl settings, but contrary to the above statements, the data is provided in host byte order. .Pp When a Index: bios.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bios.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bios.9 -L share/man/man9/bios.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bios.9 +++ share/man/man9/bios.9 @@ -1,4 +1,4 @@ -.\" $FreeBSD: src/share/man/man9/bios.9,v 1.13.10.1 2005/08/14 18:48:54 murray Exp $ +.\" $FreeBSD: src/share/man/man9/bios.9,v 1.16 2005/11/18 10:52:24 ru Exp $ .\" .\" Copyright (c) 1997 Michael Smith .\" All rights reserved. @@ -24,13 +24,14 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 1, 1997 +.Dd August 9, 2005 .Dt BIOS 9 .Os .Sh NAME .Nm bios_sigsearch , .Nm bios32_SDlookup , -.Nm bios32 +.Nm bios32 , +.Nm bios_oem_strings .Nd interact with PC BIOS .Sh SYNOPSIS .In sys/param.h @@ -50,6 +51,23 @@ .Vt extern struct bios32_SDentry PCIbios ; .Vt extern struct SMBIOS_table SMBIOStable ; .Vt extern struct DMI_table DMItable ; +.Ft int +.Fn bios_oem_strings "struct bios_oem *oem" "u_char *buffer" "size_t maxlen" +.Bd -literal +struct bios_oem_signature { + char * anchor; /* search anchor string in BIOS memory */ + size_t offset; /* offset from anchor (may be negative) */ + size_t totlen; /* total length of BIOS string to copy */ +}; +struct bios_oem_range { + u_int from; /* shouldn't be below 0xe0000 */ + u_int to; /* shouldn't be above 0xfffff */ +}; +struct bios_oem { + struct bios_oem_range range; + struct bios_oem_signature signature[]; +}; +.Ed .Sh DESCRIPTION These functions provide a general-purpose interface for dealing with the BIOS functions and data encountered on x86 PC-architecture systems. @@ -75,6 +93,46 @@ If the signature is found, its effective physical address is returned. If no signature is found, zero is returned. +.It Fn bios_oem_strings +Searches a given BIOS memory range for one or more strings, +and composes a printable concatenation of those found. +The routine expects a structure describing the BIOS address +.Fa range +(within +.Li 0xe0000 +- +.Li 0xfffff ) , +and a { +.Dv NULL , Li 0 , 0 +} -terminated array of +.Vt bios_oem_signature +structures which define the +.Va anchor +string, an +.Va offset +from the beginning of the match (which may be negative), and +.Va totlen +number of bytes to be collected from BIOS memory starting at that offset. +Unmatched anchors are ignored, whereas matches are copied from BIOS memory +starting at their corresponding +.Vt offset +with unprintable characters being replaced with space, and consecutive spaces +being suppressed. +This composed string is stored in +.Fa buffer +up to the given +.Fa maxlen +bytes (including trailing +.Ql \e0 , +and any trailing space surpressed). +If an error is encountered, i.e.\& trying to read out of said BIOS range, +other invalid input, or +.Fa buffer +overflow, a negative integer is returned, otherwise the +length of the composed string is returned. +In particular, a return +value of 0 means that none of the given anchor strings were found in +the specified BIOS memory range. .It Fn BIOS_VADDRTOPADDR Returns the effective physical address which corresponds to the kernel virtual address Index: vm_page_deactivate.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_deactivate.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vm_page_deactivate.9 -L share/man/man9/vm_page_deactivate.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vm_page_deactivate.9 +++ share/man/man9/vm_page_deactivate.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_page_deactivate.9,v 1.2 2001/08/08 10:04:08 ru Exp $ +.\" $FreeBSD: src/share/man/man9/vm_page_deactivate.9,v 1.3 2007/02/25 06:51:11 ru Exp $ .\" .Dd July 24, 2001 .Dt VM_PAGE_DEACTIVATE 9 @@ -44,7 +44,6 @@ function moves the given page to the inactive queue as long as it is unmanaged and is not wired. .Sh SEE ALSO -.Xr vm_page_unmanage 9 , .Xr vm_page_wire 9 .Sh AUTHORS This manual page was written by --- /dev/null +++ share/man/man9/socket.9 @@ -0,0 +1,338 @@ +.\"- +.\" Copyright (c) 2006 Robert N. M. Watson +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/socket.9,v 1.2 2006/12/16 10:32:10 rwatson Exp $ +.\" +.Dd December 14, 2006 +.Dt SOCKET 9 +.Os +.Sh NAME +.Nm socket +.Nd "kernel socket interface" +.Sh SYNOPSIS +.In sys/socket.h +.In sys/socketvar.h +.Ft int +.Fn sobind "struct socket *so" "struct sockaddr *nam" "struct thread *td" +.Ft void +.Fn soclose "struct socket *so" +.Ft int +.Fn soconnect "struct socket *so" "struct sockaddr *nam" "struct thread *td" +.Ft int +.Fo socreate +.Fa "int dom" "struct socket **aso" "int type" "int proto" +.Fa "struct ucred *cred" "struct thread *td" +.Fc +.Ft int +.Fn sogetopt "struct socket *so" "struct sockopt *sopt" +.Ft int +.Fo soreceive +.Fa "struct socket *so" "struct sockaddr **psa" "struct uio *uio" +.Fa "struct mbuf **mp0" "struct mbuf **controlp" "int *flagsp" +.Fc +.Ft int +.Fn sosetopt "struct socket *so" "struct sockopt *sopt" +.Ft int +.Fo sosend +.Fa "struct socket *so" "struct sockaddr *addr" "struct uio *uio" +.Fa "struct mbuf *top" "struct mbuf *control" "int flags" "struct thread *td" +.Fc +.Ft int +.Fn soshutdown "struct socket *so" "int how" +.Sh DESCRIPTION +The kernel +.Nm +programming interface permits in-kernel consumers to interact with +local and network socket objects in a manner similar to that permitted using +the +.Xr socket 2 +user API. +These interfaces are appropriate for use by distributed file systems and +other network-aware kernel services. +While the user API operates on file descriptors, the kernel interfaces +operate directly on +.Vt "struct socket" +pointers. +.Pp +Except where otherwise indicated, +.Nm +functions may sleep, and are not appropriate for use in an +.Xr ithread 9 +context or while holding non-sleepable kernel locks. +.Ss Creating and Destroying Sockets +A new socket may be created using +.Fn socreate . +As with +.Xr socket 2 , +arguments specify the requested domain, type, and protocol via +.Fa dom , type , +and +.Fa proto . +The socket is returned via +.Fa aso +on success. +In addition, the credential used to authorize operations associated with the +socket will be passed via +.Fa cred +(and will be cached for the lifetime of the socket), and the thread +performing the operation via +.Fa td . +.Em Warning : +authorization of the socket creation operation will be performed +using the thread credential for some protocols (such as raw sockets). +.Pp +Sockets may be closed and freed using +.Fn soclose , +which has similar semantics to +.Xr close 2 . +.Ss Connections and Addresses +The +.Fn sobind +function is equivalent to the +.Xr bind 2 +system call, and binds the socket +.Fa so +to the address +.Fa nam . +The operation would be authorized using the credential on thread +.Fa td . +.Pp +The +.Fn soconnect +function is equivalent to the +.Xr connect 2 +system call, and initiates a connection on the socket +.Fa so +to the address +.Fa nam . +The operation will be authorized using the credential on thread +.Fa td . +Unlike the user system call, +.Fn soconnect +returns immediately; the caller may +.Xr msleep 9 +on +.Fa so->so_timeo +while holding the socket mutex and waiting for the +.Dv SS_ISCONNECTING +flag to clear or +.Fa so->so_error +to become non-zero. +If +.Fn soconnect +fails, the caller must manually clear the +.Dv SS_ISCONNECTING +flag. +.Pp +The +.Fn soshutdown +function is equivalent to the +.Xr shutdown 2 +system call, and causes part or all of a connection on a socket to be closed +down. +.Ss Socket Options +The +.Fn sogetopt +function is equivalent to the +.Xr getsockopt 2 +system call, and retrieves a socket option on socket +.Fa so . +The +.Fn sosetopt +function is equivalent to the +.Xr setsockopt 2 +system call, and sets a socket option on socket +.Fa so . +.Pp +The second argument in both +.Fn sogetopt +and +.Fn sosetopt +is the +.Fa sopt +pointer to a +.Vt "struct sopt" +describing the socket option operation. +The caller-allocated structure must be zeroed, and then have its fields +initialized to specify socket option operation arguments: +.Bl -tag -width ".Va sopt_valsize" +.It Va sopt_dir +Set to +.Dv SOPT_SET +or +.Dv SOPT_GET +depending on whether this is a get or set operation. +.It Va sopt_level +Specify the level in the network stack the operation is targeted at; for +example, +.Dv SOL_SOCKET . +.It Va sopt_name +Specify the name of the socket option to set. +.It Va sopt_val +Kernel space pointer to the argument value for the socket option. +.It Va sopt_valsize +Size of the argument value in bytes. +.El +.Ss Socket I/O +The +.Fn soreceive +function is equivalent to the +.Xr recvmsg 2 +system call, and attempts to receive bytes of data from the socket +.Fa so , +optionally blocking awaiting for data if none is ready to read. +Data may be retrieved directly to kernel or user memory via the +.Fa uio +argument, or as an mbuf chain returned to the caller via +.Fa mp0 , +avoiding a data copy. +Only one of the +.Fa uio +or +.Fa mp0 +pointers may be +.Pf non- Dv NULL . +The caller may optionally retrieve a socket address on a protocol with the +.Dv PR_ADDR +capability by providing storage via +.Pf non- Dv NULL +.Fa psa +argument. +The caller may optionally retrieve control data mbufs via a +.Pf non- Dv NULL +.Fa controlp +argument. +Optional flags may be passed to +.Fn soreceive +via a +.Pf non- Dv NULL +.Fa flagsp +argument, and use the same flag name space as the +.Xr recvmsg 2 +system call. +.Pp +The +.Fn sosend +function is equivalent to the +.Xr sendmsg 2 +system call, and attempts to send bytes of data via the socket +.Fa so , +optionally blocking if data cannot be immediately sent. +Data may be sent directly from kernel or user memory via the +.Fa uio +argument, or as an mbuf chain via +.Fa top , +avoiding a data copy. +Only one of the +.Fa uio +or +.Fa top +pointers may be +.Pf non- Dv NULL . +An optional destination address may be specified via a +.Pf non- Dv NULL +.Fa addr +argument, which may result in an implicit connect if supported by the +protocol. +The caller may optionally send control data mbufs via a +.Pf non- Dv NULL +.Fa control +argument. +Flags may be passed to +.Fn sosend +using the +.Fa flags +argument, and use the same flag name space as the +.Xr sendmsg 2 +system call. +.Pp +Kernel callers running in +.Xr ithread 9 +context, or with a mutex held, will wish to use non-blocking sockets and pass +the +.Dv MSG_DONTWAIT +flag in order to prevent these functions from sleeping. +.Sh SEE ALSO +.Xr bind 2 , +.Xr close 2 , +.Xr connect 2 , +.Xr getsockopt 2 , +.Xr recv 2 , +.Xr send 2 , +.Xr setsockopt 2 , +.Xr shutdown 2 , +.Xr socket 2 , +.Xr ng_ksocket 4 , +.Xr ithread 9 , +.Xr msleep 9 , +.Xr ucred 9 +.Sh HISTORY +The +.Xr socket 2 +system call appeared in +.Bx 4.2 . +This manual page was introduced in +.Fx 7.0 . +.Sh AUTHORS +This manual page was written by +.An Robert Watson . +.Sh BUGS +The use of explicitly passed credentials, credentials hung from explicitly +passed threads, the credential on +.Dv curthread , +and the cached credential from +socket creation time is inconsistent, and may lead to unexpected behaviour. +It is possible that several of the +.Fa td +arguments should be +.Fa cred +arguments, or simply not be present at all. +.Pp +The caller may need to manually clear +.Dv SS_ISCONNECTING +if +.Fn soconnect +returns an error. +.Pp +The +.Dv MSG_DONTWAIT +flag is not implemented for +.Fn sosend , +and may not always work with +.Fn soreceive +when zero copy sockets are enabled. +.Pp +This manual page does not describe how to register socket upcalls or monitor +a socket for readability/writability without using blocking I/O. +.Pp +The +.Fn soref +and +.Fn sorele +functions are not described, and in most cases should not be used, due to +confusing and potentially incorrect interactions when +.Fn sorele +is last called after +.Fn soclose . Index: time.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/time.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/time.9 -L share/man/man9/time.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/time.9 +++ share/man/man9/time.9 @@ -29,7 +29,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/time.9,v 1.16 2005/06/15 13:31:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/time.9,v 1.17 2006/03/02 19:47:41 ru Exp $ .\" .Dd September 17, 2004 .Dt TIME 9 @@ -43,8 +43,8 @@ .In sys/time.h .Pp .Vt extern struct timeval boottime ; -.Vt extern struct time_t time_second ; -.Vt extern struct timeval time_uptime ; +.Vt extern time_t time_second ; +.Vt extern time_t time_uptime ; .Sh DESCRIPTION The .Va boottime @@ -71,7 +71,6 @@ functions can be used to get the current time more accurately and in an atomic manner. Similarly, the -The .Xr binuptime 9 , .Xr getbinuptime 9 , .Xr microuptime 9 , --- /dev/null +++ share/man/man9/stack.9 @@ -0,0 +1,119 @@ +.\" +.\" Copyright (c) 2007 Robert N. M. Watson +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/stack.9,v 1.5.2.1 2007/12/04 15:22:31 rwatson Exp $ +.\" +.Dd February 27, 2007 +.Dt STACK 9 +.Os +.Sh NAME +.Nm stack +.Nd kernel thread stack tracing routines +.Sh SYNOPSIS +.In sys/param.h> +.In sys/stack.h +.Pp +In kernel configuration files: +.Cd "options DDB" +.Ft struct stack * +.Fn stack_create "void" +.Ft void +.Fn stack_destroy "struct stack *st" +.Ft int +.Fn stack_put "struct stack *st" "vm_offset_t pc" +.Ft void +.Fn stack_copy "struct stack *src" "struct stack dst" +.Ft void +.Fn stack_zero "struct stack *st" +.Ft void +.Fn stack_print "struct stack *st" +.Ft void +.Fn stack_sbuf_print "struct sbuf sb*" "struct stack *st" +.Ft void +.Fn stack_save "struct stack *st" +.Sh DESCRIPTION +The +.Nm +KPI allows querying of kernel stack trace information and the automated +generation of kernel stack trace strings for the purposes of debugging and +tracing. +.Nm +relies on the presence of +.Xr DDB 4 , +and all use of these functions must be made conditional on +.Nm DDB +being compiled in the kernel. +.Pp +Each stack trace is described by a +.Vt "struct stack" . +Before a trace may be created or otherwise manipulated, storage for the trace +must be allocated with +.Fn stack_create , +which may sleep. +Memory associated with a trace may be freed by calling +.Fn stack_destroy . +.Pp +A trace of the current kernel thread's call stack may be captured using +.Fn stack_save . +.Pp +.Fn stack_print +may be used to print a stack trace using the kernel +.Xr printf 9 . +.Pp +.Fn stack_sbuf_print +may be used to construct a human-readable string, including conversion (where +possible) from a simple kernel instruction pointer to a named symbol and +offset. +The argument +.Ar sb +must be an initialized +.Dv struct sbuf +as described in +.Xr sbuf 9 . +This function may sleep if an auto-extending +.Dv struct sbuf +is used. +.Pp +The utility functions +.Nm stack_zero , +.Nm stack_copy , +and +.Nm stack_put +may be used to manipulate stack data structures directly. +.Sh SEE ALSO +.Xr DDB 4 , +.Xr printf 9 , +.Xr sbuf 9 +.Sh AUTHORS +.An -nosplit +The +.Xr stack 9 +function suite was created by +.An Antoine Brodin . +.Pp +This manual page was written by +.An Robert Watson . Index: alloc_unr.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/alloc_unr.9,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L share/man/man9/alloc_unr.9 -L share/man/man9/alloc_unr.9 -u -r1.1.1.2 -r1.2 --- share/man/man9/alloc_unr.9 +++ share/man/man9/alloc_unr.9 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/alloc_unr.9,v 1.2.2.1 2006/01/24 17:02:38 joel Exp $ +.\" $FreeBSD: src/share/man/man9/alloc_unr.9,v 1.3 2005/11/24 09:25:09 joel Exp $ .\" .Dd March 23, 2005 .Dt ALLOC_UNR 9 Index: make_dev.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/make_dev.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/make_dev.9 -L share/man/man9/make_dev.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/make_dev.9 +++ share/man/man9/make_dev.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/make_dev.9,v 1.17 2005/03/28 10:28:57 brueffer Exp $ +.\" $FreeBSD: src/share/man/man9/make_dev.9,v 1.23 2007/05/09 05:05:50 brueffer Exp $ .\" -.Dd March 28, 2005 +.Dd May 6, 2007 .Os .Dt MAKE_DEV 9 .Sh NAME @@ -38,14 +38,14 @@ .Sh SYNOPSIS .In sys/param.h .In sys/conf.h -.Ft struct cdev +.Ft struct cdev * .Fn make_dev "struct cdevsw *cdevsw" "int minor" "uid_t uid" "gid_t gid" "int perms" "const char *fmt" ... -.Ft struct cdev -.Fn make_dev_alias "struct cdev pdev" "const char *fmt" ... +.Ft struct cdev * +.Fn make_dev_alias "struct cdev *pdev" "const char *fmt" ... .Ft void -.Fn destroy_dev "struct cdev dev" +.Fn destroy_dev "struct cdev *dev" .Ft void -.Fn dev_depends "struct cdev pdev" "struct cdev cdev" +.Fn dev_depends "struct cdev *pdev" "struct cdev *cdev" .Sh DESCRIPTION The .Fn make_dev @@ -57,9 +57,19 @@ The device will be owned by .Va uid , with the group ownership as -.Va gid , -and with the name as specified in -.Va name . +.Va gid . +The name is the expansion of +.Va fmt +and following arguments as +.Xr printf 9 +would print it. +The name determines its path under +.Pa /dev +or other +.Xr devfs 5 +mount point and may contain slash +.Ql / +characters to denote subdirectories. The permissions of the file specified in .Va perms are defined in @@ -102,6 +112,24 @@ .Fn make_dev . .Pp The +.Fa cdev +returned by +.Fn make_dev +and +.Fn make_dev_alias +has two fields, +.Fa si_drv1 +and +.Fa si_drv2 , +that are available to store state. +Both fields are of type +.Ft void * . +These are designed to replace the +.Fa minor +argument to +.Fn make_dev . +.Pp +The .Fn destroy_dev function takes the returned .Fa cdev Index: ieee80211_ioctl.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ieee80211_ioctl.9,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L share/man/man9/ieee80211_ioctl.9 -L share/man/man9/ieee80211_ioctl.9 -u -r1.1.1.2 -r1.2 --- share/man/man9/ieee80211_ioctl.9 +++ share/man/man9/ieee80211_ioctl.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ieee80211_ioctl.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/ieee80211_ioctl.9,v 1.5 2007/07/01 10:25:06 thompsa Exp $ .\" $Id: ieee80211_ioctl.9,v 1.5 2004/03/04 12:33:27 bruce Exp $ .\" .Dd March 2, 2004 @@ -55,11 +55,6 @@ .Fn ieee80211_cfgset functions implement a legacy interface for getting and setting 802.11 interface attributes respectively. -The interface is compatible with the RIDs implemented by the legacy -.Xr owi 4 -driver and used by the -.Xr wicontrol 8 -utility. .Pp .\" The @@ -79,9 +74,7 @@ to use this as the catch-all in a switch statement to avoid code duplication. .\" .Sh SEE ALSO -.Xr owi 4 , .Xr ifconfig 8 , -.Xr wicontrol 8 , .Xr ieee80211 9 , .Xr ifnet 9 .Sh HISTORY Index: sema.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sema.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sema.9 -L share/man/man9/sema.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sema.9 +++ share/man/man9/sema.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sema.9,v 1.9 2004/07/07 19:57:15 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sema.9,v 1.11 2007/03/30 18:07:26 julian Exp $ .\" -.Dd June 14, 2004 +.Dd February 1, 2006 .Dt SEMA 9 .Os .Sh NAME @@ -125,6 +125,8 @@ .El .Sh SEE ALSO .Xr condvar 9 , +.Xr locking 9 , .Xr mtx_pool 9 , .Xr mutex 9 , +.Xr rwlock 9 , .Xr sx 9 Index: vhold.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vhold.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vhold.9 -L share/man/man9/vhold.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vhold.9 +++ share/man/man9/vhold.9 @@ -24,13 +24,13 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vhold.9,v 1.3.2.1 2005/09/24 01:59:38 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/vhold.9,v 1.5 2007/04/01 09:48:59 maxim Exp $ .\" -.Dd November 21, 2001 +.Dd April 1, 2007 .Dt VHOLD 9 .Os .Sh NAME -.Nm vhold , vdrop +.Nm vhold , vdrop , vdropl .Nd "acquire/release a hold on a vnode" .Sh SYNOPSIS .In sys/param.h @@ -39,6 +39,8 @@ .Fn vhold "struct vnode *vp" .Ft void .Fn vdrop "struct vnode *vp" +.Ft void +.Fn vdropl "struct vnode *vp" .Sh DESCRIPTION The .Fn vhold @@ -50,13 +52,29 @@ .Pp The .Fn vdrop -function decrements the +and +.Fn vdropl +functions decrement the .Va v_holdcnt of the vnode. If the holdcount is less than or equal to zero prior to calling -.Fn vdrop , +.Fn vdrop +or +.Fn vdropl , the system will panic. If the vnode is no longer referenced, it will be freed. +.Pp +The difference between +.Fn vdrop +and +.Fn vdropl +is that +.Fn vdrop +locks the vnode interlock and then calls +.Fn vdropl +while +.Fn vdropl +expects the interlock to already be locked. .Sh SEE ALSO .Xr vbusy 9 , .Xr vfree 9 Index: module.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/module.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/module.9 -L share/man/man9/module.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/module.9 +++ share/man/man9/module.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/module.9,v 1.10 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/module.9,v 1.11 2007/07/19 11:22:34 flz Exp $ .\" -.Dd March 1, 2001 +.Dd July 19, 2007 .Dt MODULE 9 .Os .Sh NAME @@ -85,7 +85,7 @@ .Pp The module should return .Er EOPNOTSUPP -for unrecognized values of +for unsupported and unrecognized values of .Fa what . .Sh EXAMPLES .Bd -literal Index: rman.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/rman.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/rman.9 -L share/man/man9/rman.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/rman.9 +++ share/man/man9/rman.9 @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/rman.9,v 1.6 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/rman.9,v 1.9 2007/04/29 19:46:33 jmg Exp $ .\" -.Dd March 15, 2005 +.Dd April 29, 2007 .Dt RMAN 9 .Os .Sh NAME @@ -139,7 +139,28 @@ function initializes the region descriptor, pointed to by the .Fa rm argument, for use with the resource management functions. +It is required that the fields +.Va rm_type +and +.Va rm_descr +of +.Vt "struct rman" +be set before calling +.Fn rman_init . +The field +.Va rm_type +shall be set to +.Dv RMAN_ARRAY . +The field +.Va rm_descr +shall be set to a string that describes the resource to be managed. It also initializes any mutexes associated with the structure. +If +.Fn rman_init +fails to initalize the mutex, it will return +.Er ENOMEM ; otherwise it will return 0 and +.Fa rm +will be initalized. .Pp The .Fn rman_fini @@ -167,10 +188,15 @@ and .Fa end arguments specify the bounds of the region. -.Pp -.Em NOTE : -This interface is not robust against programming errors which -add multiple copies of the same region. +If successful, +.Fn rman_manage_region +will return 0. +If the region overlaps with an existing region, it will return +.Er EBUSY . +.Er ENOMEM +will be return when +.Fn rman_manage_region +failed to allocate memory for the region. .Pp The .Fn rman_reserve_resource_bound @@ -316,7 +342,6 @@ .Fn rman_get_device function returns a pointer to the device which reserved the resource .Fa r . -.Pp .Sh SEE ALSO .Xr bus_activate_resource 9 , .Xr bus_alloc_resource 9 , Index: bus_space.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bus_space.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bus_space.9 -L share/man/man9/bus_space.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bus_space.9 +++ share/man/man9/bus_space.9 @@ -56,7 +56,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bus_space.9,v 1.2 2005/06/25 08:59:05 ru Exp $ +.\" $FreeBSD: src/share/man/man9/bus_space.9,v 1.4 2006/09/18 14:31:03 ru Exp $ .\" .Dd June 13, 2005 .Dt BUS_SPACE 9 @@ -68,6 +68,10 @@ .Nm bus_space_copy_region_2 , .Nm bus_space_copy_region_4 , .Nm bus_space_copy_region_8 , +.Nm bus_space_copy_region_stream_1 , +.Nm bus_space_copy_region_stream_2 , +.Nm bus_space_copy_region_stream_4 , +.Nm bus_space_copy_region_stream_8 , .Nm bus_space_free , .Nm bus_space_map , .Nm bus_space_read_1 , @@ -78,20 +82,40 @@ .Nm bus_space_read_multi_2 , .Nm bus_space_read_multi_4 , .Nm bus_space_read_multi_8 , +.Nm bus_space_read_multi_stream_1 , +.Nm bus_space_read_multi_stream_2 , +.Nm bus_space_read_multi_stream_4 , +.Nm bus_space_read_multi_stream_8 , .Nm bus_space_read_region_1 , .Nm bus_space_read_region_2 , .Nm bus_space_read_region_4 , .Nm bus_space_read_region_8 , +.Nm bus_space_read_region_stream_1 , +.Nm bus_space_read_region_stream_2 , +.Nm bus_space_read_region_stream_4 , +.Nm bus_space_read_region_stream_8 , +.Nm bus_space_read_stream_1 , +.Nm bus_space_read_stream_2 , +.Nm bus_space_read_stream_4 , +.Nm bus_space_read_stream_8 , +.Nm bus_space_set_multi_1 , +.Nm bus_space_set_multi_2 , +.Nm bus_space_set_multi_4 , +.Nm bus_space_set_multi_8 , +.Nm bus_space_set_multi_stream_1 , +.Nm bus_space_set_multi_stream_2 , +.Nm bus_space_set_multi_stream_4 , +.Nm bus_space_set_multi_stream_8 , .Nm bus_space_set_region_1 , .Nm bus_space_set_region_2 , .Nm bus_space_set_region_4 , .Nm bus_space_set_region_8 , +.Nm bus_space_set_region_stream_1 , +.Nm bus_space_set_region_stream_2 , +.Nm bus_space_set_region_stream_4 , +.Nm bus_space_set_region_stream_8 , .Nm bus_space_subregion , .Nm bus_space_unmap , -.Nm bus_space_set_multi_1 , -.Nm bus_space_set_multi_2 , -.Nm bus_space_set_multi_4 , -.Nm bus_space_set_multi_8 , .Nm bus_space_write_1 , .Nm bus_space_write_2 , .Nm bus_space_write_4 , @@ -100,10 +124,22 @@ .Nm bus_space_write_multi_2 , .Nm bus_space_write_multi_4 , .Nm bus_space_write_multi_8 , +.Nm bus_space_write_multi_stream_1 , +.Nm bus_space_write_multi_stream_2 , +.Nm bus_space_write_multi_stream_4 , +.Nm bus_space_write_multi_stream_8 , .Nm bus_space_write_region_1 , .Nm bus_space_write_region_2 , .Nm bus_space_write_region_4 , -.Nm bus_space_write_region_8 +.Nm bus_space_write_region_8 , +.Nm bus_space_write_region_stream_1 , +.Nm bus_space_write_region_stream_2 , +.Nm bus_space_write_region_stream_4 , +.Nm bus_space_write_region_stream_8 , +.Nm bus_space_write_stream_1 , +.Nm bus_space_write_stream_2 , +.Nm bus_space_write_stream_4 , +.Nm bus_space_write_stream_8 .Nd "bus space manipulation functions" .Sh SYNOPSIS .In machine/bus.h @@ -147,6 +183,22 @@ .Fo bus_space_read_8 .Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" .Fc +.Ft u_int8_t +.Fo bus_space_read_stream_1 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc +.Ft u_int16_t +.Fo bus_space_read_stream_2 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc +.Ft u_int32_t +.Fo bus_space_read_stream_4 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc +.Ft u_int64_t +.Fo bus_space_read_stream_8 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc .Ft void .Fo bus_space_write_1 .Fa "bus_space_tag_t space" "bus_space_handle_t handle" @@ -168,6 +220,26 @@ .Fa "bus_size_t offset" "u_int64_t value" .Fc .Ft void +.Fo bus_space_write_stream_1 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int8_t value" +.Fc +.Ft void +.Fo bus_space_write_stream_2 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int16_t value" +.Fc +.Ft void +.Fo bus_space_write_stream_4 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int32_t value" +.Fc +.Ft void +.Fo bus_space_write_stream_8 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int64_t value" +.Fc +.Ft void .Fo bus_space_barrier .Fa "bus_space_tag_t space" "bus_space_handle_t handle" .Fa "bus_size_t offset" "bus_size_t length" "int flags" @@ -197,6 +269,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_read_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_write_region_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" @@ -221,6 +317,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_write_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_copy_region_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" @@ -245,6 +365,30 @@ .Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" .Fc .Ft void +.Fo bus_space_copy_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_copy_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_copy_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_copy_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void .Fo bus_space_set_region_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" @@ -269,6 +413,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_set_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t value" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_read_multi_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" @@ -293,6 +461,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_read_multi_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_multi_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_multi_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_multi_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_write_multi_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" @@ -317,6 +509,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_write_multi_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_multi_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_multi_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_multi_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_set_multi_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" @@ -340,6 +556,30 @@ .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t value" .Fa "bus_size_t count" .Fc +.Ft void +.Fo bus_space_set_multi_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_multi_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_multi_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_multi_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t value" +.Fa "bus_size_t count" +.Fc .Sh DESCRIPTION The .Nm @@ -1356,6 +1596,58 @@ argument error), that indicates a software bug which should cause a panic. In that case, they will never return. +.Sh STREAM FUNCTIONS +Most of the +.Nm +functions imply a host byte-order and a bus byte-order and take care of +any translation for the caller. +In some cases, however, hardware may map a FIFO or some other memory region +for which the caller may want to use multi-word, yet untranslated access. +Access to these types of memory regions should be with the +.Fn bus_space_*_stream_N +functions. +.Pp +.Bl -tag -compact +.It Fn bus_space_read_stream_1 +.It Fn bus_space_read_stream_2 +.It Fn bus_space_read_stream_4 +.It Fn bus_space_read_stream_8 +.It Fn bus_space_read_multi_stream_1 +.It Fn bus_space_read_multi_stream_2 +.It Fn bus_space_read_multi_stream_4 +.It Fn bus_space_read_multi_stream_8 +.It Fn bus_space_read_region_stream_1 +.It Fn bus_space_read_region_stream_2 +.It Fn bus_space_read_region_stream_4 +.It Fn bus_space_read_region_stream_8 +.It Fn bus_space_write_stream_1 +.It Fn bus_space_write_stream_2 +.It Fn bus_space_write_stream_4 +.It Fn bus_space_write_stream_8 +.It Fn bus_space_write_multi_stream_1 +.It Fn bus_space_write_multi_stream_2 +.It Fn bus_space_write_multi_stream_4 +.It Fn bus_space_write_multi_stream_8 +.It Fn bus_space_write_region_stream_1 +.It Fn bus_space_write_region_stream_2 +.It Fn bus_space_write_region_stream_4 +.It Fn bus_space_write_region_stream_8 +.It Fn bus_space_copy_region_stream_1 +.It Fn bus_space_copy_region_stream_2 +.It Fn bus_space_copy_region_stream_4 +.It Fn bus_space_copy_region_stream_8 +.It Fn bus_space_set_multi_stream_1 +.It Fn bus_space_set_multi_stream_2 +.It Fn bus_space_set_multi_stream_4 +.It Fn bus_space_set_multi_stream_8 +.It Fn bus_space_set_region_stream_1 +.It Fn bus_space_set_region_stream_2 +.It Fn bus_space_set_region_stream_4 +.It Fn bus_space_set_region_stream_8 +.El +.Pp +These functions are defined just as their non-stream counterparts, +except that they provide no byte-order translation. .Sh COMPATIBILITY The current .Nx Index: critical_enter.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/critical_enter.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/critical_enter.9 -L share/man/man9/critical_enter.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/critical_enter.9 +++ share/man/man9/critical_enter.9 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/critical_enter.9,v 1.7.14.1 2005/10/14 18:34:29 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/critical_enter.9,v 1.8 2005/10/05 19:48:21 jhb Exp $ .\" .Dd October 5, 2005 .Dt CRITICAL_ENTER 9 Index: vm_page_sleep_busy.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_sleep_busy.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_sleep_busy.9 -L share/man/man9/vm_page_sleep_busy.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_sleep_busy.9 +++ share/man/man9/vm_page_sleep_busy.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_sleep_busy.9,v 1.2 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_SLEEP_BUSY 9 Index: pmap_extract.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pmap_extract.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pmap_extract.9 -L share/man/man9/pmap_extract.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pmap_extract.9 +++ share/man/man9/pmap_extract.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pmap_extract.9,v 1.3 2004/07/06 07:02:31 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pmap_extract.9,v 1.4 2007/01/28 16:23:55 rwatson Exp $ .\" .Dd July 21, 2003 .Dt PMAP_EXTRACT 9 @@ -55,13 +55,6 @@ the given page protection. .Sh IMPLEMENTATION NOTES Currently, the page protection requested by the caller is not verified. -.Pp -In the -.Fn pmap_extract_and_hold -function, the -.Va Giant -lock is held for the duration of the call to ensure that only a single -caller is present. .Sh RETURN VALUES The .Fn pmap_extract Index: VOP_OPENCLOSE.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_OPENCLOSE.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_OPENCLOSE.9 -L share/man/man9/VOP_OPENCLOSE.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_OPENCLOSE.9 +++ share/man/man9/VOP_OPENCLOSE.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_OPENCLOSE.9,v 1.18 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_OPENCLOSE.9,v 1.19 2007/06/05 10:48:29 kib Exp $ .\" -.Dd July 24, 1996 +.Dd June 5, 2007 .Os .Dt VOP_OPEN 9 .Sh NAME @@ -39,7 +39,7 @@ .In sys/param.h .In sys/vnode.h .Ft int -.Fn VOP_OPEN "struct vnode *vp" "int mode" "struct ucred *cred" "struct thread *td" "int fdidx" +.Fn VOP_OPEN "struct vnode *vp" "int mode" "struct ucred *cred" "struct thread *td" "struct file *fp" .Ft int .Fn VOP_CLOSE "struct vnode *vp" "int mode" "struct ucred *cred" "struct thread *td" .Sh DESCRIPTION @@ -57,14 +57,21 @@ The access mode required by the calling process. .It Fa td The thread which is accessing the file. +.It Fa fp +The file being opened. .El .Pp -Additionally, -.Fn VOP_OPEN -can accept a file descriptor number in -.Fa fdidx ; -this is useful for file systems which require such information, e.g., +Pointer to the file +.Fa fp +is useful for file systems which require such information, e.g., .Xr fdescfs 5 . +Use +.Ql NULL +as +.Fa fp +argument to +.Fn VOP_OPEN +for in-kernel opens. .Pp The access mode is a set of flags, including .Dv FREAD , @@ -85,20 +92,13 @@ .Fa vn_close expects an unlocked, referenced vnode and will dereference the vnode prior to returning. -.Sh IMPLEMENTATION NOTES -The -.Fa fdidx -argument to -.Fn VOP_OPEN -is currently unused, use -.Ql \-1 -for the meantime; however, this will change in future. .Sh RETURN VALUES Zero is returned on success, otherwise an error code is returned. .Sh PSEUDOCODE .Bd -literal int -vop_open(struct vnode *vp, int mode, struct ucred *cred, struct thread *td) +vop_open(struct vnode *vp, int mode, struct ucred *cred, struct thread *td, + struct file *fp) { /* * Most file systems don't do much here. Index: mac.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mac.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/mac.9 -L share/man/man9/mac.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/mac.9 +++ share/man/man9/mac.9 @@ -31,9 +31,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mac.9,v 1.15 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/mac.9,v 1.17 2006/07/11 16:26:40 joel Exp $ .\" -.Dd February 16, 2002 +.Dd July 10, 2006 .Dt MAC 9 .Os .Sh NAME @@ -152,7 +152,7 @@ policies. .Sh ENTRY POINTS System service and module authors should reference the -.%T "FreeBSD Developer's Handbook" +.%T "FreeBSD Architecture Handbook" for information on the MAC Framework APIs. .Sh SEE ALSO .Xr acl 3 , @@ -172,8 +172,8 @@ .Xr vaccess_acl_posix1e 9 , .Xr VFS 9 .Rs -.%T "The FreeBSD Developers' Handbook" -.%O "http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/developers-handbook/" +.%T "The FreeBSD Architecture Handbook" +.%O "http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/arch-handbook/" .Re .Sh HISTORY The Index: vm_page_rename.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_rename.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_rename.9 -L share/man/man9/vm_page_rename.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_rename.9 +++ share/man/man9/vm_page_rename.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_rename.9,v 1.2 2001/08/08 10:04:08 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_RENAME 9 Index: hash.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/hash.9,v retrieving revision 1.1 retrieving revision 1.2 diff -L share/man/man9/hash.9 -L share/man/man9/hash.9 -u -r1.1 -r1.2 --- share/man/man9/hash.9 +++ share/man/man9/hash.9 @@ -24,39 +24,39 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $OpenBSD: hash.9,v 1.5 2003/04/17 05:08:39 jmc Exp $ -.\" $FreeBSD: src/share/man/man9/hash.9,v 1.1.2.1 2006/04/04 19:50:02 andre Exp $ +.\" $FreeBSD: src/share/man/man9/hash.9,v 1.4 2007/04/09 22:55:14 thompsa Exp $ .\" -.Dd December 8, 2001 +.Dd April 3, 2007 .Dt HASH 9 .Os .Sh NAME -.Nm hash -.\" XXX - Should all these be .Nm as well? -.\" .Nm hash32 , -.\" .Nm hash32_buf , -.\" .Nm hash32_str , -.\" .Nm hash32_strn , -.\" .Nm hash32_stre , -.\" .Nm hash32_strne +.Nm hash , +.Nm hash32 , +.Nm hash32_buf , +.Nm hash32_str , +.Nm hash32_strn , +.Nm hash32_stre , +.Nm hash32_strne .Nd general kernel hashing functions .Sh SYNOPSIS -.Fd #include +.In sys/hash.h .Ft uint32_t -.Fn hash32_buf "void *buf" "size_t len" "uint32_t hash" +.Fn hash32_buf "const void *buf" "size_t len" "uint32_t hash" .Ft uint32_t -.Fn hash32_str "void *buf" "uint32_t hash" +.Fn hash32_str "const void *buf" "uint32_t hash" .Ft uint32_t -.Fn hash32_strn "void *buf" "size_t len" "uint32_t hash" +.Fn hash32_strn "const void *buf" "size_t len" "uint32_t hash" .Ft uint32_t -.Fn hash32_stre "void *buf" "int end" "char **ep" "uint32_t hash" +.Fn hash32_stre "const void *buf" "int end" "const char **ep" "uint32_t hash" .Ft uint32_t -.Fn hash32_strne "void *buf" "size_t len" "int end" "char **ep" "uint32_t hash" +.Fn hash32_strne "const void *buf" "size_t len" "int end" "const char **ep" "uint32_t hash" .Sh DESCRIPTION The .Fn hash32 functions are used to give a consistent and general interface to a decent hashing algorithm within the kernel. -These functions can be used to hash ASCII +These functions can be used to hash +.Tn ASCII .Dv NUL terminated strings, as well as blocks of memory. .Pp @@ -119,6 +119,7 @@ void sample_init(void) { + hashtbl = hashinit(numwanted, type, flags, &mask); } Index: buf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/buf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/buf.9 -L share/man/man9/buf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/buf.9 +++ share/man/man9/buf.9 @@ -29,7 +29,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/buf.9,v 1.17 2005/02/15 09:27:00 ru Exp $ +.\" $FreeBSD: src/share/man/man9/buf.9,v 1.18 2006/02/13 21:34:18 joel Exp $ .\" .Dd December 22, 1998 .Dt BUF 9 @@ -138,7 +138,6 @@ buffer cache from being freed. This can complicate the life of the paging system. -.Pp .\" .Sh SEE ALSO .\" .Xr 9 .Sh HISTORY Index: SYSCALL_MODULE.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/SYSCALL_MODULE.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/SYSCALL_MODULE.9 -L share/man/man9/SYSCALL_MODULE.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/SYSCALL_MODULE.9 +++ share/man/man9/SYSCALL_MODULE.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/SYSCALL_MODULE.9,v 1.6 2005/01/07 09:02:40 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/SYSCALL_MODULE.9,v 1.7 2006/04/15 12:04:18 maxim Exp $ .\" .Dd January 7, 2005 .Dt SYSCALL_MODULE 9 @@ -40,7 +40,7 @@ .In sys/proc.h .In sys/module.h .In sys/sysent.h -.Fn SYSCALL_MODULE name "int *offset" "struct sysent new_sysent" "modeventhand_t evh" "void *arg" +.Fn SYSCALL_MODULE name "int *offset" "struct sysent *new_sysent" "modeventhand_t evh" "void *arg" .Sh DESCRIPTION The .Fn SYSCALL_MODULE @@ -58,8 +58,8 @@ .Vt "struct sysent" where the syscall is allocated. .It Fa new_sysent -The function implementing the syscall and the number of arguments this -function needs (see +is a pointer to a structure that specifies the function implementing +the syscall and the number of arguments this function needs (see .In sys/sysent.h ) . .It Fa evh A pointer to the kernel module event handler function with the argument --- /dev/null +++ share/man/man9/priv.9 @@ -0,0 +1,123 @@ +.\"- +.\" Copyright (c) 2006 nCircle Network Security, Inc. +.\" All rights reserved. +.\" +.\" This software was developed by Robert N. M. Watson for the TrustedBSD +.\" Project under contract to nCircle Network Security, Inc. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR, NCIRCLE NETWORK SECURITY, +.\" INC., OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +.\" SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +.\" TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +.\" PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +.\" LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +.\" NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +.\" SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/priv.9,v 1.6 2007/06/26 23:12:05 rwatson Exp $ +.\" +.Dd August 30, 2006 +.Dt PRIV 9 +.Os +.Sh NAME +.Nm priv +.Nd kernel privilege checking API +.Sh SYNOPSIS +.In sys/priv.h +.Ft int +.Fn priv_check "struct thread *td" "int priv" +.Ft int +.Fn priv_check_cred "struct ucred *cred" "int priv" "int flags" +.Sh DESCRIPTION +The +.Nm +interfaces check to see if specific system privileges are granted to the +passed thread, +.Fa td , +or credential, +.Fa cred . +This interface replaces the +.Xr suser 9 +privilege checking interface. +Privileges typically represent rights in one of two categories: the right to +manage a particular component of the system, or an exemption to a specific +policy or access control list. +The caller identifies the desired privilege via the +.Fa priv +argument. +The optional flags argument, +.Fa flags , +is currently unused. +.Ss Privilege Policies +Privileges are typically granted based on one of two base system policies: +the superuser policy, which grants privilege based on the effective (or +sometimes real) UID having a value of 0, and the +.Xr jail 2 +policy, which permits only certain privileges to be granted to processes in a +jail. +The set of available privileges may also be influenced by the TrustedBSD MAC +Framework, described in +.Xr mac 9 . +.Sh IMPLEMENTATION NOTES +When adding a new privilege check to a code path, first check the complete +list of current privileges in +.Pa sys/priv.h +to see if one already exists for the class of privilege required. +Only if there is not an exact match should a new privilege be added to the +privilege list. +As privilege numbers becomes encoded in the kernel module ABI, privilege +constants must not be changed as any kernel modules depending on privileges +will then need to be recompiled. +When adding a new privilege, be certain to also determine whether it should +be listed in +.Fn prison_priv_check , +which includes a complete list of privileges granted to the root user in +.Xr jail 2 . +.Pp +Certain catch-all privileges exist, such as +.Dv PRIV_DRIVER , +intended to be used by device drivers, rather than adding a new +driver-specific privilege. +.Sh RETURN VALUES +Typically, 0 will be returned for success, and +.Er EPERM +will be returned on failure. +Most consumers of +.Nm +will wish to directly return the error code from a failed privilege check to +user space; a small number will wish to translate it to another error code +appropriate to a specific context. +.Pp +When designing new APIs, it is preferable to return explicit errors from a +call if privilege is not granted rather than changing the semantics of the +call but returning success. +For example, the behavior exhibited by +.Xr stat 2 , +in which the generation field is optionally zero'd out when there is +insufficient privilege is highly undesirable, as it results in frequent +privilege checks, and the caller is unable to tell if an access control +failure occurred. +.Sh SEE ALSO +.Xr jail 2 , +.Xr mac 9 , +.Xr suser 9 , +.Xr ucred 9 +.Sh AUTHORS +The +.Nm +API and implementation were created by +.An Robert Watson +under contract to +nCircle Network Security, Inc. Index: VOP_FSYNC.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_FSYNC.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_FSYNC.9 -L share/man/man9/VOP_FSYNC.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_FSYNC.9 +++ share/man/man9/VOP_FSYNC.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_FSYNC.9,v 1.15 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_FSYNC.9,v 1.16 2007/05/12 13:10:55 pav Exp $ .\" .Dd July 24, 1996 .Os @@ -38,7 +38,7 @@ .In sys/param.h .In sys/vnode.h .Ft int -.Fn VOP_FSYNC "struct vnode *vp" "struct ucred *cred" "int waitfor" "struct thread *td" +.Fn VOP_FSYNC "struct vnode *vp" "int waitfor" "struct thread *td" .Sh DESCRIPTION This call flushes any dirty file system buffers for the file. It is used to implement the @@ -51,8 +51,6 @@ .Bl -tag -width waitfor .It Fa vp The vnode of the file. -.It Fa cred -The caller's credentials. .It Fa waitfor Whether the function should wait for I/O to complete. Possible values are: @@ -84,7 +82,7 @@ .Sh PSEUDOCODE .Bd -literal int -vop_fsync(struct vnode *vp, struct ucred *cred, int waitfor, struct thread *td) +vop_fsync(struct vnode *vp, int waitfor, struct thread *td) { struct buf *bp; struct buf *nbp; Index: driver.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/driver.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/driver.9 -L share/man/man9/driver.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/driver.9 +++ share/man/man9/driver.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/driver.9,v 1.11 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/driver.9,v 1.12 2005/08/08 12:16:53 brian Exp $ .\" .Dd June 16, 1998 .Dt DRIVER 9 @@ -45,7 +45,7 @@ static int foo_frob(device_t, int, int); static int foo_twiddle(device_t, char *); -static struct device_method_t foo_methods[] = { +static device_method_t foo_methods[] = { /* Methods from the device interface */ DEVMETHOD(device_probe, foo_probe), DEVMETHOD(device_attach, foo_attach), Index: vm_page_free.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_free.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_free.9 -L share/man/man9/vm_page_free.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_free.9 +++ share/man/man9/vm_page_free.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_free.9,v 1.2 2001/08/08 10:04:08 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 2001 .Dt VM_PAGE_FREE 9 Index: VFS_SYNC.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_SYNC.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_SYNC.9 -L share/man/man9/VFS_SYNC.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_SYNC.9 +++ share/man/man9/VFS_SYNC.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_SYNC.9,v 1.15 2005/06/15 13:31:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_SYNC.9,v 1.16 2007/05/12 13:10:55 pav Exp $ .\" .Dd January 7, 2005 .Os @@ -39,7 +39,7 @@ .In sys/mount.h .In sys/vnode.h .Ft int -.Fn VFS_SYNC "struct mount *mp" "int waitfor" "struct ucred *cred" "struct thread *td" +.Fn VFS_SYNC "struct mount *mp" "int waitfor" "struct thread *td" .Sh DESCRIPTION The .Fn VFS_SYNC @@ -61,8 +61,6 @@ .It Dv MNT_LAZY push data not written by file system syncer .El -.It Fa cred -The caller's credentials. .It Fa td The calling thread. .El Index: sbuf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sbuf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sbuf.9 -L share/man/man9/sbuf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sbuf.9 +++ share/man/man9/sbuf.9 @@ -23,12 +23,13 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sbuf.9,v 1.24 2004/07/09 11:44:49 des Exp $ +.\" $FreeBSD: src/share/man/man9/sbuf.9,v 1.26 2006/09/18 15:24:20 ru Exp $ .\" .Dd July 9, 2004 .Dt SBUF 9 .Os .Sh NAME +.Nm sbuf , .Nm sbuf_new , .Nm sbuf_clear , .Nm sbuf_setpos , @@ -92,7 +93,7 @@ .Fn sbuf_delete "struct sbuf *s" .Sh DESCRIPTION The -.Nm sbuf +.Nm family of functions allows one to safely allocate, construct and release bounded null-terminated strings in kernel space. Instead of arrays of characters, these functions operate on structures @@ -308,35 +309,48 @@ or it is reinitialized to a sufficiently short string using .Fn sbuf_cpy . .Sh RETURN VALUES +The .Fn sbuf_new -returns +function returns .Dv NULL if it failed to allocate a storage buffer, and a pointer to the new .Fa sbuf otherwise. .Pp +The .Fn sbuf_setpos -returns \-1 if +function returns \-1 if .Fa pos was invalid, and zero otherwise. .Pp +The .Fn sbuf_cat , .Fn sbuf_cpy , .Fn sbuf_printf , .Fn sbuf_putc , and .Fn sbuf_trim +functions all return \-1 if the buffer overflowed, and zero otherwise. .Pp +The .Fn sbuf_overflowed +function returns a non-zero value if the buffer overflowed, and zero otherwise. .Pp +The .Fn sbuf_data and .Fn sbuf_len -return +functions return .Dv NULL and \-1, respectively, if the buffer overflowed. +.Pp +The +.Fn sbuf_copyin +function +returns \-1 if copying string from userland failed, and number of bytes +copied otherwise. .Sh SEE ALSO .Xr printf 3 , .Xr strcat 3 , @@ -346,13 +360,13 @@ .Xr printf 9 .Sh HISTORY The -.Nm sbuf +.Nm family of functions first appeared in .Fx 4.4 . .Sh AUTHORS .An -nosplit The -.Nm sbuf +.Nm family of functions was designed by .An Poul-Henning Kamp Aq phk at FreeBSD.org and implemented by Index: sysctl_add_oid.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sysctl_add_oid.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sysctl_add_oid.9 -L share/man/man9/sysctl_add_oid.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sysctl_add_oid.9 +++ share/man/man9/sysctl_add_oid.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sysctl_add_oid.9,v 1.20 2004/07/03 18:29:24 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sysctl_add_oid.9,v 1.21 2006/04/28 10:45:27 rwatson Exp $ .\" .Dd July 15, 2000 .Dt SYSCTL_ADD_OID 9 @@ -496,6 +496,7 @@ .Em "Care should be taken to free all oids once they are no longer needed!" .Sh SEE ALSO .Xr sysctl 8 , +.Xr sysctl 9 , .Xr sysctl_ctx_free 9 , .Xr sysctl_ctx_init 9 .Sh HISTORY Index: selrecord.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/selrecord.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/selrecord.9 -L share/man/man9/selrecord.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/selrecord.9 +++ share/man/man9/selrecord.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/selrecord.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/selrecord.9,v 1.4 2007/06/14 22:38:50 njl Exp $ .\" -.Dd March 20, 2002 +.Dd June 13, 2007 .Dt SELRECORD 9 .Os .Sh NAME @@ -86,6 +86,13 @@ .Xr poll 2 when they wake up. .Pp +The contents of +.Fa *sip +must be zeroed, such as by softc initialization, before any call to +.Fn selrecord +or +.Fn selwakeup , +otherwise a panic may occur. .Fn selwakeup acquires and releases .Va sellock Index: VFS.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS.9 -L share/man/man9/VFS.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS.9 +++ share/man/man9/VFS.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS.9,v 1.11.2.1 2005/07/27 02:11:20 scottl Exp $ +.\" $FreeBSD: src/share/man/man9/VFS.9,v 1.12 2005/07/27 02:08:59 scottl Exp $ .\" .Dd July 24, 1996 .Os --- /dev/null +++ share/man/man9/p_cansee.9 @@ -0,0 +1,93 @@ +.\" +.\" Copyright (c) 2003 Joseph Koshy +.\" Copyright (c) 2006 Ceri Davies +.\" +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/p_cansee.9,v 1.1 2006/11/19 13:35:03 ceri Exp $ +.\" +.Dd November 19, 2006 +.Os +.Dt P_CANSEE 9 +.Sh NAME +.Nm p_cansee +.Nd determine visibility of a process +.Sh SYNOPSIS +.In sys/param.h +.In sys/proc.h +.Ft int +.Fn p_cansee "struct thread *td" "struct proc *p" +.Sh DESCRIPTION +This function can be used to determine if a given process +.Fa p +is visible to the thread +.Fa td , +where the notion of +.Dq visibility +may be read as +.Dq "awareness of existence" . +.Pp +The function is implemented using +.Xr cr_cansee 9 , +and the dependencies on +.Xr sysctl 8 +variables documented in the +.Xr cr_cansee 9 +manual page apply. +.Sh RETURN VALUES +The +.Fn p_cansee +function +returns +.Li 0 +if the process denoted by +.Fa p +is visible by thread +.Fa td , +or a non-zero error return value otherwise. +.Sh ERRORS +.Bl -tag -width Er +.It Bq Er ESRCH +Process +.Fa p +is not visible to thread +.Fa td +as determined by +.Xr cr_cansee 9 . +.It Bq Er ESRCH +Thread +.Fa td +has been jailed and process +.Fa p +does not belong to the same jail as +.Fa td . +.It Bq Er ESRCH +The MAC subsystem denied visibility. +.El +.Sh SEE ALSO +.Xr jail 2 , +.Xr sysctl 8 , +.Xr cr_cansee 9 , +.Xr mac 9 , +.Xr p_candebug 9 , +.Xr prison_check 9 --- /dev/null +++ share/man/man9/sf_buf.9 @@ -0,0 +1,141 @@ +.\" +.\" Copyright (c) 2007 Seccuris Inc. +.\" All rights reserved. +.\" +.\" This documentation was written by Robert N. M. Watson under contract to +.\" Seccuris Inc. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/sf_buf.9,v 1.2 2007/01/31 09:40:31 rwatson Exp $ +.\" +.Dd January 28, 2007 +.Dt SF_BUF 9 +.Os +.Sh NAME +.Nm sf_buf +.Nd manage temporary kernel address space mapping for memory pages +.Sh SYNOPSIS +.In sys/sf_buf.h +.Ft struct sf_buf * +.Fn sf_buf_alloc "struct vm_page *m" "int flags" +.Ft void +.Fn sf_buf_free "struct sf_buf *sf" +.Ft vm_offset_t +.Fn sf_buf_kva "struct sf_buf *sf" +.Ft struct vm_page * +.Fn sf_buf_page "struct sf_buf *sf" +.Sh DESCRIPTION +The +.Nm +interface, historically the +.Xr sendfile 2 +buffer interface, allows kernel subsystems to manage temporary kernel address +space mappings for physical memory pages. +On systems with a direct memory map region (allowing all physical pages to be +visible in the kernel address space at all times), the +.Vt "struct sf_buf" +will point to an address in the direct map region; on systems without a +direct memory map region, the +.Vt "struct sf_buf" +will manage a temporary kernel address space mapping valid for the lifetime +of the +.Vt "struct sf_buf". +.Pp +Call +.Fn sf_buf_alloc +to allocate a +.Vt "struct sf_buf" +for a physical memory page. +.Fn sf_buf_alloc +is not responsible for arranging for the page to be present in physical +memory; the caller should already have arranged for the page to be wired, +i.e., by calling +.Xr vm_page_wire 9 . +Several flags may be passed to +.Fn sf_buf_alloc : +.Bl -tag -width SFB_CPUPRIVATE +.It Dv SFB_CATCH +Cause +.Fn sf_buf_alloc +to abort and return +.Dv NULL +if a signal is received waiting for a +.Vt "struct sf_buf" +to become available. +.It Dv SFB_NOWAIT +Cause +.Fn sf_buf_alloc +to return +.Dv NULL +rather than sleeping if a +.Vt "struct sf_buf" +is not immediately available. +.It Dv SFB_CPUPRIVATE +Cause +.Fn sf_buf_alloc +to only arrange that the temporary mapping be valid on the current CPU, +avoiding unnecessary TLB shootdowns for mappings that will only be accessed +on a single CPU at a time. +The caller must ensure that accesses to the virtual address occur only on the +CPU from which +.Fn sf_buf_alloc +was invoked, perhaps by using +.Fn sched_pin . +.El +.Pp +Call +.Fn sf_buf_kva +to return a kernel mapped address for the page. +.Pp +Call +.Fn sf_buf_page +to return a pointer to the page originally passed into +.Fn sf_buf_alloc . +.Pp +Call +.Fn sf_buf_free +to release the +.Vt "struct sf_buf" +reference. +The caller is responsible for releasing any wiring they have previously +acquired on the physical page; +.Fn sf_buf_free +releases only the temporary kernel address space mapping, not the page +itself. +.Pp +Uses of this interface include managing mappings of borrowed pages from user +memory, such as in zero-copy socket I/O, or pages of memory from the buffer +cache referenced by mbuf external storage for +.Xr sendfile 2 . +.Sh SEE ALSO +.Xr sendfile 2 , +.Xr vm_page_wire 9 +.Sh AUTHORS +The +.Vt "struct sf_buf" +API was designed and implemented by +.An Alan L. Cox . +This manual page was written by +.An Robert N. M. Watson . Index: kobj.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/kobj.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/kobj.9 -L share/man/man9/kobj.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/kobj.9 +++ share/man/man9/kobj.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/kobj.9,v 1.16 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/kobj.9,v 1.17 2006/10/28 10:57:35 maxim Exp $ .\" .Dd April 4, 2000 .Dt KOBJ 9 @@ -83,7 +83,7 @@ specified by the class and initialise it by zeroing the memory and installing a pointer to the class' method dispatch table. Objects created in this way should be freed by calling -.Fn kobj_free . +.Fn kobj_delete . .Pp Clients which would like to manage the allocation of memory themselves should call Index: Makefile =================================================================== RCS file: /home/cvs/src/share/man/man9/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/Makefile -L share/man/man9/Makefile -u -r1.2 -r1.3 --- share/man/man9/Makefile +++ share/man/man9/Makefile @@ -1,4 +1,5 @@ -# $FreeBSD: src/share/man/man9/Makefile,v 1.260.2.5 2006/02/23 02:13:29 mlaier Exp $ +# $MidnightBSD$ +# $FreeBSD: src/share/man/man9/Makefile,v 1.310.2.1.2.1 2008/02/15 15:19:26 brueffer Exp $ MAN= accept_filter.9 \ accf_data.9 \ @@ -38,8 +39,10 @@ byteorder.9 \ cd.9 \ condvar.9 \ + config_intrhook.9 \ contigmalloc.9 \ copy.9 \ + cr_cansee.9 \ critical_enter.9 \ cr_seeothergids.9 \ cr_seeotheruids.9 \ @@ -72,6 +75,7 @@ device_get_parent.9 \ device_get_softc.9 \ device_get_state.9 \ + device_get_sysctl.9 \ device_get_unit.9 \ DEVICE_IDENTIFY.9 \ device_ids.9 \ @@ -85,7 +89,6 @@ DEVICE_SHUTDOWN.9 \ DEV_MODULE.9 \ devstat.9 \ - devsw.9 \ devtoname.9 \ disk.9 \ domain.9 \ @@ -127,9 +130,12 @@ kernacc.9 \ kernel_mount.9 \ kobj.9 \ + kqueue.9 \ kthread.9 \ ktr.9 \ lock.9 \ + locking.9 \ + LOCK_PROFILING.9 \ mac.9 \ make_dev.9 \ malloc.9 \ @@ -149,11 +155,11 @@ MODULE_VERSION.9 \ mtx_pool.9 \ mutex.9 \ - MUTEX_PROFILING.9 \ namei.9 \ panic.9 \ pbuf.9 \ p_candebug.9 \ + p_cansee.9 \ pci.9 \ pfil.9 \ pfind.9 \ @@ -185,10 +191,12 @@ pmap_zero_page.9 \ printf.9 \ prison_check.9 \ + priv.9 \ pseudofs.9 \ psignal.9 \ random.9 \ random_harvest.9 \ + redzone.9 \ resettodr.9 \ resource_int_value.9 \ rijndael.9 \ @@ -196,21 +204,26 @@ rtalloc.9 \ rtentry.9 \ runqueue.9 \ + rwlock.9 \ sbuf.9 \ scheduler.9 \ securelevel_gt.9 \ selrecord.9 \ sema.9 \ + sf_buf.9 \ signal.9 \ sleep.9 \ sleepqueue.9 \ + socket.9 \ spl.9 \ + stack.9 \ store.9 \ style.9 \ suser.9 \ swi.9 \ sx.9 \ SYSCALL_MODULE.9 \ + sysctl.9 \ sysctl_add_oid.9 \ sysctl_ctx_init.9 \ taskqueue.9 \ @@ -221,6 +234,7 @@ ucred.9 \ uidinfo.9 \ uio.9 \ + usbdi.9 \ utopia.9 \ vaccess.9 \ vaccess_acl_posix1e.9 \ @@ -232,6 +246,7 @@ vfsconf.9 \ VFS_FHTOVP.9 \ vfs_getnewfsid.9 \ + vfs_getopt.9 \ vfs_getvfs.9 \ VFS_LOCK_GIANT.9 \ VFS_MOUNT.9 \ @@ -249,7 +264,6 @@ VFS_UNMOUNT.9 \ vfs_unmountall.9 \ VFS_VGET.9 \ - VFS_VPTOFH.9 \ vget.9 \ vgone.9 \ vhold.9 \ @@ -292,7 +306,6 @@ vm_page_protect.9 \ vm_page_rename.9 \ vm_page_sleep_busy.9 \ - vm_page_unmanage.9 \ vm_page_wakeup.9 \ vm_page_wire.9 \ vm_page_zero_fill.9 \ @@ -331,6 +344,7 @@ VOP_SETACL.9 \ VOP_SETEXTATTR.9 \ VOP_STRATEGY.9 \ + VOP_VPTOFH.9 \ vput.9 \ vref.9 \ vrele.9 \ @@ -368,6 +382,7 @@ bus_dma.9 bus_dmamap_destroy.9 \ bus_dma.9 bus_dmamap_load.9 \ bus_dma.9 bus_dmamap_load_mbuf.9 \ + bus_dma.9 bus_dmamap_load_mbuf_sg.9 \ bus_dma.9 bus_dmamap_load_uio.9 \ bus_dma.9 bus_dmamap_sync.9 \ bus_dma.9 bus_dmamap_unload.9 \ @@ -380,6 +395,83 @@ MLINKS+=BUS_SETUP_INTR.9 bus_setup_intr.9 \ BUS_SETUP_INTR.9 BUS_TEARDOWN_INTR.9 \ BUS_SETUP_INTR.9 bus_teardown_intr.9 +MLINKS+=bus_space.9 bus_space_barrier.9 \ + bus_space.9 bus_space_copy_region_1.9 \ + bus_space.9 bus_space_copy_region_2.9 \ + bus_space.9 bus_space_copy_region_4.9 \ + bus_space.9 bus_space_copy_region_8.9 \ + bus_space.9 bus_space_copy_region_stream_1.9 \ + bus_space.9 bus_space_copy_region_stream_2.9 \ + bus_space.9 bus_space_copy_region_stream_4.9 \ + bus_space.9 bus_space_copy_region_stream_8.9 \ + bus_space.9 bus_space_free.9 \ + bus_space.9 bus_space_map.9 \ + bus_space.9 bus_space_read_1.9 \ + bus_space.9 bus_space_read_2.9 \ + bus_space.9 bus_space_read_4.9 \ + bus_space.9 bus_space_read_8.9 \ + bus_space.9 bus_space_read_multi_1.9 \ + bus_space.9 bus_space_read_multi_2.9 \ + bus_space.9 bus_space_read_multi_4.9 \ + bus_space.9 bus_space_read_multi_8.9 \ + bus_space.9 bus_space_read_multi_stream_1.9 \ + bus_space.9 bus_space_read_multi_stream_2.9 \ + bus_space.9 bus_space_read_multi_stream_4.9 \ + bus_space.9 bus_space_read_multi_stream_8.9 \ + bus_space.9 bus_space_read_region_1.9 \ + bus_space.9 bus_space_read_region_2.9 \ + bus_space.9 bus_space_read_region_4.9 \ + bus_space.9 bus_space_read_region_8.9 \ + bus_space.9 bus_space_read_region_stream_1.9 \ + bus_space.9 bus_space_read_region_stream_2.9 \ + bus_space.9 bus_space_read_region_stream_4.9 \ + bus_space.9 bus_space_read_region_stream_8.9 \ + bus_space.9 bus_space_read_stream_1.9 \ + bus_space.9 bus_space_read_stream_2.9 \ + bus_space.9 bus_space_read_stream_4.9 \ + bus_space.9 bus_space_read_stream_8.9 \ + bus_space.9 bus_space_set_multi_1.9 \ + bus_space.9 bus_space_set_multi_2.9 \ + bus_space.9 bus_space_set_multi_4.9 \ + bus_space.9 bus_space_set_multi_8.9 \ + bus_space.9 bus_space_set_multi_stream_1.9 \ + bus_space.9 bus_space_set_multi_stream_2.9 \ + bus_space.9 bus_space_set_multi_stream_4.9 \ + bus_space.9 bus_space_set_multi_stream_8.9 \ + bus_space.9 bus_space_set_region_1.9 \ + bus_space.9 bus_space_set_region_2.9 \ + bus_space.9 bus_space_set_region_4.9 \ + bus_space.9 bus_space_set_region_8.9 \ + bus_space.9 bus_space_set_region_stream_1.9 \ + bus_space.9 bus_space_set_region_stream_2.9 \ + bus_space.9 bus_space_set_region_stream_4.9 \ + bus_space.9 bus_space_set_region_stream_8.9 \ + bus_space.9 bus_space_subregion.9 \ + bus_space.9 bus_space_unmap.9 \ + bus_space.9 bus_space_write_1.9 \ + bus_space.9 bus_space_write_2.9 \ + bus_space.9 bus_space_write_4.9 \ + bus_space.9 bus_space_write_8.9 \ + bus_space.9 bus_space_write_multi_1.9 \ + bus_space.9 bus_space_write_multi_2.9 \ + bus_space.9 bus_space_write_multi_4.9 \ + bus_space.9 bus_space_write_multi_8.9 \ + bus_space.9 bus_space_write_multi_stream_1.9 \ + bus_space.9 bus_space_write_multi_stream_2.9 \ + bus_space.9 bus_space_write_multi_stream_4.9 \ + bus_space.9 bus_space_write_multi_stream_8.9 \ + bus_space.9 bus_space_write_region_1.9 \ + bus_space.9 bus_space_write_region_2.9 \ + bus_space.9 bus_space_write_region_4.9 \ + bus_space.9 bus_space_write_region_8.9 \ + bus_space.9 bus_space_write_region_stream_1.9 \ + bus_space.9 bus_space_write_region_stream_2.9 \ + bus_space.9 bus_space_write_region_stream_4.9 \ + bus_space.9 bus_space_write_region_stream_8.9 \ + bus_space.9 bus_space_write_stream_1.9 \ + bus_space.9 bus_space_write_stream_2.9 \ + bus_space.9 bus_space_write_stream_4.9 \ + bus_space.9 bus_space_write_stream_8.9 MLINKS+=byteorder.9 be16dec.9 \ byteorder.9 be16enc.9 \ byteorder.9 be16toh.9 \ @@ -416,7 +508,10 @@ condvar.9 cv_timedwait_sig.9 \ condvar.9 cv_wait.9 \ condvar.9 cv_wait_sig.9 \ + condvar.9 cv_wait_unlock.9 \ condvar.9 cv_wmesg.9 +MLINKS+=config_intrhook.9 config_intrhook_disestablish.9 \ + config_intrhook.9 config_intrhook_establish.9 MLINKS+=contigmalloc.9 contigfree.9 MLINKS+=copy.9 copyin.9 \ copy.9 copyinstr.9 \ @@ -424,20 +519,20 @@ copy.9 copystr.9 MLINKS+=critical_enter.9 critical.9 \ critical_enter.9 critical_exit.9 -MLINKS+=crypto.9 crypto_get_driverid.9 \ - crypto.9 crypto_register.9 \ - crypto.9 crypto_kregister.9 \ - crypto.9 crypto_unregister.9 \ - crypto.9 crypto_unregister_all.9 \ +MLINKS+=crypto.9 crypto_dispatch.9 \ crypto.9 crypto_done.9 \ - crypto.9 crypto_kdone.9 \ - crypto.9 crypto_newsession.9 \ + crypto.9 crypto_freereq.9 \ crypto.9 crypto_freesession.9 \ - crypto.9 crypto_dispatch.9 \ + crypto.9 crypto_get_driverid.9 \ + crypto.9 crypto_getreq.9 \ crypto.9 crypto_kdispatch.9 \ + crypto.9 crypto_kdone.9 \ + crypto.9 crypto_kregister.9 \ + crypto.9 crypto_newsession.9 \ + crypto.9 crypto_register.9 \ crypto.9 crypto_unblock.9 \ - crypto.9 crypto_getreq.9 \ - crypto.9 crypto_freereq.9 + crypto.9 crypto_unregister.9 \ + crypto.9 crypto_unregister_all.9 MLINKS+=devclass_add_driver.9 devclass_delete_driver.9 \ devclass_add_driver.9 devclass_find_driver.9 MLINKS+=device_add_child.9 device_add_child_ordered.9 @@ -449,6 +544,8 @@ device_get_state.9 device_is_alive.9 \ device_get_state.9 device_is_attached.9 \ device_get_state.9 device_unbusy.9 +MLINKS+=device_get_sysctl.9 device_get_sysctl_ctx.9 \ + device_get_sysctl.9 device_get_sysctl_tree.9 MLINKS+=device_ids.9 major.9 \ device_ids.9 minor.9 \ device_ids.9 umajor.9 \ @@ -467,19 +564,19 @@ disk.9 disk_destroy.9 MLINKS+=domain.9 DOMAIN_SET.9 \ domain.9 net_add_domain.9 \ - domain.9 pfctlinput2.9 \ domain.9 pfctlinput.9 \ + domain.9 pfctlinput2.9 \ domain.9 pffindproto.9 \ domain.9 pffindtype.9 MLINKS+=DRIVER_MODULE.9 MULTI_DRIVER_MODULE.9 MLINKS+=EVENTHANDLER.9 EVENTHANDLER_DECLARE.9 \ EVENTHANDLER.9 EVENTHANDLER_DEREGISTER.9 \ EVENTHANDLER.9 eventhandler_deregister.9 \ + EVENTHANDLER.9 eventhandler_find_list.9 \ EVENTHANDLER.9 EVENTHANDLER_INVOKE.9 \ + EVENTHANDLER.9 eventhandler_prune_list.9 \ EVENTHANDLER.9 EVENTHANDLER_REGISTER.9 \ - EVENTHANDLER.9 eventhandler_register.9 \ - EVENTHANDLER.9 eventhandler_find_list.9 \ - EVENTHANDLER.9 eventhandler_prune_list.9 + EVENTHANDLER.9 eventhandler_register.9 MLINKS+=fetch.9 fubyte.9 \ fetch.9 fuswintr.9 \ fetch.9 fusword.9 \ @@ -501,8 +598,15 @@ MLINKS+=g_provider.9 g_destroy_provider.9 \ g_provider.9 g_error_provider.9 \ g_provider.9 g_new_providerf.9 +MLINKS+=hash.9 hash32.9 \ + hash.9 hash32_buf.9 \ + hash.9 hash32_str.9 \ + hash.9 hash32_stre.9 \ + hash.9 hash32_strn.9 \ + hash.9 hash32_strne.9 MLINKS+=hashinit.9 hashdestroy.9 \ - hashinit.9 phashinit.9 + hashinit.9 phashinit.9 \ + hashinit.9 hashinit_flags.9 MLINKS+=ieee80211.9 ieee80211_attach.9 \ ieee80211.9 ieee80211_chan2ieee.9 \ ieee80211.9 ieee80211_chan2mode.9 \ @@ -572,6 +676,20 @@ kobj.9 kobj_create.9 \ kobj.9 kobj_delete.9 \ kobj.9 kobj_init.9 +MLINKS+=kqueue.9 knlist_add.9 \ + kqueue.9 knlist_clear.9 \ + kqueue.9 knlist_delete.9 \ + kqueue.9 knlist_destroy.9 \ + kqueue.9 knlist_empty.9 \ + kqueue.9 knlist_init.9 \ + kqueue.9 knlist_remove.9 \ + kqueue.9 knlist_remove_inevent.9 \ + kqueue.9 knote_fdclose.9 \ + kqueue.9 KNOTE_LOCKED.9 \ + kqueue.9 KNOTE_UNLOCKED.9 \ + kqueue.9 kqfd_register.9 \ + kqueue.9 kqueue_add_filteropts.9 \ + kqueue.9 kqueue_del_filteropts.9 MLINKS+=kthread.9 kproc_shutdown.9 \ kthread.9 kproc_start.9 \ kthread.9 kthread_create.9 \ @@ -591,6 +709,7 @@ lock.9 lockmgr.9 \ lock.9 lockmgr_printinfo.9 \ lock.9 lockstatus.9 +MLINKS+=LOCK_PROFILING.9 MUTEX_PROFILING.9 MLINKS+=make_dev.9 destroy_dev.9 \ make_dev.9 dev_depends.9 \ make_dev.9 make_dev_alias.9 @@ -720,6 +839,7 @@ mutex.9 mtx_lock_spin_flags.9 \ mutex.9 mtx_owned.9 \ mutex.9 mtx_recursed.9 \ + mutex.9 mtx_sleep.9 \ mutex.9 MTX_SYSINIT.9 \ mutex.9 mtx_trylock.9 \ mutex.9 mtx_trylock_flags.9 \ @@ -737,6 +857,7 @@ pci.9 pci_enable_busmaster.9 \ pci.9 pci_enable_io.9 \ pci.9 pci_find_bsf.9 \ + pci.9 pci_find_dbsf.9 \ pci.9 pci_find_device.9 \ pci.9 pci_get_powerstate.9 \ pci.9 pci_read_config.9 \ @@ -763,6 +884,8 @@ MLINKS+=printf.9 log.9 \ printf.9 tprintf.9 \ printf.9 uprintf.9 +MLINKS+=priv.9 priv_check.9 \ + priv.9 priv_check_cred.9 MLINKS+=psignal.9 gsignal.9 \ psignal.9 pgsignal.9 MLINKS+=random.9 arc4rand.9 \ @@ -775,7 +898,6 @@ rman.9 rman_await_resource.9 \ rman.9 rman_deactivate_resource.9 \ rman.9 rman_fini.9 \ - rman.9 rman_fini.9 \ rman.9 rman_get_bushandle.9 \ rman.9 rman_get_bustag.9 \ rman.9 rman_get_device.9 \ @@ -797,12 +919,25 @@ rman.9 rman_set_virtual.9 MLINKS+=rtalloc.9 rtalloc1.9 \ rtalloc.9 rtalloc_ign.9 \ - rtalloc.9 rtfree.9 \ - rtalloc.9 RTFREE.9 + rtalloc.9 RTFREE.9 \ + rtalloc.9 rtfree.9 MLINKS+=runqueue.9 chooseproc.9 \ runqueue.9 procrunnable.9 \ runqueue.9 remrunqueue.9 \ runqueue.9 setrunqueue.9 +MLINKS+=rwlock.9 rw_assert.9 \ + rwlock.9 rw_destroy.9 \ + rwlock.9 rw_downgrade.9 \ + rwlock.9 rw_init.9 \ + rwlock.9 rw_initialized.9 \ + rwlock.9 rw_rlock.9 \ + rwlock.9 rw_runlock.9 \ + rwlock.9 rw_sleep.9 \ + rwlock.9 RW_SYSINIT.9 \ + rwlock.9 rw_try_upgrade.9 \ + rwlock.9 rw_wlock.9 \ + rwlock.9 rw_wowned.9 \ + rwlock.9 rw_wunlock.9 MLINKS+=sbuf.9 sbuf_bcat.9 \ sbuf.9 sbuf_bcopyin.9 \ sbuf.9 sbuf_bcpy.9 \ @@ -841,6 +976,10 @@ sema.9 sema_trywait.9 \ sema.9 sema_value.9 \ sema.9 sema_wait.9 +MLINKS+=sf_buf.9 sf_buf_alloc.9 \ + sf_buf.9 sf_buf_free.9 \ + sf_buf.9 sf_buf_kva.9 \ + sf_buf.9 sf_buf_page.9 MLINKS+=signal.9 cursig.9 \ signal.9 execsigs.9 \ signal.9 issignal.9 \ @@ -868,6 +1007,8 @@ signal.9 SIG_STOPSIGMASK.9 \ signal.9 trapsignal.9 MLINKS+=sleep.9 msleep.9 \ + sleep.9 msleep_spin.9 \ + sleep.9 pause.9 \ sleep.9 tsleep.9 \ sleep.9 wakeup.9 \ sleep.9 wakeup_one.9 @@ -888,6 +1029,15 @@ sleepqueue.9 sleepq_timedwait_sig.9 \ sleepqueue.9 sleepq_wait.9 \ sleepqueue.9 sleepq_wait_sig.9 +MLINKS+=socket.9 sobind.9 \ + socket.9 soclose.9 \ + socket.9 soconnect.9 \ + socket.9 socreate.9 \ + socket.9 sogetopt.9 \ + socket.9 soreceive.9 \ + socket.9 sosetopt.9 \ + socket.9 sosend.9 \ + socket.9 soshutdown.9 MLINKS+=spl.9 spl0.9 \ spl.9 splbio.9 \ spl.9 splclock.9 \ @@ -900,6 +1050,14 @@ spl.9 spltty.9 \ spl.9 splvm.9 \ spl.9 splx.9 +MLINKS+=stack.9 stack_copy.9 \ + stack.9 stack_create.9 \ + stack.9 stack_destroy.9 \ + stack.9 stack_printf.9 \ + stack.9 stack_put.9 \ + stack.9 stack_save.9 \ + stack.9 stack_sbuf_print.9 \ + stack.9 stack_zero.9 MLINKS+=store.9 subyte.9 \ store.9 suswintr.9 \ store.9 susword.9 \ @@ -911,14 +1069,31 @@ sx.9 sx_destroy.9 \ sx.9 sx_downgrade.9 \ sx.9 sx_init.9 \ + sx.9 sx_init_flags.9 \ sx.9 sx_slock.9 \ sx.9 sx_sunlock.9 \ sx.9 SX_SYSINIT.9 \ sx.9 sx_try_slock.9 \ sx.9 sx_try_upgrade.9 \ sx.9 sx_try_xlock.9 \ + sx.9 sx_sleep.9 \ + sx.9 sx_unlock.9 \ + sx.9 sx_xholder.9 \ sx.9 sx_xlock.9 \ + sx.9 sx_xlocked.9 \ sx.9 sx_xunlock.9 +MLINKS+=sysctl.9 SYSCTL_DECL.9 \ + sysctl.9 SYSCTL_INT.9 \ + sysctl.9 SYSCTL_LONG.9 \ + sysctl.9 SYSCTL_NODE.9 \ + sysctl.9 SYSCTL_OPAQUE.9 \ + sysctl.9 SYSCTL_PROC.9 \ + sysctl.9 SYSCTL_STRING.9 \ + sysctl.9 SYSCTL_STRUCT.9 \ + sysctl.9 SYSCTL_UINT.9 \ + sysctl.9 SYSCTL_ULONG.9 \ + sysctl.9 SYSCTL_XINT.9 \ + sysctl.9 SYSCTL_XLONG.9 MLINKS+=sysctl_add_oid.9 SYSCTL_ADD_INT.9 \ sysctl_add_oid.9 SYSCTL_ADD_LONG.9 \ sysctl_add_oid.9 SYSCTL_ADD_NODE.9 \ @@ -971,13 +1146,68 @@ uidinfo.9 uihashinit.9 \ uidinfo.9 uihold.9 MLINKS+=uio.9 uiomove.9 +MLINKS+=usbdi.9 usbd_abort_default_pipe.9 \ + usbdi.9 usbd_abort_pipe.9 \ + usbdi.9 usbd_alloc_buffer.9 \ + usbdi.9 usbd_alloc_xfer.9 \ + usbdi.9 usbd_clear_endpoint_stall.9 \ + usbdi.9 usbd_clear_endpoint_stall_async.9 \ + usbdi.9 usbd_clear_endpoint_toggle.9 \ + usbdi.9 usbd_close_pipe.9 \ + usbdi.9 usbd_device2interface_handle.9 \ + usbdi.9 usbd_do_request.9 \ + usbdi.9 usbd_do_request_async.9 \ + usbdi.9 usbd_do_request_flags.9 \ + usbdi.9 usbd_do_request_flags_pipe.9 \ + usbdi.9 usbd_endpoint_count.9 \ + usbdi.9 usbd_errstr.9 \ + usbdi.9 usbd_find_edesc.9 \ + usbdi.9 usbd_find_idesc.9 \ + usbdi.9 usbd_free_buffer.9 \ + usbdi.9 usbd_free_xfer.9 \ + usbdi.9 usbd_get_buffer.9 \ + usbdi.9 usbd_get_config.9 \ + usbdi.9 usbd_get_config_desc.9 \ + usbdi.9 usbd_get_config_desc_full.9 \ + usbdi.9 usbd_get_config_descriptor.9 \ + usbdi.9 usbd_get_device_descriptor.9 \ + usbdi.9 usbd_get_endpoint_descriptor.9 \ + usbdi.9 usbd_get_interface_altindex.9 \ + usbdi.9 usbd_get_interface_descriptor.9 \ + usbdi.9 usbd_get_no_alts.9 \ + usbdi.9 usbd_get_quirks.9 \ + usbdi.9 usbd_get_speed.9 \ + usbdi.9 usbd_get_string.9 \ + usbdi.9 usbd_get_string_desc.9 \ + usbdi.9 usbd_get_xfer_status.9 \ + usbdi.9 usbd_interface2device_handle.9 \ + usbdi.9 usbd_interface2endpoint_descriptor.9 \ + usbdi.9 usbd_interface_count.9 \ + usbdi.9 usbd_open_pipe.9 \ + usbdi.9 usbd_open_pipe_intr.9 \ + usbdi.9 usbd_pipe2device_handle.9 \ + usbdi.9 usbd_set_config_index.9 \ + usbdi.9 usbd_set_config_no.9 \ + usbdi.9 usbd_set_interface.9 \ + usbdi.9 usbd_setup_default_xfer.9 \ + usbdi.9 usbd_setup_isoc_xfer.9 \ + usbdi.9 usbd_setup_xfer.9 \ + usbdi.9 usbd_sync_transfer.9 \ + usbdi.9 usbd_transfer.9 \ + usbdi.9 usb_find_desc.9 MLINKS+=vcount.9 count_dev.9 MLINKS+=vfsconf.9 vfs_modevent.9 \ vfsconf.9 vfs_register.9 \ vfsconf.9 vfs_unregister.9 +MLINKS+=vfs_getopt.9 vfs_getopts.9 \ + vfs_getopt.9 vfs_flagopt.9 \ + vfs_getopt.9 vfs_scanopt.9 \ + vfs_getopt.9 vfs_copyopt.9 \ + vfs_getopt.9 vfs_filteropt.9 MLINKS+=VFS_LOCK_GIANT.9 VFS_UNLOCK_GIANT.9 MLINKS+=vgone.9 vgonel.9 -MLINKS+=vhold.9 vdrop.9 +MLINKS+=vhold.9 vdrop.9 \ + vhold.9 vdropl.9 MLINKS+=vm_map_lock.9 vm_map_lock_downgrade.9 \ vm_map_lock.9 vm_map_lock_read.9 \ vm_map_lock.9 vm_map_lock_upgrade.9 \ Index: microtime.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/microtime.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/microtime.9 -L share/man/man9/microtime.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/microtime.9 +++ share/man/man9/microtime.9 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/microtime.9,v 1.10.2.1 2005/11/04 22:08:40 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/microtime.9,v 1.11 2005/10/13 16:01:28 jhb Exp $ .\" .Dd September 16, 2004 .Dt MICROTIME 9 Index: vm_page_io.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_io.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_io.9 -L share/man/man9/vm_page_io.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_io.9 +++ share/man/man9/vm_page_io.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_io.9,v 1.5 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_IO_START 9 Index: sx.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sx.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sx.9 -L share/man/man9/sx.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sx.9 +++ share/man/man9/sx.9 @@ -24,25 +24,31 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sx.9,v 1.31 2005/01/12 21:48:25 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sx.9,v 1.41.2.1 2007/11/27 14:08:14 attilio Exp $ .\" -.Dd January 5, 2005 +.Dd November 25, 2007 .Dt SX 9 .Os .Sh NAME .Nm sx , .Nm sx_init , +.Nm sx_init_flags , .Nm sx_destroy , .Nm sx_slock , .Nm sx_xlock , +.Nm sx_slock_sig , +.Nm sx_xlock_sig , .Nm sx_try_slock , .Nm sx_try_xlock , .Nm sx_sunlock , .Nm sx_xunlock , +.Nm sx_unlock , .Nm sx_try_upgrade , .Nm sx_downgrade , +.Nm sx_sleep , +.Nm sx_xholder , +.Nm sx_xlocked , .Nm sx_assert , -.Nm sx_unlock , .Nm SX_SYSINIT .Nd kernel shared/exclusive lock .Sh SYNOPSIS @@ -52,12 +58,18 @@ .Ft void .Fn sx_init "struct sx *sx" "const char *description" .Ft void +.Fn sx_init_flags "struct sx *sx" "const char *description" "int opts" +.Ft void .Fn sx_destroy "struct sx *sx" .Ft void .Fn sx_slock "struct sx *sx" .Ft void .Fn sx_xlock "struct sx *sx" .Ft int +.Fn sx_slock_sig "struct sx *sx" +.Ft int +.Fn sx_xlock_sig "struct sx *sx" +.Ft int .Fn sx_try_slock "struct sx *sx" .Ft int .Fn sx_try_xlock "struct sx *sx" @@ -65,28 +77,36 @@ .Fn sx_sunlock "struct sx *sx" .Ft void .Fn sx_xunlock "struct sx *sx" +.Ft void +.Fn sx_unlock "struct sx *sx" .Ft int .Fn sx_try_upgrade "struct sx *sx" .Ft void .Fn sx_downgrade "struct sx *sx" +.Ft int +.Fn sx_sleep "void *chan" "struct sx *sx" "int priority" "const char *wmesg" "int timo" +.Ft "struct thread *" +.Fn sx_xholder "struct sx *sx" +.Ft int +.Fn sx_xlocked "struct sx *sx" +.Pp +.Cd "options INVARIANTS" +.Cd "options INVARIANT_SUPPORT" .Ft void .Fn sx_assert "struct sx *sx" "int what" -.\" -.Ss Nm Ss utility macros -.Fn sx_unlock "struct sx *sx" +.In sys/kernel.h .Fn SX_SYSINIT "name" "struct sx *sx" "const char *description" -.\" -.Ss Kernel options -.Cd "options INVARIANTS" -.Cd "options INVARIANT_SUPPORT" .Sh DESCRIPTION Shared/exclusive locks are used to protect data that are read far more often than they are written. -Mutexes are inherently more efficient than shared/exclusive locks, so +Shared/exclusive locks do not implement priority propagation like mutexes and +reader/writer locks to prevent priority inversions, so shared/exclusive locks should be used prudently. .Pp -Shared/exclusive locks are created with -.Fn sx_init , +Shared/exclusive locks are created with either +.Fn sx_init +or +.Fn sx_init_flags where .Fa sx is a pointer to space for a @@ -95,10 +115,46 @@ .Fa description is a pointer to a null-terminated character string that describes the shared/exclusive lock. +The +.Fa opts +argument to +.Fn sx_init_flags +specifies a set of optional flags to alter the behavior of +.Fa sx . +It contains one or more of the following flags: +.Bl -tag -width SX_ADAPTIVESPIN +.It Dv SX_ADAPTIVESPIN +If the kernel is compiled with +.Cd "options ADAPTIVE_SX" , +then lock operations for +.Fa sx +will spin instead of sleeping while an exclusive lock holder is executing on +another CPU. +.It Dv SX_DUPOK +Witness should not log messages about duplicate locks being acquired. +.It Dv SX_NOWITNESS +Instruct +.Xr witness 4 +to ignore this lock. +.It Dv SX_NOPROFILE +Do not profile this lock. +.It Dv SX_RECURSE +Allow threads to recursively acquire exclusive locks for +.Fa sx . +.It Dv SX_QUIET +Do not log any operations for this lock via +.Xr ktr 4 . +.El +.Pp Shared/exclusive locks are destroyed with .Fn sx_destroy . +The lock +.Fa sx +must not be locked by any thread when it is destroyed. +.Pp Threads acquire and release a shared lock by calling -.Fn sx_slock +.Fn sx_slock , +.Fn sx_slock_sig or .Fn sx_try_slock and @@ -106,7 +162,8 @@ or .Fn sx_unlock . Threads acquire and release an exclusive lock by calling -.Fn sx_xlock +.Fn sx_xlock , +.Fn sx_xlock_sig or .Fn sx_try_xlock and @@ -132,6 +189,20 @@ immediately; otherwise the exclusive lock will be acquired and a non-zero value will be returned. .Pp +.Fn sx_slock_sig +and +.Fn sx_xlock_sig +do the same as their normal versions but performing an interruptible sleep. +They return a non-zero value if the sleep has been interrupted by a signal +or an interrupt, otherwise 0. +.Pp +A thread can atomically release a shared/exclusive lock while waiting for an +event by calling +.Fn sx_sleep . +For more details on the parameters to this function, +see +.Xr sleep 9 . +.Pp When compiled with .Cd "options INVARIANTS" and @@ -143,29 +214,58 @@ for the assertions specified in .Fa what , and panics if they are not met. -The following assertions are supported: -.Bl -tag -width ".Dv SX_UNLOCKED" -.It Dv SX_LOCKED +One of the following assertions must be specified: +.Bl -tag -width ".Dv SA_UNLOCKED" +.It Dv SA_LOCKED Assert that the current thread has either a shared or an exclusive lock on the .Vt sx lock pointed to by the first argument. -.It Dv SX_SLOCKED +.It Dv SA_SLOCKED Assert that the current thread has a shared lock on the .Vt sx lock pointed to by the first argument. -.It Dv SX_XLOCKED +.It Dv SA_XLOCKED Assert that the current thread has an exclusive lock on the .Vt sx lock pointed to by the first argument. -.It Dv SX_UNLOCKED +.It Dv SA_UNLOCKED Assert that the current thread has no lock on the .Vt sx lock pointed to by the first argument. .El .Pp +In addition, one of the following optional assertions may be included with +either an +.Dv SA_LOCKED , +.Dv SA_SLOCKED , +or +.Dv SA_XLOCKED +assertion: +.Bl -tag -width ".Dv SA_NOTRECURSED" +.It Dv SA_RECURSED +Assert that the current thread has a recursed lock on +.Fa sx . +.It Dv SA_NOTRECURSED +Assert that the current thread does not have a recursed lock on +.Fa sx . +.El +.Pp +.Fn sx_xholder +will return a pointer to the thread which currently holds an exclusive lock on +.Fa sx . +If no thread holds an exclusive lock on +.Fa sx , +then +.Dv NULL +is returned instead. +.Pp +.Fn sx_xlocked +will return non-zero if the current thread holds the exclusive lock; +otherwise, it will return zero. +.Pp For ease of programming, .Fn sx_unlock is provided as a macro frontend to the respective functions, @@ -206,10 +306,11 @@ lock after acquiring a mutex, then the second thread would effectively end up sleeping while holding a mutex, which is not allowed. .Sh SEE ALSO -.Xr condvar 9 , -.Xr mtx_pool 9 , +.Xr locking 9 , +.Xr lock 9 , .Xr mutex 9 , .Xr panic 9 , +.Xr rwlock 9 , .Xr sema 9 .Sh BUGS Currently there is no way to assert that a lock is not held. @@ -220,8 +321,8 @@ In the .No non- Ns Dv WITNESS case, the -.Dv SX_LOCKED +.Dv SA_LOCKED and -.Dv SX_SLOCKED +.Dv SA_SLOCKED assertions merely check that some thread holds a shared lock. They do not ensure that the current thread holds a shared lock. Index: vn_fullpath.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vn_fullpath.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vn_fullpath.9 -L share/man/man9/vn_fullpath.9 -u -r1.2 -r1.3 --- share/man/man9/vn_fullpath.9 +++ share/man/man9/vn_fullpath.9 @@ -26,7 +26,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vn_fullpath.9,v 1.4 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd January 11, 2004 .Dt VN_FULLPATH 9 Index: vm_page_protect.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_protect.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_protect.9 -L share/man/man9/vm_page_protect.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_protect.9 +++ share/man/man9/vm_page_protect.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_protect.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 14, 2001 .Dt VM_PAGE_PROTECT 9 Index: utopia.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/utopia.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/utopia.9 -L share/man/man9/utopia.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/utopia.9 +++ share/man/man9/utopia.9 @@ -25,7 +25,7 @@ .\" .\" Author: Hartmut Brandt .\" -.\" $FreeBSD: src/share/man/man9/utopia.9,v 1.7 2004/07/07 07:56:58 ru Exp $ +.\" $FreeBSD: src/share/man/man9/utopia.9,v 1.8 2006/12/14 14:33:13 mpp Exp $ .\" .Dd May 8, 2003 .Dt UTOPIA 9 @@ -245,7 +245,7 @@ .It Va chip This points to a function vector for chip specific functions. Two fields -in this vector are publically available: +in this vector are publicly available: .Bl -tag -width indent .It Va type This is the type of the detected PHY chip. Index: bpf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bpf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bpf.9 -L share/man/man9/bpf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bpf.9 +++ share/man/man9/bpf.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bpf.9,v 1.6 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/bpf.9,v 1.7 2006/12/13 06:27:20 ru Exp $ .\" -.Dd May 19, 2004 +.Dd December 13, 2006 .Dt BPF 9 .Os .\" @@ -51,7 +51,7 @@ .Fn bpf_mtap2 "struct bpf_if *bp" "void *data" "u_int dlen" "struct mbuf *m" .Ft u_int .Fo bpf_filter -.Fa "const struct bpf_insn *pc " "u_char *pkt" "u_int *wirelen" "u_int *buflen" +.Fa "const struct bpf_insn *pc " "u_char *pkt" "u_int wirelen" "u_int buflen" .Fc .Ft int .Fn bpf_validate "const struct bpf_insn *fcode" "int flen" @@ -217,6 +217,12 @@ is the length of the original packet and .Fa buflen is the amount of data present. +The +.Fa buflen +value of 0 is special; it indicates that the +.Fa pkt +is actually a pointer to an mbuf chain +.Pq Vt "struct mbuf *" . .Pp The .Fn bpf_validate Index: vm_page_lookup.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_lookup.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_lookup.9 -L share/man/man9/vm_page_lookup.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_lookup.9 +++ share/man/man9/vm_page_lookup.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_lookup.9,v 1.2 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_LOOKUP 9 Index: pmap_zero_page.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pmap_zero_page.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/pmap_zero_page.9 -L share/man/man9/pmap_zero_page.9 -u -r1.2 -r1.3 --- share/man/man9/pmap_zero_page.9 +++ share/man/man9/pmap_zero_page.9 @@ -24,7 +24,6 @@ .\" SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/pmap_zero_page.9,v 1.3 2004/07/06 07:02:31 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 21, 2003 .Dt PMAP_ZERO 9 Index: vm_set_page_size.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_set_page_size.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_set_page_size.9 -L share/man/man9/vm_set_page_size.9 -u -r1.2 -r1.3 --- share/man/man9/vm_set_page_size.9 +++ share/man/man9/vm_set_page_size.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_set_page_size.9,v 1.4 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_SET_PAGE_SIZE 9 Index: g_bio.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/g_bio.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/g_bio.9 -L share/man/man9/g_bio.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/g_bio.9 +++ share/man/man9/g_bio.9 @@ -1,5 +1,5 @@ .\" -.\" Copyright (c) 2004 Pawel Jakub Dawidek +.\" Copyright (c) 2004-2006 Pawel Jakub Dawidek .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -22,9 +22,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/g_bio.9,v 1.9 2004/08/04 21:35:05 pjd Exp $ +.\" $FreeBSD: src/share/man/man9/g_bio.9,v 1.13 2007/05/06 12:48:39 wkoszek Exp $ .\" -.Dd January 16, 2004 +.Dd November 1, 2006 .Dt G_BIO 9 .Os .Sh NAME @@ -39,7 +39,11 @@ .Ft "struct bio *" .Fn g_new_bio void .Ft "struct bio *" +.Fn g_alloc_bio void +.Ft "struct bio *" .Fn g_clone_bio "struct bio *bp" +.Ft "struct bio *" +.Fn g_duplicate_bio "struct bio *bp" .Ft void .Fn g_destroy_bio "struct bio *bp" .Ft void @@ -71,6 +75,8 @@ Attributes are named by ascii strings and are stored in the .Va bio_attribute field. +.It Dv BIO_FLUSH +Tells underlying providers to flush their write caches. .El .It Va bio_flags Available flags: @@ -138,6 +144,13 @@ .Vt bio structure. .Pp +.Fn g_alloc_bio +- same as +.Fn g_new_bio , +but always succeeds (allocates bio with the +.Dv M_WAITOK +malloc flag). +.Pp The .Fn g_clone_bio function allocates a new @@ -174,6 +187,13 @@ Schedule the clone on its own consumer. .El .Pp +.Fn g_duplicate_bio +- same as +.Fn g_clone_bio , +but always succeeds (allocates bio with the +.Dv M_WAITOK +malloc flag). +.Pp The .Fn g_destroy_bio function deallocates and destroys the given @@ -213,7 +233,7 @@ struct bio *cbp; printf("Request received: "); - g_print_bio(); + g_print_bio(bp); printf("\\n"); sc = bp->bio_to->geom->softc; Index: sleepqueue.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sleepqueue.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sleepqueue.9 -L share/man/man9/sleepqueue.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sleepqueue.9 +++ share/man/man9/sleepqueue.9 @@ -21,9 +21,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sleepqueue.9,v 1.12 2005/04/19 16:30:25 jkoshy Exp $ +.\" $FreeBSD: src/share/man/man9/sleepqueue.9,v 1.16 2007/09/28 11:13:40 gabor Exp $ .\" -.Dd March 10, 2004 +.Dd August 13, 2007 .Dt SLEEPQUEUE 9 .Os .Sh NAME @@ -54,11 +54,11 @@ .Ft void .Fn sleepq_abort "struct thread *td" .Ft void -.Fn sleepq_add "void *wchan" "struct mtx *lock" "const char *wmesg" "int flags" +.Fn sleepq_add "void *wchan" "struct lock_object *lock" "const char *wmesg" "int flags" "int queue" .Ft struct sleepqueue * .Fn sleepq_alloc "void" .Ft void -.Fn sleepq_broadcast "void *wchan" "int flags" "int pri" +.Fn sleepq_broadcast "void *wchan" "int flags" "int pri" "int queue" .Ft int .Fn sleepq_calc_signal_retval "int sig" .Ft int @@ -74,7 +74,7 @@ .Ft void .Fn sleepq_remove "struct thread *td" "void *wchan" .Ft void -.Fn sleepq_signal "void *wchan" "int flags" "int pri" +.Fn sleepq_signal "void *wchan" "int flags" "int pri" "int queue" .Ft void .Fn sleepq_set_timeout "void *wchan" "int timo" .Ft int @@ -91,6 +91,8 @@ Each queue is associated with a specific wait channel when it is active, and only one queue may be associated with a wait channel at any given point in time. +The implementation of each wait channel splits its sleepqueue into 2 sub-queues +in order to enable some optimizations on threads' wakeups. An active queue holds a list of threads that are blocked on the associated wait channel. Threads that are not blocked on a wait channel have an associated inactive @@ -157,12 +159,12 @@ must be locked by a prior call to .Fn sleepq_lock when this function is called. -If a mutex is specified via the +If a lock is specified via the .Fa lock argument, and if the kernel was compiled with .Cd "options INVARIANTS" , then the sleep queue code will perform extra checks to ensure that -the mutex is used by all threads sleeping on +the lock is used by all threads sleeping on .Fa wchan . The .Fa wmesg @@ -172,18 +174,25 @@ .Fa flags parameter is a bitmask consisting of the type of sleep queue being slept on and zero or more optional flags. +The +.Fa queue +parameter specifies the sub-queue, in which the contending thread will be +inserted. .Pp -There are currently two types of sleep queues: +There are currently three types of sleep queues: .Pp .Bl -tag -width ".Dv SLEEPQ_CONDVAR" -compact .It Dv SLEEPQ_CONDVAR A sleep queue used to implement condition variables. -.It Dv SLEEPQ_MSLEEP +.It Dv SLEEPQ_SLEEP A sleep queue used to implement -.Xr msleep 9 , +.Xr sleep 9 , .Xr wakeup 9 and .Xr wakeup_one 9 . +.It Dv SLEEPQ_PAUSE +A sleep queue used to implement +.Xr pause 9 . .El .Pp There is currently only one optional flag: @@ -307,6 +316,9 @@ must be locked by a prior call to .Fn sleepq_lock before calling any of these functions. +The +.Fa queue +argument specifies the sub-queue, from which threads need to be woken up. .Pp A thread in an interruptible sleep can be interrupted by another thread via the @@ -336,7 +348,7 @@ channel. .Pp The sleep queue interface is currently used to implement the -.Xr msleep 9 +.Xr sleep 9 and .Xr condvar 9 interfaces. @@ -344,6 +356,6 @@ than manipulating sleep queues directly. .Sh SEE ALSO .Xr condvar 9 , -.Xr msleep 9 , .Xr runqueue 9 , -.Xr scheduler 9 +.Xr scheduler 9 , +.Xr sleep 9 Index: vm_map.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_map.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vm_map.9 -L share/man/man9/vm_map.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vm_map.9 +++ share/man/man9/vm_map.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_map.9,v 1.9 2005/01/15 12:28:00 ru Exp $ +.\" $FreeBSD: src/share/man/man9/vm_map.9,v 1.10 2007/01/27 18:58:33 rwatson Exp $ .\" .Dd September 26, 2004 .Dt VM_MAP 9 @@ -144,7 +144,7 @@ .It Dv MAP_DISABLE_COREDUMP Do not include the mapping in a core dump. .It Dv MAP_PREFAULT_MADVISE -Specify that the request from a user process calling +Specify that the request is from a user process calling .Xr madvise 2 . .El .Pp --- /dev/null +++ share/man/man9/redzone.9 @@ -0,0 +1,123 @@ +.\" Copyright (c) 2006 Pawel Jakub Dawidek +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/redzone.9,v 1.1 2006/01/31 11:09:20 pjd Exp $ +.\" +.Dd January 31, 2006 +.Dt REDZONE 9 +.Os +.Sh NAME +.Nm RedZone +.Nd "buffer corruptions detector" +.Sh SYNOPSIS +.Cd "options DEBUG_REDZONE" +.Sh DESCRIPTION +.Nm +detects buffer underflow and buffer overflow bugs at runtime. +Currently +.Nm +only detects buffer corruptions for memory allocated with +.Xr malloc 9 . +When such corruption is detected two backtraces are printed on the console. +The first one shows from where memory was allocated, the second one shows from +where memory was freed. +By default the system will not panic when buffer corruption is detected. +This can be changed by setting the +.Va vm.redzone.panic +.Xr sysctl 8 +variable to 1. +The amount of extra memory allocated for +.Nm Ns 's +needs is stored in the +.Va vm.redzone.extra_mem +.Xr sysctl 8 +variable. +.Sh EXAMPLE +The example below shows the logs from the detection of a buffer underflow and a +buffer overflow. +.Bd -literal -offset indent +REDZONE: Buffer underflow detected. 2 bytes corrupted before 0xc8688580 (16 bytes allocated). +Allocation backtrace: +#0 0xc0583e4e at redzone_setup+0x3c +#1 0xc04a23fa at malloc+0x19e +#2 0xcdeb69ca at redzone_modevent+0x60 +#3 0xc04a3f3c at module_register_init+0x82 +#4 0xc049d96a at linker_file_sysinit+0x8e +#5 0xc049dc7c at linker_load_file+0xed +#6 0xc04a041f at linker_load_module+0xc4 +#7 0xc049e883 at kldload+0x116 +#8 0xc05d9b3d at syscall+0x325 +#9 0xc05c944f at Xint0x80_syscall+0x1f +Free backtrace: +#0 0xc0583f92 at redzone_check+0xd4 +#1 0xc04a2422 at free+0x1c +#2 0xcdeb69a6 at redzone_modevent+0x3c +#3 0xc04a438d at module_unload+0x61 +#4 0xc049e0b3 at linker_file_unload+0x89 +#5 0xc049e979 at kern_kldunload+0x96 +#6 0xc049ea00 at kldunloadf+0x2c +#7 0xc05d9b3d at syscall+0x325 +#8 0xc05c944f at Xint0x80_syscall+0x1f + +REDZONE: Buffer overflow detected. 4 bytes corrupted after 0xc8688590 (16 bytes allocated). +Allocation backtrace: +#0 0xc0583e4e at redzone_setup+0x3c +#1 0xc04a23fa at malloc+0x19e +#2 0xcdeb69ca at redzone_modevent+0x60 +#3 0xc04a3f3c at module_register_init+0x82 +#4 0xc049d96a at linker_file_sysinit+0x8e +#5 0xc049dc7c at linker_load_file+0xed +#6 0xc04a041f at linker_load_module+0xc4 +#7 0xc049e883 at kldload+0x116 +#8 0xc05d9b3d at syscall+0x325 +#9 0xc05c944f at Xint0x80_syscall+0x1f +Free backtrace: +#0 0xc0584020 at redzone_check+0x162 +#1 0xc04a2422 at free+0x1c +#2 0xcdeb69a6 at redzone_modevent+0x3c +#3 0xc04a438d at module_unload+0x61 +#4 0xc049e0b3 at linker_file_unload+0x89 +#5 0xc049e979 at kern_kldunload+0x96 +#6 0xc049ea00 at kldunloadf+0x2c +#7 0xc05d9b3d at syscall+0x325 +#8 0xc05c944f at Xint0x80_syscall+0x1f +.Ed +.Sh SEE ALSO +.Xr sysctl 8 , +.Xr malloc 9 , +.Xr memguard 9 +.Sh HISTORY +.Nm +first appeared in +.Fx 7.0 . +.Sh AUTHORS +.An Pawel Jakub Dawidek Aq pjd at FreeBSD.org +.Sh BUGS +Currently, +.Nm +does not cooperate with +.Xr memguard 9 . +Allocations from a memory type controlled by +.Xr memguard 9 +are simply skipped, so buffer corruptions will not be detected there. --- /dev/null +++ share/man/man9/cr_cansee.9 @@ -0,0 +1,92 @@ +.\" +.\" Copyright (c) 2006 Ceri Davies +.\" +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/cr_cansee.9,v 1.1 2006/11/19 13:35:03 ceri Exp $ +.\" +.Dd November 19, 2006 +.Os +.Dt CR_CANSEE 9 +.Sh NAME +.Nm cr_cansee +.Nd "determine visibility of objects given their user credentials" +.Sh SYNOPSIS +.In sys/param.h +.In sys/systm.h +.In sys/ucred.h +.Ft int +.Fn cr_cansee "struct ucred *u1" "struct ucred *u2" +.Sh DESCRIPTION +This function determines the visibility of objects in the +kernel based on the real user IDs and group IDs in the credentials +.Fa u1 +and +.Fa u2 +associated with them. +.Pp +The visibility of objects is influenced by the +.Xr sysctl 8 +variables +.Va security.bsd.see_other_gids +and +.Va security.bsd.see_other_uids , +as per the description in +.Xr cr_seeothergids 9 +and +.Xr cr_seeotheruids 9 +respectively. +.Sh RETURN VALUES +This function returns zero if the object with credential +.Fa u1 +can +.Dq see +the object with credential +.Fa u2 , +or +.Er ESRCH +otherwise. +.Sh ERRORS +.Bl -tag -width Er +.It Bq Er ESRCH +The object with credential +.Fa u1 +cannot +.Dq see +the object with credential +.Fa u2 . +.It Bq Er ESRCH +The object with credential +.Fa u1 +has been jailed and the object with credential +.Fa u2 +does not belong to the same jail as +.Fa u1 . +.It Bq Er ESRCH +The MAC subsystem denied visibility. +.El +.Sh SEE ALSO +.Xr cr_seeothergids 9 , +.Xr cr_seeotheruids 9 , +.Xr mac 9 , +.Xr p_cansee 9 Index: DECLARE_GEOM_CLASS.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/DECLARE_GEOM_CLASS.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/DECLARE_GEOM_CLASS.9 -L share/man/man9/DECLARE_GEOM_CLASS.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/DECLARE_GEOM_CLASS.9 +++ share/man/man9/DECLARE_GEOM_CLASS.9 @@ -22,9 +22,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/DECLARE_GEOM_CLASS.9,v 1.4 2005/01/13 09:33:06 ru Exp $ +.\" $FreeBSD: src/share/man/man9/DECLARE_GEOM_CLASS.9,v 1.5 2007/09/20 10:52:08 gabor Exp $ .\" -.Dd January 6, 2005 +.Dd August 13, 2007 .Dt DECLARE_GEOM_CLASS 9 .Os .Sh NAME @@ -110,7 +110,7 @@ .Sh EXAMPLES Example class declaration. .Bd -literal -offset indent -static struct geom * +static struct g_geom * g_example_taste(struct g_class *mp, struct g_provider *pp, int flags __unused) { Index: VOP_REMOVE.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_REMOVE.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_REMOVE.9 -L share/man/man9/VOP_REMOVE.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_REMOVE.9 +++ share/man/man9/VOP_REMOVE.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_REMOVE.9,v 1.14 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_REMOVE.9,v 1.15 2006/11/04 23:58:15 pjd Exp $ .\" .Dd July 24, 1996 .Os @@ -80,16 +80,6 @@ */ ...; - /* - * Careful about trying to remove ".". XXX this should be handled - * higher up. - */ - if (dvp == vp) - vrele(vp); - else - vput(vp); - vput(dvp); - return error; } .Ed Index: vm_map_stack.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_map_stack.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vm_map_stack.9 -L share/man/man9/vm_map_stack.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vm_map_stack.9 +++ share/man/man9/vm_map_stack.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_map_stack.9,v 1.4 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/vm_map_stack.9,v 1.5 2006/12/14 14:33:13 mpp Exp $ .\" .Dd July 19, 2003 .Dt VM_MAP_STACK 9 @@ -100,7 +100,7 @@ or if there is already a mapping at the address which would result, or if .Fa max_ssize -could not be accomodated within the current mapping, +could not be accommodated within the current mapping, .Dv KERN_NO_SPACE is returned. .Pp Index: condvar.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/condvar.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/condvar.9 -L share/man/man9/condvar.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/condvar.9 +++ share/man/man9/condvar.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/condvar.9,v 1.11 2004/11/08 18:15:11 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/condvar.9,v 1.21 2007/06/05 20:53:18 imp Exp $ .\" -.Dd December 11, 2000 +.Dd June 5, 2007 .Dt CONDVAR 9 .Os .Sh NAME @@ -35,6 +35,7 @@ .Nm cv_destroy , .Nm cv_wait , .Nm cv_wait_sig , +.Nm cv_wait_unlock , .Nm cv_timedwait , .Nm cv_timedwait_sig , .Nm cv_signal , @@ -51,13 +52,15 @@ .Ft void .Fn cv_destroy "struct cv *cvp" .Ft void -.Fn cv_wait "struct cv *cvp" "struct mtx *mp" +.Fn cv_wait "struct cv *cvp" "lock" .Ft int -.Fn cv_wait_sig "struct cv *cvp" "struct mtx *mp" +.Fn cv_wait_sig "struct cv *cvp" "lock" +.Ft void +.Fn cv_wait_unlock "struct cv *cvp" "lock" .Ft int -.Fn cv_timedwait "struct cv *cvp" "struct mtx *mp" "int timo" +.Fn cv_timedwait "struct cv *cvp" "lock" "int timo" .Ft int -.Fn cv_timedwait_sig "struct cv *cvp" "struct mtx *mp" "int timo" +.Fn cv_timedwait_sig "struct cv *cvp" "lock" "int timo" .Ft void .Fn cv_signal "struct cv *cvp" .Ft void @@ -84,6 +87,7 @@ Threads wait on condition variables by calling .Fn cv_wait , .Fn cv_wait_sig , +.Fn cv_wait_unlock , .Fn cv_timedwait , or .Fn cv_timedwait_sig . @@ -105,26 +109,45 @@ as set by the initial call to .Fn cv_init . .Pp +The +.Fa lock +argument is a pointer to either a +.Xr mutex 9 , +.Xr rwlock 9 , +or +.Xr sx 9 +lock. +A +.Xr mutex 9 +argument must be initialized with +.Dv MTX_DEF +and not +.Dv MTX_SPIN . A thread must hold -.Fa mp +.Fa lock before calling .Fn cv_wait , .Fn cv_wait_sig , +.Fn cv_wait_unlock , .Fn cv_timedwait , or .Fn cv_timedwait_sig . When a thread waits on a condition, -.Fa mp -is atomically released before the thread is blocked, then atomically reacquired +.Fa lock +is atomically released before the thread is blocked, then reacquired before the function call returns. +The +.Fn cv_wait_unlock +function does not reacquire the lock before returning. All waiters must pass the same -.Fa mp +.Fa lock in conjunction with .Fa cvp . .Pp When .Fn cv_wait , .Fn cv_wait_sig , +.Fn cv_wait_unlock , .Fn cv_timedwait , and .Fn cv_timedwait_sig @@ -169,9 +192,9 @@ will fail if: .Bl -tag -width Er .It Bq Er EINTR -An unmasked signal was caught. +A signal was caught and the system call should be interrupted. .It Bq Er ERESTART -A masked signal was caught. +A signal was caught and the system call should be restarted. .El .Pp .Fn cv_timedwait @@ -183,8 +206,10 @@ Timeout expired. .El .Sh SEE ALSO -.Xr msleep 9 , +.Xr locking 9 , .Xr mtx_pool 9 , .Xr mutex 9 , +.Xr rwlock 9 , .Xr sema 9 , +.Xr sleep 9 , .Xr sx 9 Index: p_candebug.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/p_candebug.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/p_candebug.9 -L share/man/man9/p_candebug.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/p_candebug.9 +++ share/man/man9/p_candebug.9 @@ -25,15 +25,16 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/p_candebug.9,v 1.3 2004/07/06 07:26:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/p_candebug.9,v 1.5 2006/11/19 13:36:04 ceri Exp $ .\" -.Dd November 11, 2003 +.Dd November 19, 2006 .Os .Dt P_CANDEBUG 9 .Sh NAME .Nm p_candebug .Nd determine debuggability of a process .Sh SYNOPSIS +.In sys/param.h .In sys/proc.h .Ft int .Fn p_candebug "struct thread *td" "struct proc *p" @@ -128,10 +129,10 @@ The MAC subsystem denied debuggability. .El .Sh SEE ALSO -.Xr intro 2 , .Xr jail 2 , .Xr sysctl 8 , .Xr cr_seeothergids 9 , .Xr cr_seeotheruids 9 , .Xr mac 9 , +.Xr p_cansee 9 , .Xr prison_check 9 Index: vslock.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vslock.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vslock.9 -L share/man/man9/vslock.9 -u -r1.2 -r1.3 --- share/man/man9/vslock.9 +++ share/man/man9/vslock.9 @@ -35,7 +35,6 @@ .\" POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vslock.9,v 1.15 2004/08/16 03:12:10 green Exp $ -.\" $MidnightBSD$ .\" .Dd August 10, 2004 .Dt VSLOCK 9 Index: style.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/style.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/style.9 -L share/man/man9/style.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/style.9 +++ share/man/man9/style.9 @@ -24,7 +24,7 @@ .\" SUCH DAMAGE. .\" .\" From: @(#)style 1.14 (Berkeley) 4/28/95 -.\" $FreeBSD: src/share/man/man9/style.9,v 1.121 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/style.9,v 1.123 2007/01/28 20:51:04 joel Exp $ .\" .Dd February 10, 2005 .Dt STYLE 9 @@ -46,7 +46,7 @@ * Style guide for FreeBSD. Based on the CSRG's KNF (Kernel Normal Form). * * @(#)style 1.14 (Berkeley) 4/28/95 - * $FreeBSD: src/share/man/man9/style.9,v 1.121 2005/06/28 20:15:18 hmp Exp $ + * $FreeBSD: src/share/man/man9/style.9,v 1.123 2007/01/28 20:51:04 joel Exp $ */ /* @@ -65,7 +65,8 @@ line of the comment having a dash after the star like so: .Bd -literal /*- - * Copyright (c) 1984-2025 John Q. Public. All Rights Reserved. + * Copyright (c) 1984-2025 John Q. Public + * All rights reserved. * * Long, boring license goes here, but redacted for brevity */ @@ -110,7 +111,7 @@ #endif #include -__FBSDID("$FreeBSD: src/share/man/man9/style.9,v 1.121 2005/06/28 20:15:18 hmp Exp $"); +__FBSDID("$FreeBSD: src/share/man/man9/style.9,v 1.123 2007/01/28 20:51:04 joel Exp $"); .Ed .Pp Leave another blank line before the header files. @@ -473,7 +474,7 @@ while ((ch = getopt(argc, argv, "abNn:")) != -1) switch (ch) { /* Indent the switch. */ case 'a': /* Don't indent the case. */ - aflag = 1; + aflag = 1; /* Indent case body one tab. */ /* FALLTHROUGH */ case 'b': bflag = 1; Index: vm_page_insert.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_insert.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_insert.9 -L share/man/man9/vm_page_insert.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_insert.9 +++ share/man/man9/vm_page_insert.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_insert.9,v 1.3 2001/08/08 10:04:08 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_INSERT 9 Index: VFS_LOCK_GIANT.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_LOCK_GIANT.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_LOCK_GIANT.9 -L share/man/man9/VFS_LOCK_GIANT.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_LOCK_GIANT.9 +++ share/man/man9/VFS_LOCK_GIANT.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_LOCK_GIANT.9,v 1.1.2.1 2005/09/25 18:51:45 rwatson Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_LOCK_GIANT.9,v 1.5 2006/01/03 14:00:22 rwatson Exp $ .\" .Dd September 21, 2005 .Dt VFS_LOCK_GIANT 9 @@ -33,9 +33,10 @@ .Sh NAME .Nm VFS_LOCK_GIANT , .Nm VFS_UNLOCK_GIANT -.Nd "Conditionally lock and unlock Giant around entry into VFS" +.Nd "conditionally lock and unlock Giant around entry into VFS" .Sh SYNOPSIS .In sys/param.h +.In sys/mount.h .In sys/vnode.h .Ft int .Fn VFS_LOCK_GIANT "struct mount *mp" @@ -44,16 +45,18 @@ .Sh DESCRIPTION .Fn VFS_LOCK_GIANT will conditionally acquire the -.Dv Giant +.Va Giant lock if the file system referenced by .Fa mp -is marked as MPSAFE or not, returning a flag indicating whether Giant was +is marked as MPSAFE or not, returning a flag indicating whether +.Va Giant +was set, which may later be passed to .Fn VFS_UNLOCK_GIANT . The value of .Fa mp will typically be derived from the mount pointer in a -.Xr vnode +.Vt vnode on which a VFS operation will be performed. .Pp .Fn VFS_UNLOCK_GIANT @@ -63,7 +66,7 @@ .Fa vfslocked argument is non-zero. It is expected that the argument will be derived from the return values of -.Vn VFS_LOCK_GIANT +.Fn VFS_LOCK_GIANT or .Xr NDHASGIANT 9 . .Sh RETURN VALUES @@ -76,6 +79,7 @@ .Xr NDHASGIANT 9 , .Xr vnode 9 .Sh AUTHORS +.An -nosplit MPSAFE VFS support for .Fx was implemented by @@ -84,7 +88,6 @@ This manual page was written by .An Robert Watson . .Sh BUGS -.Pp Non-MPSAFE file systems exist, requiring callers conditional locking and unlocking of .Va Giant . --- /dev/null +++ share/man/man9/kqueue.9 @@ -0,0 +1,375 @@ +.\" Copyright 2006 John-Mark Gurney +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/kqueue.9,v 1.6 2006/12/29 22:30:10 jmg Exp $ +.\" +.Dd December 28, 2006 +.Dt KQUEUE 9 +.Os +.Sh NAME +.Nm kqueue_add_filteropts , kqueue_del_filteropts , +.Nm kqfd_register , +.Nm knote_fdclose , +.Nm knlist_add , knlist_remove , knlist_remove_inevent , knlist_empty , +.Nm knlist_init , knlist_destroy , knlist_clear , knlist_delete , +.Nm KNOTE_LOCKED , KNOTE_UNLOCKED +.Nd "event delivery subsystem" +.Sh SYNOPSIS +.In sys/event.h +.Ft int +.Fn kqueue_add_filteropts "int filt" "struct filterops *filtops" +.Ft int +.Fn kqueue_del_filteropts "int filt" +.Ft int +.Fn kqfd_register "int fd" "struct kevent *kev" "struct thread *td" "int waitok" +.Ft void +.Fn knote_fdclose "struct thread *td" "int fd" +.Ft void +.Fn knlist_add "struct knlist *knl" "struct knote *kn" "int islocked" +.Ft void +.Fn knlist_remove "struct knlist *knl" "struct knote *kn" "int islocked" +.Ft void +.Fn knlist_remove_inevent "struct knlist *knl" "struct knote *kn" +.Ft int +.Fn knlist_empty "struct knlist *knl" +.Ft void +.Fo knlist_init +.Fa "struct knlist *knl" +.Fa "void *lock" +.Fa "void \*[lp]*kl_lock\*[rp]\*[lp]void *\*[rp]" +.Fa "void \*[lp]*kl_unlock\*[rp]\*[lp]void *\*[rp]" +.Fa "int \*[lp]*kl_locked\*[rp]\*[lp]void *\*[rp]" +.Fc +.Ft void +.Fn knlist_destroy "struct knlist *knl" +.Ft void +.Fn knlist_clear "struct knlist *knl" "int islocked" +.Ft void +.Fn knlist_delete "struct knlist *knl" "struct thread *td" "int islocked" +.Ft void +.Fn KNOTE_LOCKED "struct knlist *knl" "long hint" +.Ft void +.Fn KNOTE_UNLOCKED "struct knlist *knl" "long hint" +.Sh DESCRIPTION +The functions +.Fn kqueue_add_filteropts +and +.Fn kqueue_del_filteropts +allow for the addition and removal of a filter type. +The filter is statically defined by the +.Dv EVFILT_* +macros. +The function +.Fn kqueue_add_filteropts +will make +.Fa filt +available. +The +.Vt "struct filterops" +has the following members: +.Bl -tag -width ".Va f_attach" +.It Va f_isfd +If +.Va f_isfd +is set, +.Va ident +in +.Vt "struct kevent" +is taken to be a file descriptor. +In this case, the +.Vt knote +passed into +.Va f_attach +will have the +.Va kn_fp +member initialized to the +.Vt "struct file *" +that represents the file descriptor. +.It Va f_attach +The +.Va f_attach +function will be called when attaching a +.Vt knote +to the object. +The method should call +.Fn knlist_add +to add the +.Vt knote +to the list that was initialized with +.Fn knlist_init . +The call to +.Fn knlist_add +is only necessary if the object can have multiple +.Vt knotes +associated with it. +If there is no +.Vt knlist +to call +.Fn knlist_add +with, the function +.Va f_attach +must clear the +.Dv KN_DETACHED +bit of +.Va kn_status +in the +.Vt knote . +The function shall return 0 on success, or appropriate error for the failure. +During +.Va f_attach , +it is valid to change the +.Va kn_fops +pointer to a different pointer. +This will change the +.Va f_event +and +.Va f_detach +functions called when processing the +.Vt knote . +.It Va f_detach +The +.Va f_detach +function will be called to detach the +.Vt knote +if the +.Vt knote +has not already been detached by a call to +.Fn knlist_remove . +.It Va f_event +The +.Va f_event +function will be called to update the status of the +.Vt knote . +If the function returns 0, it will be assumed that the object is not +ready (or no longer ready) to be woken up. +The +.Fa hint +argument will be 0 when scanning +.Vt knotes +to see which are triggered. +Otherwise, the +.Fa hint +argument will be the value passed to either +.Dv KNOTE_LOCKED +or +.Dv KNOTE_UNLOCKED . +The +.Va kn_data +value should be updated as necessary to reflect the current value, such as +number of bytes available for reading, or buffer space available for writing. +If the note needs to be removed, +.Fn knlist_remove_inevent +must be called. +The function +.Fn knlist_remove_inevent +will remove the note from the list, the +.Va f_detach +function will not be called and the +.Vt knote +will not be returned as an event. +.Pp +Locks +.Em must not +be acquired in +.Va f_event . +If a lock is required in +.Va f_event , +it must be obtained in the +.Fa kl_lock +function of the +.Vt knlist +that the +.Va knote +was added to. +.El +.Pp +The function +.Fn kqfd_register +will register the +.Vt kevent +on the kqueue file descriptor +.Fa fd . +If it is safe to sleep, +.Fa waitok +should be set. +.Pp +The function +.Fn knote_fdclose +is used to delete all +.Vt knotes +associated with +.Fa fd . +Once returned, there will no longer be any +.Vt knotes +associated with the +.Fa fd . +The +.Vt knotes +removed will never be returned from a +.Xr kevent 2 +call, so if userland uses the +.Vt knote +to track resources, they will be leaked. +The +.Fn FILEDESC_LOCK +lock must be held over the call to +.Fn knote_fdclose +so that file descriptors cannot be added or removed. +.Pp +The +.Fn knlist_* +family of functions are for managing +.Vt knotes +associated with an object. +A +.Vt knlist +is not required, but is commonly used. +If used, the +.Vt knlist +must be initialized with the +.Fn knlist_init +function. +If +.Fa lock +is +.Dv NULL , +an internal lock will be used and the remaining arguments will be ignored. +The +.Fa kl_lock , kl_unlock +and +.Fa kl_locked +functions will be used to manipulate a +.Fa lock . +If the argument is +.Dv NULL , +default routines operating on +.Vt "struct mtx *" +will be used. +The +.Vt knlist +structure may be embedded into the object structure. +The +.Fa lock +will be held over calls to +.Va f_event . +If +.Dv NULL +is passed for the mutex, a private mutex will be used. +The function +.Fn knlist_empty +requires that a +.Fa lock +be held. +The function +.Fn knlist_clear +is used to remove all +.Vt knotes +associated with the list. +The +.Fa islocked +argument declares if +.Fa lock +has been acquired. +All +.Vt knotes +will be marked as detached, and +.Dv EV_ONESHOT +will be set so that the +.Vt knote +will be deleted after the next scan. +The +.Fn knlist_destroy +function is used to destroy a +.Vt knlist . +There must be no +.Vt knotes +associated with the +.Vt knlist +.Fn ( knlist_empty +returns true) +and no more +.Vt knotes +may be attached to the object. +A +.Vt knlist +may be emptied by calling +.Fn knlist_clear . +.Pp +The macros +.Fn KNOTE_LOCKED +and +.Fn KNOTE_UNLOCKED +are used to notify +.Vt knotes +about events associated with the object. +It will iterate over all +.Vt knotes +on the list calling the +.Va f_event +function associated with the +.Vt knote . +The macro +.Fn KNOTE_LOCKED +must be used if the lock associated with the +.Fa knl +passed in is held. +The function +.Fn KNOTE_UNLOCKED +will acquire the lock before iterating over the list of +.Vt knotes . +.Sh RETURN VALUES +The function +.Fn kqueue_add_filteropts +will return zero on success, +.Er EINVAL +in the case of an invalid +.Fa filt , +or +.Er EEXIST +if the filter has already been installed. +.Pp +The function +.Fn kqueue_del_filteropts +will return zero on success, +.Er EINVAL +in the case of an invalid +.Fa filt , +or +.Er EBUSY +if the filter is still in use. +.Pp +The function +.Fn kqfd_register +will return zero on success, +.Er EBADF +if the file descriptor is not a kqueue, or any of the possible values returned +by +.Xr kevent 2 . +.Sh SEE ALSO +.Xr kevent 2 , +.Xr kqueue 2 +.Sh AUTHORS +This +manual page was written by +.An John-Mark Gurney Aq jmg at FreeBSD.org . Index: zero_copy.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/zero_copy.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/zero_copy.9 -L share/man/man9/zero_copy.9 -u -r1.2 -r1.3 --- share/man/man9/zero_copy.9 +++ share/man/man9/zero_copy.9 @@ -23,8 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/zero_copy.9,v 1.7 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/zero_copy.9,v 1.8 2006/05/15 20:58:05 wilko Exp $ .\" .Dd December 5, 2004 .Dt ZERO_COPY 9 @@ -91,8 +90,7 @@ For receiving data, in order to take advantage of the zero copy receive code, the user must have a NIC that is configured for an MTU greater than the architecture page size. -(E.g., for alpha this would be 8KB, for i386, -it would be 4KB.) +(E.g., for i386 it would be 4KB.) Additionally, in order for zero copy receive to work, packet payloads must be at least a page in size and page aligned. .Pp Index: VOP_RENAME.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_RENAME.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_RENAME.9 -L share/man/man9/VOP_RENAME.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_RENAME.9 +++ share/man/man9/VOP_RENAME.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_RENAME.9,v 1.21 2005/01/28 10:43:05 ru Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_RENAME.9,v 1.22 2006/11/04 23:59:51 pjd Exp $ .\" .Dd July 24, 1996 .Os @@ -104,34 +104,13 @@ } /* - * Check if just deleting a link name. + * POSIX: "If the old argument and the new argument + * both refer to links to the same existing file, + * the rename() function shall return successfully + * and perform no other action." + * The upper layers already handle this case. */ - if (fvp == tvp) { - if (fvp->v_type == VDIR) { - error = EINVAL; - goto abortit; - } - - /* - * Release destination. - */ - vput(tdvp); - vput(tvp); - - /* - * Delete source. Pretty bizarre stuff. - */ - vrele(fdvp); - vrele(fvp); - fcnp->cn_flags &= ~MODMASK; - fcnp->cn_flags |= LOCKPARENT | LOCKLEAF; - fcnp->cn_nameiop = DELETE; - VREF(fdvp); - error = relookup(fdvp, &fvp, fcnp); - if (error == 0) - vrele(fdvp); - return VOP_REMOVE(fdvp, fvp, fcnp); - } + KASSERT(fvp != tvp, ("vop_rename: source and destination are the same")); if (fvp is immutable) { error = EPERM; Index: uio.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/uio.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/uio.9 -L share/man/man9/uio.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/uio.9 +++ share/man/man9/uio.9 @@ -23,9 +23,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/uio.9,v 1.19 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/uio.9,v 1.21 2006/11/29 20:24:56 alfred Exp $ .\" -.Dd February 2, 1997 +.Dd December 8, 2006 .Os .Dt UIO 9 .Sh NAME @@ -38,13 +38,13 @@ .Pp .Bd -literal struct uio { - struct iovec *uio_iov; - int uio_iovcnt; - off_t uio_offset; - int uio_resid; - enum uio_seg uio_segflg; - enum uio_rw uio_rw; - struct thread *uio_td; + struct iovec *uio_iov; /* scatter/gather list */ + int uio_iovcnt; /* length of scatter/gather list */ + off_t uio_offset; /* offset in target object */ + int uio_resid; /* remaining bytes to copy */ + enum uio_seg uio_segflg; /* address space */ + enum uio_rw uio_rw; /* operation */ + struct thread *uio_td; /* owner */ }; .Ed .Ft int @@ -87,7 +87,7 @@ .It Va uio_offset The offset into the device. .It Va uio_resid -The number of bytes to process. +The remaining number of bytes to process, updated after transfer. .It Va uio_segflg One of the following flags: .Bl -tag -width ".Dv UIO_USERSPACE" @@ -112,14 +112,20 @@ space. .El .Sh RETURN VALUES +On success .Fn uiomove -can return -.Er EFAULT -from the invoked +will return 0, on error it will return an appropriate errno. +.Sh ERRORS +.Fn uiomove +will fail and return the following error code if: +.Bl -tag -width Er +.It Bq Er EFAULT +The invoked .Xr copyin 9 or .Xr copyout 9 -in case the transfer was to/from a process's address space. +returned +.Er EFAULT .Sh EXAMPLES The idea is that the driver maintains a private buffer for its data, and processes the request in chunks of maximal the size of this Index: vn_isdisk.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vn_isdisk.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vn_isdisk.9 -L share/man/man9/vn_isdisk.9 -u -r1.2 -r1.3 --- share/man/man9/vn_isdisk.9 +++ share/man/man9/vn_isdisk.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vn_isdisk.9,v 1.6 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 9, 2001 .Dt VN_ISDISK 9 --- /dev/null +++ share/man/man9/LOCK_PROFILING.9 @@ -0,0 +1,203 @@ +.\"- +.\" Copyright (c) 2004 Dag-Erling Co?dan Sm?rgrav +.\" Copyright (c) 2005 Robert N. M. Watson +.\" Copyright (c) 2006 Kip Macy +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" 3. The name of the author may not be used to endorse or promote products +.\" derived from this software without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/LOCK_PROFILING.9,v 1.2 2006/12/01 17:46:25 ru Exp $ +.\" +.Dd November 11, 2006 +.Dt LOCK_PROFILING 9 +.Os +.Sh NAME +.Nm LOCK_PROFILING +.Nd kernel lock profiling support +.Sh SYNOPSIS +.Cd "options LOCK_PROFILING" +.Sh DESCRIPTION +The +.Dv LOCK_PROFILING +kernel option adds support for measuring and reporting lock use and +contention statistics. +These statistics are collated by +.Dq acquisition point . +Acquisition points are +distinct places in the kernel source code (identified by source file +name and line number) where a lock is acquired. +.Pp +For each acquisition point, the following statistics are accumulated: +.Bl -bullet +.It +The longest time the lock was ever continuously held after being +acquired at this point. +.It +The total time the lock was held after being acquired at this point. +.It +The total time that threads have spent waiting to acquire the lock. +.It +The total number of non-recursive acquisitions. +.It +The total number of times the lock was already held by another thread +when this point was reached, requiring a spin or a sleep. +.It +The total number of times another thread tried to acquire the lock +while it was held after having been acquired at this point. +.El +.Pp +In addition, the average hold time and average wait time are derived +from the total hold time +and total wait time respectively and the number of acquisitions. +.Pp +The +.Dv LOCK_PROFILING +kernel option also adds the following +.Xr sysctl 8 +variables to control and monitor the profiling code: +.Bl -tag -width indent +.It Va debug.lock.prof.enable +Enable or disable the lock profiling code. +This defaults to 0 (off). +.It Va debug.lock.prof.reset +Reset the current lock profiling buffers. +.It Va debug.lock.prof.acquisitions +The total number of lock acquisitions recorded. +.It Va debug.lock.prof.records +The total number of acquisition points recorded. +Note that only active acquisition points (i.e., points that have been +reached at least once) are counted. +.It Va debug.lock.prof.maxrecords +The maximum number of acquisition points the profiling code is capable +of monitoring. +Since it would not be possible to call +.Xr malloc 9 +from within the lock profiling code, this is a static limit. +The number of records can be changed with the +.Dv LPROF_BUFFERS +kernel option. +.It Va debug.lock.prof.rejected +The number of acquisition points that were ignored after the table +filled up. +.It Va debug.lock.prof.hashsize +The size of the hash table used to map acquisition points to +statistics records. +The hash size can be changed with the +.Dv LPROF_HASH_SIZE +kernel option. +.It Va debug.lock.prof.collisions +The number of hash collisions in the acquisition point hash table. +.It Va debug.lock.prof.stats +The actual profiling statistics in plain text. +The columns are as follows, from left to right: +.Bl -tag -width ".Va cnt_hold" +.It Va max +The longest continuous hold time in microseconds. +.It Va total +The total (accumulated) hold time in microseconds. +.It Va wait_total +The total (accumulated) wait time in microseconds. +.It Va count +The total number of acquisitions. +.It Va avg +The average hold time in microseconds, derived from the total hold time +and the number of acquisitions. +.It Va wait_avg +The average wait time in microseconds, derived from the total wait time +and the number of acquisitions. +.It Va cnt_hold +The number of times the lock was held and another thread attempted to +acquire the lock. +.It Va cnt_lock +The number of times the lock was already held when this point was +reached. +.It Va name +The name of the acquisition point, derived from the source file name +and line number, followed by the name of the lock in parentheses. +.El +.El +.Sh SEE ALSO +.Xr sysctl 8 , +.Xr mutex 9 +.Sh HISTORY +Mutex profiling support appeared in +.Fx 5.0 . +Generalized lock profiling support appeared in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm MUTEX_PROFILING +code was written by +.An Eivind Eklund Aq eivind at FreeBSD.org , +.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org +and +.An Robert Watson Aq rwatson at FreeBSD.org . +The +.Nm +code was written by +.An Kip Macy Aq kmacy at FreeBSD.org . +This manual page was written by +.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org . +.Sh NOTES +The +.Dv LOCK_PROFILING +option increases the size of +.Vt "struct lock_object" , +so a kernel built with that option will not work with modules built +without it. +.Pp +The +.Dv LOCK_PROFILING +option also prevents inlining of the mutex code, which can result in a +fairly severe performance penalty. +This is, however, not always the case. +.Dv LOCK_PROFILING +can introduce a substantial performance overhead that is easily +monitorable using other profiling tools, so combining profiling tools +with +.Dv LOCK_PROFILING +is not recommended. +.Pp +Measurements are made and stored in nanoseconds using +.Xr nanotime 9 , +(on architectures without a synchronized TSC) but are presented in microseconds. +This should still be sufficient for the locks one would be most +interested in profiling (those that are held long and/or acquired +often). +.Pp +.Dv LOCK_PROFILING +should generally not be used in combination with other debugging options, as +the results may be strongly affected by interactions between the features. +In particular, +.Dv LOCK_PROFILING +will report higher than normal +.Xr uma 9 +lock contention when run with +.Dv INVARIANTS +due to extra locking that occurs when +.Dv INVARIANTS +is present; likewise, using it in combination with +.Dv WITNESS +will lead to much higher lock hold times and contention in profiling output. --- /dev/null +++ share/man/man9/device_get_sysctl.9 @@ -0,0 +1,58 @@ +.\" -*- nroff -*- +.\" +.\" Copyright (c) 2006 M. Warner Losh +.\" +.\" All rights reserved. +.\" +.\" This program is free software. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/device_get_sysctl.9,v 1.2 2006/09/30 17:09:59 ru Exp $ +.\" +.Dd May 23, 2006 +.Dt DEVICE_GET_SYSCTL 9 +.Os +.Sh NAME +.Nm device_get_sysctl_ctx , +.Nm device_get_sysctl_tree +.Nd manipulate the sysctl oid tree for driver specific sysctl nodes +.Sh SYNOPSIS +.In sys/param.h +.In sys/bus.h +.Ft "struct sysctl_ctx_list *" +.Fn device_get_sysctl_ctx "device_t dev" +.Ft "struct sysctl_oid *" +.Fn device_get_sysctl_tree "device_t dev" +.Sh DESCRIPTION +The newbus system automatically adds a sysctl node for each device +in the system. +This node can be accessed with the +.Fn device_get_sysctl_tree +function. +The context for the node can be obtained with the +.Fn device_get_sysctl_ctl +function. +.Sh SEE ALSO +.Xr device 9 +.Sh AUTHORS +This manual page was written by +.An Warner Losh . Index: ifnet.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ifnet.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/ifnet.9 -L share/man/man9/ifnet.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/ifnet.9 +++ share/man/man9/ifnet.9 @@ -26,9 +26,9 @@ .\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ifnet.9,v 1.50.2.1 2005/08/18 15:01:24 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/ifnet.9,v 1.53 2007/03/14 13:19:50 bms Exp $ .\" -.Dd June 10, 2005 +.Dd March 14, 2007 .Os .Dt IFNET 9 .Sh NAME @@ -103,19 +103,9 @@ .Ft void .Fn \*(lp*if_start\*(rp "struct ifnet *ifp" .Ft int -.Fn \*(lp*if_done\*(rp "struct ifnet *ifp" -.Ft int .Fn \*(lp*if_ioctl\*(rp "struct ifnet *ifp" "int cmd" "caddr_t data" .Ft void .Fn \*(lp*if_watchdog\*(rp "struct ifnet *ifp" -.Ft int -.Fn \*(lp*if_poll_recv\*(rp "struct ifnet *ifp" "int *quotap" -.Ft int -.Fn \*(lp*if_poll_xmit\*(rp "struct ifnet *ifp" "int *quotap" -.Ft void -.Fn \*(lp*if_poll_inttrn\*(rp "struct ifnet *ifp" -.Ft void -.Fn \*(lp*if_poll_slowinput\*(rp "struct ifnet *ifp" "struct mbuf *m" .Ft void .Fn \*(lp*if_init\*(rp "void *if_softc" .Ft int @@ -1024,7 +1014,7 @@ .Va ifnet_addrs . ) The .Fa ifp -must have been allocted by +must have been allocated by .Fn if_alloc . .It Fn if_detach Shut down and unlink the specified Index: g_consumer.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/g_consumer.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/g_consumer.9 -L share/man/man9/g_consumer.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/g_consumer.9 +++ share/man/man9/g_consumer.9 @@ -22,7 +22,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/g_consumer.9,v 1.7 2004/07/06 08:21:12 ru Exp $ +.\" $FreeBSD: src/share/man/man9/g_consumer.9,v 1.8 2006/03/17 13:13:18 des Exp $ .\" .Dd January 16, 2004 .Dt G_CONSUMER 9 @@ -60,11 +60,9 @@ .It The geom .Fa gp -has to have -.Va start -and -.Va access -methods defined. +has to have an +.Va orphan +method defined. .It The topology lock has to be held. .El Index: VOP_LISTEXTATTR.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_LISTEXTATTR.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_LISTEXTATTR.9 -L share/man/man9/VOP_LISTEXTATTR.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_LISTEXTATTR.9 +++ share/man/man9/VOP_LISTEXTATTR.9 @@ -28,7 +28,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_LISTEXTATTR.9,v 1.6.2.1 2005/08/31 00:27:35 rodrigc Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_LISTEXTATTR.9,v 1.7 2005/08/19 12:17:47 rodrigc Exp $ .\" .Dd August 19, 2005 .Os Index: EVENTHANDLER.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/EVENTHANDLER.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/EVENTHANDLER.9 -L share/man/man9/EVENTHANDLER.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/EVENTHANDLER.9 +++ share/man/man9/EVENTHANDLER.9 @@ -21,7 +21,7 @@ .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. -.\" $FreeBSD: src/share/man/man9/EVENTHANDLER.9,v 1.3 2005/01/07 19:41:00 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/EVENTHANDLER.9,v 1.4 2005/10/11 16:05:35 keramida Exp $ .\" .Dd January 7, 2005 .Dt EVENTHANDLER 9 @@ -139,7 +139,7 @@ A pointer to a callback function. Argument .Fa arg -is a passed to the callback function +is passed to the callback function .Fa func as its first argument when it is invoked. .It Fa priority Index: vflush.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vflush.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vflush.9 -L share/man/man9/vflush.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vflush.9 +++ share/man/man9/vflush.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vflush.9,v 1.5 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/vflush.9,v 1.6 2006/06/08 04:39:02 maxim Exp $ .\" .Dd November 21, 2001 .Dt VFLUSH 9 @@ -61,7 +61,7 @@ If set, busy vnodes will be forcibly closed. .It Dv SKIPSYSTEM If set, vnodes with the -.Dv VSYSTEM +.Dv VV_SYSTEM flag set will be skipped. .It Dv WRITECLOSE If set, only regular files currently opened for writing will be removed. Index: bus_dma.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bus_dma.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bus_dma.9 -L share/man/man9/bus_dma.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bus_dma.9 +++ share/man/man9/bus_dma.9 @@ -57,10 +57,10 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bus_dma.9,v 1.25.2.1 2005/12/08 01:41:54 scottl Exp $ +.\" $FreeBSD: src/share/man/man9/bus_dma.9,v 1.40 2007/03/06 17:32:49 jhb Exp $ .\" $NetBSD: bus_dma.9,v 1.25 2002/10/14 13:43:16 wiz Exp $ .\" -.Dd December 5, 2005 +.Dd March 6, 2007 .Dt BUS_DMA 9 .Os .Sh NAME @@ -133,7 +133,7 @@ DMA mappings, handling cache issues, bus specific features and limitations. .Sh STRUCTURES AND TYPES -.Bl -tag -width compact +.Bl -tag -width indent .It Vt bus_dma_tag_t A machine-dependent (MD) opaque type that describes the characteristics of DMA transactions. @@ -143,17 +143,17 @@ to contribute to the constraints of those transactions. .It Vt bus_dma_filter_t Client specified address filter having the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft int .Fn "client_filter" "void *filtarg" "bus_addr_t testaddr" .El -.sp +.Pp Address filters can be specified during tag creation to allow for devices whose DMA address restrictions cannot be specified by a single window. The .Fa filtarg -is client specified during tag creation to be passed to all +argument is specified by the client during tag creation to be passed to all invocations of the callback. The .Fa testaddr @@ -163,16 +163,17 @@ to .Ql trunc_page(testaddr) + PAGE_SIZE - 1 , inclusive. -The filter function should return zero for any mapping in this range -that can be accommodated by the device and non-zero otherwise. +The filter function should return zero if any mapping in this range +can be accommodated by the device and non-zero otherwise. .It Vt bus_dma_segment_t A machine-dependent type that describes individual DMA segments. +It contains the following fields: .Bd -literal bus_addr_t ds_addr; bus_size_t ds_len; .Ed -.sp +.Pp The .Fa ds_addr field contains the device visible address of the DMA segment, and @@ -187,9 +188,12 @@ One map is used for each memory allocation that will be loaded. Maps can be reused once they have been unloaded. Multiple maps can be associated with one DMA tag. -While the value of the map may evaluate to NULL on some platforms under -certain conditions, it should never be assumed that it will be NULL in all -cases. +While the value of the map may evaluate to +.Dv NULL +on some platforms under certain conditions, +it should never be assumed that it will be +.Dv NULL +in all cases. .It Vt bus_dmamap_callback_t Client specified callback for receiving mapping information resulting from the load of a @@ -197,12 +201,12 @@ via .Fn bus_dmamap_load . Callbacks are of the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft void .Fn "client_callback" "void *callback_arg" "bus_dma_segment_t *segs" \ "int nseg" "int error" .El -.sp +.Pp The .Fa callback_arg is the callback argument passed to dmamap load functions. @@ -210,13 +214,13 @@ .Fa segs and .Fa nseg -parameters describe an array of +arguments describe an array of .Vt bus_dma_segment_t structures that represent the mapping. This array is only valid within the scope of the callback function. The success or failure of the mapping is indicated by the .Fa error -parameter. +argument. More information on the use of callbacks can be found in the description of the individual dmamap load functions. .It Vt bus_dmamap_callback2_t @@ -227,14 +231,14 @@ .Fn bus_dmamap_load_uio or .Fn bus_dmamap_load_mbuf . -.sp +.Pp Callback2s are of the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft void .Fn "client_callback2" "void *callback_arg" "bus_dma_segment_t *segs" \ "int nseg" "bus_size_t mapsize" "int error" .El -.sp +.Pp Callback2's behavior is the same as .Vt bus_dmamap_callback_t with the addition that the length of the data mapped is provided via @@ -257,22 +261,22 @@ All operations specified below are performed from the host memory point of view, where a read implies data coming from the device to the host memory, and a write implies data going from the host memory to the device. -Alternately, the operations can be thought of in terms of driver operations, +Alternatively, the operations can be thought of in terms of driver operations, where reading a network packet or storage sector corresponds to a read operation in .Nm . -.Bl -tag -width BUS_DMASYNC_POSTWRITE +.Bl -tag -width ".Dv BUS_DMASYNC_POSTWRITE" .It Dv BUS_DMASYNC_PREREAD Perform any synchronization required prior to an update of host memory by the -DMA read operation. +device. .It Dv BUS_DMASYNC_PREWRITE Perform any synchronization required after an update of host memory by the CPU -and prior to DMA write operations. +and prior to device access to host memory. .It Dv BUS_DMASYNC_POSTREAD -Perform any synchronization required after DMA read operations and prior to -CPU access to host memory. +Perform any synchronization required after an update of host memory by the +device and prior to CPU access to host memory. .It Dv BUS_DMASYNC_POSTWRITE -Perform any synchronization required after DMA write operations. +Perform any synchronization required after device access to host memory. .El .It Vt bus_dma_lock_t Client specified lock/mutex manipulation method. @@ -287,48 +291,57 @@ will not be called since the function loading the map should be holding the appropriate locks. This method is of the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft void .Fn "lockfunc" "void *lockfunc_arg" "bus_dma_lock_op_t op" .El -.sp +.Pp +The +.Fa lockfuncarg +argument is specified by the client during tag creation to be passed to all +invocations of the callback. +The +.Fa op +argument specifies the lock operation to perform. +.Pp Two .Vt lockfunc implementations are provided for convenience. .Fn busdma_lock_mutex -performs standard mutex operations on the sleep mutex provided via the +performs standard mutex operations on the sleep mutex provided via .Fa lockfuncarg . -passed into -.Fn bus_dma_tag_create . .Fn dflt_lock will generate a system panic if it is called. It is substituted into the tag when .Fa lockfunc -is passed as NULL to -.Fn bus_dma_tag_create . +is passed as +.Dv NULL +to +.Fn bus_dma_tag_create +and is useful for tags that should not be used with deferred load operations. .It Vt bus_dma_lock_op_t Operations to be performed by the client-specified .Fn lockfunc . -.Bl -tag -width BUS_DMA_UNLOCK +.Bl -tag -width ".Dv BUS_DMA_UNLOCK" .It Dv BUS_DMA_LOCK Acquires and/or locks the client locking primitive. .It Dv BUS_DMA_UNLOCK Releases and/or unlocks the client locking primitive. .El .El -.sp .Sh FUNCTIONS -.Bl -tag -width compact +.Bl -tag -width indent .It Fn bus_dma_tag_create "parent" "alignment" "boundary" "lowaddr" \ "highaddr" "*filtfunc" "*filtfuncarg" "maxsize" "nsegments" "maxsegsz" \ "flags" "lockfunc" "lockfuncarg" "*dmat" Allocates a device specific DMA tag, and initializes it according to the arguments provided: -.Bl -tag -width *filtfuncarg -compact +.Bl -tag -width ".Fa filtfuncarg" .It Fa parent Indicates restrictions between the parent bridge, CPU memory, and the device. -May be NULL, if no DMA restrictions are to be inherited. +Each device must use a master parent tag by calling +.Fn bus_get_dma_tag . .It Fa alignment Alignment constraint, in bytes, of any mappings created using this tag. The alignment must be a power of 2. @@ -337,7 +350,7 @@ for byte alignment. Hardware requiring DMA transfers to start on a multiple of 4K would specify -.Em 4096. +.Em 4096 . .It Fa boundary Boundary constraint, in bytes, of the target DMA memory region. The boundary indicates the set of addresses, all multiples of the @@ -347,8 +360,7 @@ maximum segment size. .Ql 0 indicates that there are no boundary restrictions. -.It Fa lowaddr -.It Fa highaddr +.It Fa lowaddr , highaddr Bounds of the window of bus address space that .Em cannot be directly accessed by the device. @@ -372,11 +384,13 @@ is used to bounce requests that would otherwise conflict with the exclusion window. .It Fa filtfunc -Optional filter function (may be NULL) to be called for any attempt to +Optional filter function (may be +.Dv NULL ) +to be called for any attempt to map memory into the window described by .Fa lowaddr and -.Fa highaddr. +.Fa highaddr . A filter function is only required when the single window described by .Fa lowaddr @@ -387,7 +401,8 @@ that overlaps the exclusion window. .It Fa filtfuncarg Argument passed to all calls to the filter function for this tag. -May be NULL. +May be +.Dv NULL . .It Fa maxsize Maximum size, in bytes, of the sum of all segment lengths in a given DMA mapping associated with this tag. @@ -403,7 +418,7 @@ .Fa dmat . .It Fa flags Are as follows: -.Bl -tag -width "BUS_DMA_ALLOCNOW" -compact +.Bl -tag -width ".Dv BUS_DMA_ALLOCNOW" .It Dv BUS_DMA_ALLOCNOW Pre-allocate enough resources to handle at least one map load operation on this tag. @@ -418,9 +433,13 @@ It should be treated only as a minor optimization. .El .It Fa lockfunc -Optional lock manipulation function (may be NULL) to be called when busdma +Optional lock manipulation function (may be +.Dv NULL ) +to be called when busdma needs to manipulate a lock on behalf of the client. -If NULL is specified, +If +.Dv NULL +is specified, .Fn dflt_lock is used. .It Fa lockfuncarg @@ -451,7 +470,7 @@ .It Fn bus_dmamap_create "dmat" "flags" "*mapp" Allocates and initializes a DMA map. Arguments are as follows: -.Bl -tag -width nsegments -compact +.Bl -tag -width ".Fa nsegments" .It Fa dmat DMA tag. .It Fa flags @@ -471,7 +490,7 @@ .It Fn bus_dmamap_destroy "dmat" "map" Frees all resources associated with a given DMA map. Arguments are as follows: -.Bl -tag -width dmat -compact +.Bl -tag -width ".Fa dmat" .It Fa dmat DMA tag used to allocate .Fa map . @@ -493,10 +512,10 @@ .Fa map . This call will always return immediately and will not block for any reason. Arguments are as follows: -.Bl -tag -width buflen -compact +.Bl -tag -width ".Fa buflen" .It Fa dmat DMA tag used to allocate -.Fa map. +.Fa map . .It Fa map A DMA map without a currently active mapping. .It Fa buf @@ -515,15 +534,15 @@ See below for specific flags and error codes that control this behavior. .It Fa flags Are as follows: -.Bl -tag -width BUS_DMA_NOWAIT -compact -.It Er BUS_DMA_NOWAIT +.Bl -tag -width ".Dv BUS_DMA_NOWAIT" +.It Dv BUS_DMA_NOWAIT The load should not be deferred in case of insufficient mapping resources, and instead should return immediately with an appropriate error. .El .El .Pp Return values to the caller are as follows: -.Bl -tag -width EINPROGRESS -compact +.Bl -tag -width ".Er EINPROGRESS" .It 0 The callback has been called and completed. The status of the mapping has been delivered to the callback. @@ -536,7 +555,7 @@ .It Er ENOMEM The load request has failed due to insufficient resources, and the caller specifically used the -.Fa BUS_DMA_NOWAIT +.Dv BUS_DMA_NOWAIT flag. .It Er EINVAL The load request was invalid. @@ -558,7 +577,7 @@ When the callback is called, it is presented with an error value indicating the disposition of the mapping. Error may be one of the following: -.Bl -tag -width EINPROGRESS -compact +.Bl -tag -width ".Er EINPROGRESS" .It 0 The mapping was successful and the .Fa dm_segs @@ -581,7 +600,7 @@ argument is also passed to the callback routine, which contains the mbuf chain's packet header length. The -.Fa BUS_DMA_NOWAIT +.Dv BUS_DMA_NOWAIT flag is implied, thus no callback deferral will happen. .Pp Mbuf chains are assumed to be in kernel virtual address space. @@ -617,7 +636,7 @@ i.e. .Fa uio->uio_resid . The -.Fa BUS_DMA_NOWAIT +.Dv BUS_DMA_NOWAIT flag is implied, thus no callback deferral will happen. Returns the same errors as .Fn bus_dmamap_load . @@ -638,7 +657,7 @@ .It Fn bus_dmamap_unload "dmat" "map" Unloads a DMA map. Arguments are as follows: -.Bl -tag -width dmam -compact +.Bl -tag -width ".Fa dmam" .It Fa dmat DMA tag used to allocate .Fa map . @@ -655,7 +674,7 @@ Performs synchronization of a device visible mapping with the CPU visible memory referenced by that mapping. Arguments are as follows: -.Bl -tag -width dmat -compact +.Bl -tag -width ".Fa dmat" .It Fa dmat DMA tag used to allocate .Fa map . @@ -669,38 +688,44 @@ .Fa op . .El .Pp +The .Fn bus_dmamap_sync -is the method used to ensure that CPU and device DMA access to shared +function +is the method used to ensure that CPU's and device's direct +memory access (DMA) to shared memory is coherent. -For example, the CPU might be used to setup the contents of a buffer -that is to be DMA'ed into a device. +For example, the CPU might be used to set up the contents of a buffer +that is to be made available to a device. To ensure that the data are visible via the device's mapping of that -memory, the buffer must be loaded and a dma sync operation of -.Dv BUS_DMASYNC_PREREAD -must be performed. -Additional sync operations must be performed after every CPU write -to this memory if additional DMA reads are to be performed. -Conversely, for the DMA write case, the buffer must be loaded, -and a dma sync operation of +memory, the buffer must be loaded and a DMA sync operation of +.Dv BUS_DMASYNC_PREWRITE +must be performed after the CPU has updated the buffer and before the device +access is initiated. +If the CPU modifies this buffer again later, another .Dv BUS_DMASYNC_PREWRITE -must be performed. -The CPU will only be able to see the results of this DMA write -once the DMA has completed and a -.Dv BUS_DMASYNC_POSTWRITE -operation has been performed. +sync operation must be performed before an additional device +access. +Conversely, suppose a device updates memory that is to be read by a CPU. +In this case, the buffer must be loaded, and a DMA sync operation of +.Dv BUS_DMASYNC_PREREAD +must be performed before the device access is initiated. +The CPU will only be able to see the results of this memory update +once the DMA operation has completed and a +.Dv BUS_DMASYNC_POSTREAD +sync operation has been performed. .Pp -If DMA read and write operations are not preceded and followed by the +If read and write operations are not preceded and followed by the appropriate synchronization operations, behavior is undefined. .It Fn bus_dmamem_alloc "dmat" "**vaddr" "flags" "*mapp" Allocates memory that is mapped into KVA at the address returned in .Fa vaddr -that is permanently loaded into the newly created +and that is permanently loaded into the newly created .Vt bus_dmamap_t returned via .Fa mapp . Arguments are as follows: -.Bl -tag -width alignment -compact +.Bl -tag -width ".Fa alignment" .It Fa dmat DMA tag describing the constraints of the DMA mapping. .It Fa vaddr @@ -708,7 +733,7 @@ the allocated region. .It Fa flags Flags are defined as follows: -.Bl -tag -width BUS_DMA_NOWAIT -compact +.Bl -tag -width ".Dv BUS_DMA_NOWAIT" .It Dv BUS_DMA_WAITOK The routine can safely wait (sleep) for resources. .It Dv BUS_DMA_NOWAIT @@ -724,6 +749,9 @@ Use of this flag does not remove the requirement of using bus_dmamap_sync, but it may reduce the cost of performing these operations. +The +.Dv BUS_DMA_COHERENT +flag is currently implemented on sparc64 and arm. .It Dv BUS_DMA_ZERO Causes the allocated memory to be set to all zeros. .El @@ -735,7 +763,9 @@ .Pp The size of memory to be allocated is .Fa maxsize -as specified in +as specified in the call to +.Fn bus_dma_tag_create +for .Fa dmat . .Pp The current implementation of @@ -753,7 +783,7 @@ referenced by the returned map, the synchronization requirements as described in the .Fn bus_dmamap_sync -section still apply and should be used to achieve portability on architecutures +section still apply and should be used to achieve portability on architectures without coherent buses. .Pp Returns @@ -766,7 +796,7 @@ Any mappings will be invalidated. Arguments are as follows: -.Bl -tag -width vaddr -compact +.Bl -tag -width ".Fa vaddr" .It Fa dmat DMA tag. .It Fa vaddr @@ -783,14 +813,84 @@ .Er ENOMEM is returned. All -routines that are not of type, -.Vt void , +routines that are not of type +.Vt void will return 0 on success or an error -code, as discussed above. +code on failure as discussed above. .Pp All .Vt void routines will succeed if provided with valid arguments. +.Sh LOCKING +Two locking protocols are used by +.Nm . +The first is a private global lock that is used to synchronize access to the +bounce buffer pool on the architectures that make use of them. +This lock is strictly a leaf lock that is only used internally to +.Nm +and is not exposed to clients of the API. +.Pp +The second protocol involves protecting various resources stored in the tag. +Since almost all +.Nm +operations are done through requests from the driver that created the tag, +the most efficient way to protect the tag resources is through the lock that +the driver uses. +In cases where +.Nm +acts on its own without being called by the driver, the lock primitive +specified in the tag is acquired and released automatically. +An example of this is when the +.Fn bus_dmamap_load +callback function is called from a deferred context instead of the driver +context. +This means that certain +.Nm +functions must always be called with the same lock held that is specified in the +tag. +These functions include: +.Pp +.Bl -item -offset indent -compact +.It +.Fn bus_dmamap_load +.It +.Fn bus_dmamap_load_uio +.It +.Fn bus_dmamap_load_mbuf +.It +.Fn bus_dmamap_load_mbuf_sg +.It +.Fn bus_dmamap_unload +.It +.Fn bus_dmamap_sync +.El +.Pp +There is one exception to this rule. +It is common practice to call some of these functions during driver start-up +without any locks held. +So long as there is a guarantee of no possible concurrent use of the tag by +different threads during this operation, it is safe to not hold a lock for +these functions. +.Pp +Certain +.Nm +operations should not be called with the driver lock held, either because +they are already protected by an internal lock, or because they might sleep +due to memory or resource allocation. +The following functions must not be +called with any non-sleepable locks held: +.Pp +.Bl -item -offset indent -compact +.It +.Fn bus_dma_tag_create +.It +.Fn bus_dmamap_create +.It +.Fn bus_dmamem_alloc +.El +.Pp +All other functions do not have a locking protocol and can thus be +called with or without any system or driver locks held. .Sh SEE ALSO .Xr devclass 9 , .Xr device 9 , Index: mutex.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mutex.9,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L share/man/man9/mutex.9 -L share/man/man9/mutex.9 -u -r1.1.1.2 -r1.2 --- share/man/man9/mutex.9 +++ share/man/man9/mutex.9 @@ -26,14 +26,15 @@ .\" SUCH DAMAGE. .\" .\" from BSDI $Id: mutex.4,v 1.1.2.3 1998/04/27 22:53:13 ewv Exp $ -.\" $FreeBSD: src/share/man/man9/mutex.9,v 1.47.2.1 2005/09/21 21:09:36 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/mutex.9,v 1.55 2007/03/30 18:07:26 julian Exp $ .\" -.Dd February 16, 2005 +.Dd December 21, 2006 .Dt MUTEX 9 .Os .Sh NAME .Nm mutex , .Nm mtx_init , +.Nm mtx_destroy , .Nm mtx_lock , .Nm mtx_lock_spin , .Nm mtx_lock_flags , @@ -44,7 +45,7 @@ .Nm mtx_unlock_spin , .Nm mtx_unlock_flags , .Nm mtx_unlock_spin_flags , -.Nm mtx_destroy , +.Nm mtx_sleep , .Nm mtx_initialized , .Nm mtx_owned , .Nm mtx_recursed , @@ -58,6 +59,8 @@ .Ft void .Fn mtx_init "struct mtx *mutex" "const char *name" "const char *type" "int opts" .Ft void +.Fn mtx_destroy "struct mtx *mutex" +.Ft void .Fn mtx_lock "struct mtx *mutex" .Ft void .Fn mtx_lock_spin "struct mtx *mutex" @@ -77,8 +80,8 @@ .Fn mtx_unlock_flags "struct mtx *mutex" "int flags" .Ft void .Fn mtx_unlock_spin_flags "struct mtx *mutex" "int flags" -.Ft void -.Fn mtx_destroy "struct mtx *mutex" +.Ft int +.Fn mtx_sleep "void *chan" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" .Ft int .Fn mtx_initialized "struct mtx *mutex" .Ft int @@ -91,7 +94,7 @@ .Ft void .Fn mtx_assert "struct mtx *mutex" "int what" .In sys/kernel.h -.Fn MTX_SYSINIT "name" "struct mutex *mtx" "const char *description" "int opts" +.Fn MTX_SYSINIT "name" "struct mtx *mtx" "const char *description" "int opts" .Sh DESCRIPTION Mutexes are the most basic and primary method of thread synchronization. The major design considerations for mutexes are: @@ -305,6 +308,15 @@ when it is destroyed. .Pp The +.Fn mtx_sleep +function is used to atomically release +.Fa mtx +while waiting for an event. +For more details on the parameters to this function, +see +.Xr sleep 9 . +.Pp +The .Fn mtx_initialized function returns non-zero if .Fa mutex @@ -434,6 +446,8 @@ to ignore this lock. .It Dv MTX_DUPOK Witness should not log messages about duplicate locks being acquired. +.It Dv MTX_NOPROFILE +Do not profile this lock. .El .Ss Lock and Unlock Flags The flags passed to the @@ -495,11 +509,13 @@ No locks are needed when calling these functions. .Sh SEE ALSO .Xr condvar 9 , -.Xr msleep 9 , +.Xr LOCK_PROFILING 9 , +.Xr locking 9 , .Xr mtx_pool 9 , -.Xr MUTEX_PROFILING 9 , .Xr panic 9 , +.Xr rwlock 9 , .Xr sema 9 , +.Xr sleep 9 , .Xr sx 9 .Sh HISTORY These Index: pmap_remove.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pmap_remove.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pmap_remove.9 -L share/man/man9/pmap_remove.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pmap_remove.9 +++ share/man/man9/pmap_remove.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pmap_remove.9,v 1.2 2004/07/06 07:02:31 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pmap_remove.9,v 1.3 2006/04/03 21:17:36 peter Exp $ .\" .Dd July 21, 2003 .Dt PMAP_REMOVE 9 @@ -42,7 +42,7 @@ .Ft void .Fn pmap_remove_all "vm_page_t m" .Ft void -.Fn pmap_remove_pages "pmap_t pmap" "vm_offset_t sva" "vm_offset_t eva" +.Fn pmap_remove_pages "pmap_t pmap" .Sh DESCRIPTION The .Fn pmap_remove @@ -72,12 +72,8 @@ .Pp The .Fn pmap_remove_pages -function removes all pages from the physical map -.Fa pmap , -within the range of physical addresses bounded by -.Fa sva -and -.Fa eva . +function removes all user pages from the physical map +.Fa pmap . This function is called when a process exits to run down its address space more quickly than would be the case for calling .Fn pmap_remove . Index: suser.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/suser.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/suser.9 -L share/man/man9/suser.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/suser.9 +++ share/man/man9/suser.9 @@ -12,11 +12,7 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" 3. All advertising materials mentioning features or use of this software -.\" must display the following acknowledgement: -.\" This product includes software developed for the FreeBSD Project -.\" by Julian R Elischer -.\" 4. The name of the author may not be used to endorse or promote products +.\" 3. The name of the author may not be used to endorse or promote products .\" derived from this software without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR @@ -31,18 +27,17 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/suser.9,v 1.28 2005/01/12 21:48:25 ru Exp $ +.\" $FreeBSD: src/share/man/man9/suser.9,v 1.34 2007/08/30 15:03:21 danger Exp $ .\" -.Dd April 2, 2002 +.Dd August 30, 2007 .Dt SUSER 9 .Os .Sh NAME .Nm suser , .Nm suser_cred -.Nd check if credentials have superuser privilege +.Nd check if credentials have superuser privileges .Sh SYNOPSIS -.In sys/param.h -.In sys/systm.h +.In sys/priv.h .Ft int .Fn suser "struct thread *td" .Ft int @@ -54,6 +49,12 @@ .Fn suser_cred functions check if the credentials given include superuser powers. .Pp +These interfaces have now been obsoleted by +.Xr priv 9 , +and are provided only for compatibility with third party kernel modules that +have not yet been updated to the new interface. +They should not be used in any new kernel code. +.Pp The .Fn suser function is the most common, and should be used unless special @@ -66,37 +67,17 @@ powers should be extended to imprisoned roots, or when the credential to be checked is the real user rather than the effective user. .Pp -By default, a process does not command superuser powers if it has -been imprisoned by the -.Xr jail 2 -system call. -There are cases however where this is appropriate, and this can -be done by passing -.Dv SUSER_ALLOWJAIL -in the -.Fa flag -argument to the -.Fn suser_cred -function. -It is important to review carefully in each case that -this does not weaken the prison. -Generally, only where the action is protected by -.Xr chroot 2 -implicit in the -.Xr jail 2 -call should such powers be granted. -.Pp -By default, the credential checked is the effective user. -There are cases -where it is instead necessary to check the real user (for example, when -determining if resource limits should be applied), and this can be done -by passing the -.Dv SUSER_RUID -flag in the -.Fa flag -argument to the -.Fn suser_cred -function. +Whether or not a privilege is permitted in a +.Xr jail 8 +depends on logic in +.Fn prison_priv_check . +.Pp +In general, privileges are assigned based on the effective user ID; in some +cases, the real user ID may be used. +.Pp +The +.Fa flags +field is currently unused. .Pp The .Fn suser @@ -123,7 +104,8 @@ in which a TRUE response indicates superuser powers. .Sh SEE ALSO .Xr chroot 2 , -.Xr jail 2 +.Xr jail 2 , +.Xr priv 9 .Sh BUGS The .Fn suser Index: vref.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vref.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vref.9 -L share/man/man9/vref.9 -u -r1.2 -r1.3 --- share/man/man9/vref.9 +++ share/man/man9/vref.9 @@ -27,7 +27,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vref.9,v 1.13 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 1996 .Os Index: sleep.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sleep.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/sleep.9 -L share/man/man9/sleep.9 -u -r1.2 -r1.3 --- share/man/man9/sleep.9 +++ share/man/man9/sleep.9 @@ -23,14 +23,15 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sleep.9,v 1.45 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/sleep.9,v 1.61 2007/03/30 18:07:26 julian Exp $ .\" -.Dd December 17, 1998 +.Dd February 27, 2007 .Os .Dt SLEEP 9 .Sh NAME -.Nm sleep , .Nm msleep , +.Nm msleep_spin , +.Nm pause , .Nm tsleep , .Nm wakeup .Nd wait for events @@ -39,80 +40,65 @@ .In sys/systm.h .In sys/proc.h .Ft int -.Fn tsleep "void *ident" "int priority" "const char *wmesg" "int timo" +.Fn msleep "void *chan" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" .Ft int -.Fn msleep "void *ident" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" +.Fn msleep_spin "void *chan" "struct mtx *mtx" "const char *wmesg" "int timo" .Ft void -.Fn wakeup "void *ident" +.Fn pause "const char *wmesg" "int timo" +.Ft int +.Fn tsleep "void *chan" "int priority" "const char *wmesg" "int timo" +.Ft void +.Fn wakeup "void *chan" .Ft void -.Fn wakeup_one "void *ident" +.Fn wakeup_one "void *chan" .Sh DESCRIPTION The functions -.Fn tsleep +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +.Fn pause , +.Fn wakeup , and -.Fn wakeup -handle event-based process blocking. -If a process must wait for an -external event, it is put on sleep by -.Fn tsleep . +.Fn wakeup_one +handle event-based thread blocking. +If a thread must wait for an +external event, it is put to sleep by +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +or +.Fn pause . +Threads may also wait using one of the locking primitive sleep routines +.Xr mtx_sleep 9 , +.Xr rw_sleep 9 , +or +.Xr sx_sleep 9 . +.Pp The parameter -.Fa ident +.Fa chan is an arbitrary address that uniquely identifies the event on which -the process is being asleep. -All processes sleeping on a single -.Fa ident +the thread is being put to sleep. +All threads sleeping on a single +.Fa chan are woken up later by .Fn wakeup , often called from inside an interrupt routine, to indicate that the -resource the process was blocking on is available now. +resource the thread was blocking on is available now. .Pp The parameter -.Fa wmesg -is a string describing the sleep condition for tools like -.Xr ps 1 . -Due to the limited space of those programs to display arbitrary strings, -this message should not be longer than 6 characters. -.Pp -The -.Fn wakeup_one -function is used to make the first process in the queue that is -sleeping on the parameter -.Fa ident -runnable. -This can prevent the system from becoming saturated -when a large number of processes are sleeping on the same address, -but only one of them can actually do any useful work when made -runnable. -.Pp -The -.Fn tsleep -function is the general sleep call. -Suspends the current process until a wakeup is -performed on the specified identifier. -The process will then be made +.Fa priority +specifies a new priority for the thread as well as some optional flags. +If the new priority is not 0, +then the thread will be made runnable with the specified -.Fa priority . -Sleeps at most -.Fa timo -\&/ hz seconds (0 means no timeout). -If the -.Va Giant -lock is not held, and -.Fa mtx -is -.Dv NULL , -then -.Fa timo -must be non-zero. +.Fa priority +when it resumes. If .Fa priority includes the .Dv PCATCH -flag, signals are checked before and after sleeping, else signals are +flag, signals are checked before and after sleeping, otherwise signals are not checked. -Returns 0 if awakened, -.Er EWOULDBLOCK -if the timeout expires. If .Dv PCATCH is set and a signal needs to be delivered, @@ -124,48 +110,206 @@ (return .Er EINTR ) . .Pp -The -.Fn msleep -function is a variation on tsleep. The parameter -.Fa mtx -is a mutex which will be released before sleeping and reacquired before -.Fn msleep -returns. +.Fa wmesg +is a string describing the sleep condition for tools like +.Xr ps 1 . +Due to the limited space of those programs to display arbitrary strings, +this message should not be longer than 6 characters. +.Pp +The parameter +.Fa timo +specifies a timeout for the sleep. +If +.Fa timo +is not 0, +then the thread will sleep for at most +.Fa timo No / Va hz +seconds. +If the timeout expires, +then the sleep function will return +.Er EWOULDBLOCK . +.Pp +Several of the sleep functions including +.Fn msleep , +.Fn msleep_spin , +and the locking primitive sleep routines specify an additional lock +parameter. +The lock will be released before sleeping and reacquired +before the sleep routine returns. If .Fa priority includes the .Dv PDROP -flag, the -.Fa mtx -parameter will not be reacquired before returning. -The mutex is -used to ensure that a condition can be checked atomically, and -that the current process can be suspended without missing a +flag, then +the lock will not be reacquired before returning. +The lock is used to ensure that a condition can be checked atomically, +and that the current thread can be suspended without missing a change to the condition, or an associated wakeup. +In addition, all of the sleep routines will fully drop the +.Va Giant +mutex +(even if recursed) +while the thread is suspended and will reacquire the +.Va Giant +mutex before the function returns. +.Pp +To avoid lost wakeups, +either a lock should be used to protect against races, +or a timeout should be specified to place an upper bound on the delay due +to a lost wakeup. +As a result, +the +.Fn tsleep +function should only be invoked with a timeout of 0 when the +.Va Giant +mutex is held. +.Pp +The +.Fn msleep +function requires that +.Fa mtx +reference a default, i.e. non-spin, mutex. +Its use is deprecated in favor of +.Xr mtx_sleep 9 +which provides identical behavior. +.Pp +The +.Fn msleep_spin +function requires that +.Fa mtx +reference a spin mutex. +The +.Fn msleep_spin +function does not accept a +.Fa priority +parameter and thus does not support changing the current thread's priority, +the +.Dv PDROP +flag, +or catching signals via the +.Dv PCATCH +flag. +.Pp +The +.Fn pause +function is a wrapper around +.Fn tsleep +that suspends execution of the current thread for the indicated timeout. +The thread can not be awakened early by signals or calls to +.Fn wakeup +or +.Fn wakeup_one . +.Pp +The +.Fn wakeup_one +function makes the first thread in the queue that is sleeping on the +parameter +.Fa chan +runnable. +This reduces the load when a large number of threads are sleeping on +the same address, but only one of them can actually do any useful work +when made runnable. +.Pp +Due to the way it works, the +.Fn wakeup_one +function requires that only related threads sleep on a specific +.Fa chan +address. +It is the programmer's responsibility to choose a unique +.Fa chan +value. +The older +.Fn wakeup +function did not require this, though it was never good practice +for threads to share a +.Fa chan +value. +When converting from +.Fn wakeup +to +.Fn wakeup_one , +pay particular attention to ensure that no other threads wait on the +same +.Fa chan . .Sh RETURN VALUES -See above. +If the thread is awakened by a call to +.Fn wakeup +or +.Fn wakeup_one , +the +.Fn msleep , +.Fn msleep_spin , +.Fn tsleep , +and locking primitive sleep functions return 0. +Otherwise, a non-zero error code is returned. +.Sh ERRORS +.Fn msleep , +.Fn msleep_spin , +.Fn tsleep , +and the locking primitive sleep functions will fail if: +.Bl -tag -width Er +.It Bq Er EINTR +The +.Dv PCATCH +flag was specified, a signal was caught, and the system call should be +interrupted. +.It Bq Er ERESTART +The +.Dv PCATCH +flag was specified, a signal was caught, and the system call should be +restarted. +.It Bq Er EWOULDBLOCK +A non-zero timeout was specified and the timeout expired. +.El .Sh SEE ALSO .Xr ps 1 , +.Xr locking 9 , .Xr malloc 9 , -.Xr mi_switch 9 +.Xr mi_switch 9 , +.Xr mtx_sleep 9 , +.Xr rw_sleep 9 , +.Xr sx_sleep 9 .Sh HISTORY -The sleep/wakeup process synchronization mechanism is very old. -It -appeared in a very early version of +The functions +.Fn sleep +and +.Fn wakeup +were present in +.At v1 . +They were probably also present in the preceding +PDP-7 version of .Ux . +They were the basic process synchronization model. .Pp The .Fn tsleep function appeared in -.Bx 4.4 . -.Pp +.Bx 4.4 +and added the parameters +.Fa wmesg +and +.Fa timo . The .Fn sleep -function used to be the traditional form. -It did not let you specify a timeout or a -.Fa wmesg , -hence it was discontinued. +function was removed in +.Fx 2.2 . +The +.Fn wakeup_one +function appeared in +.Fx 2.2 . +The +.Fn msleep +function appeared in +.Fx 5.0 , +and the +.Fn msleep_spin +function appeared in +.Fx 6.2 . +The +.Fn pause +function appeared in +.Fx 7.0 . .Sh AUTHORS .An -nosplit This manual page was written by Index: atomic.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/atomic.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/atomic.9 -L share/man/man9/atomic.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/atomic.9 +++ share/man/man9/atomic.9 @@ -21,9 +21,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/atomic.9,v 1.11.10.1 2005/10/06 18:12:04 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/atomic.9,v 1.13 2005/11/18 10:52:24 ru Exp $ .\" -.Dd October 27, 2000 +.Dd September 27, 2005 .Os .Dt ATOMIC 9 .Sh NAME Index: rtentry.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/rtentry.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/rtentry.9 -L share/man/man9/rtentry.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/rtentry.9 +++ share/man/man9/rtentry.9 @@ -26,7 +26,7 @@ .\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/rtentry.9,v 1.24 2005/01/21 08:36:40 ru Exp $ +.\" $FreeBSD: src/share/man/man9/rtentry.9,v 1.25 2007/08/05 07:38:09 maxim Exp $ .\" .Dd October 7, 2004 .Os @@ -263,7 +263,7 @@ .Dv RMX_RTTUNIT per second. .It Vt "u_long rmx_rttvar" ; -The average deviation of the round-type time to this destination, in +The average deviation of the round-trip time to this destination, in units of .Dv RMX_RTTUNIT per second. Index: device_get_softc.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/device_get_softc.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/device_get_softc.9 -L share/man/man9/device_get_softc.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/device_get_softc.9 +++ share/man/man9/device_get_softc.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/device_get_softc.9,v 1.10.10.2 2005/11/04 22:10:13 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/device_get_softc.9,v 1.13 2005/11/18 10:52:24 ru Exp $ .\" .Dd August 2, 2005 .Dt DEVICE_GET_SOFTC 9 @@ -60,8 +60,8 @@ .Sh RETURN VALUES The pointer to the driver-specific instance variable is returned. .Sh SEE ALSO -.Xr DEVICE_PROBE 9 , .Xr device 9 , +.Xr DEVICE_PROBE 9 , .Xr device_set_softc 9 , .Xr driver 9 .Sh AUTHORS Index: mi_switch.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mi_switch.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/mi_switch.9 -L share/man/man9/mi_switch.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/mi_switch.9 +++ share/man/man9/mi_switch.9 @@ -34,7 +34,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mi_switch.9,v 1.19 2005/01/29 20:05:07 ru Exp $ +.\" $FreeBSD: src/share/man/man9/mi_switch.9,v 1.20 2007/03/09 22:41:01 jhb Exp $ .\" .Dd November 24, 1996 .Dt MI_SWITCH 9 @@ -65,13 +65,13 @@ can be enumerated as follows: .Bl -enum -offset indent .It -From within -.Xr sleep 9 , -.Xr tsleep 9 -and -.Xr msleep 9 +From within a function such as +.Xr cv_wait 9 , +.Xr mtx_lock , +or +.Xr tsleep 9 when the current thread -voluntarily relinquishes the CPU to wait for some resource to become +voluntarily relinquishes the CPU to wait for some resource or lock to become available. .It After handling a trap @@ -157,6 +157,7 @@ .Va sched_lock mutex held. .Sh SEE ALSO +.Xr cv_wait 9 , .Xr issignal 9 , .Xr mutex 9 , .Xr runqueue 9 , Index: vm_page_wakeup.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_wakeup.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_wakeup.9 -L share/man/man9/vm_page_wakeup.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_wakeup.9 +++ share/man/man9/vm_page_wakeup.9 @@ -24,8 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_page_wakeup.9,v 1.2 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/vm_page_wakeup.9,v 1.3 2006/02/13 21:34:19 joel Exp $ .\" .Dd July 14, 2001 .Dt VM_PAGE_BUSY 9 @@ -68,7 +67,6 @@ flag on the page, and calls .Fn vm_page_flash in case somebody has been waiting for it. -.Pp .Sh SEE ALSO .Xr vm_page_sleep_busy 9 , .Xr wakeup 9 Index: memguard.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/memguard.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/memguard.9 -L share/man/man9/memguard.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/memguard.9 +++ share/man/man9/memguard.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/memguard.9,v 1.1 2005/02/22 17:18:27 brueffer Exp $ +.\" $FreeBSD: src/share/man/man9/memguard.9,v 1.5 2006/09/18 15:24:20 ru Exp $ .\" -.Dd February 22, 2005 +.Dd January 31, 2006 .Dt MEMGUARD 9 .Os .Sh NAME @@ -47,42 +47,38 @@ and .Fn free for a particular malloc type. -.Nm -takes over -.Dv M_SUBPROC -allocations by default. -.Sh FILES -.Bl -tag -width ".Pa src/sys/kern/kern_malloc.c" -compact -.It Pa src/sys/kern/kern_malloc.c -File to replace the malloc type in -.El .Sh EXAMPLES -The following steps are necessary to use -.Nm : -.Bl -enum -.It -Put the -.Dv DEBUG_MEMGUARD -option into your kernel config. -.It -Open -.Pa src/sys/kern/kern_malloc.c -in your favourite editor. -Look for lines containing -.Dq Li "XXX CHANGEME!" -and replace -.Dv M_SUBPROC -with the appropriate malloc type. -This might require additional but small/simple -code modifications -(e.g., if the malloc type is declared out of scope). -.It -Build and install your kernel. -Tune the -.Va vm.memguard_divisor -boot-time tunable, which is used to scale how much of +To use +.Nm +for memory type compiled into the kernel, one has to add the +following line to the +.Pa /boot/loader.conf : +.Bd -literal -offset indent +vm.memguard.desc= +.Ed +.Pp +Where +.Ar memory_type +is a short description of memory type to monitor. +The short description of memory type is the second argument to +.Xr MALLOC_DEFINE 9 , +so one has to find it in the kernel source. +.Pp +To use +.Nm +for memory type defined in a kernel module, one has to set +.Va vm.memguard.desc +.Xr sysctl 8 +variable before loading the module: +.Bd -literal -offset indent +sysctl vm.memguard.desc= +.Ed +.Pp +The +.Va vm.memguard.divisor +boot-time tunable is used to scale how much of .Va kmem_map -you want to allot for +one wants to allocate for .Nm . The default is 10, so .Va kmem_size Ns /10 @@ -93,12 +89,12 @@ .Va vm.kmem_size .Xr sysctl 8 variable. -.El .Sh SEE ALSO .Xr sysctl 8 , .Xr vmstat 8 , .Xr contigmalloc 9 , -.Xr malloc 9 +.Xr malloc 9 , +.Xr redzone 9 .Sh HISTORY .Nm first appeared in --- /dev/null +++ share/man/man9/locking.9 @@ -0,0 +1,357 @@ +.\" Copyright (c) 2007 Julian Elischer (julian - freebsd org ) +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/locking.9,v 1.11 2007/08/09 21:09:56 julian Exp $ +.\" +.Dd March 14, 2007 +.Dt LOCKING 9 +.Os +.Sh NAME +.Nm locking +.Nd kernel synchronization primitives +.Sh SYNOPSIS +All sorts of stuff to go here. +.Pp +.Sh DESCRIPTION +The +.Em FreeBSD +kernel is written to run across multiple CPUs and as such requires +several different synchronization primitives to allow the developers +to safely access and manipulate the many data types required. +.Pp +These include: +.Bl -enum +.It +Spin Mutexes +.It +Sleep Mutexes +.It +pool Mutexes +.It +Shared-Exclusive locks +.It +Reader-Writer locks +.It +Turnstiles +.It +Semaphores +.It +Condition variables +.It +Sleep/wakeup +.It +Giant +.It +Lockmanager locks +.El +.Pp +The primitives interact and have a number of rules regarding how +they can and can not be combined. +There are too many for the average +human mind and they keep changing. +(if you disagree, please write replacement text) :-) +.Pp +Some of these primitives may be used at the low (interrupt) level and +some may not. +.Pp +There are strict ordering requirements and for some of the types this +is checked using the +.Xr witness 4 +code. +.Pp +.Ss SPIN Mutexes +Mutexes are the basic primitive. +You either hold it or you don't. +If you don't own it then you just spin, waiting for the holder (on +another CPU) to release it. +Hopefully they are doing something fast. +You +.Em must not +do anything that deschedules the thread while you +are holding a SPIN mutex. +.Ss Mutexes +Basically (regular) mutexes will deschedule the thread if the +mutex can not be acquired. +A non-spin mutex can be considered to be equivalent +to getting a write lock on an +.Em rw_lock +(see below), and in fact non-spin mutexes and rw_locks may soon become the same thing. +As in spin mutexes, you either get it or you don't. +You may only call the +.Xr sleep 9 +call via +.Fn msleep +or the new +.Fn mtx_sleep +variant. +These will atomically drop the mutex and reacquire it +as part of waking up. +This is often however a +.Em BAD +idea because it generally relies on you having +such a good knowledge of all the call graph above you +and what assumptions it is making that there are a lot +of ways to make hard-to-find mistakes. +For example you MUST re-test all the assumptions you made before, +all the way up the call graph to where you got the lock. +You can not just assume that mtx_sleep can be inserted anywhere. +If any caller above you has any mutex or +rwlock, your sleep, will cause a panic. +If the sleep only happens rarely it may be years before the +bad code path is found. +.Ss Pool Mutexes +A variant of regular mutexes where the allocation of the mutex is handled +more by the system. +.Ss Rw_locks +Reader/writer locks allow shared access to protected data by multiple threads, +or exclusive access by a single thread. +The threads with shared access are known as +.Em readers +since they should only read the protected data. +A thread with exclusive access is known as a +.Em writer +since it may modify protected data. +.Pp +Although reader/writer locks look very similar to +.Xr sx 9 +(see below) locks, their usage pattern is different. +Reader/writer locks can be treated as mutexes (see above and +.Xr mutex 9 ) +with shared/exclusive semantics. +More specifically, regular mutexes can be +considered to be equivalent to a write-lock on an +.Em rw_lock. +In the future this may in fact +become literally the fact. +An +.Em rw_lock +can be locked while holding a regular mutex, but +can +.Em not +be held while sleeping. +The +.Em rw_lock +locks have priority propagation like mutexes, but priority +can be propagated only to an exclusive holder. +This limitation comes from the fact that shared owners +are anonymous. +Another important property is that shared holders of +.Em rw_lock +can recurse, but exclusive locks are not allowed to recurse. +This ability should not be used lightly and +.Em may go away. +Users of recursion in any locks should be prepared to +defend their decision against vigorous criticism. +.Ss Sx_locks +Shared/exclusive locks are used to protect data that are read far more often +than they are written. +Mutexes are inherently more efficient than shared/exclusive locks, so +shared/exclusive locks should be used prudently. +The main reason for using an +.Em sx_lock +is that a thread may hold a shared or exclusive lock on an +.Em sx_lock +lock while sleeping. +As a consequence of this however, an +.Em sx_lock +lock may not be acquired while holding a mutex. +The reason for this is that, if one thread slept while holding an +.Em sx_lock +lock while another thread blocked on the same +.Em sx_lock +lock after acquiring a mutex, then the second thread would effectively +end up sleeping while holding a mutex, which is not allowed. +The +.Em sx_lock +should be considered to be closely related to +.Xr sleep 9 . +In fact it could in some cases be +considered a conditional sleep. +.Ss Turnstiles +Turnstiles are used to hold a queue of threads blocked on +non-sleepable locks. +Sleepable locks use condition variables to implement their queues. +Turnstiles differ from a sleep queue in that turnstile queue's +are assigned to a lock held by an owning thread. +Thus, when one thread is enqueued onto a turnstile, it can lend its +priority to the owning thread. +If this sounds confusing, we need to describe it better. +.Ss Semaphores +.Ss Condition variables +Condition variables are used in conjunction with mutexes to wait for +conditions to occur. +A thread must hold the mutex before calling the +.Fn cv_wait* , +functions. +When a thread waits on a condition, the mutex +is atomically released before the thread is blocked, then reacquired +before the function call returns. +.Ss Giant +Giant is a special instance of a sleep lock. +It has several special characteristics. +.Bl -enum +.It +It is recursive. +.It +Drivers can request that Giant be locked around them, but this is +going away. +.It +You can sleep while it has recursed, but other recursive locks cannot. +.It +Giant must be locked first before other locks. +.It +There are places in the kernel that drop Giant and pick it back up +again. +Sleep locks will do this before sleeping. +Parts of the Network or VM code may do this as well, depending on the +setting of a sysctl. +This means that you cannot count on Giant keeping other code from +running if your code sleeps, even if you want it to. +.El +.Ss Sleep/wakeup +The functions +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +.Fn pause , +.Fn wakeup , +and +.Fn wakeup_one +handle event-based thread blocking. +If a thread must wait for an external event, it is put to sleep by +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +or +.Fn pause . +Threads may also wait using one of the locking primitive sleep routines +.Xr mtx_sleep 9 , +.Xr rw_sleep 9 , +or +.Xr sx_sleep 9 . +.Pp +The parameter +.Fa chan +is an arbitrary address that uniquely identifies the event on which +the thread is being put to sleep. +All threads sleeping on a single +.Fa chan +are woken up later by +.Fn wakeup , +often called from inside an interrupt routine, to indicate that the +resource the thread was blocking on is available now. +.Pp +Several of the sleep functions including +.Fn msleep , +.Fn msleep_spin , +and the locking primitive sleep routines specify an additional lock +parameter. +The lock will be released before sleeping and reacquired +before the sleep routine returns. +If +.Fa priority +includes the +.Dv PDROP +flag, then the lock will not be reacquired before returning. +The lock is used to ensure that a condition can be checked atomically, +and that the current thread can be suspended without missing a +change to the condition, or an associated wakeup. +In addition, all of the sleep routines will fully drop the +.Va Giant +mutex +(even if recursed) +while the thread is suspended and will reacquire the +.Va Giant +mutex before the function returns. +.Pp +.Ss lockmanager locks +Largely deprecated. +See the +.Xr lock 9 +page for more information. +I don't know what the downsides are but I'm sure someone will fill in this part. +.Sh Usage tables. +.Ss Interaction table. +The following table shows what you can and can not do if you hold +one of the synchronization primitives discussed here: +(someone who knows what they are talking about should write this table) +.Bl -column ".Ic xxxxxxxxxxxxxxxxxxxx" ".Xr XXXXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXX" -offset indent +.It Xo +.Em "You have: You want:" Ta Spin_mtx Ta Slp_mtx Ta sx_lock Ta rw_lock Ta sleep +.Xc +.It Ic SPIN mutex Ta \&ok Ta \&no Ta \&no Ta \&no Ta \&no-3 +.It Ic Sleep mutex Ta \&ok Ta \&ok-1 Ta \&no Ta \&ok Ta \&no-3 +.It Ic sx_lock Ta \&ok Ta \&no Ta \&ok-2 Ta \&no Ta \&ok-4 +.It Ic rw_lock Ta \&ok Ta \&ok Ta \&no Ta \&ok-2 Ta \&no-3 +.El +.Pp +.Em *1 +Recursion is defined per lock. +Lock order is important. +.Pp +.Em *2 +readers can recurse though writers can not. +Lock order is important. +.Pp +.Em *3 +There are calls atomically release this primitive when going to sleep +and reacquire it on wakeup (e.g. +.Fn mtx_sleep , +.Fn rw_sleep +and +.Fn msleep_spin +). +.Pp +.Em *4 +Though one can sleep holding an sx lock, one can also use +.Fn sx_sleep +which atomically release this primitive when going to sleep and +reacquire it on wakeup. +.Ss Context mode table. +The next table shows what can be used in different contexts. +At this time this is a rather easy to remember table. +.Bl -column ".Ic Xxxxxxxxxxxxxxxxxxxx" ".Xr XXXXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXX" -offset indent +.It Xo +.Em "Context:" Ta Spin_mtx Ta Slp_mtx Ta sx_lock Ta rw_lock Ta sleep +.Xc +.It interrupt: Ta \&ok Ta \&no Ta \&no Ta \&no Ta \&no +.It idle: Ta \&ok Ta \&no Ta \&no Ta \&no Ta \&no +.El +.Sh SEE ALSO +.Xr condvar 9 , +.Xr lock 9 , +.Xr mtx_pool 9 , +.Xr mutex 9 , +.Xr rwlock 9 , +.Xr sema 9 , +.Xr sleep 9 , +.Xr sx 9 , +.Xr LOCK_PROFILING 9 , +.Xr WITNESS 9 +.Sh HISTORY +These +functions appeared in +.Bsx 4.1 +through +.Fx 7.0 Index: zone.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/zone.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/zone.9 -L share/man/man9/zone.9 -u -r1.2 -r1.3 --- share/man/man9/zone.9 +++ share/man/man9/zone.9 @@ -23,10 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/zone.9,v 1.26 2004/01/25 11:39:41 des Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/zone.9,v 1.28 2006/10/21 16:08:21 ru Exp $ .\" -.Dd July 21, 2003 +.Dd October 2, 2006 .Dt ZONE 9 .Os .Sh NAME @@ -66,27 +65,9 @@ are not, and provides functions for allocating items from the zone and for releasing them back (which makes them available for later use). .Pp -The zone allocator stores state information inside the items proper -while they are not allocated, -so structures that will be managed by the zone allocator -and wish to use the type stable property of zones by leaving some fields -pre-filled between allocations, must reserve -two pointers at the very beginning for internal use by the zone -allocator, as follows: -.Bd -literal -offset indent -struct my_item { - struct my_item *z_rsvd1; - struct my_item *z_rsvd2; - /* rest of structure */ -}; -.Ed -.Pp -Alternatively they should assume those entries corrupted -after each allocation. After the first allocation of an item, it will have been cleared to zeroes, however subsequent allocations -will retain the contents as of the last free, with the exception of the -fields mentioned above. +will retain the contents as of the last free. .Pp The .Fn uma_zcreate Index: disk.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/disk.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/disk.9 -L share/man/man9/disk.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/disk.9 +++ share/man/man9/disk.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/disk.9,v 1.7 2004/06/21 14:11:45 mpp Exp $ +.\" $FreeBSD: src/share/man/man9/disk.9,v 1.10 2007/05/05 17:12:15 pjd Exp $ .\" .Dd February 18, 2004 .Dt DISK 9 @@ -35,7 +35,7 @@ .Nd kernel disk storage API .Sh SYNOPSIS .In geom/geom_disk.h -.Ft struct *disk +.Ft struct disk * .Fn disk_alloc void .Ft void .Fn disk_create "struct disk *disk" "int version" @@ -94,8 +94,10 @@ (maintained by device driver), .Dv DISKFLAG_OPEN (maintained by storage framework), -and .Dv DISKFLAG_CANDELETE +(maintained by device driver), +and +.Dv DISKFLAG_CANFLUSHCACHE (maintained by device driver). .It Vt "const char *" Va d_name Holds the name of the storage device class, e.g., @@ -170,6 +172,8 @@ Please see .Pa src/sys/geom/notes for details. +.It Vt char Va d_ident[DISK_IDENT_SIZE] +This field can and should be used to store disk's serial number. .El .Ss Driver Private Data This field may be used by the device driver to store a pointer to Index: VFS_ROOT.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_ROOT.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_ROOT.9 -L share/man/man9/VFS_ROOT.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_ROOT.9 +++ share/man/man9/VFS_ROOT.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_ROOT.9,v 1.10 2004/07/12 09:06:51 alfred Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_ROOT.9,v 1.12 2006/09/18 15:24:20 ru Exp $ .\" -.Dd July 24, 1996 +.Dd August 26, 2006 .Os .Dt VFS_ROOT 9 .Sh NAME @@ -39,14 +39,23 @@ .In sys/mount.h .In sys/vnode.h .Ft int -.Fn VFS_ROOT "struct mount *mp" "struct vnode **vpp" "struct thread *td" +.Fn VFS_ROOT "struct mount *mp" "int flags" "struct vnode **vpp" "struct thread *td" .Sh DESCRIPTION Return a locked vnode for the root directory of the file system. .Pp Its arguments are: -.Bl -tag -width vpp +.Bl -tag -width flags .It Fa mp The file system. +.It Fa flags +The lock type. +Could be +.Dv LK_EXCLUSIVE +or +.Dv LK_SHARED . +File system is free to ignore the +.Fa flags +argument and instead acquire an exclusive lock. .It Fa vpp Return parameter for the root vnode. .It Fa td Index: pci.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pci.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pci.9 -L share/man/man9/pci.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pci.9 +++ share/man/man9/pci.9 @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pci.9,v 1.9 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/pci.9,v 1.10 2007/09/30 11:05:13 marius Exp $ .\" -.Dd January 22, 2005 +.Dd September 30, 2007 .Dt PCI 9 .Os .Sh NAME @@ -39,6 +39,7 @@ .Nm pci_set_powerstate , .Nm pci_get_powerstate , .Nm pci_find_bsf , +.Nm pci_find_dbsf , .Nm pci_find_device .Nd PCI bus interface .Sh SYNOPSIS @@ -65,6 +66,8 @@ .Ft device_t .Fn pci_find_bsf "uint8_t bus" "uint8_t slot" "uint8_t func" .Ft device_t +.Fn pci_find_dbsf "uint32_t domain" "uint8_t bus" "uint8_t slot" "uint8_t func" +.Ft device_t .Fn pci_find_device "uint16_t vendor" "uint16_t device" .Sh DESCRIPTION The @@ -198,6 +201,30 @@ number actually refers to the number of the device on the bus, which does not necessarily indicate its geographic location in terms of a physical slot. +Note that in case the system has multiple PCI domains, +the +.Fn pci_find_bsf +function only searches the first one. +Actually, it is equivalent to: +.Bd -literal -offset indent +pci_find_dbsf(0, bus, slot, func); +.Ed +.Pp +The +.Fn pci_find_dbsf +function looks up the +.Vt device_t +of a PCI device, given its +.Fa domain , +.Fa bus , +.Fa slot , +and +.Fa func . +The +.Fa slot +number actually refers to the number of the device on the bus, +which does not necessarily indicate its geographic location +in terms of a physical slot. .Pp The .Fn pci_find_device --- /dev/null +++ share/man/man9/rwlock.9 @@ -0,0 +1,286 @@ +.\" Copyright (c) 2006 Gleb Smirnoff +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/rwlock.9,v 1.10.2.1 2007/11/27 14:08:14 attilio Exp $ +.\" +.Dd November 25, 2007 +.Dt RWLOCK 9 +.Os +.Sh NAME +.Nm rwlock , +.Nm rw_init , +.Nm rw_init_flags, +.Nm rw_destroy , +.Nm rw_rlock , +.Nm rw_wlock , +.Nm rw_runlock , +.Nm rw_wunlock , +.Nm rw_try_upgrade , +.Nm rw_downgrade , +.Nm rw_sleep , +.Nm rw_initialized , +.Nm rw_wowned , +.Nm rw_assert , +.Nm RW_SYSINIT +.Nd kernel reader/writer lock +.Sh SYNOPSIS +.In sys/param.h +.In sys/lock.h +.In sys/rwlock.h +.Ft void +.Fn rw_init "struct rwlock *rw" "const char *name" +.Ft void +.Fn rw_init_flags "struct rwlock *rw" "const char *name" "int opts" +.Ft void +.Fn rw_destroy "struct rwlock *rw" +.Ft void +.Fn rw_rlock "struct rwlock *rw" +.Ft void +.Fn rw_wlock "struct rwlock *rw" +.Ft void +.Fn rw_runlock "struct rwlock *rw" +.Ft void +.Fn rw_wunlock "struct rwlock *rw" +.Ft int +.Fn rw_try_upgrade "struct rwlock *rw" +.Ft void +.Fn rw_downgrade "struct rwlock *rw" +.Ft int +.Fn rw_sleep "void *chan" "struct rwlock *rw" "int priority" "const char *wmesg" "int timo" +.Ft int +.Fn rw_initialized "struct rwlock *rw" +.Ft int +.Fn rw_wowned "struct rwlock *rw" +.Pp +.Cd "options INVARIANTS" +.Cd "options INVARIANT_SUPPORT" +.Ft void +.Fn rw_assert "struct rwlock *rw" "int what" +.In sys/kernel.h +.Fn RW_SYSINIT "name" "struct rwlock *rw" "const char *desc" +.Sh DESCRIPTION +Reader/writer locks allow shared access to protected data by multiple threads, +or exclusive access by a single thread. +The threads with shared access are known as +.Em readers +since they only read the protected data. +A thread with exclusive access is known as a +.Em writer +since it can modify protected data. +.Pp +Although reader/writer locks look very similar to +.Xr sx 9 +locks, their usage pattern is different. +Reader/writer locks can be treated as mutexes (see +.Xr mutex 9 ) +with shared/exclusive semantics. +Unlike +.Xr sx 9 , +an +.Nm +can be locked while holding a non-spin mutex, and an +.Nm +cannot be held while sleeping. +The +.Nm +locks have priority propagation like mutexes, but priority +can be propagated only to an exclusive holder. +This limitation comes from the fact that shared owners +are anonymous. +Another important property is that shared holders of +.Nm +can recurse, +and exclusive locks can be made recursive selectively. +.Ss Macros and Functions +.Bl -tag -width indent +.It Fn rw_init "struct rwlock *rw" "const char *name" +Initialize structure located at +.Fa rw +as reader/writer lock, described by name +.Fa name . +The description is used solely for debugging purposes. +This function must be called before any other operations +on the lock. +.It Fn rw_init_flags "struct rwlock *rw" "const char *name" "int opts" +Initialize the rw lock just like the +.Fn rw_init +function, but specifying a set of optional flags to alter the +behaviour of +.Fa rw , +through the +.Fa opts +argument. +It contains one or more of the following flags: +.Bl -tag -width ".Dv RW_NOPROFILE" +.It Dv RW_DUPOK +Witness should not log messages about duplicate locks being acquired. +.It Dv RW_NOPROFILE +Do not profile this lock. +.It Dv RW_NOWITNESS +Instruct +.Xr witness 4 +to ignore this lock. +.It Dv RW_QUIET +Do not log any operations for this lock via +.Xr ktr 4 . +.It Dv RW_RECURSE +Allow threads to recursively acquire exclusive locks for +.Fa rw . +.It Fn rw_rlock "struct rwlock *rw" +Lock +.Fa rw +as a reader. +If any thread holds this lock exclusively, the current thread blocks, +and its priority is propagated to the exclusive holder. +The +.Fn rw_rlock +function can be called when the thread has already acquired reader +access on +.Fa rw . +This is called +.Dq "recursing on a lock" . +.It Fn rw_wlock "struct rwlock *rw" +Lock +.Fa rw +as a writer. +If there are any shared owners of the lock, the current thread blocks. +The +.Fn rw_wlock +function can be called recursively only if +.Fa rw +has been initialized with the +.Dv RW_RECURSE +option enabled. +.It Fn rw_runlock "struct rwlock *rw" +This function releases a shared lock previously acquired by +.Fn rw_rlock . +.It Fn rw_wunlock "struct rwlock *rw" +This function releases an exclusive lock previously acquired by +.Fn rw_wlock . +.It Fn rw_try_upgrade "struct rwlock *rw" +Attempt to upgrade a single shared lock to an exclusive lock. +The current thread must hold a shared lock of +.Fa rw . +This will only succeed if the current thread holds the only shared lock on +.Fa rw , +and it only holds a single shared lock. +If the attempt succeeds +.Fn rw_try_upgrade +will return a non-zero value, +and the current thread will hold an exclusive lock. +If the attempt fails +.Fn rw_try_upgrade +will return zero, +and the current thread will still hold a shared lock. +.It Fn rw_downgrade "struct rwlock *rw" +Convert an exclusive lock into a single shared lock. +The current thread must hold an exclusive lock of +.Fa rw . +.It Fn rw_sleep "void *chan" "struct rwlock *rw" "int priority" "const char *wmesg" "int timo" +Atomically release +.Fa rw +while waiting for an event. +For more details on the parameters to this function, +see +.Xr sleep 9 . +.It Fn rw_initialized "struct rwlock *rw" +This function returns non-zero if +.Fa rw +has been initialized, and zero otherwise. +.It Fn rw_destroy "struct rwlock *rw" +This functions destroys a lock previously initialized with +.Fn rw_init . +The +.Fa rw +lock must be unlocked. +.It Fn rw_wowned "struct rwlock *rw" +This function returns a non-zero value if the current thread owns an +exclusive lock on +.Fa rw . +.It Fn rw_assert "struct rwlock *rw" "int what" +This function allows assertions specified in +.Fa what +to be made about +.Fa rw . +If the assertions are not true and the kernel is compiled +with +.Cd "options INVARIANTS" +and +.Cd "options INVARIANT_SUPPORT" , +the kernel will panic. +Currently the following assertions are supported: +.Bl -tag -width ".Dv RA_UNLOCKED" +.It Dv RA_LOCKED +Assert that current thread holds either a shared or exclusive lock +of +.Fa rw . +.It Dv RA_RLOCKED +Assert that current thread holds a shared lock of +.Fa rw . +.It Dv RA_WLOCKED +Assert that current thread holds an exclusive lock of +.Fa rw . +.It Dv RA_UNLOCKED +Assert that current thread holds neither a shared nor exclusive lock of +.Fa rw . +.El +.El +.Sh SEE ALSO +.Xr locking 9 , +.Xr mutex 9 , +.Xr panic 9 , +.Xr sema 9 , +.Xr sx 9 +.Sh HISTORY +These +functions appeared in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm +facility was written by +.An "John Baldwin" . +This manual page was written by +.An "Gleb Smirnoff" . +.Sh BUGS +If +.Dv WITNESS +is not included in the kernel, +then it is impossible to assert that the current thread does or does not +hold a read lock. +In the +.Pf non- Dv WITNESS +case, the +.Dv RA_LOCKED +and +.Dv RA_RLOCKED +assertions merely check that some thread holds a read lock. +.Pp +Reader/writer is a bit of an awkward name. +An +.Nm +can also be called a +.Dq Robert Watson +lock if desired. Index: vm_page_wire.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_wire.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_wire.9 -L share/man/man9/vm_page_wire.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_wire.9 +++ share/man/man9/vm_page_wire.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_wire.9,v 1.3 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_WIRE 9 --- /dev/null +++ share/man/man9/usbdi.9 @@ -0,0 +1,1253 @@ +.\" +.\" Copyright (c) 2005 Ian Dowse +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/usbdi.9,v 1.2 2006/12/14 14:33:13 mpp Exp $ +.Dd December 30, 2005 +.Os +.Dt USBDI 9 +.Sh NAME +.Nm usb_detach_wait , +.Nm usb_detach_wakeup , +.Nm usb_find_desc , +.Nm usbd_abort_default_pipe , +.Nm usbd_abort_pipe , +.Nm usbd_alloc_buffer , +.Nm usbd_alloc_xfer , +.Nm usbd_bulk_transfer , +.Nm usbd_clear_endpoint_stall , +.Nm usbd_clear_endpoint_stall_async , +.Nm usbd_clear_endpoint_toggle , +.Nm usbd_close_pipe , +.Nm usbd_device2interface_handle , +.Nm usbd_devinfo , +.Nm usbd_do_request , +.Nm usbd_do_request_async , +.Nm usbd_do_request_flags , +.Nm usbd_do_request_flags_pipe , +.Nm usbd_dopoll , +.Nm usbd_endpoint_count , +.Nm usbd_errstr , +.Nm usbd_fill_deviceinfo , +.Nm usbd_find_edesc , +.Nm usbd_find_idesc , +.Nm usbd_free_buffer , +.Nm usbd_free_xfer , +.Nm usbd_get_buffer , +.Nm usbd_get_config , +.Nm usbd_get_config_desc , +.Nm usbd_get_config_desc_full , +.Nm usbd_get_config_descriptor , +.Nm usbd_get_device_descriptor , +.Nm usbd_get_endpoint_descriptor , +.Nm usbd_get_interface_altindex , +.Nm usbd_get_interface_descriptor , +.Nm usbd_get_no_alts , +.Nm usbd_get_quirks , +.Nm usbd_get_speed , +.Nm usbd_get_string , +.Nm usbd_get_string_desc , +.Nm usbd_get_xfer_status , +.Nm usbd_interface2device_handle , +.Nm usbd_interface2endpoint_descriptor , +.Nm usbd_interface_count , +.Nm usbd_intr_transfer , +.Nm usbd_open_pipe , +.Nm usbd_open_pipe_intr , +.Nm usbd_pipe2device_handle , +.Nm usbd_ratecheck , +.Nm usbd_set_config_index , +.Nm usbd_set_config_no , +.Nm usbd_set_interface , +.Nm usbd_set_polling , +.Nm usbd_setup_default_xfer , +.Nm usbd_setup_isoc_xfer , +.Nm usbd_setup_xfer , +.Nm usbd_sync_transfer , +.Nm usbd_transfer +.Nd Universal Serial Bus driver programming interface +.Sh SYNOPSIS +.In dev/usb/usb.h +.In dev/usb/usbdi.h +.In dev/usb/usbdi_util.h +.Pp +.Ft void +.Fn usb_detach_wait "device_ptr_t dv" +.Ft void +.Fn usb_detach_wakeup "device_ptr_t dv" +.Ft "const usb_descriptor_t *" +.Fn usb_find_desc "usbd_device_handle dev" "int type" "int subtype" +.Ft usbd_status +.Fn usbd_abort_default_pipe "usbd_device_handle dev" +.Ft usbd_status +.Fn usbd_abort_pipe "usbd_pipe_handle pipe" +.Ft "void *" +.Fn usbd_alloc_buffer "usbd_xfer_handle xfer" "u_int32_t size" +.Ft usbd_xfer_handle +.Fn usbd_alloc_xfer "usbd_device_handle dev" +.Ft usbd_status +.Fo usbd_bulk_transfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "u_int16_t flags" +.Fa "u_int32_t timeout" +.Fa "void *buf" +.Fa "u_int32_t *size" +.Fa "char *lbl" +.Fc +.Ft usbd_status +.Fn usbd_clear_endpoint_stall "usbd_pipe_handle pipe" +.Ft usbd_status +.Fn usbd_clear_endpoint_stall_async "usbd_pipe_handle" +.Ft void +.Fn usbd_clear_endpoint_toggle "usbd_pipe_handle pipe" +.Ft usbd_status +.Fn usbd_close_pipe "usbd_pipe_handle pipe" +.Ft usbd_status +.Fo usbd_device2interface_handle +.Fa "usbd_device_handle dev" +.Fa "u_int8_t ifaceno" +.Fa "usbd_interface_handle *iface" +.Fc +.Ft void +.Fn usbd_devinfo "usbd_device_handle dev" "int showclass" "char *cp" +.Ft usbd_status +.Fo usbd_do_request +.Fa "usbd_device_handle dev" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fc +.Ft usbd_status +.Fo usbd_do_request_async +.Fa "usbd_device_handle dev" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fc +.Ft usbd_status +.Fo usbd_do_request_flags +.Fa "usbd_device_handle dev" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fa "u_int16_t flags" +.Fa "int *actlen" +.Fa "u_int32_t timo" +.Fc +.Ft usbd_status +.Fo usbd_do_request_flags_pipe +.Fa "usbd_device_handle dev" +.Fa "usbd_pipe_handle pipe" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fa "u_int16_t flags" +.Fa "int *actlen" +.Fa "u_int32_t timeout" +.Fc +.Ft void +.Fn usbd_dopoll "usbd_interface_handle iface" +.Ft usbd_status +.Fn usbd_endpoint_count "usbd_interface_handle iface" "u_int8_t *count" +.Ft "const char *" +.Fn usbd_errstr "usbd_status err" +.Ft void +.Fo usbd_fill_deviceinfo +.Fa "usbd_device_handle dev" +.Fa "struct usb_device_info *di" +.Fa "int usedev" +.Fc +.Ft "usb_endpoint_descriptor_t *" +.Fo usbd_find_edesc +.Fa "usb_config_descriptor_t *cd" +.Fa "int ifaceidx" +.Fa "int altidx" +.Fa "int endptidx" +.Fc +.Ft "usb_interface_descriptor_t *" +.Fn usbd_find_idesc "usb_config_descriptor_t *cd" "int ifaceidx" "int altidx" +.Ft void +.Fn usbd_free_buffer "usbd_xfer_handle xfer" +.Ft usbd_status +.Fn usbd_free_xfer "usbd_xfer_handle xfer" +.Ft "void *" +.Fn usbd_get_buffer "usbd_xfer_handle xfer" +.Ft usbd_status +.Fn usbd_get_config "usbd_device_handle dev" "u_int8_t *conf" +.Ft usbd_status +.Fo usbd_get_config_desc +.Fa "usbd_device_handle dev" +.Fa "int confidx" +.Fa "usb_config_descriptor_t *d" +.Fc +.Ft usbd_status +.Fo usbd_get_config_desc_full +.Fa "usbd_device_handle dev" +.Fa "int conf" +.Fa "void *d" +.Fa "int size" +.Fc +.Ft "usb_config_descriptor_t *" +.Fn usbd_get_config_descriptor "usbd_device_handle dev" +.Ft "usb_device_descriptor_t *" +.Fn usbd_get_device_descriptor "usbd_device_handle dev" +.Ft "usb_endpoint_descriptor_t *" +.Fo usbd_get_endpoint_descriptor +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t address" +.Fc +.Ft int +.Fn usbd_get_interface_altindex "usbd_interface_handle iface" +.Ft "usb_interface_descriptor_t *" +.Fn usbd_get_interface_descriptor "usbd_interface_handle iface" +.Ft int +.Fn usbd_get_no_alts "usb_config_descriptor_t *cdesc" "int ifaceno" +.Ft "const struct usbd_quirks *" +.Fn usbd_get_quirks "usbd_device_handle dev" +.Ft int +.Fn usbd_get_speed "usbd_device_handle dev" +.Ft usbd_status +.Fn usbd_get_string "usbd_device_handle dev" "int si" "char *buf" +.Ft usbd_status +.Fo usbd_get_string_desc +.Fa "usbd_device_handle dev" +.Fa "int sindex" +.Fa "int langid" +.Fa "usb_string_descriptor_t *sdesc" +.Fa "int *sizep" +.Fc +.Ft void +.Fo usbd_get_xfer_status +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_private_handle *priv" +.Fa "void **buffer" +.Fa "u_int32_t *count" +.Fa "usbd_status *status" +.Fc +.Ft void +.Fo usbd_interface2device_handle +.Fa "usbd_interface_handle iface" +.Fa "usbd_device_handle *dev" +.Fc +.Ft "usb_endpoint_descriptor_t *" +.Fo usbd_interface2endpoint_descriptor +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t index" +.Fc +.Ft usbd_status +.Fn usbd_interface_count "usbd_device_handle dev" "u_int8_t *count" +.Ft usbd_status +.Fo usbd_intr_transfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "u_int16_t flags" +.Fa "u_int32_t timeout" +.Fa "void *buf" +.Fa "u_int32_t *size" +.Fa "char *lbl" +.Fc +.Ft usbd_status +.Fo usbd_open_pipe +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t address" +.Fa "u_int8_t flags" +.Fa "usbd_pipe_handle *pipe" +.Fc +.Ft usbd_status +.Fo usbd_open_pipe_intr +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t address" +.Fa "u_int8_t flags" +.Fa "usbd_pipe_handle *pipe" +.Fa "usbd_private_handle priv" +.Fa "void *buffer" +.Fa "u_int32_t len" +.Fa "usbd_callback cb" +.Fa "int ival" +.Fc +.Ft usbd_device_handle +.Fn usbd_pipe2device_handle "usbd_pipe_handle pipe" +.Ft int +.Fn usbd_ratecheck "struct timeval *last" +.Ft usbd_status +.Fn usbd_set_config_index "usbd_device_handle dev" "int index" "int msg" +.Ft usbd_status +.Fn usbd_set_config_no "usbd_device_handle dev" "int no" "int msg" +.Ft usbd_status +.Fn usbd_set_interface "usbd_interface_handle iface" "int altidx" +.Ft void +.Fn usbd_set_polling "usbd_device_handle dev" "int on" +.Ft void +.Fo usbd_setup_default_xfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_device_handle dev" +.Fa "usbd_private_handle priv" +.Fa "u_int32_t timeout" +.Fa "usb_device_request_t *req" +.Fa "void *buffer" +.Fa "u_int32_t length" +.Fa "u_int16_t flags" +.Fa "usbd_callback callback" +.Fc +.Ft void +.Fo usbd_setup_isoc_xfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "usbd_private_handle priv" +.Fa "u_int16_t *frlengths" +.Fa "u_int32_t nframes" +.Fa "u_int16_t flags" +.Fa "usbd_callback callback" +.Fc +.Ft void +.Fo usbd_setup_xfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "usbd_private_handle priv" +.Fa "void *buffer" +.Fa "u_int32_t length" +.Fa "u_int16_t flags" +.Fa "u_int32_t timeout" +.Fa "usbd_callback callback" +.Fc +.Ft usbd_status +.Fn usbd_sync_transfer "usbd_xfer_handle xfer" +.Ft usbd_status +.Fn usbd_transfer "usbd_xfer_handle xfer" +.Sh DESCRIPTION +The Universal Serial Bus (USB) driver programming interface provides +USB peripheral drivers with a host controller independent API for +controlling and communicating with USB peripherals. +.Pp +Typically, drivers will first use some combination of the functions +.Fn usbd_set_config_no , +.Fn usbd_get_config_descriptor , +.Fn usbd_set_interface , +.Fn usbd_get_interface_descriptor , +.Fn usbd_device2interface_handle , +.Fn usbd_endpoint_count +and +.Fn usbd_interface2endpoint_descriptor +to query the device's properties and prepare it for use. +Drivers can then perform requests on the USB control pipe using +.Fn usbd_do_request , +they can open pipes using the functions +.Fn usbd_open_pipe +and +.Fn usbd_open_pipe_intr , +and perform transfers over these pipes using +.Fn usbd_alloc_xfer , +.Fn usbd_setup_xfer +and +.Fn usbd_transfer . +Finally, the functions +.Fn usbd_abort_pipe , +.Fn usbd_close_pipe +and +.Fn usbd_free_xfer +are used to cancel outstanding transfers, close open pipes and deallocate +transfer structures. +.Pp +The +.Fn usbd_get_device_descriptor +function returns a pointer to the USB device descriptor for +.Fa dev . +See +.Sx "USB Descriptors" +below for information about the USB device descriptor. +.Pp +The +.Fn usbd_get_config_desc +function retrieves the specified configuration descriptor from the device. +The +.Fa confidx +parameter specifies the configuration descriptor index, which must be less +than the +.Fa bNumConfigurations +value in the device descriptor. +The function +.Fn usbd_get_config_desc_full +retrieves a full configuration descriptor, which has all related interface +and endpoint descriptors appended to a normal configuration descriptor. +The parameter +.Fa d +should point to memory that is at least +.Fa size +bytes in length, and this should be at least as long as the +.Fa wTotalLength +value from the configuration descriptor. +See +.Sx "USB Descriptors" +below for information about the USB configuration descriptor. +.Pp +The +.Fn usbd_get_config +function retrieves the current configuration number from the device, i.e.\& +the +.Fa bConfigurationValue +value from the configuration that is active. +If the device is unconfigured then +.Dv USB_UNCONFIG_NO +is returned. +The current configuration can be changed by calling either +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +The difference between these functions is that +.Fn usbd_set_config_index +accepts a configuration index number that is less than the +.Fa bNumConfigurations +value from the device descriptor, whereas +.Fn usbd_set_config_no +requires the +.Fa bConfigurationValue +value of the desired configuration to be provided instead. +To unconfigure the device, supply a configuration index of +.Dv USB_UNCONFIG_INDEX +to +.Fn usbd_set_config_index , +or else specify a configuration number of +.Dv USB_UNCONFIG_NO +to +.Fn usbd_set_config_no . +.Pp +The +.Fn usbd_get_config_descriptor +function returns a pointer to an in-memory copy of the full configuration +descriptor of the configuration that is currently active. +The returned pointer remains valid until the device configuration +is changed using +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +If the device is unconfigured then +.Dv NULL +is returned instead. +.Pp +The function +.Fn usbd_interface_count +returns the number of interfaces available in the current device +configuration. +The +.Fn usbd_get_no_alts +function determines the number of alternate interfaces in a full +configuration descriptor by counting the interface descriptors with +.Fa bInterfaceNumber +equal to +.Fa ifaceno +(the count includes alternate index zero). +The +.Fn usbd_find_idesc +function locates an interface descriptor within a full configuration +descriptor. +The +.Fa ifaceidx +parameter specifies the interface index number, which should be less than +the number of interfaces in the configuration descriptor (i.e.\& the value +returned by +.Fn usbd_interface_count +or the +.Fa bNumInterface +field from the configuration descriptor). +An alternate interface can be specified using a non-zero +.Fa altidx , +which should be less than the value returned by +.Fn usbd_get_no_alts . +The return value is a pointer to the requested interface descriptor +within the full configuration descriptor, or +.Dv NULL +if the specified interface descriptor does not exist. +Note that the +.Fa altidx +parameter specifies the alternate setting by index number starting +at zero; it is not the alternate setting number defined in the +interface descriptor. +.Pp +The function +.Fn usbd_find_edesc +locates an endpoint descriptor within a full configuration descriptor. +The +.Fa ifaceidx +and +.Fa altidx +parameters are the same as described for +.Fn usbd_find_idesc , +and the +.Fa endptidx +parameter is an endpoint index number that should be less than the +.Fa bNumEndpoints +field in the interface descriptor. +The return value is a pointer to the requested endpoint descriptor +within the full configuration descriptor, or +.Dv NULL +if the specified endpoint descriptor does not exist. +Note that the +.Fa altidx +and +.Fa endptidx +parameters are index numbers starting at zero; they are not the +alternate setting and endpoint address defined in the descriptors. +.Pp +The +.Fn usbd_get_speed +function returns the device speed. +This can be +.Dv USB_SPEED_LOW , +.Dv USB_SPEED_FULL +or +.Dv USB_SPEED_HIGH . +.Pp +USB devices optionally support string descriptors, which can be +retrieved using the +.Fn usbd_get_string +or +.Fn usbd_get_string_desc +functions. +Device, configuration and interface descriptors reference strings by +an index number that can be supplied to these functions. +The +.Fn usbd_get_string +function should be used unless a non-default language is required. +It requires that +.Fa buf +points to a buffer of at least +.Dv USB_MAX_STRING_LEN +bytes in size. +The +.Fa si +parameter specified which string to retrieve. +.Pp +The +.Fn usb_find_desc +function searches through the in-memory full configuration descriptor +for the active configuration and finds the first descriptor that has a +.Fa bDescriptorType +equal to +.Fa type , +and if +.Fa subtype +is not equal to +.Dv USBD_SUBTYPE_ANY , +the descriptor must also have a +.Fa bDescriptorSubtype +equal to +.Fa subtype . +If found, then a pointer to the descriptor is returned. +Otherwise, +.Fn usb_find_desc +returns +.Dv NULL . +The returned pointer is valid until the device configuration is changed using +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +.Pp +The USB driver interface uses opaque interface handles to refer to +configuration interfaces. +These handles remain valid until the device configuration is changed using +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +The +.Fn usbd_device2interface_handle +function retrieves an interface handle. +The +.Fa ifaceno +parameter is an interface index number starting at zero. +If the device is configured and the specified interface exists, then +.Dv USBD_NORMAL_COMPLETION +is returned and the interface handle is stored in +.Fa *iface . +Otherwise an error code is returned and +.Fa *iface +is not changed. +The +.Fn usbd_interface2device_handle +function retrieves the device handle from an interface handle. +This is just for convenience to save passing around the device +handle as well as the interface handle. +The +.Fn usbd_set_interface +function changes the alternate setting number for an interface to +the alternate setting identified by the zero-based index number +.Fa altidx . +This operation invalidates any existing endpoints on this +interface and their descriptors. +The +.Fn usbd_get_interface_altindex +function returns the current alternative setting index as was +specified when calling +.Fn usbd_set_interface . +The +.Fn usbd_endpoint_count +function retrieves the number of endpoints associated with the +specified interface. +The +.Fn usbd_interface2endpoint_descriptor +function returns a pointer to an in-memory endpoint descriptor for +the endpoint that has an index number of +.Fa index . +This pointer remains valid until the configuration or alternate setting +number are changed. +The function +.Fn usbd_get_endpoint_descriptor +is like +.Fn usbd_interface2endpoint_descriptor +but it accepts a +.Fa bEndpointAddress +address value instead of an index. +.Pp +The +.Fn usbd_fill_deviceinfo +function fills out a +.Vt usb_device_info +structure with information about the device. +The vendor and product names come from the device itself, falling back to +a table lookup or just providing the IDs in hexadecimal. +If +.Fa usedev +is zero then +.Fn usbd_fill_deviceinfo +will not attempt to retrieve the vendor and product names from the +device. +The usb_device_info structure is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +struct usb_device_info { + u_int8_t udi_bus; + u_int8_t udi_addr; /* device address */ + usb_event_cookie_t udi_cookie; + char udi_product[USB_MAX_STRING_LEN]; + char udi_vendor[USB_MAX_STRING_LEN]; + char udi_release[8]; + u_int16_t udi_productNo; + u_int16_t udi_vendorNo; + u_int16_t udi_releaseNo; + u_int8_t udi_class; + u_int8_t udi_subclass; + u_int8_t udi_protocol; + u_int8_t udi_config; + u_int8_t udi_speed; +#define USB_SPEED_LOW 1 +#define USB_SPEED_FULL 2 +#define USB_SPEED_HIGH 3 + int udi_power; /* power consumption in mA */ + int udi_nports; + char udi_devnames[USB_MAX_DEVNAMES][USB_MAX_DEVNAMELEN]; + /* hub only: addresses of devices on ports */ + u_int8_t udi_ports[16]; +#define USB_PORT_ENABLED 0xff +#define USB_PORT_SUSPENDED 0xfe +#define USB_PORT_POWERED 0xfd +} +.Ed +.Pp +The +.Fn usbd_devinfo +function generates a string description of the USB device. +The +.Fa cp +argument should point to a 1024-byte buffer (XXX the maximum length +is approximately 320 chars, but there is no sanity checking and everything uses +1024-character buffers). +Device class information is included if the +.Fa showclass +parameter is non-zero. +.Pp +The +.Fn usbd_get_quirks +function returns information from a table of devices that require +special workarounds in order to function correctly. +The returned structure is defined in +.In dev/usb/usb_quirks.h +as follows: +.Bd -literal +struct usbd_quirks { + u_int32_t uq_flags; /* Device problems */ +}; +.Ed +.Pp +See +.In dev/usb/usb_quirks.h +for a list of all currently defined quirks. +.Pp +USB control requests are performed via +.Vt usb_device_request_t +structures, defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bmRequestType; + uByte bRequest; + uWord wValue; + uWord wIndex; + uWord wLength; +} UPACKED usb_device_request_t; +.Ed +.Pp +The +.Fn usbd_do_request +function performs a single request synchronously. +The +.Fa req +parameter should point to a properly initialized +.Vt usb_device_request_t , +and when the +.Fa wLength +field is non-zero, +.Fa data +should point at a buffer that is at least +.Fa wLength +bytes in length. +The request timeout is set to 5 seconds, so the operation will fail +with +.Er USBD_TIMEOUT +if the device does not respond within that time. +The +.Fn usbd_do_request_async +function is like +.Fn usbd_do_request , +but it does not wait for the request to complete before returning. +This routine does not block so it can be used from contexts where +sleeping is not allowed. +Note that there is no notification mechanism to report when the +operation completed nor is there a way to determine whether the +request succeeded, so this function is of limited use. +See +.Fn usbd_setup_default_xfer +and +.Fn usbd_transfer +for a way to invoke an asynchronous callback upon completion of +a control request. +The +.Fn usbd_do_request_flags +function is like +.Fn usbd_do_request , +but additional flags can be specified, the timeout is configurable, +and the actual number of bytes transferred is made available to the +caller. +The +.Fn usbd_do_request_flags_pipe +function uses a specified pipe instead of the default pipe. +.Pp +The function +.Fn usbd_open_pipe +creates a pipe connected to a specified endpoint on a specified interface. +The parameter +.Fa address +should be the +.Fa bEndpointAddress +value from one of this interface's endpoint descriptors. +If +.Fa flags +contains +.Dv USBD_EXCLUSIVE_USE +then the operation will only succeed if there are no open pipes +already connected to the specified endpoint. +The +.Fn usbd_open_pipe_intr +function creates an interrupt pipe connected to the specified endpoint. +The parameter +.Fa address +should be the +.Fa bEndpointAddress +value from one of this interface's endpoint descriptors. +The +.Fa flags +parameter is passed to +.Fn usbd_setup_xfer . +The +.Fa buffer +and +.Fa len +parameters define a buffer that is to be used for the interrupt transfers. +The callback to be invoked each time a transfer completes is specified by +.Fa cb , +and +.Fa priv +is an argument to be passed to the callback function. +The +.Fa ival +parameter specifies the maximum acceptable interval between transfers; +in practice the transfers may occur more frequently. +The function +.Fn usbd_pipe2device_handle +returns the device associated with the specified +.Fa pipe . +.Pp +The +.Fn usbd_abort_pipe +function aborts all active or waiting transfers on the specified pipe. +Each transfer is aborted with a +.Dv USBD_CANCELLED +status; callback routines must detect this error code to ensure that +they do not attempt to initiate a new transfer in response to one being +aborted. +This routine blocks while it is waiting for the hardware to complete +processing of aborted transfers, so it is only safe to call it in +contexts where sleeping is allowed. +The function +.Fn usbd_abort_default_pipe +aborts all active or waiting transfers on the default pipe. +Like +.Fn usbd_abort_pipe , +it blocks waiting for the hardware processing to complete. +.Pp +When a pipe has no active or waiting transfers, the pipe may be closed +using the +.Fn usbd_close_pipe +function. +Once a pipe is closed, its pipe handle becomes invalid and may no longer +be used. +.Pp +USB transfer handles are allocated using the function +.Fn usbd_alloc_xfer +and may be freed using +.Fn usbd_free_xfer . +.Pp +The function +.Fn usbd_setup_xfer +initializes a transfer handle with the details of a transfer to or from +a USB device. +The +.Fa xfer +parameter specifies the transfer handle to initialize, +.Fa pipe +specifies the pipe on which the transfer is to take place, and +.Fa priv +is an argument that will be passed to callback function. +The arguments +.Fa buffer +and +.Fa length +define the data buffer for the transfer. +If +.Fa length +is zero then the +.Fa buffer +may be +.Dv NULL . +The +.Fa flags +parameter may contain the following flags: +.Bl -tag -width ".Dv USBD_FORCE_SHORT_XFER" +.It Dv USBD_NO_COPY +This is used in association with +.Fn usbd_alloc_buffer +and +.Fn usbd_free_buffer +to use a dedicated DMA-capable buffer for the transfer. +.It Dv USBD_SYNCHRONOUS +Wait for the transfer to compete in +.Fn usbd_transfer . +.It Dv USBD_SHORT_XFER_OK +Permit transfers shorter than the requested data length. +.It Dv USBD_FORCE_SHORT_XFER +Force a short transfer at the end of a write operation to let the +device know that the transfer has ended. +.El +.Pp +The +.Fa timeout +parameter specifies a timeout for the transfer in milliseconds. +A value of +.Dv USBD_NO_TIMEOUT +indicates that no timeout should be configured. +The parameter +.Fa callback +specifies the function to call when the transfer completes. +Note that +.Fn usbd_setup_xfer +does not actually initiate the transfer. +The +.Fn usbd_setup_default_xfer +initializes a control transfer for the default pipe. +The +.Fa req +parameter should point at a completed +.Vt usb_device_request_t +structure. +The function +.Fa usbd_setup_isoc_xfer +initializes a transfer for an isochronous pipe. +.Pp +The function +.Fn usbd_transfer +initiates a transfer. +Normally it returns +.Dv USBD_IN_PROGRESS +to indicate that the transfer has been queued. +If the USB stack is operating in polling mode, or if the transfer +is synchronous, then +.Dv USBD_NORMAL_COMPLETION +may be returned. +Other return values indicate that the transfer could not be +initiated due to an error. +The +.Fn usbd_sync_transfer +function executes a transfer synchronously. +It will sleep waiting for the transfer to complete and then return +the transfer status. +Note that if the transfer has a callback routine, this will be +invoked before +.Fn usbd_sync_transfer +returns. +.Pp +The +.Fn usbd_intr_transfer +and +.Fn usbd_bulk_transfer +functions set up a transfer and wait synchronously for it to complete +but they allows signals to interrupt the wait. +They returns +.Dv USBD_INTERRUPTED +if the transfer was interrupted by a signal. +XXX these two functions are identical apart from their names. +.Pp +The function +.Fn usbd_get_xfer_status +retrieves various information from a completed transfer. +If the +.Fa priv +parameter is not NULL then the callback private argument is +stored in +.Fa *priv . +If +.Fa buffer +is not NULL then the transfer buffer pointer is stored in +.Fa *buffer . +The actual number of bytes transferred is stored in +.Fa *count +if +.Fa count is not NULL. +Finally, the transfer status is stored in +.Fa *status +if +.Fa status +is not NULL. +.Pp +The +.Fn usbd_clear_endpoint_stall +function clears an endpoint stall condition synchronously, i.e.\& +it sleeps waiting for the stall clear request to complete. +The function +.Fn usbd_clear_endpoint_stall_async +performs the same function asynchronously, but it provides no +way to determine when the request completed, or whether it was +successful. +The +.Fn usbd_clear_endpoint_toggle +function instructs the host controller driver to reset the toggle bit +on a pipe. +This is used when manually clearing an endpoint stall using a +control pipe request, in order to ensure that the host controller +driver and the USB device restart with the same toggle value. +.Pp +Normally the USB subsystem maps and copies data to and from +DMA-capable memory each time a transfer is performed. +The function +.Fn usbd_alloc_buffer +allocates a permanent DMA-capable buffer associated with the +transfer to avoid this overhead. +The return value is the virtual address of the buffer. +Any time that +.Fn usbd_setup_xfer +is called on the transfer with the +.Dv USBD_NO_COPY +flag enabled, the allocated buffer will be used directly and +the +.Fa buffer +argument passed to +.Fn usbd_setup_xfer +will be ignored. +The +.Fn usbd_get_buffer +function returns a pointer to the virtual address of a buffer previously +allocated by +.Fn usbd_alloc_buffer . +Finally, +.Fn usbd_free_buffer +deallocates the buffer. +.Pp +The +.Fn usbd_errstr +function converts a status code into a string for display. +.Pp +The function +.Fn usbd_set_polling +enables or disables polling mode. +In polling mode, all operations will busy-wait for the device to +respond, so its use is effectively limited to boot time and kernel +debuggers. +It is important to match up calls that enable and disable polling +mode, because the implementation just increments a polling reference +count when +.Fa on +is non-zero and decrements it when +.Fa on +is zero. +The +.Fn usbd_dopoll +causes the host controller driver to poll for any activity. +This should only be used when polling mode is enabled. +.Pp +The +.Fn usbd_ratecheck +function is used to limit the rate at which error messages are +printed to approximately once per second. +The +.Fa last +argument should point at a persistent +.Vt "struct timeval" . +A value of 1 will be returned if a message should be printed, but if +.Fn usbd_ratecheck +has already been called with the same +.Vt "struct timeval" +parameter in the last second then 0 is returned and the error message +should be suppressed. +.Pp +The functions +.Fn usb_detach_wait +and +.Fn usb_detach_wakeup +are used to wait for references to drain before completing the +detachment of a device. +The +.Fn usb_detach_wait +function will wait up to 60 seconds to receive a signal from +.Fn usb_detach_wait . +.Ss "USB Descriptors" +The USB specification defines a number of standard descriptors by +which USB devices report their attributes. +These descriptors are fixed-format structures that all USB devices +make available through USB control pipe requests. +.Pp +Every USB device has exactly one USB device descriptor. +The USB subsystem retrieves this automatically when a device is +attached, and a copy of the descriptor is kept in memory. +The +.Fn usbd_get_device_descriptor +function returns a pointer to the descriptor. +The device descriptor structure is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uWord bcdUSB; +#define UD_USB_2_0 0x0200 +#define UD_IS_USB2(d) (UGETW((d)->bcdUSB) >= UD_USB_2_0) + uByte bDeviceClass; + uByte bDeviceSubClass; + uByte bDeviceProtocol; + uByte bMaxPacketSize; + /* The fields below are not part of the initial descriptor. */ + uWord idVendor; + uWord idProduct; + uWord bcdDevice; + uByte iManufacturer; + uByte iProduct; + uByte iSerialNumber; + uByte bNumConfigurations; +} UPACKED usb_device_descriptor_t; +#define USB_DEVICE_DESCRIPTOR_SIZE 18 +.Ed +.Pp +USB devices have at least one configuration descriptor. +The +.Fa bNumConfigurations +field of the device descriptor specifies the number of configuration +descriptors that a device supports. +The +.Fn usbd_get_config_desc +function retrieves a particular configuration descriptor from the device +and the +.Fn usbd_get_config_desc_full +function retrieves a full +.Fa wTotalLength +length configuration descriptor, which includes all related interface +and endpoint descriptors. +Only one configuration may be active at a time. +The +.Fn usbd_set_config_index +function activates a specified configuration. +The configuration descriptor structure is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uWord wTotalLength; + uByte bNumInterface; + uByte bConfigurationValue; + uByte iConfiguration; + uByte bmAttributes; +#define UC_BUS_POWERED 0x80 +#define UC_SELF_POWERED 0x40 +#define UC_REMOTE_WAKEUP 0x20 + uByte bMaxPower; /* max current in 2 mA units */ +#define UC_POWER_FACTOR 2 +} UPACKED usb_config_descriptor_t; +#define USB_CONFIG_DESCRIPTOR_SIZE 9 +.Ed +.Pp +Each device configuration provides one or more interfaces. +The +.Fa bNumInterface +field of the configuration descriptor specifies the number of +interfaces associated with a device configuration. +Interfaces are described by an interface descriptor, which is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uByte bInterfaceNumber; + uByte bAlternateSetting; + uByte bNumEndpoints; + uByte bInterfaceClass; + uByte bInterfaceSubClass; + uByte bInterfaceProtocol; + uByte iInterface; +} UPACKED usb_interface_descriptor_t; +#define USB_INTERFACE_DESCRIPTOR_SIZE 9 +.Ed +.Pp +Configurations may also have alternate interfaces with the same +.Fa bInterfaceNumber +but different +.Fa bAlternateSetting +values. +These alternate interface settings may be selected by passing a +non-zero +.Fa altidx +parameter to +.Fn usbd_set_interface . +.Pp +Interfaces have zero or more endpoints, and each endpoint has an +endpoint descriptor. +Note that endpoint zero, which is always present, does not have an +endpoint descriptor, and it is never included in the +.Fa bNumEndpoints +count of endpoints. +The endpoint descriptor is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uByte bEndpointAddress; +#define UE_GET_DIR(a) ((a) & 0x80) +#define UE_SET_DIR(a,d) ((a) | (((d)&1) << 7)) +#define UE_DIR_IN 0x80 +#define UE_DIR_OUT 0x00 +#define UE_ADDR 0x0f +#define UE_GET_ADDR(a) ((a) & UE_ADDR) + uByte bmAttributes; +#define UE_XFERTYPE 0x03 +#define UE_CONTROL 0x00 +#define UE_ISOCHRONOUS 0x01 +#define UE_BULK 0x02 +#define UE_INTERRUPT 0x03 +#define UE_GET_XFERTYPE(a) ((a) & UE_XFERTYPE) +#define UE_ISO_TYPE 0x0c +#define UE_ISO_ASYNC 0x04 +#define UE_ISO_ADAPT 0x08 +#define UE_ISO_SYNC 0x0c +#define UE_GET_ISO_TYPE(a) ((a) & UE_ISO_TYPE) + uWord wMaxPacketSize; + uByte bInterval; +} UPACKED usb_endpoint_descriptor_t; +#define USB_ENDPOINT_DESCRIPTOR_SIZE 7 +.Ed +.Sh RETURN VALUES +Many functions return a +.Vt usbd_status +type to indicate the outcome of the operation. +If the operation completed successfully then +.Dv USBD_NORMAL_COMPLETION +is returned. +Operations that have been started but not yet completed will return +.Dv USBD_IN_PROGRESS . +Other errors usually indicate a problem. +Error codes can be converted to strings using +.Fn usbd_errstr . +.Sh ERRORS +.Bl -tag -width ".Er USBD_PENDING_REQUESTS" +.It Bq Er USBD_PENDING_REQUESTS +A pipe could not be closed because there are active requests. +.It Bq Er USBD_NOT_STARTED +The transfer has not yet been started. +.It Bq Er USBD_INVAL +An invalid value was supplied. +.It Bq Er USBD_NOMEM +An attempt to allocate memory failed. +.It Bq Er USBD_CANCELLED +The transfer was aborted. +.It Bq Er USBD_BAD_ADDRESS +The specified endpoint address was not found. +.It Bq Er USBD_IN_USE +The endpoint is already in use, or the configuration cannot be changed +because some of its endpoints are in use. +.It Bq Er USBD_NO_ADDR +No free USB devices addresses were found to assign to the device. +.It Bq Er USBD_SET_ADDR_FAILED +The device address could not be set. +.It Bq Er USBD_NO_POWER +Insufficient power was available for the device. +.It Bq Er USBD_TOO_DEEP +Too many levels of chained hubs were found. +.It Bq Er USBD_IOERROR +There was an error communicating with the device. +.It Bq Er USBD_NOT_CONFIGURED +An operation that requires an active configuration was attempted while +the device was in an unconfigured state. +.It Bq Er USBD_TIMEOUT +A transfer timed out. +.It Bq Er USBD_SHORT_XFER +A transfer that disallowed short data lengths completed with less than +the requested length transferred. +.It Bq Er USBD_STALLED +A transfer failed because the pipe is stalled. +.It Bq Er USBD_INTERRUPTED +An interruptible operation caught a signal. +.El +.Sh SEE ALSO +.Xr usb 4 +.Sh HISTORY +The USB driver interface first appeared in +.Fx 3.0 . +.Sh AUTHORS +The USB driver was written by +.An Lennart Augustsson +for the +.Nx +project. +.Pp +.An -nosplit +This manual page was written by +.An Ian Dowse Aq iedowse at FreeBSD.org . Index: timeout.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/timeout.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/timeout.9 -L share/man/man9/timeout.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/timeout.9 +++ share/man/man9/timeout.9 @@ -34,7 +34,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/timeout.9,v 1.28.2.2 2005/12/05 20:07:33 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/timeout.9,v 1.31 2005/12/01 19:16:35 jhb Exp $ .\" .Dd September 8, 2005 .Dt TIMEOUT 9 --- /dev/null +++ share/man/man9/config_intrhook.9 @@ -0,0 +1,105 @@ +.\" +.\" Copyright (C) 2006 M. Warner Losh . All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/config_intrhook.9,v 1.4 2006/12/14 14:33:13 mpp Exp $ +.\" +.Dd September 24, 2006 +.Dt CONFIG_INTRHOOK 9 +.Os +.Sh NAME +.Nm config_intrhook +.Nd schedule a function to be run after interrupts have been enabled, +but before root is mounted +.Sh SYNOPSIS +.In sys/kernel.h +.Ft int +.Fn config_intrhook_establish "struct intr_config_hook *hook" +.Ft void +.Fn config_intrhook_disestablish "struct intr_config_hook *hook" +.Sh DESCRIPTION +The +.Fn config_intrhook_establish +function schedules a function to be run after interrupts have been +enabled, but before root is mounted. +If the system has already passed this point in its initialization, +the function is called immediately. +.Pp +The +.Fn config_intrhook_disestablish +function removes the entry from the hook queue. +.Pp +Before root is mounted, all the previously established hooks are +run. +The boot process is then stalled until all handlers remove their hook +from the hook queue with +.Fn config_intrhook_disestablish . +The boot process then proceeds to attempt to mount the root file +system. +Any driver that can potentially provide devices they wish to be +mounted as root must use either this hook, or probe all these devices +in the initial probe. +Since interrupts are disabled during the probe process, many drivers +need a method to probe for devices with interrupts enabled. +.Pp +The requests are made with the +.Vt intr_config_hook +structure. +This structure is defined as follows: +.Bd -literal +struct intr_config_hook { + TAILQ_ENTRY(intr_config_hook) ich_links;/* Private */ + void (*ich_func)(void *arg); /* function to call */ + void *ich_arg; /* Argument to call */ +}; +.Ed +.Pp +Storage for the +.Vt intr_config_hook +structure must be provided by the driver. +It must be stable from just before the hook is established until +after the hook is disestablished. +.Pp +Specifically, hooks are run at +.Fn SI_SUB_INT_CONFIG_HOOKS , +which is immediately after the scheduler is started, +and just before the root file system device is discovered. +.Sh RETURN VALUES +A zero return value means the hook was successfully added to the queue +(with either deferred or immediate execution). +A non-zero return value means the hook could not be added to the queue +because it was already on the queue. +.Sh SEE ALSO +.Xr DEVICE_ATTACH 9 +.Sh HISTORY +These functions were introduced in +.Fx 3.0 +with the CAM subsystem, but are available for any driver to use. +.Sh AUTHORS +.An -nosplit +The functions were written by +.An Justin Gibbs Aq gibbs at FreeBSD.org . +This manual page was written by +.An M. Warner Losh Aq imp at FreeBSD.org . Index: vrele.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vrele.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vrele.9 -L share/man/man9/vrele.9 -u -r1.2 -r1.3 --- share/man/man9/vrele.9 +++ share/man/man9/vrele.9 @@ -27,7 +27,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vrele.9,v 1.12 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 1996 .Os Index: BUS_SETUP_INTR.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/BUS_SETUP_INTR.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/BUS_SETUP_INTR.9 -L share/man/man9/BUS_SETUP_INTR.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/BUS_SETUP_INTR.9 +++ share/man/man9/BUS_SETUP_INTR.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/BUS_SETUP_INTR.9,v 1.18 2005/01/06 17:11:56 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/BUS_SETUP_INTR.9,v 1.20 2007/03/01 14:33:29 ru Exp $ .\" -.Dd January 6, 2005 +.Dd March 1, 2007 .Dt BUS_SETUP_INTR 9 .Os .Sh NAME @@ -37,11 +37,21 @@ .In sys/param.h .In sys/bus.h .Ft int -.Fn BUS_SETUP_INTR "device_t dev" "device_t child" "struct resource *irq" "int flags" "driver_intr_t *intr" "void *arg" "void **cookiep" +.Fo BUS_SETUP_INTR +.Fa "device_t dev" "device_t child" "struct resource *irq" "int flags" +.Fa "driver_filter_t *filter" "driver_intr_t *ithread" "void *arg" +.Fa "void **cookiep" +.Fc .Ft int -.Fn bus_setup_intr "device_t dev" "struct resource *r" "int flags" "driver_intr_t handler" "void *arg" "void **cookiep" +.Fo bus_setup_intr +.Fa "device_t dev" "struct resource *r" "int flags" +.Fa "driver_filter_t filter" "driver_intr_t ithread" "void *arg" +.Fa "void **cookiep" +.Fc .Ft int -.Fn BUS_TEARDOWN_INTR "device_t dev" "device_t child" "struct resource *irq" "void *cookiep" +.Fo BUS_TEARDOWN_INTR +.Fa "device_t dev" "device_t child" "struct resource *irq" "void *cookiep" +.Fc .Ft int .Fn bus_teardown_intr "device_t dev" "struct resource *r" "void *cookiep" .Sh DESCRIPTION @@ -61,11 +71,6 @@ .Fa flags also tell the interrupt handlers about certain device driver characteristics. -.Dv INTR_FAST -means the handler is for a timing-critical function. -Extra care is take to speed up these handlers. -Use of this implies -.Dv INTR_EXCL . .Dv INTR_EXCL marks the handler as being an exclusive handler for this interrupt. @@ -79,8 +84,16 @@ marks the interrupt as being a good source of entropy - this may be used by the entropy device .Pa /dev/random . -The handler -.Fa intr +.Pp +To define a time-critical handler (previously known as +.Dv INTR_FAST ) +that will not execute any potentially blocking operation, use the +.Fa filter +argument. +Otherwise, use the +.Fa ithread +argument. +The defined handler will be called with the value .Fa arg as its only argument. Index: thread_exit.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/thread_exit.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/thread_exit.9 -L share/man/man9/thread_exit.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/thread_exit.9 +++ share/man/man9/thread_exit.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/thread_exit.9,v 1.2 2002/12/09 14:29:34 ru Exp $ +.\" $FreeBSD: src/share/man/man9/thread_exit.9,v 1.3 2007/03/09 22:41:01 jhb Exp $ .\" .Dd July 5, 2002 .Dt THREAD_EXIT 9 @@ -58,6 +58,6 @@ mutex held. .Sh SEE ALSO .Xr mi_switch 9 , -.Xr msleep 9 , .Xr mutex 9 , -.Xr runqueue 9 +.Xr runqueue 9 , +.Xr sleep 9 Index: ithread.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ithread.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/ithread.9 -L share/man/man9/ithread.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/ithread.9 +++ share/man/man9/ithread.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ithread.9,v 1.11 2004/07/05 17:12:52 ru Exp $ +.\" $FreeBSD: src/share/man/man9/ithread.9,v 1.12 2006/08/25 19:04:42 pav Exp $ .\" -.Dd February 10, 2001 +.Dd August 25, 2006 .Dt ITHREAD 9 .Os .Sh NAME @@ -202,6 +202,12 @@ and .Dv INTR_ENTROPY flags are not valid for software interrupt handlers. +.Pp +It is not permitted to sleep in an interrupt thread; hence, any memory +or zone allocations in an interrupt thread should be specified with the +.Dv M_NOWAIT +flag set. +Any allocation errors must be handled thereafter. .Sh RETURN VALUES The .Fn ithread_add_handler , @@ -340,7 +346,9 @@ .El .Sh SEE ALSO .Xr kthread 9 , -.Xr swi 9 +.Xr malloc 9 , +.Xr swi 9 , +.Xr uma 9 .Sh HISTORY Interrupt threads and their corresponding API first appeared in .Fx 5.0 . --- /dev/null +++ share/man/man9/sysctl.9 @@ -0,0 +1,304 @@ +.\" +.\" Copyright (c) 2006 Robert N. M. Watson +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/sysctl.9,v 1.8 2006/12/14 14:33:13 mpp Exp $ +.\" +.Dd November 23, 2006 +.Dt SYSCTL 9 +.Os +.Sh NAME +.Nm SYSCTL_DECL , +.Nm SYSCTL_INT , +.Nm SYSCTL_LONG , +.Nm SYSCTL_NODE , +.Nm SYSCTL_OPAQUE , +.Nm SYSCTL_PROC , +.Nm SYSCTL_STRING , +.Nm SYSCTL_STRUCT , +.Nm SYSCTL_UINT , +.Nm SYSCTL_ULONG , +.Nm SYSCTL_XINT , +.Nm SYSCTL_XLONG +.Nd Static sysctl declaration functions +.Sh SYNOPSIS +.In sys/types.h +.In sys/sysctl.h +.Fn SYSCTL_DECL name +.Fn SYSCTL_INT parent nbr name access ptr val descr +.Fn SYSCTL_LONG parent nbr name access ptr val descr +.Fn SYSCTL_NODE parent nbr name access handler descr +.Fn SYSCTL_OPAQUE parent nbr name access ptr len fmt descr +.Fn SYSCTL_PROC parent nbr name access ptr arg handler fmt descr +.Fn SYSCTL_STRING parent nbr name access arg len descr +.Fn SYSCTL_STRUCT parent nbr name access ptr type descr +.Fn SYSCTL_UINT parent nbr name access ptr val descr +.Fn SYSCTL_ULONG parent nbr name access ptr val descr +.Fn SYSCTL_XINT parent nbr name access ptr val descr +.Fn SYSCTL_XLONG parent nbr name access ptr val descr +.Sh DESCRIPTION +The +.Nm SYSCTL +kernel interfaces allow code to statically declare +.Xr sysctl 8 +MIB entries, which will be initialized when the kernel module containing the +declaration is initialized. +When the module is unloaded, the sysctl will be automatically destroyed. +.Pp +Sysctl nodes are created in a hierarchical tree, with all static nodes being +represented by named C data structures; in order to create a new node under +an existing node in the tree, the structure representing the desired parent +node must be declared in the current context using +.Fn SYSCTL_DECL . +.Pp +New nodes are declared using one of +.Fn SYSCTL_INT , +.Fn SYSCTL_LONG , +.Fn SYSCTL_NODE , +.Fn SYSCTL_OPAQUE , +.Fn SYSCTL_PROC , +.Fn SYSCTL_STRING , +.Fn SYSCTL_STRUCT , +.Fn SYSCTL_UINT , +.Fn SYSCTL_ULONG , +.Fn SYSCTL_XINT , +and +.Fn SYSCTL_XLONG . +Each macro accepts a parent name, as declared using +.Fn SYSCTL_DECL , +an OID number, typically +.Dv OID_AUTO , +a node name, a set of control and access flags, and a description. +Depending on the macro, a pointer to a variable supporting the MIB entry, a +size, a value, and a function pointer implementing the MIB entry may also be +present. +.Pp +For most of the above macros, declaring a type as part of the access flags is +not necessary \[em] however, when declaring a sysctl implemented by a function, +including a type in the access mask is required: +.Bl -tag -width ".Dv CTLTYPE_STRING" +.It Dv CTLTYPE_NODE +This is a node intended to be a parent for other nodes. +.It Dv CTLTYPE_INT +This is a signed integer. +.It Dv CTLTYPE_STRING +This is a nul-terminated string stored in a character array. +.It Dv CTLTYPE_QUAD +This is a 64-bit signed integer. +.It Dv CTLTYPE_OPAQUE +This is an opaque data structure. +.It Dv CTLTYPE_STRUCT +Alias for +.Dv CTLTYPE_OPAQUE. +.It Dv CTLTYPE_UINT +This is an unsigned integer. +.It Dv CTLTYPE_LONG +This is a signed long. +.It Dv CTLTYPE_ULONG +This is an unsigned long. +.El +.Pp +All sysctl types except for new node declarations require one or more flags +to be set indicating the read and write disposition of the sysctl: +.Bl -tag -width ".Dv CTLFLAG_ANYBODY" +.It Dv CTLFLAG_RD +This is a read-only sysctl. +.It Dv CTLFLAG_WR +This is a writable sysctl. +.It Dv CTLFLAG_RW +This sysctl is readable and writable. +.It Dv CTLFLAG_ANYBODY +Any user or process can write to this sysctl. +.It Dv CTLFLAG_SECURE +This sysctl can be written to only if the effective securelevel of the +process is \[<=] 0. +.It Dv CTLFLAG_PRISON +This sysctl can be written to by processes in +.Xr jail 2 . +.It Dv CTLFLAG_SKIP +When iterating the sysctl name space, do not list this sysctl. +.It Dv CTLFLAG_TUN +Also declare a system tunable with the same name to initialize this variable. +.It Dv CTLFLAG_RDTUN +Also declare a system tunable with the same name to initialize this variable; +however, the run-time variable is read-only. +.El +.Pp +When creating new sysctls, careful attention should be paid to the security +implications of the monitoring or management interface being created. +Most sysctls present in the kernel are read-only or writable only by the +superuser. +Sysctls exporting extensive information on system data structures and +operation, especially those implemented using procedures, will wish to +implement access control to limit the undesired exposure of information about +other processes, network connections, etc. +.Pp +The following top level sysctl name spaces are commonly used: +.Bl -tag -width ".Va regression" +.It Va compat +Compatibility layer information. +.It Va debug +Debugging information. +Various name spaces exist under +.Va debug . +.It Va hw +Hardware and device driver information. +.It Va kern +Kernel behavior tuning; generally deprecated in favor of more specific +name spaces. +.It Va machdep +Machine-dependent configuration parameters. +.It Va net +Network subsystem. +Various protocols have name spaces under +.Va net . +.It Va regression +Regression test configuration and information. +.It Va security +Security and security-policy configuration and information. +.It Va sysctl +Reserved name space for the implementation of sysctl. +.It Va user +Configuration settings relating to user application behavior. +Generally, configuring applications using kernel sysctls is discouraged. +.It Va vfs +Virtual file system configuration and information. +.It Va vm +Virtual memory subsystem configuration and information. +.El +.Sh EXAMPLES +Sample use of +.Fn SYSCTL_DECL +to declare the +.Va security +sysctl tree for use by new nodes: +.Bd -literal -offset indent +SYSCTL_DECL(_security); +.Ed +.Pp +Examples of integer, opaque, string, and procedure sysctls follow: +.Bd -literal -offset indent +/* + * Example of a constant integer value. Notice that the control + * flags are CTLFLAG_RD, the variable pointer is NULL, and the + * value is declared. + * If sysctl(8) should print this value in hex, use 'SYSCTL_XINT'. + */ +SYSCTL_INT(_debug_sizeof, OID_AUTO, bio, CTLFLAG_RD, NULL, + sizeof(struct bio), "sizeof(struct bio)"); + +/* + * Example of a variable integer value. Notice that the control + * flags are CTLFLAG_RW, the variable pointer is set, and the + * value is 0. + */ +static int doingcache = 1; /* 1 => enable the cache */ +SYSCTL_INT(_debug, OID_AUTO, vfscache, CTLFLAG_RW, &doingcache, 0, + "Enable name cache"); + +/* + * Example of a variable string value. Notice that the control + * flags are CTLFLAG_RW, that the variable pointer and string + * size are set. Unlike newer sysctls, this older sysctl uses a + * static oid number. + */ +char kernelname[MAXPATHLEN] = "/kernel"; /* XXX bloat */ +SYSCTL_STRING(_kern, KERN_BOOTFILE, bootfile, CTLFLAG_RW, + kernelname, sizeof(kernelname), "Name of kernel file booted"); + +/* + * Example of an opaque data type exported by sysctl. Notice that + * the variable pointer and size are provided, as well as a format + * string for sysctl(8). + */ +static l_fp pps_freq; /* scaled frequence offset (ns/s) */ +SYSCTL_OPAQUE(_kern_ntp_pll, OID_AUTO, pps_freq, CTLFLAG_RD, + &pps_freq, sizeof(pps_freq), "I", ""); + +/* + * Example of a procedure based sysctl exporting string + * information. Notice that the data type is declared, the NULL + * variable pointer and 0 size, the function pointer, and the + * format string for sysctl(8). + */ +SYSCTL_PROC(_kern_timecounter, OID_AUTO, hardware, CTLTYPE_STRING | + CTLFLAG_RW, NULL, 0, sysctl_kern_timecounter_hardware, "A", + ""); +.Ed +.Sh SYSCTL NAMING +When adding, modifying, or removing sysctl names, it is important to be +aware that these interfaces may be used by users, libraries, applications, +or documentation (such as published books), and are implicitly published application interfaces. +As with other application interfaces, caution must be taken not to break +existing applications, and to think about future use of new name spaces so as +to avoid the need to rename or remove interfaces that might be depended on in +the future. +.Pp +The semantics chosen for a new sysctl should be as clear as possible, +and the name of the sysctl must closely reflect its semantics. +Therefore the sysctl name deserves a fair amount of consideration. +It should be short but yet representative of the sysctl meaning. +If the name consists of several words, they should be separated by +underscore characters, as in +.Va compute_summary_at_mount . +Underscore characters may be omitted only if the name consists of not more +than two words, each being not longer than four characters, as in +.Va bootfile . +For boolean sysctls, negative logic should be totally avoided. +That is, do not use names like +.Va no_foobar +or +.Va foobar_disable . +They are confusing and lead to configuration errors. +Use positive logic instead: +.Va foobar , +.Va foobar_enable . +.Pp +A temporary sysctl node that should not be relied upon must be designated +as such by a leading underscore character in its name. For example: +.Va _dirty_hack . +.Sh SEE ALSO +.Xr sysctl 8 , +.Xr sysctl_add_oid 9 , +.Xr sysctl_ctx_free 9 , +.Xr sysctl_ctx_init 9 , +.Xr sysctl_remove_oid 9 +.Sh HISTORY +The +.Xr sysctl 8 +utility first appeared in +.Bx 4.4 . +.Sh AUTHORS +.An -nosplit +The +.Nm sysctl +implementation originally found in +.Bx +has been extensively rewritten by +.An Poul-Henning Kamp +in order to add support for name lookups, name space iteration, and dynamic +addition of MIB nodes. +.Pp +This man page was written by +.An Robert N. M. Watson . Index: taskqueue.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/taskqueue.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/taskqueue.9 -L share/man/man9/taskqueue.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/taskqueue.9 +++ share/man/man9/taskqueue.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/taskqueue.9,v 1.20 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/taskqueue.9,v 1.21 2007/07/09 06:24:10 jmg Exp $ .\" .Dd May 19, 2005 .Dt TASKQUEUE 9 @@ -160,6 +160,12 @@ and the value of .Va ta_pending as its second argument. +After the function +.Va ta_func +returns, +.Xr wakeup 9 +is called on the task pointer passed to +.Fn taskqueue_enqueue . .Pp The .Fn taskqueue_drain Index: watchdog.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/watchdog.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/watchdog.9 -L share/man/man9/watchdog.9 -u -r1.2 -r1.3 --- share/man/man9/watchdog.9 +++ share/man/man9/watchdog.9 @@ -22,8 +22,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/watchdog.9,v 1.3 2004/07/06 07:39:50 ru Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/watchdog.9,v 1.6 2007/03/28 21:21:22 brueffer Exp $ .\" .Dd February 28, 2004 .Dt WATCHDOG 9 @@ -36,6 +35,7 @@ .Ft void .Fn watchdog_fn "void *private" "u_int cmd" "int *error" .Fn EVENTHANDLER_REGISTER watchdog_list watchdog_fn private 0 +.Fn EVENTHANDLER_DEREGISTER watchdog_list eventhandler_tag .Sh DESCRIPTION To implement a watchdog in software or hardware, only a single function needs to be written and registered on the global @@ -51,17 +51,21 @@ is zero, the watchdog must be disabled and the .Fa error argument left untouched. +If the watchdog cannot be disabled, the +.Fa error +argument must be set to +.Dv EOPNOTSUPP . .Pp Else the watchdog should be reset and configured to a timeout of .Pq 1 << Pq Fa cmd No & Dv WD_INTERVAL nanoseconds or larger and the .Fa error -argument be set to zero. +argument be set to zero to signal arming of a watchdog. .Pp If the watchdog cannot be configured to the proposed timeout, it must be disabled and the .Fa error -argument left untouched. +argument left as is (to avoid hiding the arming of another watchdog). .Pp There is no specification of what the watchdog should do when it times out, but a hardware reset or similar Index: mtx_pool.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mtx_pool.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/mtx_pool.9 -L share/man/man9/mtx_pool.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/mtx_pool.9 +++ share/man/man9/mtx_pool.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mtx_pool.9,v 1.5 2003/09/14 13:41:59 ru Exp $ +.\" $FreeBSD: src/share/man/man9/mtx_pool.9,v 1.8 2007/03/30 18:07:26 julian Exp $ .\" .Dd March 25, 2002 .Dt MTX_POOL 9 @@ -64,7 +64,7 @@ .Sh DESCRIPTION Mutex pools are designed to be used as short term leaf mutexes; i.e., the last mutex one might acquire before calling -.Xr msleep 9 . +.Xr mtx_sleep 9 . They operate using a shared pool of mutexes. A mutex may be chosen from the pool based on a supplied pointer, which may or may not point to anything valid, @@ -110,7 +110,7 @@ No initialization or destruction overhead. .It Can be used with -.Xr msleep 9 . +.Xr mtx_sleep 9 . .El .Pp And the following disadvantages: @@ -176,9 +176,8 @@ on each mutex in the specified pool, deallocates the memory associated with the pool, and assigns NULL to the pool pointer. -.Pp .Sh SEE ALSO -.Xr msleep 9 , +.Xr locking 9 .Xr mutex 9 .Sh HISTORY These routines first appeared in Index: ktr.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ktr.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/ktr.9 -L share/man/man9/ktr.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/ktr.9 +++ share/man/man9/ktr.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ktr.9,v 1.9 2005/06/15 13:31:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/ktr.9,v 1.13 2006/10/16 07:59:05 danger Exp $ .\" -.Dd February 15, 2001 +.Dd December 27, 2005 .Dt KTR 9 .Os .Sh NAME @@ -51,6 +51,8 @@ .Fn CTR4 "u_int mask" "char *format" "arg1" "arg2" "arg3" "arg4" .Ft void .Fn CTR5 "u_int mask" "char *format" "arg1" "arg2" "arg3" "arg4" "arg5" +.Ft void +.Fn CTR6 "u_int mask" "char *format" "arg1" "arg2" "arg3" "arg4" "arg5" "arg6" .Sh DESCRIPTION KTR provides a circular buffer of events that can be logged in a .Xr printf 9 @@ -143,3 +145,13 @@ so that if one CPU halts or starts spinning, then the log messages it emitted just prior to halting or spinning will not be drowned out by events from the other CPUs. +.Pp +The arguments given in +.Fn CTRx +macros are stored as +.Vt u_long , +so do not pass arguments larger than size of an +.Vt u_long +type. +For example passing 64bit arguments on 32bit architectures will give incorrect +results. Index: bus_alloc_resource.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bus_alloc_resource.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bus_alloc_resource.9 -L share/man/man9/bus_alloc_resource.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bus_alloc_resource.9 +++ share/man/man9/bus_alloc_resource.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bus_alloc_resource.9,v 1.21 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/bus_alloc_resource.9,v 1.23 2007/05/27 20:49:08 imp Exp $ .\" .Dd May 18, 2000 .Dt BUS_ALLOC_RESOURCE 9 @@ -90,10 +90,10 @@ points to a bus specific handle that identifies the resource being allocated. For ISA this is an index into an array of resources that have been setup for this device by either the PnP mechanism, or via the hints mechanism. -For PCCARD, similar things are used as of writing, -but that may change in the future with newcard. -For PCI it just happens to be the offset into pci config space which has -a word that describes the resource. +For PCCARD, this is an index into the array of resources described by the PC Card's +CIS entry. +For PCI, the offset into pci config space which has the BAR to use to access +the resource. The bus methods are free to change the RIDs that they are given as a parameter. You must not depend on the value you gave it earlier. .It @@ -159,7 +159,7 @@ .Va irqid should be saved in the softc of the device after these calls. .Bd -literal - struct resource *portres, irqres; + struct resource *portres, *irqres; int portid, irqid; portid = 0; Index: vput.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vput.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vput.9 -L share/man/man9/vput.9 -u -r1.2 -r1.3 --- share/man/man9/vput.9 +++ share/man/man9/vput.9 @@ -27,7 +27,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vput.9,v 1.11 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 1996 .Os Index: acl.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/acl.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/acl.9 -L share/man/man9/acl.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/acl.9 +++ share/man/man9/acl.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/acl.9,v 1.14 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/acl.9,v 1.15 2006/02/13 21:34:18 joel Exp $ .\" .Dd December 23, 1999 .Os @@ -135,7 +135,6 @@ to the associated file. .El .El -.Pp .Sh IMPLEMENTATION NOTES .Bd -literal typedef mode_t *acl_permset_t; Index: device_set_driver.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/device_set_driver.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/device_set_driver.9 -L share/man/man9/device_set_driver.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/device_set_driver.9 +++ share/man/man9/device_set_driver.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/device_set_driver.9,v 1.3 2003/10/23 06:19:45 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/device_set_driver.9,v 1.4 2007/02/09 21:12:21 brueffer Exp $ .\" .Dd April 21, 2003 .Dt DEVICE_SET_DRIVER 9 @@ -45,9 +45,7 @@ It is typically used in .Xr DEVICE_IDENTIFY 9 functions to add devices to a bus that does not support doing so -automatically, such as the -.Xr isa 4 -bus. +automatically, such as the ISA bus. .Sh SEE ALSO .Xr device 9 .Sh AUTHORS Index: crypto.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/crypto.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/crypto.9 -L share/man/man9/crypto.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/crypto.9 +++ share/man/man9/crypto.9 @@ -15,9 +15,9 @@ .\" MERCHANTABILITY OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR .\" PURPOSE. .\" -.\" $FreeBSD: src/share/man/man9/crypto.9,v 1.5 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/crypto.9,v 1.14 2007/09/19 16:28:46 brueffer Exp $ .\" -.Dd October 14, 2002 +.Dd September 19, 2007 .Dt CRYPTO 9 .Os .Sh NAME @@ -62,7 +62,7 @@ struct cryptoini { int cri_alg; int cri_klen; - int cri_rnd; + int cri_mlen; caddr_t cri_key; u_int8_t cri_iv[EALG_MAX_BLOCK_LEN]; struct cryptoini *cri_next; @@ -74,6 +74,10 @@ int crd_inject; int crd_flags; struct cryptoini CRD_INI; +#define crd_iv CRD_INI.cri_iv +#define crd_key CRD_INI.cri_key +#define crd_alg CRD_INI.cri_alg +#define crd_klen CRD_INI.cri_klen struct cryptodesc *crd_next; }; @@ -171,30 +175,33 @@ Currently supported algorithms are: .Pp .Bl -tag -width ".Dv CRYPTO_RIPEMD160_HMAC" -compact -.It Dv CRYPTO_DES_CBC -.It Dv CRYPTO_3DES_CBC +.It Dv CRYPTO_AES_CBC +.It Dv CRYPTO_ARC4 .It Dv CRYPTO_BLF_CBC +.It Dv CRYPTO_CAMELLIA_CBC .It Dv CRYPTO_CAST_CBC +.It Dv CRYPTO_DES_CBC +.It Dv CRYPTO_3DES_CBC .It Dv CRYPTO_SKIPJACK_CBC +.It Dv CRYPTO_MD5 .It Dv CRYPTO_MD5_HMAC -.It Dv CRYPTO_SHA1_HMAC -.It Dv CRYPTO_RIPEMD160_HMAC .It Dv CRYPTO_MD5_KPDK -.It Dv CRYPTO_SHA1_KPDK -.It Dv CRYPTO_AES_CBC -.It Dv CRYPTO_ARC4 -.It Dv CRYPTO_MD5 +.It Dv CRYPTO_RIPEMD160_HMAC .It Dv CRYPTO_SHA1 -.It Dv CRYPTO_SHA2_HMAC +.It Dv CRYPTO_SHA1_HMAC +.It Dv CRYPTO_SHA1_KPDK +.It Dv CRYPTO_SHA2_256_HMAC +.It Dv CRYPTO_SHA2_384_HMAC +.It Dv CRYPTO_SHA2_512_HMAC .It Dv CRYPTO_NULL_HMAC .It Dv CRYPTO_NULL_CBC .El .It Va cri_klen Specifies the length of the key in bits, for variable-size key algorithms. -.It Va cri_rnd -Specifies the number of rounds to be used with the algorithm, for -variable-round algorithms. +.It Va cri_mlen +Specifies how many bytes from the calculated hash should be copied back. +0 means entire hash. .It Va cri_key Contains the key to be used with the algorithm. .It Va cri_iv @@ -278,11 +285,27 @@ .It Va crp_flags Is a bitmask of flags associated with this request. Currently defined flags are: -.Bl -tag -width ".Dv CRYPTO_F_IMBUF" +.Bl -tag -width ".Dv CRYPTO_F_CBIFSYNC" .It Dv CRYPTO_F_IMBUF The buffer pointed to by .Va crp_buf is an mbuf chain. +.It Dv CRYPTO_F_IOV +The buffer pointed to by +.Va crp_buf +is an +.Vt uio +structure. +.It Dv CRYPTO_F_REL +Must return data in the same place. +.It Dv CRYPTO_F_BATCH +Batch operation if possible. +.It Dv CRYPTO_F_CBIMM +Do callback immediately instead of doing it from a dedicated kernel thread. +.It Dv CRYPTO_F_DONE +Operation completed. +.It Dv CRYPTO_F_CBIFSYNC +Do callback immediately if operation is synchronous. .El .It Va crp_buf Points to the input buffer. @@ -302,6 +325,23 @@ on the input buffer. The various fields are: .Bl -tag -width ".Va crd_inject" +.It Va crd_iv +The field where IV should be provided when the +.Dv CRD_F_IV_EXPLICIT +flag is given. +.It Va crd_key +When the +.Dv CRD_F_KEY_EXPLICIT +flag is given, the +.Va crd_key +points to a buffer with encryption or authentication key. +.It Va crd_alg +An algorithm to use. +Must be the same as the one given at newsession time. +.It Va crd_klen +The +.Va crd_key +key length. .It Va crd_skip The offset in the input buffer where processing should start. .It Va crd_len @@ -318,7 +358,7 @@ inserted. .It Va crd_flags The following flags are defined: -.Bl -tag -width ".Dv CRD_F_IV_EXPLICIT" +.Bl -tag -width 3n .It Dv CRD_F_ENCRYPT For encryption algorithms, this bit is set when encryption is required (when not set, decryption is performed). @@ -343,8 +383,8 @@ .It Dv CRD_F_IV_EXPLICIT For encryption algorithms, this bit is set when the IV is explicitly provided by the consumer in the -.Va cri_iv -fields. +.Va crd_iv +field. Otherwise, for encryption operations the IV is provided for by the driver used to perform the operation, whereas for decryption operations it is pointed to by the @@ -355,6 +395,14 @@ by the consumer, and does not precede the data (some .Xr ipsec 4 configurations, and the encrypted swap are two such examples). +.It Dv CRD_F_KEY_EXPLICIT +For encryption and authentication (MAC) algorithms, this bit is set when the key +is explicitly provided by the consumer in the +.Va crd_key +field for the given operation. +Otherwise, the key is taken at newsession time from the +.Va cri_key +field. .It Dv CRD_F_COMP For compression algorithms, this bit is set when compression is required (when not set, decompression is performed). Index: vm_page_grab.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_grab.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_grab.9 -L share/man/man9/vm_page_grab.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_grab.9 +++ share/man/man9/vm_page_grab.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_grab.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd August 7, 2001 .Dt VM_PAGE_GRAB 9 Index: hashinit.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/hashinit.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/hashinit.9 -L share/man/man9/hashinit.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/hashinit.9 +++ share/man/man9/hashinit.9 @@ -23,13 +23,13 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/hashinit.9,v 1.2 2005/01/21 08:36:40 ru Exp $ +.\" $FreeBSD: src/share/man/man9/hashinit.9,v 1.4 2007/01/27 23:06:00 ru Exp $ .\" .Dd October 10, 2004 .Dt HASHINIT 9 .Os .Sh NAME -.Nm hashinit , hashdestroy , phashinit +.Nm hashinit , hashinit_flags, hashdestroy , phashinit .Nd manage kernel hash tables .Sh SYNOPSIS .In sys/malloc.h @@ -38,12 +38,17 @@ .Ft "void *" .Fn hashinit "int nelements" "struct malloc_type *type" "u_long *hashmask" .Ft void +.Fo hashinit_flags +.Fa "int nelements" "struct malloc_type *type" "u_long *hashmask" "int flags" +.Fc +.Ft void .Fn hashdestroy "void *hashtbl" "struct malloc_type *type" "u_long hashmask" .Ft "void *" .Fn phashinit "int nelements" "struct malloc_type *type" "u_long *nentries" .Sh DESCRIPTION The -.Fn hashinit +.Fn hashinit , +.Fn hashinit_flags and .Fn phashinit functions allocate space for hash tables of size given by the argument @@ -59,6 +64,13 @@ function allocates hash tables that are sized to the largest prime number less than or equal to argument .Fa nelements . +The +.Fn hashinit_flags +function operates like +.Fn hashinit +but also accepts an additional argument +.Fa flags +which control various options during allocation. Allocated hash tables are contiguous arrays of .Xr LIST_HEAD 3 entries, allocated using @@ -80,6 +92,20 @@ should be the bit mask returned by the call to .Fn hashinit that allocated the hash table. +The argument +.Fa flags +must be used with one of the following values. +.Pp +.Bl -tag -width ".Dv HASH_NOWAIT" -offset indent -compact +.It Dv HASH_NOWAIT +Any malloc performed by the +.Fn hashinit_flags +function will not be allowed to wait, and therefore may fail. +.It Dv HASH_WAITOK +Any malloc performed by the +.Fn hashinit_flags +function is allowed to wait for memory. +.El .Sh IMPLEMENTATION NOTES The largest prime hash value chosen by .Fn phashinit Index: mbuf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mbuf.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/mbuf.9 -L share/man/man9/mbuf.9 -u -r1.2 -r1.3 --- share/man/man9/mbuf.9 +++ share/man/man9/mbuf.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mbuf.9,v 1.58.2.2 2006/03/23 23:24:33 sam Exp $ +.\" $FreeBSD: src/share/man/man9/mbuf.9,v 1.65 2007/02/26 15:17:19 bms Exp $ .\" -.Dd March 15, 2006 +.Dd February 26, 2007 .Dt MBUF 9 .Os .\" @@ -51,14 +51,10 @@ .Fa "int type" .Fc .Fn MEXTFREE "struct mbuf *mbuf" -.Fn MEXT_ADD_REF "struct mbuf *mbuf" -.Fn MEXT_REM_REF "struct mbuf *mbuf" .Fn MFREE "struct mbuf *mbuf" "struct mbuf *successor" .\" .Ss Mbuf utility macros .Fn mtod "struct mbuf *mbuf" "type" -.Ft int -.Fn MEXT_IS_REF "struct mbuf *mbuf" .Fn M_ALIGN "struct mbuf *mbuf" "u_int len" .Fn MH_ALIGN "struct mbuf *mbuf" "u_int len" .Ft int @@ -101,6 +97,8 @@ .Ft struct mbuf * .Fn m_pullup "struct mbuf *mbuf" "int len" .Ft struct mbuf * +.Fn m_pulldown "struct mbuf *mbuf" "int offset" "int len" "int *offsetp" +.Ft struct mbuf * .Fn m_copym "struct mbuf *mbuf" "int offset" "int len" "int how" .Ft struct mbuf * .Fn m_copypacket "struct mbuf *mbuf" "int how" @@ -233,9 +231,8 @@ .Bd -literal /* mbuf types */ #define MT_DATA 1 /* dynamic (data) allocation */ -#define MT_HEADER 2 /* packet header */ +#define MT_HEADER MT_DATA /* packet header */ #define MT_SONAME 8 /* socket name */ -#define MT_FTABLE 11 /* fragment reassembly header */ #define MT_CONTROL 14 /* extra-data protocol message */ #define MT_OOBDATA 15 /* expedited data */ .Ed @@ -302,18 +299,6 @@ .Pp The allocation and management of the reference counter is handled by the subsystem. -The developer can check whether the reference count for the -external storage of a given -.Vt mbuf -is greater than 1 with the -.Dv MEXT_IS_REF -macro. -Similarly, the developer can directly add and remove references, -if absolutely necessary, with the use of the -.Dv MEXT_ADD_REF -and -.Dv MEXT_REM_REF -macros. .Pp The system also supplies a default type of external storage buffer called an .Vt mbuf cluster . @@ -660,6 +645,10 @@ .Fa mbuf , so they are accessible with .Fn mtod mbuf type . +It is important to remember that this may involve +reallocating some mbufs and moving data so all pointers +referencing data within the old mbuf chain +must be recalculated or made invalid. Return the new .Vt mbuf chain on success, @@ -676,6 +665,42 @@ must be less than .Dv MHLEN . .\" +.It Fn m_pulldown mbuf offset len offsetp +Arrange that +.Fa len +bytes between +.Fa offset +and +.Fa offset + len +in the +.Vt mbuf chain +are contiguous and lay in the data area of +.Fa mbuf , +so they are accessible with +.Fn mtod mbuf type . +.Fa len must be smaller than, or equal to, the size of an +.Vt mbuf cluster . +Return a pointer to an intermediate +.Vt mbuf +in the chain containing the requested region; +the offset in the data region of the +.Vt mbuf chain +to the data contained in the returned mbuf is stored in +.Fa *offsetp . +If +.Fa offp +is NULL, the region may be accessed using +.Fn mtod mbuf type . +If +.Fa offp +is non-NULL, the region may be accessed using +.Fn mtod mbuf uint8_t + *offsetp . +The region of the mbuf chain between its beginning and +.Fa off +is not modified, therefore it is safe to hold pointers to data within +this region before calling +.Fn m_pulldown . +.\" .It Fn m_copym mbuf offset len how Make a copy of an .Vt mbuf chain @@ -1135,7 +1160,35 @@ Besides being used for network packets, they were used to store various dynamic structures, such as routing table entries, interface addresses, protocol control blocks, etc. +In more recent +.Fx +use of +.Vt mbufs +is almost entirely limited to packet storage, with +.Xr uma 9 +zones being used directly to store other network-related memory. +.Pp +Historically, the +.Vt mbuf +allocator has been a special-purpose memory allocator able to run in +interrupt contexts and allocating from a special kernel address space map. +As of +.Fx 5.3 , +the +.Vt mbuf +allocator is a wrapper around +.Xr uma 9 , +allowing caching of +.Vt mbufs , +clusters, and +.Vt mbuf ++ cluster pairs in per-CPU caches, as well as bringing other benefits of +slab allocation. .Sh AUTHORS The original .Nm manual page was written by Yar Tikhiy. +The +.Xr uma 9 +.Vt mbuf +allocator was written by Bosko Milekic. Index: vgone.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vgone.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vgone.9 -L share/man/man9/vgone.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vgone.9 +++ share/man/man9/vgone.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vgone.9,v 1.4 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/vgone.9,v 1.5 2006/06/07 16:51:54 jkoshy Exp $ .\" .Dd November 21, 2001 .Dt VGONE 9 @@ -50,7 +50,7 @@ If the vnode has a .Va v_usecount of zero, and its -.Dv VDOOMED +.Dv VI_DOOMED flag is not set, it is moved to the head of the free list as in most cases the vnode is about to be reused, or its file system being unmounted. @@ -66,8 +66,6 @@ while .Fn vgonel expects the interlock to already be locked. -.Sh SEE ALSO -.Xr vclean 9 .Sh AUTHORS This manual page was written by .An Chad David Aq davidc at acns.ab.ca . Index: lock.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/lock.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/lock.9 -L share/man/man9/lock.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/lock.9 +++ share/man/man9/lock.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/lock.9,v 1.12 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/lock.9,v 1.17 2007/06/21 16:39:25 brueffer Exp $ .\" -.Dd July 9, 2001 +.Dd June 20, 2006 .Dt LOCK 9 .Os .Sh NAME @@ -63,14 +63,14 @@ A pointer to the lock to initialize. .It Fa prio The priority passed to -.Xr msleep 9 . +.Xr sleep 9 . .It Fa wmesg The lock message. This is used for both debugging output and -.Xr msleep 9 . +.Xr sleep 9 . .It Fa timo The timeout value passed to -.Xr msleep 9 . +.Xr sleep 9 . .It Fa flags The flags the lock is to be initialized with. .Bl -tag -width ".Dv LG_CANRECURSE" @@ -80,10 +80,8 @@ Fail after a sleep. .It Dv LK_CANRECURSE Allow recursive exclusive locks. -.It Dv LK_REENABLE -Re-enable the lock after a drain. -.It Dv LK_NOPAUSE -Disable the spinlock while acquiring the lock. +.It Dv LK_NOSHARE +Allow exclusive locks only. .It Dv LK_TIMELOCK Use .Fa timo @@ -140,6 +138,8 @@ .It Dv LK_UPGRADE Upgrade a shared lock to an exclusive lock. If this call fails, the shared lock is lost. +During the upgrade, the shared lock could +be temporarily dropped. Attempts to upgrade an exclusive lock will cause a .Xr panic 9 . .It Dv LK_RELEASE @@ -272,7 +272,12 @@ .Xr panic 9 will be the result of trying. .Sh SEE ALSO -.Xr msleep 9 , +.Xr condvar 9 , +.Xr locking 9 , +.Xr mutex 9 , +.Xr rwlock 9 , +.Xr sleep 9 , +.Xr sx 9 , .Xr mtx_assert 9 , .Xr panic 9 , .Xr VOP_PRINT 9 Index: firmware.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/firmware.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/firmware.9 -L share/man/man9/firmware.9 -u -r1.2 -r1.3 --- share/man/man9/firmware.9 +++ share/man/man9/firmware.9 @@ -21,7 +21,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/firmware.9,v 1.2.2.2 2006/03/23 07:41:32 hrs Exp $ +.\" $FreeBSD: src/share/man/man9/firmware.9,v 1.6 2007/02/15 17:52:17 luigi Exp $ .\" .Dd January 6, 2006 .Os @@ -43,73 +43,224 @@ const void *data; /* location of image */ size_t datasize; /* size of image in bytes */ unsigned int version; /* version of the image */ - int refcnt; /* held references */ - struct firmware *parent; /* not null if a subimage */ - linker_file_t file; /* loadable module */ }; .Ed -.Ft struct firmware * +.Ft "const struct firmware *" .Fo firmware_register .Fa "const char *imagename" .Fa "const void *data" .Fa "size_t datasize" .Fa "unsigned int version" -.Fa "struct firmware *parent" +.Fa "const struct firmware *parent" .Fc .Ft int .Fn firmware_unregister "const char *imagename" -.Ft struct firmware * +.Ft "const struct firmware *" .Fn firmware_get "const char *imagename" .Ft void -.Fn firmware_put "struct firmware *fp" "int flags" +.Fn firmware_put "const struct firmware *fp" "int flags" .Sh DESCRIPTION -The firmware abstraction provides a convenient interface for loading firmware -images into the kernel. -Specially crafted kernel modules are used to hold the firmware images. +The +.Nm firmware +abstraction provides a convenient interface for loading +.Nm firmware images +into the kernel, and for accessing such images from kernel components. +.Pp +A +.Nm firmware image +(or +.Nm image +for brevity) +is an opaque block of data residing in kernel memory. +It is associated to a unique +.Nm imagename +which constitutes a search key, and to an integer +.Nm version +number, which is also an opaque piece of information for the +firmware subsystem. +.Pp +An image is registered with the +.Nm firmware +subsystem by calling the function +.Fn firmware_register , +and unregistered by calling +.Fn firmware_unregister . +These functions are usually (but not exclusively) called by +specially crafted kernel modules that contain the firmware image. +The modules can be statically compiled in the kernel, or loaded by +.Nm /boot/loader , +manually at runtime, or on demand by the firmware subsystem. +.Pp +.Nm Clients +of the firmware subsystem can request access to a given image +by calling the function +.Fn firmware_get +with the +.Nm imagename +they want as an argument. If a matching image is not already registered, +the firmware subsystem will try to load it using the +mechanisms specified below (typically, a kernel module +with +.Nm the same name +as the image). +.Sh API DESCRIPTION +The kernel +.Nm firmware API +is made of the following functions: .Pp -The function -.Fn firmware_register -is used on load of such modules to register contained firmware images. -The arguments to .Fn firmware_register -include a name that identifies the image for later requests to the firmware -system, a pointer to the actual image, the size of the image and an optional -parent image. -The parent image is used to keep track of references to a given module so that -it can be unloaded on last reference. +registers with the kernel an image of size +.Nm datasize +located at address +.Nm data , +under the name +.Nm imagename . +.Pp +The function returns NULL on error (e.g. because an +image with the same name already exists, or the image +table is full), or a +.Ft const struct firmware * +pointer to the image requested. .Pp -The function .Fn firmware_unregister -removes the firmware image identified by the name from the system if there -are no pending references or returns an error otherwise. +tries to unregister the firmware image +.Nm imagename +from the system. The function is successful and returns 0 +if there are no pending references to the image, otherwise +it does not unregister the image and returns EBUSY. .Pp -The function .Fn firmware_get returns the requested firmware image. -If the image is not yet registered with the system +If the image is not yet registered with the system, +the function tries to load it. +This involves the linker subsystem and disk access, so .Fn firmware_get -tries to load a module with the corresponding name. -This involves the linker subsystem and disk access which is why -.Fn firmware_get -must not be called with any locks (except for Giant). -On success +must not be called with any locks (except for +.Va Giant ) . +The caller must also have a process context so filesystem state such as +the root vnode is defined (e.g. you cannot load from a taskqueue thread). +.Pp +On success, .Fn firmware_get returns a pointer to the image description and increases the reference count -for this image. +for this image. On failure, the function returns NULL. .Pp -The function .Fn firmware_put -is used to drop the reference to a firmware image. -The flags argument may be set to +drops a reference to a firmware image. +The +.Fa flags +argument may be set to .Dv FIRMWARE_UNLOAD -to indicate that the caller wishes to unload the corresponding module if the -image becomes unreferenced. +to indicate that +firmware_put is free to reclaim resources associated with +the firmware image if this is the last reference. +.Sh FIRMWARE LOADING MECHANISMS +As mentioned before, any component of the system can register +firmware images at any time by simply calling +.Fn firmware_register . +.Pp +This is typically done when a module containing +a firmware image is given control, +whether compiled in, or preloaded by +.Nm /boot/loader , +or manually loaded with +.Xr kldload 8 . +However, a system can implement additional mechanisms to bring +these images in memory before calling +.Fn firmware_register . +.Pp +When +.Fn firmware_get +does not find the requested image, it tries to load it using +one of the available loading mechanisms. +At the moment, there is only one, namely +.Nm Loadable kernel modules : +.Pp +A firmware image named +.Nm foo +is looked up by trying to load the module named +.Nm foo.ko , +using the facilities described in +.Xr kld 4 . +In particular, images are looked up in the directories specified +by the sysctl variable +.Nm kern.module_path +which on most systems defaults to +.Nm /boot/kernel;/boot/modules . +.Pp +Note that in case a module contains multiple images, +the caller should first request a +.Fn firmware_get +for the first image contained in the module, followed by requests +for the other images. +.Sh BUILDING FIRMWARE LOADABLE MODULES +A firmware module is built by embedding the +.Nm firmware image +into a suitable loadable kernel module that calls +.Fn firmware_register +on loading, and +.Fn firmware_unregister +on unloading. +.Pp +Various system scripts and makefiles let you build a module +by simply writing a Makefile with the following entries: +.Bd -literal + + KMOD= imagename + FIRMWS= image_file:imagename[:version] + .include + +.Ed +where KMOD is the basename of the module; FIRMWS is a list of +colon-separated tuples indicating the image_file's to be embedded +in the module, the imagename and version of each firmware image. +.Pp +If you need to embed firmware images into a system, you should write +appropriate entries in the file, e.g. this example is +from +.Nm sys/arm/xscale/ixp425/files.ixp425: +.Bd -literal +ixp425_npe_fw.c optional npe_fw \\ + compile-with "${AWK} -f $S/tools/fw_stub.awk \\ + IxNpeMicrocode.dat:npe_fw -mnpe -c${.TARGET}" \\ + no-implicit-rule before-depend local \\ + clean "ixp425_npe_fw.c" +# +# NB: ld encodes the path in the binary symbols generated for the +# firmware image so link the file to the object directory to +# get known values for reference in the _fw.c file. +# +IxNpeMicrocode.fwo optional npe_fw \\ + dependency "IxNpeMicrocode.dat" \\ + compile-with "${LD} -b binary -d -warn-common \\ + -r -d -o ${.TARGET} IxNpeMicrocode.dat" \\ + no-implicit-rule \\ + clean "IxNpeMicrocode.fwo" +IxNpeMicrocode.dat optional npe_fw \\ + dependency ".PHONY" \\ + compile-with "if [ -e $S/arm/xscale/ixp425/IxNpeMicrocode.dat ]; \\ + then \\ + ln -sf $S/arm/xscale/ixp425/IxNpeMicrocode.dat .; \\ + else echo 'WARNING, no IxNpeMicrocode.dat file; you must obtain this from the Intel web site'; false; \\ + fi" \\ + no-obj no-implicit-rule \\ + clean "IxNpeMicrocode.dat" +.Ed +.Pp +Note that generating the firmware modules in this way requires +the availability of the following tools: +.Xr awk , +.Xr Make , +the compiler and the linker. .Sh SEE ALSO -.Xr module 9 +.Xr module 9 , +.Xr kld 4 .Pp -.Pa /usr/share/examples/kld +.Pa /usr/share/examples/kld/firmware .Sh HISTORY -The firmware system was introduced in +The +.Nm firmware +system was introduced in .Fx 6.1 . .Sh AUTHORS This manual page was written by Index: namei.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/namei.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/namei.9 -L share/man/man9/namei.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/namei.9 +++ share/man/man9/namei.9 @@ -31,9 +31,9 @@ .\" If you integrate this manpage in another OS, I'd appreciate a note .\" - eivind at FreeBSD.org .\" -.\" $FreeBSD: src/share/man/man9/namei.9,v 1.26.2.1 2005/09/25 18:51:45 rwatson Exp $ +.\" $FreeBSD: src/share/man/man9/namei.9,v 1.29 2005/12/13 17:07:52 ru Exp $ .\" -.Dd May 27, 2003 +.Dd September 21, 2005 .Os .Dt NAMEI 9 .Sh NAME @@ -82,7 +82,7 @@ in which case the caller must later release .Va Giant based on the results of -.Fn NDHASGIANT. +.Fn NDHASGIANT . .Pp The .Fn NDINIT Index: vnode.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vnode.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vnode.9 -L share/man/man9/vnode.9 -u -r1.2 -r1.3 --- share/man/man9/vnode.9 +++ share/man/man9/vnode.9 @@ -25,7 +25,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vnode.9,v 1.29 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd May 20, 2003 .Os From laffer1 at midnightbsd.org Tue Jan 20 15:10:05 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 15:10:05 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/if_ndis: sc->ndis_txidx should be cycle between 0 and Message-ID: <200901202010.n0KKA5Df072609@stargazer.midnightbsd.org> Log Message: ----------- sc->ndis_txidx should be cycle between 0 and sc->ndis_maxpkts, not NDIS_TXPKTS and don't allocate unused extra spaces for sc->ndis_txarray and sc->ndis_txpool. Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.7 -> r1.8) if_ndisvar.h (r1.2 -> r1.3) -------------- next part -------------- Index: if_ndisvar.h =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndisvar.h,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/if_ndis/if_ndisvar.h -L sys/dev/if_ndis/if_ndisvar.h -u -r1.2 -r1.3 --- sys/dev/if_ndis/if_ndisvar.h +++ sys/dev/if_ndis/if_ndisvar.h @@ -87,7 +87,7 @@ #define NDIS_TXPKTS 64 #define NDIS_INC(x) \ - (x)->ndis_txidx = ((x)->ndis_txidx + 1) % NDIS_TXPKTS + (x)->ndis_txidx = ((x)->ndis_txidx + 1) % (x)->ndis_maxpkts #define NDIS_EVENTS 4 #define NDIS_EVTINC(x) (x) = ((x) + 1) % NDIS_EVENTS Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.7 retrieving revision 1.8 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.7 -r1.8 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -643,12 +643,12 @@ sc->ndis_maxpkts = 10; sc->ndis_txarray = malloc(sizeof(ndis_packet *) * - NDIS_TXPKTS, M_DEVBUF, M_NOWAIT|M_ZERO); + sc->ndis_maxpkts, M_DEVBUF, M_NOWAIT|M_ZERO); /* Allocate a pool of ndis_packets for TX encapsulation. */ NdisAllocatePacketPool(&i, &sc->ndis_txpool, - NDIS_TXPKTS, PROTOCOL_RESERVED_SIZE_IN_PACKET); + sc->ndis_maxpkts, PROTOCOL_RESERVED_SIZE_IN_PACKET); if (i != NDIS_STATUS_SUCCESS) { sc->ndis_txpool = NULL; From laffer1 at midnightbsd.org Tue Jan 20 15:13:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 15:13:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Remove FreeBSD_version definition completely. Message-ID: <200901202013.n0KKDtZ8072961@stargazer.midnightbsd.org> Log Message: ----------- Remove FreeBSD_version definition completely. Modified Files: -------------- src/include: Makefile (r1.6 -> r1.7) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/include/Makefile,v retrieving revision 1.6 retrieving revision 1.7 diff -L include/Makefile -L include/Makefile -u -r1.6 -r1.7 --- include/Makefile +++ include/Makefile @@ -85,8 +85,6 @@ echo "#ifdef _KERNEL" >> osreldate.h; \ echo "#error \" cannot be used in the kernel, use \"" >> osreldate.h; \ echo "#else" >> osreldate.h; \ - echo "#undef __FreeBSD_version" >> osreldate.h; \ - echo "#define __FreeBSD_version $$RELDATE" >> osreldate.h; \ echo "#undef __MidnightBSD_version" >> osreldate.h; \ echo "#define __MidnightBSD_version $$RELDATE" >> osreldate.h; \ echo "#endif" >> osreldate.h From laffer1 at midnightbsd.org Tue Jan 20 15:31:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 15:31:48 -0500 (EST) Subject: [Midnightbsd-cvs] mports: config.guess: this still isn't good, but it's at least not Message-ID: <200901202031.n0KKVmap074880@stargazer.midnightbsd.org> Log Message: ----------- this still isn't good, but it's at least not totally wrong Modified Files: -------------- mports/Templates: config.guess (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: config.guess =================================================================== RCS file: /home/cvs/mports/Templates/config.guess,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L Templates/config.guess -L Templates/config.guess -u -r1.1.1.1 -r1.2 --- Templates/config.guess +++ Templates/config.guess @@ -768,22 +768,8 @@ case ${LIBC} in gnu) kernel_only='k' ;; esac echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} exit 0 ;; - *:MidnightBSD:*:*|*:GNU/FreeBSD:*:*) - # Determine whether the default compiler uses glibc. - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - #if __GLIBC__ >= 2 - LIBC=gnu - #else - LIBC= - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` - # GNU/FreeBSD systems have a "k" prefix to indicate we are using - # FreeBSD's kernel, but not the complete OS. - case ${LIBC} in gnu) kernel_only='k' ;; esac - echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} + *:MidnightBSD:*:*) + echo ${UNAME_MACHINE}-unknown-midnightbsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit 0 ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin From laffer1 at midnightbsd.org Tue Jan 20 16:10:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:10:48 -0500 (EST) Subject: [Midnightbsd-cvs] src: pcc/mip: WIP: Update to .99 Message-ID: <200901202110.n0KLAmFT079125@stargazer.midnightbsd.org> Log Message: ----------- WIP: Update to .99 Added Files: ----------- src/usr.bin/pcc/ccom: softfloat.c (r1.1) src/usr.bin/pcc/i386: flocal.c (r1.1) src/usr.bin/pcc/mip: compat.h (r1.1) -------------- next part -------------- --- /dev/null +++ usr.bin/pcc/i386/flocal.c @@ -0,0 +1,234 @@ +/* $Id: flocal.c,v 1.16 2008/12/19 20:26:50 ragge Exp $ */ +/* + * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * Redistributions of source code and documentation must retain the above + * copyright notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditionsand the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed or owned by Caldera + * International, Inc. + * Neither the name of Caldera International, Inc. nor the names of other + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA + * INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE LIABLE + * FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ +#include + +#include "defines.h" +#include "defs.h" + +void +prchars(int *s) +{ + printf("\t.byte 0%o,0%o\n", s[0], s[1]); +} + + +void +setloc(int l) +{ + static int lastloc = -1; + static char *loctbl[] = + { "text", "data", "section .rodata", "section .rodata", "bss" }; + if (l == lastloc) + return; + printf("\t.%s\n", loctbl[l]); + lastloc = l; +} + +#ifdef FCOM + + +/* + PDP11-780/VAX - SPECIFIC PRINTING ROUTINES +*/ + +/* + * Called just before return from a subroutine. + */ +void +goret(int type) +{ +} + +/* + * Print out a label. + */ +void +prlabel(int k) +{ + printf(LABFMT ":\n", k); +} + +/* + * Print naming for location. + * name[0] is location type. + */ +void +prnloc(char *name) +{ + if (*name == '0') + setloc(DATA); + else + fatal("unhandled prnloc %c", *name); + printf("%s:\n", name+1); +} + +/* + * Print integer constant. + */ +void +prconi(FILE *fp, int type, ftnint n) +{ + fprintf(fp, "\t%s\t%ld\n", (type==TYSHORT ? ".word" : ".long"), n); +} + +/* + * Print address constant, given as a label number. + */ +void +prcona(ftnint a) +{ + printf("\t.long\t" LABFMT "\n", (int)a); +} + +/* + * Print out a floating constant. + */ +void +prconr(FILE *fp, int type, double x) +{ + fprintf(fp, "\t%s\t0f%e\n", (type==TYREAL ? ".float" : ".double"), x); +} + +void +preven(int k) +{ + if (k > 1) + printf("\t.align\t%d\n", k); +} + +/* + * Convert a tag and offset into the symtab table to a string. + * An external string is never longer than XL bytes. + */ +char * +memname(int stg, int mem) +{ +#define MLEN (XL + 10) + char *s = malloc(MLEN); + + switch(stg) { + case STGCOMMON: + case STGEXT: + snprintf(s, MLEN, "%s", varstr(XL, extsymtab[mem].extname)); + break; + + case STGBSS: + case STGINIT: + snprintf(s, MLEN, "v.%d", mem); + break; + + case STGCONST: + snprintf(s, MLEN, ".L%d", mem); + break; + + case STGEQUIV: + snprintf(s, MLEN, "q.%d", mem); + break; + + default: + fatal1("memname: invalid vstg %d", stg); + } + return(s); +} + +void +prlocvar(char *s, ftnint len) +{ + printf("\t.lcomm\t%s,%ld\n", s, len); +} + + +void +prext(char *name, ftnint leng, int init) +{ + if(leng == 0) + printf("\t.globl\t%s\n", name); + else + printf("\t.comm\t%s,%ld\n", name, leng); +} + +void +prendproc() +{ +} + +void +prtail() +{ +} + +void +prolog(struct entrypoint *ep, struct bigblock *argvec) +{ + /* Ignore for now. ENTRY is not supported */ +} + + + +void +prdbginfo() +{ +} + +static void +fcheck(NODE *p, void *arg) +{ + NODE *r, *l; + + switch (p->n_op) { + case CALL: /* fix arguments */ + for (r = p->n_right; r->n_op == CM; r = r->n_left) { + r->n_right = mkunode(FUNARG, r->n_right, 0, + r->n_right->n_type); + } + l = talloc(); + *l = *r; + r->n_op = FUNARG; + r->n_left = l; + r->n_type = l->n_type; + break; + } +} + +/* + * Called just before the tree is written out to pass2. + */ +void p2tree(NODE *p); +void +p2tree(NODE *p) +{ + walkf(p, fcheck, 0); +} +#endif /* FCOM */ --- /dev/null +++ usr.bin/pcc/ccom/softfloat.c @@ -0,0 +1,318 @@ +/* $Id: softfloat.c,v 1.2 2008/09/12 16:27:26 ragge Exp $ */ + +/* + * Copyright (c) 2008 Anders Magnusson. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifdef SOFTFLOAT + +#include "manifest.h" +#include "pass1.h" + + +/* + * Floating point emulation to be used when cross-compiling. + * Currently only supports F- and D-float, used in DEC machines. + * Should be trivial to add other emulations. + * + * XXX - assumes that: + * - long long is (at least) 64 bits + * - int is at least 32 bits. + * - short is 16 bits. + */ + +#ifdef FDFLOAT + +/* + * Useful macros to manipulate the float. + */ +#define DSIGN(w) (((w).fd1 >> 15) & 1) +#define DSIGNSET(w,s) ((w).fd1 = (s << 15) | ((w).fd1 & 077777)) +#define DEXP(w) (((w).fd1 >> 7) & 0377) +#define DEXPSET(w,e) ((w).fd1 = (((e) & 0377) << 7) | ((w).fd1 & 0100177)) +#define DMANTH(w) ((w).fd1 & 0177) +#define DMANTHSET(w,m) ((w).fd1 = ((m) & 0177) | ((w).fd1 & 0177600)) + +typedef unsigned int lword; +typedef unsigned long long dword; + +#define MAXMANT 0x100000000000000LL + +/* + * Returns a zero dfloat. + */ +static SF +nulldf(void) +{ + SF rv; + + rv.fd1 = rv.fd2 = rv.fd3 = rv.fd4 = 0; + return rv; +} + +/* + * Convert a (u)longlong to dfloat. + * XXX - fails on too large (> 55 bits) numbers. + */ +SF +soft_cast(CONSZ ll, TWORD t) +{ + int i; + SF rv; + + rv = nulldf(); + if (ll == 0) + return rv; /* fp is zero */ + if (ll < 0) + DSIGNSET(rv,1), ll = -ll; + for (i = 0; ll > 0; i++, ll <<= 1) + ; + DEXPSET(rv, 192-i); + DMANTHSET(rv, ll >> 56); + rv.fd2 = ll >> 40; + rv.fd3 = ll >> 24; + rv.fd4 = ll >> 8; + return rv; +} + +/* + * multiply two dfloat. Use chop, not round. + */ +SF +soft_mul(SF p1, SF p2) +{ + SF rv; + lword a1[2], a2[2], res[4]; + dword sum; + + res[0] = res[1] = res[2] = res[3] = 0; + + /* move mantissa into lwords */ + a1[0] = p1.fd4 | (p1.fd3 << 16); + a1[1] = p1.fd2 | DMANTH(p1) << 16 | 0x800000; + + a2[0] = p2.fd4 | (p2.fd3 << 16); + a2[1] = p2.fd2 | DMANTH(p2) << 16 | 0x800000; + +#define MULONE(x,y,r) sum += (dword)a1[x] * (dword)a2[y]; sum += res[r]; \ + res[r] = sum; sum >>= 32; + + sum = 0; + MULONE(0, 0, 0); + MULONE(1, 0, 1); + res[2] = sum; + sum = 0; + MULONE(0, 1, 1); + MULONE(1, 1, 2); + res[3] = sum; + + rv.fd1 = 0; + DSIGNSET(rv, DSIGN(p1) ^ DSIGN(p2)); + DEXPSET(rv, DEXP(p1) + DEXP(p2) - 128); + if (res[3] & 0x8000) { + res[3] = (res[3] << 8) | (res[2] >> 24); + res[2] = (res[2] << 8) | (res[1] >> 24); + } else { + DEXPSET(rv, DEXP(rv) - 1); + res[3] = (res[3] << 9) | (res[2] >> 23); + res[2] = (res[2] << 9) | (res[1] >> 23); + } + DMANTHSET(rv, res[3] >> 16); + rv.fd2 = res[3]; + rv.fd3 = res[2] >> 16; + rv.fd4 = res[2]; + return rv; +} + +SF +soft_div(SF t, SF n) +{ + SF rv; + dword T, N, K; + int c; + +#define SHL(x,b) ((dword)(x) << b) + T = SHL(1,55) | SHL(DMANTH(t), 48) | + SHL(t.fd2, 32) | SHL(t.fd3, 16) | t.fd4; + N = SHL(1,55) | SHL(DMANTH(n), 48) | + SHL(n.fd2, 32) | SHL(n.fd3, 16) | n.fd4; + + c = T > N; + for (K = 0; (K & 0x80000000000000ULL) == 0; ) { + if (T >= N) { + T -= N; + K |= 1; + } + T <<= 1; + K <<= 1; + } + rv.fd1 = 0; + DSIGNSET(rv, DSIGN(t) ^ DSIGN(n)); + DEXPSET(rv, DEXP(t) - DEXP(n) + 128 + c); + DMANTHSET(rv, K >> 48); + rv.fd2 = K >> 32; + rv.fd3 = K >> 16; + rv.fd4 = K; + return rv; +} + +/* + * Negate a float number. Easy. + */ +SF +soft_neg(SF sf) +{ + int sign = DSIGN(sf) == 0; + DSIGNSET(sf, sign); + return sf; +} + +/* + * Return true if fp number is zero. + */ +int +soft_isz(SF sf) +{ + return (DEXP(sf) == 0); +} + +/* + * Convert a fp number to a CONSZ. + */ +CONSZ +soft_val(SF sf) +{ + CONSZ mant; + int exp = DEXP(sf) - 128; + + mant = SHL(1,55) | SHL(DMANTH(sf), 48) | + SHL(sf.fd2, 32) | SHL(sf.fd3, 16) | sf.fd4; + + while (exp < 0) + mant >>= 1, exp++; + while (exp > 0) + mant <<= 1, exp--; + return mant; +} + +SF +soft_plus(SF x1, SF x2) +{ + cerror("soft_plus"); + return x1; +} + +SF +soft_minus(SF x1, SF x2) +{ + cerror("soft_minus"); + return x1; +} + +/* + * Convert a hex constant to floating point number. + */ +NODE * +fhexcon(char *s) +{ + cerror("fhexcon"); + return NULL; +} + +/* + * Convert a floating-point constant to D-float and store it in a NODE. + */ +NODE * +floatcon(char *s) +{ + NODE *p; + dword mant; + SF fl, flexp, exp5; + int exp, negexp, bexp; + + exp = 0; + mant = 0; +#define ADDTO(sum, val) sum = sum * 10 + val - '0' + for (; *s >= '0' && *s <= '9'; s++) { + if (mant= '0' && *s <= '9'; s++) { + if (mant= '0' && *s <= '9'; s++) + ADDTO(eexp, *s); + if (sign) + eexp = -eexp; + exp = exp + eexp; + } + + negexp = 1; + if (exp<0) { + negexp = -1; + exp = -exp; + } + + + flexp = soft_cast(1, INT); + exp5 = soft_cast(5, INT); + bexp = exp; + fl = soft_cast(mant, INT); + + for (; exp; exp >>= 1) { + if (exp&01) + flexp = soft_mul(flexp, exp5); + exp5 = soft_mul(exp5, exp5); + } + if (negexp<0) + fl = soft_div(fl, flexp); + else + fl = soft_mul(fl, flexp); + + DEXPSET(fl, DEXP(fl) + negexp*bexp); + p = block(FCON, NIL, NIL, DOUBLE, 0, MKSUE(DOUBLE)); /* XXX type */ + p->n_dcon = fl; + return p; +} +#else +#error missing softfloat definition +#endif +#endif --- /dev/null +++ usr.bin/pcc/mip/compat.h @@ -0,0 +1,45 @@ +/* + * Just compatibility function prototypes. + * Public domain. + */ + +#ifndef COMPAT_H +#define COMPAT_H + +#include + +#ifndef HAVE_STRLCPY +size_t strlcpy(char *dst, const char *src, size_t siz); +#endif + +#ifndef HAVE_STRLCAT +size_t strlcat(char *dst, const char *src, size_t siz); +#endif + +#ifndef HAVE_GETOPT +extern char *optarg; +extern int optind; +int getopt(int, char **, char *); +#endif + +#ifndef HAVE_BASENAME +char *basename(char *); +#endif + +#ifndef HAVE_MKSTEMP +int mkstemp(char *); +#endif + +#ifndef HAVE_FFS +int ffs(int); +#endif + +#ifndef HAVE_SNPRINTF +int snprintf(char *str, size_t count, const char *fmt, ...); +#endif + +#ifndef HAVE_VSNPRINTF +int vsnprintf(char *str, size_t count, const char *fmt, va_list args); +#endif + +#endif From laffer1 at midnightbsd.org Tue Jan 20 16:09:44 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:09:44 -0500 (EST) Subject: [Midnightbsd-cvs] src: usr.bin/pcc: WIP: Update to .99 Message-ID: <200901202109.n0KL9iWd078711@stargazer.midnightbsd.org> Log Message: ----------- WIP: Update to .99 Modified Files: -------------- src/usr.bin/pcc: ccconfig.h (r1.1 -> r1.2) config.h (r1.3 -> r1.4) src/usr.bin/pcc/cc: Makefile (r1.8 -> r1.9) cc.c (r1.2 -> r1.3) src/usr.bin/pcc/ccom: Makefile (r1.2 -> r1.3) ccom.1 (r1.1 -> r1.2) cgram.y (r1.1 -> r1.2) gcc_compat.c (r1.1 -> r1.2) init.c (r1.1 -> r1.2) inline.c (r1.1 -> r1.2) main.c (r1.2 -> r1.3) optim.c (r1.1 -> r1.2) pass1.h (r1.1 -> r1.2) pftn.c (r1.1 -> r1.2) scan.l (r1.1 -> r1.2) stabs.c (r1.1 -> r1.2) symtabs.c (r1.1 -> r1.2) trees.c (r1.1 -> r1.2) src/usr.bin/pcc/cpp: Makefile (r1.6 -> r1.7) cpp.c (r1.3 -> r1.4) cpp.h (r1.2 -> r1.3) cpy.y (r1.1 -> r1.2) scanner.l (r1.1 -> r1.2) token.c (r1.1 -> r1.2) src/usr.bin/pcc/i386: code.c (r1.1 -> r1.2) local.c (r1.1 -> r1.2) local2.c (r1.1 -> r1.2) macdefs.h (r1.1 -> r1.2) order.c (r1.1 -> r1.2) table.c (r1.1 -> r1.2) src/usr.bin/pcc/mip: common.c (r1.1 -> r1.2) compat.c (r1.1 -> r1.2) manifest.h (r1.1 -> r1.2) match.c (r1.1 -> r1.2) mkext.c (r1.1 -> r1.2) node.h (r1.1 -> r1.2) optim2.c (r1.1 -> r1.2) pass2.h (r1.1 -> r1.2) protos.h (r1.1 -> r1.2) reader.c (r1.1 -> r1.2) regs.c (r1.1 -> r1.2) Added Files: ----------- src/usr.bin/pcc/amd64: code.c (r1.1) local.c (r1.1) local2.c (r1.1) macdefs.h (r1.1) order.c (r1.1) table.c (r1.1) src/usr.bin/pcc/cpp: pcpp.1 (r1.1) src/usr.bin/pcc/sparc64: code.c (r1.1) local.c (r1.1) local2.c (r1.1) macdefs.h (r1.1) order.c (r1.1) table.c (r1.1) Removed Files: ------------- src/usr.bin/pcc/cpp: cpp.1 -------------- next part -------------- --- /dev/null +++ usr.bin/pcc/amd64/order.c @@ -0,0 +1,273 @@ +/* $Id: order.c,v 1.1 2008/11/27 05:25:15 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +# include "pass2.h" + +#include + +int canaddr(NODE *); + +/* is it legal to make an OREG or NAME entry which has an + * offset of off, (from a register of r), if the + * resulting thing had type t */ +int +notoff(TWORD t, int r, CONSZ off, char *cp) +{ + return(0); /* YES */ +} + +/* + * Turn a UMUL-referenced node into OREG. + * Be careful about register classes, this is a place where classes change. + */ +void +offstar(NODE *p, int shape) +{ + NODE *r; + + if (x2debug) + printf("offstar(%p)\n", p); + + if (isreg(p)) + return; /* Is already OREG */ + + r = p->n_right; + if( p->n_op == PLUS || p->n_op == MINUS ){ + if( r->n_op == ICON ){ + if (isreg(p->n_left) == 0) + (void)geninsn(p->n_left, INAREG); + /* Converted in ormake() */ + return; + } + if (r->n_op == LS && r->n_right->n_op == ICON && + r->n_right->n_lval == 2 && p->n_op == PLUS) { + if (isreg(p->n_left) == 0) + (void)geninsn(p->n_left, INAREG); + if (isreg(r->n_left) == 0) + (void)geninsn(r->n_left, INAREG); + return; + } + } + (void)geninsn(p, INAREG); +} + +/* + * Do the actual conversion of offstar-found OREGs into real OREGs. + */ +void +myormake(NODE *q) +{ + NODE *p, *r; + + if (x2debug) + printf("myormake(%p)\n", q); + + p = q->n_left; + if (p->n_op == PLUS && (r = p->n_right)->n_op == LS && + r->n_right->n_op == ICON && r->n_right->n_lval == 2 && + p->n_left->n_op == REG && r->n_left->n_op == REG) { + q->n_op = OREG; + q->n_lval = 0; + q->n_rval = R2PACK(p->n_left->n_rval, r->n_left->n_rval, 0); + tfree(p); + } +} + +/* + * Shape matches for UMUL. Cooperates with offstar(). + */ +int +shumul(NODE *p, int shape) +{ + + if (x2debug) + printf("shumul(%p)\n", p); + + /* Turns currently anything into OREG on x86 */ + if (shape & SOREG) + return SROREG; + return SRNOPE; +} + +/* + * Rewrite operations on binary operators (like +, -, etc...). + * Called as a result of table lookup. + */ +int +setbin(NODE *p) +{ + + if (x2debug) + printf("setbin(%p)\n", p); + return 0; + +} + +/* setup for assignment operator */ +int +setasg(NODE *p, int cookie) +{ + if (x2debug) + printf("setasg(%p)\n", p); + return(0); +} + +/* setup for unary operator */ +int +setuni(NODE *p, int cookie) +{ + return 0; +} + +/* + * Special handling of some instruction register allocation. + */ +struct rspecial * +nspecial(struct optab *q) +{ + switch (q->op) { + case OPLOG: + { + static struct rspecial s[] = { { NEVER, EAX }, { 0 } }; + return s; + } + + case STASG: + case STARG: + { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NEVER, ECX }, { 0 } }; + return s; + } + + case DIV: + if (q->lshape == SBREG) { + static struct rspecial s[] = { + { NEVER, AL }, { NEVER, AH }, + { NLEFT, AL }, { NRES, AL }, + { NORIGHT, AH }, { NORIGHT, AL }, { 0 } }; + return s; + } else if (q->lshape == SAREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NLEFT, EAX }, { NRES, EAX }, + { NORIGHT, EDX }, { NORIGHT, EAX }, { 0 } }; + return s; + } else if (q->lshape & SCREG) { + static struct rspecial s[] = { + { NEVER, RAX }, { NEVER, RDX }, + { NLEFT, RAX }, { NRES, RAX }, + { NORIGHT, RDX }, { NORIGHT, RAX }, { 0 } }; + return s; + } + break; + case MOD: + if (q->lshape == SBREG) { + static struct rspecial s[] = { + { NEVER, AL }, { NEVER, AH }, + { NLEFT, AL }, { NRES, AH }, + { NORIGHT, AH }, { NORIGHT, AL }, { 0 } }; + return s; + } else if (q->lshape == SAREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NLEFT, EAX }, { NRES, EDX }, + { NORIGHT, EDX }, { NORIGHT, EAX }, { 0 } }; + return s; + } else if (q->lshape & SCREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NEVER, ECX }, { NRES, RAX }, { 0 } }; + return s; + } + break; + case MUL: + if (q->lshape == SBREG) { + static struct rspecial s[] = { + { NEVER, AL }, { NEVER, AH }, + { NLEFT, AL }, { NRES, AL }, { 0 } }; + return s; + } else if (q->lshape & SCREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NEVER, ECX }, { NRES, RAX }, { 0 } }; + return s; + } + break; + case LS: + case RS: + static struct rspecial s[] = { + { NRIGHT, CL }, { NOLEFT, RCX }, { 0 } }; + return s; + break; + + default: + break; + } + comperr("nspecial entry %d", q - table); + return 0; /* XXX gcc */ +} + +/* + * Set evaluation order of a binary node if it differs from default. + */ +int +setorder(NODE *p) +{ + return 0; /* nothing differs on x86 */ +} + +/* + * set registers in calling conventions live. + */ +int * +livecall(NODE *p) +{ + static int r[] = { EAX, EBX, -1 }; + int off = 1; + +#ifdef TLS + if (p->n_left->n_op == ICON && + strcmp(p->n_left->n_name, "___tls_get_addr at PLT") == 0) + off--; +#endif + + return kflag ? &r[off] : &r[2]; +} + +/* + * Signal whether the instruction is acceptable for this target. + */ +int +acceptable(struct optab *op) +{ + return 1; +} --- /dev/null +++ usr.bin/pcc/amd64/macdefs.h @@ -0,0 +1,337 @@ +/* $Id: macdefs.h,v 1.2 2008/12/10 17:59:30 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* + * Machine-dependent defines for both passes. + */ + +/* + * Convert (multi-)character constant to integer. + */ +#define makecc(val,i) lastcon = (lastcon<<8)|((val<<24)>>24); + +#define ARGINIT 64 /* # bits above fp where arguments start */ +#define AUTOINIT 0 /* # bits below fp where automatics start */ + +/* + * Storage space requirements + */ +#define SZCHAR 8 +#define SZBOOL 8 +#define SZSHORT 16 +#define SZINT 32 +#define SZLONG 64 +#define SZPOINT(t) 64 +#define SZLONGLONG 64 +#define SZFLOAT 32 +#define SZDOUBLE 64 +#define SZLDOUBLE 128 + +/* + * Alignment constraints + */ +#define ALCHAR 8 +#define ALBOOL 8 +#define ALSHORT 16 +#define ALINT 32 +#define ALLONG 64 +#define ALPOINT 64 +#define ALLONGLONG 64 +#define ALFLOAT 32 +#define ALDOUBLE 64 +#define ALLDOUBLE 128 +#define ALSTRUCT 128 +#define ALSTACK 64 +#define ALMAX 128 + +/* + * Min/max values. + */ +#define MIN_CHAR -128 +#define MAX_CHAR 127 +#define MAX_UCHAR 255 +#define MIN_SHORT -32768 +#define MAX_SHORT 32767 +#define MAX_USHORT 65535 +#define MIN_INT (-0x7fffffff-1) +#define MAX_INT 0x7fffffff +#define MAX_UNSIGNED 0xffffffff +#define MIN_LONG MIN_LONGLONG +#define MAX_LONG MAX_LONGLONG +#define MAX_ULONG MAX_ULONGLONG +#define MIN_LONGLONG 0x8000000000000000LL +#define MAX_LONGLONG 0x7fffffffffffffffLL +#define MAX_ULONGLONG 0xffffffffffffffffULL + +/* Default char is signed */ +#undef CHAR_UNSIGNED +#define BOOL_TYPE CHAR /* what used to store _Bool */ +#if defined(os_mirbsd) || defined(os_win32) +#define WCHAR_TYPE USHORT /* ISO 10646 16-bit Unicode */ +#else +#define WCHAR_TYPE INT /* what used to store wchar_t */ +#endif + +/* + * Use large-enough types. + */ +typedef long long CONSZ; +typedef unsigned long long U_CONSZ; +typedef long long OFFSZ; + +#define CONFMT "%lld" /* format for printing constants */ +#define LABFMT ".L%d" /* format for printing labels */ +#define STABLBL ".LL%d" /* format for stab (debugging) labels */ +#ifdef LANG_F77 +#define BLANKCOMMON "_BLNK_" +#define MSKIREG (M(TYSHORT)|M(TYLONG)) +#define TYIREG TYLONG +#define FSZLENG FSZLONG +#define AUTOREG EBP +#define ARGREG EBP +#define ARGOFFSET 8 +#endif + +#define BACKAUTO /* stack grows negatively for automatics */ +#define BACKTEMP /* stack grows negatively for temporaries */ + +#undef FIELDOPS /* no bit-field instructions */ +#define RTOLBYTES /* bytes are numbered right to left */ + +#define ENUMSIZE(high,low) INT /* enums are always stored in full int */ + +#define FINDMOPS /* i386 has instructions that modifies memory */ + +/* Definitions mostly used in pass2 */ + +#define BYTEOFF(x) ((x)&03) +#define wdal(k) (BYTEOFF(k)==0) +#define BITOOR(x) (x) /* bit offset to oreg offset XXX die! */ + +#define STOARG(p) +#define STOFARG(p) +#define STOSTARG(p) +#define genfcall(a,b) gencall(a,b) + +#define szty(t) (((t) == DOUBLE || (t) == FLOAT || (t) == LONG || \ + (t) == ULONG || (t) == LONGLONG || (t) == ULONGLONG) ? 2 : \ + (t) == LDOUBLE ? 4 : 1) + +/* + * The x86 has a bunch of register classes, most of them interfering + * with each other. All registers are given a sequential number to + * identify it which must match rnames[] in local2.c. + * Class membership and overlaps are defined in the macros RSTATUS + * and ROVERLAP below. + * + * The classes used on x86 are: + * A - short and int regs + * B - char regs + * C - long long regs + * D - floating point + */ +#define EAX 000 /* Scratch and return register */ +#define EDX 001 /* Scratch and secondary return register */ +#define ECX 002 /* Scratch (and shift count) register */ +#define EBX 003 /* GDT pointer or callee-saved temporary register */ +#define ESI 004 /* Callee-saved temporary register */ +#define EDI 005 /* Callee-saved temporary register */ +#define EBP 006 /* Frame pointer */ +#define ESP 007 /* Stack pointer */ + +#define AL 010 +#define AH 011 +#define DL 012 +#define DH 013 +#define CL 014 +#define CH 015 +#define BL 016 +#define BH 017 + +#define RAX 020 +#define RDX 021 +#define RCX 022 +#define RBX 023 +#define RSI 024 +#define RDI 025 +#define RBP 026 +#define RSP 027 +#define R08 030 +#define R09 031 +#define R10 032 +#define R11 033 +#define R12 034 +#define R13 035 +#define R14 036 +#define R15 037 + +/* The 8 math registers in class D lacks names */ + +#define MAXREGS 050 /* 40 registers */ + +#define RSTATUS \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|PERMREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, 0, 0, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, 0, 0, \ + SCREG|TEMPREG, SCREG|TEMPREG, SCREG|TEMPREG, SCREG|TEMPREG, \ + SCREG|PERMREG, SCREG|PERMREG, SCREG|PERMREG, SCREG|PERMREG, \ + SDREG, SDREG, SDREG, SDREG, SDREG, SDREG, SDREG, SDREG, + +#define ROVERLAP \ + /* 8 basic registers */\ + { AL, AH, RAX, -1 },\ + { DL, DH, RDX, -1 },\ + { CL, CH, RCX, -1 },\ + { BL, BH, RBX, -1 },\ + { RSI, -1 },\ + { RDI, -1 },\ + { RBP, -1 },\ + { RSP, -1 },\ +\ + /* 8 char registers */\ + { EAX, RAX, -1 },\ + { EAX, RAX, -1 },\ + { EDX, RDX, -1 },\ + { EDX, RDX, -1 },\ + { ECX, RCX, -1 },\ + { ECX, RCX, -1 },\ + { EBX, RBX, -1 },\ + { EBX, RBX, -1 },\ +\ + /* 16 long-long-emulating registers */\ + { EAX, AL, AH, -1 },\ + { EDX, DL, DH, -1 },\ + { ECX, CL, CH, -1 },\ + { EBX, BL, BH, -1 },\ + { ESI, -1 },\ + { EDI, -1 },\ + { EBP, -1 },\ + { ESP, -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ +\ + /* The fp registers do not overlap with anything */\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 }, + + +/* Return a register class based on the type of the node */ +#define PCLASS(p) (p->n_type <= UCHAR ? SBREG : \ + (p->n_type == LONG || p->n_type == ULONG || \ + p->n_type == LONGLONG || p->n_type == ULONGLONG ? SCREG : \ + (p->n_type >= FLOAT && p->n_type <= LDOUBLE ? SDREG : SAREG))) + +#define NUMCLASS 4 /* highest number of reg classes used */ + +int COLORMAP(int c, int *r); +#define GCLASS(x) (x < 8 ? CLASSA : x < 16 ? CLASSB : x < 32 ? CLASSC : CLASSD) +#define DECRA(x,y) (((x) >> (y*8)) & 255) /* decode encoded regs */ +#define ENCRD(x) (x) /* Encode dest reg in n_reg */ +#define ENCRA1(x) ((x) << 8) /* A1 */ +#define ENCRA2(x) ((x) << 16) /* A2 */ +#define ENCRA(x,y) ((x) << (8+y*8)) /* encode regs in int */ +/* XXX - return char in al? */ +#define RETREG(x) (x == CHAR || x == UCHAR ? AL : \ + x == LONG || x == ULONG || \ + x == LONGLONG || x == ULONGLONG ? RAX : \ + x == FLOAT || x == DOUBLE || x == LDOUBLE ? 32 : EAX) + +//#define R2REGS 1 /* permit double indexing */ + +/* XXX - to die */ +#define FPREG RBP /* frame pointer */ +#define STKREG RSP /* stack pointer */ + +#define SHSTR (MAXSPECIAL+1) /* short struct */ +#define SFUNCALL (MAXSPECIAL+2) /* struct assign after function call */ +#define SPCON (MAXSPECIAL+3) /* positive nonnamed constant */ + +/* + * Specials that indicate the applicability of machine idioms. + */ +#define SMIXOR (MAXSPECIAL+4) +#define SMILWXOR (MAXSPECIAL+5) +#define SMIHWXOR (MAXSPECIAL+6) + +/* + * i386-specific symbol table flags. + */ +#define SSECTION SLOCAL1 +#define STLS SLOCAL2 +#define SNOUNDERSCORE SLOCAL3 +#define SSTDCALL SLOCAL2 +#define SDLLINDIRECT SLOCAL3 + +/* + * i386-specific node flags. + */ +#define FSTDCALL 0x01 + +/* + * i386-specific interpass stuff. + */ + +#define TARGET_IPP_MEMBERS \ + int ipp_argstacksize; + +/* + * Extended assembler macros. + */ +void targarg(char *w, void *arg); +#define XASM_TARGARG(w, ary) \ + (w[1] == 'b' || w[1] == 'h' || w[1] == 'w' || w[1] == 'k' ? \ + w++, targarg(w, ary), 1 : 0) +int numconv(void *ip, void *p, void *q); +#define XASM_NUMCONV(ip, p, q) numconv(ip, p, q) + +/* + * builtins. + */ +#define TARGET_BUILTINS \ + { "__builtin_frame_address", i386_builtin_frame_address }, \ + { "__builtin_return_address", i386_builtin_return_address }, + +#define NODE struct node +struct node; +NODE *i386_builtin_frame_address(NODE *f, NODE *a); +NODE *i386_builtin_return_address(NODE *f, NODE *a); +#undef NODE --- /dev/null +++ usr.bin/pcc/amd64/table.c @@ -0,0 +1,1568 @@ +/* $Id: table.c,v 1.1 2008/11/27 05:25:15 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +# include "pass2.h" + +# define TLL TLONG|TULONG|TLONGLONG|TULONGLONG +# define ANYSIGNED TINT|TSHORT|TCHAR +# define ANYUSIGNED TUNSIGNED|TUSHORT|TUCHAR +# define ANYFIXED ANYSIGNED|ANYUSIGNED +# define TUWORD TUNSIGNED +# define TSWORD TINT +# define TWORD TUWORD|TSWORD +#define SHINT SAREG /* short and int */ +#define ININT INAREG +#define SHCH SBREG /* shape for char */ +#define INCH INBREG +#define SHLL SCREG /* shape for long long */ +#define INLL INCREG +#define SHFL SDREG /* shape for float/double */ +#define INFL INDREG /* shape for float/double */ + +struct optab table[] = { +/* First entry must be an empty entry */ +{ -1, FOREFF, SANY, TANY, SANY, TANY, 0, 0, "", }, + +/* PCONVs are usually not necessary */ +{ PCONV, INAREG, + SAREG, TWORD|TPOINT, + SAREG, TWORD|TPOINT, + 0, RLEFT, + "", }, + +/* + * A bunch conversions of integral<->integral types + * There are lots of them, first in table conversions to itself + * and then conversions from each type to the others. + */ + +/* itself to itself, including pointers */ + +/* convert (u)char to (u)char. */ +{ SCONV, INCH, + SHCH, TCHAR|TUCHAR, + SHCH, TCHAR|TUCHAR, + 0, RLEFT, + "", }, + +/* convert pointer to (u)longlong. */ +{ SCONV, INLL, + SHLL, TLL|TPOINT, + SHLL, TLL, + 0, RLEFT, + "", }, + +/* convert double <-> float. nothing to do here */ +{ SCONV, INFL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + "", }, + +/* convert pointers to pointers and ints. */ +{ SCONV, ININT, + SHINT, TPOINT|TWORD, + SANY, TPOINT, + 0, RLEFT, + "", }, + +/* char to something */ + +/* convert char to (unsigned) short. */ +{ SCONV, ININT, + SBREG|SOREG|SNAME, TCHAR, + SAREG, TSHORT|TUSHORT, + NASL|NAREG, RESC1, + " movsbw AL,A1\n", }, + +/* convert unsigned char to (u)short. */ +{ SCONV, ININT, + SHCH|SOREG|SNAME, TUCHAR, + SAREG, TSHORT|TUSHORT, + NASL|NAREG, RESC1, + " movzbw AL,A1\n", }, + +/* convert signed char to int (or pointer). */ +{ SCONV, ININT, + SHCH|SOREG|SNAME, TCHAR, + SAREG, TWORD|TPOINT, + NASL|NAREG, RESC1, + " movsbl AL,A1\n", }, + +/* convert unsigned char to (u)int. */ +{ SCONV, ININT, + SHCH|SOREG|SNAME, TUCHAR, + SAREG, TWORD, + NASL|NAREG, RESC1, + " movzbl AL,A1\n", }, + +/* convert char to (u)long long */ +{ SCONV, INLL, + SHCH|SOREG|SNAME, TCHAR, + SANY, TLL, + NCREG|NCSL, RESC1, + " movsbq AL,A1\n", }, + +/* convert unsigned char to (u)long long */ +{ SCONV, INLL, + SHCH|SOREG|SNAME, TUCHAR, + SANY, TLL, + NCREG|NCSL, RESC1, + " movzbq AL,A1\n", }, + +/* convert char (in register) to double XXX - use NTEMP */ +{ SCONV, INFL, + SHCH|SOREG|SNAME, TCHAR, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NAREG|NASL|NDREG, RESC2, + " movsbl AL,A1\n pushl A1\n" /* XXX fpconv */ + " fildl (%rsp)\n addl $8,%rsp\n", }, + +/* convert (u)char (in register) to double XXX - use NTEMP */ +{ SCONV, INFL, + SHCH|SOREG|SNAME, TUCHAR, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NAREG|NASL|NDREG, RESC2, + " movzbl AL,A1\n pushl A1\n" /* XXX fpconv */ + " fildl (%rsp)\n addl $8,%rsp\n", }, + +/* short to something */ + +/* convert short (in memory) to char */ +{ SCONV, INCH, + SNAME|SOREG, TSHORT|TUSHORT, + SHCH, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + " movb AL,A1\n", }, + +/* convert short (in reg) to char. */ +{ SCONV, INCH, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL|NBREG|NBSL, RESC1, + "ZM", }, + +/* convert short to (u)int. */ +{ SCONV, ININT, + SAREG|SOREG|SNAME, TSHORT, + SAREG, TWORD, + NASL|NAREG, RESC1, + " movswl AL,A1\n", }, + +/* convert unsigned short to (u)int. */ +{ SCONV, ININT, + SAREG|SOREG|SNAME, TUSHORT, + SAREG, TWORD, + NASL|NAREG, RESC1, + " movzwl AL,A1\n", }, + +/* convert short to (u)long long */ +{ SCONV, INLL, + SAREG|SOREG|SNAME, TSHORT, + SHLL, TLL, + NCREG|NCSL, RESC1, + " movswq AL,A1\n", }, + +/* convert unsigned short to (u)long long */ +{ SCONV, INLL, + SAREG|SOREG|SNAME, TUSHORT, + SHLL, TLL, + NCREG|NCSL, RESC1, + " movzwq AL,A1\n", }, + +/* convert short (in memory) to float/double */ +{ SCONV, INFL, + SOREG|SNAME, TSHORT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, + " fild AL\n", }, /* XXX fpconv */ + +/* convert short (in register) to float/double */ +{ SCONV, INFL, + SAREG, TSHORT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NTEMP|NDREG, RESC1, /* XXX fpconv */ + " pushw AL\n fild (%rsp)\n addl $8,%rsp\n", }, + +/* convert unsigned short to double XXX - use NTEMP */ +{ SCONV, INFL, + SAREG|SOREG|SNAME, TUSHORT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NAREG|NASL|NDREG|NTEMP, RESC2, + " movzwl AL,A1\n pushl A1\n" /* XXX fpconv */ + " fildl (%rsp)\n addl $8,%esp\n", }, + +/* int to something */ + +/* convert int to char. This is done when register is loaded */ +{ SCONV, INCH, + SAREG, TWORD|TPOINT, + SANY, TCHAR|TUCHAR, + NSPECIAL|NBREG|NBSL, RESC1, + "ZM", }, + +/* convert int to short. Nothing to do */ +{ SCONV, INAREG, + SAREG, TWORD, + SANY, TSHORT|TUSHORT, + 0, RLEFT, + "", }, + +/* convert signed int to (u)long long */ +{ SCONV, INLL, + SHINT, TSWORD, + SHLL, TLL, + NSPECIAL|NCREG|NCSL, RESC1, + " cltd\n", }, + +/* convert unsigned int to (u)long long */ +{ SCONV, INLL, + SHINT|SOREG|SNAME, TUWORD|TPOINT, + SHLL, TLL, + NCSL|NCREG, RESC1, + " movzlq AL,A1\n\n", }, + +/* convert int (in memory) to double */ +{ SCONV, INFL, + SOREG|SNAME, TWORD, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, + " fildl AL\n", }, + +/* convert int (in register) to double */ +{ SCONV, INFL, + SAREG, TWORD, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NTEMP|NDREG, RESC1, /* XXX fpconv */ + " pushl AL\n fildl (%esp)\n addl $8,%esp\n", }, + +/* long long to something */ + +/* convert (u)long long to (u)char (mem->reg) */ +{ SCONV, INCH, + SOREG|SNAME, TLL, + SANY, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + " movb AL,A1\n", }, + +/* convert (u)long long to (u)char (reg->reg, hopefully nothing) */ +{ SCONV, INCH, + SHLL, TLL, + SANY, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + "ZS", }, + +/* convert (u)long long to (u)short (mem->reg) */ +{ SCONV, INAREG, + SOREG|SNAME, TLL, + SAREG, TSHORT|TUSHORT, + NAREG|NASL, RESC1, + " movw AL,A1\n", }, + +/* convert (u)long long to (u)short (reg->reg, hopefully nothing) */ +{ SCONV, INAREG, + SHLL|SOREG|SNAME, TLL, + SAREG, TSHORT|TUSHORT, + NAREG|NASL, RESC1, + "ZS", }, + +/* convert long long to int (mem->reg) */ +{ SCONV, INAREG, + SOREG|SNAME, TLL, + SAREG, TWORD|TPOINT, + NAREG|NASL, RESC1, + " movl AL,A1\n", }, + +/* convert long long to int (reg->reg, hopefully nothing) */ +{ SCONV, INAREG, + SHLL|SOREG|SNAME, TLL, + SAREG, TWORD|TPOINT, + NAREG|NASL, RESC1, + "ZS", }, + +/* convert long long (in memory) to floating */ +{ SCONV, INFL, + SOREG|SNAME, TLONGLONG, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, /* XXX fpconv */ + " fildq AL\n", }, + +/* convert long long (in register) to floating */ +{ SCONV, INFL, + SHLL, TLONGLONG, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NTEMP|NDREG, RESC1, /* XXX fpconv */ + " pushq AL\n\n" + " fildq (%esp)\n addl $8,%esp\n", }, + +/* convert unsigned long long to floating */ +{ SCONV, INFL, + SCREG, TULONGLONG, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, /* XXX fpconv */ + "ZJ", }, + +/* float to something */ + +#if 0 /* go via int by adding an extra sconv in clocal() */ +/* convert float/double to (u) char. XXX should use NTEMP here */ +{ SCONV, INCH, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHCH, TWORD|TSHORT|TUSHORT|TCHAR|TUCHAR, + NBREG, RESC1, /* XXX fpconv */ + " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, + +/* convert float/double to (u) int/short/char. XXX should use NTEMP here */ +{ SCONV, INCH, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHCH, TWORD|TSHORT|TUSHORT|TCHAR|TUCHAR, + NCREG, RESC1, /* XXX fpconv */ + " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, +#endif + +/* convert float/double to (u)int. XXX should use NTEMP here */ +{ SCONV, INAREG, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SAREG, TWORD, + NAREG, RESC1, /* XXX fpconv */ +#ifdef notdef /* Must round down and nothing else */ + " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, +#else + " subl $12,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpl 8(%esp)\n" + " movl 8(%esp),A1\n" + " fldcw 4(%esp)\n" + " addl $12,%esp\n", }, +#endif + +/* convert float/double (in register) to (unsigned) long long */ +/* XXX - unsigned is not handled correct */ +{ SCONV, INLL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHLL, TLONGLONG|TULONGLONG, + NCREG, RESC1, /* XXX fpconv */ +#ifdef notdef /* Must round down and nothing else */ + " subl $8,%esp\n fistpq (%esp)\n" + " popl A1\n popl U1\n", }, +#else + " subl $16,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpq 8(%esp)\n" + " movl 8(%esp),A1\n" + " movl 12(%esp),U1\n" + " fldcw 4(%esp)\n" + " addl $16,%esp\n", }, +#endif + +/* slut sconv */ + +/* + * Subroutine calls. + */ + +{ CALL, FOREFF, + SCON, TANY, + SANY, TANY, + 0, 0, + " call CL\nZC", }, + +{ UCALL, FOREFF, + SCON, TANY, + SAREG, TWORD|TPOINT, + 0, 0, + " call CL\n", }, + +{ CALL, INAREG, + SCON, TANY, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INAREG, + SCON, TANY, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\n", }, + +{ CALL, INBREG, + SCON, TANY, + SBREG, TCHAR|TUCHAR, + NBREG, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INBREG, + SCON, TANY, + SBREG, TCHAR|TUCHAR, + NBREG, RESC1, /* should be 0 */ + " call CL\n", }, + +{ CALL, INCREG, + SCON, TANY, + SCREG, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INCREG, + SCON, TANY, + SCREG, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call CL\n", }, + +{ CALL, INDREG, + SCON, TANY, + SDREG, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INDREG, + SCON, TANY, + SDREG, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ CALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call *AL\nZC", }, + +{ UCALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call *AL\nZC", }, + +{ CALL, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ CALL, INBREG, + SAREG, TANY, + SANY, TANY, + NBREG|NBSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INBREG, + SAREG, TANY, + SANY, TANY, + NBREG|NBSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ CALL, INCREG, + SAREG, TANY, + SANY, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INCREG, + SAREG, TANY, + SANY, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ CALL, INDREG, + SAREG, TANY, + SANY, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INDREG, + SAREG, TANY, + SANY, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +/* struct return */ +{ USTCALL, FOREFF, + SCON, TANY, + SANY, TANY, + NAREG|NASL, 0, + " call CL\nZC", }, + +{ USTCALL, INAREG, + SCON, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ USTCALL, INAREG, + SNAME|SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ STCALL, FOREFF, + SCON, TANY, + SANY, TANY, + NAREG|NASL, 0, + " call CL\nZC", }, + +{ STCALL, INAREG, + SCON, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ STCALL, INAREG, + SNAME|SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +/* + * The next rules handle all binop-style operators. + */ +{ PLUS, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " faddl AR\n", }, + +{ PLUS, INFL|FOREFF, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " faddp\n", }, + +{ PLUS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL|TPOINT, + SONE, TANY, + 0, RLEFT, + " incq AL\n", }, + +{ PLUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SONE, TANY, + 0, RLEFT, + " incl AL\n", }, + +{ PLUS, INLL, + SCREG, TLL|TPOINT, + SCON, TWORD, + NCREG|NCSL, RESC1, + " leaq CR(AL),A1\n", }, + +{ PLUS, INAREG, + SAREG, TWORD, + SCON, TANY, + NAREG|NASL, RESC1, + " leal CR(AL),A1\n", }, + +{ PLUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " incw AL\n", }, + +{ PLUS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SONE, TANY, + 0, RLEFT, + " incb AL\n", }, + +{ PLUS, INAREG, + SAREG, TWORD, + SAREG, TWORD, + NAREG|NASL|NASR, RESC1, + " leal (AL,AR),A1\n", }, + +{ MINUS, INLL|FOREFF, + SCREG|SNAME|SOREG, TLL|TPOINT, + SONE, TANY, + 0, RLEFT, + " decq AL\n", }, + +{ MINUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SONE, TANY, + 0, RLEFT, + " decl AL\n", }, + +{ MINUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " decw AL\n", }, + +{ MINUS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SONE, TANY, + 0, RLEFT, + " decb AL\n", }, + +/* address as register offset, negative */ +{ MINUS, INAREG, + SAREG, TWORD|TPOINT, + SPCON, TANY, + NAREG|NASL, RESC1, + " leal -CR(AL),A1\n", }, + +{ MINUS, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " fsubl AR\n", }, + +{ MINUS, INFL|FOREFF, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fsubZAp\n", }, + +/* Simple r/m->reg ops */ +/* m/r |= r */ +{ OPSIMP, INLL|FOREFF|FORCC, + SHLL|SNAME|SOREG, TLL|TPOINT, + SHLL, TLL|TPOINT, + 0, RLEFT|RESCC, + " Oq AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INLL|FOREFF|FORCC, + SHLL, TLL|TPOINT, + SHLL|SNAME|SOREG, TLL|TPOINT, + 0, RLEFT|RESCC, + " Oq AR,AL\n", }, + +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD, + SAREG, TWORD, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG, TWORD|TPOINT, + SAREG|SNAME|SOREG, TWORD|TPOINT, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + SHINT, TSHORT|TUSHORT, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT, TSHORT|TUSHORT, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +/* m/r |= r */ +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* m/r |= const */ +{ OPSIMP, INLL|FOREFF|FORCC, + SCREG|SNAME|SOREG, TLL, + SCON, TWORD, + 0, RLEFT|RESCC, + " Oq AR,AL\n", }, + +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD, + SCON, TWORD, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + SCON, TANY, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SCON, TANY, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INLL|FOREFF, + SHLL, TLL|TPOINT, + SHLL|SNAME|SOREG, TLL|TPOINT, + 0, RLEFT, + " Oq AR,AL\n", }, + +/* + * The next rules handle all shift operators. + */ +/* r/m <<= r */ +{ LS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL, + SHLL, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " salq AR,AL\n", }, + +/* r/m <<= const */ +{ LS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL, + SCON, TANY, + 0, RLEFT, + " salq AR,AL\n", }, + +/* r/m <<= r */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sall AR,AL\n", }, + +/* r/m <<= const */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SCON, TANY, + 0, RLEFT, + " sall AR,AL\n", }, + +/* r/m <<= r */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shlw AR,AL\n", }, + +/* r/m <<= const */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SCON, TANY, + 0, RLEFT, + " shlw AR,AL\n", }, + +{ LS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " salb AR,AL\n", }, + +{ LS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SCON, TANY, + 0, RLEFT, + " salb AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLONG|TLONGLONG, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarq AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLONG|TLONGLONG, + SCON, TANY, + 0, RLEFT, + " sarq AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TULONG|TULONGLONG, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrq AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TULONG|TULONGLONG, + SCON, TANY, + 0, RLEFT, + " shrq AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSWORD, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSWORD, + SCON, TANY, + 0, RLEFT, + " sarl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUWORD, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUWORD, + SCON, TANY, + 0, RLEFT, + " shrl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarw AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT, + SCON, TANY, + 0, RLEFT, + " sarw AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrw AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUSHORT, + SCON, TANY, + 0, RLEFT, + " shrw AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarb AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR, + SCON, TANY, + 0, RLEFT, + " sarb AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TUCHAR, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrb AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TUCHAR, + SCON, TANY, + 0, RLEFT, + " shrb AR,AL\n", }, + +/* + * The next rules takes care of assignments. "=". + */ +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL|TPOINT, + SMIXOR, TANY, + 0, RDEST, + " xorq AL,AL\n\n", }, + +{ ASSIGN, FOREFF|INLL, + SHLL, TLL|TPOINT, + SCON, TANY, + 0, RDEST, + " movabs AR,AL\n", }, + +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TWORD, + SMIXOR, TANY, + 0, RDEST, + " xorl AL,AL\n", }, + +{ ASSIGN, FOREFF, + SAREG|SNAME|SOREG, TWORD, + SCON, TANY, + 0, 0, + " movl AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TWORD, + SCON, TANY, + 0, RDEST, + " movl AR,AL\n", }, + +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + 0, RDEST, + " xorw AL,AL\n", }, + +{ ASSIGN, FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SCON, TANY, + 0, 0, + " movw AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TSHORT|TUSHORT, + SCON, TANY, + 0, RDEST, + " movw AR,AL\n", }, + +{ ASSIGN, FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SCON, TANY, + 0, 0, + " movb AR,AL\n", }, + +{ ASSIGN, FOREFF|INCH, + SHCH, TCHAR|TUCHAR, + SCON, TANY, + 0, RDEST, + " movb AR,AL\n", }, + +{ ASSIGN, FOREFF|INLL, + SHLL|SNAME|SOREG, TLL, + SHLL, TLL, + 0, RDEST, + " movq AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG|SNAME|SOREG, TWORD|TPOINT, + SAREG, TWORD|TPOINT, + 0, RDEST, + " movl AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TWORD|TPOINT, + SAREG|SNAME|SOREG, TWORD|TPOINT, + 0, RDEST, + " movl AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + 0, RDEST, + " movw AR,AL\n", }, + +{ ASSIGN, FOREFF|INCH, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SHCH, TCHAR|TUCHAR|TWORD, + 0, RDEST, + " movb AR,AL\n", }, + +{ ASSIGN, FOREFF|INBREG, + SFLD, TCHAR|TUCHAR, + SBREG|SCON, TCHAR|TUCHAR, + NAREG|NBREG, RDEST, + " movb AR,A2\n" + " movzbl A2,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movb AR,AD\n" + "FZE", }, + +{ ASSIGN, FOREFF|INAREG, + SFLD, TSHORT|TUSHORT, + SAREG|SCON, TSHORT|TUSHORT, + NAREG, RDEST, + " movw AR,A1\n" + " movzwl A1,ZN\n" + " andl $N,AL\n" + " sall $H,ZN\n" + " andl $M,ZN\n" + " orl ZN,AL\n" + "F movw AR,AD\n" + "FZE", }, + +{ ASSIGN, FOREFF|INAREG, + SFLD, TWORD, + SAREG|SNAME|SOREG|SCON, TWORD, + NAREG, RDEST, + " movl AR,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movl AR,AD\n" + "FZE", }, + +{ ASSIGN, INDREG|FOREFF, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + "", }, /* This will always be in the correct register */ + +/* order of table entries is very important here! */ +{ ASSIGN, INFL, + SNAME|SOREG, TLDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + " fst AL\n", }, + +{ ASSIGN, FOREFF, + SNAME|SOREG, TLDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, 0, + " fstpt AL\n", }, + +{ ASSIGN, INFL, + SNAME|SOREG, TDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + " fstl AL\n", }, + +{ ASSIGN, FOREFF, + SNAME|SOREG, TDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, 0, + " fstpl AL\n", }, + +{ ASSIGN, INFL, + SNAME|SOREG, TFLOAT, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + " fsts AL\n", }, + +{ ASSIGN, FOREFF, + SNAME|SOREG, TFLOAT, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, 0, + " fstps AL\n", }, +/* end very important order */ + +{ ASSIGN, INFL|FOREFF, + SHFL, TLDOUBLE, + SHFL|SOREG|SNAME, TLDOUBLE, + 0, RDEST, + " fldt AR\n", }, + +{ ASSIGN, INFL|FOREFF, + SHFL, TDOUBLE, + SHFL|SOREG|SNAME, TDOUBLE, + 0, RDEST, + " fldl AR\n", }, + +{ ASSIGN, INFL|FOREFF, + SHFL, TFLOAT, + SHFL|SOREG|SNAME, TFLOAT, + 0, RDEST, + " flds AR\n", }, + +/* Do not generate memcpy if return from funcall */ +#if 0 +{ STASG, INAREG|FOREFF, + SOREG|SNAME|SAREG, TPTRTO|TSTRUCT, + SFUNCALL, TPTRTO|TSTRUCT, + 0, RRIGHT, + "", }, +#endif + +{ STASG, INAREG|FOREFF, + SOREG|SNAME, TANY, + SAREG|SOREG|SNAME, TPTRTO|TANY, + NSPECIAL, RRIGHT, + "ZQ", }, + +/* + * DIV/MOD/MUL + */ +{ DIV, INLL, + SCREG, TLONG|TLONGLONG, + SCREG|SNAME|SOREG, TLL, + NSPECIAL, RDEST, + " cltd\n idivq AR\n", }, + +{ DIV, INAREG, + SAREG, TULONG|TULONGLONG|TPOINT, + SAREG|SNAME|SOREG, TULONG|TULONGLONG|TPOINT, + NSPECIAL, RDEST, + " xorq %rdx,%rdx\n divq AR\n", }, + +{ DIV, INAREG, + SAREG, TSWORD, + SAREG|SNAME|SOREG, TWORD, + NSPECIAL, RDEST, + " cltd\n idivl AR\n", }, + +{ DIV, INAREG, + SAREG, TUWORD, + SAREG|SNAME|SOREG, TUWORD, + NSPECIAL, RDEST, + " xorl %edx,%edx\n divl AR\n", }, + +{ DIV, INAREG, + SAREG, TUSHORT, + SAREG|SNAME|SOREG, TUSHORT, + NSPECIAL, RDEST, + " xorl %edx,%edx\n divw AR\n", }, + +{ DIV, INCH, + SHCH, TUCHAR, + SHCH|SNAME|SOREG, TUCHAR, + NSPECIAL, RDEST, + " xorb %ah,%ah\n divb AR\n", }, + +{ DIV, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " fdivl AR\n", }, + +{ DIV, INFL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fdivZAp\n", }, + +{ MOD, INLL, + SCREG, TLONG|TLONGLONG, + SCREG|SNAME|SOREG, TLONG|TLONGLONG, + NCREG|NSPECIAL, RESC1, + " cltd\n idivq AR\n", }, + +{ MOD, INLL, + SCREG, TLL|TPOINT, + SCREG|SNAME|SOREG, TULONG|TULONGLONG|TPOINT, + NCREG|NSPECIAL, RESC1, + " xorq %rdx,%rdx\n divq AR\n", }, + +{ MOD, INAREG, + SAREG, TSWORD, + SAREG|SNAME|SOREG, TSWORD, + NAREG|NSPECIAL, RESC1, + " cltd\n idivl AR\n", }, + +{ MOD, INAREG, + SAREG, TWORD, + SAREG|SNAME|SOREG, TUWORD, + NAREG|NSPECIAL, RESC1, + " xorl %edx,%edx\n divl AR\n", }, + +{ MOD, INAREG, + SAREG, TUSHORT, + SAREG|SNAME|SOREG, TUSHORT, + NAREG|NSPECIAL, RESC1, + " xorl %edx,%edx\n divw AR\n", }, + +{ MOD, INCH, + SHCH, TUCHAR, + SHCH|SNAME|SOREG, TUCHAR, + NBREG|NSPECIAL, RESC1, + " xorb %ah,%ah\n divb AR\n", }, + +{ MUL, INLL, + SCREG, TLL|TPOINT, + SCREG|SNAME|SOREG|SCON, TLL|TPOINT, + 0, RLEFT, + " imulq AR,AL\n", }, + +{ MUL, INAREG, + SAREG, TWORD, + SAREG|SNAME|SOREG|SCON, TWORD, + 0, RLEFT, + " imull AR,AL\n", }, + +{ MUL, INAREG, + SAREG, TSHORT|TUSHORT, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + 0, RLEFT, + " imulw AR,AL\n", }, + +{ MUL, INCH, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + NSPECIAL, RDEST, + " imulb AR\n", }, + +{ MUL, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " fmull AR\n", }, + +{ MUL, INFL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fmulp\n", }, + +/* + * Indirection operators. + */ +{ UMUL, INLL, + SANY, TANY, + SOREG, TLL|TPOINT, + NCREG, RESC1, + " movq AL,A1\n", }, + +{ UMUL, INAREG, + SANY, TWORD, + SOREG, TWORD, + NAREG|NASL, RESC1, + " movl AL,A1\n", }, + +{ UMUL, INCH, + SANY, TANY, + SOREG, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + " movb AL,A1\n", }, + +{ UMUL, INAREG, + SANY, TANY, + SOREG, TSHORT|TUSHORT, + NAREG|NASL, RESC1, + " movw AL,A1\n", }, + +{ UMUL, INFL, + SANY, TANY, + SOREG, TLDOUBLE, + NDREG|NDSL, RESC1, + " fldt AL\n", }, + +{ UMUL, INFL, + SANY, TANY, + SOREG, TDOUBLE, + NDREG|NDSL, RESC1, + " fldl AL\n", }, + +{ UMUL, INFL, + SANY, TANY, + SOREG, TFLOAT, + NDREG|NDSL, RESC1, + " flds AL\n", }, + +/* + * Logical/branching operators + */ + +/* Comparisions, take care of everything */ +{ OPLOG, FORCC, + SCON, TWORD, + SHLL|SOREG|SNAME, TLL|TPOINT, + 0, RESCC, + " cmpq AR,AL\n", }, + +{ OPLOG, FORCC, + SHLL, TLL|TPOINT, + SHLL|SOREG|SNAME, TLL|TPOINT, + 0, RESCC, + " cmpq AR,AL\n", }, + +{ OPLOG, FORCC, + SHLL|SOREG|SNAME, TLL|TPOINT, + SHLL, TLL|TPOINT, + 0, RESCC, + " cmpq AR,AL\n", }, + +{ OPLOG, FORCC, + SAREG|SOREG|SNAME, TWORD, + SCON|SAREG, TWORD, + 0, RESCC, + " cmpl AR,AL\n", }, + +{ OPLOG, FORCC, + SCON|SAREG, TWORD, + SAREG|SOREG|SNAME, TWORD, + 0, RESCC, + " cmpl AR,AL\n", }, + +{ OPLOG, FORCC, + SAREG|SOREG|SNAME, TSHORT|TUSHORT, + SCON|SAREG, TANY, + 0, RESCC, + " cmpw AR,AL\n", }, + +{ OPLOG, FORCC, + SBREG|SOREG|SNAME, TCHAR|TUCHAR, + SCON|SBREG, TANY, + 0, RESCC, + " cmpb AR,AL\n", }, + +{ OPLOG, FORCC, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NSPECIAL, 0, + "ZG", }, + +{ OPLOG, FORCC, + SOREG|SNAME, TDOUBLE|TFLOAT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NSPECIAL, 0, + "ZG", }, + +#if 0 +/* Ppro and later only */ +{ OPLOG, FORCC, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RESCC, + "ZA fucomip %st,%st(1)\n", }, +#endif + +{ OPLOG, FORCC, + SANY, TANY, + SANY, TANY, + REWRITE, 0, + "diediedie!", }, + +/* AND/OR/ER/NOT */ +{ AND, INAREG|FOREFF, + SCREG|SOREG|SNAME, TLL, + SCON, TWORD, + 0, RLEFT, + " andq AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SCREG|SOREG|SNAME, TLL, + SCREG, TLL, + 0, RLEFT, + " andq AR,AL\n", }, + +{ AND, INCREG|FOREFF, + SCREG, TLL, + SCREG|SOREG|SNAME, TLL, + 0, RLEFT, + " andq AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG|SOREG|SNAME, TWORD, + SCON|SAREG, TWORD, + 0, RLEFT, + " andl AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG, TWORD, + SAREG|SOREG|SNAME, TWORD, + 0, RLEFT, + " andl AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG|SOREG|SNAME, TSHORT|TUSHORT, + SCON|SAREG, TSHORT|TUSHORT, + 0, RLEFT, + " andw AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG, TSHORT|TUSHORT, + SAREG|SOREG|SNAME, TSHORT|TUSHORT, + 0, RLEFT, + " andw AR,AL\n", }, + +{ AND, INBREG|FOREFF, + SBREG|SOREG|SNAME, TCHAR|TUCHAR, + SCON|SBREG, TCHAR|TUCHAR, + 0, RLEFT, + " andb AR,AL\n", }, + +{ AND, INBREG|FOREFF, + SBREG, TCHAR|TUCHAR, + SBREG|SOREG|SNAME, TCHAR|TUCHAR, + 0, RLEFT, + " andb AR,AL\n", }, +/* AND/OR/ER/NOT */ + +/* + * Jumps. + */ +{ GOTO, FOREFF, + SCON, TANY, + SANY, TANY, + 0, RNOP, + " jmp LL\n", }, + +#if defined(GCC_COMPAT) || defined(LANG_F77) +{ GOTO, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, RNOP, + " jmp *AL\n", }, +#endif + +/* + * Convert LTYPE to reg. + */ +{ OPLTYPE, FORCC|INLL, + SCREG, TLL|TPOINT, + SMIXOR, TANY, + NCREG, RESC1, + " xorq A1,A1\n", }, + +{ OPLTYPE, INLL, + SANY, TANY, + SCREG|SCON|SOREG|SNAME, TLL|TPOINT, + NCREG, RESC1, + " movq AL,A1\n", }, + +{ OPLTYPE, FORCC|INAREG, + SAREG, TWORD, + SMIXOR, TANY, + NAREG|NASL, RESC1, + " xorl A1,A1\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SAREG|SCON|SOREG|SNAME, TWORD, + NAREG|NASL, RESC1, + " movl AL,A1\n", }, + +{ OPLTYPE, INBREG, + SANY, TANY, + SBREG|SOREG|SNAME|SCON, TCHAR|TUCHAR, + NBREG, RESC1, + " movb AL,A1\n", }, + +{ OPLTYPE, FORCC|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + NAREG, RESC1, + " xorw A1,A1\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SAREG|SOREG|SNAME|SCON, TSHORT|TUSHORT, + NAREG, RESC1, + " movw AL,A1\n", }, + +{ OPLTYPE, INDREG, + SANY, TLDOUBLE, + SOREG|SNAME, TLDOUBLE, + NDREG, RESC1, + " fldt AL\n", }, + +{ OPLTYPE, INDREG, + SANY, TDOUBLE, + SOREG|SNAME, TDOUBLE, + NDREG, RESC1, + " fldl AL\n", }, + +{ OPLTYPE, INDREG, + SANY, TFLOAT, + SOREG|SNAME, TFLOAT, + NDREG, RESC1, + " flds AL\n", }, + +/* Only used in ?: constructs. The stack already contains correct value */ +{ OPLTYPE, INDREG, + SANY, TFLOAT|TDOUBLE|TLDOUBLE, + SDREG, TFLOAT|TDOUBLE|TLDOUBLE, + NDREG, RESC1, + "", }, + +/* + * Negate a word. + */ + +{ UMINUS, INCREG|FOREFF, + SCREG, TLL|TPOINT, + SCREG, TLL|TPOINT, + 0, RLEFT, + " negq AL\n", }, + +{ UMINUS, INAREG|FOREFF, + SAREG, TWORD, + SAREG, TWORD, + 0, RLEFT, + " negl AL\n", }, + +{ UMINUS, INAREG|FOREFF, + SAREG, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + 0, RLEFT, + " negw AL\n", }, + +{ UMINUS, INBREG|FOREFF, + SBREG, TCHAR|TUCHAR, + SBREG, TCHAR|TUCHAR, + 0, RLEFT, + " negb AL\n", }, + +{ UMINUS, INFL|FOREFF, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fchs\n", }, + +{ COMPL, INCREG, + SCREG, TLL, + SANY, TANY, + 0, RLEFT, + " notq AL\n", }, + +{ COMPL, INAREG, + SAREG, TWORD, + SANY, TANY, + 0, RLEFT, + " notl AL\n", }, + +{ COMPL, INAREG, + SAREG, TSHORT|TUSHORT, + SANY, TANY, + 0, RLEFT, + " notw AL\n", }, + +{ COMPL, INBREG, + SBREG, TCHAR|TUCHAR, + SANY, TANY, + 0, RLEFT, + " notb AL\n", }, + +# define DF(x) FORREW,SANY,TANY,SANY,TANY,REWRITE,x,"" + +{ UMUL, DF( UMUL ), }, + +{ ASSIGN, DF(ASSIGN), }, + +{ STASG, DF(STASG), }, + +{ FLD, DF(FLD), }, + +{ OPLEAF, DF(NAME), }, + +/* { INIT, DF(INIT), }, */ + +{ OPUNARY, DF(UMINUS), }, + +{ OPANY, DF(BITYPE), }, + +{ FREE, FREE, FREE, FREE, FREE, FREE, FREE, FREE, "help; I'm in trouble\n" }, +}; + +int tablesize = sizeof(table)/sizeof(table[0]); --- /dev/null +++ usr.bin/pcc/amd64/local2.c @@ -0,0 +1,1163 @@ +/* $Id: local2.c,v 1.1 2008/11/27 05:25:15 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +# include "pass2.h" +# include +# include + +static int stkpos; + +void +deflab(int label) +{ + printf(LABFMT ":\n", label); +} + +static int regoff[7]; +static TWORD ftype; + +/* + * Print out the prolog assembler. + * addto and regoff are already calculated. + */ +static void +prtprolog(struct interpass_prolog *ipp, int addto) +{ + static int lwnr; + int i; + + printf(" pushl %%ebp\n"); + printf(" movl %%esp,%%ebp\n"); + if (addto) + printf(" subl $%d,%%esp\n", addto); + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) + fprintf(stdout, " movl %s,-%d(%s)\n", + rnames[i], regoff[i], rnames[FPREG]); + if (kflag == 0) + return; + + /* if ebx are not saved to stack, it must be moved into another reg */ + /* check and emit the move before GOT stuff */ + if (!TESTBIT(ipp->ipp_regs, EBX)) { + struct interpass *ip = (struct interpass *)ipp; + + ip = DLIST_PREV(ip, qelem); + ip = DLIST_PREV(ip, qelem); + ip = DLIST_PREV(ip, qelem); + if (ip->type != IP_NODE || ip->ip_node->n_op != ASSIGN || + ip->ip_node->n_left->n_op != REG) + comperr("prtprolog pic error"); + ip = (struct interpass *)ipp; + ip = DLIST_NEXT(ip, qelem); + if (ip->type != IP_NODE || ip->ip_node->n_op != ASSIGN || + ip->ip_node->n_left->n_op != REG) + comperr("prtprolog pic error2"); + printf(" movl %s,%s\n", + rnames[ip->ip_node->n_right->n_rval], + rnames[ip->ip_node->n_left->n_rval]); + tfree(ip->ip_node); + DLIST_REMOVE(ip, qelem); + } + printf(" call .LW%d\n", ++lwnr); + printf(".LW%d:\n", lwnr); + printf(" popl %%ebx\n"); + printf(" addl $_GLOBAL_OFFSET_TABLE_+[.-.LW%d], %%ebx\n", lwnr); +} + +/* + * calculate stack size and offsets + */ +static int +offcalc(struct interpass_prolog *ipp) +{ + int i, addto; + + addto = p2maxautooff; + if (addto >= AUTOINIT/SZCHAR) + addto -= AUTOINIT/SZCHAR; + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) { + addto += SZINT/SZCHAR; + regoff[i] = addto; + } + return addto; +} + +void +prologue(struct interpass_prolog *ipp) +{ + int addto; + + ftype = ipp->ipp_type; + +#ifdef LANG_F77 + if (ipp->ipp_vis) + printf(" .globl %s\n", ipp->ipp_name); + printf(" .align 4\n"); + printf("%s:\n", ipp->ipp_name); +#endif + /* + * We here know what register to save and how much to + * add to the stack. + */ + addto = offcalc(ipp); + prtprolog(ipp, addto); +} + +void +eoftn(struct interpass_prolog *ipp) +{ + int i; + + if (ipp->ipp_ip.ip_lbl == 0) + return; /* no code needs to be generated */ + + /* return from function code */ + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) + fprintf(stdout, " movl -%d(%s),%s\n", + regoff[i], rnames[FPREG], rnames[i]); + + /* struct return needs special treatment */ + if (ftype == STRTY || ftype == UNIONTY) { + printf(" movl 8(%%ebp),%%eax\n"); + printf(" leave\n"); + printf(" ret $%d\n", 4); + } else { + printf(" leave\n"); + } + printf("\t.size %s,.-%s\n", ipp->ipp_name, + ipp->ipp_name); +} + +/* + * add/sub/... + * + * Param given: + */ +void +hopcode(int f, int o) +{ + char *str; + + switch (o) { + case PLUS: + str = "add"; + break; + case MINUS: + str = "sub"; + break; + case AND: + str = "and"; + break; + case OR: + str = "or"; + break; + case ER: + str = "xor"; + break; + default: + comperr("hopcode2: %d", o); + str = 0; /* XXX gcc */ + } + printf("%s%c", str, f); +} + +/* + * Return type size in bytes. Used by R2REGS, arg 2 to offset(). + */ +int +tlen(p) NODE *p; +{ + switch(p->n_type) { + case CHAR: + case UCHAR: + return(1); + + case SHORT: + case USHORT: + return(SZSHORT/SZCHAR); + + case DOUBLE: + return(SZDOUBLE/SZCHAR); + + case INT: + case UNSIGNED: + return(SZINT/SZCHAR); + + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + return SZLONGLONG/SZCHAR; + + default: + if (!ISPTR(p->n_type)) + comperr("tlen type %d not pointer"); + return SZPOINT(p->n_type)/SZCHAR; + } +} + +/* + * Emit code to compare two longlong numbers. + */ +static void +twollcomp(NODE *p) +{ + int o = p->n_op; + int s = getlab(); + int e = p->n_label; + int cb1, cb2; + + if (o >= ULE) + o -= (ULE-LE); + switch (o) { + case NE: + cb1 = 0; + cb2 = NE; + break; + case EQ: + cb1 = NE; + cb2 = 0; + break; + case LE: + case LT: + cb1 = GT; + cb2 = LT; + break; + case GE: + case GT: + cb1 = LT; + cb2 = GT; + break; + + default: + cb1 = cb2 = 0; /* XXX gcc */ + } + if (p->n_op >= ULE) + cb1 += 4, cb2 += 4; + expand(p, 0, " cmpl UR,UL\n"); + if (cb1) cbgen(cb1, s); + if (cb2) cbgen(cb2, e); + expand(p, 0, " cmpl AR,AL\n"); + cbgen(p->n_op, e); + deflab(s); +} + +int +fldexpand(NODE *p, int cookie, char **cp) +{ + CONSZ val; + + if (p->n_op == ASSIGN) + p = p->n_left; + switch (**cp) { + case 'S': + printf("%d", UPKFSZ(p->n_rval)); + break; + case 'H': + printf("%d", UPKFOFF(p->n_rval)); + break; + case 'M': + case 'N': + val = (CONSZ)1 << UPKFSZ(p->n_rval); + --val; + val <<= UPKFOFF(p->n_rval); + printf("0x%llx", (**cp == 'M' ? val : ~val) & 0xffffffff); + break; + default: + comperr("fldexpand"); + } + return 1; +} + +static void +bfext(NODE *p) +{ + int ch = 0, sz = 0; + + if (ISUNSIGNED(p->n_right->n_type)) + return; + switch (p->n_right->n_type) { + case CHAR: + ch = 'b'; + sz = 8; + break; + case SHORT: + ch = 'w'; + sz = 16; + break; + case INT: + ch = 'l'; + sz = 32; + break; + case LONG: + ch = 'q'; + sz = 64; + break; + default: + comperr("bfext"); + } + + sz -= UPKFSZ(p->n_left->n_rval); + printf("\tshl%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n\tsar%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n"); +} + +/* + * Push a structure on stack as argument. + * the scratch registers are already free here + */ +static void +starg(NODE *p) +{ + FILE *fp = stdout; + + fprintf(fp, " subl $%d,%%esp\n", p->n_stsize); + fprintf(fp, " pushl $%d\n", p->n_stsize); + expand(p, 0, " pushl AL\n"); + expand(p, 0, " leal 8(%esp),A1\n"); + expand(p, 0, " pushl A1\n"); + fprintf(fp, " call memcpy\n"); + fprintf(fp, " addl $12,%%esp\n"); +} + +/* + * Compare two floating point numbers. + */ +static void +fcomp(NODE *p) +{ + + if (p->n_left->n_op == REG) { + if (p->n_su & DORIGHT) + expand(p, 0, " fxch\n"); + expand(p, 0, " fucompp\n"); /* emit compare insn */ + } else if (p->n_left->n_type == DOUBLE) + expand(p, 0, " fcompl AL\n"); /* emit compare insn */ + else if (p->n_left->n_type == FLOAT) + expand(p, 0, " fcomp AL\n"); /* emit compare insn */ + else + comperr("bad compare %p\n", p); + expand(p, 0, " fnstsw %ax\n"); /* move status reg to ax */ + + switch (p->n_op) { + case EQ: + expand(p, 0, " andb $64,%ah\n jne LC\n"); + break; + case NE: + expand(p, 0, " andb $64,%ah\n je LC\n"); + break; + case LE: + expand(p, 0, " andb $65,%ah\n cmpb $1,%ah\n jne LC\n"); + break; + case LT: + expand(p, 0, " andb $65,%ah\n je LC\n"); + break; + case GT: + expand(p, 0, " andb $1,%ah\n jne LC\n"); + break; + case GE: + expand(p, 0, " andb $65,%ah\n jne LC\n"); + break; + default: + comperr("fcomp op %d\n", p->n_op); + } +} + +/* + * Convert an unsigned long long to floating point number. + */ +static void +ulltofp(NODE *p) +{ + static int loadlab; + int jmplab; + + if (loadlab == 0) { + loadlab = getlab(); + expand(p, 0, " .data\n"); + printf(LABFMT ": .long 0,0x80000000,0x403f\n", loadlab); + expand(p, 0, " .text\n"); + } + jmplab = getlab(); + expand(p, 0, " pushl UL\n pushl AL\n"); + expand(p, 0, " fildq (%esp)\n"); + expand(p, 0, " addl $8,%esp\n"); + expand(p, 0, " cmpl $0,UL\n"); + printf(" jge " LABFMT "\n", jmplab); + printf(" fldt " LABFMT "\n", loadlab); + printf(" faddp %%st,%%st(1)\n"); + printf(LABFMT ":\n", jmplab); +} + +static int +argsiz(NODE *p) +{ + TWORD t = p->n_type; + + if (t < LONG || t == FLOAT || t > BTMASK) + return 4; + if (t == LONG || t == ULONG || t == LONGLONG || t == ULONGLONG || + t == DOUBLE) + return 8; + if (t == LDOUBLE) + return 16; + if (t == STRTY || t == UNIONTY) + return p->n_stsize; + comperr("argsiz"); + return 0; +} + +void +zzzcode(NODE *p, int c) +{ + NODE *r, *l; + int pr, lr, s; + char *ch; + + switch (c) { + case 'A': /* swap st0 and st1 if right is evaluated second */ + if ((p->n_su & DORIGHT) == 0) { + if (logop(p->n_op)) + printf(" fxch\n"); + else + printf("r"); + } + break; + + case 'C': /* remove from stack after subroutine call */ + if (p->n_left->n_flags & FSTDCALL) + break; + pr = p->n_qual; + if (p->n_op == STCALL || p->n_op == USTCALL) + pr += 4; + if (p->n_op == UCALL) + return; /* XXX remove ZC from UCALL */ + if (pr) + printf(" addl $%d, %s\n", pr, rnames[ESP]); + break; + + case 'E': /* Perform bitfield sign-extension */ + bfext(p); + break; + + case 'F': /* Structure argument */ + if (p->n_stalign != 0) /* already on stack */ + starg(p); + break; + + case 'G': /* Floating point compare */ + fcomp(p); + break; + + case 'J': /* convert unsigned long long to floating point */ + ulltofp(p); + break; + + case 'M': /* Output sconv move, if needed */ + l = getlr(p, 'L'); + /* XXX fixneed: regnum */ + pr = DECRA(p->n_reg, 0); + lr = DECRA(l->n_reg, 0); + if ((pr == AL && lr == EAX) || (pr == BL && lr == EBX) || + (pr == CL && lr == ECX) || (pr == DL && lr == EDX)) + ; + else + printf(" movb %%%cl,%s\n", + rnames[lr][2], rnames[pr]); + l->n_rval = l->n_reg = p->n_reg; /* XXX - not pretty */ + break; + + case 'N': /* output extended reg name */ + printf("%s", rnames[getlr(p, '1')->n_rval]); + break; + + case 'S': /* emit eventual move after cast from longlong */ + pr = DECRA(p->n_reg, 0); + lr = p->n_left->n_rval; + switch (p->n_type) { + case CHAR: + case UCHAR: + if (rnames[pr][2] == 'l' && rnames[lr][2] == 'x' && + rnames[pr][1] == rnames[lr][1]) + break; + if (rnames[lr][2] == 'x') { + printf("\tmovb %%%cl,%s\n", + rnames[lr][1], rnames[pr]); + break; + } + /* Must go via stack */ + s = BITOOR(freetemp(1)); + printf("\tmovl %%e%ci,%d(%%rbp)\n", rnames[lr][1], s); + printf("\tmovb %d(%%rbp),%s\n", s, rnames[pr]); + comperr("SCONV1 %s->%s", rnames[lr], rnames[pr]); + break; + + case SHORT: + case USHORT: + if (rnames[lr][1] == rnames[pr][2] && + rnames[lr][2] == rnames[pr][3]) + break; + printf("\tmovw %%%c%c,%%%s\n", + rnames[lr][1], rnames[lr][2], rnames[pr]+2); + comperr("SCONV2 %s->%s", rnames[lr], rnames[pr]); + break; + case INT: + case UNSIGNED: + if (rnames[lr][1] == rnames[pr][2] && + rnames[lr][2] == rnames[pr][3]) + break; + printf("\tmovl %%e%c%c,%s\n", + rnames[lr][1], rnames[lr][2], rnames[pr]); + comperr("SCONV3 %s->%s", rnames[lr], rnames[pr]); + break; + + default: + if (rnames[lr][1] == rnames[pr][2] && + rnames[lr][2] == rnames[pr][3]) + break; + comperr("SCONV4 %s->%s", rnames[lr], rnames[pr]); + break; + } + break; + + default: + comperr("zzzcode %c", c); + } +} + +/*ARGSUSED*/ +int +rewfld(NODE *p) +{ + return(1); +} + +int canaddr(NODE *); +int +canaddr(NODE *p) +{ + int o = p->n_op; + + if (o==NAME || o==REG || o==ICON || o==OREG || + (o==UMUL && shumul(p->n_left, SOREG))) + return(1); + return(0); +} + +/* + * Does the bitfield shape match? + */ +int +flshape(NODE *p) +{ + int o = p->n_op; + + if (o == OREG || o == REG || o == NAME) + return SRDIR; /* Direct match */ + if (o == UMUL && shumul(p->n_left, SOREG)) + return SROREG; /* Convert into oreg */ + return SRREG; /* put it into a register */ +} + +/* INTEMP shapes must not contain any temporary registers */ +/* XXX should this go away now? */ +int +shtemp(NODE *p) +{ + return 0; +#if 0 + int r; + + if (p->n_op == STARG ) + p = p->n_left; + + switch (p->n_op) { + case REG: + return (!istreg(p->n_rval)); + + case OREG: + r = p->n_rval; + if (R2TEST(r)) { + if (istreg(R2UPK1(r))) + return(0); + r = R2UPK2(r); + } + return (!istreg(r)); + + case UMUL: + p = p->n_left; + return (p->n_op != UMUL && shtemp(p)); + } + + if (optype(p->n_op) != LTYPE) + return(0); + return(1); +#endif +} + +void +adrcon(CONSZ val) +{ + printf("$" CONFMT, val); +} + +void +conput(FILE *fp, NODE *p) +{ + int val = p->n_lval; + + switch (p->n_op) { + case ICON: + if (p->n_name[0] != '\0') { + fprintf(fp, "%s", p->n_name); + if (val) + fprintf(fp, "+%d", val); + } else + fprintf(fp, "%d", val); + return; + + default: + comperr("illegal conput, p %p", p); + } +} + +/*ARGSUSED*/ +void +insput(NODE *p) +{ + comperr("insput"); +} + +/* + * Write out the upper address, like the upper register of a 2-register + * reference, or the next memory location. + */ +void +upput(NODE *p, int size) +{ + + size /= SZCHAR; + switch (p->n_op) { + case REG: + fprintf(stdout, "%%%s", &rnames[p->n_rval][3]); + break; + + case NAME: + case OREG: + p->n_lval += size; + adrput(stdout, p); + p->n_lval -= size; + break; + case ICON: + fprintf(stdout, "$" CONFMT, p->n_lval >> 32); + break; + default: + comperr("upput bad op %d size %d", p->n_op, size); + } +} + +void +adrput(FILE *io, NODE *p) +{ + int r; + /* output an address, with offsets, from p */ + + if (p->n_op == FLD) + p = p->n_left; + + switch (p->n_op) { + + case NAME: + if (p->n_name[0] != '\0') { + fputs(p->n_name, io); + if (p->n_lval != 0) + fprintf(io, "+" CONFMT, p->n_lval); + } else + fprintf(io, CONFMT, p->n_lval); + return; + + case OREG: + r = p->n_rval; + if (p->n_name[0]) + printf("%s%s", p->n_name, p->n_lval ? "+" : ""); + if (p->n_lval) + fprintf(io, "%d", (int)p->n_lval); + if (R2TEST(r)) { + fprintf(io, "(%s,%s,8)", rnames[R2UPK1(r)], + rnames[R2UPK2(r)]); + } else + fprintf(io, "(%s)", rnames[p->n_rval]); + return; + case ICON: +#ifdef PCC_DEBUG + /* Sanitycheck for PIC, to catch adressable constants */ + if (kflag && p->n_name[0]) { + static int foo; + + if (foo++ == 0) { + printf("\nfailing...\n"); + fwalk(p, e2print, 0); + comperr("pass2 conput"); + } + } +#endif + /* addressable value of the constant */ + fputc('$', io); + conput(io, p); + return; + + case REG: + switch (p->n_type) { + case LONGLONG: + case ULONGLONG: + fprintf(io, "%%%c%c%c", rnames[p->n_rval][0], + rnames[p->n_rval][1], rnames[p->n_rval][2]); + break; + case SHORT: + case USHORT: + fprintf(io, "%%%s", &rnames[p->n_rval][2]); + break; + default: + fprintf(io, "%s", rnames[p->n_rval]); + } + return; + + default: + comperr("illegal address, op %d, node %p", p->n_op, p); + return; + + } +} + +static char * +ccbranches[] = { + "je", /* jumpe */ + "jne", /* jumpn */ + "jle", /* jumple */ + "jl", /* jumpl */ + "jge", /* jumpge */ + "jg", /* jumpg */ + "jbe", /* jumple (jlequ) */ + "jb", /* jumpl (jlssu) */ + "jae", /* jumpge (jgequ) */ + "ja", /* jumpg (jgtru) */ +}; + + +/* printf conditional and unconditional branches */ +void +cbgen(int o, int lab) +{ + if (o < EQ || o > UGT) + comperr("bad conditional branch: %s", opst[o]); + printf(" %s " LABFMT "\n", ccbranches[o-EQ], lab); +} + +static void +fixcalls(NODE *p, void *arg) +{ + /* Prepare for struct return by allocating bounce space on stack */ + switch (p->n_op) { + case STCALL: + case USTCALL: + if (p->n_stsize+p2autooff > stkpos) + stkpos = p->n_stsize+p2autooff; + break; + } +} + +/* + * Must store floats in memory if there are two function calls involved. + */ +static int +storefloat(struct interpass *ip, NODE *p) +{ + int l, r; + + switch (optype(p->n_op)) { + case BITYPE: + l = storefloat(ip, p->n_left); + r = storefloat(ip, p->n_right); + if (p->n_op == CM) + return 0; /* arguments, don't care */ + if (callop(p->n_op)) + return 1; /* found one */ +#define ISF(p) ((p)->n_type == FLOAT || (p)->n_type == DOUBLE || \ + (p)->n_type == LDOUBLE) + if (ISF(p->n_left) && ISF(p->n_right) && l && r) { + /* must store one. store left */ + struct interpass *nip; + TWORD t = p->n_left->n_type; + NODE *ll; + int off; + + off = BITOOR(freetemp(szty(t))); + ll = mklnode(OREG, off, FPREG, t); + nip = ipnode(mkbinode(ASSIGN, ll, p->n_left, t)); + p->n_left = mklnode(OREG, off, FPREG, t); + DLIST_INSERT_BEFORE(ip, nip, qelem); + } + return l|r; + + case UTYPE: + l = storefloat(ip, p->n_left); + if (callop(p->n_op)) + l = 1; + return l; + default: + return 0; + } +} + +void +myreader(struct interpass *ipole) +{ + struct interpass *ip; + + stkpos = p2autooff; + DLIST_FOREACH(ip, ipole, qelem) { + if (ip->type != IP_NODE) + continue; + walkf(ip->ip_node, fixcalls, 0); + storefloat(ip, ip->ip_node); + } + if (stkpos > p2autooff) + p2autooff = stkpos; + if (stkpos > p2maxautooff) + p2maxautooff = stkpos; + if (x2debug) + printip(ipole); +} + +/* + * Remove some PCONVs after OREGs are created. + */ +static void +pconv2(NODE *p, void *arg) +{ + NODE *q; + + if (p->n_op == PLUS) { + if (p->n_type == (PTR|SHORT) || p->n_type == (PTR|USHORT)) { + if (p->n_right->n_op != ICON) + return; + if (p->n_left->n_op != PCONV) + return; + if (p->n_left->n_left->n_op != OREG) + return; + q = p->n_left->n_left; + nfree(p->n_left); + p->n_left = q; + /* + * This will be converted to another OREG later. + */ + } + } +} + +void +mycanon(NODE *p) +{ + walkf(p, pconv2, 0); +} + +void +myoptim(struct interpass *ip) +{ +} + +void +rmove(int s, int d, TWORD t) +{ + int sl, sh, dl, dh; + + switch (t) { + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + printf(" movq %s,%s\n", rnames[s], rnames[d]); + break; + case CHAR: + case UCHAR: + printf(" movb %s,%s\n", rnames[s], rnames[d]); + break; + case FLOAT: + case DOUBLE: + case LDOUBLE: +#ifdef notdef + /* a=b()*c(); will generate this */ + comperr("bad float rmove: %d %d", s, d); +#endif + break; + default: + printf(" movl %s,%s\n", rnames[s], rnames[d]); + } +} + +/* + * For class c, find worst-case displacement of the number of + * registers in the array r[] indexed by class. + */ +int +COLORMAP(int c, int *r) +{ + int num; + + switch (c) { + case CLASSA: + num = r[CLASSB] > 4 ? 4 : r[CLASSB]; + num += 2*r[CLASSC]; + num += r[CLASSA]; + return num < 6; + case CLASSB: + num = r[CLASSA]; + num += 2*r[CLASSC]; + num += r[CLASSB]; + return num < 4; + case CLASSC: + num = r[CLASSA]; + num += r[CLASSB] > 4 ? 4 : r[CLASSB]; + num += 2*r[CLASSC]; + return num < 5; + case CLASSD: + return r[CLASSD] < DREGCNT; + } + return 0; /* XXX gcc */ +} + +char *rnames[] = { + "%eax", "%edx", "%ecx", "%ebx", "%esi", "%edi", "%ebp", "%esp", + "%al", "%ah", "%dl", "%dh", "%cl", "%ch", "%bl", "%bh", + "%rax", "%rdx", "%rcx", "%rbx", "%rsi", "%rdi", "%rbp", "%rsp", + "%r08", "%r09", "%r10", "%r11", "%r12", "%r13", "%r14", "%r15", + "%st0", "%st1", "%st2", "%st3", "%st4", "%st5", "%st6", "%st7", +}; + +/* + * Return a class suitable for a specific type. + */ +int +gclass(TWORD t) +{ + if (t == CHAR || t == UCHAR) + return CLASSB; + if (t == LONG || t == ULONG || t == LONGLONG || t == ULONGLONG) + return CLASSC; + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) + return CLASSD; + return CLASSA; +} + +/* + * Calculate argument sizes. + */ +void +lastcall(NODE *p) +{ + NODE *op = p; + int size = 0; + + p->n_qual = 0; + if (p->n_op != CALL && p->n_op != FORTCALL && p->n_op != STCALL) + return; + for (p = p->n_right; p->n_op == CM; p = p->n_left) + size += argsiz(p->n_right); + size += argsiz(p); + if (kflag) + size -= 4; + op->n_qual = size; /* XXX */ +} + +/* + * Special shapes. + */ +int +special(NODE *p, int shape) +{ + int o = p->n_op; + + switch (shape) { + case SFUNCALL: + if (o == STCALL || o == USTCALL) + return SRREG; + break; + case SPCON: + if (o != ICON || p->n_name[0] || + p->n_lval < 0 || p->n_lval > 0x7fffffff) + break; + return SRDIR; + case SMIXOR: + return tshape(p, SZERO); + case SMILWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || p->n_lval & 0xffffffff) + break; + return SRDIR; + case SMIHWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || (p->n_lval >> 32) != 0) + break; + return SRDIR; + } + return SRNOPE; +} + +/* + * Target-dependent command-line options. + */ +void +mflags(char *str) +{ +} + +/* + * Do something target-dependent for xasm arguments. + */ +int +myxasm(struct interpass *ip, NODE *p) +{ + struct interpass *ip2; + NODE *in = 0, *ut = 0; + TWORD t; + char *w; + int reg; + int cw; + + cw = xasmcode(p->n_name); + if (cw & (XASMASG|XASMINOUT)) + ut = p->n_left; + if ((cw & XASMASG) == 0) + in = p->n_left; + + switch (XASMVAL(cw)) { + case 'D': reg = EDI; break; + case 'S': reg = ESI; break; + case 'a': reg = EAX; break; + case 'b': reg = EBX; break; + case 'c': reg = ECX; break; + case 'd': reg = EDX; break; + case 't': reg = 0; break; + case 'u': reg = 1; break; + case 'A': reg = EAXEDX; break; + case 'q': /* XXX let it be CLASSA as for now */ + p->n_name = tmpstrdup(p->n_name); + w = strchr(p->n_name, 'q'); + *w = 'r'; + return 0; + default: + return 0; + } + p->n_name = tmpstrdup(p->n_name); + for (w = p->n_name; *w; w++) + ; + w[-1] = 'r'; /* now reg */ + t = p->n_left->n_type; + if (reg == EAXEDX) { + p->n_label = CLASSC; + } else { + p->n_label = CLASSA; + if (t == CHAR || t == UCHAR) { + p->n_label = CLASSB; + reg = reg * 2 + 8; + } + } + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) { + p->n_label = CLASSD; + reg += 037; + } + + if (in && ut) + in = tcopy(in); + p->n_left = mklnode(REG, 0, reg, t); + if (ut) { + ip2 = ipnode(mkbinode(ASSIGN, ut, tcopy(p->n_left), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + } + if (in) { + ip2 = ipnode(mkbinode(ASSIGN, tcopy(p->n_left), in, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + return 1; +} + +void +targarg(char *w, void *arg) +{ + NODE **ary = arg; + NODE *p, *q; + + p = ary[(int)w[1]-'0']->n_left; + if (optype(p->n_op) != LTYPE) + comperr("bad xarg op %d", p->n_op); + q = tcopy(p); + if (q->n_op == REG) { + if (*w == 'k') { + q->n_type = INT; + } else if (*w != 'w') { + if (q->n_type > UCHAR) { + regno(q) = regno(q)*2+8; + if (*w == 'h') + regno(q)++; + } + q->n_type = INT; + } else + q->n_type = SHORT; + } + adrput(stdout, q); + tfree(q); +} + +/* + * target-specific conversion of numeric arguments. + */ +int +numconv(void *ip, void *p1, void *q1) +{ + NODE *p = p1, *q = q1; + int cw = xasmcode(q->n_name); + + switch (XASMVAL(cw)) { + case 'a': + case 'b': + case 'c': + case 'd': + p->n_name = tmpcalloc(2); + p->n_name[0] = XASMVAL(cw); + return 1; + default: + return 0; + } +} --- /dev/null +++ usr.bin/pcc/amd64/code.c @@ -0,0 +1,290 @@ +/* $Id: code.c,v 1.2 2008/12/10 17:59:30 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +# include "pass1.h" + +NODE *funarg(NODE *, int *); +int argreg(TWORD, int *); + +int lastloc = -1; + +/* + * Define everything needed to print out some data (or text). + * This means segment, alignment, visibility, etc. + */ +void +defloc(struct symtab *sp) +{ + extern char *nextsect; + static char *loctbl[] = { "text", "data", "section .rodata" }; + TWORD t; + int s; + + if (sp == NULL) { + lastloc = -1; + return; + } + t = sp->stype; + s = ISFTN(t) ? PROG : ISCON(cqual(t, sp->squal)) ? RDATA : DATA; +#ifdef TLS + if (sp->sflags & STLS) { + if (s != DATA) + cerror("non-data symbol in tls section"); + nextsect = ".tdata"; + } +#endif + if (nextsect) { + printf(" .section %s\n", nextsect); + nextsect = NULL; + s = -1; + } else if (s != lastloc) + printf(" .%s\n", loctbl[s]); + lastloc = s; + while (ISARY(t)) + t = DECREF(t); + if (sp->ssue->suealign > ALCHAR) + printf(" .align %d\n", sp->ssue->suealign/ALCHAR); + if (sp->sclass == EXTDEF) + printf(" .globl %s\n", exname(sp->soname)); + if (ISFTN(t)) + printf("\t.type %s, at function\n", exname(sp->soname)); + if (sp->slevel == 0) + printf("%s:\n", exname(sp->soname)); + else + printf(LABFMT ":\n", sp->soffset); +} + +/* + * code for the end of a function + * deals with struct return here + */ +void +efcode() +{ + extern int gotnr; + NODE *p, *q; + + gotnr = 0; /* new number for next fun */ + if (cftnsp->stype != STRTY+FTN && cftnsp->stype != UNIONTY+FTN) + return; + /* Create struct assignment */ + q = block(OREG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); + q->n_rval = EBP; + q->n_lval = 8; /* return buffer offset */ + q = buildtree(UMUL, q, NIL); + p = block(REG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); + p = buildtree(UMUL, p, NIL); + p = buildtree(ASSIGN, q, p); + ecomp(p); +} + +/* + * code for the beginning of a function; a is an array of + * indices in symtab for the arguments; n is the number + */ +void +bfcode(struct symtab **a, int cnt) +{ + struct symtab *sp2; + extern int gotnr; + NODE *n, *p; + int i; + + if (cftnsp->stype == STRTY+FTN || cftnsp->stype == UNIONTY+FTN) { + /* Function returns struct, adjust arg offset */ + for (i = 0; i < cnt; i++) + sp[i]->soffset += SZPOINT(LONG); + } + + if (kflag) { + /* Put ebx in temporary */ + n = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + n->n_rval = EBX; + p = tempnode(0, INT, 0, MKSUE(INT)); + gotnr = regno(p); + ecomp(buildtree(ASSIGN, p, n)); + } + + /* recalculate the arg offset and create TEMP moves */ + for (n = 0, i = 0; i < cnt; i++) { + sp = a[i]; + + if (n < 6) { + p = tempnode(0, sp->stype, sp->sdf, sp->ssue); + q = block(REG, NIL, NIL, sp->stype, sp->sdf, sp->ssue); + q->n_rval = argreg(sp->stype, &n); + p = buildtree(ASSIGN, p, q); + sp->soffset = regno(p->n_left); + sp->sflags |= STNODE; + ecomp(p); + } else { + sp->soffset += SZLONG * n; + if (xtemps) { + /* put stack args in temps if optimizing */ + p = tempnode(0, sp->stype, sp->sdf, sp->ssue); + p = buildtree(ASSIGN, p, buildtree(NAME, 0, 0)); + sp->soffset = regno(p->n_left); + sp->sflags |= STNODE; + ecomp(p); + } + } + } +} + + +/* + * by now, the automatics and register variables are allocated + */ +void +bccode() +{ + SETOFF(autooff, SZINT); +} + +/* called just before final exit */ +/* flag is 1 if errors, 0 if none */ +void +ejobcode(int flag ) +{ + if (errors) + return; + +#define _MKSTR(x) #x +#define MKSTR(x) _MKSTR(x) +#define OS MKSTR(TARGOS) + printf("\t.ident \"PCC: %s (%s)\"\n\t.end\n", PACKAGE_STRING, OS); +} + +void +bjobcode() +{ +} + +static const int argregsi[] = { RDI, RSI, RDX, RCX, R09, R08 }; + +int +argreg(TWORD t, int *n) +{ + switch (t) { + case FLOAT: + case DOUBLE: + case LDOUBLE: + return FR6 - *n - 2; + case LONGLONG: + case ULONGLONG: + /* TODO */; + default: + return argregsi[(*n)++]; + } +} + +NODE * +funarg(NODE *p, int *n) +{ + NODE *r; + int sz; + + if (p->n_op == CM) { + p->n_left = funarg(p->n_left, n); + p->n_right = funarg(p->n_right, n); + return p; + } + + if (*n >= 6) { + *n++; + r = block(OREG, NIL, NIL, p->n_type|PTR, 0, + MKSUE(p->n_type|PTR)); + r->n_rval = RBP; + r->n_lval = 16 + (*n - 6) * 8; + } else { + r = block(REG, NIL, NIL, p->n_type, 0, 0); + r->n_lval = 0; + r->n_rval = argreg(p->n_type, n); + } + p = block(ASSIGN, r, p, p->n_type, 0, 0); + clocal(p); + + return p; +} + +/* + * Called with a function call with arguments as argument. + * This is done early in buildtree() and only done once. + * Returns p. + */ +NODE * +funcode(NODE *p) +{ + extern int gotnr; + NODE *r, *l; + int n = 0; + + p->n_right = funarg(p->n_right, &n); + + if (kflag == 0) + return p; + /* Create an ASSIGN node for ebx */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + l = buildtree(ASSIGN, l, tempnode(gotnr, INT, 0, MKSUE(INT))); + if (p->n_right->n_op != CM) { + p->n_right = block(CM, l, p->n_right, INT, 0, MKSUE(INT)); + } else { + for (r = p->n_right; r->n_left->n_op == CM; r = r->n_left) + ; + r->n_left = block(CM, l, r->n_left, INT, 0, MKSUE(INT)); + } + return p; +} + +/* + * return the alignment of field of type t + */ +int +fldal(unsigned int t) +{ + uerror("illegal field type"); + return(ALINT); +} + +/* fix up type of field p */ +void +fldty(struct symtab *p) +{ +} + +/* + * XXX - fix genswitch. + */ +int +mygenswitch(int num, TWORD type, struct swents **p, int n) +{ + return 0; +} --- /dev/null +++ usr.bin/pcc/amd64/local.c @@ -0,0 +1,1117 @@ +/* $Id: local.c,v 1.2 2008/12/14 21:16:58 ragge Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +#include "pass1.h" + +/* this file contains code which is dependent on the target machine */ + +/* + * Check if a constant is too large for a type. + */ +static int +toolarge(TWORD t, CONSZ con) +{ + U_CONSZ ucon = con; + + switch (t) { + case ULONG: + case LONG: + case ULONGLONG: + case LONGLONG: + break; /* cannot be too large */ +#define SCHK(i) case i: if (con > MAX_##i || con < MIN_##i) return 1; break +#define UCHK(i) case i: if (ucon > MAX_##i) return 1; break + SCHK(INT); + SCHK(SHORT); + case BOOL: + SCHK(CHAR); + UCHK(UNSIGNED); + UCHK(USHORT); + UCHK(UCHAR); + default: + cerror("toolarge"); + } + return 0; +} + +#define IALLOC(sz) (isinlining ? permalloc(sz) : tmpalloc(sz)) + +/* + * Make a symtab entry for PIC use. + */ +static struct symtab * +picsymtab(char *p, char *s, char *s2) +{ + struct symtab *sp = IALLOC(sizeof(struct symtab)); + size_t len = strlen(p) + strlen(s) + strlen(s2) + 1; + + sp->sname = sp->soname = IALLOC(len); + strlcpy(sp->soname, p, len); + strlcat(sp->soname, s, len); + strlcat(sp->soname, s2, len); + sp->sclass = EXTERN; + sp->sflags = sp->slevel = 0; + return sp; +} + +int gotnr; /* tempnum for GOT register */ +int argstacksize; + +/* + * Create a reference for an extern variable. + */ +static NODE * +picext(NODE *p) +{ + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@GOT"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, PTR|VOID, 0, MKSUE(VOID)); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; +} + +/* + * Create a reference for a static variable. + */ +static NODE * +picstatic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + if (p->n_sp->slevel > 0) { + char buf[32]; + snprintf(buf, 32, LABFMT, (int)p->n_sp->soffset); + sp = picsymtab("", buf, "@GOTOFF"); + } else + sp = picsymtab("", p->n_sp->soname, "@GOTOFF"); + sp->sclass = STATIC; + sp->stype = p->n_sp->stype; + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; +} + +#ifdef TLS +/* + * Create a reference for a TLS variable. + */ +static NODE * +tlspic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + + /* + * creates: + * leal var at TLSGD(%ebx),%eax + * call ___tls_get_addr at PLT + */ + + /* calc address of var at TLSGD */ + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@TLSGD"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + + /* assign to %eax */ + r = block(REG, NIL, NIL, PTR|VOID, 0, MKSUE(VOID)); + r->n_rval = EAX; + q = buildtree(ASSIGN, r, q); + + /* call ___tls_get_addr */ + sp2 = lookup("___tls_get_addr at PLT", 0); + sp2->stype = EXTERN|INT|FTN; + r = nametree(sp2); + r = buildtree(ADDROF, r, NIL); + r = block(UCALL, r, NIL, INT, 0, MKSUE(INT)); + + /* fusion both parts together */ + q = buildtree(COMOP, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsnonpic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + int ext = p->n_sp->sclass; + + sp = picsymtab("", p->n_sp->soname, + ext == EXTERN ? "@INDNTPOFF" : "@NTPOFF"); + q = xbcon(0, sp, INT); + if (ext == EXTERN) + q = block(UMUL, q, NIL, PTR|VOID, 0, MKSUE(VOID)); + + sp2 = lookup("%gs:0", 0); + sp2->stype = EXTERN|INT; + r = nametree(sp2); + + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsref(NODE *p) +{ + if (kflag) + return (tlspic(p)); + else + return (tlsnonpic(p)); +} +#endif + +/* clocal() is called to do local transformations on + * an expression tree preparitory to its being + * written out in intermediate code. + * + * the major essential job is rewriting the + * automatic variables and arguments in terms of + * REG and OREG nodes + * conversion ops which are not necessary are also clobbered here + * in addition, any special features (such as rewriting + * exclusive or) are easily handled here as well + */ +NODE * +clocal(NODE *p) +{ + + register struct symtab *q; + register NODE *r, *l; + register int o; + register int m; + TWORD t; + +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal: %p\n", p); + fwalk(p, eprint, 0); + } +#endif + switch( o = p->n_op ){ + + case NAME: + if ((q = p->n_sp) == NULL) + return p; /* Nothing to care about */ + + switch (q->sclass) { + + case PARAM: + case AUTO: + /* fake up a structure reference */ + r = block(REG, NIL, NIL, PTR+STRTY, 0, 0); + r->n_lval = 0; + r->n_rval = FPREG; + p = stref(block(STREF, r, p, 0, 0, 0)); + break; + + case USTATIC: + if (kflag == 0) + break; + /* FALLTHROUGH */ + case STATIC: +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); + break; + } +#endif + if (kflag == 0) { + if (q->slevel == 0) + break; + p->n_lval = 0; + } else if (blevel > 0) + p = picstatic(p); + break; + + case REGISTER: + p->n_op = REG; + p->n_lval = 0; + p->n_rval = q->soffset; + break; + + case EXTERN: + case EXTDEF: +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); + break; + } +#endif + if (kflag == 0) + break; + if (blevel > 0) + p = picext(p); + break; + } + break; + + case ADDROF: + if (kflag == 0 || blevel == 0) + break; + /* char arrays may end up here */ + l = p->n_left; + if (l->n_op != NAME || + (l->n_type != ARY+CHAR && l->n_type != ARY+WCHAR_TYPE)) + break; + l = p; + p = picstatic(p->n_left); + nfree(l); + if (p->n_op != UMUL) + cerror("ADDROF error"); + l = p; + p = p->n_left; + nfree(l); + break; + + case UCALL: + case USTCALL: + if (kflag == 0) + break; + /* Change to CALL node with ebx as argument */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + p->n_right = buildtree(ASSIGN, l, + tempnode(gotnr, INT, 0, MKSUE(INT))); + p->n_op -= (UCALL-CALL); + break; + + case CBRANCH: + l = p->n_left; + + /* + * Remove unnecessary conversion ops. + */ + if (clogop(l->n_op) && l->n_left->n_op == SCONV) { + if (coptype(l->n_op) != BITYPE) + break; + if (l->n_right->n_op == ICON) { + r = l->n_left->n_left; + if (r->n_type >= FLOAT && r->n_type <= LDOUBLE) + break; + if (ISPTR(r->n_type)) + break; /* no opt for pointers */ + if (toolarge(r->n_type, l->n_right->n_lval)) + break; + /* Type must be correct */ + t = r->n_type; + nfree(l->n_left); + l->n_left = r; + l->n_type = t; + l->n_right->n_type = t; + } + } + break; + + case PCONV: + /* Remove redundant PCONV's. Be careful */ + l = p->n_left; + if (l->n_op == ICON) { + l->n_lval = (unsigned)l->n_lval; + goto delp; + } + if (l->n_type < INT || l->n_type == LONGLONG || + l->n_type == ULONGLONG) { + /* float etc? */ + p->n_left = block(SCONV, l, NIL, + UNSIGNED, 0, MKSUE(UNSIGNED)); + break; + } + /* if left is SCONV, cannot remove */ + if (l->n_op == SCONV) + break; + + /* avoid ADDROF TEMP */ + if (l->n_op == ADDROF && l->n_left->n_op == TEMP) + break; + + /* if conversion to another pointer type, just remove */ + if (p->n_type > BTMASK && l->n_type > BTMASK) + goto delp; + break; + + delp: l->n_type = p->n_type; + l->n_qual = p->n_qual; + l->n_df = p->n_df; + l->n_sue = p->n_sue; + nfree(p); + p = l; + break; + + case SCONV: + l = p->n_left; + + if (p->n_type == l->n_type) { + nfree(p); + return l; + } + + if ((p->n_type & TMASK) == 0 && (l->n_type & TMASK) == 0 && + btdims[p->n_type].suesize == btdims[l->n_type].suesize) { + if (p->n_type != FLOAT && p->n_type != DOUBLE && + l->n_type != FLOAT && l->n_type != DOUBLE && + l->n_type != LDOUBLE && p->n_type != LDOUBLE) { + if (l->n_op == NAME || l->n_op == UMUL || + l->n_op == TEMP) { + l->n_type = p->n_type; + nfree(p); + return l; + } + } + } + + if (DEUNSIGN(p->n_type) == INT && DEUNSIGN(l->n_type) == INT && + coptype(l->n_op) == BITYPE) { + l->n_type = p->n_type; + nfree(p); + return l; + } + + o = l->n_op; + m = p->n_type; + + if (o == ICON) { + CONSZ val = l->n_lval; + + if (!ISPTR(m)) /* Pointers don't need to be conv'd */ + switch (m) { + case BOOL: + l->n_lval = l->n_lval != 0; + break; + case CHAR: + l->n_lval = (char)val; + break; + case UCHAR: + l->n_lval = val & 0377; + break; + case SHORT: + l->n_lval = (short)val; + break; + case USHORT: + l->n_lval = val & 0177777; + break; + case UNSIGNED: + l->n_lval = val & 0xffffffff; + break; + case INT: + l->n_lval = (int)val; + break; + case LONG: + case LONGLONG: + l->n_lval = (long long)val; + break; + case ULONG: + case ULONGLONG: + l->n_lval = val; + break; + case VOID: + break; + case LDOUBLE: + case DOUBLE: + case FLOAT: + l->n_op = FCON; + l->n_dcon = val; + break; + default: + cerror("unknown type %d", m); + } + l->n_type = m; + l->n_sue = MKSUE(m); + nfree(p); + return l; + } else if (l->n_op == FCON) { + l->n_lval = l->n_dcon; + l->n_sp = NULL; + l->n_op = ICON; + l->n_type = m; + l->n_sue = MKSUE(m); + nfree(p); + return clocal(l); + } + if (DEUNSIGN(p->n_type) == SHORT && + DEUNSIGN(l->n_type) == SHORT) { + nfree(p); + p = l; + } + if ((p->n_type == CHAR || p->n_type == UCHAR || + p->n_type == SHORT || p->n_type == USHORT) && + (l->n_type == FLOAT || l->n_type == DOUBLE || + l->n_type == LDOUBLE)) { + p = block(SCONV, p, NIL, p->n_type, p->n_df, p->n_sue); + p->n_left->n_type = INT; + return p; + } + break; + + case MOD: + case DIV: + if (o == DIV && p->n_type != CHAR && p->n_type != SHORT) + break; + if (o == MOD && p->n_type != CHAR && p->n_type != SHORT) + break; + /* make it an int division by inserting conversions */ + p->n_left = block(SCONV, p->n_left, NIL, INT, 0, MKSUE(INT)); + p->n_right = block(SCONV, p->n_right, NIL, INT, 0, MKSUE(INT)); + p = block(SCONV, p, NIL, p->n_type, 0, MKSUE(p->n_type)); + p->n_left->n_type = INT; + break; + + case PMCONV: + case PVCONV: + r = p; + p = buildtree(o == PMCONV ? MUL : DIV, p->n_left, p->n_right); + nfree(r); + break; + + case FORCE: + /* put return value in return reg */ + p->n_op = ASSIGN; + p->n_right = p->n_left; + p->n_left = block(REG, NIL, NIL, p->n_type, 0, MKSUE(INT)); + p->n_left->n_rval = p->n_left->n_type == BOOL ? + RETREG(CHAR) : RETREG(p->n_type); + break; + + case LS: + case RS: + /* shift count must be in a char + * unless longlong, where it must be int */ + if (p->n_type == LONGLONG || p->n_type == ULONGLONG) { + if (p->n_right->n_type != INT) + p->n_right = block(SCONV, p->n_right, NIL, + INT, 0, MKSUE(INT)); + break; + } + if (p->n_right->n_type == CHAR || p->n_right->n_type == UCHAR) + break; + p->n_right = block(SCONV, p->n_right, NIL, + CHAR, 0, MKSUE(CHAR)); + break; + } +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal end: %p\n", p); + fwalk(p, eprint, 0); + } +#endif + return(p); +} + +/* + * Change CALL references to either direct (static) or PLT. + */ +static void +fixnames(NODE *p, void *arg) +{ + struct symtab *sp; + struct suedef *sue; + NODE *q; + char *c; + int isu; + + if ((cdope(p->n_op) & CALLFLG) == 0) + return; + isu = 0; + q = p->n_left; + sue = q->n_sue; + if (q->n_op == UMUL) + q = q->n_left, isu = 1; + + if (q->n_op == PLUS && q->n_left->n_op == TEMP && + q->n_right->n_op == ICON) { + sp = q->n_right->n_sp; + + if (sp == NULL) + return; /* nothing to do */ + if (sp->sclass == STATIC && !ISFTN(sp->stype)) + return; /* function pointer */ + + if (sp->sclass != STATIC && sp->sclass != EXTERN && + sp->sclass != EXTDEF) + cerror("fixnames"); + + if ((c = strstr(sp->soname, "@GOT")) == NULL) + cerror("fixnames2"); + if (isu) { + memcpy(c, "@PLT", sizeof("@PLT")); + } else + *c = 0; + + nfree(q->n_left); + q = q->n_right; + if (isu) + nfree(p->n_left->n_left); + nfree(p->n_left); + p->n_left = q; + q->n_sue = sue; + } +} + +void +myp2tree(NODE *p) +{ + struct symtab *sp; + + if (kflag) + walkf(p, fixnames, 0); /* XXX walkf not needed */ + if (p->n_op != FCON) + return; + +#if 0 + /* put floating constants in memory */ + setloc1(RDATA); + defalign(ALLDOUBLE); + deflab1(i = getlab()); + ninval(0, btdims[p->n_type].suesize, p); +#endif + + sp = IALLOC(sizeof(struct symtab)); + sp->sclass = STATIC; + sp->ssue = MKSUE(p->n_type); + sp->slevel = 1; /* fake numeric label */ + sp->soffset = getlab(); + sp->sflags = 0; + sp->stype = p->n_type; + sp->squal = (CON >> TSHIFT); + + defloc(sp); + ninval(0, sp->ssue->suesize, p); + + p->n_op = NAME; + p->n_lval = 0; + p->n_sp = sp; +} + +/*ARGSUSED*/ +int +andable(NODE *p) +{ + return(1); /* all names can have & taken on them */ +} + +/* + * at the end of the arguments of a ftn, set the automatic offset + */ +void +cendarg() +{ + autooff = AUTOINIT; +} + +/* + * Return 1 if a variable of type type is OK to put in register. + */ +int +cisreg(TWORD t) +{ + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) + return 0; /* not yet */ + return 1; +} + +/* + * return a node, for structure references, which is suitable for + * being added to a pointer of type t, in order to be off bits offset + * into a structure + * t, d, and s are the type, dimension offset, and sizeoffset + * For pdp10, return the type-specific index number which calculation + * is based on its size. For example, short a[3] would return 3. + * Be careful about only handling first-level pointers, the following + * indirections must be fullword. + */ +NODE * +offcon(OFFSZ off, TWORD t, union dimfun *d, struct suedef *sue) +{ + register NODE *p; + + if (xdebug) + printf("offcon: OFFSZ %lld type %x dim %p siz %d\n", + off, t, d, sue->suesize); + + p = bcon(0); + p->n_lval = off/SZCHAR; /* Default */ + return(p); +} + +/* + * Allocate off bits on the stack. p is a tree that when evaluated + * is the multiply count for off, t is a storeable node where to write + * the allocated address. + */ +void +spalloc(NODE *t, NODE *p, OFFSZ off) +{ + NODE *sp; + + p = buildtree(MUL, p, bcon(off/SZCHAR)); /* XXX word alignment? */ + + /* sub the size from sp */ + sp = block(REG, NIL, NIL, p->n_type, 0, MKSUE(INT)); + sp->n_lval = 0; + sp->n_rval = STKREG; + ecomp(buildtree(MINUSEQ, sp, p)); + + /* save the address of sp */ + sp = block(REG, NIL, NIL, PTR+INT, t->n_df, t->n_sue); + sp->n_lval = 0; + sp->n_rval = STKREG; + t->n_type = sp->n_type; + ecomp(buildtree(ASSIGN, t, sp)); /* Emit! */ + +} + +/* + * Print out a string of characters. + * Assume that the assembler understands C-style escape + * sequences. + */ +void +instring(struct symtab *sp) +{ + char *s, *str = sp->sname; + + defloc(sp); + + /* be kind to assemblers and avoid long strings */ + printf("\t.ascii \""); + for (s = str; *s != 0; ) { + if (*s++ == '\\') { + (void)esccon(&s); + } + if (s - str > 60) { + fwrite(str, 1, s - str, stdout); + printf("\"\n\t.ascii \""); + str = s; + } + } + fwrite(str, 1, s - str, stdout); + printf("\\0\"\n"); +} + +/* + * Print out a wide string by calling ninval(). + */ +void +inwstring(struct symtab *sp) +{ + char *s = sp->sname; + NODE *p; + + defloc(sp); + p = xbcon(0, NULL, WCHAR_TYPE); + do { + if (*s++ == '\\') + p->n_lval = esccon(&s); + else + p->n_lval = (unsigned char)s[-1]; + ninval(0, (MKSUE(WCHAR_TYPE))->suesize, p); + } while (s[-1] != 0); + nfree(p); +} + + +static int inbits, inval; + +/* + * set fsz bits in sequence to zero. + */ +void +zbits(OFFSZ off, int fsz) +{ + int m; + + if (idebug) + printf("zbits off %lld, fsz %d inbits %d\n", off, fsz, inbits); + if ((m = (inbits % SZCHAR))) { + m = SZCHAR - m; + if (fsz < m) { + inbits += fsz; + return; + } else { + fsz -= m; + printf("\t.byte %d\n", inval); + inval = inbits = 0; + } + } + if (fsz >= SZCHAR) { + printf("\t.zero %d\n", fsz/SZCHAR); + fsz -= (fsz/SZCHAR) * SZCHAR; + } + if (fsz) { + inval = 0; + inbits = fsz; + } +} + +/* + * Initialize a bitfield. + */ +void +infld(CONSZ off, int fsz, CONSZ val) +{ + if (idebug) + printf("infld off %lld, fsz %d, val %lld inbits %d\n", + off, fsz, val, inbits); + val &= ((CONSZ)1 << fsz)-1; + while (fsz + inbits >= SZCHAR) { + inval |= (val << inbits); + printf("\t.byte %d\n", inval & 255); + fsz -= (SZCHAR - inbits); + val >>= (SZCHAR - inbits); + inval = inbits = 0; + } + if (fsz) { + inval |= (val << inbits); + inbits += fsz; + } +} + +/* + * print out a constant node, may be associated with a label. + * Do not free the node after use. + * off is bit offset from the beginning of the aggregate + * fsz is the number of bits this is referring to + */ +void +ninval(CONSZ off, int fsz, NODE *p) +{ + union { float f; double d; long double l; int i[3]; } u; + struct symtab *q; + char *c; + TWORD t; + int i; + + t = p->n_type; + if (t > BTMASK) + t = INT; /* pointer */ + + while (p->n_op == SCONV || p->n_op == PCONV) { + NODE *l = p->n_left; + l->n_type = p->n_type; + p = l; + } + + if (kflag && (p->n_op == PLUS || p->n_op == UMUL)) { + if (p->n_op == UMUL) + p = p->n_left; + p = p->n_right; + q = p->n_sp; + + if ((c = strstr(q->soname, "@GOT")) != NULL) + *c = 0; /* ignore GOT ref here */ + } + if (p->n_op != ICON && p->n_op != FCON) + cerror("ninval: init node not constant"); + + if (p->n_op == ICON && p->n_sp != NULL && DEUNSIGN(t) != INT) + uerror("element not constant"); + + switch (t) { + case LONGLONG: + case ULONGLONG: + i = (p->n_lval >> 32); + p->n_lval &= 0xffffffff; + p->n_type = INT; + ninval(off, 32, p); + p->n_lval = i; + ninval(off+32, 32, p); + break; + case INT: + case UNSIGNED: + printf("\t.long 0x%x", (int)p->n_lval); + if ((q = p->n_sp) != NULL) { + if ((q->sclass == STATIC && q->slevel > 0)) { + printf("+" LABFMT, q->soffset); + } else { + printf("+%s", exname(q->soname)); + } + } + printf("\n"); + break; + case SHORT: + case USHORT: + printf("\t.short 0x%x\n", (int)p->n_lval & 0xffff); + break; + case BOOL: + if (p->n_lval > 1) + p->n_lval = p->n_lval != 0; + /* FALLTHROUGH */ + case CHAR: + case UCHAR: + printf("\t.byte %d\n", (int)p->n_lval & 0xff); + break; + case LDOUBLE: + u.i[2] = 0; + u.l = (long double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + /* XXX probably broken on most hosts */ + printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[2], u.i[1], u.i[0]); +#else + printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[0], u.i[1], u.i[2]); +#endif + break; + case DOUBLE: + u.d = (double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + printf("\t.long\t0x%x,0x%x\n", u.i[1], u.i[0]); +#else + printf("\t.long\t0x%x,0x%x\n", u.i[0], u.i[1]); +#endif + break; + case FLOAT: + u.f = (float)p->n_dcon; + printf("\t.long\t0x%x\n", u.i[0]); + break; + default: + cerror("ninval"); + } +} + +/* make a name look like an external name in the local machine */ +char * +exname(char *p) +{ + return (p == NULL ? "" : p); +} + +/* + * map types which are not defined on the local machine + */ +TWORD +ctype(TWORD type) +{ + switch (BTYPE(type)) { + case LONG: + MODTYPE(type,LONG); + break; + + case ULONG: + MODTYPE(type,ULONG); + + } + return (type); +} + +void +calldec(NODE *p, NODE *q) +{ +} + +void +extdec(struct symtab *q) +{ +} + +/* make a common declaration for id, if reasonable */ +void +defzero(struct symtab *sp) +{ + int off; + +#ifdef TLS + if (sp->sflags & STLS) { + if (sp->sclass == EXTERN) + sp->sclass = EXTDEF; + simpleinit(sp, bcon(0)); + return; + } +#endif + + off = tsize(sp->stype, sp->sdf, sp->ssue); + off = (off+(SZCHAR-1))/SZCHAR; + printf(" .%scomm ", sp->sclass == STATIC ? "l" : ""); + if (sp->slevel == 0) + printf("%s,0%o\n", exname(sp->soname), off); + else + printf(LABFMT ",0%o\n", sp->soffset, off); +} + +static char * +section2string(char *name, int len) +{ + char *s; + int n; + + if (strncmp(name, "link_set", 8) == 0) { + const char *postfix = ",\"aw\", at progbits"; + n = len + strlen(postfix) + 1; + s = IALLOC(n); + strlcpy(s, name, n); + strlcat(s, postfix, n); + return s; + } + + return newstring(name, len); +} + +char *nextsect; +#ifdef TLS +static int gottls; +#endif +static char *alias; +static int constructor; +static int destructor; + +/* + * Give target the opportunity of handling pragmas. + */ +int +mypragma(char **ary) +{ +#ifdef TLS + if (strcmp(ary[1], "tls") == 0 && ary[2] == NULL) { + gottls = 1; + return 1; + } +#endif + if (strcmp(ary[1], "constructor") == 0 || strcmp(ary[1], "init") == 0) { + constructor = 1; + return 1; + } + if (strcmp(ary[1], "destructor") == 0 || strcmp(ary[1], "fini") == 0) { + destructor = 1; + return 1; + } + if (strcmp(ary[1], "section") == 0 && ary[2] != NULL) { + nextsect = section2string(ary[2], strlen(ary[2])); + return 1; + } + if (strcmp(ary[1], "alias") == 0 && ary[2] != NULL) { + alias = tmpstrdup(ary[2]); + return 1; + } + + return 0; +} + +/* + * Called when a identifier has been declared. + */ +void +fixdef(struct symtab *sp) +{ +#ifdef TLS + /* may have sanity checks here */ + if (gottls) + sp->sflags |= STLS; + gottls = 0; +#endif + if (alias != NULL && (sp->sclass != PARAM)) { + printf("\t.globl %s\n", exname(sp->soname)); + printf("%s = ", exname(sp->soname)); + printf("%s\n", exname(alias)); + alias = NULL; + } + if ((constructor || destructor) && (sp->sclass != PARAM)) { + printf("\t.section .%ctors,\"aw\", at progbits\n", + constructor ? 'c' : 'd'); + printf("\t.p2align 2\n"); + printf("\t.long %s\n", exname(sp->sname)); + constructor = destructor = 0; + } +} + +NODE * +i386_builtin_return_address(NODE *f, NODE *a) +{ + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; + + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + f = block(PLUS, f, bcon(4), INCREF(PTR+VOID), 0, MKSUE(VOID)); + f = buildtree(UMUL, f, NIL); + + return f; +bad: + uerror("bad argument to __builtin_return_address"); + return bcon(0); +} + +NODE * +i386_builtin_frame_address(NODE *f, NODE *a) +{ + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; + + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + return f; +bad: + uerror("bad argument to __builtin_frame_address"); + return bcon(0); +} + +void +pass1_lastchance(struct interpass *ip) +{ +} Index: cc.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cc/cc.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/cc/cc.c -L usr.bin/pcc/cc/cc.c -u -r1.2 -r1.3 --- usr.bin/pcc/cc/cc.c +++ usr.bin/pcc/cc/cc.c @@ -1,4 +1,4 @@ -/* $Id: cc.c,v 1.61 2007/09/26 14:48:47 ragge Exp $ */ +/* $Id: cc.c,v 1.136 2008/12/22 02:04:11 gmcgarry Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -47,21 +47,35 @@ * * This file should be rewritten readable. */ +#include "config.h" + #include +#ifdef HAVE_SYS_WAIT_H #include +#endif -#include #include +#include +#include +#ifdef HAVE_LIBGEN_H +#include +#endif #include +#include +#include +#include #include -#include +#ifdef HAVE_UNISTD_H #include -#include -#include -#include -#include +#endif + +#ifdef WIN32 +#include +#include +#include +#endif -#include "../config.h" +#include "compat.h" #include "ccconfig.h" /* C command */ @@ -72,34 +86,79 @@ /* * Many specific definitions, should be declared elsewhere. */ -#define STDINC "/usr/include/" -#define SBSIZE 10000 -#define MAXINC 100 -#define MAXFIL 100 +#ifndef STDINC +#define STDINC "/usr/include/" +#endif + +#ifndef LIBDIR +#define LIBDIR "/usr/lib/" +#endif + +#ifndef PREPROCESSOR +#define PREPROCESSOR "pcpp" +#endif + +#ifndef COMPILER +#define COMPILER "pccom"; +#endif + +#ifndef ASSEMBLER +#define ASSEMBLER "as" +#endif + +#ifndef LINKER +#define LINKER "ld" +#endif + +#define OS MKS(TARGOS) +#define MACH MKS(TARGMACH) +#ifndef PCCINCDIR +#define PCCINCDIR LIBDIR "pcc/" MACH "-" OS "/" PACKAGE_VERSION "/include" +#endif +#ifndef PCCLIBDIR +#define PCCLIBDIR LIBDIR "pcc/" MACH "-" OS "/" PACKAGE_VERSION "/lib" +#endif + +#define MAXFIL 10000 #define MAXLIB 10000 #define MAXAV 10000 #define MAXOPT 100 char *tmp3; char *tmp4; -char *outfile; -char *copy(char *as),*setsuf(char *as, char ch); -int getsuf(char []); +char *outfile, *ermfile; +char *Bprefix(char *); +char *copy(char *, int),*setsuf(char *, char); +int getsuf(char *); int main(int, char *[]); void error(char *, ...); -void errorx(int eval, char *, ...); -int nodup(char **, char *); +void errorx(int, char *, ...); int callsys(char [], char *[]); int cunlink(char *); -void dexit(int eval); +void dexit(int); void idexit(int); -char *gettmp(); +char *gettmp(void); +void *ccmalloc(int size); +#ifdef WIN32 +char *win32pathsubst(char *); +#endif char *av[MAXAV]; char *clist[MAXFIL]; char *llist[MAXLIB]; +char *aslist[MAXAV]; char alist[20]; char *xlist[100]; int xnum; +char *mlist[100]; +char *flist[100]; +char *wlist[100]; +char *idirafter; +int nm; +int nf; +int nw; +int sspflag; +int Cflag; +int Vflag; int dflag; int pflag; int sflag; @@ -117,205 +176,416 @@ int pgflag; int exfail; int Xflag; -int nostartfiles, Bstatic; +int Wallflag; +int Wflag; +int nostartfiles, Bstatic, shared; int nostdinc, nostdlib; int onlyas; int pthreads; +int xcflag; +int ascpp; -char *pass0 = LIBEXECDIR "/pccom"; -char *passp = LIBEXECDIR "/pcpp"; +char *passp = LIBEXECDIR PREPROCESSOR; +char *pass0 = LIBEXECDIR COMPILER; +char *as = ASSEMBLER; +char *ld = LINKER; char *Bflag; char *cppadd[] = CPPADD; +#ifdef DYNLINKER char *dynlinker[] = DYNLINKER; +#endif +#ifdef CRT0FILE char *crt0file = CRT0FILE; +#endif +#ifdef CRT0FILE_PROFILE +char *crt0file_profile = CRT0FILE_PROFILE; +#endif +#ifdef STARTFILES char *startfiles[] = STARTFILES; char *endfiles[] = ENDFILES; +#endif +#ifdef STARTFILES_T +char *startfiles_T[] = STARTFILES_T; +char *endfiles_T[] = ENDFILES_T; +#endif +#ifdef STARTFILES_S +char *startfiles_S[] = STARTFILES_S; +char *endfiles_S[] = ENDFILES_S; +#endif +#ifdef MULTITARGET +char *mach = DEFMACH; +struct cppmd { + char *mach; + char *cppmdadd[MAXCPPMDARGS]; +}; + +struct cppmd cppmds[] = CPPMDADDS; +#else char *cppmdadd[] = CPPMDADD; +#endif #ifdef LIBCLIBS char *libclibs[] = LIBCLIBS; #else char *libclibs[] = { "-lc", NULL }; #endif +#ifdef LIBCLIBS_PROFILE +char *libclibs_profile[] = LIBCLIBS_PROFILE; +#else +char *libclibs_profile[] = { "-lc_p", NULL }; +#endif #ifndef STARTLABEL #define STARTLABEL "__start" #endif +char *incdir = STDINC; +char *libdir = LIBDIR; +char *pccincdir = PCCINCDIR; +char *pcclibdir = PCCLIBDIR; + +/* handle gcc warning emulations */ +struct Wflags { + char *name; + int flags; +#define INWALL 1 +#define NEGATIVE 2 +} Wflags[] = { + { "-Werror", 0 }, + { "-Wshadow", 0 }, + { "-Wno-shadow", NEGATIVE }, + { "-Wpointer-sign", INWALL }, + { "-Wno-pointer-sign", NEGATIVE }, + { "-Wsign-compare", 0 }, + { "-Wno-sign-compare", NEGATIVE }, + { "-Wunknown-pragmas", INWALL }, + { "-Wno-unknown-pragmas", NEGATIVE }, + { "-Wunreachable-code", 0 }, + { "-Wno-unreachable-code", NEGATIVE }, + { 0, 0 }, +}; + +#define SZWFL (sizeof(Wflags)/sizeof(Wflags[0])) int main(int argc, char *argv[]) { + struct Wflags *Wf; char *t, *u; char *assource; char **pv, *ptemp[MAXOPT], **pvt; - int nc, nl, i, j, c, nxo, na; + int nc, nl, nas, i, j, c, nxo, na; +#ifdef MULTITARGET + int k; +#endif - i = nc = nl = nxo = 0; +#ifdef WIN32 + /* have to prefix path early. -B may override */ + incdir = win32pathsubst(incdir); + libdir = win32pathsubst(libdir); + pccincdir = win32pathsubst(pccincdir); + pcclibdir = win32pathsubst(pcclibdir); + passp = win32pathsubst(passp); + pass0 = win32pathsubst(pass0); +#endif + + i = nc = nl = nas = nxo = 0; pv = ptemp; while(++i < argc) { - if (argv[i][0] == '-') - switch (argv[i][1]) { - default: - goto passa; + if (argv[i][0] == '-') { + switch (argv[i][1]) { + default: + goto passa; +#ifdef notyet + /* must add library options first (-L/-l/...) */ + error("unrecognized option `-%c'", argv[i][1]); + break; +#endif - case 'B': /* other search paths for binaries */ - Bflag = &argv[i][2]; - break; + case '-': /* double -'s */ + if (strcmp(argv[i], "--version") == 0) { + printf("%s\n", VERSSTR); + return 0; + } else if (strcmp(argv[i], "--param") == 0) + /* NOTHING YET */; + else + error("unrecognized option %s", argv[i]); + break; - case 'X': - Xflag++; - break; - case 'W': /* Ignore (most of) W-flags */ - if (strncmp(argv[i], "-Wl,", 4) == 0) { - /* options to the linker */ - t = &argv[i][4]; - while ((u = strchr(t, ','))) { - *u++ = 0; + case 'B': /* other search paths for binaries */ + Bflag = &argv[i][2]; + break; + +#ifdef MULTITARGET + case 'b': + t = &argv[i][2]; + if (*t == '\0' && i + 1 < argc) { + t = argv[i+1]; + i++; + } + if (strncmp(t, "?", 1) == 0) { + /* show machine targets */ + printf("Available machine targets:"); + for (j=0; cppmds[j].mach; j++) + printf(" %s",cppmds[j].mach); + printf("\n"); + exit(0); + } + for (j=0; cppmds[j].mach; j++) + if (strcmp(t, cppmds[j].mach) == 0) { + mach = cppmds[j].mach; + break; + } + if (cppmds[j].mach == NULL) + errorx(1, "unknown target arch %s", t); + break; +#endif + + case 'X': + Xflag++; + break; + case 'W': /* Ignore (most of) W-flags */ + if (strncmp(argv[i], "-Wl,", 4) == 0) { + /* options to the linker */ + t = &argv[i][4]; + while ((u = strchr(t, ','))) { + *u++ = 0; + llist[nl++] = t; + t = u; + } llist[nl++] = t; - t = u; + } else if (strncmp(argv[i], "-Wa,", 4) == 0) { + /* options to the assembler */ + t = &argv[i][4]; + while ((u = strchr(t, ','))) { + *u++ = 0; + aslist[nas++] = t; + t = u; + } + aslist[nas++] = t; + } else if (strncmp(argv[i], "-Wp,", 4) == 0) { + /* preprocessor */ + if (!strncmp(argv[i], "-Wp,-C", 6)) + Cflag++; + else if (!strncmp(argv[i], "-Wp,-V", 6)) + Vflag++; + } else if (strcmp(argv[i], "-Wall") == 0) { + Wallflag = 1; + } else if (strcmp(argv[i], "-WW") == 0) { + Wflag = 1; + } else { + /* check and set if available */ + for (Wf = Wflags; Wf->name; Wf++) { + if (strcmp(argv[i], Wf->name)) + continue; + wlist[nw++] = Wf->name; + } } - llist[nl++] = t; - } - break; + break; - case 'f': /* GCC compatibility flags */ - if (strcmp(argv[i], "-fPIC") == 0) - kflag = F_PIC; - if (strcmp(argv[i], "-fpic") == 0) - kflag = F_pic; - /* silently ignore the rest */ - break; + case 'f': /* GCC compatibility flags */ + if (strcmp(argv[i], "-fPIC") == 0) + kflag = F_PIC; + else if (strcmp(argv[i], "-fpic") == 0) + kflag = F_pic; + else if (strcmp(argv[i], + "-fsigned-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-fno-signed-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-funsigned-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-fno-unsigned-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-fstack-protector") == 0) { + flist[nf++] = argv[i]; + sspflag++; + } else if (strcmp(argv[i], + "-fstack-protector-all") == 0) { + flist[nf++] = argv[i]; + sspflag++; + } else if (strcmp(argv[i], + "-fno-stack-protector") == 0) { + flist[nf++] = argv[i]; + sspflag = 0; + } else if (strcmp(argv[i], + "-fno-stack-protector-all") == 0) { + flist[nf++] = argv[i]; + sspflag = 0; + } + /* silently ignore the rest */ + break; - case 'g': /* create debug output */ - gflag++; - break; + case 'g': /* create debug output */ + gflag++; + break; - case 'i': - if (strcmp(argv[i], "-isystem") == 0) { - *pv++ = "-S"; - *pv++ = argv[++i]; - } else if (strcmp(argv[i], "-include") == 0) { - *pv++ = "-i"; - *pv++ = argv[++i]; - } else - goto passa; - break; + case 'i': + if (strcmp(argv[i], "-isystem") == 0) { + *pv++ = "-S"; + *pv++ = argv[++i]; + } else if (strcmp(argv[i], "-include") == 0) { + *pv++ = "-i"; + *pv++ = argv[++i]; + } else if (strcmp(argv[i], "-idirafter") == 0) { + idirafter = argv[++i]; + } else + goto passa; + break; - case 'k': /* generate PIC code */ - kflag = F_pic; - break; + case 'k': /* generate PIC code */ + kflag = F_pic; + break; - case 'n': /* handle -n flags */ - if (strcmp(argv[i], "-nostdinc") == 0) - nostdinc++; - if (strcmp(argv[i], "-nostdlib") == 0) { - nostdlib++; - nostartfiles++; - } else if (strcmp(argv[i], "-nostartfiles") == 0) - nostartfiles = 1; - else - goto passa; - break; + case 'm': /* target-dependent options */ + mlist[nm++] = argv[i]; + break; - case 'p': - if (strcmp(argv[i], "-pg") == 0) - pgflag++; - else if (strcmp(argv[i], "-pthread") == 0) - pthreads++; - else - errorx(1, "unknown option %s", argv[i]); - break; + case 'n': /* handle -n flags */ + if (strcmp(argv[i], "-nostdinc") == 0) + nostdinc++; + else if (strcmp(argv[i], "-nostdlib") == 0) { + nostdlib++; + nostartfiles++; + } else if (strcmp(argv[i], "-nostartfiles") == 0) + nostartfiles = 1; + else + goto passa; + break; - case 'x': - xlist[xnum++] = argv[i]; - break; - case 't': - tflag++; - break; - case 'S': - sflag++; - cflag++; - break; - case 'o': - if (outfile) - errorx(8, "too many -o"); - outfile = argv[++i]; - break; - case 'O': - Oflag++; - break; - case 'E': - Eflag++; - break; - case 'P': - pflag++; - *pv++ = argv[i]; - case 'c': - cflag++; - break; + case 'p': + if (strcmp(argv[i], "-pg") == 0 || + strcmp(argv[i], "-p") == 0) + pgflag++; + else if (strcmp(argv[i], "-pthread") == 0) + pthreads++; + else if (strcmp(argv[i], "-pipe") == 0) + /* NOTHING YET */; + else + errorx(1, "unknown option %s", argv[i]); + break; + + case 'x': + t = &argv[i][2]; + if (*t == 0) + t = argv[++i]; + if (strcmp(t, "c") == 0) + xcflag = 1; /* default */ + else if (strcmp(t, "assembler-with-cpp") == 0) + ascpp = 1; +#ifdef notyet + else if (strcmp(t, "c++") == 0) + cxxflag++; +#endif + else + xlist[xnum++] = argv[i]; + break; + case 't': + tflag++; + break; + case 'S': + sflag++; + cflag++; + break; + case 'o': + if (outfile) + errorx(8, "too many -o"); + outfile = argv[++i]; + break; + case 'O': + if (argv[i][2] == '0') + Oflag = 0; + else + Oflag++; + break; + case 'E': + Eflag++; + break; + case 'P': + pflag++; + *pv++ = argv[i]; + case 'c': + cflag++; + break; #if 0 - case '2': - if(argv[i][2] == '\0') - pref = "/lib/crt2.o"; - else { - pref = "/lib/crt20.o"; - } - break; + case '2': + if(argv[i][2] == '\0') + pref = "/lib/crt2.o"; + else { + pref = "/lib/crt20.o"; + } + break; #endif - case 'D': - case 'I': - case 'U': - case 'C': - *pv++ = argv[i]; - if (argv[i][2] == 0) - *pv++ = argv[++i]; - if (pv >= ptemp+MAXOPT) - { - error("Too many DIUC options"); - --pv; + case 'C': + Cflag = 1; + break; + case 'D': + case 'I': + case 'U': + *pv++ = argv[i]; + if (argv[i][2] == 0) + *pv++ = argv[++i]; + if (pv >= ptemp+MAXOPT) { + error("Too many DIU options"); + --pv; } - break; + break; - case 'M': - Mflag++; - break; + case 'M': + Mflag++; + break; - case 'd': - dflag++; - strncpy(alist, argv[i], 19); - break; - case 'v': - printf("%s\n", VERSSTR); - vflag++; - break; + case 'd': + dflag++; + strlcpy(alist, argv[i], sizeof (alist)); + break; + case 'v': + printf("%s\n", VERSSTR); + vflag++; + break; - case 's': - if (strcmp(argv[i], "-static") == 0) - Bstatic = 1; - else - goto passa; - break; + case 's': + if (strcmp(argv[i], "-static") == 0) + Bstatic = 1; + else if (strcmp(argv[i], "-shared") == 0) { + shared = 1; +#ifndef os_win32 + nostdlib = 1; +#endif + } else if (strncmp(argv[i], "-std", 4) == 0) { + /* ignore gcc -std= */; + } else + goto passa; + break; + } } else { passa: t = argv[i]; if (*argv[i] == '-' && argv[i][1] == 'L') ; else if((c=getsuf(t))=='c' || c=='S' || c=='i' || - c=='s'|| Eflag) { + c=='s'|| Eflag || xcflag) { clist[nc++] = t; - if (nc>=MAXFIL) - { + if (nc>=MAXFIL) { error("Too many source files"); exit(1); - } + } t = setsuf(t, 'o'); } - if (nodup(llist, t)) { + + /* Check for duplicate .o files. */ + for (j = getsuf(t) == 'o' ? 0 : nl; j < nl; j++) { + if (strcmp(llist[j], t) == 0) + break; + } + if (j == nl) { llist[nl++] = t; - if (nl >= MAXLIB) - { + if (nl >= MAXLIB) { error("Too many object/library files"); exit(1); - } + } if (getsuf(t)=='o') nxo++; } @@ -329,31 +599,30 @@ if (outfile && clist[0] && strcmp(outfile, clist[0]) == 0) errorx(8, "output file will be clobbered"); #if 0 - for(i=0, j=0; iname; Wf++) { + if (Wf->flags != INWALL) + continue; + av[na++] = Wf->name; + } + } + if (Wflag) { + /* set all positive flags */ + for (Wf = Wflags; Wf->name; Wf++) { + if (Wf->flags == NEGATIVE) + continue; + av[na++] = Wf->name; + } + } + for (j = 0; j < nw; j++) + av[na++] = wlist[j]; + for (j = 0; j < nf; j++) + av[na++] = flist[j]; if (vflag) av[na++] = "-v"; + if (pgflag) + av[na++] = "-p"; if (gflag) av[na++] = "-g"; +#ifdef os_darwin + /* darwin always wants PIC compilation */ + if (!Bstatic) + av[na++] = "-k"; +#else if (kflag) av[na++] = "-k"; +#endif if (Oflag) { av[na++] = "-xtemps"; + av[na++] = "-xdeljumps"; + av[na++] = "-xinline"; } for (j = 0; j < xnum; j++) av[na++] = xlist[j]; - av[na++] = tmp4; + for (j = 0; j < nm; j++) + av[na++] = mlist[j]; + if (getsuf(clist[i])=='i') + av[na++] = clist[i]; + else + av[na++] = tmp4; /* created by cpp */ if (pflag || exfail) { cflag++; @@ -440,11 +767,11 @@ } if(sflag) { if (outfile) - assource = tmp3 = outfile; + tmp3 = outfile; else - assource = tmp3 = setsuf(clist[i], 's'); + tmp3 = setsuf(clist[i], 's'); } - av[na++] = tmp3; + ermfile = av[na++] = tmp3; #if 0 if (proflag) { av[3] = "-XP"; @@ -466,21 +793,30 @@ */ assemble: na = 0; - av[na++] = "as"; + av[na++] = as; + for (j = 0; j < nas; j++) + av[na++] = aslist[j]; +#if defined(os_sunos) && defined(mach_sparc64) + av[na++] = "-m64"; +#endif +#if defined(os_darwin) + if (Bstatic) + av[na++] = "-static"; +#endif if (vflag) av[na++] = "-v"; if (kflag) av[na++] = "-k"; av[na++] = "-o"; if (outfile && cflag) - av[na++] = outfile; + ermfile = av[na++] = outfile; else - av[na++] = setsuf(clist[i], 'o'); - av[na++] = onlyas ? tmp4 : assource; + ermfile = av[na++] = setsuf(clist[i], 'o'); + av[na++] = assource; if (dflag) av[na++] = alist; av[na++] = 0; - if (callsys("/bin/as", av)) { + if (callsys(as, av)) { cflag++; eflag++; cunlink(tmp4); @@ -498,26 +834,86 @@ nocom: if (cflag==0 && nl!=0) { j = 0; - av[j++] = "ld"; + av[j++] = ld; +#ifndef MSLINKER if (vflag) av[j++] = "-v"; +#endif +#if !defined(os_sunos) && !defined(os_win32) && !defined(os_darwin) av[j++] = "-X"; - av[j++] = "-d"; - av[j++] = "-e"; - av[j++] = STARTLABEL; - if (Bstatic == 0) { /* Dynamic linkage */ - for (i = 0; dynlinker[i]; i++) - av[j++] = dynlinker[i]; - } else - av[j++] = "-Bstatic"; +#endif + if (shared) { + av[j++] = "-shared"; +#ifdef os_win32 + av[j++] = "-Bdynamic"; +#endif +#ifndef os_sunos + } else { +#ifndef os_win32 +#ifndef os_darwin + av[j++] = "-d"; +#endif + av[j++] = "-e"; + av[j++] = STARTLABEL; +#endif +#endif + if (Bstatic == 0) { /* Dynamic linkage */ +#ifdef DYNLINKER + for (i = 0; dynlinker[i]; i++) + av[j++] = dynlinker[i]; +#endif + } else { +#ifdef os_darwin + av[j++] = "-static"; +#else + av[j++] = "-Bstatic"; +#endif + } + } if (outfile) { +#ifdef MSLINKER +#define OUTSTR "/OUT:" + char *s = copy(OUTSTR, i = strlen(outfile)); + strlcat(s, outfile, sizeof(OUTSTR) + i); + av[j++] = s; +#else av[j++] = "-o"; av[j++] = outfile; +#endif } - if (!nostartfiles) { - av[j++] = crt0file; - for (i = 0; startfiles[i]; i++) - av[j++] = startfiles[i]; +#ifdef STARTFILES_S + if (shared) { + if (!nostartfiles) { + for (i = 0; startfiles_S[i]; i++) + av[j++] = Bprefix(startfiles_S[i]); + } + } else +#endif + { + if (!nostartfiles) { +#ifdef CRT0FILE_PROFILE + if (pgflag) { + av[j++] = Bprefix(crt0file_profile); + } else +#endif + { +#ifdef CRT0FILE + av[j++] = Bprefix(crt0file); +#endif + } +#ifdef STARTFILES_T + if (Bstatic) { + for (i = 0; startfiles_T[i]; i++) + av[j++] = Bprefix(startfiles_T[i]); + } else +#endif + { +#ifdef STARTFILES + for (i = 0; startfiles[i]; i++) + av[j++] = Bprefix(startfiles[i]); +#endif + } + } } i = 0; while(i= MAXAV) error("Too many ld options"); } +#ifndef MACHOABI + /* darwin assembler doesn't want -g */ + if (gflag) + av[j++] = "-g"; +#endif #if 0 if (gflag) av[j++] = "-lg"; #endif if (pthreads) av[j++] = "-lpthread"; - if (!nostdlib) - for (i = 0; libclibs[i]; i++) - av[j++] = libclibs[i]; + if (!nostdlib) { +#ifdef MSLINKER +#define DL "/LIBPATH:" +#else +#define DL "-L" +#endif + char *s = copy(DL, i = strlen(pcclibdir)); + strlcat(s, pcclibdir, sizeof(DL) + i); + av[j++] = s; +#ifdef os_win32 + s = copy(DL, i = strlen(libdir)); + strlcat(s, libdir, sizeof(DL) + i); + av[j++] = s; +#endif + if (pgflag) { + for (i = 0; libclibs_profile[i]; i++) + av[j++] = Bprefix(libclibs_profile[i]); + } else { + for (i = 0; libclibs[i]; i++) + av[j++] = Bprefix(libclibs[i]); + } + } if (!nostartfiles) { - for (i = 0; endfiles[i]; i++) - av[j++] = endfiles[i]; +#ifdef STARTFILES_S + if (shared) { + for (i = 0; endfiles_S[i]; i++) + av[j++] = Bprefix(endfiles_S[i]); + } else +#endif + { +#ifdef STARTFILES_T + if (Bstatic) { + for (i = 0; endfiles_T[i]; i++) + av[j++] = Bprefix(endfiles_T[i]); + } else +#endif + { +#ifdef STARTFILES + for (i = 0; endfiles[i]; i++) + av[j++] = Bprefix(endfiles[i]); +#endif + } + } } av[j++] = 0; - eflag |= callsys("/bin/ld", av); + eflag |= callsys(ld, av); if (nc==1 && nxo==1 && eflag==0) cunlink(setsuf(clist[0], 'o')); else if (nc > 0 && eflag == 0) { @@ -572,6 +1010,10 @@ cunlink(tmp3); cunlink(tmp4); } + if (exfail || eflag) + cunlink(ermfile); + if (eval == 100) + _exit(eval); exit(eval); } @@ -612,14 +1054,47 @@ dexit(eval); } +char * +Bprefix(char *s) +{ + char *suffix; + char *str; + int i; + +#ifdef os_win32 + + /* put here to save sprinkling it ~everywhere */ + s = win32pathsubst(s); + + if (Bflag == NULL) + return s; + suffix = strrchr(s, '/'); + if (suffix == NULL) + suffix = strrchr(s, '\\'); + +#else + + if (Bflag == NULL || s[0] != '/') + return s; + suffix = strrchr(s, '/'); + +#endif + + if (suffix == NULL) + suffix = s; + + str = copy(Bflag, i = strlen(suffix)); + strlcat(str, suffix, strlen(Bflag) + i + 1); + return str; +} + int -getsuf(as) -char as[]; +getsuf(char *s) { - register char *s; + register char *p; - if ((s = strrchr(as, '.')) && s[1] != '\0' && s[2] == '\0') - return s[1]; + if ((p = strrchr(s, '.')) && p[1] != '\0' && p[2] == '\0') + return p[1]; return(0); } @@ -629,16 +1104,71 @@ char * setsuf(char *s, char ch) { - s = copy(basename(s)); - s[strlen(s) - 1] = ch; + char *p; + + s = copy(basename(s), 2); + if ((p = strrchr(s, '.')) == NULL) { + p = s + strlen(s); + p[0] = '.'; + } + p[1] = ch; + p[2] = '\0'; return(s); } +#ifdef WIN32 int -callsys(char f[], char *v[]) +callsys(char *f, char *v[]) { - int status; - pid_t t; + int t; + char cmd[MAX_PATH]; + int len; + STARTUPINFO si; + PROCESS_INFORMATION pi; + DWORD exitCode; + BOOL ok; + + len = strlcpy(cmd, f, MAX_PATH); + for (t = 1; v[t] && len < MAX_PATH; t++) { + len = strlcat(cmd, " ", MAX_PATH); + len = strlcat(cmd, v[t], MAX_PATH); + } + + if (vflag) + printf("%s\n", cmd); + + ZeroMemory(&si, sizeof(STARTUPINFO)); + si.cb = sizeof(STARTUPINFO); + ZeroMemory(&pi, sizeof(PROCESS_INFORMATION)); + + ok = CreateProcess(NULL, // the executable program + cmd, // the command line arguments + NULL, // ignored + NULL, // ignored + TRUE, // inherit handles + HIGH_PRIORITY_CLASS, + NULL, // ignored + NULL, // ignored + &si, + &pi); + + if (!ok) { + fprintf(stderr, "Can't find %s\n", f); + return 100; + } + + WaitForSingleObject(pi.hProcess, INFINITE); + GetExitCodeProcess(pi.hProcess, &exitCode); + return (exitCode != 0); +} + +#else + +int +callsys(char *f, char *v[]) +{ + int t, status = 0; + pid_t p; char *s; if (vflag) { @@ -648,82 +1178,94 @@ fprintf(stderr, "\n"); } - if ((t=fork())==0) { + if ((p = fork()) == 0) { if (Bflag) { size_t len = strlen(Bflag) + 8; char *a = malloc(len); - if (a == NULL) - errorx(1, "callsys: malloc failed\n"); + if (a == NULL) { + error("callsys: malloc failed"); + exit(1); + } if ((s = strrchr(f, '/'))) { strlcpy(a, Bflag, len); strlcat(a, s, len); execv(a, v); } } - execv(f, v); + execvp(f, v); if ((s = strrchr(f, '/'))) execvp(s+1, v); - printf("Can't find %s\n", f); - exit(100); - } else - if (t == -1) { + fprintf(stderr, "Can't find %s\n", f); + _exit(100); + } else { + if (p == -1) { printf("Try again\n"); return(100); } - while(t!=wait(&status)); - if ((t=(status&0377)) != 0 && t!=14) { - if (t!=2) /* interrupt */ - errorx(8, "Fatal error in %s", f); - dexit(eflag); } - return((status>>8) & 0377); + while (waitpid(p, &status, 0) == -1 && errno == EINTR) + ; + if (WIFEXITED(status)) + return (WEXITSTATUS(status)); + if (WIFSIGNALED(status)) + dexit(eflag ? eflag : 1); + errorx(8, "Fatal error in %s", f); + + return 0; } +#endif +/* + * Make a copy of string as, mallocing extra bytes in the string. + */ char * -copy(char *as) +copy(char *s, int extra) { - char *p; - - if ((p = strdup(as)) == NULL) - errorx(8, "no space for file names"); + int len = strlen(s)+1; + char *rv; - return p; + rv = ccmalloc(len+extra); + strlcpy(rv, s, len); + return rv; } int -nodup(l, os) -char **l, *os; +cunlink(char *f) { - register char *t, *s; - register int c; - - s = os; - if (getsuf(s) != 'o') - return(1); - while((t = *l++)) { - while((c = *s++)) - if (c != *t++) - break; - if (*t=='\0' && c=='\0') - return(0); - s = os; - } - return(1); + if (f==0 || Xflag) + return(0); + return (unlink(f)); } -int -cunlink(f) -char *f; +#ifdef WIN32 +char * +gettmp(void) { - if (f==0 || Xflag) - return(0); - return(unlink(f)); +#define BUFFSIZE 1000 + DWORD pathSize; + char pathBuffer[BUFFSIZE]; + char tempFilename[MAX_PATH]; + UINT uniqueNum; + + pathSize = GetTempPath(BUFFSIZE, pathBuffer); + if (pathSize < BUFFSIZE) + pathBuffer[pathSize] = 0; + else + pathBuffer[0] = 0; + uniqueNum = GetTempFileName(pathBuffer, "ctm", 0, tempFilename); + if (uniqueNum == 0) { + fprintf(stderr, "%s:\n", pathBuffer); + exit(8); + } + return copy(tempFilename, 0); } +#else + char * -gettmp() +gettmp(void) { - char *sfn = strdup("/tmp/ctm.XXXXXX"); + char *sfn = copy("/tmp/ctm.XXXXXX", 0); int fd = -1; if ((fd = mkstemp(sfn)) == -1) { @@ -731,6 +1273,43 @@ exit(8); } close(fd); - return sfn; } +#endif + +void * +ccmalloc(int size) +{ + void *rv; + + if ((rv = malloc(size)) == NULL) + error("malloc failed"); + return rv; +} + +#ifdef WIN32 + +char * +win32pathsubst(char *s) +{ + char env[1024]; + char *rv; + int len; + + len = ExpandEnvironmentStrings(s, env, sizeof(env)); + if (len <= 0) + return s; + + while (env[len-1] == '/' || env[len-1] == '\\' || env[len-1] == '\0') + env[--len] = 0; + + len += 3; + rv = ccmalloc(len); + strlcpy(rv, "\"", len); + strlcat(rv, env, len); + strlcat(rv, "\"", len); + + return rv; +} + +#endif Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cc/Makefile,v retrieving revision 1.8 retrieving revision 1.9 diff -L usr.bin/pcc/cc/Makefile -L usr.bin/pcc/cc/Makefile -u -r1.8 -r1.9 --- usr.bin/pcc/cc/Makefile +++ usr.bin/pcc/cc/Makefile @@ -5,8 +5,8 @@ TARGOS= midnightbsd TARGMACH= ${MACHINE_ARCH} -CFLAGS+= -DLIBEXECDIR=\"/usr/libexec\" -CFLAGS+= -I${.CURDIR}/.. +CFLAGS+= -DLIBEXECDIR=\"/usr/libexec/\" +CFLAGS+= -I${.CURDIR}/.. -I${.CURDIR}/../mip/ CFLAGS+= -Dmach_${TARGMACH} -Dos_${TARGOS} BINDIR= /usr/bin Index: inline.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/inline.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/inline.c -L usr.bin/pcc/ccom/inline.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/inline.c +++ usr.bin/pcc/ccom/inline.c @@ -1,6 +1,6 @@ -/* $Id: inline.c,v 1.17 2007/09/09 10:01:01 ragge Exp $ */ +/* $Id: inline.c,v 1.25 2008/11/28 15:23:57 ragge Exp $ */ /* - * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * Copyright (c) 2003, 2008 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -32,104 +32,135 @@ #include /* + * Simple description of how the inlining works: + * A function found with the keyword "inline" is always saved. + * If it also has the keyword "extern" it is written out thereafter. + * If it has the keyword "static" it will be written out if it is referenced. + * inlining will only be done if -xinline is given, and only if it is + * possible to inline the function. + */ +static void printip(struct interpass *pole); + +/* * ilink from ipole points to the next struct in the list of functions. */ static struct istat { - struct istat *ilink; - char *name; - int type; -#define NOTYETR 0 /* saved but not yet referenced */ -#define NOTYETW 1 /* saved and referenced but not yet written out */ -#define WRITTEN 2 /* is written out */ -#define NOTYETD 3 /* referenced but not yet saved */ + SLIST_ENTRY(istat) link; + struct symtab *sp; + int flags; +#define CANINL 1 /* function is possible to inline */ +#define WRITTEN 2 /* function is written out */ +#define REFD 4 /* Referenced but not yet written out */ + int *args; /* Array of arg temp numbers */ + int nargs; /* number of args in array */ + int retval; /* number of return temporary, if any */ struct interpass shead; -} *ipole, *cifun; +} *cifun; + +static SLIST_HEAD(, istat) ipole = { NULL, &ipole.q_forw }; +static int nlabs; #define IP_REF (MAXIP+1) +#ifdef PCC_DEBUG +#define SDEBUG(x) if (sdebug) printf x +#else +#define SDEBUG(x) +#endif -int isinlining, recovernodes; +int isinlining; int inlnodecnt, inlstatcnt; -#define ialloc() permalloc(sizeof(struct istat)); inlstatcnt++ -#define nalloc() permalloc(sizeof(NODE)) +#define SZSI sizeof(struct istat) +#define ialloc() memset(permalloc(SZSI), 0, SZSI); inlstatcnt++ static void -tcnt(NODE *p) +tcnt(NODE *p, void *arg) { inlnodecnt++; + if (nlabs > 1 && (p->n_op == REG || p->n_op == OREG) && + regno(p) == FPREG) + SLIST_FIRST(&ipole)->flags &= ~CANINL; /* no stack refs */ + if (nflag) + printf("locking node %p\n", p); } static struct istat * -findfun(char *name) +findfun(struct symtab *sp) { - struct istat *is = ipole; - while (is) { - if (is->name == name) + struct istat *is; + + SLIST_FOREACH(is, &ipole, link) + if (is->sp == sp) return is; - is = is->ilink; - } return NULL; } static void -refnode(char *str) +refnode(struct symtab *sp) { struct interpass *ip; - if (sdebug) - printf("refnode(%s)\n", str); + SDEBUG(("refnode(%s)\n", sp->sname)); ip = permalloc(sizeof(*ip)); ip->type = IP_REF; - ip->ip_name = str; + ip->ip_name = (char *)sp; inline_addarg(ip); } void inline_addarg(struct interpass *ip) { + extern NODE *cftnod; + +// SDEBUG(("inline_addarg(%p)\n", ip)); DLIST_INSERT_BEFORE(&cifun->shead, ip, qelem); + if (ip->type == IP_DEFLAB) + nlabs++; if (ip->type == IP_NODE) - walkf(ip->ip_node, tcnt); /* Count as saved */ + walkf(ip->ip_node, tcnt, 0); /* Count as saved */ + if (cftnod) + cifun->retval = regno(cftnod); } /* * Called to setup for inlining of a new function. */ void -inline_start(char *name) +inline_start(struct symtab *sp) { struct istat *is; - if (sdebug) - printf("inline_start(\"%s\")\n", name); + SDEBUG(("inline_start(\"%s\")\n", sp->sname)); if (isinlining) cerror("already inlining function"); - if ((is = findfun(name)) == 0) { - is = ialloc(); - is->ilink = ipole; - ipole = is; - is->name = name; - is->type = NOTYETR; + if ((is = findfun(sp)) != 0) { + if (!DLIST_ISEMPTY(&is->shead, qelem)) + uerror("inline function already defined"); } else { - if (is->type != NOTYETD) - cerror("inline function already defined"); - is->type = NOTYETW; + is = ialloc(); + is->sp = sp; + SLIST_INSERT_FIRST(&ipole, is, link); + DLIST_INIT(&is->shead, qelem); } - DLIST_INIT(&is->shead, qelem); cifun = is; + nlabs = 0; isinlining++; } void inline_end() { - if (sdebug) - printf("inline_end()\n"); + SDEBUG(("inline_end()\n")); + if (sdebug)printip(&cifun->shead); isinlining = 0; + if (cifun->sp->sclass == EXTDEF) { + cifun->flags |= REFD; + inline_prtout(); + } } /* @@ -138,49 +169,85 @@ * The function may not be defined when inline_ref() is called. */ void -inline_ref(char *name) +inline_ref(struct symtab *sp) { - struct istat *w = ipole; + struct istat *w; - if (sdebug) - printf("inline_ref(\"%s\")\n", name); + SDEBUG(("inline_ref(\"%s\")\n", sp->sname)); + if (sp->sclass == SNULL) + return; /* only inline, no references */ if (isinlining) { - refnode(name); + refnode(sp); } else { - while (w != NULL) { - if (w->name == name) { - if (w->type == NOTYETR) - w->type = NOTYETW; - return; /* setup for writeout */ - } - w = w->ilink; + SLIST_FOREACH(w,&ipole, link) { + if (w->sp != sp) + continue; + w->flags |= REFD; + return; } /* function not yet defined, print out when found */ w = ialloc(); - w->ilink = ipole; - ipole = w; - w->name = name; - w->type = NOTYETD; + w->sp = sp; + w->flags |= REFD; + SLIST_INSERT_FIRST(&ipole, w, link); + DLIST_INIT(&w->shead, qelem); } } static void puto(struct istat *w) { + struct interpass_prolog *ipp, *epp, *pp; struct interpass *ip, *nip; + extern int crslab; + int lbloff = 0; - /* if -O, list will be saved again so foreach cannot be used */ - ip = DLIST_NEXT(&w->shead, qelem); - while (ip != (&w->shead)) { - nip = DLIST_NEXT(ip, qelem); - DLIST_REMOVE(ip, qelem); - if (ip->type == IP_REF) - inline_ref(ip->ip_name); - else - pass2_compile(ip); - ip = nip; + /* Copy the saved function and print it out */ + ipp = 0; /* XXX data flow analysis */ + DLIST_FOREACH(ip, &w->shead, qelem) { + switch (ip->type) { + case IP_EPILOG: + case IP_PROLOG: + if (ip->type == IP_PROLOG) { + ipp = (struct interpass_prolog *)ip; + /* fix label offsets */ + lbloff = crslab - ipp->ip_lblnum; + } else { + epp = (struct interpass_prolog *)ip; + crslab += (epp->ip_lblnum - ipp->ip_lblnum); + } + pp = tmpalloc(sizeof(struct interpass_prolog)); + memcpy(pp, ip, sizeof(struct interpass_prolog)); + pp->ip_lblnum += lbloff; +#ifdef PCC_DEBUG + if (ip->type == IP_EPILOG && crslab != pp->ip_lblnum) + cerror("puto: %d != %d", crslab, pp->ip_lblnum); +#endif + pass2_compile((struct interpass *)pp); + break; + + case IP_REF: + inline_ref((struct symtab *)ip->ip_name); + break; + + default: + nip = tmpalloc(sizeof(struct interpass)); + *nip = *ip; + if (nip->type == IP_NODE) { + NODE *p; + + p = nip->ip_node = tcopy(nip->ip_node); + if (p->n_op == GOTO) + p->n_left->n_lval += lbloff; + else if (p->n_op == CBRANCH) + p->n_right->n_lval += lbloff; + } else if (nip->type == IP_DEFLAB) + nip->ip_lbl += lbloff; + pass2_compile(nip); + break; + } } - DLIST_INIT(&w->shead, qelem); + w->flags |= WRITTEN; } /* @@ -189,21 +256,246 @@ void inline_prtout() { - struct istat *w = ipole; + struct istat *w; int gotone = 0; - if (w == NULL) - return; - recovernodes++; - while (w != NULL) { - if (w->type == NOTYETW) { + SLIST_FOREACH(w, &ipole, link) { + if ((w->flags & (REFD|WRITTEN)) == REFD && + !DLIST_ISEMPTY(&w->shead, qelem)) { + defloc(w->sp); puto(w); - w->type = WRITTEN; + w->flags |= WRITTEN; gotone++; } - w = w->ilink; } if (gotone) inline_prtout(); - recovernodes--; +} + +#if 1 +static void +printip(struct interpass *pole) +{ + static char *foo[] = { + 0, "NODE", "PROLOG", "STKOFF", "EPILOG", "DEFLAB", "DEFNAM", "ASM" }; + struct interpass *ip; + struct interpass_prolog *ipplg, *epplg; + + DLIST_FOREACH(ip, pole, qelem) { + if (ip->type > MAXIP) + printf("IP(%d) (%p): ", ip->type, ip); + else + printf("%s (%p): ", foo[ip->type], ip); + switch (ip->type) { + case IP_NODE: printf("\n"); +#ifdef PCC_DEBUG + fwalk(ip->ip_node, eprint, 0); break; +#endif + case IP_PROLOG: + ipplg = (struct interpass_prolog *)ip; + printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", + ipplg->ipp_name, ipplg->ipp_vis ? "(local)" : "", + ipplg->ipp_regs[0], ipplg->ipp_autos, ipplg->ip_tmpnum, + ipplg->ip_lblnum); + break; + case IP_EPILOG: + epplg = (struct interpass_prolog *)ip; + printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", + epplg->ipp_name, epplg->ipp_vis ? "(local)" : "", + epplg->ipp_regs[0], epplg->ipp_autos, epplg->ip_tmpnum, + epplg->ip_lblnum); + break; + case IP_DEFLAB: printf(LABFMT "\n", ip->ip_lbl); break; + case IP_DEFNAM: printf("\n"); break; + case IP_ASM: printf("%s\n", ip->ip_asm); break; + default: + break; + } + } +} +#endif + +static int toff; + +static NODE * +mnode(int *n, NODE *p) +{ + NODE *q; + int num = *n + toff; + + if (p->n_op == CM) { + q = p->n_right; + q = tempnode(num, q->n_type, q->n_df, q->n_sue); + n--; + p->n_right = buildtree(ASSIGN, q, p->n_right); + p->n_left = mnode(n, p->n_left); + p->n_op = COMOP; + } else { + p = pconvert(p); + q = tempnode(num, p->n_type, p->n_df, p->n_sue); + p = buildtree(ASSIGN, q, p); + } + return p; +} + +static void +rtmps(NODE *p, void *arg) +{ + if (p->n_op == TEMP) + regno(p) += toff; +} + +/* + * Inline a function. Returns the return value. + * There are two major things that must be converted when + * inlining a function: + * - Label numbers must be updated with an offset. + * - The stack block must be relocated (add to REG or OREG). + * - Temporaries should be updated (but no must) + */ +NODE * +inlinetree(struct symtab *sp, NODE *f, NODE *ap) +{ + extern int crslab, tvaloff; + struct istat *is = findfun(sp); + struct interpass *ip, *ipf, *ipl; + int lmin, stksz, L0, L1, L2; + OFFSZ stkoff; + NODE *p, *rp; + + if (is == NULL) { + inline_ref(sp); /* prototype of not yet declared inline ftn */ + return NIL; + } + + SDEBUG(("inlinetree(%p,%p) OK %d\n", f, ap, is->flags & CANINL)); + + if ((is->flags & CANINL) == 0 || xinline == 0) { + if (is->sp->sclass == STATIC || is->sp->sclass == USTATIC) + is->flags |= REFD; /* if static inline, emit */ + return NIL; + } + +#ifdef mach_i386 + if (kflag) { + is->flags |= REFD; /* if static inline, emit */ + return NIL; /* XXX cannot handle hidden ebx arg */ + } +#endif + + stksz = stkoff = 0; + /* emit jumps to surround inline function */ + branch(L0 = getlab()); + plabel(L1 = getlab()); + L2 = getlab(); + SDEBUG(("branch labels %d,%d,%d\n", L0, L1, L2)); + + ipf = DLIST_NEXT(&is->shead, qelem); /* prolog */ + ipl = DLIST_PREV(&is->shead, qelem); /* epilog */ + + /* Fix label & temp offsets */ +#define IPP(x) ((struct interpass_prolog *)x) + SDEBUG(("pre-offsets crslab %d tvaloff %d\n", crslab, tvaloff)); + lmin = crslab - IPP(ipf)->ip_lblnum; + crslab += (IPP(ipl)->ip_lblnum - IPP(ipf)->ip_lblnum) + 1; + toff = tvaloff - IPP(ipf)->ip_tmpnum; + tvaloff += (IPP(ipl)->ip_tmpnum - IPP(ipf)->ip_tmpnum) + 1; + SDEBUG(("offsets crslab %d lmin %d tvaloff %d toff %d\n", + crslab, lmin, tvaloff, toff)); + + /* traverse until first real label */ + ipf = DLIST_NEXT(ipf, qelem); + do + ipf = DLIST_NEXT(ipf, qelem); + while (ipf->type != IP_DEFLAB); + + /* traverse backwards to last label */ + do + ipl = DLIST_PREV(ipl, qelem); + while (ipl->type != IP_DEFLAB); + + /* So, walk over all statements and emit them */ + for (ip = ipf; ip != ipl; ip = DLIST_NEXT(ip, qelem)) { + switch (ip->type) { + case IP_NODE: + p = tcopy(ip->ip_node); + if (p->n_op == GOTO) + p->n_left->n_lval += lmin; + else if (p->n_op == CBRANCH) + p->n_right->n_lval += lmin; + walkf(p, rtmps, 0); +#ifdef PCC_DEBUG + if (sdebug) { + printf("converted node\n"); + fwalk(ip->ip_node, eprint, 0); + fwalk(p, eprint, 0); + } +#endif + send_passt(IP_NODE, p); + break; + + case IP_DEFLAB: + SDEBUG(("converted label %d to %d\n", + ip->ip_lbl, ip->ip_lbl + lmin)); + send_passt(IP_DEFLAB, ip->ip_lbl + lmin); + break; + + case IP_ASM: + send_passt(IP_ASM, ip->ip_asm); + break; + + case IP_REF: + inline_ref((struct symtab *)ip->ip_name); + break; + + default: + cerror("bad inline stmt %d", ip->type); + } + } + SDEBUG(("last label %d to %d\n", ip->ip_lbl, ip->ip_lbl + lmin)); + send_passt(IP_DEFLAB, ip->ip_lbl + lmin); + + branch(L2); + plabel(L0); + + rp = block(GOTO, bcon(L1), NIL, INT, 0, MKSUE(INT)); + if (is->retval) + p = tempnode(is->retval + toff, DECREF(sp->stype), + sp->sdf, sp->ssue); + else + p = bcon(0); + rp = buildtree(COMOP, rp, p); + + if (is->nargs) { + p = mnode(&is->args[is->nargs-1], ap); + rp = buildtree(COMOP, p, rp); + } + + tfree(f); + return rp; +} + +void +inline_args(struct symtab **sp, int nargs) +{ + struct istat *cf; + int i; + + SDEBUG(("inline_args\n")); + cf = cifun; + /* + * First handle arguments. We currently do not inline anything if: + * - function has varargs + * - function args are volatile, checked if no temp node is asg'd. + */ + if (nargs) { + for (i = 0; i < nargs; i++) + if ((sp[i]->sflags & STNODE) == 0) + return; /* not temporary */ + cf->args = permalloc(sizeof(int)*nargs); + for (i = 0; i < nargs; i++) + cf->args[i] = sp[i]->soffset; + } + cf->nargs = nargs; + cf->flags |= CANINL; } Index: scan.l =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/scan.l,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/scan.l -L usr.bin/pcc/ccom/scan.l -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/scan.l +++ usr.bin/pcc/ccom/scan.l @@ -1,5 +1,5 @@ %{ -/* $Id: scan.l,v 1.61 2007/09/19 17:20:26 ragge Exp $ */ +/* $Id: scan.l,v 1.81 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2002 Anders Magnusson. All rights reserved. @@ -38,6 +38,7 @@ IS (u|U|l|L)* %{ +#include #include #include #include @@ -48,30 +49,29 @@ static NODE *cvtdig(int radix); static NODE *charcon(void); static void control(int); -static NODE *floatcon(void); -static NODE *fhexcon(void); -int notype, parbal; +static void pragma(void); +int notype, parbal, inattr, parlvl; +static int resw(TWORD, int); -#define CPP_PRAGMA 1 #define CPP_IDENT 2 #define CPP_LINE 3 #define CPP_HASH 4 #ifdef STABS -#define STABS_LINE(x) if (gflag && blevel) stabs_line(x) +#define STABS_LINE(x) if (gflag && cftnsp) stabs_line(x) #else #define STABS_LINE(x) #endif #if defined(FLEX_SCANNER) && YY_FLEX_SUBMINOR_VERSION >= 31 -/* Hack to avoid unneccessary warnings */ +/* Hack to avoid unnecessary warnings */ FILE *yyget_in (void); FILE *yyget_out (void); int yyget_leng (void); char *yyget_text (void); -void yyset_in (FILE * in_str ); -void yyset_out (FILE * out_str ); +void yyset_in (FILE *); +void yyset_out (FILE *); int yyget_debug (void); -void yyset_debug (int bdebug ); +void yyset_debug (int); int yylex_destroy (void); extern int yyget_lineno (void); extern void yyset_lineno (int); @@ -95,9 +95,9 @@ "case" { return(C_CASE); } "char" { yylval.nodep = mkty((TWORD)CHAR, 0, MKSUE(CHAR)); notype=1; return(C_TYPE); } -"const" { yylval.nodep = - block(QUALIFIER, NIL, NIL, CON, 0, 0); - return(C_QUALIFIER); } +"_Complex" { yylval.nodep = mkty((TWORD)COMPLEX, 0, MKSUE(DOUBLE)); + notype=1; return(C_TYPE); } +"const" { return resw(CON, C_QUALIFIER); } "continue" { return(C_CONTINUE); } "default" { return(C_DEFAULT); } "do" { return(C_DO); } @@ -125,60 +125,48 @@ notype=1; return(C_TYPE); } "sizeof" { return(C_SIZEOF); } "static" { yylval.intval = STATIC; return(C_CLASS); } -"struct" { yylval.intval = INSTRUCT; notype=1; return(C_STRUCT); } +"struct" { yylval.intval = STNAME; notype=1; return(C_STRUCT); } "switch" { return(C_SWITCH); } "typedef" { yylval.intval = TYPEDEF; return(C_CLASS); } -"union" { yylval.intval = INUNION; notype=1; return(C_STRUCT); } +"union" { yylval.intval = UNAME; notype=1; return(C_STRUCT); } "unsigned" { yylval.nodep = mkty((TWORD)UNSIGNED, 0, MKSUE(UNSIGNED)); notype=1; return(C_TYPE); } "void" { yylval.nodep = mkty((TWORD)VOID, 0, MKSUE(VOID)); notype=1; return(C_TYPE); } -"volatile" { yylval.nodep = - block(QUALIFIER, NIL, NIL, VOL, 0, 0); - return(C_QUALIFIER); } +"volatile" { return resw(VOL, C_QUALIFIER); } "while" { return(C_WHILE); } -{L}({L}|{D})* { struct symtab *s; - int i; +{L}({L}|{D})* { struct symtab *s; + int i = 0; - yylval.strp = addname(yytext); - if ((i = gcc_keyword(yylval.strp, - &yylval.nodep)) != 0) - return i; -// printf("str: %s notype %d parbal %d\n", yytext, notype, parbal); - if (!notype) { - s = lookup(yylval.strp, SNOCREAT); - if (s && s->sclass == TYPEDEF) - return notype=1, C_TYPENAME; - } - return(C_NAME); + yylval.strp = addname(yytext); +#ifdef GCC_COMPAT + if ((i = gcc_keyword(yylval.strp, &yylval.nodep)) > 0) + return i; +#endif + if (i == 0) { + if (notype) + return(C_NAME); + s = lookup(yylval.strp, SNOCREAT); + return s && s->sclass == TYPEDEF ? + notype=1, C_TYPENAME : C_NAME; } + } 0[xX]{H}+{IS}? { yylval.nodep = cvtdig(16); return(C_ICON); } 0{D}+{IS}? { yylval.nodep = cvtdig(8); return(C_ICON); } {D}+{IS}? { yylval.nodep = cvtdig(10); return(C_ICON); } L?'(\\.|[^\\'])+' { yylval.nodep = charcon(); return(C_ICON); } -{D}+{E}{FS}? { yylval.nodep = floatcon(); return(C_FCON); } -{D}*"."{D}+({E})?{FS}? { yylval.nodep = floatcon(); return(C_FCON); } -{D}+"."{D}*({E})?{FS}? { yylval.nodep = floatcon(); return(C_FCON); } -0[xX]{H}*"."{H}+{P}{FS}? { yylval.nodep = fhexcon(); return(C_FCON); } -0[xX]{H}+"."{P}{FS}? { yylval.nodep = fhexcon(); return(C_FCON); } -0[xX]{H}+{P}{FS}? { yylval.nodep = fhexcon(); return(C_FCON); } - -L?\"(\\.|[^\\"])*\" { - char *c = yytext; - int i = yyleng-2, rv; - - if (*c++ == 'L') { - c++, i--; - rv = C_WSTRING; - } else - rv = C_STRING; - c[i] = 0; /* last " */ - yylval.strp = c; - return rv; - } +{D}+{E}{FS}? { yylval.nodep = floatcon(yytext); return(C_FCON); } +{D}*"."{D}+({E})?{FS}? { yylval.nodep = floatcon(yytext); return(C_FCON); } +{D}+"."{D}*({E})?{FS}? { yylval.nodep = floatcon(yytext); return(C_FCON); } +0[xX]{H}*"."{H}+{P}{FS}? { yylval.nodep = fhexcon(yytext); return(C_FCON); } +0[xX]{H}+"."{P}{FS}? { yylval.nodep = fhexcon(yytext); return(C_FCON); } +0[xX]{H}+{P}{FS}? { yylval.nodep = fhexcon(yytext); return(C_FCON); } + +L?\"(\\.|[^\\"])*\" { yylval.strp = yytext; return C_STRING; } + "..." { return(C_ELLIPSIS); } ">>=" { yylval.intval = RSEQ; return(C_ASOP); } "<<=" { yylval.intval = LSEQ; return(C_ASOP); } @@ -203,12 +191,16 @@ "!=" { yylval.intval = NE; return(C_EQUOP); } ";" { notype = 0; return(';'); } ("{"|"<%") { notype = 0; return('{'); } -("}"|"%>") { return('}'); } +("}"|"%>") { if (rpole) notype = 1; return('}'); } "," { if (parbal) notype = 0; return(','); } ":" { return(':'); } "=" { return('='); } "(" { parbal++; notype = 0; return('('); } -")" { parbal--; if (parbal==0) { notype = 0; } return(')'); } +")" { parbal--; + if (parbal==0) { notype = 0; } + if (inattr && parlvl == parbal) + inattr = 0; + return(')'); } ("["|"<:") { return('['); } ("]"|":>") { return(']'); } "." { yylval.intval = DOT; return(C_STROP); } @@ -225,7 +217,7 @@ "^" { return('^'); } "|" { return('|'); } "?" { return('?'); } -^#pragma[ \t].* { control(CPP_PRAGMA); } +^#pragma[ \t].* { pragma(); } ^#ident[ \t].* { control(CPP_IDENT); } ^#line[ \t].* { control(CPP_LINE); } ^#.* { control(CPP_HASH); } @@ -246,6 +238,25 @@ return(1); } +int +resw(TWORD t, int rv) +{ + if (inattr) { + yylval.strp = addname(yytext); + return C_NAME; + } + + switch (rv) { + case C_QUALIFIER: + yylval.nodep = block(QUALIFIER, NIL, NIL, t, 0, 0); + return C_QUALIFIER; + default: + cerror("resw"); + } + return 0; +} + +#ifndef SOFTFLOAT /* * XXX floatcon() and fhexcon() should be in support libraries for * the target floating point. @@ -266,9 +277,9 @@ } NODE * -floatcon(void) +floatcon(char *s) { - return f2(yytext); + return f2(s); } static int @@ -283,10 +294,9 @@ } NODE * -fhexcon(void) +fhexcon(char *c) { char buf[500]; - char *c = yytext; unsigned long long num1, num2; /* XXX - convert it to a decimal float number and use strtod */ @@ -307,6 +317,7 @@ snprintf(buf, sizeof(buf), "%llu.%lluE%s", num1, num2, c); return f2(buf); } +#endif unsigned int esccon(char **sptr) @@ -325,9 +336,13 @@ case '\"': val = '\"'; break; case 'x': val = strtoul(wr, &wr, 16); break; case '0': case '1': case '2': case '3': case '4': - case '5': case '6': case '7': case '8': case '9': - wr--; - val = strtoul(wr, &wr, 8); + case '5': case '6': case '7': + val = wr[-1] - '0'; + if (*wr >= '0' && *wr <= '7') { + val = (val << 3) + (*wr++ - '0'); + if (*wr >= '0' && *wr <= '7') + val = (val << 3) + (*wr++ - '0'); + } break; default: val = wr[-1]; } @@ -387,8 +402,7 @@ ntype = UNSIGNED; } ntype = ctype(ntype); - p = block(ICON, NIL, NIL, ntype, 0, MKSUE(ntype)); - p->n_lval = v; + p = xbcon(v, NULL, ntype); ASGLVAL(p->n_slval, v); return p; @@ -432,7 +446,6 @@ wr++; /* Skip initial '#' */ switch (t) { - case CPP_PRAGMA: case CPP_IDENT: return; /* Just skip these for now. */ @@ -447,6 +460,8 @@ lineno = val - 1; while (*wr && *wr != '\"') wr++; + if (*wr == 0) + return; if (*wr++ != '\"') goto bad; eptr = wr; @@ -465,3 +480,62 @@ bad: werror("%s: illegal control", yytext); } + +/* + * split a pragma string in parts. + */ +static char ** +splitup(char *str) +{ + char *s, **ary; + int i; + + /* count ws. at least needed array size, add 2 to terminate */ + for (i = 2, s = str; *s; s++) + if (*s == ' ' || *s == '\t' || + *s == '(' || *s == ')' || *s == ',') + i++; + ary = tmpalloc(sizeof(char *)*i); + for (i = 0, s = strtok(str, " \t(,)"); s; s = strtok(NULL, " \t(,)")) + ary[i++] = s; + ary[i] = NULL; + return ary; +} + +int pragma_allpacked; +int pragma_packed, pragma_aligned; +char *pragma_renamed; + +/* + * got a full pragma line. Split it up here. + */ +static void +pragma() +{ + char **ary; + + ary = splitup(yytext); + if (ary[1] == NULL) + goto bad; + if (strcmp(ary[1], "pack") == 0) { + pragma_allpacked = ary[2] ? atoi(ary[2]) : 0; + } else if (strcmp(ary[1], "packed") == 0) { + pragma_packed = ary[2] ? atoi(ary[2]) : 1; + } else if (strcmp(ary[1], "aligned") == 0) { + pragma_aligned = ary[2] ? atoi(ary[2]) : 1; + } else if (strcmp(ary[1], "rename") == 0) { + pragma_renamed = newstring(ary[2], strlen(ary[2])); + } else if (mypragma(ary)) { + return; + } else { +bad: + if (Wunknown_pragmas) + werror("unknown pragma"); + } +} + +void +cunput(char c) +{ + unput(c); +} Index: pftn.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/pftn.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/pftn.c -L usr.bin/pcc/ccom/pftn.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/pftn.c +++ usr.bin/pcc/ccom/pftn.c @@ -1,4 +1,4 @@ -/* $Id: pftn.c,v 1.171 2007/09/23 20:00:22 ragge Exp $ */ +/* $Id: pftn.c,v 1.241 2008/12/14 17:19:50 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -69,49 +69,41 @@ #include /* XXX - for strcmp */ -struct symtab *spname; +#include "cgram.h" + struct symtab *cftnsp; -static int strunem; /* currently parsed member type */ int arglistcnt, dimfuncnt; /* statistics */ int symtabcnt, suedefcnt; /* statistics */ int autooff, /* the next unused automatic offset */ maxautooff, /* highest used automatic offset in function */ - argoff, /* the next unused argument offset */ - strucoff; /* the next structure offset position */ + argoff; /* the next unused argument offset */ int retlab = NOLAB; /* return label for subroutine */ int brklab; int contlab; int flostat; -int instruct, blevel; +int blevel; int reached, prolab; struct params; -#define ISSTR(ty) (ty == STRTY || ty == UNIONTY || ty == ENUMTY) +#define ISSTR(ty) (ty == STRTY || ty == UNIONTY) #define ISSOU(ty) (ty == STRTY || ty == UNIONTY) #define MKTY(p, t, d, s) r = talloc(); *r = *p; \ r = argcast(r, t, d, s); *p = *r; nfree(r); /* - * Info stored for delaying string printouts. - */ -struct strsched { - struct strsched *next; - int locctr; - struct symtab *sym; -} *strpole; - -/* * Linked list stack while reading in structs. */ struct rstack { struct rstack *rnext; - int rinstruct; - int rclass; - int rstrucoff; - struct params *rlparam; + int rsou; + int rstr; struct symtab *rsym; -}; + struct symtab *rb; + struct suedef *rsue; + int flags; +#define LASTELM 1 +} *rpole; /* * Linked list for parameter (and struct elements) declaration. @@ -127,6 +119,7 @@ static NODE *arrstk[10]; static int arrstkp; static int intcompare; +static NODE *parlink; void fixtype(NODE *p, int class); int fixclass(int class, TWORD type); @@ -135,9 +128,9 @@ void inforce(OFFSZ n); void vfdalign(int n); static void ssave(struct symtab *); -static void strprint(void); static void alprint(union arglist *al, int in); static void lcommadd(struct symtab *sp); +extern int fun_inline; int ddebug = 0; @@ -161,6 +154,9 @@ p = q->n_sp; + if (p->sname == NULL) + cerror("defining null identifier"); + #ifdef PCC_DEBUG if (ddebug) { printf("defid(%s (%p), ", p->sname, p); @@ -195,16 +191,13 @@ if (blevel == 1) { switch (class) { default: - if (!(class&FIELD)) + if (!(class&FIELD) && !ISFTN(type)) uerror("declared argument %s missing", p->sname ); case MOS: - case STNAME: case MOU: - case UNAME: - case MOE: - case ENAME: case TYPEDEF: + case PARAM: ; } } @@ -228,10 +221,11 @@ changed = 0; for (temp = type; temp & TMASK; temp = DECREF(temp)) { if (ISARY(temp)) { - if (dsym->ddim == 0) { + if (dsym->ddim == NOOFFSET) { dsym->ddim = ddef->ddim; changed = 1; - } else if (ddef->ddim != 0 && dsym->ddim!=ddef->ddim) { + } else if (ddef->ddim != NOOFFSET && + dsym->ddim!=ddef->ddim) { goto mismatch; } ++dsym; @@ -252,9 +246,7 @@ #endif /* check that redeclarations are to the same structure */ - if ((temp == STRTY || temp == UNIONTY || temp == ENUMTY) && - p->ssue != q->n_sue && - class != STNAME && class != UNAME && class != ENAME) { + if ((temp == STRTY || temp == UNIONTY) && p->ssue != q->n_sue) { goto mismatch; } @@ -265,99 +257,87 @@ printf(" previous class: %s\n", scnames(scl)); #endif - if (class&FIELD) { - /* redefinition */ - if (!falloc(p, class&FLDSIZ, 1, NIL)) { - /* successful allocation */ - ssave(p); - return; - } - /* blew it: resume at end of switch... */ - } else switch(class) { + if (class & FIELD) + return; + switch(class) { case EXTERN: switch( scl ){ case STATIC: case USTATIC: - if( slev==0 ) return; + if( slev==0 ) + goto done; break; case EXTDEF: case EXTERN: case FORTRAN: case UFORTRAN: - return; + goto done; + case SNULL: + if (p->sflags & SINLINE) { + p->sclass = EXTDEF; + inline_ref(p); + goto done; } + break; + } break; case STATIC: if (scl==USTATIC || (scl==EXTERN && blevel==0)) { p->sclass = STATIC; - return; + goto done; } if (changed || (scl == STATIC && blevel == slev)) - return; /* identical redeclaration */ + goto done; /* identical redeclaration */ break; case USTATIC: if (scl==STATIC || scl==USTATIC) - return; + goto done; break; case TYPEDEF: if (scl == class) - return; + goto done; break; case UFORTRAN: if (scl == UFORTRAN || scl == FORTRAN) - return; + goto done; break; case FORTRAN: if (scl == UFORTRAN) { p->sclass = FORTRAN; - return; + goto done; } break; case MOU: case MOS: - if (scl == class) { - if (oalloc(p, &strucoff)) - break; - if (class == MOU) - strucoff = 0; - ssave(p); - return; - } - break; - - case MOE: - break; + goto done; case EXTDEF: switch (scl) { case EXTERN: p->sclass = EXTDEF; - return; + goto done; case USTATIC: p->sclass = STATIC; - return; + goto done; } break; - case STNAME: - case UNAME: - case ENAME: - if (scl != class) - break; - if (p->ssue->suesize == 0) - return; /* previous entry just a mention */ - break; - case AUTO: case REGISTER: - ; /* mismatch.. */ + if (blevel == slev) + goto redec; + break; /* mismatch.. */ + case SNULL: + if (fun_inline && ISFTN(type)) + goto done; + break; } mismatch: @@ -368,12 +348,12 @@ if (blevel == slev || class == EXTERN || class == FORTRAN || class == UFORTRAN) { if (ISSTR(class) && !ISSTR(p->sclass)) { - uerror("redeclaration of %s", p->sname); +redec: uerror("redeclaration of %s", p->sname); return; } } if (blevel == 0) - uerror("redeclaration of %s", p->sname); + goto redec; q->n_sp = p = hide(p); enter: /* make a new entry */ @@ -387,24 +367,9 @@ p->sclass = class; p->slevel = blevel; p->soffset = NOOFFSET; - p->suse = lineno; - if (class == STNAME || class == UNAME || class == ENAME) { - p->ssue = permalloc(sizeof(struct suedef)); - suedefcnt++; - p->ssue->suesize = 0; - p->ssue->suelem = NULL; - p->ssue->suealign = ALSTRUCT; - } else { - switch (BTYPE(type)) { - case STRTY: - case UNIONTY: - case ENUMTY: - p->ssue = q->n_sue; - break; - default: - p->ssue = MKSUE(BTYPE(type)); - } - } + if (q->n_sue == NULL) + cerror("q->n_sue == NULL"); + p->ssue = q->n_sue; /* copy dimensions */ p->sdf = q->n_df; @@ -415,7 +380,6 @@ /* allocate offsets */ if (class&FIELD) { (void) falloc(p, class&FLDSIZ, 0, NIL); /* new entry */ - ssave(p); } else switch (class) { case REGISTER: @@ -427,47 +391,45 @@ else oalloc(p, &autooff); break; - case STATIC: - case EXTDEF: - p->soffset = getlab(); -#ifdef GCC_COMPAT - { extern char *renname; - if (renname) - gcc_rename(p, renname); - renname = NULL; + case PARAM: + if (ISARY(p->stype)) { + /* remove array type on parameters before oalloc */ + p->stype += (PTR-ARY); + p->sdf++; } -#endif + if (arrstkp) + dynalloc(p, &argoff); + else + oalloc(p, &argoff); break; - + + case STATIC: + case EXTDEF: case EXTERN: case UFORTRAN: case FORTRAN: p->soffset = getlab(); -#ifdef notdef - /* Cannot reset level here. What does the standard say??? */ - p->slevel = 0; -#endif -#ifdef GCC_COMPAT - { extern char *renname; - if (renname) - gcc_rename(p, renname); - renname = NULL; - } -#endif + if (pragma_renamed) + p->soname = pragma_renamed; + pragma_renamed = NULL; break; + case MOU: + rpole->rstr = 0; + /* FALLTHROUGH */ case MOS: - oalloc(p, &strucoff); + oalloc(p, &rpole->rstr); if (class == MOU) - strucoff = 0; - ssave(p); + rpole->rstr = 0; break; - - case MOE: - p->soffset = strucoff++; - ssave(p); + case SNULL: +#ifdef notdef + if (fun_inline) { + p->slevel = 1; + p->soffset = getlab(); + } +#endif break; - } #ifdef STABS @@ -475,12 +437,13 @@ stabs_newsym(p); #endif +done: + fixdef(p); /* Leave last word to target */ #ifdef PCC_DEBUG if (ddebug) printf( " sdf, ssue, offset: %p, %p, %d\n", p->sdf, p->ssue, p->soffset); #endif - } void @@ -492,13 +455,10 @@ p->next = NULL; p->sym = sym; - if (lparam == NULL) { - p->prev = (struct params *)&lpole; + if ((p->prev = lparam) == NULL) lpole = p; - } else { + else lparam->next = p; - p->prev = lparam; - } lparam = p; } @@ -508,22 +468,24 @@ void ftnend() { + extern NODE *cftnod; extern struct savbc *savbc; extern struct swdef *swpole; + extern int tvaloff; char *c; if (retlab != NOLAB && nerrors == 0) { /* inside a real function */ plabel(retlab); + if (cftnod) + ecomp(buildtree(FORCE, cftnod, NIL)); efcode(); /* struct return handled here */ - c = cftnsp->sname; -#ifdef GCC_COMPAT - c = gcc_findname(cftnsp); -#endif + c = cftnsp->soname; SETOFF(maxautooff, ALCHAR); - send_passt(IP_EPILOG, 0, maxautooff/SZCHAR, c, - cftnsp->stype, cftnsp->sclass == EXTDEF, retlab); + send_passt(IP_EPILOG, maxautooff/SZCHAR, c, + cftnsp->stype, cftnsp->sclass == EXTDEF, retlab, tvaloff); } + cftnod = NIL; tcheck(); brklab = contlab = retlab = NOLAB; flostat = 0; @@ -537,6 +499,7 @@ } savbc = NULL; lparam = NULL; + cftnsp = NULL; maxautooff = autooff = AUTOINIT; reached = 1; @@ -544,11 +507,13 @@ inline_end(); inline_prtout(); - strprint(); - tmpfree(); /* Release memory resources */ } +static struct symtab nulsym = { + NULL, 0, 0, 0, 0, "null", "null", INT, 0, NULL, NULL +}; + void dclargs() { @@ -556,15 +521,12 @@ union arglist *al, *al2, *alb; struct params *a; struct symtab *p, **parr = NULL; /* XXX gcc */ - char *c; int i; - argoff = ARGINIT; - /* * Deal with fun(void) properly. */ - if (nparams == 1 && lparam->sym->stype == VOID) + if (nparams == 1 && lparam->sym && lparam->sym->stype == VOID) goto done; /* @@ -575,11 +537,13 @@ parr = tmpalloc(sizeof(struct symtab *) * nparams); if (nparams) - for (a = lparam, i = 0; a != NULL && a != (struct params *)&lpole; - a = a->prev) { - + for (a = lparam, i = 0; a != NULL; a = a->prev) { p = a->sym; parr[i++] = p; + if (p == NULL) { + uerror("parameter %d name missing", i); + p = &nulsym; /* empty symtab */ + } if (p->stype == FARG) { p->stype = INT; p->ssue = MKSUE(INT); @@ -591,8 +555,6 @@ werror("function declared as argument"); p->stype = INCREF(p->stype); } - /* always set aside space, even for register arguments */ - oalloc(p, &argoff); #ifdef STABS if (gflag) stabs_newsym(p); @@ -618,41 +580,66 @@ if (chkftn(al, alb)) uerror("function doesn't match prototype"); intcompare = 0; + } + + if (oldstyle && nparams) { + /* Must recalculate offset for oldstyle args here */ + argoff = ARGINIT; + for (i = 0; i < nparams; i++) { + parr[i]->soffset = NOOFFSET; + oalloc(parr[i], &argoff); + } + } + done: cendarg(); - c = cftnsp->sname; -#ifdef GCC_COMPAT - c = gcc_findname(cftnsp); -#endif -#if 0 - prolab = getlab(); - send_passt(IP_PROLOG, -1, -1, c, cftnsp->stype, - cftnsp->sclass == EXTDEF, prolab); -#endif + plabel(prolab); /* after prolog, used in optimization */ retlab = getlab(); bfcode(parr, nparams); - if (xtemps) { - /* put arguments in temporaries */ - for (i = 0; i < nparams; i++) { - NODE *q, *r, *s; - - p = parr[i]; - if (p->stype == STRTY || p->stype == UNIONTY || - cisreg(p->stype) == 0) - continue; - spname = p; - q = buildtree(NAME, 0, 0); - r = tempnode(0, p->stype, p->sdf, p->ssue); - s = buildtree(ASSIGN, r, q); - p->soffset = r->n_lval; - p->sflags |= STNODE; - ecomp(s); - } - plabel(getlab()); /* used when spilling */ - } + if (fun_inline && xinline) + inline_args(parr, nparams); + plabel(getlab()); /* used when spilling */ + if (parlink) + ecomp(parlink); + parlink = NIL; lparam = NULL; nparams = 0; + symclear(1); /* In case of function pointer args */ +} + +/* + * Struct/union/enum symtab construction. + */ +static void +defstr(struct symtab *sp, int class) +{ + sp->ssue = permalloc(sizeof(struct suedef)); + memset(sp->ssue, 0, sizeof(struct suedef)); + sp->sclass = class; + if (class == STNAME) + sp->stype = STRTY; + else if (class == UNAME) + sp->stype = UNIONTY; + else if (class == ENAME) + sp->stype = ENUMTY; +} + +/* + * Declare a struct/union/enum tag. + * If not found, create a new tag with UNDEF type. + */ +static struct symtab * +deftag(char *name, int class) +{ + struct symtab *sp; + + if ((sp = lookup(name, STAGNAME))->ssue == NULL) { + /* New tag */ + defstr(sp, class); + } else if (sp->sclass != class) + uerror("tag %s redeclared", name); + return sp; } /* @@ -661,194 +648,246 @@ NODE * rstruct(char *tag, int soru) { - struct symtab *p; - NODE *q; + struct symtab *sp; - p = (struct symtab *)lookup(tag, STAGNAME); - switch (p->stype) { + sp = deftag(tag, soru); + return mkty(sp->stype, 0, sp->ssue); +} - case UNDEF: - def: - q = block(NAME, NIL, NIL, 0, 0, 0); - q->n_sp = p; - q->n_type = (soru&INSTRUCT) ? STRTY : - ((soru&INUNION) ? UNIONTY : ENUMTY); - defid(q, (soru&INSTRUCT) ? STNAME : - ((soru&INUNION) ? UNAME : ENAME)); - nfree(q); - break; +static int enumlow, enumhigh; +int enummer; - case STRTY: - if (soru & INSTRUCT) - break; - goto def; +/* + * Declare a member of enum. + */ +void +moedef(char *name) +{ + struct symtab *sp; - case UNIONTY: - if (soru & INUNION) - break; - goto def; + sp = lookup(name, SNORMAL); + if (sp->stype == UNDEF || (sp->slevel < blevel)) { + if (sp->stype != UNDEF) + sp = hide(sp); + sp->stype = INT; /* always */ + sp->ssue = MKSUE(INT); + sp->sclass = MOE; + sp->soffset = enummer; + } else + uerror("%s redeclared", name); + if (enummer < enumlow) + enumlow = enummer; + if (enummer > enumhigh) + enumhigh = enummer; + enummer++; +} - case ENUMTY: - if (!(soru&(INUNION|INSTRUCT))) - break; - goto def; +/* + * Declare an enum tag. Complain if already defined. + */ +struct symtab * +enumhd(char *name) +{ + struct symtab *sp; + + enummer = enumlow = enumhigh = 0; + if (name == NULL) + return NULL; + sp = deftag(name, ENAME); + if (sp->stype != ENUMTY) { + if (sp->slevel == blevel) + uerror("%s redeclared", name); + sp = hide(sp); + defstr(sp, ENAME); } - q = mkty(p->stype, 0, p->ssue); - q->n_sue = p->ssue; - return q; + sp->ssue->sylnk = sp; /* ourselves */ + return sp; } -void -moedef(char *name) +/* + * finish declaration of an enum + */ +NODE * +enumdcl(struct symtab *sp) { - NODE *q; + NODE *p; + TWORD t; - q = block(NAME, NIL, NIL, MOETY, 0, 0); - q->n_sp = lookup(name, 0); - defid(q, MOE); - nfree(q); +#ifdef ENUMSIZE + t = ENUMSIZE(enumhigh, enumlow); +#else + if (enumhigh <= MAX_CHAR && enumlow >= MIN_CHAR) + t = ctype(CHAR); + else if (enumhigh <= MAX_SHORT && enumlow >= MIN_SHORT) + t = ctype(SHORT); + else + t = ctype(INT); +#endif + if (sp) { + sp->stype = t; + sp->ssue = MKSUE(t); + } + p = mkty(t, 0, MKSUE(t)); + p->n_sp = sp; + return p; +} + +/* + * Handle reference to an enum + */ +NODE * +enumref(char *name) +{ + struct symtab *sp; + NODE *p; + + sp = lookup(name, STAGNAME); + +#ifdef notdef + /* + * 6.7.2.3 Clause 2: + * "A type specifier of the form 'enum identifier' without an + * enumerator list shall only appear after the type it specifies + * is complete." + */ + if (sp->sclass != ENAME) + uerror("enum %s undeclared", name); +#endif + if (sp->sclass == SNULL) { + /* declare existence of enum */ + sp = enumhd(name); + sp->stype = ENUMTY; + } + + p = mkty(sp->stype, 0, sp->ssue); + p->n_sp = sp; + return p; } /* * begining of structure or union declaration */ struct rstack * -bstruct(char *name, int soru) +bstruct(char *name, int soru, struct suedef *sue) { struct rstack *r; - struct symtab *s; - NODE *q; + struct symtab *sp; - if (name != NULL) - s = lookup(name, STAGNAME); - else - s = NULL; + if (name != NULL) { + sp = deftag(name, soru); + if (sp->ssue->suealign != 0) { + if (sp->slevel < blevel) { + sp = hide(sp); + defstr(sp, soru); + } else + uerror("%s redeclared", name); + } + } else + sp = NULL; - r = tmpalloc(sizeof(struct rstack)); - r->rinstruct = instruct; - r->rclass = strunem; - r->rstrucoff = strucoff; - - strucoff = 0; - instruct = soru; - q = block(NAME, NIL, NIL, 0, 0, 0); - q->n_sp = s; - if (instruct==INSTRUCT) { - strunem = MOS; - q->n_type = STRTY; - if (s != NULL) - defid(q, STNAME); - } else if(instruct == INUNION) { - strunem = MOU; - q->n_type = UNIONTY; - if (s != NULL) - defid(q, UNAME); - } else { /* enum */ - strunem = MOE; - q->n_type = ENUMTY; - if (s != NULL) - defid(q, ENAME); - } - r->rsym = q->n_sp; - r->rlparam = lparam; - nfree(q); + r = tmpcalloc(sizeof(struct rstack)); + r->rsou = soru; + r->rsym = sp; + r->rb = NULL; + r->rsue = sue; + r->rnext = rpole; + rpole = r; return r; } /* * Called after a struct is declared to restore the environment. + * Alignment and packing are handled here. + * - If ALSTRUCT is defined, this will be the struct alignment and the + * struct size will be a multiple of ALSTRUCT, otherwise it will use + * the alignment of the largest struct member. + * - If suep->suealigned is set, then it will specify the alignment. + * - If suep->suepacked is set, it will pack all struct members. */ NODE * -dclstruct(struct rstack *r) +dclstruct(struct rstack *r, struct suedef *suep) { NODE *n; - struct params *l, *m; struct suedef *sue; - struct symtab *p; - int al, sa, sz; - TWORD temp; - int i, high, low; + struct symtab *sp; + int al, sa, sz, coff; + struct suedef sues; + + if (suep && r->rsue) { /* merge */ + if (suep->suealigned == 0) + suep->suealigned = r->rsue->suealigned; + if (suep->suepacked == 0) + suep->suepacked = r->rsue->suepacked; + } else if (suep == NULL) + suep = r->rsue; + if (suep == NULL) + suep = memset(&sues, 0, sizeof sues); + + if (pragma_allpacked && !suep->suepacked) + suep->suepacked = pragma_allpacked; if (r->rsym == NULL) { sue = permalloc(sizeof(struct suedef)); + memset(sue, 0, sizeof(struct suedef)); suedefcnt++; - sue->suesize = 0; - sue->suealign = ALSTRUCT; } else sue = r->rsym->ssue; -#ifdef PCC_DEBUG - if (ddebug) - printf("dclstruct(%s)\n", r->rsym ? r->rsym->sname : "??"); -#endif - temp = (instruct&INSTRUCT)?STRTY:((instruct&INUNION)?UNIONTY:ENUMTY); - instruct = r->rinstruct; - strunem = r->rclass; +#ifdef ALSTRUCT al = ALSTRUCT; +#else + al = ALCHAR; +#endif - high = low = 0; - - if ((l = r->rlparam) == NULL) - l = lpole; - else - l = l->next; - - /* memory for the element array must be allocated first */ - for (m = l, i = 1; m != NULL; m = m->next) - i++; - sue->suelem = permalloc(sizeof(struct symtab *) * i); - - for (i = 0; l != NULL; l = l->next) { - sue->suelem[i++] = p = l->sym; - - if (p == NULL) - cerror("gummy structure member"); - if (temp == ENUMTY) { - if (p->soffset < low) - low = p->soffset; - if (p->soffset > high) - high = p->soffset; - p->ssue = sue; - continue; - } - sa = talign(p->stype, p->ssue); - if (p->sclass & FIELD) { - sz = p->sclass&FLDSIZ; - } else { - sz = tsize(p->stype, p->sdf, p->ssue); + /* + * extract size and alignment, recalculate offsets + * if struct should be packed. + */ + coff = 0; + sue->sylnk = r->rb; + for (sp = r->rb; sp; sp = sp->snext) { + sa = talign(sp->stype, sp->ssue); + if (sp->sclass & FIELD) + sz = sp->sclass&FLDSIZ; + else + sz = tsize(sp->stype, sp->sdf, sp->ssue); + if (suep->suepacked && r->rsou == STNAME) { + sp->soffset = coff; + coff += sz; + rpole->rstr = coff; } - if (sz > strucoff) - strucoff = sz; /* for use with unions */ + if (sz > rpole->rstr) + rpole->rstr = sz; /* for use with unions */ /* * set al, the alignment, to the lcm of the alignments * of the members. */ - SETOFF(al, sa); + if (suep->suepacked == 0) + SETOFF(al, sa); } - sue->suelem[i] = NULL; - SETOFF(strucoff, al); - if (temp == ENUMTY) { - TWORD ty; + /* If alignment given is larger that calculated, expand */ + if (suep->suealigned) + SETOFF(al, suep->suealigned); -#ifdef ENUMSIZE - ty = ENUMSIZE(high,low); -#else - if ((char)high == high && (char)low == low) - ty = ctype(CHAR); - else if ((short)high == high && (short)low == low) - ty = ctype(SHORT); - else - ty = ctype(INT); -#endif - strucoff = tsize(ty, 0, MKSUE(ty)); - sue->suealign = al = talign(ty, MKSUE(ty)); - } + SETOFF(rpole->rstr, al); - sue->suesize = strucoff; + sue->suesize = rpole->rstr; sue->suealign = al; + sue->suealigned = suep->suealigned; + sue->suepacked = suep->suepacked; + +#ifdef PCC_DEBUG + if (ddebug) { + printf("dclstruct(%s): size=%d, align=%d\n", + r->rsym ? r->rsym->sname : "??", + sue->suesize, sue->suealign); + } +#endif + + pragma_packed = pragma_aligned = 0; #ifdef STABS if (gflag) @@ -857,25 +896,77 @@ #ifdef PCC_DEBUG if (ddebug>1) { - int i; - - printf("\tsize %d align %d elem %p\n", - sue->suesize, sue->suealign, sue->suelem); - for (i = 0; sue->suelem[i] != NULL; ++i) { - printf("\tmember %s(%p)\n", - sue->suelem[i]->sname, sue->suelem[i]); + printf("\tsize %d align %d link %p\n", + sue->suesize, sue->suealign, sue->sylnk); + for (sp = sue->sylnk; sp != NULL; sp = sp->snext) { + printf("\tmember %s(%p)\n", sp->sname, sp); } } #endif - strucoff = r->rstrucoff; - if ((lparam = r->rlparam) != NULL) - lparam->next = NULL; - n = mkty(temp, 0, sue); + rpole = r->rnext; + n = mkty(r->rsou == STNAME ? STRTY : UNIONTY, 0, sue); return n; } /* + * Add a new member to the current struct or union being declared. + */ +void +soumemb(NODE *n, char *name, int class) +{ + struct symtab *sp, *lsp; + int incomp; + + if (rpole == NULL) + cerror("soumemb"); + + /* check if tag name exists */ + lsp = NULL; + for (sp = rpole->rb; sp != NULL; lsp = sp, sp = sp->snext) + if (*name != '*' && sp->sname == name) + uerror("redeclaration of %s", name); + + sp = getsymtab(name, SMOSNAME); + if (rpole->rb == NULL) + rpole->rb = sp; + else + lsp->snext = sp; + n->n_sp = sp; + if ((class & FIELD) == 0) + class = rpole->rsou == STNAME ? MOS : MOU; + defid(n, class); + + /* + * 6.7.2.1 clause 16: + * "...the last member of a structure with more than one + * named member may have incomplete array type;" + */ + if (ISARY(sp->stype) && sp->sdf->ddim == NOOFFSET) + incomp = 1; + else + incomp = 0; + if ((rpole->flags & LASTELM) || (rpole->rb == sp && incomp == 1)) + uerror("incomplete array in struct"); + if (incomp == 1) + rpole->flags |= LASTELM; + + /* + * 6.7.2.1 clause 2: + * "...such a structure shall not be a member of a structure + * or an element of an array." + */ + if (rpole->rsou == STNAME && sp->ssue->sylnk) { + struct symtab *lnk; + + for (lnk = sp->ssue->sylnk; lnk->snext; lnk = lnk->snext) + ; + if (ISARY(lnk->stype) && lnk->sdf->ddim == NOOFFSET) + uerror("incomplete struct in struct"); + } +} + +/* * error printing routine in parser */ void yyerror(char *s); @@ -900,74 +991,44 @@ ftnarg(NODE *p) { NODE *q; - struct symtab *s; #ifdef PCC_DEBUG if (ddebug > 2) printf("ftnarg(%p)\n", p); #endif /* - * Enter argument onto param stack. - * Do not declare parameters until later (in dclargs); - * the function must be declared first. - * put it on the param stack in reverse order, due to the - * nature of the stack it will be reclaimed correct. + * Push argument symtab entries onto param stack in reverse order, + * due to the nature of the stack it will be reclaimed correct. */ for (; p->n_op != NAME; p = p->n_left) { - if (p->n_op == (UCALL) && p->n_left->n_op == NAME) + if (p->n_op == UCALL && p->n_left->n_op == NAME) return; /* Nothing to enter */ if (p->n_op == CALL && p->n_left->n_op == NAME) break; } p = p->n_right; - blevel = 1; - while (p->n_op == CM) { q = p->n_right; if (q->n_op != ELLIPSIS) { - s = lookup((char *)q->n_sp, 0); - if (s->stype != UNDEF) { - if (s->slevel > 0) - uerror("parameter '%s' redefined", - s->sname); - s = hide(s); - } - s->soffset = NOOFFSET; - s->sclass = PARAM; - s->stype = q->n_type; - s->sdf = q->n_df; - s->ssue = q->n_sue; - ssave(s); + ssave(q->n_sp); nparams++; #ifdef PCC_DEBUG if (ddebug > 2) printf(" saving sym %s (%p) from (%p)\n", - s->sname, s, q); + q->n_sp->sname, q->n_sp, q); #endif } p = p->n_left; } - s = lookup((char *)p->n_sp, 0); - if (s->stype != UNDEF) { - if (s->slevel > 0) - uerror("parameter '%s' redefined", s->sname); - s = hide(s); - } - s->soffset = NOOFFSET; - s->sclass = PARAM; - s->stype = p->n_type; - s->sdf = p->n_df; - s->ssue = p->n_sue; - ssave(s); + ssave(p->n_sp); if (p->n_type != VOID) nparams++; - blevel = 0; #ifdef PCC_DEBUG if (ddebug > 2) printf(" saving sym %s (%p) from (%p)\n", - s->sname, s, p); + nparams ? p->n_sp->sname : "", p->n_sp, p); #endif } @@ -1001,35 +1062,9 @@ } } - switch( BTYPE(ty) ){ - - case UNIONTY: - case ENUMTY: - case STRTY: - return((unsigned int)sue->suealign); - case BOOL: - return (ALBOOL); - case CHAR: - case UCHAR: - return (ALCHAR); - case FLOAT: - return (ALFLOAT); - case LDOUBLE: - return (ALLDOUBLE); - case DOUBLE: - return (ALDOUBLE); - case LONGLONG: - case ULONGLONG: - return (ALLONGLONG); - case LONG: - case ULONG: - return (ALLONG); - case SHORT: - case USHORT: - return (ALSHORT); - default: - return (ALINT); - } + if (sue->suealign == 0) + uerror("no alignment"); + return sue->suealign; } /* compute the size associated with type ty, @@ -1052,6 +1087,8 @@ case PTR: return( SZPOINT(ty) * mult ); case ARY: + if (d->ddim == NOOFFSET) + return 0; mult *= d->ddim; d++; continue; @@ -1074,7 +1111,7 @@ return(SZINT); } } else { - if (sue->suelem == NULL) + if (sue->suealign == 0) uerror("unknown structure/union/enum"); } @@ -1082,146 +1119,59 @@ } /* - * Write last part of wide string. - * Do not bother to save wide strings. + * Save string (and print it out). If wide then wide string. */ NODE * -wstrend(char *str) +strend(int wide, char *str) { - struct symtab *sp = getsymtab(str, SSTRING|STEMP); - struct strsched *sc = tmpalloc(sizeof(struct strsched)); - NODE *p = block(NAME, NIL, NIL, WCHAR_TYPE+ARY, - tmpalloc(sizeof(union dimfun)), MKSUE(WCHAR_TYPE)); - int i; - char *c; - - sp->sclass = ILABEL; - sp->soffset = getlab(); - sp->stype = WCHAR_TYPE+ARY; - - sc = tmpalloc(sizeof(struct strsched)); - sc->locctr = STRNG; - sc->sym = sp; - sc->next = strpole; - strpole = sc; - - /* length calculation, used only for sizeof */ - for (i = 0, c = str; *c; ) { - if (*c++ == '\\') - (void)esccon(&c); - i++; - } - p->n_df->ddim = (i+1) * ((MKSUE(WCHAR_TYPE))->suesize/SZCHAR); - p->n_sp = sp; - return(p); -} - -/* - * Write last part of string. - */ -NODE * -strend(char *str) -{ -// extern int maystr; - struct symtab *s; + struct symtab *sp; NODE *p; - int i; - char *c; /* If an identical string is already emitted, just forget this one */ - str = addstring(str); /* enter string in string table */ - s = lookup(str, SSTRING); /* check for existance */ - - if (s->soffset == 0 /* && maystr == 0 */) { /* No string */ - struct strsched *sc; - s->sclass = ILABEL; - - /* - * Delay printout of this string until after the current - * function, or the end of the statement. - */ - sc = tmpalloc(sizeof(struct strsched)); - sc->locctr = STRNG; - sc->sym = s; - sc->next = strpole; - strpole = sc; - s->soffset = getlab(); + if (wide) { + /* Do not save wide strings, at least not now */ + sp = getsymtab(str, SSTRING|STEMP); + } else { + str = addstring(str); /* enter string in string table */ + sp = lookup(str, SSTRING); /* check for existance */ } - p = block(NAME, NIL, NIL, CHAR+ARY, - tmpalloc(sizeof(union dimfun)), MKSUE(CHAR)); -#ifdef CHAR_UNSIGNED - p->n_type = UCHAR+ARY; -#endif - /* length calculation, used only for sizeof */ - for (i = 0, c = str; *c; ) { - if (*c++ == '\\') - (void)esccon(&c); - i++; - } - p->n_df->ddim = i+1; - p->n_sp = s; - return(p); -} + if (sp->soffset == 0) { /* No string */ + char *wr; + int i; -/* - * Print out new strings, before temp memory is cleared. - */ -void -strprint() -{ - char *wr; - int i, val, isw; - NODE *p = bcon(0); - - while (strpole != NULL) { - setloc1(STRNG); - deflab1(strpole->sym->soffset); - isw = strpole->sym->stype == WCHAR_TYPE+ARY; - - i = 0; - wr = strpole->sym->sname; - while (*wr != 0) { - if (*wr++ == '\\') - val = esccon(&wr); - else - val = (unsigned char)wr[-1]; - if (isw) { - p->n_lval = val; - p->n_type = WCHAR_TYPE; - ninval(i*(WCHAR_TYPE/SZCHAR), - (MKSUE(WCHAR_TYPE))->suesize, p); - } else - bycode(val, i); - i++; - } - if (isw) { - p->n_lval = 0; - ninval(i*(WCHAR_TYPE/SZCHAR), - (MKSUE(WCHAR_TYPE))->suesize, p); + sp->sclass = STATIC; + sp->slevel = 1; + sp->soffset = getlab(); + sp->squal = (CON >> TSHIFT); + sp->sdf = permalloc(sizeof(union dimfun)); + if (wide) { + sp->stype = WCHAR_TYPE+ARY; + sp->ssue = MKSUE(WCHAR_TYPE); } else { - bycode(0, i++); - bycode(-1, i); + if (funsigned_char) { + sp->stype = UCHAR+ARY; + sp->ssue = MKSUE(UCHAR); + } else { + sp->stype = CHAR+ARY; + sp->ssue = MKSUE(CHAR); + } } - strpole = strpole->next; + for (wr = sp->sname, i = 1; *wr; i++) + if (*wr++ == '\\') + (void)esccon(&wr); + + sp->sdf->ddim = i; + if (wide) + inwstring(sp); + else + instring(sp); } - nfree(p); -} -#if 0 -/* - * simulate byte v appearing in a list of integer values - */ -void -putbyte(int v) -{ - NODE *p; - p = bcon(v); - incode( p, SZCHAR ); - tfree( p ); -// gotscal(); + p = block(NAME, NIL, NIL, sp->stype, sp->sdf, sp->ssue); + p->n_sp = sp; + return(clocal(p)); } -#endif /* * update the offset pointed to by poff; return the @@ -1253,14 +1203,13 @@ /* * Only generate tempnodes if we are optimizing, * and only for integers, floats or pointers, - * and not if the basic type is volatile. + * and not if the type on this level is volatile. */ -/* XXX OLDSTYLE */ if (xtemps && ((p->sclass == AUTO) || (p->sclass == REGISTER)) && (p->stype < STRTY || ISPTR(p->stype)) && - !ISVOL((p->squal << TSHIFT)) && cisreg(p->stype)) { + !(cqual(p->stype, p->squal) & VOL) && cisreg(p->stype)) { NODE *tn = tempnode(0, p->stype, p->sdf, p->ssue); - p->soffset = tn->n_lval; + p->soffset = regno(tn); p->sflags |= STNODE; nfree(tn); return 0; @@ -1279,7 +1228,7 @@ } else #endif if (p->sclass == PARAM && (p->stype == CHAR || p->stype == UCHAR || - p->stype == SHORT || p->stype == USHORT)) { + p->stype == SHORT || p->stype == USHORT || p->stype == BOOL)) { off = upoff(SZINT, ALINT, &noff); #ifndef RTOLBYTES off = noff - tsz; @@ -1301,7 +1250,24 @@ } /* - * Allocate space on the stack for dynamic arrays. + * Delay emission of code generated in argument headers. + */ +static void +edelay(NODE *p) +{ + if (blevel == 1) { + /* Delay until after declarations */ + if (parlink == NULL) + parlink = p; + else + parlink = block(COMOP, parlink, p, 0, 0, 0); + } else + ecomp(p); +} + +/* + * Allocate space on the stack for dynamic arrays (or at least keep track + * of the index). * Strategy is as follows: * - first entry is a pointer to the dynamic datatype. * - if it's a one-dimensional array this will be the only entry used. @@ -1316,41 +1282,68 @@ union dimfun *df; NODE *n, *nn, *tn, *pol; TWORD t; - int i, no; + int astkp, no; /* - * The pointer to the array is stored in a TEMP node, which number - * is in the soffset field; + * The pointer to the array is not necessarily stored in a + * TEMP node, but if it is, its number is in the soffset field; */ t = p->stype; - p->sflags |= (STNODE|SDYNARRAY); - p->stype = INCREF(p->stype); /* Make this an indirect pointer */ - tn = tempnode(0, p->stype, p->sdf, p->ssue); - p->soffset = tn->n_lval; + astkp = 0; + if (ISARY(t) && blevel == 1) { + /* must take care of side effects of dynamic arg arrays */ + if (p->sdf->ddim < 0 && p->sdf->ddim != NOOFFSET) { + /* first-level array will be indexed correct */ + edelay(arrstk[astkp++]); + } + p->sdf++; + p->stype += (PTR-ARY); + t = p->stype; + } + if (ISARY(t)) { + p->sflags |= (STNODE|SDYNARRAY); + p->stype = INCREF(p->stype); /* Make this an indirect pointer */ + tn = tempnode(0, p->stype, p->sdf, p->ssue); + p->soffset = regno(tn); + } else { + oalloc(p, poff); + tn = NIL; + } df = p->sdf; pol = NIL; - for (i = 0; ISARY(t); t = DECREF(t), df++) { - if (df->ddim >= 0) + for (; t > BTMASK; t = DECREF(t)) { + if (!ISARY(t)) continue; - n = arrstk[i++]; - nn = tempnode(0, INT, 0, MKSUE(INT)); - no = nn->n_lval; - ecomp(buildtree(ASSIGN, nn, n)); /* Save size */ + if (df->ddim < 0) { + n = arrstk[astkp++]; + do { + nn = tempnode(0, INT, 0, MKSUE(INT)); + no = regno(nn); + } while (no == -NOOFFSET); + edelay(buildtree(ASSIGN, nn, n)); - df->ddim = -no; - n = tempnode(no, INT, 0, MKSUE(INT)); - if (pol == NIL) - pol = n; - else - pol = buildtree(MUL, pol, n); + df->ddim = -no; + n = tempnode(no, INT, 0, MKSUE(INT)); + } else + n = bcon(df->ddim); + + pol = (pol == NIL ? n : buildtree(MUL, pol, n)); + df++; } /* Create stack gap */ - if (pol == NIL) - uerror("aggregate dynamic array not allowed"); - else - spalloc(tn, pol, tsize(t, 0, p->ssue)); + if (blevel == 1) { + if (tn) + tfree(tn); + if (pol) + tfree(pol); + } else { + if (pol == NIL) + uerror("aggregate dynamic array not allowed"); + if (tn) + spalloc(tn, pol, tsize(t, 0, p->ssue)); + } arrstkp = 0; } @@ -1368,14 +1361,6 @@ /* this must be fixed to use the current type in alignments */ switch( new<0?pty->n_type:p->stype ){ - case ENUMTY: { - struct suedef *sue; - sue = new < 0 ? pty->n_sue : p->ssue; - al = sue->suealign; - sz = sue->suesize; - break; - } - case CHAR: case UCHAR: al = ALCHAR; @@ -1409,24 +1394,24 @@ } if( w == 0 ){ /* align only */ - SETOFF( strucoff, al ); + SETOFF( rpole->rstr, al ); if( new >= 0 ) uerror( "zero size field"); return(0); } - if( strucoff%al + w > sz ) SETOFF( strucoff, al ); + if( rpole->rstr%al + w > sz ) SETOFF( rpole->rstr, al ); if( new < 0 ) { - strucoff += w; /* we know it will fit */ + rpole->rstr += w; /* we know it will fit */ return(0); } /* establish the field */ if( new == 1 ) { /* previous definition */ - if( p->soffset != strucoff || p->sclass != (FIELD|w) ) return(1); + if( p->soffset != rpole->rstr || p->sclass != (FIELD|w) ) return(1); } - p->soffset = strucoff; - strucoff += w; + p->soffset = rpole->rstr; + rpole->rstr += w; p->stype = type; fldty( p ); return(0); @@ -1448,7 +1433,7 @@ if (class == SNULL) { if (blevel > 1) class = AUTO; - else if (blevel != 0 || instruct) + else if (blevel != 0 || rpole) cerror( "nidcl error" ); else /* blevel = 0 */ commflag = 1, class = EXTERN; @@ -1458,7 +1443,7 @@ sp = p->n_sp; /* check if forward decl */ - if (ISARY(sp->stype) && sp->sdf->ddim == 0) + if (ISARY(sp->stype) && sp->sdf->ddim == NOOFFSET) return; if (sp->sflags & SASG) @@ -1479,7 +1464,7 @@ if (blevel == 0) lcommadd(p->n_sp); else - lcommdec(p->n_sp); + defzero(p->n_sp); break; } } @@ -1539,173 +1524,161 @@ struct lcd *lc; SLIST_FOREACH(lc, &lhead, next) { - if (lc->sp != NULL) { - if (lc->sp->sclass == STATIC) - lcommdec(lc->sp); - else - commdec(lc->sp); - } + if (lc->sp != NULL) + defzero(lc->sp); } } /* - * Merges a type tree into one type. Returns one type node with merged types - * and class stored in the su field. Frees all other nodes. - * XXX - classes in typedefs? + * Merge given types to a single node. + * Any type can end up here. + * p is the old node, q is the old (if any). + * CLASS is AUTO, EXTERN, REGISTER, STATIC or TYPEDEF. + * QUALIFIER is VOL or CON + * TYPE is CHAR, SHORT, INT, LONG, SIGNED, UNSIGNED, VOID, BOOL, FLOAT, + * DOUBLE, STRTY, UNIONTY. */ NODE * typenode(NODE *p) { - NODE *l, *sp = NULL; - int class = 0, adj, noun, sign; - TWORD qual = 0; - - adj = INT; /* INT, LONG or SHORT */ - noun = UNDEF; /* INT, CHAR or FLOAT */ - sign = 0; /* 0, SIGNED or UNSIGNED */ - - /* Remove initial QUALIFIERs */ - if (p && p->n_op == QUALIFIER) { - qual = p->n_type; - l = p->n_left; - nfree(p); - p = l; - } - - /* Handle initial classes special */ - if (p && p->n_op == CLASS) { - class = p->n_type; - l = p->n_left; - nfree(p); - p = l; - } - - /* Remove more QUALIFIERs */ - if (p && p->n_op == QUALIFIER) { - qual |= p->n_type; - l = p->n_left; - nfree(p); - p = l; - } - -ag: if (p && p->n_op == TYPE) { - if (p->n_left == NIL) { -#ifdef CHAR_UNSIGNED - if (p->n_type == CHAR) - p->n_type = UCHAR; -#endif - if (p->n_type == SIGNED) - p->n_type = INT; -uni: p->n_lval = class; - p->n_qual = qual >> TSHIFT; - return p; - } else if (p->n_left->n_op == QUALIFIER) { - qual |= p->n_left->n_type; - l = p->n_left; - p->n_left = l->n_left; - nfree(l); - goto ag; - } else if (ISSTR(p->n_type)) { - /* Save node; needed for return */ - sp = p; - p = p->n_left; - } - } - - while (p != NIL) { - if (p->n_op == QUALIFIER) { - qual |= p->n_type; - goto next; - } - if (p->n_op == CLASS) { - if (class != 0) - uerror("too many storage classes"); + NODE *q, *saved; + TWORD type; + int class, qual; + int sig, uns, cmplx; + + cmplx = type = class = qual = sig = uns = 0; + saved = NIL; + + for (q = p; p; p = p->n_left) { + switch (p->n_op) { + case CLASS: + if (class) + goto bad; /* max 1 class */ class = p->n_type; - goto next; - } - if (p->n_op != TYPE) - cerror("typenode got notype %d", p->n_op); - switch (p->n_type) { - case UCHAR: - case USHORT: /* may come from typedef */ - if (sign != 0 || adj != INT) - goto bad; - noun = p->n_type; break; - case SIGNED: - case UNSIGNED: - if (sign != 0) - goto bad; - sign = p->n_type; + + case QUALIFIER: + qual |= p->n_type >> TSHIFT; break; - case LONG: - if (adj == LONG) { - adj = LONGLONG; + + case TYPE: + if (p->n_sp != NULL || ISSOU(p->n_type)) { + /* typedef, enum or struct/union */ + if (saved || type) + goto bad; + saved = p; break; - } - /* FALLTHROUGH */ - case SHORT: - if (adj != INT) + } else if ((p->n_type == SIGNED && uns) || + (p->n_type == UNSIGNED && sig)) goto bad; - adj = p->n_type; - break; - case INT: - case CHAR: + + switch (p->n_type) { + case BOOL: + case CHAR: + case FLOAT: + case VOID: + if (type) + goto bad; + type = p->n_type; + break; + case DOUBLE: + if (type == 0) + type = DOUBLE; + else if (type == LONG) + type = LDOUBLE; + else + goto bad; + break; + case SHORT: + if (type == 0 || type == INT) + type = SHORT; + else + goto bad; + break; + case INT: + if (type == SHORT || type == LONG || + type == LONGLONG) + break; + else if (type == 0) + type = INT; + else + goto bad; + break; + case LONG: + if (type == 0) + type = LONG; + else if (type == INT) + break; + else if (type == LONG) + type = LONGLONG; + else if (type == DOUBLE) + type = LDOUBLE; + else + goto bad; + break; + case SIGNED: + if (sig || uns) + goto bad; + sig = 1; + break; + case UNSIGNED: + if (sig || uns) + goto bad; + uns = 1; + break; + case COMPLEX: + cmplx = 1; + break; + default: + cerror("typenode"); + } + } + } + if (cmplx) { + if (sig || uns) + goto bad; + switch (type) { case FLOAT: - case DOUBLE: - if (noun != UNDEF) - goto bad; - noun = p->n_type; + type = FCOMPLEX; break; - case VOID: - if (noun != UNDEF || adj != INT) - goto bad; - adj = noun = VOID; + case DOUBLE: + type = COMPLEX; break; - case STRTY: - case UNIONTY: + case LDOUBLE: + type = LCOMPLEX; break; default: goto bad; } - next: - l = p->n_left; - nfree(p); - p = l; } - if (sp) { - p = sp; - goto uni; + if (saved && type) + goto bad; + if (sig || uns) { + if (type == 0) + type = sig ? INT : UNSIGNED; + if (type > ULONGLONG) + goto bad; + if (uns) + type = ENUNSIGN(type); } -#ifdef CHAR_UNSIGNED - if (noun == CHAR && sign == 0) - sign = UNSIGNED; -#endif - if (noun == UNDEF) { - noun = INT; - } else if (noun == FLOAT) { - if (sign != 0 || adj == SHORT) - goto bad; - noun = (adj == LONG ? DOUBLE : FLOAT); - } else if (noun == DOUBLE) { - if (sign != 0 || adj == SHORT) - goto bad; - noun = (adj == LONG ? LDOUBLE : DOUBLE); - } else if (noun == CHAR && adj != INT) - goto bad; + if (funsigned_char && type == CHAR && sig == 0) + type = UCHAR; + + /* free the chain */ + while (q) { + p = q->n_left; + if (q != saved) + nfree(q); + q = p; + } - if (adj != INT && (noun != DOUBLE && noun != LDOUBLE)) - noun = adj; - if (sign == UNSIGNED) - noun += (UNSIGNED-INT); - - p = block(TYPE, NIL, NIL, noun, 0, 0); - p->n_qual = qual >> TSHIFT; - if (strunem != 0) - class = strunem; + p = (saved ? saved : block(TYPE, NIL, NIL, type, 0, 0)); + p->n_qual = qual; p->n_lval = class; + if (BTYPE(p->n_type) == UNDEF) + MODTYPE(p->n_type, INT); return p; bad: uerror("illegal type combination"); @@ -1729,13 +1702,18 @@ (*ntdim)++; } -/* merge type typ with identifier idp */ +/* + * merge type typ with identifier idp. + * idp is returned as a NAME node with correct types. + * typ is untouched. + */ NODE * tymerge(NODE *typ, NODE *idp) { NODE *p; union dimfun *j; struct tylnk *base, tylnk, *tylkp; + struct suedef *sue; unsigned int t; int ntdim, i; @@ -1750,8 +1728,10 @@ } #endif + sue = idp->n_sue; + idp->n_type = typ->n_type; - idp->n_qual = (typ->n_qual << TSHIFT) | idp->n_qual; /* XXX ??? */ + idp->n_qual |= typ->n_qual; tylkp = &tylnk; tylkp->next = NULL; @@ -1776,12 +1756,29 @@ /* now idp is a single node: fix up type */ idp->n_type = ctype(idp->n_type); - idp->n_qual = DECQAL(idp->n_qual); /* in case ctype has rewritten things */ if ((t = BTYPE(idp->n_type)) != STRTY && t != UNIONTY && t != ENUMTY) idp->n_sue = MKSUE(t); +#if 1 + if (sue) { + struct suedef *s = permalloc(sizeof(struct suedef)); + *s = *idp->n_sue; + idp->n_sue = s; + if (sue->suealigned > s->suealign) + s->suealign = sue->suealigned; + s->suepacked = sue->suepacked; + s->suesection = sue->suesection; + } +#else + if (sue) { + if (sue->suealigned > idp->n_sue->suealign) + idp->n_sue->suealign = sue->suealigned; + idp->n_sue->suepacked = sue->suepacked; + } +#endif + if (idp->n_op != NAME) { for (p = idp->n_left; p->n_op != NAME; p = p->n_left) nfree(p); @@ -1818,8 +1815,7 @@ if (w->n_right->n_op == ELLIPSIS) continue; ty = w->n_right->n_type; - if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY || - BTYPE(ty) == ENUMTY) + if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY) num++; while (ISFTN(ty) == 0 && ISARY(ty) == 0 && ty > BTMASK) ty = DECREF(ty); @@ -1828,8 +1824,7 @@ } cnt++; ty = w->n_type; - if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY || - BTYPE(ty) == ENUMTY) + if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY) num++; while (ISFTN(ty) == 0 && ISARY(ty) == 0 && ty > BTMASK) ty = DECREF(ty); @@ -1863,8 +1858,7 @@ ap[j]->n_type = INCREF(ap[j]->n_type); ty = ap[j]->n_type; al[k++].type = ty; - if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY || - BTYPE(ty) == ENUMTY) + if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY) al[k++].sue = ap[j]->n_sue; while (ISFTN(ty) == 0 && ISARY(ty) == 0 && ty > BTMASK) ty = DECREF(ty); @@ -1875,8 +1869,10 @@ if (k > num) cerror("arglist: k%d > num%d", k, num); tfree(n); +#ifdef PCC_DEBUG if (pdebug) alprint(al, 0); +#endif return al; } @@ -1894,8 +1890,10 @@ TWORD t, q; o = p->n_op; - if (o == NAME) + if (o == NAME) { + p->n_qual = DECQAL(p->n_qual); return; + } t = INCREF(p->n_type); q = p->n_qual; @@ -1918,7 +1916,7 @@ nfree(p->n_right); #ifdef notdef /* XXX - check dimensions at usage time */ - if (dim.ddim == 0 && p->n_left->n_op == LB) + if (dim.ddim == NOOFFSET && p->n_left->n_op == LB) uerror("null dimension"); #endif } @@ -1975,25 +1973,153 @@ if (xnobuiltins) return NULL; #endif - - if (f->n_op != NAME) - return NULL; /* not direct call */ sp = f->n_sp; - /* XXX - strcmp is bad, use pointer comparision, redo someday */ - if (strcmp(sp->sname, "__builtin_alloca")) /* use GCC name */ - return NULL; /* not alloca */ - if (a == NULL || a->n_op == CM) { uerror("wrong arg count for alloca"); - return NULL; + return bcon(0); } t = tempnode(0, VOID|PTR, 0, MKSUE(INT) /* XXX */); - u = tempnode(t->n_lval, VOID|PTR, 0, MKSUE(INT) /* XXX */); + u = tempnode(regno(t), VOID|PTR, 0, MKSUE(INT) /* XXX */); spalloc(t, a, SZCHAR); tfree(f); return u; } + +/* + * Determine if a value is known to be constant at compile-time and + * hence that PCC can perform constant-folding on expressions involving + * that value. + */ +static NODE * +builtin_constant_p(NODE *f, NODE *a) +{ + int isconst = (a != NULL && a->n_op == ICON); + + tfree(f); + tfree(a); + + return bcon(isconst); +} + +#ifndef TARGET_STDARGS +static NODE * +builtin_stdarg_start(NODE *f, NODE *a) +{ + NODE *p, *q; + int sz; + + /* check num args and type */ + if (a == NULL || a->n_op != CM || a->n_left->n_op == CM || + !ISPTR(a->n_left->n_type)) + goto bad; + + /* must first deal with argument size; use int size */ + p = a->n_right; + if (p->n_type < INT) { + sz = SZINT/tsize(p->n_type, p->n_df, p->n_sue); + } else + sz = 1; + + /* do the real job */ + p = buildtree(ADDROF, p, NIL); /* address of last arg */ +#ifdef BACKAUTO + p = optim(buildtree(PLUS, p, bcon(sz))); /* add one to it (next arg) */ +#else + p = optim(buildtree(MINUS, p, bcon(sz))); /* add one to it (next arg) */ +#endif + q = block(NAME, NIL, NIL, PTR+VOID, 0, 0); /* create cast node */ + q = buildtree(CAST, q, p); /* cast to void * (for assignment) */ + p = q->n_right; + nfree(q->n_left); + nfree(q); + p = buildtree(ASSIGN, a->n_left, p); /* assign to ap */ + tfree(f); + nfree(a); + return p; +bad: + uerror("bad argument to __builtin_stdarg_start"); + return bcon(0); +} + +static NODE * +builtin_va_arg(NODE *f, NODE *a) +{ + NODE *p, *q, *r, *rv; + int sz, nodnum; + + /* check num args and type */ + if (a == NULL || a->n_op != CM || a->n_left->n_op == CM || + !ISPTR(a->n_left->n_type) || a->n_right->n_op != TYPE) + goto bad; + + /* create a copy to a temp node of current ap */ + p = tcopy(a->n_left); + q = tempnode(0, p->n_type, p->n_df, p->n_sue); + nodnum = regno(q); + rv = buildtree(ASSIGN, q, p); + + r = a->n_right; + sz = tsize(r->n_type, r->n_df, r->n_sue)/SZCHAR; + /* add one to ap */ +#ifdef BACKAUTO + rv = buildtree(COMOP, rv , buildtree(PLUSEQ, a->n_left, bcon(sz))); +#else +#error fix wrong eval order in builtin_va_arg + ecomp(buildtree(MINUSEQ, a->n_left, bcon(sz))); +#endif + + nfree(a->n_right); + nfree(a); + nfree(f); + r = tempnode(nodnum, INCREF(r->n_type), r->n_df, r->n_sue); + return buildtree(COMOP, rv, buildtree(UMUL, r, NIL)); +bad: + uerror("bad argument to __builtin_va_arg"); + return bcon(0); + +} + +static NODE * +builtin_va_end(NODE *f, NODE *a) +{ + tfree(f); + tfree(a); + return bcon(0); /* nothing */ +} + +static NODE * +builtin_va_copy(NODE *f, NODE *a) +{ + if (a == NULL || a->n_op != CM || a->n_left->n_op == CM) + goto bad; + tfree(f); + f = buildtree(ASSIGN, a->n_left, a->n_right); + nfree(a); + return f; + +bad: + uerror("bad argument to __builtin_va_copy"); + return bcon(0); +} +#endif /* TARGET_STDARGS */ + +static struct bitable { + char *name; + NODE *(*fun)(NODE *f, NODE *a); +} bitable[] = { + { "__builtin_alloca", builtin_alloca }, + { "__builtin_constant_p", builtin_constant_p }, +#ifndef TARGET_STDARGS + { "__builtin_stdarg_start", builtin_stdarg_start }, + { "__builtin_va_arg", builtin_va_arg }, + { "__builtin_va_end", builtin_va_end }, + { "__builtin_va_copy", builtin_va_copy }, +#endif +#ifdef TARGET_BUILTINS + TARGET_BUILTINS +#endif +}; #endif #ifdef PCC_DEBUG @@ -2010,16 +2136,18 @@ printf(" "); printf("arg %d: ", i++); tprint(stdout, al->type, 0); - if (BTYPE(al->type) == STRTY || - BTYPE(al->type) == UNIONTY || BTYPE(al->type) == ENUMTY) { + if (ISARY(al->type)) { + printf(" dim %d\n", al->df->ddim); + } else if (BTYPE(al->type) == STRTY || + BTYPE(al->type) == UNIONTY) { al++; - printf("dim %d\n", al->df->ddim); - } - printf("\n"); - if (ISFTN(DECREF(al->type))) { + printf(" (size %d align %d)", al->sue->suesize, + al->sue->suealign); + } else if (ISFTN(DECREF(al->type))) { al++; alprint(al->df->dfun, in+1); } + printf("\n"); } if (in == 0) printf("end arglist\n"); @@ -2031,7 +2159,7 @@ * Returns a merged node (via buildtree() of function and arguments. */ NODE * -doacall(NODE *f, NODE *a) +doacall(struct symtab *sp, NODE *f, NODE *a) { NODE *w, *r; union arglist *al; @@ -2054,7 +2182,7 @@ /* First let MD code do something */ calldec(f, a); /* XXX XXX hack */ - if ((f->n_op == CALL || f->n_op == CALL) && + if ((f->n_op == CALL) && f->n_left->n_op == ADDROF && f->n_left->n_left->n_op == NAME && (f->n_left->n_left->n_type & 0x7e0) == 0x4c0) @@ -2062,30 +2190,54 @@ /* XXX XXX hack */ #ifndef NO_C_BUILTINS - /* check for alloca */ - if ((w = builtin_alloca(f, a))) - return w; + /* check for builtins. function pointers are not allowed */ + if (f->n_op == NAME && + f->n_sp->sname[0] == '_' && f->n_sp->sname[1] == '_') { + int i; + + for (i = 0; i < (int)(sizeof(bitable)/sizeof(bitable[0])); i++) { + if (strcmp(bitable[i].name, f->n_sp->sname) == 0) + return (*bitable[i].fun)(f, a); + } + } #endif + + /* Check for undefined or late defined enums */ + if (BTYPE(f->n_type) == ENUMTY) { + /* not-yet check if declared enum */ + if (f->n_sue->sylnk->stype != ENUMTY) + MODTYPE(f->n_type, f->n_sue->sylnk->stype); + if (BTYPE(f->n_type) == ENUMTY) + uerror("enum %s not declared", f->n_sue->sylnk->sname); + } + /* * Do some basic checks. */ if (f->n_df == NULL || (al = f->n_df[0].dfun) == NULL) { if (Wimplicit_function_declaration) { - if (f->n_sp != NULL) - werror("no prototype for function '%s()'", - f->n_sp->sname); - else + if (f->n_sp != NULL) { + if (strncmp(f->n_sp->sname, + "__builtin", 9) != 0) + werror("no prototype for function " + "'%s()'", f->n_sp->sname); + } else { werror("no prototype for function pointer"); + } } /* floats must be cast to double */ if (a == NULL) goto build; for (w = a; w->n_op == CM; w = w->n_left) { + if (w->n_right->n_op == TYPE) + uerror("type is not an argument"); if (w->n_right->n_type != FLOAT) continue; w->n_right = argcast(w->n_right, DOUBLE, NULL, MKSUE(DOUBLE)); } + if (a->n_op == TYPE) + uerror("type is not an argument"); if (a->n_type == FLOAT) { MKTY(a, DOUBLE, 0, 0); } @@ -2103,7 +2255,7 @@ } #ifdef PCC_DEBUG if (pdebug) { - printf("arglist for %p\n", + printf("arglist for %s\n", f->n_sp != NULL ? f->n_sp->sname : "function pointer"); alprint(al, 0); } @@ -2149,8 +2301,19 @@ if ((hasarray = ISARY(arrt))) arrt += (PTR-ARY); #endif - if (ISARY(type)) - type += (PTR-ARY); + /* Taking addresses of arrays are meaningless in expressions */ + /* but people tend to do that and also use in prototypes */ + /* this is mostly a problem with typedefs */ + if (ISARY(type)) { + if (ISPTR(arrt) && ISARY(DECREF(arrt))) + type = INCREF(type); + else + type += (PTR-ARY); + } else if (ISPTR(type) && !ISARY(DECREF(type)) && + ISPTR(arrt) && ISARY(DECREF(arrt))) { + type += (ARY-PTR); + type = INCREF(type); + } /* Check structs */ if (type <= BTMASK && arrt <= BTMASK) { @@ -2162,12 +2325,17 @@ MKTY(apole->node, arrt, 0, 0) } } else if (ISSOU(BTYPE(type))) { - if (apole->node->n_sue != al[1].sue) + if (apole->node->n_sue->sylnk != al[1].sue->sylnk) goto incomp; } goto out; } + /* XXX should (recusively) check return type and arg list of + func ptr arg XXX */ + if (ISFTN(DECREF(arrt)) && ISFTN(type)) + type = INCREF(type); + /* Hereafter its only pointers (or arrays) left */ /* Check for struct/union intermixing with other types */ if (((type <= BTMASK) && ISSOU(BTYPE(type))) || @@ -2177,14 +2345,11 @@ /* Check for struct/union compatibility */ if (type == arrt) { if (ISSOU(BTYPE(type))) { - if (apole->node->n_sue == al[1].sue) + if (apole->node->n_sue->sylnk == al[1].sue->sylnk) goto out; } else goto out; } - if (BTYPE(arrt) == ENUMTY && BTYPE(type) == INT && - (arrt & ~BTMASK) == (type & ~BTMASK)) - goto skip; /* XXX enumty destroyed in optim() */ if (BTYPE(arrt) == VOID && type > BTMASK) goto skip; /* void *f = some pointer */ if (arrt > BTMASK && BTYPE(type) == VOID) @@ -2193,9 +2358,9 @@ goto skip; /* Anything assigned a zero */ if ((type & ~BTMASK) == (arrt & ~BTMASK)) { - /* do not complain for intermixed char/uchar */ - if ((BTYPE(type) == CHAR || BTYPE(type) == UCHAR) && - (BTYPE(arrt) == CHAR || BTYPE(arrt) == UCHAR)) + /* do not complain for pointers with signedness */ + if (!Wpointer_sign && + DEUNSIGN(BTYPE(type)) == DEUNSIGN(BTYPE(arrt))) goto skip; } @@ -2231,7 +2396,9 @@ if (apole != NULL) uerror("too many arguments to function"); -build: return buildtree(a == NIL ? UCALL : CALL, f, a); +build: if (sp != NULL && (sp->sflags & SINLINE) && (w = inlinetree(sp, f, a))) + return w; + return buildtree(a == NIL ? UCALL : CALL, f, a); } static int @@ -2241,9 +2408,9 @@ switch (type & TMASK) { case ARY: /* may be declared without dimension */ - if (dsym->ddim == 0) + if (dsym->ddim == NOOFFSET) dsym->ddim = ddef->ddim; - if (ddef->ddim && dsym->ddim != ddef->ddim) + if (ddef->ddim != NOOFFSET && dsym->ddim != ddef->ddim) return 1; dsym++, ddef++; break; @@ -2303,7 +2470,7 @@ t2 = usym->type; if (ISSTR(ty)) { usym++, udef++; - if (usym->sue != udef->sue) + if (usym->sue->sylnk != udef->sue->sylnk) return 1; } @@ -2345,7 +2512,7 @@ } /* detect function arguments, watching out for structure declarations */ - if (instruct && ISFTN(type)) { + if (rpole && ISFTN(type)) { uerror("function illegal in structure or union"); type = INCREF(type); } @@ -2371,12 +2538,14 @@ int fixclass(int class, TWORD type) { + extern int fun_inline; + /* first, fix null class */ if (class == SNULL) { - if (instruct&INSTRUCT) - class = MOS; - else if (instruct&INUNION) - class = MOU; + if (fun_inline && ISFTN(type)) + return SNULL; + if (rpole) + class = rpole->rsou == STNAME ? MOS : MOU; else if (blevel == 0) class = EXTDEF; else @@ -2402,28 +2571,23 @@ } } - if( class&FIELD ){ - if( !(instruct&INSTRUCT) ) uerror( "illegal use of field" ); - return( class ); - } - - switch( class ){ + if (class & FIELD) { + if (rpole && rpole->rsou != STNAME && rpole->rsou != UNAME) + uerror("illegal use of field"); + return(class); + } - case MOU: - if( !(instruct&INUNION) ) uerror( "illegal MOU class" ); - return( class ); + switch (class) { case MOS: - if( !(instruct&INSTRUCT) ) uerror( "illegal MOS class" ); - return( class ); - - case MOE: - if( instruct & (INSTRUCT|INUNION) ) uerror( "illegal MOE class" ); - return( class ); + case MOU: + if (rpole == NULL) + uerror("illegal member class"); + return(class); case REGISTER: if (blevel == 0) - uerror( "illegal register declaration" ); + uerror("illegal register declaration"); if (blevel == 1) return(PARAM); else @@ -2445,14 +2609,12 @@ uerror( "fortran function has wrong type" ); } } - case STNAME: - case UNAME: - case ENAME: case EXTERN: case STATIC: case EXTDEF: case TYPEDEF: case USTATIC: + case PARAM: return( class ); default: @@ -2504,7 +2666,7 @@ s = permalloc(sizeof(struct symtab)); symtabcnt++; } - s->sname = name; + s->sname = s->soname = name; s->snext = NULL; s->stype = UNDEF; s->squal = 0; @@ -2512,9 +2674,23 @@ s->sflags = flags & SMASK; s->soffset = 0; s->slevel = blevel; + s->sdf = NULL; + s->ssue = NULL; return s; } +int +fldchk(int sz) +{ + if (rpole->rsou != STNAME && rpole->rsou != UNAME) + uerror("field outside of structure"); + if (sz < 0 || sz >= FIELD) { + uerror("illegal field size"); + return 1; + } + return 0; +} + #ifdef PCC_DEBUG static char * ccnames[] = { /* names of storage classes */ @@ -2551,3 +2727,108 @@ return( ccnames[c] ); } #endif + +void +sspinit() +{ + NODE *p; + + p = block(NAME, NIL, NIL, FTN+VOID, 0, MKSUE(VOID)); + p->n_sp = lookup("__stack_chk_fail", SNORMAL); + defid(p, EXTERN); + nfree(p); + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_guard", SNORMAL); + defid(p, EXTERN); + nfree(p); +} + +void +sspstart() +{ + NODE *p, *q; + + q = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + q->n_sp = lookup("__stack_chk_guard", SNORMAL); + q = clocal(q); + + p = block(REG, NIL, NIL, INT, 0, 0); + p->n_lval = 0; + p->n_rval = FPREG; + q = block(ER, p, q, INT, 0, MKSUE(INT)); + q = clocal(q); + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_canary", SNORMAL); + defid(p, AUTO); + p = clocal(p); + + ecomp(buildtree(ASSIGN, p, q)); +} + +void +sspend() +{ + NODE *p, *q; + TWORD t; + int tmpnr = 0; + int lab; + + if (retlab != NOLAB) { + plabel(retlab); + retlab = getlab(); + } + + t = DECREF(cftnsp->stype); + if (t == BOOL) + t = BOOL_TYPE; + + if (t != VOID && !ISSOU(t)) { + p = tempnode(0, t, cftnsp->sdf, cftnsp->ssue); + tmpnr = regno(p); + q = block(REG, NIL, NIL, t, cftnsp->sdf, cftnsp->ssue); + q->n_rval = RETREG(t); + ecomp(buildtree(ASSIGN, p, q)); + } + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_canary", SNORMAL); + p = clocal(p); + + q = block(REG, NIL, NIL, INT, 0, 0); + q->n_lval = 0; + q->n_rval = FPREG; + q = block(ER, p, q, INT, 0, MKSUE(INT)); + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_guard", SNORMAL); + p = clocal(p); + + lab = getlab(); + cbranch(buildtree(EQ, p, q), bcon(lab)); + + p = block(NAME, NIL, NIL, FTN+VOID, 0, MKSUE(VOID)); + p->n_sp = lookup("__stack_chk_fail", SNORMAL); + p = clocal(p); + + ecomp(buildtree(UCALL, p, NIL)); + + plabel(lab); + + if (t != VOID && !ISSOU(t)) { + p = tempnode(tmpnr, t, cftnsp->sdf, cftnsp->ssue); + q = block(REG, NIL, NIL, t, cftnsp->sdf, cftnsp->ssue); + q->n_rval = RETREG(t); + ecomp(buildtree(ASSIGN, q, p)); + } +} + +/* + * Allocate on the permanent heap for inlines, otherwise temporary heap. + */ +void * +inlalloc(int size) +{ + return isinlining ? permalloc(size) : tmpalloc(size); +} Index: init.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/init.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/init.c -L usr.bin/pcc/ccom/init.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/init.c +++ usr.bin/pcc/ccom/init.c @@ -1,4 +1,4 @@ -/* $Id: init.c,v 1.30 2007/09/24 20:34:03 ragge Exp $ */ +/* $Id: init.c,v 1.47 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2004, 2007 Anders Magnusson (ragge at ludd.ltu.se). @@ -65,13 +65,13 @@ #include /* - * Four machine-dependent routines may be called during initialization: + * The following machine-dependent routines may be called during + * initialization: * - * instring(char *str) - Print out a string. * zbits(OFFSZ, int) - sets int bits of zero at position OFFSZ. * infld(CONSZ off, int fsz, CONSZ val) * - sets the bitfield val starting at off and size fsz. - * inval(CONSZ off, int fsz, NODE *) + * ninval(CONSZ off, int fsz, NODE *) * - prints an integer constant which may have * a label associated with it, located at off and * size fsz. @@ -118,8 +118,8 @@ */ static struct instk { struct instk *in_prev; /* linked list */ - struct symtab **in_xp; /* member in structure initializations */ - struct symtab *in_sym; /* stab index */ + struct symtab *in_lnk; /* member in structure initializations */ + struct symtab *in_sym; /* symtab index */ union dimfun *in_df; /* dimenston of array */ TWORD in_t; /* type for this level */ int in_n; /* number of arrays seen so far */ @@ -148,11 +148,20 @@ SLIST_ENTRY(llist) next; CONSZ begsz; /* bit offset of this entry */ struct ilist *il; -} *curll; -static SLIST_HEAD(, llist) lpole; +}; +static SLIST_HEAD(llh, llist) lpole; static CONSZ basesz; static int numents; /* # of array entries allocated */ +static struct initctx { + struct initctx *prev; + struct instk *pstk; + struct symtab *psym; + struct llh lpole; + CONSZ basesz; + int numents; +} *inilnk; + static struct ilist * getil(struct ilist *next, CONSZ b, int sz, NODE *n) { @@ -185,16 +194,19 @@ /* * Return structure containing off bitnumber. * Allocate more entries, if needed. - * This is not bright implemented. */ static struct llist * setll(OFFSZ off) { - struct llist *ll; + struct llist *ll = NULL; /* Ensure that we have enough entries */ while (off >= basesz * numents) - (void)getll(); + ll = getll(); + + if (ll != NULL && ll->begsz <= off && ll->begsz + basesz > off) + return ll; + SLIST_FOREACH(ll, &lpole, next) if (ll->begsz <= off && ll->begsz + basesz > off) break; @@ -209,14 +221,30 @@ void beginit(struct symtab *sp) { + struct initctx *ict; struct instk *is = &pbase; - struct llist *ll; #ifdef PCC_DEBUG if (idebug) printf("beginit(), sclass %s\n", scnames(sp->sclass)); #endif + if (pstk) { +#ifdef PCC_DEBUG + if (idebug) + printf("beginit: saving ctx pstk %p\n", pstk); +#endif + /* save old context */ + ict = tmpalloc(sizeof(struct initctx)); + ict->prev = inilnk; + inilnk = ict; + ict->pstk = pstk; + ict->psym = csym; + ict->lpole = lpole; + ict->basesz = basesz; + ict->numents = numents; + is = tmpalloc(sizeof(struct instk)); + } csym = sp; numents = 0; /* no entries in array list */ @@ -225,10 +253,9 @@ else basesz = tsize(DECREF(sp->stype), sp->sdf, sp->ssue); SLIST_INIT(&lpole); - curll = ll = getll(); /* at least first entry in list */ /* first element */ - is->in_xp = ISSOU(sp->stype) ? sp->ssue->suelem : NULL; + is->in_lnk = ISSOU(sp->stype) ? sp->ssue->sylnk : NULL; is->in_n = 0; is->in_t = sp->stype; is->in_sym = sp; @@ -276,25 +303,26 @@ is->in_n = 0; if (pstk == NULL) { /* stack empty */ - is->in_xp = ISSOU(sp->stype) ? sp->ssue->suelem : NULL; + is->in_lnk = ISSOU(sp->stype) ? sp->ssue->sylnk : NULL; is->in_t = sp->stype; is->in_sym = sp; is->in_df = sp->sdf; } else if (ISSOU(t)) { - sq = *pstk->in_xp; + sq = pstk->in_lnk; if (sq == NULL) { uerror("excess of initializing elements"); } else { - is->in_xp = ISSOU(sq->stype) ? sq->ssue->suelem : 0; + is->in_lnk = ISSOU(sq->stype) ? sq->ssue->sylnk : 0; is->in_t = sq->stype; is->in_sym = sq; is->in_df = sq->sdf; } } else if (ISARY(t)) { - is->in_xp = ISSOU(DECREF(t)) ? pstk->in_sym->ssue->suelem : 0; + is->in_lnk = ISSOU(DECREF(t)) ? pstk->in_sym->ssue->sylnk : 0; is->in_t = DECREF(t); is->in_sym = sp; - if (pstk->in_df->ddim && pstk->in_n >= pstk->in_df->ddim) { + if (pstk->in_df->ddim != NOOFFSET && + pstk->in_n >= pstk->in_df->ddim) { werror("excess of initializing elements"); pstk->in_n--; } @@ -326,9 +354,9 @@ printf("stkpop\n"); #endif for (; pstk; pstk = pstk->in_prev) { - if (pstk->in_t == STRTY) { - pstk->in_xp++; - if (*pstk->in_xp != NULL) + if (pstk->in_t == STRTY && pstk->in_lnk != NULL) { + pstk->in_lnk = pstk->in_lnk->snext; + if (pstk->in_lnk != NULL) break; } if (ISSOU(pstk->in_t) && pstk->in_fl) @@ -337,7 +365,7 @@ pstk->in_n++; if (pstk->in_fl) break; - if (pstk->in_df->ddim == 0 || + if (pstk->in_df->ddim == NOOFFSET || pstk->in_n < pstk->in_df->ddim) break; /* ger more elements */ } @@ -398,10 +426,12 @@ } } } +#ifdef PCC_DEBUG if (idebug>1) { printf("findoff: off %lld\n", off); prtstk(pstk); } +#endif return off; } @@ -445,24 +475,6 @@ } /* - * Align data and set correct location. - */ -static void -setscl(struct symtab *sp) -{ - setloc1((sp->squal << TSHIFT) & CON ? RDATA : DATA); - defalign(talign(sp->stype, sp->ssue)); - if (sp->sclass == EXTDEF || - (sp->sclass == STATIC && sp->slevel == 0)) { - defnam(sp); - } else { - if (sp->soffset == NOOFFSET) - cerror("setscl"); - deflab1(sp->soffset); - } -} - -/* * take care of generating a value for the initializer p * inoff has the current offset (last bit written) * in the current word being generated @@ -487,9 +499,11 @@ p = optim(p); +#ifdef notdef /* leave to the target to decide if useable */ if (csym->sclass != AUTO && p->n_op != ICON && p->n_op != FCON && p->n_op != NAME) cerror("scalinit not leaf"); +#endif /* Out of elements? */ if (pstk == NULL) { @@ -552,17 +566,14 @@ else typ = INT; /* Fake a struct reference */ - spname = csym; - p = buildtree(ADDROF, - buildtree(NAME, NIL, NIL), NIL); - r = block(ICON, NIL, NIL, typ, 0, MKSUE(typ)); + p = buildtree(ADDROF, nametree(csym), NIL); sym.stype = typ; sym.squal = 0; sym.sdf = 0; sym.ssue = MKSUE(typ); sym.soffset = off; sym.sclass = typ == INT ? FIELD | fsz : MOU; - r->n_sp = &sym; + r = xbcon(0, &sym, typ); p = block(STREF, p, r, INT, 0, MKSUE(INT)); ecode(buildtree(ASSIGN, stref(p), bcon(val))); } @@ -609,10 +620,10 @@ #endif if (csym->sclass != AUTO) - setscl(csym); + defloc(csym); /* Calculate total block size */ - if (ISARY(csym->stype) && csym->sdf->ddim == 0) { + if (ISARY(csym->stype) && csym->sdf->ddim == NOOFFSET) { tbit = numents*basesz; /* open-ended arrays */ csym->sdf->ddim = numents; if (csym->sclass == AUTO) { /* Get stack space */ @@ -644,20 +655,17 @@ (ll->begsz + il->off) - lastoff); /* Fake a struct reference */ - spname = csym; - p = buildtree(ADDROF, - buildtree(NAME, NIL, NIL), NIL); + p = buildtree(ADDROF, nametree(csym), NIL); n = il->n; - r = block(ICON, NIL, NIL, INT, 0, MKSUE(INT)); sym.stype = n->n_type; sym.squal = n->n_qual; sym.sdf = n->n_df; sym.ssue = n->n_sue; sym.soffset = ll->begsz + il->off; sym.sclass = fsz < 0 ? FIELD | -fsz : 0; - r->n_sp = &sym; + r = xbcon(0, &sym, INT); p = block(STREF, p, r, INT, 0, MKSUE(INT)); - ecode(buildtree(ASSIGN, stref(p), il->n)); + ecomp(buildtree(ASSIGN, stref(p), il->n)); if (fsz < 0) fsz = -fsz; @@ -670,7 +678,7 @@ infld(il->off, fsz, il->n->n_lval); } else ninval(il->off, fsz, il->n); - nfree(il->n); + tfree(il->n); } lastoff = ll->begsz + il->off + fsz; } @@ -679,6 +687,19 @@ clearbf(lastoff, tbit-lastoff); } else zbits(lastoff, tbit-lastoff); + if (inilnk) { + struct initctx *ict = inilnk; + pstk = ict->pstk; + csym = ict->psym; + lpole = ict->lpole; + basesz = ict->basesz; + numents = ict->numents; + inilnk = inilnk->prev; +#ifdef PCC_DEBUG + if (idebug) + printf("endinit: restoring ctx pstk %p\n", pstk); +#endif + } } /* @@ -731,8 +752,9 @@ if (ISARY(pstk->in_t)) pstk->in_n = pstk->in_df->ddim; else if (pstk->in_t == STRTY) { - while (pstk->in_xp[1] != NULL) - pstk->in_xp++; + while (pstk->in_lnk != NULL && + pstk->in_lnk->snext != NULL) + pstk->in_lnk = pstk->in_lnk->snext; } stkpop(); return; @@ -766,11 +788,11 @@ break; case NAME: - if (pstk->in_xp) { - for (; pstk->in_xp[0]; pstk->in_xp++) - if (pstk->in_xp[0]->sname == (char *)p->n_sp) + if (pstk->in_lnk) { + for (; pstk->in_lnk; pstk->in_lnk = pstk->in_lnk->snext) + if (pstk->in_lnk->sname == (char *)p->n_sp) break; - if (pstk->in_xp[0] == NULL) + if (pstk->in_lnk == NULL) uerror("member missing"); } else { uerror("not a struct/union"); @@ -798,12 +820,12 @@ pstk = pstk->in_prev; /* Empty stack */ if (ISSOU(pstk->in_t)) - pstk->in_xp = pstk->in_sym->ssue->suelem; + pstk->in_lnk = pstk->in_sym->ssue->sylnk; mkstack(p); /* Setup for assignment */ /* pop one step if SOU, ilbrace will push */ - if (op == NAME) + if (op == NAME || op == LB) pstk = pstk->in_prev; #ifdef PCC_DEBUG @@ -830,7 +852,7 @@ i = (unsigned char)s[-1]; asginit(bcon(i)); } - nfree(p); + tfree(p); } /* @@ -904,8 +926,8 @@ if (in->in_fl) printf("{ "); printf("soff=%d ", in->in_sym->soffset); if (in->in_t == STRTY) { - if (in->in_xp && in->in_xp[0]) - printf("curel %s ", in->in_xp[0]->sname); + if (in->in_lnk) + printf("curel %s ", in->in_lnk->sname); else printf("END struct"); } @@ -931,7 +953,7 @@ /* Handle "aaa" as { 'a', 'a', 'a' } */ beginit(sp); strcvt(p); - if (csym->sdf->ddim == 0) + if (csym->sdf->ddim == NOOFFSET) scalinit(bcon(0)); /* Null-term arrays */ endinit(); return; @@ -940,9 +962,8 @@ switch (sp->sclass) { case STATIC: case EXTDEF: - spname = sp; - p = optim(buildtree(ASSIGN, buildtree(NAME, NIL, NIL), p)); - setscl(sp); + p = optim(buildtree(ASSIGN, nametree(sp), p)); + defloc(sp); ninval(0, p->n_right->n_sue->suesize, p->n_right); tfree(p); break; @@ -951,8 +972,7 @@ case REGISTER: if (ISARY(sp->stype)) cerror("no array init"); - spname = sp; - ecomp(buildtree(ASSIGN, buildtree(NAME, NIL, NIL), p)); + ecomp(buildtree(ASSIGN, nametree(sp), p)); break; default: Index: gcc_compat.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/gcc_compat.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/gcc_compat.c -L usr.bin/pcc/ccom/gcc_compat.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/gcc_compat.c +++ usr.bin/pcc/ccom/gcc_compat.c @@ -1,4 +1,4 @@ -/* $Id: gcc_compat.c,v 1.7 2006/05/13 06:35:36 ragge Exp $ */ +/* $Id: gcc_compat.c,v 1.22 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -36,15 +36,46 @@ #include +/* Remove heading and trailing __ */ +static char * +decap(char *s) +{ + if (s[0] == '_' && s[1] == '_') { + int len = strlen(s); + + if (s[len-1] == '_' && s[len-2] == '_') { + s = tmpstrdup(s); /* will trash */ + s[len-2] = 0; + } + s += 2; + } + return s; +} + static struct kw { char *name, *ptr; int rv; } kw[] = { - { "__asm", NULL, C_ASM }, - { "__signed", NULL, 0 }, - { "__inline", NULL, C_FUNSPEC }, - { "__const", NULL, 0 }, - { "__asm__", NULL, C_ASM }, +/* + * Do NOT change the order of these entries unless you know + * what you're doing! + */ +/* 0 */ { "__asm", NULL, C_ASM }, +/* 1 */ { "__signed", NULL, 0 }, +/* 2 */ { "__inline", NULL, C_FUNSPEC }, +/* 3 */ { "__const", NULL, 0 }, +/* 4 */ { "__asm__", NULL, C_ASM }, +/* 5 */ { "__inline__", NULL, C_FUNSPEC }, +/* 6 */ { "__thread", NULL, 0 }, +/* 7 */ { "__FUNCTION__", NULL, 0 }, +/* 8 */ { "__volatile", NULL, 0 }, +/* 9 */ { "__volatile__", NULL, 0 }, +/* 10 */{ "__restrict", NULL, -1 }, +/* 11 */{ "__typeof__", NULL, C_TYPEOF }, +/* 12 */{ "typeof", NULL, C_TYPEOF }, +/* 13 */{ "__extension__", NULL, -1 }, +/* 14 */{ "__signed__", NULL, 0 }, +/* 15 */{ "__attribute__", NULL, 0 }, { NULL, NULL, 0 }, }; @@ -58,12 +89,16 @@ } +#define TS "\n#pragma tls\n# %d\n" +#define TLLEN sizeof(TS)+10 /* * See if a string matches a gcc keyword. */ int gcc_keyword(char *str, NODE **n) { + extern int inattr, parlvl, parbal; + char tlbuf[TLLEN], *tw; struct kw *kwp; int i; @@ -75,52 +110,174 @@ if (kwp->rv) return kwp->rv; switch (i) { - case 1: /* __signed */ + case 1: /* __signed */ + case 14: /* __signed__ */ *n = mkty((TWORD)SIGNED, 0, MKSUE(SIGNED)); return C_TYPE; case 3: /* __const */ *n = block(QUALIFIER, NIL, NIL, CON, 0, 0); return C_QUALIFIER; + case 6: /* __thread */ + snprintf(tlbuf, TLLEN, TS, lineno); + tw = &tlbuf[strlen(tlbuf)]; + while (tw > tlbuf) + cunput(*--tw); + return -1; + case 7: /* __FUNCTION__ */ + if (cftnsp == NULL) { + uerror("__FUNCTION__ outside function"); + yylval.strp = ""; + } else + yylval.strp = cftnsp->sname; /* XXX - not C99 */ + return C_STRING; + case 8: /* __volatile */ + case 9: /* __volatile__ */ + *n = block(QUALIFIER, NIL, NIL, VOL, 0, 0); + return C_QUALIFIER; + case 15: /* __attribute__ */ + inattr = 1; + parlvl = parbal; + return C_ATTRIBUTE; } cerror("gcc_keyword"); return 0; } -static struct ren { - struct ren *next; - char *old, *new; -} *renp; +#ifndef TARGET_TYPE_ATTR +#define TARGET_TYPE_ATTR(p, sue) 1 +#endif +#ifndef TARGET_VAR_ATTR +#define TARGET_VAR_ATTR(p, sue) 1 +#endif +#ifndef ALMAX +#define ALMAX (ALLDOUBLE > ALLONGLONG ? ALLDOUBLE : ALLONGLONG) +#endif + /* - * Save a name for later renaming of a variable. + * Get type attributes from an argument list. */ -void -gcc_rename(struct symtab *sp, char *newname) +static void +gcc_ta(NODE *p, void *arg) { - struct ren *ren = permalloc(sizeof(struct ren)); + struct suedef *sue = arg; + char *n2, *name = NULL; - sp->sflags |= SRENAME; - ren->old = sp->sname; - ren->new = newstring(newname, strlen(newname)+1); - ren->next = renp; - renp = ren; + if (p->n_op == NAME) { + name = (char *)p->n_sp; + } else if (p->n_op == CALL || p->n_op == UCALL) { + name = (char *)p->n_left->n_sp; + } else + cerror("bad type attribute"); + + n2 = name; + name = decap(name); + if (strcmp(name, "aligned") == 0) { + /* Align the type to a given max alignment */ + if (p->n_op == CALL) { + sue->suealigned = icons(eve(p->n_right)) * SZCHAR; + p->n_op = UCALL; + } else + sue->suealigned = ALMAX; + } else if (strcmp(name, "packed") == 0) { + /* pack members of a struct */ + if (p->n_op != NAME) + uerror("packed takes no args"); + sue->suepacked = SZCHAR; /* specify pack size? */ + } else if (TARGET_TYPE_ATTR(p, sue) == 0) + werror("unsupported attribute %s", n2); } /* - * Get a renamed variable. + * Get variable attributes from an argument list. */ -char * -gcc_findname(struct symtab *sp) +static void +gcc_va(NODE *p, void *arg) { - struct ren *w; + struct suedef *sue = arg; + char *n2, *name = NULL; - if ((sp->sflags & SRENAME) == 0) - return exname(sp->sname); + if (p->n_op == NAME) { + name = (char *)p->n_sp; + } else if (p->n_op == CALL || p->n_op == UCALL) { + name = (char *)p->n_left->n_sp; + } else + cerror("bad variable attribute"); + + n2 = name; + name = decap(name); + if (strcmp(name, "aligned") == 0) { + /* Align the variable to a given max alignment */ + if (p->n_op == CALL) { + sue->suealigned = icons(eve(p->n_right)) * SZCHAR; + p->n_op = UCALL; + } else + sue->suealigned = ALMAX; + } else if (strcmp(name, "section") == 0) { + if (p->n_right->n_op != STRING) + uerror("bad section"); + sue->suesection = p->n_right->n_name; +#ifdef notyet + } else if (strcmp(name, "packed") == 0) { + /* pack members of a struct */ + if (p->n_op != NAME) + uerror("packed takes no args"); + sue->suepacked = SZCHAR; /* specify pack size? */ +#endif + } else if (TARGET_VAR_ATTR(p, sue) == 0) + werror("unsupported attribute %s", n2); +} - for (w = renp; w; w = w->next) { - if (w->old == sp->sname) - return exname(w->new); - } - cerror("gcc_findname %s", sp->sname); - return NULL; +/* + * Extract type attributes from a node tree and setup a suedef + * struct based on its contents. + */ +struct suedef * +gcc_type_attrib(NODE *p) +{ + struct suedef *sue = tmpcalloc(sizeof(struct suedef)); + + flist(p, gcc_ta, sue); + tfree(p); + return sue; +} + +struct suedef * +gcc_var_attrib(NODE *p) +{ + struct suedef *sue = permalloc(sizeof(struct suedef)); /* XXX ??? */ + + memset(sue, 0, sizeof(struct suedef)); + flist(p, gcc_va, sue); + tfree(p); + return sue; +} + + +#ifdef notyet +struct gcc_attrib { + int atype; + union { + int iarg; char *sarg; + } a1; + union { + int iarg; char *sarg; + } a2; + union { + int iarg; char *sarg; + } a3; +}; + +typedef struct gcc_attrib g_attr_t; + +/* + * Parse an attribute tree and create a attribute struct. + * If failed, return NULL> + */ +g_attr_t * +gcc_attrib_parse(NODE *p) +{ } + +#endif + #endif Index: pass1.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/pass1.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/pass1.h -L usr.bin/pcc/ccom/pass1.h -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/pass1.h +++ usr.bin/pcc/ccom/pass1.h @@ -1,4 +1,4 @@ -/* $Id: pass1.h,v 1.125 2007/09/09 10:01:01 ragge Exp $ */ +/* $Id: pass1.h,v 1.166 2008/12/14 21:15:24 ragge Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -33,9 +33,20 @@ * POSSIBILITY OF SUCH DAMAGE. */ +#include "config.h" + #include #include +#include +#ifdef HAVE_STDINT_H +#include +#endif +#ifndef MKEXT +#include "external.h" +#else +typedef unsigned int bittype; /* XXX - for basicblock */ +#endif #include "manifest.h" #include "protos.h" @@ -63,7 +74,6 @@ #define MOE 16 #define UFORTRAN 17 #define USTATIC 18 -#define ILABEL 19 /* field size is ORed in */ #define FIELD 0100 @@ -81,21 +91,17 @@ #define NSTYPES 05 #define SMASK 07 -#define SSET 00010 -#define SREF 00020 -#define SNOCREAT 00040 -#define STEMP 00100 -#define SDYNARRAY 00200 -#define SINLINE 00400 -#define STNODE 01000 -#ifdef GCC_COMPAT -#define SRENAME 02000 /* Node is renamed */ -#endif -#define SASG 04000 - -#ifndef FIXDEF -#define FIXDEF(p) -#endif +/* #define SSET 00010 */ +/* #define SREF 00020 */ +#define SNOCREAT 00040 /* don't create a symbol in lookup() */ +#define STEMP 00100 /* Allocate symtab from temp or perm mem */ +#define SDYNARRAY 00200 /* symbol is dynamic array on stack */ +#define SINLINE 00400 /* function is of type inline */ +#define STNODE 01000 /* symbol shall be a temporary node */ +#define SASG 04000 /* symbol is assigned to already */ +#define SLOCAL1 010000 +#define SLOCAL2 020000 +#define SLOCAL3 040000 /* alignment of initialized quantities */ #ifndef AL_INIT @@ -122,8 +128,11 @@ */ struct suedef { int suesize; /* Size of the struct */ - struct symtab **suelem;/* points to the list of elements */ + struct symtab *sylnk; /* the list of elements */ int suealign; /* Alignment of this struct */ + int suealigned; /* Larger alignment requested */ + int suepacked; /* Smaller alignment requested */ + char * suesection; /* Section requested for this var/fun */ }; /* @@ -134,38 +143,26 @@ union dimfun *df; struct suedef *sue; }; -#define TNULL INCREF(MOETY) /* pointer to MOETY -- impossible type */ -#define TELLIPSIS INCREF(INCREF(MOETY)) +#define TNULL INCREF(FARG) /* pointer to FARG -- impossible type */ +#define TELLIPSIS INCREF(INCREF(FARG)) /* * Symbol table definition. - * - * The symtab_hdr struct is used to save label info in NAME and ICON nodes. */ -struct symtab_hdr { - struct symtab *h_next; /* link to other symbols in the same scope */ - int h_offset; /* offset or value */ - char h_sclass; /* storage class */ - char h_slevel; /* scope level */ - short h_sflags; /* flags, see below */ -}; - struct symtab { - struct symtab_hdr hdr; - char *sname; + struct symtab *snext; /* link to other symbols in the same scope */ + int soffset; /* offset or value */ + char sclass; /* storage class */ + char slevel; /* scope level */ + short sflags; /* flags, see below */ + char *sname; /* Symbol name */ + char *soname; /* Written-out name */ TWORD stype; /* type word */ TWORD squal; /* qualifier word */ union dimfun *sdf; /* ptr to the dimension/prototype array */ struct suedef *ssue; /* ptr to the definition table */ - int suse; /* line number of last use of the variable */ }; -#define snext hdr.h_next -#define soffset hdr.h_offset -#define sclass hdr.h_sclass -#define slevel hdr.h_slevel -#define sflags hdr.h_sflags - #define MKSUE(type) &btdims[type] extern struct suedef btdims[]; @@ -177,7 +174,7 @@ CONSZ sval; /* case value */ int slab; /* associated label */ }; -void genswitch(int, struct swents **, int); +int mygenswitch(int, TWORD, struct swents **, int); extern int blevel; extern int instruct, got_type; @@ -189,16 +186,12 @@ extern struct symtab *cftnsp; extern int autooff, maxautooff, argoff, strucoff; extern int brkflag; -extern int lastloc; extern OFFSZ inoff; extern int reached; extern int isinlining; - -/* tunnel to buildtree for name id's */ - -extern struct symtab *spname; +extern int xinline; extern int sdebug, idebug, pdebug; @@ -208,11 +201,9 @@ extern int flostat; extern int retlab; -/* - * Flags used in structures/unions - */ -#define INSTRUCT 02 -#define INUNION 04 +/* pragma globals */ +extern int pragma_allpacked, pragma_packed, pragma_aligned; +extern char *pragma_renamed; /* * Flags used in the (elementary) flow analysis ... @@ -228,16 +219,16 @@ /* declarations of various functions */ extern NODE - *buildtree(int, NODE *l, NODE *r), + *buildtree(int, NODE *, NODE *r), *mkty(unsigned, union dimfun *, struct suedef *), *rstruct(char *, int), - *dclstruct(struct rstack *), - *strend(char *), - *wstrend(char *), - *tymerge(NODE *typ, NODE *idp), + *dclstruct(struct rstack *, struct suedef *), + *strend(int gtype, char *), + *tymerge(NODE *, NODE *), *stref(NODE *), *offcon(OFFSZ, TWORD, union dimfun *, struct suedef *), *bcon(int), + *xbcon(CONSZ, struct symtab *, TWORD), *bpsize(NODE *), *convert(NODE *, int), *pconvert(NODE *), @@ -245,99 +236,150 @@ *ptmatch(NODE *), *tymatch(NODE *), *makety(NODE *, TWORD, TWORD, union dimfun *, struct suedef *), - *block(int, NODE *, NODE *r, TWORD, union dimfun *, struct suedef *), + *block(int, NODE *, NODE *, TWORD, union dimfun *, struct suedef *), *doszof(NODE *), *talloc(void), *optim(NODE *), *clocal(NODE *), *ccopy(NODE *), - *btsize(TWORD, union dimfun *, struct suedef *), - *tempnode(int, TWORD type, union dimfun *df, struct suedef *sue), - *doacall(NODE *f, NODE *a); + *tempnode(int, TWORD, union dimfun *, struct suedef *), + *eve(NODE *), + *doacall(struct symtab *, NODE *, NODE *); +NODE *intprom(NODE *); OFFSZ tsize(TWORD, union dimfun *, struct suedef *), psize(NODE *); NODE * typenode(NODE *new); void spalloc(NODE *, NODE *, OFFSZ); char *exname(char *); +NODE *floatcon(char *); +NODE *fhexcon(char *); +extern struct rstack *rpole; -int oalloc(struct symtab *p, int *poff); +int oalloc(struct symtab *, int *); void deflabel(char *); -void deflab1(int); -void setloc1(int); void gotolabel(char *); -unsigned int esccon(char **sptr); -void inline_start(char *name); +unsigned int esccon(char **); +void inline_start(struct symtab *); void inline_end(void); void inline_addarg(struct interpass *); -void inline_ref(char *); +void inline_ref(struct symtab *); void inline_prtout(void); +void inline_args(struct symtab **, int); +NODE *inlinetree(struct symtab *, NODE *, NODE *); void ftnarg(NODE *); -struct rstack *bstruct(char *, int); +struct rstack *bstruct(char *, int, struct suedef *); void moedef(char *); void beginit(struct symtab *); void simpleinit(struct symtab *, NODE *); -struct symtab *lookup(char *name, int s); -struct symtab *getsymtab(char *name, int flags); +struct symtab *lookup(char *, int); +struct symtab *getsymtab(char *, int); char *addstring(char *); char *addname(char *); -char *newstring(char *, int len); -void symclear(int level); -void schedremove(struct symtab *p); -struct symtab *hide(struct symtab *p); +void symclear(int); +struct symtab *hide(struct symtab *); +void soumemb(NODE *, char *, int); int talign(unsigned int, struct suedef *); void bfcode(struct symtab **, int); int chkftn(union arglist *, union arglist *); void branch(int); -void cbranch(NODE *p, NODE *q); +void cbranch(NODE *, NODE *); void extdec(struct symtab *); -void commdec(struct symtab *); -void lcommdec(struct symtab *); -int falloc(struct symtab *p, int w, int new, NODE *pty); +void defzero(struct symtab *); +int falloc(struct symtab *, int, int, NODE *); TWORD ctype(TWORD); -void ninval(CONSZ off, int fsz, NODE *); -void infld(CONSZ off, int fsz, CONSZ); -void zbits(CONSZ off, int fsz); -void indata(CONSZ, int); -void instring(char *); -void defnam(struct symtab *); -void plabel(int lab); +void ninval(CONSZ, int, NODE *); +void infld(CONSZ, int, CONSZ); +void zbits(CONSZ, int); +void instring(struct symtab *); +void inwstring(struct symtab *); +void plabel(int); void bjobcode(void); void ejobcode(int); void calldec(NODE *, NODE *); int cisreg(TWORD); -char *tmpsprintf(char *fmt, ...); -char *tmpvsprintf(char *fmt, va_list ap); +char *tmpsprintf(char *, ...); +char *tmpvsprintf(char *, va_list); void asginit(NODE *); void desinit(NODE *); void endinit(void); +void sspinit(void); +void sspstart(void); +void sspend(void); void ilbrace(void); void irbrace(void); -void scalinit(NODE *p); -int ftoint(NODE *, CONSZ **); -void p1print(char *fmt, ...); +void scalinit(NODE *); +void p1print(char *, ...); char *copst(int); int cdope(int); void myp2tree(NODE *); void lcommprint(void); void lcommdel(struct symtab *); +NODE *funcode(NODE *); +struct symtab *enumhd(char *); +NODE *enumdcl(struct symtab *); +NODE *enumref(char *); +CONSZ icons(NODE *); +int mypragma(char **); +void fixdef(struct symtab *); +int cqual(TWORD, TWORD); +void defloc(struct symtab *); +int fldchk(int); +int nncon(NODE *); +void cunput(char); +NODE *nametree(struct symtab *sp); +void *inlalloc(int size); +void pass1_lastchance(struct interpass *); +void fldty(struct symtab *p); +int getlab(void); + +#ifdef SOFTFLOAT +typedef struct softfloat SF; +SF soft_neg(SF); +SF soft_cast(CONSZ v, TWORD); +SF soft_plus(SF, SF); +SF soft_minus(SF, SF); +SF soft_mul(SF, SF); +SF soft_div(SF, SF); +int soft_isz(SF); +CONSZ soft_val(SF); +#define FLOAT_NEG(sf) soft_neg(sf) +#define FLOAT_CAST(v,t) soft_cast(v, t) +#define FLOAT_PLUS(x1,x2) soft_plus(x1, x2) +#define FLOAT_MINUS(x1,x2) soft_minus(x1, x2) +#define FLOAT_MUL(x1,x2) soft_mul(x1, x2) +#define FLOAT_DIV(x1,x2) soft_div(x1, x2) +#define FLOAT_ISZERO(sf) soft_isz(sf) +#define FLOAT_VAL(sf) soft_val(sf) +#else +#define FLOAT_NEG(p) -(p) +#define FLOAT_CAST(p,v) (ISUNSIGNED(v) ? \ + (long double)(U_CONSZ)(p) : (long double)(CONSZ)(p)) +#define FLOAT_PLUS(x1,x2) (x1) + (x2) +#define FLOAT_MINUS(x1,x2) (x1) - (x2) +#define FLOAT_MUL(x1,x2) (x1) * (x2) +#define FLOAT_DIV(x1,x2) (x1) / (x2) +#define FLOAT_ISZERO(p) (p) == 0.0 +#define FLOAT_VAL(p) (CONSZ)(p) +#endif #ifdef GCC_COMPAT void gcc_init(void); int gcc_keyword(char *, NODE **); -void gcc_rename(struct symtab *sp, char *newname); -char *gcc_findname(struct symtab *sp); +struct suedef *gcc_type_attrib(NODE *); +struct suedef *gcc_var_attrib(NODE *); #endif #ifdef STABS void stabs_init(void); void stabs_file(char *); +void stabs_efile(char *); void stabs_line(int); void stabs_rbrac(int); void stabs_lbrac(int); void stabs_func(struct symtab *); void stabs_newsym(struct symtab *); void stabs_chgsym(struct symtab *); -void stabs_struct(struct symtab *p, struct suedef *sue); +void stabs_struct(struct symtab *, struct suedef *); #endif #ifndef CHARCAST @@ -363,7 +405,7 @@ #define OROR (MAXOP+12) #define NOT (MAXOP+13) #define CAST (MAXOP+14) -/* #define STRING (MAXOP+15) */ +#define STRING (MAXOP+15) /* The following must be in the same order as their NOASG counterparts */ #define PLUSEQ (MAXOP+16) @@ -381,12 +423,18 @@ #define INCR (MAXOP+26) #define DECR (MAXOP+27) +#define SZOF (MAXOP+28) + + /* * The following types are only used in pass1. */ #define SIGNED (MAXTYPES+1) #define BOOL (MAXTYPES+2) - +#define FCOMPLEX (MAXTYPES+3) +#define COMPLEX (MAXTYPES+4) +#define LCOMPLEX (MAXTYPES+5) +#define ENUMTY (MAXTYPES+6) #define coptype(o) (cdope(o)&TYFLG) #define clogop(o) (cdope(o)&LOGFLG) Index: main.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/main.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/ccom/main.c -L usr.bin/pcc/ccom/main.c -u -r1.2 -r1.3 --- usr.bin/pcc/ccom/main.c +++ usr.bin/pcc/ccom/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.72 2007/09/25 06:43:06 ragge Exp $ */ +/* $Id: main.c,v 1.95 2008/12/17 15:59:24 ragge Exp $ */ /* * Copyright (c) 2002 Anders Magnusson. All rights reserved. @@ -26,7 +26,11 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "config.h" + +#ifdef HAVE_UNISTD_H #include +#endif #include #include #include @@ -34,19 +38,44 @@ #include "pass1.h" #include "pass2.h" -int sflag, nflag, oflag, kflag; -int lflag, odebug, rdebug, radebug, vdebug, s2debug, udebug, x2debug; +int sflag, nflag, oflag, kflag, pflag; +int lflag, odebug, rdebug, s2debug, udebug, x2debug; #if !defined(MULTIPASS) || defined(PASST) int iTflag, oTflag; #endif -int xdebug, mdebug, sdebug, gflag, c2debug, pdebug; +int xdebug, sdebug, gflag, c2debug, pdebug; int Wstrict_prototypes, Wmissing_prototypes, Wimplicit_int, - Wimplicit_function_declaration; -int xssaflag, xtailcallflag, xtemps, xdeljumps; + Wimplicit_function_declaration, Wpointer_sign, Wshadow, + Wsign_compare, Wunknown_pragmas, Wunreachable_code; +#ifdef CHAR_UNSIGNED +int funsigned_char = 1; +#else +int funsigned_char = 0; +#endif +int sspflag; +int xssaflag, xtailcallflag, xtemps, xdeljumps, xdce, xinline; int e2debug, t2debug, f2debug, b2debug; -struct suedef btdims[24]; +struct suedef btdims[32] = { + [BOOL] = { .suesize = SZBOOL, .suealign = ALBOOL }, + [CHAR] = { .suesize = SZCHAR, .suealign = ALCHAR }, + [INT] = { .suesize = SZINT, .suealign = ALINT }, + [FLOAT] = { .suesize = SZFLOAT, .suealign = ALFLOAT }, + [DOUBLE] = { .suesize = SZDOUBLE, .suealign = ALDOUBLE }, + [LDOUBLE] = { .suesize = SZLDOUBLE, .suealign = ALLDOUBLE }, + [LONG] = { .suesize = SZLONG, .suealign = ALLONG }, + [LONGLONG] = { .suesize = SZLONGLONG, .suealign = ALLONGLONG }, + [SHORT] = { .suesize = SZSHORT, .suealign = ALSHORT }, + [UCHAR] = { .suesize = SZCHAR, .suealign = ALCHAR }, + [USHORT] = { .suesize = SZSHORT, .suealign = ALSHORT }, + [UNSIGNED] = { .suesize = SZINT, .suealign = ALINT }, + [ULONG] = { .suesize = SZLONG, .suealign = ALLONG }, + [ULONGLONG] = { .suesize = SZLONGLONG, .suealign = ALLONGLONG }, + [FCOMPLEX] = { .suesize = SZFLOAT * 2, .suealign = ALFLOAT }, + [COMPLEX] = { .suesize = SZDOUBLE * 2, .suealign = ALDOUBLE }, + [LCOMPLEX] = { .suesize = SZLDOUBLE * 2, .suealign = ALLDOUBLE }, +}; char *prgname; static void prtstats(void); @@ -58,6 +87,11 @@ { "missing-prototypes", &Wmissing_prototypes, }, { "implicit-int", &Wimplicit_int, }, { "implicit-function-declaration", &Wimplicit_function_declaration, }, + { "shadow", &Wshadow, }, + { "pointer-sign", &Wpointer_sign, }, + { "sign-compare", &Wsign_compare, }, + { "unknown-pragmas", &Wunknown_pragmas, }, + { "unreachable-code", &Wunreachable_code, }, { NULL, NULL, }, }; @@ -72,10 +106,12 @@ static void segvcatch(int a) { - fprintf(stderr, "%sinternal compiler error: %s, line %d\n", + char buf[1024]; + + snprintf(buf, sizeof buf, "%sinternal compiler error: %s, line %d\n", nerrors ? "" : "major ", ftitle, lineno); - fflush(stderr); - exit(1); + write(STDERR_FILENO, buf, strlen(buf)); + _exit(1); } /* @@ -84,22 +120,60 @@ static void Wflags(char *str) { - int i, found = 0, all; + int i, flagval = 1, found = 0, all; + + if (strncmp("no-", str, 3) == 0) { + str += 3; + flagval = 0; + } if (strcmp(str, "implicit") == 0) { - Wimplicit_int = Wimplicit_function_declaration = 1; + Wimplicit_int = Wimplicit_function_declaration = flagval; + return; + } + if (strcmp(str, "error") == 0) { + warniserr = flagval; return; } + all = strcmp(str, "W") == 0; - for (i = 0; flagstr[i].n; i++) + for (i = 0; flagstr[i].n; i++) { if (all || strcmp(flagstr[i].n, str) == 0) { - *flagstr[i].f = 1; + *flagstr[i].f = flagval; found++; } - if (found == 0) + } + if (found == 0) { + fprintf(stderr, "unrecognised option '%s'\n", str); usage(); + } } +static void +fflags(char *str) +{ + int flagval = 1; + + if (strncmp("no-", str, 3) == 0) { + str += 3; + flagval = 0; + } + + if (strcmp(str, "signed-char") == 0) + funsigned_char = !flagval; + else if (strcmp(str, "unsigned-char") == 0) + funsigned_char = flagval; + else if (strcmp(str, "stack-protector") == 0) + sspflag = flagval; + else if (strcmp(str, "stack-protector-all") == 0) + sspflag = flagval; + else if (strncmp(str, "pack-struct", 11) == 0) + pragma_allpacked = (strlen(str) > 12 ? atoi(str+12) : 1); + else { + fprintf(stderr, "unrecognised option '%s'\n", str); + usage(); + } +} /* control multiple files */ int @@ -108,9 +182,15 @@ int ch; +#ifdef TIMING + struct timeval t1, t2; + + (void)gettimeofday(&t1, NULL); +#endif + prgname = argv[0]; - while ((ch = getopt(argc, argv, "VlwX:Z:W:sOT:gx:kv")) != -1) + while ((ch = getopt(argc, argv, "OT:VW:X:Z:f:gklm:psvwx:")) != -1) switch (ch) { #if !defined(MULTIPASS) || defined(PASS1) case 'X': @@ -118,13 +198,13 @@ switch (*optarg++) { case 'd': ++ddebug; break; /* declarations */ case 'i': ++idebug; break; /* initializations */ - case 'b': ++bdebug; break; - case 't': ++tdebug; break; + case 'b': ++bdebug; break; /* buildtree */ + case 't': ++tdebug; break; /* type match */ case 'e': ++edebug; break; /* pass1 exit */ case 'x': ++xdebug; break; /* MD code */ - case 's': ++sdebug; break; - case 'n': ++nflag; break; - case 'o': ++oflag; break; + case 's': ++sdebug; break; /* inline */ + case 'n': ++nflag; break; /* node alloc */ + case 'o': ++oflag; break; /* optim */ case 'p': ++pdebug; break; /* prototype */ default: fprintf(stderr, "unknown X flag '%c'\n", @@ -161,15 +241,12 @@ case 'r': /* register alloc/graph coloring */ ++rdebug; break; - case 'a': ++radebug; break; case 'b': /* basic block and SSA building */ ++b2debug; break; case 'c': /* code printout */ ++c2debug; break; - case 'm': ++mdebug; break; - case 'v': ++vdebug; break; case 't': ++t2debug; break; case 's': /* shape matching */ ++s2debug; @@ -187,16 +264,28 @@ #endif break; + case 'f': /* Language */ + fflags(optarg); + break; + + case 'g': /* Debugging */ + gflag = 1; + break; + case 'k': /* PIC code */ ++kflag; break; - case 'l': /* linenos */ + case 'l': /* Linenos */ ++lflag; break; - case 'g': /* Debugging */ - gflag = 1; + case 'm': /* Target-specific */ + mflags(optarg); + break; + + case 'p': /* Profiling */ + pflag = 1; break; case 's': /* Statistics */ @@ -216,6 +305,10 @@ xtemps++; else if (strcmp(optarg, "deljumps") == 0) xdeljumps++; + else if (strcmp(optarg, "dce") == 0) + xdce++; + else if (strcmp(optarg, "inline") == 0) + xinline++; else usage(); break; @@ -230,20 +323,21 @@ argc -= optind; argv += optind; - if (argc != 0) { + if (argc > 0 && strcmp(argv[0], "-") != 0) { if (freopen(argv[0], "r", stdin) == NULL) { fprintf(stderr, "open input file '%s':", argv[0]); perror(NULL); exit(1); } - if (argc != 1) - if (freopen(argv[1], "w", stdout) == NULL) { - fprintf(stderr, "open output file '%s':", - argv[1]); - perror(NULL); - exit(1); - } + } + if (argc > 1 && strcmp(argv[1], "-") != 0) { + if (freopen(argv[1], "w", stdout) == NULL) { + fprintf(stderr, "open output file '%s':", + argv[1]); + perror(NULL); + exit(1); + } } mkdope(); @@ -254,27 +348,18 @@ gcc_init(); #endif - /* dimension table initialization */ - - btdims[VOID].suesize = 0; - btdims[BOOL].suesize = SZBOOL; - btdims[CHAR].suesize = SZCHAR; - btdims[INT].suesize = SZINT; - btdims[FLOAT].suesize = SZFLOAT; - btdims[DOUBLE].suesize = SZDOUBLE; - btdims[LDOUBLE].suesize = SZLDOUBLE; - btdims[LONG].suesize = SZLONG; - btdims[LONGLONG].suesize = SZLONGLONG; - btdims[SHORT].suesize = SZSHORT; - btdims[UCHAR].suesize = SZCHAR; - btdims[USHORT].suesize = SZSHORT; - btdims[UNSIGNED].suesize = SZINT; - btdims[ULONG].suesize = SZLONG; - btdims[ULONGLONG].suesize = SZLONGLONG; - /* starts past any of the above */ reached = 1; bjobcode(); +#ifndef TARGET_STDARGS + { + NODE *p = block(NAME, NIL, NIL, PTR|CHAR, NULL, MKSUE(CHAR)); + struct symtab *sp = lookup(addname("__builtin_va_list"), 0); + p->n_sp = sp; + defid(p, TYPEDEF); + nfree(p); + } +#endif #ifdef STABS if (gflag) { @@ -283,13 +368,34 @@ } #endif + if (sspflag) + sspinit(); + (void) yyparse(); yyaccpt(); - ejobcode( nerrors ? 1 : 0 ); if (!nerrors) lcommprint(); +#ifdef STABS + if (gflag) + stabs_efile(argc ? argv[0] : ""); +#endif + + ejobcode( nerrors ? 1 : 0 ); + +#ifdef TIMING + (void)gettimeofday(&t2, NULL); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + if (t2.tv_usec < 0) { + t2.tv_usec += 1000000; + t2.tv_sec -= 1; + } + fprintf(stderr, "pccom total time: %ld s %ld us\n", + t2.tv_sec, t2.tv_usec); +#endif + if (sflag) prtstats(); return(nerrors?1:0); Index: cgram.y =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/cgram.y,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/cgram.y -L usr.bin/pcc/ccom/cgram.y -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/cgram.y +++ usr.bin/pcc/ccom/cgram.y @@ -1,4 +1,4 @@ -/* $Id: cgram.y,v 1.170 2007/09/16 19:25:33 ragge Exp $ */ +/* $Id: cgram.y,v 1.241 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). @@ -79,7 +79,6 @@ /* * Token used in C lex/yacc communications. */ -%token C_WSTRING /* a wide string constant */ %token C_STRING /* a string constant */ %token C_ICON /* an integer constant */ %token C_FCON /* a floating point constant */ @@ -116,6 +115,9 @@ %token C_QUALIFIER %token C_FUNSPEC %token C_ASM +%token NOMATCH +%token C_TYPEOF /* COMPAT_GCC */ +%token C_ATTRIBUTE /* COMPAT_GCC */ /* * Precedence @@ -142,14 +144,15 @@ # include # include -static int fun_inline; /* Reading an inline function */ +int fun_inline; /* Reading an inline function */ int oldstyle; /* Current function being defined */ -int noretype; static struct symtab *xnf; -#ifdef GCC_COMPAT -char *renname; /* for renaming of variables */ -#endif +extern int enummer, tvaloff; +extern struct rstack *rpole; +static int ctval, widestr; +NODE *cftnod; +#define NORETYP SNOCREAT /* no return type, save in unused field in symtab */ static NODE *bdty(int op, ...); static void fend(void); @@ -159,12 +162,29 @@ static void resetbc(int mask); static void swend(void); static void addcase(NODE *p); +#ifdef GCC_COMPAT +static void gcccase(NODE *p, NODE *); +#endif static void adddef(void); static void savebc(void); -static void swstart(int); -static NODE * structref(NODE *p, int f, char *name); +static void swstart(int, TWORD); +static void genswitch(int, TWORD, struct swents **, int); +static NODE *structref(NODE *p, int f, char *name); static char *mkpstr(char *str); static struct symtab *clbrace(NODE *); +static NODE *cmop(NODE *l, NODE *r); +static NODE *xcmop(NODE *out, NODE *in, NODE *str); +static void mkxasm(char *str, NODE *p); +static NODE *xasmop(char *str, NODE *p); +static int maxstlen(char *str); +static char *stradd(char *old, char *new); +static NODE *biop(int op, NODE *l, NODE *r); +static void flend(void); +static char * simname(char *s); +#ifdef GCC_COMPAT +static NODE *tyof(NODE *); /* COMPAT_GCC */ +static NODE *voidcon(void); /* COMPAT_GCC */ +#endif /* * State for saving current switch state (when nested switches). @@ -184,6 +204,7 @@ NODE *nodep; struct symtab *symp; struct rstack *rp; + struct suedef *suep; char *strp; } @@ -191,60 +212,49 @@ %start ext_def_list %type con_e ifelprefix ifprefix whprefix forprefix doprefix switchpart - type_qualifier_list -%type e .e term enum_dcl struct_dcl cast_type funct_idn declarator + type_qualifier_list xbegin +%type e .e term enum_dcl struct_dcl cast_type declarator direct_declarator elist type_specifier merge_attribs parameter_declaration abstract_declarator initializer parameter_type_list parameter_list addrlbl declaration_specifiers pointer direct_abstract_declarator specifier_qualifier_list merge_specifiers nocon_e - identifier_list arg_param_list arg_declaration arg_dcl_list - designator_list designator -%type string wstring C_STRING C_WSTRING -%type enum_head str_head -%type xnfdeclarator clbrace + identifier_list arg_param_list + designator_list designator xasm oplist oper cnstr funtype + typeof attribute attribute_specifier /* COMPAT_GCC */ + attribute_list attr_spec_list /* COMPAT_GCC */ +%type string C_STRING +%type str_head +%type xnfdeclarator clbrace enum_head %type C_CLASS C_STRUCT C_RELOP C_DIVOP C_SHIFTOP C_ANDAND C_OROR C_STROP C_INCOP C_UNOP C_ASOP C_EQUOP + %type C_TYPE C_QUALIFIER C_ICON C_FCON %type C_NAME C_TYPENAME - +%type attr_var %% ext_def_list: ext_def_list external_def | { ftnend(); } ; -external_def: function_definition { blevel = 0; } +external_def: funtype kr_args compoundstmt { fend(); } | declaration { blevel = 0; symclear(0); } | asmstatement ';' | ';' | error { blevel = 0; } ; -function_definition: - /* Ansi (or K&R header without parameter types) */ - declaration_specifiers declarator { - fundef($1, $2); - } compoundstmt { fend(); } - /* Same as above but without declaring function type */ - | declarator { - noretype = 1; - fundef(mkty(INT, 0, MKSUE(INT)), $1); - } compoundstmt { fend(); noretype = 0; } - /* K&R function without type declaration */ - | declarator { - noretype = 1; - if (oldstyle == 0) - uerror("bad declaration in ansi function"); - fundef(mkty(INT, 0, MKSUE(INT)), $1); - } arg_dcl_list compoundstmt { fend(); noretype = 0; } - /* K&R function with type declaration */ - | declaration_specifiers declarator { - if (oldstyle == 0) - uerror("bad declaration in ansi function"); - fundef($1, $2); - } arg_dcl_list compoundstmt { fend(); } +funtype: /* no type given */ declarator { + fundef(mkty(INT, 0, MKSUE(INT)), $1); + cftnsp->sflags |= NORETYP; + } + | declaration_specifiers declarator { fundef($1,$2); } + ; + +kr_args: /* empty */ + | arg_dcl_list ; /* @@ -264,14 +274,12 @@ | C_QUALIFIER merge_attribs { $1->n_left = $2; $$ = $1; } | function_specifiers { $$ = NIL; } | function_specifiers merge_attribs { $$ = $2; } + /*COMPAT_GCC*/ | typeof { $$ = $1; } + /*COMPAT_GCC*/ | typeof merge_attribs { $1->n_left = $2; $$ = $1; } ; function_specifiers: - C_FUNSPEC { - if (fun_inline) - uerror("too many inline"); - fun_inline = 1; - } + C_FUNSPEC { fun_inline = 1; } ; type_specifier: C_TYPE { $$ = $1; } @@ -282,16 +290,40 @@ } | struct_dcl { $$ = $1; } | enum_dcl { $$ = $1; } + | attribute_specifier { tfree($1); $$ = biop(FLD, 0, 0); } + ; + +typeof: C_TYPEOF '(' term ')' { $$ = tyof($3); } /* COMPAT_GCC */ + /*COMPAT_GCC*/ | C_TYPEOF '(' cast_type ')' { $$ = tyof($3); } + /*COMPAT_GCC*/ ; + +attribute_specifier : + C_ATTRIBUTE '(' '(' attribute_list ')' ')' { $$ = $4; } + /*COMPAT_GCC*/ ; + +attribute_list: attribute + | attribute ',' attribute_list { $$ = cmop($3, $1); } + ; + +attribute: { $$ = voidcon(); } + | C_NAME { $$ = bdty(NAME, $1); } + | C_NAME '(' elist ')' { + $$ = bdty($3 == NIL ? UCALL : CALL, bdty(NAME, $1), $3); + } ; /* * Adds a pointer list to front of the declarators. * Note the UMUL right node pointer usage. */ -declarator: pointer direct_declarator { - $$ = $1; $1->n_right->n_left = $2; +declarator: pointer direct_declarator attr_var { + $$ = $1; $1->n_right->n_left = $2; $$->n_sue = 0; } - | direct_declarator { $$ = $1; } + | pointer attr_spec_list direct_declarator attr_var { + $$ = $1; $1->n_right->n_left = $3; $$->n_sue = 0; + tfree($2); + } + | direct_declarator attr_var { $$ = $1; $$->n_sue = 0; } ; /* @@ -328,41 +360,58 @@ direct_declarator: C_NAME { $$ = bdty(NAME, $1); } | '(' declarator ')' { $$ = $2; } | direct_declarator '[' nocon_e ']' { - $$ = block(LB, $1, $3, INT, 0, MKSUE(INT)); + $3 = optim($3); + if ((blevel == 0 || rpole != NULL) && !nncon($3)) + uerror("array size not constant"); + /* + * Checks according to 6.7.5.2 clause 1: + * "...the expression shall have an integer type." + * "If the expression is a constant expression, + * it shall have a value greater than zero." + */ + if (!ISINTEGER($3->n_type)) + werror("array size is not an integer"); + else if ($3->n_op == ICON) { + if ($3->n_lval < 0) { + uerror("array size cannot be negative"); + $3->n_lval = 1; + } +#ifdef notyet + if ($3->n_lval == 0 && Wgcc) + werror("gcc extension; zero size"); +#endif + } + $$ = biop(LB, $1, $3); + } + | direct_declarator '[' ']' { + $$ = biop(LB, $1, bcon(NOOFFSET)); } - | direct_declarator '[' ']' { $$ = bdty(LB, $1, 0); } - | direct_declarator '(' notype parameter_type_list ')' { - $$ = bdty(CALL, $1, $4); + | direct_declarator '(' parameter_type_list ')' { + $$ = bdty(CALL, $1, $3); } - | direct_declarator '(' notype identifier_list ')' { - $$ = bdty(CALL, $1, $4); + | direct_declarator '(' identifier_list ')' { + $$ = bdty(CALL, $1, $3); if (blevel != 0) uerror("function declaration in bad context"); oldstyle = 1; } - | direct_declarator '(' ')' { $$ = bdty(UCALL, $1); } - ; - -notype: { /* extern int notype, doproto; notype = 0; doproto=1; printf("notype\n"); */ } + | direct_declarator '(' ')' { + ctval = tvaloff; + $$ = bdty(UCALL, $1); + } ; -identifier_list: C_NAME { $$ = bdty(NAME, $1); $$->n_type = FARG; } - | identifier_list ',' C_NAME { - $$ = bdty(NAME, $3); - $$->n_type = FARG; - $$ = block(CM, $1, $$, 0, 0, 0); - } +identifier_list: C_NAME { $$ = bdty(NAME, $1); } + | identifier_list ',' C_NAME { $$ = cmop($1, bdty(NAME, $3)); } ; /* * Returns as parameter_list, but can add an additional ELLIPSIS node. - * Calls revert() to get the parameter list in the forward order. */ parameter_type_list: parameter_list { $$ = $1; } | parameter_list ',' C_ELLIPSIS { - $$ = block(CM, $1, block(ELLIPSIS, NIL, NIL, 0, 0, 0), - 0, 0, 0); + $$ = cmop($1, biop(ELLIPSIS, NIL, NIL)); } ; @@ -373,7 +422,7 @@ */ parameter_list: parameter_declaration { $$ = $1; } | parameter_list ',' parameter_declaration { - $$ = block(CM, $1, $3, 0, 0, 0); + $$ = cmop($1, $3); } ; @@ -382,15 +431,22 @@ */ parameter_declaration: declaration_specifiers declarator { + if ($1->n_lval != SNULL && $1->n_lval != REGISTER) + uerror("illegal parameter class"); + $2->n_sue = NULL; /* no attributes */ $$ = tymerge($1, $2); nfree($1); + } | declaration_specifiers abstract_declarator { + $2->n_sue = NULL; /* no attributes */ $$ = tymerge($1, $2); nfree($1); } | declaration_specifiers { - $$ = tymerge($1, bdty(NAME, NULL)); + $$ = bdty(NAME, NULL); + $$->n_sue = NULL; /* no attributes */ + $$ = tymerge($1, $$); nfree($1); } ; @@ -398,28 +454,30 @@ abstract_declarator: pointer { $$ = $1; $1->n_right->n_left = bdty(NAME, NULL); } | direct_abstract_declarator { $$ = $1; } - | pointer direct_abstract_declarator { + | pointer direct_abstract_declarator attr_var { $$ = $1; $1->n_right->n_left = $2; } ; direct_abstract_declarator: '(' abstract_declarator ')' { $$ = $2; } - | '[' ']' { $$ = bdty(LB, bdty(NAME, NULL), 0); } + | '[' ']' { $$ = biop(LB, bdty(NAME, NULL), bcon(NOOFFSET)); } | '[' con_e ']' { $$ = bdty(LB, bdty(NAME, NULL), $2); } - | direct_abstract_declarator '[' ']' { $$ = bdty(LB, $1, 0); } + | direct_abstract_declarator '[' ']' { + $$ = biop(LB, $1, bcon(NOOFFSET)); + } | direct_abstract_declarator '[' con_e ']' { $$ = bdty(LB, $1, $3); } | '(' ')' { $$ = bdty(UCALL, bdty(NAME, NULL)); } - | '(' notype parameter_type_list ')' { - $$ = bdty(CALL, bdty(NAME, NULL), $3); + | '(' parameter_type_list ')' { + $$ = bdty(CALL, bdty(NAME, NULL), $2); } | direct_abstract_declarator '(' ')' { $$ = bdty(UCALL, $1); } - | direct_abstract_declarator '(' notype parameter_type_list ')' { - $$ = bdty(CALL, $1, $4); + | direct_abstract_declarator '(' parameter_type_list ')' { + $$ = bdty(CALL, $1, $3); } ; @@ -445,25 +503,24 @@ /* * Declarations in beginning of blocks. */ -declaration_list: declaration - | declaration_list declaration +block_item_list: block_item + | block_item_list block_item + ; + +block_item: declaration + | statement ; /* * Here starts the old YACC code. */ -stmt_list: stmt_list statement - | { bccode(); } - ; - /* * Variables are declared in init_declarator. */ -declaration: declaration_specifiers ';' { nfree($1); goto inl; } +declaration: declaration_specifiers ';' { nfree($1); fun_inline = 0; } | declaration_specifiers init_declarator_list ';' { nfree($1); - inl: fun_inline = 0; } ; @@ -474,41 +531,51 @@ */ init_declarator_list: init_declarator - | init_declarator_list ',' { $$ = $0; } init_declarator + | init_declarator_list ',' attr_var { $$ = $0; } init_declarator attr_var ; -enum_dcl: enum_head '{' moe_list optcomma '}' { $$ = dclstruct($1); } - | C_ENUM C_NAME { $$ = rstruct($2,0); } - | C_ENUM C_TYPENAME { $$ = rstruct($2,0); } +enum_dcl: enum_head '{' moe_list optcomma '}' { $$ = enumdcl($1); } + | C_ENUM C_NAME { $$ = enumref($2); } ; -enum_head: C_ENUM { $$ = bstruct(NULL,0); } - | C_ENUM C_NAME { $$ = bstruct($2,0); } - | C_ENUM C_TYPENAME { $$ = bstruct($2,0); } +enum_head: C_ENUM { $$ = enumhd(NULL); } + | C_ENUM C_NAME { $$ = enumhd($2); } ; moe_list: moe | moe_list ',' moe ; -moe: C_NAME { moedef( $1 ); } - | C_NAME '=' con_e { strucoff = $3; moedef( $1 ); } +moe: C_NAME { moedef($1); } + | C_TYPENAME { moedef($1); } + | C_NAME '=' con_e { enummer = $3; moedef($1); } + | C_TYPENAME '=' con_e { enummer = $3; moedef($1); } ; -struct_dcl: str_head '{' struct_dcl_list '}' { $$ = dclstruct($1); } - | C_STRUCT C_NAME { $$ = rstruct($2,$1); } - | C_STRUCT C_TYPENAME { $$ = rstruct($2,$1); } - | str_head '{' '}' { -#ifndef GCC_COMPAT - werror("gcc extension"); -#endif - $$ = dclstruct($1); +struct_dcl: str_head '{' struct_dcl_list '}' { + $$ = dclstruct($1, NULL); } + | C_STRUCT attr_var C_NAME { $$ = rstruct($3,$1); } + /*COMPAT_GCC*/ | str_head '{' '}' { $$ = dclstruct($1, NULL); } ; -str_head: C_STRUCT { $$ = bstruct(NULL, $1); } - | C_STRUCT C_NAME { $$ = bstruct($2,$1); } - | C_STRUCT C_TYPENAME { $$ = bstruct($2,$1); } +attr_var: { + if (pragma_aligned || pragma_packed) { + $$ = tmpcalloc(sizeof(struct suedef)); + $$->suealigned = pragma_aligned; + $$->suepacked = pragma_packed; + } else + $$ = NULL; + } + /*COMPAT_GCC*/ | attr_spec_list { $$ = gcc_type_attrib($1); } + ; + +attr_spec_list: attribute_specifier + | attr_spec_list attribute_specifier { tfree($2); /* XXX */ } + ; + +str_head: C_STRUCT attr_var { $$ = bstruct(NULL, $1, $2); } + | C_STRUCT attr_var C_NAME { $$ = bstruct($3,$1, $2); } ; struct_dcl_list: struct_declaration @@ -539,30 +606,33 @@ struct_declarator: declarator { tymerge($0, $1); - $1->n_sp = getsymtab((char *)$1->n_sp, SMOSNAME); /* XXX */ - defid($1, $0->n_lval); + soumemb($1, (char *)$1->n_sp, 0); nfree($1); } | ':' con_e { - if (!(instruct&INSTRUCT)) - uerror( "field outside of structure" ); + if (fldchk($2)) + $2 = 1; falloc(NULL, $2, -1, $0); } | declarator ':' con_e { - if (!(instruct&INSTRUCT)) - uerror( "field outside of structure" ); - if( $3<0 || $3 >= FIELD ){ - uerror( "illegal field size" ); + if (fldchk($3)) $3 = 1; - } if ($1->n_op == NAME) { tymerge($0, $1); - $1->n_sp = getsymtab((char *)$1->n_sp,SMOSNAME); - defid($1, FIELD|$3); + soumemb($1, (char *)$1->n_sp, FIELD | $3); nfree($1); } else uerror("illegal declarator"); } + | /* unnamed member */ { + NODE *p = $0; + char *c = permalloc(10); + + if (p->n_type != STRTY && p->n_type != UNIONTY) + uerror("bad unnamed member type"); + snprintf(c, 10, "*%dFAKE", getlab()); + soumemb(p, c, 0); + } ; /* always preceeded by attributes */ @@ -576,27 +646,29 @@ init_declarator: declarator { init_declarator($0, $1, 0); } | declarator C_ASM '(' string ')' { #ifdef GCC_COMPAT - renname = $4; + pragma_renamed = newstring($4, strlen($4)); init_declarator($0, $1, 0); #else werror("gcc extension"); init_declarator($0, $1, 0); #endif } - | xnfdeclarator '=' e { simpleinit($1, $3); xnf = NULL; } + | xnfdeclarator '=' e { simpleinit($1, eve($3)); xnf = NULL; } | xnfdeclarator '=' begbr init_list optcomma '}' { endinit(); xnf = NULL; } + /*COMPAT_GCC*/ | xnfdeclarator '=' begbr '}' { endinit(); xnf = NULL; } | xnfdeclarator '=' addrlbl { simpleinit($1, $3); xnf = NULL; } ; begbr: '{' { beginit($-1); } ; -initializer: e %prec ',' { $$ = $1; } +initializer: e %prec ',' { $$ = eve($1); } | addrlbl { $$ = $1; } | ibrace init_list optcomma '}' { $$ = NULL; } + | ibrace '}' { asginit(bcon(0)); $$ = NULL; } ; init_list: designation initializer { asginit($2); } @@ -611,8 +683,18 @@ | designator_list designator { $$ = $2; $$->n_left = $1; } ; -designator: '[' con_e ']' { $$ = bdty(LB, NULL, $2); } - | C_STROP C_NAME { $$ = bdty(NAME, $2); } +designator: '[' con_e ']' { + if ($2 < 0) { + uerror("designator must be non-negative"); + $2 = 0; + } + $$ = biop(LB, NIL, bcon($2)); + } + | C_STROP C_NAME { + if ($1 != DOT) + uerror("invalid designator"); + $$ = bdty(NAME, $2); + } ; optcomma : /* VOID */ @@ -624,34 +706,8 @@ /* STATEMENTS */ -compoundstmt: begin declaration_list stmt_list '}' { -#ifdef STABS - if (gflag && blevel > 2) - stabs_rbrac(blevel); -#endif - --blevel; - if( blevel == 1 ) - blevel = 0; - symclear(blevel); /* Clean ut the symbol table */ - if (autooff > maxautooff) - maxautooff = autooff; - autooff = savctx->contlab; - savctx = savctx->next; - } - | begin stmt_list '}' { -#ifdef STABS - if (gflag && blevel > 2) - stabs_rbrac(blevel); -#endif - --blevel; - if( blevel == 1 ) - blevel = 0; - symclear(blevel); /* Clean ut the symbol table */ - if (autooff > maxautooff) - maxautooff = autooff; - autooff = savctx->contlab; - savctx = savctx->next; - } +compoundstmt: begin block_item_list '}' { flend(); } + | begin '}' { flend(); } ; begin: '{' { @@ -672,10 +728,13 @@ bc->contlab = autooff; bc->next = savctx; savctx = bc; + bccode(); + if (sspflag && blevel == 2) + sspstart(); } ; -statement: e ';' { ecomp( $1 ); } +statement: e ';' { ecomp(eve($1)); symclear(blevel); } | compoundstmt | ifprefix statement { plabel($1); reached = 1; } | ifelprefix statement { @@ -698,9 +757,9 @@ if (flostat & FCONT) reached = 1; if (reached) - cbranch($5, bcon($1)); + cbranch(eve($5), bcon($1)); else - tfree($5); + tfree(eve($5)); plabel( brklab); reached = 1; resetbc(0); @@ -741,35 +800,37 @@ } | C_RETURN ';' { branch(retlab); - if (cftnsp->stype != VOID && noretype && + if (cftnsp->stype != VOID && + (cftnsp->sflags & NORETYP) == 0 && cftnsp->stype != VOID+FTN) uerror("return value required"); rch: - if (!reached) + if (!reached && Wunreachable_code) werror( "statement is not reached"); reached = 0; } | C_RETURN e ';' { - register NODE *temp; - - spname = cftnsp; - temp = buildtree( NAME, NIL, NIL ); - temp->n_type = DECREF(temp->n_type); - temp = buildtree(RETURN, temp, $2); + NODE *p; - if (temp->n_type == VOID) - ecomp(temp->n_right); - else - ecomp(buildtree(FORCE, temp->n_right, NIL)); - nfree(temp->n_left); - nfree(temp); + p = nametree(cftnsp); + p->n_type = DECREF(p->n_type); + p = buildtree(RETURN, p, eve($2)); + if (p->n_type == VOID) { + ecomp(p->n_right); + } else { + if (cftnod == NIL) + cftnod = tempnode(0, p->n_type, + p->n_df, p->n_sue); + ecomp(buildtree(ASSIGN, + tcopy(cftnod), p->n_right)); + } + tfree(p->n_left); + nfree(p); branch(retlab); reached = 0; } | C_GOTO C_NAME ';' { gotolabel($2); goto rch; } - | C_GOTO '*' e ';' { - ecomp(block(GOTO, $3, NIL, INT, 0, 0)); - } + | C_GOTO '*' e ';' { ecomp(biop(GOTO, eve($3), NIL)); } | asmstatement ';' | ';' | error ';' @@ -777,18 +838,44 @@ | label statement ; -asmstatement: C_ASM '(' string ')' { send_passt(IP_ASM, mkpstr($3)); } +asmstatement: C_ASM mvol '(' string ')' { send_passt(IP_ASM, mkpstr($4)); } + | C_ASM mvol '(' string xasm ')' { mkxasm($4, $5); } + ; + +mvol: /* empty */ + | C_QUALIFIER { nfree($1); } + ; + +xasm: ':' oplist { $$ = xcmop($2, NIL, NIL); } + | ':' oplist ':' oplist { $$ = xcmop($2, $4, NIL); } + | ':' oplist ':' oplist ':' cnstr { $$ = xcmop($2, $4, $6); } + ; + +oplist: /* nothing */ { $$ = NIL; } + | oper { $$ = $1; } ; +oper: string '(' e ')' { $$ = xasmop($1, eve($3)); } + | oper ',' string '(' e ')' { + $$ = cmop($1, xasmop($3, eve($5))); + } + ; + +cnstr: string { $$ = xasmop($1, bcon(0)); } + | cnstr ',' string { $$ = cmop($1, xasmop($3, bcon(0))); } + ; + label: C_NAME ':' { deflabel($1); reached = 1; } - | C_CASE e ':' { addcase($2); reached = 1; } + | C_TYPENAME ':' { deflabel($1); reached = 1; } + | C_CASE e ':' { addcase(eve($2)); reached = 1; } +/* COMPAT_GCC */| C_CASE e C_ELLIPSIS e ':' { + gcccase(eve($2), eve($4)); reached = 1; + } | C_DEFAULT ':' { reached = 1; adddef(); flostat |= FDEF; } ; doprefix: C_DO { savebc(); - if (!reached) - werror("loop not entered at top"); brklab = getlab(); contlab = getlab(); plabel( $$ = getlab()); @@ -796,7 +883,7 @@ } ; ifprefix: C_IF '(' e ')' { - cbranch(buildtree(NOT, $3, NIL), bcon($$ = getlab())); + cbranch(buildtree(NOT, eve($3), NIL), bcon($$ = getlab())); reached = 1; } ; @@ -812,8 +899,7 @@ whprefix: C_WHILE '(' e ')' { savebc(); - if (!reached) - werror("loop not entered at top"); + $3 = eve($3); if ($3->n_op == ICON && $3->n_lval != 0) flostat = FLOOP; plabel( contlab = getlab()); @@ -828,8 +914,18 @@ forprefix: C_FOR '(' .e ';' .e ';' { if ($3) ecomp($3); - else if (!reached) - werror("loop not entered at top"); + savebc(); + contlab = getlab(); + brklab = getlab(); + plabel( $$ = getlab()); + reached = 1; + if ($5) + cbranch(buildtree(NOT, $5, NIL), bcon(brklab)); + else + flostat |= FLOOP; + } + | C_FOR '(' incblev declaration .e ';' { + blevel--; savebc(); contlab = getlab(); brklab = getlab(); @@ -841,182 +937,152 @@ flostat |= FLOOP; } ; -switchpart: C_SWITCH '(' e ')' { + +incblev: { blevel++; } + ; + +switchpart: C_SWITCH '(' e ')' { NODE *p; int num; + TWORD t; savebc(); brklab = getlab(); - if ($3->n_type != INT) { - /* must cast to integer */ - p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); - p = buildtree(CAST, p, $3); - $3 = p->n_right; - nfree(p->n_left); - nfree(p); + $3 = eve($3); + if (($3->n_type != BOOL && $3->n_type > ULONGLONG) || + $3->n_type < CHAR) { + uerror("switch expression must have integer " + "type"); + t = INT; + } else { + $3 = intprom($3); + t = $3->n_type; } -// ecomp( buildtree( FORCE, $3, NIL ) ); - p = tempnode(0, INT, 0, MKSUE(INT)); - num = p->n_lval; + p = tempnode(0, t, 0, MKSUE(t)); + num = regno(p); ecomp(buildtree(ASSIGN, p, $3)); branch( $$ = getlab()); - swstart(num); + swstart(num, t); reached = 0; } ; /* EXPRESSIONS */ -con_e: { $$=instruct; instruct=0; } e %prec ',' { - $$ = icons( $2 ); - instruct=$1; +con_e: { $$ = rpole; rpole = NULL; } e %prec ',' { + $$ = icons(eve($2)); + rpole = $1; } ; -nocon_e: { $$=instruct; instruct=0; } e %prec ',' { - instruct=$1; - $$ = $2; +nocon_e: { $$ = rpole; rpole = NULL; } e %prec ',' { + rpole = $1; + $$ = eve($2); } ; -.e: e +.e: e { $$ = eve($1); } | { $$=0; } ; -elist: e %prec ',' - | elist ',' e { $$ = buildtree(CM, $1, $3); } +elist: { $$ = NIL; } + | e %prec ',' + | elist ',' e { $$ = biop(CM, $1, $3); } + | elist ',' cast_type { /* hack for stdarg */ + $3->n_op = TYPE; + $$ = biop(CM, $1, $3); + } ; /* * Precedence order of operators. */ -e: e ',' e { $$ = buildtree(COMOP, $1, $3); } - | e '=' e { $$ = buildtree(ASSIGN, $1, $3); } - | e C_ASOP e { $$ = buildtree($2, $1, $3); } +e: e ',' e { $$ = biop(COMOP, $1, $3); } + | e '=' e { $$ = biop(ASSIGN, $1, $3); } + | e C_ASOP e { $$ = biop($2, $1, $3); } | e '?' e ':' e { - $$=buildtree(QUEST, $1, buildtree(COLON, $3, $5)); + $$=biop(QUEST, $1, biop(COLON, $3, $5)); } - | e C_OROR e { $$ = buildtree($2, $1, $3); } - | e C_ANDAND e { $$ = buildtree($2, $1, $3); } - | e '|' e { $$ = buildtree(OR, $1, $3); } - | e '^' e { $$ = buildtree(ER, $1, $3); } - | e '&' e { $$ = buildtree(AND, $1, $3); } - | e C_EQUOP e { $$ = buildtree($2, $1, $3); } - | e C_RELOP e { $$ = buildtree($2, $1, $3); } - | e C_SHIFTOP e { $$ = buildtree($2, $1, $3); } - | e '+' e { $$ = buildtree(PLUS, $1, $3); } - | e '-' e { $$ = buildtree(MINUS, $1, $3); } - | e C_DIVOP e { $$ = buildtree($2, $1, $3); } - | e '*' e { $$ = buildtree(MUL, $1, $3); } - | e '=' addrlbl { $$ = buildtree(ASSIGN, $1, $3); } + | e C_OROR e { $$ = biop($2, $1, $3); } + | e C_ANDAND e { $$ = biop($2, $1, $3); } + | e '|' e { $$ = biop(OR, $1, $3); } + | e '^' e { $$ = biop(ER, $1, $3); } + | e '&' e { $$ = biop(AND, $1, $3); } + | e C_EQUOP e { $$ = biop($2, $1, $3); } + | e C_RELOP e { $$ = biop($2, $1, $3); } + | e C_SHIFTOP e { $$ = biop($2, $1, $3); } + | e '+' e { $$ = biop(PLUS, $1, $3); } + | e '-' e { $$ = biop(MINUS, $1, $3); } + | e C_DIVOP e { $$ = biop($2, $1, $3); } + | e '*' e { $$ = biop(MUL, $1, $3); } + | e '=' addrlbl { $$ = biop(ASSIGN, $1, $3); } | term ; +xbegin: begin { + $$ = getlab(); getlab(); getlab(); + branch($$); plabel(($$)+1); } + ; + addrlbl: C_ANDAND C_NAME { #ifdef GCC_COMPAT struct symtab *s = lookup($2, SLBLNAME); if (s->soffset == 0) s->soffset = -getlab(); - spname = s; - $$ = buildtree(ADDROF, buildtree(NAME, NIL, NIL), NIL); + $$ = buildtree(ADDROF, nametree(s), NIL); #else uerror("gcc extension"); #endif } ; -term: term C_INCOP { $$ = buildtree( $2, $1, bcon(1) ); } - | '*' term { $$ = buildtree(UMUL, $2, NIL); } - | '&' term { - if( ISFTN($2->n_type) || ISARY($2->n_type) ){ -#ifdef notdef - werror( "& before array or function: ignored" ); -#endif - $$ = $2; - } else - $$ = buildtree(ADDROF, $2, NIL); - } - | '-' term { $$ = buildtree(UMINUS, $2, NIL ); } +term: term C_INCOP { $$ = biop($2, $1, bcon(1)); } + | '*' term { $$ = biop(UMUL, $2, NIL); } + | '&' term { $$ = biop(ADDROF, $2, NIL); } + | '-' term { $$ = biop(UMINUS, $2, NIL ); } | '+' term { $$ = $2; } - | C_UNOP term { $$ = buildtree( $1, $2, NIL ); } + | C_UNOP term { $$ = biop($1, $2, NIL); } | C_INCOP term { - $$ = buildtree($1 == INCR ? PLUSEQ : MINUSEQ, - $2, bcon(1)); + $$ = biop($1 == INCR ? PLUSEQ : MINUSEQ, $2, bcon(1)); } - | C_SIZEOF term { $$ = doszof($2); } + | C_SIZEOF term { $$ = biop(SZOF, $2, bcon(0)); } | '(' cast_type ')' term %prec C_INCOP { - $$ = buildtree(CAST, $2, $4); - nfree($$->n_left); - nfree($$); - $$ = $$->n_right; + $$ = biop(CAST, $2, $4); } | C_SIZEOF '(' cast_type ')' %prec C_SIZEOF { - $$ = doszof($3); + $$ = biop(SZOF, $3, bcon(1)); } - | '(' cast_type ')' clbrace init_list '}' { + | '(' cast_type ')' clbrace init_list optcomma '}' { + uerror("compound literals"); endinit(); - spname = $4; - $$ = buildtree(NAME, NIL, NIL); - } - | term '[' e ']' { - $$ = buildtree( UMUL, - buildtree( PLUS, $1, $3 ), NIL ); - } - | funct_idn ')' { $$ = doacall($1, NIL); } - | funct_idn elist ')' { $$ = doacall($1, $2); } - | term C_STROP C_NAME { $$ = structref($1, $2, $3); } - | term C_STROP C_TYPENAME { $$ = structref($1, $2, $3); } - | C_NAME { - spname = lookup($1, 0); - /* recognize identifiers in initializations */ - if (blevel==0 && spname->stype == UNDEF) { - register NODE *q; - werror("undeclared initializer name %s", - spname->sname); - q = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); - q->n_sp = spname; - defid(q, EXTERN); - nfree(q); - } - if (spname->sflags & SINLINE) - inline_ref($1); - $$ = buildtree(NAME, NIL, NIL); - spname->suse = -lineno; - if (spname->sflags & SDYNARRAY) - $$ = buildtree(UMUL, $$, NIL); + $$ = nametree($4); } + | term '[' e ']' { $$ = biop(LB, $1, $3); } + | C_NAME '(' elist ')' { + $$ = biop($3 ? CALL : UCALL, bdty(NAME, $1), $3); + } + | term '(' elist ')' { $$ = biop($3 ? CALL : UCALL, $1, $3); } + | term C_STROP C_NAME { $$ = biop($2, $1, bdty(NAME, $3)); } + | term C_STROP C_TYPENAME { $$ = biop($2, $1, bdty(NAME, $3));} + | C_NAME %prec C_SIZEOF /* below ( */{ $$ = bdty(NAME, $1); } | C_ICON { $$ = $1; } | C_FCON { $$ = $1; } - | string { $$ = strend($1); /* get string contents */ } - | wstring { $$ = wstrend($1); } + | string { $$ = bdty(STRING, $1, widestr); } | '(' e ')' { $$=$2; } + | '(' xbegin block_item_list e ';' '}' ')' { + branch(($2)+2); + plabel($2); + $$ = biop(COMOP, biop(GOTO, bcon(($2)+1), NIL), $4); + $$->n_type = $4->n_type; /* XXX type checking ? */ + $$->n_sue = $4->n_sue; /* XXX type checking ? */ + $$->n_df = $4->n_df; /* XXX type checking ? */ + flend(); + } ; clbrace: '{' { $$ = clbrace($-1); } ; -string: C_STRING { - int len = strlen($1) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - } - | string C_STRING { - int len = strlen($1) + strlen($2) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - strlcat($$, $2, len); - } - ; - -wstring: C_WSTRING { - int len = strlen($1) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - } - | string C_WSTRING { - int len = strlen($1) + strlen($2) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - strlcat($$, $2, len); - } +string: C_STRING { widestr = $1[0] == 'L'; $$ = stradd("", $1); } + | string C_STRING { $$ = stradd($1, $2); } ; cast_type: specifier_qualifier_list { @@ -1027,25 +1093,9 @@ $$ = tymerge($1, $2); nfree($1); } + /*COMPAT_GCC*/ | typeof { $$ = $1; $$->n_op = NAME; } ; -funct_idn: C_NAME '(' { - struct symtab *s = lookup($1, 0); - if (s->stype == UNDEF) { - register NODE *q; - q = block(NAME, NIL, NIL, FTN|INT, 0, MKSUE(INT)); - q->n_sp = s; - defid(q, EXTERN); - nfree(q); - } - if (s->sflags & SINLINE) - inline_ref($1); - spname = s; - $$ = buildtree(NAME, NIL, NIL); - s->suse = -lineno; - } - | term '(' - ; %% NODE * @@ -1058,10 +1108,11 @@ bdty(int op, ...) { va_list ap; + int val; register NODE *q; va_start(ap, op); - q = block(op, NIL, NIL, INT, 0, MKSUE(INT)); + q = biop(op, NIL, NIL); switch (op) { case UMUL: @@ -1077,13 +1128,22 @@ case LB: q->n_left = va_arg(ap, NODE *); - q->n_right = bcon(va_arg(ap, int)); + if ((val = va_arg(ap, int)) <= 0) { + uerror("array size must be positive"); + val = 1; + } + q->n_right = bcon(val); break; case NAME: q->n_sp = va_arg(ap, struct symtab *); /* XXX survive tymerge */ break; + case STRING: + q->n_name = va_arg(ap, char *); + q->n_lval = va_arg(ap, int); + break; + default: cerror("bad bdty"); } @@ -1093,6 +1153,25 @@ } static void +flend(void) +{ + if (sspflag && blevel == 2) + sspend(); +#ifdef STABS + if (gflag && blevel > 2) + stabs_rbrac(blevel); +#endif + --blevel; + if( blevel == 1 ) + blevel = 0; + symclear(blevel); /* Clean ut the symbol table */ + if (autooff > maxautooff) + maxautooff = autooff; + autooff = savctx->contlab; + savctx = savctx->next; +} + +static void savebc(void) { struct savbc *bc = tmpalloc(sizeof(struct savbc)); @@ -1120,6 +1199,7 @@ struct swents *ents; /* Linked sorted list of case entries */ int nents; /* # of entries in list */ int num; /* Node value will end up in */ + TWORD type; /* Type of switch expression */ } *swpole; /* @@ -1128,7 +1208,8 @@ static void addcase(NODE *p) { - struct swents *w, *sw = tmpalloc(sizeof(struct swents)); + struct swents **put, *w, *sw = tmpalloc(sizeof(struct swents)); + CONSZ val; p = optim(p); /* change enum to ints */ if (p->n_op != ICON || p->n_sp != NULL) { @@ -1140,40 +1221,55 @@ return; } + if (DEUNSIGN(swpole->type) != DEUNSIGN(p->n_type)) { + val = p->n_lval; + p = makety(p, swpole->type, 0, 0, MKSUE(swpole->type)); + if (p->n_op != ICON) + cerror("could not cast case value to type of switch " + "expression"); + if (p->n_lval != val) + werror("case expression truncated"); + } sw->sval = p->n_lval; - plabel( sw->slab = getlab()); - w = swpole->ents; - if (swpole->ents == NULL) { - sw->next = NULL; - swpole->ents = sw; - } else if (swpole->ents->next == NULL) { - if (swpole->ents->sval == sw->sval) { - uerror("duplicate case in switch"); - } else if (swpole->ents->sval < sw->sval) { - sw->next = NULL; - swpole->ents->next = sw; - } else { - sw->next = swpole->ents; - swpole->ents = sw; - } + tfree(p); + put = &swpole->ents; + if (ISUNSIGNED(swpole->type)) { + for (w = swpole->ents; + w != NULL && (U_CONSZ)w->sval < (U_CONSZ)sw->sval; + w = w->next) + put = &w->next; } else { - while (w->next->next != NULL && w->next->sval < sw->sval) { - w = w->next; - } - if (w->next->sval == sw->sval) { - uerror("duplicate case in switch"); - } else if (w->next->sval > sw->sval) { - sw->next = w->next; - w->next = sw; - } else { - sw->next = NULL; - w->next->next = sw; - } + for (w = swpole->ents; w != NULL && w->sval < sw->sval; + w = w->next) + put = &w->next; } + if (w != NULL && w->sval == sw->sval) { + uerror("duplicate case in switch"); + return; + } + plabel(sw->slab = getlab()); + *put = sw; + sw->next = w; swpole->nents++; - tfree(p); } +#ifdef GCC_COMPAT +void +gcccase(NODE *ln, NODE *hn) +{ + CONSZ i, l, h; + + l = icons(optim(ln)); + h = icons(optim(hn)); + + if (h < l) + i = l, l = h, h = i; + + for (i = l; i <= h; i++) + addcase(xbcon(i, NULL, hn->n_type)); +} +#endif + /* * add default case to switch */ @@ -1189,7 +1285,7 @@ } static void -swstart(int num) +swstart(int num, TWORD type) { struct swdef *sw = tmpalloc(sizeof(struct swdef)); @@ -1197,6 +1293,7 @@ sw->ents = NULL; sw->next = swpole; sw->num = num; + sw->type = type; swpole = sw; } @@ -1219,12 +1316,44 @@ swp[i] = swpole->ents; swpole->ents = swpole->ents->next; } - genswitch(swpole->num, swp, swpole->nents); + genswitch(swpole->num, swpole->type, swp, swpole->nents); swpole = swpole->next; } /* + * num: tempnode the value of the switch expression is in + * type: type of the switch expression + * + * p points to an array of structures, each consisting + * of a constant value and a label. + * The first is >=0 if there is a default label; + * its value is the label number + * The entries p[1] to p[n] are the nontrivial cases + * n is the number of case statements (length of list) + */ +static void +genswitch(int num, TWORD type, struct swents **p, int n) +{ + NODE *r, *q; + int i; + + if (mygenswitch(num, type, p, n)) + return; + + /* simple switch code */ + for (i = 1; i <= n; ++i) { + /* already in 1 */ + r = tempnode(num, type, 0, MKSUE(type)); + q = xbcon(p[i]->sval, NULL, type); + r = buildtree(NE, r, clocal(q)); + cbranch(buildtree(NOT, r, NIL), bcon(p[i]->slab)); + } + if (p[0]->slab > 0) + branch(p[0]->slab); +} + +/* * Declare a variable or prototype. */ static struct symtab * @@ -1240,10 +1369,11 @@ typ->n_sp->sflags |= SINLINE; if (ISFTN(typ->n_type) == 0) { - setloc1(DATA); if (assign) { defid(typ, class); typ->n_sp->sflags |= SASG; + if (typ->n_sp->sflags & SDYNARRAY) + uerror("can't initialize dynamic arrays"); lcommdel(typ->n_sp); } else { nidcl(typ, class); @@ -1258,6 +1388,24 @@ } /* + * Declare function arguments. + */ +static void +funargs(NODE *p) +{ + if (p->n_op == ELLIPSIS) + return; + if (oldstyle) { + p->n_op = TYPE; + p->n_type = FARG; + } + p->n_sp = lookup((char *)p->n_sp, 0);/* XXX */ + if (ISFTN(p->n_type)) + p->n_type = INCREF(p->n_type); + defid(p, PARAM); +} + +/* * Declare a function. */ static void @@ -1265,14 +1413,29 @@ { extern int prolab; struct symtab *s; + NODE *q = p; int class = tp->n_lval, oclass; char *c; - setloc1(PROG); - /* Enter function args before they are clobbered in tymerge() */ - /* Typecheck against prototype will be done in defid(). */ - ftnarg(p); + for (q = p; coptype(q->n_op) != LTYPE && q->n_left->n_op != NAME; + q = q->n_left) + ; + if (q->n_op != CALL && q->n_op != UCALL) { + uerror("invalid function definition"); + p = bdty(UCALL, p); + } + + argoff = ARGINIT; + ctval = tvaloff; + blevel++; + + if (q->n_op == CALL && q->n_right->n_type != VOID) { + /* declare function arguments */ + listf(q->n_right, funargs); + ftnarg(q); + } + blevel--; tymerge(tp, p); s = p->n_sp = lookup((char *)p->n_sp, 0); /* XXX */ @@ -1280,26 +1443,22 @@ if (class == STATIC && oclass == EXTERN) werror("%s was first declared extern, then static", s->sname); - if ((oclass == SNULL || oclass == USTATIC) && - class == STATIC && fun_inline) { - /* Unreferenced, store it for (eventual) later use */ - /* Ignore it if it not declared static */ + if (fun_inline) { + /* special syntax for inline functions */ s->sflags |= SINLINE; - inline_start(s->sname); - } - if (class == EXTERN) + inline_start(s); + if (class == EXTERN) + class = EXTDEF; + } else if (class == EXTERN) class = SNULL; /* same result */ cftnsp = s; defid(p, class); prolab = getlab(); - c = cftnsp->sname; -#ifdef GCC_COMPAT - c = gcc_findname(cftnsp); -#endif - send_passt(IP_PROLOG, -1, -1, c, cftnsp->stype, - cftnsp->sclass == EXTDEF, prolab); - blevel = 1; + c = cftnsp->soname; + send_passt(IP_PROLOG, -1, c, cftnsp->stype, + cftnsp->sclass == EXTDEF, prolab, ctval); + blevel++; #ifdef STABS if (gflag) stabs_func(s); @@ -1326,9 +1485,10 @@ if (f == DOT) p = buildtree(ADDROF, p, NIL); - r = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + r = biop(NAME, NIL, NIL); r->n_name = name; - return buildtree(STREF, p, r); + r = buildtree(STREF, p, r); + return r; } static void @@ -1351,7 +1511,7 @@ branch(int lbl) { int r = reached++; - ecomp(block(GOTO, bcon(lbl), NIL, INT, 0, 0)); + ecomp(biop(GOTO, bcon(lbl), NIL)); reached = r; } @@ -1362,9 +1522,10 @@ mkpstr(char *str) { char *s, *os; - int v, l = strlen(str)+1; + int v, l = strlen(str)+3; /* \t + \n + \0 */ - os = s = isinlining ? permalloc(l) : tmpalloc(l); + os = s = inlalloc(l); + *s++ = '\t'; for (; *str; ) { if (*str++ == '\\') v = esccon(&str); @@ -1372,29 +1533,365 @@ v = str[-1]; *s++ = v; } + *s++ = '\n'; *s = 0; return os; } +/* + * Estimate the max length a string will have in its internal + * representation based on number of \ characters. + */ +static int +maxstlen(char *str) +{ + int i; + + for (i = 0; *str; str++, i++) + if (*str == '\\' || *str < 32 || *str > 0176) + i += 3; + return i; +} + +static char * +voct(char *d, unsigned int v) +{ + v &= (1 << SZCHAR) - 1; + *d++ = '\\'; + *d++ = v/64 + '0'; v &= 077; + *d++ = v/8 + '0'; v &= 7; + *d++ = v + '0'; + return d; +} + + +/* + * Convert a string to internal format. The resulting string may be no + * more than len characters long. + */ +static void +fixstr(char *d, char *s, int len) +{ + unsigned int v; + + while (*s) { + if (len <= 0) + cerror("fixstr"); + if (*s == '\\') { + s++; + v = esccon(&s); + d = voct(d, v); + len -= 4; + } else if (*s < ' ' || *s > 0176) { + d = voct(d, *s++); + len -= 4; + } else + *d++ = *s++, len--; + } + *d = 0; +} + +/* + * Add "raw" string new to cleaned string old. + */ +static char * +stradd(char *old, char *new) +{ + char *rv; + int len; + + if (*new == 'L' && new[1] == '\"') + widestr = 1, new++; + if (*new == '\"') { + new++; /* remove first " */ + new[strlen(new) - 1] = 0;/* remove last " */ + } + len = strlen(old) + maxstlen(new) + 1; + rv = tmpalloc(len); + strlcpy(rv, old, len); + fixstr(rv + strlen(old), new, maxstlen(new) + 1); + return rv; +} + static struct symtab * clbrace(NODE *p) { struct symtab *sp; - if (blevel == 0 && xnf != NULL) - cerror("no level0 compound literals"); - - sp = getsymtab("cl", STEMP); + sp = getsymtab(simname("cl"), STEMP); + if (blevel == 0 && xnf != NULL) { + sp->sclass = STATIC; + sp->slevel = 2; + sp->soffset = getlab(); + } else { + sp->sclass = blevel ? AUTO : STATIC; + if (!ISARY(sp->stype) || sp->sdf->ddim != NOOFFSET) { + sp->soffset = NOOFFSET; + oalloc(sp, &autooff); + } + } sp->stype = p->n_type; sp->squal = p->n_qual; sp->sdf = p->n_df; sp->ssue = p->n_sue; - sp->sclass = blevel ? AUTO : STATIC; - if (!ISARY(sp->stype) || sp->sdf->ddim != 0) { - sp->soffset = NOOFFSET; - oalloc(sp, &autooff); - } tfree(p); beginit(sp); return sp; } + +char * +simname(char *s) +{ + int len = strlen(s) + 10 + 1; + char *w = tmpalloc(len); + + snprintf(w, len, "%s%d", s, getlab()); + return w; +} + +NODE * +biop(int op, NODE *l, NODE *r) +{ + return block(op, l, r, INT, 0, MKSUE(INT)); +} + +static NODE * +cmop(NODE *l, NODE *r) +{ + return biop(CM, l, r); +} + +static NODE * +voidcon(void) +{ + return block(ICON, NIL, NIL, STRTY, 0, MKSUE(VOID)); +} + +/* Support for extended assembler a' la' gcc style follows below */ + +static NODE * +xmrg(NODE *out, NODE *in) +{ + NODE *p = in; + + if (p->n_op == XARG) { + in = cmop(out, p); + } else { + while (p->n_left->n_op == CM) + p = p->n_left; + p->n_left = cmop(out, p->n_left); + } + return in; +} + +/* + * Put together in and out node lists in one list, and balance it with + * the constraints on the right side of a CM node. + */ +static NODE * +xcmop(NODE *out, NODE *in, NODE *str) +{ + NODE *p, *q; + + if (out) { + /* D out-list sanity check */ + for (p = out; p->n_op == CM; p = p->n_left) { + q = p->n_right; + if (q->n_name[0] != '=' && q->n_name[0] != '+') + uerror("output missing ="); + } + if (p->n_name[0] != '=' && p->n_name[0] != '+') + uerror("output missing ="); + if (in == NIL) + p = out; + else + p = xmrg(out, in); + } else if (in) { + p = in; + } else + p = voidcon(); + + if (str == NIL) + str = voidcon(); + return cmop(p, str); +} + +/* + * Generate a XARG node based on a string and an expression. + */ +static NODE * +xasmop(char *str, NODE *p) +{ + + p = biop(XARG, p, NIL); + p->n_name = isinlining ? newstring(str, strlen(str)+1) : str; + return p; +} + +/* + * Generate a XASM node based on a string and an expression. + */ +static void +mkxasm(char *str, NODE *p) +{ + NODE *q; + + q = biop(XASM, p->n_left, p->n_right); + q->n_name = isinlining ? newstring(str, strlen(str)+1) : str; + nfree(p); + ecomp(q); +} + +#ifdef GCC_COMPAT +static NODE * +tyof(NODE *p) +{ + static struct symtab spp; + NODE *q = block(TYPE, NIL, NIL, p->n_type, 0, 0); + q->n_qual = p->n_qual; + q->n_sp = &spp; /* for typenode */ + tfree(p); + return q; +} +#endif + +/* + * Traverse an unhandled expression tree bottom-up and call buildtree() + * or equivalent as needed. + */ +NODE * +eve(NODE *p) +{ + struct symtab *sp; + NODE *r, *p1, *p2; + r = NULL; + + p1 = p->n_left; + p2 = p->n_right; + switch (p->n_op) { + case NAME: + sp = lookup((char *)p->n_sp, 0); + if (sp->sflags & SINLINE) + inline_ref(sp); + r = nametree(sp); + if (sp->sflags & SDYNARRAY) + r = buildtree(UMUL, r, NIL); + break; + + case DOT: + case STREF: + r = structref(eve(p1), p->n_op, (char *)p2->n_sp); + nfree(p2); + break; + + case CAST: + p1 = buildtree(CAST, p1, eve(p2)); + nfree(p1->n_left); + r = p1->n_right; + nfree(p1); + break; + + + case SZOF: + if (p2->n_lval == 0) + p1 = eve(p1); + nfree(p2); + r = doszof(p1); + break; + + case LB: + p1 = eve(p->n_left); + r = buildtree(UMUL, buildtree(PLUS, p1, eve(p2)), NIL); + break; + + case COMPL: + case UMINUS: + case NOT: + case UMUL: + r = buildtree(p->n_op, eve(p->n_left), NIL); + break; + + case ADDROF: + r = eve(p1); + if (ISFTN(p->n_type)/* || ISARY(p->n_type) */){ +#ifdef notdef + werror( "& before array or function: ignored" ); +#endif + } else + r = buildtree(ADDROF, r, NIL); + break; + + case CALL: + p2 = eve(p2); + /* FALLTHROUGH */ + case UCALL: + if (p1->n_op == NAME) { + sp = lookup((char *)p1->n_sp, 0); + if (sp->stype == UNDEF) { + p1->n_type = FTN|INT; + p1->n_sp = sp; + defid(p1, EXTERN); + } + nfree(p1); + r = doacall(sp, nametree(sp), p2); + } else + r = doacall(NULL, eve(p1), p2); + break; + + case INCR: + case DECR: + case CM: + case GT: + case GE: + case LT: + case LE: + case EQ: + case NE: + case RS: + case LS: + case RSEQ: + case LSEQ: + case AND: + case OR: + case ER: + case MUL: + case DIV: + case MOD: + case PLUS: + case MINUS: + case OROR: + case ANDAND: + case EREQ: + case OREQ: + case ANDEQ: + case MINUSEQ: + case PLUSEQ: + case MULEQ: + case DIVEQ: + case MODEQ: + case COMOP: + case QUEST: + case COLON: + case ASSIGN: + p1 = eve(p1); + r = buildtree(p->n_op, p1, eve(p2)); + break; + + case STRING: + r = strend(p->n_lval, p->n_name); + break; + + case TYPE: + case ICON: + case FCON: + return p; + + default: +#ifdef PCC_DEBUG + fwalk(p, eprint, 0); +#endif + cerror("eve"); + } + nfree(p); + return r; +} Index: ccom.1 =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/ccom.1,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/ccom.1 -L usr.bin/pcc/ccom/ccom.1 -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/ccom.1 +++ usr.bin/pcc/ccom/ccom.1 @@ -1,39 +1,43 @@ -.\" $Id: ccom.1,v 1.2 2007/09/26 14:48:49 ragge Exp $ .\" $NetBSD$ -.\" $OpenBSD$ +.\" $Id: ccom.1,v 1.8 2008/02/20 01:31:26 gmcgarry Exp $ ."\ .\" Copyright (c) 2007 Jeremy C. Reed -.\" Permission to use, copy, modify, and/or distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above +.\" Permission to use, copy, modify, and/or distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above .\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM -.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND -.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL -.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR -.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS -.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM +.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND +.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS +.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF .\" THIS SOFTWARE. .Dd September 14, 2007 -.Dt ccom 1 +.Dt CCOM 1 .Os .Sh NAME .Nm ccom .Nd C compiler .Sh SYNOPSIS .Nm +.Op Fl gs +.Op Fl W Ar flags .Op Fl X Ar flags +.Op Fl x Ar optimizations +.Op Fl Z Ar flags .Op infile .Op outfile -.Pp .Sh DESCRIPTION The .Nm utility provides a C compiler. The frontend is usually .Xr pcc 1 . -It is \fBnot\fR intended to be run directly. +It is +.Em not +intended to be run directly. .Pp .Nm reads the C source from @@ -48,6 +52,8 @@ .It Fl g Enable debugging. .\" built into binary, explain stabs? +.It Fl k +Generate PIC code. .It Fl s Print statistics to standard error when complete. This includes: @@ -56,81 +62,112 @@ dimension/function unions, struct/union/enum blocks, inline node count, inline control blocks, and permanent symtab entries. .\" TODO: explain units for above? +.It Fl v +Display version. .It Fl W Ar flags Report warnings. (Do some basic checks.) -NOTE! These are subject to change RSN! -.Ar Flags +.Em NOTE! +.Em These are subject to change RSN! +.Ar flags is one or more of the following: .Bl -tag -width Ds +.It Sy error +Report all warnings as errors. .It Sy implicit Implies -.Sy implicit-int +.Sy implicit-function-declaration and -.Sy implicit-function-declaration . +.Sy implicit-int . +.It Sy implicit-function-declaration +Report if no prototype was declared for a function. .It Sy implicit-int TODO -.It Sy implicit-function-declaration -Report if no prototype for function. .It Sy missing-prototypes TODO .It Sy strict-prototypes TODO +.It Sy W +Enable all warnings. +.El +.\" +.It Fl X Ar flags +C specific debugging where +.Ar flags +is one or more of the following: +.Bl -tag -width Ds +.It Sy b +Building of parse trees +.It Sy d +Declarations (using multiple +.Sy d +flags gives more output) +.It Sy e +Pass1 trees at exit +.It Sy i +Initializations +.It Sy n +Memory allocations +.It Sy o +Turn off optimisations +.It Sy p +Prototypes +.It Sy s +Inlining +.It Sy t +Type conversions +.It Sy x +Target-specific flag, used in machine-dependent code .El .\" .It Fl x Ar optimizations .Ar optimizations -is one or more of the following: +is one of the following: +.\" TODO: reword this, since multiple terms don't go with one -x switch?? .Bl -tag -width deljumps .It Sy deljumps Delete redundant jumps and dead code. .It Sy ssa -Convert statements into SSA form for optimization. Not yet finished. +Convert statements into SSA form for optimization. +Not yet finished. .It Sy tailcall Currently not implemented. .It Sy temps -Setting this flag allow variables to be put into registers, for further +Setting this flag allows variables to be put into registers, for further optimization by the register allocator. .El +The +.Fl x +flag can be passed multiple times to set different options. .\" -.It Fl X Ar C specific debugging flags -.Ar Flags +.It Fl Z Ar flags +Code generator (pass2) specific debugging where +.Ar flags is one or more of the following: .Bl -tag -width Ds .It Sy b -Building of parse trees -.It Sy d -Declarations, more d gives more output -.It Sy t -Type conversions -.It Sy i -Initializations -.It Sy e -Pass1 trees at exit -.It Sy x -Target-specific flag, used in machine-dependent code -.El -.\" -.It Fl Z Ar Code generator (pass2) specific debugging flags -.Ar Flags -is one or more of the following: -.Bl -tag -width Ds +Basic block and SSA building +.It Sy c +Code printout .It Sy e Trees when entering pass2 -.It Sy o -Instruction generator .It Sy f Instruction matcher, may provide much output +.It Sy n +Memory allocation +.It Sy o +Instruction generator .It Sy r Register allocator -.It Sy t -Type matching in instruction generator .It Sy s Shape matching in instruction generator +.It Sy t +Type matching in instruction generator .It Sy u Sethi-Ullman computations .It Sy x -Target-specific flag, used in machine-dependent code +Target-specific flag, used in machine-dependent code +.El .El .Sh SEE ALSO .Xr as 1 , @@ -139,8 +176,8 @@ .Sh HISTORY The .Nm -compiler is based on the original Portable C Compiler by S. C. -Johnson, written in the late 70's. +compiler is based on the original Portable C Compiler by S. C. Johnson, +written in the late 70's. Even though much of the compiler has been rewritten, some of the basics still remain. About 50% of the frontend code and 80% of the backend code has been @@ -148,5 +185,8 @@ Most is written by Anders Magnusson, with the exception of the data-flow analysis part and the SSA conversion code which is written by Peter A Jonsson, and the Mips port that were written as -part of a project by undergraduate students at Lulea University of +part of a project by undergraduate students at Lulea University of Technology. +.Pp +This product includes software developed or owned by Caldera +International, Inc. Index: trees.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/trees.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/trees.c -L usr.bin/pcc/ccom/trees.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/trees.c +++ usr.bin/pcc/ccom/trees.c @@ -1,4 +1,4 @@ -/* $Id: trees.c,v 1.163 2007/09/16 08:26:39 ragge Exp $ */ +/* $Id: trees.c,v 1.223 2008/12/14 21:15:24 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -70,14 +70,16 @@ # include "pass2.h" # include +# include static void chkpun(NODE *p); static int opact(NODE *p); static int moditype(TWORD); static NODE *strargs(NODE *); static void rmcops(NODE *p); - -int lastloc = -1; +static void putjops(NODE *, void *); +static struct symtab *findmember(struct symtab *, char *); +int inftn; /* currently between epilog/prolog */ /* some special actions, used in finding the type of nodes */ # define NCVT 01 @@ -107,6 +109,8 @@ */ int bdebug = 0; +extern int negrel[]; + NODE * buildtree(int o, NODE *l, NODE *r) @@ -116,8 +120,6 @@ int opty; struct symtab *sp = NULL; /* XXX gcc */ NODE *lr, *ll; - char *name; - struct symtab **elem; #ifdef PCC_DEBUG if (bdebug) { @@ -143,23 +145,23 @@ } else if (o == NOT && l->n_op == FCON) { l = clocal(block(SCONV, l, NIL, INT, 0, MKSUE(INT))); } else if( o == UMINUS && l->n_op == FCON ){ - l->n_dcon = -l->n_dcon; + l->n_dcon = FLOAT_NEG(l->n_dcon); return(l); } else if( o==QUEST && l->n_op==ICON ) { CONSZ c = l->n_lval; nfree(l); if (c) { + walkf(r->n_right, putjops, 0); tfree(r->n_right); l = r->n_left; - nfree(r); - return(l); } else { + walkf(r->n_left, putjops, 0); tfree(r->n_left); l = r->n_right; - nfree(r); - return(l); } + nfree(r); + return(l); } else if( opty == BITYPE && l->n_op == ICON && r->n_op == ICON ){ switch( o ){ @@ -199,9 +201,11 @@ case ER: case LS: case RS: - if( conval( l, o, r ) ) { - nfree(r); - return(l); + if (!ISPTR(l->n_type) && !ISPTR(r->n_type)) { + if( conval( l, o, r ) ) { + nfree(r); + return(l); + } } break; } @@ -214,21 +218,24 @@ case MUL: case DIV: if (l->n_op == ICON) - l->n_dcon = l->n_lval; + l->n_dcon = FLOAT_CAST(l->n_lval, l->n_type); if (r->n_op == ICON) - r->n_dcon = r->n_lval; + r->n_dcon = FLOAT_CAST(r->n_lval, r->n_type); switch (o) { case PLUS: - l->n_dcon += r->n_dcon; break; + l->n_dcon = FLOAT_PLUS(l->n_dcon, r->n_dcon); + break; case MINUS: - l->n_dcon -= r->n_dcon; break; + l->n_dcon = FLOAT_MINUS(l->n_dcon, r->n_dcon); + break; case MUL: - l->n_dcon *= r->n_dcon; break; + l->n_dcon = FLOAT_MUL(l->n_dcon, r->n_dcon); + break; case DIV: - if (r->n_dcon == 0) - uerror("division by 0."); - else - l->n_dcon /= r->n_dcon; + if (FLOAT_ISZERO(r->n_dcon)) + goto runtime; + l->n_dcon = FLOAT_DIV(l->n_dcon, r->n_dcon); + break; } l->n_op = FCON; l->n_type = DOUBLE; @@ -237,7 +244,7 @@ return(l); } } - +runtime: /* its real; we must make a new node */ p = block(o, l, r, INT, 0, MKSUE(INT)); @@ -247,6 +254,8 @@ if (actions & LVAL) { /* check left descendent */ if (notlval(p->n_left)) { uerror("lvalue required"); + nfree(p); + return l; #ifdef notyet } else { if ((l->n_type > BTMASK && ISCON(l->n_qual)) || @@ -296,53 +305,7 @@ switch(o){ case NAME: - sp = spname; - if (sp->sflags & STNODE) { - /* Generated for optimizer */ - p->n_op = TEMP; - p->n_type = sp->stype; - p->n_sue = sp->ssue; - p->n_df = sp->sdf; - p->n_lval = sp->soffset; - break; - } - -#ifdef GCC_COMPAT - /* Get a label name */ - if (sp->sflags == SLBLNAME) { - p->n_type = VOID; - p->n_sue = MKSUE(VOID); - p->n_lval = 0; - p->n_sp = sp; - break; - } else -#endif - if (sp->stype == UNDEF) { - uerror("%s undefined", sp->sname); - /* make p look reasonable */ - p->n_type = INT; - p->n_sue = MKSUE(INT); - p->n_df = NULL; - p->n_sp = sp; - p->n_lval = 0; - defid(p, SNULL); - break; - } - p->n_type = sp->stype; - p->n_qual = sp->squal; - p->n_df = sp->sdf; - p->n_sue = sp->ssue; - p->n_lval = 0; - p->n_sp = sp; - /* special case: MOETY is really an ICON... */ - if (p->n_type == MOETY) { - p->n_sp = NULL; - p->n_lval = sp->soffset; - p->n_df = NULL; - p->n_type = ENUMTY; - p->n_op = ICON; - } - break; + cerror("buildtree NAME"); case STREF: /* p->x turned into *(p+offset) */ @@ -354,17 +317,23 @@ break; } - if ((elem = l->n_sue->suelem) == NULL) + if ((sp = l->n_sue->sylnk) == NULL) { uerror("undefined struct or union"); + break; + } + sp = findmember(sp, r->n_name); +#ifdef notdef name = r->n_name; - for (; *elem != NULL; elem++) { - sp = *elem; + for (; sp != NULL; sp = sp->snext) { if (sp->sname == name) break; } - if (*elem == NULL) - uerror("member '%s' not declared", name); +#endif + if (sp == NULL) { + uerror("member '%s' not declared", r->n_name); + break; + } r->n_sp = sp; p = stref(p); @@ -453,7 +422,7 @@ TWORD t; union dimfun *d; - if (l->n_sue != r->n_sue) + if (l->n_sue->sylnk != r->n_sue->sylnk) uerror("assignment of different structures"); r = buildtree(ADDROF, r, NIL); @@ -462,6 +431,7 @@ sue = r->n_sue; l = block(STASG, l, r, t, d, sue); + l = clocal(l); if( o == RETURN ){ nfree(p); @@ -483,6 +453,8 @@ case CALL: p->n_right = r = strargs(p->n_right); + p = funcode(p); + /* FALLTHROUGH */ case UCALL: if (!ISPTR(l->n_type)) uerror("illegal function"); @@ -540,6 +512,88 @@ } +/* Find a member in a struct or union. May be an unnamed member */ +static struct symtab * +findmember(struct symtab *sp, char *s) +{ + struct symtab *sp2, *sp3; + + for (; sp != NULL; sp = sp->snext) { + if (sp->sname[0] == '*') { + /* unnamed member, recurse down */ + if ((sp2 = findmember(sp->ssue->sylnk, s))) { + sp3 = tmpalloc(sizeof (struct symtab)); + *sp3 = *sp2; + sp3->soffset += sp->soffset; + return sp3; + } + } else if (sp->sname == s) + return sp; + } + return NULL; +} + + +/* + * Check if there will be a lost label destination inside of a ?: + * It cannot be reached so just print it out. + */ +static void +putjops(NODE *p, void *arg) +{ + if (p->n_op == COMOP && p->n_left->n_op == GOTO) + plabel(p->n_left->n_left->n_lval+1); +} + +/* + * Build a name node based on a symtab entry. + * broken out from buildtree(). + */ +NODE * +nametree(struct symtab *sp) +{ + NODE *p; + + p = block(NAME, NIL, NIL, sp->stype, sp->sdf, sp->ssue); + p->n_qual = sp->squal; + p->n_sp = sp; + +#ifndef NO_C_BUILTINS + if (sp->sname[0] == '_' && strncmp(sp->sname, "__builtin_", 10) == 0) + return p; /* do not touch builtins here */ + +#endif + + if (sp->sflags & STNODE) { + /* Generated for optimizer */ + p->n_op = TEMP; + p->n_rval = sp->soffset; + } + +#ifdef GCC_COMPAT + /* Get a label name */ + if (sp->sflags == SLBLNAME) { + p->n_type = VOID; + p->n_sue = MKSUE(VOID); + } +#endif + if (sp->stype == UNDEF) { + uerror("%s undefined", sp->sname); + /* make p look reasonable */ + p->n_type = INT; + p->n_sue = MKSUE(INT); + p->n_df = NULL; + defid(p, SNULL); + } + if (sp->sclass == MOE) { + p->n_op = ICON; + p->n_lval = sp->soffset; + p->n_df = NULL; + p->n_sp = NULL; + } + return clocal(p); +} + /* * Do a conditional branch. */ @@ -548,8 +602,10 @@ { p = buildtree(CBRANCH, p, q); if (p->n_left->n_op == ICON) { - if (p->n_left->n_lval != 0) + if (p->n_left->n_lval != 0) { branch(q->n_lval); /* branch always */ + reached = 0; + } tfree(p); tfree(q); return; @@ -714,6 +770,7 @@ * we check that this integer is in fact a constant zero... * in the case of ASSIGN, any assignment of pointer to integer is illegal * this falls out, because the LHS is never 0. + * XXX - check for COMOPs in assignment RHS? */ void chkpun(NODE *p) @@ -743,8 +800,10 @@ return; break; default: - if ((t1 == VOID && t2 != VOID) || (t1 != VOID && t2 == VOID)) - return uerror("value of void expression used"); + if ((t1 == VOID && t2 != VOID) || (t1 != VOID && t2 == VOID)) { + uerror("value of void expression used"); + return; + } break; } @@ -754,26 +813,6 @@ if (BTYPE(t2) == VOID && (t1 & TMASK)) return; -#ifdef notdef - /* C99 says that enums always should be handled as ints */ - /* check for enumerations */ - if (t1==ENUMTY || t2==ENUMTY) { - if( clogop( p->n_op ) && p->n_op != EQ && p->n_op != NE ) { - werror( "comparison of enums" ); - return; - } - if (t1==ENUMTY && t2==ENUMTY) { - if (p->n_left->n_sue!=p->n_right->n_sue) - werror("enumeration type clash, " - "operator %s", copst(p->n_op)); - return; - } - if ((t1 == ENUMTY && t2 <= BTMASK) || - (t2 == ENUMTY && t1 <= BTMASK)) - return; - } -#endif - if (ISPTR(t1) || ISARY(t1)) q = p->n_right; else @@ -786,7 +825,7 @@ d1 = p->n_left->n_df; d2 = p->n_right->n_df; if (t1 == t2) { - if (p->n_left->n_sue != p->n_right->n_sue) + if (p->n_left->n_sue->sylnk != p->n_right->n_sue->sylnk) werror("illegal structure pointer combination"); return; } @@ -815,7 +854,8 @@ t1 = DECREF(t1); t2 = DECREF(t2); } - werror("illegal pointer combination"); + if (Wpointer_sign) + werror("illegal pointer combination"); } } @@ -856,6 +896,21 @@ off = s->soffset; dsc = s->sclass; +#ifndef CAN_UNALIGN + /* + * If its a packed struct, and the target cannot do unaligned + * accesses, then split it up in two bitfield operations. + * LHS and RHS accesses are different, so must delay + * it until we know. Do the bitfield construct here though. + */ + if ((dsc & FIELD) == 0 && (off % talign(s->stype, s->ssue))) { +// int sz = tsize(s->stype, s->sdf, s->ssue); +// int al = talign(s->stype, s->ssue); +// int sz1 = al - (off % al); + + } +#endif + if (dsc & FIELD) { /* make fields look like ints */ off = (off/ALINT)*ALINT; sue = MKSUE(INT); @@ -911,12 +966,18 @@ NODE * bcon(int i) { - register NODE *p; + return xbcon(i, NULL, INT); +} - p = block(ICON, NIL, NIL, INT, 0, MKSUE(INT)); - p->n_lval = i; - p->n_sp = NULL; - return(clocal(p)); +NODE * +xbcon(CONSZ val, struct symtab *sp, TWORD type) +{ + NODE *p; + + p = block(ICON, NIL, NIL, type, 0, MKSUE(type)); + p->n_lval = val; + p->n_sp = sp; + return clocal(p); } NODE * @@ -995,34 +1056,6 @@ return(p); } -/* - * change enums to ints, or appropriate types - */ -void -econvert( p ) register NODE *p; { - - - register TWORD ty; - - if( (ty=BTYPE(p->n_type)) == ENUMTY || ty == MOETY ) { - if (p->n_sue->suesize == SZCHAR) - ty = INT; - else if (p->n_sue->suesize == SZINT) - ty = INT; - else if (p->n_sue->suesize == SZSHORT) - ty = INT; - else if (p->n_sue->suesize == SZLONGLONG) - ty = LONGLONG; - else - ty = LONG; - ty = ctype(ty); - p->n_sue = MKSUE(ty); - MODTYPE(p->n_type,ty); - if (p->n_op == ICON && ty != LONG && ty != LONGLONG) - p->n_type = INT, p->n_sue = MKSUE(INT); - } -} - NODE * pconvert( p ) register NODE *p; { @@ -1049,7 +1082,12 @@ case LT: case GE: case GT: - if( ISUNSIGNED(p->n_left->n_type) || ISUNSIGNED(p->n_right->n_type) ) p->n_op += (ULE-LE); + if(ISUNSIGNED(p->n_left->n_type) || + ISUNSIGNED(p->n_right->n_type) || + ISPTR(p->n_left->n_type) || + ISPTR(p->n_right->n_type)) + p->n_op += (ULE-LE); + /* FALLTHROUGH */ case EQ: case NE: return( p ); @@ -1184,10 +1222,10 @@ t2 = DEUNSIGN(t2); } - if (t1 == ENUMTY || t1 == MOETY) - t1 = INT; /* XXX */ - if (t2 == ENUMTY || t2 == MOETY) - t2 = INT; /* XXX */ + if (Wsign_compare && clogop(o) && t1 == t2 && lu != ru && + p->n_left->n_op != ICON && p->n_right->n_op != ICON) + werror("comparison between signed and unsigned"); + #if 0 if ((t1 == CHAR || t1 == SHORT) && o!= RETURN) t1 = INT; @@ -1266,8 +1304,6 @@ makety(NODE *p, TWORD t, TWORD q, union dimfun *d, struct suedef *sue) { - if (p->n_type == ENUMTY && p->n_op == ICON) - econvert(p); if (t == p->n_type) { p->n_df = d; p->n_sue = sue; @@ -1294,10 +1330,7 @@ if (p->n_op == ICON) { if (t == DOUBLE || t == FLOAT) { p->n_op = FCON; - if (ISUNSIGNED(p->n_type)) - p->n_dcon = (U_CONSZ) p->n_lval; - else - p->n_dcon = p->n_lval; + p->n_dcon = FLOAT_CAST(p->n_lval, p->n_type); p->n_type = t; p->n_qual = q; p->n_sue = MKSUE(t); @@ -1332,20 +1365,21 @@ return(p); } -int -icons(p) register NODE *p; { +/* + * Return the constant value from an ICON. + */ +CONSZ +icons(NODE *p) +{ /* if p is an integer constant, return its value */ - int val; + CONSZ val; - if( p->n_op != ICON ){ + if (p->n_op != ICON || p->n_sp != NULL) { uerror( "constant expected"); val = 1; - } - else { + } else val = p->n_lval; - if( val != p->n_lval ) uerror( "constant too big for cross-compiler" ); - } - tfree( p ); + tfree(p); return(val); } @@ -1382,7 +1416,6 @@ # define MSTR 04 /* structure */ # define MPTR 010 /* pointer */ # define MPTI 020 /* pointer or integer */ -# define MENU 040 /* enumeration variable or member */ int opact(NODE *p) @@ -1428,8 +1461,6 @@ case MUL: case DIV: - if ((mt1&MDBI) && (mt2&MENU)) return( TYMATCH ); - if ((mt2&MDBI) && (mt1&MENU)) return( TYMATCH ); if( mt12 & MDBI ) return( TYMATCH ); break; @@ -1452,13 +1483,12 @@ case GT: case GE: if( mt12 & MDBI ) return( TYMATCH+CVTO ); - else if( mt12 & MPTR ) return( PTMATCH+PUN ); + else if( mt12 & MPTR ) return( PTMATCH+PUN+CVTO ); else if( mt12 & MPTI ) return( PTMATCH+PUN ); else break; case QUEST: case COMOP: - if( mt2&MENU ) return( TYPR+NCVTR ); return( TYPR ); case STREF: @@ -1480,12 +1510,6 @@ if( mt12 & MSTR ) return( LVAL+NCVT+TYPL+OTHER ); case CAST: if( mt12 & MDBI ) return( TYPL+LVAL+TYMATCH ); -#if 0 - else if(mt1&MENU && mt2&MDBI) return( TYPL+LVAL+TYMATCH ); - else if(mt2&MENU && mt1&MDBI) return( TYPL+LVAL+TYMATCH ); - else if( (mt1&MENU)||(mt2&MENU) ) - return( LVAL+NCVT+TYPL+PTMATCH+PUN ); -#endif else if( mt1 & MPTR) return( LVAL+PTMATCH+PUN ); else if( mt12 & MPTI ) return( TYPL+LVAL+TYMATCH+PUN ); break; @@ -1542,10 +1566,6 @@ { switch (ty) { - case ENUMTY: - case MOETY: - return( MENU|MINT|MDBI|MPTI ); - case STRTY: case UNIONTY: return( MSTR ); @@ -1572,7 +1592,7 @@ } } -int tvaloff = 100; +int tvaloff = MAXREGS+NPERMREG > 100 ? MAXREGS+NPERMREG + 100 : 100; /* * Returns a TEMP node with temp number nr. @@ -1584,7 +1604,7 @@ NODE *r; r = block(TEMP, NIL, NIL, type, df, sue); - r->n_lval = nr ? nr : tvaloff; + regno(r) = nr ? nr : tvaloff; tvaloff += szty(type); return r; } @@ -1599,6 +1619,9 @@ TWORD ty; NODE *rv; + if (p->n_op == FLD) + uerror("can't apply sizeof to bit-field"); + /* * Arrays may be dynamic, may need to make computations. */ @@ -1607,6 +1630,8 @@ df = p->n_df; ty = p->n_type; while (ISARY(ty)) { + if (df->ddim == NOOFFSET) + uerror("sizeof of incomplete type"); rv = buildtree(MUL, rv, df->ddim >= 0 ? bcon(df->ddim) : tempnode(-df->ddim, INT, 0, MKSUE(INT))); df++; @@ -1633,40 +1658,51 @@ ty = coptype( p->n_op ); printf("%p) %s, ", p, copst(p->n_op)); + if (p->n_op == XARG || p->n_op == XASM) + printf("id '%s', ", p->n_name); if (ty == LTYPE) { printf(CONFMT, p->n_lval); - printf(", %d, ", p->n_rval); + printf(", %d, ", (p->n_op != NAME && p->n_op != ICON) ? + p->n_rval : 0); } tprint(stdout, p->n_type, p->n_qual); printf( ", %p, %p\n", p->n_df, p->n_sue ); } # endif -void -prtdcon(NODE *p) +/* + * Emit everything that should be emitted on the left side + * of a comma operator, and remove the operator. + * Do not traverse through QUEST, ANDAND and OROR. + * Enable this for all targets when stable enough. + */ +static void +comops(NODE *p) { - int o = p->n_op, i; - - if (o != FCON) - return; - - /* Write float constants to memory */ - /* Should be volontary per architecture */ + int o; + NODE *q; - setloc1(RDATA); - defalign(p->n_type == FLOAT ? ALFLOAT : p->n_type == DOUBLE ? - ALDOUBLE : ALLDOUBLE ); - deflab1(i = getlab()); - ninval(0, btdims[p->n_type].suesize, p); - p->n_op = NAME; - p->n_lval = 0; - p->n_sp = tmpalloc(sizeof(struct symtab_hdr)); - p->n_sp->sclass = ILABEL; - p->n_sp->soffset = i; + while (p->n_op == COMOP) { + /* XXX hack for GCC ({ }) ops */ + if (p->n_left->n_op == GOTO) { + int v = p->n_left->n_left->n_lval; + ecomp(p->n_left); + plabel(v+1); + } else + ecomp(p->n_left); /* will recurse if more COMOPs */ + q = p->n_right; + *p = *q; + nfree(q); + } + o = coptype(p->n_op); + if (p->n_op == QUEST || p->n_op == ANDAND || p->n_op == OROR) + o = UTYPE; + if (o != LTYPE) + comops(p->n_left); + if (o == BITYPE) + comops(p->n_right); } -extern int negrel[]; - /* * Walk up through the tree from the leaves, * removing constant operators. @@ -1815,6 +1851,7 @@ case ANDAND: lab = false<0 ? getlab() : false ; andorbr(p->n_left, -1, lab); + comops(p->n_right); andorbr(p->n_right, true, false); if (false < 0) plabel( lab); @@ -1824,6 +1861,7 @@ case OROR: lab = true<0 ? getlab() : true; andorbr(p->n_left, lab, -1); + comops(p->n_right); andorbr(p->n_right, true, false); if (true < 0) plabel( lab); @@ -1862,9 +1900,18 @@ NODE *q, *r; int o, ty, lbl, lbl2, tval = 0; -again: o = p->n_op; ty = coptype(o); + if (BTYPE(p->n_type) == ENUMTY) { /* fixup enum */ + MODTYPE(p->n_type, p->n_sue->sylnk->stype); + /* + * XXX may fail if these are true: + * - variable-sized enums + * - non-byte-addressed targets. + */ + if (BTYPE(p->n_type) == ENUMTY && ISPTR(p->n_type)) + MODTYPE(p->n_type, INT); /* INT ok? */ + } switch (o) { case QUEST: @@ -1878,9 +1925,10 @@ /* Make ASSIGN node */ /* Only if type is not void */ q = p->n_right->n_left; + comops(q); if (type != VOID) { r = tempnode(0, q->n_type, q->n_df, q->n_sue); - tval = r->n_lval; + tval = regno(r); q = buildtree(ASSIGN, r, q); } rmcops(q); @@ -1889,6 +1937,7 @@ plabel( lbl); q = p->n_right->n_right; + comops(q); if (type != VOID) { r = tempnode(tval, q->n_type, q->n_df, q->n_sue); q = buildtree(ASSIGN, r, q); @@ -1927,7 +1976,7 @@ *r = *p; andorbr(r, -1, lbl = getlab()); q = tempnode(0, p->n_type, p->n_df, p->n_sue); - tval = q->n_lval; + tval = regno(q); r = tempnode(tval, p->n_type, p->n_df, p->n_sue); ecode(buildtree(ASSIGN, q, bcon(1))); branch(lbl2 = getlab()); @@ -1945,13 +1994,7 @@ p->n_op = ICON; p->n_type = VOID; break; case COMOP: - rmcops(p->n_left); - ecode(p->n_left); - /* Now when left tree is dealt with, rm COMOP */ - q = p->n_right; - *p = *p->n_right; - nfree(q); - goto again; + cerror("COMOP error"); default: if (ty == LTYPE) @@ -1994,7 +2037,7 @@ if (p->n_op == INCR || p->n_op == DECR) { /* * Rewrite x++ to (x += 1) -1; and deal with it further down. - * Pass2 will remove -1 if unneccessary. + * Pass2 will remove -1 if unnecessary. */ q = ccopy(p); tfree(p->n_left); @@ -2009,7 +2052,7 @@ if (has_se(l)) { q = tempnode(0, ll->n_type, ll->n_df, ll->n_sue); - tval = q->n_lval; + tval = regno(q); r = tempnode(tval, ll->n_type, ll->n_df,ll->n_sue); l->n_left = q; /* Now the left side of node p has no side effects. */ @@ -2052,19 +2095,21 @@ fwalk(p, eprint, 0); #endif if (!reached) { - werror("statement not reached"); + if (Wunreachable_code) + werror("statement not reached"); reached = 1; } p = optim(p); + comops(p); rmcops(p); p = delasgop(p); - setloc1(PROG); if (p->n_op == ICON && p->n_type == VOID) tfree(p); else ecode(p); } + #if defined(MULTIPASS) void p2tree(NODE *p) @@ -2072,9 +2117,7 @@ struct symtab *q; int ty; -# ifdef MYP2TREE - MYP2TREE(p); /* local action can be taken here; then return... */ -# endif + myp2tree(p); /* local action can be taken here */ ty = coptype(p->n_op); @@ -2101,11 +2144,10 @@ case ICON: /* print external name */ if ((q = p->n_sp) != NULL) { - if ((q->sclass == STATIC && q->slevel > 0) || - q->sclass == ILABEL) { + if ((q->sclass == STATIC && q->slevel > 0)) { printf(LABFMT, q->soffset); } else - printf("%s\n", exname(q->sname)); + printf("%s\n", exname(q->soname)); } else printf("\n"); break; @@ -2125,6 +2167,10 @@ printf("\t%d\t\n", talign(STRTY, p->n_left->n_sue)); break; + case XARG: + case XASM: + break; + default: printf( "\n" ); } @@ -2135,15 +2181,24 @@ p2tree(p->n_right); } #else +static char * +sptostr(struct symtab *sp) +{ + char *cp = inlalloc(32); + int n = sp->soffset; + if (n < 0) + n = -n; + snprintf(cp, 32, LABFMT, n); + return cp; +} + void p2tree(NODE *p) { struct symtab *q; int ty; -# ifdef MYP2TREE - MYP2TREE(p); /* local action can be taken here; then return... */ -# endif + myp2tree(p); /* local action can be taken here */ ty = coptype(p->n_op); @@ -2154,23 +2209,19 @@ if ((q = p->n_sp) != NULL) { if ((q->sclass == STATIC && q->slevel > 0) || #ifdef GCC_COMPAT - q->sflags == SLBLNAME || + q->sflags == SLBLNAME #endif - q->sclass == ILABEL) { - char *cp = (isinlining ? - permalloc(32) : tmpalloc(32)); - int n = q->soffset; - if (n < 0) - n = -n; - snprintf(cp, 32, LABFMT, n); + ) { + p->n_name = sptostr(q); + } else if (!kflag) { + char *name = exname(q->soname); + int n = strlen(name) + 1; + char *cp = inlalloc(n); + + strlcpy(cp, name, n); p->n_name = cp; - } else { -#ifdef GCC_COMPAT - p->n_name = gcc_findname(q); -#else - p->n_name = exname(q->sname); -#endif - } + } else + p->n_name = q->soname; } else p->n_name = ""; break; @@ -2198,6 +2249,10 @@ p->n_stalign = talign(STRTY,p->n_left->n_sue)/SZCHAR; break; + case XARG: + case XASM: + break; + default: p->n_name = ""; } @@ -2212,7 +2267,7 @@ * Change void data types into char. */ static void -delvoid(NODE *p) +delvoid(NODE *p, void *arg) { /* Convert "PTR undef" (void *) to "PTR uchar" */ if (BTYPE(p->n_type) == VOID) @@ -2227,7 +2282,7 @@ *q = *p; q->n_type = BOOL_TYPE; r = tempnode(0, BOOL_TYPE, NULL, MKSUE(BOOL_TYPE)); - val = r->n_lval; + val = regno(r); s = tempnode(val, BOOL_TYPE, NULL, MKSUE(BOOL_TYPE)); *p = *s; q = buildtree(ASSIGN, r, q); @@ -2250,8 +2305,7 @@ p = optim(p); p = delasgop(p); - walkf(p, prtdcon); - walkf(p, delvoid); + walkf(p, delvoid, 0); #ifdef PCC_DEBUG if (xdebug) { printf("Fulltree:\n"); @@ -2282,26 +2336,28 @@ else sz = sizeof(struct interpass); - ip = isinlining ? permalloc(sz) : tmpalloc(sz); + ip = inlalloc(sz); ip->type = type; ip->lineno = lineno; switch (type) { case IP_NODE: - if (lastloc != PROG) - setloc1(PROG); ip->ip_node = va_arg(ap, NODE *); break; case IP_EPILOG: + if (!isinlining) + defloc(cftnsp); + /* FALLTHROUGH */ case IP_PROLOG: - setloc1(PROG); + inftn = type == IP_PROLOG ? 1 : 0; ipp = (struct interpass_prolog *)ip; - ipp->ipp_regs = va_arg(ap, int); + memset(ipp->ipp_regs, (type == IP_PROLOG)? -1 : 0, + sizeof(ipp->ipp_regs)); ipp->ipp_autos = va_arg(ap, int); ipp->ipp_name = va_arg(ap, char *); ipp->ipp_type = va_arg(ap, TWORD); ipp->ipp_vis = va_arg(ap, int); ip->ip_lbl = va_arg(ap, int); - ipp->ip_tmpnum = tvaloff; + ipp->ip_tmpnum = va_arg(ap, int); ipp->ip_lblnum = crslab; if (type == IP_PROLOG) ipp->ip_lblnum--; @@ -2311,9 +2367,11 @@ break; case IP_ASM: if (blevel == 0) { /* outside function */ - printf("\t%s\n", va_arg(ap, char *)); + printf("\t"); + printf("%s", va_arg(ap, char *)); + printf("\n"); va_end(ap); - lastloc = -1; + defloc(NULL); return; } ip->ip_asm = va_arg(ap, char *); @@ -2322,12 +2380,11 @@ cerror("bad send_passt type %d", type); } va_end(ap); + pass1_lastchance(ip); /* target-specific info */ if (isinlining) inline_addarg(ip); else pass2_compile(ip); - if (type == IP_EPILOG) - lastloc = PROG; } char * @@ -2363,6 +2420,8 @@ SNAM(RSEQ,>>=) SNAM(INCR,++) SNAM(DECR,--) + SNAM(STRING,STRING) + SNAM(SZOF,SIZEOF) default: cerror("bad copst %d", op); } @@ -2375,6 +2434,7 @@ if (op <= MAXOP) return dope[op]; switch (op) { + case STRING: case QUALIFIER: case CLASS: case RB: @@ -2415,6 +2475,7 @@ case DECR: return BITYPE|ASGFLG; } + cerror("cdope missing op %d", op); return 0; /* XXX gcc */ } @@ -2445,7 +2506,45 @@ void plabel(int label) { - setloc1(PROG); reached = 1; /* Will this always be correct? */ send_passt(IP_DEFLAB, label); } + +/* + * Perform integer promotion on node n. + */ +NODE * +intprom(NODE *n) +{ + if ((n->n_type >= CHAR && n->n_type < INT) || n->n_type == BOOL) { + if ((n->n_type == UCHAR && MAX_UCHAR > MAX_INT) || + (n->n_type == USHORT && MAX_USHORT > MAX_INT)) + return makety(n, UNSIGNED, 0, 0, MKSUE(UNSIGNED)); + return makety(n, INT, 0, 0, MKSUE(INT)); + } + return n; +} + +/* + * Return CON/VOL/0, whichever are active for the current type. + */ +int +cqual(TWORD t, TWORD q) +{ + while (ISARY(t)) + t = DECREF(t), q = DECQAL(q); + if (t <= BTMASK) + q <<= TSHIFT; + return q & (CON|VOL); +} + +int crslab = 10; +/* + * Return a number for internal labels. + */ +int +getlab(void) +{ + return crslab++; +} + Index: stabs.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/stabs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/stabs.c -L usr.bin/pcc/ccom/stabs.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/stabs.c +++ usr.bin/pcc/ccom/stabs.c @@ -1,4 +1,4 @@ -/* $Id: stabs.c,v 1.15 2007/09/15 07:37:44 ragge Exp $ */ +/* $Id: stabs.c,v 1.27 2008/12/08 21:39:50 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -39,18 +39,31 @@ #ifdef STABS #include -#include #include #include #define STABHASH 256 #define INTNUM 1 /* internal number of type "int" */ +#undef BIT2BYTE /* from external.h */ #define BIT2BYTE(x) ((x)/SZCHAR) #ifndef STABLBL #error macdefs.h must define STABLBL #endif +/* defines taken from BSD */ +#define N_GSYM 0x20 /* global symbol */ +#define N_FUN 0x24 /* procedure name */ +#define N_LCSYM 0x28 /* bss segment variable */ +#define N_RSYM 0x40 /* register variable */ +#define N_SLINE 0x44 /* text segment line number */ +#define N_SO 0x64 /* main source file name */ +#define N_LSYM 0x80 /* stack variable */ +#define N_SOL 0x84 /* included source file name */ +#define N_PSYM 0xa0 /* parameter variable */ +#define N_LBRAC 0xc0 /* left bracket */ +#define N_RBRAC 0xe0 /* right bracket */ + /* * Local type mapping * Types are defined as a typeword, a dimension pointer (in the case @@ -67,6 +80,7 @@ static int ntypes; static char *curfun; static int stablbl = 10; +extern int inftn; void ptype(char *name, int num, int inhnum, long long min, long long max); struct stabtype *addtype(TWORD, union dimfun *, struct suedef *); @@ -77,7 +91,6 @@ #define MAXPSTR 100 extern int isinlining; -#define savestabs isinlining /* * Output type definitions for the stab debugging format. @@ -109,7 +122,7 @@ ptype("double", ADDTYPE(DOUBLE)->num, INTNUM, 8, 0); ptype("long double", ADDTYPE(LDOUBLE)->num, INTNUM, 12, 0); st = ADDTYPE(VOID); - cprint(savestabs, ".stabs \"void:t%d=r%d\",%d,0,0,0\n", + cprint(0, "\t.stabs \"void:t%d=r%d\",%d,0,0,0\n", st->num, st->num, N_LSYM); } @@ -120,7 +133,7 @@ void ptype(char *name, int num, int inhnum, long long min, long long max) { - cprint(savestabs, ".stabs \"%s:t%d=r%d;%lld;%lld;\",%d,0,0,0", + cprint(0, "\t.stabs \"%s:t%d=r%d;%lld;%lld;\",%d,0,0,0\n", name, num, inhnum, min, max, N_LSYM); } @@ -183,8 +196,16 @@ void stabs_line(int line) { - cprint(savestabs, ".stabn %d,0,%d," STABLBL "-%s", N_SLINE, line, stablbl, curfun); - cprint(1, STABLBL ":", stablbl++); + if (inftn == 0) + return; /* ignore */ +#ifdef STAB_LINE_ABSOLUTE + cprint(1, "\t.stabn %d,0,%d," STABLBL "\n" STABLBL ":\n", + N_SLINE, line, stablbl, stablbl); +#else + cprint(1, "\t.stabn %d,0,%d," STABLBL "-%s\n" STABLBL ":\n", + N_SLINE, line, stablbl, exname(curfun), stablbl); +#endif + stablbl++; } /* @@ -193,9 +214,14 @@ void stabs_lbrac(int blklvl) { - cprint(savestabs, ".stabn %d,0,%d," STABLBL "-%s", - N_LBRAC, blklvl, stablbl, curfun); - cprint(1, STABLBL ":", stablbl++); +#ifdef STAB_LINE_ABSOLUTE + cprint(1, "\t.stabn %d,0,%d," STABLBL "\n" STABLBL ":\n", + N_LBRAC, blklvl, stablbl, stablbl); +#else + cprint(1, "\t.stabn %d,0,%d," STABLBL "-%s\n" STABLBL ":\n", + N_LBRAC, blklvl, stablbl, exname(curfun), stablbl); +#endif + stablbl++; } /* @@ -204,24 +230,40 @@ void stabs_rbrac(int blklvl) { - cprint(savestabs, ".stabn %d,0,%d," STABLBL "-%s\n", - N_RBRAC, blklvl, stablbl, curfun); - cprint(1, STABLBL ":", stablbl++); +#ifdef STAB_LINE_ABSOLUTE + cprint(1, "\t.stabn %d,0,%d," STABLBL "\n" STABLBL ":\n", + N_RBRAC, blklvl, stablbl, stablbl); +#else + cprint(1, "\t.stabn %d,0,%d," STABLBL "-%s\n" STABLBL ":\n", + N_RBRAC, blklvl, stablbl, exname(curfun), stablbl); +#endif + stablbl++; } +static char *mainfile; + /* * Print current file and set mark. */ void stabs_file(char *fname) { - static char *mainfile; - if (mainfile == NULL) mainfile = fname; /* first call */ - cprint(savestabs, ".stabs \"%s\",%d,0,0," STABLBL, - fname, fname == mainfile ? N_SO : N_SOL, stablbl); - cprint(savestabs, STABLBL ":", stablbl++); + cprint(inftn, "\t.stabs \"%s\",%d,0,0," STABLBL "\n" STABLBL ":\n", + fname, fname == mainfile ? N_SO : N_SOL, stablbl, stablbl); + stablbl++; +} + +/* + * Print end mark + */ +void +stabs_efile(char *fname) +{ + cprint(inftn, "\t.stabs \"\",%d,0,0," STABLBL "\n" STABLBL ":\n", + fname == mainfile ? N_SO : N_SOL, stablbl, stablbl); + stablbl++; } /* @@ -232,12 +274,9 @@ { char str[MAXPSTR]; - curfun = s->sname; -#ifdef GCC_COMPAT - curfun = gcc_findname(cftnsp); -#endif + curfun = s->soname; printtype(s, str, sizeof(str)); - cprint(savestabs, ".stabs \"%s:%c%s\",%d,0,%d,%s", + cprint(1, "\t.stabs \"%s:%c%s\",%d,0,%d,%s\n", curfun, s->sclass == STATIC ? 'f' : 'F', str, N_FUN, BIT2BYTE(s->ssue->suesize), exname(curfun)); } @@ -286,8 +325,10 @@ void stabs_newsym(struct symtab *s) { + extern int fun_inline; char *sname; char ostr[MAXPSTR]; + int suesize; if (ISFTN(s->stype)) return; /* functions are handled separate */ @@ -297,43 +338,48 @@ s->sclass == TYPEDEF || (s->sclass & FIELD)) return; /* XXX - fix structs */ - sname = s->sname; -#ifdef GCC_COMPAT - sname = gcc_findname(s); -#endif + sname = s->soname; + suesize = BIT2BYTE(s->ssue->suesize); + if (suesize > 32767) + suesize = 32767; + else if (suesize < -32768) + suesize = -32768; printtype(s, ostr, sizeof(ostr)); switch (s->sclass) { case PARAM: - cprint(savestabs, ".stabs \"%s:p%s\",%d,0,%d,%d", sname, ostr, - N_PSYM, BIT2BYTE(s->ssue->suesize), BIT2BYTE(s->soffset)); + cprint(0, "\t.stabs \"%s:p%s\",%d,0,%d,%d\n", sname, ostr, + N_PSYM, suesize, BIT2BYTE(s->soffset)); break; case AUTO: - cprint(savestabs, ".stabs \"%s:%s\",%d,0,%d,%d", sname, ostr, - N_LSYM, BIT2BYTE(s->ssue->suesize), BIT2BYTE(s->soffset)); + cprint(0, "\t.stabs \"%s:%s\",%d,0,%d,%d\n", sname, ostr, + N_LSYM, suesize, BIT2BYTE(s->soffset)); break; case STATIC: if (blevel) - cprint(savestabs, ".stabs \"%s:V%s\",%d,0,%d," LABFMT, sname, ostr, - N_LCSYM, BIT2BYTE(s->ssue->suesize), s->soffset); + cprint(0, "\t.stabs \"%s:V%s\",%d,0,%d," LABFMT "\n", sname, ostr, + N_LCSYM, suesize, s->soffset); else - cprint(savestabs, ".stabs \"%s:S%s\",%d,0,%d,%s", sname, ostr, - N_LCSYM, BIT2BYTE(s->ssue->suesize), exname(sname)); + cprint(0, "\t.stabs \"%s:S%s\",%d,0,%d,%s\n", sname, ostr, + N_LCSYM, suesize, exname(sname)); break; case EXTERN: case EXTDEF: - cprint(savestabs, ".stabs \"%s:G%s\",%d,0,%d,0", sname, ostr, - N_GSYM, BIT2BYTE(s->ssue->suesize)); + cprint(0, "\t.stabs \"%s:G%s\",%d,0,%d,0\n", sname, ostr, + N_GSYM, suesize); break; case REGISTER: - cprint(savestabs, ".stabs \"%s:r%s\",%d,0,%d,%d", sname, ostr, + cprint(0, "\t.stabs \"%s:r%s\",%d,0,%d,%d\n", sname, ostr, N_RSYM, 1, s->soffset); break; - + case SNULL: + if (fun_inline) + break; + /* FALLTHROUGH */ default: cerror("fix stab_newsym; class %d", s->sclass); } @@ -352,22 +398,54 @@ { } -void +struct stabsv { + SLIST_ENTRY(stabsv) next; + char *str; +} ; +static SLIST_HEAD(, stabsv) stpole = { NULL, &stpole.q_forw }; + +/* + * Global variable debug info is printed out directly. + * For functions and their declarations, both the labels and + * the debug info is put into ASM nodes and follows their statements + * into pass2. + * Due to the possible unsync between pass1 and 2 and where the + * stabs info for text is sent over the following syncing is used: + * curfun == 0 + * print out everything; only data will be. + * curfun != 0 && inftn == 0 + * save in linked list + * curfun != 0 && inftn != 0 + * print linked list first, empty it, then arg. + */ +void cprint(int p2, char *fmt, ...) { - va_list ap; + struct stabsv *w; + va_list ap; char *str; + if (isinlining) + return; /* XXX do not save any inline functions currently */ + va_start(ap, fmt); if (p2) { str = tmpvsprintf(fmt, ap); - str = newstring(str, strlen(str)); /* XXX - for inlines */ - send_passt(IP_ASM, str); - } else { - putchar('\t'); + if (inftn == 0) { + w = tmpalloc(sizeof(struct stabsv)); + w->str = str; + SLIST_INSERT_LAST(&stpole, w, next); + } else { + if (stpole.q_last != &stpole.q_forw) { + SLIST_FOREACH(w, &stpole, next) { + send_passt(IP_ASM, w->str); + } + SLIST_INIT(&stpole); + } + send_passt(IP_ASM, str); + } + } else vprintf(fmt, ap); - putchar('\n'); - } va_end(ap); } Index: symtabs.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/symtabs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/symtabs.c -L usr.bin/pcc/ccom/symtabs.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/symtabs.c +++ usr.bin/pcc/ccom/symtabs.c @@ -1,4 +1,4 @@ -/* $Id: symtabs.c,v 1.14 2006/06/16 09:30:32 ragge Exp $ */ +/* $Id: symtabs.c,v 1.18 2008/06/19 08:05:00 gmcgarry Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -175,15 +175,15 @@ * Returns a struct symtab. */ struct symtab * -lookup(char *key, int ttype) +lookup(char *key, int stype) { struct symtab *sym; struct tree *w, *new, *last; - int cix, bit, fbit, svbit, ix, bitno, match; + int cix, bit, fbit, svbit, bitno; int type, uselvl; + intptr_t ix, match, code = (intptr_t)key; - long code = (long)key; - type = ttype & SMASK; + type = stype & SMASK; uselvl = (blevel > 0 && type != SSTRING); /* @@ -197,15 +197,15 @@ switch (numsyms[type]) { case 0: - if (ttype & SNOCREAT) + if (stype & SNOCREAT) return NULL; if (uselvl) { - sym = getsymtab(key, ttype|STEMP); + sym = getsymtab(key, stype|STEMP); sym->snext = tmpsyms[type]; tmpsyms[type] = sym; return sym; } - sympole[type] = (struct tree *)getsymtab(key, ttype); + sympole[type] = (struct tree *)getsymtab(key, stype); numsyms[type]++; return (struct symtab *)sympole[type]; @@ -228,12 +228,12 @@ } sym = (struct symtab *)w; - match = (long)sym->sname; + match = (intptr_t)sym->sname; ix = code ^ match; if (ix == 0) return sym; - else if (ttype & SNOCREAT) + else if (stype & SNOCREAT) return NULL; #ifdef PCC_DEBUG @@ -246,7 +246,7 @@ * Insert into the linked list, if feasible. */ if (uselvl) { - sym = getsymtab(key, ttype|STEMP); + sym = getsymtab(key, stype|STEMP); sym->snext = tmpsyms[type]; tmpsyms[type] = sym; return sym; @@ -258,17 +258,17 @@ * This could be optimized by adding a remove routine, but it * may be more trouble than it is worth. */ - if (ttype == (STEMP|SNORMAL)) - ttype = SNORMAL; + if (stype == (STEMP|SNORMAL)) + stype = SNORMAL; for (cix = 0; (ix & 1) == 0; ix >>= 1, cix++) ; - new = ttype & STEMP ? tmpalloc(sizeof(struct tree)) : + new = stype & STEMP ? tmpalloc(sizeof(struct tree)) : permalloc(sizeof(struct tree)); bit = (code >> cix) & 1; new->bitno = cix | (bit ? RIGHT_IS_LEAF : LEFT_IS_LEAF); - new->lr[bit] = (struct tree *)getsymtab(key, ttype); + new->lr[bit] = (struct tree *)getsymtab(key, stype); if (numsyms[type]++ == 1) { new->lr[!bit] = sympole[type]; new->bitno |= (bit ? LEFT_IS_LEAF : RIGHT_IS_LEAF); @@ -343,10 +343,15 @@ hide(struct symtab *sym) { struct symtab *new; + int typ = sym->sflags & SMASK; + + new = getsymtab(sym->sname, typ|STEMP); + new->snext = tmpsyms[typ]; + tmpsyms[typ] = new; + + if (Wshadow) + werror("declaration of '%s' shadows previous", sym->sname); - new = getsymtab(sym->sname, SNORMAL|STEMP); - new->snext = tmpsyms[SNORMAL]; - tmpsyms[SNORMAL] = new; #ifdef PCC_DEBUG if (ddebug) printf("\t%s hidden at level %d (%p -> %p)\n", Index: optim.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/optim.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/optim.c -L usr.bin/pcc/ccom/optim.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/optim.c +++ usr.bin/pcc/ccom/optim.c @@ -1,4 +1,4 @@ -/* $Id: optim.c,v 1.28 2006/07/11 07:54:29 ragge Exp $ */ +/* $Id: optim.c,v 1.32 2008/10/27 21:13:20 ragge Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -43,8 +43,6 @@ # define LO(p) p->n_left->n_op # define LV(p) p->n_left->n_lval -static int nncon(NODE *); - int oflag = 0; /* remove left node */ @@ -92,7 +90,7 @@ int i; TWORD t; - if( (t=BTYPE(p->n_type))==ENUMTY || t==MOETY ) econvert(p); + t = BTYPE(p->n_type); if( oflag ) return(p); ty = coptype(p->n_op); @@ -137,7 +135,8 @@ goto setuleft; case RS: - if (LO(p) == RS && RCON(p->n_left) && RCON(p)) { + if (LO(p) == RS && RCON(p->n_left) && RCON(p) && + (RV(p) + RV(p->n_left)) < p->n_sue->suesize) { /* two right-shift by constants */ RV(p) += RV(p->n_left); p->n_left = zapleft(p->n_left); @@ -334,7 +333,21 @@ p->n_op = revrel[p->n_op - EQ ]; break; +#ifdef notyet + case ASSIGN: + /* Simple test to avoid two branches */ + if (RO(p) != NE) + break; + q = p->n_right; + if (RCON(q) && RV(q) == 0 && LO(q) == AND && + RCON(q->n_left) && (i = ispow2(RV(q->n_left))) && + q->n_left->n_type == INT) { + q->n_op = RS; + RV(q) = i; } + break; +#endif + } return(p); } Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/ccom/Makefile -L usr.bin/pcc/ccom/Makefile -u -r1.2 -r1.3 --- usr.bin/pcc/ccom/Makefile +++ usr.bin/pcc/ccom/Makefile @@ -14,8 +14,8 @@ CFLAGS+= -Dmach_${TARGMACH} CFLAGS+= -DPCC_DEBUG -DGCC_COMPAT CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Werror -CFLAGS+= -I. -I${.CURDIR}/.. -I${.CURDIR} -I${.CURDIR}/../mip -CFLAGS+= -I${.CURDIR}/../${TARGMACH} +CFLAGS+= -I. -I${.CURDIR}/.. -I${.CURDIR} +CFLAGS+= -I${.CURDIR}/../${TARGMACH} -I${.CURDIR}/../mip .PATH: ${.CURDIR}/../${TARGMACH} .PATH: ${.CURDIR}/../mip Index: scanner.l =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/scanner.l,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/cpp/scanner.l -L usr.bin/pcc/cpp/scanner.l -u -r1.1 -r1.2 --- usr.bin/pcc/cpp/scanner.l +++ usr.bin/pcc/cpp/scanner.l @@ -1,5 +1,5 @@ %{ -/* $Id: scanner.l,v 1.20 2007/09/25 20:41:07 ragge Exp $ */ +/* $Id: scanner.l,v 1.48 2008/08/21 16:32:40 ragge Exp $ */ /* * Copyright (c) 2004 Anders Magnusson. All rights reserved. @@ -27,19 +27,25 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "config.h" + #include #include #include +#ifdef HAVE_UNISTD_H #include +#endif #include +#include +#include "compat.h" #include "cpp.h" #include "y.tab.h" %} %{ -static long long cvtdig(int rad); -static int charcon(void); +static void cvtdig(int rad); +static int charcon(usch *); static void elsestmt(void); static void ifdefstmt(void); static void ifndefstmt(void); @@ -50,8 +56,8 @@ static void undefstmt(void); static void cpperror(void); static void elifstmt(void); -//static void linestmt(void); static void storepb(void); +static void badop(const char *); void include(void); void define(void); @@ -82,15 +88,17 @@ } #undef YY_INPUT #undef YY_BUF_SIZE -#define YY_BUF_SIZE 32768 +#define YY_BUF_SIZE (8*65536) #define YY_INPUT(b,r,m) (r = yyinput(b, m)) +#ifdef HAVE_CPP_VARARG_MACRO_GCC #define fprintf(x, ...) error(__VA_ARGS__) +#endif #define ECHO putstr((usch *)yytext) #undef fileno #define fileno(x) 0 #if YY_FLEX_SUBMINOR_VERSION >= 31 -/* Hack to avoid unneccessary warnings */ +/* Hack to avoid unnecessary warnings */ FILE *yyget_in (void); FILE *yyget_out (void); int yyget_leng (void); @@ -108,6 +116,9 @@ #define unput(ch) unch(ch) #endif #define PRTOUT(x) if (YYSTATE || slow) return x; if (!flslvl) putstr((usch *)yytext); +/* protection against recursion in #include */ +#define MAX_INCLEVEL 100 +static int inclevel; %} D [0-9] @@ -118,7 +129,7 @@ IS (u|U|l|L)* WS [\t ] -%s IFR CONTR DEF +%s IFR CONTR DEF COMMENT %% @@ -139,6 +150,8 @@ "\r" { ; /* Ignore CR's */ } +"++" { badop("++"); } +"--" { badop("--"); } "==" { return EQ; } "!=" { return NE; } "<=" { return LE; } @@ -160,28 +173,41 @@ {WS}+ { ; } {L}({L}|{D})* { + yylval.node.op = NUMBER; if (gotdef) { - yylval.val = - lookup((usch *)yytext, FIND) != 0; + yylval.node.nd_val + = lookup((usch *)yytext, FIND) != 0; gotdef = 0; return IDENT; } - yylval.val = 0; + yylval.node.nd_val = 0; return NUMBER; } -[1-9][0-9]* { if (slow && !YYSTATE) return IDENT; scale = 10; goto num; } +[0-9][0-9]* { + if (slow && !YYSTATE) + return IDENT; + scale = yytext[0] == '0' ? 8 : 10; + goto num; + } 0[xX]{H}+{IS}? { scale = 16; - num: if (YYSTATE) - yylval.val = cvtdig(scale); + num: if (YYSTATE == IFR) + cvtdig(scale); PRTOUT(NUMBER); } 0{D}+{IS}? { scale = 8; goto num; } {D}+{IS}? { scale = 10; goto num; } -L?'(\\.|[^\\'])+' { if (YYSTATE) - yylval.val = charcon(); - PRTOUT(NUMBER); +'(\\.|[^\\'])+' { + if (YYSTATE || slow) { + yylval.node.op = NUMBER; + yylval.node.nd_val = charcon((usch *)yytext); + return (NUMBER); + } + if (tflag) + yyless(1); + if (!flslvl) + putstr((usch *)yytext); } . { return yytext[0]; } @@ -190,7 +216,14 @@ {D}*"."{D}+({E})?{FS}? { PRTOUT(FPOINT); } {D}+"."{D}*({E})?{FS}? { PRTOUT(FPOINT); } -^{WS}*#{WS}* { contr = 1; BEGIN CONTR; } +^{WS}*#{WS}* { extern int inmac; + + if (inmac) + error("preprocessor directive found " + "while expanding macro"); + contr = 1; + BEGIN CONTR; + } {WS}+ { PRTOUT(WSPACE); } "ifndef" { contr = 0; ifndefstmt(); } @@ -203,19 +236,25 @@ "define" { contr = 0; BEGIN DEF; define(); BEGIN 0; } "undef" { contr = 0; if (slow) return IDENT; undefstmt(); } "line" { contr = 0; storepb(); BEGIN 0; line(); } -"pragma" { contr = 0; pragmastmt(); } +"pragma" { contr = 0; pragmastmt(); BEGIN 0; } "elif" { contr = 0; storepb(); BEGIN IFR; elifstmt(); BEGIN 0; } "//".*$ { /* if (tflag) yyless(..) */ - if (Cflag) + if (Cflag && !flslvl && !slow) putstr((usch *)yytext); else if (!flslvl) putch(' '); } "/*" { int c, wrn; - if (Cflag) + int prtcm = Cflag && !flslvl && !slow; + extern int readmac; + + if (Cflag && !flslvl && readmac) + return CMNT; + + if (prtcm) putstr((usch *)yytext); wrn = 0; more: while ((c = input()) && c != '*') { @@ -223,20 +262,18 @@ putch(c), ifiles->lineno++; else if (c == 1) /* WARN */ wrn = 1; - else if (Cflag) + else if (prtcm) putch(c); } if (c == 0) return 0; - if (Cflag) + if (prtcm) putch(c); if ((c = input()) && c != '/') { - if (Cflag) - putch('*'); unput(c); goto more; } - if (Cflag) + if (prtcm) putch(c); if (c == 0) return 0; @@ -280,7 +317,31 @@ xx: ; } -. { PRTOUT(yytext[0]); } +. { + if (contr) { + while (input() != '\n') + ; + unput('\n'); + BEGIN 0; + contr = 0; + goto yy; + } + if (YYSTATE || slow) + return yytext[0]; + if (yytext[0] == 6) { /* PRAGS */ + usch *obp = stringbuf; + extern usch *prtprag(usch *); + *stringbuf++ = yytext[0]; + do { + *stringbuf = input(); + } while (*stringbuf++ != 14); + prtprag(obp); + stringbuf = obp; + } else { + PRTOUT(yytext[0]); + } + yy:; + } %% @@ -393,25 +454,26 @@ /* * A new file included. * If ifiles == NULL, this is the first file and already opened (stdin). - * Return 0 on success, -1 on failure to open file. + * Return 0 on success, -1 if file to be included is not found. */ int pushfile(usch *file) { extern struct initar *initar; struct includ ibuf; - struct includ *old; struct includ *ic; int c, otrulvl; ic = &ibuf; - old = ifiles; + ic->next = ifiles; slow = 0; if (file != NULL) { if ((ic->infil = open((char *)file, O_RDONLY)) < 0) return -1; ic->orgfn = ic->fname = file; + if (++inclevel > MAX_INCLEVEL) + error("Limit for nested includes exceeded"); } else { ic->infil = 0; ic->orgfn = ic->fname = (usch *)""; @@ -438,8 +500,9 @@ if (otrulvl != trulvl || flslvl) error("unterminated conditional"); - ifiles = old; + ifiles = ic->next; close(ic->infil); + inclevel--; return 0; } @@ -458,7 +521,7 @@ s = sheap("%s: %s\n", Mfile, ifiles->fname); write(ofd, s, strlen((char *)s)); } - } else + } else if (!Pflag) putstr(sheap("# %d \"%s\"\n", ifiles->lineno, ifiles->fname)); stringbuf = os; } @@ -468,7 +531,7 @@ { #ifdef CPP_DEBUG extern int dflag; - if (dflag)printf(": '%c'(%d)", c, c); + if (dflag)printf(": '%c'(%d)", c > 31 ? c : ' ', c); #endif unput(c); } @@ -488,13 +551,13 @@ } /* - * Convert some string numbers to long long. - * Do not care about UL trailers, should we? + * Convert string numbers to unsigned long long and check overflow. */ -static long long +static void cvtdig(int rad) { - long long rv = 0; + unsigned long long rv = 0; + unsigned long long rv2 = 0; char *y = yytext; int c; @@ -503,20 +566,30 @@ y++; while (isxdigit(c)) { rv = rv * rad + dig2num(c); + /* check overflow */ + if (rv / rad < rv2) + error("Constant \"%s\" is out of range", yytext); + rv2 = rv; c = *y++; } - return rv; + y--; + while (*y == 'l' || *y == 'L') + y++; + yylval.node.op = *y == 'u' || *y == 'U' ? UNUMBER : NUMBER; + yylval.node.nd_uval = rv; + if ((rad == 8 || rad == 16) && yylval.node.nd_val < 0) + yylval.node.op = UNUMBER; + if (yylval.node.op == NUMBER && yylval.node.nd_val < 0) + /* too large for signed */ + error("Constant \"%s\" is out of range", yytext); } static int -charcon(void) +charcon(usch *p) { - usch *p = (usch *)yytext; int val, c; - if (*p == 'L') - p++; - p++; /* first ' */ + p++; /* skip first ' */ val = 0; if (*p++ == '\\') { switch (*p++) { @@ -553,14 +626,24 @@ } static void -chknl(void) +chknl(int ignore) { int t; + slow = 1; while ((t = yylex()) == WSPACE) ; - if (t != '\n') - error("newline expected, got %d", t); + if (t != '\n') { + if (ignore) { + warning("newline expected, got \"%s\"", yytext); + /* ignore rest of line */ + while ((t = yylex()) && t != '\n') + ; + } + else + error("newline expected, got \"%s\"", yytext); + } + slow = 0; } static void @@ -583,12 +666,14 @@ if (elslvl==trulvl+flslvl) error("Too many else"); elslvl=trulvl+flslvl; - chknl(); + chknl(1); } static void ifdefstmt(void) { + int t; + if (flslvl) { /* just ignore the rest of the line */ while (input() != '\n') @@ -599,28 +684,36 @@ return; } slow = 1; - if (yylex() != WSPACE || yylex() != IDENT) + do + t = yylex(); + while (t == WSPACE); + if (t != IDENT) error("bad ifdef"); slow = 0; if (flslvl == 0 && lookup((usch *)yytext, FIND) != 0) trulvl++; else flslvl++; - chknl(); + chknl(0); } static void ifndefstmt(void) { + int t; + slow = 1; - if (yylex() != WSPACE || yylex() != IDENT) + do + t = yylex(); + while (t == WSPACE); + if (t != IDENT) error("bad ifndef"); slow = 0; if (flslvl == 0 && lookup((usch *)yytext, FIND) == 0) trulvl++; else flslvl++; - chknl(); + chknl(0); } static void @@ -637,7 +730,7 @@ if (flslvl == 0) elflvl = 0; elslvl = 0; - chknl(); + chknl(1); } /* @@ -694,8 +787,24 @@ usch *opb = stringbuf; int c; - while ((c = input()) != '\n') + while ((c = input()) != '\n') { + if (c == '/') { + if ((c = input()) == '*') { + /* ignore comments here whatsoever */ + usch *g = stringbuf; + getcmnt(); + stringbuf = g; + continue; + } else if (c == '/') { + while ((c = input()) && c != '\n') + ; + break; + } + unput(c); + c = '/'; + } savch(c); + } cunput('\n'); savch(0); fixdefined(opb); /* XXX can fail if #line? */ @@ -779,7 +888,7 @@ if (flslvl) stringbuf = cp; else - error("error: %s", cp); + error("%s", cp); } static void @@ -793,7 +902,7 @@ if (flslvl == 0 && (np = lookup((usch *)yytext, FIND))) np->value = 0; slow = 0; - chknl(); + chknl(0); } static void @@ -804,11 +913,26 @@ slow = 1; if (yylex() != WSPACE) error("bad pragma"); - putstr((usch *)"#pragma "); + if (!flslvl) + putstr((usch *)"#pragma "); do { - putch(c = input()); /* Do arg expansion instead? */ + c = input(); + if (!flslvl) + putch(c); /* Do arg expansion instead? */ } while (c && c != '\n'); ifiles->lineno++; prtline(); slow = 0; } + +static void +badop(const char *op) +{ + error("invalid operator in preprocessor expression: %s", op); +} + +int +cinput() +{ + return input(); +} Index: token.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/token.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/cpp/token.c -L usr.bin/pcc/cpp/token.c -u -r1.1 -r1.2 --- usr.bin/pcc/cpp/token.c +++ usr.bin/pcc/cpp/token.c @@ -1,4 +1,4 @@ -/* $Id: token.c,v 1.11 2006/09/28 11:10:08 ragge Exp $ */ +/* $Id: token.c,v 1.12 2008/04/15 09:54:23 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson. All rights reserved. @@ -35,17 +35,7 @@ #include "cpp.h" /* definition for include file info */ -struct includ { - struct includ *next; - char *fname; - int lineno; - int infil; - usch *curptr; - usch *maxread; - usch *ostr; - usch *buffer; - usch bbuf[NAMEMAX+CPPBUF+1]; -} *ifiles; +struct includ *ifiles; usch *yyp, *yystr, yybuf[CPPBUF]; Index: cpp.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/cpp.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L usr.bin/pcc/cpp/cpp.c -L usr.bin/pcc/cpp/cpp.c -u -r1.3 -r1.4 --- usr.bin/pcc/cpp/cpp.c +++ usr.bin/pcc/cpp/cpp.c @@ -1,4 +1,4 @@ -/* $Id: cpp.c,v 1.65 2007/09/25 20:41:08 ragge Exp $ */ +/* $Id: cpp.c,v 1.95 2008/12/07 20:12:05 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -66,24 +66,24 @@ * from V7 cpp, and at last ansi/c99 support. */ -#include "../config.h" +#include "config.h" +#ifdef HAVE_SYS_WAIT_H #include +#endif #include +#ifdef HAVE_UNISTD_H #include +#endif #include #include #include #include #include -#include #include -#ifdef HAVE_ALLOCA_H -#include -#endif - +#include "compat.h" #include "cpp.h" #include "y.tab.h" @@ -103,12 +103,15 @@ #define DDPRINT(x) #endif +#define GCC_VARI + int ofd; usch outbuf[CPPBUF]; -int obufp, istty; -int Cflag, Mflag, dMflag; +int obufp, istty, inmac; +int Cflag, Mflag, dMflag, Pflag; usch *Mfile; struct initar *initar; +int readmac; /* avoid recursion */ struct recur { @@ -149,6 +152,7 @@ * 1-> - number of args. */ +#define GCCARG 0xfd /* has gcc varargs that may be replaced with 0 */ #define VARG 0xfe /* has varargs */ #define OBJCT 0xff #define WARN 1 /* SOH, not legal char */ @@ -156,6 +160,8 @@ #define SNUFF 3 /* ETX, not legal char */ #define NOEXP 4 /* EOT, not legal char */ #define EXPAND 5 /* ENQ, not legal char */ +#define PRAGS 6 /* start of converted pragma */ +#define PRAGE 14 /* end of converted pragma */ /* args for lookup() */ #define FIND 0 @@ -168,6 +174,9 @@ void line(void); void flbuf(void); void usage(void); +usch *xstrdup(char *str); +usch *prtprag(usch *opb); + int main(int argc, char **argv) @@ -177,7 +186,13 @@ struct symtab *nl; register int ch; - while ((ch = getopt(argc, argv, "CD:I:MS:U:d:i:tvV?")) != -1) +#ifdef TIMING + struct timeval t1, t2; + + (void)gettimeofday(&t1, NULL); +#endif + + while ((ch = getopt(argc, argv, "CD:I:MPS:U:d:i:tvV?")) != -1) switch (ch) { case 'C': /* Do not discard comments */ Cflag++; @@ -199,6 +214,10 @@ Mflag++; break; + case 'P': /* Inhibit generation of line numbers */ + Pflag++; + break; + case 'S': case 'I': if ((w = calloc(sizeof(struct incs), 1)) == NULL) @@ -219,7 +238,7 @@ break; #endif case 'v': - printf("pcpp: %s\n", VERSSTR); + printf("cpp: %s\n", VERSSTR); break; case 'd': if (optarg[0] == 'M') { @@ -267,6 +286,10 @@ nl = lookup((usch *)"__STDC__", ENTER); savch(0); savch('1'); savch(OBJCT); nl->value = stringbuf-1; + + nl = lookup((usch *)"__STDC_VERSION__", ENTER); + savch(0); savstr((usch *)"199901L"); savch(OBJCT); + nl->value = stringbuf-1; } if (Mflag && !dMflag) { @@ -298,6 +321,17 @@ flbuf(); close(ofd); +#ifdef TIMING + (void)gettimeofday(&t2, NULL); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + if (t2.tv_usec < 0) { + t2.tv_usec += 1000000; + t2.tv_sec -= 1; + } + fprintf(stderr, "cpp total time: %ld s %ld us\n", + t2.tv_sec, t2.tv_usec); +#endif return 0; } @@ -315,6 +349,7 @@ thisnl = NULL; slow = 1; + readmac++; base = osp = stringbuf; goto found; @@ -377,6 +412,10 @@ thisnl = NULL; break; + case CMNT: + getcmnt(); + break; + case STRING: case '\n': case NUMBER: @@ -394,11 +433,12 @@ } if (thisnl == NULL) { slow = 0; + readmac--; savch(0); return base; } } - error("preamture EOF"); + error("premature EOF"); /* NOTREACHED */ return NULL; /* XXX gcc */ } @@ -423,7 +463,7 @@ slow = 0; return; } - if (yylex() != STRING) + if (yylex() != STRING || yytext[0] == 'L') goto bad; c = strlen((char *)yytext); if (llen < c) { @@ -550,6 +590,55 @@ } void +getcmnt(void) +{ + int c; + + savstr((usch *)yytext); + for (;;) { + c = cinput(); + if (c == '*') { + c = cinput(); + if (c == '/') { + savstr((usch *)"*/"); + return; + } + cunput(c); + c = '*'; + } + savch(c); + } +} + +/* + * Compare two replacement lists, taking in account comments etc. + */ +static int +cmprepl(usch *o, usch *n) +{ + for (; *o; o--, n--) { + /* comment skip */ + if (*o == '/' && o[-1] == '*') { + while (*o != '*' || o[-1] != '/') + o--; + o -= 2; + } + if (*n == '/' && n[-1] == '*') { + while (*n != '*' || n[-1] != '/') + n--; + n -= 2; + } + while (*o == ' ' || *o == '\t') + o--; + while (*n == ' ' || *n == '\t') + n--; + if (*o != *n) + return 1; + } + return 0; +} + +void define() { struct symtab *np; @@ -557,7 +646,10 @@ int c, i, redef; int mkstr = 0, narg = -1; int ellips = 0; - int len; +#ifdef GCC_VARI + usch *gccvari = NULL; + int wascon; +#endif if (flslvl) return; @@ -571,12 +663,13 @@ np = lookup((usch *)yytext, ENTER); redef = np->value != NULL; + readmac = 1; sbeg = stringbuf; if ((c = yylex()) == '(') { narg = 0; /* function-like macros, deal with identifiers */ + c = definp(); for (;;) { - c = definp(); if (c == ')') break; if (c == ELLIPS) { @@ -586,15 +679,27 @@ break; } if (c == IDENT) { - len = strlen(yytext); - args[narg] = alloca(len+1); - strlcpy((char *)args[narg], yytext, len+1); - narg++; - if ((c = definp()) == ',') + /* make sure there is no arg of same name */ + for (i = 0; i < narg; i++) + if (!strcmp((char *) args[i], yytext)) + error("Duplicate macro " + "parameter \"%s\"", yytext); + args[narg++] = xstrdup(yytext); + if ((c = definp()) == ',') { + if ((c = definp()) == ')') + goto bad; continue; + } +#ifdef GCC_VARI + if (c == ELLIPS) { + if (definp() != ')') + goto bad; + gccvari = args[--narg]; + break; + } +#endif if (c == ')') break; - goto bad; } goto bad; } @@ -608,9 +713,17 @@ while (c == WSPACE) c = yylex(); + /* replacement list cannot start with ## operator */ + if (c == CONCAT) + goto bad; + /* parse replacement-list, substituting arguments */ savch('\0'); while (c != '\n') { +#ifdef GCC_VARI + wascon = 0; +loop: +#endif switch (c) { case WSPACE: /* remove spaces if it surrounds a ## directive */ @@ -622,6 +735,12 @@ savch(CONC); if ((c = yylex()) == WSPACE) c = yylex(); +#ifdef GCC_VARI + if (c == '\n') + break; + wascon = 1; + goto loop; +#endif } continue; @@ -630,7 +749,14 @@ savch(CONC); if ((c = yylex()) == WSPACE) c = yylex(); +#ifdef GCC_VARI + if (c == '\n') + break; + wascon = 1; + goto loop; +#else continue; +#endif case MKSTR: if (narg < 0) { @@ -655,6 +781,16 @@ if (strcmp(yytext, (char *)args[i]) == 0) break; if (i == narg) { +#ifdef GCC_VARI + if (gccvari && + strcmp(yytext, (char *)gccvari) == 0) { + savch(wascon ? GCCARG : VARG); + savch(WARN); + if (mkstr) + savch(SNUFF), mkstr = 0; + break; + } +#endif if (mkstr) error("not argument"); goto id; @@ -674,31 +810,40 @@ savch(SNUFF), mkstr = 0; break; + case CMNT: /* save comments */ + getcmnt(); + break; + default: id: savstr((usch *)yytext); break; } c = yylex(); } + readmac = 0; /* remove trailing whitespace */ while (stringbuf > sbeg) { if (stringbuf[-1] == ' ' || stringbuf[-1] == '\t') stringbuf--; + /* replacement list cannot end with ## operator */ + else if (stringbuf[-1] == CONC) + goto bad; else break; } +#ifdef GCC_VARI + if (gccvari) { + savch(narg); + savch(VARG); + } else +#endif if (ellips) { savch(narg); savch(VARG); } else savch(narg < 0 ? OBJCT : narg); if (redef) { - usch *o = np->value, *n = stringbuf-1; - - /* Redefinition to identical replacement-list is allowed */ - while (*o && *o == *n) - o--, n--; - if (*o || *o != *n) + if (cmprepl(np->value, stringbuf-1)) error("%s redefined\nprevious define: %s:%d", np->namep, np->file, np->line); stringbuf = sbeg; /* forget this space */ @@ -726,12 +871,31 @@ } #endif slow = 0; + for (i = 0; i < narg; i++) + free(args[i]); return; bad: error("bad define"); } void +xwarning(usch *s) +{ + usch *t; + usch *sb = stringbuf; + + flbuf(); + savch(0); + if (ifiles != NULL) { + t = sheap("%s:%d: warning: ", ifiles->fname, ifiles->lineno); + write (2, t, strlen((char *)t)); + } + write (2, s, strlen((char *)s)); + write (2, "\n", 1); + stringbuf = sb; +} + +void xerror(usch *s) { usch *t; @@ -739,7 +903,7 @@ flbuf(); savch(0); if (ifiles != NULL) { - t = sheap("%s:%d: ", ifiles->fname, ifiles->lineno); + t = sheap("%s:%d: error: ", ifiles->fname, ifiles->lineno); write (2, t, strlen((char *)t)); } write (2, s, strlen((char *)s)); @@ -751,7 +915,7 @@ * store a character into the "define" buffer. */ void -savch(c) +savch(int c) { if (stringbuf-sbf < SBSIZE) { *stringbuf++ = c; @@ -768,10 +932,9 @@ pragoper(void) { usch *opb; - int t; + int t, plev; - slow = 1; - putstr((usch *)"\n#pragma "); + slow++; if ((t = yylex()) == WSPACE) t = yylex(); if (t != '(') @@ -779,29 +942,37 @@ if ((t = yylex()) == WSPACE) t = yylex(); opb = stringbuf; - while (t != ')') { + for (plev = 0; ; t = yylex()) { + if (t == '(') + plev++; + if (t == ')') + plev--; + if (plev < 0) + break; savstr((usch *)yytext); - t = yylex(); } + savch(0); cunput(WARN); unpstr(opb); stringbuf = opb; expmac(NULL); + cunput('\n'); while (stringbuf > opb) cunput(*--stringbuf); - if ((t = yylex()) != STRING) - goto bad; - opb = (usch *)yytext; - if (*opb++ == 'L') - opb++; - while ((t = *opb++) != '\"') { - if (t == '\\' && (*opb == '\"' || *opb == '\\')) - t = *opb++; - putch(t); + savch(PRAGS); + while ((t = yylex()) != '\n') { + if (t == WSPACE) + continue; + if (t != STRING) + goto bad; + savstr((usch *)yytext); } - putch('\n'); - prtline(); + + savch(PRAGE); + while (stringbuf > opb) + cunput(*--stringbuf); + slow--; return; bad: error("bad pragma operator"); } @@ -815,8 +986,8 @@ struct recur *rp; { struct recur rp2; - register usch *vp, *cp; - int c, rv = 0, ws; + register usch *vp, *cp, *obp; + int c, nl; DPRINT(("subst: %s\n", sp->namep)); /* @@ -842,40 +1013,36 @@ /* should we be here at all? */ /* check if identifier is followed by parentheses */ - rv = 1; - ws = 0; + + obp = stringbuf; + nl = 0; do { - c = yylex(); + c = cinput(); + *stringbuf++ = c; if (c == WARN) { gotwarn++; if (rp == NULL) - goto noid; - } else if (c == WSPACE || c == '\n') - ws = 1; - } while (c == WSPACE || c == '\n' || c == WARN); - - cp = (usch *)yytext; - while (*cp) - cp++; - while (cp > (usch *)yytext) - cunput(*--cp); + break; + } + if (c == '\n') + nl++; + } while (c == ' ' || c == '\t' || c == '\n' || + c == '\r' || c == WARN); + DPRINT(("c %d\n", c)); if (c == '(' ) { + cunput(c); + stringbuf = obp; + ifiles->lineno += nl; expdef(vp, &rp2, gotwarn); - return rv; + return 1; } else { - /* restore identifier */ -noid: while (gotwarn--) - cunput(WARN); - if (ws) - cunput(' '); - cp = sp->namep; - while (*cp) - cp++; - while (cp > sp->namep) - cunput(*--cp); + *stringbuf = 0; + unpstr(obp); + unpstr(sp->namep); if ((c = yylex()) != IDENT) error("internal sync error"); + stringbuf = obp; return 0; } } else { @@ -903,18 +1070,18 @@ struct symtab *nl; int c, noexp = 0, orgexp; usch *och, *stksv; - extern int yyleng; #ifdef CPP_DEBUG if (dflag) { struct recur *rp2 = rp; printf("\nexpmac\n"); while (rp2) { - printf("do not expand %s\n", rp->sp->namep); + printf("do not expand %s\n", rp2->sp->namep); rp2 = rp2->next; } } #endif + readmac++; while ((c = yylex()) != WARN) { switch (c) { case NOEXP: noexp++; break; @@ -940,7 +1107,8 @@ else orgexp++; - DDPRINT(("id1: noexp %d orgexp %d\n", noexp, orgexp)); + DDPRINT(("id1: typ %d noexp %d orgexp %d\n", + c, noexp, orgexp)); if (c == IDENT) { /* XXX numbers? */ DDPRINT(("id2: str %s\n", yytext)); /* OK to always expand here? */ @@ -974,6 +1142,8 @@ unpstr((usch *)yytext); if (orgexp == -1) cunput(EXPAND); + else if (orgexp == -2) + cunput(EXPAND), cunput(EXPAND); else if (orgexp == 1) cunput(NOEXP); unpstr(och); @@ -1004,8 +1174,7 @@ error("bad noexp %d", noexp); stksv = NULL; if ((c = yylex()) == WSPACE) { - stksv = alloca(yyleng+1); - strlcpy((char *)stksv, yytext, yyleng+1); + stksv = xstrdup(yytext); c = yylex(); } /* only valid for expansion if fun macro */ @@ -1022,6 +1191,12 @@ unpstr(stksv); savstr(nl->namep); } + if (stksv) + free(stksv); + break; + + case CMNT: + getcmnt(); break; case STRING: @@ -1043,6 +1218,7 @@ } if (noexp) error("expmac noexp=%d", noexp); + readmac--; DPRINT(("return from expmac\n")); } @@ -1053,34 +1229,40 @@ * result is written on top of heap */ void -expdef(vp, rp, gotwarn) - usch *vp; - struct recur *rp; +expdef(usch *vp, struct recur *rp, int gotwarn) { usch **args, *sptr, *ap, *bp, *sp; int narg, c, i, plev, snuff, instr; int ellips = 0; - DPRINT(("expdef %s rp %s\n", vp, (rp ? (char *)rp->sp->namep : ""))); + DPRINT(("expdef rp %s\n", (rp ? (char *)rp->sp->namep : ""))); if ((c = yylex()) != '(') - error("got %c, expected )", c); + error("got %c, expected (", c); if (vp[1] == VARG) { narg = *vp--; ellips = 1; } else narg = vp[1]; - args = alloca(sizeof(usch *) * (narg+ellips)); + if ((args = malloc(sizeof(usch *) * (narg+ellips))) == NULL) + error("expdef: out of mem"); /* * read arguments and store them on heap. * will be removed just before return from this function. */ + inmac = 1; sptr = stringbuf; + instr = 0; for (i = 0; i < narg && c != ')'; i++) { args[i] = stringbuf; plev = 0; while ((c = yylex()) == WSPACE || c == '\n') ; + DDPRINT((":AAA (%d)", c)); + if (instr == -1) + savch(NOEXP), instr = 1; + if (c == NOEXP) + instr = 1; for (;;) { if (plev == 0 && (c == ')' || c == ',')) break; @@ -1091,10 +1273,20 @@ savstr((usch *)yytext); while ((c = yylex()) == '\n') savch('\n'); + while (c == CMNT) { + getcmnt(); + c = yylex(); + } + if (c == EXPAND) + instr = 0; + if (c == 0) + error("eof in macro"); } while (args[i] < stringbuf && (stringbuf[-1] == ' ' || stringbuf[-1] == '\t')) stringbuf--; + if (instr == 1) + savch(EXPAND), instr = -1; savch('\0'); } if (ellips) @@ -1102,8 +1294,12 @@ if (ellips && c != ')') { args[i] = stringbuf; plev = 0; + instr = 0; while ((c = yylex()) == WSPACE) ; + if (c == NOEXP) + instr++; + DDPRINT((":AAY (%d)", c)); for (;;) { if (plev == 0 && c == ')') break; @@ -1111,9 +1307,16 @@ plev++; if (c == ')') plev--; - savstr((usch *)yytext); + if (plev == 0 && c == ',' && instr) { + savch(EXPAND); + savch(','); + savch(NOEXP); + } else + savstr((usch *)yytext); while ((c = yylex()) == '\n') savch('\n'); + if (c == EXPAND) + instr--; } while (args[i] < stringbuf && (stringbuf[-1] == ' ' || stringbuf[-1] == '\t')) @@ -1122,10 +1325,13 @@ } if (narg == 0 && ellips == 0) - c = yylex(); + while ((c = yylex()) == WSPACE || c == '\n') + ; + if (c != ')' || (i != narg && ellips == 0) || (i < narg && ellips == 1)) error("wrong arg count"); + inmac = 0; while (gotwarn--) cunput(WARN); @@ -1147,6 +1353,14 @@ if (sp[-1] == VARG) { bp = ap = args[narg]; sp--; +#ifdef GCC_VARI + } else if (sp[-1] == GCCARG) { + ap = args[narg]; + if (ap[0] == 0) + ap = (usch *)"0"; + bp = ap; + sp--; +#endif } else bp = ap = args[(int)*--sp]; if (sp[2] != CONC && !snuff && sp[-1] != CONC) { @@ -1192,6 +1406,7 @@ /* scan the input buffer (until WARN) and save result on heap */ expmac(rp); + free(args); } usch * @@ -1255,6 +1470,10 @@ putstr(usch *s) { for (; *s; s++) { + if (*s == PRAGS) { + s = prtprag(s); + continue; + } outbuf[obufp++] = *s; if (obufp == CPPBUF || (istty && *s == '\n')) flbuf(); @@ -1480,3 +1699,41 @@ return (struct symtab *)new->lr[bit]; } +usch * +xstrdup(char *str) +{ + size_t len = strlen(str)+1; + usch *rv; + + if ((rv = malloc(len)) == NULL) + error("xstrdup: out of mem"); + strlcpy((char *)rv, str, len); + return rv; +} + +usch * +prtprag(usch *s) +{ + int ch; + + s++; + putstr((usch *)"\n#pragma "); + while (*s != PRAGE) { + if (*s == 'L') + s++; + if (*s == '\"') { + s++; + while ((ch = *s++) != '\"') { + if (ch == '\\' && (*s == '\"' || *s == '\\')) + ch = *s++; + putch(ch); + } + } else { + s++; + putch(*s); + } + } + putstr((usch *)"\n"); + prtline(); + return ++s; +} Index: cpy.y =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/cpy.y,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/cpp/cpy.y -L usr.bin/pcc/cpp/cpy.y -u -r1.1 -r1.2 --- usr.bin/pcc/cpp/cpy.y +++ usr.bin/pcc/cpp/cpy.y @@ -1,4 +1,4 @@ -/* $Id: cpy.y,v 1.12 2006/10/08 13:41:39 ragge Exp $ */ +/* $Id: cpy.y,v 1.16 2008/04/12 17:14:27 ragge Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -62,23 +62,34 @@ */ %{ -#include -#include -#include + +#include "cpp.h" + void yyerror(char *); int yylex(void); +int setd(int l, int r); + +#define EVALUNARY(tok, l, r) l.nd_val = tok r.nd_val; l.op = r.op +#define EVALBIN(tok, d, l, r) \ + d.op = setd(l.op, r.op); d.nd_val = l.nd_val tok r.nd_val +#define EVALUBIN(tok, d, l, r, t) \ + d.op = setd(l.op, r.op); \ + if (d.op == NUMBER) d.nd_val = l.nd_val tok r.nd_val; \ + else d.nd_uval = l.nd_uval tok r.nd_uval; \ + if (t && d.op) d.op = NUMBER +#define XEVALUBIN(tok, d, l, r) \ + if (r.nd_val) { EVALUBIN(tok, d, l, r, 0); } else d.op = 0 %} %term stop %term EQ NE LE GE LS RS -%term ANDAND OROR IDENT NUMBER +%term ANDAND OROR IDENT NUMBER UNUMBER /* * The following terminals are not used in the yacc code. */ -%term STRING FPOINT WSPACE VA_ARGS CONCAT MKSTR ELLIPS +%term STRING FPOINT WSPACE VA_ARGS CONCAT MKSTR ELLIPS CMNT %left ',' -%right '=' %right '?' ':' %left OROR %left ANDAND @@ -90,77 +101,117 @@ %left '+' '-' %left '*' '/' '%' %right '!' '~' UMINUS -%left '(' '.' +%left '(' %union { - long long val; + struct nd node; } -%type term NUMBER e +%type term e NUMBER UNUMBER %% -S: e '\n' { return($1 != 0);} - +S: e '\n' { + if ($1.op == 0) + error("division by zero"); + return $1.nd_val; + } e: e '*' e - {$$ = $1 * $3;} + { EVALUBIN(*, $$, $1, $3, 0); } | e '/' e - {$$ = $1 / $3;} + { XEVALUBIN(/, $$, $1, $3); } | e '%' e - {$$ = $1 % $3;} + { XEVALUBIN(%, $$, $1, $3); } | e '+' e - {$$ = $1 + $3;} + { EVALBIN(+, $$, $1, $3); } | e '-' e - {$$ = $1 - $3;} + { EVALBIN(-, $$, $1, $3); } | e LS e - {$$ = $1 << $3;} + { EVALBIN(<<, $$, $1, $3); } | e RS e - {$$ = $1 >> $3;} + { EVALUBIN(>>, $$, $1, $3, 0); } | e '<' e - {$$ = $1 < $3;} + { EVALUBIN(<, $$, $1, $3, 1); } | e '>' e - {$$ = $1 > $3;} + { EVALUBIN(>, $$, $1, $3, 1); } | e LE e - {$$ = $1 <= $3;} + { EVALUBIN(<=, $$, $1, $3, 1); } | e GE e - {$$ = $1 >= $3;} + { EVALUBIN(>=, $$, $1, $3, 1); } | e EQ e - {$$ = $1 == $3;} + { EVALUBIN(==, $$, $1, $3, 1); } | e NE e - {$$ = $1 != $3;} + { EVALUBIN(!=, $$, $1, $3, 1); } | e '&' e - {$$ = $1 & $3;} + { EVALBIN(&, $$, $1, $3); } | e '^' e - {$$ = $1 ^ $3;} + { EVALBIN(^, $$, $1, $3); } | e '|' e - {$$ = $1 | $3;} - | e ANDAND e - {$$ = $1 && $3;} - | e OROR e - {$$ = $1 || $3;} - | e '?' e ':' e - {$$ = $1 ? $3 : $5;} - | e ',' e - {$$ = $3;} + { EVALBIN(|, $$, $1, $3); } + | e ANDAND e { + $$ = $1; + if ($1.nd_val) { + $$.op = setd($1.op, $3.op); + $$.nd_val = ($3.nd_val != 0); + } + if ($$.op == UNUMBER) $$.op = NUMBER; + } + | e OROR e { + if ($1.nd_val != 0) { + $$.nd_val = ($1.nd_val != 0); + $$.op = $1.op; + } else { + $$.nd_val = ($3.nd_val != 0); + $$.op = setd($1.op, $3.op); + } + if ($$.op == UNUMBER) $$.op = NUMBER; + } + | e '?' e ':' e { + if ($1.op == 0) + $$ = $1; + else if ($1.nd_val) + $$ = $3; + else + $$ = $5; + } + | e ',' e { + $$.op = setd($1.op, $3.op); + $$.nd_val = $3.nd_val; + if ($$.op) $$.op = $3.op; + } | term {$$ = $1;} term: '-' term %prec UMINUS - {$$ = -$2;} + { EVALUNARY(-, $$, $2); } + | '+' term %prec UMINUS + {$$ = $2;} | '!' term - {$$ = !$2;} + { $$.nd_val = ! $2.nd_val; $$.op = $2.op ? NUMBER : 0; } | '~' term - {$$ = ~$2;} + { EVALUNARY(~, $$, $2); } | '(' e ')' {$$ = $2;} | NUMBER - {$$= $1;} + {$$ = $1;} %% -#include "cpp.h" - void yyerror(char *err) { error(err); } + +/* + * Set return type of an expression. + */ +int +setd(int l, int r) +{ + if (!l || !r) + return 0; /* div by zero involved */ + if (l == UNUMBER || r == UNUMBER) + return UNUMBER; + return NUMBER; +} + Index: cpp.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/cpp.h,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/cpp/cpp.h -L usr.bin/pcc/cpp/cpp.h -u -r1.2 -r1.3 --- usr.bin/pcc/cpp/cpp.h +++ usr.bin/pcc/cpp/cpp.h @@ -1,4 +1,4 @@ -/* $Id: cpp.h,v 1.27 2007/09/17 18:16:14 ragge Exp $ */ +/* $Id: cpp.h,v 1.37 2008/07/02 01:12:41 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -28,8 +28,9 @@ */ #include /* for obuf */ +#include -#include "../config.h" +#include "config.h" typedef unsigned char usch; #ifdef YYTEXT_POINTER @@ -43,7 +44,7 @@ extern int flslvl; extern int elflvl; extern int elslvl; -extern int tflag, Cflag; +extern int tflag, Cflag, Pflag; extern int Mflag, dMflag; extern usch *Mfile; extern int ofd; @@ -72,6 +73,7 @@ int infil; usch *curptr; usch *maxread; + usch *ostr; usch *buffer; usch bbuf[NAMEMAX+CPPBUF+1]; } *ifiles; @@ -90,6 +92,23 @@ char *str; }; +/* + * Struct used in parse tree evaluation. + * op is one of: + * - number type (NUMBER, UNUMBER) + * - zero (0) if divided by zero. + */ +struct nd { + int op; + union { + long long val; + unsigned long long uval; + } n; +}; + +#define nd_val n.val +#define nd_uval n.uval + struct recur; /* not used outside cpp.c */ int subst(struct symtab *, struct recur *); struct symtab *lookup(usch *namep, int enterf); @@ -115,6 +134,15 @@ void putstr(usch *s); void line(void); usch *sheap(char *fmt, ...); +void xwarning(usch *); void xerror(usch *); +#ifdef HAVE_CPP_VARARG_MACRO_GCC +#define warning(...) xwarning(sheap(__VA_ARGS__)) #define error(...) xerror(sheap(__VA_ARGS__)) +#else +#define warning printf +#define error printf +#endif void expmac(struct recur *); +int cinput(void); +void getcmnt(void); --- /dev/null +++ usr.bin/pcc/cpp/pcpp.1 @@ -0,0 +1,210 @@ +.\" $Id: cpp.1,v 1.10 2008/07/02 01:12:41 gmcgarry Exp $ +.\" $NetBSD$ +.\" $OpenBSD$ +."\ +.\" Copyright (c) 2007 Jeremy C. Reed +.\" +.\" Permission to use, copy, modify, and/or distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above +.\" copyright notice and this permission notice appear in all copies. +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM +.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND +.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS +.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +.\" THIS SOFTWARE. +.\" +.Dd September 17, 2007 +.Dt CPP 1 +.Os +.Sh NAME +.Nm cpp +.Nd C preprocessor +.Sh SYNOPSIS +.Nm +.\" TODO also document -Dvar and below without spaces? +.Op Fl CdMtVv +.Op Fl D Ar macro[=value] +.Op Fl I Ar path +.Op Fl i Ar file +.Op Fl S Ar path +.Op Fl U Ar macro +.Op Ar infile | - +.Op Ar outfile +.Sh DESCRIPTION +The +.Nm +utility is a macro preprocessor used by the +.Xr pcc 1 +compiler. +It is used to include header files, +expand macro definitions, +and perform conditional compilation. +.Pp +The +.Ar infile +input file is optional. +If not provided or the file name is +.Qq - +(dash), +.Nm +reads its initial file from standard input. +The +.Ar outfile +output file is also optional. +It writes by default to standard output. +.Pp +.\" TODO: document MAXARG 250 args to a macro, limited by char value +.\" TODO: Include order: +.\" For "..." files, first search "current" dir, then as <...> files. +.\" For <...> files, first search -I directories, then system directories. +.\" +The options are as follows: +.Bl -tag -width Ds +.It Fl ? +Show command line usage for +.Nm . +.It Fl C +Do not discard comments. +.It Fl D Ar macro[=value] +Fake a definition at the beginning by using +.Do #define +.Ar macro=value Dc . +If +.Ar value +is not set on command-line, then define it as 1. +.\" TODO: show example +.It Fl dM +Print list of +.Dq #define +statements to standard output for all defined macros other than +builtin macros (see below). +The normal results of preprocessing are not output. +.\" TODO this doesn't show predefined macros +.\" other -d options are ignored +.It Fl I Ar path +Add +.Ar path +to the list of directories containing needed header files. +This may be used to override system include directories +(see +.Fl S +option). +.Fl I +may be specified multiple times. +.It Fl i Ar file +Include a file at the beginning by using +.Do #include +.Ar file Dc . +.\" Note: I did not use the .In macro above +.It Fl M +Generate dependencies for +.Xr make 1 . +.\" TODO: explain and show example? +.It Fl P +Inhibit generation of line markers. This is sometimes useful when +running the preprocessor on something other than C code. +.It Fl S Ar path +Add +.Ar path +to the list of system directories containing needed header files. +The +.Fl S +option may be specified multiple times. +Note: +.Nm +does not have a default include directory defined. +.\" TODO: explain difference between -I and -S +.\" The directories listed by -I are searched first? +.It Fl t +Traditional cpp syntax. +Do not define the +.Dv __TIME__ , +.Dv __DATE__ , +.Dv __STDC__ , +and +.Dv __STDC_VERSION__ +macros. +.\" +.It Fl U Ar macro +Undefine a macro at the beginning by using +.Do #undef +.Ar macro Dc . +.It Fl V +Verbose debugging output. +.Fl V +can be repeated for further details. +.\" -V only available if cpp source built with CPP_DEBUG, which is the default. +.It Fl v +Display version. +.El +.Ss Builtin Macros +A few macros are interpreted inside the +.Nm cpp +program: +.Bl -diag +.It __DATE__ +Expands to the date in abbreviated month, day, and year format from +.Xr ctime 3 +in quotes. +.\" TODO: is that ctime(3) format output change according to locale? +.It __FILE__ +Expands to the name of the current input file in quotes. +When read from standard input, it expands to +.Qq Aq stdin . +.It __LINE__ +Expands to the line number of the current line containing the macro. +.It __STDC__ +Expands to the constant 1. +This means the compiler conforms to +.St -isoC +.Po also known as +.Do C90 Dc Pc . +.It __STDC_VERSION__ +Expands to +.Dq 199901L +which indicates that +.Nm +supports +.St -isoC-99 +.Po commonly referred to as +.Do C99 Dc Pc . +.It __TIME__ +Expands to the time in hour, minutes, and seconds from +.Xr ctime 3 +in quotes. +.El +.Pp +Also see the +.Fl t +option. +.Sh EXIT STATUS +The +.Nm +utility exits with one of the following values: +.Bl -tag -width Ds +.It 0 +Successfully finished. +.It 1 +An error occurred. +.El +.Sh SEE ALSO +.Xr as 1 , +.Xr ccom 1 , +.Xr pcc 1 +.\" +.Sh HISTORY +The +.Nm +command comes from the original Portable C Compiler by S. C. Johnson, +written in the late 70's. +The code originates from the V6 preprocessor with some additions +from V7 cpp and ansi/c99 support. +.Pp +A lot of the PCC code was rewritten by Anders Magnusson. +.Pp +This product includes software developed or owned by Caldera +International, Inc. Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/Makefile,v retrieving revision 1.6 retrieving revision 1.7 diff -L usr.bin/pcc/cpp/Makefile -L usr.bin/pcc/cpp/Makefile -u -r1.6 -r1.7 --- usr.bin/pcc/cpp/Makefile +++ usr.bin/pcc/cpp/Makefile @@ -5,13 +5,11 @@ PROG= pcpp TARGOS= midnightbsd BINDIR= ${libexecdir} -NO_MAN= -#MAN= cpp.1 -#MANDIR= /usr/local/man/man +MAN= pcpp.1 CFLAGS+= -DCPP_DEBUG -Wall -Wmissing-prototypes -Wstrict-prototypes -Werror CFLAGS+= -DLIBEXECDIR=\"${libexecdir}\" -CFLAGS+= -I. -I${.CURDIR} +CFLAGS+= -I. -I${.CURDIR} -I${.CURDIR}/.. -I${.CURDIR}/../mip/ SRCS= cpy.y scanner.l cpp.c CLEANFILES+= y.tab.c y.tab.h --- usr.bin/pcc/cpp/cpp.1 +++ /dev/null @@ -1,191 +0,0 @@ -.\" $Id: cpp.1,v 1.4 2007/09/26 14:48:51 ragge Exp $ -.\" $NetBSD$ -.\" $OpenBSD$ -."\ -.\" Copyright (c) 2007 Jeremy C. Reed -.\" -.\" Permission to use, copy, modify, and/or distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above -.\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM -.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND -.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL -.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR -.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS -.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF -.\" THIS SOFTWARE. -.\" -.Dd September 17, 2007 -.Dt cpp 1 -.Os -.Sh NAME -.Nm cpp -.Nd C preprocessor -.Sh SYNOPSIS -.Nm -.\" TODO also document -Dvar and below without spaces? -.Op Fl Cdt -.Op Fl D Ar var=val -.Op Fl U Ar var -.Op Fl I Ar path -.Op Fl S Ar path -.Op Ar infile | - -.Op Ar outfile -.Pp -.Sh DESCRIPTION -The -.Nm -utility is a macro preprocessor used by the -.Xr pcc 1 -compiler. -It is used to include header files, -expand macro definitions, -and perform conditional compilation. -.Pp -The -.Ar infile -input file is optional. -If not provided or the file name is -.Qq - -(dash), -.Nm -reads its initial file from standard input. -The -.Ar outfile -output file is also optional. -It writes by default to standard output. -.Pp -.\" TODO: document MAXARG 250 args to a macro, limited by char value -.\" TODO: Include order: -.\" For "..." files, first search "current" dir, then as <...> files. -.\" For <...> files, first search -I directories, then system directories. -.\" -The options are as follows: -.Bl -tag -width Ds -.It Fl C -Do not discard comments. -.It Fl dM -Print list of -.Dq #define -statements to standard output for all defined macros other than -builtin macros (see below). -The normal results of preprocessing are not outputted. -.\" TODO this doesn't show predefined macros -.\" other -d options are ignored -.It Fl D Ar macro[=value] -Fake a definition at the beginning by using -.Do #define -.Ar macro=value Dc . -If -.Ar value -is not set on command-line, then defines as 1. -.\" TODO: show example -.It Fl i Ar file -Include a file at the beginning by using -.Do #include -.Ar file Dc . -.\" Note: I did not use the .In macro above -.It Fl I Ar directory -Add -.Ar directory -to the list of system directories containing needed header files. -This may be used to override system include directories -(see -.Fl S -option). -.Fl I -may be specified multiple times. -.It Fl M -Generate dependencies for -.Xr make 1 . -.\" TODO: explain and show example? -.It Fl S Ar directory -Add -.Ar directory -to the list of system directories containing needed header files. -.Fl S -may be specified multiple times. -Note: -.Nm -does not have a default include directory defined. -.\" TODO: explain difference between -I and -S -.\" The directories listed by -I are searched first? -.It Fl t -Traditional cpp syntax. -Do not define the -.Dv __TIME__ , -.Dv __DATE__ , -and -.Dv __STDC__ -macros. -.\" -.It Fl U Ar macro -Undefine a macro at the beginning by using -.Do #undef -.Ar macro Dc . -.It Fl v -Verbose debugging output. -.Fl v -can be repeated for further details. -.\" -v only available if cpp source built with CPP_DEBUG, which is the default. -.It Fl ? -Show command line usage for -.Nm . -.El -.Sh Builtin Macros -A few macros are interpreted inside the -.Nm cpp -program: -.Bl -diag -.It __DATE__ -Expands to the date in abbreviated month, day, and year format from -.Xr ctime 3 -in quotes. -.\" TODO: is that ctime(3) format output change according to locale? -.It __FILE__ -Expands to the name of the current input file in quotes. -When read from standard input, it expands to -.Qq Ao stdin Ac . -.It __LINE__ -Expands to the line number of the current line containing the macro. -.It __STDC__ -Expands to the constant 1. -This means the compiler conforms to ISO Standard C. -.It __TIME__ -Expands to the time in hour, minutes, and seconds from -.Xr ctime 3 -in quotes. -.El -.Pp -Also see the -.Fl t -option. -.Sh EXIT STATUS -The -.Nm -utility exits with one of the following values: -.Bl -tag -width Ds -.It 0 -Successfully finished. -.It 1 -An error occurred. -.El -.Sh SEE ALSO -.Xr as 1 , -.Xr ccom 1 , -.Xr pcc 1 -.\" -.Sh HISTORY -The -.Nm -command comes from the original Portable C Compiler by S. C. -Johnson, written in the late 70's. -The code originates from the V6 preprocessor with some additions -from V7 cpp and ansi/c99 support. -.Pp -A lot of the PCC code was rewritten by Anders Magnusson. -.Pp -This product includes software developed or owned by Caldera -International, Inc. Index: order.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/order.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/order.c -L usr.bin/pcc/i386/order.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/order.c +++ usr.bin/pcc/i386/order.c @@ -1,4 +1,4 @@ -/* $Id: order.c,v 1.49 2007/08/01 04:53:58 ragge Exp $ */ +/* $Id: order.c,v 1.54 2008/09/27 07:35:22 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -103,26 +103,16 @@ * Shape matches for UMUL. Cooperates with offstar(). */ int -shumul(NODE *p) +shumul(NODE *p, int shape) { if (x2debug) printf("shumul(%p)\n", p); /* Turns currently anything into OREG on x86 */ - return SOREG; -} - -/* - * Rewrite increment/decrement operation. - */ -int -setincr(NODE *p) -{ - if (x2debug) - printf("setincr(%p)\n", p); - - return(0); + if (shape & SOREG) + return SROREG; + return SRNOPE; } /* @@ -183,8 +173,8 @@ static struct rspecial s[] = { { NOLEFT, ESI }, { NOLEFT, EDI }, { 0 } }; return s; - } else if ((q->ltype & (TINT|TUNSIGNED)) && - q->rtype == TLONGLONG) { + } else if ((q->ltype & TINT) && + q->rtype == (TLONGLONG|TULONGLONG)) { static struct rspecial s[] = { { NLEFT, EAX }, { NRES, EAXEDX }, { NEVER, EAX }, { NEVER, EDX }, { 0 } }; @@ -285,3 +275,30 @@ { return 0; /* nothing differs on x86 */ } + +/* + * set registers in calling conventions live. + */ +int * +livecall(NODE *p) +{ + static int r[] = { EAX, EBX, -1 }; + int off = 1; + +#ifdef TLS + if (p->n_left->n_op == ICON && + strcmp(p->n_left->n_name, "___tls_get_addr at PLT") == 0) + off--; +#endif + + return kflag ? &r[off] : &r[2]; +} + +/* + * Signal whether the instruction is acceptable for this target. + */ +int +acceptable(struct optab *op) +{ + return 1; +} Index: macdefs.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/macdefs.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/macdefs.h -L usr.bin/pcc/i386/macdefs.h -u -r1.1 -r1.2 --- usr.bin/pcc/i386/macdefs.h +++ usr.bin/pcc/i386/macdefs.h @@ -1,4 +1,4 @@ -/* $Id: macdefs.h,v 1.46 2007/08/19 19:25:22 ragge Exp $ */ +/* $Id: macdefs.h,v 1.67 2008/12/14 18:26:43 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -65,8 +65,9 @@ #define ALLONGLONG 32 #define ALSHORT 16 #define ALPOINT 32 -#define ALSTRUCT 32 +#undef ALSTRUCT /* Not defined if ELF ABI */ #define ALSTACK 32 +#define ALMAX 128 /* not yet supported type */ /* * Min/max values. @@ -77,7 +78,7 @@ #define MIN_SHORT -32768 #define MAX_SHORT 32767 #define MAX_USHORT 65535 -#define MIN_INT -1 +#define MIN_INT (-0x7fffffff-1) #define MAX_INT 0x7fffffff #define MAX_UNSIGNED 0xffffffff #define MIN_LONG MIN_INT @@ -90,7 +91,11 @@ /* Default char is signed */ #undef CHAR_UNSIGNED #define BOOL_TYPE CHAR /* what used to store _Bool */ +#if defined(os_mirbsd) || defined(os_win32) +#define WCHAR_TYPE USHORT /* ISO 10646 16-bit Unicode */ +#else #define WCHAR_TYPE INT /* what used to store wchar_t */ +#endif /* * Use large-enough types. @@ -100,36 +105,37 @@ typedef long long OFFSZ; #define CONFMT "%lld" /* format for printing constants */ +#if defined(ELFABI) #define LABFMT ".L%d" /* format for printing labels */ #define STABLBL ".LL%d" /* format for stab (debugging) labels */ -#ifdef FORTRAN -#define XL 8 -#define FLABELFMT "%s:\n" -#define USETEXT ".text" -#define USECONST ".data\t0" /* XXX - fix */ -#define USEBSS ".data\t1" /* XXX - fix */ -#define USEINIT ".data\t2" /* XXX - fix */ -#define MAXREGVAR 3 /* XXX - fix */ +#else +#define LABFMT "L%d" /* format for printing labels */ +#define STABLBL "LL%d" /* format for stab (debugging) labels */ +#endif +#ifdef LANG_F77 #define BLANKCOMMON "_BLNK_" #define MSKIREG (M(TYSHORT)|M(TYLONG)) #define TYIREG TYLONG #define FSZLENG FSZLONG -#define FUDGEOFFSET 1 #define AUTOREG EBP #define ARGREG EBP -#define ARGOFFSET 4 +#define ARGOFFSET 8 +#endif + +#ifdef MACHOABI +#define STAB_LINE_ABSOLUTE /* S_LINE fields use absolute addresses */ #endif #define BACKAUTO /* stack grows negatively for automatics */ #define BACKTEMP /* stack grows negatively for temporaries */ -#define MYP2TREE(p) myp2tree(p); - #undef FIELDOPS /* no bit-field instructions */ #define RTOLBYTES /* bytes are numbered right to left */ #define ENUMSIZE(high,low) INT /* enums are always stored in full int */ +#define FINDMOPS /* i386 has instructions that modifies memory */ + /* Definitions mostly used in pass2 */ #define BYTEOFF(x) ((x)&03) @@ -292,10 +298,69 @@ #define FPREG EBP /* frame pointer */ #define STKREG ESP /* stack pointer */ -#define MYREADER(p) myreader(p) -#define MYCANON(p) mycanon(p) -#define MYOPTIM - #define SHSTR (MAXSPECIAL+1) /* short struct */ #define SFUNCALL (MAXSPECIAL+2) /* struct assign after function call */ #define SPCON (MAXSPECIAL+3) /* positive nonnamed constant */ + +/* + * Specials that indicate the applicability of machine idioms. + */ +#define SMIXOR (MAXSPECIAL+4) +#define SMILWXOR (MAXSPECIAL+5) +#define SMIHWXOR (MAXSPECIAL+6) + +/* + * i386-specific symbol table flags. + */ +#define SSECTION SLOCAL1 +#define STLS SLOCAL2 +#define SNOUNDERSCORE SLOCAL3 +#define SSTDCALL SLOCAL2 +#define SDLLINDIRECT SLOCAL3 + +/* + * i386-specific node flags. + */ +#define FSTDCALL 0x01 + +/* + * i386-specific interpass stuff. + */ + +#define TARGET_IPP_MEMBERS \ + int ipp_argstacksize; + +/* + * Extended assembler macros. + */ +void targarg(char *w, void *arg); +#define XASM_TARGARG(w, ary) \ + (w[1] == 'b' || w[1] == 'h' || w[1] == 'w' || w[1] == 'k' ? \ + w++, targarg(w, ary), 1 : 0) +int numconv(void *ip, void *p, void *q); +#define XASM_NUMCONV(ip, p, q) numconv(ip, p, q) +int xasmconstregs(char *); +#define XASMCONSTREGS(x) xasmconstregs(x) + +/* + * builtins. + */ +#define TARGET_BUILTINS \ + { "__builtin_frame_address", i386_builtin_frame_address }, \ + { "__builtin_return_address", i386_builtin_return_address }, + +#define NODE struct node +struct node; +NODE *i386_builtin_frame_address(NODE *f, NODE *a); +NODE *i386_builtin_return_address(NODE *f, NODE *a); +#undef NODE + +#if defined(MACHOABI) +struct stub { + struct { struct stub *q_forw, *q_back; } link; + char *name; +}; +extern struct stub stublist; +extern struct stub nlplist; +void addstub(struct stub *list, char *name); +#endif Index: table.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/table.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/table.c -L usr.bin/pcc/i386/table.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/table.c +++ usr.bin/pcc/i386/table.c @@ -1,4 +1,4 @@ -/* $Id: table.c,v 1.96 2007/09/20 14:52:13 ragge Exp $ */ +/* $Id: table.c,v 1.110 2008/11/24 14:52:02 mickey Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -133,7 +133,7 @@ { SCONV, INLL, SHCH|SOREG|SNAME, TCHAR, SANY, TLL, - NSPECIAL|NAREG|NASL, RESC1, + NSPECIAL|NCREG|NCSL, RESC1, " movsbl AL,%eax\n cltd\n", }, /* convert unsigned char to (u)long long */ @@ -229,7 +229,7 @@ /* convert int to char. This is done when register is loaded */ { SCONV, INCH, - SAREG, TWORD, + SAREG, TWORD|TPOINT, SANY, TCHAR|TUCHAR, NSPECIAL|NBREG|NBSL, RESC1, "ZM", }, @@ -241,17 +241,17 @@ 0, RLEFT, "", }, -/* convert int to long long */ +/* convert signed int to (u)long long */ { SCONV, INLL, - SAREG, TWORD|TPOINT, - SCREG, TLONGLONG, + SHINT, TSWORD, + SHLL, TLL, NSPECIAL|NCREG|NCSL, RESC1, " cltd\n", }, -/* convert int to unsigned long long */ +/* convert unsigned int to (u)long long */ { SCONV, INLL, - SAREG|SOREG|SNAME, TWORD|TPOINT, - SHLL, TULONGLONG, + SHINT|SOREG|SNAME, TUWORD|TPOINT, + SHLL, TLL, NCSL|NCREG, RESC1, " movl AL,A1\n xorl U1,U1\n", }, @@ -275,14 +275,14 @@ { SCONV, INCH, SOREG|SNAME, TLL, SANY, TCHAR|TUCHAR, - NAREG|NASL, RESC1, + NBREG|NBSL, RESC1, " movb AL,A1\n", }, /* convert (u)long long to (u)char (reg->reg, hopefully nothing) */ { SCONV, INCH, SHLL, TLL, SANY, TCHAR|TUCHAR, - NAREG|NASL, RESC1, + NBREG|NBSL, RESC1, "ZS", }, /* convert (u)long long to (u)short (mem->reg) */ @@ -358,7 +358,19 @@ SHFL, TLDOUBLE|TDOUBLE|TFLOAT, SAREG, TWORD, NAREG, RESC1, +#ifdef notdef /* Must round down and nothing else */ " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, +#else + " subl $12,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpl 8(%esp)\n" + " movl 8(%esp),A1\n" + " fldcw 4(%esp)\n" + " addl $12,%esp\n", }, +#endif /* convert float/double (in register) to (unsigned) long long */ /* XXX - unsigned is not handled correct */ @@ -366,8 +378,21 @@ SHFL, TLDOUBLE|TDOUBLE|TFLOAT, SHLL, TLONGLONG|TULONGLONG, NCREG, RESC1, +#ifdef notdef /* Must round down and nothing else */ " subl $8,%esp\n fistpq (%esp)\n" " popl A1\n popl U1\n", }, +#else + " subl $16,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpq 8(%esp)\n" + " movl 8(%esp),A1\n" + " movl 12(%esp),U1\n" + " fldcw 4(%esp)\n" + " addl $16,%esp\n", }, +#endif /* slut sconv */ @@ -389,13 +414,13 @@ { CALL, INAREG, SCON, TANY, - SAREG, TWORD|TPOINT, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, NAREG|NASL, RESC1, /* should be 0 */ " call CL\nZC", }, { UCALL, INAREG, SCON, TANY, - SAREG, TWORD|TPOINT, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, NAREG|NASL, RESC1, /* should be 0 */ " call CL\n", }, @@ -573,6 +598,12 @@ NAREG|NASL, RESC1, " leal CR(AL),A1\n", }, +{ PLUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " incw AL\n", }, + { PLUS, INCH|FOREFF, SHCH|SNAME|SOREG, TCHAR|TUCHAR, SONE, TANY, @@ -591,6 +622,12 @@ 0, RLEFT, " decl AL\n", }, +{ MINUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " decw AL\n", }, + { MINUS, INCH|FOREFF, SHCH|SNAME|SOREG, TCHAR|TUCHAR, SONE, TANY, @@ -623,48 +660,81 @@ " fsubZAp\n", }, /* Simple r/m->reg ops */ -{ OPSIMP, INAREG|FOREFF, +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD|TPOINT, + SAREG, TWORD|TPOINT, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, SAREG, TWORD|TPOINT, SAREG|SNAME|SOREG, TWORD|TPOINT, - 0, RLEFT, + 0, RLEFT|RESCC, " Ol AR,AL\n", }, -{ OPSIMP, INAREG|FOREFF, +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + SHINT, TSHORT|TUSHORT, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, SHINT, TSHORT|TUSHORT, SHINT|SNAME|SOREG, TSHORT|TUSHORT, - 0, RLEFT, + 0, RLEFT|RESCC, " Ow AR,AL\n", }, -{ OPSIMP, INCH|FOREFF, +/* m/r |= r */ +{ OPSIMP, INCH|FOREFF|FORCC, SHCH, TCHAR|TUCHAR, SHCH|SNAME|SOREG, TCHAR|TUCHAR, - 0, RLEFT, + 0, RLEFT|RESCC, " Ob AR,AL\n", }, -{ OPSIMP, INAREG|FOREFF, - SAREG, TWORD|TPOINT, +/* r |= r/m */ +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* m/r |= const */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD|TPOINT, SCON, TWORD|TPOINT, - 0, RLEFT, + 0, RLEFT|RESCC, " Ol AR,AL\n", }, -{ OPSIMP, INAREG|FOREFF, +{ OPSIMP, INAREG|FOREFF|FORCC, SHINT|SNAME|SOREG, TSHORT|TUSHORT, SCON, TANY, - 0, RLEFT, + 0, RLEFT|RESCC, " Ow AR,AL\n", }, -{ OPSIMP, INCH|FOREFF, +{ OPSIMP, INCH|FOREFF|FORCC, SHCH|SNAME|SOREG, TCHAR|TUCHAR, SCON, TANY, - 0, RLEFT, + 0, RLEFT|RESCC, " Ob AR,AL\n", }, +/* r |= r/m */ { OPSIMP, INLL|FOREFF, SHLL, TLL, SHLL|SNAME|SOREG, TLL, 0, RLEFT, " Ol AR,AL\n Ol UR,UL\n", }, +/* m/r |= r/const */ +{ OPSIMP, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL, + SHLL|SCON, TLL, + 0, RLEFT, + " Ol AR,AL\n Ol UR,UL\n", }, + /* * The next rules handle all shift operators. @@ -676,24 +746,28 @@ NSPECIAL|NCREG|NCSL|NCSR, RESC1, "ZO", }, +/* r/m <<= r */ { LS, INAREG|FOREFF, SAREG|SNAME|SOREG, TWORD, SHCH, TCHAR|TUCHAR, NSPECIAL, RLEFT, " sall AR,AL\n", }, +/* r/m <<= const */ { LS, INAREG|FOREFF, - SAREG, TWORD, + SAREG|SNAME|SOREG, TWORD, SCON, TANY, 0, RLEFT, " sall AR,AL\n", }, +/* r/m <<= r */ { LS, INAREG|FOREFF, SAREG|SNAME|SOREG, TSHORT|TUSHORT, SHCH, TCHAR|TUCHAR, NSPECIAL, RLEFT, " shlw AR,AL\n", }, +/* r/m <<= const */ { LS, INAREG|FOREFF, SAREG|SNAME|SOREG, TSHORT|TUSHORT, SCON, TANY, @@ -727,7 +801,7 @@ { RS, INAREG|FOREFF, SAREG|SNAME|SOREG, TSWORD, - SCON, TWORD|TCHAR|TUCHAR|TSHORT|TUSHORT, + SCON, TANY, 0, RLEFT, " sarl AR,AL\n", }, @@ -739,7 +813,7 @@ { RS, INAREG|FOREFF, SAREG|SNAME|SOREG, TUWORD, - SCON, TWORD|TCHAR|TUCHAR|TSHORT|TUSHORT, + SCON, TANY, 0, RLEFT, " shrl AR,AL\n", }, @@ -794,17 +868,41 @@ /* * The next rules takes care of assignments. "=". */ +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL, + SMIXOR, TANY, + 0, RDEST, + " xorl AL,AL\n xorl UL,UL\n", }, + +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL, + SMILWXOR, TANY, + 0, RDEST, + " xorl AL,AL\n movl UR,UL\n", }, + +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL, + SMIHWXOR, TANY, + 0, RDEST, + " movl AR,AL\n xorl UL,UL\n", }, + +{ ASSIGN, FOREFF|INLL, + SHLL, TLL, + SCON, TANY, + 0, RDEST, + " movl AR,AL\n movl UR,UL\n", }, + { ASSIGN, FOREFF, SHLL|SNAME|SOREG, TLL, SCON, TANY, 0, 0, " movl AR,AL\n movl UR,UL\n", }, -{ ASSIGN, FOREFF|INLL, - SHLL, TLL, - SCON, TANY, +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TWORD|TPOINT, + SMIXOR, TANY, 0, RDEST, - " movl AR,AL\n movl UR,UL\n", }, + " xorl AL,AL\n", }, { ASSIGN, FOREFF, SAREG|SNAME|SOREG, TWORD|TPOINT, @@ -818,6 +916,12 @@ 0, RDEST, " movl AR,AL\n", }, +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + 0, RDEST, + " xorw AL,AL\n", }, + { ASSIGN, FOREFF, SAREG|SNAME|SOREG, TSHORT|TUSHORT, SCON, TANY, @@ -875,20 +979,40 @@ { ASSIGN, FOREFF|INBREG, SFLD, TCHAR|TUCHAR, SBREG|SCON, TCHAR|TUCHAR, - NBREG, RDEST, - "ZE", }, + NAREG|NBREG, RDEST, + " movb AR,A2\n" + " movzbl A2,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movb AR,AD\n" + "FZE", }, { ASSIGN, FOREFF|INAREG, - SFLD, TANY, - SAREG, TANY, + SFLD, TSHORT|TUSHORT, + SAREG|SCON, TSHORT|TUSHORT, NAREG, RDEST, - "ZE", }, + " movw AR,A1\n" + " movzwl A1,ZN\n" + " andl $N,AL\n" + " sall $H,ZN\n" + " andl $M,ZN\n" + " orl ZN,AL\n" + "F movw AR,AD\n" + "FZE", }, -{ ASSIGN, FOREFF, - SFLD, TANY, - SAREG|SNAME|SOREG|SCON, TANY, - NAREG, 0, - "ZE", }, +{ ASSIGN, FOREFF|INAREG, + SFLD, TWORD, + SAREG|SNAME|SOREG|SCON, TWORD, + NAREG, RDEST, + " movl AR,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movl AR,AD\n" + "FZE", }, { ASSIGN, INDREG|FOREFF, SHFL, TFLOAT|TDOUBLE|TLDOUBLE, @@ -901,7 +1025,7 @@ SNAME|SOREG, TLDOUBLE, SHFL, TFLOAT|TDOUBLE|TLDOUBLE, 0, RDEST, - " fstt AL\n", }, + " fst AL\n", }, { ASSIGN, FOREFF, SNAME|SOREG, TLDOUBLE, @@ -1087,7 +1211,7 @@ { UMUL, INLL, SANY, TANY, SOREG, TLL, - NCREG|NCSL, RESC1, + NCREG, RESC1, " movl UL,U1\n movl AL,A1\n", }, { UMUL, INAREG, @@ -1241,7 +1365,7 @@ 0, RNOP, " jmp LL\n", }, -#ifdef GCC_COMPAT +#if defined(GCC_COMPAT) || defined(LANG_F77) { GOTO, FOREFF, SAREG, TANY, SANY, TANY, @@ -1252,12 +1376,36 @@ /* * Convert LTYPE to reg. */ +{ OPLTYPE, FORCC|INLL, + SCREG, TLL, + SMIXOR, TANY, + NCREG, RESC1, + " xorl U1,U1\n xorl A1,A1\n", }, + +{ OPLTYPE, FORCC|INLL, + SCREG, TLL, + SMILWXOR, TANY, + NCREG, RESC1, + " movl UL,U1\n xorl A1,A1\n", }, + +{ OPLTYPE, FORCC|INLL, + SCREG, TLL, + SMIHWXOR, TANY, + NCREG, RESC1, + " xorl U1,U1\n movl AL,A1\n", }, + { OPLTYPE, INLL, SANY, TANY, SCREG|SCON|SOREG|SNAME, TLL, NCREG, RESC1, " movl UL,U1\n movl AL,A1\n", }, +{ OPLTYPE, FORCC|INAREG, + SAREG, TWORD|TPOINT, + SMIXOR, TANY, + NAREG|NASL, RESC1, + " xorl A1,A1\n", }, + { OPLTYPE, INAREG, SANY, TANY, SAREG|SCON|SOREG|SNAME, TWORD|TPOINT, @@ -1270,6 +1418,12 @@ NBREG, RESC1, " movb AL,A1\n", }, +{ OPLTYPE, FORCC|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + NAREG, RESC1, + " xorw A1,A1\n", }, + { OPLTYPE, INAREG, SANY, TANY, SAREG|SOREG|SNAME|SCON, TSHORT|TUSHORT, Index: local2.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/local2.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/local2.c -L usr.bin/pcc/i386/local2.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/local2.c +++ usr.bin/pcc/i386/local2.c @@ -1,4 +1,4 @@ -/* $Id: local2.c,v 1.89 2007/09/16 19:08:16 ragge Exp $ */ +/* $Id: local2.c,v 1.120 2008/12/14 18:26:43 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -26,22 +26,18 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - # include "pass2.h" # include # include -void acon(NODE *p); -int argsize(NODE *p); +#if defined(PECOFFABI) || defined(MACHOABI) +#define EXPREFIX "_" +#else +#define EXPREFIX "" +#endif -static int stkpos; -void -lineid(int l, char *fn) -{ - /* identify line l and file fn */ - printf("# line %d, file %s\n", l, fn); -} +static int stkpos; void deflab(int label) @@ -59,16 +55,19 @@ static void prtprolog(struct interpass_prolog *ipp, int addto) { - int i, j; + int i; printf(" pushl %%ebp\n"); printf(" movl %%esp,%%ebp\n"); +#if defined(MACHOABI) + printf(" subl $8,%%esp\n"); /* 16-byte stack alignment */ +#endif if (addto) printf(" subl $%d,%%esp\n", addto); - for (i = ipp->ipp_regs, j = 0; i; i >>= 1, j++) - if (i & 1) + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) fprintf(stdout, " movl %s,-%d(%s)\n", - rnames[j], regoff[j], rnames[FPREG]); + rnames[i], regoff[i], rnames[FPREG]); } /* @@ -77,17 +76,16 @@ static int offcalc(struct interpass_prolog *ipp) { - int i, j, addto; + int i, addto; addto = p2maxautooff; if (addto >= AUTOINIT/SZCHAR) addto -= AUTOINIT/SZCHAR; - for (i = ipp->ipp_regs, j = 0; i ; i >>= 1, j++) { - if (i & 1) { + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) { addto += SZINT/SZCHAR; - regoff[j] = addto; + regoff[i] = addto; } - } return addto; } @@ -97,43 +95,61 @@ int addto; ftype = ipp->ipp_type; + +#ifdef LANG_F77 if (ipp->ipp_vis) printf(" .globl %s\n", ipp->ipp_name); printf(" .align 4\n"); printf("%s:\n", ipp->ipp_name); +#endif /* * We here know what register to save and how much to * add to the stack. */ addto = offcalc(ipp); +#if defined(MACHOABI) + addto = (addto + 15) & ~15; /* stack alignment */ +#endif prtprolog(ipp, addto); } void eoftn(struct interpass_prolog *ipp) { - int i, j; + int i; if (ipp->ipp_ip.ip_lbl == 0) return; /* no code needs to be generated */ /* return from function code */ - for (i = ipp->ipp_regs, j = 0; i ; i >>= 1, j++) { - if (i & 1) + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) fprintf(stdout, " movl -%d(%s),%s\n", - regoff[j], rnames[FPREG], rnames[j]); - - } + regoff[i], rnames[FPREG], rnames[i]); /* struct return needs special treatment */ if (ftype == STRTY || ftype == UNIONTY) { printf(" movl 8(%%ebp),%%eax\n"); printf(" leave\n"); - printf(" ret $4\n"); +#ifdef os_win32 + printf(" ret $%d\n", 4 + ipp->ipp_argstacksize); +#else + printf(" ret $%d\n", 4); +#endif } else { printf(" leave\n"); - printf(" ret\n"); +#ifdef os_win32 + if (ipp->ipp_argstacksize) + printf(" ret $%d\n", ipp->ipp_argstacksize); + else +#endif + printf(" ret\n"); } + +#if defined(ELFABI) + printf("\t.size " EXPREFIX "%s,.-" EXPREFIX "%s\n", ipp->ipp_name, + ipp->ipp_name); +#endif } /* @@ -211,7 +227,7 @@ twollcomp(NODE *p) { int o = p->n_op; - int s = getlab(); + int s = getlab2(); int e = p->n_label; int cb1, cb2; @@ -250,58 +266,64 @@ deflab(s); } -/* - * Assign to a bitfield. - * Clumsy at least, but what to do? - */ +int +fldexpand(NODE *p, int cookie, char **cp) +{ + CONSZ val; + + if (p->n_op == ASSIGN) + p = p->n_left; + switch (**cp) { + case 'S': + printf("%d", UPKFSZ(p->n_rval)); + break; + case 'H': + printf("%d", UPKFOFF(p->n_rval)); + break; + case 'M': + case 'N': + val = (CONSZ)1 << UPKFSZ(p->n_rval); + --val; + val <<= UPKFOFF(p->n_rval); + printf("0x%llx", (**cp == 'M' ? val : ~val) & 0xffffffff); + break; + default: + comperr("fldexpand"); + } + return 1; +} + static void -bfasg(NODE *p) +bfext(NODE *p) { - NODE *fn = p->n_left; - int shift = UPKFOFF(fn->n_rval); - int fsz = UPKFSZ(fn->n_rval); - int andval, tch = 0; - - /* get instruction size */ - switch (p->n_type) { - case CHAR: case UCHAR: tch = 'b'; break; - case SHORT: case USHORT: tch = 'w'; break; - case INT: case UNSIGNED: tch = 'l'; break; - default: comperr("bfasg"); - } - - /* put src into a temporary reg */ - fprintf(stdout, " mov%c ", tch); - adrput(stdout, getlr(p, 'R')); - fprintf(stdout, ","); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, "\n"); - - /* AND away the bits from dest */ - andval = ~(((1 << fsz) - 1) << shift); - fprintf(stdout, " and%c $%d,", tch, andval); - adrput(stdout, fn->n_left); - fprintf(stdout, "\n"); - - /* AND away unwanted bits from src */ - andval = ((1 << fsz) - 1); - fprintf(stdout, " and%c $%d,", tch, andval); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, "\n"); - - /* SHIFT left src number of bits */ - if (shift) { - fprintf(stdout, " sal%c $%d,", tch, shift); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, "\n"); + int ch = 0, sz = 0; + + if (ISUNSIGNED(p->n_right->n_type)) + return; + switch (p->n_right->n_type) { + case CHAR: + ch = 'b'; + sz = 8; + break; + case SHORT: + ch = 'w'; + sz = 16; + break; + case INT: + case LONG: + ch = 'l'; + sz = 32; + break; + default: + comperr("bfext"); } - /* OR in src to dest */ - fprintf(stdout, " or%c ", tch); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, ","); - adrput(stdout, fn->n_left); - fprintf(stdout, "\n"); + sz -= UPKFSZ(p->n_left->n_rval); + printf("\tshl%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n\tsar%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n"); } /* @@ -318,7 +340,12 @@ expand(p, 0, " pushl AL\n"); expand(p, 0, " leal 8(%esp),A1\n"); expand(p, 0, " pushl A1\n"); - fprintf(fp, " call memcpy\n"); +#if defined(MACHOABI) + fprintf(fp, " call L%s$stub\n", EXPREFIX "memcpy"); + addstub(&stublist, "memcpy"); +#else + fprintf(fp, " call %s\n", EXPREFIX "memcpy"); +#endif fprintf(fp, " addl $12,%%esp\n"); } @@ -375,12 +402,12 @@ int jmplab; if (loadlab == 0) { - loadlab = getlab(); + loadlab = getlab2(); expand(p, 0, " .data\n"); printf(LABFMT ": .long 0,0x80000000,0x403f\n", loadlab); expand(p, 0, " .text\n"); } - jmplab = getlab(); + jmplab = getlab2(); expand(p, 0, " pushl UL\n pushl AL\n"); expand(p, 0, " fildq (%esp)\n"); expand(p, 0, " addl $8,%esp\n"); @@ -426,6 +453,8 @@ break; case 'C': /* remove from stack after subroutine call */ + if (p->n_left->n_flags & FSTDCALL) + break; pr = p->n_qual; if (p->n_op == STCALL || p->n_op == USTCALL) pr += 4; @@ -439,8 +468,8 @@ twollcomp(p); break; - case 'E': /* Assign to bitfield */ - bfasg(p); + case 'E': /* Perform bitfield sign-extension */ + bfext(p); break; case 'F': /* Structure argument */ @@ -491,7 +520,8 @@ else if (p->n_op == RS) ch = "ashr"; else if (p->n_op == LS) ch = "ashl"; else ch = 0, comperr("ZO"); - printf("\tcall __%sdi3\n\taddl $%d,%s\n", ch, pr, rnames[ESP]); + printf("\tcall " EXPREFIX "__%sdi3\n\taddl $%d,%s\n", + ch, pr, rnames[ESP]); break; case 'P': /* push hidden argument on stack */ @@ -508,7 +538,12 @@ printf("\tpushl $%d\n", p->n_stsize); expand(p, INAREG, "\tpushl AR\n"); expand(p, INAREG, "\tleal AL,%eax\n\tpushl %eax\n"); - printf("\tcall memcpy\n"); +#if defined(MACHOABI) + printf("\tcall L%s$stub\n", EXPREFIX "memcpy"); + addstub(&stublist, "memcpy"); +#else + printf("\tcall %s\n", EXPREFIX "memcpy"); +#endif printf("\taddl $12,%%esp\n"); break; @@ -578,7 +613,7 @@ int o = p->n_op; if (o==NAME || o==REG || o==ICON || o==OREG || - (o==UMUL && shumul(p->n_left))) + (o==UMUL && shumul(p->n_left, SOREG))) return(1); return(0); } @@ -593,7 +628,7 @@ if (o == OREG || o == REG || o == NAME) return SRDIR; /* Direct match */ - if (o == UMUL && shumul(p->n_left)) + if (o == UMUL && shumul(p->n_left, SOREG)) return SROREG; /* Convert into oreg */ return SRREG; /* put it into a register */ } @@ -717,6 +752,8 @@ case OREG: r = p->n_rval; + if (p->n_name[0]) + printf("%s%s", p->n_name, p->n_lval ? "+" : ""); if (p->n_lval) fprintf(io, "%d", (int)p->n_lval); if (R2TEST(r)) { @@ -726,12 +763,23 @@ fprintf(io, "(%s)", rnames[p->n_rval]); return; case ICON: +#ifdef PCC_DEBUG + /* Sanitycheck for PIC, to catch adressable constants */ + if (kflag && p->n_name[0] && 0) { + static int foo; + + if (foo++ == 0) { + printf("\nfailing...\n"); + fwalk(p, e2print, 0); + comperr("pass2 conput"); + } + } +#endif /* addressable value of the constant */ fputc('$', io); conput(io, p); return; - case MOVE: case REG: switch (p->n_type) { case LONGLONG: @@ -780,7 +828,7 @@ } static void -fixcalls(NODE *p) +fixcalls(NODE *p, void *arg) { /* Prepare for struct return by allocating bounce space on stack */ switch (p->n_op) { @@ -844,7 +892,7 @@ DLIST_FOREACH(ip, ipole, qelem) { if (ip->type != IP_NODE) continue; - walkf(ip->ip_node, fixcalls); + walkf(ip->ip_node, fixcalls, 0); storefloat(ip, ip->ip_node); } if (stkpos > p2autooff) @@ -859,7 +907,7 @@ * Remove some PCONVs after OREGs are created. */ static void -pconv2(NODE *p) +pconv2(NODE *p, void *arg) { NODE *q; @@ -884,7 +932,7 @@ void mycanon(NODE *p) { - walkf(p, pconv2); + walkf(p, pconv2, 0); } void @@ -1026,6 +1074,22 @@ for (p = p->n_right; p->n_op == CM; p = p->n_left) size += argsiz(p->n_right); size += argsiz(p); +#if defined(ELFABI) + if (kflag) + size -= 4; +#endif + + +#if defined(MACHOABI) + int newsize = (size + 15) & ~15; /* stack alignment */ + int align = newsize-size; + + if (align != 0) + printf(" subl $%d,%%esp\n", align); + + size=newsize; +#endif + op->n_qual = size; /* XXX */ } @@ -1047,6 +1111,177 @@ p->n_lval < 0 || p->n_lval > 0x7fffffff) break; return SRDIR; + case SMIXOR: + return tshape(p, SZERO); + case SMILWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || p->n_lval & 0xffffffff) + break; + return SRDIR; + case SMIHWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || (p->n_lval >> 32) != 0) + break; + return SRDIR; } return SRNOPE; } + +/* + * Target-dependent command-line options. + */ +void +mflags(char *str) +{ +} + +/* + * Do something target-dependent for xasm arguments. + */ +int +myxasm(struct interpass *ip, NODE *p) +{ + struct interpass *ip2; + NODE *in = 0, *ut = 0; + TWORD t; + char *w; + int reg; + int cw; + + cw = xasmcode(p->n_name); + if (cw & (XASMASG|XASMINOUT)) + ut = p->n_left; + if ((cw & XASMASG) == 0) + in = p->n_left; + + switch (XASMVAL(cw)) { + case 'D': reg = EDI; break; + case 'S': reg = ESI; break; + case 'a': reg = EAX; break; + case 'b': reg = EBX; break; + case 'c': reg = ECX; break; + case 'd': reg = EDX; break; + case 't': reg = 0; break; + case 'u': reg = 1; break; + case 'A': reg = EAXEDX; break; + case 'q': /* XXX let it be CLASSA as for now */ + p->n_name = tmpstrdup(p->n_name); + w = strchr(p->n_name, 'q'); + *w = 'r'; + return 0; + default: + return 0; + } + p->n_name = tmpstrdup(p->n_name); + for (w = p->n_name; *w; w++) + ; + w[-1] = 'r'; /* now reg */ + t = p->n_left->n_type; + if (reg == EAXEDX) { + p->n_label = CLASSC; + } else { + p->n_label = CLASSA; + if (t == CHAR || t == UCHAR) { + p->n_label = CLASSB; + reg = reg * 2 + 8; + } + } + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) { + p->n_label = CLASSD; + reg += 037; + } + + if (in && ut) + in = tcopy(in); + p->n_left = mklnode(REG, 0, reg, t); + if (ut) { + ip2 = ipnode(mkbinode(ASSIGN, ut, tcopy(p->n_left), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + } + if (in) { + ip2 = ipnode(mkbinode(ASSIGN, tcopy(p->n_left), in, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + return 1; +} + +void +targarg(char *w, void *arg) +{ + NODE **ary = arg; + NODE *p, *q; + + p = ary[(int)w[1]-'0']->n_left; + if (optype(p->n_op) != LTYPE) + comperr("bad xarg op %d", p->n_op); + q = tcopy(p); + if (q->n_op == REG) { + if (*w == 'k') { + q->n_type = INT; + } else if (*w != 'w') { + if (q->n_type > UCHAR) { + regno(q) = regno(q)*2+8; + if (*w == 'h') + regno(q)++; + } + q->n_type = INT; + } else + q->n_type = SHORT; + } + adrput(stdout, q); + tfree(q); +} + +/* + * target-specific conversion of numeric arguments. + */ +int +numconv(void *ip, void *p1, void *q1) +{ + NODE *p = p1, *q = q1; + int cw = xasmcode(q->n_name); + + switch (XASMVAL(cw)) { + case 'a': + case 'b': + case 'c': + case 'd': + p->n_name = tmpcalloc(2); + p->n_name[0] = XASMVAL(cw); + return 1; + default: + return 0; + } +} + +static struct { + char *name; int num; +} xcr[] = { + { "eax", EAX }, + { "ebx", EBX }, + { "ecx", ECX }, + { "edx", EDX }, + { "ax", EAX }, + { "bx", EBX }, + { "cx", ECX }, + { "dx", EDX }, + { NULL, 0 }, +}; + +/* + * Check for other names of the xasm constraints registers. + */ + +/* + * Check for other names of the xasm constraints registers. + */ +int xasmconstregs(char *s) +{ + int i; + + for (i = 0; xcr[i].name; i++) + if (strcmp(xcr[i].name, s) == 0) + return xcr[i].num; + return -1; +} + Index: code.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/code.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/code.c -L usr.bin/pcc/i386/code.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/code.c +++ usr.bin/pcc/i386/code.c @@ -1,4 +1,4 @@ -/* $Id: code.c,v 1.15 2007/07/06 17:02:27 ragge Exp $ */ +/* $Id: code.c,v 1.38 2008/12/14 17:20:58 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -29,37 +29,62 @@ # include "pass1.h" -/* - * cause the alignment to become a multiple of n - * never called for text segment. - */ -void -defalign(int n) -{ - n /= SZCHAR; - if (n == 1) - return; - printf(" .align %d\n", n); -} +int lastloc = -1; /* - * define the current location as the name p->sname - * never called for text segment. + * Define everything needed to print out some data (or text). + * This means segment, alignment, visibility, etc. */ void -defnam(struct symtab *p) +defloc(struct symtab *sp) { - char *c = p->sname; + extern char *nextsect; +#if defined(ELFABI) || defined(PECOFFABI) + static char *loctbl[] = { "text", "data", "section .rodata" }; +#elif defined(MACHOABI) + static char *loctbl[] = { "text", "data", "const_data" }; +#endif + TWORD t; + int s; -#ifdef GCC_COMPAT - c = gcc_findname(p); + if (sp == NULL) { + lastloc = -1; + return; + } + t = sp->stype; + s = ISFTN(t) ? PROG : ISCON(cqual(t, sp->squal)) ? RDATA : DATA; +#ifdef TLS + if (sp->sflags & STLS) { + if (s != DATA) + cerror("non-data symbol in tls section"); + nextsect = ".tdata"; + } +#endif + if (sp->ssue->suesection) + nextsect = sp->ssue->suesection; + if (nextsect) { + printf(" .section %s\n", nextsect); + nextsect = NULL; + s = -1; + } else if (s != lastloc) + printf(" .%s\n", loctbl[s]); + lastloc = s; + while (ISARY(t)) + t = DECREF(t); + if (sp->ssue->suealign > ALCHAR) + printf(" .align %d\n", sp->ssue->suealign/ALCHAR); + if (sp->sclass == EXTDEF) + printf(" .globl %s\n", exname(sp->soname)); +#if defined(ELFABI) + if (ISFTN(t)) + printf("\t.type %s, at function\n", exname(sp->soname)); #endif - if (p->sclass == EXTDEF) - printf(" .globl %s\n", c); - printf("%s:\n", c); + if (sp->slevel == 0) + printf("%s:\n", exname(sp->soname)); + else + printf(LABFMT ":\n", sp->soffset); } - /* * code for the end of a function * deals with struct return here @@ -67,27 +92,21 @@ void efcode() { + extern int gotnr; NODE *p, *q; - int sz; + gotnr = 0; /* new number for next fun */ if (cftnsp->stype != STRTY+FTN && cftnsp->stype != UNIONTY+FTN) return; - /* address of return struct is in eax */ - /* create a call to memcpy() */ - /* will get the result in eax */ - p = block(REG, NIL, NIL, CHAR+PTR, 0, MKSUE(CHAR+PTR)); - p->n_rval = EAX; - q = block(OREG, NIL, NIL, CHAR+PTR, 0, MKSUE(CHAR+PTR)); + /* Create struct assignment */ + q = block(OREG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); q->n_rval = EBP; q->n_lval = 8; /* return buffer offset */ - p = block(CM, q, p, INT, 0, MKSUE(INT)); - sz = (tsize(STRTY, cftnsp->sdf, cftnsp->ssue)+SZCHAR-1)/SZCHAR; - p = block(CM, p, bcon(sz), INT, 0, MKSUE(INT)); - p->n_right->n_name = ""; - p = block(CALL, bcon(0), p, CHAR+PTR, 0, MKSUE(CHAR+PTR)); - p->n_left->n_name = "memcpy"; - p = clocal(p); - send_passt(IP_NODE, p); + q = buildtree(UMUL, q, NIL); + p = block(REG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); + p = buildtree(UMUL, p, NIL); + p = buildtree(ASSIGN, q, p); + ecomp(p); } /* @@ -95,15 +114,86 @@ * indices in symtab for the arguments; n is the number */ void -bfcode(struct symtab **a, int n) +bfcode(struct symtab **sp, int cnt) { +#ifdef os_win32 + extern int argstacksize; +#endif + struct symtab *sp2; + extern int gotnr; + NODE *n, *p; int i; - if (cftnsp->stype != STRTY+FTN && cftnsp->stype != UNIONTY+FTN) + if (cftnsp->stype == STRTY+FTN || cftnsp->stype == UNIONTY+FTN) { + /* Function returns struct, adjust arg offset */ + for (i = 0; i < cnt; i++) + sp[i]->soffset += SZPOINT(INT); + } + +#ifdef os_win32 + /* + * Count the arguments and mangle name in symbol table as a callee. + */ + argstacksize = 0; + if (cftnsp->sflags & SSTDCALL) { + char buf[64]; + for (i = 0; i < cnt; i++) { + TWORD t = sp[i]->stype; + if (t == STRTY || t == UNIONTY) + argstacksize += sp[i]->ssue->suesize; + else + argstacksize += szty(t) * SZINT / SZCHAR; + } + snprintf(buf, 64, "%s@%d", cftnsp->soname, argstacksize); + cftnsp->soname = newstring(buf, strlen(buf)); + } +#endif + + if (kflag) { +#define STL 100 + char *str = inlalloc(STL); +#if !defined(MACHOABI) + int l = getlab(); +#endif + + /* Generate extended assembler for PIC prolog */ + p = tempnode(0, INT, 0, MKSUE(INT)); + gotnr = regno(p); + p = block(XARG, p, NIL, INT, 0, MKSUE(INT)); + p->n_name = "=g"; + p = block(XASM, p, bcon(0), INT, 0, MKSUE(INT)); +#if defined(MACHOABI) + if (snprintf(str, STL, "call L%s$pb\nL%s$pb:\n\tpopl %%0\n", + cftnsp->sname, cftnsp->sname) >= STL) + cerror("bfcode"); +#else + if (snprintf(str, STL, + "call " LABFMT "\n" LABFMT ":\n popl %%0\n" + " addl $_GLOBAL_OFFSET_TABLE_+[.-" LABFMT "], %%0\n", + l, l, l) >= STL) + cerror("bfcode"); +#endif + p->n_name = str; + p->n_right->n_type = STRTY; + ecomp(p); + } + if (xtemps == 0) return; - /* Function returns struct, adjust arg offset */ - for (i = 0; i < n; i++) - a[i]->soffset += SZPOINT(INT); + + /* put arguments in temporaries */ + for (i = 0; i < cnt; i++) { + if (sp[i]->stype == STRTY || sp[i]->stype == UNIONTY || + cisreg(sp[i]->stype) == 0) + continue; + if (cqual(sp[i]->stype, sp[i]->squal) & VOL) + continue; + sp2 = sp[i]; + n = tempnode(0, sp[i]->stype, sp[i]->sdf, sp[i]->ssue); + n = buildtree(ASSIGN, n, nametree(sp2)); + sp[i]->soffset = regno(n->n_left); + sp[i]->sflags |= STNODE; + ecomp(n); + } } @@ -116,60 +206,97 @@ SETOFF(autooff, SZINT); } +#if defined(MACHOABI) +struct stub stublist; +struct stub nlplist; +#endif + /* called just before final exit */ /* flag is 1 if errors, 0 if none */ void ejobcode(int flag ) { +#if defined(MACHOABI) + /* + * iterate over the stublist and output the PIC stubs +` */ + if (kflag) { + struct stub *p; + + DLIST_FOREACH(p, &stublist, link) { + printf("\t.section __IMPORT,__jump_table,symbol_stubs,self_modifying_code+pure_instructions,5\n"); + printf("L%s$stub:\n", p->name); + printf("\t.indirect_symbol %s\n", exname(p->name)); + printf("\thlt ; hlt ; hlt ; hlt ; hlt\n"); + printf("\t.subsections_via_symbols\n"); + } + + printf("\t.section __IMPORT,__pointers,non_lazy_symbol_pointers\n"); + DLIST_FOREACH(p, &nlplist, link) { + printf("L%s$non_lazy_ptr:\n", p->name); + printf("\t.indirect_symbol %s\n", exname(p->name)); + printf("\t.long 0\n"); + } + + } +#endif + +#define _MKSTR(x) #x +#define MKSTR(x) _MKSTR(x) +#define OS MKSTR(TARGOS) + printf("\t.ident \"PCC: %s (%s)\"\n", PACKAGE_STRING, OS); } void bjobcode() { +#if defined(MACHOABI) + DLIST_INIT(&stublist, link); + DLIST_INIT(&nlplist, link); +#endif } /* - * Print character t at position i in one string, until t == -1. - * Locctr & label is already defined. + * Called with a function call with arguments as argument. + * This is done early in buildtree() and only done once. + * Returns p. */ -void -bycode(int t, int i) +NODE * +funcode(NODE *p) { - static int lastoctal = 0; - - /* put byte i+1 in a string */ + extern int gotnr; + NODE *r, *l; - if (t < 0) { - if (i != 0) - puts("\""); + /* Fix function call arguments. On x86, just add funarg */ + for (r = p->n_right; r->n_op == CM; r = r->n_left) { + if (r->n_right->n_op != STARG) + r->n_right = block(FUNARG, r->n_right, NIL, + r->n_right->n_type, r->n_right->n_df, + r->n_right->n_sue); + } + if (r->n_op != STARG) { + l = talloc(); + *l = *r; + r->n_op = FUNARG; + r->n_left = l; + r->n_type = l->n_type; + } + if (kflag == 0) + return p; +#if defined(ELFABI) + /* Create an ASSIGN node for ebx */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + l = buildtree(ASSIGN, l, tempnode(gotnr, INT, 0, MKSUE(INT))); + if (p->n_right->n_op != CM) { + p->n_right = block(CM, l, p->n_right, INT, 0, MKSUE(INT)); } else { - if (i == 0) - printf("\t.ascii \""); - if (t == '\\' || t == '"') { - lastoctal = 0; - putchar('\\'); - putchar(t); - } else if (t < 040 || t >= 0177) { - lastoctal++; - printf("\\%o",t); - } else if (lastoctal && '0' <= t && t <= '9') { - lastoctal = 0; - printf("\"\n\t.ascii \"%c", t); - } else { - lastoctal = 0; - putchar(t); - } + for (r = p->n_right; r->n_left->n_op == CM; r = r->n_left) + ; + r->n_left = block(CM, l, r->n_left, INT, 0, MKSUE(INT)); } -} - -/* - * n integer words of zeros - */ -void -zecode(int n) -{ - printf(" .zero %d\n", n * (SZINT/SZCHAR)); -// inoff += n * SZINT; +#endif + return p; } /* @@ -188,26 +315,11 @@ { } -/* p points to an array of structures, each consisting - * of a constant value and a label. - * The first is >=0 if there is a default label; - * its value is the label number - * The entries p[1] to p[n] are the nontrivial cases +/* * XXX - fix genswitch. */ -void -genswitch(int num, struct swents **p, int n) +int +mygenswitch(int num, TWORD type, struct swents **p, int n) { - NODE *r; - int i; - - /* simple switch code */ - for (i = 1; i <= n; ++i) { - /* already in 1 */ - r = tempnode(num, INT, 0, MKSUE(INT)); - r = buildtree(NE, r, bcon(p[i]->sval)); - cbranch(buildtree(NOT, r, NIL), bcon(p[i]->slab)); - } - if (p[0]->slab > 0) - branch(p[0]->slab); + return 0; } Index: local.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/local.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/local.c -L usr.bin/pcc/i386/local.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/local.c +++ usr.bin/pcc/i386/local.c @@ -1,4 +1,4 @@ -/* $Id: local.c,v 1.56 2007/09/24 16:23:36 ragge Exp $ */ +/* $Id: local.c,v 1.95 2008/12/23 06:51:21 gmcgarry Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -31,6 +31,277 @@ /* this file contains code which is dependent on the target machine */ +/* + * Check if a constant is too large for a type. + */ +static int +toolarge(TWORD t, CONSZ con) +{ + U_CONSZ ucon = con; + + switch (t) { + case ULONGLONG: + case LONGLONG: + break; /* cannot be too large */ +#define SCHK(i) case i: if (con > MAX_##i || con < MIN_##i) return 1; break +#define UCHK(i) case i: if (ucon > MAX_##i) return 1; break + SCHK(INT); + SCHK(SHORT); + case BOOL: + SCHK(CHAR); + UCHK(UNSIGNED); + UCHK(USHORT); + UCHK(UCHAR); + default: + cerror("toolarge"); + } + return 0; +} + +#if defined(MACHOABI) + +/* + * Keep track of PIC stubs. + */ + +void +addstub(struct stub *list, char *name) +{ + struct stub *s; + + DLIST_FOREACH(s, list, link) { + if (strcmp(s->name, name) == 0) + return; + } + + s = permalloc(sizeof(struct stub)); + s->name = permalloc(strlen(name) + 1); + strcpy(s->name, name); + DLIST_INSERT_BEFORE(list, s, link); +} + +#endif + +#define IALLOC(sz) (isinlining ? permalloc(sz) : tmpalloc(sz)) + +#ifndef os_win32 +/* + * Make a symtab entry for PIC use. + */ +static struct symtab * +picsymtab(char *p, char *s, char *s2) +{ + struct symtab *sp = IALLOC(sizeof(struct symtab)); + size_t len = strlen(p) + strlen(s) + strlen(s2) + 1; + + sp->sname = sp->soname = IALLOC(len); + strlcpy(sp->soname, p, len); + strlcat(sp->soname, s, len); + strlcat(sp->soname, s2, len); + sp->sclass = EXTERN; + sp->sflags = sp->slevel = 0; + return sp; +} +#endif + +int gotnr; /* tempnum for GOT register */ +int argstacksize; + +/* + * Create a reference for an extern variable. + */ +static NODE * +picext(NODE *p) +{ + +#if defined(ELFABI) + + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@GOT"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, PTR|VOID, 0, MKSUE(VOID)); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; + +#elif defined(MACHOABI) + + NODE *q, *r; + struct symtab *sp; + char buf2[64]; + + if (p->n_sp->sclass == EXTDEF) { + snprintf(buf2, 64, "-L%s$pb", cftnsp->soname); + sp = picsymtab("", exname(p->n_sp->soname), buf2); + } else { + snprintf(buf2, 64, "$non_lazy_ptr-L%s$pb", cftnsp->soname); + sp = picsymtab("L", p->n_sp->soname, buf2); + addstub(&nlplist, p->n_sp->soname); + } + q = tempnode(gotnr, PTR+VOID, 0, MKSUE(VOID)); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + + if (p->n_sp->sclass != EXTDEF) + q = block(UMUL, q, 0, PTR+VOID, 0, MKSUE(VOID)); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; + +#elif defined(PECOFFABI) + + return p; + +#endif + +} + +/* + * Create a reference for a static variable. + */ +static NODE * +picstatic(NODE *p) +{ + +#if defined(ELFABI) + + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + if (p->n_sp->slevel > 0) { + char buf[32]; + snprintf(buf, 32, LABFMT, (int)p->n_sp->soffset); + sp = picsymtab("", buf, "@GOTOFF"); + } else + sp = picsymtab("", p->n_sp->soname, "@GOTOFF"); + sp->sclass = STATIC; + sp->stype = p->n_sp->stype; + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; + +#elif defined(MACHOABI) + + NODE *q, *r; + struct symtab *sp; + char buf2[64]; + + snprintf(buf2, 64, "-L%s$pb", cftnsp->soname); + + if (p->n_sp->slevel > 0) { + char buf1[64]; + snprintf(buf1, 64, LABFMT, (int)p->n_sp->soffset); + sp = picsymtab("", buf1, buf2); + sp->sflags |= SNOUNDERSCORE; + } else { + sp = picsymtab("", exname(p->n_sp->soname), buf2); + } + sp->sclass = STATIC; + sp->stype = p->n_sp->stype; + q = tempnode(gotnr, PTR+VOID, 0, MKSUE(VOID)); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; + nfree(p); + return q; + +#elif defined(PECOFFABI) + + return p; + +#endif + +} + +#ifdef TLS +/* + * Create a reference for a TLS variable. + */ +static NODE * +tlspic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + + /* + * creates: + * leal var at TLSGD(%ebx),%eax + * call ___tls_get_addr at PLT + */ + + /* calc address of var at TLSGD */ + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@TLSGD"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + + /* assign to %eax */ + r = block(REG, NIL, NIL, PTR|VOID, 0, MKSUE(VOID)); + r->n_rval = EAX; + q = buildtree(ASSIGN, r, q); + + /* call ___tls_get_addr */ + sp2 = lookup("___tls_get_addr at PLT", 0); + sp2->stype = EXTERN|INT|FTN; + r = nametree(sp2); + r = buildtree(ADDROF, r, NIL); + r = block(UCALL, r, NIL, INT, 0, MKSUE(INT)); + + /* fusion both parts together */ + q = buildtree(COMOP, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsnonpic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + int ext = p->n_sp->sclass; + + sp = picsymtab("", p->n_sp->soname, + ext == EXTERN ? "@INDNTPOFF" : "@NTPOFF"); + q = xbcon(0, sp, INT); + if (ext == EXTERN) + q = block(UMUL, q, NIL, PTR|VOID, 0, MKSUE(VOID)); + + sp2 = lookup("%gs:0", 0); + sp2->stype = EXTERN|INT; + r = nametree(sp2); + + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsref(NODE *p) +{ + if (kflag) + return (tlspic(p)); + else + return (tlsnonpic(p)); +} +#endif + /* clocal() is called to do local transformations on * an expression tree preparitory to its being * written out in intermediate code. @@ -75,11 +346,23 @@ p = stref(block(STREF, r, p, 0, 0, 0)); break; + case USTATIC: + if (kflag == 0) + break; + /* FALLTHROUGH */ case STATIC: - if (q->slevel == 0) +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); break; - p->n_lval = 0; - p->n_sp = q; + } +#endif + if (kflag == 0) { + if (q->slevel == 0) + break; + p->n_lval = 0; + } else if (blevel > 0) + p = picstatic(p); break; case REGISTER: @@ -88,31 +371,72 @@ p->n_rval = q->soffset; break; + case EXTERN: + case EXTDEF: +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); + break; } +#endif + if (kflag == 0) + break; + if (blevel > 0) + p = picext(p); + break; + } break; - case STCALL: + case ADDROF: + if (kflag == 0 || blevel == 0) + break; + /* char arrays may end up here */ + l = p->n_left; + if (l->n_op != NAME || + (l->n_type != ARY+CHAR && l->n_type != ARY+WCHAR_TYPE)) + break; + l = p; + p = picstatic(p->n_left); + nfree(l); + if (p->n_op != UMUL) + cerror("ADDROF error"); + l = p; + p = p->n_left; + nfree(l); + break; + + case UCALL: + case USTCALL: + if (kflag == 0) + break; +#if defined(ELFABI) + /* Change to CALL node with ebx as argument */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + p->n_right = buildtree(ASSIGN, l, + tempnode(gotnr, INT, 0, MKSUE(INT))); + p->n_op -= (UCALL-CALL); +#endif + + /* FALLTHROUGH */ +#if defined(MACHOABI) case CALL: - /* Fix function call arguments. On x86, just add funarg */ - for (r = p->n_right; r->n_op == CM; r = r->n_left) { - if (r->n_right->n_op != STARG && - r->n_right->n_op != FUNARG) - r->n_right = block(FUNARG, r->n_right, NIL, - r->n_right->n_type, r->n_right->n_df, - r->n_right->n_sue); - } - if (r->n_op != STARG && r->n_op != FUNARG) { - l = talloc(); - *l = *r; - r->n_op = FUNARG; r->n_left = l; r->n_type = l->n_type; - } + case STCALL: + if (p->n_type == VOID) + break; + + r = tempnode(0, p->n_type, p->n_df, p->n_sue); + l = tcopy(r); + p = buildtree(COMOP, buildtree(ASSIGN, r, p), l); +#endif + break; - + case CBRANCH: l = p->n_left; /* - * Remove unneccessary conversion ops. + * Remove unnecessary conversion ops. */ if (clogop(l->n_op) && l->n_left->n_op == SCONV) { if (coptype(l->n_op) != BITYPE) @@ -121,6 +445,10 @@ r = l->n_left->n_left; if (r->n_type >= FLOAT && r->n_type <= LDOUBLE) break; + if (ISPTR(r->n_type)) + break; /* no opt for pointers */ + if (toolarge(r->n_type, l->n_right->n_lval)) + break; /* Type must be correct */ t = r->n_type; nfree(l->n_left); @@ -222,8 +550,6 @@ case UNSIGNED: l->n_lval = val & 0xffffffff; break; - case ENUMTY: - case MOETY: case LONG: case INT: l->n_lval = (int)val; @@ -249,6 +575,14 @@ l->n_sue = MKSUE(m); nfree(p); return l; + } else if (l->n_op == FCON) { + l->n_lval = l->n_dcon; + l->n_sp = NULL; + l->n_op = ICON; + l->n_type = m; + l->n_sue = MKSUE(m); + nfree(p); + return clocal(l); } if (DEUNSIGN(p->n_type) == SHORT && DEUNSIGN(l->n_type) == SHORT) { @@ -280,9 +614,10 @@ case PMCONV: case PVCONV: - if( p->n_right->n_op != ICON ) cerror( "bad conversion", 0); - nfree(p); - return(buildtree(o==PMCONV?MUL:DIV, p->n_left, p->n_right)); + r = p; + p = buildtree(o == PMCONV ? MUL : DIV, p->n_left, p->n_right); + nfree(r); + break; case FORCE: /* put return value in return reg */ @@ -297,8 +632,6 @@ case RS: /* shift count must be in a char * unless longlong, where it must be int */ - if (p->n_right->n_op == ICON) - break; /* do not do anything */ if (p->n_type == LONGLONG || p->n_type == ULONGLONG) { if (p->n_right->n_type != INT) p->n_right = block(SCONV, p->n_right, NIL, @@ -320,16 +653,115 @@ return(p); } +/* + * Change CALL references to either direct (static) or PLT. + */ +static void +fixnames(NODE *p, void *arg) +{ +#if !defined(PECOFFABI) + + struct symtab *sp; + struct suedef *sue; + NODE *q; + char *c; + int isu; + + if ((cdope(p->n_op) & CALLFLG) == 0) + return; + isu = 0; + q = p->n_left; + sue = q->n_sue; + if (q->n_op == UMUL) + q = q->n_left, isu = 1; + + if (q->n_op == PLUS && q->n_left->n_op == TEMP && + q->n_right->n_op == ICON) { + sp = q->n_right->n_sp; + + if (sp == NULL) + return; /* nothing to do */ + if (sp->sclass == STATIC && !ISFTN(sp->stype)) + return; /* function pointer */ + + if (sp->sclass != STATIC && sp->sclass != EXTERN && + sp->sclass != EXTDEF) + cerror("fixnames"); + +#if defined(ELFABI) + + if ((c = strstr(sp->soname, "@GOT")) == NULL) + cerror("fixnames2"); + if (isu) { + memcpy(c, "@PLT", sizeof("@PLT")); + } else + *c = 0; + +#elif defined(MACHOABI) + + if ((c = strstr(sp->soname, "$non_lazy_ptr")) == NULL && + (c = strstr(sp->soname, "-L")) == NULL) + cerror("fixnames2"); + if (isu) { + *c = 0; + addstub(&stublist, sp->soname+1); + strcpy(c, "$stub"); + } else + *c = 0; + +#endif + + nfree(q->n_left); + q = q->n_right; + if (isu) + nfree(p->n_left->n_left); + nfree(p->n_left); + p->n_left = q; + q->n_sue = sue; + } +#endif +} + void myp2tree(NODE *p) { + struct symtab *sp; + + if (kflag) + walkf(p, fixnames, 0); /* XXX walkf not needed */ + if (p->n_op != FCON) + return; + +#if 0 + /* put floating constants in memory */ + setloc1(RDATA); + defalign(ALLDOUBLE); + deflab1(i = getlab()); + ninval(0, btdims[p->n_type].suesize, p); +#endif + + sp = IALLOC(sizeof(struct symtab)); + sp->sclass = STATIC; + sp->ssue = MKSUE(p->n_type); + sp->slevel = 1; /* fake numeric label */ + sp->soffset = getlab(); + sp->sflags = 0; + sp->stype = p->n_type; + sp->squal = (CON >> TSHIFT); + + defloc(sp); + ninval(0, sp->ssue->suesize, p); + + p->n_op = NAME; + p->n_lval = 0; + p->n_sp = sp; } /*ARGSUSED*/ int andable(NODE *p) { - return(1); /* all names can have & taken on them */ + return(1); /* all names can have & taken on them */ } /* @@ -403,47 +835,38 @@ } -#if 0 -/* - * Print out an integer constant of size size. - * can only be sizes <= SZINT. - */ -void -indata(CONSZ val, int size) -{ - switch (size) { - case SZCHAR: - printf("\t.byte %d\n", (int)val & 0xff); - break; - case SZSHORT: - printf("\t.word %d\n", (int)val & 0xffff); - break; - case SZINT: - printf("\t.long %d\n", (int)val & 0xffffffff); - break; - default: - cerror("indata"); - } -} -#endif - /* * Print out a string of characters. * Assume that the assembler understands C-style escape - * sequences. Location is already set. + * sequences. */ void -instring(char *str) +instring(struct symtab *sp) { - char *s; + char *s, *str = sp->sname; + +#if defined(ELFABI) || defined(PECOFFABI) + + defloc(sp); + +#elif defined(MACHOABI) + + extern int lastloc; + if (lastloc != STRNG) + printf(" .cstring\n"); + lastloc = STRNG; + printf("\t.p2align 2\n"); + printf(LABFMT ":\n", sp->soffset); - /* be kind to assemblers and avoid?long strings */ +#endif + + /* be kind to assemblers and avoid long strings */ printf("\t.ascii \""); for (s = str; *s != 0; ) { if (*s++ == '\\') { (void)esccon(&s); } - if (s - str > 64) { + if (s - str > 60) { fwrite(str, 1, s - str, stdout); printf("\"\n\t.ascii \""); str = s; @@ -453,6 +876,28 @@ printf("\\0\"\n"); } +/* + * Print out a wide string by calling ninval(). + */ +void +inwstring(struct symtab *sp) +{ + char *s = sp->sname; + NODE *p; + + defloc(sp); + p = xbcon(0, NULL, WCHAR_TYPE); + do { + if (*s++ == '\\') + p->n_lval = esccon(&s); + else + p->n_lval = (unsigned char)s[-1]; + ninval(0, (MKSUE(WCHAR_TYPE))->suesize, p); + } while (s[-1] != 0); + nfree(p); +} + + static int inbits, inval; /* @@ -520,6 +965,9 @@ { union { float f; double d; long double l; int i[3]; } u; struct symtab *q; +#if defined(ELFABI) || defined(MACHOABI) + char *c; +#endif TWORD t; int i; @@ -527,6 +975,34 @@ if (t > BTMASK) t = INT; /* pointer */ + while (p->n_op == SCONV || p->n_op == PCONV) { + NODE *l = p->n_left; + l->n_type = p->n_type; + p = l; + } + + if (kflag && (p->n_op == PLUS || p->n_op == UMUL)) { + if (p->n_op == UMUL) + p = p->n_left; + p = p->n_right; + q = p->n_sp; + +#if defined(ELFABI) + + if ((c = strstr(q->soname, "@GOT")) != NULL) + *c = 0; /* ignore GOT ref here */ + +#elif defined(MACHOABI) + + if ((c = strstr(q->soname, "$non_lazy_ptr")) != NULL) { + q->soname++; /* skip "L" */ + *c = 0; /* ignore GOT ref here */ + } + else if ((c = strstr(q->soname, "-L")) != NULL) + *c = 0; /* ignore GOT ref here */ + +#endif + } if (p->n_op != ICON && p->n_op != FCON) cerror("ninval: init node not constant"); @@ -547,17 +1023,26 @@ case UNSIGNED: printf("\t.long 0x%x", (int)p->n_lval); if ((q = p->n_sp) != NULL) { - if ((q->sclass == STATIC && q->slevel > 0) || - q->sclass == ILABEL) { + if ((q->sclass == STATIC && q->slevel > 0)) { printf("+" LABFMT, q->soffset); - } else - printf("+%s", exname(q->sname)); + } else { +#if defined(MACHOABI) + if ((q->sflags & SNOUNDERSCORE) != 0) + printf("+%s", q->soname); + else +#endif + printf("+%s", exname(q->soname)); + } } printf("\n"); break; case SHORT: case USHORT: +#ifdef os_sunos + printf("\t.2byte 0x%x\n", (int)p->n_lval & 0xffff); +#else printf("\t.short 0x%x\n", (int)p->n_lval & 0xffff); +#endif break; case BOOL: if (p->n_lval > 1) @@ -570,11 +1055,20 @@ case LDOUBLE: u.i[2] = 0; u.l = (long double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + /* XXX probably broken on most hosts */ + printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[2], u.i[1], u.i[0]); +#else printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[0], u.i[1], u.i[2]); +#endif break; case DOUBLE: u.d = (double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + printf("\t.long\t0x%x,0x%x\n", u.i[1], u.i[0]); +#else printf("\t.long\t0x%x,0x%x\n", u.i[0], u.i[1]); +#endif break; case FLOAT: u.f = (float)p->n_dcon; @@ -585,49 +1079,33 @@ } } -#if 0 -/* - * print out an integer. - */ -void -inval(CONSZ word) -{ - word &= 0xffffffff; - printf(" .long 0x%llx\n", word); -} - -/* output code to initialize a floating point value */ -/* the proper alignment has been obtained */ -void -finval(NODE *p) -{ - union { float f; double d; long double l; int i[3]; } u; - - switch (p->n_type) { - case LDOUBLE: - u.i[2] = 0; - u.l = (long double)p->n_dcon; - printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[0], u.i[1], u.i[2]); - break; - case DOUBLE: - u.d = (double)p->n_dcon; - printf("\t.long\t0x%x,0x%x\n", u.i[0], u.i[1]); - break; - case FLOAT: - u.f = (float)p->n_dcon; - printf("\t.long\t0x%x\n", u.i[0]); - break; - } -} -#endif - /* make a name look like an external name in the local machine */ char * exname(char *p) { +#if defined(PECOFFABI) || defined(MACHOABI) + +#define NCHNAM 256 + static char text[NCHNAM+1]; + int i; + if (p == NULL) return ""; - return p; + + text[0] = '_'; + for (i=1; *p && istype, q->sdf, q->ssue); - off = (off+(SZCHAR-1))/SZCHAR; -#ifdef GCC_COMPAT - printf(" .comm %s,0%o\n", gcc_findname(q), off); -#else - printf(" .comm %s,0%o\n", exname(q->sname), off); +#ifdef TLS + if (sp->sflags & STLS) { + if (sp->sclass == EXTERN) + sp->sclass = EXTDEF; + simpleinit(sp, bcon(0)); + return; + } #endif + + al = talign(sp->stype, sp->ssue)/SZCHAR; + off = tsize(sp->stype, sp->sdf, sp->ssue); + off = (off+(SZCHAR-1))/SZCHAR; + printf(" .%scomm ", sp->sclass == STATIC ? "l" : ""); + if (sp->slevel == 0) + printf("%s,0%o", exname(sp->soname), off); + else + printf(LABFMT ",0%o", sp->soffset, off); + if (sp->sclass != STATIC) + printf(",%d", al); + printf("\n"); } -/* make a local common declaration for id, if reasonable */ -void -lcommdec(struct symtab *q) +static char * +section2string(char *name, int len) { - int off; +#if defined(ELFABI) + char *s; + int n; - off = tsize(q->stype, q->sdf, q->ssue); - off = (off+(SZCHAR-1))/SZCHAR; - if (q->slevel == 0) -#ifdef GCC_COMPAT - printf(" .lcomm %s,0%o\n", gcc_findname(q), off); -#else - printf(" .lcomm %s,0%o\n", exname(q->sname), off); + if (strncmp(name, "link_set", 8) == 0) { + const char *postfix = ",\"aw\", at progbits"; + n = len + strlen(postfix) + 1; + s = IALLOC(n); + strlcpy(s, name, n); + strlcat(s, postfix, n); + return s; + } #endif - else - printf(" .lcomm " LABFMT ",0%o\n", q->soffset, off); + + return newstring(name, len); } +char *nextsect; +#ifdef TLS +static int gottls; +#endif +#ifdef os_win32 +static int stdcall; +static int dllindirect; +#endif +static char *alias; +static int constructor; +static int destructor; + /* - * print a (non-prog) label. + * Give target the opportunity of handling pragmas. + */ +int +mypragma(char **ary) +{ +#ifdef TLS + if (strcmp(ary[1], "tls") == 0 && ary[2] == NULL) { + gottls = 1; + return 1; + } +#endif +#ifdef os_win32 + if (strcmp(ary[1], "stdcall") == 0) { + stdcall = 1; + return 1; + } + if (strcmp(ary[1], "cdecl") == 0) { + stdcall = 0; + return 1; + } + if (strcmp(ary[1], "fastcall") == 0) { + stdcall = 2; + return 1; + } + if (strcmp(ary[1], "dllimport") == 0) { + dllindirect = 1; + return 1; + } + if (strcmp(ary[1], "dllexport") == 0) { + dllindirect = 1; + return 1; + } +#endif + if (strcmp(ary[1], "constructor") == 0 || strcmp(ary[1], "init") == 0) { + constructor = 1; + return 1; + } + if (strcmp(ary[1], "destructor") == 0 || strcmp(ary[1], "fini") == 0) { + destructor = 1; + return 1; + } + if (strcmp(ary[1], "section") == 0 && ary[2] != NULL) { + nextsect = section2string(ary[2], strlen(ary[2])); + return 1; + } + if (strcmp(ary[1], "alias") == 0 && ary[2] != NULL) { + alias = tmpstrdup(ary[2]); + return 1; + } + if (strcmp(ary[1], "ident") == 0) + return 1; /* Just ignore */ + + return 0; +} + +/* + * Called when a identifier has been declared. */ void -deflab1(int label) +fixdef(struct symtab *sp) { - printf(LABFMT ":\n", label); +#ifdef TLS + /* may have sanity checks here */ + if (gottls) + sp->sflags |= STLS; + gottls = 0; +#endif + if (alias != NULL && (sp->sclass != PARAM)) { + printf("\t.globl %s\n", exname(sp->soname)); + printf("%s = ", exname(sp->soname)); + printf("%s\n", exname(alias)); + alias = NULL; + } + if ((constructor || destructor) && (sp->sclass != PARAM)) { +#if defined(ELFABI) + printf("\t.section .%ctors,\"aw\", at progbits\n", + constructor ? 'c' : 'd'); +#elif defined(PECOFFABI) + printf("\t.section .%ctors,\"w\"\n", + constructor ? 'c' : 'd'); +#elif defined(MACHOABI) + if (kflag) { + if (constructor) + printf("\t.mod_init_func\n"); + else + printf("\t.mod_term_func\n"); + } else { + if (constructor) + printf("\t.constructor\n"); + else + printf("\t.destructor\n"); + } +#endif + printf("\t.p2align 2\n"); + printf("\t.long %s\n", exname(sp->sname)); + constructor = destructor = 0; + } +#ifdef os_win32 + if (stdcall && (sp->sclass != PARAM)) { + sp->sflags |= SSTDCALL; + stdcall = 0; + } + if (dllindirect && (sp->sclass != PARAM)) { + sp->sflags |= SDLLINDIRECT; + dllindirect = 0; + } +#endif } -static char *loctbl[] = { "text", "data", "section .rodata", "section .rodata" }; +NODE * +i386_builtin_return_address(NODE *f, NODE *a) +{ + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; -void -setloc1(int locc) + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + f = block(PLUS, f, bcon(4), INCREF(PTR+VOID), 0, MKSUE(VOID)); + f = buildtree(UMUL, f, NIL); + + return f; +bad: + uerror("bad argument to __builtin_return_address"); + return bcon(0); +} + +NODE * +i386_builtin_frame_address(NODE *f, NODE *a) { - if (locc == lastloc) - return; - lastloc = locc; - printf(" .%s\n", loctbl[locc]); + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; + + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + return f; +bad: + uerror("bad argument to __builtin_frame_address"); + return bcon(0); } -#if 0 -int -ftoint(NODE *p, CONSZ **c) +#ifdef os_win32 +/* + * Postfix external functions with the arguments size. + */ +static void +mangle(NODE *p, void *arg) { - static CONSZ cc[3]; - union { float f; double d; long double l; int i[3]; } u; - int n; + NODE *l, *r; + TWORD t; + int size = 0; + char buf[64]; - switch (p->n_type) { - case LDOUBLE: - u.i[2] = 0; - u.l = (long double)p->n_dcon; - n = SZLDOUBLE; - break; - case DOUBLE: - u.d = (double)p->n_dcon; - n = SZDOUBLE; - break; - case FLOAT: - u.f = (float)p->n_dcon; - n = SZFLOAT; - break; + if ((p->n_op == NAME || p->n_op == ICON) && + p->n_sp && (p->n_sp->sflags & SDLLINDIRECT) && p->n_name) { + snprintf(buf, 64, "__imp_%s", p->n_name); + p->n_name = IALLOC(strlen(buf) + 1); + strcpy(p->n_name, buf); + return; + } + + if (p->n_op != CALL && p->n_op != STCALL && + p->n_op != UCALL && p->n_op != USTCALL) + return; + + l = p->n_left; + if (l->n_op == ADDROF) + l = l->n_left; + if (l->n_sp == NULL) + return; + if (l->n_sp->sflags & SSTDCALL) { + if (strchr(l->n_name, '@') == NULL) { + if (p->n_op == CALL || p->n_op == STCALL) { + for (r = p->n_right; + r->n_op == CM; r = r->n_left) { + t = r->n_type; + if (t == STRTY || t == UNIONTY) + size += r->n_sue->suesize; + else + size += szty(t) * SZINT / SZCHAR; + } + t = r->n_type; + if (t == STRTY || t == UNIONTY) + size += r->n_sue->suesize; + else + size += szty(t) * SZINT / SZCHAR; + } + snprintf(buf, 64, "%s@%d", l->n_name, size); + l->n_name = IALLOC(strlen(buf) + 1); + strcpy(l->n_name, buf); + } + + l->n_flags = FSTDCALL; } - cc[0] = u.i[0]; - cc[1] = u.i[1]; - cc[2] = u.i[2]; - *c = cc; - return n; } #endif + +void +pass1_lastchance(struct interpass *ip) +{ +#ifdef os_win32 + if (ip->type == IP_EPILOG) { + struct interpass_prolog *ipp = (struct interpass_prolog *)ip; + ipp->ipp_argstacksize = argstacksize; + } + + if (ip->type == IP_NODE) + walkf(ip->ip_node, mangle, 0); +#endif +} Index: reader.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/reader.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/reader.c -L usr.bin/pcc/mip/reader.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/reader.c +++ usr.bin/pcc/mip/reader.c @@ -1,4 +1,4 @@ -/* $Id: reader.c,v 1.203 2007/09/24 17:49:54 ragge Exp $ */ +/* $Id: reader.c,v 1.248 2008/12/03 07:08:40 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -61,12 +61,8 @@ */ /* - * Everything is entered via pass2_compile(). Three functions are - * allowed to recurse into pass2_compile(), so be careful: - * - deluseless() - * - myreader() - * Especially in myreader note that trees may be rewritten twice if - * things are not carefully handled. + * Everything is entered via pass2_compile(). No functions are + * allowed to recurse back into pass2_compile(). */ # include "pass2.h" @@ -86,59 +82,185 @@ NODE *nodepole; FILE *prfil; -static struct interpass prepole; +struct interpass prepole; void saveip(struct interpass *ip); -void deljumps(void); -void deltemp(NODE *p); -void mkhardops(NODE *p); -void optdump(struct interpass *ip); -void cvtemps(struct interpass *epil); +void deltemp(NODE *p, void *); +static void cvtemps(struct interpass *ipole, int op, int off); NODE *store(NODE *); -void rcount(void); -void compile2(struct interpass *ip); -void compile3(struct interpass *ip); -void compile4(struct interpass *ip); +static void fixxasm(struct p2env *); static void gencode(NODE *p, int cookie); +static void genxasm(NODE *p); -char *ltyp[] = { "", "LREG", "LOREG", "LTEMP" }; -char *rtyp[] = { "", "RREG", "ROREG", "RTEMP" }; +struct p2env p2env; -/* used when removing nodes */ -struct tmpsave { - struct tmpsave *next; - CONSZ tempaddr; - int tempno; -} *tmpsave; +int +getlab2(void) +{ + extern int getlab(void); + int rv = getlab(); +#ifdef PCC_DEBUG + if (p2env.epp->ip_lblnum != rv) + comperr("getlab2 error: %d != %d", p2env.epp->ip_lblnum, rv); +#endif + p2env.epp->ip_lblnum++; + return rv; +} #ifdef PCC_DEBUG +static int *lbldef, *lbluse; static void -cktree(NODE *p) +cktree(NODE *p, void *arg) { + int i; + if (p->n_op > MAXOP) - cerror("op %d slipped through", p->n_op); + cerror("%p) op %d slipped through", p, p->n_op); if (BTYPE(p->n_type) > MAXTYPES) - cerror("type %x slipped through", p->n_type); - if (p->n_op == CBRANCH && !logop(p->n_left->n_op)) - cerror("not logop branch"); + cerror("%p) type %x slipped through", p, p->n_type); + if (p->n_op == CBRANCH) { + if (!logop(p->n_left->n_op)) + cerror("%p) not logop branch", p); + i = p->n_right->n_lval; + if (i < p2env.ipp->ip_lblnum || i >= p2env.epp->ip_lblnum) + cerror("%p) label %d outside boundaries %d-%d", + p, i, p2env.ipp->ip_lblnum, p2env.epp->ip_lblnum); + lbluse[i-p2env.ipp->ip_lblnum] = 1; + } if ((dope[p->n_op] & ASGOPFLG) && p->n_op != RETURN) - cerror("asgop %d slipped through", p->n_op); + cerror("%p) asgop %d slipped through", p, p->n_op); + if (p->n_op == TEMP && + (regno(p) < p2env.ipp->ip_tmpnum || regno(p) >= p2env.epp->ip_tmpnum)) + cerror("%p) temporary %d outside boundaries %d-%d", + p, regno(p), p2env.ipp->ip_tmpnum, p2env.epp->ip_tmpnum); + if (p->n_op == GOTO) { + i = p->n_left->n_lval; + if (i < p2env.ipp->ip_lblnum || i >= p2env.epp->ip_lblnum) + cerror("%p) label %d outside boundaries %d-%d", + p, i, p2env.ipp->ip_lblnum, p2env.epp->ip_lblnum); + lbluse[i-p2env.ipp->ip_lblnum] = 1; + } +} + +/* + * Check that the trees are in a suitable state for pass2. + */ +static void +sanitychecks(struct p2env *p2e) +{ + struct interpass *ip; + int i; +#ifdef notyet + TMPMARK(); +#endif + lbldef = tmpcalloc(sizeof(int) * (p2e->epp->ip_lblnum - p2e->ipp->ip_lblnum)); + lbluse = tmpcalloc(sizeof(int) * (p2e->epp->ip_lblnum - p2e->ipp->ip_lblnum)); + + DLIST_FOREACH(ip, &p2env.ipole, qelem) { + if (ip->type == IP_DEFLAB) { + i = ip->ip_lbl; + if (i < p2e->ipp->ip_lblnum || i >= p2e->epp->ip_lblnum) + cerror("label %d outside boundaries %d-%d", + i, p2e->ipp->ip_lblnum, p2e->epp->ip_lblnum); + lbldef[i-p2e->ipp->ip_lblnum] = 1; + } + if (ip->type == IP_NODE) + walkf(ip->ip_node, cktree, 0); + } + for (i = 0; i < (p2e->epp->ip_lblnum - p2e->ipp->ip_lblnum); i++) + if (lbluse[i] != 0 && lbldef[i] == 0) + cerror("internal label %d not defined", + i + p2e->ipp->ip_lblnum); + +#ifdef notyet + TMPFREE(); +#endif } #endif /* + * Look if a temporary comes from a on-stack argument, in that case + * use the already existing stack position instead of moving it to + * a new place, and remove the move-to-temp statement. + */ +static int +stkarg(int tnr, int *soff) +{ + struct p2env *p2e = &p2env; + struct interpass *ip; + NODE *p; + + ip = DLIST_NEXT((struct interpass *)p2e->ipp, qelem); + while (ip->type != IP_DEFLAB) /* search for first DEFLAB */ + ip = DLIST_NEXT(ip, qelem); + + ip = DLIST_NEXT(ip, qelem); /* first NODE */ + + for (; ip->type != IP_DEFLAB; ip = DLIST_NEXT(ip, qelem)) { + if (ip->type != IP_NODE) + continue; + + p = ip->ip_node; + if (p->n_op == XASM) + continue; /* XXX - hack for x86 PIC */ +#ifdef PCC_DEBUG + if (p->n_op != ASSIGN || p->n_left->n_op != TEMP) + comperr("temparg"); +#endif + if (p->n_right->n_op != OREG && p->n_right->n_op != UMUL) + continue; /* arg in register */ + if (tnr != regno(p->n_left)) + continue; /* wrong assign */ + p = p->n_right; + if (p->n_op == UMUL && + p->n_left->n_op == PLUS && + p->n_left->n_left->n_op == REG && + p->n_left->n_right->n_op == ICON) + *soff = p->n_left->n_right->n_lval; + else if (p->n_op == OREG) + *soff = p->n_lval; + else + comperr("stkarg: bad arg"); + tfree(ip->ip_node); + DLIST_REMOVE(ip, qelem); + return 1; + } + return 0; +} + +/* + * See if an ADDROF is somewhere inside the expression tree. + * If so, fill in the offset table. + */ +static void +findaof(NODE *p, void *arg) +{ + int *aof = arg; + int tnr; + + if (p->n_op != ADDROF) + return; + tnr = regno(p->n_left); + if (aof[tnr]) + return; /* already gotten stack address */ + if (stkarg(tnr, &aof[tnr])) + return; /* argument was on stack */ + aof[tnr] = BITOOR(freetemp(szty(p->n_left->n_type))); +} + +/* * Check if a node has side effects. */ static int isuseless(NODE *n) { switch (n->n_op) { + case XASM: case FUNARG: case UCALL: case UFORTCALL: case FORCE: -/* case INIT: */ case ASSIGN: case CALL: case FORTCALL: @@ -158,7 +280,7 @@ /* * Delete statements with no meaning (like a+b; or 513.4;) */ -static NODE * +NODE * deluseless(NODE *p) { struct interpass *ip; @@ -192,70 +314,111 @@ return NULL; } -static struct interpass ipole; -struct interpass_prolog *ipp, *epp; - /* * Receives interpass structs from pass1. */ void pass2_compile(struct interpass *ip) { + struct p2env *p2e = &p2env; + int *addrp; + MARK mark; + if (ip->type == IP_PROLOG) { - tmpsave = NULL; - ipp = (struct interpass_prolog *)ip; - DLIST_INIT(&ipole, qelem); + memset(p2e, 0, sizeof(struct p2env)); + p2e->ipp = (struct interpass_prolog *)ip; + DLIST_INIT(&p2e->ipole, qelem); } - DLIST_INSERT_BEFORE(&ipole, ip, qelem); + DLIST_INSERT_BEFORE(&p2e->ipole, ip, qelem); if (ip->type != IP_EPILOG) return; #ifdef PCC_DEBUG if (e2debug) { printf("Entering pass2\n"); - printip(&ipole); + printip(&p2e->ipole); } #endif - epp = (struct interpass_prolog *)DLIST_PREV(&ipole, qelem); - p2maxautooff = p2autooff = epp->ipp_autos; + p2e->epp = (struct interpass_prolog *)DLIST_PREV(&p2e->ipole, qelem); + p2maxautooff = p2autooff = p2e->epp->ipp_autos; - myreader(&ipole); /* local massage of input */ +#ifdef PCC_DEBUG + sanitychecks(p2e); +#endif + myreader(&p2e->ipole); /* local massage of input */ + + /* + * Do initial modification of the trees. Two loops; + * - first, search for ADDROF of TEMPs, these must be + * converterd to OREGs on stack. + * - second, do the actual conversions, in case of not xtemps + * convert all temporaries to stack references. + */ + markset(&mark); + if (p2e->epp->ip_tmpnum != p2e->ipp->ip_tmpnum) { + addrp = tmpcalloc(sizeof(int) * + (p2e->epp->ip_tmpnum - p2e->ipp->ip_tmpnum)); + addrp -= p2e->ipp->ip_tmpnum; + } else + addrp = NULL; + if (xtemps) { + DLIST_FOREACH(ip, &p2e->ipole, qelem) { + if (ip->type == IP_NODE) + walkf(ip->ip_node, findaof, addrp); + } + } + DLIST_FOREACH(ip, &p2e->ipole, qelem) + if (ip->type == IP_NODE) + walkf(ip->ip_node, deltemp, addrp); + markfree(&mark); + +#ifdef PCC_DEBUG + if (e2debug) { + printf("Efter ADDROF/TEMP\n"); + printip(&p2e->ipole); + } +#endif - DLIST_FOREACH(ip, &ipole, qelem) { +#if 0 + DLIST_FOREACH(ip, &p2e->ipole, qelem) { if (ip->type != IP_NODE) continue; if (xtemps == 0) - walkf(ip->ip_node, deltemp); + walkf(ip->ip_node, deltemp, 0); } +#endif + DLIST_INIT(&prepole, qelem); - DLIST_FOREACH(ip, &ipole, qelem) { + DLIST_FOREACH(ip, &p2e->ipole, qelem) { if (ip->type != IP_NODE) continue; canon(ip->ip_node); - walkf(ip->ip_node, cktree); if ((ip->ip_node = deluseless(ip->ip_node)) == NULL) { DLIST_REMOVE(ip, qelem); } else while (!DLIST_ISEMPTY(&prepole, qelem)) { - struct interpass *ipp; + struct interpass *tipp; - ipp = DLIST_NEXT(&prepole, qelem); - DLIST_REMOVE(ipp, qelem); - DLIST_INSERT_BEFORE(ip, ipp, qelem); + tipp = DLIST_NEXT(&prepole, qelem); + DLIST_REMOVE(tipp, qelem); + DLIST_INSERT_BEFORE(ip, tipp, qelem); } } - optimize(&ipole); - ngenregs(&ipole); + fixxasm(p2e); /* setup for extended asm */ - DLIST_FOREACH(ip, &ipole, qelem) + optimize(p2e); + ngenregs(p2e); + + DLIST_FOREACH(ip, &p2e->ipole, qelem) emit(ip); } void emit(struct interpass *ip) { - NODE *p; + NODE *p, *r; + struct optab *op; int o; switch (ip->type) { @@ -263,23 +426,36 @@ p = ip->ip_node; nodepole = p; -//printf("bu:\n"); -//fwalk(p, e2print, 0); canon(p); /* may convert stuff after genregs */ -//fwalk(p, e2print, 0); + if (c2debug > 1) { + printf("emit IP_NODE:\n"); + fwalk(p, e2print, 0); + } switch (p->n_op) { case CBRANCH: /* Only emit branch insn if RESCC */ - if (table[TBLIDX(p->n_left->n_su)].rewrite & RESCC) { + /* careful when an OPLOG has been elided */ + if (p->n_left->n_su == 0 && p->n_left->n_left != NULL) { + op = &table[TBLIDX(p->n_left->n_left->n_su)]; + r = p->n_left; + } else { + op = &table[TBLIDX(p->n_left->n_su)]; + r = p; + } + if (op->rewrite & RESCC) { o = p->n_left->n_op; - gencode(p, FORCC); + gencode(r, FORCC); cbgen(o, p->n_right->n_lval); - } else - gencode(p, FORCC); + } else { + gencode(r, FORCC); + } break; case FORCE: gencode(p->n_left, INREGS); break; + case XASM: + genxasm(p); + break; default: if (p->n_op != REG || p->n_type != VOID) /* XXX */ gencode(p, FOREFF); /* Emit instructions */ @@ -292,17 +468,16 @@ break; case IP_EPILOG: eoftn((struct interpass_prolog *)ip); - tmpsave = NULL; /* Always forget old nodes */ p2maxautooff = p2autooff = AUTOINIT/SZCHAR; break; case IP_DEFLAB: deflab(ip->ip_lbl); break; case IP_ASM: - printf("\t%s\n", ip->ip_asm); + printf("%s", ip->ip_asm); break; default: - cerror("compile4 %d", ip->type); + cerror("emit %d", ip->type); } } @@ -370,7 +545,7 @@ geninsn(NODE *p, int cookie) { NODE *p1, *p2; - int o, rv = 0; + int q, o, rv = 0; #ifdef PCC_DEBUG if (odebug) { @@ -379,6 +554,9 @@ } #endif + q = cookie & QUIET; + cookie &= ~QUIET; /* XXX - should not be necessary */ + again: switch (o = p->n_op) { case EQ: case NE: @@ -390,6 +568,18 @@ case ULT: case UGE: case UGT: + p1 = p->n_left; + p2 = p->n_right; + if (p2->n_op == ICON && p2->n_lval == 0 && + optype(p1->n_op) == BITYPE) { +#ifdef mach_pdp11 /* XXX all targets? */ + if ((rv = geninsn(p1, FORCC|QUIET)) != FFAIL) + break; +#else + if (findops(p1, FORCC) > 0) + break; +#endif + } rv = relops(p); break; @@ -407,6 +597,11 @@ break; case ASSIGN: +#ifdef FINDMOPS + if ((rv = findmops(p, cookie)) != FFAIL) + break; + /* FALLTHROUGH */ +#endif case STASG: rv = findasg(p, cookie); break; @@ -419,6 +614,7 @@ case TEMP: case NAME: case ICON: + case FCON: case OREG: rv = findleaf(p, cookie); break; @@ -427,9 +623,10 @@ case CALL: /* CALL arguments are handled special */ for (p1 = p->n_right; p1->n_op == CM; p1 = p1->n_left) - geninsn(p1->n_right, FOREFF); - geninsn(p1, FOREFF); + (void)geninsn(p1->n_right, FOREFF); + (void)geninsn(p1, FOREFF); /* FALLTHROUGH */ + case FLD: case COMPL: case UMINUS: case PCONV: @@ -440,6 +637,7 @@ case STARG: case UCALL: case USTCALL: + case ADDROF: rv = finduni(p, cookie); break; @@ -447,23 +645,39 @@ p1 = p->n_left; p2 = p->n_right; p1->n_label = p2->n_lval; - o = p1->n_op; - geninsn(p1, FORCC); + (void)geninsn(p1, FORCC); p->n_su = 0; break; case FORCE: /* XXX needed? */ - geninsn(p->n_left, INREGS); + (void)geninsn(p->n_left, INREGS); p->n_su = 0; /* su calculations traverse left */ break; + case XASM: + for (p1 = p->n_left; p1->n_op == CM; p1 = p1->n_left) + (void)geninsn(p1->n_right, FOREFF); + (void)geninsn(p1, FOREFF); + break; /* all stuff already done? */ + + case XARG: + /* generate code for correct class here */ +// geninsn(p->n_left, 1 << p->n_label); + break; + default: comperr("geninsn: bad op %s, node %p", opst[o], p); } - if (rv == FFAIL) + if (rv == FFAIL && !q) comperr("Cannot generate code, node %p op %s", p,opst[p->n_op]); if (rv == FRETRY) goto again; +#ifdef PCC_DEBUG + if (odebug) { + printf("geninsn(%p, %s) rv %d\n", p, prcook(cookie), rv); + fwalk(p, e2print, 0); + } +#endif return rv; } @@ -514,7 +728,7 @@ * Rewrite node to register after instruction emit. */ static void -rewrite(NODE *p, int rewrite, int cookie) +rewrite(NODE *p, int dorewrite, int cookie) { NODE *l, *r; int o; @@ -550,18 +764,75 @@ tfree(l); if (optype(o) == BITYPE) tfree(r); - if (rewrite == 0) + if (dorewrite == 0) return; - CDEBUG(("rewrite: %p, reg %s\n", p, rnames[DECRA(p->n_reg, 0)])); + CDEBUG(("rewrite: %p, reg %s\n", p, + p->n_reg == -1? "" : rnames[DECRA(p->n_reg, 0)])); p->n_rval = DECRA(p->n_reg, 0); } +#ifndef XASM_TARGARG +#define XASM_TARGARG(x,y) 0 +#endif + +/* + * printout extended assembler. + */ +void +genxasm(NODE *p) +{ + NODE *q, **nary; + int n = 1, o = 0; + char *w; + + if (p->n_left->n_op != ICON || p->n_left->n_type != STRTY) { + for (q = p->n_left; q->n_op == CM; q = q->n_left) + n++; + nary = tmpalloc(sizeof(NODE *)*n); + o = n; + for (q = p->n_left; q->n_op == CM; q = q->n_left) { + gencode(q->n_right->n_left, INREGS); + nary[--o] = q->n_right; + } + gencode(q->n_left, INREGS); + nary[--o] = q; + } else + nary = 0; + + w = p->n_name; + putchar('\t'); + while (*w != 0) { + if (*w == '%') { + if (w[1] == '%') + putchar('%'); + else if (XASM_TARGARG(w, nary)) + ; /* handled by target */ + else if (w[1] < '0' || w[1] > (n + '0')) + uerror("bad xasm arg number %c", w[1]); + else + adrput(stdout, nary[(int)w[1]-'0']->n_left); + w++; + } else if (*w == '\\') { /* Always 3-digit octal */ + int num = *++w - '0'; + num = (num << 3) + *++w - '0'; + num = (num << 3) + *++w - '0'; + putchar(num); + } else + putchar(*w); + w++; + } + putchar('\n'); +} + void gencode(NODE *p, int cookie) { struct optab *q = &table[TBLIDX(p->n_su)]; NODE *p1, *l, *r; int o = optype(p->n_op); +#ifdef FINDMOPS + int ismops = (p->n_op == ASSIGN && (p->n_flags & 1)); +#endif l = p->n_left; r = p->n_right; @@ -598,7 +869,12 @@ } if (o != LTYPE) { gencode(l, INREGS); - if (q->rewrite & RLEFT) +#ifdef FINDMOPS + if (ismops) + ; + else +#endif + if (q->rewrite & RLEFT) ckmove(p, l); } if (o == BITYPE && !(p->n_su & DORIGHT)) { @@ -607,6 +883,18 @@ ckmove(p, r); } +#ifdef FINDMOPS + if (ismops) { + /* reduce right tree to make expand() work */ + if (optype(r->n_op) != LTYPE) { + p->n_op = r->n_op; + r = tcopy(r->n_right); + tfree(p->n_right); + p->n_right = r; + } + } +#endif + canon(p); if (q->needs & NSPECIAL) { @@ -614,6 +902,10 @@ int lr = rspecial(q, NLEFT); if (rr >= 0) { +#ifdef PCC_DEBUG + if (optype(p->n_op) != BITYPE) + comperr("gencode: rspecial borked"); +#endif if (r->n_op != REG) comperr("gencode: rop != REG"); if (rr != r->n_rval) @@ -633,7 +925,8 @@ if (p->n_op == ASSIGN && p->n_left->n_op == REG && p->n_right->n_op == REG && - p->n_left->n_rval == p->n_right->n_rval){ + p->n_left->n_rval == p->n_right->n_rval && + (p->n_su & RVCC) == 0) { /* XXX should check if necessary */ /* do not emit anything */ CDEBUG(("gencode(%p) assign nothing\n", p)); rewrite(p, q->rewrite, cookie); @@ -645,6 +938,12 @@ return; expand(p, cookie, q->cstring); +#ifdef FINDMOPS + if (ismops && DECRA(p->n_reg, 0) != regno(l) && cookie != FOREFF) { + CDEBUG(("gencode(%p) rmove\n", p)); + rmove(regno(l), DECRA(p->n_reg, 0), p->n_type); + } else +#endif if (callop(p->n_op) && cookie != FOREFF && DECRA(p->n_reg, 0) != RETREG(p->n_type)) { CDEBUG(("gencode(%p) retreg\n", p)); @@ -681,6 +980,7 @@ } int negrel[] = { NE, EQ, GT, GE, LT, LE, UGT, UGE, ULT, ULE } ; /* negatives of relationals */ +size_t negrelsize = sizeof negrel / sizeof negrel[0]; #ifdef PCC_DEBUG #undef PRTABLE @@ -708,7 +1008,12 @@ break; case TEMP: - fprintf(prfil, " " CONFMT, p->n_lval); + fprintf(prfil, " %d", regno(p)); + break; + + case XASM: + case XARG: + fprintf(prfil, " '%s'", p->n_name); break; case ICON: @@ -730,16 +1035,9 @@ fprintf(prfil, ", " ); tprint(prfil, p->n_type, p->n_qual); fprintf(prfil, ", " ); - { - int gregn(struct regw *); - if (p->n_reg == -1) - fprintf(prfil, "REG "); - else if (p->n_reg < 100000) /* XXX */ - fprintf(prfil, "REG %s", rnames[DECRA(p->n_reg, 0)]); - else - fprintf(prfil, "TEMP %d", gregn(p->n_regw)); - } - fprintf(prfil, ", SU= %d(%cREG,%s,%s,%s,%s)\n", + + prtreg(prfil, p); + fprintf(prfil, ", SU= %d(%cREG,%s,%s,%s,%s,%s,%s)\n", TBLIDX(p->n_su), TCLASS(p->n_su)+'@', #ifdef PRTABLE @@ -748,8 +1046,9 @@ #else "", #endif - ltyp[LMASK&p->n_su], - rtyp[(p->n_su&RMASK) >> 2], p->n_su & DORIGHT ? "DORIGHT" : ""); + p->n_su & LREG ? "LREG" : "", p->n_su & RREG ? "RREG" : "", + p->n_su & RVEFF ? "RVEFF" : "", p->n_su & RVCC ? "RVCC" : "", + p->n_su & DORIGHT ? "DORIGHT" : ""); } #endif @@ -815,35 +1114,32 @@ * change left TEMPs into OREGs */ void -deltemp(NODE *p) +deltemp(NODE *p, void *arg) { - struct tmpsave *w; - NODE *l; + int *aor = arg; + NODE *l, *r; if (p->n_op == TEMP) { - /* Check if already existing */ - for (w = tmpsave; w; w = w->next) - if (w->tempno == p->n_lval) - break; - if (w == NULL) { - /* new on stack */ - w = tmpalloc(sizeof(struct tmpsave)); - w->tempno = p->n_lval; - w->tempaddr = BITOOR(freetemp(szty(p->n_type))); - w->next = tmpsave; - tmpsave = w; - } - p->n_op = OREG; - p->n_rval = FPREG; - p->n_lval = w->tempaddr; - } else if (p->n_op == ADDROF) { - /* TEMPs are already converted to OREGs */ - if ((l = p->n_left)->n_op != OREG) - comperr("bad U&"); + if (aor[regno(p)] == 0) { + if (xtemps) + return; + aor[regno(p)] = BITOOR(freetemp(szty(p->n_type))); + } + l = mklnode(REG, 0, FPREG, INCREF(p->n_type)); + r = mklnode(ICON, aor[regno(p)], 0, INT); + p->n_left = mkbinode(PLUS, l, r, INCREF(p->n_type)); + p->n_op = UMUL; + } else if (p->n_op == ADDROF && p->n_left->n_op == OREG) { p->n_op = PLUS; + l = p->n_left; l->n_op = REG; l->n_type = INCREF(l->n_type); p->n_right = mklnode(ICON, l->n_lval, 0, INT); + } else if (p->n_op == ADDROF && p->n_left->n_op == UMUL) { + l = p->n_left; + *p = *p->n_left->n_left; + nfree(l->n_left); + nfree(l); } } @@ -851,7 +1147,7 @@ * for pointer/integer arithmetic, set pointer at left node */ static void -setleft(NODE *p) +setleft(NODE *p, void *arg) { NODE *q; @@ -909,10 +1205,10 @@ int i; if( (r=base(ql))>=0 && (i=offset(qr, tlen(p)))>=0) { makeor2(p, ql, r, i); - return; + return 1; } else if((r=base(qr))>=0 && (i=offset(ql, tlen(p)))>=0) { makeor2(p, qr, r, i); - return; + return 1; } } @@ -966,7 +1262,7 @@ * look for situations where we can turn * into OREG */ void -oreg2(NODE *p) +oreg2(NODE *p, void *arg) { if (p->n_op != UMUL) return; @@ -980,14 +1276,12 @@ canon(p) NODE *p; { /* put p in canonical form */ - walkf(p, setleft); /* ptrs at left node for arithmetic */ - walkf(p, oreg2); /* look for and create OREG nodes */ + walkf(p, setleft, 0); /* ptrs at left node for arithmetic */ + walkf(p, oreg2, 0); /* look for and create OREG nodes */ #ifndef FIELDOPS fwalk(p, ffld, 0); /* look for field operators */ # endif -#ifdef MYCANON - MYCANON(p); /* your own canonicalization routine(s) */ -#endif + mycanon(p); /* your own canonicalization routine(s) */ } @@ -997,6 +1291,12 @@ extern char *ftitle; va_list ap; + if (nerrors) { + fprintf(stderr, + "cannot recover from earlier errors: goodbye!\n"); + exit(1); + } + va_start(ap, str); fprintf(stderr, "%s, line %d: compiler error: ", ftitle, thisline); vfprintf(stderr, str, ap); @@ -1004,8 +1304,10 @@ va_end(ap); prfil = stderr; +#ifdef PCC_DEBUG if (nodepole && nodepole->n_op != FREE) fwalk(nodepole, e2print, 0); +#endif exit(1); } @@ -1050,6 +1352,7 @@ p->n_name = ""; p->n_qual = 0; p->n_op = op; + p->n_label = 0; p->n_lval = lval; p->n_rval = rval; p->n_type = type; @@ -1066,10 +1369,12 @@ p->n_name = ""; p->n_qual = 0; p->n_op = op; + p->n_label = 0; p->n_left = left; p->n_right = right; p->n_type = type; p->n_regw = NULL; + p->n_su = 0; return p; } @@ -1081,10 +1386,12 @@ p->n_name = ""; p->n_qual = 0; p->n_op = op; + p->n_label = 0; p->n_left = left; p->n_rval = rval; p->n_type = type; p->n_regw = NULL; + p->n_su = 0; return p; } @@ -1110,3 +1417,222 @@ } return -1; } + +#ifndef XASM_NUMCONV +#define XASM_NUMCONV(x,y,z) 0 +#endif + +/* + * change numeric argument redirections to the correct node type after + * cleaning up the other nodes. + * be careful about input operands that may have different value than output. + */ +static void +delnums(NODE *p, void *arg) +{ + struct interpass *ip = arg, *ip2; + NODE *r = ip->ip_node->n_left; + NODE *q; + TWORD t; + int cnt; + + if (p->n_name[0] < '0' || p->n_name[0] > '9') + return; /* not numeric */ + if ((q = listarg(r, p->n_name[0] - '0', &cnt)) == NIL) + comperr("bad delnums"); + + /* target may have opinions whether to do this conversion */ + if (XASM_NUMCONV(ip, p, q)) + return; + + /* Delete number by adding move-to/from-temp. Later on */ + /* the temps may be rewritten to other LTYPEs */ + t = p->n_left->n_type; + r = mklnode(TEMP, 0, p2env.epp->ip_tmpnum++, t); + + /* pre node */ + ip2 = ipnode(mkbinode(ASSIGN, tcopy(r), p->n_left, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + + /* post node */ + ip2 = ipnode(mkbinode(ASSIGN, q->n_left, tcopy(r), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + + p->n_left = tcopy(r); + q->n_left = r; + + p->n_name = tmpstrdup(q->n_name); + if (*p->n_name == '=') + p->n_name++; +} + +/* + * Ensure that a node is correct for the destination. + */ +static void +ltypify(NODE *p, void *arg) +{ + struct interpass *ip = arg; + struct interpass *ip2; + TWORD t = p->n_left->n_type; + NODE *q, *r; + int cw, ooff; + char *c; + +again: + if (myxasm(ip, p)) + return; /* handled by target-specific code */ + + cw = xasmcode(p->n_name); + switch (XASMVAL(cw)) { + case 'p': + /* pointer */ + /* just make register of it */ + p->n_name = tmpstrdup(p->n_name); + c = strchr(p->n_name, XASMVAL(cw)); /* cannot fail */ + *c = 'r'; + /* FALLTHROUGH */ + case 'g': /* general; any operand */ + case 'r': /* general reg */ + /* set register class */ + p->n_label = gclass(p->n_left->n_type); + if (p->n_left->n_op == REG || p->n_left->n_op == TEMP) + break; + q = p->n_left; + r = (cw & XASMINOUT ? tcopy(q) : q); + p->n_left = mklnode(TEMP, 0, p2env.epp->ip_tmpnum++, t); + if ((cw & XASMASG) == 0) { + ip2 = ipnode(mkbinode(ASSIGN, tcopy(p->n_left), r, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + if (cw & (XASMASG|XASMINOUT)) { + /* output parameter */ + ip2 = ipnode(mkbinode(ASSIGN, q, tcopy(p->n_left), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + } + break; + + case '0': case '1': case '2': case '3': case '4': + case '5': case '6': case '7': case '8': case '9': + break; + + case 'm': /* memory operand */ + /* store and reload value */ + q = p->n_left; + if (optype(q->n_op) == LTYPE) { + if (q->n_op == TEMP) { + ooff = BITOOR(freetemp(szty(t))); + cvtemps(ip, q->n_rval, ooff); + } else if (q->n_op == REG) + comperr("xasm m and reg"); + } else if (q->n_op == UMUL && + (q->n_left->n_op != TEMP && q->n_left->n_op != REG)) { + t = q->n_left->n_type; + ooff = p2env.epp->ip_tmpnum++; + ip2 = ipnode(mkbinode(ASSIGN, + mklnode(TEMP, 0, ooff, t), q->n_left, t)); + q->n_left = mklnode(TEMP, 0, ooff, t); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + break; + + case 'i': /* immediate constant */ + case 'n': /* numeric constant */ + if (p->n_left->n_op == ICON) + break; + p->n_name = tmpstrdup(p->n_name); + c = strchr(p->n_name, XASMVAL(cw)); /* cannot fail */ + if (c[1]) { + c[0] = c[1], c[1] = 0; + goto again; + } else + uerror("constant required"); + break; + + default: + uerror("unsupported xasm option string '%s'", p->n_name); + } +} + +/* Extended assembler hacks */ +static void +fixxasm(struct p2env *p2e) +{ + struct interpass *pole = &p2e->ipole; + struct interpass *ip; + NODE *p; + + DLIST_FOREACH(ip, pole, qelem) { + if (ip->type != IP_NODE || ip->ip_node->n_op != XASM) + continue; + thisline = ip->lineno; + p = ip->ip_node->n_left; + + if (p->n_op == ICON && p->n_type == STRTY) + continue; + + /* replace numeric redirections with its underlying type */ + flist(p, delnums, ip); + + /* + * Ensure that the arg nodes can be directly addressable + * We decide that everything shall be LTYPE here. + */ + flist(p, ltypify, ip); + } +} + +/* + * Extract codeword from xasm string */ +int +xasmcode(char *s) +{ + int cw = 0; + + while (*s) { + switch ((int)*s) { + case '=': cw |= XASMASG; break; + case '&': cw |= XASMCONSTR; break; + case '+': cw |= XASMINOUT; break; + default: + if ((*s >= 'a' && *s <= 'z') || + (*s >= 'A' && *s <= 'Z') || + (*s >= '0' && *s <= '9')) { + cw |= *s; + return cw; + } + uerror("bad xasm constraint %c", *s); + } + s++; + } + return cw; +} + +static int xasnum, xoffnum; + +static void +xconv(NODE *p, void *arg) +{ + if (p->n_op != TEMP || p->n_rval != xasnum) + return; + p->n_op = OREG; + p->n_rval = FPREG; + p->n_lval = xoffnum; +} + +/* + * Convert nodes of type TEMP to op with lval off. + */ +static void +cvtemps(struct interpass *ipl, int tnum, int off) +{ + struct interpass *ip; + + xasnum = tnum; + xoffnum = off; + + DLIST_FOREACH(ip, ipl, qelem) + if (ip->type == IP_NODE) + walkf(ip->ip_node, xconv, 0); + walkf(ipl->ip_node, xconv, 0); +} Index: node.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/node.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/node.h -L usr.bin/pcc/mip/node.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/node.h +++ usr.bin/pcc/mip/node.h @@ -1,4 +1,4 @@ -/* $Id: node.h,v 1.31 2007/07/22 12:50:56 ragge Exp $ */ +/* $Id: node.h,v 1.35 2008/09/04 08:00:11 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -26,6 +26,9 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#ifndef NODE_H +#define NODE_H + /* * The node structure is the basic element in the compiler. * Depending on the operator, it may be one of several types. @@ -60,6 +63,7 @@ union { int _label; int _stalign; + int _flags; struct suedef *_sue; } n_6; union { @@ -77,7 +81,18 @@ struct symtab *_sp; } n_r; } n_u; +#ifdef SOFTFLOAT +#ifdef FDFLOAT + /* To store F- or D-floats */ + struct softfloat { + unsigned short fd1, fd2, fd3, fd4; + } _dcon; +#else +#error missing softfloat structure definition +#endif +#else long double _dcon; +#endif } n_f; } NODE; @@ -87,6 +102,7 @@ #define n_label n_6._label #define n_stalign n_6._stalign +#define n_flags n_6._flags #define n_sue n_6._sue #define n_left n_f.n_u.n_l._left @@ -97,6 +113,9 @@ #define n_sp n_f.n_u.n_r._sp #define n_dcon n_f._dcon +#define NLOCAL1 010000 +#define NLOCAL2 020000 +#define NLOCAL3 040000 /* * Node types. * @@ -113,7 +132,7 @@ #define REG 6 #define OREG 7 #define TEMP 8 -#define MOVE 9 /* Special reg-reg move node */ +#define XARG 9 /* * Arithmetic nodes. @@ -184,7 +203,7 @@ #define STASG 50 #define STARG 51 #define FORCE 52 -/* #define INIT 53 */ +#define XASM 53 #define GOTO 54 #define RETURN 55 #define STREF 56 @@ -192,3 +211,5 @@ #define ADDROF 58 #define MAXOP 58 + +#endif Index: match.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/match.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/match.c -L usr.bin/pcc/mip/match.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/match.c +++ usr.bin/pcc/mip/match.c @@ -1,4 +1,4 @@ -/* $Id: match.c,v 1.72 2006/07/30 09:32:15 ragge Exp $ */ +/* $Id: match.c,v 1.89 2008/11/26 17:31:40 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -60,16 +60,15 @@ * POSSIBILITY OF SUCH DAMAGE. */ -# include "pass2.h" +#include "pass2.h" +#ifdef HAVE_STRINGS_H #include +#endif -void prttype(int t); void setclass(int tmp, int class); int getclass(int tmp); -int fldsz, fldshf; - int s2debug = 0; extern char *ltyp[], *rtyp[]; @@ -149,27 +148,14 @@ break; case ICON: + case FCON: if (shape & SCON) return SRDIR; break; case FLD: - if (shape & SFLD) { - int sh; - - if ((sh = flshape(p->n_left)) == SRNOPE) - return sh; - /* it is a FIELD shape; make side-effects */ - /* XXX - this will not work for multi-matches */ - o = p->n_rval; - fldsz = UPKFSZ(o); -# ifdef RTOLBYTES - fldshf = UPKFOFF(o); -# else - fldshf = SZINT - fldsz - UPKFOFF(o); -# endif - return sh; - } + if (shape & SFLD) + return flshape(p->n_left); break; case CCODES: @@ -190,9 +176,13 @@ break; case UMUL: +#if 0 if (shumul(p->n_left) & shape) return SROREG; /* Calls offstar to traverse down */ break; +#else + return shumul(p->n_left, shape); +#endif } return SRNOPE; @@ -264,6 +254,13 @@ return(0); } +#define FLDSZ(x) UPKFSZ(x) +#ifdef RTOLBYTES +#define FLDSHF(x) UPKFOFF(x) +#else +#define FLDSHF(x) (SZINT - FLDSZ(x) - UPKFOFF(x)) +#endif + /* * generate code by interpreting table entry */ @@ -272,6 +269,9 @@ { CONSZ val; +//printf("expand\n"); +//fwalk(p, e2print, 0); + for( ; *cp; ++cp ){ switch( *cp ){ @@ -284,23 +284,34 @@ continue; case 'F': /* this line deleted if FOREFF is active */ - if( cookie & FOREFF ) while( *++cp != '\n' ) ; /* VOID */ + if (cookie & FOREFF) { + while (*cp && *cp != '\n') + cp++; + if (*cp == 0) + return; + } continue; case 'S': /* field size */ - printf( "%d", fldsz ); + if (fldexpand(p, cookie, &cp)) + continue; + printf("%d", FLDSZ(p->n_rval)); continue; case 'H': /* field shift */ - printf( "%d", fldshf ); + if (fldexpand(p, cookie, &cp)) + continue; + printf("%d", FLDSHF(p->n_rval)); continue; case 'M': /* field mask */ case 'N': /* complement of field mask */ + if (fldexpand(p, cookie, &cp)) + continue; val = 1; - val <<= fldsz; + val <<= FLDSZ(p->n_rval); --val; - val <<= fldshf; + val <<= FLDSHF(p->n_rval); adrcon( *cp=='M' ? val : ~val ); continue; @@ -312,6 +323,11 @@ continue; case 'O': /* opcode string */ +#ifdef FINDMOPS + if (p->n_op == ASSIGN) + hopcode(*++cp, p->n_right->n_op); + else +#endif hopcode( *++cp, p->n_op ); continue; @@ -382,26 +398,6 @@ return NULL; } -static char *tarr[] = { - "CHAR", "SHORT", "INT", "LONG", "FLOAT", "DOUBLE", "POINT", "UCHAR", - "USHORT", "UINT", "ULONG", "PTRTO", "ANY", "STRUCT", "LONGLONG", - "ULONGLONG", -}; - -void -prttype(int t) -{ - int i, gone = 0; - - for (i = 0; i < 16; i++) - if ((t >> i) & 1) { - if (gone) putchar('|'); - gone++; - printf("%s", tarr[i]); - } -} - - #ifdef PCC_DEBUG #define F2DEBUG(x) if (f2debug) printf x #define F2WALK(x) if (f2debug) fwalk(x, e2print, 0) @@ -415,8 +411,8 @@ * Shape is register class where we want the result. * Returns register class if register nodes. * If w is: (should be shapes) - * - LREG - result in register, call geninsn(). - * - LOREG - create OREG; call offstar(). + * - SRREG - result in register, call geninsn(). + * - SROREG - create OREG; call offstar(). * - 0 - clear su, walk down. */ static int @@ -424,12 +420,14 @@ { int rv = 0; + F2DEBUG(("swmatch: p=%p, shape=%s, w=%s\n", p, prcook(shape), srtyp[w])); + switch (w) { - case LREG: + case SRREG: rv = geninsn(p, shape); break; - case LOREG: + case SROREG: /* should be here only if op == UMUL */ if (p->n_op != UMUL && p->n_op != FLD) comperr("swmatch %p", p); @@ -493,7 +491,8 @@ * p - node (for this leg) * shape - given shape for this leg * cookie - cookie given for parent node - * rv - switch key for traversing down + * rew - + * go - switch key for traversing down * returns register class. */ static int @@ -501,20 +500,23 @@ { int lsh; + F2DEBUG(("shswitch: p=%p, shape=%s, ", p, prcook(shape))); + F2DEBUG(("cookie=%s, rew=0x%x, go=%s\n", prcook(cookie), rew, srtyp[go])); + switch (go) { case SRDIR: /* direct match, just clear su */ (void)swmatch(p, 0, 0); break; case SROREG: /* call offstar to prepare for OREG conversion */ - (void)swmatch(p, shape, LOREG); + (void)swmatch(p, shape, SROREG); break; case SRREG: /* call geninsn() to get value into register */ - lsh = shape & INREGS; + lsh = shape & (FORCC | INREGS); if (rew && cookie != FOREFF) - lsh &= (cookie & INREGS); - lsh = swmatch(p, lsh, LREG); + lsh &= (cookie & (FORCC | INREGS)); + lsh = swmatch(p, lsh, SRREG); if (rew) sh = lsh; break; @@ -549,7 +551,10 @@ for (i = 0; ixp[i] >= 0; i++) { q = &table[ixp[i]]; - F2DEBUG(("findop: ixp %d\n", ixp[i])); + F2DEBUG(("findop: ixp %d str %s\n", ixp[i], q->cstring)); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0 || ttype(r->n_type, q->rtype) == 0) continue; /* Types must be correct */ @@ -565,7 +570,8 @@ F2DEBUG(("findop lshape %d\n", shl)); F2WALK(l); - if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT))== SRNOPE) continue; + if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT)) == SRNOPE) + continue; F2DEBUG(("findop rshape %d\n", shr)); F2WALK(r); @@ -592,18 +598,26 @@ sh = -1; +#ifdef mach_pdp11 + if (cookie == FORCC && p->n_op != AND) /* XXX - fix */ + cookie = INREGS; +#else + if (cookie == FORCC) + cookie = INREGS; +#endif + sh = shswitch(sh, p->n_left, qq->lshape, cookie, qq->rewrite & RLEFT, gol); sh = shswitch(sh, p->n_right, qq->rshape, cookie, qq->rewrite & RRIGHT, gor); if (sh == -1) { - if (cookie == FOREFF) + if (cookie == FOREFF || cookie == FORCC) sh = 0; else sh = ffs(cookie & qq->visit & INREGS)-1; } - F2DEBUG(("findops: node %p (%s)\n", p, prcook(1 << sh))); + F2DEBUG(("findops: node %p sh %d (%s)\n", p, sh, prcook(1 << sh))); p->n_su = MKIDX(idx, 0); SCLASS(p->n_su, sh); return sh; @@ -647,6 +661,9 @@ q = &table[ixp[i]]; F2DEBUG(("relops: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0 || ttype(r->n_type, q->rtype) == 0) continue; /* Types must be correct */ @@ -686,7 +703,7 @@ (void)shswitch(-1, p->n_right, q->rshape, FORCC, q->rewrite & RRIGHT, gor); - F2DEBUG(("findops: node %p\n", p)); + F2DEBUG(("relops: node %p\n", p)); p->n_su = MKIDX(idx, 0); SCLASS(p->n_su, CLASSA); /* XXX */ return 0; @@ -727,7 +744,10 @@ for (i = 0; ixp[i] >= 0; i++) { q = &table[ixp[i]]; - F2DEBUG(("asgop: ixp %d\n", ixp[i])); + F2DEBUG(("findasg: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0 || ttype(r->n_type, q->rtype) == 0) continue; /* Types must be correct */ @@ -735,20 +755,30 @@ if ((cookie & q->visit) == 0) continue; /* must get a result */ - F2DEBUG(("asgop got types\n")); - if ((shl = tshape(l, q->lshape)) == SRNOPE) - continue; - - if (shl == SRREG) - continue; + F2DEBUG(("findasg got types\n")); +#ifdef mach_pdp11 /* XXX - check for other targets too */ + if (p->n_op == STASG && ISPTR(l->n_type)) { + /* Accept lvalue to be in register */ + /* if struct assignment is given a pointer */ + if ((shl = chcheck(l, q->lshape, + q->rewrite & RLEFT)) == SRNOPE) + continue; + } else +#endif + { + if ((shl = tshape(l, q->lshape)) == SRNOPE) + continue; + if (shl == SRREG) + continue; + } - F2DEBUG(("asgop lshape %d\n", shl)); + F2DEBUG(("findasg lshape %d\n", shl)); F2WALK(l); - if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT))== SRNOPE) + if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT)) == SRNOPE) continue; - F2DEBUG(("asgop rshape %d\n", shr)); + F2DEBUG(("findasg rshape %d\n", shr)); F2WALK(r); if (q->needs & REWRITE) break; /* Done here */ @@ -778,6 +808,23 @@ sh = shswitch(sh, p->n_right, qq->rshape, cookie, qq->rewrite & RRIGHT, gor); +#ifdef mach_pdp11 /* XXX all targets? */ + lvl = 0; + if (cookie == FOREFF) + lvl = RVEFF, sh = 0; + else if (cookie == FORCC) + lvl = RVCC, sh = 0; + else if (sh == -1) { + sh = ffs(cookie & qq->visit & INREGS)-1; +#ifdef PCC_DEBUG + if (sh == -1) + comperr("findasg bad shape"); +#endif + SCLASS(lvl,sh); + } else + SCLASS(lvl,sh); + p->n_su = MKIDX(idx, lvl); +#else if (sh == -1) { if (cookie == FOREFF) sh = 0; @@ -788,7 +835,10 @@ p->n_su = MKIDX(idx, 0); SCLASS(p->n_su, sh); - +#endif /* mach_pdp11 */ +#ifdef FINDMOPS + p->n_flags &= ~1; +#endif return sh; } @@ -812,6 +862,9 @@ q = &table[ixp[i]]; F2DEBUG(("findumul: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if ((q->visit & cookie) == 0) continue; /* wrong registers */ @@ -874,6 +927,8 @@ q = &table[ixp[i]]; F2DEBUG(("findleaf: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; if ((q->visit & cookie) == 0) continue; /* wrong registers */ @@ -935,6 +990,9 @@ q = &table[ixp[i]]; F2DEBUG(("finduni: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0) continue; /* Type must be correct */ @@ -993,3 +1051,192 @@ SCLASS(p->n_su, sh); return sh; } + +#ifdef FINDMOPS +/* + * Try to find constructs like "a = a + 1;" and match them together + * with instructions like "incl a" or "addl $1,a". + * + * Level assignment for priority: + * left right prio + * - - - + * direct direct 1 + * direct REG 2 + * direct OREG 3 + * OREG direct 4 + * OREG REG 5 + * OREG OREG 6 + */ +int +findmops(NODE *p, int cookie) +{ + extern int *qtable[]; + struct optab *q; + int i, sh, shl, shr, lvl = 10; + NODE *l, *r; + int *ixp; + struct optab *qq = NULL; /* XXX gcc */ + int idx = 0, gol = 0, gor = 0; + + shl = shr = 0; + + F2DEBUG(("findmops tree: %s\n", prcook(cookie))); + F2WALK(p); + + l = getlr(p, 'L'); + r = getlr(p, 'R'); + /* See if this is a usable tree to work with */ + /* Currently only check for leaves */ + if (optype(r->n_op) != BITYPE || treecmp(l, r->n_left) == 0) + return FFAIL; + + F2DEBUG(("findmops is useable\n")); + + /* We can try to find a match. Use right op */ + ixp = qtable[r->n_op]; + l = getlr(r, 'L'); + r = getlr(r, 'R'); + + for (i = 0; ixp[i] >= 0; i++) { + q = &table[ixp[i]]; + + F2DEBUG(("findmops: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + + if (ttype(l->n_type, q->ltype) == 0 || + ttype(r->n_type, q->rtype) == 0) + continue; /* Types must be correct */ + + F2DEBUG(("findmops got types\n")); + + switch (cookie) { + case FOREFF: + if ((q->visit & FOREFF) == 0) + continue; /* Not only for side effects */ + break; + case FORCC: + if ((q->visit & FORCC) == 0) + continue; /* Not only for side effects */ + break; + default: + if ((cookie & q->visit) == 0) + continue; /* Won't match requested shape */ + if (((cookie & INREGS & q->lshape) == 0) || !isreg(l)) + continue; /* Bad return register */ + break; + } + F2DEBUG(("findmops cookie\n")); + + /* + * left shape must match left node. + */ + if ((shl = tshape(l, q->lshape)) != SRDIR && (shl != SROREG)) + continue; + + F2DEBUG(("findmops lshape %d\n", shl)); + F2WALK(l); + + if ((shr = chcheck(r, q->rshape, 0)) == SRNOPE) + continue; + + F2DEBUG(("findmops rshape %d\n", shr)); + + /* + * Only allow RLEFT. XXX + */ + if ((q->rewrite & (RLEFT|RRIGHT)) != RLEFT) + continue; + + F2DEBUG(("rewrite OK\n")); + + F2WALK(r); + if (q->needs & REWRITE) + break; /* Done here */ + + if (lvl <= (shl + shr)) + continue; + + lvl = shl + shr; + qq = q; + idx = ixp[i]; + gol = shl; + gor = shr; + } + + if (lvl == 10) + return FFAIL; + F2DEBUG(("findmops entry %d(%s,%s)\n", idx, srtyp[gol], srtyp[gor])); + + /* + * Now we're here and have a match. left is semi-direct and + * right may be anything. + */ + + sh = -1; + sh = shswitch(sh, p->n_left, qq->lshape, cookie, + qq->rewrite & RLEFT, gol); + sh = shswitch(sh, r, qq->rshape, cookie, 0, gor); + + if (sh == -1) { + if (cookie & (FOREFF|FORCC)) + sh = 0; + else + sh = ffs(cookie & qq->visit & INREGS)-1; + } + F2DEBUG(("findmops done: node %p class %d\n", p, sh)); + + /* Trickery: Set table index on assign to op instead */ + /* gencode() will remove useless nodes */ + p->n_su = MKIDX(idx, 0); + p->n_flags |= 1; /* XXX tell gencode to reduce the right tree */ + SCLASS(p->n_su, sh); + + return sh; +} + +/* + * Compare two trees; return 1 if equal and 0 if not. + */ +int +treecmp(NODE *p1, NODE *p2) +{ + if (p1->n_op != p2->n_op) + return 0; + + switch (p1->n_op) { + case UMUL: + return treecmp(p1->n_left, p2->n_left); + + case OREG: + if (p1->n_lval != p2->n_lval || p1->n_rval != p2->n_rval) + return 0; + break; + + case NAME: + case ICON: + if (strcmp(p1->n_name, p2->n_name)) + return 0; + /* FALLTHROUGH */ + if (p1->n_lval != p2->n_lval) + return 0; + break; + + case REG: + case TEMP: + if (p1->n_rval != p2->n_rval) + return 0; + break; + case PLUS: + case MINUS: + if (treecmp(p1->n_left, p2->n_left) == 0 || + treecmp(p1->n_right, p2->n_right) == 0) + return 0; + break; + + default: + return 0; + } + return 1; +} +#endif Index: pass2.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/pass2.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/pass2.h -L usr.bin/pcc/mip/pass2.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/pass2.h +++ usr.bin/pcc/mip/pass2.h @@ -1,4 +1,4 @@ -/* $Id: pass2.h,v 1.98 2006/12/22 06:23:09 ragge Exp $ */ +/* $Id: pass2.h,v 1.119 2008/11/22 20:13:50 pantzer Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -34,13 +34,14 @@ */ #include -#include "manifest.h" -#include "protos.h" #ifndef MKEXT #include "external.h" #else -typedef int bittype; /* XXX - for basicblock */ +typedef unsigned int bittype; /* XXX - for basicblock */ +#define BIT2BYTE(a) (((a) + 31) / 32) #endif +#include "manifest.h" +#include "protos.h" /* cookies, used as arguments to codgen */ #define FOREFF 01 /* compute for effects only */ @@ -50,8 +51,12 @@ #define INDREG 020 /* compute into a register */ #define INREGS (INAREG|INBREG|INCREG|INDREG) #define FORCC 040 /* compute for condition codes only */ +#define QUIET 0100 /* tell geninsn() to not complain if fail */ #define INTEMP 010000 /* compute into a temporary location */ #define FORREW 040000 /* search the table for a rewrite rule */ +#define INEREG 0x10000 /* compute into a register, > 16 bits */ +#define INFREG 0x20000 /* compute into a register, > 16 bits */ +#define INGREG 0x40000 /* compute into a register, > 16 bits */ /* * OP descriptors, @@ -91,10 +96,13 @@ #define SSCON (SPECIAL|4) /* -32768 <= constant < 32768 */ #define SSOREG (SPECIAL|5) /* non-indexed OREG */ #define MAXSPECIAL (SPECIAL|5) +#define SEREG 0x10000 /* same as INEREG */ +#define SFREG 0x20000 /* same as INFREG */ +#define SGREG 0x40000 /* same as INGREG */ /* These are used in rstatus[] in conjunction with SxREG */ -#define TEMPREG 0100 -#define PERMREG 0200 +#define TEMPREG 01000 +#define PERMREG 02000 /* tshape() return values */ #define SRNOPE 0 /* Cannot match any shape */ @@ -140,28 +148,38 @@ #define RNOP 010000 /* DANGER: can cause loops.. */ /* needs */ -#define NAREG 0000001 -#define NACOUNT 0000003 -#define NAMASK 0000017 -#define NASL 0000004 /* may share left register */ -#define NASR 0000010 /* may share right register */ -#define NBREG 0000020 -#define NBCOUNT 0000060 -#define NBMASK 0000360 -#define NBSL 0000100 -#define NBSR 0000200 -#define NTEMP 0000400 -#define NTMASK 0001400 -#define NSPECIAL 0040000 /* need special register treatment */ -#define REWRITE 0100000 -#define NCSL 0x10000 /* Above 16 bit */ -#define NCSR 0x20000 /* Above 16 bit */ -#define NCREG 0x40000 /* Above 16 bit */ -#define NCCOUNT 0xc0000 -#define NDSL 0x100000 /* Above 16 bit */ -#define NDSR 0x200000 /* Above 16 bit */ -#define NDREG 0x400000 /* Above 16 bit */ -#define NDCOUNT 0xc00000 +#define NASL 0x0001 /* may share left register */ +#define NASR 0x0002 /* may share right register */ +#define NAREG 0x0004 +#define NACOUNT 0x000c +#define NBSL 0x0010 +#define NBSR 0x0020 +#define NBREG 0x0040 +#define NBCOUNT 0x00c0 +#define NCSL 0x0100 +#define NCSR 0x0200 +#define NCREG 0x0400 +#define NCCOUNT 0x0c00 +#define NTEMP 0x1000 +#define NTMASK 0x3000 +#define NSPECIAL 0x4000 /* need special register treatment */ +#define REWRITE 0x8000 +#define NDSL 0x00010000 /* Above 16 bit */ +#define NDSR 0x00020000 /* Above 16 bit */ +#define NDREG 0x00040000 /* Above 16 bit */ +#define NDCOUNT 0x000c0000 +#define NESL 0x00100000 /* Above 16 bit */ +#define NESR 0x00200000 /* Above 16 bit */ +#define NEREG 0x00400000 /* Above 16 bit */ +#define NECOUNT 0x00c00000 +#define NFSL 0x01000000 /* Above 16 bit */ +#define NFSR 0x02000000 /* Above 16 bit */ +#define NFREG 0x04000000 /* Above 16 bit */ +#define NFCOUNT 0x0c000000 +#define NGSL 0x10000000 /* Above 16 bit */ +#define NGSR 0x20000000 /* Above 16 bit */ +#define NGREG 0x40000000 /* Above 16 bit */ +#define NGCOUNT 0xc0000000 /* special treatment */ #define NLEFT (0001) /* left leg register (moveadd) */ @@ -178,14 +196,6 @@ #define isreg(p) (p->n_op == REG || p->n_op == TEMP) -#define TBUSY 01000 - -#define SETSTO(x,y) (stotree = (x), stocook = (y)) -extern int stocook; - -extern NODE *stotree; -extern int callflag; - extern int fregs; /* code tables */ @@ -215,14 +225,13 @@ #endif }; +struct p2env; extern NODE resc[]; - extern int p2autooff, p2maxautooff; extern NODE *talloc(void), *eread(void), - *tcopy(NODE *), *mklnode(int, CONSZ, int, TWORD), *mkbinode(int, NODE *, NODE *, TWORD), *mkunode(int, NODE *, int, TWORD), @@ -230,17 +239,12 @@ void eoftn(struct interpass_prolog *); void prologue(struct interpass_prolog *); -void setlocc(int locctr); void e2print(NODE *p, int down, int *a, int *b); void myoptim(struct interpass *); void cbgen(int op, int label); -struct optab *nxtmatch(struct optab *); -int chkmatch(NODE *, int, int, int); int match(NODE *p, int cookie); -int nmatch(NODE *p, int what); -#ifndef special +int acceptable(struct optab *); int special(NODE *, int); -#endif int setasg(NODE *, int); int setuni(NODE *, int); int sucomp(NODE *); @@ -250,9 +254,8 @@ void adrput(FILE *, NODE *); void comperr(char *str, ...); void genregs(NODE *p); -void ngenregs(struct interpass *); +void ngenregs(struct p2env *); NODE *store(NODE *); -void gencall(NODE *, NODE *prev); struct interpass *ipnode(NODE *); void deflab(int); void rmove(int, int, TWORD); @@ -265,14 +268,29 @@ int findumul(NODE *p, int); int findleaf(NODE *p, int); int relops(NODE *p); +#ifdef FINDMOPS +int findmops(NODE *p, int); +int treecmp(NODE *p1, NODE *p2); +#endif void offstar(NODE *p, int shape); int gclass(TWORD); void lastcall(NODE *); void myreader(struct interpass *pole); int oregok(NODE *p, int sharp); void myormake(NODE *); - +int *livecall(NODE *); +void prtreg(FILE *, NODE *); char *prcook(int); +int myxasm(struct interpass *ip, NODE *p); +int xasmcode(char *s); +int freetemp(int k); +int rewfld(NODE *p); +void canon(NODE *); +void mycanon(NODE *); +void oreg2(NODE *p, void *); +int shumul(NODE *p, int); +NODE *deluseless(NODE *p); +int getlab2(void); void conput(FILE *, NODE *); @@ -289,6 +307,17 @@ #define CLASSC 3 #define CLASSD 4 #define CLASSE 5 +#define CLASSF 6 +#define CLASSG 7 + +/* used when parsing xasm codes */ +#define XASMVAL(x) ((x) & 0377) /* get val from codeword */ +#define XASMASG 0x100 /* = */ +#define XASMCONSTR 0x200 /* & */ +#define XASMINOUT 0x400 /* + */ +#define XASMALL (XASMASG|XASMCONSTR|XASMINOUT) +#define XASMISINP(cw) (((cw) & XASMASG) == 0) /* input operand */ +#define XASMISOUT(cw) ((cw) & (XASMASG|XASMINOUT)) /* output operand */ /* routines to handle double indirection */ #ifdef R2REGS @@ -299,8 +328,8 @@ extern int lineno; extern int fldshf, fldsz; -extern int lflag, x2debug, udebug, e2debug, odebug, mdebug; -extern int rdebug, radebug, t2debug, s2debug, b2debug, c2debug; +extern int lflag, x2debug, udebug, e2debug, odebug; +extern int rdebug, t2debug, s2debug, b2debug, c2debug; extern int kflag; #ifdef FORT extern int Oflag; @@ -330,24 +359,17 @@ /* * Layout of findops() return value: - * bit 0-1 where to store left node. - * bit 2-3 where to store right node. - * bit 4 set if right leg should be evaluated first - * bit 5- table index + * bit 0 whether left shall go into a register. + * bit 1 whether right shall go into a register. + * bit 2 entry is only used for side effects. + * bit 3 if condition codes are used. * - * LOREG means: walk down left node, after code emission call canon() to - * convert the tree to an OREG. + * These values should be synced with FOREFF/FORCC. */ #define LREG 001 -#define LOREG 002 -#define LTEMP 003 -#define LDIR 003 -#define LMASK 003 -#define RREG 004 -#define ROREG 010 -#define RTEMP 014 -#define RDIR 014 -#define RMASK 014 +#define RREG 002 +#define RVEFF 004 +#define RVCC 010 #define DORIGHT 020 #define SCLASS(v,x) ((v) |= ((x) << 5)) #define TCLASS(x) (((x) >> 5) & 7) @@ -360,9 +382,12 @@ #define TBREGS 0 #endif #define REGBIT(x) (1 << (x)) +#ifndef PERMTYPE +#define PERMTYPE(a) (INT) +#endif void emit(struct interpass *); -void optimize(struct interpass *); +void optimize(struct p2env *); struct basicblock { DLIST_ENTRY(basicblock) bbelem; @@ -380,23 +405,25 @@ bittype *dfchildren; bittype *Aorig; bittype *Aphi; + SLIST_HEAD(, phiinfo) phi; struct interpass *first; /* first element of basic block */ struct interpass *last; /* last element of basic block */ }; struct labelinfo { struct basicblock **arr; - unsigned int size; + int size; unsigned int low; }; struct bblockinfo { - unsigned int size; + int size; struct basicblock **arr; }; struct varinfo { struct pvarinfo **arr; + SLIST_HEAD(, varstack) *stack; int size; int low; }; @@ -404,14 +431,44 @@ struct pvarinfo { struct pvarinfo *next; struct basicblock *bb; - NODE *top, *n; + TWORD n_type; +}; + +struct varstack { + SLIST_ENTRY(varstack) varstackelem; + int tmpregno; }; + struct cfgnode { SLIST_ENTRY(cfgnode) cfgelem; struct basicblock *bblock; }; +struct phiinfo { + SLIST_ENTRY(phiinfo) phielem; + int tmpregno; + int newtmpregno; + TWORD n_type; + int size; + int *intmpregno; +}; + +/* + * Description of the pass2 environment. + * There will be only one of these structs. It is used to keep + * all state descriptions during the compilation of a function + * in one place. + */ +struct p2env { + struct interpass ipole; /* all statements */ + struct interpass_prolog *ipp, *epp; /* quick references */ + struct basicblock bblocks; + int nbblocks; +}; + +extern struct p2env p2env; + /* * C compiler second pass extra defines. */ Index: regs.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/regs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/regs.c -L usr.bin/pcc/mip/regs.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/regs.c +++ usr.bin/pcc/mip/regs.c @@ -1,4 +1,4 @@ -/* $Id: regs.c,v 1.155 2007/09/22 17:15:00 ragge Exp $ */ +/* $Id: regs.c,v 1.198 2008/12/14 18:26:02 ragge Exp $ */ /* * Copyright (c) 2005 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -28,11 +28,22 @@ #include "pass2.h" #include +#ifdef HAVE_STRINGS_H +#include +#endif +#ifdef HAVE_STDINT_H +#include +#endif #include +#ifdef HAVE_ALLOCA_H +#include +#endif #define MAXLOOP 20 /* Max number of allocation loops XXX 3 should be enough */ +#ifndef MAX #define MAX(a,b) (((a) > (b)) ? (a) : (b)) +#endif /* * New-style register allocator using graph coloring. @@ -40,9 +51,8 @@ * "Iterated Register Coalescing", ACM Transactions, No 3, May 1996. */ -#define BIT2BYTE(bits) ((((bits)+NUMBITS-1)/NUMBITS)*(NUMBITS/8)) #define BITALLOC(ptr,all,sz) { \ - int __s = BIT2BYTE(sz); ptr = all(__s); memset(ptr, 0, __s); } + int sz__s = BIT2BYTE(sz); ptr = all(sz__s); memset(ptr, 0, sz__s); } #undef COMPERR_PERM_MOVE #define RDEBUG(x) if (rdebug) printf x @@ -50,6 +60,9 @@ #define RPRINTIP(x) if (rdebug) printip(x) #define RDX(x) x #define UDEBUG(x) if (udebug) printf x +#define BDEBUG(x) if (b2debug) printf x + +#define VALIDREG(p) (p->n_op == REG && TESTBIT(validregs, regno(p))) /* * Data structure overview for this implementation of graph coloring: @@ -124,6 +137,7 @@ static REGW initial, *nblock; static void insnwalk(NODE *p); #ifdef PCC_DEBUG +int use_regw; int nodnum = 100; #define SETNUM(x) (x)->nodnum = nodnum++ #define ASGNUM(x) (x)->nodnum @@ -132,7 +146,7 @@ #define ASGNUM(x) #endif -#define ALLNEEDS (NACOUNT|NBCOUNT|NCCOUNT|NDCOUNT) +#define ALLNEEDS (NACOUNT|NBCOUNT|NCCOUNT|NDCOUNT|NECOUNT|NFCOUNT|NGCOUNT) /* XXX */ REGW *ablock; @@ -157,17 +171,21 @@ static REGW * newblock(NODE *p) { - REGW *nb = &nblock[(int)p->n_lval]; + REGW *nb = &nblock[regno(p)]; if (nb->link.q_forw == 0) { DLIST_INSERT_AFTER(&initial, nb, link); - ASGNUM(nb) = p->n_lval; +#ifdef PCC_DEBUG + ASGNUM(nb) = regno(p); RDEBUG(("Adding longtime %d for tmp %d\n", - nb->nodnum, (int)p->n_lval)); + nb->nodnum, regno(p))); +#endif } if (nb->r_class == 0) nb->r_class = gclass(p->n_type); +#ifdef PCC_DEBUG RDEBUG(("newblock: p %p, node %d class %d\n", p, nb->nodnum, nb->r_class)); +#endif return nb; } @@ -191,7 +209,7 @@ struct optab *q; int left, right; int nreg, need, i, nxreg, o; - int nareg, nbreg, ncreg, ndreg; + int nareg, nbreg, ncreg, ndreg, nereg, nfreg, ngreg; REGW *w; o = optype(p->n_op); @@ -205,6 +223,8 @@ if (o == LTYPE ) { if (p->n_op == TEMP) p->n_regw = newblock(p); + else if (p->n_op == REG) + p->n_regw = &ablock[regno(p)]; } else a = nsucomp(p->n_left); if (o == BITYPE) { @@ -217,16 +237,23 @@ } q = &table[TBLIDX(p->n_su)]; - nareg = (q->needs & NACOUNT); + for (i = (q->needs & NACOUNT), nareg = 0; i; i -= NAREG) + nareg++; for (i = (q->needs & NBCOUNT), nbreg = 0; i; i -= NBREG) nbreg++; for (i = (q->needs & NCCOUNT), ncreg = 0; i; i -= NCREG) ncreg++; for (i = (q->needs & NDCOUNT), ndreg = 0; i; i -= NDREG) ndreg++; + for (i = (q->needs & NECOUNT), nereg = 0; i; i -= NEREG) + nereg++; + for (i = (q->needs & NFCOUNT), nfreg = 0; i; i -= NFREG) + nfreg++; + for (i = (q->needs & NGCOUNT), ngreg = 0; i; i -= NGREG) + ngreg++; - nxreg = nareg + nbreg + ncreg + ndreg; + nxreg = nareg + nbreg + ncreg + ndreg + nereg + nfreg + ngreg; nreg = nxreg; if (callop(p->n_op)) nreg = MAX(fregs, nreg); @@ -276,11 +303,18 @@ return need; } +#ifdef PCC_DEBUG #define ADCL(n, cl) \ for (i = 0; i < n; i++, w++) { w->r_class = cl; \ DLIST_INSERT_BEFORE(&initial, w, link); SETNUM(w); \ UDEBUG(("Adding " #n " %d\n", w->nodnum)); \ } +#else +#define ADCL(n, cl) \ + for (i = 0; i < n; i++, w++) { w->r_class = cl; \ + DLIST_INSERT_BEFORE(&initial, w, link); SETNUM(w); \ + } +#endif UDEBUG(("node %p numregs %d\n", p, nxreg+1)); w = p->n_regw = tmpalloc(sizeof(REGW) * (nxreg+1)); @@ -293,12 +327,17 @@ SETNUM(w); if (w->r_class) DLIST_INSERT_BEFORE(&initial, w, link); - UDEBUG(("Adding short %d calss %d\n", w->nodnum, w->r_class)); +#ifdef PCC_DEBUG + UDEBUG(("Adding short %d class %d\n", w->nodnum, w->r_class)); +#endif w++; ADCL(nareg, CLASSA); ADCL(nbreg, CLASSB); ADCL(ncreg, CLASSC); ADCL(ndreg, CLASSD); + ADCL(nereg, CLASSE); + ADCL(nfreg, CLASSF); + ADCL(ngreg, CLASSG); if (q->rewrite & RESC1) { w = p->n_regw + 1; @@ -361,9 +400,13 @@ #endif i = COLORMAP(c, r); -if (i < 0 || i > 1) - comperr("trivially_colorable_p"); -//printf("trivially_colorable_p: n[1] %d n[2] %d n[3] %d n[4] %d class %d, triv %d\n", n[1], n[2], n[3], n[4], c, i); + if (i < 0 || i > 1) + comperr("trivially_colorable_p"); +#ifdef PCC_DEBUG + if (rdebug > 1) + printf("trivially_colorable_p: n[1] %d n[2] %d n[3] %d n[4] " + "%d for class %d, triv %d\n", n[1], n[2], n[3], n[4], c, i); +#endif return i; } @@ -380,10 +423,16 @@ needs -= NCREG, i++; while (needs & NDCOUNT) needs -= NDREG, i++; + while (needs & NECOUNT) + needs -= NEREG, i++; + while (needs & NFCOUNT) + needs -= NFREG, i++; + while (needs & NGCOUNT) + needs -= NGREG, i++; return i; } -static inline REGW * +static REGW * popwlist(REGW *l) { REGW *w = DLIST_NEXT(l, link); @@ -400,7 +449,7 @@ worklistMoves, activeMoves; enum { COAL, CONSTR, FROZEN, WLIST, ACTIVE }; -static inline REGM * +static REGM * popmlist(REGM *l) { REGM *w = DLIST_NEXT(l, link); @@ -418,7 +467,7 @@ * * Bitfields are used for liveness. Bit arrays are allocated on the * heap for the "live" variable and on the stack for the in, out, gen - * and kill variables. Therefore, for a temp number, the bit number must + * and killed variables. Therefore, for a temp number, the bit number must * be biased with tempmin. * * There may be an idea to use a different data structure to store @@ -430,21 +479,31 @@ LIVEADD(int x) { RDEBUG(("Liveadd: %d\n", x)); - if (x < tempmin || x >= tempmax) + if (x >= MAXREGS && (x < tempmin || x >= tempmax)) comperr("LIVEADD: out of range"); - BITSET(live, (x-tempmin)); + if (x < MAXREGS) { + BITSET(live, x); + } else + BITSET(live, (x-tempmin+MAXREGS)); } + static void LIVEDEL(int x) { RDEBUG(("Livedel: %d\n", x)); - if (x < tempmin || x >= tempmax) + + if (x >= MAXREGS && (x < tempmin || x >= tempmax)) comperr("LIVEDEL: out of range"); - BITCLEAR(live, (x-tempmin)); + if (x < MAXREGS) { + BITCLEAR(live, x); + } else + BITCLEAR(live, (x-tempmin+MAXREGS)); } #else -#define LIVEADD(x) BITSET(live, (x-tempmin)) -#define LIVEDEL(x) BITCLEAR(live, (x-tempmin)) +#define LIVEADD(x) \ + (x >= MAXREGS ? BITSET(live, (x-tempmin+MAXREGS)) : BITSET(live, x)) +#define LIVEDEL(x) \ + (x >= MAXREGS ? BITCLEAR(live, (x-tempmin+MAXREGS)) : BITCLEAR(live, x)) #endif static struct lives { @@ -479,7 +538,9 @@ { struct lives *l; +#ifdef PCC_DEBUG RDEBUG(("LIVEDELR: %d\n", x->nodnum)); +#endif DLIST_FOREACH(l, &lused, link) { if (l->var != x) continue; @@ -515,10 +576,11 @@ return w; } +#define HASHSZ 16384 struct AdjSet { struct AdjSet *next; REGW *u, *v; -} *edgehash[256]; +} *edgehash[HASHSZ]; /* Check if a node pair is adjacent */ static int @@ -543,7 +605,7 @@ } if (u > v) t = v, v = u, u = t; - w = edgehash[((long)u+(long)v) & 255]; + w = edgehash[((intptr_t)u+(intptr_t)v) & (HASHSZ-1)]; for (; w; w = w->next) { if (u == w->u && v == w->v) return 1; @@ -561,7 +623,7 @@ if (u > v) t = v, v = u, u = t; - x = ((long)u+(long)v) & 255; + x = ((intptr_t)u+(intptr_t)v) & (HASHSZ-1); w = tmpalloc(sizeof(struct AdjSet)); w->u = u, w->v = v; w->next = edgehash[x]; @@ -576,9 +638,9 @@ { ADJL *x; +#ifdef PCC_DEBUG RRDEBUG(("AddEdge: u %d v %d\n", ASGNUM(u), ASGNUM(v))); -#ifdef PCC_DEBUG #if 0 if (ASGNUM(u) == 0) comperr("AddEdge 0"); @@ -678,10 +740,11 @@ addalledges(REGW *e) { int i, j, k; - int nbits = xbits; struct lives *l; +#ifdef PCC_DEBUG RDEBUG(("addalledges for %d\n", e->nodnum)); +#endif if (e->r_class == -1) return; /* unused */ @@ -691,14 +754,17 @@ AddEdge(e, &ablock[ndontregs[i]]); } - /* First add to long-lived temps */ + /* First add to long-lived temps and hard regs */ RDEBUG(("addalledges longlived ")); - for (i = 0; i < nbits; i += NUMBITS) { + for (i = 0; i < xbits; i += NUMBITS) { if ((k = live[i/NUMBITS]) == 0) continue; while (k) { j = ffs(k)-1; - AddEdge(&nblock[i+j+tempmin], e); + if (i+j < MAXREGS) + AddEdge(&ablock[i+j], e); + else + AddEdge(&nblock[i+j+tempmin-MAXREGS], e); RRDEBUG(("%d ", i+j+tempmin)); k &= ~(1 << j); } @@ -707,7 +773,9 @@ /* short-lived temps */ RDEBUG(("addalledges shortlived ")); DLIST_FOREACH(l, &lused, link) { +#ifdef PCC_DEBUG RRDEBUG(("%d ", ASGNUM(l->var))); +#endif AddEdge(l->var, e); } RDEBUG(("done\n")); @@ -723,7 +791,9 @@ if (def == use) return; /* no move to itself XXX - ``shouldn't happen'' */ +#ifdef PCC_DEBUG RDEBUG(("moveadd: def %d use %d\n", ASGNUM(def), ASGNUM(use))); +#endif r = WORKLISTMOVEADD(use, def); MOVELISTADD(def, r); @@ -754,23 +824,25 @@ setlive(NODE *p, int set, REGW *rv) { if (rv != NULL) { + if (rv->nodnum < MAXREGS && + TESTBIT(validregs, rv->nodnum) == 0) + return; set ? LIVEADDR(rv) : LIVEDELR(rv); return; } if (p->n_regw != NULL) { + if (p->n_regw->nodnum < MAXREGS && + TESTBIT(validregs, p->n_regw->nodnum) == 0) + return; set ? LIVEADDR(p->n_regw) : LIVEDELR(p->n_regw); return; } switch (optype(p->n_op)) { case LTYPE: - if (p->n_op == TEMP) - set ? LIVEADD((int)p->n_lval) : LIVEDEL((int)p->n_lval); -#ifdef notyet - else if (p->n_op == REG) - ... -#endif + if (p->n_op == TEMP || VALIDREG(p)) + set ? LIVEADD(regno(p)) : LIVEDEL(regno(p)); break; case BITYPE: setlive(p->n_right, set, rv); @@ -788,7 +860,12 @@ static void addedge_r(NODE *p, REGW *w) { + RRDEBUG(("addedge_r: node %p regw %p\n", p, w)); + if (p->n_regw != NULL) { + if (p->n_regw->nodnum < MAXREGS && + TESTBIT(validregs, p->n_regw->nodnum) == 0) + return; AddEdge(p->n_regw, w); return; } @@ -800,6 +877,50 @@ } /* + * add/del parameter from live set. + */ +static void +setxarg(NODE *p) +{ + int i, ut = 0, in = 0; + int cw; + + if (p->n_op == ICON && p->n_type == STRTY) + return; + + RDEBUG(("setxarg %p %s\n", p, p->n_name)); + cw = xasmcode(p->n_name); + if (XASMISINP(cw)) + in = 1; + if (XASMISOUT(cw)) + ut = 1; + + switch (XASMVAL(cw)) { + case 'g': + if (p->n_left->n_op != REG && p->n_left->n_op != TEMP) + break; + /* FALLTHROUGH */ + case 'r': + i = regno(p->n_left); + if (ut) { + REGW *rw = p->n_left->n_op == REG ? ablock : nblock; + LIVEDEL(i); + addalledges(&rw[i]); + } + if (in) { + LIVEADD(i); + } + break; + case 'i': + case 'm': + case 'n': + break; + default: + comperr("bad ixarg %s", p->n_name); + } +} + +/* * Do the in-tree part of liveness analysis. (the difficult part) * * Walk down the tree in reversed-evaluation order (backwards). @@ -825,14 +946,13 @@ * Moves to special regs are scheduled after the evaluation of both legs. */ -#define ASGLEFT(p) (p->n_op == ASSIGN && p->n_left->n_op == TEMP) - static void insnwalk(NODE *p) { int o = p->n_op; struct optab *q = &table[TBLIDX(p->n_su)]; REGW *lr, *rr, *rv, *r, *rrv, *lrv; + NODE *lp, *rp; int i, n; RDEBUG(("insnwalk %p\n", p)); @@ -840,14 +960,16 @@ rv = p->n_regw; rrv = lrv = NULL; - if (ASGLEFT(p)) { - int v = p->n_left->n_lval; - LIVEDEL(v); /* remove assigned temp from live set */ - addalledges(&nblock[v]); + if (p->n_op == ASSIGN && + (p->n_left->n_op == TEMP || VALIDREG(p->n_left))) { + lr = p->n_left->n_op == TEMP ? nblock : ablock; + i = regno(p->n_left); + LIVEDEL(i); /* remove assigned temp from live set */ + addalledges(&lr[i]); } /* Add edges for the result of this node */ - if (rv && (q->visit & INREGS || o == TEMP)) + if (rv && (q->visit & INREGS || o == TEMP || VALIDREG(p))) addalledges(rv); /* special handling of CALL operators */ @@ -866,24 +988,36 @@ /* Check leaves for results in registers */ lr = optype(o) != LTYPE ? p->n_left->n_regw : NULL; + lp = optype(o) != LTYPE ? p->n_left : NULL; rr = optype(o) == BITYPE ? p->n_right->n_regw : NULL; + rp = optype(o) == BITYPE ? p->n_right : NULL; /* simple needs */ n = ncnt(q->needs); for (i = 0; i < n; i++) { #if 1 - static int ncl[] = { 0, NASL, NBSL, NCSL, NDSL }; - static int ncr[] = { 0, NASR, NBSR, NCSR, NDSR }; - + static int ncl[] = + { 0, NASL, NBSL, NCSL, NDSL, NESL, NFSL, NGSL }; + static int ncr[] = + { 0, NASR, NBSR, NCSR, NDSR, NESR, NFSR, NGSR }; + int j; + /* edges are already added */ - if ((r = &p->n_regw[1+i])->r_class == -1) + if ((r = &p->n_regw[1+i])->r_class == -1) { r = p->n_regw; - else + } else { + AddEdge(r, p->n_regw); addalledges(r); + } if (optype(o) != LTYPE && (q->needs & ncl[CLASS(r)]) == 0) addedge_r(p->n_left, r); if (optype(o) == BITYPE && (q->needs & ncr[CLASS(r)]) == 0) addedge_r(p->n_right, r); + for (j = i + 1; j < n; j++) { + if (p->n_regw[j+1].r_class == -1) + continue; + AddEdge(r, &p->n_regw[j+1]); + } #else if ((r = &p->n_regw[1+i])->r_class == -1) continue; @@ -924,6 +1058,13 @@ } if (o == ASSIGN) { + /* avoid use of unhandled registers */ + if (p->n_left->n_op == REG && + !TESTBIT(validregs, regno(p->n_left))) + lr = NULL; + if (p->n_right->n_op == REG && + !TESTBIT(validregs, regno(p->n_right))) + rr = NULL; /* needs special treatment */ if (lr && rr) moveadd(lr, rr); @@ -932,33 +1073,31 @@ if (rr && rv) moveadd(rr, rv); } else if (callop(o)) { -#ifdef notdef - /* calls needs special treatment */ - for (i = 0; tempregs[i] >= 0; i++) - addalledges(&ablock[i]); - if (rv) - moveadd(rv, &ablock[RETREG(p->n_type)]); -#endif - /* XXX - here must all live arg registers be added - * for archs with arguments in registers */ + int *c; + + for (c = livecall(p); *c != -1; c++) { + addalledges(ablock + *c); + LIVEADD(*c); + } } else if (q->rewrite & (RESC1|RESC2|RESC3)) { if (lr && rr) AddEdge(lr, rr); } else if (q->rewrite & RLEFT) { if (lr && rv) moveadd(rv, lr), lrv = rv; - if (rr && rv) - AddEdge(rr, rv); + if (rv && rp) + addedge_r(rp, rv); } else if (q->rewrite & RRIGHT) { if (rr && rv) moveadd(rv, rr), rrv = rv; - if (lr && rv) - AddEdge(lr, rv); + if (rv && lp) + addedge_r(lp, rv); } switch (optype(o)) { case BITYPE: - if (ASGLEFT(p)) { + if (p->n_op == ASSIGN && + (p->n_left->n_op == TEMP || p->n_left->n_op == REG)) { /* only go down right node */ insnwalk(p->n_right); } else if (callop(o)) { @@ -984,18 +1123,23 @@ case LTYPE: switch (o) { + case REG: + if (!TESTBIT(validregs, regno(p))) + break; /* never add moves */ + /* FALLTHROUGH */ case TEMP: - rr = &nblock[(int)p->n_lval]; + i = regno(p); + rr = (o == TEMP ? &nblock[i] : &ablock[i]); if (rv != rr) { addalledges(rr); moveadd(rv, rr); } - LIVEADD((int)p->n_lval); - break; - case REG: - case OREG: - /* Liveness for regs??? */ + LIVEADD(i); break; + + case OREG: /* XXX - not yet */ + break; + default: break; } @@ -1003,8 +1147,218 @@ } } -static bittype **gen, **kill, **in, **out; +static bittype **gen, **killed, **in, **out; + +#define MAXNSPILL 100 +static int notspill[MAXNSPILL], nspill; + +static int +innotspill(int n) +{ + int i; + for (i = 0; i < nspill; i++) + if (notspill[i] == n) + return 1; + return 0; +} + +/* + * Found an extended assembler node, so growel out gen/killed nodes. + */ +static void +xasmionize(NODE *p, void *arg) +{ + int bb = *(int *)arg; + int cw, b; + + if (p->n_op == ICON && p->n_type == STRTY) + return; /* dummy end marker */ + + cw = xasmcode(p->n_name); + if (XASMVAL(cw) == 'n' || XASMVAL(cw) == 'm') + return; /* no flow analysis */ + p = p->n_left; + + if (XASMVAL(cw) == 'g' && p->n_op != TEMP && p->n_op != REG) + return; /* no flow analysis */ + + b = regno(p); + if (XASMVAL(cw) == 'r' && p->n_op == TEMP) { + if (!innotspill(b)) { + if (nspill < MAXNSPILL) + notspill[nspill++] = b; + else + werror("MAXNSPILL overbooked"); + } + } + if (XASMISOUT(cw)) { + if (p->n_op == TEMP) { + b -= tempmin+MAXREGS; + BITCLEAR(gen[bb], b); + BITSET(killed[bb], b); + } else if (p->n_op == REG) { + BITCLEAR(gen[bb], b); + BITSET(killed[bb], b); + } else + uerror("bad xasm node type"); + } + if (XASMISINP(cw)) { + if (p->n_op == TEMP) { + BITSET(gen[bb], (b - tempmin+MAXREGS)); + } else if (p->n_op == REG) { + BITSET(gen[bb], b); + } else if (optype(p->n_op) != LTYPE) { + if (XASMVAL(cw) == 'r') + uerror("couldn't find available register"); + else + uerror("bad xasm node type2"); + } + } +} + +#ifndef XASMCONSTREGS +#define XASMCONSTREGS(x) (-1) +#endif + +/* + * Check that given constraints are valid. + */ +static void +xasmconstr(NODE *p, void *arg) +{ + int i; + + if (p->n_op == ICON && p->n_type == STRTY) + return; /* no constraints */ + + if (strcmp(p->n_name, "cc") == 0 || strcmp(p->n_name, "memory") == 0) + return; + + for (i = 0; i < MAXREGS; i++) + if (strcmp(rnames[i], p->n_name) == 0) { + addalledges(&ablock[i]); + return; + } + if ((i = XASMCONSTREGS(p->n_name)) < 0) + comperr("unsupported xasm constraint %s", p->n_name); + addalledges(&ablock[i]); +} + +#define RUP(x) (((x)+NUMBITS-1)/NUMBITS) +#define SETCOPY(t,f,i,n) for (i = 0; i < RUP(n); i++) t[i] = f[i] +#define SETSET(t,f,i,n) for (i = 0; i < RUP(n); i++) t[i] |= f[i] +#define SETCLEAR(t,f,i,n) for (i = 0; i < RUP(n); i++) t[i] &= ~f[i] +#define SETCMP(v,t,f,i,n) for (i = 0; i < RUP(n); i++) \ + if (t[i] != f[i]) v = 1 +#define SETEMPTY(t,sz) memset(t, 0, BIT2BYTE(sz)) + +static int +deldead(NODE *p, bittype *lvar) +{ + NODE *q; + int ty, rv = 0; + +#define BNO(p) (regno(p) - tempmin+MAXREGS) + if (p->n_op == TEMP) + BITSET(lvar, BNO(p)); + if (asgop(p->n_op) && p->n_left->n_op == TEMP && + TESTBIT(lvar, BNO(p->n_left)) == 0) { + /* + * Not live, must delete the right tree at least + * down to next statement with side effects. + */ + BDEBUG(("DCE deleting temp %d\n", regno(p->n_left))); + nfree(p->n_left); + q = p->n_right; + *p = *q; + nfree(q); + rv = 1; + } + ty = optype(p->n_op); + if (ty != LTYPE) + rv |= deldead(p->n_left, lvar); + if (ty == BITYPE) + rv |= deldead(p->n_right, lvar); + return rv; +} + +/* + * Do dead code elimination. + */ +static int +dce(struct p2env *p2e) +{ + extern struct interpass prepole; + struct basicblock *bb; + struct interpass *ip; + NODE *p; + bittype *lvar; + int i, bbnum, fix = 0; + + BDEBUG(("Entering DCE\n")); + /* + * Traverse over the basic blocks. + * if an assignment is found that writes to a temporary + * that is not live out, remove that assignment and its legs. + */ + DLIST_INIT(&prepole, qelem); + BITALLOC(lvar, alloca, xbits); + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { + bbnum = bb->bbnum; + BDEBUG(("DCE bblock %d, start %p last %p\n", + bbnum, bb->first, bb->last)); + SETCOPY(lvar, out[bbnum], i, xbits); + for (ip = bb->last; ; ip = DLIST_PREV(ip, qelem)) { + if (ip->type == IP_NODE && deldead(ip->ip_node, lvar)) { + if ((p = deluseless(ip->ip_node)) == NULL) { +#ifdef notyet + if (ip == bb->last) { + bb->last = + DLIST_PREV(ip, qelem); + } else if (ip == bb->first) { + bb->first = + DLIST_NEXT(ip, qelem); + } + DLIST_REMOVE(ip, qelem); +#else + ip->type = IP_ASM; + ip->ip_asm = ""; +#endif + fix++; + BDEBUG(("DCE ip %p deleted\n", ip)); + } else while (!DLIST_ISEMPTY(&prepole, qelem)) { + BDEBUG(("DCE doing ip prepend\n")); +#ifdef notyet + struct interpass *tipp; + tipp = DLIST_NEXT(&prepole, qelem); + DLIST_REMOVE(tipp, qelem); + DLIST_INSERT_BEFORE(ip, tipp, qelem); + if (ip == bb->first) + bb->first = tipp; + fix++; +#else + comperr("dce needs bb fixup"); +#endif + BDEBUG(("DCE ip prepended\n")); + } + if (ip->type == IP_NODE) { + geninsn(p, FOREFF); + nsucomp(p); + ip->ip_node = p; + } + } + if (ip == bb->first) + break; + } + } + BDEBUG(("DCE fix %d\n", fix)); + return fix; +} + +/* + * Set/clear long term liveness for regs and temps. + */ static void unionize(NODE *p, int bb) { @@ -1013,27 +1367,37 @@ if ((o = p->n_op) == TEMP) { #ifdef notyet for (i = 0; i < szty(p->n_type); i++) { - BITSET(gen[bb], ((int)p->n_lval - tempmin+i)); + BITSET(gen[bb], (regno(p) - tempmin+i+MAXREGS)); } #else i = 0; - BITSET(gen[bb], ((int)p->n_lval - tempmin+i)); + BITSET(gen[bb], (regno(p) - tempmin+i+MAXREGS)); #endif + } else if (VALIDREG(p)) { + BITSET(gen[bb], regno(p)); } - if (asgop(o) && p->n_left->n_op == TEMP) { - int b = p->n_left->n_lval - tempmin; + if (asgop(o)) { + if (p->n_left->n_op == TEMP) { + int b = regno(p->n_left) - tempmin+MAXREGS; #ifdef notyet - for (i = 0; i < szty(p->n_type); i++) { - BITCLEAR(gen[bb], (b+i)); - BITSET(kill[bb], (b+i)); - } + for (i = 0; i < szty(p->n_type); i++) { + BITCLEAR(gen[bb], (b+i)); + BITSET(killed[bb], (b+i)); + } #else - i = 0; - BITCLEAR(gen[bb], (b+i)); - BITSET(kill[bb], (b+i)); + i = 0; + BITCLEAR(gen[bb], (b+i)); + BITSET(killed[bb], (b+i)); #endif - unionize(p->n_right, bb); - return; + unionize(p->n_right, bb); + return; + } else if (VALIDREG(p->n_left)) { + int b = regno(p->n_left); + BITCLEAR(gen[bb], b); + BITSET(killed[bb], b); + unionize(p->n_right, bb); + return; + } } ty = optype(o); if (ty != LTYPE) @@ -1049,62 +1413,60 @@ * when doing short-range liveness analysis in Build(). */ static void -LivenessAnalysis(void) +LivenessAnalysis(struct p2env *p2e) { - extern struct basicblock bblocks; struct basicblock *bb; struct interpass *ip; int i, bbnum; /* - * generate the gen-kill sets for all basic blocks. + * generate the gen-killed sets for all basic blocks. */ - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { bbnum = bb->bbnum; for (ip = bb->last; ; ip = DLIST_PREV(ip, qelem)) { - /* gen/kill is 'p', this node is 'n' */ - if (ip->type == IP_NODE) - unionize(ip->ip_node, bbnum); + /* gen/killed is 'p', this node is 'n' */ + if (ip->type == IP_NODE) { + if (ip->ip_node->n_op == XASM) + flist(ip->ip_node->n_left, + xasmionize, &bbnum); + else + unionize(ip->ip_node, bbnum); + } if (ip == bb->first) break; } - memcpy(in[bbnum], gen[bbnum], BIT2BYTE(tempmax-tempmin)); + memcpy(in[bbnum], gen[bbnum], BIT2BYTE(xbits)); #ifdef PCC_DEBUG +#define PRTRG(x) printf("%d ", i < MAXREGS ? i : i + tempmin-MAXREGS) if (rdebug) { printf("basic block %d\ngen: ", bbnum); - for (i = 0; i < tempmax-tempmin; i++) + for (i = 0; i < xbits; i++) if (TESTBIT(gen[bbnum], i)) - printf("%d ", i+tempmin); - printf("\nkill: "); - for (i = 0; i < tempmax-tempmin; i++) - if (TESTBIT(kill[bbnum], i)) - printf("%d ", i+tempmin); + PRTRG(i); + printf("\nkilled: "); + for (i = 0; i < xbits; i++) + if (TESTBIT(killed[bbnum], i)) + PRTRG(i); printf("\n"); } #endif } } -#define SETCOPY(t,f,i,n) for (i = 0; i < n/NUMBITS; i++) t[i] = f[i] -#define SETSET(t,f,i,n) for (i = 0; i < n/NUMBITS; i++) t[i] |= f[i] -#define SETCLEAR(t,f,i,n) for (i = 0; i < n/NUMBITS; i++) t[i] &= ~f[i] -#define SETCMP(v,t,f,i,n) for (i = 0; i < n/NUMBITS; i++) \ - if (t[i] != f[i]) v = 1 - /* * Build the set of interference edges and adjacency list. */ static void -Build(struct interpass *ipole) +Build(struct p2env *p2e) { - extern struct basicblock bblocks; + struct interpass *ipole = &p2e->ipole; struct basicblock bbfake; struct interpass *ip; struct basicblock *bb; struct cfgnode *cn; - extern int nbblocks; bittype *saved; - int i, j, again, nbits; + int i, j, again; if (xtemps == 0) { /* @@ -1112,35 +1474,37 @@ * so fake one basic block to keep the liveness analysis * happy. */ - nbblocks = 1; + p2e->nbblocks = 1; bbfake.bbnum = 0; bbfake.last = DLIST_PREV(ipole, qelem); bbfake.first = DLIST_NEXT(ipole, qelem); - DLIST_INIT(&bblocks, bbelem); - DLIST_INSERT_AFTER(&bblocks, &bbfake, bbelem); + DLIST_INIT(&p2e->bblocks, bbelem); + DLIST_INSERT_AFTER(&p2e->bblocks, &bbfake, bbelem); SLIST_INIT(&bbfake.children); } /* Just fetch space for the temporaries from stack */ - nbits = xbits+(NUMBITS-1); - gen = alloca(nbblocks*sizeof(bittype*)); - kill = alloca(nbblocks*sizeof(bittype*)); - in = alloca(nbblocks*sizeof(bittype*)); - out = alloca(nbblocks*sizeof(bittype*)); - for (i = 0; i < nbblocks; i++) { - BITALLOC(gen[i],alloca,nbits); - BITALLOC(kill[i],alloca,nbits); - BITALLOC(in[i],alloca,nbits); - BITALLOC(out[i],alloca,nbits); - } - BITALLOC(saved,alloca,nbits); - LivenessAnalysis(); + gen = alloca(p2e->nbblocks*sizeof(bittype*)); + killed = alloca(p2e->nbblocks*sizeof(bittype*)); + in = alloca(p2e->nbblocks*sizeof(bittype*)); + out = alloca(p2e->nbblocks*sizeof(bittype*)); + for (i = 0; i < p2e->nbblocks; i++) { + BITALLOC(gen[i],alloca,xbits); + BITALLOC(killed[i],alloca,xbits); + BITALLOC(in[i],alloca,xbits); + BITALLOC(out[i],alloca,xbits); + } + BITALLOC(saved,alloca,xbits); + + nspill = 0; +livagain: + LivenessAnalysis(p2e); /* register variable temporaries are live */ for (i = 0; i < NPERMREG-1; i++) { if (nsavregs[i]) continue; - BITSET(out[nbblocks-1], i); + BITSET(out[p2e->nbblocks-1], (i+MAXREGS)); for (j = i+1; j < NPERMREG-1; j++) { if (nsavregs[j]) continue; @@ -1152,47 +1516,73 @@ do { again = 0; /* XXX - loop should be in reversed execution-order */ - DLIST_FOREACH_REVERSE(bb, &bblocks, bbelem) { - int i = bb->bbnum; - SETCOPY(saved, out[i], j, nbits); + DLIST_FOREACH_REVERSE(bb, &p2e->bblocks, bbelem) { + i = bb->bbnum; + SETCOPY(saved, out[i], j, xbits); SLIST_FOREACH(cn, &bb->children, cfgelem) { - SETSET(out[i], in[cn->bblock->bbnum], - j, nbits); + SETSET(out[i], in[cn->bblock->bbnum], j, xbits); } - SETCMP(again, saved, out[i], j, nbits); - SETCOPY(saved, in[i], j, nbits); - SETCOPY(in[i], out[i], j, nbits); - SETCLEAR(in[i], kill[i], j, nbits); - SETSET(in[i], gen[i], j, nbits); - SETCMP(again, saved, in[i], j, nbits); + SETCMP(again, saved, out[i], j, xbits); + SETCOPY(saved, in[i], j, xbits); + SETCOPY(in[i], out[i], j, xbits); + SETCLEAR(in[i], killed[i], j, xbits); + SETSET(in[i], gen[i], j, xbits); + SETCMP(again, saved, in[i], j, xbits); } } while (again); #ifdef PCC_DEBUG if (rdebug) { - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { printf("basic block %d\nin: ", bb->bbnum); - for (i = 0; i < tempmax-tempmin; i++) + for (i = 0; i < xbits; i++) if (TESTBIT(in[bb->bbnum], i)) - printf("%d ", i+tempmin); + PRTRG(i); printf("\nout: "); - for (i = 0; i < tempmax-tempmin; i++) + for (i = 0; i < xbits; i++) if (TESTBIT(out[bb->bbnum], i)) - printf("%d ", i+tempmin); + PRTRG(i); printf("\n"); } } #endif + if (xtemps && xdce) { + /* + * Do dead code elimination by using live out. + * Ignores if any variable read from is marked volatile, + * but what it should do is unspecified anyway. + * Liveness Analysis should be done in optim2 instead. + * + * This should recalculate the basic block structure. + */ + if (dce(p2e)) { + /* Clear bitfields */ + for (i = 0; i < p2e->nbblocks; i++) { + SETEMPTY(gen[i],xbits); + SETEMPTY(killed[i],xbits); + SETEMPTY(in[i],xbits); + SETEMPTY(out[i],xbits); + } + SETEMPTY(saved,xbits); + goto livagain; + } + } - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { RDEBUG(("liveadd bb %d\n", bb->bbnum)); i = bb->bbnum; - for (j = 0; j < (tempmax-tempmin); j += NUMBITS) + for (j = 0; j < xbits; j += NUMBITS) live[j/NUMBITS] = 0; - SETCOPY(live, out[i], j, nbits); + SETCOPY(live, out[i], j, xbits); for (ip = bb->last; ; ip = DLIST_PREV(ip, qelem)) { - if (ip->type == IP_NODE) - insnwalk(ip->ip_node); + if (ip->type == IP_NODE) { + if (ip->ip_node->n_op == XASM) { + flist(ip->ip_node->n_right, + xasmconstr, 0); + listf(ip->ip_node->n_left, setxarg); + } else + insnwalk(ip->ip_node); + } if (ip == bb->first) break; } @@ -1200,14 +1590,13 @@ #ifdef PCC_DEBUG if (rdebug) { - int i; struct AdjSet *w; ADJL *x; REGW *y; MOVL *m; printf("Interference edges\n"); - for (i = 0; i < 256; i++) { + for (i = 0; i < HASHSZ; i++) { if ((w = edgehash[i]) == NULL) continue; for (; w; w = w->next) @@ -1217,14 +1606,16 @@ DLIST_FOREACH(y, &initial, link) { printf("%d (%c): trivial [%d] ", ASGNUM(y), CLASS(y)+'@', trivially_colorable(y)); + i = 0; for (x = ADJLIST(y); x; x = x->r_next) { if (ONLIST(x->a_temp) != &selectStack && ONLIST(x->a_temp) != &coalescedNodes) printf("%d ", ASGNUM(x->a_temp)); else printf("(%d) ", ASGNUM(x->a_temp)); + i++; } - printf("\n"); + printf(": n=%d\n", i); } printf("Move nodes\n"); DLIST_FOREACH(y, &initial, link) { @@ -1281,7 +1672,9 @@ { int wast; +#ifdef PCC_DEBUG RRDEBUG(("DecrementDegree: w %d, c %d\n", ASGNUM(w), c)); +#endif wast = trivially_colorable(w); NCLASS(w, c)--; @@ -1306,7 +1699,9 @@ w = POPWLIST(simplifyWorklist); PUSHWLIST(w, selectStack); +#ifdef PCC_DEBUG RDEBUG(("Simplify: node %d class %d\n", ASGNUM(w), w->r_class)); +#endif l = w->r_adjList; for (; l; l = l->r_next) { @@ -1328,10 +1723,10 @@ static int OK(REGW *t, REGW *r) { +#ifdef PCC_DEBUG RDEBUG(("OK: t %d CLASS(t) %d adjSet(%d,%d)=%d\n", ASGNUM(t), CLASS(t), ASGNUM(t), ASGNUM(r), adjSet(t, r))); -#ifdef PCC_DEBUG if (rdebug > 1) { ADJL *w; int ndeg = 0; @@ -1376,7 +1771,6 @@ return 1; } -#define oldcons /* check some more */ /* * Do a conservative estimation of whether two temporaries can * be coalesced. This is "Briggs-style" check. @@ -1387,41 +1781,8 @@ { ADJL *w, *ww; REGW *n; -#ifdef oldcons - int i, ncl[NUMCLASS+1]; - - if (CLASS(u) != CLASS(v)) - comperr("Conservative: u(%d = %d), v(%d = %d)", - ASGNUM(u), CLASS(u), ASGNUM(v), CLASS(v)); - - for (i = 0; i < NUMCLASS+1; i++) - ncl[i] = 0; - - RDEBUG(("Conservative (%d,%d)\n", ASGNUM(u), ASGNUM(v))); - - for (w = ADJLIST(u); w; w = w->r_next) { - n = w->a_temp; - if (ONLIST(n) == &selectStack || ONLIST(n) == &coalescedNodes) - continue; - for (ww = ADJLIST(v); ww; ww = ww->r_next) - if (ww->a_temp == n) - break; - if (ww) - continue; - if (!trivially_colorable(n)) - ncl[CLASS(n)]++; - } - for (w = ADJLIST(v); w; w = w->r_next) { - n = w->a_temp; - if (ONLIST(n) == &selectStack || ONLIST(n) == &coalescedNodes) - continue; - if (!trivially_colorable(n)) - ncl[CLASS(n)]++; - } - i = trivially_colorable_p(CLASS(u), ncl); -#endif -{ int xncl[NUMCLASS+1], mcl = 0, j; + for (j = 0; j < NUMCLASS+1; j++) xncl[j] = 0; /* @@ -1461,17 +1822,7 @@ break; } out: j = trivially_colorable_p(CLASS(u), xncl); -#ifdef oldcons - if (j != i) - comperr("Conservative: j %d i %d", j, i); -#else return j; -#endif -} -#ifdef oldcons - RDEBUG(("Conservative i=%d\n", i)); - return i; -#endif } static void @@ -1492,7 +1843,9 @@ ADJL *l; REGW *t; +#ifdef PCC_DEBUG RDEBUG(("Combine (%d,%d)\n", ASGNUM(u), ASGNUM(v))); +#endif if (ONLIST(v) == &freezeWorklist) { DELWLIST(v); @@ -1501,12 +1854,14 @@ } PUSHWLIST(v, coalescedNodes); ALIAS(v) = u; +#ifdef PCC_DEBUG if (rdebug) { printf("adjlist(%d): ", ASGNUM(v)); for (l = ADJLIST(v); l; l = l->r_next) printf("%d ", l->a_temp->nodnum); printf("\n"); } +#endif #if 1 { MOVL *m0 = MOVELIST(v); @@ -1544,6 +1899,7 @@ DELWLIST(u); PUSHWLIST(u, spillWorklist); } +#ifdef PCC_DEBUG if (rdebug) { ADJL *w; printf("Combine %d class (%d): ", ASGNUM(u), CLASS(u)); @@ -1556,6 +1912,7 @@ } printf("\n"); } +#endif } static void @@ -1573,9 +1930,11 @@ else u = x, v = y; +#ifdef PCC_DEBUG RDEBUG(("Coalesce: src %d dst %d u %d v %d x %d y %d\n", ASGNUM(m->src), ASGNUM(m->dst), ASGNUM(u), ASGNUM(v), ASGNUM(x), ASGNUM(y))); +#endif if (CLASS(m->src) != CLASS(m->dst)) comperr("Coalesce: src class %d, dst class %d", @@ -1620,8 +1979,10 @@ v = GetAlias(x); else v = GetAlias(y); +#ifdef PCC_DEBUG RDEBUG(("FreezeMoves: u %d (%d,%d) v %d\n", ASGNUM(u),ASGNUM(x),ASGNUM(y),ASGNUM(v))); +#endif DLIST_REMOVE(m, link); PUSHMLIST(m, frozenMoves, FROZEN); if (ONLIST(v) != &freezeWorklist) @@ -1649,7 +2010,9 @@ */ u = POPWLIST(freezeWorklist); PUSHWLIST(u, simplifyWorklist); +#ifdef PCC_DEBUG RDEBUG(("Freeze %d\n", ASGNUM(u))); +#endif FreezeMoves(u); } @@ -1659,9 +2022,11 @@ REGW *w; RDEBUG(("SelectSpill\n")); +#ifdef PCC_DEBUG if (rdebug) DLIST_FOREACH(w, &spillWorklist, link) printf("SelectSpill: %d\n", ASGNUM(w)); +#endif /* First check if we can spill register variables */ DLIST_FOREACH(w, &spillWorklist, link) { @@ -1672,6 +2037,8 @@ if (w == &spillWorklist) { /* try to find another long-range variable */ DLIST_FOREACH(w, &spillWorklist, link) { + if (innotspill(w - nblock)) + continue; if (w >= &nblock[tempmin] && w < &nblock[tempmax]) break; } @@ -1695,41 +2062,42 @@ DLIST_REMOVE(w, link); PUSHWLIST(w, simplifyWorklist); +#ifdef PCC_DEBUG RDEBUG(("Freezing node %d\n", ASGNUM(w))); +#endif FreezeMoves(w); } -int gregn(REGW *); - -int -gregn(REGW *w) -{ - return w->nodnum; -} - /* * Set class on long-lived temporaries based on its type. */ static void -traclass(NODE *p) +traclass(NODE *p, void *arg) { REGW *nb; if (p->n_op != TEMP) return; - nb = &nblock[(int)p->n_lval]; + nb = &nblock[regno(p)]; if (CLASS(nb) == 0) CLASS(nb) = gclass(p->n_type); } static void -paint(NODE *p) +paint(NODE *p, void *arg) { struct optab *q; REGW *w, *ww; int i; +#ifdef notyet + /* XXX - trashes rewrite of trees (short) */ + if (!DLIST_ISEMPTY(&spilledNodes, link)) { + p->n_reg = 0; + return; + } +#endif if (p->n_regw != NULL) { /* Must color all allocated regs also */ ww = w = p->n_regw; @@ -1747,8 +2115,8 @@ } else p->n_reg = -1; if (p->n_op == TEMP) { - REGW *nb = &nblock[(int)p->n_lval]; - p->n_rval = COLOR(nb); + REGW *nb = &nblock[regno(p)]; + regno(p) = COLOR(nb); if (TCLASS(p->n_su) == 0) SCLASS(p->n_su, CLASS(nb)); p->n_op = REG; @@ -1759,6 +2127,7 @@ static void AssignColors(struct interpass *ip) { + struct interpass *ip2; int okColors, c; REGW *o, *w; ADJL *x; @@ -1767,13 +2136,17 @@ while (!WLISTEMPTY(selectStack)) { w = POPWLIST(selectStack); okColors = classmask(CLASS(w)); +#ifdef PCC_DEBUG RDEBUG(("classmask av %d, class %d: %x\n", w->nodnum, CLASS(w), okColors)); +#endif for (x = ADJLIST(w); x; x = x->r_next) { o = GetAlias(x->a_temp); +#ifdef PCC_DEBUG RRDEBUG(("Adj(%d): %d (%d)\n", ASGNUM(w), ASGNUM(o), ASGNUM(x->a_temp))); +#endif if (ONLIST(o) == &coloredNodes || ONLIST(o) == &precolored) { @@ -1787,37 +2160,47 @@ } if (okColors == 0) { PUSHWLIST(w, spilledNodes); +#ifdef PCC_DEBUG RDEBUG(("Spilling node %d\n", ASGNUM(w))); +#endif } else { PUSHWLIST(w, coloredNodes); c = ffs(okColors)-1; COLOR(w) = color2reg(c, CLASS(w)); +#ifdef PCC_DEBUG RDEBUG(("Coloring %d with %s, free %x\n", ASGNUM(w), rnames[COLOR(w)], okColors)); +#endif } } DLIST_FOREACH(w, &coalescedNodes, link) { REGW *ww = GetAlias(w); COLOR(w) = COLOR(ww); if (ONLIST(ww) == &spilledNodes) { +#ifdef PCC_DEBUG RDEBUG(("coalesced node %d spilled\n", w->nodnum)); +#endif ww = DLIST_PREV(w, link); DLIST_REMOVE(w, link); PUSHWLIST(w, spilledNodes); w = ww; - } else + } else { +#ifdef PCC_DEBUG RDEBUG(("Giving coalesced node %d color %s\n", w->nodnum, rnames[COLOR(w)])); +#endif + } } +#ifdef PCC_DEBUG if (rdebug) DLIST_FOREACH(w, &coloredNodes, link) printf("%d: color %s\n", ASGNUM(w), rnames[COLOR(w)]); +#endif if (DLIST_ISEMPTY(&spilledNodes, link)) { - struct interpass *ip2; DLIST_FOREACH(ip2, ip, qelem) if (ip2->type == IP_NODE) - walkf(ip2->ip_node, paint); + walkf(ip2->ip_node, paint, 0); } } @@ -1827,23 +2210,25 @@ * Will never end up here if not optimizing. */ static void -longtemp(NODE *p) +longtemp(NODE *p, void *arg) { + NODE *l, *r; REGW *w; if (p->n_op != TEMP) return; /* XXX - should have a bitmask to find temps to convert */ DLIST_FOREACH(w, spole, link) { - if (w != &nblock[(int)p->n_lval]) + if (w != &nblock[regno(p)]) continue; if (w->r_class == 0) { w->r_color = BITOOR(freetemp(szty(p->n_type))); w->r_class = 1; } - p->n_op = OREG; - p->n_lval = w->r_color; - p->n_rval = FPREG; + l = mklnode(REG, 0, FPREG, INCREF(p->n_type)); + r = mklnode(ICON, w->r_color, 0, INT); + p->n_left = mkbinode(PLUS, l, r, INCREF(p->n_type)); + p->n_op = UMUL; p->n_regw = NULL; break; } @@ -1855,7 +2240,7 @@ * XXX - must check if basic block structure is destroyed! */ static void -shorttemp(NODE *p) +shorttemp(NODE *p, void *arg) { struct interpass *nip; struct optab *q; @@ -1870,10 +2255,14 @@ /* XXX - use canaddr() */ if (p->n_op == OREG || p->n_op == NAME) { DLIST_REMOVE(w, link); +#ifdef PCC_DEBUG RDEBUG(("Node %d already in memory\n", ASGNUM(w))); +#endif break; } +#ifdef PCC_DEBUG RDEBUG(("rewriting node %d\n", ASGNUM(w))); +#endif off = BITOOR(freetemp(szty(p->n_type))); l = mklnode(OREG, off, FPREG, p->n_type); @@ -1923,7 +2312,7 @@ if (ip->type != IP_NODE) continue; cip = ip; - walkf(ip->ip_node, shorttemp); /* convert temps to oregs */ + walkf(ip->ip_node, shorttemp, 0); /* convert temps to oregs */ } if (!DLIST_ISEMPTY(spole, link)) comperr("treerewrite not empty"); @@ -1945,7 +2334,7 @@ continue; nodepole = ip->ip_node; thisline = ip->lineno; - walkf(ip->ip_node, longtemp); /* convert temps to oregs */ + walkf(ip->ip_node, longtemp, 0); /* convert temps to oregs */ } nodepole = NIL; } @@ -1960,19 +2349,21 @@ NODE *p; ip = DLIST_NEXT(ipole, qelem); /* PROLOG */ - ip = DLIST_NEXT(ip, qelem); /* first DEFLAB */ + while (ip->type != IP_DEFLAB) + ip = DLIST_NEXT(ip, qelem); ip = DLIST_NEXT(ip, qelem); /* first NODE */ for (; ip->type != IP_DEFLAB; ip = DLIST_NEXT(ip, qelem)) { if (ip->type == IP_ASM) continue; p = ip->ip_node; -#ifdef PCC_DEBUG +#ifdef notdef + /* register args may already have been put on stack */ if (p->n_op != ASSIGN || p->n_left->n_op != TEMP) comperr("temparg"); #endif if (p->n_right->n_op != OREG) continue; /* arg in register */ - if (w != &nblock[(int)p->n_left->n_lval]) + if (w != &nblock[regno(p->n_left)]) continue; w->r_color = p->n_right->n_lval; tfree(p); @@ -2068,6 +2459,33 @@ return rwtyp; } +#ifdef PCC_DEBUG +/* + * Print TEMP/REG contents in a node. + */ +void +prtreg(FILE *fp, NODE *p) +{ + int i, n = p->n_su == -1 ? 0 : ncnt(table[TBLIDX(p->n_su)].needs); +if (p->n_reg == -1) goto foo; + if (use_regw || p->n_reg > 0x40000000 || p->n_reg < 0) { + fprintf(fp, "TEMP "); + if (p->n_regw != NULL) { + for (i = 0; i < n+1; i++) + fprintf(fp, "%d ", p->n_regw[i].nodnum); + } else + fprintf(fp, ""); + } else { +foo: fprintf(fp, "REG "); + if (p->n_reg != -1) { + for (i = 0; i < n+1; i++) + fprintf(fp, "%s ", rnames[DECRA(p->n_reg, i)]); + } else + fprintf(fp, ""); + } +} +#endif + #ifdef notyet /* * Assign instructions, calculate evaluation order and @@ -2087,15 +2505,16 @@ * Do register allocation for trees by graph-coloring. */ void -ngenregs(struct interpass *ipole) +ngenregs(struct p2env *p2e) { + struct interpass *ipole = &p2e->ipole; extern NODE *nodepole; - struct interpass_prolog *ipp, *epp; struct interpass *ip; - int i, j, nbits = 0; + int i, j, tbits; int uu[NPERMREG] = { -1 }; int xnsavregs[NPERMREG]; int beenhere = 0; + TWORD type; DLIST_INIT(&lunused, link); DLIST_INIT(&lused, link); @@ -2103,11 +2522,8 @@ /* * Do some setup before doing the real thing. */ - ipp = (struct interpass_prolog *)DLIST_NEXT(ipole, qelem); - epp = (struct interpass_prolog *)DLIST_PREV(ipole, qelem); - - tempmin = ipp->ip_tmpnum; - tempmax = epp->ip_tmpnum; + tempmin = p2e->ipp->ip_tmpnum; + tempmax = p2e->epp->ip_tmpnum; /* * Allocate space for the permanent registers in the @@ -2130,16 +2546,16 @@ #ifdef PCC_DEBUG nodnum = tempmax; #endif - nbits = xbits = tempmax - tempmin; - if (nbits) { - nblock = tmpalloc(nbits * sizeof(REGW)); + tbits = tempmax - tempmin; /* # of temporaries */ + xbits = tbits + MAXREGS; /* total size of live array */ + if (tbits) { + nblock = tmpalloc(tbits * sizeof(REGW)); nblock -= tempmin; - live = tmpalloc(BIT2BYTE(nbits)); - RDEBUG(("nblock %p num %d size %zd\n", - nblock, nbits, (int)(nbits * sizeof(REGW)))); + RDEBUG(("nblock %p num %d size %zu\n", + nblock, tbits, (size_t)(tbits * sizeof(REGW)))); } - + live = tmpalloc(BIT2BYTE(xbits)); /* Block for precolored nodes */ ablock = tmpalloc(sizeof(REGW)*MAXREGS); @@ -2159,16 +2575,16 @@ recalc: onlyperm: /* XXX - should not have to redo all */ + memset(edgehash, 0, sizeof(edgehash)); - if (nbits) { - memset(nblock+tempmin, 0, nbits * sizeof(REGW)); - memset(live, 0, BIT2BYTE(nbits)); - memset(edgehash, 0, sizeof(edgehash)); + if (tbits) { + memset(nblock+tempmin, 0, tbits * sizeof(REGW)); #ifdef PCC_DEBUG for (i = tempmin; i < tempmax; i++) nblock[i].nodnum = i; #endif } + memset(live, 0, BIT2BYTE(xbits)); RPRINTIP(ipole); DLIST_INIT(&initial, link); DLIST_FOREACH(ip, ipole, qelem) { @@ -2177,15 +2593,20 @@ continue; nodepole = ip->ip_node; thisline = ip->lineno; - geninsn(ip->ip_node, FOREFF); + if (ip->ip_node->n_op != XASM) + geninsn(ip->ip_node, FOREFF); nsucomp(ip->ip_node); - walkf(ip->ip_node, traclass); + walkf(ip->ip_node, traclass, 0); } nodepole = NIL; RDEBUG(("nsucomp allocated %d temps (%d,%d)\n", tempmax-tempmin, tempmin, tempmax)); +#ifdef PCC_DEBUG + use_regw = 1; RPRINTIP(ipole); + use_regw = 0; +#endif RDEBUG(("ngenregs: numtemps %d (%d, %d)\n", tempmax-tempmin, tempmin, tempmax)); @@ -2205,7 +2626,7 @@ addalledges(&nblock[i+tempmin]); } - Build(ipole); + Build(p2e); RDEBUG(("Build done\n")); MkWorklist(); RDEBUG(("MkWorklist done\n")); @@ -2230,20 +2651,20 @@ case ONLYPERM: goto onlyperm; case SMALL: - optimize(ipole); + optimize(p2e); if (beenhere++ == MAXLOOP) - comperr("beenhere"); + comperr("cannot color graph - COLORMAP() bug?"); goto recalc; } } - /* fill in regs to save */ - ipp->ipp_regs = 0; + /* fill in regs to save */ + memset(p2e->ipp->ipp_regs, 0, sizeof(p2e->ipp->ipp_regs)); for (i = 0; i < NPERMREG-1; i++) { NODE *p; if (nsavregs[i]) { - ipp->ipp_regs |= (1 << permregs[i]); + BITSET(p2e->ipp->ipp_regs, permregs[i]); continue; /* Spilled */ } if (nblock[i+tempmin].r_color == permregs[i]) @@ -2251,7 +2672,7 @@ /* * If the original color of this permreg is used for * coloring another register, swap them to avoid - * unneccessary moves. + * unnecessary moves. */ for (j = i+1; j < NPERMREG-1; j++) { if (nblock[j+tempmin].r_color != permregs[i]) @@ -2263,23 +2684,27 @@ continue; /* Generate reg-reg move nodes for save */ + type = PERMTYPE(permregs[i]); +#ifdef PCC_DEBUG + if (PERMTYPE(nblock[i+tempmin].r_color) != type) + comperr("permreg botch"); +#endif p = mkbinode(ASSIGN, - mklnode(REG, 0, nblock[i+tempmin].r_color, INT), - mklnode(REG, 0, permregs[i], INT), INT); + mklnode(REG, 0, nblock[i+tempmin].r_color, type), + mklnode(REG, 0, permregs[i], type), type); p->n_reg = p->n_left->n_reg = p->n_right->n_reg = -1; p->n_left->n_su = p->n_right->n_su = 0; geninsn(p, FOREFF); ip = ipnode(p); DLIST_INSERT_AFTER(ipole->qelem.q_forw, ip, qelem); - /* XXX not int */ - p = mkbinode(ASSIGN, mklnode(REG, 0, permregs[i], INT), - mklnode(REG, 0, nblock[i+tempmin].r_color, INT), INT); + p = mkbinode(ASSIGN, mklnode(REG, 0, permregs[i], type), + mklnode(REG, 0, nblock[i+tempmin].r_color, type), type); p->n_reg = p->n_left->n_reg = p->n_right->n_reg = -1; p->n_left->n_su = p->n_right->n_su = 0; geninsn(p, FOREFF); ip = ipnode(p); DLIST_INSERT_BEFORE(ipole->qelem.q_back, ip, qelem); } - epp->ipp_regs = ipp->ipp_regs; - /* Done! */ + memcpy(p2e->epp->ipp_regs, p2e->ipp->ipp_regs, sizeof(p2e->epp->ipp_regs)); + /* Done! */ } Index: common.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/common.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/common.c -L usr.bin/pcc/mip/common.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/common.c +++ usr.bin/pcc/mip/common.c @@ -1,4 +1,4 @@ -/* $Id: common.c,v 1.73 2007/09/22 17:15:00 ragge Exp $ */ +/* $Id: common.c,v 1.87 2008/12/03 07:10:04 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -11,8 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. The name of the author may not be used to endorse or promote products - * derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES @@ -75,10 +73,19 @@ char *ftitle; int lineno; +int warniserr = 0; + #ifndef WHERE #define WHERE(ch) fprintf(stderr, "%s, line %d: ", ftitle, lineno); #endif +static void +incerr(void) +{ + if (++nerrors > 30) + cerror("too many errors"); +} + /* * nonfatal error message * the routine where is different for pass 1 and pass 2; @@ -90,13 +97,11 @@ va_list ap; va_start(ap, s); - ++nerrors; WHERE('u'); vfprintf(stderr, s, ap); fprintf(stderr, "\n"); - if (nerrors > 30) - cerror("too many errors"); va_end(ap); + incerr(); } /* @@ -137,22 +142,22 @@ vfprintf(stderr, s, ap); fprintf(stderr, "\n"); va_end(ap); + if (warniserr) + incerr(); } #ifndef MKEXT static NODE *freelink; static int usednodes; +#ifndef LANG_F77 NODE * talloc() { - extern int inlnodecnt, recovernodes; register NODE *p; usednodes++; - if (recovernodes) - inlnodecnt++; if (freelink != NULL) { p = freelink; freelink = p->next; @@ -169,6 +174,7 @@ printf("alloc node %p from memory\n", p); return p; } +#endif /* * make a fresh copy of p @@ -191,7 +197,7 @@ return(q); } - +#ifndef LANG_F77 /* * ensure that all nodes have been freed */ @@ -206,6 +212,7 @@ if ((usednodes - inlnodecnt) != 0) cerror("usednodes == %d, inlnodecnt %d", usednodes, inlnodecnt); } +#endif /* * free the tree p @@ -214,7 +221,7 @@ tfree(NODE *p) { if (p->n_op != FREE) - walkf(p, (void (*)(NODE *))nfree); + walkf(p, (void (*)(NODE *, void *))nfree, 0); } /* @@ -224,7 +231,6 @@ NODE * nfree(NODE *p) { - extern int inlnodecnt, recovernodes; NODE *l; #ifdef PCC_DEBUG_NODES NODE *q; @@ -251,12 +257,16 @@ p->next = freelink; freelink = p; usednodes--; - if (recovernodes) - inlnodecnt--; return l; } #endif +#ifdef LANG_F77 +#define OPTYPE(x) optype(x) +#else +#define OPTYPE(x) coptype(x) +#endif + #ifdef MKEXT #define coptype(o) (dope[o]&TYFLG) #else @@ -275,7 +285,7 @@ (*f)(t, down, &down1, &down2); - switch (coptype( t->n_op )) { + switch (OPTYPE( t->n_op )) { case BITYPE: fwalk( t->n_left, f, down1 ); @@ -292,17 +302,18 @@ } void -walkf(NODE *t, void (*f)(NODE *)) +walkf(NODE *t, void (*f)(NODE *, void *), void *arg) { int opty; - opty = coptype(t->n_op); + + opty = OPTYPE(t->n_op); if (opty != LTYPE) - walkf( t->n_left, f ); + walkf( t->n_left, f, arg ); if (opty == BITYPE) - walkf( t->n_right, f ); - (*f)(t); + walkf( t->n_right, f, arg ); + (*f)(t, arg); } int dope[DSIZE]; @@ -317,7 +328,6 @@ { REG, "REG", LTYPE, }, { OREG, "OREG", LTYPE, }, { TEMP, "TEMP", LTYPE, }, - { MOVE, "MOVE", UTYPE, }, { ICON, "ICON", LTYPE, }, { FCON, "FCON", LTYPE, }, { CCODES, "CCODES", LTYPE, }, @@ -328,7 +338,8 @@ { UFORTCALL, "UFCALL", UTYPE|CALLFLG, }, { COMPL, "~", UTYPE, }, { FORCE, "FORCE", UTYPE, }, -/* { INIT, "INIT", UTYPE, }, */ + { XARG, "XARG", UTYPE, }, + { XASM, "XASM", BITYPE, }, { SCONV, "SCONV", UTYPE, }, { PCONV, "PCONV", UTYPE, }, { PLUS, "+", BITYPE|FLOFLG|SIMPFLG|COMMFLG, }, @@ -411,6 +422,9 @@ "void", "signed", /* pass1 */ "bool", /* pass1 */ + "fcomplex", /* pass1 */ + "dcomplex", /* pass1 */ + "lcomplex", /* pass1 */ "?", "?" }; @@ -434,16 +448,6 @@ } } -int crslab = 10; -/* - * Return a number for internal labels. - */ -int -getlab() -{ - return crslab++; -} - /* * Memory allocation routines. * Memory are allocated from the system in MEMCHUNKSZ blocks. @@ -453,7 +457,7 @@ */ #define MEMCHUNKSZ 8192 /* 8k per allocation */ -struct b { +struct balloc { char a1; union { long long l; @@ -461,13 +465,11 @@ } a2; }; -#define ALIGNMENT ((long)&((struct b *)0)->a2) +#define ALIGNMENT ((long)&((struct balloc *)0)->a2) #define ROUNDUP(x) (((x) + ((ALIGNMENT)-1)) & ~((ALIGNMENT)-1)) static char *allocpole; static int allocleft; -static char *tmppole; -static int tmpleft; int permallocsize, tmpallocsize, lostmem; void * @@ -475,29 +477,27 @@ { void *rv; -//printf("permalloc: allocpole %p allocleft %d size %d ", allocpole, allocleft, size); - if (size > MEMCHUNKSZ) - cerror("permalloc"); + if (size > MEMCHUNKSZ) { + if ((rv = malloc(size)) == NULL) + cerror("permalloc: missing %d bytes", size); + return rv; + } if (size <= 0) cerror("permalloc2"); if (allocleft < size) { /* looses unused bytes */ lostmem += allocleft; -//fprintf(stderr, "allocating perm\n"); if ((allocpole = malloc(MEMCHUNKSZ)) == NULL) cerror("permalloc: out of memory"); allocleft = MEMCHUNKSZ; } size = ROUNDUP(size); rv = &allocpole[MEMCHUNKSZ-allocleft]; -//printf("rv %p\n", rv); allocleft -= size; permallocsize += size; return rv; } -static char *tmplink; - void * tmpcalloc(int size) { @@ -508,66 +508,96 @@ return rv; } -#define TMPOLE &tmppole[MEMCHUNKSZ-tmpleft] +/* + * Duplicate a string onto the temporary heap. + */ +char * +tmpstrdup(char *str) +{ + int len; + + len = strlen(str) + 1; + return memcpy(tmpalloc(len), str, len); +} + +/* + * Allocation routines for temporary memory. + */ +#if 0 +#define ALLDEBUG(x) printf x +#else +#define ALLDEBUG(x) +#endif + +#define NELEM ((MEMCHUNKSZ-ROUNDUP(sizeof(struct xalloc *)))/ALIGNMENT) +#define ELEMSZ (ALIGNMENT) +#define MAXSZ (NELEM*ELEMSZ) +struct xalloc { + struct xalloc *next; + union { + struct balloc b; /* for initial alignment */ + char elm[MAXSZ]; + } u; +} *tapole, *tmpole; +int uselem = NELEM; /* next unused element */ + void * tmpalloc(int size) { + struct xalloc *xp; void *rv; + size_t nelem; - if (size > MEMCHUNKSZ/2) { - size += ROUNDUP(sizeof(char *)); - if ((rv = malloc(size)) == NULL) - cerror("tmpalloc: out of memory"); - /* link in before current chunk XXX */ - *(char **)rv = *(char **)tmppole; - *(char **)tmppole = rv; - tmpallocsize += size; - return (char *)rv + ROUNDUP(sizeof(char *)); - } - if (size <= 0) - cerror("tmpalloc2"); -//printf("tmpalloc: tmppole %p tmpleft %d size %d ", tmppole, tmpleft, size); - size = ROUNDUP(size); - if (tmpleft < size) { - if ((tmppole = malloc(MEMCHUNKSZ)) == NULL) - cerror("tmpalloc: out of memory"); -//fprintf(stderr, "allocating tmp\n"); - tmpleft = MEMCHUNKSZ - ROUNDUP(sizeof(char *)); - *(char **)tmppole = tmplink; - tmplink = tmppole; - } - rv = TMPOLE; -//printf("rv %p\n", rv); - tmpleft -= size; - tmpallocsize += size; + nelem = ROUNDUP(size)/ELEMSZ; + ALLDEBUG(("tmpalloc(%ld,%ld) %d (%zd) ", ELEMSZ, NELEM, size, nelem)); + if (nelem > NELEM/2) { + xp = malloc(size + ROUNDUP(sizeof(struct xalloc *))); + if (xp == NULL) + cerror("out of memory"); + ALLDEBUG(("XMEM! (%ld,%p) ", + size + ROUNDUP(sizeof(struct xalloc *)), xp)); + xp->next = tmpole; + tmpole = xp; + ALLDEBUG(("rv %p\n", &xp->u.elm[0])); + return &xp->u.elm[0]; + } + if (nelem + uselem >= NELEM) { + ALLDEBUG(("MOREMEM! ")); + /* alloc more */ + if ((xp = malloc(sizeof(struct xalloc))) == NULL) + cerror("out of memory"); + xp->next = tapole; + tapole = xp; + uselem = 0; + } else + xp = tapole; + rv = &xp->u.elm[uselem * ELEMSZ]; + ALLDEBUG(("elemno %d ", uselem)); + uselem += nelem; + ALLDEBUG(("new %d rv %p\n", uselem, rv)); return rv; } -#if 0 -/* - * Print and pack strings on heap. - */ -char *tmpsprintf(char *fmt, ...); -char * -tmpsprintf(char *fmt, ...) +void +tmpfree() { - va_list ap; - int len; - char *tmp; + struct xalloc *x1; - tmp = TMPOLE; - va_start(ap, fmt); - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) { - (void)tmpalloc(tmpleft); /* ugly */ - tmp = TMPOLE; - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) - cerror("bad tmpsprintf len"); + while (tmpole) { + x1 = tmpole; + tmpole = tmpole->next; + ALLDEBUG(("XMEM! free %p\n", x1)); + free(x1); + } + while (tapole && tapole->next) { + x1 = tapole; + tapole = tapole->next; + ALLDEBUG(("MOREMEM! free %p\n", x1)); + free(x1); } - va_end(ap); - tmpleft += len; - return tmp; + if (tapole) + uselem = 0; } -#endif /* * Print and pack vararg string on heap. @@ -576,43 +606,58 @@ char * tmpvsprintf(char *fmt, va_list ap) { - int len; + int len, asz; char *tmp; - if (tmpleft == 0) + if (uselem == NELEM) (void)tmpalloc(1); /* XXX ugly */ - tmp = TMPOLE; - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) { - (void)tmpalloc(tmpleft+1); /* ugly */ - tmp = TMPOLE; - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) + tmp = &tapole->u.elm[uselem * ELEMSZ]; + asz = (NELEM-uselem) * ELEMSZ; +//printf("tmpvsprintf: uselem %d asz %d ", uselem, asz); + if ((len = vsnprintf(tmp, asz, fmt, ap)) >= asz) { + (void)tmpalloc(asz+1); /* ugly */ + tmp = &tapole->u.elm[uselem * ELEMSZ]; + asz = (NELEM-uselem) * ELEMSZ; +//printf("len %d uselem %d \n", len, uselem); + if ((len = vsnprintf(tmp, asz, fmt, ap)) >= asz) cerror("bad tmpsprintf len"); } - tmpleft -= len+1; +//else printf("\n"); + uselem += (ROUNDUP(len+1)/ELEMSZ); +//printf("len %d asz %d strlen(tmp) %ld\n", len, asz, strlen(tmp)); return tmp; } +/* + * Set a mark for later removal from the temp heap. + */ void -tmpfree() +markset(struct mark *m) { - char *f, *of; + m->tmsav = tmpole; + m->tasav = tapole; + m->elem = uselem; +} - f = tmplink; - if (f == NULL) - return; - if (*(char **)f == NULL) { - tmpleft = MEMCHUNKSZ - ROUNDUP(sizeof(char *)); - return; +/* + * Remove everything on tmp heap from a mark. + */ +void +markfree(struct mark *m) +{ + struct xalloc *x1; + + while (tmpole != m->tmsav) { + x1 = tmpole; + tmpole = tmpole->next; + free(x1); } - while (f != NULL) { - of = f; - f = *(char **)f; - free(of); - } - tmplink = tmppole = NULL; - tmpleft = 0; -//fprintf(stderr, "freeing tmp\n"); - /* XXX - nothing right now */ + while (tapole != m->tasav) { + x1 = tapole; + tapole = tapole->next; + free(x1); + } + uselem = m->elem; } /* @@ -636,3 +681,48 @@ *c++ = *s++; return u; } + +/* + * Do a preorder walk of the CM list p and apply function f on each element. + */ +void +flist(NODE *p, void (*f)(NODE *, void *), void *arg) +{ + if (p->n_op == CM) { + (*f)(p->n_right, arg); + flist(p->n_left, f, arg); + } else + (*f)(p, arg); +} + +/* + * The same as flist but postorder. + */ +void +listf(NODE *p, void (*f)(NODE *)) +{ + if (p->n_op == CM) { + listf(p->n_left, f); + (*f)(p->n_right); + } else + (*f)(p); +} + +/* + * Get list argument number n from list, or NIL if out of list. + */ +NODE * +listarg(NODE *p, int n, int *cnt) +{ + NODE *r; + + if (p->n_op == CM) { + r = listarg(p->n_left, n, cnt); + if (n == ++(*cnt)) + r = p->n_right; + } else { + *cnt = 0; + r = n == 0 ? p : NIL; + } + return r; +} Index: compat.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/compat.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/compat.c -L usr.bin/pcc/mip/compat.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/compat.c +++ usr.bin/pcc/mip/compat.c @@ -24,12 +24,83 @@ * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: compat.c,v 1.1 2007/09/20 12:52:15 ragge Exp $ + * $Id: compat.c,v 1.8 2008/11/01 08:29:38 mickey Exp $ + */ + +/*- + * Copyright (c) 1997, 2002 The NetBSD Foundation, Inc. + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Klaus Klein and Jason R. Thorpe. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the NetBSD + * Foundation, Inc. and its contributors. + * 4. Neither the name of The NetBSD Foundation nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + * $NetBSD: basename.c,v 1.5 2002/10/17 02:06:04 thorpej Exp $ + */ + +/* + * Copyright (c) 1987, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $NetBSD: gettemp.c,v 1.13 2003/12/05 00:57:36 uebayasi Exp $ */ #include +#include -#include "../config.h" +#include "config.h" +#define MKEXT /* XXX */ #include "manifest.h" #ifndef HAVE_STRLCAT @@ -102,3 +173,754 @@ return(s - src - 1); /* count does not include NUL */ } #endif + +#ifndef HAVE_GETOPT +char *optarg; +int optind = 1; +int +getopt(int argc, char **argv, char *args) +{ + int n; + int nlen = strlen(args); + char cmd; + char rv; + + if (argv[optind] && *argv[optind] == '-') { + cmd = *(argv[optind] + 1); + + for (n = 0; n < nlen; n++) { + if (args[n] == ':') + continue; + if (args[n] == cmd) { + rv = *(argv[optind] + 1); + if (args[n+1] == ':') { + if (*(argv[optind] + 2) != '\0') { + optarg = argv[optind] + 2; + optind += 1; + } else { + optarg = argv[optind + 1]; + optind += 2; + } + if (!optarg) + optarg=""; + return rv; + } else { + optarg = NULL; + optind += 1; + return rv; + } + } + } + } + + return -1; +} +#endif + +#ifdef WIN32 +#define ISPATHSEPARATOR(x) ((x == '/') || (x == '\\')) +#else +#define ISPATHSEPARATOR(x) (x == '/') +#endif + +#ifndef HAVE_BASENAME +#ifndef PATH_MAX +#define PATH_MAX 5000 +#endif + +char * +basename(char *path) +{ + static char singledot[] = "."; + static char result[PATH_MAX]; + char *p, *lastp; + size_t len; + + /* + * If `path' is a null pointer or points to an empty string, + * return a pointer to the string ".". + */ + if ((path == NULL) || (*path == '\0')) + return (singledot); + + /* Strip trailing slashes, if any. */ + lastp = path + strlen(path) - 1; + while (lastp != path && ISPATHSEPARATOR(*lastp)) + lastp--; + + /* Now find the beginning of this (final) component. */ + p = lastp; + while (p != path && !ISPATHSEPARATOR(*(p - 1))) + p--; + + /* ...and copy the result into the result buffer. */ + len = (lastp - p) + 1 /* last char */; + if (len > (PATH_MAX - 1)) + len = PATH_MAX - 1; + + memcpy(result, p, len); + result[len] = '\0'; + + return (result); +} +#endif + +#if !defined(HAVE_MKSTEMP) && !defined(WIN32) +int +mkstemp(char *path) +{ + char *start, *trv; + unsigned int pid; + + /* To guarantee multiple calls generate unique names even if + the file is not created. 676 different possibilities with 7 + or more X's, 26 with 6 or less. */ + static char xtra[2] = "aa"; + int xcnt = 0; + + pid = getpid(); + + /* Move to end of path and count trailing X's. */ + for (trv = path; *trv; ++trv) + if (*trv == 'X') + xcnt++; + else + xcnt = 0; + + /* Use at least one from xtra. Use 2 if more than 6 X's. */ + if (*(trv - 1) == 'X') + *--trv = xtra[0]; + if (xcnt > 6 && *(trv - 1) == 'X') + *--trv = xtra[1]; + + /* Set remaining X's to pid digits with 0's to the left. */ + while (*--trv == 'X') { + *trv = (pid % 10) + '0'; + pid /= 10; + } + + /* update xtra for next call. */ + if (xtra[0] != 'z') + xtra[0]++; + else { + xtra[0] = 'a'; + if (xtra[1] != 'z') + xtra[1]++; + else + xtra[1] = 'a'; + } + + return open(path, O_CREAT | O_EXCL | O_RDWR, 0600); +} +#endif + +#ifndef HAVE_FFS +int +ffs(int x) +{ + int r = 1; + if (!x) return 0; + if (!(x & 0xffff)) { x >>= 16; r += 16; } + if (!(x & 0xff)) { x >>= 8; r += 8; } + if (!(x & 0xf)) { x >>= 4; r += 4; } + if (!(x & 3)) { x >>= 2; r += 2; } + if (!(x & 1)) { x >>= 1; r += 1; } + + return r; +} +#endif + +/* + * Copyright Patrick Powell 1995 + * This code is based on code written by Patrick Powell (papowell at astart.com) + * It may be used for any purpose as long as this notice remains intact + * on all source code distributions + */ + +#if !defined(HAVE_SNPRINTF) || !defined(HAVE_VSNPRINTF) + +static void +dopr(char *buffer, size_t maxlen, const char *format, va_list args); + +static void +fmtstr(char *buffer, size_t *currlen, size_t maxlen, char *value, int flags, + int min, int max); + +static void +fmtint(char *buffer, size_t *currlen, size_t maxlen, long value, int base, + int min, int max, int flags); + +static void +fmtfp(char *buffer, size_t *currlen, size_t maxlen, long double fvalue, + int min, int max, int flags); + +static void +dopr_outch(char *buffer, size_t *currlen, size_t maxlen, char c); + +/* + * dopr(): poor man's version of doprintf + */ + +/* format read states */ +#define DP_S_DEFAULT 0 +#define DP_S_FLAGS 1 +#define DP_S_MIN 2 +#define DP_S_DOT 3 +#define DP_S_MAX 4 +#define DP_S_MOD 5 +#define DP_S_CONV 6 +#define DP_S_DONE 7 + +/* format flags - Bits */ +#define DP_F_MINUS (1 << 0) +#define DP_F_PLUS (1 << 1) +#define DP_F_SPACE (1 << 2) +#define DP_F_NUM (1 << 3) +#define DP_F_ZERO (1 << 4) +#define DP_F_UP (1 << 5) +#define DP_F_UNSIGNED (1 << 6) + +/* Conversion Flags */ +#define DP_C_SHORT 1 +#define DP_C_LONG 2 +#define DP_C_LDOUBLE 3 +#define DP_C_LONG_LONG 4 + +#define char_to_int(p) (p - '0') +#define abs_val(p) (p < 0 ? -p : p) + + +static void +dopr(char *buffer, size_t maxlen, const char *format, va_list args) +{ + char *strvalue, ch; + long value; + long double fvalue; + int min = 0, max = -1, state = DP_S_DEFAULT, flags = 0, cflags = 0; + size_t currlen = 0; + + ch = *format++; + + while (state != DP_S_DONE) { + if ((ch == '\0') || (currlen >= maxlen)) + state = DP_S_DONE; + + switch(state) { + case DP_S_DEFAULT: + if (ch == '%') + state = DP_S_FLAGS; + else + dopr_outch(buffer, &currlen, maxlen, ch); + ch = *format++; + break; + case DP_S_FLAGS: + switch (ch) { + case '-': + flags |= DP_F_MINUS; + ch = *format++; + break; + case '+': + flags |= DP_F_PLUS; + ch = *format++; + break; + case ' ': + flags |= DP_F_SPACE; + ch = *format++; + break; + case '#': + flags |= DP_F_NUM; + ch = *format++; + break; + case '0': + flags |= DP_F_ZERO; + ch = *format++; + break; + default: + state = DP_S_MIN; + break; + } + break; + case DP_S_MIN: + if (isdigit((unsigned char)ch)) { + min = 10 * min + char_to_int (ch); + ch = *format++; + } else if (ch == '*') { + min = va_arg (args, int); + ch = *format++; + state = DP_S_DOT; + } else + state = DP_S_DOT; + break; + case DP_S_DOT: + if (ch == '.') { + state = DP_S_MAX; + ch = *format++; + } else + state = DP_S_MOD; + break; + case DP_S_MAX: + if (isdigit((unsigned char)ch)) { + if (max < 0) + max = 0; + max = 10 * max + char_to_int(ch); + ch = *format++; + } else if (ch == '*') { + max = va_arg (args, int); + ch = *format++; + state = DP_S_MOD; + } else + state = DP_S_MOD; + break; + case DP_S_MOD: + switch (ch) { + case 'h': + cflags = DP_C_SHORT; + ch = *format++; + break; + case 'l': + cflags = DP_C_LONG; + ch = *format++; + if (ch == 'l') { + cflags = DP_C_LONG_LONG; + ch = *format++; + } + break; + case 'q': + cflags = DP_C_LONG_LONG; + ch = *format++; + break; + case 'L': + cflags = DP_C_LDOUBLE; + ch = *format++; + break; + default: + break; + } + state = DP_S_CONV; + break; + case DP_S_CONV: + switch (ch) { + case 'd': + case 'i': + if (cflags == DP_C_SHORT) + value = va_arg(args, int); + else if (cflags == DP_C_LONG) + value = va_arg(args, long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg (args, long long); + else + value = va_arg (args, int); + fmtint(buffer, &currlen, maxlen, value, 10, min, max, flags); + break; + case 'o': + flags |= DP_F_UNSIGNED; + if (cflags == DP_C_SHORT) + value = va_arg(args, unsigned int); + else if (cflags == DP_C_LONG) + value = va_arg(args, unsigned long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg(args, unsigned long long); + else + value = va_arg(args, unsigned int); + fmtint(buffer, &currlen, maxlen, value, 8, min, max, flags); + break; + case 'u': + flags |= DP_F_UNSIGNED; + if (cflags == DP_C_SHORT) + value = va_arg(args, unsigned int); + else if (cflags == DP_C_LONG) + value = va_arg(args, unsigned long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg(args, unsigned long long); + else + value = va_arg(args, unsigned int); + fmtint (buffer, &currlen, maxlen, value, 10, min, max, flags); + break; + case 'X': + flags |= DP_F_UP; + case 'x': + flags |= DP_F_UNSIGNED; + if (cflags == DP_C_SHORT) + value = va_arg(args, unsigned int); + else if (cflags == DP_C_LONG) + value = va_arg(args, unsigned long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg(args, unsigned long long); + else + value = va_arg(args, unsigned int); + fmtint(buffer, &currlen, maxlen, value, 16, min, max, flags); + break; + case 'f': + if (cflags == DP_C_LDOUBLE) + fvalue = va_arg(args, long double); + else + fvalue = va_arg(args, double); + /* um, floating point? */ + fmtfp(buffer, &currlen, maxlen, fvalue, min, max, flags); + break; + case 'E': + flags |= DP_F_UP; + case 'e': + if (cflags == DP_C_LDOUBLE) + fvalue = va_arg(args, long double); + else + fvalue = va_arg(args, double); + break; + case 'G': + flags |= DP_F_UP; + case 'g': + if (cflags == DP_C_LDOUBLE) + fvalue = va_arg(args, long double); + else + fvalue = va_arg(args, double); + break; + case 'c': + dopr_outch(buffer, &currlen, maxlen, va_arg(args, int)); + break; + case 's': + strvalue = va_arg(args, char *); + if (max < 0) + max = maxlen; /* ie, no max */ + fmtstr(buffer, &currlen, maxlen, strvalue, flags, min, max); + break; + case 'p': + strvalue = va_arg(args, void *); + fmtint(buffer, &currlen, maxlen, (long) strvalue, 16, min, max, flags); + break; + case 'n': + if (cflags == DP_C_SHORT) { + short int *num; + num = va_arg(args, short int *); + *num = currlen; + } else if (cflags == DP_C_LONG) { + long int *num; + num = va_arg(args, long int *); + *num = currlen; + } else if (cflags == DP_C_LONG_LONG) { + long long *num; + num = va_arg(args, long long *); + *num = currlen; + } else { + int *num; + num = va_arg(args, int *); + *num = currlen; + } + break; + case '%': + dopr_outch(buffer, &currlen, maxlen, ch); + break; + case 'w': /* not supported yet, treat as next char */ + ch = *format++; + break; + default: /* Unknown, skip */ + break; + } + ch = *format++; + state = DP_S_DEFAULT; + flags = cflags = min = 0; + max = -1; + break; + case DP_S_DONE: + break; + default: /* hmm? */ + break; /* some picky compilers need this */ + } + } + if (currlen < maxlen - 1) + buffer[currlen] = '\0'; + else + buffer[maxlen - 1] = '\0'; +} + +static void +fmtstr(char *buffer, size_t *currlen, size_t maxlen, + char *value, int flags, int min, int max) +{ + int cnt = 0, padlen, strln; /* amount to pad */ + + if (value == 0) + value = ""; + + for (strln = 0; value[strln]; ++strln); /* strlen */ + padlen = min - strln; + if (padlen < 0) + padlen = 0; + if (flags & DP_F_MINUS) + padlen = -padlen; /* Left Justify */ + + while ((padlen > 0) && (cnt < max)) { + dopr_outch(buffer, currlen, maxlen, ' '); + --padlen; + ++cnt; + } + while (*value && (cnt < max)) { + dopr_outch(buffer, currlen, maxlen, *value++); + ++cnt; + } + while ((padlen < 0) && (cnt < max)) { + dopr_outch(buffer, currlen, maxlen, ' '); + ++padlen; + ++cnt; + } +} + +/* Have to handle DP_F_NUM (ie 0x and 0 alternates) */ + +static void +fmtint(char *buffer, size_t *currlen, size_t maxlen, + long value, int base, int min, int max, int flags) +{ + unsigned long uvalue; + char convert[20]; + int signvalue = 0, place = 0, caps = 0; + int spadlen = 0; /* amount to space pad */ + int zpadlen = 0; /* amount to zero pad */ + +#define PADMAX(x,y) ((x) > (y) ? (x) : (y)) + + if (max < 0) + max = 0; + + uvalue = value; + + if (!(flags & DP_F_UNSIGNED)) { + if (value < 0) { + signvalue = '-'; + uvalue = -value; + } else if (flags & DP_F_PLUS) /* Do a sign (+/i) */ + signvalue = '+'; + else if (flags & DP_F_SPACE) + signvalue = ' '; + } + + if (flags & DP_F_UP) + caps = 1; /* Should characters be upper case? */ + do { + convert[place++] = + (caps ? "0123456789ABCDEF" : "0123456789abcdef") + [uvalue % (unsigned)base]; + uvalue = (uvalue / (unsigned)base ); + } while (uvalue && (place < 20)); + if (place == 20) + place--; + convert[place] = 0; + + zpadlen = max - place; + spadlen = min - PADMAX(max, place) - (signvalue ? 1 : 0); + if (zpadlen < 0) + zpadlen = 0; + if (spadlen < 0) + spadlen = 0; + if (flags & DP_F_ZERO) { + zpadlen = PADMAX(zpadlen, spadlen); + spadlen = 0; + } + if (flags & DP_F_MINUS) + spadlen = -spadlen; /* Left Justifty */ + + /* Spaces */ + while (spadlen > 0) { + dopr_outch(buffer, currlen, maxlen, ' '); + --spadlen; + } + + /* Sign */ + if (signvalue) + dopr_outch(buffer, currlen, maxlen, signvalue); + + /* Zeros */ + if (zpadlen > 0) { + while (zpadlen > 0) { + dopr_outch(buffer, currlen, maxlen, '0'); + --zpadlen; + } + } + + /* Digits */ + while (place > 0) + dopr_outch(buffer, currlen, maxlen, convert[--place]); + + /* Left Justified spaces */ + while (spadlen < 0) { + dopr_outch (buffer, currlen, maxlen, ' '); + ++spadlen; + } +} + +static long double +pow10(int exp) +{ + long double result = 1; + + while (exp) { + result *= 10; + exp--; + } + + return result; +} + +static long +round(long double value) +{ + long intpart = value; + + value -= intpart; + if (value >= 0.5) + intpart++; + + return intpart; +} + +static void +fmtfp(char *buffer, size_t *currlen, size_t maxlen, long double fvalue, + int min, int max, int flags) +{ + char iconvert[20], fconvert[20]; + int signvalue = 0, iplace = 0, fplace = 0; + int padlen = 0; /* amount to pad */ + int zpadlen = 0, caps = 0; + long intpart, fracpart; + long double ufvalue; + + /* + * AIX manpage says the default is 0, but Solaris says the default + * is 6, and sprintf on AIX defaults to 6 + */ + if (max < 0) + max = 6; + + ufvalue = abs_val(fvalue); + + if (fvalue < 0) + signvalue = '-'; + else if (flags & DP_F_PLUS) /* Do a sign (+/i) */ + signvalue = '+'; + else if (flags & DP_F_SPACE) + signvalue = ' '; + + intpart = ufvalue; + + /* + * Sorry, we only support 9 digits past the decimal because of our + * conversion method + */ + if (max > 9) + max = 9; + + /* We "cheat" by converting the fractional part to integer by + * multiplying by a factor of 10 + */ + fracpart = round((pow10 (max)) * (ufvalue - intpart)); + + if (fracpart >= pow10 (max)) { + intpart++; + fracpart -= pow10 (max); + } + + /* Convert integer part */ + do { + iconvert[iplace++] = + (caps ? "0123456789ABCDEF" : "0123456789abcdef") + [intpart % 10]; + intpart = (intpart / 10); + } while(intpart && (iplace < 20)); + if (iplace == 20) + iplace--; + iconvert[iplace] = 0; + + /* Convert fractional part */ + do { + fconvert[fplace++] = + (caps ? "0123456789ABCDEF" : "0123456789abcdef") + [fracpart % 10]; + fracpart = (fracpart / 10); + } while(fracpart && (fplace < 20)); + if (fplace == 20) + fplace--; + fconvert[fplace] = 0; + + /* -1 for decimal point, another -1 if we are printing a sign */ + padlen = min - iplace - max - 1 - ((signvalue) ? 1 : 0); + zpadlen = max - fplace; + if (zpadlen < 0) + zpadlen = 0; + if (padlen < 0) + padlen = 0; + if (flags & DP_F_MINUS) + padlen = -padlen; /* Left Justifty */ + + if ((flags & DP_F_ZERO) && (padlen > 0)) { + if (signvalue) { + dopr_outch(buffer, currlen, maxlen, signvalue); + --padlen; + signvalue = 0; + } + while (padlen > 0) { + dopr_outch(buffer, currlen, maxlen, '0'); + --padlen; + } + } + while (padlen > 0) { + dopr_outch(buffer, currlen, maxlen, ' '); + --padlen; + } + if (signvalue) + dopr_outch(buffer, currlen, maxlen, signvalue); + + while (iplace > 0) + dopr_outch(buffer, currlen, maxlen, iconvert[--iplace]); + + /* + * Decimal point. This should probably use locale to find the + * correct char to print out. + */ + dopr_outch(buffer, currlen, maxlen, '.'); + + while (fplace > 0) + dopr_outch(buffer, currlen, maxlen, fconvert[--fplace]); + + while (zpadlen > 0) { + dopr_outch(buffer, currlen, maxlen, '0'); + --zpadlen; + } + + while (padlen < 0) { + dopr_outch(buffer, currlen, maxlen, ' '); + ++padlen; + } +} + +static void +dopr_outch(char *buffer, size_t *currlen, size_t maxlen, char c) +{ + if (*currlen < maxlen) + buffer[(*currlen)++] = c; +} +#endif /* !defined(HAVE_SNPRINTF) || !defined(HAVE_VSNPRINTF) */ + +#ifndef HAVE_VSNPRINTF +int +vsnprintf(char *str, size_t count, const char *fmt, va_list args) +{ + str[0] = 0; + dopr(str, count, fmt, args); + + return(strlen(str)); +} +#endif /* !HAVE_VSNPRINTF */ + +#ifndef HAVE_SNPRINTF +int +snprintf(char *str,size_t count,const char *fmt,...) +{ + va_list ap; + + va_start(ap, fmt); + (void) vsnprintf(str, count, fmt, ap); + va_end(ap); + + return(strlen(str)); +} + +#endif /* !HAVE_SNPRINTF */ Index: manifest.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/manifest.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/manifest.h -L usr.bin/pcc/mip/manifest.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/manifest.h +++ usr.bin/pcc/mip/manifest.h @@ -1,4 +1,4 @@ -/* $Id: manifest.h,v 1.59 2007/09/20 12:02:54 ragge Exp $ */ +/* $Id: manifest.h,v 1.87 2008/12/04 07:28:55 ragge Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -37,9 +37,11 @@ #define MANIFEST #include -#include "../config.h" +#include +#include "config.h" #include "macdefs.h" #include "node.h" +#include "compat.h" /* * Node types @@ -75,8 +77,8 @@ #define LDOUBLE 14 #define STRTY 15 #define UNIONTY 16 -#define ENUMTY 17 -#define MOETY 18 /* member of enum */ +/* #define ENUMTY 17 */ +/* #define MOETY 18 */ /* member of enum */ #define VOID 19 #define MAXTYPES 19 /* highest type+1 to be used by lang code */ @@ -114,6 +116,7 @@ #define UNSIGNABLE(x) (((x)<=ULONGLONG&&(x)>=CHAR) && !ISUNSIGNED(x)) #define ENUNSIGN(x) ((x)|1) #define DEUNSIGN(x) ((x)&~1) +#define ISINTEGER(x) (((x) >= CHAR && (x) <= ULONGLONG) || (x) == BOOL) #define ISPTR(x) (((x)&TMASK)==PTR) #define ISFTN(x) (((x)&TMASK)==FTN) /* is x a function type? */ #define ISARY(x) (((x)&TMASK)==ARY) /* is x an array type? */ @@ -165,18 +168,24 @@ #define DATA 1 /* (rw) data segment */ #define RDATA 2 /* (ro) data segment */ #define STRNG 3 /* (ro) string segment */ +#define UDATA 4 /* (rw) uninitialized data */ +#define regno(p) ((p)->n_rval) /* register number */ + /* * */ extern int bdebug, tdebug, edebug; extern int ddebug, xdebug, f2debug; -extern int iTflag, oTflag; -extern int vdebug, sflag, nflag, gflag; +extern int iTflag, oTflag, kflag; +extern int sflag, nflag, gflag, pflag; extern int Wstrict_prototypes, Wmissing_prototypes, Wimplicit_int, - Wimplicit_function_declaration; -extern int xssaflag, xtailcallflag, xtemps, xdeljumps; + Wimplicit_function_declaration, Wpointer_sign, Wshadow, + Wsign_compare, Wunknown_pragmas, Wunreachable_code; +extern int funsigned_char; +extern int sspflag; +extern int xssaflag, xtailcallflag, xtemps, xdeljumps, xdce; int yyparse(void); void yyaccpt(void); @@ -191,6 +200,7 @@ #define DLIST_NEXT(h,f) (h)->f.q_forw #define DLIST_PREV(h,f) (h)->f.q_back #define DLIST_ISEMPTY(h,f) ((h)->f.q_forw == (h)) +#define DLIST_ENDMARK(h) (h) #define DLIST_FOREACH(v,h,f) \ for ((v) = (h)->f.q_forw; (v) != (h); (v) = (v)->f.q_forw) #define DLIST_FOREACH_REVERSE(v,h,f) \ @@ -215,17 +225,26 @@ /* Single-linked list */ #define SLIST_INIT(h) \ { (h)->q_forw = NULL; (h)->q_last = &(h)->q_forw; } +#define SLIST_SETUP(h) { NULL, &(h)->q_forw } #define SLIST_ENTRY(t) struct { struct t *q_forw; } #define SLIST_HEAD(n,t) struct n { struct t *q_forw, **q_last; } +#define SLIST_ISEMPTY(h) ((h)->q_last == &(h)->q_forw) #define SLIST_FIRST(h) ((h)->q_forw) #define SLIST_FOREACH(v,h,f) \ for ((v) = (h)->q_forw; (v) != NULL; (v) = (v)->f.q_forw) +#define SLIST_INSERT_FIRST(h,e,f) { \ + if ((h)->q_last == &(h)->q_forw) \ + (h)->q_last = &(e)->f.q_forw; \ + (e)->f.q_forw = (h)->q_forw; \ + (h)->q_forw = (e); \ +} #define SLIST_INSERT_LAST(h,e,f) { \ (e)->f.q_forw = NULL; \ *(h)->q_last = (e); \ (h)->q_last = &(e)->f.q_forw; \ } +#ifndef MKEXT /* * Functions for inter-pass communication. * @@ -253,11 +272,20 @@ char *ipp_name; /* Function name */ int ipp_vis; /* Function visibility */ TWORD ipp_type; /* Function type */ - int ipp_regs; /* Bitmask of registers to save */ +#define NIPPREGS BIT2BYTE(MAXREGS)/sizeof(bittype) + bittype ipp_regs[NIPPREGS]; + /* Bitmask of registers to save */ int ipp_autos; /* Size on stack needed */ int ip_tmpnum; /* # allocated temp nodes so far */ int ip_lblnum; /* # used labels so far */ +#ifdef TARGET_IPP_MEMBERS + TARGET_IPP_MEMBERS +#endif }; +#else +struct interpass { int dummy; }; +struct interpass_prolog; +#endif /* !MKEXT */ /* * Epilog/prolog takes following arguments (in order): @@ -289,17 +317,13 @@ /* * External declarations, typedefs and the like */ -char *hash(char *s); -char *savestr(char *cp); -char *tstr(char *cp); - -#ifndef HAVE_STRLCPY -size_t strlcpy(char *dst, const char *src, size_t siz); -#endif -#ifndef HAVE_STRLCAT -size_t strlcat(char *dst, const char *src, size_t siz); -#endif +/* used for memory allocation */ +typedef struct mark { + void *tmsav; + void *tasav; + int elem; +} MARK; /* memory management stuff */ void *permalloc(int size); @@ -307,6 +331,12 @@ void *tmpalloc(int size); void tmpfree(void); char *newstring(char *, int len); +char *tmpstrdup(char *str); +void markset(struct mark *m); +void markfree(struct mark *m); + +/* command-line processing */ +void mflags(char *); void tprint(FILE *, TWORD, TWORD); @@ -318,7 +348,18 @@ /* node routines */ NODE *nfree(NODE *); +void tfree(NODE *); +NODE *tcopy(NODE *); +void walkf(NODE *, void (*f)(NODE *, void *), void *); void fwalk(NODE *t, void (*f)(NODE *, int, int *, int *), int down); +void flist(NODE *p, void (*f)(NODE *, void *), void *); +void listf(NODE *p, void (*f)(NODE *)); +NODE *listarg(NODE *p, int n, int *cnt); +void cerror(char *s, ...); +void werror(char *s, ...); +void uerror(char *s, ...); + extern int nerrors; /* number of errors seen so far */ +extern int warniserr; /* treat warnings as errors */ #endif Index: mkext.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/mkext.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/mkext.c -L usr.bin/pcc/mip/mkext.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/mkext.c +++ usr.bin/pcc/mip/mkext.c @@ -3,8 +3,21 @@ * Generate defines for the needed hardops. */ #include "pass2.h" +#include +#ifdef HAVE_STRING_H #include +#endif + +#ifdef HAVE_C99_FORMAT +#define FMTdPTR "%td" +#else +#if defined(_WIN64) || defined(LP64) +#define FMTdPTR "%ld" +#else +#define FMTdPTR "%d" +#endif +#endif int chkop[DSIZE]; @@ -62,12 +75,53 @@ int rstatus[] = { RSTATUS }; int roverlay[MAXREGS][MAXREGS] = { ROVERLAP }; -int regclassmap[NUMCLASS][MAXREGS]; +int regclassmap[CLASSG][MAXREGS]; /* CLASSG is highest class */ static void compl(struct optab *q, char *str) { - printf("table entry %td, op %s: %s\n", q - table, opst[q->op], str); + int op = q->op; + char *s; + + if (op < OPSIMP) { + s = opst[op]; + } else + switch (op) { + default: s = "Special op"; break; + case OPSIMP: s = "OPLSIMP"; break; + case OPCOMM: s = "OPCOMM"; break; + case OPMUL: s = "OPMUL"; break; + case OPDIV: s = "OPDIV"; break; + case OPUNARY: s = "OPUNARY"; break; + case OPLEAF: s = "OPLEAF"; break; + case OPANY: s = "OPANY"; break; + case OPLOG: s = "OPLOG"; break; + case OPFLOAT: s = "OPFLOAT"; break; + case OPSHFT: s = "OPSHFT"; break; + case OPLTYPE: s = "OPLTYPE"; break; + } + + printf("table entry " FMTdPTR ", op %s: %s\n", q - table, s, str); +} + +static int +getrcl(struct optab *q) +{ + int v = q->needs & + (NACOUNT|NBCOUNT|NCCOUNT|NDCOUNT|NECOUNT|NFCOUNT|NGCOUNT); + int r = q->rewrite & RESC1 ? 1 : q->rewrite & RESC2 ? 2 : 3; + int i = 0; + +#define INCK(c) while (v & c##COUNT) { \ + v -= c##REG, i++; if (i == r) return I##c##REG; } + INCK(NA) + INCK(NB) + INCK(NC) + INCK(ND) + INCK(NE) + INCK(NF) + INCK(NG) + return 0; } int @@ -75,10 +129,16 @@ { struct optab *q; struct checks *ch; - int i, j, areg, breg, creg, dreg, mx; + int i, j, areg, breg, creg, dreg, mx, ereg, freg, greg; char *bitary; int bitsz, rval, nelem; + if (argc == 2) { + i = atoi(argv[1]); + printf("Entry %d:\n%s\n", i, table[i].cstring); + return 0; + } + mkdope(); for (q = table; q->op != FREE; q++) { @@ -99,6 +159,8 @@ perror("open hfile"); return(1); } + fprintf(fh, "#ifndef _EXTERNAL_H_\n#define _EXTERNAL_H_\n"); + for (ch = checks; ch->op != 0; ch++) { if ((chkop[ch->op] & ch->type) == 0) fprintf(fh, "#define NEED_%s\n", ch->name); @@ -117,12 +179,17 @@ bitsz = sizeof(int) == 4 ? 32 : 16; } fprintf(fh, "#define NUMBITS %d\n", bitsz); + fprintf(fh, "#define BIT2BYTE(bits) " + "((((bits)+NUMBITS-1)/NUMBITS)*(NUMBITS/8))\n"); fprintf(fh, "#define BITSET(arr, bit) " - "(arr[bit/NUMBITS] |= (1 << (bit & (NUMBITS-1))))\n"); + "(arr[bit/NUMBITS] |= ((%s)1 << (bit & (NUMBITS-1))))\n", + bitary); fprintf(fh, "#define BITCLEAR(arr, bit) " - "(arr[bit/NUMBITS] &= ~(1 << (bit & (NUMBITS-1))))\n"); + "(arr[bit/NUMBITS] &= ~((%s)1 << (bit & (NUMBITS-1))))\n", + bitary); fprintf(fh, "#define TESTBIT(arr, bit) " - "(arr[bit/NUMBITS] & (1 << (bit & (NUMBITS-1))))\n"); + "(arr[bit/NUMBITS] & ((%s)1 << (bit & (NUMBITS-1))))\n", + bitary); fprintf(fh, "typedef %s bittype;\n", bitary); /* register class definitions, used by graph-coloring */ @@ -134,16 +201,25 @@ if (q->op == ASSIGN) { #define F(x) (q->visit & x && q->rewrite & (RLEFT|RRIGHT) && \ q->lshape & ~x && q->rshape & ~x) - if (F(INAREG) || F(INBREG) || F(INCREG) || F(INDREG)) { + if (F(INAREG) || F(INBREG) || F(INCREG) || F(INDREG) || + F(INEREG) || F(INFREG) || F(INGREG)) { compl(q, "may match without result register"); rval++; } #undef F - if ((q->visit & INREGS) && q->rewrite != RDEST) { + if ((q->visit & INREGS) && !(q->rewrite & RDEST)) { compl(q, "ASSIGN reclaim must be RDEST"); rval++; } } + /* check that reclaim is not the wrong class */ + if ((q->rewrite & (RESC1|RESC2|RESC3)) && + !(q->needs & REWRITE)) { + if ((q->visit & getrcl(q)) == 0) { + compl(q, "wrong RESCx class"); + rval++; + } + } if (q->rewrite & (RESC1|RESC2|RESC3) && q->visit & FOREFF) compl(q, "FOREFF may cause reclaim of wrong class"); } @@ -163,23 +239,42 @@ fprintf(fc, "%d, ", i), j++; fprintf(fc, "-1 };\n"); fprintf(fh, "#define NPERMREG %d\n", j+1); + fprintf(fc, "bittype validregs[] = {\n"); + for (j = 0; j < MAXREGS; j += bitsz) { + int cbit = 0; + for (i = 0; i < bitsz; i++) { + if (i+j == MAXREGS) + break; + if (rstatus[i+j] & INREGS) + cbit |= (1 << i); + } + fprintf(fc, "\t0x%08x,\n", cbit); + } + fprintf(fc, "};\n"); + fprintf(fh, "extern bittype validregs[];\n"); /* * The register allocator uses bitmasks of registers for each class. */ - areg = breg = creg = dreg = 0; + areg = breg = creg = dreg = ereg = freg = greg = 0; for (i = 0; i < MAXREGS; i++) { - regclassmap[0][i] = regclassmap[1][i] = regclassmap[2][i] = - regclassmap[3][i] = -1; + for (j = 0; j < NUMCLASS; j++) + regclassmap[j][i] = -1; if (rstatus[i] & SAREG) regclassmap[0][i] = areg++; if (rstatus[i] & SBREG) regclassmap[1][i] = breg++; if (rstatus[i] & SCREG) regclassmap[2][i] = creg++; if (rstatus[i] & SDREG) regclassmap[3][i] = dreg++; + if (rstatus[i] & SEREG) regclassmap[4][i] = ereg++; + if (rstatus[i] & SFREG) regclassmap[5][i] = freg++; + if (rstatus[i] & SGREG) regclassmap[6][i] = greg++; } fprintf(fh, "#define AREGCNT %d\n", areg); fprintf(fh, "#define BREGCNT %d\n", breg); fprintf(fh, "#define CREGCNT %d\n", creg); fprintf(fh, "#define DREGCNT %d\n", dreg); + fprintf(fh, "#define EREGCNT %d\n", ereg); + fprintf(fh, "#define FREGCNT %d\n", freg); + fprintf(fh, "#define GREGCNT %d\n", greg); if (areg > bitsz) printf("%d regs in class A (max %d)\n", areg, bitsz), rval++; if (breg > bitsz) @@ -188,15 +283,24 @@ printf("%d regs in class C (max %d)\n", creg, bitsz), rval++; if (dreg > bitsz) printf("%d regs in class D (max %d)\n", dreg, bitsz), rval++; + if (ereg > bitsz) + printf("%d regs in class E (max %d)\n", ereg, bitsz), rval++; + if (freg > bitsz) + printf("%d regs in class F (max %d)\n", freg, bitsz), rval++; + if (greg > bitsz) + printf("%d regs in class G (max %d)\n", greg, bitsz), rval++; fprintf(fc, "static int amap[MAXREGS][NUMCLASS] = {\n"); for (i = 0; i < MAXREGS; i++) { - int ba, bb, bc, bd, r; - ba = bb = bc = bd = 0; + int ba, bb, bc, bd, r, be, bf, bg; + ba = bb = bc = bd = be = bf = bg = 0; if (rstatus[i] & SAREG) ba = (1 << regclassmap[0][i]); if (rstatus[i] & SBREG) bb = (1 << regclassmap[1][i]); if (rstatus[i] & SCREG) bc = (1 << regclassmap[2][i]); if (rstatus[i] & SDREG) bd = (1 << regclassmap[3][i]); + if (rstatus[i] & SEREG) be = (1 << regclassmap[4][i]); + if (rstatus[i] & SFREG) bf = (1 << regclassmap[5][i]); + if (rstatus[i] & SGREG) bg = (1 << regclassmap[6][i]); for (j = 0; roverlay[i][j] >= 0; j++) { r = roverlay[i][j]; if (rstatus[r] & SAREG) @@ -207,8 +311,21 @@ bc |= (1 << regclassmap[2][r]); if (rstatus[r] & SDREG) bd |= (1 << regclassmap[3][r]); + if (rstatus[r] & SEREG) + be |= (1 << regclassmap[4][r]); + if (rstatus[r] & SFREG) + bf |= (1 << regclassmap[5][r]); + if (rstatus[r] & SGREG) + bg |= (1 << regclassmap[6][r]); } - fprintf(fc, "\t{ 0x%x,0x%x,0x%x,0x%x },\n", ba, bb, bc, bd); + fprintf(fc, "\t/* %d */{ 0x%x", i, ba); + if (NUMCLASS > 1) fprintf(fc, ",0x%x", bb); + if (NUMCLASS > 2) fprintf(fc, ",0x%x", bc); + if (NUMCLASS > 3) fprintf(fc, ",0x%x", bd); + if (NUMCLASS > 4) fprintf(fc, ",0x%x", be); + if (NUMCLASS > 5) fprintf(fc, ",0x%x", bf); + if (NUMCLASS > 6) fprintf(fc, ",0x%x", bg); + fprintf(fc, " },\n"); } fprintf(fc, "};\n"); @@ -221,9 +338,12 @@ if (breg > mx) mx = breg; if (creg > mx) mx = creg; if (dreg > mx) mx = dreg; - if (mx > (sizeof(int)*8)-1) { - printf("too many regs in a calss, use two classes instead\n"); - printf("%d > %d\n", mx, (sizeof(int)*8)-1); + if (ereg > mx) mx = ereg; + if (freg > mx) mx = freg; + if (greg > mx) mx = greg; + if (mx > (int)(sizeof(int)*8)-1) { + printf("too many regs in a class, use two classes instead\n"); + printf("%d > %zu\n", mx, (sizeof(int)*8)-1); rval++; } fprintf(fc, "static int rmap[NUMCLASS][%d] = {\n", mx); @@ -241,13 +361,16 @@ fprintf(fc, " return rmap[class-1][color];\n}\n"); /* used by register allocator */ - fprintf(fc, "int regK[] = { 0, %d, %d, %d, %d };\n", - areg, breg, creg, dreg); + fprintf(fc, "int regK[] = { 0, %d, %d, %d, %d, %d, %d, %d };\n", + areg, breg, creg, dreg, ereg, freg, greg); fprintf(fc, "int\nclassmask(int class)\n{\n"); fprintf(fc, "\tif(class == CLASSA) return 0x%x;\n", (1 << areg)-1); fprintf(fc, "\tif(class == CLASSB) return 0x%x;\n", (1 << breg)-1); fprintf(fc, "\tif(class == CLASSC) return 0x%x;\n", (1 << creg)-1); - fprintf(fc, "\treturn 0x%x;\n}\n", (1 << dreg)-1); + fprintf(fc, "\tif(class == CLASSD) return 0x%x;\n", (1 << dreg)-1); + fprintf(fc, "\tif(class == CLASSE) return 0x%x;\n", (1 << ereg)-1); + fprintf(fc, "\tif(class == CLASSF) return 0x%x;\n", (1 << freg)-1); + fprintf(fc, "\treturn 0x%x;\n}\n", (1 << greg)-1); fprintf(fh, "int interferes(int reg1, int reg2);\n"); nelem = (MAXREGS+bitsz-1)/bitsz; @@ -270,6 +393,7 @@ fprintf(fc, "int\ninterferes(int reg1, int reg2)\n{\n"); fprintf(fc, "return TESTBIT(ovlarr[reg1], reg2);\n}\n"); fclose(fc); + fprintf(fh, "#endif /* _EXTERNAL_H_ */\n"); fclose(fh); return rval; } @@ -291,19 +415,20 @@ for (op = table; op->op != FREE; op++) { if (op->op < OPSIMP) { if (op->op == i) { - P((fc, "%td, ", op - table)); + P((fc, FMTdPTR ", ", op - table)); curalen++; } } else { int opmtemp; if ((opmtemp=mamask[op->op - OPSIMP])&SPFLG) { if (i==NAME || i==ICON || i==TEMP || - i==OREG || i == REG) { - P((fc, "%td, ", op - table)); + i==OREG || i == REG || i == FCON) { + P((fc, FMTdPTR ", ", + op - table)); curalen++; } } else if ((dope[i]&(opmtemp|ASGFLG))==opmtemp){ - P((fc, "%td, ", op - table)); + P((fc, FMTdPTR ", ", op - table)); curalen++; } } Index: optim2.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/optim2.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/optim2.c -L usr.bin/pcc/mip/optim2.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/optim2.c +++ usr.bin/pcc/mip/optim2.c @@ -1,4 +1,4 @@ -/* $Id: optim2.c,v 1.44 2006/06/20 06:02:44 ragge Exp $ */ +/* $Id: optim2.c,v 1.62 2008/12/11 21:23:28 pantzer Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -41,169 +41,48 @@ #define BDEBUG(x) if (b2debug) printf x +#define mktemp(n, t) mklnode(TEMP, 0, n, t) + static int dfsnum; void saveip(struct interpass *ip); -void deljumps(struct interpass *); +void deljumps(struct p2env *); void optdump(struct interpass *ip); void printip(struct interpass *pole); static struct varinfo defsites; struct interpass *storesave; -static struct interpass_prolog *ipp, *epp; /* prolog/epilog */ -void bblocks_build(struct interpass *, struct labelinfo *, struct bblockinfo *); -void cfg_build(struct labelinfo *labinfo); +void bblocks_build(struct p2env *, struct labelinfo *, struct bblockinfo *); +void cfg_build(struct p2env *, struct labelinfo *labinfo); void cfg_dfs(struct basicblock *bb, unsigned int parent, struct bblockinfo *bbinfo); -void dominators(struct bblockinfo *bbinfo); +void dominators(struct p2env *, struct bblockinfo *bbinfo); struct basicblock * ancestorwithlowestsemi(struct basicblock *bblock, struct bblockinfo *bbinfo); void link(struct basicblock *parent, struct basicblock *child); void computeDF(struct basicblock *bblock, struct bblockinfo *bbinfo); +void printDF(struct p2env *p2e, struct bblockinfo *bbinfo); void findTemps(struct interpass *ip); -void placePhiFunctions(struct bblockinfo *bbinfo); -void remunreach(void); - -struct basicblock bblocks; -int nbblocks; -static struct interpass *cvpole; - -struct addrof { - struct addrof *next; - int tempnum; - int oregoff; -} *otlink; - -static int -getoff(int num) -{ - struct addrof *w; - - for (w = otlink; w; w = w->next) - if (w->tempnum == num) - return w->oregoff; - return 0; -} - -/* - * Use stack argument addresses instead of copying if & is used on a var. - */ -static int -setargs(int tval, struct addrof *w) -{ - struct interpass *ip; - NODE *p; - - ip = DLIST_NEXT(cvpole, qelem); /* PROLOG */ - ip = DLIST_NEXT(ip, qelem); /* first DEFLAB */ - ip = DLIST_NEXT(ip, qelem); /* first NODE */ - for (; ip->type != IP_DEFLAB; ip = DLIST_NEXT(ip, qelem)) { - p = ip->ip_node; -#ifdef PCC_DEBUG - if (p->n_op != ASSIGN || p->n_left->n_op != TEMP) - comperr("temparg"); -#endif - if (p->n_right->n_op != OREG) - continue; /* arg in register */ - if (tval != p->n_left->n_lval) - continue; /* wrong assign */ - w->oregoff = p->n_right->n_lval; - tfree(p); - DLIST_REMOVE(ip, qelem); - return 1; - } - return 0; -} - -/* - * Search for ADDROF elements and, if found, record them. - */ -static void -findaddrof(NODE *p) -{ - struct addrof *w; - - if (p->n_op != ADDROF) - return; - if (getoff(p->n_left->n_lval)) - return; - w = tmpalloc(sizeof(struct addrof)); - w->tempnum = p->n_left->n_lval; - if (setargs(p->n_left->n_lval, w) == 0) - w->oregoff = BITOOR(freetemp(szty(p->n_left->n_type))); - w->next = otlink; - otlink = w; -} - - -/* - * Convert address-taken temps to OREGs. - */ -static void -cvtaddrof(NODE *p) -{ - NODE *l; - int n; - - if (p->n_op != ADDROF && p->n_op != TEMP) - return; - if (p->n_op == TEMP) { - n = getoff(p->n_lval); - if (n == 0) - return; - p->n_op = OREG; - p->n_lval = n; - p->n_rval = FPREG; - } else { - l = p->n_left; - l->n_type = p->n_type; - p->n_right = mklnode(ICON, l->n_lval, 0, l->n_type); - p->n_op = PLUS; - l->n_op = REG; - l->n_lval = 0; - l->n_rval = FPREG; - - } -} +void placePhiFunctions(struct p2env *, struct bblockinfo *bbinfo); +void renamevar(struct p2env *p2e,struct basicblock *bblock, struct bblockinfo *bbinfo); +void removephi(struct p2env *p2e, struct labelinfo *,struct bblockinfo *bbinfo); +void remunreach(struct p2env *); void -optimize(struct interpass *ipole) +optimize(struct p2env *p2e) { - struct interpass *ip; + struct interpass *ipole = &p2e->ipole; struct labelinfo labinfo; struct bblockinfo bbinfo; - ipp = (struct interpass_prolog *)DLIST_NEXT(ipole, qelem); - epp = (struct interpass_prolog *)DLIST_PREV(ipole, qelem); - if (b2debug) { printf("initial links\n"); printip(ipole); } - /* - * Convert ADDROF TEMP to OREGs. - */ - if (xtemps) { - otlink = NULL; - cvpole = ipole; - DLIST_FOREACH(ip, ipole, qelem) { - if (ip->type != IP_NODE) - continue; - walkf(ip->ip_node, findaddrof); - } - if (otlink) { - DLIST_FOREACH(ip, ipole, qelem) { - if (ip->type != IP_NODE) - continue; - walkf(ip->ip_node, cvtaddrof); - } - } - } - if (xdeljumps) - deljumps(ipole); /* Delete redundant jumps and dead code */ + deljumps(p2e); /* Delete redundant jumps and dead code */ #ifdef PCC_DEBUG if (b2debug) { @@ -212,32 +91,64 @@ } #endif if (xssaflag || xtemps) { - DLIST_INIT(&bblocks, bbelem); - bblocks_build(ipole, &labinfo, &bbinfo); + DLIST_INIT(&p2e->bblocks, bbelem); + bblocks_build(p2e, &labinfo, &bbinfo); BDEBUG(("Calling cfg_build\n")); - cfg_build(&labinfo); + cfg_build(p2e, &labinfo); } if (xssaflag) { BDEBUG(("Calling dominators\n")); - dominators(&bbinfo); + dominators(p2e, &bbinfo); BDEBUG(("Calling computeDF\n")); - computeDF(DLIST_NEXT(&bblocks, bbelem), &bbinfo); + computeDF(DLIST_NEXT(&p2e->bblocks, bbelem), &bbinfo); + + if (b2debug) { + printDF(p2e,&bbinfo); + } + + BDEBUG(("Calling placePhiFunctions\n")); + + placePhiFunctions(p2e, &bbinfo); + + BDEBUG(("Calling renamevar\n")); + + renamevar(p2e,DLIST_NEXT(&p2e->bblocks, bbelem), &bbinfo); + + BDEBUG(("Calling removephi\n")); + + removephi(p2e,&labinfo,&bbinfo); + BDEBUG(("Calling remunreach\n")); - remunreach(); -#if 0 - dfg = dfg_build(cfg); - ssa = ssa_build(cfg, dfg); + remunreach(p2e); + + /* + Recalculate basic blocks and cfg that was destroyed + by removephi + */ + + DLIST_INIT(&p2e->bblocks, bbelem); + bblocks_build(p2e, &labinfo, &bbinfo); + BDEBUG(("Calling cfg_build\n")); + cfg_build(p2e, &labinfo); + +#ifdef PCC_DEBUG + if (b2debug) { + printf("new tree\n"); + printip(ipole); + } #endif } #ifdef PCC_DEBUG - if (epp->ipp_regs != 0) - comperr("register error"); + { + int i; + for (i = NIPPREGS; i--; ) + if (p2e->epp->ipp_regs[i] != 0) + comperr("register error"); + } #endif -#ifdef MYOPTIM - myoptim((struct interpass *)ipp); -#endif + myoptim(ipole); } /* @@ -245,14 +156,18 @@ * This routine can be made much more efficient. */ void -deljumps(struct interpass *ipole) +deljumps(struct p2env *p2e) { - struct interpass *ip, *n, *ip2; + struct interpass *ipole = &p2e->ipole; + struct interpass *ip, *n, *ip2, *start; int gotone,low, high; - int *lblary, sz, o, i; + int *lblary, *jmpary, sz, o, i, j, lab1, lab2; + int del; + extern int negrel[]; + extern size_t negrelsize; - low = ipp->ip_lblnum; - high = epp->ip_lblnum; + low = p2e->ipp->ip_lblnum; + high = p2e->epp->ip_lblnum; #ifdef notyet mark = tmpmark(); /* temporary used memory */ @@ -260,18 +175,64 @@ sz = (high-low) * sizeof(int); lblary = tmpalloc(sz); + jmpary = tmpalloc(sz); + + /* + * XXX: Find the first two labels. They may not be deleted, + * because the register allocator expects them to be there. + * These will not be coalesced with any other label. + */ + lab1 = lab2 = -1; + start = NULL; + DLIST_FOREACH(ip, ipole, qelem) { + if (ip->type != IP_DEFLAB) + continue; + if (lab1 < 0) + lab1 = ip->ip_lbl; + else if (lab2 < 0) { + lab2 = ip->ip_lbl; + start = ip; + } else /* lab1 >= 0 && lab2 >= 0, we're done. */ + break; + } + if (lab1 < 0 || lab2 < 0) + comperr("deljumps"); again: gotone = 0; memset(lblary, 0, sz); + lblary[lab1 - low] = lblary[lab2 - low] = 1; + memset(jmpary, 0, sz); /* refcount and coalesce all labels */ DLIST_FOREACH(ip, ipole, qelem) { - if (ip->type == IP_DEFLAB) { + if (ip->type == IP_DEFLAB && ip->ip_lbl != lab1 && + ip->ip_lbl != lab2) { n = DLIST_NEXT(ip, qelem); + + /* + * Find unconditional jumps directly following a + * label. Jumps jumping to themselves are not + * taken into account. + */ + if (n->type == IP_NODE && n->ip_node->n_op == GOTO) { + i = n->ip_node->n_left->n_lval; + if (i != ip->ip_lbl) + jmpary[ip->ip_lbl - low] = i; + } + while (n->type == IP_DEFLAB) { - if (n->type == IP_DEFLAB && - lblary[n->ip_lbl-low] >= 0) - lblary[n->ip_lbl-low] = -ip->ip_lbl; + if (n->ip_lbl != lab1 && n->ip_lbl != lab2 && + lblary[n->ip_lbl-low] >= 0) { + /* + * If the label is used, mark the + * label to be coalesced with as + * used, too. + */ + if (lblary[n->ip_lbl - low] > 0 && + lblary[ip->ip_lbl - low] == 0) + lblary[ip->ip_lbl - low] = 1; + lblary[n->ip_lbl - low] = -ip->ip_lbl; + } n = DLIST_NEXT(n, qelem); } } @@ -284,7 +245,15 @@ i = ip->ip_node->n_right->n_lval; else continue; - lblary[i-low] |= 1; + + /* + * Mark destination label i as used, if it is not already. + * If i is to be merged with label j, mark j as used, too. + */ + if (lblary[i - low] == 0) + lblary[i-low] = 1; + else if ((j = lblary[i - low]) < 0 && lblary[-j - low] == 0) + lblary[-j - low] = 1; } /* delete coalesced/unused labels and rename gotos */ @@ -295,22 +264,33 @@ DLIST_REMOVE(n, qelem); gotone = 1; } - continue; } - if (n->type != IP_NODE) + if (ip->type != IP_NODE) continue; - o = n->ip_node->n_op; + o = ip->ip_node->n_op; if (o == GOTO) - i = n->ip_node->n_left->n_lval; + i = ip->ip_node->n_left->n_lval; else if (o == CBRANCH) - i = n->ip_node->n_right->n_lval; + i = ip->ip_node->n_right->n_lval; else continue; + + /* Simplify (un-)conditional jumps to unconditional jumps. */ + if (jmpary[i - low] > 0) { + gotone = 1; + i = jmpary[i - low]; + if (o == GOTO) + ip->ip_node->n_left->n_lval = i; + else + ip->ip_node->n_right->n_lval = i; + } + + /* Fixup for coalesced labels. */ if (lblary[i-low] < 0) { if (o == GOTO) - n->ip_node->n_left->n_lval = -lblary[i-low]; + ip->ip_node->n_left->n_lval = -lblary[i-low]; else - n->ip_node->n_right->n_lval = -lblary[i-low]; + ip->ip_node->n_right->n_lval = -lblary[i-low]; } } @@ -332,13 +312,61 @@ if (ip2->type != IP_DEFLAB) continue; - if (ip2->ip_lbl == i) { + if (ip2->ip_lbl == i && i != lab1 && i != lab2) { tfree(n->ip_node); DLIST_REMOVE(n, qelem); gotone = 1; } } + /* + * Transform cbranch cond, 1; goto 2; 1: ... into + * cbranch !cond, 2; 1: ... + */ + DLIST_FOREACH(ip, ipole, qelem) { + n = DLIST_NEXT(ip, qelem); + ip2 = DLIST_NEXT(n, qelem); + if (ip->type != IP_NODE || ip->ip_node->n_op != CBRANCH) + continue; + if (n->type != IP_NODE || n->ip_node->n_op != GOTO) + continue; + if (ip2->type != IP_DEFLAB) + continue; + i = ip->ip_node->n_right->n_lval; + j = n->ip_node->n_left->n_lval; + if (j == lab1 || j == lab2) + continue; + if (i != ip2->ip_lbl || i == lab1 || i == lab2) + continue; + ip->ip_node->n_right->n_lval = j; + i = ip->ip_node->n_left->n_op; + if (i < EQ || i - EQ >= (int)negrelsize) + comperr("deljumps: unexpected op"); + ip->ip_node->n_left->n_op = negrel[i - EQ]; + tfree(n->ip_node); + DLIST_REMOVE(n, qelem); + gotone = 1; + } + + /* Delete everything after a goto up to the next label. */ + for (ip = start, del = 0; ip != DLIST_ENDMARK(ipole); + ip = DLIST_NEXT(ip, qelem)) { +loop: + if ((n = DLIST_NEXT(ip, qelem)) == DLIST_ENDMARK(ipole)) + break; + if (n->type != IP_NODE) { + del = 0; + continue; + } + if (del) { + tfree(n->ip_node); + DLIST_REMOVE(n, qelem); + gotone = 1; + goto loop; + } else if (n->ip_node->n_op == GOTO) + del = 1; + } + if (gotone) goto again; @@ -355,7 +383,9 @@ printf("type %s\n", nm[ip->type-1]); switch (ip->type) { case IP_NODE: +#ifdef PCC_DEBUG fwalk(ip->ip_node, e2print, 0); +#endif break; case IP_DEFLAB: printf("label " LABFMT "\n", ip->ip_lbl); @@ -374,9 +404,10 @@ */ void -bblocks_build(struct interpass *ipole, struct labelinfo *labinfo, +bblocks_build(struct p2env *p2e, struct labelinfo *labinfo, struct bblockinfo *bbinfo) { + struct interpass *ipole = &p2e->ipole; struct interpass *ip; struct basicblock *bb = NULL; int low, high; @@ -384,8 +415,8 @@ int i; BDEBUG(("bblocks_build (%p, %p)\n", labinfo, bbinfo)); - low = ipp->ip_lblnum; - high = epp->ip_lblnum; + low = p2e->ipp->ip_lblnum; + high = p2e->epp->ip_lblnum; /* * First statement is a leader. @@ -410,8 +441,9 @@ bb->dfchildren = NULL; bb->Aorig = NULL; bb->Aphi = NULL; + SLIST_INIT(&bb->phi); bb->bbnum = count; - DLIST_INSERT_BEFORE(&bblocks, bb, bbelem); + DLIST_INSERT_BEFORE(&p2e->bblocks, bb, bbelem); count++; } bb->last = ip; @@ -421,12 +453,12 @@ if (ip->type == IP_PROLOG) bb = NULL; } - nbblocks = count; + p2e->nbblocks = count; if (b2debug) { printf("Basic blocks in func: %d, low %d, high %d\n", count, low, high); - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { printf("bb %p: first %p last %p\n", bb, bb->first, bb->last); } @@ -446,7 +478,7 @@ } /* Build the label table */ - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { if (bb->first->type == IP_DEFLAB) labinfo->arr[bb->first->ip_lbl - low] = bb; } @@ -465,14 +497,14 @@ */ void -cfg_build(struct labelinfo *labinfo) +cfg_build(struct p2env *p2e, struct labelinfo *labinfo) { /* Child and parent nodes */ struct cfgnode *cnode; struct cfgnode *pnode; struct basicblock *bb; - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { if (bb->first->type == IP_EPILOG) { break; @@ -483,7 +515,8 @@ pnode->bblock = bb; if ((bb->last->type == IP_NODE) && - (bb->last->ip_node->n_op == GOTO)) { + (bb->last->ip_node->n_op == GOTO) && + (bb->last->ip_node->n_left->n_op == ICON)) { if (bb->last->ip_node->n_left->n_lval - labinfo->low > labinfo->size) { comperr("Label out of range: %d, base %d", @@ -550,27 +583,27 @@ */ void -dominators(struct bblockinfo *bbinfo) +dominators(struct p2env *p2e, struct bblockinfo *bbinfo) { struct cfgnode *cnode; struct basicblock *bb, *y, *v; struct basicblock *s, *sprime, *p; int h, i; - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { bb->bucket = setalloc(bbinfo->size); bb->df = setalloc(bbinfo->size); bb->dfchildren = setalloc(bbinfo->size); } dfsnum = 0; - cfg_dfs(DLIST_NEXT(&bblocks, bbelem), 0, bbinfo); + cfg_dfs(DLIST_NEXT(&p2e->bblocks, bbelem), 0, bbinfo); if (b2debug) { struct basicblock *bbb; struct cfgnode *ccnode; - DLIST_FOREACH(bbb, &bblocks, bbelem) { + DLIST_FOREACH(bbb, &p2e->bblocks, bbelem) { printf("Basic block %d, parents: ", bbb->dfnum); SLIST_FOREACH(ccnode, &bbb->parents, cfgelem) { printf("%d, ", ccnode->bblock->dfnum); @@ -587,6 +620,9 @@ bb = bbinfo->arr[h]; p = s = bbinfo->arr[bb->dfparent]; SLIST_FOREACH(cnode, &bb->parents, cfgelem) { + if (cnode->bblock->dfnum ==0) + continue; /* Ignore unreachable code */ + if (cnode->bblock->dfnum <= bb->dfnum) sprime = cnode->bblock; else @@ -613,7 +649,7 @@ if (b2debug) { printf("Num\tSemi\tAncest\tidom\n"); - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { printf("%d\t%d\t%d\t%d\n", bb->dfnum, bb->semi, bb->ancestor, bb->idom); } @@ -625,7 +661,7 @@ bb->idom = bbinfo->arr[bb->samedom]->idom; } } - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { if (bb->idom != 0 && bb->idom != bb->dfnum) { BDEBUG(("Setting child %d of %d\n", bb->dfnum, bbinfo->arr[bb->idom]->dfnum)); @@ -672,36 +708,70 @@ computeDF(bbinfo->arr[h], bbinfo); for (i = 1; i < bbinfo->size; i++) { if (TESTBIT(bbinfo->arr[h]->df, i) && - (bbinfo->arr[h] == bblock || - (bblock->idom != bbinfo->arr[h]->dfnum))) + (bbinfo->arr[i] == bblock || + (bblock->dfnum != bbinfo->arr[i]->idom))) BITSET(bblock->df, i); } } } +void printDF(struct p2env *p2e, struct bblockinfo *bbinfo) +{ + struct basicblock *bb; + int i; + + printf("Dominance frontiers:\n"); + + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { + printf("bb %d : ", bb->dfnum); + + for (i=1; i < bbinfo->size;i++) { + if (TESTBIT(bb->df,i)) { + printf("%d ",i); + } + } + + printf("\n"); + } + +} + + + static struct basicblock *currbb; static struct interpass *currip; /* Helper function for findTemps, Find assignment nodes. */ static void -searchasg(NODE *p) +searchasg(NODE *p, void *arg) { struct pvarinfo *pv; - + int tempnr; + struct varstack *stacke; + if (p->n_op != ASSIGN) return; if (p->n_left->n_op != TEMP) return; + tempnr=regno(p->n_left)-defsites.low; + + BITSET(currbb->Aorig, tempnr); + pv = tmpcalloc(sizeof(struct pvarinfo)); - pv->next = defsites.arr[p->n_left->n_lval]; + pv->next = defsites.arr[tempnr]; pv->bb = currbb; - pv->top = currip->ip_node; - pv->n = p->n_left; - BITSET(currbb->Aorig, p->n_left->n_lval); - - defsites.arr[p->n_left->n_lval] = pv; + pv->n_type = p->n_left->n_type; + + defsites.arr[tempnr] = pv; + + + if (SLIST_FIRST(&defsites.stack[tempnr])==NULL) { + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=0; + SLIST_INSERT_FIRST(&defsites.stack[tempnr],stacke,varstackelem); + } } /* Walk the interpass looking for assignment nodes. */ @@ -712,7 +782,7 @@ currip = ip; - walkf(ip->ip_node, searchasg); + walkf(ip->ip_node, searchasg, 0); } /* @@ -720,32 +790,37 @@ */ void -placePhiFunctions(struct bblockinfo *bbinfo) +placePhiFunctions(struct p2env *p2e, struct bblockinfo *bbinfo) { struct basicblock *bb; + struct basicblock *y; struct interpass *ip; - int maxtmp, i, j, k, l; + int maxtmp, i, j, k; struct pvarinfo *n; struct cfgnode *cnode; TWORD ntype; - NODE *p; struct pvarinfo *pv; + struct phiinfo *phi; + int phifound; - bb = DLIST_NEXT(&bblocks, bbelem); + bb = DLIST_NEXT(&p2e->bblocks, bbelem); defsites.low = ((struct interpass_prolog *)bb->first)->ip_tmpnum; - bb = DLIST_PREV(&bblocks, bbelem); + bb = DLIST_PREV(&p2e->bblocks, bbelem); maxtmp = ((struct interpass_prolog *)bb->first)->ip_tmpnum; defsites.size = maxtmp - defsites.low + 1; defsites.arr = tmpcalloc(defsites.size*sizeof(struct pvarinfo *)); - + defsites.stack = tmpcalloc(defsites.size*sizeof(SLIST_HEAD(, varstack))); + + for (i=0;ibblocks, bbelem) { currbb = bb; ip = bb->first; bb->Aorig = setalloc(defsites.size); bb->Aphi = setalloc(defsites.size); - while (ip != bb->last) { findTemps(ip); ip = DLIST_NEXT(ip, qelem); @@ -753,8 +828,9 @@ /* Make sure we get the last statement in the bblock */ findTemps(ip); } + /* For each variable */ - for (i = defsites.low; i < defsites.size; i++) { + for (i = 0; i < defsites.size; i++) { /* While W not empty */ while (defsites.arr[i] != NULL) { /* Remove some node n from W */ @@ -768,27 +844,45 @@ if (TESTBIT(bbinfo->arr[j]->Aphi, i)) continue; - ntype = n->n->n_type; + y=bbinfo->arr[j]; + ntype = n->n_type; k = 0; /* Amount of predecessors for y */ - SLIST_FOREACH(cnode, &n->bb->parents, cfgelem) + SLIST_FOREACH(cnode, &y->parents, cfgelem) k++; - /* Construct phi(...) */ - p = mklnode(TEMP, i, 0, ntype); - for (l = 0; l < k-1; l++) - p = mkbinode(PHI, p, - mklnode(TEMP, i, 0, ntype), ntype); - ip = ipnode(mkbinode(ASSIGN, - mklnode(TEMP, i, 0, ntype), p, ntype)); - /* Insert phi at top of basic block */ - DLIST_INSERT_BEFORE(((struct interpass*)&n->bb->first), ip, qelem); - n->bb->first = ip; + /* Construct phi(...) + */ + + phifound=0; + + SLIST_FOREACH(phi, &y->phi, phielem) { + if (phi->tmpregno==i+defsites.low) + phifound++; + } + + if (phifound==0) { + if (b2debug) + printf("Phi in %d (%p) for %d\n",y->dfnum,y,i+defsites.low); + + phi = tmpcalloc(sizeof(struct phiinfo)); + + phi->tmpregno=i+defsites.low; + phi->size=k; + phi->n_type=ntype; + phi->intmpregno=tmpcalloc(k*sizeof(int)); + + SLIST_INSERT_LAST(&y->phi,phi,phielem); + } else { + if (b2debug) + printf("Phi already in %d for %d\n",y->dfnum,i+defsites.low); + } + BITSET(bbinfo->arr[j]->Aphi, i); if (!TESTBIT(bbinfo->arr[j]->Aorig, i)) { pv = tmpalloc(sizeof(struct pvarinfo)); - // XXXpj Ej fullst?ndig information. - pv->bb = bbinfo->arr[j]; - pv->next = defsites.arr[i]->next; + pv->bb = y; + pv->n_type=ntype; + pv->next = defsites.arr[i]; defsites.arr[i] = pv; } @@ -798,18 +892,232 @@ } } +/* Helper function for renamevar. */ +static void +renamevarhelper(struct p2env *p2e,NODE *t,void *poplistarg) +{ + SLIST_HEAD(, varstack) *poplist=poplistarg; + int opty; + int tempnr; + int newtempnr; + int x; + struct varstack *stacke; + + if (t->n_op == ASSIGN && t->n_left->n_op == TEMP) { + renamevarhelper(p2e,t->n_right,poplist); + + tempnr=regno(t->n_left)-defsites.low; + + newtempnr=p2e->epp->ip_tmpnum++; + regno(t->n_left)=newtempnr; + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=newtempnr; + SLIST_INSERT_FIRST(&defsites.stack[tempnr],stacke,varstackelem); + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=tempnr; + SLIST_INSERT_FIRST(poplist,stacke,varstackelem); + } else { + if (t->n_op == TEMP) { + tempnr=regno(t)-defsites.low; + + x=SLIST_FIRST(&defsites.stack[tempnr])->tmpregno; + regno(t)=x; + } + + opty = optype(t->n_op); + + if (opty != LTYPE) + renamevarhelper(p2e, t->n_left,poplist); + if (opty == BITYPE) + renamevarhelper(p2e, t->n_right,poplist); + } +} + + +void +renamevar(struct p2env *p2e,struct basicblock *bb, struct bblockinfo *bbinfo) +{ + struct interpass *ip; + int h,j; + SLIST_HEAD(, varstack) poplist; + struct varstack *stacke; + struct cfgnode *cfgn; + struct cfgnode *cfgn2; + int tmpregno,newtmpregno; + struct phiinfo *phi; + + SLIST_INIT(&poplist); + + SLIST_FOREACH(phi,&bb->phi,phielem) { + tmpregno=phi->tmpregno-defsites.low; + + newtmpregno=p2e->epp->ip_tmpnum++; + phi->newtmpregno=newtmpregno; + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=newtmpregno; + SLIST_INSERT_FIRST(&defsites.stack[tmpregno],stacke,varstackelem); + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=tmpregno; + SLIST_INSERT_FIRST(&poplist,stacke,varstackelem); + } + + + ip=bb->first; + + while (1) { + if ( ip->type == IP_NODE) { + renamevarhelper(p2e,ip->ip_node,&poplist); + } + + if (ip==bb->last) + break; + + ip = DLIST_NEXT(ip, qelem); + } + + SLIST_FOREACH(cfgn,&bb->children,cfgelem) { + j=0; + + SLIST_FOREACH(cfgn2, &cfgn->bblock->parents, cfgelem) { + if (cfgn2->bblock->dfnum==bb->dfnum) + break; + + j++; + } + + SLIST_FOREACH(phi,&cfgn->bblock->phi,phielem) { + phi->intmpregno[j]=SLIST_FIRST(&defsites.stack[phi->tmpregno-defsites.low])->tmpregno; + } + + } + + for (h = 1; h < bbinfo->size; h++) { + if (!TESTBIT(bb->dfchildren, h)) + continue; + + renamevar(p2e,bbinfo->arr[h], bbinfo); + } + + SLIST_FOREACH(stacke,&poplist,varstackelem) { + tmpregno=stacke->tmpregno; + + defsites.stack[tmpregno].q_forw=defsites.stack[tmpregno].q_forw->varstackelem.q_forw; + } +} + +void +removephi(struct p2env *p2e, struct labelinfo *labinfo,struct bblockinfo *bbinfo) +{ + struct basicblock *bb,*bbparent; + struct cfgnode *cfgn; + struct phiinfo *phi; + int i; + struct interpass *ip; + struct interpass *pip; + TWORD n_type; + int complex; + int label=0; + int newlabel; + + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { + SLIST_FOREACH(phi,&bb->phi,phielem) { // Look at only one, notice break at end + i=0; + + SLIST_FOREACH(cfgn, &bb->parents, cfgelem) { + bbparent=cfgn->bblock; + + pip=bbparent->last; + + complex = 0; + + BDEBUG(("removephi: %p in %d",pip,bb->dfnum)); + if (pip->type == IP_NODE && pip->ip_node->n_op == GOTO) { + BDEBUG((" GOTO ")); + label=pip->ip_node->n_left->n_lval; + complex=1; + } else if (pip->type == IP_NODE && pip->ip_node->n_op == CBRANCH) { + BDEBUG((" CBRANCH ")); + label=pip->ip_node->n_right->n_lval; + + if (bb==labinfo->arr[label - p2e->ipp->ip_lblnum]) + complex=2; + } + + BDEBUG((" Complex: %d\n",complex)); + + if (complex > 0) { + /* + This destroys basic block calculations. + Maybe it shoud not + */ + ip = ipnode(mkunode(GOTO, mklnode(ICON, label, 0, INT), 0, INT)); + DLIST_INSERT_BEFORE((bb->first), ip, qelem); + + newlabel=getlab2(); + + ip = tmpalloc(sizeof(struct interpass)); + ip->type = IP_DEFLAB; + // Line number?? ip->lineno; + ip->ip_lbl = newlabel; + DLIST_INSERT_BEFORE((bb->first), ip, qelem); + + SLIST_FOREACH(phi,&bb->phi,phielem) { + if (phi->intmpregno[i]>0) { + n_type=phi->n_type; + ip = ipnode(mkbinode(ASSIGN, + mktemp(phi->newtmpregno, n_type), + mktemp(phi->intmpregno[i],n_type), + n_type)); + + DLIST_INSERT_BEFORE((bb->first), ip, qelem); + } + } + + if (complex==1) + pip->ip_node->n_left->n_lval=newlabel; + + if (complex==2) + pip->ip_node->n_right->n_lval=newlabel; + + } else { + /* Construct move */ + SLIST_FOREACH(phi,&bb->phi,phielem) { + if (phi->intmpregno[i]>0) { + n_type=phi->n_type; + ip = ipnode(mkbinode(ASSIGN, + mktemp(phi->newtmpregno, n_type), + mktemp(phi->intmpregno[i],n_type), + n_type)); + + /* Insert move at bottom of parent basic block */ + DLIST_INSERT_AFTER((bbparent->last), ip, qelem); + } + } + } + i++; + } + break; + } + } +} + + /* * Remove unreachable nodes in the CFG. */ void -remunreach(void) +remunreach(struct p2env *p2e) { struct basicblock *bb, *nbb; struct interpass *next, *ctree; - bb = DLIST_NEXT(&bblocks, bbelem); - while (bb != &bblocks) { + bb = DLIST_NEXT(&p2e->bblocks, bbelem); + while (bb != &p2e->bblocks) { nbb = DLIST_NEXT(bb, bbelem); /* Code with dfnum 0 is unreachable */ @@ -848,7 +1156,8 @@ static char *foo[] = { 0, "NODE", "PROLOG", "STKOFF", "EPILOG", "DEFLAB", "DEFNAM", "ASM" }; struct interpass *ip; - struct interpass_prolog *ipp, *epp; + struct interpass_prolog *ipplg, *epplg; + unsigned i; DLIST_FOREACH(ip, pole, qelem) { if (ip->type > MAXIP) @@ -857,20 +1166,28 @@ printf("%s (%p): ", foo[ip->type], ip); switch (ip->type) { case IP_NODE: printf("\n"); +#ifdef PCC_DEBUG fwalk(ip->ip_node, e2print, 0); break; +#endif case IP_PROLOG: - ipp = (struct interpass_prolog *)ip; - printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", - ipp->ipp_name, ipp->ipp_vis ? "(local)" : "", - ipp->ipp_regs, ipp->ipp_autos, ipp->ip_tmpnum, - ipp->ip_lblnum); + ipplg = (struct interpass_prolog *)ip; + printf("%s %s regs", + ipplg->ipp_name, ipplg->ipp_vis ? "(local)" : ""); + for (i = 0; i < NIPPREGS; i++) + printf("%s0x%x", i? ":" : " ", + ipplg->ipp_regs[i]); + printf(" autos %d mintemp %d minlbl %d\n", + ipplg->ipp_autos, ipplg->ip_tmpnum, ipplg->ip_lblnum); break; case IP_EPILOG: - epp = (struct interpass_prolog *)ip; - printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", - epp->ipp_name, epp->ipp_vis ? "(local)" : "", - epp->ipp_regs, epp->ipp_autos, epp->ip_tmpnum, - epp->ip_lblnum); + epplg = (struct interpass_prolog *)ip; + printf("%s %s regs", + epplg->ipp_name, epplg->ipp_vis ? "(local)" : ""); + for (i = 0; i < NIPPREGS; i++) + printf("%s0x%x", i? ":" : " ", + epplg->ipp_regs[i]); + printf(" autos %d mintemp %d minlbl %d\n", + epplg->ipp_autos, epplg->ip_tmpnum, epplg->ip_lblnum); break; case IP_DEFLAB: printf(LABFMT "\n", ip->ip_lbl); break; case IP_DEFNAM: printf("\n"); break; Index: protos.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/protos.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/protos.h -L usr.bin/pcc/mip/protos.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/protos.h +++ usr.bin/pcc/mip/protos.h @@ -1,24 +1,9 @@ -struct optab; -struct symtab; -struct sw; - -void cerror(char *s, ...); -void werror(char *s, ...); -void uerror(char *s, ...); -void reclaim(NODE *p, int, int); -void walkf(NODE *, void (*f)(NODE *)); -void allchk(void); -void tfree(NODE *); int tshape(NODE *, int); -void prtdcon(NODE *p); -void tinit(void); void tcheck(void); void mkdope(void); -int tshape(NODE *p, int shape); int shtemp(NODE *p); int flshape(NODE *p); -int shumul(NODE *p); int ttype(TWORD t, int tword); void expand(NODE *, int, char *); void hopcode(int, int); @@ -26,58 +11,29 @@ void zzzcode(NODE *, int); void insput(NODE *); void upput(NODE *, int); -void econvert(NODE *); int andable(NODE *); int conval(NODE *, int, NODE *); int ispow2(CONSZ); void defid(NODE *q, int class); -int getlab(void); void ftnend(void); void efcode(void); void dclargs(void); -void fixarg(struct symtab *); void cendarg(void); -void defalign(int); int fldal(unsigned int); -void vfdzero(int); -void zecode(int); -void putbyte(int v); +int fldexpand(NODE *, int, char **); void ecomp(NODE *p); -void cinit(NODE *, int); void bccode(void); int upoff(int size, int alignment, int *poff); -void fldty(struct symtab *p); void nidcl(NODE *p, int class); int noinit(void); void eprint(NODE *, int, int *, int *); int uclass(int class); -int fixclass(int, TWORD type); -void lineid(int, char *); -void mycanon(NODE *); -void delay(NODE *); -int delay1(NODE *); -void delay2(NODE *); void setregs(void); -int autoincr(NODE *); -int deltest(NODE *); -void canon(NODE *); -void order(NODE *, int); int tlen(NODE *p); -int setincr(NODE *); int setbin(NODE *); -void stoarg(NODE *p, int); -void constore(NODE *); -void markcall(NODE *); -void oreg2(NODE *p); int notoff(TWORD, int, CONSZ, char *); -void bycode(int, int); -void pstab(char *, int); -void psline(void); int notlval(NODE *); -int icons(NODE *); void ecode(NODE *p); int yylex(void); void yyerror(char *s); void p2tree(NODE *p); -int rewfld(NODE *p); -int freetemp(int k); Index: ccconfig.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccconfig.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccconfig.h -L usr.bin/pcc/ccconfig.h -u -r1.1 -r1.2 --- usr.bin/pcc/ccconfig.h +++ usr.bin/pcc/ccconfig.h @@ -1,43 +1,129 @@ +/* $Id: ccconfig.h,v 1.4 2008/07/18 06:53:48 gmcgarry Exp $ */ /*- - * Copyright (c) 2007 Lucas Holt - * Copyright (c) 2007 David O'Brien - * Copyright (c) 2007 Ed Schouten - * All rights reserved. + * Copyright (c) 2007, 2008 + * Thorsten Glaser * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. + * Provided that these terms and disclaimer and all copyright notices + * are retained or reproduced in an accompanying document, permission + * is granted to deal in this work without restriction, including un- + * limited rights to use, publicly perform, distribute, sell, modify, + * merge, give away, or sublicence. * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. + * This work is provided "AS IS" and WITHOUT WARRANTY of any kind, to + * the utmost extent permitted by applicable law, neither express nor + * implied; without malicious intent or gross negligence. In no event + * may a licensor, author or contributor be held liable for indirect, + * direct, other damage, loss, or other issues arising in any way out + * of dealing in the work, even if advised of the possibility of such + * damage or existence of a defect, except proven that it results out + * of said person's immediate fault when using the work as intended. */ -#define CPPADD { "-D__MidnightBSD__", "-D__ELF__", "-D__unix__=1", "-D__unix=1", "-D__STDC__=1", NULL, } -#define DYNLINKER { "-dynamic-linker", "/libexec/ld-elf.so.1", NULL } -#define CRT0FILE "/usr/lib/crt1.o" -#define STARTFILES { "/usr/lib/crti.o", "/usr/lib/crtbegin.o", NULL } -#define ENDFILES { "/usr/lib/crtend.o", "/usr/lib/crtn.o", NULL } -#define STARTLABEL "_start" +/** + * Configuration for pcc on a MidnightBSD (amd64, i386 or sparc64) target + */ -#if defined(mach_i386) || defined(mach_x86) -#define CPPMDADD { "-D__i386__", "-D__i386", NULL, } -#else -#error defines for arch missing +/* === mi part === */ + +#ifndef LIBDIR +#define LIBDIR "/usr/lib/" #endif +/* cpp MI defines */ +#define CPPADD { \ + "-D__MidnightBSD__", \ + "-D__FreeBSD__", \ + "-D__unix__", \ + "-D__unix", \ + "-Dunix", \ + "-D__ELF__", \ + "-D_LONGLONG", \ + NULL \ +} + +/* for dynamically linked binaries */ +#define DYNLINKER { \ + "-dynamic-linker", \ + "/libexec/ld-elf.so.1", \ + NULL \ +} +#define STARTFILES { \ + LIBDIR "crti.o", \ + LIBDIR "crtbegin.o", \ + NULL \ +} +#define ENDFILES { \ + LIBDIR "crtend.o", \ + LIBDIR "crtn.o", \ + NULL \ +} + +/* for shared libraries */ +#define STARTFILES_S { \ + LIBDIR "crti.o", \ + LIBDIR "crtbeginS.o", \ + NULL \ +} +#define ENDFILES_S { \ + LIBDIR "crtendS.o", \ + LIBDIR "crtn.o", \ + NULL \ +} + +/* for statically linked binaries */ +#define STARTFILES_T { \ + LIBDIR "crti.o", \ + LIBDIR "crtbeginT.o", \ + NULL \ +} +#define ENDFILES_T { \ + LIBDIR "crtend.o", \ + LIBDIR "crtn.o", \ + NULL \ +} + +#define LIBCLIBS { \ + "-lc", \ + NULL \ +} +#define LIBCLIBS_PROFILE { \ + "-lc_p", \ + NULL \ +} + + +/* C run-time startup */ +#define CRT0FILE LIBDIR "crt1.o" +#define CRT0FILE_PROFILE LIBDIR "gcrt1.o" +#define STARTLABEL "_start" + +/* debugging info */ #define STABS +/* === md part === */ + +#if defined(mach_i386) +#define CPPMDADD { \ + "-D__i386__", \ + "-D__i386", \ + "-Di386", \ + NULL, \ +} +#elif defined(mach_sparc64) +#define CPPMDADD { \ + "-D__sparc64__", \ + "-D__sparc_v9__", \ + "-D__sparcv9", \ + "-D__sparc__", \ + "-D__sparc", \ + "-Dsparc", \ + "-D__arch64__", \ + "-D__LP64__", \ + "-D_LP64", \ + NULL, \ +} +#elif defined(mach_amd64) +#error pcc does not support amd64 yet +#else +#error this architecture is not supported by MidnightBSD +#endif Index: config.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/config.h,v retrieving revision 1.3 retrieving revision 1.4 diff -L usr.bin/pcc/config.h -L usr.bin/pcc/config.h -u -r1.3 -r1.4 --- usr.bin/pcc/config.h +++ usr.bin/pcc/config.h @@ -1,6 +1,21 @@ /* config.h. Generated from config.h.in by configure. */ /* config.h.in. Generated from configure.ac by autoheader. */ +/* Using a.out ABI */ +/* #undef AOUTABI */ + +/* Define path to alternate assembler */ +/* #undef ASSEMBLER */ + +/* Using Classic 68k ABI */ +/* #undef CLASSIC68K */ + +/* Using COFF ABI */ +/* #undef COFFABI */ + +/* Define path to alternate preprocessor */ +/* #undef COMPILER */ + /* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP systems. This function is required for `alloca.c' support on those systems. */ @@ -9,6 +24,12 @@ /* Define to 1 if using `alloca.c'. */ /* #undef C_ALLOCA */ +/* Using ECOFF ABI */ +/* #undef ECOFFABI */ + +/* Using ELF ABI */ +#define ELFABI + /* Define to 1 if you have `alloca', as a function or macro. */ #define HAVE_ALLOCA 1 @@ -16,30 +37,38 @@ */ /* #undef HAVE_ALLOCA_H */ -/* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ -/* #undef HAVE_DOPRNT */ +/* Define to 1 if you have the `basename' function. */ +#define HAVE_BASENAME 1 + +/* Define to 1 if printf supports C99 size specifiers */ +#define HAVE_C99_FORMAT 1 + +/* Define to 1 if your compiler supports C99 variadic macros */ +#define HAVE_CPP_VARARG_MACRO_GCC 1 -/* Define to 1 if you have the header file. */ -/* #undef HAVE_FCNTL_H */ +/* Define to 1 if you have the `ffs' function. */ +#define HAVE_FFS 1 -/* Define to 1 if you have the `fork' function. */ -/* #undef HAVE_FORK */ +/* Define to 1 if you have the `getopt' function. */ +#define HAVE_GETOPT 1 /* Define to 1 if you have the header file. */ #define HAVE_INTTYPES_H 1 -/* Define to 1 if your system has a GNU libc compatible `malloc' function, and - to 0 otherwise. */ -/* #undef HAVE_MALLOC */ +/* Define to 1 if you have the header file. */ +#define HAVE_LIBGEN_H 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_MALLOC_H */ /* Define to 1 if you have the header file. */ #define HAVE_MEMORY_H 1 -/* Define to 1 if you have the `memset' function. */ -/* #undef HAVE_MEMSET */ +/* Define to 1 if you have the `mkstemp' function. */ +#define HAVE_MKSTEMP 1 -/* Define to 1 if stdbool.h conforms to C99. */ -/* #undef HAVE_STDBOOL_H */ +/* Define to 1 if you have the `snprintf' function. */ +#define HAVE_SNPRINTF 1 /* Define to 1 if you have the header file. */ #define HAVE_STDINT_H 1 @@ -47,27 +76,17 @@ /* Define to 1 if you have the header file. */ #define HAVE_STDLIB_H 1 -/* Define to 1 if you have the `strchr' function. */ -/* #undef HAVE_STRCHR */ -#define HAVE_STRCHR 1 - -/* Define to 1 if you have the `strdup' function. */ -/* #undef HAVE_STRDUP */ -#define HAVE_STRDUP 1 - /* Define to 1 if you have the header file. */ #define HAVE_STRINGS_H 1 /* Define to 1 if you have the header file. */ #define HAVE_STRING_H 1 -/* Define to 1 if you have the `strrchr' function. */ -/* #undef HAVE_STRRCHR */ -#define HAVE_STRRCHR 1 - -/* Define to 1 if you have the `strtol' function. */ -/* #undef HAVE_STRTOL */ -#define HAVE_STRTOL 1 +/* Define to 1 if you have the `strlcat' function. */ +#define HAVE_STRLCAT 1 + +/* Define to 1 if you have the `strlcpy' function. */ +#define HAVE_STRLCPY 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_STAT_H 1 @@ -76,51 +95,61 @@ #define HAVE_SYS_TYPES_H 1 /* Define to 1 if you have that is POSIX.1 compatible. */ -/* #undef HAVE_SYS_WAIT_H */ +#define HAVE_SYS_WAIT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_UNISTD_H 1 -/* Define to 1 if you have the `vfork' function. */ -/* #undef HAVE_VFORK */ -#define HAVE_VFORK 1 +/* Define to 1 if you have the `vsnprintf' function. */ +#define HAVE_VSNPRINTF 1 -/* Define to 1 if you have the header file. */ -/* #undef HAVE_VFORK_H */ +/* Define if host is BIG endian */ +/* #undef HOST_BIG_ENDIAN */ -/* Define to 1 if you have the `vprintf' function. */ -/* #undef HAVE_VPRINTF */ -#define HAVE_VPRINTF 1 +/* Define if host is LITTLE endian */ +#define HOST_LITTLE_ENDIAN -/* Define to 1 if `fork' works. */ -/* #undef HAVE_WORKING_FORK */ +/* lex is flex */ +#define ISFLEX 1 -/* Define to 1 if `vfork' works. */ -/* #undef HAVE_WORKING_VFORK */ +/* Define alternate standard lib directory */ +/* #undef LIBDIR */ -/* Define to 1 if the system has the type `_Bool'. */ -/* #undef HAVE__BOOL */ +/* Define path to alternate linker */ +/* #undef LINKER */ -/* Name of package */ -/* #undef PACKAGE */ +/* Using Mach-O ABI */ +/* #undef MACHOABI */ /* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "BUG-REPORT-ADDRESS" +#define PACKAGE_BUGREPORT "" /* Define to the full name of this package. */ #define PACKAGE_NAME "pcc" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "pcc 0.9.8" +#define PACKAGE_STRING "pcc 0.9.9" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "pcc" /* Define to the version of this package. */ -#define PACKAGE_VERSION "0.9.8" +#define PACKAGE_VERSION "0.9.9" + +/* Major version no */ +#define PCC_MAJOR 0 -/* Define as the return type of signal handlers (`int' or `void'). */ -/* #undef RETSIGTYPE */ +/* Minor version no */ +#define PCC_MINOR 9 + +/* Minor minor version no */ +#define PCC_MINORMINOR 9 + +/* Using PE/COFF ABI */ +/* #undef PECOFFABI */ + +/* Define path to alternate preprocessor */ +/* #undef PREPROCESSOR */ /* If using the C implementation of alloca, define if you know the direction of stack growth for your system; otherwise it will be @@ -133,30 +162,24 @@ /* Define to 1 if you have the ANSI C header files. */ #define STDC_HEADERS 1 -/* Version number of package */ -#define PCC_MAJOR 0 -#define PCC_MINOR 9 -#define PCC_MINORMINOR 8 -#define VERSSTR "pcc 0.9.8 for i386-unknown-midnightbsd0.2, laffer1 at m5.midnightbsd.org Wed Sep 26 15:13:33 EDT 2007" - -/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a - `char[]'. */ -#define YYTEXT_POINTER 1 - -/* Define to rpl_malloc if the replacement function should be used. */ -/* #undef malloc */ +/* Define alternate standard include directory */ +/* #undef STDINC */ -/* Define to `int' if does not define. */ -/* #undef pid_t */ +/* Define if target defaults to BIG endian */ +/* #undef TARGET_BIG_ENDIAN */ -/* Define as `fork' if `vfork' does not work. */ -/* #undef vfork */ +/* Define if target defaults to LITTLE endian */ +#define TARGET_LITTLE_ENDIAN 1 -/* target operating system */ +/* Target OS */ #define TARGOS midnightbsd -/* mkstemp() */ -#define HAVE_MKSTEMP 1 +/* Enable thread-local storage (TLS). */ +/* #undef TLS */ -/* which lex is used */ -#define ISFLEX 1 +/* Version string */ +#define VERSSTR "pcc 0.9.9 for i386-unknown-midnightbsd0.3, root at defiant.midnightbsd.org Tue Jan 20 15:33:42 EST 2009" + +/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a + `char[]'. */ +#define YYTEXT_POINTER 1 --- /dev/null +++ usr.bin/pcc/sparc64/order.c @@ -0,0 +1,112 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass2.h" + +int +notoff(TWORD t, int r, CONSZ off, char *cp) +{ + return 0; +} + +/* + * Turn a UMUL-referenced node into OREG. + */ +void +offstar(NODE *p, int shape) +{ + if (x2debug) + printf("offstar(%p)\n", p); + + if (p->n_op == PLUS || p->n_op == MINUS) { + if (p->n_right->n_op == ICON) { + if (isreg(p->n_left) == 0) + (void)geninsn(p->n_left, INAREG); + /* Converted in ormake() */ + return; + } + } + (void)geninsn(p, INAREG); +} + +void +myormake(NODE *q) +{ +} + +int +shumul(NODE *p, int shape) +{ + if (shape & SOREG) + return SROREG; + return SRNOPE; +} + +int +setbin(NODE *p) +{ + return 0; +} + +int +setasg(NODE *p, int cookie) +{ + return 0; +} + +int +setuni(NODE *p, int cookie) +{ + return 0; +} + +struct rspecial * +nspecial(struct optab *q) +{ + switch (q->op) { + case STASG: { + static struct rspecial s[] = { + { NEVER, O0 }, + { NRIGHT, O1 }, + { NEVER, O2 }, + { 0 } + }; + return s; + } + } + + comperr("unknown nspecial %d: %s", q - table, q->cstring); + return 0; /* XXX */ +} + +int +setorder(NODE *p) +{ + return 0; +} + +int * +livecall(NODE *p) +{ + static int ret[] = { O0, O1, O2, O3, O4, O5, O6, O7, -1 }; + return ret; +} + +int +acceptable(struct optab *op) +{ + return 1; +} --- /dev/null +++ usr.bin/pcc/sparc64/macdefs.h @@ -0,0 +1,267 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + + +/* + * Many arithmetic instructions take 'reg_or_imm' in SPARCv9, where imm + * means we can use a signed 13-bit constant (simm13). This gives us a + * shortcut for small constants, instead of loading them into a register. + * Special handling is required because 13 bits lies between SSCON and SCON. + */ +#define SIMM13(val) (val < 4096 && val > -4097) + +/* + * The SPARCv9 ABI specifies a stack bias of 2047 bits. This means that the + * end of our call space is %fp+V9BIAS, working back towards %sp+V9BIAS+176. + */ +#define V9BIAS 2047 + +/* + * The ABI requires that every frame reserve 176 bits for saving registers + * in the case of a spill. The stack size must be 16-bit aligned. + */ +#define V9RESERVE 176 +#define V9STEP(x) ALIGN(x, 0xf) +#define ALIGN(x, y) ((x & y) ? (x + y) & ~y : x) + + +#define makecc(val,i) lastcon = (lastcon<<8)|((val<<24)>>24); + +#define ARGINIT (7*8) /* XXX */ +#define AUTOINIT (0) + +/* Type sizes */ +#define SZCHAR 8 +#define SZBOOL 32 +#define SZINT 32 +#define SZFLOAT 32 +#define SZDOUBLE 64 +#define SZLDOUBLE 64 +#define SZLONG 64 +#define SZSHORT 16 +#define SZLONGLONG 64 +#define SZPOINT(t) 64 + +/* Type alignments */ +#define ALCHAR 8 +#define ALBOOL 32 +#define ALINT 32 +#define ALFLOAT 32 +#define ALDOUBLE 64 +#define ALLDOUBLE 64 +#define ALLONG 64 +#define ALLONGLONG 64 +#define ALSHORT 16 +#define ALPOINT 64 +#define ALSTRUCT 32 +#define ALSTACK 64 + +/* Min/max values. */ +#define MIN_CHAR -128 +#define MAX_CHAR 127 +#define MAX_UCHAR 255 +#define MIN_SHORT -32768 +#define MAX_SHORT 32767 +#define MAX_USHORT 65535 +#define MIN_INT -1 +#define MAX_INT 0x7fffffff +#define MAX_UNSIGNED 0xffffffff +#define MIN_LONGLONG 0x8000000000000000LL +#define MAX_LONGLONG 0x7fffffffffffffffLL +#define MAX_ULONGLONG 0xffffffffffffffffULL +#define MIN_LONG MIN_LONGLONG +#define MAX_LONG MAX_LONGLONG +#define MAX_ULONG MAX_ULONGLONG + +#define BOOL_TYPE INT +#define WCHAR_TYPE INT + +typedef long long CONSZ; +typedef unsigned long long U_CONSZ; +typedef long long OFFSZ; + +#define CONFMT "%lld" +#define LABFMT "L%d" +#define STABLBL "LL%d" + +#define BACKAUTO /* Stack grows negatively for automatics. */ +#define BACKTEMP /* Stack grows negatively for temporaries. */ + +#undef FIELDOPS +#define RTOLBYTES + +#define ENUMSIZE(high,low) INT +#define BYTEOFF(x) ((x)&03) +#define BITOOR(x) (x) + +#define szty(t) ((ISPTR(t) || (t) == DOUBLE || \ + (t) == LONG || (t) == ULONG || \ + (t) == LONGLONG || (t) == ULONGLONG) ? 2 : 1) + + +/* Register names. */ + +#define MAXREGS (31 + 31 + 16 + 2) +#define NUMCLASS 4 + +//define G0 -1 +#define G1 0 +#define G2 1 +#define G3 2 +#define G4 3 +#define G5 4 +#define G6 5 +#define G7 6 +#define O0 7 +#define O1 8 +#define O2 9 +#define O3 10 +#define O4 11 +#define O5 12 +#define O6 13 +#define O7 14 +#define L0 15 +#define L1 16 +#define L2 17 +#define L3 18 +#define L4 19 +#define L5 20 +#define L6 21 +#define L7 22 +#define I0 23 +#define I1 24 +#define I2 25 +#define I3 26 +#define I4 27 +#define I5 28 +#define I6 29 +#define I7 30 + +#define F0 31 +#define F1 32 +#define F2 33 +#define F3 34 +#define F4 35 +#define F5 36 +#define F6 37 +#define F7 38 +#define F8 39 +#define F9 40 +#define F10 41 +#define F11 42 +#define F12 43 +#define F13 44 +#define F14 45 +#define F15 46 +#define F16 47 +#define F17 48 +#define F18 49 +#define F19 50 +#define F20 51 +#define F21 52 +#define F22 53 +#define F23 54 +#define F24 55 +#define F25 56 +#define F26 57 +#define F27 58 +#define F28 59 +#define F29 60 +#define F30 61 +//define F31 XXX +#define D0 62 +#define D1 63 +#define D2 64 +#define D3 65 +#define D4 66 +#define D5 67 +#define D6 68 +#define D7 69 +#define D8 70 +#define D9 71 +#define D10 72 +#define D11 73 +#define D12 74 +#define D13 75 +#define D14 76 +#define D15 77 + +#define SP 78 +#define FP 79 + +#define FPREG FP + +#define RETREG(x) ((x)==DOUBLE ? D0 : (x)==FLOAT ? F1 : O0) +#define RETREG_PRE(x) ((x)==DOUBLE ? D0 : (x)==FLOAT ? F1 : I0) + +#define RSTATUS \ + /* global */ \ + SAREG|PERMREG, SAREG|PERMREG, SAREG|PERMREG, \ + SAREG|PERMREG, SAREG|PERMREG, SAREG|PERMREG, SAREG|PERMREG, \ + /* out */ \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + /* local */ \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + /* in */ \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + /* 32-bit floating point */ \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, /*, SBREG */ \ + /* 64-bit floating point */ \ + SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, \ + SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, \ + /* sp */ SDREG, \ + /* fp */ SDREG + +#define ROVERLAP \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ +/* 32-bit floating point */ \ + { D0, -1 }, { D0, -1 }, { D1, -1 }, { D1, -1 }, \ + { D2, -1 }, { D2, -1 }, { D3, -1 }, { D3, -1 }, \ + { D4, -1 }, { D4, -1 }, { D5, -1 }, { D5, -1 }, \ + { D6, -1 }, { D6, -1 }, { D7, -1 }, { D7, -1 }, \ + { D8, -1 }, { D8, -1 }, { D9, -1 }, { D9, -1 }, \ + { D10, -1 }, { D10, -1 }, { D11, -1 }, { D11, -1 }, \ + { D12, -1 }, { D12, -1 }, { D13, -1 }, { D13, -1 }, \ + { D14, -1 }, { D14, -1 }, { D15, -1 }, /* { D15, -1 }, */ \ +/* 64-bit floating point */ \ + { F0, F1, -1 }, { F2, F3, -1 }, { F4, F5, -1 }, \ + { F6, F7, -1 }, { F8, F9, -1 }, { F10, F11, -1 }, \ + { F12, F13, -1 }, { F14, F15, -1 }, { F16, F17, -1 }, \ + { F18, F19, -1 }, { F20, F21, -1 }, { F22, F23, -1 }, \ + { F24, F25, -1 }, { F26, F27, -1 }, { F28, F29, -1 }, \ + { F30, /* F31, */ -1 }, \ + { -1 }, \ + { -1 } + +#define GCLASS(x) (x <= I7 ? CLASSA : \ + (x <= F30 ? CLASSB : \ + (x <= D15 ? CLASSC : \ + (x == SP || x == FP ? CLASSD : 0)))) +#define PCLASS(p) (1 << gclass((p)->n_type)) +#define DECRA(x,y) (((x) >> (y*7)) & 127) +#define ENCRA(x,y) ((x) << (7+y*7)) +#define ENCRD(x) (x) + +int COLORMAP(int c, int *r); --- /dev/null +++ usr.bin/pcc/sparc64/table.c @@ -0,0 +1,963 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass2.h" + +#define TS64 TLONG|TLONGLONG +#define TU64 TULONG|TULONGLONG|TPOINT +#define T64 TS64|TU64 + +struct optab table[] = { + +{ -1, FOREFF, SANY, TANY, SANY, TANY, 0, 0, "", }, /* empty */ + +{ PCONV, INAREG, + SAREG, T64|TINT, + SAREG, T64, + 0, RLEFT, + " ! convert between word and pointer\n", }, + +/* Conversions. */ + +{ SCONV, INAREG, + SAREG, T64|TUNSIGNED, + SAREG, TINT, + NAREG|NASL, RESC1, + " sra AL,0,A1 \t\t! (u)int64/32 -> (u)int32\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED, + SAREG, TSHORT, + NAREG|NASL, RESC1, + " sll AL,16,A1 \t\t! (u)int64/32 -> int16\n" + " sra AL,16,A1\n" + " sra AL, 0,A1\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED, + SAREG, TUSHORT, + NAREG|NASL, RESC1, + " sll AL,16,A1 \t\t! (u)int64/32 -> uint16\n" + " srl AL,16,A1\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED|TSHORT|TUSHORT, + SAREG, TCHAR, + NAREG|NASL, RESC1, + " sll AL,24,A1 \t\t! (u)int64/32/16 -> int8\n" + " sra AL,24,A1\n" + " sra AL, 0,A1\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED|TSHORT|TUSHORT, + SAREG, TUCHAR, + NAREG|NASL, RESC1, + " and AL,0xff,A1 \t\t! (u)int64/32/16 -> uint8\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED|TSHORT|TUSHORT, + SAREG, T64, + 0, RLEFT, + " \t\t! (u)int64...8 -> (u)int64\n", }, + +{ SCONV, INAREG, + SAREG, TSHORT|TUSHORT|TCHAR|TUCHAR, + SAREG, TINT, + 0, RLEFT, + " \t\t! (u)int16/8 -> int32\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TSHORT|TCHAR, + SAREG, TUNSIGNED, + 0, RLEFT, + " srl AL, 0,A1 \t\t! int32/16/8 -> uint32\n", }, + +{ SCONV, INAREG, + SAREG, TUSHORT|TUCHAR, + SAREG, TUNSIGNED, + 0, RLEFT, + " \t\t! uint16/8 -> uint32\n", }, + +{ SCONV, INBREG, + SBREG, TINT|TUNSIGNED, + SBREG, TFLOAT, + NBREG|NASL, RESC1, + " fitos AL,A1 \t\t! (u)int32 -> float\n", }, + +{ SCONV, INBREG, + SBREG, T64, + SBREG, TFLOAT, + NBREG|NASL, RESC1, + " fxtos AL,A1 \t\t! (u)int64 -> float\n", }, + +{ SCONV, INCREG, + SCREG, TINT|TUNSIGNED, + SCREG, TDOUBLE, + NCREG|NASL, RESC1, + " fitod AL,A1 \t\t! (u)int32 -> double\n", }, + +{ SCONV, INCREG, + SCREG, T64, + SCREG, TDOUBLE, + NCREG|NASL, RESC1, + " fxtod AL,A1 \t\t! (u)int64 -> double\n", }, + + +/* Floating-point conversions must be stored and loaded. */ + +{ SCONV, INAREG, + SOREG, TFLOAT, + SAREG, TINT, + NAREG|(2*NBREG), RESC1, + " ld [AL],A2 \t\t! float -> int32\n" + " nop\n" + " fmovs A2,A3\n" + " fstoi A2,A2\n" + " st A2,[AL]\n" + " nop\n" + " ld [AL],A1\n" + " nop\n" + " st A3,[AL]\n" + " nop\n", }, + +{ SCONV, INAREG, + SOREG, TDOUBLE, + SAREG, TINT, + NAREG|(2*NCREG), RESC1, + " ld [AL],A2 \t\t! double -> int32\n" + " nop\n" + " fmovd A2,A3\n" + " fdtoi A2,A2\n" + " std A2,[AL]\n" + " nop\n" + " ldd [AL],A1\n" + " nop\n" + " std A3,[AL]\n" + " nop\n", }, + +{ SCONV, INBREG, + SOREG, T64|TUNSIGNED, + SBREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 \t\t! int64 -> float\n" + " fxtos A1,A1\n", }, + +{ SCONV, INBREG, + SOREG, TINT|TSHORT|TCHAR, + SBREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 \t\t! int32/16/8 -> float\n" + " fitos A1,A1\n", }, // XXX need 'lds', 'ldh', etc + +{ SCONV, INCREG, + SOREG, T64|TUNSIGNED, + SCREG, TDOUBLE, + NCREG, RESC1, + " ldd [AL],A1 \t\t! (u)int64 -> double\n" + " fxtod A1,A1\n", }, + +{ SCONV, INCREG, + SOREG, TINT|TSHORT|TCHAR, + SCREG, TDOUBLE, + NCREG, RESC1, + " ld [AL],A1 \t\t! int32/16/8 -> double\n" + " fitod A1,A1\n", }, // XXX need 'lds' 'ldh' 'ld', etc. + +{ SCONV, INBREG, + SCREG, TDOUBLE, + SBREG, TFLOAT, + NBREG, RESC1, + " fdtos AL,A1 \t\t! double -> float\n",}, + +{ SCONV, INCREG, + SBREG, TFLOAT, + SCREG, TDOUBLE, + NCREG, RESC1, + " fstod AL,A1 \t\t! float -> double\n",}, + +{ SCONV, INAREG, + SBREG, TFLOAT, + SAREG, TINT, + NAREG|NBREG, RESC1, + " fstoi AL,A2 \t\t! float -> int\n" + " st A2,[%fp+2047]\n" + " nop\n" + " ld [%fp+2047],A1\n" + " nop\n",}, + +{ SCONV, INAREG, + SCREG, TDOUBLE, + SAREG, TINT, + NAREG|NCREG, RESC1, + " fdtoi AL,A2 \t\t! double -> int\n" + " st A2,[%fp+2047]\n" + " nop\n" + " ld [%fp+2047],A1\n" + " nop\n",}, + + +/* Multiplication and division */ + +{ MUL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASR|NASL, RESC1, + " mulx AL,AR,A1 ! multiply\n", }, + +{ MUL, INBREG, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG|NBSR|NBSL, RESC1, + " fmuls AL,AR,A1 ! multiply float\n", }, + +{ MUL, INCREG, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG|NCSR|NCSL, RESC1, + " fmuld AL,AR,A1 ! multiply double\n", }, + +{ DIV, INAREG, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + NAREG|NASR|NASL, RESC1, + " udivx AL,AR,A1 ! unsigned division\n", }, + +{ DIV, INAREG, + SAREG, TINT|TSHORT|TCHAR|TS64, + SAREG, TINT|TSHORT|TCHAR|TS64, + NAREG|NASR|NASL, RESC1, + " sdivx AL,AR,A1 ! signed division\n", }, + +{ DIV, INBREG, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG|NBSR|NBSL, RESC1, + " fdivs AL,AR,A1 ! divide float\n", }, + +{ DIV, INCREG, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG|NCSR|NCSL, RESC1, + " fdivd AL,AR,A1 ! divide double\n", }, + +{ MOD, INAREG, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + NAREG, RESC1, + " udivx AL,AR,A1 ! unsigned modulo\n" + " mulx A1,AR,A1\n" + " sub AL,A1,A1\n", }, + +{ MOD, INAREG, + SAREG, TINT|TSHORT|TCHAR|TS64, + SAREG, TINT|TSHORT|TCHAR|TS64, + NAREG, RESC1, + " sdivx AL,AR,A1 ! signed modulo\n" + " mulx A1,AR,A1\n" + " sub AL,A1,A1\n", }, + +{ PLUS, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASL, RESC1, + " add AL,AR,A1\n", }, + +{ PLUS, INBREG, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG|NBSL, RESC1, + " fadds AL,AR,A1\n", }, + +{ PLUS, INCREG, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG|NCSL, RESC1, + " faddd AL,AR,A1\n", }, + +{ PLUS, INAREG, + SAREG, TANY, + SCON, TANY, + (3*NAREG)|NASL, RESC1, + "ZA", }, + +{ MINUS, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASL, RESC1, + " sub AL,AR,A1\n", }, + +{ MINUS, INBREG, + SBREG, TANY, + SBREG, TANY, + NBREG|NBSL|NBSR, RESC1, + " fsubs AL,AR,A1\n", }, + +{ MINUS, INCREG, + SCREG, TANY, + SCREG, TANY, + NCREG|NCSL|NBSR, RESC1, + " fsubd AL,AR,A1\n", }, + +{ MINUS, INAREG, + SAREG, TANY, + SCON, TANY, + (3*NAREG)|NASL, RESC1, + "ZB", }, + +{ UMINUS, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, + " sub %g0,AL,A1\n", }, + +{ UMINUS, INBREG, + SBREG, TANY, + SANY, TANY, + NBREG|NBSL, RESC1, + " fsubs %g0,AL,A1\n", }, + +{ UMINUS, INCREG, + SCREG, TANY, + SANY, TANY, + NCREG|NCSL, RESC1, + " fsubd %g0,AL,A1\n", }, + +/* Shifts */ + +{ RS, INAREG, + SAREG, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + SAREG|SCON, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " sra AL,AR,A1 ! shift right\n", }, + +{ RS, INAREG, + SAREG, T64, + SAREG|SCON, T64|TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " srax AL,AR,A1 ! shift right\n", }, + +{ LS, INAREG, + SAREG, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + SAREG|SCON, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " sll AL,AR,A1 ! shift left\n", }, + +{ LS, INAREG, + SAREG, T64, + SAREG|SCON, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " sllx AL,AR,A1 ! shift left\n", }, + +{ COMPL, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, + " orn AL,%g0,A1 ! complement\n", }, + +/* Assignments */ + +{ ASSIGN, FOREFF|INAREG, + SOREG, TINT|TUNSIGNED, + SAREG, TINT|TUNSIGNED, + 0, RDEST, + " stw AR,[AL] ! store (u)int32\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SOREG, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + 0, RDEST, + " sth AR,[AL] ! store (u)int16\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SOREG, TCHAR|TUCHAR, + SAREG, TCHAR|TUCHAR, + 0, RDEST, + " stb AR,[AL] ! store (u)int8\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SOREG, T64, + SAREG, T64, + 0, RDEST, + " stx AR,[AL] ! store (u)int64\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INBREG, + SOREG, TFLOAT, + SBREG, TFLOAT, + 0, RDEST, + " st AR,[AL] ! store float\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INBREG, + SOREG, TINT, + SBREG, TINT, + 0, RDEST, + " st AR,[AL] ! store int from fp address\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SOREG, TDOUBLE, + SCREG, TDOUBLE, + 0, RDEST, + " std AR,[AL] ! store double\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SOREG, TINT, + SCREG, TINT, + 0, RDEST, + " st AR,[AL] ! store int from fp address\n" + " nop\n", }, + + +{ ASSIGN, FOREFF|INAREG, + SNAME, TINT|TUNSIGNED, + SAREG, TINT|TUNSIGNED, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int32 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " stw AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SNAME, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int16 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " sth AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SNAME, TCHAR|TUCHAR, + SAREG, TCHAR|TUCHAR, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int8 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " stb AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SNAME, T64, + SAREG, T64, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int64 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " stx AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INBREG, + SNAME, TFLOAT|TINT, + SBREG, TFLOAT|TINT, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store float into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " st AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SNAME, TDOUBLE, + SCREG, TDOUBLE, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store double into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " std AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SNAME, TINT, + SCREG, TINT, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store int into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " st AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TANY, + SAREG, TANY, + 0, RDEST, + " mov AR,AL ! register move\n", }, + +{ ASSIGN, FOREFF|INBREG, + SBREG, TANY, + SBREG, TANY, + 0, RDEST, + " fmovs AR,AL ! move float\n", }, + +{ ASSIGN, FOREFF|INCREG, + SCREG, TANY, + SCREG, TANY, + 0, RDEST, + " fmovd AR,AL ! move double\n", }, + +/* Structure assignment. */ + +{ STASG, INAREG|FOREFF, + SOREG|SNAME, TANY, + SAREG, TPTRTO|TANY, + NSPECIAL, RRIGHT, + "ZQ", }, + +/* Comparisons. */ + +{ EQ, FORCC, + SAREG, TANY, + SAREG, TANY, + 0, RESCC, + " cmp AL,AR\n" + " be LC\n" + " nop\n", }, + +{ NE, FORCC, + SAREG, TANY, + SAREG, TANY, + 0, RESCC, + " cmp AL,AR\n" + " bne LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SAREG, TANY, + SZERO, TANY, + 0, RESCC, + " O AL,LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SAREG, TANY, + SAREG, TANY, + NAREG|NASL, RESCC, + " sub AL,AR,A1 ! oplog\n" + " O A1,LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SAREG, TANY, + SCCON, TANY, + NAREG|NASL, RESCC, + " sub AL,AR,A1 ! oplog sccon\n" + " O A1,LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG, RESCC, + " fcmps AL,AR ! oplog float\n" + " ZF LC\n", }, + +{ OPLOG, FORCC, + SOREG, TFLOAT, + SBREG, TFLOAT, + NBREG, RESCC, + " ld [AL], A1 ! oplog float oreg\n" + " nop\n" + " fcmps A1,AR\n" + " ZF LC\n", }, + +{ OPLOG, FORCC, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG, RESCC, + " fcmpd AL,AR ! oplog double\n" + " ZF LC\n", }, + +{ OPLOG, FORCC, + SOREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG, RESCC, + " ldd [AL], A1 ! oplog double oreg\n" + " nop\n" + " fcmpd A1,AR\n" + " ZF LC\n", }, + + +/* Load constants to register. */ + +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, T64, + NAREG, RESC1, + " sethi %h44(AL),A1\t ! load const (u)int64 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldx [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TINT, + NAREG, RESC1, + " sethi %h44(AL),A1\t ! load const int32 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldsw [A1+%l44(AL)],A1\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TUNSIGNED, + NAREG, RESC1, + " sethi %h44(AL),A1\t! load const uint32 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " lduw [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TSHORT, + NAREG, RESC1, + " sethi %h44(AL),A1\t! load const int16 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldsh [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TUSHORT, + NAREG, RESC1, + " sethi %h44(AL),A1\t ! load const uint16 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " lduh [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TCHAR, + NAREG, RESC1, + " sethi %h44(AL),A1\t\t! load const int8 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldsb [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TUCHAR, + NAREG, RESC1, + " sethi %h44(AL),A1\t! load const uint8 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldub [A1+%l44(AL)],A1\n" + " nop\n", }, + +{ OPLTYPE, INBREG, + SBREG, TANY, + SNAME, TANY, + NAREG|NBREG, RESC2, + " sethi %h44(AL),A1\t\t! load const to fp reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ld [A1+%l44(AL)],A2\n" + " nop\n", }, + +{ OPLTYPE, INCREG, + SCREG, TANY, + SNAME, TANY, + NAREG|NCREG, RESC2, + " sethi %h44(AL),A1\t\t! load const to fp reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldd [A1+%l44(AL)],A2\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SCON, TANY, + (2*NAREG), RESC1, + "ZC" }, + +/* Convert LTYPE to reg. */ + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TCHAR, + NAREG, RESC1, + " ldsb [AL],A1 ! load int8 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TUCHAR, + NAREG, RESC1, + " ldub [AL],A1 ! load uint8 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TSHORT, + NAREG, RESC1, + " ldsh [AL],A1 ! load int16 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TUSHORT, + NAREG, RESC1, + " lduh [AL],A1 ! load uint16 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TINT, + NAREG, RESC1, + " ldsw [AL],A1 ! load int32 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TUNSIGNED, + NAREG, RESC1, + " lduw [AL],A1 ! load uint32 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, T64, + NAREG, RESC1, + " ldx [AL],A1 ! load (u)int64 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SZERO, TANY, + NAREG, RESC1, + " mov \%g0,A1\t ! load 0 to reg\n", }, + +{ OPLTYPE, INBREG, + SBREG, TFLOAT, + SOREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 ! load float to reg\n" + " nop\n", }, + +{ OPLTYPE, INCREG, + SCREG, TDOUBLE, + SOREG, TDOUBLE, + NCREG, RESC1, + " ldd [AL],A1 ! load double to reg\n" + " nop\n", }, + +/* Jumps. */ + +{ GOTO, FOREFF, + SCON, TANY, + SANY, TANY, + 0, RNOP, + " call LL ! goto LL\n" + " nop\n", }, + +{ UCALL, FOREFF, + SCON, TANY, + SANY, TANY, + 0, 0, + " call CL ! void CL()\n" + " nop\n", }, + +{ UCALL, INAREG, + SCON, TANY, + SAREG, TANY, + NAREG, RESC1, + " call CL ! = CL()\n" + " nop\n", }, + +{ CALL, FOREFF, + SCON, TANY, + SANY, TANY, + 0, 0, + " call CL ! void CL(constant)\n" + " nop\n", }, + +{ CALL, INAREG, + SCON, TANY, + SAREG, TANY, + NAREG, RESC1, + " call CL ! = CL(constant)\n" + " nop\n", }, + +{ CALL, INBREG, + SCON, TANY, + SBREG, TFLOAT, + NBREG, RESC1, + " call CL ! = CL(constant)\n" + " nop\n", }, + +{ CALL, INCREG, + SCON, TANY, + SCREG, TDOUBLE, + NCREG, RESC1, + " call CL ! = CL(constant)\n" + " nop\n", }, + +{ CALL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG, RESC1, + " call AL ! = AL(args)\n" + " nop\n", }, + +{ CALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call AL ! void AL(args)\n" + " nop\n", }, + +{ UCALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call AL ! (*AL)()\n" + " nop\n", }, + +{ UCALL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG, RESC1, + " call AL ! = (*AL)()\n" + " nop\n", }, + +{ CALL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG, RESC1, + " call AL ! = (*AL)(args)\n" + " nop\n", }, + +/* Function arguments. */ + +{ FUNARG, FOREFF, + SAREG, T64, + SANY, TANY, + 0, 0, + " stx AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SAREG, TINT|TUNSIGNED, + SANY, TANY, + 0, 0, + " stw AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SAREG, TSHORT|TUSHORT, + SANY, TANY, + 0, 0, + " sth AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SAREG, TCHAR|TUCHAR, + SANY, TANY, + 0, 0, + " stb AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SBREG, TFLOAT, + SANY, TANY, + 0, 0, + " st AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SCREG, TDOUBLE, + SANY, TANY, + 0, 0, + " std AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + + +/* Indirection. */ + +{ OPSIMP, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASR|NASL, RESC1, + " O AL,AR,A1\n", }, + +{ UMUL, INAREG, + SANY, T64, + SOREG, T64, + NAREG, RESC1, + " ldx [AL],A1 ! (u)int64 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TINT, + SOREG, TINT, + NAREG, RESC1, + " ldsw [AL],A1 ! int32 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TUNSIGNED, + SOREG, TUNSIGNED, + NAREG, RESC1, + " lduw [AL],A1 ! uint32 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TCHAR, + SOREG, TCHAR, + NAREG, RESC1, + " ldsb [AL],A1 ! int8 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TUCHAR, + SOREG, TUCHAR, + NAREG, RESC1, + " ldub [AL],A1 ! uint8 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TSHORT, + SOREG, TSHORT, + NAREG, RESC1, + " ldsh [AL],A1 ! int16 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TUSHORT, + SOREG, TUSHORT, + NAREG, RESC1, + " lduh [AL],A1 ! uint16 load\n" + " nop\n", }, + +{ UMUL, INBREG, + SANY, TFLOAT, + SOREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 ! load float\n" + " nop\n", }, + +{ UMUL, INCREG, + SANY, TDOUBLE, + SOREG, TDOUBLE, + NCREG, RESC1, + " ldd [AL],A1 ! load double\n" + " nop\n", }, + +{ FREE,FREE,FREE,FREE,FREE,FREE,FREE,FREE, "ERR: printing free op\n" }, + +}; + +int tablesize = sizeof(table)/sizeof(table[0]); --- /dev/null +++ usr.bin/pcc/sparc64/local2.c @@ -0,0 +1,424 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass1.h" +#include "pass2.h" + + +char * +rnames[] = { + /* "\%g0", always zero, removed due to 31-element class limit */ + "\%g1", "\%g2", "\%g3", "\%g4", "\%g5", "\%g6", "\%g7", + "\%o0", "\%o1", "\%o2", "\%o3", "\%o4", "\%o5", "\%o6", "\%o7", + "\%l0", "\%l1", "\%l2", "\%l3", "\%l4", "\%l5", "\%l6", "\%l7", + "\%i0", "\%i1", "\%i2", "\%i3", "\%i4", "\%i5", "\%i6", "\%i7", + + "\%f0", "\%f1", "\%f2", "\%f3", "\%f4", "\%f5", "\%f6", "\%f7", + "\%f8", "\%f9", "\%f10", "\%f11", "\%f12", "\%f13", "\%f14", "\%f15", + "\%f16", "\%f17", "\%f18", "\%f19", "\%f20", "\%f21", "\%f22", "\%f23", + "\%f24", "\%f25", "\%f26", "\%f27", "\%f28", "\%f29", "\%f30", + /*, "\%f31" XXX removed due to 31-element class limit */ + + "\%f0", "\%f2", "\%f4", "\%f6", "\%f8", "\%f10", "\%f12", "\%f14", + "\%f16", "\%f18", "\%f20", "\%f22", "\%f24", "\%f26", "\%f28", "\%f30", + + "\%sp", "\%fp", +}; + +void +deflab(int label) +{ + printf(LABFMT ":\n", label); +} + +void +prologue(struct interpass_prolog *ipp) +{ + int i, stack; + + stack = V9RESERVE + V9STEP(p2maxautooff); + + for (i = ipp->ipp_regs[0]; i; i >>= 1) + if (i & 1) + stack += 16; + + /* TODO printf("\t.proc %d\n"); */ + printf("\t.global %s\n", ipp->ipp_name); + printf("\t.align 4\n"); + printf("%s:\n", ipp->ipp_name); + if (SIMM13(stack)) + printf("\tsave %%sp,-%d,%%sp\n", stack); + else { + printf("\tsetx -%d,%%g4,%%g1\n", stack); + printf("\tsave %%sp,%%g1,%%sp\n"); + } +} + +void +eoftn(struct interpass_prolog *ipp) +{ + printf("\tret\n"); + printf("\trestore\n"); + printf("\t.type %s,#function\n", ipp->ipp_name); + printf("\t.size %s,(.-%s)\n", ipp->ipp_name, ipp->ipp_name); +} + +void +hopcode(int f, int o) +{ + char *str; + + switch (o) { + case EQ: str = "brz"; break; + case NE: str = "brnz"; break; + case ULE: + case LE: str = "brlez"; break; + case ULT: + case LT: str = "brlz"; break; + case UGE: + case GE: str = "brgez"; break; + case UGT: + case GT: str = "brgz"; break; + case PLUS: str = "add"; break; + case MINUS: str = "sub"; break; + case AND: str = "and"; break; + case OR: str = "or"; break; + case ER: str = "xor"; break; + default: + comperr("unknown hopcode: %d (with %c)", o, f); + return; + } + + printf("%s%c", str, f); +} + +int +tlen(NODE *p) +{ + switch (p->n_type) { + case CHAR: + case UCHAR: + return 1; + case SHORT: + case USHORT: + return (SZSHORT / SZCHAR); + case FLOAT: + return (SZFLOAT / SZCHAR); + case DOUBLE: + return (SZDOUBLE / SZCHAR); + case INT: + case UNSIGNED: + return (SZINT / SZCHAR); + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + return SZLONGLONG / SZCHAR; + default: + if (!ISPTR(p->n_type)) + comperr("tlen type unknown: %d"); + return SZPOINT(p->n_type) / SZCHAR; + } +} + +void +zzzcode(NODE * p, int c) +{ + char *str; + NODE *l, *r; + l = p->n_left; + r = p->n_right; + + switch (c) { + + case 'A': /* Add const. */ + if (ISPTR(l->n_type) && l->n_rval == FP) + r->n_lval += V9BIAS; + + if (SIMM13(r->n_lval)) + expand(p, 0, "\tadd AL,AR,A1\t\t! add const\n"); + else + expand(p, 0, "\tsetx AR,A3,A2\t\t! add const\n" + "\tadd AL,A2,A1\n"); + break; + case 'B': /* Subtract const. */ + if (ISPTR(l->n_type) && l->n_rval == FP) + r->n_lval -= V9BIAS; + + if (SIMM13(r->n_lval)) + expand(p, 0, "\tsub AL,AR,A1\t\t! subtract const\n"); + else + expand(p, 0, "\tsetx AR,A3,A2\t\t! subtract const\n" + "\tsub AL,A2,A1\n"); + break; + case 'C': /* Load constant to register. */ + if (ISPTR(p->n_type)) + expand(p, 0, + "\tsethi %h44(AL),A1\t\t! load label\n" + "\tor A1,%m44(AL),A1\n" + "\tsllx A1,12,A1\n" + "\tor A1,%l44(AL),A1\n"); + else if (SIMM13(p->n_lval)) + expand(p, 0, "\tor %g0,AL,A1\t\t\t! load const\n"); + else + expand(p, 0, "\tsetx AL,A2,A1\t\t! load const\n"); + break; + case 'F': /* Floating-point comparison, cf. hopcode(). */ + switch (p->n_op) { + case EQ: str = "fbe"; break; + case NE: str = "fbne"; break; + case ULE: + case LE: str = "fbule"; break; + case ULT: + case LT: str = "fbul"; break; + case UGE: + case GE: str = "fbuge"; break; + case UGT: + case GT: str = "fbug"; break; + /* XXX + case PLUS: str = "add"; break; + case MINUS: str = "sub"; break; + case AND: str = "and"; break; + case OR: str = "or"; break; + case ER: str = "xor"; break;*/ + default: + comperr("unknown float code: %d", p->n_op); + return; + } + printf(str); + break; + + case 'Q': /* Structure assignment. */ + /* TODO Check if p->n_stsize is small and use a few ldx's + to move the struct instead of memcpy. The equiv. + could be done on all the architectures. */ + if (l->n_rval != O0) + printf("\tmov %s,%s\n", rnames[l->n_rval], rnames[O0]); + if (SIMM13(p->n_stsize)) + printf("\tor %%g0,%d,%%o2\n", p->n_stsize); + else + printf("\tsetx %d,%%g1,%%o2\n", p->n_stsize); + printf("\tcall memcpy\t\t\t! struct assign (dest, src, len)\n"); + printf("\tnop\n"); + break; + default: + cerror("unknown zzzcode call: %c", c); + } +} + +int +rewfld(NODE * p) +{ + return (1); +} + +int +fldexpand(NODE *p, int cookie, char **cp) +{ + printf("XXX fldexpand called\n"); /* XXX */ + return 1; +} + +int +flshape(NODE * p) +{ + return SRREG; +} + +int +shtemp(NODE * p) +{ + return 0; +} + + +void +adrcon(CONSZ val) +{ +} + +void +conput(FILE * fp, NODE * p) +{ + if (p->n_op != ICON) { + comperr("conput got bad op: %s", copst(p->n_op)); + return; + } + + if (p->n_name[0] != '\0') { + fprintf(fp, "%s", p->n_name); + if (p->n_lval > 0) + fprintf(fp, "+"); + if (p->n_lval) + fprintf(fp, "%lld", p->n_lval); + } else + fprintf(fp, CONFMT, p->n_lval); +} + +void +insput(NODE * p) +{ + comperr("insput"); +} + +void +upput(NODE *p, int size) +{ + comperr("upput"); +} + +void +adrput(FILE * io, NODE * p) +{ + int64_t off; + + if (p->n_op == FLD) { + printf("adrput a FLD\n"); + p = p->n_left; + } + + if (p->n_op == UMUL && p->n_right == 0) + p = p->n_left; + + off = p->n_lval; + + switch (p->n_op) { + case NAME: + if (p->n_name[0] != '\0') + fputs(p->n_name, io); + if (off > 0) + fprintf(io, "+"); + if (off != 0) + fprintf(io, CONFMT, off); + return; + case OREG: + fprintf(io, "%s", rnames[p->n_rval]); + if (p->n_rval == FP) + off += V9BIAS; + if (p->n_rval == SP) + off += V9BIAS + V9RESERVE; + if (off > 0) + fprintf(io, "+"); + if (off) + fprintf(io, "%lld", off); + return; + case ICON: + /* addressable value of the constant */ + conput(io, p); + return; + case REG: + fputs(rnames[p->n_rval], io); + return; + case FUNARG: + /* We do something odd and store the stack offset in n_rval. */ + fprintf(io, "%d", V9BIAS + V9RESERVE + p->n_rval); + return; + default: + comperr("bad address, %s, node %p", copst(p->n_op), p); + return; + } +} + +void +cbgen(int o, int lab) +{ +} + +void +myreader(struct interpass * ipole) +{ +} + +void +mycanon(NODE * p) +{ +} + +void +myoptim(struct interpass * ipole) +{ +} + +void +rmove(int s, int d, TWORD t) +{ + printf("\t"); + + if (t == FLOAT) printf("fmovs"); + else if (t == DOUBLE) printf("fmovd"); + else printf("mov"); + + printf(" %s,%s\t\t\t! rmove()\n", rnames[s], rnames[d]); +} + +int +gclass(TWORD t) +{ + if (t == FLOAT) + return CLASSB; + if (t == DOUBLE) + return CLASSC; + return CLASSA; +} + +void +lastcall(NODE *p) +{ +} + +int +special(NODE *p, int shape) +{ + return SRNOPE; +} + +void mflags(char *str) +{ +} + +int +COLORMAP(int c, int *r) +{ + int num=0; + + switch (c) { + case CLASSA: + num += r[CLASSA]; + return num < 32; + case CLASSB: + num += r[CLASSB]; + num += 2*r[CLASSC]; + return num < 32;; + case CLASSC: + num += r[CLASSC]; + num += 2*r[CLASSB]; + return num < 17; + case CLASSD: + return 0; + default: + comperr("COLORMAP: unknown class: %d", c); + return 0; + } +} +/* + * Do something target-dependent for xasm arguments. + * Supposed to find target-specific constraints and rewrite them. + */ +int +myxasm(struct interpass *ip, NODE *p) +{ + return 0; +} --- /dev/null +++ usr.bin/pcc/sparc64/code.c @@ -0,0 +1,237 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass1.h" + +void +defloc(struct symtab *sp) +{ + static char *loctbl[] = { "text", "data", "rodata" }; + static int lastloc = -1; + TWORD t; + int s; + + t = sp->stype; + s = ISFTN(t) ? PROG : ISCON(cqual(t, sp->squal)) ? RDATA : DATA; + if (s != lastloc) + printf("\n\t.section \".%s\"\n", loctbl[s]); + lastloc = s; + if (s == PROG) + return; + + switch (DEUNSIGN(sp->stype)) { + case CHAR: s = 1; + case SHORT: s = 2; + case INT: + case UNSIGNED: s = 4; + default: s = 8; + } + printf("\t.align %d\n", s); + + if (sp->sclass == EXTDEF) + printf("\t.global %s\n", sp->soname); + if (sp->slevel == 0) { + printf("\t.type %s,#object\n", sp->soname); + printf("\t.size %s," CONFMT "\n", sp->soname, + tsize(sp->stype, sp->sdf, sp->ssue) / SZCHAR); + printf("%s:\n", sp->soname); + } else + printf(LABFMT ":\n", sp->soffset); +} + +void +efcode() +{ + /* XXX */ +} + +void +bfcode(struct symtab **sp, int cnt) +{ + int i, off; + NODE *p, *q; + struct symtab *sym; + + /* Process the first six arguments. */ + for (i=0; i < cnt && i < 6; i++) { + sym = sp[i]; + q = block(REG, NIL, NIL, sym->stype, sym->sdf, sym->ssue); + q->n_rval = RETREG_PRE(sym->stype) + i; + p = tempnode(0, sym->stype, sym->sdf, sym->ssue); + sym->soffset = regno(p); + sym->sflags |= STNODE; + p = buildtree(ASSIGN, p, q); + ecomp(p); + } + + /* Process the remaining arguments. */ + for (off = V9RESERVE; i < cnt; i++) { + sym = sp[i]; + p = tempnode(0, sym->stype, sym->sdf, sym->ssue); + off = ALIGN(off, (tlen(p) - 1)); + sym->soffset = off * SZCHAR; + off += tlen(p); + p = buildtree(ASSIGN, p, nametree(sym)); + sym->soffset = regno(p->n_left); + sym->sflags |= STNODE; + ecomp(p); + } +} + +void +bccode() +{ + SETOFF(autooff, SZINT); +} + +void +ejobcode(int flag) +{ +} + +void +bjobcode() +{ +} + +/* + * The first six 64-bit arguments are saved in the registers O0 to O5, + * which become I0 to I5 after the "save" instruction moves the register + * window. Arguments 7 and up must be saved on the stack to %sp+BIAS+176. + * + * For a pretty picture, see Figure 3-16 in the SPARC Compliance Def 2.4. + */ +static NODE * +moveargs(NODE *p, int *regp, int *stacksize) +{ + NODE *r, *q; + + if (p->n_op == CM) { + p->n_left = moveargs(p->n_left, regp, stacksize); + r = p->n_right; + } else { + r = p; + } + + /* XXX more than six FP args can and should be passed in registers. */ + if (*regp > 5 && r->n_op != STARG) { + /* We are storing the stack offset in n_rval. */ + r = block(FUNARG, r, NIL, r->n_type, r->n_df, r->n_sue); + /* Make sure we are appropriately aligned. */ + *stacksize = ALIGN(*stacksize, (tlen(r) - 1)); + r->n_rval = *stacksize; + *stacksize += tlen(r); + } else if (r->n_op == STARG) + cerror("op STARG in moveargs"); + else { + q = block(REG, NIL, NIL, r->n_type, r->n_df, r->n_sue); + + /* + * The first six non-FP arguments go in the registers O0 - O5. + * Float arguments are stored in %fp1, %fp3, ..., %fp29, %fp31. + * Double arguments are stored in %fp0, %fp2, ..., %fp28, %fp30. + * A non-fp argument still increments register, eg. + * test(int a, int b, float b) + * takes %o0, %o1, %fp5. + */ + if (q->n_type == FLOAT) + q->n_rval = F0 + (*regp++ * 2) + 1; + else if (q->n_type == DOUBLE) + q->n_rval = D0 + *regp++; + else if (q->n_type == LDOUBLE) + cerror("long double support incomplete"); + else + q->n_rval = O0 + (*regp)++; + + r = buildtree(ASSIGN, q, r); + } + + if (p->n_op == CM) { + p->n_right = r; + return p; + } + + return r; +} + +NODE * +funcode(NODE *p) +{ + NODE *r, *l; + int reg = 0, stacksize = 0; + + r = l = 0; + + p->n_right = moveargs(p->n_right, ®, &stacksize); + + /* + * This is a particularly gross and inefficient way to handle + * argument overflows. First, we calculate how much stack space + * we need in moveargs(). Then we assign it by moving %sp, make + * the function call, and then move %sp back. + * + * What we should be doing is getting the maximum of all the needed + * stacksize values to the prologue and doing it all in the "save" + * instruction. + */ + if (stacksize != 0) { + stacksize = V9STEP(stacksize); /* 16-bit alignment. */ + + r = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + r->n_lval = 0; + r->n_rval = SP; + r = block(MINUS, r, bcon(stacksize), INT, 0, MKSUE(INT)); + + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_lval = 0; + l->n_rval = SP; + r = buildtree(ASSIGN, l, r); + + p = buildtree(COMOP, r, p); + + r = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + r->n_lval = 0; + r->n_rval = SP; + r = block(PLUS, r, bcon(stacksize), INT, 0, MKSUE(INT)); + + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_lval = 0; + l->n_rval = SP; + r = buildtree(ASSIGN, l, r); + + p = buildtree(COMOP, p, r); + + } + return p; +} + +int +fldal(unsigned int t) +{ + uerror("illegal field type"); + return ALINT; +} + +void +fldty(struct symtab *p) +{ +} + +int +mygenswitch(int num, TWORD type, struct swents **p, int n) +{ + return 0; +} --- /dev/null +++ usr.bin/pcc/sparc64/local.c @@ -0,0 +1,354 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass1.h" + +NODE * +clocal(NODE *p) +{ + struct symtab *sp; + int op; + NODE *r, *l; + + op = p->n_op; + sp = p->n_sp; + l = p->n_left; + r = p->n_right; + +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal in: %p, %s\n", p, copst(op)); + fwalk(p, eprint, 0); + } +#endif + + switch (op) { + + case NAME: + if (sp->sclass == PARAM || sp->sclass == AUTO) { + /* + * Use a fake structure reference to + * write out frame pointer offsets. + */ + l = block(REG, NIL, NIL, PTR+STRTY, 0, 0); + l->n_lval = 0; + l->n_rval = FP; + r = p; + p = stref(block(STREF, l, r, 0, 0, 0)); + } + break; + case PCONV: /* Remove what PCONVs we can. */ + if (l->n_op == SCONV) + break; + + if (l->n_op == ICON || (ISPTR(p->n_type) && ISPTR(l->n_type))) { + l->n_type = p->n_type; + l->n_qual = p->n_qual; + l->n_df = p->n_df; + l->n_sue = p->n_sue; + nfree(p); + p = l; + } + break; + + case SCONV: + /* Remove redundant conversions. */ + if ((p->n_type & TMASK) == 0 && (l->n_type & TMASK) == 0 && + btdims[p->n_type].suesize == btdims[l->n_type].suesize && + p->n_type != FLOAT && p->n_type != DOUBLE && + l->n_type != FLOAT && l->n_type != DOUBLE && + l->n_type != DOUBLE && p->n_type != LDOUBLE) { + if (l->n_op == NAME || l->n_op == UMUL || + l->n_op == TEMP) { + l->n_type = p->n_type; + nfree(p); + p = l; + break; + } + } + + /* Convert floating point to int before to char or short. */ + if ((l->n_type == FLOAT || l->n_type == DOUBLE || l->n_type == LDOUBLE) + && (DEUNSIGN(p->n_type) == CHAR || DEUNSIGN(p->n_type) == SHORT)) { + p = block(SCONV, p, NIL, p->n_type, p->n_df, p->n_sue); + p->n_left->n_type = INT; + break; + } + + /* Transform constants now. */ + if (l->n_op != ICON) + break; + + if (ISPTR(p->n_type)) { + l->n_type = p->n_type; + nfree(p); + p = l; + break; + } + + switch (p->n_type) { + case BOOL: l->n_lval = (l->n_lval != 0); break; + case CHAR: l->n_lval = (char)l->n_lval; break; + case UCHAR: l->n_lval = l->n_lval & 0377; break; + case SHORT: l->n_lval = (short)l->n_lval; break; + case USHORT: l->n_lval = l->n_lval & 0177777; break; + case UNSIGNED: l->n_lval = l->n_lval & 0xffffffff; break; + case INT: l->n_lval = (int)l->n_lval; break; + case ULONG: + case ULONGLONG: l->n_lval = l->n_lval; break; + case LONG: + case LONGLONG: l->n_lval = (long long)l->n_lval; break; + case FLOAT: + case DOUBLE: + case LDOUBLE: + l->n_op = FCON; + l->n_dcon = l->n_lval; + break; + case VOID: + break; + default: + cerror("sconv type unknown %d", p->n_type); + } + + l->n_type = p->n_type; + nfree(p); + p = l; + break; + + case PMCONV: + case PVCONV: + if (r->n_op != ICON) + cerror("converting bad type"); + nfree(p); + p = buildtree(op == PMCONV ? MUL : DIV, l, r); + break; + + case FORCE: + /* Put attached value into the return register. */ + p->n_op = ASSIGN; + p->n_right = p->n_left; + p->n_left = block(REG, NIL, NIL, p->n_type, 0, MKSUE(INT)); + p->n_left->n_rval = RETREG_PRE(p->n_type); + break; + } + +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal out: %p, %s\n", p, copst(op)); + fwalk(p, eprint, 0); + } +#endif + + return p; +} + +void +myp2tree(NODE *p) +{ + struct symtab *sp; + + if (p->n_op != FCON) + return; + + sp = tmpalloc(sizeof(struct symtab)); + sp->sclass = STATIC; + sp->slevel = 1; + sp->soffset = getlab(); + sp->sflags = 0; + sp->stype = p->n_type; + sp->squal = (CON >> TSHIFT); + + defloc(sp); + ninval(0, btdims[p->n_type].suesize, p); + + p->n_op = NAME; + p->n_lval = 0; + p->n_sp = sp; +} + +int +andable(NODE *p) +{ + return 1; +} + +void +cendarg() +{ + autooff = AUTOINIT; +} + +int +cisreg(TWORD t) +{ + /* SPARCv9 registers are all 64-bits wide. */ + return 1; +} + +NODE * +offcon(OFFSZ off, TWORD t, union dimfun *d, struct suedef *sue) +{ + return bcon(off / SZCHAR); +} + +void +spalloc(NODE *t, NODE *p, OFFSZ off) +{ +} + +void +inwstring(struct symtab *sp) +{ +} + +void +instring(struct symtab *sp) +{ + char *s, *str; + + defloc(sp); + str = sp->sname; + + printf("\t.ascii \""); + for (s = str; *s != 0; *s++) { + if (*s++ == '\\') + esccon(&s); + if (s - str > 60) { + fwrite(str, 1, s - str, stdout); + printf("\"\n\t.ascii \""); + str = s; + } + } + fwrite(str, 1, s - str, stdout); + printf("\\0\"\n"); +} + +void +zbits(OFFSZ off, int fsz) +{ +} + +void +infld(CONSZ off, int fsz, CONSZ val) +{ +} + +void +ninval(CONSZ off, int fsz, NODE *p) +{ + TWORD t; + struct symtab *sp; + union { float f; double d; int i; long long l; } u; + + t = p->n_type; + sp = p->n_sp; + + if (ISPTR(t)) + t = LONGLONG; + + if (p->n_op != ICON && p->n_op != FCON) + cerror("ninval: not a constant"); + if (p->n_op == ICON && sp != NULL && DEUNSIGN(t) != LONGLONG) + cerror("ninval: not constant"); + + switch (t) { + case CHAR: + case UCHAR: + printf("\t.byte %d\n", (int)p->n_lval & 0xff); + break; + case SHORT: + case USHORT: + printf("\t.half %d\n", (int)p->n_lval &0xffff); + break; + case BOOL: + p->n_lval = (p->n_lval != 0); /* FALLTHROUGH */ + case INT: + case UNSIGNED: + printf("\t.long " CONFMT "\n", p->n_lval); + break; + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + printf("\t.xword %lld", p->n_lval); + if (sp != 0) { + if (sp->sclass == STATIC && sp->slevel > 0) + printf("+" LABFMT, sp->soffset); + else + printf("+%s", exname(sp->soname)); + } + printf("\n"); + break; + case FLOAT: + u.f = (float)p->n_dcon; + printf("\t.long %d\n", u.i); + break; + case DOUBLE: + u.d = (double)p->n_dcon; + printf("\t.xword %lld\n", u.l); + break; + } +} + +char * +exname(char *p) +{ + return p ? p : ""; +} + +TWORD +ctype(TWORD type) +{ + return type; +} + +void +calldec(NODE *p, NODE *q) +{ +} + +void +extdec(struct symtab *q) +{ +} + +void +defzero(struct symtab *sp) +{ + int off = (tsize(sp->stype, sp->sdf, sp->ssue) + SZCHAR - 1) / SZCHAR; + printf("\t.comm "); + if (sp->slevel == 0) + printf("%s,%d\n", exname(sp->soname), off); + else + printf(LABFMT ",%d\n", sp->soffset, off); +} + +int +mypragma(char **ary) +{ + return 0; +} + +void +fixdef(struct symtab *sp) +{ +} + +void +pass1_lastchance(struct interpass *ip) +{ +} + From laffer1 at midnightbsd.org Tue Jan 20 16:30:17 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:30:17 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: move the pcc line to a more logical place Message-ID: <200901202130.n0KLUHkH081073@stargazer.midnightbsd.org> Log Message: ----------- move the pcc line to a more logical place Modified Files: -------------- src/usr.bin: Makefile (r1.19 -> r1.20) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/Makefile,v retrieving revision 1.19 retrieving revision 1.20 diff -L usr.bin/Makefile -L usr.bin/Makefile -u -r1.19 -r1.20 --- usr.bin/Makefile +++ usr.bin/Makefile @@ -316,8 +316,8 @@ .if ${MK_NCP} != "no" _ncplist= ncplist _ncplogin= ncplogin -#_pcc= pcc .endif +#_pcc= pcc _smbutil= smbutil .endif From laffer1 at midnightbsd.org Tue Jan 20 16:32:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:32:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: src/etc: Message-ID: <200901202132.n0KLWVhC081261@stargazer.midnightbsd.org> Log Message: ----------- Modified Files: -------------- src/etc: rc.bsdextended (r1.2 -> r1.3) rc.initdiskless (r1.2 -> r1.3) -------------- next part -------------- Index: rc.initdiskless =================================================================== RCS file: /home/cvs/src/etc/rc.initdiskless,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.initdiskless -L etc/rc.initdiskless -u -r1.2 -r1.3 --- etc/rc.initdiskless +++ etc/rc.initdiskless @@ -24,9 +24,9 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.initdiskless,v 1.42.2.4 2006/01/24 05:49:58 brooks Exp $ # $MidnightBSD$ -# +# $FreeBSD: src/etc/rc.initdiskless,v 1.52 2006/12/03 23:50:29 luigi Exp $ + # On entry to this script the entire system consists of a read-only root # mounted via NFS. The kernel has run BOOTP and configured an interface # (otherwise it would not have been able to mount the NFS root!) @@ -71,12 +71,16 @@ # then /dev/ad0s3 will be be mounted on /conf/1.2.3.4/foo/ # # /conf/T/M/diskless_remount -# The contents of the file points to an NFS filesystem. E.g. if -# /conf/base/etc/diskless_remount contains "foo.com:/etc", -# then foo.com:/etc will be be mounted on /conf/base/etc/ -# If the file contains a pathname starting with "/", then -# the root path is prepended to it; this allows relocation of -# the root filesystem without changing configuration files. +# The contents of the file points to an NFS filesystem, +# possibly followed by mount_nfs options. If the server name +# is omitted, the script will prepend the root path used when +# booting. E.g. if you booted from foo.com:/path/to/root, +# an entry for /conf/base/etc/diskless_remount could be any of +# foo.com:/path/to/root/etc +# /etc -o ro +# Because mount_nfs understands ".." in paths, it is +# possible to mount from locations above the NFS root with +# paths such as "/../../etc". # # /conf/T/M/md_size # The contents of the file specifies the size of the memory @@ -98,21 +102,27 @@ # The list of paths contained in the file are rm -rf'd # relative to /SUBDIR. # +# /conf/diskless_remount +# Similar to /conf/T/M/diskless_remount above, but allows +# all of /conf to be remounted. This can be used to allow +# multiple roots to share the same /conf. +# +# # You will almost universally want to create the following files under /conf # -# File Content -# ---------------------------- ------------------------------------------ -# /conf/base/etc/md_size size of /etc filesystem -# /conf/base/diskless_remount "/etc" -# /conf/default/etc/rc.conf generic diskless config parameters -# /conf/default/etc/fstab generic diskless fstab e.g. like this -# -# foo:/root_part / nfs ro 0 0 -# foo:/usr_part /usr nfs ro 0 0 -# foo:/home_part /home nfs rw 0 0 -# md /tmp mfs -s=30m,rw 0 0 -# md /var mfs -s=30m,rw 0 0 -# proc /proc procfs rw 0 0 +# File Content +# ---------------------------- ---------------------------------- +# /conf/base/etc/md_size size of /etc filesystem +# /conf/base/etc/diskless_remount "/etc" +# /conf/default/etc/rc.conf generic diskless config parameters +# /conf/default/etc/fstab generic diskless fstab e.g. like this +# +# foo:/root_part / nfs ro 0 0 +# foo:/usr_part /usr nfs ro 0 0 +# foo:/home_part /home nfs rw 0 0 +# md /tmp mfs -s=30m,rw 0 0 +# md /var mfs -s=30m,rw 0 0 +# proc /proc procfs rw 0 0 # # plus, possibly, overrides for password files etc. # @@ -124,6 +134,14 @@ dlv=`/sbin/sysctl -n vfs.nfs.diskless_valid 2> /dev/null` +# DEBUGGING +# log something on stdout if verbose. +o_verbose=0 # set to 1 or 2 if you want more debugging +log() { + [ ${o_verbose} -gt 0 ] && echo "*** $* ***" + [ ${o_verbose} -gt 1 ] && read -p "=== Press enter to continue" foo +} + # chkerr: # # Routine to check for error @@ -143,6 +161,23 @@ esac } +# The list of filesystems to umount after the copy +to_umount="" + +handle_remount() { # $1 = mount point + local nfspt mountopts b + b=$1 + log handle_remount $1 + [ -d $b -a -f $b/diskless_remount ] || return + read nfspt mountopts < $b/diskless_remount + log "nfspt ${nfspt} mountopts ${mountopts}" + # prepend the nfs root if not present + [ `expr "$nfspt" : '\(.\)'` = "/" ] && nfspt="${nfsroot}${nfspt}" + mount_nfs $mountopts $nfspt $b + chkerr $? "mount_nfs $nfspt $b" + to_umount="$b ${to_umount}" +} + # Create a generic memory disk # mount_md() { @@ -152,16 +187,16 @@ # Create the memory filesystem if it has not already been created # create_md() { - if [ "x`eval echo \\$md_created_$1`" = "x" ]; then + [ "x`eval echo \\$md_created_$1`" = "x" ] || return # only once if [ "x`eval echo \\$md_size_$1`" = "x" ]; then md_size=10240 else md_size=`eval echo \\$md_size_$1` fi + log create_md $1 with size $md_size mount_md $md_size /$1 /bin/chmod 755 /$1 eval md_created_$1=created - fi } # DEBUGGING @@ -197,7 +232,7 @@ echo "Interface ${bootp_ifc} IP-Address ${bootp_ipa} Broadcast ${bootp_ipbca} ${class}" fi -# Figure out our NFS root path +log Figure out our NFS root path # set -- `mount -t nfs` while [ $# -ge 1 ] ; do @@ -220,20 +255,8 @@ templates="${templates} ${bootp_ipa} ip/${bootp_ipa}" fi -# The list of filesystems to umount after the copy -to_umount="" - -# If /conf/diskless_remount exists, remount all of /conf. This allows -# multiple roots to share the same conf files. -if [ -d /conf -a -f /conf/diskless_remount ]; then - nfspt=`/bin/cat /conf/diskless_remount` - if [ `expr "$nfspt" : '\(.\)'` = "/" ]; then - nfspt="${nfsroot}${nfspt}" - fi - mount_nfs $nfspt /conf - chkerr $? "mount_nfs $nfspt /conf" - to_umount="/conf" -fi +# If /conf/diskless_remount exists, remount all of /conf. +handle_remount /conf # Resolve templates in /conf/base, /conf/default, /conf/${bootp_ipbca}, # and /conf/${bootp_ipa}. For each subdirectory found within these @@ -255,18 +278,17 @@ # it before attemping to the remount. This allows the root to be # relocated without needing to change the remount files. # +log "templates are ${templates}" for i in ${templates} ; do for j in /conf/$i/* ; do + [ -d $j ] || continue + # memory filesystem size specification - # subdir=${j##*/} - if [ -d $j -a -f $j/md_size ]; then - eval md_size_$subdir=`cat $j/md_size` - fi + [ -f $j/md_size ] && eval md_size_$subdir=`cat $j/md_size` - # remount - # - if [ -d $j -a -f $j/remount ]; then + # remount. Beware, the command is in the file itself! + if [ -f $j/remount ]; then nfspt=`/bin/cat $j/remount` $nfspt $j chkerr $? "$nfspt $j" @@ -274,16 +296,7 @@ fi # NFS remount - # - if [ -d $j -a -f $j/diskless_remount ]; then - nfspt=`/bin/cat $j/diskless_remount` - if [ `expr "$nfspt" : '\(.\)'` = "/" ]; then - nfspt="${nfsroot}${nfspt}" - fi - mount_nfs $nfspt $j - chkerr $? "mount_nfs $nfspt $j" - to_umount="$j ${to_umount}" - fi + handle_remount $j done done @@ -301,7 +314,7 @@ subdir=${j##*/} if [ -d $j -a ! -f $j.cpio.gz ]; then create_md $subdir - cp -Rp $j/* /$subdir + cp -Rp $j/ /$subdir fi done for j in /conf/$i/*.cpio.gz ; do Index: rc.bsdextended =================================================================== RCS file: /home/cvs/src/etc/rc.bsdextended,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.bsdextended -L etc/rc.bsdextended -u -r1.2 -r1.3 --- etc/rc.bsdextended +++ etc/rc.bsdextended @@ -23,10 +23,9 @@ # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. -# -# $MidnightBSD$ -# $FreeBSD: src/etc/rc.bsdextended,v 1.1 2004/09/29 00:12:28 trhodes Exp $ # +# $FreeBSD: src/etc/rc.bsdextended,v 1.2 2006/04/22 11:02:44 trhodes Exp $ +# $MidnightBSD$ #### # Sample startup policy for the mac_bsdextended(4) security module. @@ -49,34 +48,25 @@ #### # WARNING: recommended reading is the handbook's MAC -# chapter and the ugidfw(8) -# manual page. You can lock yourself out of the system -# very quickly by setting incorrect values here. -#### - -#### -# Set the value of 'x' to system users. This would be nice but it -# does not get the \n proper. Work around is used below. -#x=`awk -F: '($3 >= 1001) && ($3 != 65534) { print $1 }' /etc/passwd`; -#l=`awk -F: '($3 >= 1001) && ($3 != 65534) { print $3 }' /etc/passwd`; +# chapter and the ugidfw(8) manual page. You can +# lock yourself out of the system very quickly by setting +# incorrect values here. These are only examples. #### #### # Build a generic list of rules here, these should be # modified before using this script. -# ugidfw add 1 subject uid USER1 object uid USER2 mode n -# ugidfw add 2 subject gid USER1 object gid USER2 mode n # # For apache to read user files, the ruleadd must give # it permissions by default. #### -${CMD} add subject uid 80 object not uid 80 mode rxws; -${CMD} add subject gid 80 object not gid 80 mode rxws; +#${CMD} add subject uid 80 object not uid 80 mode rxws; +#${CMD} add subject gid 80 object not gid 80 mode rxws; #### # majordomo compat: #${CMD} add subject uid 54 object not uid 54 mode rxws; -${CMD} add subject gid 26 object gid 54 mode rxws; +#${CMD} add subject gid 26 object gid 54 mode rxws; #### # This is for root: @@ -84,14 +74,9 @@ ${CMD} add subject gid 0 object not gid 0 mode arxws; #### -# And for mailnull: -${CMD} add subject uid 26 object not uid 26 mode rxws; -${CMD} add subject gid 26 object not gid 26 mode rxws; - -#### # And for majordomo: -${CMD} add subject uid 54 object not uid 54 mode rxws; -${CMD} add subject gid 54 object not gid 54 mode rxws; +#${CMD} add subject uid 54 object not uid 54 mode rxws; +#${CMD} add subject gid 54 object not gid 54 mode rxws; #### # And for bin: @@ -100,8 +85,8 @@ #### # And for mail/pop: -${CMD} add subject uid 68 object not uid 68 mode rxws; -${CMD} add subject gid 6 object not gid 6 mode arxws; +#${CMD} add subject uid 68 object not uid 68 mode rxws; +#${CMD} add subject gid 6 object not gid 6 mode arxws; #### # And for smmsp: @@ -115,13 +100,13 @@ #### # For cyrus: -${CMD} add subject uid 60 object not uid 60 mode rxws; -${CMD} add subject gid 60 object not gid 60 mode rxws; +#${CMD} add subject uid 60 object not uid 60 mode rxws; +#${CMD} add subject gid 60 object not gid 60 mode rxws; #### # For stunnel: -${CMD} add subject uid 1018 object not uid 1018 mode rxws; -${CMD} add subject gid 1018 object not gid 1018 mode rxws; +#${CMD} add subject uid 1018 object not uid 1018 mode rxws; +#${CMD} add subject gid 1018 object not gid 1018 mode rxws; #### # For the nobody account: @@ -137,12 +122,6 @@ done; #### -# Work around majordomo problem where gid is `4'. -for x in `awk -F: '($3 >= 1001) && ($3 != 65534) { print $1 }' /etc/passwd`; - do ${CMD} add subject uid $x object gid 4 mode arwxs; -done; - -#### # Use some script to get a list of users and # add all users to mode n for all other users. This # will isolate all users from other user home directories while From laffer1 at midnightbsd.org Tue Jan 20 22:34:06 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 22:34:06 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: We don't have usbd.conf anymore Message-ID: <200901210334.n0L3Y6na014161@stargazer.midnightbsd.org> Log Message: ----------- We don't have usbd.conf anymore Modified Files: -------------- src/release: Makefile (r1.19 -> r1.20) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/release/Makefile,v retrieving revision 1.19 retrieving revision 1.20 diff -L release/Makefile -L release/Makefile -u -r1.19 -r1.20 --- release/Makefile +++ release/Makefile @@ -28,7 +28,7 @@ # #CHROOTDIR=/junk/release # If this is a -stable snapshot, then set -#RELEASETAG=RELENG_0_2 +#RELEASETAG=RELENG_0_3 # # To test a release with a source tree containing patches and # other work. This tree will get copied instead of getting the @@ -699,7 +699,6 @@ done ) cp ${RD}/trees/base/sbin/dhclient-script ${RD}/mfsfd/stand # cp ${RD}/trees/base/usr/bin/tar ${RD}/mfsfd/stand - cp ${.CURDIR}/../etc/usbd.conf ${RD}/mfsfd/etc/usbd.conf cp ${.CURDIR}/../etc/master.passwd ${RD}/mfsfd/etc/master.passwd cp ${RD}/trees/base/etc/*pwd.db ${RD}/mfsfd/etc/ ( for F in defaults/rc.conf netconfig protocols ; do \ From laffer1 at midnightbsd.org Tue Jan 20 23:34:56 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 23:34:56 -0500 (EST) Subject: [Midnightbsd-cvs] mports: clamav-clamd.in: Fix file checking. Message-ID: <200901210434.n0L4Yuks019209@stargazer.midnightbsd.org> Log Message: ----------- Fix file checking. Modified Files: -------------- mports/security/clamav/files: clamav-clamd.in (r1.3 -> r1.4) -------------- next part -------------- Index: clamav-clamd.in =================================================================== RCS file: /home/cvs/mports/security/clamav/files/clamav-clamd.in,v retrieving revision 1.3 retrieving revision 1.4 diff -L security/clamav/files/clamav-clamd.in -L security/clamav/files/clamav-clamd.in -u -r1.3 -r1.4 --- security/clamav/files/clamav-clamd.in +++ security/clamav/files/clamav-clamd.in @@ -36,8 +36,8 @@ #clamav .93 won't start without a valid main.cvd file clamav_clamd_precmd() { - if [ ! -f %%DBDIR%%/main.cvd ];then - echo "Missing %%DBDIR%%/clamav/*.cvd files. You must run freshclam first" + if [ ! -f %%DBDIR%%/main.cvd -a ! -f %%DBDIR%%/main.cld ];then + echo "Missing %%DBDIR%%/*.cvd or *.cld files. You must run freshclam first" exit 1 fi } From laffer1 at midnightbsd.org Wed Jan 21 00:00:58 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Wed, 21 Jan 2009 00:00:58 -0500 (EST) Subject: [Midnightbsd-cvs] mports: security/clamav: update to 0.94.2. Message-ID: <200901210500.n0L50wFf040508@stargazer.midnightbsd.org> Log Message: ----------- update to 0.94.2. stop using libtool as it's got a built in version now. Modified Files: -------------- mports/security/clamav: Makefile (r1.15 -> r1.16) distinfo (r1.13 -> r1.14) mports/security/clamav/files: patch-configure (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/security/clamav/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -L security/clamav/Makefile -L security/clamav/Makefile -u -r1.15 -r1.16 --- security/clamav/Makefile +++ security/clamav/Makefile @@ -7,7 +7,7 @@ # PORTNAME= clamav -PORTVERSION= 0.94 +PORTVERSION= 0.94.2 CATEGORIES= security MASTER_SITES= SF @@ -28,7 +28,7 @@ STDERR "Print logs to stderr instead of stdout" Off \ EXPERIMENTAL "Build experimental code" Off -USE_AUTOTOOLS= libtool:15 +GNU_CONFIGURE= yes CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd6.0 USE_LDCONFIG= yes USE_RC_SUBR= clamav-clamd clamav-freshclam @@ -43,9 +43,9 @@ CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" \ LDFLAGS="${LDFLAGS}" CONFIGURE_ARGS= --with-dbdir=${DBDIR} \ + --libdir=${PREFIX}/lib \ --with-zlib=/usr \ --mandir=${MANPREFIX}/man \ - --disable-zlib-vcheck \ --disable-clamuko \ --disable-clamav \ --enable-bigstack \ Index: distinfo =================================================================== RCS file: /home/cvs/mports/security/clamav/distinfo,v retrieving revision 1.13 retrieving revision 1.14 diff -L security/clamav/distinfo -L security/clamav/distinfo -u -r1.13 -r1.14 --- security/clamav/distinfo +++ security/clamav/distinfo @@ -1,3 +1,3 @@ -MD5 (clamav-0.94.tar.gz) = d3f6d5fff2db81950491749166ab0ffa -SHA256 (clamav-0.94.tar.gz) = ae188c18936ea9154eb6a85ea553c29f4349ee3e95457055fae5fe1b981af602 -SIZE (clamav-0.94.tar.gz) = 20509228 +MD5 (clamav-0.94.2.tar.gz) = 1181e6d62341b84708f126cc353f7ebf +SHA256 (clamav-0.94.2.tar.gz) = 1aec7fecff375958d067aceeb9782d3ff0be7c13bed0eecf6240fb089f8d268c +SIZE (clamav-0.94.2.tar.gz) = 22107637 Index: patch-configure =================================================================== RCS file: /home/cvs/mports/security/clamav/files/patch-configure,v retrieving revision 1.3 retrieving revision 1.4 diff -L security/clamav/files/patch-configure -L security/clamav/files/patch-configure -u -r1.3 -r1.4 --- security/clamav/files/patch-configure +++ security/clamav/files/patch-configure @@ -1,6 +1,6 @@ ---- configure.orig 2008-09-01 15:41:18.000000000 -0300 -+++ configure 2008-09-05 08:57:53.000000000 -0300 -@@ -16571,7 +16571,7 @@ +--- configure.orig 2008-10-15 07:41:31.000000000 -0300 ++++ configure 2008-10-15 08:55:58.000000000 -0300 +@@ -17909,7 +17909,7 @@ ;; freebsd*) if test "$have_pthreads" = "yes"; then @@ -9,16 +9,16 @@ TH_SAFE="-thread-safe" cat >>confdefs.h <<\_ACEOF -@@ -16931,7 +16931,7 @@ +@@ -18269,7 +18269,7 @@ if test "$have_milter" = "yes"; then - save_LDFLAGS="$LDFLAGS" -- CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" -+ CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS $THREAD_LIBS" + save_LIBS="$LIBS" +- CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" ++ CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS $THREAD_LIBS" if test -d /usr/lib/libmilter ; then CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -L/usr/lib/libmilter" fi -@@ -17468,19 +17468,25 @@ +@@ -18806,19 +18806,25 @@ sendmailver_c=`echo $sendmailver | awk -F. '{printf $3}'` From ctriv at midnightbsd.org Wed Jan 21 11:47:03 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Wed, 21 Jan 2009 11:47:03 -0500 (EST) Subject: [Midnightbsd-cvs] mports: apache.mk: provide some sensible defaults if apxs isn't Message-ID: <200901211647.n0LGl3mm012849@stargazer.midnightbsd.org> Log Message: ----------- provide some sensible defaults if apxs isn't installed. Modified Files: -------------- mports/Mk/extensions: apache.mk (r1.2 -> r1.3) -------------- next part -------------- Index: apache.mk =================================================================== RCS file: /home/cvs/mports/Mk/extensions/apache.mk,v retrieving revision 1.2 retrieving revision 1.3 diff -L Mk/extensions/apache.mk -L Mk/extensions/apache.mk -u -r1.2 -r1.3 --- Mk/extensions/apache.mk +++ Mk/extensions/apache.mk @@ -350,8 +350,13 @@ .elif defined(AP_PORT_IS_MODULE) +.if exists(${APXS}) APR_CONFIG!= ${APXS} -q APR_CONFIG AP_LIBTOOL!= ${APR_CONFIG} --apr-libtool +.else +APR_CONFIG= ${LOCALBASE}/bin/apr-1-config +AP_LIBTOOL= ${LOCALBASE}/build-1/libtool +.endif .if defined(AP_FAST_BUILD) .if !target(ap-gen-plist) From laffer1 at midnightbsd.org Wed Jan 21 13:56:03 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Wed, 21 Jan 2009 13:56:03 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: switch to releases directory Message-ID: <200901211856.n0LIu3IX056367@stargazer.midnightbsd.org> Log Message: ----------- switch to releases directory Modified Files: -------------- www/download: index.html (r1.41 -> r1.42) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.41 retrieving revision 1.42 diff -L download/index.html -L download/index.html -u -r1.41 -r1.42 --- download/index.html +++ download/index.html @@ -43,7 +43,7 @@
NetBSD.se - HTTP + FTP + HTTP + FTP Fast From crash at midnightbsd.org Sun Jan 25 14:37:14 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 14:37:14 -0500 (EST) Subject: [Midnightbsd-cvs] mports: archivers/unrar: update to 3.80 instead of 3.80.b2 Message-ID: <200901251937.n0PJbE4D075247@stargazer.midnightbsd.org> Log Message: ----------- update to 3.80 instead of 3.80.b2 Modified Files: -------------- mports/archivers/unrar: Makefile (r1.5 -> r1.6) distinfo (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/archivers/unrar/Makefile,v retrieving revision 1.5 retrieving revision 1.6 diff -L archivers/unrar/Makefile -L archivers/unrar/Makefile -u -r1.5 -r1.6 --- archivers/unrar/Makefile +++ archivers/unrar/Makefile @@ -7,11 +7,11 @@ # PORTNAME= unrar -PORTVERSION= 3.80.b2 +PORTVERSION= 3.80 PORTEPOCH= 5 CATEGORIES+= archivers MASTER_SITES= http://www.rarlab.com/rar/ -DISTNAME= unrarsrc-3.8.2 +DISTNAME= unrarsrc-3.8.4 MAINTAINER?= ports at MidnightBSD.org COMMENT= Extract, view & test RAR archives Index: distinfo =================================================================== RCS file: /home/cvs/mports/archivers/unrar/distinfo,v retrieving revision 1.3 retrieving revision 1.4 diff -L archivers/unrar/distinfo -L archivers/unrar/distinfo -u -r1.3 -r1.4 --- archivers/unrar/distinfo +++ archivers/unrar/distinfo @@ -1,3 +1,3 @@ -MD5 (unrarsrc-3.8.2.tar.gz) = 897e7d72c7576ff8c83a2b8f48017bb1 -SHA256 (unrarsrc-3.8.2.tar.gz) = d989b1393d350290fdab4162b4e7a6bcf061d2b3a4a1c4982fc0868d668cc731 -SIZE (unrarsrc-3.8.2.tar.gz) = 134853 +MD5 (unrarsrc-3.8.4.tar.gz) = b40b43e28dee42abd9840bfc9e2909ee +SHA256 (unrarsrc-3.8.4.tar.gz) = 5d501b853885c30f4b0ee8fd9a7c61607df99fd1aaf7db99a2c44c6243337886 +SIZE (unrarsrc-3.8.4.tar.gz) = 135665 From crash at midnightbsd.org Sun Jan 25 14:53:09 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 14:53:09 -0500 (EST) Subject: [Midnightbsd-cvs] mports: archivers/p7zip: update to 4.61 Message-ID: <200901251953.n0PJr9eb076478@stargazer.midnightbsd.org> Log Message: ----------- update to 4.61 Modified Files: -------------- mports/archivers/p7zip: Makefile (r1.6 -> r1.7) distinfo (r1.4 -> r1.5) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/archivers/p7zip/Makefile,v retrieving revision 1.6 retrieving revision 1.7 diff -L archivers/p7zip/Makefile -L archivers/p7zip/Makefile -u -r1.6 -r1.7 --- archivers/p7zip/Makefile +++ archivers/p7zip/Makefile @@ -7,7 +7,7 @@ # PORTNAME= p7zip -PORTVERSION= 4.58 +PORTVERSION= 4.61 PORTREVISION= 1 CATEGORIES= archivers MASTER_SITES= SF Index: distinfo =================================================================== RCS file: /home/cvs/mports/archivers/p7zip/distinfo,v retrieving revision 1.4 retrieving revision 1.5 diff -L archivers/p7zip/distinfo -L archivers/p7zip/distinfo -u -r1.4 -r1.5 --- archivers/p7zip/distinfo +++ archivers/p7zip/distinfo @@ -1,3 +1,3 @@ -MD5 (p7zip_4.58_src_all.tar.bz2) = 315b184102c17c4956f53218d973222d -SHA256 (p7zip_4.58_src_all.tar.bz2) = 52391559b7782d2bad45b783579ea9825f28670ba6f234fd0d9248af3e82bedd -SIZE (p7zip_4.58_src_all.tar.bz2) = 1948207 +MD5 (p7zip_4.61_src_all.tar.bz2) = a01408ac4ef496270ff936db21309b92 +SHA256 (p7zip_4.61_src_all.tar.bz2) = ccc309c6411b3e9badc73f2c3e1c0469d333d09a1ea30481c4a6be0782dbe061 +SIZE (p7zip_4.61_src_all.tar.bz2) = 2483533 From crash at midnightbsd.org Sun Jan 25 15:03:27 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 15:03:27 -0500 (EST) Subject: [Midnightbsd-cvs] mports: archivers/pbzip2: update to 1.0.5 Message-ID: <200901252003.n0PK3Rwj077352@stargazer.midnightbsd.org> Log Message: ----------- update to 1.0.5 Modified Files: -------------- mports/archivers/pbzip2: Makefile (r1.5 -> r1.6) distinfo (r1.2 -> r1.3) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/archivers/pbzip2/Makefile,v retrieving revision 1.5 retrieving revision 1.6 diff -L archivers/pbzip2/Makefile -L archivers/pbzip2/Makefile -u -r1.5 -r1.6 --- archivers/pbzip2/Makefile +++ archivers/pbzip2/Makefile @@ -1,10 +1,10 @@ # $MidnightBSD$ PORTNAME= pbzip2 -PORTVERSION= 1.0.2 +PORTVERSION= 1.0.5 CATEGORIES= archivers -MASTER_SITES= http://compression.ca/pbzip2/ CENKES - +MASTER_SITES= http://compression.ca/pbzip2/ +DIST_SUBDIR= ${PORTNAME}-${PORTVERSION} MAINTAINER= ports at MidnightBSD.org COMMENT= Parallel BZIP2 LICENSE= bzip2 @@ -14,16 +14,14 @@ MAN1= pbzip2.1 MLINKS= pbzip2.1 pbunzip2.1 +USE_GMAKE= YES post-patch: @${REINPLACE_CMD} \ - -e "s,-pthread -lpthread,${PTHREAD_LIBS},g" \ - -e "s,-O3,${CXXFLAGS}," \ - -e "s,^CC,#CC," \ - -e "s,CC,CXX," ${WRKSRC}/Makefile - @${REINPLACE_CMD} \ - -e "s,PRIu64 \"Lu\",PRIu64 Lu," \ - -e "s,\"PRIu64\",#PRIu64,g" ${WRKSRC}/pbzip2.cpp - + -e 's,-pthread -lpthread,${PTHREAD_LIBS},g; \ + s,-O2,${CXXFLAGS},; \ + s,^CC,#CC,; \ + s,CC,CXX,' ${WRKSRC}/Makefile + do-install: @${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin/ @${LN} -sf ${PORTNAME} ${PREFIX}/bin/pbunzip2 Index: distinfo =================================================================== RCS file: /home/cvs/mports/archivers/pbzip2/distinfo,v retrieving revision 1.2 retrieving revision 1.3 diff -L archivers/pbzip2/distinfo -L archivers/pbzip2/distinfo -u -r1.2 -r1.3 --- archivers/pbzip2/distinfo +++ archivers/pbzip2/distinfo @@ -1,3 +1,3 @@ -MD5 (pbzip2-1.0.2.tar.gz) = 7c959f0554695bc484865b938e791aaf -SHA256 (pbzip2-1.0.2.tar.gz) = 41c654b493bfd045f3a625ca9f3fb66e327ad0a4395e515c2bd6c3070b83c0e4 -SIZE (pbzip2-1.0.2.tar.gz) = 22777 +MD5 (pbzip2-1.0.5/pbzip2-1.0.5.tar.gz) = e2448d22ee29d1e6549ac58b98df11ab +SHA256 (pbzip2-1.0.5/pbzip2-1.0.5.tar.gz) = 415d8c8a69080b7e55a50784852971fca249cd9e5ec4ada8e617ca2696c9896d +SIZE (pbzip2-1.0.5/pbzip2-1.0.5.tar.gz) = 26997 From crash at midnightbsd.org Sun Jan 25 15:27:25 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 15:27:25 -0500 (EST) Subject: [Midnightbsd-cvs] mports: shells/bash: update 3.2 to patchlevel 48 Message-ID: <200901252027.n0PKRPX3079594@stargazer.midnightbsd.org> Log Message: ----------- update 3.2 to patchlevel 48 Modified Files: -------------- mports/shells/bash: Makefile (r1.8 -> r1.9) distinfo (r1.4 -> r1.5) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/shells/bash/Makefile,v retrieving revision 1.8 retrieving revision 1.9 diff -L shells/bash/Makefile -L shells/bash/Makefile -u -r1.8 -r1.9 --- shells/bash/Makefile +++ shells/bash/Makefile @@ -8,7 +8,7 @@ # PORTNAME= bash -PATCHLEVEL= 39 +PATCHLEVEL= 48 PORTVERSION= 3.2.${PATCHLEVEL:S/^0//g} CATEGORIES= shells MASTER_SITES= ${MASTER_SITE_GNU:S/$/:bash/} \ Index: distinfo =================================================================== RCS file: /home/cvs/mports/shells/bash/distinfo,v retrieving revision 1.4 retrieving revision 1.5 diff -L shells/bash/distinfo -L shells/bash/distinfo -u -r1.4 -r1.5 --- shells/bash/distinfo +++ shells/bash/distinfo @@ -118,5 +118,32 @@ MD5 (bash/bash32-039) = e240c34f979b64bcb83c5f6567110bb1 SHA256 (bash/bash32-039) = 46d427fd5b1509ec7dd980c07efd88634fde61cf07ab221dcbde9e1021bd2817 SIZE (bash/bash32-039) = 5034 +MD5 (bash/bash32-040) = 06e6df263398807fa032707fb7b77b5f +SHA256 (bash/bash32-040) = c9e0387eb4a2904126864d24de0699cdb6070789e1c02287a3b81ea96bf945aa +SIZE (bash/bash32-040) = 1403 +MD5 (bash/bash32-041) = 373ae081d658dc85bc1058c4759d6669 +SHA256 (bash/bash32-041) = cc551fa57d613efea30ab2404fe724793a3d10f012b030e611d2c6449e463bcd +SIZE (bash/bash32-041) = 4446 +MD5 (bash/bash32-042) = 9c9ebc6bfc33a0215277ee17a276eb5a +SHA256 (bash/bash32-042) = fd0df54d03034e104b6377f249624bda0271aa874190a46e9d41fc49ad3caaef +SIZE (bash/bash32-042) = 1209 +MD5 (bash/bash32-043) = b87fb9ea16a64ca41b6676e9a7eb7a33 +SHA256 (bash/bash32-043) = 43df7d2d7d61d3a8f0e14bc86d4f55b6d2e64829ba0829a78f5214d186087af7 +SIZE (bash/bash32-043) = 1658 +MD5 (bash/bash32-044) = 07e0229ce5879bfbd26a8146070fd366 +SHA256 (bash/bash32-044) = 204b5ecaaa5de334c3cfbce6dfd8a9d3770b09024ab4724d86080fbf501ded69 +SIZE (bash/bash32-044) = 5565 +MD5 (bash/bash32-045) = 1ad07965a8a93f3556ee1ab18b97cde2 +SHA256 (bash/bash32-045) = 3250e6c6d5d6884e31beaa2f521d2a1af9c2f701a4c0e67a7cd011b6ad8f082b +SIZE (bash/bash32-045) = 1338 +MD5 (bash/bash32-046) = f7b1e19fcad54c2286bc0ed614aad9bf +SHA256 (bash/bash32-046) = fc829e92fa951c34368d83272d746f5c0ed345a7ad037f93322347eed00a1e1f +SIZE (bash/bash32-046) = 1275 +MD5 (bash/bash32-047) = 550690766de770116c34dbdf74e59184 +SHA256 (bash/bash32-047) = 623d4a958d2b022a15929a4de7403766ff07b295a185987b4d1e6cf3b70ea106 +SIZE (bash/bash32-047) = 1981 +MD5 (bash/bash32-048) = 4cc593e7b789b23b37a5397e092d3954 +SHA256 (bash/bash32-048) = 74cb56764274f393676f68738eb22a3ed8fa388c0487feeadf0d78a45b549749 +SIZE (bash/bash32-048) = 1948 MD5 (bash/FAQ) = IGNORE SHA256 (bash/FAQ) = IGNORE From laffer1 at midnightbsd.org Sun Jan 25 16:55:17 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 25 Jan 2009 16:55:17 -0500 (EST) Subject: [Midnightbsd-cvs] mports: www/apache22: update to 2.2.11 Message-ID: <200901252155.n0PLtHHt087319@stargazer.midnightbsd.org> Log Message: ----------- update to 2.2.11 Modified Files: -------------- mports/www/apache22: Makefile (r1.10 -> r1.11) Makefile.doc (r1.2 -> r1.3) Makefile.modules (r1.2 -> r1.3) distinfo (r1.6 -> r1.7) -------------- next part -------------- Index: Makefile.doc =================================================================== RCS file: /home/cvs/mports/www/apache22/Makefile.doc,v retrieving revision 1.2 retrieving revision 1.3 diff -L www/apache22/Makefile.doc -L www/apache22/Makefile.doc -u -r1.2 -r1.3 --- www/apache22/Makefile.doc +++ www/apache22/Makefile.doc @@ -5,6 +5,7 @@ # - make options output # - apache22 man/docs routines # +# $MidnightBSD$ # $FreeBSD: ports/www/apache22/Makefile.doc,v 1.10 2006/11/05 10:49:17 clement Exp $ # Index: Makefile.modules =================================================================== RCS file: /home/cvs/mports/www/apache22/Makefile.modules,v retrieving revision 1.2 retrieving revision 1.3 diff -L www/apache22/Makefile.modules -L www/apache22/Makefile.modules -u -r1.2 -r1.3 --- www/apache22/Makefile.modules +++ www/apache22/Makefile.modules @@ -9,6 +9,7 @@ # gsed 's/^\(.*\)mod\(.*\)\.so/%%\MOD\U\2%%\L\1mod\2\.so/' pkg-plist > tmp # mv tmp pkg-plist # +# $MidnightBSD$ # $FreeBSD: ports/www/apache22/Makefile.modules,v 1.21 2007/01/13 13:18:35 clement Exp $ # Index: Makefile =================================================================== RCS file: /home/cvs/mports/www/apache22/Makefile,v retrieving revision 1.10 retrieving revision 1.11 diff -L www/apache22/Makefile -L www/apache22/Makefile -u -r1.10 -r1.11 --- www/apache22/Makefile +++ www/apache22/Makefile @@ -8,7 +8,7 @@ # PORTNAME= apache -PORTVERSION= 2.2.10 +PORTVERSION= 2.2.11 CATEGORIES= www MASTER_SITES= ${MASTER_SITE_APACHE_HTTPD} \ ${MASTER_SITE_LOCAL:S/%SUBDIR%\//clement\/:aprmysql/} Index: distinfo =================================================================== RCS file: /home/cvs/mports/www/apache22/distinfo,v retrieving revision 1.6 retrieving revision 1.7 diff -L www/apache22/distinfo -L www/apache22/distinfo -u -r1.6 -r1.7 --- www/apache22/distinfo +++ www/apache22/distinfo @@ -1,3 +1,3 @@ -MD5 (apache22/httpd-2.2.10.tar.bz2) = 6697772ba5f8d34988fe297417ccaacc -SHA256 (apache22/httpd-2.2.10.tar.bz2) = 681d5787288e4e527877f415acce198be96ce7de0dc6e354646b1df4aae21383 -SIZE (apache22/httpd-2.2.10.tar.bz2) = 5068069 +MD5 (apache22/httpd-2.2.11.tar.bz2) = 3e98bcb14a7122c274d62419566431bb +SHA256 (apache22/httpd-2.2.11.tar.bz2) = 5ce34825c5b84d1808605a22f8d16d44c6f91882a538bb98a3affed8f5dff6fe +SIZE (apache22/httpd-2.2.11.tar.bz2) = 5230130 From laffer1 at midnightbsd.org Mon Jan 26 14:14:09 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:14:09 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: Add new partial mirror Message-ID: <200901261914.n0QJE9UY017809@stargazer.midnightbsd.org> Log Message: ----------- Add new partial mirror Modified Files: -------------- www/download: index.html (r1.42 -> r1.43) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.42 retrieving revision 1.43 diff -L download/index.html -L download/index.html -u -r1.42 -r1.43 --- download/index.html +++ download/index.html @@ -62,6 +62,11 @@ Medium + "Kitty" (ISOs only) + HTTP + FTP + Medium + +
MidnightBSD.org HTTP + FTP Slow From laffer1 at midnightbsd.org Mon Jan 26 14:18:13 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:18:13 -0500 (EST) Subject: [Midnightbsd-cvs] www: www/download: change URLs for vm images so they are on the ftp Message-ID: <200901261918.n0QJIDqm018372@stargazer.midnightbsd.org> Log Message: ----------- change URLs for vm images so they are on the ftp server too. Modified Files: -------------- www/download: parallels.html (r1.2 -> r1.3) vmware.html (r1.3 -> r1.4) -------------- next part -------------- Index: vmware.html =================================================================== RCS file: /home/cvs/www/download/vmware.html,v retrieving revision 1.3 retrieving revision 1.4 diff -L download/vmware.html -L download/vmware.html -u -r1.3 -r1.4 --- download/vmware.html +++ download/vmware.html @@ -12,10 +12,10 @@ is no password. DHCP is enabled. X.org 6.9 and perl are installed.

-Download (Zip format) the MidnightBSD VMware virtual appliance. +Download (Zip format) the MidnightBSD VMware virtual appliance.

-

A second appliance (7zip format) is available with a subset of KDE 3.5.4 installed and kdm running at startup. It is approximately 291MB and requires a username and password of mnbsd.

+

A second appliance (7zip format) is available with a subset of KDE 3.5.4 installed and kdm running at startup. It is approximately 291MB and requires a username and password of mnbsd.

Index: parallels.html =================================================================== RCS file: /home/cvs/www/download/parallels.html,v retrieving revision 1.2 retrieving revision 1.3 diff -L download/parallels.html -L download/parallels.html -u -r1.2 -r1.3 --- download/parallels.html +++ download/parallels.html @@ -11,7 +11,7 @@

This MidnightBSD appliance is based on 0.1.1-RELEASE. It is 60MB compressedand under 200MB uncompressed. Only the root account is configured and there is no password. DHCP is enabled. No x.org. Made on Parallels 3 for Mac OS X.

-

MidnightBSD 0.1.1 for Parallels

+

MidnightBSD 0.1.1 for Parallels

From laffer1 at midnightbsd.org Mon Jan 26 14:19:47 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:19:47 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: change url for VMs Message-ID: <200901261919.n0QJJlxs018488@stargazer.midnightbsd.org> Log Message: ----------- change url for VMs Modified Files: -------------- www/download: index.html (r1.43 -> r1.44) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.43 retrieving revision 1.44 diff -L download/index.html -L download/index.html -u -r1.43 -r1.44 --- download/index.html +++ download/index.html @@ -80,15 +80,15 @@

- - + + - + - +
VMWare Image (222MB)Parallels Image (60MB)Parallels 3.x Image (60MB)
This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. A second appliance (7zip, 291MB) is available with a subset of KDE 3.5.4 and kdm running at startup. Username and password: mnbsd.This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. A second appliance (7zip, 291MB) is available with a subset of KDE 3.5.4 and kdm running at startup. Username and password: mnbsd. This MidnightBSD appliance is based on 0.1.1-RELEASE. It is 60MB compressed and 200MB uncompressed. Only the root account is configured and there is no password. DHCP is enabled. No X.org. Made on Parallels 3 for Mac OS X.

From laffer1 at midnightbsd.org Mon Jan 26 14:24:58 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:24:58 -0500 (EST) Subject: [Midnightbsd-cvs] www: www/download: change vmware availability. Message-ID: <200901261924.n0QJOwRH019144@stargazer.midnightbsd.org> Log Message: ----------- change vmware availability. (i need to make new ones soon) Modified Files: -------------- www/download: index.html (r1.44 -> r1.45) vmware.html (r1.4 -> r1.5) -------------- next part -------------- Index: vmware.html =================================================================== RCS file: /home/cvs/www/download/vmware.html,v retrieving revision 1.4 retrieving revision 1.5 diff -L download/vmware.html -L download/vmware.html -u -r1.4 -r1.5 --- download/vmware.html +++ download/vmware.html @@ -15,8 +15,5 @@ Download (Zip format) the MidnightBSD VMware virtual appliance.

-

A second appliance (7zip format) is available with a subset of KDE 3.5.4 installed and kdm running at startup. It is approximately 291MB and requires a username and password of mnbsd.

- - Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.44 retrieving revision 1.45 diff -L download/index.html -L download/index.html -u -r1.44 -r1.45 --- download/index.html +++ download/index.html @@ -80,7 +80,7 @@

- + @@ -88,7 +88,7 @@ - +
Parallels 3.x Image (60MB)
This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. A second appliance (7zip, 291MB) is available with a subset of KDE 3.5.4 and kdm running at startup. Username and password: mnbsd.This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. This MidnightBSD appliance is based on 0.1.1-RELEASE. It is 60MB compressed and 200MB uncompressed. Only the root account is configured and there is no password. DHCP is enabled. No X.org. Made on Parallels 3 for Mac OS X.

From laffer1 at midnightbsd.org Thu Jan 29 12:52:58 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 29 Jan 2009 12:52:58 -0500 (EST) Subject: [Midnightbsd-cvs] mports: www/dojo: Add dojo and zend framework ports. Message-ID: <200901291752.n0THqwS3004816@stargazer.midnightbsd.org> Log Message: ----------- Add dojo and zend framework ports. These are based on Greg Larkin's ports for FreeBSD. I need this for work. Added Files: ----------- mports/www/dojo: Makefile (r1.1) distinfo (r1.1) pkg-descr (r1.1) pkg-plist (r1.1) mports/www/dojo/files: dojo.conf.in (r1.1) pkg-message.in (r1.1) mports/www/zend-framework: Makefile (r1.1) distinfo (r1.1) pkg-descr (r1.1) pkg-plist (r1.1) mports/www/zend-framework/files: pkg-message.in (r1.1) -------------- next part -------------- --- /dev/null +++ www/dojo/pkg-descr @@ -0,0 +1,7 @@ +Dojo is an Open Source DHTML toolkit written in JavaScript. It +builds on several contributed code bases (nWidgets, Burstlib, f(m)), +which is why we refer to it sometimes as a "unified" toolkit. Dojo +aims to solve some long-standing historical problems with DHTML +which prevented mass adoption of dynamic web application development. + +WWW: http://dojotoolkit.org/ --- /dev/null +++ www/dojo/pkg-plist @@ -0,0 +1,2179 @@ +%%WWWDIR%%/dijit/ColorPalette.js +%%WWWDIR%%/dijit/Declaration.js +%%WWWDIR%%/dijit/Dialog.js +%%WWWDIR%%/dijit/Editor.js +%%WWWDIR%%/dijit/InlineEditBox.js +%%WWWDIR%%/dijit/LICENSE +%%WWWDIR%%/dijit/Menu.js +%%WWWDIR%%/dijit/ProgressBar.js +%%WWWDIR%%/dijit/TitlePane.js +%%WWWDIR%%/dijit/Toolbar.js +%%WWWDIR%%/dijit/Tooltip.js +%%WWWDIR%%/dijit/Tree.js +%%WWWDIR%%/dijit/_Calendar.js +%%WWWDIR%%/dijit/_Container.js +%%WWWDIR%%/dijit/_Templated.js +%%WWWDIR%%/dijit/_TimePicker.js +%%WWWDIR%%/dijit/_Widget.js +%%WWWDIR%%/dijit/_base.js +%%WWWDIR%%/dijit/_base/focus.js +%%WWWDIR%%/dijit/_base/manager.js +%%WWWDIR%%/dijit/_base/place.js +%%WWWDIR%%/dijit/_base/popup.js +%%WWWDIR%%/dijit/_base/scroll.js +%%WWWDIR%%/dijit/_base/sniff.js +%%WWWDIR%%/dijit/_base/typematic.js +%%WWWDIR%%/dijit/_base/wai.js +%%WWWDIR%%/dijit/_base/window.js +%%WWWDIR%%/dijit/_editor/RichText.js +%%WWWDIR%%/dijit/_editor/_Plugin.js +%%WWWDIR%%/dijit/_editor/html.js +%%WWWDIR%%/dijit/_editor/nls/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ar/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ar/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ar/commands.js +%%WWWDIR%%/dijit/_editor/nls/ca/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ca/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ca/commands.js +%%WWWDIR%%/dijit/_editor/nls/commands.js +%%WWWDIR%%/dijit/_editor/nls/cs/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/cs/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/cs/commands.js +%%WWWDIR%%/dijit/_editor/nls/da/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/da/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/da/commands.js +%%WWWDIR%%/dijit/_editor/nls/de/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/de/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/de/commands.js +%%WWWDIR%%/dijit/_editor/nls/el/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/el/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/el/commands.js +%%WWWDIR%%/dijit/_editor/nls/es/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/es/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/es/commands.js +%%WWWDIR%%/dijit/_editor/nls/fi/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/fi/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/fi/commands.js +%%WWWDIR%%/dijit/_editor/nls/fr/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/fr/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/fr/commands.js +%%WWWDIR%%/dijit/_editor/nls/he/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/he/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/he/commands.js +%%WWWDIR%%/dijit/_editor/nls/hu/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/hu/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/hu/commands.js +%%WWWDIR%%/dijit/_editor/nls/it/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/it/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/it/commands.js +%%WWWDIR%%/dijit/_editor/nls/ja/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ja/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ja/commands.js +%%WWWDIR%%/dijit/_editor/nls/ko/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ko/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ko/commands.js +%%WWWDIR%%/dijit/_editor/nls/nb/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/nb/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/nb/commands.js +%%WWWDIR%%/dijit/_editor/nls/nl/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/nl/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/nl/commands.js +%%WWWDIR%%/dijit/_editor/nls/pl/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/pl/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/pl/commands.js +%%WWWDIR%%/dijit/_editor/nls/pt-pt/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/pt-pt/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/pt-pt/commands.js +%%WWWDIR%%/dijit/_editor/nls/pt/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/pt/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/pt/commands.js +%%WWWDIR%%/dijit/_editor/nls/ru/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ru/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ru/commands.js +%%WWWDIR%%/dijit/_editor/nls/sk/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/sk/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/sk/commands.js +%%WWWDIR%%/dijit/_editor/nls/sl/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/sl/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/sl/commands.js +%%WWWDIR%%/dijit/_editor/nls/sv/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/sv/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/sv/commands.js +%%WWWDIR%%/dijit/_editor/nls/th/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/th/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/th/commands.js +%%WWWDIR%%/dijit/_editor/nls/tr/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/tr/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/tr/commands.js +%%WWWDIR%%/dijit/_editor/nls/zh-tw/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/zh-tw/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/zh-tw/commands.js +%%WWWDIR%%/dijit/_editor/nls/zh/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/zh/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/zh/commands.js +%%WWWDIR%%/dijit/_editor/plugins/AlwaysShowToolbar.js +%%WWWDIR%%/dijit/_editor/plugins/EnterKeyHandling.js +%%WWWDIR%%/dijit/_editor/plugins/FontChoice.js +%%WWWDIR%%/dijit/_editor/plugins/LinkDialog.js +%%WWWDIR%%/dijit/_editor/plugins/TabIndent.js +%%WWWDIR%%/dijit/_editor/plugins/TextColor.js +%%WWWDIR%%/dijit/_editor/plugins/ToggleDir.js +%%WWWDIR%%/dijit/_editor/range.js +%%WWWDIR%%/dijit/_editor/selection.js +%%WWWDIR%%/dijit/_tree/Node.html +%%WWWDIR%%/dijit/_tree/Tree.html +%%WWWDIR%%/dijit/_tree/dndContainer.js +%%WWWDIR%%/dijit/_tree/dndSelector.js +%%WWWDIR%%/dijit/_tree/dndSource.js +%%WWWDIR%%/dijit/_tree/model.js +%%WWWDIR%%/dijit/dijit-all.js +%%WWWDIR%%/dijit/dijit.js +%%WWWDIR%%/dijit/form/Button.js +%%WWWDIR%%/dijit/form/CheckBox.js +%%WWWDIR%%/dijit/form/ComboBox.js +%%WWWDIR%%/dijit/form/CurrencyTextBox.js +%%WWWDIR%%/dijit/form/DateTextBox.js +%%WWWDIR%%/dijit/form/FilteringSelect.js +%%WWWDIR%%/dijit/form/Form.js +%%WWWDIR%%/dijit/form/MultiSelect.js +%%WWWDIR%%/dijit/form/NumberSpinner.js +%%WWWDIR%%/dijit/form/NumberTextBox.js +%%WWWDIR%%/dijit/form/SimpleTextarea.js +%%WWWDIR%%/dijit/form/Slider.js +%%WWWDIR%%/dijit/form/TextBox.js +%%WWWDIR%%/dijit/form/Textarea.js +%%WWWDIR%%/dijit/form/TimeTextBox.js +%%WWWDIR%%/dijit/form/ValidationTextBox.js +%%WWWDIR%%/dijit/form/_DateTimeTextBox.js +%%WWWDIR%%/dijit/form/_FormWidget.js +%%WWWDIR%%/dijit/form/_Spinner.js +%%WWWDIR%%/dijit/form/nls/ComboBox.js +%%WWWDIR%%/dijit/form/nls/Textarea.js +%%WWWDIR%%/dijit/form/nls/ar/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ar/Textarea.js +%%WWWDIR%%/dijit/form/nls/ar/validate.js +%%WWWDIR%%/dijit/form/nls/ca/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ca/Textarea.js +%%WWWDIR%%/dijit/form/nls/ca/validate.js +%%WWWDIR%%/dijit/form/nls/cs/ComboBox.js +%%WWWDIR%%/dijit/form/nls/cs/Textarea.js +%%WWWDIR%%/dijit/form/nls/cs/validate.js +%%WWWDIR%%/dijit/form/nls/da/ComboBox.js +%%WWWDIR%%/dijit/form/nls/da/Textarea.js +%%WWWDIR%%/dijit/form/nls/da/validate.js +%%WWWDIR%%/dijit/form/nls/de/ComboBox.js +%%WWWDIR%%/dijit/form/nls/de/Textarea.js +%%WWWDIR%%/dijit/form/nls/de/validate.js +%%WWWDIR%%/dijit/form/nls/el/ComboBox.js +%%WWWDIR%%/dijit/form/nls/el/Textarea.js +%%WWWDIR%%/dijit/form/nls/el/validate.js +%%WWWDIR%%/dijit/form/nls/es/ComboBox.js +%%WWWDIR%%/dijit/form/nls/es/Textarea.js +%%WWWDIR%%/dijit/form/nls/es/validate.js +%%WWWDIR%%/dijit/form/nls/fi/ComboBox.js +%%WWWDIR%%/dijit/form/nls/fi/Textarea.js +%%WWWDIR%%/dijit/form/nls/fi/validate.js +%%WWWDIR%%/dijit/form/nls/fr/ComboBox.js +%%WWWDIR%%/dijit/form/nls/fr/Textarea.js +%%WWWDIR%%/dijit/form/nls/fr/validate.js +%%WWWDIR%%/dijit/form/nls/he/ComboBox.js +%%WWWDIR%%/dijit/form/nls/he/Textarea.js +%%WWWDIR%%/dijit/form/nls/he/validate.js +%%WWWDIR%%/dijit/form/nls/hu/ComboBox.js +%%WWWDIR%%/dijit/form/nls/hu/Textarea.js +%%WWWDIR%%/dijit/form/nls/hu/validate.js +%%WWWDIR%%/dijit/form/nls/it/ComboBox.js +%%WWWDIR%%/dijit/form/nls/it/Textarea.js +%%WWWDIR%%/dijit/form/nls/it/validate.js +%%WWWDIR%%/dijit/form/nls/ja/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ja/Textarea.js +%%WWWDIR%%/dijit/form/nls/ja/validate.js +%%WWWDIR%%/dijit/form/nls/ko/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ko/Textarea.js +%%WWWDIR%%/dijit/form/nls/ko/validate.js +%%WWWDIR%%/dijit/form/nls/nb/ComboBox.js +%%WWWDIR%%/dijit/form/nls/nb/Textarea.js +%%WWWDIR%%/dijit/form/nls/nb/validate.js +%%WWWDIR%%/dijit/form/nls/nl/ComboBox.js +%%WWWDIR%%/dijit/form/nls/nl/Textarea.js +%%WWWDIR%%/dijit/form/nls/nl/validate.js +%%WWWDIR%%/dijit/form/nls/pl/ComboBox.js +%%WWWDIR%%/dijit/form/nls/pl/Textarea.js +%%WWWDIR%%/dijit/form/nls/pl/validate.js +%%WWWDIR%%/dijit/form/nls/pt-pt/ComboBox.js +%%WWWDIR%%/dijit/form/nls/pt-pt/Textarea.js +%%WWWDIR%%/dijit/form/nls/pt-pt/validate.js +%%WWWDIR%%/dijit/form/nls/pt/ComboBox.js +%%WWWDIR%%/dijit/form/nls/pt/Textarea.js +%%WWWDIR%%/dijit/form/nls/pt/validate.js +%%WWWDIR%%/dijit/form/nls/ru/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ru/Textarea.js +%%WWWDIR%%/dijit/form/nls/ru/validate.js +%%WWWDIR%%/dijit/form/nls/sk/ComboBox.js +%%WWWDIR%%/dijit/form/nls/sk/Textarea.js +%%WWWDIR%%/dijit/form/nls/sk/validate.js +%%WWWDIR%%/dijit/form/nls/sl/ComboBox.js +%%WWWDIR%%/dijit/form/nls/sl/Textarea.js +%%WWWDIR%%/dijit/form/nls/sl/validate.js +%%WWWDIR%%/dijit/form/nls/sv/ComboBox.js +%%WWWDIR%%/dijit/form/nls/sv/Textarea.js +%%WWWDIR%%/dijit/form/nls/sv/validate.js +%%WWWDIR%%/dijit/form/nls/th/ComboBox.js +%%WWWDIR%%/dijit/form/nls/th/Textarea.js +%%WWWDIR%%/dijit/form/nls/th/validate.js +%%WWWDIR%%/dijit/form/nls/tr/ComboBox.js +%%WWWDIR%%/dijit/form/nls/tr/Textarea.js +%%WWWDIR%%/dijit/form/nls/tr/validate.js +%%WWWDIR%%/dijit/form/nls/validate.js +%%WWWDIR%%/dijit/form/nls/zh-tw/ComboBox.js +%%WWWDIR%%/dijit/form/nls/zh-tw/Textarea.js +%%WWWDIR%%/dijit/form/nls/zh-tw/validate.js +%%WWWDIR%%/dijit/form/nls/zh/ComboBox.js +%%WWWDIR%%/dijit/form/nls/zh/Textarea.js +%%WWWDIR%%/dijit/form/nls/zh/validate.js +%%WWWDIR%%/dijit/layout/AccordionContainer.js +%%WWWDIR%%/dijit/layout/BorderContainer.js +%%WWWDIR%%/dijit/layout/ContentPane.js +%%WWWDIR%%/dijit/layout/LayoutContainer.js +%%WWWDIR%%/dijit/layout/LinkPane.js +%%WWWDIR%%/dijit/layout/SplitContainer.js +%%WWWDIR%%/dijit/layout/StackContainer.js +%%WWWDIR%%/dijit/layout/TabContainer.js +%%WWWDIR%%/dijit/layout/_LayoutWidget.js +%%WWWDIR%%/dijit/nls/ar/common.js +%%WWWDIR%%/dijit/nls/ar/loading.js +%%WWWDIR%%/dijit/nls/ca/common.js +%%WWWDIR%%/dijit/nls/ca/loading.js +%%WWWDIR%%/dijit/nls/common.js +%%WWWDIR%%/dijit/nls/cs/common.js +%%WWWDIR%%/dijit/nls/cs/loading.js +%%WWWDIR%%/dijit/nls/da/common.js +%%WWWDIR%%/dijit/nls/da/loading.js +%%WWWDIR%%/dijit/nls/de/common.js +%%WWWDIR%%/dijit/nls/de/loading.js +%%WWWDIR%%/dijit/nls/dijit-all_ROOT.js +%%WWWDIR%%/dijit/nls/dijit-all_ar.js +%%WWWDIR%%/dijit/nls/dijit-all_ca.js +%%WWWDIR%%/dijit/nls/dijit-all_cs.js +%%WWWDIR%%/dijit/nls/dijit-all_da.js +%%WWWDIR%%/dijit/nls/dijit-all_de-de.js +%%WWWDIR%%/dijit/nls/dijit-all_de.js +%%WWWDIR%%/dijit/nls/dijit-all_el.js +%%WWWDIR%%/dijit/nls/dijit-all_en-gb.js +%%WWWDIR%%/dijit/nls/dijit-all_en-us.js +%%WWWDIR%%/dijit/nls/dijit-all_en.js +%%WWWDIR%%/dijit/nls/dijit-all_es-es.js +%%WWWDIR%%/dijit/nls/dijit-all_es.js +%%WWWDIR%%/dijit/nls/dijit-all_fi-fi.js +%%WWWDIR%%/dijit/nls/dijit-all_fi.js +%%WWWDIR%%/dijit/nls/dijit-all_fr-fr.js +%%WWWDIR%%/dijit/nls/dijit-all_fr.js +%%WWWDIR%%/dijit/nls/dijit-all_he-il.js +%%WWWDIR%%/dijit/nls/dijit-all_he.js +%%WWWDIR%%/dijit/nls/dijit-all_hu.js +%%WWWDIR%%/dijit/nls/dijit-all_it-it.js +%%WWWDIR%%/dijit/nls/dijit-all_it.js +%%WWWDIR%%/dijit/nls/dijit-all_ja-jp.js +%%WWWDIR%%/dijit/nls/dijit-all_ja.js +%%WWWDIR%%/dijit/nls/dijit-all_ko-kr.js +%%WWWDIR%%/dijit/nls/dijit-all_ko.js +%%WWWDIR%%/dijit/nls/dijit-all_nl-nl.js +%%WWWDIR%%/dijit/nls/dijit-all_nl.js +%%WWWDIR%%/dijit/nls/dijit-all_no.js +%%WWWDIR%%/dijit/nls/dijit-all_pl.js +%%WWWDIR%%/dijit/nls/dijit-all_pt-br.js +%%WWWDIR%%/dijit/nls/dijit-all_pt-pt.js +%%WWWDIR%%/dijit/nls/dijit-all_pt.js +%%WWWDIR%%/dijit/nls/dijit-all_ru.js +%%WWWDIR%%/dijit/nls/dijit-all_sk.js +%%WWWDIR%%/dijit/nls/dijit-all_sl.js +%%WWWDIR%%/dijit/nls/dijit-all_sv.js +%%WWWDIR%%/dijit/nls/dijit-all_th.js +%%WWWDIR%%/dijit/nls/dijit-all_tr.js +%%WWWDIR%%/dijit/nls/dijit-all_xx.js +%%WWWDIR%%/dijit/nls/dijit-all_zh-cn.js +%%WWWDIR%%/dijit/nls/dijit-all_zh-tw.js +%%WWWDIR%%/dijit/nls/dijit-all_zh.js +%%WWWDIR%%/dijit/nls/el/common.js +%%WWWDIR%%/dijit/nls/el/loading.js +%%WWWDIR%%/dijit/nls/es/common.js +%%WWWDIR%%/dijit/nls/es/loading.js +%%WWWDIR%%/dijit/nls/fi/common.js +%%WWWDIR%%/dijit/nls/fi/loading.js +%%WWWDIR%%/dijit/nls/fr/common.js +%%WWWDIR%%/dijit/nls/fr/loading.js +%%WWWDIR%%/dijit/nls/he/common.js +%%WWWDIR%%/dijit/nls/he/loading.js +%%WWWDIR%%/dijit/nls/hu/common.js +%%WWWDIR%%/dijit/nls/hu/loading.js +%%WWWDIR%%/dijit/nls/it/common.js +%%WWWDIR%%/dijit/nls/it/loading.js +%%WWWDIR%%/dijit/nls/ja/common.js +%%WWWDIR%%/dijit/nls/ja/loading.js +%%WWWDIR%%/dijit/nls/ko/common.js +%%WWWDIR%%/dijit/nls/ko/loading.js +%%WWWDIR%%/dijit/nls/loading.js +%%WWWDIR%%/dijit/nls/nb/common.js +%%WWWDIR%%/dijit/nls/nb/loading.js +%%WWWDIR%%/dijit/nls/nl/common.js +%%WWWDIR%%/dijit/nls/nl/loading.js +%%WWWDIR%%/dijit/nls/pl/common.js +%%WWWDIR%%/dijit/nls/pl/loading.js +%%WWWDIR%%/dijit/nls/pt-pt/common.js +%%WWWDIR%%/dijit/nls/pt-pt/loading.js +%%WWWDIR%%/dijit/nls/pt/common.js +%%WWWDIR%%/dijit/nls/pt/loading.js +%%WWWDIR%%/dijit/nls/ru/common.js +%%WWWDIR%%/dijit/nls/ru/loading.js +%%WWWDIR%%/dijit/nls/sk/common.js +%%WWWDIR%%/dijit/nls/sk/loading.js +%%WWWDIR%%/dijit/nls/sl/common.js +%%WWWDIR%%/dijit/nls/sl/loading.js +%%WWWDIR%%/dijit/nls/sv/common.js +%%WWWDIR%%/dijit/nls/sv/loading.js +%%WWWDIR%%/dijit/nls/th/common.js +%%WWWDIR%%/dijit/nls/th/loading.js +%%WWWDIR%%/dijit/nls/tr/common.js +%%WWWDIR%%/dijit/nls/tr/loading.js +%%WWWDIR%%/dijit/nls/zh-tw/common.js +%%WWWDIR%%/dijit/nls/zh-tw/loading.js +%%WWWDIR%%/dijit/nls/zh/common.js +%%WWWDIR%%/dijit/nls/zh/loading.js +%%WWWDIR%%/dijit/resources/_modules.js +%%WWWDIR%%/dijit/robot.js +%%WWWDIR%%/dijit/robotx.js +%%WWWDIR%%/dijit/themes/a11y/README.txt +%%WWWDIR%%/dijit/themes/a11y/colors3x4.png +%%WWWDIR%%/dijit/themes/a11y/colors7x10.png +%%WWWDIR%%/dijit/themes/a11y/indeterminate_progress.gif +%%WWWDIR%%/dijit/themes/dijit.css +%%WWWDIR%%/dijit/themes/dijit_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Calendar.css +%%WWWDIR%%/dijit/themes/nihilo/Calendar_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/ColorPalette.css +%%WWWDIR%%/dijit/themes/nihilo/Common.css +%%WWWDIR%%/dijit/themes/nihilo/Dialog.css +%%WWWDIR%%/dijit/themes/nihilo/Dialog_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Editor.css +%%WWWDIR%%/dijit/themes/nihilo/Editor_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Menu.css +%%WWWDIR%%/dijit/themes/nihilo/Menu_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/ProgressBar.css +%%WWWDIR%%/dijit/themes/nihilo/TimePicker.css +%%WWWDIR%%/dijit/themes/nihilo/TitlePane.css +%%WWWDIR%%/dijit/themes/nihilo/TitlePane_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Toolbar.css +%%WWWDIR%%/dijit/themes/nihilo/Tree.css +%%WWWDIR%%/dijit/themes/nihilo/Tree_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/Button.css +%%WWWDIR%%/dijit/themes/nihilo/form/Button_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/Checkbox.css +%%WWWDIR%%/dijit/themes/nihilo/form/ComboBox.css +%%WWWDIR%%/dijit/themes/nihilo/form/Common.css +%%WWWDIR%%/dijit/themes/nihilo/form/Common_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/RadioButton.css +%%WWWDIR%%/dijit/themes/nihilo/form/Slider.css +%%WWWDIR%%/dijit/themes/nihilo/form/Slider_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/TimeTextBox.css +%%WWWDIR%%/dijit/themes/nihilo/images/accordionItemActive.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonActive.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonDisabled.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonEnabled.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonHover.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndCopy.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndMove.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndNoCopy.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndNoMove.png +%%WWWDIR%%/dijit/themes/nihilo/images/editor.gif +%%WWWDIR%%/dijit/themes/nihilo/images/editorDisabled.gif +%%WWWDIR%%/dijit/themes/nihilo/images/editorDisabled_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/editor_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/no.gif +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumb.gif +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumbFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/progressBarAnim.gif +%%WWWDIR%%/dijit/themes/nihilo/images/progressBarEmpty.png +%%WWWDIR%%/dijit/themes/nihilo/images/progressBarFull.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderEmpty.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderEmptyVertical.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFull.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFullFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFullVertical.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFullVerticalFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumb.gif +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumbFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerH-thumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerH.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerV-thumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerV.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteArrows.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteArrows.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteCheckbox.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteCheckbox.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteDivIcons.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteDivIcons.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRadio.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRadio.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRoundedIconsSmall.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRoundedIconsSmall.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree_rtl.png +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomActiveC.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomActiveSpriteLR.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomEnabledC.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomEnabledSpriteLR.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomHoverC.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomHoverSpriteLR.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabContainerSprite.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabLeftChecked.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabRightChecked.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripe.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripeBottom.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripeLeft.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripeRight.gif +%%WWWDIR%%/dijit/themes/nihilo/images/titleBar.png +%%WWWDIR%%/dijit/themes/nihilo/images/titleBarActive.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorDown.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorDown.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorLeft.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorLeft.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorRight.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorRight.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorUp.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorUp.png +%%WWWDIR%%/dijit/themes/nihilo/images/treeExpand_loading.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI_half.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI_half_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/validationInputBg.gif +%%WWWDIR%%/dijit/themes/nihilo/images/validationInputBg.png +%%WWWDIR%%/dijit/themes/nihilo/images/warning.png +%%WWWDIR%%/dijit/themes/nihilo/layout/AccordionContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/AccordionContainer_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/layout/BorderContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/ContentPane.css +%%WWWDIR%%/dijit/themes/nihilo/layout/SplitContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/TabContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/TabContainer_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/nihilo.css +%%WWWDIR%%/dijit/themes/nihilo/nihilo_rtl.css +%%WWWDIR%%/dijit/themes/soria/Calendar.css +%%WWWDIR%%/dijit/themes/soria/Calendar_rtl.css +%%WWWDIR%%/dijit/themes/soria/ColorPalette.css +%%WWWDIR%%/dijit/themes/soria/Common.css +%%WWWDIR%%/dijit/themes/soria/Dialog.css +%%WWWDIR%%/dijit/themes/soria/Dialog_rtl.css +%%WWWDIR%%/dijit/themes/soria/Editor.css +%%WWWDIR%%/dijit/themes/soria/Editor_rtl.css +%%WWWDIR%%/dijit/themes/soria/Menu.css +%%WWWDIR%%/dijit/themes/soria/Menu_rtl.css +%%WWWDIR%%/dijit/themes/soria/ProgressBar.css +%%WWWDIR%%/dijit/themes/soria/TimePicker.css +%%WWWDIR%%/dijit/themes/soria/TitlePane.css +%%WWWDIR%%/dijit/themes/soria/TitlePane_rtl.css +%%WWWDIR%%/dijit/themes/soria/Toolbar.css +%%WWWDIR%%/dijit/themes/soria/Tree.css +%%WWWDIR%%/dijit/themes/soria/Tree_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/Button.css +%%WWWDIR%%/dijit/themes/soria/form/Button_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/Checkbox.css +%%WWWDIR%%/dijit/themes/soria/form/ComboBox.css +%%WWWDIR%%/dijit/themes/soria/form/Common.css +%%WWWDIR%%/dijit/themes/soria/form/Common_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/RadioButton.css +%%WWWDIR%%/dijit/themes/soria/form/Slider.css +%%WWWDIR%%/dijit/themes/soria/form/Slider_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/TimeTextBox.css +%%WWWDIR%%/dijit/themes/soria/images/accordionItemActive.gif +%%WWWDIR%%/dijit/themes/soria/images/accordionItemActive.png +%%WWWDIR%%/dijit/themes/soria/images/buttonActive.png +%%WWWDIR%%/dijit/themes/soria/images/buttonDisabled.png +%%WWWDIR%%/dijit/themes/soria/images/buttonEnabled.png +%%WWWDIR%%/dijit/themes/soria/images/buttonHover.png +%%WWWDIR%%/dijit/themes/soria/images/dndCopy.png +%%WWWDIR%%/dijit/themes/soria/images/dndMove.png +%%WWWDIR%%/dijit/themes/soria/images/dndNoCopy.png +%%WWWDIR%%/dijit/themes/soria/images/dndNoMove.png +%%WWWDIR%%/dijit/themes/soria/images/editor.gif +%%WWWDIR%%/dijit/themes/soria/images/editorDisabled.gif +%%WWWDIR%%/dijit/themes/soria/images/editorDisabled_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/editor_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumb.gif +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumb.png +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumbFocus.png +%%WWWDIR%%/dijit/themes/soria/images/progressBarAnim.gif +%%WWWDIR%%/dijit/themes/soria/images/progressBarEmpty.png +%%WWWDIR%%/dijit/themes/soria/images/progressBarFull.png +%%WWWDIR%%/dijit/themes/soria/images/sliderEmpty.png +%%WWWDIR%%/dijit/themes/soria/images/sliderEmptyVertical.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFull.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFullFocus.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFullVertical.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFullVerticalFocus.png +%%WWWDIR%%/dijit/themes/soria/images/sliderThumb.gif +%%WWWDIR%%/dijit/themes/soria/images/sliderThumb.png +%%WWWDIR%%/dijit/themes/soria/images/sliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/soria/images/sliderThumbFocus.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerH-thumb.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerH.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerV-thumb.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerV.png +%%WWWDIR%%/dijit/themes/soria/images/spriteArrows.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteArrows.png +%%WWWDIR%%/dijit/themes/soria/images/spriteCheckbox.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteCheckbox.png +%%WWWDIR%%/dijit/themes/soria/images/spriteDivIcons.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteDivIcons.png +%%WWWDIR%%/dijit/themes/soria/images/spriteRadio.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteRadio.png +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmall.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmall.png +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmallBl.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmallBl.png +%%WWWDIR%%/dijit/themes/soria/images/spriteTree.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteTree.png +%%WWWDIR%%/dijit/themes/soria/images/spriteTree_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteTree_rtl.png +%%WWWDIR%%/dijit/themes/soria/images/tabBottomActiveC.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomActiveSpriteLR.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomEnabledC.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomEnabledSpriteLR.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomHoverC.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomHoverSpriteLR.gif +%%WWWDIR%%/dijit/themes/soria/images/tabContainerSprite.gif +%%WWWDIR%%/dijit/themes/soria/images/tabLeftChecked.gif +%%WWWDIR%%/dijit/themes/soria/images/tabRightChecked.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripe.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripeBottom.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripeLeft.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripeRight.gif +%%WWWDIR%%/dijit/themes/soria/images/titleBar.png +%%WWWDIR%%/dijit/themes/soria/images/titleBarActive.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorDown.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorDown.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorLeft.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorLeft.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorRight.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorRight.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorUp.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorUp.png +%%WWWDIR%%/dijit/themes/soria/images/treeExpand_loading.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI_half.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI_half_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/validationInputBg.gif +%%WWWDIR%%/dijit/themes/soria/images/validationInputBg.png +%%WWWDIR%%/dijit/themes/soria/images/warning.png +%%WWWDIR%%/dijit/themes/soria/layout/AccordionContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/AccordionContainer_rtl.css +%%WWWDIR%%/dijit/themes/soria/layout/BorderContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/ContentPane.css +%%WWWDIR%%/dijit/themes/soria/layout/SplitContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/TabContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/TabContainer_rtl.css +%%WWWDIR%%/dijit/themes/soria/soria.css +%%WWWDIR%%/dijit/themes/soria/soria_rtl.css +%%WWWDIR%%/dijit/themes/templateThemeTest.html +%%WWWDIR%%/dijit/themes/themeTester.html +%%WWWDIR%%/dijit/themes/themeTesterImages/blackButtonEnabled.gif +%%WWWDIR%%/dijit/themes/themeTesterImages/blackButtonHover.gif +%%WWWDIR%%/dijit/themes/themeTesterQuirk.html +%%WWWDIR%%/dijit/themes/tundra/Calendar.css +%%WWWDIR%%/dijit/themes/tundra/Calendar_rtl.css +%%WWWDIR%%/dijit/themes/tundra/ColorPalette.css +%%WWWDIR%%/dijit/themes/tundra/Common.css +%%WWWDIR%%/dijit/themes/tundra/Dialog.css +%%WWWDIR%%/dijit/themes/tundra/Dialog_rtl.css +%%WWWDIR%%/dijit/themes/tundra/Editor.css +%%WWWDIR%%/dijit/themes/tundra/Editor_rtl.css +%%WWWDIR%%/dijit/themes/tundra/Menu.css +%%WWWDIR%%/dijit/themes/tundra/Menu_rtl.css +%%WWWDIR%%/dijit/themes/tundra/ProgressBar.css +%%WWWDIR%%/dijit/themes/tundra/TimePicker.css +%%WWWDIR%%/dijit/themes/tundra/TitlePane.css +%%WWWDIR%%/dijit/themes/tundra/TitlePane_rtl.css +%%WWWDIR%%/dijit/themes/tundra/Toolbar.css +%%WWWDIR%%/dijit/themes/tundra/Tree.css +%%WWWDIR%%/dijit/themes/tundra/Tree_rtl.css +%%WWWDIR%%/dijit/themes/tundra/form/Button.css +%%WWWDIR%%/dijit/themes/tundra/form/Checkbox.css +%%WWWDIR%%/dijit/themes/tundra/form/Common.css +%%WWWDIR%%/dijit/themes/tundra/form/Common_rtl.css +%%WWWDIR%%/dijit/themes/tundra/form/RadioButton.css +%%WWWDIR%%/dijit/themes/tundra/form/Slider.css +%%WWWDIR%%/dijit/themes/tundra/form/Slider_rtl.css +%%WWWDIR%%/dijit/themes/tundra/images/accordionItemActive.gif +%%WWWDIR%%/dijit/themes/tundra/images/accordionItemHover.gif +%%WWWDIR%%/dijit/themes/tundra/images/buttonActive.png +%%WWWDIR%%/dijit/themes/tundra/images/buttonDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/buttonEnabled.png +%%WWWDIR%%/dijit/themes/tundra/images/buttonHover.png +%%WWWDIR%%/dijit/themes/tundra/images/calendarDayLabel.png +%%WWWDIR%%/dijit/themes/tundra/images/calendarMonthLabel.png +%%WWWDIR%%/dijit/themes/tundra/images/calendarYearLabel.png +%%WWWDIR%%/dijit/themes/tundra/images/checkmark.gif +%%WWWDIR%%/dijit/themes/tundra/images/checkmark.png +%%WWWDIR%%/dijit/themes/tundra/images/checkmarkNoBorder.gif +%%WWWDIR%%/dijit/themes/tundra/images/checkmarkNoBorder.png +%%WWWDIR%%/dijit/themes/tundra/images/circleIcon.gif +%%WWWDIR%%/dijit/themes/tundra/images/circleIcon.png +%%WWWDIR%%/dijit/themes/tundra/images/comboArrowDown.gif +%%WWWDIR%%/dijit/themes/tundra/images/dijitProgressBarAnim.gif +%%WWWDIR%%/dijit/themes/tundra/images/dijitProgressBarAnim.psd +%%WWWDIR%%/dijit/themes/tundra/images/dndCopy.png +%%WWWDIR%%/dijit/themes/tundra/images/dndMove.png +%%WWWDIR%%/dijit/themes/tundra/images/dndNoCopy.png +%%WWWDIR%%/dijit/themes/tundra/images/dndNoMove.png +%%WWWDIR%%/dijit/themes/tundra/images/dojoTundraGradientBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/dojoTundraGradientBg.png +%%WWWDIR%%/dijit/themes/tundra/images/doubleArrowDown.png +%%WWWDIR%%/dijit/themes/tundra/images/doubleArrowUp.png +%%WWWDIR%%/dijit/themes/tundra/images/editor.gif +%%WWWDIR%%/dijit/themes/tundra/images/editorDisabled.gif +%%WWWDIR%%/dijit/themes/tundra/images/editorDisabled_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/editor_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/folderClosed.gif +%%WWWDIR%%/dijit/themes/tundra/images/folderOpened.gif +%%WWWDIR%%/dijit/themes/tundra/images/i.gif +%%WWWDIR%%/dijit/themes/tundra/images/i_half.gif +%%WWWDIR%%/dijit/themes/tundra/images/i_half_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/i_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/leaf.gif +%%WWWDIR%%/dijit/themes/tundra/images/loading.gif +%%WWWDIR%%/dijit/themes/tundra/images/menu.png +%%WWWDIR%%/dijit/themes/tundra/images/minusButton.gif +%%WWWDIR%%/dijit/themes/tundra/images/no.gif +%%WWWDIR%%/dijit/themes/tundra/images/noX.gif +%%WWWDIR%%/dijit/themes/tundra/images/plusButton.gif +%%WWWDIR%%/dijit/themes/tundra/images/popupMenuBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumb.gif +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumb.png +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumbFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-1.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-2.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-3.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-4.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-5.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-6.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-7.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-8.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-9.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim.gif +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim.psd +%%WWWDIR%%/dijit/themes/tundra/images/progressBarEmpty.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarFull.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonActive.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonActiveDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonActiveHover.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonEnabled.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonHover.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderEmpty.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderEmptyVertical.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFull.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFullFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFullVertical.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFullVerticalFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderThumb.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/tundra/images/sliderThumbFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/smallArrowDown.png +%%WWWDIR%%/dijit/themes/tundra/images/smallArrowUp.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerH-thumb.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerH.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerV-thumb.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerV.png +%%WWWDIR%%/dijit/themes/tundra/images/spriteArrows.gif +%%WWWDIR%%/dijit/themes/tundra/images/spriteArrows.png +%%WWWDIR%%/dijit/themes/tundra/images/spriteRoundedIconsSmall.gif +%%WWWDIR%%/dijit/themes/tundra/images/spriteRoundedIconsSmall.png +%%WWWDIR%%/dijit/themes/tundra/images/tabActive.png +%%WWWDIR%%/dijit/themes/tundra/images/tabClose.gif +%%WWWDIR%%/dijit/themes/tundra/images/tabClose.png +%%WWWDIR%%/dijit/themes/tundra/images/tabCloseHover.gif +%%WWWDIR%%/dijit/themes/tundra/images/tabCloseHover.png +%%WWWDIR%%/dijit/themes/tundra/images/tabDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/tabEnabled.png +%%WWWDIR%%/dijit/themes/tundra/images/tabHover.gif +%%WWWDIR%%/dijit/themes/tundra/images/tabHover.png +%%WWWDIR%%/dijit/themes/tundra/images/titleBar.png +%%WWWDIR%%/dijit/themes/tundra/images/titleBarBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorDown.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorDown.png +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorLeft.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorLeft.png +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorRight.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorRight.png +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorUp.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorUp.png +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_leaf.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_leaf_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_loading.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_minus.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_minus_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_mius.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_plus.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_plus_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/validationInputBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/validationInputBg.png +%%WWWDIR%%/dijit/themes/tundra/images/warning.png +%%WWWDIR%%/dijit/themes/tundra/layout/AccordionContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/BorderContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/ContentPane.css +%%WWWDIR%%/dijit/themes/tundra/layout/SplitContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/TabContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/TabContainer_rtl.css +%%WWWDIR%%/dijit/themes/tundra/tundra.css +%%WWWDIR%%/dojo/AdapterRegistry.js +%%WWWDIR%%/dojo/DeferredList.js +%%WWWDIR%%/dojo/LICENSE +%%WWWDIR%%/dojo/NodeList-fx.js +%%WWWDIR%%/dojo/NodeList-html.js +%%WWWDIR%%/dojo/OpenAjax.js +%%WWWDIR%%/dojo/_base.js +%%WWWDIR%%/dojo/_base/Color.js +%%WWWDIR%%/dojo/_base/Deferred.js +%%WWWDIR%%/dojo/_base/NodeList.js +%%WWWDIR%%/dojo/_base/_loader/bootstrap.js +%%WWWDIR%%/dojo/_base/_loader/hostenv_browser.js +%%WWWDIR%%/dojo/_base/_loader/hostenv_rhino.js +%%WWWDIR%%/dojo/_base/_loader/hostenv_spidermonkey.js +%%WWWDIR%%/dojo/_base/_loader/loader.js +%%WWWDIR%%/dojo/_base/_loader/loader_debug.js +%%WWWDIR%%/dojo/_base/_loader/loader_xd.js +%%WWWDIR%%/dojo/_base/array.js +%%WWWDIR%%/dojo/_base/browser.js +%%WWWDIR%%/dojo/_base/connect.js +%%WWWDIR%%/dojo/_base/declare.js +%%WWWDIR%%/dojo/_base/event.js +%%WWWDIR%%/dojo/_base/fx.js +%%WWWDIR%%/dojo/_base/html.js +%%WWWDIR%%/dojo/_base/json.js +%%WWWDIR%%/dojo/_base/lang.js +%%WWWDIR%%/dojo/_base/query.js +%%WWWDIR%%/dojo/_base/window.js +%%WWWDIR%%/dojo/_base/xhr.js +%%WWWDIR%%/dojo/_firebug/LICENSE +%%WWWDIR%%/dojo/_firebug/errorIcon.png +%%WWWDIR%%/dojo/_firebug/firebug.css +%%WWWDIR%%/dojo/_firebug/firebug.js +%%WWWDIR%%/dojo/_firebug/infoIcon.png +%%WWWDIR%%/dojo/_firebug/tab_lft_norm.png +%%WWWDIR%%/dojo/_firebug/tab_lft_over.png +%%WWWDIR%%/dojo/_firebug/tab_rgt_norm.png +%%WWWDIR%%/dojo/_firebug/tab_rgt_over.png +%%WWWDIR%%/dojo/_firebug/warningIcon.png +%%WWWDIR%%/dojo/back.js +%%WWWDIR%%/dojo/behavior.js +%%WWWDIR%%/dojo/build.txt +%%WWWDIR%%/dojo/cldr/LICENSE +%%WWWDIR%%/dojo/cldr/README +%%WWWDIR%%/dojo/cldr/monetary.js +%%WWWDIR%%/dojo/cldr/nls/currency.js +%%WWWDIR%%/dojo/cldr/nls/de-de/number.js +%%WWWDIR%%/dojo/cldr/nls/de/currency.js +%%WWWDIR%%/dojo/cldr/nls/de/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/de/number.js +%%WWWDIR%%/dojo/cldr/nls/en-au/currency.js +%%WWWDIR%%/dojo/cldr/nls/en-au/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en-au/number.js +%%WWWDIR%%/dojo/cldr/nls/en-ca/currency.js +%%WWWDIR%%/dojo/cldr/nls/en-ca/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en-gb/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en-gb/number.js +%%WWWDIR%%/dojo/cldr/nls/en-us/currency.js +%%WWWDIR%%/dojo/cldr/nls/en-us/number.js +%%WWWDIR%%/dojo/cldr/nls/en/currency.js +%%WWWDIR%%/dojo/cldr/nls/en/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en/number.js +%%WWWDIR%%/dojo/cldr/nls/es-es/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/es-es/number.js +%%WWWDIR%%/dojo/cldr/nls/es/currency.js +%%WWWDIR%%/dojo/cldr/nls/es/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/es/number.js +%%WWWDIR%%/dojo/cldr/nls/fr/currency.js +%%WWWDIR%%/dojo/cldr/nls/fr/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/fr/number.js +%%WWWDIR%%/dojo/cldr/nls/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/it-it/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/it/currency.js +%%WWWDIR%%/dojo/cldr/nls/it/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/it/number.js +%%WWWDIR%%/dojo/cldr/nls/ja-jp/number.js +%%WWWDIR%%/dojo/cldr/nls/ja/currency.js +%%WWWDIR%%/dojo/cldr/nls/ja/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/ja/number.js +%%WWWDIR%%/dojo/cldr/nls/ko-kr/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/ko-kr/number.js +%%WWWDIR%%/dojo/cldr/nls/ko/currency.js +%%WWWDIR%%/dojo/cldr/nls/ko/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/ko/number.js +%%WWWDIR%%/dojo/cldr/nls/number.js +%%WWWDIR%%/dojo/cldr/nls/pt-br/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/pt/currency.js +%%WWWDIR%%/dojo/cldr/nls/pt/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/pt/number.js +%%WWWDIR%%/dojo/cldr/nls/zh-cn/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/zh-cn/number.js +%%WWWDIR%%/dojo/cldr/nls/zh-tw/currency.js +%%WWWDIR%%/dojo/cldr/nls/zh-tw/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/zh-tw/number.js +%%WWWDIR%%/dojo/cldr/nls/zh/currency.js +%%WWWDIR%%/dojo/cldr/nls/zh/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/zh/number.js +%%WWWDIR%%/dojo/cldr/supplemental.js +%%WWWDIR%%/dojo/colors.js +%%WWWDIR%%/dojo/cookie.js +%%WWWDIR%%/dojo/currency.js +%%WWWDIR%%/dojo/data/ItemFileReadStore.js +%%WWWDIR%%/dojo/data/ItemFileWriteStore.js +%%WWWDIR%%/dojo/data/api/Identity.js +%%WWWDIR%%/dojo/data/api/Notification.js +%%WWWDIR%%/dojo/data/api/Read.js +%%WWWDIR%%/dojo/data/api/Request.js +%%WWWDIR%%/dojo/data/api/Write.js +%%WWWDIR%%/dojo/data/util/filter.js +%%WWWDIR%%/dojo/data/util/simpleFetch.js +%%WWWDIR%%/dojo/data/util/sorter.js +%%WWWDIR%%/dojo/date.js +%%WWWDIR%%/dojo/date/locale.js +%%WWWDIR%%/dojo/date/stamp.js +%%WWWDIR%%/dojo/dnd/Avatar.js +%%WWWDIR%%/dojo/dnd/Container.js +%%WWWDIR%%/dojo/dnd/Manager.js +%%WWWDIR%%/dojo/dnd/Moveable.js +%%WWWDIR%%/dojo/dnd/Mover.js +%%WWWDIR%%/dojo/dnd/Selector.js +%%WWWDIR%%/dojo/dnd/Source.js +%%WWWDIR%%/dojo/dnd/TimedMoveable.js +%%WWWDIR%%/dojo/dnd/autoscroll.js +%%WWWDIR%%/dojo/dnd/common.js +%%WWWDIR%%/dojo/dnd/move.js +%%WWWDIR%%/dojo/dojo.js +%%WWWDIR%%/dojo/fx.js +%%WWWDIR%%/dojo/fx/easing.js +%%WWWDIR%%/dojo/gears.js +%%WWWDIR%%/dojo/html.js +%%WWWDIR%%/dojo/i18n.js +%%WWWDIR%%/dojo/io/iframe.js +%%WWWDIR%%/dojo/io/script.js +%%WWWDIR%%/dojo/jaxer.js +%%WWWDIR%%/dojo/nls/ar/colors.js +%%WWWDIR%%/dojo/nls/ca/colors.js +%%WWWDIR%%/dojo/nls/colors.js +%%WWWDIR%%/dojo/nls/cs/colors.js +%%WWWDIR%%/dojo/nls/da/colors.js +%%WWWDIR%%/dojo/nls/de/colors.js +%%WWWDIR%%/dojo/nls/el/colors.js +%%WWWDIR%%/dojo/nls/es/colors.js +%%WWWDIR%%/dojo/nls/fi/colors.js +%%WWWDIR%%/dojo/nls/fr/colors.js +%%WWWDIR%%/dojo/nls/he/colors.js +%%WWWDIR%%/dojo/nls/hu/colors.js +%%WWWDIR%%/dojo/nls/it/colors.js +%%WWWDIR%%/dojo/nls/ja/colors.js +%%WWWDIR%%/dojo/nls/ko/colors.js +%%WWWDIR%%/dojo/nls/nb/colors.js +%%WWWDIR%%/dojo/nls/nl/colors.js +%%WWWDIR%%/dojo/nls/pl/colors.js +%%WWWDIR%%/dojo/nls/pt-pt/colors.js +%%WWWDIR%%/dojo/nls/pt/colors.js +%%WWWDIR%%/dojo/nls/ru/colors.js +%%WWWDIR%%/dojo/nls/sk/colors.js +%%WWWDIR%%/dojo/nls/sl/colors.js +%%WWWDIR%%/dojo/nls/sv/colors.js +%%WWWDIR%%/dojo/nls/th/colors.js +%%WWWDIR%%/dojo/nls/tr/colors.js +%%WWWDIR%%/dojo/nls/zh-tw/colors.js +%%WWWDIR%%/dojo/nls/zh/colors.js +%%WWWDIR%%/dojo/number.js +%%WWWDIR%%/dojo/parser.js +%%WWWDIR%%/dojo/regexp.js +%%WWWDIR%%/dojo/resources/LICENSE +%%WWWDIR%%/dojo/resources/_modules.js +%%WWWDIR%%/dojo/resources/blank.gif +%%WWWDIR%%/dojo/resources/blank.html +%%WWWDIR%%/dojo/resources/dnd.css +%%WWWDIR%%/dojo/resources/dojo.css +%%WWWDIR%%/dojo/resources/iframe_history.html +%%WWWDIR%%/dojo/resources/images/dndCopy.png +%%WWWDIR%%/dojo/resources/images/dndMove.png +%%WWWDIR%%/dojo/resources/images/dndNoCopy.png +%%WWWDIR%%/dojo/resources/images/dndNoMove.png +%%WWWDIR%%/dojo/robot.js +%%WWWDIR%%/dojo/robotx.js +%%WWWDIR%%/dojo/rpc/JsonService.js +%%WWWDIR%%/dojo/rpc/JsonpService.js +%%WWWDIR%%/dojo/rpc/RpcService.js +%%WWWDIR%%/dojo/string.js +%%WWWDIR%%/dojox/LICENSE +%%WWWDIR%%/dojox/analytics.js +%%WWWDIR%%/dojox/analytics/README +%%WWWDIR%%/dojox/analytics/Urchin.js +%%WWWDIR%%/dojox/analytics/_base.js +%%WWWDIR%%/dojox/analytics/logger/JSON.php +%%WWWDIR%%/dojox/analytics/logger/dojoxAnalytics.php +%%WWWDIR%%/dojox/analytics/plugins/consoleMessages.js +%%WWWDIR%%/dojox/analytics/plugins/dojo.js +%%WWWDIR%%/dojox/analytics/plugins/idle.js +%%WWWDIR%%/dojox/analytics/plugins/mouseClick.js +%%WWWDIR%%/dojox/analytics/plugins/mouseOver.js +%%WWWDIR%%/dojox/analytics/plugins/window.js +%%WWWDIR%%/dojox/analytics/profiles/analytics.profile.js +%%WWWDIR%%/dojox/analytics/profiles/analyticsInBase.profile.js +%%WWWDIR%%/dojox/av/FLVideo.js +%%WWWDIR%%/dojox/av/README +%%WWWDIR%%/dojox/av/_Media.js +%%WWWDIR%%/dojox/av/resources/version.mov +%%WWWDIR%%/dojox/av/resources/video.swf +%%WWWDIR%%/dojox/av/widget/PlayButton.js +%%WWWDIR%%/dojox/av/widget/Player.js +%%WWWDIR%%/dojox/av/widget/ProgressSlider.js +%%WWWDIR%%/dojox/av/widget/Status.js +%%WWWDIR%%/dojox/av/widget/VolumeButton.js +%%WWWDIR%%/dojox/av/widget/resources/PlayButton.html +%%WWWDIR%%/dojox/av/widget/resources/Player.css +%%WWWDIR%%/dojox/av/widget/resources/Player.html +%%WWWDIR%%/dojox/av/widget/resources/ProgressSlider.html +%%WWWDIR%%/dojox/av/widget/resources/Status.html +%%WWWDIR%%/dojox/av/widget/resources/VolumeButton.html +%%WWWDIR%%/dojox/av/widget/resources/images/dojoPlayerIcons.png +%%WWWDIR%%/dojox/av/widget/resources/images/playerIcons +%%WWWDIR%%/dojox/av/widget/resources/images/player_sprite.png +%%WWWDIR%%/dojox/av/widget/resources/images/progressLoadedBk.png +%%WWWDIR%%/dojox/av/widget/resources/images/progressPositionBk.png +%%WWWDIR%%/dojox/av/widget/resources/images/sliderHandleNorm.png +%%WWWDIR%%/dojox/av/widget/resources/images/sliderHandleOver.png +%%WWWDIR%%/dojox/av/widget/resources/images/sliderHandleSprite.png +%%WWWDIR%%/dojox/charting/Chart2D.js +%%WWWDIR%%/dojox/charting/Chart3D.js +%%WWWDIR%%/dojox/charting/Element.js +%%WWWDIR%%/dojox/charting/README +%%WWWDIR%%/dojox/charting/Series.js +%%WWWDIR%%/dojox/charting/Theme.js +%%WWWDIR%%/dojox/charting/action2d/Base.js +%%WWWDIR%%/dojox/charting/action2d/Highlight.js +%%WWWDIR%%/dojox/charting/action2d/Magnify.js +%%WWWDIR%%/dojox/charting/action2d/MoveSlice.js +%%WWWDIR%%/dojox/charting/action2d/Shake.js +%%WWWDIR%%/dojox/charting/action2d/Tooltip.js +%%WWWDIR%%/dojox/charting/axis2d/Base.js +%%WWWDIR%%/dojox/charting/axis2d/Default.js +%%WWWDIR%%/dojox/charting/axis2d/common.js +%%WWWDIR%%/dojox/charting/plot2d/Areas.js +%%WWWDIR%%/dojox/charting/plot2d/Bars.js +%%WWWDIR%%/dojox/charting/plot2d/Base.js +%%WWWDIR%%/dojox/charting/plot2d/Bubble.js +%%WWWDIR%%/dojox/charting/plot2d/ClusteredBars.js +%%WWWDIR%%/dojox/charting/plot2d/ClusteredColumns.js +%%WWWDIR%%/dojox/charting/plot2d/Columns.js +%%WWWDIR%%/dojox/charting/plot2d/Default.js +%%WWWDIR%%/dojox/charting/plot2d/Grid.js +%%WWWDIR%%/dojox/charting/plot2d/Lines.js +%%WWWDIR%%/dojox/charting/plot2d/Markers.js +%%WWWDIR%%/dojox/charting/plot2d/MarkersOnly.js +%%WWWDIR%%/dojox/charting/plot2d/Pie.js +%%WWWDIR%%/dojox/charting/plot2d/Scatter.js +%%WWWDIR%%/dojox/charting/plot2d/Stacked.js +%%WWWDIR%%/dojox/charting/plot2d/StackedAreas.js +%%WWWDIR%%/dojox/charting/plot2d/StackedBars.js +%%WWWDIR%%/dojox/charting/plot2d/StackedColumns.js +%%WWWDIR%%/dojox/charting/plot2d/StackedLines.js +%%WWWDIR%%/dojox/charting/plot2d/common.js +%%WWWDIR%%/dojox/charting/plot3d/Bars.js +%%WWWDIR%%/dojox/charting/plot3d/Base.js +%%WWWDIR%%/dojox/charting/plot3d/Cylinders.js +%%WWWDIR%%/dojox/charting/scaler/common.js +%%WWWDIR%%/dojox/charting/scaler/linear.js +%%WWWDIR%%/dojox/charting/scaler/primitive.js +%%WWWDIR%%/dojox/charting/themes/Adobebricks.js +%%WWWDIR%%/dojox/charting/themes/Algae.js +%%WWWDIR%%/dojox/charting/themes/Bahamation.js +%%WWWDIR%%/dojox/charting/themes/BlueDusk.js +%%WWWDIR%%/dojox/charting/themes/CubanShirts.js +%%WWWDIR%%/dojox/charting/themes/Desert.js +%%WWWDIR%%/dojox/charting/themes/Dollar.js +%%WWWDIR%%/dojox/charting/themes/ET/greys.js +%%WWWDIR%%/dojox/charting/themes/Grasshopper.js +%%WWWDIR%%/dojox/charting/themes/Grasslands.js +%%WWWDIR%%/dojox/charting/themes/GreySkies.js +%%WWWDIR%%/dojox/charting/themes/IndigoNation.js +%%WWWDIR%%/dojox/charting/themes/Ireland.js +%%WWWDIR%%/dojox/charting/themes/MiamiNice.js +%%WWWDIR%%/dojox/charting/themes/Midwest.js +%%WWWDIR%%/dojox/charting/themes/Minty.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/README +%%WWWDIR%%/dojox/charting/themes/PlotKit/blue.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/cyan.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/green.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/orange.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/purple.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/red.js +%%WWWDIR%%/dojox/charting/themes/PurpleRain.js +%%WWWDIR%%/dojox/charting/themes/README +%%WWWDIR%%/dojox/charting/themes/RoyalPurples.js +%%WWWDIR%%/dojox/charting/themes/SageToLime.js +%%WWWDIR%%/dojox/charting/themes/Shrooms.js +%%WWWDIR%%/dojox/charting/themes/Tufte.js +%%WWWDIR%%/dojox/charting/themes/WatersEdge.js +%%WWWDIR%%/dojox/charting/themes/Wetland.js +%%WWWDIR%%/dojox/charting/widget/Chart2D.js +%%WWWDIR%%/dojox/charting/widget/Legend.js +%%WWWDIR%%/dojox/charting/widget/Sparkline.js +%%WWWDIR%%/dojox/collections.js +%%WWWDIR%%/dojox/collections/ArrayList.js +%%WWWDIR%%/dojox/collections/BinaryTree.js +%%WWWDIR%%/dojox/collections/Dictionary.js +%%WWWDIR%%/dojox/collections/Queue.js +%%WWWDIR%%/dojox/collections/README +%%WWWDIR%%/dojox/collections/Set.js +%%WWWDIR%%/dojox/collections/SortedList.js +%%WWWDIR%%/dojox/collections/Stack.js +%%WWWDIR%%/dojox/collections/_base.js +%%WWWDIR%%/dojox/color.js +%%WWWDIR%%/dojox/color/Colorspace.js +%%WWWDIR%%/dojox/color/Generator.js +%%WWWDIR%%/dojox/color/Palette.js +%%WWWDIR%%/dojox/color/README +%%WWWDIR%%/dojox/color/_base.js +%%WWWDIR%%/dojox/cometd.js +%%WWWDIR%%/dojox/cometd/HttpChannels.js +%%WWWDIR%%/dojox/cometd/README +%%WWWDIR%%/dojox/cometd/RestChannels.js +%%WWWDIR%%/dojox/cometd/_base.js +%%WWWDIR%%/dojox/cometd/callbackPollTransport.js +%%WWWDIR%%/dojox/cometd/longPollTransport.js +%%WWWDIR%%/dojox/cometd/longPollTransportFormEncoded.js +%%WWWDIR%%/dojox/cometd/longPollTransportJsonEncoded.js +%%WWWDIR%%/dojox/cometd/timestamp.js +%%WWWDIR%%/dojox/cometd/timesync.js +%%WWWDIR%%/dojox/data/AndOrReadStore.js +%%WWWDIR%%/dojox/data/AndOrWriteStore.js +%%WWWDIR%%/dojox/data/AtomReadStore.js +%%WWWDIR%%/dojox/data/ClientFilter.js +%%WWWDIR%%/dojox/data/CouchDBRestStore.js +%%WWWDIR%%/dojox/data/CssClassStore.js +%%WWWDIR%%/dojox/data/CssRuleStore.js +%%WWWDIR%%/dojox/data/CsvStore.js +%%WWWDIR%%/dojox/data/FileStore.js +%%WWWDIR%%/dojox/data/FlickrRestStore.js +%%WWWDIR%%/dojox/data/FlickrStore.js +%%WWWDIR%%/dojox/data/GoogleFeedStore.js +%%WWWDIR%%/dojox/data/GoogleSearchStore.js +%%WWWDIR%%/dojox/data/HtmlStore.js +%%WWWDIR%%/dojox/data/HtmlTableStore.js +%%WWWDIR%%/dojox/data/JsonRestStore.js +%%WWWDIR%%/dojox/data/KeyValueStore.js +%%WWWDIR%%/dojox/data/OpmlStore.js +%%WWWDIR%%/dojox/data/PersevereStore.js +%%WWWDIR%%/dojox/data/PicasaStore.js +%%WWWDIR%%/dojox/data/QueryReadStore.js +%%WWWDIR%%/dojox/data/README +%%WWWDIR%%/dojox/data/S3Store.js +%%WWWDIR%%/dojox/data/ServiceStore.js +%%WWWDIR%%/dojox/data/SnapLogicStore.js +%%WWWDIR%%/dojox/data/WikipediaStore.js +%%WWWDIR%%/dojox/data/XmlStore.js +%%WWWDIR%%/dojox/data/css.js +%%WWWDIR%%/dojox/data/dom.js +%%WWWDIR%%/dojox/data/jsonPathStore.js +%%WWWDIR%%/dojox/data/restListener.js +%%WWWDIR%%/dojox/data/s3/README +%%WWWDIR%%/dojox/data/s3/proxy.example-php +%%WWWDIR%%/dojox/date/HebrewDate.js +%%WWWDIR%%/dojox/date/IslamicDate.js +%%WWWDIR%%/dojox/date/README +%%WWWDIR%%/dojox/date/php.js +%%WWWDIR%%/dojox/date/posix.js +%%WWWDIR%%/dojox/dtl.js +%%WWWDIR%%/dojox/dtl/Context.js +%%WWWDIR%%/dojox/dtl/README +%%WWWDIR%%/dojox/dtl/_HtmlTemplated.js +%%WWWDIR%%/dojox/dtl/_Templated.js +%%WWWDIR%%/dojox/dtl/_base.js +%%WWWDIR%%/dojox/dtl/contrib/data.js +%%WWWDIR%%/dojox/dtl/contrib/dijit.js +%%WWWDIR%%/dojox/dtl/contrib/html.js +%%WWWDIR%%/dojox/dtl/contrib/objects.js +%%WWWDIR%%/dojox/dtl/ext-dojo/NodeList.js +%%WWWDIR%%/dojox/dtl/filter/dates.js +%%WWWDIR%%/dojox/dtl/filter/htmlstrings.js +%%WWWDIR%%/dojox/dtl/filter/integers.js +%%WWWDIR%%/dojox/dtl/filter/lists.js +%%WWWDIR%%/dojox/dtl/filter/logic.js +%%WWWDIR%%/dojox/dtl/filter/misc.js +%%WWWDIR%%/dojox/dtl/filter/strings.js +%%WWWDIR%%/dojox/dtl/html.js +%%WWWDIR%%/dojox/dtl/render/html.js +%%WWWDIR%%/dojox/dtl/tag/date.js +%%WWWDIR%%/dojox/dtl/tag/loader.js +%%WWWDIR%%/dojox/dtl/tag/logic.js +%%WWWDIR%%/dojox/dtl/tag/loop.js +%%WWWDIR%%/dojox/dtl/tag/misc.js +%%WWWDIR%%/dojox/dtl/utils/date.js +%%WWWDIR%%/dojox/editor/README +%%WWWDIR%%/dojox/editor/plugins/TablePlugins.js +%%WWWDIR%%/dojox/editor/plugins/UploadImage.js +%%WWWDIR%%/dojox/editor/plugins/nls/TableDialog.js +%%WWWDIR%%/dojox/editor/plugins/resources/editorPlugins.css +%%WWWDIR%%/dojox/editor/plugins/resources/images/busy.gif +%%WWWDIR%%/dojox/editor/plugins/resources/images/cellpad.png +%%WWWDIR%%/dojox/editor/plugins/resources/images/cellspace.png +%%WWWDIR%%/dojox/editor/plugins/resources/images/tableIcons.png +%%WWWDIR%%/dojox/editor/plugins/resources/images/uploadImageIcon.gif +%%WWWDIR%%/dojox/editor/plugins/resources/insertTable.html +%%WWWDIR%%/dojox/editor/plugins/resources/modifyTable.html +%%WWWDIR%%/dojox/embed/Flash.js +%%WWWDIR%%/dojox/embed/IE/flash.js +%%WWWDIR%%/dojox/embed/Object.js +%%WWWDIR%%/dojox/embed/Quicktime.js +%%WWWDIR%%/dojox/embed/README +%%WWWDIR%%/dojox/embed/resources/version.mov +%%WWWDIR%%/dojox/encoding/LICENSE +%%WWWDIR%%/dojox/encoding/README +%%WWWDIR%%/dojox/encoding/_base.js +%%WWWDIR%%/dojox/encoding/ascii85.js +%%WWWDIR%%/dojox/encoding/base64.js +%%WWWDIR%%/dojox/encoding/bits.js +%%WWWDIR%%/dojox/encoding/compression/lzw.js +%%WWWDIR%%/dojox/encoding/compression/splay.js +%%WWWDIR%%/dojox/encoding/crypto/Blowfish.js +%%WWWDIR%%/dojox/encoding/crypto/_base.js +%%WWWDIR%%/dojox/encoding/digests/MD5.js +%%WWWDIR%%/dojox/encoding/digests/_base.js +%%WWWDIR%%/dojox/encoding/easy64.js +%%WWWDIR%%/dojox/flash.js +%%WWWDIR%%/dojox/flash/DojoExternalInterface.as +%%WWWDIR%%/dojox/flash/ExpressInstall.as +%%WWWDIR%%/dojox/flash/README +%%WWWDIR%%/dojox/flash/_base.js +%%WWWDIR%%/dojox/form/BusyButton.js +%%WWWDIR%%/dojox/form/CheckedMultiSelect.js +%%WWWDIR%%/dojox/form/DateTextBox.js +%%WWWDIR%%/dojox/form/DropDownSelect.js +%%WWWDIR%%/dojox/form/DropDownStack.js +%%WWWDIR%%/dojox/form/FileInput.js +%%WWWDIR%%/dojox/form/FileInputAuto.js +%%WWWDIR%%/dojox/form/FilePickerTextBox.js +%%WWWDIR%%/dojox/form/FileUploader.js +%%WWWDIR%%/dojox/form/MultiComboBox.js +%%WWWDIR%%/dojox/form/PasswordValidator.js +%%WWWDIR%%/dojox/form/README +%%WWWDIR%%/dojox/form/RadioStack.js +%%WWWDIR%%/dojox/form/RangeSlider.js +%%WWWDIR%%/dojox/form/Rating.js +%%WWWDIR%%/dojox/form/TimeSpinner.js +%%WWWDIR%%/dojox/form/_FormSelectWidget.js +%%WWWDIR%%/dojox/form/_HasDropDown.js +%%WWWDIR%%/dojox/form/_SelectStackMixin.js +%%WWWDIR%%/dojox/form/nls/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ar/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ca/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/cs/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/da/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/de/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/el/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/es/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/fi/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/fr/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/he/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/hu/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/it/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ja/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ko/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/nb/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/nl/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/pl/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/pt-pt/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/pt/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ru/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/sk/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/sl/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/sv/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/th/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/tr/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/zh-tw/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/zh/PasswordValidator.js +%%WWWDIR%%/dojox/form/resources/BusyButton.css +%%WWWDIR%%/dojox/form/resources/CheckedMultiSelect.css +%%WWWDIR%%/dojox/form/resources/CheckedMultiSelect.html +%%WWWDIR%%/dojox/form/resources/DropDownSelect.css +%%WWWDIR%%/dojox/form/resources/DropDownSelect.html +%%WWWDIR%%/dojox/form/resources/FileInput.css +%%WWWDIR%%/dojox/form/resources/FileInput.html +%%WWWDIR%%/dojox/form/resources/FileInputAuto.html +%%WWWDIR%%/dojox/form/resources/FilePickerTextBox.css +%%WWWDIR%%/dojox/form/resources/FilePickerTextBox.html +%%WWWDIR%%/dojox/form/resources/HorizontalRangeSlider.html +%%WWWDIR%%/dojox/form/resources/PasswordValidator.html +%%WWWDIR%%/dojox/form/resources/RangeSlider.css +%%WWWDIR%%/dojox/form/resources/Rating.css +%%WWWDIR%%/dojox/form/resources/RecieveFile.php +%%WWWDIR%%/dojox/form/resources/UploadFile.php +%%WWWDIR%%/dojox/form/resources/VerticalRangeSlider.html +%%WWWDIR%%/dojox/form/resources/_CheckedMultiSelectItem.html +%%WWWDIR%%/dojox/form/resources/cLOG.php +%%WWWDIR%%/dojox/form/resources/images/loading_wheel.gif +%%WWWDIR%%/dojox/form/resources/images/nihiloFolderSprite.gif +%%WWWDIR%%/dojox/form/resources/images/rating_empty.gif +%%WWWDIR%%/dojox/form/resources/images/rating_full.gif +%%WWWDIR%%/dojox/form/resources/images/soriaFolderSprite.gif +%%WWWDIR%%/dojox/form/resources/images/tundraFolderSprite.gif +%%WWWDIR%%/dojox/form/resources/uploader.swf +%%WWWDIR%%/dojox/fx.js +%%WWWDIR%%/dojox/fx/README +%%WWWDIR%%/dojox/fx/Shadow.js +%%WWWDIR%%/dojox/fx/_arg.js +%%WWWDIR%%/dojox/fx/_base.js +%%WWWDIR%%/dojox/fx/_core.js +%%WWWDIR%%/dojox/fx/easing.js +%%WWWDIR%%/dojox/fx/ext-dojo/NodeList.js +%%WWWDIR%%/dojox/fx/flip.js +%%WWWDIR%%/dojox/fx/resources/shadowB.png +%%WWWDIR%%/dojox/fx/resources/shadowBL.png +%%WWWDIR%%/dojox/fx/resources/shadowBR.png +%%WWWDIR%%/dojox/fx/resources/shadowL.png +%%WWWDIR%%/dojox/fx/resources/shadowR.png +%%WWWDIR%%/dojox/fx/resources/shadowT.png +%%WWWDIR%%/dojox/fx/resources/shadowTL.png +%%WWWDIR%%/dojox/fx/resources/shadowTR.png +%%WWWDIR%%/dojox/fx/scroll.js +%%WWWDIR%%/dojox/fx/split.js +%%WWWDIR%%/dojox/fx/style.js +%%WWWDIR%%/dojox/fx/text.js +%%WWWDIR%%/dojox/gfx.js +%%WWWDIR%%/dojox/gfx/Moveable.js +%%WWWDIR%%/dojox/gfx/Mover.js +%%WWWDIR%%/dojox/gfx/README +%%WWWDIR%%/dojox/gfx/VectorText.js +%%WWWDIR%%/dojox/gfx/_base.js +%%WWWDIR%%/dojox/gfx/arc.js +%%WWWDIR%%/dojox/gfx/attach.js +%%WWWDIR%%/dojox/gfx/canvas.js +%%WWWDIR%%/dojox/gfx/canvas_attach.js +%%WWWDIR%%/dojox/gfx/decompose.js +%%WWWDIR%%/dojox/gfx/fx.js +%%WWWDIR%%/dojox/gfx/matrix.js +%%WWWDIR%%/dojox/gfx/move.js +%%WWWDIR%%/dojox/gfx/path.js +%%WWWDIR%%/dojox/gfx/resources/Gillius.svg +%%WWWDIR%%/dojox/gfx/resources/README +%%WWWDIR%%/dojox/gfx/shape.js +%%WWWDIR%%/dojox/gfx/silverlight.js +%%WWWDIR%%/dojox/gfx/silverlight_attach.js +%%WWWDIR%%/dojox/gfx/svg.js +%%WWWDIR%%/dojox/gfx/svg_attach.js +%%WWWDIR%%/dojox/gfx/utils.js +%%WWWDIR%%/dojox/gfx/vml.js +%%WWWDIR%%/dojox/gfx/vml_attach.js +%%WWWDIR%%/dojox/gfx3d.js +%%WWWDIR%%/dojox/gfx3d/README +%%WWWDIR%%/dojox/gfx3d/_base.js +%%WWWDIR%%/dojox/gfx3d/gradient.js +%%WWWDIR%%/dojox/gfx3d/lighting.js +%%WWWDIR%%/dojox/gfx3d/matrix.js +%%WWWDIR%%/dojox/gfx3d/object.js +%%WWWDIR%%/dojox/gfx3d/scheduler.js +%%WWWDIR%%/dojox/gfx3d/vector.js +%%WWWDIR%%/dojox/grid/DataGrid.js +%%WWWDIR%%/dojox/grid/DataSelection.js +%%WWWDIR%%/dojox/grid/Grid.js +%%WWWDIR%%/dojox/grid/README +%%WWWDIR%%/dojox/grid/Selection.js +%%WWWDIR%%/dojox/grid/VirtualGrid.js +%%WWWDIR%%/dojox/grid/_EditManager.js +%%WWWDIR%%/dojox/grid/_Events.js +%%WWWDIR%%/dojox/grid/_FocusManager.js +%%WWWDIR%%/dojox/grid/_Grid.js +%%WWWDIR%%/dojox/grid/_Layout.js +%%WWWDIR%%/dojox/grid/_RowManager.js +%%WWWDIR%%/dojox/grid/_RowSelector.js +%%WWWDIR%%/dojox/grid/_Scroller.js +%%WWWDIR%%/dojox/grid/_View.js +%%WWWDIR%%/dojox/grid/_ViewManager.js +%%WWWDIR%%/dojox/grid/_grid/Grid.css +%%WWWDIR%%/dojox/grid/_grid/Grid_rtl.css +%%WWWDIR%%/dojox/grid/_grid/nihiloGrid.css +%%WWWDIR%%/dojox/grid/_grid/soriaGrid.css +%%WWWDIR%%/dojox/grid/_grid/tundraGrid.css +%%WWWDIR%%/dojox/grid/cells.js +%%WWWDIR%%/dojox/grid/cells/_base.js +%%WWWDIR%%/dojox/grid/cells/dijit.js +%%WWWDIR%%/dojox/grid/compat/Grid.js +%%WWWDIR%%/dojox/grid/compat/README +%%WWWDIR%%/dojox/grid/compat/VirtualGrid.js +%%WWWDIR%%/dojox/grid/compat/_data/dijitEditors.js +%%WWWDIR%%/dojox/grid/compat/_data/editors.js +%%WWWDIR%%/dojox/grid/compat/_data/fields.js +%%WWWDIR%%/dojox/grid/compat/_data/model.js +%%WWWDIR%%/dojox/grid/compat/_grid/Grid.css +%%WWWDIR%%/dojox/grid/compat/_grid/Grid_rtl.css +%%WWWDIR%%/dojox/grid/compat/_grid/builder.js +%%WWWDIR%%/dojox/grid/compat/_grid/cell.js +%%WWWDIR%%/dojox/grid/compat/_grid/drag.js +%%WWWDIR%%/dojox/grid/compat/_grid/edit.js +%%WWWDIR%%/dojox/grid/compat/_grid/focus.js +%%WWWDIR%%/dojox/grid/compat/_grid/images/grid_dx_gradient.gif +%%WWWDIR%%/dojox/grid/compat/_grid/images/grid_sort_down.gif +%%WWWDIR%%/dojox/grid/compat/_grid/images/grid_sort_up.gif +%%WWWDIR%%/dojox/grid/compat/_grid/images/tabEnabled_rotated.png +%%WWWDIR%%/dojox/grid/compat/_grid/images/tabHover_rotated.png +%%WWWDIR%%/dojox/grid/compat/_grid/layout.js +%%WWWDIR%%/dojox/grid/compat/_grid/lib.js +%%WWWDIR%%/dojox/grid/compat/_grid/nihiloGrid.css +%%WWWDIR%%/dojox/grid/compat/_grid/publicEvents.js +%%WWWDIR%%/dojox/grid/compat/_grid/rowbar.js +%%WWWDIR%%/dojox/grid/compat/_grid/rows.js +%%WWWDIR%%/dojox/grid/compat/_grid/scroller.js +%%WWWDIR%%/dojox/grid/compat/_grid/selection.js +%%WWWDIR%%/dojox/grid/compat/_grid/soriaGrid.css +%%WWWDIR%%/dojox/grid/compat/_grid/tundraGrid.css +%%WWWDIR%%/dojox/grid/compat/_grid/view.js +%%WWWDIR%%/dojox/grid/compat/_grid/views.js +%%WWWDIR%%/dojox/grid/compat/resources/GridView.html +%%WWWDIR%%/dojox/grid/compat/resources/VirtualGrid.html +%%WWWDIR%%/dojox/grid/compat/tests/databaseModel.js +%%WWWDIR%%/dojox/grid/compat/tests/images/closed.gif +%%WWWDIR%%/dojox/grid/compat/tests/images/flatScreen.gif +%%WWWDIR%%/dojox/grid/compat/tests/images/open.gif +%%WWWDIR%%/dojox/grid/compat/tests/support/books.xml +%%WWWDIR%%/dojox/grid/compat/tests/support/data.php +%%WWWDIR%%/dojox/grid/compat/tests/support/geography.xml +%%WWWDIR%%/dojox/grid/compat/tests/support/json.php +%%WWWDIR%%/dojox/grid/compat/tests/support/movies.csv +%%WWWDIR%%/dojox/grid/compat/tests/support/test_data.js +%%WWWDIR%%/dojox/grid/compat/tests/support/test_data_objects.js +%%WWWDIR%%/dojox/grid/compat/tests/support/testtbl.sql +%%WWWDIR%%/dojox/grid/compat/tests/support/yahoo_search.js +%%WWWDIR%%/dojox/grid/compat/tests/test_change_structure.html +%%WWWDIR%%/dojox/grid/compat/tests/test_custom_sort.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_empty.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model_EmptyResultSet.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model_multiStores.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model_processError.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_notification.html +%%WWWDIR%%/dojox/grid/compat/tests/test_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_edit_canEdit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_edit_dijit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_events.html +%%WWWDIR%%/dojox/grid/compat/tests/test_expand.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_dlg.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_headerHeight.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_layout.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_layout_LayoutContainer.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_layout_borderContainer.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_object_model_change.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_programmatic.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_programmatic_layout.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_rtl.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_themes.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_tooltip_menu.html +%%WWWDIR%%/dojox/grid/compat/tests/test_keyboard.html +%%WWWDIR%%/dojox/grid/compat/tests/test_markup.html +%%WWWDIR%%/dojox/grid/compat/tests/test_mysql_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_sizing.html +%%WWWDIR%%/dojox/grid/compat/tests/test_sizing_100rows.html +%%WWWDIR%%/dojox/grid/compat/tests/test_sizing_ResizeHandle.html +%%WWWDIR%%/dojox/grid/compat/tests/test_styling.html +%%WWWDIR%%/dojox/grid/compat/tests/test_subgrid.html +%%WWWDIR%%/dojox/grid/compat/tests/test_tundra_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_yahoo_images.html +%%WWWDIR%%/dojox/grid/compat/tests/test_yahoo_search.html +%%WWWDIR%%/dojox/grid/compat/tests/yahooSearch.js +%%WWWDIR%%/dojox/grid/resources/Grid.css +%%WWWDIR%%/dojox/grid/resources/Grid_rtl.css +%%WWWDIR%%/dojox/grid/resources/View.html +%%WWWDIR%%/dojox/grid/resources/_Grid.html +%%WWWDIR%%/dojox/grid/resources/images/grid_dx_gradient.gif +%%WWWDIR%%/dojox/grid/resources/images/grid_sort_down.gif +%%WWWDIR%%/dojox/grid/resources/images/grid_sort_up.gif +%%WWWDIR%%/dojox/grid/resources/images/tabEnabled_rotated.png +%%WWWDIR%%/dojox/grid/resources/images/tabHover_rotated.png +%%WWWDIR%%/dojox/grid/resources/nihiloGrid.css +%%WWWDIR%%/dojox/grid/resources/soriaGrid.css +%%WWWDIR%%/dojox/grid/resources/tundraGrid.css +%%WWWDIR%%/dojox/grid/util.js +%%WWWDIR%%/dojox/help/README +%%WWWDIR%%/dojox/help/_base.js +%%WWWDIR%%/dojox/help/console.js +%%WWWDIR%%/dojox/highlight.js +%%WWWDIR%%/dojox/highlight/README +%%WWWDIR%%/dojox/highlight/_base.js +%%WWWDIR%%/dojox/highlight/languages/_all.js +%%WWWDIR%%/dojox/highlight/languages/_dynamic.js +%%WWWDIR%%/dojox/highlight/languages/_static.js +%%WWWDIR%%/dojox/highlight/languages/_www.js +%%WWWDIR%%/dojox/highlight/languages/cpp.js +%%WWWDIR%%/dojox/highlight/languages/css.js +%%WWWDIR%%/dojox/highlight/languages/delphi.js +%%WWWDIR%%/dojox/highlight/languages/django.js +%%WWWDIR%%/dojox/highlight/languages/html.js +%%WWWDIR%%/dojox/highlight/languages/javascript.js +%%WWWDIR%%/dojox/highlight/languages/pygments/_html.js +%%WWWDIR%%/dojox/highlight/languages/pygments/_www.js +%%WWWDIR%%/dojox/highlight/languages/pygments/css.js +%%WWWDIR%%/dojox/highlight/languages/pygments/html.js +%%WWWDIR%%/dojox/highlight/languages/pygments/javascript.js +%%WWWDIR%%/dojox/highlight/languages/pygments/xml.js +%%WWWDIR%%/dojox/highlight/languages/python.js +%%WWWDIR%%/dojox/highlight/languages/sql.js +%%WWWDIR%%/dojox/highlight/languages/xml.js +%%WWWDIR%%/dojox/highlight/resources/highlight.css +%%WWWDIR%%/dojox/highlight/resources/pygments/autumn.css +%%WWWDIR%%/dojox/highlight/resources/pygments/borland.css +%%WWWDIR%%/dojox/highlight/resources/pygments/colorful.css +%%WWWDIR%%/dojox/highlight/resources/pygments/default.css +%%WWWDIR%%/dojox/highlight/resources/pygments/emacs.css +%%WWWDIR%%/dojox/highlight/resources/pygments/friendly.css +%%WWWDIR%%/dojox/highlight/resources/pygments/fruity.css +%%WWWDIR%%/dojox/highlight/resources/pygments/manni.css +%%WWWDIR%%/dojox/highlight/resources/pygments/murphy.css +%%WWWDIR%%/dojox/highlight/resources/pygments/native.css +%%WWWDIR%%/dojox/highlight/resources/pygments/pastie.css +%%WWWDIR%%/dojox/highlight/resources/pygments/perldoc.css +%%WWWDIR%%/dojox/highlight/resources/pygments/trac.css +%%WWWDIR%%/dojox/html.js +%%WWWDIR%%/dojox/html/README +%%WWWDIR%%/dojox/html/_base.js +%%WWWDIR%%/dojox/html/metrics.js +%%WWWDIR%%/dojox/html/styles.js +%%WWWDIR%%/dojox/image/Badge.js +%%WWWDIR%%/dojox/image/FlickrBadge.js +%%WWWDIR%%/dojox/image/Gallery.js +%%WWWDIR%%/dojox/image/Lightbox.js +%%WWWDIR%%/dojox/image/Magnifier.js +%%WWWDIR%%/dojox/image/MagnifierLite.js +%%WWWDIR%%/dojox/image/README +%%WWWDIR%%/dojox/image/SlideShow.js +%%WWWDIR%%/dojox/image/ThumbnailPicker.js +%%WWWDIR%%/dojox/image/resources/Badge.css +%%WWWDIR%%/dojox/image/resources/Gallery.css +%%WWWDIR%%/dojox/image/resources/Gallery.html +%%WWWDIR%%/dojox/image/resources/Lightbox.css +%%WWWDIR%%/dojox/image/resources/Lightbox.html +%%WWWDIR%%/dojox/image/resources/Magnifier.css +%%WWWDIR%%/dojox/image/resources/SlideShow.css +%%WWWDIR%%/dojox/image/resources/SlideShow.html +%%WWWDIR%%/dojox/image/resources/ThumbnailPicker.css +%%WWWDIR%%/dojox/image/resources/ThumbnailPicker.html +%%WWWDIR%%/dojox/image/resources/image.css +%%WWWDIR%%/dojox/image/resources/images/buttons.gif +%%WWWDIR%%/dojox/image/resources/images/buttons.png +%%WWWDIR%%/dojox/image/resources/images/close.gif +%%WWWDIR%%/dojox/image/resources/images/close.png +%%WWWDIR%%/dojox/image/resources/images/close_dark.png +%%WWWDIR%%/dojox/image/resources/images/left.gif +%%WWWDIR%%/dojox/image/resources/images/left.png +%%WWWDIR%%/dojox/image/resources/images/loading.gif +%%WWWDIR%%/dojox/image/resources/images/right.gif +%%WWWDIR%%/dojox/image/resources/images/right.png +%%WWWDIR%%/dojox/image/resources/images/warning.png +%%WWWDIR%%/dojox/io/README +%%WWWDIR%%/dojox/io/httpParse.js +%%WWWDIR%%/dojox/io/proxy/README +%%WWWDIR%%/dojox/io/proxy/tests/frag.xml +%%WWWDIR%%/dojox/io/proxy/tests/xip.html +%%WWWDIR%%/dojox/io/proxy/xip.js +%%WWWDIR%%/dojox/io/proxy/xip_client.html +%%WWWDIR%%/dojox/io/proxy/xip_server.html +%%WWWDIR%%/dojox/io/scriptFrame.js +%%WWWDIR%%/dojox/io/windowName.js +%%WWWDIR%%/dojox/io/xhrMultiPart.js +%%WWWDIR%%/dojox/io/xhrPlugins.js +%%WWWDIR%%/dojox/io/xhrWindowNamePlugin.js +%%WWWDIR%%/dojox/json/README +%%WWWDIR%%/dojox/json/query.js +%%WWWDIR%%/dojox/json/ref.js +%%WWWDIR%%/dojox/json/schema.js +%%WWWDIR%%/dojox/jsonPath.js +%%WWWDIR%%/dojox/jsonPath/README +%%WWWDIR%%/dojox/jsonPath/query.js +%%WWWDIR%%/dojox/lang/LICENSE +%%WWWDIR%%/dojox/lang/README +%%WWWDIR%%/dojox/lang/aspect.js +%%WWWDIR%%/dojox/lang/aspect/cflow.js +%%WWWDIR%%/dojox/lang/aspect/counter.js +%%WWWDIR%%/dojox/lang/aspect/memoizer.js +%%WWWDIR%%/dojox/lang/aspect/memoizerGuard.js +%%WWWDIR%%/dojox/lang/aspect/profiler.js +%%WWWDIR%%/dojox/lang/aspect/timer.js +%%WWWDIR%%/dojox/lang/aspect/tracer.js +%%WWWDIR%%/dojox/lang/functional.js +%%WWWDIR%%/dojox/lang/functional/array.js +%%WWWDIR%%/dojox/lang/functional/binrec.js +%%WWWDIR%%/dojox/lang/functional/curry.js +%%WWWDIR%%/dojox/lang/functional/fold.js +%%WWWDIR%%/dojox/lang/functional/lambda.js +%%WWWDIR%%/dojox/lang/functional/linrec.js +%%WWWDIR%%/dojox/lang/functional/listcomp.js +%%WWWDIR%%/dojox/lang/functional/multirec.js +%%WWWDIR%%/dojox/lang/functional/numrec.js +%%WWWDIR%%/dojox/lang/functional/object.js +%%WWWDIR%%/dojox/lang/functional/reversed.js +%%WWWDIR%%/dojox/lang/functional/scan.js +%%WWWDIR%%/dojox/lang/functional/sequence.js +%%WWWDIR%%/dojox/lang/functional/tailrec.js +%%WWWDIR%%/dojox/lang/functional/util.js +%%WWWDIR%%/dojox/lang/functional/zip.js +%%WWWDIR%%/dojox/lang/mix.js +%%WWWDIR%%/dojox/lang/observable.js +%%WWWDIR%%/dojox/lang/utils.js +%%WWWDIR%%/dojox/layout/BorderContainer.js +%%WWWDIR%%/dojox/layout/ContentPane.js +%%WWWDIR%%/dojox/layout/DragPane.js +%%WWWDIR%%/dojox/layout/ExpandoPane.js +%%WWWDIR%%/dojox/layout/FloatingPane.js +%%WWWDIR%%/dojox/layout/GridContainer.js +%%WWWDIR%%/dojox/layout/README +%%WWWDIR%%/dojox/layout/RadioGroup.js +%%WWWDIR%%/dojox/layout/ResizeHandle.js +%%WWWDIR%%/dojox/layout/RotatorContainer.js +%%WWWDIR%%/dojox/layout/ScrollPane.js +%%WWWDIR%%/dojox/layout/ToggleSplitter.js +%%WWWDIR%%/dojox/layout/dnd/Avatar.js +%%WWWDIR%%/dojox/layout/dnd/PlottedDnd.js +%%WWWDIR%%/dojox/layout/nls/GridContainer.js +%%WWWDIR%%/dojox/layout/nls/en/GridContainer.js +%%WWWDIR%%/dojox/layout/nls/fr/GridContainer.js +%%WWWDIR%%/dojox/layout/resources/DndGridContainer.css +%%WWWDIR%%/dojox/layout/resources/ExpandoPane.css +%%WWWDIR%%/dojox/layout/resources/ExpandoPane.html +%%WWWDIR%%/dojox/layout/resources/FloatingPane.css +%%WWWDIR%%/dojox/layout/resources/FloatingPane.html +%%WWWDIR%%/dojox/layout/resources/GridContainer.css +%%WWWDIR%%/dojox/layout/resources/GridContainer.html +%%WWWDIR%%/dojox/layout/resources/RadioGroup.css +%%WWWDIR%%/dojox/layout/resources/ResizeHandle.css +%%WWWDIR%%/dojox/layout/resources/RotatorContainer.css +%%WWWDIR%%/dojox/layout/resources/ScrollPane.css +%%WWWDIR%%/dojox/layout/resources/ScrollPane.html +%%WWWDIR%%/dojox/layout/resources/ToggleSplitter.css +%%WWWDIR%%/dojox/layout/resources/icons/grip_bg.gif +%%WWWDIR%%/dojox/layout/resources/icons/pixel.gif +%%WWWDIR%%/dojox/layout/resources/icons/resize.png +%%WWWDIR%%/dojox/layout/resources/icons/rotator.png +%%WWWDIR%%/dojox/math.js +%%WWWDIR%%/dojox/math/README +%%WWWDIR%%/dojox/math/_base.js +%%WWWDIR%%/dojox/math/curves.js +%%WWWDIR%%/dojox/math/matrix.js +%%WWWDIR%%/dojox/off.js +%%WWWDIR%%/dojox/off/README +%%WWWDIR%%/dojox/off/_common.js +%%WWWDIR%%/dojox/off/docs/bookmarklets.html +%%WWWDIR%%/dojox/off/files.js +%%WWWDIR%%/dojox/off/network_check.txt +%%WWWDIR%%/dojox/off/offline.js +%%WWWDIR%%/dojox/off/resources/checkmark.png +%%WWWDIR%%/dojox/off/resources/greenball.png +%%WWWDIR%%/dojox/off/resources/learnhow.html +%%WWWDIR%%/dojox/off/resources/learnhow.js +%%WWWDIR%%/dojox/off/resources/offline-widget.css +%%WWWDIR%%/dojox/off/resources/offline-widget.html +%%WWWDIR%%/dojox/off/resources/redball.png +%%WWWDIR%%/dojox/off/resources/roller.gif +%%WWWDIR%%/dojox/off/sync.js +%%WWWDIR%%/dojox/off/ui.js +%%WWWDIR%%/dojox/presentation.js +%%WWWDIR%%/dojox/presentation/README +%%WWWDIR%%/dojox/presentation/_base.js +%%WWWDIR%%/dojox/presentation/resources/Show.css +%%WWWDIR%%/dojox/presentation/resources/Show.html +%%WWWDIR%%/dojox/presentation/resources/Slide.html +%%WWWDIR%%/dojox/presentation/resources/icons/down.png +%%WWWDIR%%/dojox/presentation/resources/icons/next.png +%%WWWDIR%%/dojox/presentation/resources/icons/prev.png +%%WWWDIR%%/dojox/presentation/resources/icons/up.png +%%WWWDIR%%/dojox/resources/README.template +%%WWWDIR%%/dojox/resources/_modules.js +%%WWWDIR%%/dojox/resources/explore.php +%%WWWDIR%%/dojox/resources/manualTests.html +%%WWWDIR%%/dojox/resources/manualTests.js +%%WWWDIR%%/dojox/robot/README +%%WWWDIR%%/dojox/robot/recorder.js +%%WWWDIR%%/dojox/rpc/Client.js +%%WWWDIR%%/dojox/rpc/JsonRPC.js +%%WWWDIR%%/dojox/rpc/JsonRest.js +%%WWWDIR%%/dojox/rpc/OfflineRest.js +%%WWWDIR%%/dojox/rpc/ProxiedPath.js +%%WWWDIR%%/dojox/rpc/README +%%WWWDIR%%/dojox/rpc/Rest.js +%%WWWDIR%%/dojox/rpc/SMDLibrary/dojo-api.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/geonames.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/google.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/wikipedia.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/yahoo.smd +%%WWWDIR%%/dojox/rpc/Service.js +%%WWWDIR%%/dojox/rpc/test.txt +%%WWWDIR%%/dojox/secure/DOM.js +%%WWWDIR%%/dojox/secure/README +%%WWWDIR%%/dojox/secure/capability.js +%%WWWDIR%%/dojox/secure/sandbox.js +%%WWWDIR%%/dojox/sketch.js +%%WWWDIR%%/dojox/sketch/Anchor.js +%%WWWDIR%%/dojox/sketch/Annotation.js +%%WWWDIR%%/dojox/sketch/DoubleArrowAnnotation.js +%%WWWDIR%%/dojox/sketch/Figure.js +%%WWWDIR%%/dojox/sketch/LeadAnnotation.js +%%WWWDIR%%/dojox/sketch/PreexistingAnnotation.js +%%WWWDIR%%/dojox/sketch/README +%%WWWDIR%%/dojox/sketch/SingleArrowAnnotation.js +%%WWWDIR%%/dojox/sketch/Slider.js +%%WWWDIR%%/dojox/sketch/Toolbar.js +%%WWWDIR%%/dojox/sketch/UnderlineAnnotation.js +%%WWWDIR%%/dojox/sketch/UndoStack.js +%%WWWDIR%%/dojox/sketch/_Plugin.js +%%WWWDIR%%/dojox/sketch/resources/images/icons.gif +%%WWWDIR%%/dojox/sketch/resources/sketch.css +%%WWWDIR%%/dojox/sql.js +%%WWWDIR%%/dojox/sql/LICENSE +%%WWWDIR%%/dojox/sql/README +%%WWWDIR%%/dojox/sql/_base.js +%%WWWDIR%%/dojox/sql/_crypto.js +%%WWWDIR%%/dojox/storage.js +%%WWWDIR%%/dojox/storage/AirDBStorageProvider.js +%%WWWDIR%%/dojox/storage/AirEncryptedLocalStorageProvider.js +%%WWWDIR%%/dojox/storage/AirFileStorageProvider.js +%%WWWDIR%%/dojox/storage/FlashStorageProvider.js +%%WWWDIR%%/dojox/storage/GearsStorageProvider.js +%%WWWDIR%%/dojox/storage/Provider.js +%%WWWDIR%%/dojox/storage/README +%%WWWDIR%%/dojox/storage/Storage.as +%%WWWDIR%%/dojox/storage/Storage.swf +%%WWWDIR%%/dojox/storage/WhatWGStorageProvider.js +%%WWWDIR%%/dojox/storage/_common.js +%%WWWDIR%%/dojox/storage/buildFlashStorage.sh +%%WWWDIR%%/dojox/storage/manager.js +%%WWWDIR%%/dojox/storage/storage_dialog.fla +%%WWWDIR%%/dojox/storage/storage_dialog.swf +%%WWWDIR%%/dojox/string/BidiComplex.js +%%WWWDIR%%/dojox/string/Builder.js +%%WWWDIR%%/dojox/string/README +%%WWWDIR%%/dojox/string/sprintf.js +%%WWWDIR%%/dojox/string/tokenize.js +%%WWWDIR%%/dojox/testing/DocTest.js +%%WWWDIR%%/dojox/testing/README +%%WWWDIR%%/dojox/timing.js +%%WWWDIR%%/dojox/timing/README +%%WWWDIR%%/dojox/timing/Sequence.js +%%WWWDIR%%/dojox/timing/Streamer.js +%%WWWDIR%%/dojox/timing/ThreadPool.js +%%WWWDIR%%/dojox/timing/_base.js +%%WWWDIR%%/dojox/uuid.js +%%WWWDIR%%/dojox/uuid/README +%%WWWDIR%%/dojox/uuid/Uuid.js +%%WWWDIR%%/dojox/uuid/_base.js +%%WWWDIR%%/dojox/uuid/generateRandomUuid.js +%%WWWDIR%%/dojox/uuid/generateTimeBasedUuid.js +%%WWWDIR%%/dojox/validate.js +%%WWWDIR%%/dojox/validate/README +%%WWWDIR%%/dojox/validate/_base.js +%%WWWDIR%%/dojox/validate/ca.js +%%WWWDIR%%/dojox/validate/check.js +%%WWWDIR%%/dojox/validate/creditCard.js +%%WWWDIR%%/dojox/validate/isbn.js +%%WWWDIR%%/dojox/validate/regexp.js +%%WWWDIR%%/dojox/validate/us.js +%%WWWDIR%%/dojox/validate/web.js +%%WWWDIR%%/dojox/widget/Calendar.js +%%WWWDIR%%/dojox/widget/Calendar/Calendar.css +%%WWWDIR%%/dojox/widget/Calendar/Calendar.html +%%WWWDIR%%/dojox/widget/Calendar/CalendarDay.html +%%WWWDIR%%/dojox/widget/Calendar/CalendarMonth.html +%%WWWDIR%%/dojox/widget/Calendar/CalendarYear.html +%%WWWDIR%%/dojox/widget/CalendarFx.js +%%WWWDIR%%/dojox/widget/ColorPicker.js +%%WWWDIR%%/dojox/widget/ColorPicker/ColorPicker.css +%%WWWDIR%%/dojox/widget/ColorPicker/ColorPicker.html +%%WWWDIR%%/dojox/widget/ColorPicker/images/hue.png +%%WWWDIR%%/dojox/widget/ColorPicker/images/hueHandle.png +%%WWWDIR%%/dojox/widget/ColorPicker/images/pickerPointer.png +%%WWWDIR%%/dojox/widget/ColorPicker/images/underlay.png +%%WWWDIR%%/dojox/widget/Dialog.js +%%WWWDIR%%/dojox/widget/Dialog/Dialog.css +%%WWWDIR%%/dojox/widget/Dialog/Dialog.html +%%WWWDIR%%/dojox/widget/Dialog/images/dialogCloseButton.gif +%%WWWDIR%%/dojox/widget/Dialog/images/dialogCloseButton.png +%%WWWDIR%%/dojox/widget/DocTester.js +%%WWWDIR%%/dojox/widget/DocTester/DocTester.css +%%WWWDIR%%/dojox/widget/DocTester/DocTester.html +%%WWWDIR%%/dojox/widget/FilePicker.js +%%WWWDIR%%/dojox/widget/FilePicker/FilePicker.css +%%WWWDIR%%/dojox/widget/FilePicker/_FileInfoPane.html +%%WWWDIR%%/dojox/widget/FilePicker/images/nihiloFileIcons.gif +%%WWWDIR%%/dojox/widget/FilePicker/images/soriaFileIcons.gif +%%WWWDIR%%/dojox/widget/FilePicker/images/tundraFileIcons.gif +%%WWWDIR%%/dojox/widget/FisheyeList.js +%%WWWDIR%%/dojox/widget/FisheyeList/FisheyeList.css +%%WWWDIR%%/dojox/widget/FisheyeLite.js +%%WWWDIR%%/dojox/widget/Iterator.js +%%WWWDIR%%/dojox/widget/Loader.js +%%WWWDIR%%/dojox/widget/Loader/Loader.css +%%WWWDIR%%/dojox/widget/Loader/icons/loading.gif +%%WWWDIR%%/dojox/widget/Pager.js +%%WWWDIR%%/dojox/widget/Pager/Pager.css +%%WWWDIR%%/dojox/widget/Pager/Pager.html +%%WWWDIR%%/dojox/widget/Pager/images/hNext.png +%%WWWDIR%%/dojox/widget/Pager/images/hPrevious.png +%%WWWDIR%%/dojox/widget/Pager/images/pageActive.png +%%WWWDIR%%/dojox/widget/Pager/images/pageInactive.png +%%WWWDIR%%/dojox/widget/Pager/images/vNext.png +%%WWWDIR%%/dojox/widget/Pager/images/vPrevious.png +%%WWWDIR%%/dojox/widget/PlaceholderMenuItem.js +%%WWWDIR%%/dojox/widget/README +%%WWWDIR%%/dojox/widget/Roller.js +%%WWWDIR%%/dojox/widget/RollingList.js +%%WWWDIR%%/dojox/widget/RollingList/RollingList.css +%%WWWDIR%%/dojox/widget/SortList.js +%%WWWDIR%%/dojox/widget/SortList/SortList.css +%%WWWDIR%%/dojox/widget/SortList/SortList.html +%%WWWDIR%%/dojox/widget/Toaster.js +%%WWWDIR%%/dojox/widget/Toaster/Toaster.css +%%WWWDIR%%/dojox/widget/Wizard.js +%%WWWDIR%%/dojox/widget/Wizard/Wizard.css +%%WWWDIR%%/dojox/widget/Wizard/Wizard.html +%%WWWDIR%%/dojox/widget/nls/FilePicker.js +%%WWWDIR%%/dojox/widget/nls/RollingList.js +%%WWWDIR%%/dojox/widget/nls/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ar/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ca/Wizard.js +%%WWWDIR%%/dojox/widget/nls/cs/Wizard.js +%%WWWDIR%%/dojox/widget/nls/da/Wizard.js +%%WWWDIR%%/dojox/widget/nls/de/Wizard.js +%%WWWDIR%%/dojox/widget/nls/el/Wizard.js +%%WWWDIR%%/dojox/widget/nls/es/Wizard.js +%%WWWDIR%%/dojox/widget/nls/fi/Wizard.js +%%WWWDIR%%/dojox/widget/nls/fr/Wizard.js +%%WWWDIR%%/dojox/widget/nls/he/Wizard.js +%%WWWDIR%%/dojox/widget/nls/hu/Wizard.js +%%WWWDIR%%/dojox/widget/nls/it/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ja/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ko/Wizard.js +%%WWWDIR%%/dojox/widget/nls/nb/Wizard.js +%%WWWDIR%%/dojox/widget/nls/nl/Wizard.js +%%WWWDIR%%/dojox/widget/nls/pl/Wizard.js +%%WWWDIR%%/dojox/widget/nls/pt-pt/Wizard.js +%%WWWDIR%%/dojox/widget/nls/pt/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ru/Wizard.js +%%WWWDIR%%/dojox/widget/nls/sk/Wizard.js +%%WWWDIR%%/dojox/widget/nls/sl/Wizard.js +%%WWWDIR%%/dojox/widget/nls/sv/Wizard.js +%%WWWDIR%%/dojox/widget/nls/th/Wizard.js +%%WWWDIR%%/dojox/widget/nls/tr/Wizard.js +%%WWWDIR%%/dojox/widget/nls/zh-tw/Wizard.js +%%WWWDIR%%/dojox/widget/nls/zh/Wizard.js +%%WWWDIR%%/dojox/wire.js +%%WWWDIR%%/dojox/wire/CompositeWire.js +%%WWWDIR%%/dojox/wire/DataWire.js +%%WWWDIR%%/dojox/wire/README +%%WWWDIR%%/dojox/wire/TableAdapter.js +%%WWWDIR%%/dojox/wire/TextAdapter.js +%%WWWDIR%%/dojox/wire/TreeAdapter.js +%%WWWDIR%%/dojox/wire/Wire.js +%%WWWDIR%%/dojox/wire/XmlWire.js +%%WWWDIR%%/dojox/wire/_base.js +%%WWWDIR%%/dojox/wire/ml/Action.js +%%WWWDIR%%/dojox/wire/ml/Data.js +%%WWWDIR%%/dojox/wire/ml/DataStore.js +%%WWWDIR%%/dojox/wire/ml/Invocation.js +%%WWWDIR%%/dojox/wire/ml/Service.js +%%WWWDIR%%/dojox/wire/ml/Transfer.js +%%WWWDIR%%/dojox/wire/ml/util.js +%%WWWDIR%%/dojox/xml/DomParser.js +%%WWWDIR%%/dojox/xml/README +%%WWWDIR%%/dojox/xml/Script.js +%%WWWDIR%%/dojox/xml/parser.js +%%WWWDIR%%/dojox/xml/widgetParser.js +%%WWWDIR%%/dojox/xmpp/ChatService.js +%%WWWDIR%%/dojox/xmpp/PresenceService.js +%%WWWDIR%%/dojox/xmpp/README +%%WWWDIR%%/dojox/xmpp/RosterService.js +%%WWWDIR%%/dojox/xmpp/TransportSession.js +%%WWWDIR%%/dojox/xmpp/UserService.js +%%WWWDIR%%/dojox/xmpp/sasl.js +%%WWWDIR%%/dojox/xmpp/util.js +%%WWWDIR%%/dojox/xmpp/widget/ChatSession.js +%%WWWDIR%%/dojox/xmpp/widget/templates/ChatSession.html +%%WWWDIR%%/dojox/xmpp/xmppSession.js + at dirrm %%WWWDIR%%/dojox/xmpp/widget/templates + at dirrm %%WWWDIR%%/dojox/xmpp/widget + at dirrm %%WWWDIR%%/dojox/xmpp + at dirrm %%WWWDIR%%/dojox/xml + at dirrm %%WWWDIR%%/dojox/wire/ml + at dirrm %%WWWDIR%%/dojox/wire + at dirrm %%WWWDIR%%/dojox/widget/nls/zh-tw + at dirrm %%WWWDIR%%/dojox/widget/nls/zh + at dirrm %%WWWDIR%%/dojox/widget/nls/tr + at dirrm %%WWWDIR%%/dojox/widget/nls/th + at dirrm %%WWWDIR%%/dojox/widget/nls/sv + at dirrm %%WWWDIR%%/dojox/widget/nls/sl + at dirrm %%WWWDIR%%/dojox/widget/nls/sk + at dirrm %%WWWDIR%%/dojox/widget/nls/ru + at dirrm %%WWWDIR%%/dojox/widget/nls/pt-pt + at dirrm %%WWWDIR%%/dojox/widget/nls/pt + at dirrm %%WWWDIR%%/dojox/widget/nls/pl + at dirrm %%WWWDIR%%/dojox/widget/nls/nl + at dirrm %%WWWDIR%%/dojox/widget/nls/nb + at dirrm %%WWWDIR%%/dojox/widget/nls/ko + at dirrm %%WWWDIR%%/dojox/widget/nls/ja + at dirrm %%WWWDIR%%/dojox/widget/nls/it + at dirrm %%WWWDIR%%/dojox/widget/nls/hu + at dirrm %%WWWDIR%%/dojox/widget/nls/he + at dirrm %%WWWDIR%%/dojox/widget/nls/fr + at dirrm %%WWWDIR%%/dojox/widget/nls/fi + at dirrm %%WWWDIR%%/dojox/widget/nls/es + at dirrm %%WWWDIR%%/dojox/widget/nls/el + at dirrm %%WWWDIR%%/dojox/widget/nls/de + at dirrm %%WWWDIR%%/dojox/widget/nls/da + at dirrm %%WWWDIR%%/dojox/widget/nls/cs + at dirrm %%WWWDIR%%/dojox/widget/nls/ca + at dirrm %%WWWDIR%%/dojox/widget/nls/ar + at dirrm %%WWWDIR%%/dojox/widget/nls + at dirrm %%WWWDIR%%/dojox/widget/Wizard + at dirrm %%WWWDIR%%/dojox/widget/Toaster + at dirrm %%WWWDIR%%/dojox/widget/SortList + at dirrm %%WWWDIR%%/dojox/widget/RollingList + at dirrm %%WWWDIR%%/dojox/widget/Pager/images + at dirrm %%WWWDIR%%/dojox/widget/Pager + at dirrm %%WWWDIR%%/dojox/widget/Loader/icons + at dirrm %%WWWDIR%%/dojox/widget/Loader + at dirrm %%WWWDIR%%/dojox/widget/FisheyeList + at dirrm %%WWWDIR%%/dojox/widget/FilePicker/images + at dirrm %%WWWDIR%%/dojox/widget/FilePicker + at dirrm %%WWWDIR%%/dojox/widget/DocTester + at dirrm %%WWWDIR%%/dojox/widget/Dialog/images + at dirrm %%WWWDIR%%/dojox/widget/Dialog + at dirrm %%WWWDIR%%/dojox/widget/ColorPicker/images + at dirrm %%WWWDIR%%/dojox/widget/ColorPicker + at dirrm %%WWWDIR%%/dojox/widget/Calendar + at dirrm %%WWWDIR%%/dojox/widget + at dirrm %%WWWDIR%%/dojox/validate + at dirrm %%WWWDIR%%/dojox/uuid + at dirrm %%WWWDIR%%/dojox/timing + at dirrm %%WWWDIR%%/dojox/testing + at dirrm %%WWWDIR%%/dojox/string + at dirrm %%WWWDIR%%/dojox/storage + at dirrm %%WWWDIR%%/dojox/sql + at dirrm %%WWWDIR%%/dojox/sketch/resources/images + at dirrm %%WWWDIR%%/dojox/sketch/resources + at dirrm %%WWWDIR%%/dojox/sketch + at dirrm %%WWWDIR%%/dojox/secure + at dirrm %%WWWDIR%%/dojox/rpc/SMDLibrary + at dirrm %%WWWDIR%%/dojox/rpc + at dirrm %%WWWDIR%%/dojox/robot + at dirrm %%WWWDIR%%/dojox/resources + at dirrm %%WWWDIR%%/dojox/presentation/resources/icons + at dirrm %%WWWDIR%%/dojox/presentation/resources + at dirrm %%WWWDIR%%/dojox/presentation + at dirrm %%WWWDIR%%/dojox/off/resources + at dirrm %%WWWDIR%%/dojox/off/docs + at dirrm %%WWWDIR%%/dojox/off + at dirrm %%WWWDIR%%/dojox/math + at dirrm %%WWWDIR%%/dojox/layout/resources/icons + at dirrm %%WWWDIR%%/dojox/layout/resources + at dirrm %%WWWDIR%%/dojox/layout/nls/fr + at dirrm %%WWWDIR%%/dojox/layout/nls/en + at dirrm %%WWWDIR%%/dojox/layout/nls + at dirrm %%WWWDIR%%/dojox/layout/dnd + at dirrm %%WWWDIR%%/dojox/layout + at dirrm %%WWWDIR%%/dojox/lang/functional + at dirrm %%WWWDIR%%/dojox/lang/aspect + at dirrm %%WWWDIR%%/dojox/lang + at dirrm %%WWWDIR%%/dojox/jsonPath + at dirrm %%WWWDIR%%/dojox/json + at dirrm %%WWWDIR%%/dojox/io/proxy/tests + at dirrm %%WWWDIR%%/dojox/io/proxy + at dirrm %%WWWDIR%%/dojox/io + at dirrm %%WWWDIR%%/dojox/image/resources/images + at dirrm %%WWWDIR%%/dojox/image/resources + at dirrm %%WWWDIR%%/dojox/image + at dirrm %%WWWDIR%%/dojox/html + at dirrm %%WWWDIR%%/dojox/highlight/resources/pygments + at dirrm %%WWWDIR%%/dojox/highlight/resources + at dirrm %%WWWDIR%%/dojox/highlight/languages/pygments + at dirrm %%WWWDIR%%/dojox/highlight/languages + at dirrm %%WWWDIR%%/dojox/highlight + at dirrm %%WWWDIR%%/dojox/help + at dirrm %%WWWDIR%%/dojox/grid/resources/images + at dirrm %%WWWDIR%%/dojox/grid/resources + at dirrm %%WWWDIR%%/dojox/grid/compat/tests/support + at dirrm %%WWWDIR%%/dojox/grid/compat/tests/images + at dirrm %%WWWDIR%%/dojox/grid/compat/tests + at dirrm %%WWWDIR%%/dojox/grid/compat/resources + at dirrm %%WWWDIR%%/dojox/grid/compat/_grid/images + at dirrm %%WWWDIR%%/dojox/grid/compat/_grid + at dirrm %%WWWDIR%%/dojox/grid/compat/_data + at dirrm %%WWWDIR%%/dojox/grid/compat + at dirrm %%WWWDIR%%/dojox/grid/cells + at dirrm %%WWWDIR%%/dojox/grid/_grid + at dirrm %%WWWDIR%%/dojox/grid + at dirrm %%WWWDIR%%/dojox/gfx3d + at dirrm %%WWWDIR%%/dojox/gfx/resources + at dirrm %%WWWDIR%%/dojox/gfx + at dirrm %%WWWDIR%%/dojox/fx/resources + at dirrm %%WWWDIR%%/dojox/fx/ext-dojo + at dirrm %%WWWDIR%%/dojox/fx + at dirrm %%WWWDIR%%/dojox/form/resources/images + at dirrm %%WWWDIR%%/dojox/form/resources + at dirrm %%WWWDIR%%/dojox/form/nls/zh-tw + at dirrm %%WWWDIR%%/dojox/form/nls/zh + at dirrm %%WWWDIR%%/dojox/form/nls/tr + at dirrm %%WWWDIR%%/dojox/form/nls/th + at dirrm %%WWWDIR%%/dojox/form/nls/sv + at dirrm %%WWWDIR%%/dojox/form/nls/sl + at dirrm %%WWWDIR%%/dojox/form/nls/sk + at dirrm %%WWWDIR%%/dojox/form/nls/ru + at dirrm %%WWWDIR%%/dojox/form/nls/pt-pt + at dirrm %%WWWDIR%%/dojox/form/nls/pt + at dirrm %%WWWDIR%%/dojox/form/nls/pl + at dirrm %%WWWDIR%%/dojox/form/nls/nl + at dirrm %%WWWDIR%%/dojox/form/nls/nb + at dirrm %%WWWDIR%%/dojox/form/nls/ko + at dirrm %%WWWDIR%%/dojox/form/nls/ja + at dirrm %%WWWDIR%%/dojox/form/nls/it + at dirrm %%WWWDIR%%/dojox/form/nls/hu + at dirrm %%WWWDIR%%/dojox/form/nls/he + at dirrm %%WWWDIR%%/dojox/form/nls/fr + at dirrm %%WWWDIR%%/dojox/form/nls/fi + at dirrm %%WWWDIR%%/dojox/form/nls/es + at dirrm %%WWWDIR%%/dojox/form/nls/el + at dirrm %%WWWDIR%%/dojox/form/nls/de + at dirrm %%WWWDIR%%/dojox/form/nls/da + at dirrm %%WWWDIR%%/dojox/form/nls/cs + at dirrm %%WWWDIR%%/dojox/form/nls/ca + at dirrm %%WWWDIR%%/dojox/form/nls/ar + at dirrm %%WWWDIR%%/dojox/form/nls + at dirrm %%WWWDIR%%/dojox/form + at dirrm %%WWWDIR%%/dojox/flash + at dirrm %%WWWDIR%%/dojox/encoding/digests + at dirrm %%WWWDIR%%/dojox/encoding/crypto + at dirrm %%WWWDIR%%/dojox/encoding/compression + at dirrm %%WWWDIR%%/dojox/encoding + at dirrm %%WWWDIR%%/dojox/embed/resources + at dirrm %%WWWDIR%%/dojox/embed/IE + at dirrm %%WWWDIR%%/dojox/embed + at dirrm %%WWWDIR%%/dojox/editor/plugins/resources/images + at dirrm %%WWWDIR%%/dojox/editor/plugins/resources + at dirrm %%WWWDIR%%/dojox/editor/plugins/nls + at dirrm %%WWWDIR%%/dojox/editor/plugins + at dirrm %%WWWDIR%%/dojox/editor + at dirrm %%WWWDIR%%/dojox/dtl/utils + at dirrm %%WWWDIR%%/dojox/dtl/tag + at dirrm %%WWWDIR%%/dojox/dtl/render + at dirrm %%WWWDIR%%/dojox/dtl/filter + at dirrm %%WWWDIR%%/dojox/dtl/ext-dojo + at dirrm %%WWWDIR%%/dojox/dtl/contrib + at dirrm %%WWWDIR%%/dojox/dtl + at dirrm %%WWWDIR%%/dojox/date + at dirrm %%WWWDIR%%/dojox/data/s3 + at dirrm %%WWWDIR%%/dojox/data + at dirrm %%WWWDIR%%/dojox/cometd + at dirrm %%WWWDIR%%/dojox/color + at dirrm %%WWWDIR%%/dojox/collections + at dirrm %%WWWDIR%%/dojox/charting/widget + at dirrm %%WWWDIR%%/dojox/charting/themes/PlotKit + at dirrm %%WWWDIR%%/dojox/charting/themes/ET + at dirrm %%WWWDIR%%/dojox/charting/themes + at dirrm %%WWWDIR%%/dojox/charting/scaler + at dirrm %%WWWDIR%%/dojox/charting/plot3d + at dirrm %%WWWDIR%%/dojox/charting/plot2d + at dirrm %%WWWDIR%%/dojox/charting/axis2d + at dirrm %%WWWDIR%%/dojox/charting/action2d + at dirrm %%WWWDIR%%/dojox/charting + at dirrm %%WWWDIR%%/dojox/av/widget/resources/images + at dirrm %%WWWDIR%%/dojox/av/widget/resources + at dirrm %%WWWDIR%%/dojox/av/widget + at dirrm %%WWWDIR%%/dojox/av/resources + at dirrm %%WWWDIR%%/dojox/av + at dirrm %%WWWDIR%%/dojox/analytics/profiles + at dirrm %%WWWDIR%%/dojox/analytics/plugins + at dirrm %%WWWDIR%%/dojox/analytics/logger + at dirrm %%WWWDIR%%/dojox/analytics + at dirrm %%WWWDIR%%/dojox + at dirrm %%WWWDIR%%/dojo/rpc + at dirrm %%WWWDIR%%/dojo/resources/images + at dirrm %%WWWDIR%%/dojo/resources + at dirrm %%WWWDIR%%/dojo/nls/zh-tw + at dirrm %%WWWDIR%%/dojo/nls/zh + at dirrm %%WWWDIR%%/dojo/nls/tr + at dirrm %%WWWDIR%%/dojo/nls/th + at dirrm %%WWWDIR%%/dojo/nls/sv + at dirrm %%WWWDIR%%/dojo/nls/sl + at dirrm %%WWWDIR%%/dojo/nls/sk + at dirrm %%WWWDIR%%/dojo/nls/ru + at dirrm %%WWWDIR%%/dojo/nls/pt-pt + at dirrm %%WWWDIR%%/dojo/nls/pt + at dirrm %%WWWDIR%%/dojo/nls/pl + at dirrm %%WWWDIR%%/dojo/nls/nl + at dirrm %%WWWDIR%%/dojo/nls/nb + at dirrm %%WWWDIR%%/dojo/nls/ko + at dirrm %%WWWDIR%%/dojo/nls/ja + at dirrm %%WWWDIR%%/dojo/nls/it + at dirrm %%WWWDIR%%/dojo/nls/hu + at dirrm %%WWWDIR%%/dojo/nls/he + at dirrm %%WWWDIR%%/dojo/nls/fr + at dirrm %%WWWDIR%%/dojo/nls/fi + at dirrm %%WWWDIR%%/dojo/nls/es + at dirrm %%WWWDIR%%/dojo/nls/el + at dirrm %%WWWDIR%%/dojo/nls/de + at dirrm %%WWWDIR%%/dojo/nls/da + at dirrm %%WWWDIR%%/dojo/nls/cs + at dirrm %%WWWDIR%%/dojo/nls/ca + at dirrm %%WWWDIR%%/dojo/nls/ar + at dirrm %%WWWDIR%%/dojo/nls + at dirrm %%WWWDIR%%/dojo/io + at dirrm %%WWWDIR%%/dojo/fx + at dirrm %%WWWDIR%%/dojo/dnd + at dirrm %%WWWDIR%%/dojo/date + at dirrm %%WWWDIR%%/dojo/data/util + at dirrm %%WWWDIR%%/dojo/data/api + at dirrm %%WWWDIR%%/dojo/data + at dirrm %%WWWDIR%%/dojo/cldr/nls/zh-tw + at dirrm %%WWWDIR%%/dojo/cldr/nls/zh-cn + at dirrm %%WWWDIR%%/dojo/cldr/nls/zh + at dirrm %%WWWDIR%%/dojo/cldr/nls/pt-br + at dirrm %%WWWDIR%%/dojo/cldr/nls/pt + at dirrm %%WWWDIR%%/dojo/cldr/nls/ko-kr + at dirrm %%WWWDIR%%/dojo/cldr/nls/ko + at dirrm %%WWWDIR%%/dojo/cldr/nls/ja-jp + at dirrm %%WWWDIR%%/dojo/cldr/nls/ja + at dirrm %%WWWDIR%%/dojo/cldr/nls/it-it + at dirrm %%WWWDIR%%/dojo/cldr/nls/it + at dirrm %%WWWDIR%%/dojo/cldr/nls/fr + at dirrm %%WWWDIR%%/dojo/cldr/nls/es-es + at dirrm %%WWWDIR%%/dojo/cldr/nls/es + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-us + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-gb + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-ca + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-au + at dirrm %%WWWDIR%%/dojo/cldr/nls/en + at dirrm %%WWWDIR%%/dojo/cldr/nls/de-de + at dirrm %%WWWDIR%%/dojo/cldr/nls/de + at dirrm %%WWWDIR%%/dojo/cldr/nls + at dirrm %%WWWDIR%%/dojo/cldr + at dirrm %%WWWDIR%%/dojo/_firebug + at dirrm %%WWWDIR%%/dojo/_base/_loader + at dirrm %%WWWDIR%%/dojo/_base + at dirrm %%WWWDIR%%/dojo + at dirrm %%WWWDIR%%/dijit/themes/tundra/layout + at dirrm %%WWWDIR%%/dijit/themes/tundra/images + at dirrm %%WWWDIR%%/dijit/themes/tundra/form + at dirrm %%WWWDIR%%/dijit/themes/tundra + at dirrm %%WWWDIR%%/dijit/themes/themeTesterImages + at dirrm %%WWWDIR%%/dijit/themes/soria/layout + at dirrm %%WWWDIR%%/dijit/themes/soria/images + at dirrm %%WWWDIR%%/dijit/themes/soria/form + at dirrm %%WWWDIR%%/dijit/themes/soria + at dirrm %%WWWDIR%%/dijit/themes/nihilo/layout + at dirrm %%WWWDIR%%/dijit/themes/nihilo/images + at dirrm %%WWWDIR%%/dijit/themes/nihilo/form + at dirrm %%WWWDIR%%/dijit/themes/nihilo + at dirrm %%WWWDIR%%/dijit/themes/a11y + at dirrm %%WWWDIR%%/dijit/themes + at dirrm %%WWWDIR%%/dijit/resources + at dirrm %%WWWDIR%%/dijit/nls/zh-tw + at dirrm %%WWWDIR%%/dijit/nls/zh + at dirrm %%WWWDIR%%/dijit/nls/tr + at dirrm %%WWWDIR%%/dijit/nls/th + at dirrm %%WWWDIR%%/dijit/nls/sv + at dirrm %%WWWDIR%%/dijit/nls/sl + at dirrm %%WWWDIR%%/dijit/nls/sk + at dirrm %%WWWDIR%%/dijit/nls/ru + at dirrm %%WWWDIR%%/dijit/nls/pt-pt + at dirrm %%WWWDIR%%/dijit/nls/pt + at dirrm %%WWWDIR%%/dijit/nls/pl + at dirrm %%WWWDIR%%/dijit/nls/nl + at dirrm %%WWWDIR%%/dijit/nls/nb + at dirrm %%WWWDIR%%/dijit/nls/ko + at dirrm %%WWWDIR%%/dijit/nls/ja + at dirrm %%WWWDIR%%/dijit/nls/it + at dirrm %%WWWDIR%%/dijit/nls/hu + at dirrm %%WWWDIR%%/dijit/nls/he + at dirrm %%WWWDIR%%/dijit/nls/fr + at dirrm %%WWWDIR%%/dijit/nls/fi + at dirrm %%WWWDIR%%/dijit/nls/es + at dirrm %%WWWDIR%%/dijit/nls/el + at dirrm %%WWWDIR%%/dijit/nls/de + at dirrm %%WWWDIR%%/dijit/nls/da + at dirrm %%WWWDIR%%/dijit/nls/cs + at dirrm %%WWWDIR%%/dijit/nls/ca + at dirrm %%WWWDIR%%/dijit/nls/ar + at dirrm %%WWWDIR%%/dijit/nls + at dirrm %%WWWDIR%%/dijit/layout + at dirrm %%WWWDIR%%/dijit/form/nls/zh-tw + at dirrm %%WWWDIR%%/dijit/form/nls/zh + at dirrm %%WWWDIR%%/dijit/form/nls/tr + at dirrm %%WWWDIR%%/dijit/form/nls/th + at dirrm %%WWWDIR%%/dijit/form/nls/sv + at dirrm %%WWWDIR%%/dijit/form/nls/sl + at dirrm %%WWWDIR%%/dijit/form/nls/sk + at dirrm %%WWWDIR%%/dijit/form/nls/ru + at dirrm %%WWWDIR%%/dijit/form/nls/pt-pt + at dirrm %%WWWDIR%%/dijit/form/nls/pt + at dirrm %%WWWDIR%%/dijit/form/nls/pl + at dirrm %%WWWDIR%%/dijit/form/nls/nl + at dirrm %%WWWDIR%%/dijit/form/nls/nb + at dirrm %%WWWDIR%%/dijit/form/nls/ko + at dirrm %%WWWDIR%%/dijit/form/nls/ja + at dirrm %%WWWDIR%%/dijit/form/nls/it + at dirrm %%WWWDIR%%/dijit/form/nls/hu + at dirrm %%WWWDIR%%/dijit/form/nls/he + at dirrm %%WWWDIR%%/dijit/form/nls/fr + at dirrm %%WWWDIR%%/dijit/form/nls/fi + at dirrm %%WWWDIR%%/dijit/form/nls/es + at dirrm %%WWWDIR%%/dijit/form/nls/el + at dirrm %%WWWDIR%%/dijit/form/nls/de + at dirrm %%WWWDIR%%/dijit/form/nls/da + at dirrm %%WWWDIR%%/dijit/form/nls/cs + at dirrm %%WWWDIR%%/dijit/form/nls/ca + at dirrm %%WWWDIR%%/dijit/form/nls/ar + at dirrm %%WWWDIR%%/dijit/form/nls + at dirrm %%WWWDIR%%/dijit/form + at dirrm %%WWWDIR%%/dijit/_tree + at dirrm %%WWWDIR%%/dijit/_editor/plugins + at dirrm %%WWWDIR%%/dijit/_editor/nls/zh-tw + at dirrm %%WWWDIR%%/dijit/_editor/nls/zh + at dirrm %%WWWDIR%%/dijit/_editor/nls/tr + at dirrm %%WWWDIR%%/dijit/_editor/nls/th + at dirrm %%WWWDIR%%/dijit/_editor/nls/sv + at dirrm %%WWWDIR%%/dijit/_editor/nls/sl + at dirrm %%WWWDIR%%/dijit/_editor/nls/sk + at dirrm %%WWWDIR%%/dijit/_editor/nls/ru + at dirrm %%WWWDIR%%/dijit/_editor/nls/pt-pt + at dirrm %%WWWDIR%%/dijit/_editor/nls/pt + at dirrm %%WWWDIR%%/dijit/_editor/nls/pl + at dirrm %%WWWDIR%%/dijit/_editor/nls/nl + at dirrm %%WWWDIR%%/dijit/_editor/nls/nb + at dirrm %%WWWDIR%%/dijit/_editor/nls/ko + at dirrm %%WWWDIR%%/dijit/_editor/nls/ja + at dirrm %%WWWDIR%%/dijit/_editor/nls/it + at dirrm %%WWWDIR%%/dijit/_editor/nls/hu + at dirrm %%WWWDIR%%/dijit/_editor/nls/he + at dirrm %%WWWDIR%%/dijit/_editor/nls/fr + at dirrm %%WWWDIR%%/dijit/_editor/nls/fi + at dirrm %%WWWDIR%%/dijit/_editor/nls/es + at dirrm %%WWWDIR%%/dijit/_editor/nls/el + at dirrm %%WWWDIR%%/dijit/_editor/nls/de + at dirrm %%WWWDIR%%/dijit/_editor/nls/da + at dirrm %%WWWDIR%%/dijit/_editor/nls/cs + at dirrm %%WWWDIR%%/dijit/_editor/nls/ca + at dirrm %%WWWDIR%%/dijit/_editor/nls/ar + at dirrm %%WWWDIR%%/dijit/_editor/nls + at dirrm %%WWWDIR%%/dijit/_editor + at dirrm %%WWWDIR%%/dijit/_base + at dirrm %%WWWDIR%%/dijit + at dirrm %%WWWDIR%% --- /dev/null +++ www/dojo/Makefile @@ -0,0 +1,54 @@ +# $MidnightBSD: mports/www/dojo/Makefile,v 1.1 2009/01/29 17:52:54 laffer1 Exp $ + +PORTNAME= dojo +PORTVERSION= 1.2.3 +CATEGORIES= www +MASTER_SITES= http://download.dojotoolkit.org/release-${PORTVERSION}/ \ + LOCAL/glarkin +DISTNAME= dojo-release-${PORTVERSION} + +MAINTAINER= ports at MidnightBSD.org +COMMENT= An open-source DHTML toolkit written in JavaScript +LICENSE= bsd3 + +NO_BUILD= yes + +OPTIONS= APACHE "Configure for Apache-2.x" off + +.include + +PLIST_SUB+= WWWDIR=www/${PORTNAME} + +.if defined(WITH_APACHE) +USE_APACHE= 2.0+ +CONFDIR= ${PREFIX}/${CONFDIR_REL} +CONFDIR_REL= ${APACHEETCDIR}/Includes +PLIST_SUB+= NOAPACHE="" CONFDIR=${CONFDIR_REL} +CONF= dojo.conf +SUB_FILES+= pkg-message ${CONF} +.else +PLIST_SUB+= NOAPACHE="@comment " +.endif + +do-install: + @${MKDIR} ${PREFIX}/www/${PORTNAME} + (cd ${WRKSRC} && pax -rw . ${PREFIX}/www/${PORTNAME}) + @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${PREFIX}/www/${PORTNAME} + @${FIND} ${PREFIX}/www/${PORTNAME} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 + @${FIND} ${PREFIX}/www/${PORTNAME} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 + +.if defined(WITH_APACHE) +post-install: + @if [ -d "${CONFDIR}" ]; then \ + ${CP} ${WRKDIR}/${CONF} ${CONFDIR}/dojo.conf; \ + else \ + ${ECHO_MSG} "" ; \ + ${ECHO_MSG} "Please check your Apache 2.x installation -" ; \ + ${ECHO_MSG} "${CONFDIR} doesn't exist," ; \ + ${ECHO_MSG} "so I cannot install ${CONF} there!" ; \ + ${ECHO_MSG} "" ; \ + ${FALSE} ; \ + fi +.endif + +.include --- /dev/null +++ www/dojo/distinfo @@ -0,0 +1,3 @@ +MD5 (dojo-release-1.2.3.tar.gz) = ee6375dc812c75bbe3953b8c24f5cae5 +SHA256 (dojo-release-1.2.3.tar.gz) = 66afd514deff7f785dd3e95b31c72968677f0d9b3d6ba1da59743176b0d292fc +SIZE (dojo-release-1.2.3.tar.gz) = 1715583 --- /dev/null +++ www/dojo/files/pkg-message.in @@ -0,0 +1,11 @@ +You have just installed the Dojo DHTML toolkit. + +Note that you should restart your Apache web server to ensure that +the Dojo configuration file is loaded. + +Dojo toolkit demonstration pages can be found at: +http://localhost/dojo/dijit/demos/chat.html +http://localhost/dojo/dijit/demos/form.html +http://localhost/dojo/dijit/demos/i18n.html +http://localhost/dojo/dijit/demos/mail.html +http://localhost/dojo/dijit/demos/nihao.html --- /dev/null +++ www/dojo/files/dojo.conf.in @@ -0,0 +1,6 @@ +Alias /dojo %%WWWDIR%% + + + Order deny,allow + Allow from all + --- /dev/null +++ www/zend-framework/pkg-descr @@ -0,0 +1,6 @@ +This is a port of the Zend Framework. The Zend Framework aims to +provide an architecture for developing entire applications with no +other library dependencies. This code will always be actively developed, +tested, and supported by Zend and the PHP Collaboration Project. + +WWW: http://framework.zend.com/ --- /dev/null +++ www/zend-framework/pkg-plist @@ -0,0 +1,8135 @@ +%%DOJO%%%%DATADIR%%/externals/dojo/demos/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/13.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/1984.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/25.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/25_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/26.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/26_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/27.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/27_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/cinema.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/clicks.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/closterkeller.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/colony5.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/deinelakaien.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/genesis.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/godsbow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/made.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/main.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/nightspirit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/pati.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/redmprez.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/sieben.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/soon.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/thy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/alarm.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/bg.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/board.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/bubble.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/correct.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/incorrect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/questions.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/remaining.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/slow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/teacher_body.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/teacher_eyes_closed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/teacher_mouth_angry.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/try_again.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/MathFlashCard.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/MathFlashCard.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/Teacher.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/Teacher.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/Teacher.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/tests/test_Teacher.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/charts.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/comic.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/img/comicstrip.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/resources/bookplate.svg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/resources/digistrip.svg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/resources/eurostyle.svg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/charts.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/comic.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/news.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/pie.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/states.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/continents.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/flags.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/flags.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/languages.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/languages.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/model.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/normalizeJson.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/sprite.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/contacts.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/icons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/icons.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/mail.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/background.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/download.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/downloadnow.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/logo.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/logo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/shot3.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/shot3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/src/download.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/src/drop.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/en/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/fr/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/zh/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/accept.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/anchor.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_cascade.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_double.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_get.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_home.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_osx.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_osx_terminal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_boxes.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_contract.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_expand.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_list.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_tree.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_split.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_tile_horizontal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_tile_vertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_columns.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_detail.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_gallery.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_icons.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_list.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_tile.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_xp.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_xp_terminal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_branch.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_divide.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_down.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_inout.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_join.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_merge.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_redo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_refresh_small.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_rotate_anticlockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_rotate_clockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_switch.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_turn_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_turn_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_undo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_up.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/asterisk_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/asterisk_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/attach.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_bronze_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_bronze_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_bronze_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_gold_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_gold_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_gold_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_silver_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_silver_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_silver_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_remove.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bin_closed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bin_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bomb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_addresses.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_next.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_previous.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/box.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bricks.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/briefcase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_down.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_top.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_up.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_black.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_feed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_pink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_purple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_toggle_minus.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_toggle_plus.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_white.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cake.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_view_day.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_view_month.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_view_week.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_small.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cancel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/car.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/car_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/car_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_remove.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_burn.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_eject.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_organisation.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_organisation_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_organisation_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_pause.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_play.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_stop.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/coins.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/coins_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/coins_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/color_swatch.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/color_wheel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comments.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comments_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comments_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/compress.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/connect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_decrease.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_high.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_increase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_low.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_eject.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_eject_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_end.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_end_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_equalizer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_equalizer_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_fastforward.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_fastforward_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_pause.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_pause_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_play.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_play_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_repeat.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_repeat_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_rewind.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_rewind_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_start.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_start_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_stop.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_stop_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/creditcards.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cross.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cursor.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cut.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cut_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_connect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_table.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_next.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_previous.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/disconnect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/disk_multiple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drink_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_burn.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_cd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_cd_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_network.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_rename.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_web.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_attach.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_open_image.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_evilgrin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_grin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_happy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_smile.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_surprised.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_tongue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_unhappy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_waii.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_wink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/exclamation.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/eye.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/female.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_pink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_purple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_bell.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_brick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_bug.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_camera.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_explore.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_feed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_heart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_image.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_lightbulb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_page.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_page_white.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_palette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_table.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/heart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/heart_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/heart_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/help.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/house.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/house_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/house_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/images.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/information.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_cast.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_cast_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_cast_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_sound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layers.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_content.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_header.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_sidebar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb_off.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_break.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_break.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_flatbed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/magifier_zoom_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/magnifier.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/magnifier_zoom_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/male.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_dollar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_euro.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_pound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_yen.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/music.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/new.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/overlays.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_attach.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_code.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_copy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_excel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_paintbrush.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_paste.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_acrobat.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_actionscript.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_c.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_camera.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_cd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_code.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_code_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_coldfusion.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_compressed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_copy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_cplusplus.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_csharp.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_cup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_dvd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_excel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_flash.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_freehand.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_get.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_h.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_horizontal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_medal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_office.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_paint.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_paintbrush.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_paste.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_php.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_powerpoint.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_ruby.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_stack.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_swoosh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_text.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_text_width.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_tux.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_vector.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_visualstudio.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_width.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_world.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_zip.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_world.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paintbrush.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paintcan.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/palette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paste_plain.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paste_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone_sound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photos.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pictures.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pilcrow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_disabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rainbow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_first.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_last.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_next.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_previous.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rosette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_get.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_code.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_code_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_palette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_chart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_compressed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_connect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_uncompressed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shading.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_center.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_middle.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_top.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_flip_horizontal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_flip_vertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_group.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_handles.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_back.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_backwards.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_forwards.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_front.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_rotate_anticlockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_rotate_clockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_ungroup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sitemap.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sitemap_color.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_low.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_mute.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_none.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/spellcheck.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_8ball.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_basketball.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_football.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_golf.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_raquet.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_shuttlecock.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_soccer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_tennis.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_away.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_busy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_offline.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_online.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/stop.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sum.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_multiple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_relationship.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_row_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_row_insert.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_sort.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_pink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_purple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/television.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/television_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/television_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_center.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_justify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_allcaps.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_bold.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_columns.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_dropcaps.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_4.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_5.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_6.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_horizontalrule.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_indent.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_indent_remove.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_italic.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_kerning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_letter_omega.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_letterspacing.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_linespacing.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_list_bullets.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_list_numbers.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_lowercase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_top.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_replace.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_signature.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_smallcaps.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_strikethrough.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_subscript.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_superscript.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_underline.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_uppercase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_rename.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/thumb_down.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/thumb_up.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/timeline_marker.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tux.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_comment.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_female.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_gray.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_suit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vector.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vector_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vector_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/wand.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_clouds.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_cloudy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_rain.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_snow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_sun.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/wrench_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/zoom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/zoom_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/zoom_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/readme.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/readme.txt +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/users.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/buildDemo.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/imageReflect.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/bg01.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/info.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/logo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/round.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/square.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/alex.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/becka11y.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/bforbes.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/blowery.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/blowery.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/bradn.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dante.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dante.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/davidb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dmachi.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dmachi.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dylanks.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/eugene.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/gregw.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/heng.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/itorrey.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/itorrey.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/jared_j.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/kris.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/mccain.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/nonken.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/ntoone.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/pottedmeat.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/rcoup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/sfoster.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/ttrenka.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/wildbill.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/src/Image.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/src/image-lib.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/UploadFile.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/buildDemo.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/cLOG.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/buildDemo.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/blkBk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/playerIcons +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/volBack.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/volBackOver.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/volMask.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/items.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Clayman_01.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Clayman_02.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Clayman_03.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Grog.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Manager.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/OldMan.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/TapDance.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Walkin.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Clayman_01.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Clayman_02.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Clayman_03.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Grog.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Manager.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/OldMan.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/TapDance.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Walkin.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/ColorPalette.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Declaration.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Dialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Editor.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/InlineEditBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Menu.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/ProgressBar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/TitlePane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Toolbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Tooltip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Tree.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Calendar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Container.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Templated.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_TimePicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Widget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/focus.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/manager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/place.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/popup.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/scroll.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/sniff.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/typematic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/wai.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/window.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/RichText.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/_Plugin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ar/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ar/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ar/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ca/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ca/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ca/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/cs/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/cs/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/cs/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/da/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/da/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/da/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/de/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/de/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/de/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/el/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/el/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/el/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/es/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/es/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/es/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fi/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fi/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fi/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fr/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fr/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fr/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/he/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/he/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/he/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/hu/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/hu/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/hu/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/it/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/it/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/it/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ja/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ja/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ja/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ko/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ko/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ko/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nb/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nb/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nb/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nl/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nl/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nl/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pl/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pl/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pl/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ru/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ru/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ru/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sk/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sk/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sk/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sl/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sl/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sl/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sv/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sv/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sv/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/th/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/th/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/th/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/tr/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/tr/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/tr/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/AlwaysShowToolbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/EnterKeyHandling.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/TabIndent.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/TextColor.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/ToggleDir.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/range.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/selection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/Node.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/Tree.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/dndContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/dndSelector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/dndSource.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/model.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/dijit-all.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/dijit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Button.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/CheckBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/CurrencyTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/DateTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/FilteringSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Form.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/MultiSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/NumberSpinner.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/NumberTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/SimpleTextarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Slider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/TextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/TimeTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/ValidationTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/_DateTimeTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/_FormWidget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/_Spinner.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ar/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ar/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ar/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ca/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ca/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ca/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/cs/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/cs/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/cs/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/da/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/da/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/da/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/de/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/de/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/de/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/el/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/el/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/el/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/es/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/es/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/es/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fi/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fi/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fi/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fr/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fr/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fr/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/he/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/he/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/he/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/hu/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/hu/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/hu/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/it/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/it/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/it/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ja/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ja/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ja/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ko/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ko/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ko/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nb/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nb/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nb/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nl/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nl/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nl/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pl/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pl/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pl/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ru/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ru/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ru/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sk/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sk/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sk/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sl/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sl/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sl/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sv/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sv/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sv/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/th/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/th/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/th/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/tr/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/tr/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/tr/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/Button.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/CheckBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/ComboBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/ComboButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/DropDownButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/HorizontalSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/Spinner.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/TextBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/ValidationTextBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/VerticalSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/AccordionContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/BorderContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/ContentPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/LayoutContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/LinkPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/SplitContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/StackContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/TabContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/_LayoutWidget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/templates/AccordionPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/templates/TabContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/templates/_TabButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ar/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ar/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ca/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ca/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/cs/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/cs/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/da/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/da/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/de/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/de/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/el/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/el/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/es/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/es/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fi/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fi/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fr/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fr/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/he/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/he/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/hu/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/hu/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/it/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/it/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ja/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ja/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ko/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ko/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nb/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nb/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nl/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nl/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pl/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pl/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt-pt/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt-pt/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ru/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ru/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sk/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sk/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sl/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sl/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sv/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sv/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/th/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/th/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/tr/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/tr/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh-tw/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh-tw/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/resources/_modules.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/robot.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/robotx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/Calendar.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/ColorPalette.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/Dialog.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/InlineEditBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/ProgressBar.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/TimePicker.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/TitlePane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/Tooltip.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/TooltipDialog.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/tests/_data/countries.json +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/tests/_testCommon.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/README.txt +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/colors3x4.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/colors7x10.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/indeterminate_progress.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/dijit.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/dijit_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Calendar_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/ColorPalette.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Dialog_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Editor.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Editor_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Menu.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Menu_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/ProgressBar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/TimePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/TitlePane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/TitlePane_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Toolbar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Tree.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Tree_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Button.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Button_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Checkbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/ComboBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Common_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/RadioButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Slider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Slider_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/TimeTextBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/accordionItemActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editor.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editorDisabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editorDisabled_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/no.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/progressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/progressBarEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/progressBarFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderEmptyVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFullFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFullVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFullVerticalFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerH-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerH.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerV-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerV.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteArrows.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteArrows.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteCheckbox.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteCheckbox.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteDivIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteDivIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRadio.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRadio.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRoundedIconsSmall.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRoundedIconsSmall.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree_rtl.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomActiveC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomActiveSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomEnabledC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomEnabledSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomHoverC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomHoverSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabContainerSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabLeftChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabRightChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripe.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripeBottom.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripeLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripeRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/titleBar.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/titleBarActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorLeft.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorRight.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorUp.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeExpand_loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI_half.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI_half_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/validationInputBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/validationInputBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/AccordionContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/AccordionContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/BorderContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/ContentPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/SplitContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/TabContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/TabContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/nihilo.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/nihilo_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/close.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/closeActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/closeHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-center.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-center.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-right-06.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-center.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/images.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerActive-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerActive-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerHover-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerHover-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/noir.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/noir.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/noir.psd +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Calendar_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/ColorPalette.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Dialog_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Editor.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Editor_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Menu.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Menu_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/ProgressBar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/TimePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/TitlePane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/TitlePane_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Toolbar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Tree.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Tree_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Button.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Button_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Checkbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/ComboBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Common_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/RadioButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Slider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Slider_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/TimeTextBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/accordionItemActive.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/accordionItemActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editor.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editorDisabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editorDisabled_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/progressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/progressBarEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/progressBarFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderEmptyVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFullFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFullVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFullVerticalFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerH-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerH.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerV-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerV.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteArrows.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteArrows.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteCheckbox.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteCheckbox.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteDivIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteDivIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRadio.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRadio.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmall.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmall.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmallBl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmallBl.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree_rtl.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomActiveC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomActiveSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomEnabledC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomEnabledSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomHoverC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomHoverSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabContainerSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabLeftChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabRightChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripe.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripeBottom.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripeLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripeRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/titleBar.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/titleBarActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorLeft.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorRight.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorUp.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeExpand_loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI_half.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI_half_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/validationInputBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/validationInputBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/AccordionContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/AccordionContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/BorderContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/ContentPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/SplitContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/TabContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/TabContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/soria.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/soria_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/templateThemeTest.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTester.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTesterImages/blackButtonEnabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTesterImages/blackButtonHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTesterQuirk.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Calendar_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/ColorPalette.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Dialog_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Editor.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Editor_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Menu.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Menu_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/ProgressBar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/TimePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/TitlePane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/TitlePane_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Toolbar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Tree.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Tree_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Button.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Checkbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Common_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/RadioButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Slider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Slider_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/accordionItemActive.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/accordionItemHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/calendarDayLabel.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/calendarMonthLabel.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/calendarYearLabel.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmark.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmark.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmarkNoBorder.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmarkNoBorder.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/circleIcon.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/circleIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/comboArrowDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dijitProgressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dijitProgressBarAnim.psd +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dojoTundraGradientBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dojoTundraGradientBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/doubleArrowDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/doubleArrowUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editor.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editorDisabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editorDisabled_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/folderClosed.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/folderOpened.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i_half.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i_half_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/leaf.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/menu.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/minusButton.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/no.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/noX.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/plusButton.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/popupMenuBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-1.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-2.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-3.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-4.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-5.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-6.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-7.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-8.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-9.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim.psd +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonActiveDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonActiveHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderEmptyVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFullFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFullVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFullVerticalFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/smallArrowDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/smallArrowUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerH-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerH.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerV-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerV.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteArrows.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteArrows.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteRoundedIconsSmall.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteRoundedIconsSmall.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabClose.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabClose.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabCloseHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabCloseHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/titleBar.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/titleBarBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorLeft.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorRight.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorUp.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_leaf.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_leaf_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_minus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_minus_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_mius.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_plus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_plus_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/validationInputBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/validationInputBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/AccordionContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/BorderContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/ContentPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/SplitContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/TabContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/TabContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/tundra.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/AdapterRegistry.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/DeferredList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/NodeList-fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/NodeList-html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/OpenAjax.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/Color.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/Deferred.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/NodeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/bootstrap.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/hostenv_browser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/hostenv_rhino.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/hostenv_spidermonkey.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/loader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/loader_debug.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/loader_xd.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/array.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/browser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/connect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/declare.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/event.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/json.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/lang.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/query.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/window.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/xhr.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/errorIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/firebug.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/firebug.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/infoIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_lft_norm.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_lft_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_rgt_norm.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_rgt_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/warningIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/back.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/behavior.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/monetary.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de-de/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-ca/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-ca/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-gb/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-gb/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-us/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-us/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es-es/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es-es/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/fr/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/fr/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/fr/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it-it/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja-jp/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko-kr/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko-kr/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt-br/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-cn/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-cn/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/supplemental.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cookie.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/ItemFileReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/ItemFileWriteStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Identity.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Notification.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Read.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Request.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Write.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/util/filter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/util/simpleFetch.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/util/sorter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/date.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/date/locale.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/date/stamp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Avatar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Container.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Manager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Moveable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Mover.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Selector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Source.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/TimedMoveable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/autoscroll.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/move.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dojo.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/fx/easing.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/gears.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/i18n.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/io/iframe.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/io/script.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/jaxer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ar/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ca/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/cs/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/da/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/de/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/el/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/es/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/fi/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/fr/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/he/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/hu/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/it/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ja/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ko/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/nb/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/nl/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/pl/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/pt-pt/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/pt/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ru/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/sk/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/sl/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/sv/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/th/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/tr/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/zh-tw/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/zh/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/parser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/regexp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/_modules.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/blank.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/blank.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/dnd.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/dojo.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/iframe_history.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/robot.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/robotx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/rpc/JsonService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/rpc/JsonpService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/rpc/RpcService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/string.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/tests.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/Urchin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/logger/JSON.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/logger/dojoxAnalytics.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/consoleMessages.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/dojo.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/idle.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/mouseClick.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/mouseOver.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/window.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/profiles/analytics.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/profiles/analyticsInBase.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/FLVideo.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/_Media.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/resources/version.mov +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/resources/video.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/PlayButton.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/Player.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/ProgressSlider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/Status.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/VolumeButton.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/PlayButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/Player.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/Player.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/ProgressSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/Status.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/VolumeButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/dojoPlayerIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/playerIcons +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/player_sprite.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/progressLoadedBk.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/progressPositionBk.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/sliderHandleNorm.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/sliderHandleOver.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/sliderHandleSprite.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Chart2D.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Chart3D.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Element.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Series.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Theme.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Highlight.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Magnify.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/MoveSlice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Shake.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Tooltip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/axis2d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/axis2d/Default.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/axis2d/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Areas.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Bars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Bubble.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/ClusteredBars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/ClusteredColumns.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Columns.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Default.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Lines.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Markers.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/MarkersOnly.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Pie.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Scatter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Stacked.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedAreas.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedBars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedColumns.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedLines.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot3d/Bars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot3d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot3d/Cylinders.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/scaler/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/scaler/linear.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/scaler/primitive.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Adobebricks.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Algae.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Bahamation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/BlueDusk.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/CubanShirts.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Desert.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Dollar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/ET/greys.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Grasshopper.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Grasslands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/GreySkies.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/IndigoNation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Ireland.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/MiamiNice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Midwest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Minty.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/blue.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/cyan.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/green.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/orange.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/purple.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/red.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PurpleRain.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/RoyalPurples.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/SageToLime.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Shrooms.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Tufte.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/WatersEdge.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Wetland.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/widget/Chart2D.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/widget/Legend.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/widget/Sparkline.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/ArrayList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/BinaryTree.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Dictionary.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Queue.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Set.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/SortedList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Stack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/Colorspace.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/Generator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/Palette.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/HttpChannels.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/RestChannels.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/callbackPollTransport.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/longPollTransport.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/longPollTransportFormEncoded.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/longPollTransportJsonEncoded.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/timestamp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/timesync.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/AndOrReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/AndOrWriteStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/AtomReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/ClientFilter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CouchDBRestStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CssClassStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CssRuleStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CsvStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/FileStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/FlickrRestStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/FlickrStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/GoogleFeedStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/GoogleSearchStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/HtmlStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/HtmlTableStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/JsonRestStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/KeyValueStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/OpmlStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/PersevereStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/PicasaStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/QueryReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/S3Store.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/ServiceStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/SnapLogicStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/WikipediaStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/XmlStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/css.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/dom.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/jsonPathStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/restListener.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/s3/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/s3/proxy.example-php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/HebrewDate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/IslamicDate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/php.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/posix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/Context.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/_HtmlTemplated.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/_Templated.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/data.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/dijit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/objects.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/ext-dojo/NodeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/dates.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/htmlstrings.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/integers.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/lists.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/logic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/misc.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/strings.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/render/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/date.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/loader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/logic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/loop.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/misc.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/utils/date.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/TablePlugins.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/UploadImage.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/nls/TableDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/editorPlugins.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/busy.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/cellpad.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/cellspace.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/tableIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/uploadImageIcon.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/insertTable.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/modifyTable.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/Flash.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/IE/flash.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/Object.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/Quicktime.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/resources/version.mov +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/ascii85.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/base64.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/bits.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/compression/lzw.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/compression/splay.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/crypto/Blowfish.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/crypto/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/digests/MD5.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/digests/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/easy64.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/DojoExternalInterface.as +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/ExpressInstall.as +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/BusyButton.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/CheckedMultiSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/DateTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/DropDownSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/DropDownStack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FileInput.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FileInputAuto.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FilePickerTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FileUploader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/MultiComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/RadioStack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/RangeSlider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/Rating.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/TimeSpinner.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/_FormSelectWidget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/_HasDropDown.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/_SelectStackMixin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ar/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ca/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/cs/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/da/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/de/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/el/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/es/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/fi/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/fr/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/he/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/hu/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/it/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ja/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ko/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/nb/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/nl/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/pl/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/pt-pt/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/pt/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ru/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/sk/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/sl/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/sv/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/th/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/tr/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/zh-tw/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/zh/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/BusyButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/CheckedMultiSelect.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/CheckedMultiSelect.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/DropDownSelect.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/DropDownSelect.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FileInput.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FileInput.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FileInputAuto.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FilePickerTextBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FilePickerTextBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/HorizontalRangeSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/PasswordValidator.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/RangeSlider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/Rating.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/RecieveFile.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/UploadFile.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/VerticalRangeSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/_CheckedMultiSelectItem.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/cLOG.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/loading_wheel.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/nihiloFolderSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/rating_empty.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/rating_full.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/soriaFolderSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/tundraFolderSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/uploader.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/Shadow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/_arg.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/_core.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/easing.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/ext-dojo/NodeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/flip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowB.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowBL.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowBR.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowL.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowR.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowT.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowTL.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowTR.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/scroll.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/split.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/style.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/text.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/Moveable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/Mover.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/VectorText.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/arc.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/canvas.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/canvas_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/decompose.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/matrix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/move.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/path.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/resources/Gillius.svg +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/resources/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/shape.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/silverlight.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/silverlight_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/svg.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/svg_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/utils.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/vml.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/vml_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/gradient.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/lighting.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/matrix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/object.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/scheduler.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/vector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/DataGrid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/DataSelection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/Selection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/VirtualGrid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_EditManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Events.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_FocusManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Layout.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_RowManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_RowSelector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Scroller.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_View.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_ViewManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/Grid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/Grid_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/nihiloGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/soriaGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/tundraGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/cells.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/cells/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/cells/dijit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/VirtualGrid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/dijitEditors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/editors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/fields.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/model.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/Grid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/Grid_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/builder.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/cell.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/drag.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/edit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/focus.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/grid_dx_gradient.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/grid_sort_down.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/grid_sort_up.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/tabEnabled_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/tabHover_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/layout.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/lib.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/nihiloGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/publicEvents.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/rowbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/rows.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/scroller.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/selection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/soriaGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/tundraGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/view.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/views.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/resources/GridView.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/resources/VirtualGrid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/databaseModel.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images/closed.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images/flatScreen.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images/open.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/books.xml +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/data.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/geography.xml +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/json.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/movies.csv +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/test_data.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/test_data_objects.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/testtbl.sql +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/yahoo_search.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_change_structure.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_custom_sort.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_empty.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model_EmptyResultSet.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model_multiStores.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model_processError.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_notification.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_edit_canEdit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_edit_dijit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_events.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_expand.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_dlg.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_headerHeight.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_layout.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_layout_LayoutContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_layout_borderContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_object_model_change.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_programmatic.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_programmatic_layout.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_rtl.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_themes.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_tooltip_menu.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_keyboard.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_markup.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_mysql_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_sizing.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_sizing_100rows.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_sizing_ResizeHandle.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_styling.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_subgrid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_tundra_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_yahoo_images.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_yahoo_search.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/yahooSearch.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/Grid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/Grid_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/View.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/_Grid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/grid_dx_gradient.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/grid_sort_down.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/grid_sort_up.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/tabEnabled_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/tabHover_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/nihiloGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/soriaGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/tundraGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/help/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/help/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/help/console.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_all.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_dynamic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_static.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_www.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/cpp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/css.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/delphi.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/django.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/javascript.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/_html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/_www.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/css.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/javascript.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/xml.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/python.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/sql.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/xml.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/highlight.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/autumn.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/borland.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/colorful.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/default.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/emacs.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/friendly.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/fruity.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/manni.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/murphy.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/native.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/pastie.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/perldoc.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/trac.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/metrics.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/styles.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Badge.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/FlickrBadge.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Gallery.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Lightbox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Magnifier.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/MagnifierLite.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/SlideShow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/ThumbnailPicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Badge.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Gallery.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Gallery.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Lightbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Lightbox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Magnifier.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/SlideShow.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/SlideShow.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/ThumbnailPicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/ThumbnailPicker.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/image.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/buttons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/buttons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/close.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/close.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/close_dark.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/left.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/right.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/httpParse.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/tests/frag.xml +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/tests/xip.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/xip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/xip_client.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/xip_server.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/scriptFrame.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/windowName.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/xhrMultiPart.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/xhrPlugins.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/xhrWindowNamePlugin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/query.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/ref.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/schema.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/jsonPath.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/jsonPath/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/jsonPath/query.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/cflow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/counter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/memoizer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/memoizerGuard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/profiler.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/timer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/tracer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/array.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/binrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/curry.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/fold.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/lambda.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/linrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/listcomp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/multirec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/numrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/object.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/reversed.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/scan.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/sequence.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/tailrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/zip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/mix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/observable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/utils.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/BorderContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ContentPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/DragPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ExpandoPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/FloatingPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/RadioGroup.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ResizeHandle.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/RotatorContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ScrollPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ToggleSplitter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/dnd/Avatar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/dnd/PlottedDnd.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/nls/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/nls/en/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/nls/fr/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/DndGridContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ExpandoPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ExpandoPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/FloatingPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/FloatingPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/GridContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/GridContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/RadioGroup.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ResizeHandle.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/RotatorContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ScrollPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ScrollPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ToggleSplitter.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/grip_bg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/pixel.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/resize.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/rotator.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/curves.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/matrix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/_common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/docs/bookmarklets.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/files.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/network_check.txt +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/offline.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/checkmark.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/greenball.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/learnhow.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/learnhow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/offline-widget.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/offline-widget.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/redball.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/roller.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/sync.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/ui.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/Show.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/Show.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/Slide.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/down.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/next.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/prev.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/up.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/README.template +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/_modules.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/explore.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/manualTests.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/manualTests.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/robot/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/robot/recorder.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/Client.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/JsonRPC.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/JsonRest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/OfflineRest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/ProxiedPath.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/Rest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/dojo-api.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/geonames.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/google.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/wikipedia.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/yahoo.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/Service.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/test.txt +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/DOM.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/capability.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/sandbox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Anchor.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Annotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/DoubleArrowAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Figure.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/LeadAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/PreexistingAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/SingleArrowAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Slider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Toolbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/UnderlineAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/UndoStack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/_Plugin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/resources/images/icons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/resources/sketch.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/_crypto.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/AirDBStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/AirEncryptedLocalStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/AirFileStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/FlashStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/GearsStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/Provider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/Storage.as +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/Storage.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/WhatWGStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/_common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/buildFlashStorage.sh +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/manager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/storage_dialog.fla +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/storage_dialog.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/BidiComplex.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/Builder.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/sprintf.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/tokenize.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/testing/DocTest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/testing/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/Sequence.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/Streamer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/ThreadPool.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/Uuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/generateRandomUuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/generateTimeBasedUuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/ca.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/check.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/creditCard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/isbn.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/regexp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/us.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/web.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/Calendar.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/CalendarDay.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/CalendarMonth.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/CalendarYear.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/CalendarFx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/ColorPicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/ColorPicker.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/hue.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/hueHandle.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/pickerPointer.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/underlay.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/Dialog.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/images/dialogCloseButton.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/images/dialogCloseButton.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/DocTester.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/DocTester/DocTester.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/DocTester/DocTester.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/FilePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/_FileInfoPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images/nihiloFileIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images/soriaFileIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images/tundraFileIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FisheyeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FisheyeList/FisheyeList.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FisheyeLite.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Iterator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Loader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Loader/Loader.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Loader/icons/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/Pager.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/Pager.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/hNext.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/hPrevious.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/pageActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/pageInactive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/vNext.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/vPrevious.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/PlaceholderMenuItem.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Roller.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/RollingList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/RollingList/RollingList.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/SortList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/SortList/SortList.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/SortList/SortList.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Toaster.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Toaster/Toaster.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Wizard/Wizard.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Wizard/Wizard.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/FilePicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/RollingList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ar/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ca/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/cs/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/da/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/de/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/el/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/es/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/fi/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/fr/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/he/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/hu/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/it/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ja/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ko/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/nb/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/nl/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/pl/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/pt-pt/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/pt/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ru/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/sk/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/sl/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/sv/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/th/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/tr/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/zh-tw/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/zh/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/CompositeWire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/DataWire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/TableAdapter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/TextAdapter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/TreeAdapter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/Wire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/XmlWire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Action.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Data.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/DataStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Invocation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Service.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Transfer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/DomParser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/Script.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/parser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/widgetParser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/ChatService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/PresenceService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/RosterService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/TransportSession.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/UserService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/sasl.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/widget/ChatSession.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/widget/templates/ChatSession.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/xmppSession.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build.bat +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build_mini.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build_notice.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build_release.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cdnBuild.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/changeVersion.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/alias.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/arrayInherit.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/build.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/calendar.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/cldrUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/currency.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/CatalogManager.properties +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/catalog +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/core.zip +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/ldml.dtd +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/APL-2.0.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/MPL-1.0.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/MPL-1.1.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/ant-apache-bsf.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/bsf.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/js.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/resolver.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/saxon8.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/number.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/specialLocale.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/util.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/clean_release.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/copyright.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/buildUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/buildUtilXd.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/checkBuildSize.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/convertTestsToXDomain.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/dojoGuardEnd.jsfrag +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/dojoGuardStart.jsfrag +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/fileUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/i18nUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/logger.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/Packer.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/Words.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/base2.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/listProfileDeps.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/makeDojoJsWeb.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/mk_branch.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/base.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/cometd.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/demos-all.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/dtkapi.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/fx.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/layers.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/offline.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/rhino.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/sql.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/standard.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/standardCustomBase.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/storage.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/conditionalTest.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/conditionalTest.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/foo/page/view.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/profiles/customBase.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/profiles/nestedNls.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild.php +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/builder_ui.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/dojo.js.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps.properties +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Global/download.skin +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Global/global.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Root/main.hac +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/app.properties +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/index.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/makeWebBuildModuleList.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/topIndex.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/webbuild.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/webbuild.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/Robot.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_browserRunner.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_rhinoRunner.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/doh.wav +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/dohaaa.wav +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/woohoo.wav +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/DOHRobot.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/DOHRobot.java +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/compilerobot.bat +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/robot.css +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/runner.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/runner.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/runner.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/small_logo.png +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/tests/robot.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/README.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo-war/pom.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java/org/dojotoolkit/DojoFilter.java +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/webapp/WEB-INF/web.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo/pom.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo/src/main/assembly/dojo.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/pom.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/BUILD +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/MPL-1.1.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/custom_rhino.diff +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/custom_rhino.jar +%%INCUBATOR%%%%DATADIR%%/incubator/bin/zf.bat +%%INCUBATOR%%%%DATADIR%%/incubator/bin/zf.php +%%INCUBATOR%%%%DATADIR%%/incubator/bin/zf.sh +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Console/Getopt.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Class.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag/Param.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag/Return.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Extension.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Function.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Method.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Parameter.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Property.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Apache/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Body.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Class.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag/Param.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag/Return.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Member/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Member/Container.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Method.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Parameter.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Property.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli/ArgumentParser.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli/Manifest.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Dispatcher.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Request.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Response.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/Chain.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/IncludePathLoader.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/IncludePathLoader/RecursiveFilterIterator.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/ActionMetadata.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/Metadata.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/ProviderMetadata.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Action.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Signature.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Action/Create.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Action/Delete.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Manifest.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider/Phpinfo.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider/Providers.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider/Version.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem/Directory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/INotOverwritable.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ISystem.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ITopLevel.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ProjectDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ProjectProfileFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ProjectProvidersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ApisDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ApplicationDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/BootstrapFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/CacheDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ConfigsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ControllerFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ControllersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/DataDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/HtaccessFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LayoutsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LibraryDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LocalesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LogsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ModelsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ModulesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicImagesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicIndexFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicScriptsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicStylesheetsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/SearchIndexesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/SessionsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/TemporaryDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/TestsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/UploadsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewControllerScriptsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewFiltersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewHelpersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewScriptFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewScriptsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ZfStandardLibraryDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/FileParser/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/FileParser/Xml.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Iterator/EnabledResource.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource/Container.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource/SearchConstraints.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Action.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Controller.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Manifest.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Profile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Project.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/View.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/AllTests.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/TestConfiguration.php.dist +%%INCUBATOR%%%%DATADIR%%/incubator/tests/TestHelper.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/ClassTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/Tag/ParamTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/Tag/ReturnTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/TagTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/DocblockTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/ExtensionTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/FileTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/FunctionTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/MethodTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/ParameterTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/PropertyTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/_files/TestSampleClass.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/ClassTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/FileTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/MethodTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/PropertyTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/_files/TestSampleSingleClass.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/AllTests.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/Context/RegistryTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/ProfileTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/_files/.zfproject.xml.orig +%%DATADIR%%/library/Zend/Acl.php +%%DATADIR%%/library/Zend/Acl/Assert/Interface.php +%%DATADIR%%/library/Zend/Acl/Exception.php +%%DATADIR%%/library/Zend/Acl/Resource.php +%%DATADIR%%/library/Zend/Acl/Resource/Interface.php +%%DATADIR%%/library/Zend/Acl/Role.php +%%DATADIR%%/library/Zend/Acl/Role/Interface.php +%%DATADIR%%/library/Zend/Acl/Role/Registry.php +%%DATADIR%%/library/Zend/Acl/Role/Registry/Exception.php +%%DATADIR%%/library/Zend/Amf/Constants.php +%%DATADIR%%/library/Zend/Amf/Exception.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf0/Deserializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf0/Serializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf3/Deserializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf3/Serializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Deserializer.php +%%DATADIR%%/library/Zend/Amf/Parse/InputStream.php +%%DATADIR%%/library/Zend/Amf/Parse/OutputStream.php +%%DATADIR%%/library/Zend/Amf/Parse/Serializer.php +%%DATADIR%%/library/Zend/Amf/Parse/TypeLoader.php +%%DATADIR%%/library/Zend/Amf/Request.php +%%DATADIR%%/library/Zend/Amf/Request/Http.php +%%DATADIR%%/library/Zend/Amf/Response.php +%%DATADIR%%/library/Zend/Amf/Response/Http.php +%%DATADIR%%/library/Zend/Amf/Server.php +%%DATADIR%%/library/Zend/Amf/Server/Exception.php +%%DATADIR%%/library/Zend/Amf/Util/BinaryStream.php +%%DATADIR%%/library/Zend/Amf/Value/ByteArray.php +%%DATADIR%%/library/Zend/Amf/Value/MessageBody.php +%%DATADIR%%/library/Zend/Amf/Value/MessageHeader.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/AbstractMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/AcknowledgeMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/AsyncMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/CommandMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/ErrorMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/RemotingMessage.php +%%DATADIR%%/library/Zend/Amf/Value/TraitsInfo.php +%%DATADIR%%/library/Zend/Auth.php +%%DATADIR%%/library/Zend/Auth/Adapter/DbTable.php +%%DATADIR%%/library/Zend/Auth/Adapter/Digest.php +%%DATADIR%%/library/Zend/Auth/Adapter/Exception.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver/Exception.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver/File.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver/Interface.php +%%DATADIR%%/library/Zend/Auth/Adapter/InfoCard.php +%%DATADIR%%/library/Zend/Auth/Adapter/Interface.php +%%DATADIR%%/library/Zend/Auth/Adapter/Ldap.php +%%DATADIR%%/library/Zend/Auth/Adapter/OpenId.php +%%DATADIR%%/library/Zend/Auth/Exception.php +%%DATADIR%%/library/Zend/Auth/Result.php +%%DATADIR%%/library/Zend/Auth/Storage/Exception.php +%%DATADIR%%/library/Zend/Auth/Storage/Interface.php +%%DATADIR%%/library/Zend/Auth/Storage/NonPersistent.php +%%DATADIR%%/library/Zend/Auth/Storage/Session.php +%%DATADIR%%/library/Zend/Cache.php +%%DATADIR%%/library/Zend/Cache/Backend.php +%%DATADIR%%/library/Zend/Cache/Backend/Apc.php +%%DATADIR%%/library/Zend/Cache/Backend/ExtendedInterface.php +%%DATADIR%%/library/Zend/Cache/Backend/File.php +%%DATADIR%%/library/Zend/Cache/Backend/Interface.php +%%DATADIR%%/library/Zend/Cache/Backend/Memcached.php +%%DATADIR%%/library/Zend/Cache/Backend/Sqlite.php +%%DATADIR%%/library/Zend/Cache/Backend/Test.php +%%DATADIR%%/library/Zend/Cache/Backend/TwoLevels.php +%%DATADIR%%/library/Zend/Cache/Backend/Xcache.php +%%DATADIR%%/library/Zend/Cache/Backend/ZendPlatform.php +%%DATADIR%%/library/Zend/Cache/Core.php +%%DATADIR%%/library/Zend/Cache/Exception.php +%%DATADIR%%/library/Zend/Cache/Frontend/Class.php +%%DATADIR%%/library/Zend/Cache/Frontend/File.php +%%DATADIR%%/library/Zend/Cache/Frontend/Function.php +%%DATADIR%%/library/Zend/Cache/Frontend/Output.php +%%DATADIR%%/library/Zend/Cache/Frontend/Page.php +%%DATADIR%%/library/Zend/Captcha/Adapter.php +%%DATADIR%%/library/Zend/Captcha/Base.php +%%DATADIR%%/library/Zend/Captcha/Dumb.php +%%DATADIR%%/library/Zend/Captcha/Exception.php +%%DATADIR%%/library/Zend/Captcha/Figlet.php +%%DATADIR%%/library/Zend/Captcha/Image.php +%%DATADIR%%/library/Zend/Captcha/ReCaptcha.php +%%DATADIR%%/library/Zend/Captcha/Word.php +%%DATADIR%%/library/Zend/Config.php +%%DATADIR%%/library/Zend/Config/Exception.php +%%DATADIR%%/library/Zend/Config/Ini.php +%%DATADIR%%/library/Zend/Config/Writer.php +%%DATADIR%%/library/Zend/Config/Writer/Array.php +%%DATADIR%%/library/Zend/Config/Writer/Ini.php +%%DATADIR%%/library/Zend/Config/Writer/Xml.php +%%DATADIR%%/library/Zend/Config/Xml.php +%%DATADIR%%/library/Zend/Console/Getopt.php +%%DATADIR%%/library/Zend/Console/Getopt/Exception.php +%%DATADIR%%/library/Zend/Controller/Action.php +%%DATADIR%%/library/Zend/Controller/Action/Exception.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Abstract.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/ActionStack.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AjaxContext.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AutoComplete/Abstract.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AutoCompleteDojo.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AutoCompleteScriptaculous.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/ContextSwitch.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/FlashMessenger.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Json.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Redirector.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Url.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/ViewRenderer.php +%%DATADIR%%/library/Zend/Controller/Action/HelperBroker.php +%%DATADIR%%/library/Zend/Controller/Action/HelperBroker/PriorityStack.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Abstract.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Exception.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Interface.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Standard.php +%%DATADIR%%/library/Zend/Controller/Exception.php +%%DATADIR%%/library/Zend/Controller/Front.php +%%DATADIR%%/library/Zend/Controller/Plugin/Abstract.php +%%DATADIR%%/library/Zend/Controller/Plugin/ActionStack.php +%%DATADIR%%/library/Zend/Controller/Plugin/Broker.php +%%DATADIR%%/library/Zend/Controller/Plugin/ErrorHandler.php +%%DATADIR%%/library/Zend/Controller/Request/Abstract.php +%%DATADIR%%/library/Zend/Controller/Request/Apache404.php +%%DATADIR%%/library/Zend/Controller/Request/Exception.php +%%DATADIR%%/library/Zend/Controller/Request/Http.php +%%DATADIR%%/library/Zend/Controller/Request/HttpTestCase.php +%%DATADIR%%/library/Zend/Controller/Request/Simple.php +%%DATADIR%%/library/Zend/Controller/Response/Abstract.php +%%DATADIR%%/library/Zend/Controller/Response/Cli.php +%%DATADIR%%/library/Zend/Controller/Response/Exception.php +%%DATADIR%%/library/Zend/Controller/Response/Http.php +%%DATADIR%%/library/Zend/Controller/Response/HttpTestCase.php +%%DATADIR%%/library/Zend/Controller/Router/Abstract.php +%%DATADIR%%/library/Zend/Controller/Router/Exception.php +%%DATADIR%%/library/Zend/Controller/Router/Interface.php +%%DATADIR%%/library/Zend/Controller/Router/Rewrite.php +%%DATADIR%%/library/Zend/Controller/Router/Route.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Abstract.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Chain.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Hostname.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Interface.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Module.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Regex.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Static.php +%%DATADIR%%/library/Zend/Currency.php +%%DATADIR%%/library/Zend/Currency/Exception.php +%%DATADIR%%/library/Zend/Date.php +%%DATADIR%%/library/Zend/Date/Cities.php +%%DATADIR%%/library/Zend/Date/DateObject.php +%%DATADIR%%/library/Zend/Date/Exception.php +%%DATADIR%%/library/Zend/Db.php +%%DATADIR%%/library/Zend/Db/Adapter/Abstract.php +%%DATADIR%%/library/Zend/Db/Adapter/Db2.php +%%DATADIR%%/library/Zend/Db/Adapter/Db2/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Mysqli.php +%%DATADIR%%/library/Zend/Db/Adapter/Mysqli/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Oracle.php +%%DATADIR%%/library/Zend/Db/Adapter/Oracle/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Abstract.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm/Db2.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm/Ids.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Mssql.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Mysql.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Oci.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Pgsql.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Sqlite.php +%%DATADIR%%/library/Zend/Db/Exception.php +%%DATADIR%%/library/Zend/Db/Expr.php +%%DATADIR%%/library/Zend/Db/Profiler.php +%%DATADIR%%/library/Zend/Db/Profiler/Exception.php +%%DATADIR%%/library/Zend/Db/Profiler/Firebug.php +%%DATADIR%%/library/Zend/Db/Profiler/Query.php +%%DATADIR%%/library/Zend/Db/Select.php +%%DATADIR%%/library/Zend/Db/Select/Exception.php +%%DATADIR%%/library/Zend/Db/Statement.php +%%DATADIR%%/library/Zend/Db/Statement/Db2.php +%%DATADIR%%/library/Zend/Db/Statement/Db2/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Interface.php +%%DATADIR%%/library/Zend/Db/Statement/Mysqli.php +%%DATADIR%%/library/Zend/Db/Statement/Mysqli/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Oracle.php +%%DATADIR%%/library/Zend/Db/Statement/Oracle/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Pdo.php +%%DATADIR%%/library/Zend/Db/Statement/Pdo/Ibm.php +%%DATADIR%%/library/Zend/Db/Table.php +%%DATADIR%%/library/Zend/Db/Table/Abstract.php +%%DATADIR%%/library/Zend/Db/Table/Exception.php +%%DATADIR%%/library/Zend/Db/Table/Row.php +%%DATADIR%%/library/Zend/Db/Table/Row/Abstract.php +%%DATADIR%%/library/Zend/Db/Table/Row/Exception.php +%%DATADIR%%/library/Zend/Db/Table/Rowset.php +%%DATADIR%%/library/Zend/Db/Table/Rowset/Abstract.php +%%DATADIR%%/library/Zend/Db/Table/Rowset/Exception.php +%%DATADIR%%/library/Zend/Db/Table/Select.php +%%DATADIR%%/library/Zend/Db/Table/Select/Exception.php +%%DATADIR%%/library/Zend/Debug.php +%%DATADIR%%/library/Zend/Dojo.php +%%DATADIR%%/library/Zend/Dojo/Data.php +%%DATADIR%%/library/Zend/Dojo/Exception.php +%%DATADIR%%/library/Zend/Dojo/Form.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/AccordionContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/AccordionPane.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/BorderContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/ContentPane.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/DijitContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/DijitElement.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/DijitForm.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/SplitContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/StackContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/TabContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/DisplayGroup.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Button.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/CheckBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/ComboBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/CurrencyTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/DateTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Dijit.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/DijitMulti.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Editor.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/FilteringSelect.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/HorizontalSlider.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/NumberSpinner.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/NumberTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/PasswordTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/RadioButton.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Slider.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/SubmitButton.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/TextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Textarea.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/TimeTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/ValidationTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/VerticalSlider.php +%%DATADIR%%/library/Zend/Dojo/Form/SubForm.php +%%DATADIR%%/library/Zend/Dojo/View/Exception.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/AccordionContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/AccordionPane.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/BorderContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Button.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/CheckBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/ComboBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/ContentPane.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/CurrencyTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/DateTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Dijit.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/DijitContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Dojo.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Dojo/Container.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Editor.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/FilteringSelect.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Form.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/HorizontalSlider.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/NumberSpinner.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/NumberTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/PasswordTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/RadioButton.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/SimpleTextarea.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Slider.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/SplitContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/StackContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/SubmitButton.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/TabContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/TextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Textarea.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/TimeTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/ValidationTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/VerticalSlider.php +%%DATADIR%%/library/Zend/Dom/Exception.php +%%DATADIR%%/library/Zend/Dom/Query.php +%%DATADIR%%/library/Zend/Dom/Query/Css2Xpath.php +%%DATADIR%%/library/Zend/Dom/Query/Result.php +%%DATADIR%%/library/Zend/Exception.php +%%DATADIR%%/library/Zend/Feed.php +%%DATADIR%%/library/Zend/Feed/Abstract.php +%%DATADIR%%/library/Zend/Feed/Atom.php +%%DATADIR%%/library/Zend/Feed/Builder.php +%%DATADIR%%/library/Zend/Feed/Builder/Entry.php +%%DATADIR%%/library/Zend/Feed/Builder/Exception.php +%%DATADIR%%/library/Zend/Feed/Builder/Header.php +%%DATADIR%%/library/Zend/Feed/Builder/Header/Itunes.php +%%DATADIR%%/library/Zend/Feed/Builder/Interface.php +%%DATADIR%%/library/Zend/Feed/Element.php +%%DATADIR%%/library/Zend/Feed/Entry/Abstract.php +%%DATADIR%%/library/Zend/Feed/Entry/Atom.php +%%DATADIR%%/library/Zend/Feed/Entry/Rss.php +%%DATADIR%%/library/Zend/Feed/Exception.php +%%DATADIR%%/library/Zend/Feed/Rss.php +%%DATADIR%%/library/Zend/File/Transfer.php +%%DATADIR%%/library/Zend/File/Transfer/Adapter/Abstract.php +%%DATADIR%%/library/Zend/File/Transfer/Adapter/Http.php +%%DATADIR%%/library/Zend/File/Transfer/Exception.php +%%DATADIR%%/library/Zend/Filter.php +%%DATADIR%%/library/Zend/Filter/Alnum.php +%%DATADIR%%/library/Zend/Filter/Alpha.php +%%DATADIR%%/library/Zend/Filter/BaseName.php +%%DATADIR%%/library/Zend/Filter/Digits.php +%%DATADIR%%/library/Zend/Filter/Dir.php +%%DATADIR%%/library/Zend/Filter/Exception.php +%%DATADIR%%/library/Zend/Filter/File/LowerCase.php +%%DATADIR%%/library/Zend/Filter/File/Rename.php +%%DATADIR%%/library/Zend/Filter/File/UpperCase.php +%%DATADIR%%/library/Zend/Filter/HtmlEntities.php +%%DATADIR%%/library/Zend/Filter/Inflector.php +%%DATADIR%%/library/Zend/Filter/Input.php +%%DATADIR%%/library/Zend/Filter/Int.php +%%DATADIR%%/library/Zend/Filter/Interface.php +%%DATADIR%%/library/Zend/Filter/PregReplace.php +%%DATADIR%%/library/Zend/Filter/RealPath.php +%%DATADIR%%/library/Zend/Filter/StringToLower.php +%%DATADIR%%/library/Zend/Filter/StringToUpper.php +%%DATADIR%%/library/Zend/Filter/StringTrim.php +%%DATADIR%%/library/Zend/Filter/StripNewlines.php +%%DATADIR%%/library/Zend/Filter/StripTags.php +%%DATADIR%%/library/Zend/Filter/Word/CamelCaseToDash.php +%%DATADIR%%/library/Zend/Filter/Word/CamelCaseToSeparator.php +%%DATADIR%%/library/Zend/Filter/Word/CamelCaseToUnderscore.php +%%DATADIR%%/library/Zend/Filter/Word/DashToCamelCase.php +%%DATADIR%%/library/Zend/Filter/Word/DashToSeparator.php +%%DATADIR%%/library/Zend/Filter/Word/DashToUnderscore.php +%%DATADIR%%/library/Zend/Filter/Word/Separator/Abstract.php +%%DATADIR%%/library/Zend/Filter/Word/SeparatorToCamelCase.php +%%DATADIR%%/library/Zend/Filter/Word/SeparatorToDash.php +%%DATADIR%%/library/Zend/Filter/Word/SeparatorToSeparator.php +%%DATADIR%%/library/Zend/Filter/Word/UnderscoreToCamelCase.php +%%DATADIR%%/library/Zend/Filter/Word/UnderscoreToDash.php +%%DATADIR%%/library/Zend/Filter/Word/UnderscoreToSeparator.php +%%DATADIR%%/library/Zend/Form.php +%%DATADIR%%/library/Zend/Form/Decorator/Abstract.php +%%DATADIR%%/library/Zend/Form/Decorator/Callback.php +%%DATADIR%%/library/Zend/Form/Decorator/Captcha.php +%%DATADIR%%/library/Zend/Form/Decorator/Captcha/Word.php +%%DATADIR%%/library/Zend/Form/Decorator/Description.php +%%DATADIR%%/library/Zend/Form/Decorator/DtDdWrapper.php +%%DATADIR%%/library/Zend/Form/Decorator/Errors.php +%%DATADIR%%/library/Zend/Form/Decorator/Exception.php +%%DATADIR%%/library/Zend/Form/Decorator/Fieldset.php +%%DATADIR%%/library/Zend/Form/Decorator/File.php +%%DATADIR%%/library/Zend/Form/Decorator/Form.php +%%DATADIR%%/library/Zend/Form/Decorator/FormElements.php +%%DATADIR%%/library/Zend/Form/Decorator/FormErrors.php +%%DATADIR%%/library/Zend/Form/Decorator/HtmlTag.php +%%DATADIR%%/library/Zend/Form/Decorator/Image.php +%%DATADIR%%/library/Zend/Form/Decorator/Interface.php +%%DATADIR%%/library/Zend/Form/Decorator/Label.php +%%DATADIR%%/library/Zend/Form/Decorator/PrepareElements.php +%%DATADIR%%/library/Zend/Form/Decorator/ViewHelper.php +%%DATADIR%%/library/Zend/Form/Decorator/ViewScript.php +%%DATADIR%%/library/Zend/Form/DisplayGroup.php +%%DATADIR%%/library/Zend/Form/Element.php +%%DATADIR%%/library/Zend/Form/Element/Button.php +%%DATADIR%%/library/Zend/Form/Element/Captcha.php +%%DATADIR%%/library/Zend/Form/Element/Checkbox.php +%%DATADIR%%/library/Zend/Form/Element/Exception.php +%%DATADIR%%/library/Zend/Form/Element/File.php +%%DATADIR%%/library/Zend/Form/Element/Hash.php +%%DATADIR%%/library/Zend/Form/Element/Hidden.php +%%DATADIR%%/library/Zend/Form/Element/Image.php +%%DATADIR%%/library/Zend/Form/Element/Multi.php +%%DATADIR%%/library/Zend/Form/Element/MultiCheckbox.php +%%DATADIR%%/library/Zend/Form/Element/Multiselect.php +%%DATADIR%%/library/Zend/Form/Element/Password.php +%%DATADIR%%/library/Zend/Form/Element/Radio.php +%%DATADIR%%/library/Zend/Form/Element/Reset.php +%%DATADIR%%/library/Zend/Form/Element/Select.php +%%DATADIR%%/library/Zend/Form/Element/Submit.php +%%DATADIR%%/library/Zend/Form/Element/Text.php +%%DATADIR%%/library/Zend/Form/Element/Textarea.php +%%DATADIR%%/library/Zend/Form/Element/Xhtml.php +%%DATADIR%%/library/Zend/Form/Exception.php +%%DATADIR%%/library/Zend/Form/SubForm.php +%%DATADIR%%/library/Zend/Gdata.php +%%DATADIR%%/library/Zend/Gdata/App.php +%%DATADIR%%/library/Zend/Gdata/App/AuthException.php +%%DATADIR%%/library/Zend/Gdata/App/BadMethodCallException.php +%%DATADIR%%/library/Zend/Gdata/App/Base.php +%%DATADIR%%/library/Zend/Gdata/App/BaseMediaSource.php +%%DATADIR%%/library/Zend/Gdata/App/CaptchaRequiredException.php +%%DATADIR%%/library/Zend/Gdata/App/Entry.php +%%DATADIR%%/library/Zend/Gdata/App/Exception.php +%%DATADIR%%/library/Zend/Gdata/App/Extension.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Author.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Category.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Content.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Contributor.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Control.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Draft.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Element.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Email.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Generator.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Icon.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Id.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Link.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Logo.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Name.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Person.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Published.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Rights.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Source.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Subtitle.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Summary.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Text.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Title.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Updated.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Uri.php +%%DATADIR%%/library/Zend/Gdata/App/Feed.php +%%DATADIR%%/library/Zend/Gdata/App/FeedEntryParent.php +%%DATADIR%%/library/Zend/Gdata/App/FeedSourceParent.php +%%DATADIR%%/library/Zend/Gdata/App/HttpException.php +%%DATADIR%%/library/Zend/Gdata/App/IOException.php +%%DATADIR%%/library/Zend/Gdata/App/InvalidArgumentException.php +%%DATADIR%%/library/Zend/Gdata/App/LoggingHttpClientAdapterSocket.php +%%DATADIR%%/library/Zend/Gdata/App/MediaEntry.php +%%DATADIR%%/library/Zend/Gdata/App/MediaFileSource.php +%%DATADIR%%/library/Zend/Gdata/App/MediaSource.php +%%DATADIR%%/library/Zend/Gdata/App/Util.php +%%DATADIR%%/library/Zend/Gdata/App/VersionException.php +%%DATADIR%%/library/Zend/Gdata/AuthSub.php +%%DATADIR%%/library/Zend/Gdata/Books.php +%%DATADIR%%/library/Zend/Gdata/Books/CollectionEntry.php +%%DATADIR%%/library/Zend/Gdata/Books/CollectionFeed.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/AnnotationLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/BooksCategory.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/BooksLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/Embeddability.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/InfoLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/PreviewLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/Review.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/ThumbnailLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/Viewability.php +%%DATADIR%%/library/Zend/Gdata/Books/VolumeEntry.php +%%DATADIR%%/library/Zend/Gdata/Books/VolumeFeed.php +%%DATADIR%%/library/Zend/Gdata/Books/VolumeQuery.php +%%DATADIR%%/library/Zend/Gdata/Calendar.php +%%DATADIR%%/library/Zend/Gdata/Calendar/EventEntry.php +%%DATADIR%%/library/Zend/Gdata/Calendar/EventFeed.php +%%DATADIR%%/library/Zend/Gdata/Calendar/EventQuery.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/AccessLevel.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Color.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Hidden.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Link.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/QuickAdd.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Selected.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/SendEventNotifications.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Timezone.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/WebContent.php +%%DATADIR%%/library/Zend/Gdata/Calendar/ListEntry.php +%%DATADIR%%/library/Zend/Gdata/Calendar/ListFeed.php +%%DATADIR%%/library/Zend/Gdata/ClientLogin.php +%%DATADIR%%/library/Zend/Gdata/Docs.php +%%DATADIR%%/library/Zend/Gdata/Docs/DocumentListEntry.php +%%DATADIR%%/library/Zend/Gdata/Docs/DocumentListFeed.php +%%DATADIR%%/library/Zend/Gdata/Docs/Query.php +%%DATADIR%%/library/Zend/Gdata/DublinCore.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Creator.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Date.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Description.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Format.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Identifier.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Language.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Publisher.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Rights.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Subject.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Title.php +%%DATADIR%%/library/Zend/Gdata/Entry.php +%%DATADIR%%/library/Zend/Gdata/Exif.php +%%DATADIR%%/library/Zend/Gdata/Exif/Entry.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Distance.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Exposure.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/FStop.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Flash.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/FocalLength.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/ImageUniqueId.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Iso.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Make.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Model.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Tags.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Time.php +%%DATADIR%%/library/Zend/Gdata/Exif/Feed.php +%%DATADIR%%/library/Zend/Gdata/Extension.php +%%DATADIR%%/library/Zend/Gdata/Extension/AttendeeStatus.php +%%DATADIR%%/library/Zend/Gdata/Extension/AttendeeType.php +%%DATADIR%%/library/Zend/Gdata/Extension/Comments.php +%%DATADIR%%/library/Zend/Gdata/Extension/EntryLink.php +%%DATADIR%%/library/Zend/Gdata/Extension/EventStatus.php +%%DATADIR%%/library/Zend/Gdata/Extension/ExtendedProperty.php +%%DATADIR%%/library/Zend/Gdata/Extension/FeedLink.php +%%DATADIR%%/library/Zend/Gdata/Extension/OpenSearchItemsPerPage.php +%%DATADIR%%/library/Zend/Gdata/Extension/OpenSearchStartIndex.php +%%DATADIR%%/library/Zend/Gdata/Extension/OpenSearchTotalResults.php +%%DATADIR%%/library/Zend/Gdata/Extension/OriginalEvent.php +%%DATADIR%%/library/Zend/Gdata/Extension/Rating.php +%%DATADIR%%/library/Zend/Gdata/Extension/Recurrence.php +%%DATADIR%%/library/Zend/Gdata/Extension/RecurrenceException.php +%%DATADIR%%/library/Zend/Gdata/Extension/Reminder.php +%%DATADIR%%/library/Zend/Gdata/Extension/Transparency.php +%%DATADIR%%/library/Zend/Gdata/Extension/Visibility.php +%%DATADIR%%/library/Zend/Gdata/Extension/When.php +%%DATADIR%%/library/Zend/Gdata/Extension/Where.php +%%DATADIR%%/library/Zend/Gdata/Extension/Who.php +%%DATADIR%%/library/Zend/Gdata/Feed.php +%%DATADIR%%/library/Zend/Gdata/Gapps.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListQuery.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListRecipientEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListRecipientFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListRecipientQuery.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Error.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/EmailList.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Login.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Name.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Nickname.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Quota.php +%%DATADIR%%/library/Zend/Gdata/Gapps/NicknameEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/NicknameFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/NicknameQuery.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Query.php +%%DATADIR%%/library/Zend/Gdata/Gapps/ServiceException.php +%%DATADIR%%/library/Zend/Gdata/Gapps/UserEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/UserFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/UserQuery.php +%%DATADIR%%/library/Zend/Gdata/Gbase.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Entry.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Extension/BaseAttribute.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Feed.php +%%DATADIR%%/library/Zend/Gdata/Gbase/ItemEntry.php +%%DATADIR%%/library/Zend/Gdata/Gbase/ItemFeed.php +%%DATADIR%%/library/Zend/Gdata/Gbase/ItemQuery.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Query.php +%%DATADIR%%/library/Zend/Gdata/Gbase/SnippetEntry.php +%%DATADIR%%/library/Zend/Gdata/Gbase/SnippetFeed.php +%%DATADIR%%/library/Zend/Gdata/Gbase/SnippetQuery.php +%%DATADIR%%/library/Zend/Gdata/Geo.php +%%DATADIR%%/library/Zend/Gdata/Geo/Entry.php +%%DATADIR%%/library/Zend/Gdata/Geo/Extension/GeoRssWhere.php +%%DATADIR%%/library/Zend/Gdata/Geo/Extension/GmlPoint.php +%%DATADIR%%/library/Zend/Gdata/Geo/Extension/GmlPos.php +%%DATADIR%%/library/Zend/Gdata/Geo/Feed.php +%%DATADIR%%/library/Zend/Gdata/Health.php +%%DATADIR%%/library/Zend/Gdata/Health/Extension/Ccr.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileEntry.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileFeed.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileListEntry.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileListFeed.php +%%DATADIR%%/library/Zend/Gdata/Health/Query.php +%%DATADIR%%/library/Zend/Gdata/HttpClient.php +%%DATADIR%%/library/Zend/Gdata/Kind/EventEntry.php +%%DATADIR%%/library/Zend/Gdata/Media.php +%%DATADIR%%/library/Zend/Gdata/Media/Entry.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaCategory.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaContent.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaCopyright.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaCredit.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaDescription.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaGroup.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaHash.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaKeywords.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaPlayer.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaRating.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaRestriction.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaText.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaThumbnail.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaTitle.php +%%DATADIR%%/library/Zend/Gdata/Media/Feed.php +%%DATADIR%%/library/Zend/Gdata/Photos.php +%%DATADIR%%/library/Zend/Gdata/Photos/AlbumEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/AlbumFeed.php +%%DATADIR%%/library/Zend/Gdata/Photos/AlbumQuery.php +%%DATADIR%%/library/Zend/Gdata/Photos/CommentEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Access.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/AlbumId.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/BytesUsed.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Checksum.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Client.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/CommentCount.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/CommentingEnabled.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Height.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Id.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Location.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/MaxPhotosPerAlbum.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Name.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Nickname.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/NumPhotos.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/NumPhotosRemaining.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/PhotoId.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Position.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/QuotaCurrent.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/QuotaLimit.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Rotation.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Size.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Thumbnail.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Timestamp.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/User.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Version.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Weight.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Width.php +%%DATADIR%%/library/Zend/Gdata/Photos/PhotoEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/PhotoFeed.php +%%DATADIR%%/library/Zend/Gdata/Photos/PhotoQuery.php +%%DATADIR%%/library/Zend/Gdata/Photos/TagEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/UserEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/UserFeed.php +%%DATADIR%%/library/Zend/Gdata/Photos/UserQuery.php +%%DATADIR%%/library/Zend/Gdata/Query.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/CellEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/CellFeed.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/CellQuery.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/DocumentQuery.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/Cell.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/ColCount.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/Custom.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/RowCount.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/ListEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/ListFeed.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/ListQuery.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/SpreadsheetEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/SpreadsheetFeed.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/WorksheetEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/WorksheetFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube.php +%%DATADIR%%/library/Zend/Gdata/YouTube/CommentEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/CommentFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/ContactEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/ContactFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/AboutMe.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Age.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Books.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Company.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Control.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/CountHint.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Description.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Duration.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/FirstName.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Gender.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Hobbies.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Hometown.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/LastName.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Link.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Location.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaContent.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaCredit.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaGroup.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaRating.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Movies.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Music.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/NoEmbed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Occupation.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/PlaylistId.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/PlaylistTitle.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Position.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Private.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/QueryString.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Racy.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Recorded.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Relationship.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/ReleaseDate.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/School.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/State.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Statistics.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Status.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Token.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Uploaded.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Username.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/VideoId.php +%%DATADIR%%/library/Zend/Gdata/YouTube/MediaEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistListEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistListFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistVideoEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistVideoFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/SubscriptionEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/SubscriptionFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/UserProfileEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/VideoEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/VideoFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/VideoQuery.php +%%DATADIR%%/library/Zend/Http/Client.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Exception.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Interface.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Proxy.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Socket.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Test.php +%%DATADIR%%/library/Zend/Http/Client/Exception.php +%%DATADIR%%/library/Zend/Http/Cookie.php +%%DATADIR%%/library/Zend/Http/CookieJar.php +%%DATADIR%%/library/Zend/Http/Exception.php +%%DATADIR%%/library/Zend/Http/Response.php +%%DATADIR%%/library/Zend/InfoCard.php +%%DATADIR%%/library/Zend/InfoCard/Adapter/Default.php +%%DATADIR%%/library/Zend/InfoCard/Adapter/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Adapter/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Adapter/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Adapter/Rsa.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Rsa/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter/Aes128cbc.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter/Aes256cbc.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes128cbc/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes256cbc/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Claims.php +%%DATADIR%%/library/Zend/InfoCard/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Assertion.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Assertion/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Assertion/Saml.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Element.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Element/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData/XmlEnc.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedKey.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/Default.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/XmlDSig.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/EnvelopedSignature.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/XmlExcC14N.php +%%DATADIR%%/library/Zend/InfoCard/Xml/SecurityTokenReference.php +%%DATADIR%%/library/Zend/Json.php +%%DATADIR%%/library/Zend/Json/Decoder.php +%%DATADIR%%/library/Zend/Json/Encoder.php +%%DATADIR%%/library/Zend/Json/Exception.php +%%DATADIR%%/library/Zend/Json/Server.php +%%DATADIR%%/library/Zend/Json/Server/Cache.php +%%DATADIR%%/library/Zend/Json/Server/Error.php +%%DATADIR%%/library/Zend/Json/Server/Exception.php +%%DATADIR%%/library/Zend/Json/Server/Request.php +%%DATADIR%%/library/Zend/Json/Server/Request/Http.php +%%DATADIR%%/library/Zend/Json/Server/Response.php +%%DATADIR%%/library/Zend/Json/Server/Response/Http.php +%%DATADIR%%/library/Zend/Json/Server/Smd.php +%%DATADIR%%/library/Zend/Json/Server/Smd/Service.php +%%DATADIR%%/library/Zend/Layout.php +%%DATADIR%%/library/Zend/Layout/Controller/Action/Helper/Layout.php +%%DATADIR%%/library/Zend/Layout/Controller/Plugin/Layout.php +%%DATADIR%%/library/Zend/Layout/Exception.php +%%DATADIR%%/library/Zend/Ldap.php +%%DATADIR%%/library/Zend/Ldap/Exception.php +%%DATADIR%%/library/Zend/Loader.php +%%DATADIR%%/library/Zend/Loader/Exception.php +%%DATADIR%%/library/Zend/Loader/PluginLoader.php +%%DATADIR%%/library/Zend/Loader/PluginLoader/Exception.php +%%DATADIR%%/library/Zend/Loader/PluginLoader/Interface.php +%%DATADIR%%/library/Zend/Locale.php +%%DATADIR%%/library/Zend/Locale/Data.php +%%DATADIR%%/library/Zend/Locale/Data/Translation.php +%%DATADIR%%/library/Zend/Locale/Data/aa.xml +%%DATADIR%%/library/Zend/Locale/Data/aa_DJ.xml +%%DATADIR%%/library/Zend/Locale/Data/aa_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/aa_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/af.xml +%%DATADIR%%/library/Zend/Locale/Data/af_NA.xml +%%DATADIR%%/library/Zend/Locale/Data/af_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/ak.xml +%%DATADIR%%/library/Zend/Locale/Data/ak_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/am.xml +%%DATADIR%%/library/Zend/Locale/Data/am_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/ar.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_AE.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_BH.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_DZ.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_EG.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_IQ.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_JO.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_KW.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_LB.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_LY.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_MA.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_OM.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_QA.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_SA.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_SD.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_SY.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_TN.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_YE.xml +%%DATADIR%%/library/Zend/Locale/Data/as.xml +%%DATADIR%%/library/Zend/Locale/Data/as_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/az.xml +%%DATADIR%%/library/Zend/Locale/Data/az_AZ.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Cyrl_AZ.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Latn_AZ.xml +%%DATADIR%%/library/Zend/Locale/Data/be.xml +%%DATADIR%%/library/Zend/Locale/Data/be_BY.xml +%%DATADIR%%/library/Zend/Locale/Data/bg.xml +%%DATADIR%%/library/Zend/Locale/Data/bg_BG.xml +%%DATADIR%%/library/Zend/Locale/Data/bn.xml +%%DATADIR%%/library/Zend/Locale/Data/bn_BD.xml +%%DATADIR%%/library/Zend/Locale/Data/bn_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/bs.xml +%%DATADIR%%/library/Zend/Locale/Data/bs_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/byn.xml +%%DATADIR%%/library/Zend/Locale/Data/byn_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/ca.xml +%%DATADIR%%/library/Zend/Locale/Data/ca_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/cch.xml +%%DATADIR%%/library/Zend/Locale/Data/cch_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/characters.xml +%%DATADIR%%/library/Zend/Locale/Data/cop.xml +%%DATADIR%%/library/Zend/Locale/Data/cs.xml +%%DATADIR%%/library/Zend/Locale/Data/cs_CZ.xml +%%DATADIR%%/library/Zend/Locale/Data/cy.xml +%%DATADIR%%/library/Zend/Locale/Data/cy_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/da.xml +%%DATADIR%%/library/Zend/Locale/Data/da_DK.xml +%%DATADIR%%/library/Zend/Locale/Data/de.xml +%%DATADIR%%/library/Zend/Locale/Data/de_AT.xml +%%DATADIR%%/library/Zend/Locale/Data/de_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/de_CH.xml +%%DATADIR%%/library/Zend/Locale/Data/de_DE.xml +%%DATADIR%%/library/Zend/Locale/Data/de_LI.xml +%%DATADIR%%/library/Zend/Locale/Data/de_LU.xml +%%DATADIR%%/library/Zend/Locale/Data/dv.xml +%%DATADIR%%/library/Zend/Locale/Data/dv_MV.xml +%%DATADIR%%/library/Zend/Locale/Data/dz.xml +%%DATADIR%%/library/Zend/Locale/Data/dz_BT.xml +%%DATADIR%%/library/Zend/Locale/Data/ee.xml +%%DATADIR%%/library/Zend/Locale/Data/ee_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/ee_TG.xml +%%DATADIR%%/library/Zend/Locale/Data/el.xml +%%DATADIR%%/library/Zend/Locale/Data/el_CY.xml +%%DATADIR%%/library/Zend/Locale/Data/el_GR.xml +%%DATADIR%%/library/Zend/Locale/Data/el_POLYTON.xml +%%DATADIR%%/library/Zend/Locale/Data/en.xml +%%DATADIR%%/library/Zend/Locale/Data/en_AS.xml +%%DATADIR%%/library/Zend/Locale/Data/en_AU.xml +%%DATADIR%%/library/Zend/Locale/Data/en_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/en_BW.xml +%%DATADIR%%/library/Zend/Locale/Data/en_BZ.xml +%%DATADIR%%/library/Zend/Locale/Data/en_CA.xml +%%DATADIR%%/library/Zend/Locale/Data/en_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/en_GU.xml +%%DATADIR%%/library/Zend/Locale/Data/en_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/en_IE.xml +%%DATADIR%%/library/Zend/Locale/Data/en_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/en_JM.xml +%%DATADIR%%/library/Zend/Locale/Data/en_MH.xml +%%DATADIR%%/library/Zend/Locale/Data/en_MP.xml +%%DATADIR%%/library/Zend/Locale/Data/en_MT.xml +%%DATADIR%%/library/Zend/Locale/Data/en_NA.xml +%%DATADIR%%/library/Zend/Locale/Data/en_NZ.xml +%%DATADIR%%/library/Zend/Locale/Data/en_PH.xml +%%DATADIR%%/library/Zend/Locale/Data/en_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/en_SG.xml +%%DATADIR%%/library/Zend/Locale/Data/en_Shaw.xml +%%DATADIR%%/library/Zend/Locale/Data/en_TT.xml +%%DATADIR%%/library/Zend/Locale/Data/en_UM.xml +%%DATADIR%%/library/Zend/Locale/Data/en_US.xml +%%DATADIR%%/library/Zend/Locale/Data/en_US_POSIX.xml +%%DATADIR%%/library/Zend/Locale/Data/en_VI.xml +%%DATADIR%%/library/Zend/Locale/Data/en_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/en_ZW.xml +%%DATADIR%%/library/Zend/Locale/Data/eo.xml +%%DATADIR%%/library/Zend/Locale/Data/es.xml +%%DATADIR%%/library/Zend/Locale/Data/es_AR.xml +%%DATADIR%%/library/Zend/Locale/Data/es_BO.xml +%%DATADIR%%/library/Zend/Locale/Data/es_CL.xml +%%DATADIR%%/library/Zend/Locale/Data/es_CO.xml +%%DATADIR%%/library/Zend/Locale/Data/es_CR.xml +%%DATADIR%%/library/Zend/Locale/Data/es_DO.xml +%%DATADIR%%/library/Zend/Locale/Data/es_EC.xml +%%DATADIR%%/library/Zend/Locale/Data/es_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/es_GT.xml +%%DATADIR%%/library/Zend/Locale/Data/es_HN.xml +%%DATADIR%%/library/Zend/Locale/Data/es_MX.xml +%%DATADIR%%/library/Zend/Locale/Data/es_NI.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PA.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PE.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PR.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PY.xml +%%DATADIR%%/library/Zend/Locale/Data/es_SV.xml +%%DATADIR%%/library/Zend/Locale/Data/es_US.xml +%%DATADIR%%/library/Zend/Locale/Data/es_UY.xml +%%DATADIR%%/library/Zend/Locale/Data/es_VE.xml +%%DATADIR%%/library/Zend/Locale/Data/et.xml +%%DATADIR%%/library/Zend/Locale/Data/et_EE.xml +%%DATADIR%%/library/Zend/Locale/Data/eu.xml +%%DATADIR%%/library/Zend/Locale/Data/eu_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/fa.xml +%%DATADIR%%/library/Zend/Locale/Data/fa_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/fa_IR.xml +%%DATADIR%%/library/Zend/Locale/Data/fi.xml +%%DATADIR%%/library/Zend/Locale/Data/fi_FI.xml +%%DATADIR%%/library/Zend/Locale/Data/fil.xml +%%DATADIR%%/library/Zend/Locale/Data/fil_PH.xml +%%DATADIR%%/library/Zend/Locale/Data/fo.xml +%%DATADIR%%/library/Zend/Locale/Data/fo_FO.xml +%%DATADIR%%/library/Zend/Locale/Data/fr.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_CA.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_CH.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_FR.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_LU.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_MC.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_SN.xml +%%DATADIR%%/library/Zend/Locale/Data/fur.xml +%%DATADIR%%/library/Zend/Locale/Data/fur_IT.xml +%%DATADIR%%/library/Zend/Locale/Data/ga.xml +%%DATADIR%%/library/Zend/Locale/Data/ga_IE.xml +%%DATADIR%%/library/Zend/Locale/Data/gaa.xml +%%DATADIR%%/library/Zend/Locale/Data/gaa_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/gez.xml +%%DATADIR%%/library/Zend/Locale/Data/gez_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/gez_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/gl.xml +%%DATADIR%%/library/Zend/Locale/Data/gl_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/gu.xml +%%DATADIR%%/library/Zend/Locale/Data/gu_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/gv.xml +%%DATADIR%%/library/Zend/Locale/Data/gv_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/ha.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Arab_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Arab_SD.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn_NE.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_NE.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_SD.xml +%%DATADIR%%/library/Zend/Locale/Data/haw.xml +%%DATADIR%%/library/Zend/Locale/Data/haw_US.xml +%%DATADIR%%/library/Zend/Locale/Data/he.xml +%%DATADIR%%/library/Zend/Locale/Data/he_IL.xml +%%DATADIR%%/library/Zend/Locale/Data/hi.xml +%%DATADIR%%/library/Zend/Locale/Data/hi_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/hr.xml +%%DATADIR%%/library/Zend/Locale/Data/hr_HR.xml +%%DATADIR%%/library/Zend/Locale/Data/hu.xml +%%DATADIR%%/library/Zend/Locale/Data/hu_HU.xml +%%DATADIR%%/library/Zend/Locale/Data/hy.xml +%%DATADIR%%/library/Zend/Locale/Data/hy_AM.xml +%%DATADIR%%/library/Zend/Locale/Data/hy_AM_REVISED.xml +%%DATADIR%%/library/Zend/Locale/Data/ia.xml +%%DATADIR%%/library/Zend/Locale/Data/id.xml +%%DATADIR%%/library/Zend/Locale/Data/id_ID.xml +%%DATADIR%%/library/Zend/Locale/Data/ig.xml +%%DATADIR%%/library/Zend/Locale/Data/ig_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ii.xml +%%DATADIR%%/library/Zend/Locale/Data/ii_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/in.xml +%%DATADIR%%/library/Zend/Locale/Data/is.xml +%%DATADIR%%/library/Zend/Locale/Data/is_IS.xml +%%DATADIR%%/library/Zend/Locale/Data/it.xml +%%DATADIR%%/library/Zend/Locale/Data/it_CH.xml +%%DATADIR%%/library/Zend/Locale/Data/it_IT.xml +%%DATADIR%%/library/Zend/Locale/Data/iu.xml +%%DATADIR%%/library/Zend/Locale/Data/iw.xml +%%DATADIR%%/library/Zend/Locale/Data/ja.xml +%%DATADIR%%/library/Zend/Locale/Data/ja_JP.xml +%%DATADIR%%/library/Zend/Locale/Data/ka.xml +%%DATADIR%%/library/Zend/Locale/Data/ka_GE.xml +%%DATADIR%%/library/Zend/Locale/Data/kaj.xml +%%DATADIR%%/library/Zend/Locale/Data/kaj_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/kam.xml +%%DATADIR%%/library/Zend/Locale/Data/kam_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/kcg.xml +%%DATADIR%%/library/Zend/Locale/Data/kcg_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/kfo.xml +%%DATADIR%%/library/Zend/Locale/Data/kfo_CI.xml +%%DATADIR%%/library/Zend/Locale/Data/kk.xml +%%DATADIR%%/library/Zend/Locale/Data/kk_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/kk_Cyrl_KZ.xml +%%DATADIR%%/library/Zend/Locale/Data/kk_KZ.xml +%%DATADIR%%/library/Zend/Locale/Data/kl.xml +%%DATADIR%%/library/Zend/Locale/Data/kl_GL.xml +%%DATADIR%%/library/Zend/Locale/Data/km.xml +%%DATADIR%%/library/Zend/Locale/Data/km_KH.xml +%%DATADIR%%/library/Zend/Locale/Data/kn.xml +%%DATADIR%%/library/Zend/Locale/Data/kn_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ko.xml +%%DATADIR%%/library/Zend/Locale/Data/ko_KR.xml +%%DATADIR%%/library/Zend/Locale/Data/kok.xml +%%DATADIR%%/library/Zend/Locale/Data/kok_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/kpe.xml +%%DATADIR%%/library/Zend/Locale/Data/kpe_GN.xml +%%DATADIR%%/library/Zend/Locale/Data/kpe_LR.xml +%%DATADIR%%/library/Zend/Locale/Data/ku.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_Latn_TR.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_TR.xml +%%DATADIR%%/library/Zend/Locale/Data/kw.xml +%%DATADIR%%/library/Zend/Locale/Data/kw_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/ky.xml +%%DATADIR%%/library/Zend/Locale/Data/ky_KG.xml +%%DATADIR%%/library/Zend/Locale/Data/ln.xml +%%DATADIR%%/library/Zend/Locale/Data/ln_CD.xml +%%DATADIR%%/library/Zend/Locale/Data/ln_CG.xml +%%DATADIR%%/library/Zend/Locale/Data/lo.xml +%%DATADIR%%/library/Zend/Locale/Data/lo_LA.xml +%%DATADIR%%/library/Zend/Locale/Data/lt.xml +%%DATADIR%%/library/Zend/Locale/Data/lt_LT.xml +%%DATADIR%%/library/Zend/Locale/Data/lv.xml +%%DATADIR%%/library/Zend/Locale/Data/lv_LV.xml +%%DATADIR%%/library/Zend/Locale/Data/mk.xml +%%DATADIR%%/library/Zend/Locale/Data/mk_MK.xml +%%DATADIR%%/library/Zend/Locale/Data/ml.xml +%%DATADIR%%/library/Zend/Locale/Data/ml_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Cyrl_MN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_MN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Mong.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Mong_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/mo.xml +%%DATADIR%%/library/Zend/Locale/Data/mr.xml +%%DATADIR%%/library/Zend/Locale/Data/mr_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ms.xml +%%DATADIR%%/library/Zend/Locale/Data/ms_BN.xml +%%DATADIR%%/library/Zend/Locale/Data/ms_MY.xml +%%DATADIR%%/library/Zend/Locale/Data/mt.xml +%%DATADIR%%/library/Zend/Locale/Data/mt_MT.xml +%%DATADIR%%/library/Zend/Locale/Data/my.xml +%%DATADIR%%/library/Zend/Locale/Data/my_MM.xml +%%DATADIR%%/library/Zend/Locale/Data/nb.xml +%%DATADIR%%/library/Zend/Locale/Data/nb_NO.xml +%%DATADIR%%/library/Zend/Locale/Data/ne.xml +%%DATADIR%%/library/Zend/Locale/Data/ne_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ne_NP.xml +%%DATADIR%%/library/Zend/Locale/Data/nl.xml +%%DATADIR%%/library/Zend/Locale/Data/nl_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/nl_NL.xml +%%DATADIR%%/library/Zend/Locale/Data/nn.xml +%%DATADIR%%/library/Zend/Locale/Data/nn_NO.xml +%%DATADIR%%/library/Zend/Locale/Data/no.xml +%%DATADIR%%/library/Zend/Locale/Data/nr.xml +%%DATADIR%%/library/Zend/Locale/Data/nr_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/nso.xml +%%DATADIR%%/library/Zend/Locale/Data/nso_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/ny.xml +%%DATADIR%%/library/Zend/Locale/Data/ny_MW.xml +%%DATADIR%%/library/Zend/Locale/Data/om.xml +%%DATADIR%%/library/Zend/Locale/Data/om_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/om_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/or.xml +%%DATADIR%%/library/Zend/Locale/Data/or_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/pa.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Arab_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Guru.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Guru_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/pl.xml +%%DATADIR%%/library/Zend/Locale/Data/pl_PL.xml +%%DATADIR%%/library/Zend/Locale/Data/plurals.xml +%%DATADIR%%/library/Zend/Locale/Data/ps.xml +%%DATADIR%%/library/Zend/Locale/Data/ps_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/pt.xml +%%DATADIR%%/library/Zend/Locale/Data/pt_BR.xml +%%DATADIR%%/library/Zend/Locale/Data/pt_PT.xml +%%DATADIR%%/library/Zend/Locale/Data/ro.xml +%%DATADIR%%/library/Zend/Locale/Data/ro_MD.xml +%%DATADIR%%/library/Zend/Locale/Data/ro_RO.xml +%%DATADIR%%/library/Zend/Locale/Data/root.xml +%%DATADIR%%/library/Zend/Locale/Data/ru.xml +%%DATADIR%%/library/Zend/Locale/Data/ru_RU.xml +%%DATADIR%%/library/Zend/Locale/Data/ru_UA.xml +%%DATADIR%%/library/Zend/Locale/Data/rw.xml +%%DATADIR%%/library/Zend/Locale/Data/rw_RW.xml +%%DATADIR%%/library/Zend/Locale/Data/sa.xml +%%DATADIR%%/library/Zend/Locale/Data/sa_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/se.xml +%%DATADIR%%/library/Zend/Locale/Data/se_FI.xml +%%DATADIR%%/library/Zend/Locale/Data/se_NO.xml +%%DATADIR%%/library/Zend/Locale/Data/sh.xml +%%DATADIR%%/library/Zend/Locale/Data/sh_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sh_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sh_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/si.xml +%%DATADIR%%/library/Zend/Locale/Data/si_LK.xml +%%DATADIR%%/library/Zend/Locale/Data/sid.xml +%%DATADIR%%/library/Zend/Locale/Data/sid_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/sk.xml +%%DATADIR%%/library/Zend/Locale/Data/sk_SK.xml +%%DATADIR%%/library/Zend/Locale/Data/sl.xml +%%DATADIR%%/library/Zend/Locale/Data/sl_SI.xml +%%DATADIR%%/library/Zend/Locale/Data/so.xml +%%DATADIR%%/library/Zend/Locale/Data/so_DJ.xml +%%DATADIR%%/library/Zend/Locale/Data/so_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/so_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/so_SO.xml +%%DATADIR%%/library/Zend/Locale/Data/sq.xml +%%DATADIR%%/library/Zend/Locale/Data/sq_AL.xml +%%DATADIR%%/library/Zend/Locale/Data/sr.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_ME.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_RS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_ME.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_RS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_ME.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_RS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/ss.xml +%%DATADIR%%/library/Zend/Locale/Data/ss_SZ.xml +%%DATADIR%%/library/Zend/Locale/Data/ss_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/st.xml +%%DATADIR%%/library/Zend/Locale/Data/st_LS.xml +%%DATADIR%%/library/Zend/Locale/Data/st_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/supplementalData.xml +%%DATADIR%%/library/Zend/Locale/Data/sv.xml +%%DATADIR%%/library/Zend/Locale/Data/sv_FI.xml +%%DATADIR%%/library/Zend/Locale/Data/sv_SE.xml +%%DATADIR%%/library/Zend/Locale/Data/sw.xml +%%DATADIR%%/library/Zend/Locale/Data/sw_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/sw_TZ.xml +%%DATADIR%%/library/Zend/Locale/Data/syr.xml +%%DATADIR%%/library/Zend/Locale/Data/syr_SY.xml +%%DATADIR%%/library/Zend/Locale/Data/ta.xml +%%DATADIR%%/library/Zend/Locale/Data/ta_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/te.xml +%%DATADIR%%/library/Zend/Locale/Data/te_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/telephoneCodeData.xml +%%DATADIR%%/library/Zend/Locale/Data/tg.xml +%%DATADIR%%/library/Zend/Locale/Data/tg_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/tg_Cyrl_TJ.xml +%%DATADIR%%/library/Zend/Locale/Data/tg_TJ.xml +%%DATADIR%%/library/Zend/Locale/Data/th.xml +%%DATADIR%%/library/Zend/Locale/Data/th_TH.xml +%%DATADIR%%/library/Zend/Locale/Data/ti.xml +%%DATADIR%%/library/Zend/Locale/Data/ti_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/ti_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/tig.xml +%%DATADIR%%/library/Zend/Locale/Data/tig_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/tl.xml +%%DATADIR%%/library/Zend/Locale/Data/tn.xml +%%DATADIR%%/library/Zend/Locale/Data/tn_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/to.xml +%%DATADIR%%/library/Zend/Locale/Data/to_TO.xml +%%DATADIR%%/library/Zend/Locale/Data/tr.xml +%%DATADIR%%/library/Zend/Locale/Data/tr_TR.xml +%%DATADIR%%/library/Zend/Locale/Data/ts.xml +%%DATADIR%%/library/Zend/Locale/Data/ts_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/tt.xml +%%DATADIR%%/library/Zend/Locale/Data/tt_RU.xml +%%DATADIR%%/library/Zend/Locale/Data/ug.xml +%%DATADIR%%/library/Zend/Locale/Data/ug_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/ug_Arab_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/ug_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/uk.xml +%%DATADIR%%/library/Zend/Locale/Data/uk_UA.xml +%%DATADIR%%/library/Zend/Locale/Data/ur.xml +%%DATADIR%%/library/Zend/Locale/Data/ur_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ur_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/uz.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Arab_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Cyrl_UZ.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Latn_UZ.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_UZ.xml +%%DATADIR%%/library/Zend/Locale/Data/ve.xml +%%DATADIR%%/library/Zend/Locale/Data/ve_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/vi.xml +%%DATADIR%%/library/Zend/Locale/Data/vi_VN.xml +%%DATADIR%%/library/Zend/Locale/Data/wal.xml +%%DATADIR%%/library/Zend/Locale/Data/wal_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/wo.xml +%%DATADIR%%/library/Zend/Locale/Data/wo_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/wo_Latn_SN.xml +%%DATADIR%%/library/Zend/Locale/Data/wo_SN.xml +%%DATADIR%%/library/Zend/Locale/Data/xh.xml +%%DATADIR%%/library/Zend/Locale/Data/xh_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/yo.xml +%%DATADIR%%/library/Zend/Locale/Data/yo_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/zh.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_MO.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_SG.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant_MO.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant_TW.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_MO.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_SG.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_TW.xml +%%DATADIR%%/library/Zend/Locale/Data/zu.xml +%%DATADIR%%/library/Zend/Locale/Data/zu_ZA.xml +%%DATADIR%%/library/Zend/Locale/Exception.php +%%DATADIR%%/library/Zend/Locale/Format.php +%%DATADIR%%/library/Zend/Locale/Math.php +%%DATADIR%%/library/Zend/Locale/Math/Exception.php +%%DATADIR%%/library/Zend/Locale/Math/PhpMath.php +%%DATADIR%%/library/Zend/Log.php +%%DATADIR%%/library/Zend/Log/Exception.php +%%DATADIR%%/library/Zend/Log/Filter/Interface.php +%%DATADIR%%/library/Zend/Log/Filter/Message.php +%%DATADIR%%/library/Zend/Log/Filter/Priority.php +%%DATADIR%%/library/Zend/Log/Filter/Suppress.php +%%DATADIR%%/library/Zend/Log/Formatter/Interface.php +%%DATADIR%%/library/Zend/Log/Formatter/Simple.php +%%DATADIR%%/library/Zend/Log/Formatter/Xml.php +%%DATADIR%%/library/Zend/Log/Writer/Abstract.php +%%DATADIR%%/library/Zend/Log/Writer/Db.php +%%DATADIR%%/library/Zend/Log/Writer/Firebug.php +%%DATADIR%%/library/Zend/Log/Writer/Mock.php +%%DATADIR%%/library/Zend/Log/Writer/Null.php +%%DATADIR%%/library/Zend/Log/Writer/Stream.php +%%DATADIR%%/library/Zend/Mail.php +%%DATADIR%%/library/Zend/Mail/Exception.php +%%DATADIR%%/library/Zend/Mail/Message.php +%%DATADIR%%/library/Zend/Mail/Message/File.php +%%DATADIR%%/library/Zend/Mail/Message/Interface.php +%%DATADIR%%/library/Zend/Mail/Part.php +%%DATADIR%%/library/Zend/Mail/Part/File.php +%%DATADIR%%/library/Zend/Mail/Part/Interface.php +%%DATADIR%%/library/Zend/Mail/Protocol/Abstract.php +%%DATADIR%%/library/Zend/Mail/Protocol/Exception.php +%%DATADIR%%/library/Zend/Mail/Protocol/Imap.php +%%DATADIR%%/library/Zend/Mail/Protocol/Pop3.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth/Crammd5.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth/Login.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth/Plain.php +%%DATADIR%%/library/Zend/Mail/Storage.php +%%DATADIR%%/library/Zend/Mail/Storage/Abstract.php +%%DATADIR%%/library/Zend/Mail/Storage/Exception.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder/Interface.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder/Maildir.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder/Mbox.php +%%DATADIR%%/library/Zend/Mail/Storage/Imap.php +%%DATADIR%%/library/Zend/Mail/Storage/Maildir.php +%%DATADIR%%/library/Zend/Mail/Storage/Mbox.php +%%DATADIR%%/library/Zend/Mail/Storage/Pop3.php +%%DATADIR%%/library/Zend/Mail/Storage/Writable/Interface.php +%%DATADIR%%/library/Zend/Mail/Storage/Writable/Maildir.php +%%DATADIR%%/library/Zend/Mail/Transport/Abstract.php +%%DATADIR%%/library/Zend/Mail/Transport/Exception.php +%%DATADIR%%/library/Zend/Mail/Transport/Sendmail.php +%%DATADIR%%/library/Zend/Mail/Transport/Smtp.php +%%DATADIR%%/library/Zend/Measure/Abstract.php +%%DATADIR%%/library/Zend/Measure/Acceleration.php +%%DATADIR%%/library/Zend/Measure/Angle.php +%%DATADIR%%/library/Zend/Measure/Area.php +%%DATADIR%%/library/Zend/Measure/Binary.php +%%DATADIR%%/library/Zend/Measure/Capacitance.php +%%DATADIR%%/library/Zend/Measure/Cooking/Volume.php +%%DATADIR%%/library/Zend/Measure/Cooking/Weight.php +%%DATADIR%%/library/Zend/Measure/Current.php +%%DATADIR%%/library/Zend/Measure/Density.php +%%DATADIR%%/library/Zend/Measure/Energy.php +%%DATADIR%%/library/Zend/Measure/Exception.php +%%DATADIR%%/library/Zend/Measure/Flow/Mass.php +%%DATADIR%%/library/Zend/Measure/Flow/Mole.php +%%DATADIR%%/library/Zend/Measure/Flow/Volume.php +%%DATADIR%%/library/Zend/Measure/Force.php +%%DATADIR%%/library/Zend/Measure/Frequency.php +%%DATADIR%%/library/Zend/Measure/Illumination.php +%%DATADIR%%/library/Zend/Measure/Length.php +%%DATADIR%%/library/Zend/Measure/Lightness.php +%%DATADIR%%/library/Zend/Measure/Number.php +%%DATADIR%%/library/Zend/Measure/Power.php +%%DATADIR%%/library/Zend/Measure/Pressure.php +%%DATADIR%%/library/Zend/Measure/Speed.php +%%DATADIR%%/library/Zend/Measure/Temperature.php +%%DATADIR%%/library/Zend/Measure/Time.php +%%DATADIR%%/library/Zend/Measure/Torque.php +%%DATADIR%%/library/Zend/Measure/Viscosity/Dynamic.php +%%DATADIR%%/library/Zend/Measure/Viscosity/Kinematic.php +%%DATADIR%%/library/Zend/Measure/Volume.php +%%DATADIR%%/library/Zend/Measure/Weight.php +%%DATADIR%%/library/Zend/Memory.php +%%DATADIR%%/library/Zend/Memory/AccessController.php +%%DATADIR%%/library/Zend/Memory/Container.php +%%DATADIR%%/library/Zend/Memory/Container/Interface.php +%%DATADIR%%/library/Zend/Memory/Container/Locked.php +%%DATADIR%%/library/Zend/Memory/Container/Movable.php +%%DATADIR%%/library/Zend/Memory/Exception.php +%%DATADIR%%/library/Zend/Memory/Manager.php +%%DATADIR%%/library/Zend/Memory/Value.php +%%DATADIR%%/library/Zend/Mime.php +%%DATADIR%%/library/Zend/Mime/Decode.php +%%DATADIR%%/library/Zend/Mime/Exception.php +%%DATADIR%%/library/Zend/Mime/Message.php +%%DATADIR%%/library/Zend/Mime/Part.php +%%DATADIR%%/library/Zend/OpenId.php +%%DATADIR%%/library/Zend/OpenId/Consumer.php +%%DATADIR%%/library/Zend/OpenId/Consumer/Storage.php +%%DATADIR%%/library/Zend/OpenId/Consumer/Storage/File.php +%%DATADIR%%/library/Zend/OpenId/Exception.php +%%DATADIR%%/library/Zend/OpenId/Extension.php +%%DATADIR%%/library/Zend/OpenId/Extension/Sreg.php +%%DATADIR%%/library/Zend/OpenId/Provider.php +%%DATADIR%%/library/Zend/OpenId/Provider/Storage.php +%%DATADIR%%/library/Zend/OpenId/Provider/Storage/File.php +%%DATADIR%%/library/Zend/OpenId/Provider/User.php +%%DATADIR%%/library/Zend/OpenId/Provider/User/Session.php +%%DATADIR%%/library/Zend/Paginator.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Array.php +%%DATADIR%%/library/Zend/Paginator/Adapter/DbSelect.php +%%DATADIR%%/library/Zend/Paginator/Adapter/DbTableSelect.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Interface.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Iterator.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Null.php +%%DATADIR%%/library/Zend/Paginator/Exception.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/All.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Elastic.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Interface.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Jumping.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Sliding.php +%%DATADIR%%/library/Zend/Pdf.php +%%DATADIR%%/library/Zend/Pdf/Cmap.php +%%DATADIR%%/library/Zend/Pdf/Cmap/ByteEncoding.php +%%DATADIR%%/library/Zend/Pdf/Cmap/ByteEncoding/Static.php +%%DATADIR%%/library/Zend/Pdf/Cmap/SegmentToDelta.php +%%DATADIR%%/library/Zend/Pdf/Cmap/TrimmedTable.php +%%DATADIR%%/library/Zend/Pdf/Color.php +%%DATADIR%%/library/Zend/Pdf/Color/Cmyk.php +%%DATADIR%%/library/Zend/Pdf/Color/GrayScale.php +%%DATADIR%%/library/Zend/Pdf/Color/Html.php +%%DATADIR%%/library/Zend/Pdf/Color/Rgb.php +%%DATADIR%%/library/Zend/Pdf/Element.php +%%DATADIR%%/library/Zend/Pdf/Element/Array.php +%%DATADIR%%/library/Zend/Pdf/Element/Boolean.php +%%DATADIR%%/library/Zend/Pdf/Element/Dictionary.php +%%DATADIR%%/library/Zend/Pdf/Element/Name.php +%%DATADIR%%/library/Zend/Pdf/Element/Null.php +%%DATADIR%%/library/Zend/Pdf/Element/Numeric.php +%%DATADIR%%/library/Zend/Pdf/Element/Object.php +%%DATADIR%%/library/Zend/Pdf/Element/Object/Stream.php +%%DATADIR%%/library/Zend/Pdf/Element/Reference.php +%%DATADIR%%/library/Zend/Pdf/Element/Reference/Context.php +%%DATADIR%%/library/Zend/Pdf/Element/Reference/Table.php +%%DATADIR%%/library/Zend/Pdf/Element/Stream.php +%%DATADIR%%/library/Zend/Pdf/Element/String.php +%%DATADIR%%/library/Zend/Pdf/Element/String/Binary.php +%%DATADIR%%/library/Zend/Pdf/ElementFactory.php +%%DATADIR%%/library/Zend/Pdf/ElementFactory/Interface.php +%%DATADIR%%/library/Zend/Pdf/ElementFactory/Proxy.php +%%DATADIR%%/library/Zend/Pdf/Exception.php +%%DATADIR%%/library/Zend/Pdf/FileParser.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Font.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Font/OpenType.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Font/OpenType/TrueType.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Image.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Image/Png.php +%%DATADIR%%/library/Zend/Pdf/FileParserDataSource.php +%%DATADIR%%/library/Zend/Pdf/FileParserDataSource/File.php +%%DATADIR%%/library/Zend/Pdf/FileParserDataSource/String.php +%%DATADIR%%/library/Zend/Pdf/Filter/Ascii85.php +%%DATADIR%%/library/Zend/Pdf/Filter/AsciiHex.php +%%DATADIR%%/library/Zend/Pdf/Filter/Compression.php +%%DATADIR%%/library/Zend/Pdf/Filter/Compression/Flate.php +%%DATADIR%%/library/Zend/Pdf/Filter/Compression/Lzw.php +%%DATADIR%%/library/Zend/Pdf/Filter/Interface.php +%%DATADIR%%/library/Zend/Pdf/Font.php +%%DATADIR%%/library/Zend/Pdf/Image.php +%%DATADIR%%/library/Zend/Pdf/Page.php +%%DATADIR%%/library/Zend/Pdf/Parser.php +%%DATADIR%%/library/Zend/Pdf/Parser/Stream.php +%%DATADIR%%/library/Zend/Pdf/PhpArray.php +%%DATADIR%%/library/Zend/Pdf/Resource.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/CidFont.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/CidFont/TrueType.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Extracted.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/FontDescriptor.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Parsed.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Parsed/TrueType.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/Courier.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/CourierBold.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/CourierBoldOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/CourierOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/Helvetica.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/HelveticaBold.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/HelveticaBoldOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/HelveticaOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/Symbol.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesBold.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesBoldItalic.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesItalic.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesRoman.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/ZapfDingbats.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Type0.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image/Jpeg.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image/Png.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image/Tiff.php +%%DATADIR%%/library/Zend/Pdf/Resource/ImageFactory.php +%%DATADIR%%/library/Zend/Pdf/StringParser.php +%%DATADIR%%/library/Zend/Pdf/Style.php +%%DATADIR%%/library/Zend/Pdf/Trailer.php +%%DATADIR%%/library/Zend/Pdf/Trailer/Generator.php +%%DATADIR%%/library/Zend/Pdf/Trailer/Keeper.php +%%DATADIR%%/library/Zend/Pdf/UpdateInfoContainer.php +%%DATADIR%%/library/Zend/ProgressBar.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/Console.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/Exception.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/JsPull.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/JsPush.php +%%DATADIR%%/library/Zend/ProgressBar/Exception.php +%%DATADIR%%/library/Zend/Registry.php +%%DATADIR%%/library/Zend/Request/Interface.php +%%DATADIR%%/library/Zend/Rest/Client.php +%%DATADIR%%/library/Zend/Rest/Client/Exception.php +%%DATADIR%%/library/Zend/Rest/Client/Result.php +%%DATADIR%%/library/Zend/Rest/Client/Result/Exception.php +%%DATADIR%%/library/Zend/Rest/Exception.php +%%DATADIR%%/library/Zend/Rest/Server.php +%%DATADIR%%/library/Zend/Rest/Server/Exception.php +%%DATADIR%%/library/Zend/Search/Exception.php +%%DATADIR%%/library/Zend/Search/Lucene.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Text.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Text/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/TextNum.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/TextNum/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8Num.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8Num/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Token.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/LowerCase.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/LowerCaseUtf8.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/ShortWords.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/StopWords.php +%%DATADIR%%/library/Zend/Search/Lucene/Document.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Docx.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Html.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/OpenXml.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Pptx.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Xlsx.php +%%DATADIR%%/library/Zend/Search/Lucene/Exception.php +%%DATADIR%%/library/Zend/Search/Lucene/FSM.php +%%DATADIR%%/library/Zend/Search/Lucene/FSMAction.php +%%DATADIR%%/library/Zend/Search/Lucene/Field.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/DictionaryLoader.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/DocsFilter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/FieldInfo.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentInfo.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentInfoPriorityQueue.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentMerger.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter/DocumentWriter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter/StreamWriter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/TermInfo.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/Writer.php +%%DATADIR%%/library/Zend/Search/Lucene/Interface.php +%%DATADIR%%/library/Zend/Search/Lucene/LockManager.php +%%DATADIR%%/library/Zend/Search/Lucene/PriorityQueue.php +%%DATADIR%%/library/Zend/Search/Lucene/Proxy.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/BooleanExpressionRecognizer.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Boolean.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Empty.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Fuzzy.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Insignificant.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/MultiTerm.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Phrase.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Range.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Wildcard.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry/Phrase.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry/Subquery.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryHit.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryLexer.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryParser.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryParserContext.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryParserException.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryToken.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Similarity.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Similarity/Default.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Boolean.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Empty.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/MultiTerm.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Phrase.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/Directory.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/Directory/Filesystem.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/File.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/File/Filesystem.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/File/Memory.php +%%DATADIR%%/library/Zend/Server/Abstract.php +%%DATADIR%%/library/Zend/Server/Cache.php +%%DATADIR%%/library/Zend/Server/Definition.php +%%DATADIR%%/library/Zend/Server/Exception.php +%%DATADIR%%/library/Zend/Server/Interface.php +%%DATADIR%%/library/Zend/Server/Method/Callback.php +%%DATADIR%%/library/Zend/Server/Method/Definition.php +%%DATADIR%%/library/Zend/Server/Method/Parameter.php +%%DATADIR%%/library/Zend/Server/Method/Prototype.php +%%DATADIR%%/library/Zend/Server/Reflection.php +%%DATADIR%%/library/Zend/Server/Reflection/Class.php +%%DATADIR%%/library/Zend/Server/Reflection/Exception.php +%%DATADIR%%/library/Zend/Server/Reflection/Function.php +%%DATADIR%%/library/Zend/Server/Reflection/Function/Abstract.php +%%DATADIR%%/library/Zend/Server/Reflection/Method.php +%%DATADIR%%/library/Zend/Server/Reflection/Node.php +%%DATADIR%%/library/Zend/Server/Reflection/Parameter.php +%%DATADIR%%/library/Zend/Server/Reflection/Prototype.php +%%DATADIR%%/library/Zend/Server/Reflection/ReturnValue.php +%%DATADIR%%/library/Zend/Service/Abstract.php +%%DATADIR%%/library/Zend/Service/Akismet.php +%%DATADIR%%/library/Zend/Service/Amazon.php +%%DATADIR%%/library/Zend/Service/Amazon/Accessories.php +%%DATADIR%%/library/Zend/Service/Amazon/CustomerReview.php +%%DATADIR%%/library/Zend/Service/Amazon/EditorialReview.php +%%DATADIR%%/library/Zend/Service/Amazon/Image.php +%%DATADIR%%/library/Zend/Service/Amazon/Item.php +%%DATADIR%%/library/Zend/Service/Amazon/ListmaniaList.php +%%DATADIR%%/library/Zend/Service/Amazon/Offer.php +%%DATADIR%%/library/Zend/Service/Amazon/OfferSet.php +%%DATADIR%%/library/Zend/Service/Amazon/Query.php +%%DATADIR%%/library/Zend/Service/Amazon/ResultSet.php +%%DATADIR%%/library/Zend/Service/Amazon/SimilarProduct.php +%%DATADIR%%/library/Zend/Service/Audioscrobbler.php +%%DATADIR%%/library/Zend/Service/Delicious.php +%%DATADIR%%/library/Zend/Service/Delicious/Exception.php +%%DATADIR%%/library/Zend/Service/Delicious/Post.php +%%DATADIR%%/library/Zend/Service/Delicious/PostList.php +%%DATADIR%%/library/Zend/Service/Delicious/SimplePost.php +%%DATADIR%%/library/Zend/Service/Exception.php +%%DATADIR%%/library/Zend/Service/Flickr.php +%%DATADIR%%/library/Zend/Service/Flickr/Image.php +%%DATADIR%%/library/Zend/Service/Flickr/Result.php +%%DATADIR%%/library/Zend/Service/Flickr/ResultSet.php +%%DATADIR%%/library/Zend/Service/Nirvanix.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Exception.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Namespace/Base.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Namespace/Imfs.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Response.php +%%DATADIR%%/library/Zend/Service/ReCaptcha.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/Exception.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/MailHide.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/MailHide/Exception.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/Response.php +%%DATADIR%%/library/Zend/Service/Simpy.php +%%DATADIR%%/library/Zend/Service/Simpy/Link.php +%%DATADIR%%/library/Zend/Service/Simpy/LinkQuery.php +%%DATADIR%%/library/Zend/Service/Simpy/LinkSet.php +%%DATADIR%%/library/Zend/Service/Simpy/Note.php +%%DATADIR%%/library/Zend/Service/Simpy/NoteSet.php +%%DATADIR%%/library/Zend/Service/Simpy/Tag.php +%%DATADIR%%/library/Zend/Service/Simpy/TagSet.php +%%DATADIR%%/library/Zend/Service/Simpy/Watchlist.php +%%DATADIR%%/library/Zend/Service/Simpy/WatchlistFilter.php +%%DATADIR%%/library/Zend/Service/Simpy/WatchlistFilterSet.php +%%DATADIR%%/library/Zend/Service/Simpy/WatchlistSet.php +%%DATADIR%%/library/Zend/Service/SlideShare.php +%%DATADIR%%/library/Zend/Service/SlideShare/Exception.php +%%DATADIR%%/library/Zend/Service/SlideShare/SlideShow.php +%%DATADIR%%/library/Zend/Service/StrikeIron.php +%%DATADIR%%/library/Zend/Service/StrikeIron/Base.php +%%DATADIR%%/library/Zend/Service/StrikeIron/Decorator.php +%%DATADIR%%/library/Zend/Service/StrikeIron/Exception.php +%%DATADIR%%/library/Zend/Service/StrikeIron/SalesUseTaxBasic.php +%%DATADIR%%/library/Zend/Service/StrikeIron/USAddressVerification.php +%%DATADIR%%/library/Zend/Service/StrikeIron/ZipCodeInfo.php +%%DATADIR%%/library/Zend/Service/Technorati.php +%%DATADIR%%/library/Zend/Service/Technorati/Author.php +%%DATADIR%%/library/Zend/Service/Technorati/BlogInfoResult.php +%%DATADIR%%/library/Zend/Service/Technorati/CosmosResult.php +%%DATADIR%%/library/Zend/Service/Technorati/CosmosResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/DailyCountsResult.php +%%DATADIR%%/library/Zend/Service/Technorati/DailyCountsResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/Exception.php +%%DATADIR%%/library/Zend/Service/Technorati/GetInfoResult.php +%%DATADIR%%/library/Zend/Service/Technorati/KeyInfoResult.php +%%DATADIR%%/library/Zend/Service/Technorati/Result.php +%%DATADIR%%/library/Zend/Service/Technorati/ResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/SearchResult.php +%%DATADIR%%/library/Zend/Service/Technorati/SearchResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/TagResult.php +%%DATADIR%%/library/Zend/Service/Technorati/TagResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/TagsResult.php +%%DATADIR%%/library/Zend/Service/Technorati/TagsResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/Utils.php +%%DATADIR%%/library/Zend/Service/Technorati/Weblog.php +%%DATADIR%%/library/Zend/Service/Twitter.php +%%DATADIR%%/library/Zend/Service/Twitter/Exception.php +%%DATADIR%%/library/Zend/Service/Twitter/Search.php +%%DATADIR%%/library/Zend/Service/Yahoo.php +%%DATADIR%%/library/Zend/Service/Yahoo/Image.php +%%DATADIR%%/library/Zend/Service/Yahoo/ImageResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/ImageResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/InlinkDataResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/InlinkDataResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/LocalResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/LocalResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/NewsResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/NewsResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/PageDataResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/PageDataResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/Result.php +%%DATADIR%%/library/Zend/Service/Yahoo/ResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/VideoResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/VideoResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/WebResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/WebResultSet.php +%%DATADIR%%/library/Zend/Session.php +%%DATADIR%%/library/Zend/Session/Abstract.php +%%DATADIR%%/library/Zend/Session/Exception.php +%%DATADIR%%/library/Zend/Session/Namespace.php +%%DATADIR%%/library/Zend/Session/SaveHandler/DbTable.php +%%DATADIR%%/library/Zend/Session/SaveHandler/Exception.php +%%DATADIR%%/library/Zend/Session/SaveHandler/Interface.php +%%DATADIR%%/library/Zend/Session/Validator/Abstract.php +%%DATADIR%%/library/Zend/Session/Validator/HttpUserAgent.php +%%DATADIR%%/library/Zend/Session/Validator/Interface.php +%%DATADIR%%/library/Zend/Soap/AutoDiscover.php +%%DATADIR%%/library/Zend/Soap/AutoDiscover/Exception.php +%%DATADIR%%/library/Zend/Soap/Client.php +%%DATADIR%%/library/Zend/Soap/Client/Common.php +%%DATADIR%%/library/Zend/Soap/Client/DotNet.php +%%DATADIR%%/library/Zend/Soap/Client/Exception.php +%%DATADIR%%/library/Zend/Soap/Client/Local.php +%%DATADIR%%/library/Zend/Soap/Server.php +%%DATADIR%%/library/Zend/Soap/Server/Exception.php +%%DATADIR%%/library/Zend/Soap/Wsdl.php +%%DATADIR%%/library/Zend/Soap/Wsdl/CodeGenerator.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Exception.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Parser.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Parser/Result.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/Abstract.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/AnyType.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/ArrayOfTypeComplex.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/ArrayOfTypeSequence.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/DefaultComplexType.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/Interface.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/DomQuery.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/Exception.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/Redirect.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/ResponseHeader.php +%%DATADIR%%/library/Zend/Test/PHPUnit/ControllerTestCase.php +%%DATADIR%%/library/Zend/Text/Exception.php +%%DATADIR%%/library/Zend/Text/Figlet.php +%%DATADIR%%/library/Zend/Text/Figlet/Exception.php +%%DATADIR%%/library/Zend/Text/Figlet/zend-framework.flf +%%DATADIR%%/library/Zend/Text/MultiByte.php +%%DATADIR%%/library/Zend/Text/Table.php +%%DATADIR%%/library/Zend/Text/Table/Column.php +%%DATADIR%%/library/Zend/Text/Table/Decorator/Ascii.php +%%DATADIR%%/library/Zend/Text/Table/Decorator/Interface.php +%%DATADIR%%/library/Zend/Text/Table/Decorator/Unicode.php +%%DATADIR%%/library/Zend/Text/Table/Exception.php +%%DATADIR%%/library/Zend/Text/Table/Row.php +%%DATADIR%%/library/Zend/TimeSync.php +%%DATADIR%%/library/Zend/TimeSync/Exception.php +%%DATADIR%%/library/Zend/TimeSync/Ntp.php +%%DATADIR%%/library/Zend/TimeSync/Protocol.php +%%DATADIR%%/library/Zend/TimeSync/Sntp.php +%%DATADIR%%/library/Zend/Translate.php +%%DATADIR%%/library/Zend/Translate/Adapter.php +%%DATADIR%%/library/Zend/Translate/Adapter/Array.php +%%DATADIR%%/library/Zend/Translate/Adapter/Csv.php +%%DATADIR%%/library/Zend/Translate/Adapter/Gettext.php +%%DATADIR%%/library/Zend/Translate/Adapter/Ini.php +%%DATADIR%%/library/Zend/Translate/Adapter/Qt.php +%%DATADIR%%/library/Zend/Translate/Adapter/Tbx.php +%%DATADIR%%/library/Zend/Translate/Adapter/Tmx.php +%%DATADIR%%/library/Zend/Translate/Adapter/Xliff.php +%%DATADIR%%/library/Zend/Translate/Adapter/XmlTm.php +%%DATADIR%%/library/Zend/Translate/Exception.php +%%DATADIR%%/library/Zend/Uri.php +%%DATADIR%%/library/Zend/Uri/Exception.php +%%DATADIR%%/library/Zend/Uri/Http.php +%%DATADIR%%/library/Zend/Validate.php +%%DATADIR%%/library/Zend/Validate/Abstract.php +%%DATADIR%%/library/Zend/Validate/Alnum.php +%%DATADIR%%/library/Zend/Validate/Alpha.php +%%DATADIR%%/library/Zend/Validate/Barcode.php +%%DATADIR%%/library/Zend/Validate/Barcode/Ean13.php +%%DATADIR%%/library/Zend/Validate/Barcode/UpcA.php +%%DATADIR%%/library/Zend/Validate/Between.php +%%DATADIR%%/library/Zend/Validate/Ccnum.php +%%DATADIR%%/library/Zend/Validate/Date.php +%%DATADIR%%/library/Zend/Validate/Digits.php +%%DATADIR%%/library/Zend/Validate/EmailAddress.php +%%DATADIR%%/library/Zend/Validate/Exception.php +%%DATADIR%%/library/Zend/Validate/File/Count.php +%%DATADIR%%/library/Zend/Validate/File/Crc32.php +%%DATADIR%%/library/Zend/Validate/File/ExcludeExtension.php +%%DATADIR%%/library/Zend/Validate/File/ExcludeMimeType.php +%%DATADIR%%/library/Zend/Validate/File/Exists.php +%%DATADIR%%/library/Zend/Validate/File/Extension.php +%%DATADIR%%/library/Zend/Validate/File/FilesSize.php +%%DATADIR%%/library/Zend/Validate/File/Hash.php +%%DATADIR%%/library/Zend/Validate/File/ImageSize.php +%%DATADIR%%/library/Zend/Validate/File/IsCompressed.php +%%DATADIR%%/library/Zend/Validate/File/IsImage.php +%%DATADIR%%/library/Zend/Validate/File/Md5.php +%%DATADIR%%/library/Zend/Validate/File/MimeType.php +%%DATADIR%%/library/Zend/Validate/File/NotExists.php +%%DATADIR%%/library/Zend/Validate/File/Sha1.php +%%DATADIR%%/library/Zend/Validate/File/Size.php +%%DATADIR%%/library/Zend/Validate/File/Upload.php +%%DATADIR%%/library/Zend/Validate/Float.php +%%DATADIR%%/library/Zend/Validate/GreaterThan.php +%%DATADIR%%/library/Zend/Validate/Hex.php +%%DATADIR%%/library/Zend/Validate/Hostname.php +%%DATADIR%%/library/Zend/Validate/Hostname/At.php +%%DATADIR%%/library/Zend/Validate/Hostname/Ch.php +%%DATADIR%%/library/Zend/Validate/Hostname/De.php +%%DATADIR%%/library/Zend/Validate/Hostname/Fi.php +%%DATADIR%%/library/Zend/Validate/Hostname/Hu.php +%%DATADIR%%/library/Zend/Validate/Hostname/Interface.php +%%DATADIR%%/library/Zend/Validate/Hostname/Li.php +%%DATADIR%%/library/Zend/Validate/Hostname/No.php +%%DATADIR%%/library/Zend/Validate/Hostname/Se.php +%%DATADIR%%/library/Zend/Validate/Identical.php +%%DATADIR%%/library/Zend/Validate/InArray.php +%%DATADIR%%/library/Zend/Validate/Int.php +%%DATADIR%%/library/Zend/Validate/Interface.php +%%DATADIR%%/library/Zend/Validate/Ip.php +%%DATADIR%%/library/Zend/Validate/LessThan.php +%%DATADIR%%/library/Zend/Validate/NotEmpty.php +%%DATADIR%%/library/Zend/Validate/Regex.php +%%DATADIR%%/library/Zend/Validate/StringLength.php +%%DATADIR%%/library/Zend/Version.php +%%DATADIR%%/library/Zend/View.php +%%DATADIR%%/library/Zend/View/Abstract.php +%%DATADIR%%/library/Zend/View/Exception.php +%%DATADIR%%/library/Zend/View/Helper/Abstract.php +%%DATADIR%%/library/Zend/View/Helper/Action.php +%%DATADIR%%/library/Zend/View/Helper/DeclareVars.php +%%DATADIR%%/library/Zend/View/Helper/Doctype.php +%%DATADIR%%/library/Zend/View/Helper/Fieldset.php +%%DATADIR%%/library/Zend/View/Helper/Form.php +%%DATADIR%%/library/Zend/View/Helper/FormButton.php +%%DATADIR%%/library/Zend/View/Helper/FormCheckbox.php +%%DATADIR%%/library/Zend/View/Helper/FormElement.php +%%DATADIR%%/library/Zend/View/Helper/FormErrors.php +%%DATADIR%%/library/Zend/View/Helper/FormFile.php +%%DATADIR%%/library/Zend/View/Helper/FormHidden.php +%%DATADIR%%/library/Zend/View/Helper/FormImage.php +%%DATADIR%%/library/Zend/View/Helper/FormLabel.php +%%DATADIR%%/library/Zend/View/Helper/FormMultiCheckbox.php +%%DATADIR%%/library/Zend/View/Helper/FormNote.php +%%DATADIR%%/library/Zend/View/Helper/FormPassword.php +%%DATADIR%%/library/Zend/View/Helper/FormRadio.php +%%DATADIR%%/library/Zend/View/Helper/FormReset.php +%%DATADIR%%/library/Zend/View/Helper/FormSelect.php +%%DATADIR%%/library/Zend/View/Helper/FormSubmit.php +%%DATADIR%%/library/Zend/View/Helper/FormText.php +%%DATADIR%%/library/Zend/View/Helper/FormTextarea.php +%%DATADIR%%/library/Zend/View/Helper/HeadLink.php +%%DATADIR%%/library/Zend/View/Helper/HeadMeta.php +%%DATADIR%%/library/Zend/View/Helper/HeadScript.php +%%DATADIR%%/library/Zend/View/Helper/HeadStyle.php +%%DATADIR%%/library/Zend/View/Helper/HeadTitle.php +%%DATADIR%%/library/Zend/View/Helper/HtmlElement.php +%%DATADIR%%/library/Zend/View/Helper/HtmlFlash.php +%%DATADIR%%/library/Zend/View/Helper/HtmlList.php +%%DATADIR%%/library/Zend/View/Helper/HtmlObject.php +%%DATADIR%%/library/Zend/View/Helper/HtmlPage.php +%%DATADIR%%/library/Zend/View/Helper/HtmlQuicktime.php +%%DATADIR%%/library/Zend/View/Helper/InlineScript.php +%%DATADIR%%/library/Zend/View/Helper/Interface.php +%%DATADIR%%/library/Zend/View/Helper/Json.php +%%DATADIR%%/library/Zend/View/Helper/Layout.php +%%DATADIR%%/library/Zend/View/Helper/PaginationControl.php +%%DATADIR%%/library/Zend/View/Helper/Partial.php +%%DATADIR%%/library/Zend/View/Helper/Partial/Exception.php +%%DATADIR%%/library/Zend/View/Helper/PartialLoop.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container/Abstract.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container/Exception.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container/Standalone.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Registry.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Registry/Exception.php +%%DATADIR%%/library/Zend/View/Helper/RenderToPlaceholder.php +%%DATADIR%%/library/Zend/View/Helper/Translate.php +%%DATADIR%%/library/Zend/View/Helper/Url.php +%%DATADIR%%/library/Zend/View/Interface.php +%%DATADIR%%/library/Zend/View/Stream.php +%%DATADIR%%/library/Zend/Wildfire/Channel/HttpHeaders.php +%%DATADIR%%/library/Zend/Wildfire/Channel/Interface.php +%%DATADIR%%/library/Zend/Wildfire/Exception.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp/Message.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp/TableMessage.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/Interface.php +%%DATADIR%%/library/Zend/Wildfire/Protocol/JsonStream.php +%%DATADIR%%/library/Zend/XmlRpc/Client.php +%%DATADIR%%/library/Zend/XmlRpc/Client/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Client/FaultException.php +%%DATADIR%%/library/Zend/XmlRpc/Client/HttpException.php +%%DATADIR%%/library/Zend/XmlRpc/Client/IntrospectException.php +%%DATADIR%%/library/Zend/XmlRpc/Client/ServerIntrospection.php +%%DATADIR%%/library/Zend/XmlRpc/Client/ServerProxy.php +%%DATADIR%%/library/Zend/XmlRpc/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Fault.php +%%DATADIR%%/library/Zend/XmlRpc/Request.php +%%DATADIR%%/library/Zend/XmlRpc/Request/Http.php +%%DATADIR%%/library/Zend/XmlRpc/Request/Stdin.php +%%DATADIR%%/library/Zend/XmlRpc/Response.php +%%DATADIR%%/library/Zend/XmlRpc/Response/Http.php +%%DATADIR%%/library/Zend/XmlRpc/Server.php +%%DATADIR%%/library/Zend/XmlRpc/Server/Cache.php +%%DATADIR%%/library/Zend/XmlRpc/Server/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Server/Fault.php +%%DATADIR%%/library/Zend/XmlRpc/Server/System.php +%%DATADIR%%/library/Zend/XmlRpc/Value.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Array.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Base64.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Boolean.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Collection.php +%%DATADIR%%/library/Zend/XmlRpc/Value/DateTime.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Double.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Integer.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Nil.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Scalar.php +%%DATADIR%%/library/Zend/XmlRpc/Value/String.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Struct.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Feeds/consume-feed.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Blogger.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser/books_browser.css +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser/interface.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Calendar.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Docs.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Gapps.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Gbase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Health.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/InstallationChecker.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/MyLibrary/demo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Photos.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Spreadsheet-ClientLogin.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/notfound.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/operations.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/session_details.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/video_app.css +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/video_app.js +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/interface.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/video_browser.css +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/video_browser.js +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Locale/AllLanguages.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/SimpleMailer.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/maildir/maildir.tar +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/mbox/INBOX +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/mbox/subfolder/test +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/login-bg.gif +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/controllers/ErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/error/404.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/error/500.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/index/login.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/index/welcome.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html/.htaccess +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html/config.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/identity.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/identity2.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/login.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/profile.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/register.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/registration_complete.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/trust.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/test_auth.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/test_consumer.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/test_server.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Pdf/demo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Pdf/stamp.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Pdf/test.pdf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/ProgressBar/JsPush.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/ProgressBar/Upload.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/ProgressBar/animation.gif +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/feed-search/create-index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/feed-search/search-index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/CreateIndex.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/about-pear.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/authors.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.bugs.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.documentation.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.newpackage.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.patches.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.wishlist.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/copyright.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/core.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Amazon/amazon-search.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Flickr/flickr-composite.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Flickr/flickr-search.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Protocols/xmlrpc-upc-lookup.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Yahoo/yahoo-multi-search.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Db-Profiler-Firebug/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Log-Writer-Firebug/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ZendDbProfilerFirebugController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ZendLogWriterFirebugController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ZendWildfirePluginFirePhpController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/error/error.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/index/index.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-db-profiler-firebug/test-logging.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-db-profiler-firebug/test-multiple-databases.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug/test-error-controller.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug/test-large-message.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug/test-logging.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-wildfire-plugin-firephp/test-groups.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/.htaccess +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Db-Profiler-Firebug/TestDocExample.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Log-Writer-Firebug/TestDocExample.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/TestConfiguration.php.dist +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/TestHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/AclTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Contact.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/bytearray.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/longstring.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/arrayAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/bogusTypedObjectAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolFalseAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolFalseAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolTrueAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolTrueAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/byteArrayAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/credentialsheaderAmf0.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/dateAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/dateAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/intAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/largeIntAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/mixedArrayAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/nullAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/numberAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/numberAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/objectAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/referenceAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/stringAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/stringAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/typedObjectAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/undefAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/undefinedAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/xmlAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/xmlAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/RequestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/arrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/arrayAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolFalseAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolFalseAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolTrueAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolTrueAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/classMapAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/dateAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/dateAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/intAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/largeIntAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/mixedArrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/nestedArrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/nullAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/numberAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/numberAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/objectAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/stringAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/stringAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/stringArrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/typedObjectAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/TypeLoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Util/BinaryStreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Value/MessageBodyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Value/MessageHeaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/BasicSqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/BasicSqliteTest/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Digest/_files/.htdigest.1 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DigestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/AuthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/ObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/ProxyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/Resolver/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/Resolver/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/_files/htbasic.1 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/_files/htdigest.3 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/OpenIdTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/ResponseHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/AuthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/ApcBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/ClassFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/CommonBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/CommonExtendedBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/CoreTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FactoryException.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FactoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FileBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FileFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FunctionFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/MemcachedBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/OutputFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/PageFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/SqliteBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/TwoLevelsBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/XcacheBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/ZendPlatformBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/DumbTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/FigletTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/ImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/ReCaptchaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/IniTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/IniTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/XmlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/files/allsections.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/files/allsections.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/XmlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/allsections.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/allsections.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/array.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/circular.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/circular.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/config.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/config.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/invalid.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/invalid.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/multipleinheritance.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/nosections.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/onetoplevelstring.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/separator.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/shortparamsone.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/shortparamstwo.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/toplevelstring.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/zf2843.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ConfigTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Console/GetoptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/ActionStackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/AjaxContextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/AutoCompleteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/ContextSwitchTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/FlashMessengerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/JsonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/RedirectorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/UrlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/ViewRendererTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/HelperBroker/PriorityStackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/HelperBrokerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/ActionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Dispatcher/StandardTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/FrontTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Plugin/ActionStackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Plugin/BrokerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Plugin/ErrorHandlerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/Apache404Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/HttpTestCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/SimpleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Response/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Response/HttpTestCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/RewriteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/ChainTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/HostnameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/ModuleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/RegexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/RouteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin/BazController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin/FooBarController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/BazController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/EmptyController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/FooBarController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/HelperBrokerController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/HelperFlashMessengerController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Helpers/TestHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Helpers/Url.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/ObController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/ViewController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/index/test.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/test.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/test/foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/controllers/Admin/HelperController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/helpers/SampleZfHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts/admin/helper/render.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers/Admin/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/helpers/FooUseHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts/admin/index/use-helper.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/routes-root.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/routes.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/custom/renderScript.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/foo-bar/baz-bat.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/ob.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/site.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/view/index.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/view/name.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/CurrencyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Date/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Date/DateObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/DateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/Db2Statement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/MysqliStatement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/OracleStatement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/PdoStatement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Testnamespace/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/FirebugTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/ProfilerCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestMockRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestMyRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestTableRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/TestMyRowset.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableAccounts.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableAccountsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugs.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugsProducts.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugsProductsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableProducts.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableProductsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableSpecial.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TestSetup.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestSetup.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Common.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Db2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Mysqli.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Oracle.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Common.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Ibm.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Mssql.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Mysql.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Oci.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Pgsql.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Sqlite.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/DebugTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/DataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/DojoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/AccordionContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/AccordionPaneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/BorderContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/DijitContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/DijitElementTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/DijitFormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/SplitContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/StackContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/TabContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/ButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/CheckBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/ComboBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/CurrencyTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/DateTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/DijitTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/EditorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/FilteringSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/HorizontalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/NumberSpinnerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/NumberTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/PasswordTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/RadioButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/SubmitButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/TextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/TextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/TimeTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/ValidationTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/VerticalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/_files/locale/array.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/SubFormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/AccordionContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/AccordionPaneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/BorderContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/CheckBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ComboBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ContentPaneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/CurrencyTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/DateTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/DojoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/EditorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/FilteringSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/HorizontalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/NumberSpinnerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/NumberTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/PasswordTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/RadioButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/SimpleTextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/SplitContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/StackContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/SubmitButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TabContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TimeTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ValidationTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/VerticalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/Query/Css2XpathTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/Query/ResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/_files/sample.xhtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/ArrayAccessTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/AtomEntryOnlyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/AtomPublishingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/CountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/ElementTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/Entry/RssTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/ImportTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/IteratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-before-update.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-created-entry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-expected-update.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-updated-entry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestGoogle.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestMozillazine.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestOReilly.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestPlanetPHP.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample3.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample4.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest091Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest092Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest100Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest100Sample2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest200Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestCNN.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestHarvardLaw.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestPlanetPHP.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestSlashdot.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestAtomFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestAtomFeedEntryOnly.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestAtomFeedNamespaced.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestFeedEntryRssContentEncoded.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/Transfer/Adapter/AbstractTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/Transfer/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/Transfer/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/AlnumTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/AlphaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/BaseNameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/DigitsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/DirTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/File/LowerCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/File/RenameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/File/UpperCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/HtmlEntitiesTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/InflectorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/InputTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/IntTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/PregReplaceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/RealPathTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StringToLowerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StringToUpperTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StringTrimTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StripNewlinesTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StripTagsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/CamelCaseToDashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/CamelCaseToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/CamelCaseToUnderscoreTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/DashToCamelCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/DashToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/DashToUnderscoreTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/SeparatorToCamelCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/SeparatorToDashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/SeparatorToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToCamelCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToDashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToPathSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/TestNamespace/MyDigits.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/TestNamespace/StringEquals.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/_testDir2/.placeholder +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/file.1 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/testfile.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/testfile2.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/FilterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/AbstractTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/CallbackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/DescriptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ErrorsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FieldsetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FormErrorsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/HtmlTagTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/LabelTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/PrepareElementsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ViewHelperTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ViewScriptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/DisplayGroupTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/ButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/CaptchaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/CheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/HashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/HiddenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/ImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/MultiCheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/MultiselectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/PasswordTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/RadioTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/ResetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/SelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/SubmitTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/TextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/TextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/TransferAdapter/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/filter/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/validator/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/ElementTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/SubFormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/multiOptions.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/multiOptions.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/zf3213.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/zf3250.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/decorators/Label.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/decorators/TableRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/locale/array.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/contentWrappingDecorator.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/decorator.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/decoratorCausesReplacement.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/replacingDecorator.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/AuthorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/BaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/CaptchaRequiredExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/CategoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/ContentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/ControlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/EntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/FeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/GeneratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/HttpExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/MockBase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/UtilTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/AuthorElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/CategoryElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/ContentElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/ContentElementSample2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/ControlElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/EntrySample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/EntrySampleHttp1.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/FeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/GeneratorElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AppTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AttendeeStatusTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AttendeeTypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AuthSubTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/CollectionEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/CollectionFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/VolumeEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/VolumeFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/_files/VolumeEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/_files/VolumeFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/BooksOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/BooksTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/AccessLevelTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/ColorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/EventEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/EventQueryExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/EventQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/HiddenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/LinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/QuickAddTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/SelectedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/SendEventNotificationsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/TimezoneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/WebContentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/AccessLevelElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/ColorElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/EventEntrySample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/EventFeedCompositeSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/HiddenElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/LinkElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/ListFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/QuickAddElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/SelectedElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/SendEventNotificationsElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/TestDataEventFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/TimezoneElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/WebContentElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarEventTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarFeedCompositeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CommentsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/DocumentListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/DocumentListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/_files/TestDataDocumentListEntrySample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/_files/TestDataDocumentListFeedSample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/DocsOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/DocsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/EntryLinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/EntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/EventStatusTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/ExtendedPropertyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/FeedLinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/FeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListRecipientEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListRecipientFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListRecipientQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/ErrorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/LoginTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/QuotaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/ServiceExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/UserEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/UserFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/UserQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/AppsForYourDomainElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListRecipientEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListRecipientFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/LoginElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NameElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NicknameElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NicknameEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NicknameFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/QuotaElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/UserEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/UserFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GappsOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GappsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/BaseAttributeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/ItemEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/ItemFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/ItemQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/SnippetFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/SnippetQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/_files/TestDataGbaseItemFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/_files/TestDataGbaseSnippetFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GbaseOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GdataOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GdataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/ProfileEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/ProfileFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/ProfileListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_allergy0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_allergy1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_allergy_all.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_condition0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_condition1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_condition_all.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_just_ccr.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications3.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications_all.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_results0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileFeedSample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileListEntrySample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/ccr_notice_sample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/HealthOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OpenSearchItemsPerPageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OpenSearchStartIndexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OpenSearchTotalResultsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OriginalEventTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosAlbumEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosAlbumFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosAlbumQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosCommentEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosPhotoEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosPhotoFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosPhotoQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosTagEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosUserEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosUserFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosUserQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestAlbumEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestAlbumFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestCommentEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestPhotoEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestPhotoFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestTagEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestUserEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestUserFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/test.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/PhotosOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/RecurrenceExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/RecurrenceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/ReminderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ColCountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CustomTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/DocumentQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ListQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/RowCountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/SpreadsheetFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/WorksheetEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/WorksheetFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataCellFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataListFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataSpreadsheetFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataWorksheetFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/SpreadsheetsOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/SpreadsheetsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/TestUtility/MockHttpClient.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/TransparencyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/VisibilityTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/WhenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/WhereTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/WhoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/CommentEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/CommentFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/ContactEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/ContactFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistVideoEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistVideoFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/SubscriptionEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/SubscriptionFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/UserProfileEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/VideoEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/VideoFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/VideoQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/CommentEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/CommentFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/ContactEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/ContactFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/FormUploadTokenResponseSample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListFeedDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListVideoEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistVideoEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistVideoEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistVideoFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_channelV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_favoritesV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_playlistV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_queryV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionFeedDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/UserProfileEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/UserProfileEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoEntryDataSamplePrivate.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTubeOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTubeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample1.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample2.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample3.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample4.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AttendeeStatusElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AttendeeTypeElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/CommentsElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/DocsTest.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/EntryLinkElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/EntrySample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/EventStatusElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/ExtendedPropertyElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/FeedLinkElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/FeedSampleV1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/FeedSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OpenSearchItemsPerPageElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OpenSearchStartIndexElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OpenSearchTotalResultsElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OriginalEventElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RecurrenceElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RecurrenceExceptionElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/ReminderElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RsaCert.pem +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RsaKey.pem +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/TransparencyElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/VisibilityElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/WhenElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/WhereElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/WhoElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/testImage.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/CurlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/ProxyAdapterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SocketKeepaliveTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SocketPersistentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SocketTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/TestAdapterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/ZF4238-zerolineresponse.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/staticFile.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testCookies.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testGetData.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testHeaders.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testHttpAuth.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testPostData.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testRawPostData.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testRedirections.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testRelativeRedirections.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testResetParameters.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testSimpleRequests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testUploads.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/CookieJarTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/CookieTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/body +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_302 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_403_nomessage +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_404 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_500 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_chunked +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_crlf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_deflate +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_gzip +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_leadingws +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_lfonly +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_multiline_header +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_unknown +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_with_cookies +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_with_single_cookie +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/AssertionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/CipherTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/ProcessTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/XmlParsingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey_bad_block.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey_missing_enc_algo.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey_missing_encryptionmethod.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedtoken.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedtoken_bad_type.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/security_token_bad_keyref.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/signedToken.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/signedToken_bad_type.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/ssl_private.cert +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/ssl_pub.cert +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/JsonXMLTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/CacheTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/ErrorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/RequestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/Smd/ServiceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/SmdTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/JsonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/FunctionalTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/HelperTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/LayoutTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/PluginTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/MinimalCustomView.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/controllers/ZendLayoutFunctionalTestErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/controllers/ZendLayoutFunctionalTestTestController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/layouts/layout.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-error/error.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-test/index.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/helpers/FooBar.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/scripts/layout.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/scripts/layout2.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/layout.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/plugin.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/test/layout.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/BindTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/CanonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/ConnectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/AutoloadDoesNotHideParseError.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/AutoloadableClass.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/MyLoader.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/MyOverloader.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/PluginLoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/_files/ParseError.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/_files/ZfTest/CacheTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/_files/ZfTest/FormSubmit.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/LoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/DataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/FormatTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/MathTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/LocaleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/ChainingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/PriorityTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/SuppressTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Formatter/SimpleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Formatter/XmlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/LogTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/DbTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/FirebugTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/MockTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/NullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/StreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/ImapTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/InterfaceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirFolderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirMessageOldTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirWritableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MboxFolderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MboxMessageOldTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/Pop3Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/SmtpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/mail.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.maildir/maildir.tar +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox/INBOX +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox/subfolder/test +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/MailTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AccelerationTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AngleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AreaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/BinaryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/CapacitanceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Cooking/VolumeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Cooking/WeightTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/CurrentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/DensityTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/EnergyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Flow/MassTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Flow/MoleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Flow/VolumeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/ForceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/FrequencyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/IlluminationTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/LengthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/LightnessTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/NumberTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/PowerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/PressureTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/SpeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/TemperatureTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/TimeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/TorqueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Viscosity/DynamicTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Viscosity/KinematicTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/VolumeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/WeightTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/AccessControllerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/LockedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/MemoryManagerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/MemoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/MovableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/ValueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mime/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mime/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mime/PartTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/MimeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ConsumerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Extension/SregTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ExtensionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/User/SessionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ProviderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ResponseHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenIdTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbSelect/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbTableSelect/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbTableSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/IteratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/NullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/AllTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/ElasticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/JumpingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/SlidingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/TestTable.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/Zf4207.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/config.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/scripts/partial.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/test.sqlite +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/testempty.sqlite +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/PaginatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/DrawingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/BooleanTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/DictionaryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/NameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/NullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/NumericTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/Object/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/Object/StreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/ObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/StreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/String/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/String/BinaryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/StringTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/ProcessingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/pdfarchiving.pdf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/stamp.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/stamp.png +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/stamp.tif +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/COPYRIGHT.TXT +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/README.TXT +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/RELEASENOTES.TXT +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/Vera.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraBI.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraBd.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraIt.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMoBI.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMoBd.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMoIt.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMono.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraSe.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraSeBd.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/ConsoleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/JsPullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/JsPushTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/ProgressBarTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/RegistryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/ClientTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/ResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnArray.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnFalse.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnInt.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnNestedArray.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnObject.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnString.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnTrue.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnVoid.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/AnalysisTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/DocumentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/FSMTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/FieldTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/DictionaryLoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/FieldInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/SegmentInfoPriorityQueueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/SegmentInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/SegmentMergerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/TermInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/TermTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_files/mergedSegment.cfs.sample +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_0.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_1.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_1.sti +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_2.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_3.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_3.del +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_4.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/deletable +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/segments +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/LuceneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/PriorityQueueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Search23Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/SearchTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/DirectoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_files/sample_data +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_0.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_1.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_2.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_3.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_3_1.del +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_4.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/segments.gen +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/segments_8 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_0.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_1.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_2.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_3.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_3.del +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_4.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/deletable +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/segments +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.fdt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.fdx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.fnm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.frq +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.nrm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.prx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.tii +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.tis +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/segments.gen +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/segments_8 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/about-pear.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/authors.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.bugs.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.documentation.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.newpackage.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.patches.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.wishlist.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/copyright.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/core.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test.docx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test.pptx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test.xlsx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test2.docx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test3.docx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/DefinitionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/CallbackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/DefinitionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/ParameterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/PrototypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/ClassTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/FunctionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/MethodTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/NodeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/ParameterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/PrototypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/ReturnValueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/ReflectionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/AkismetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Amazon/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Amazon/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Amazon/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/AlbumDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/ArtistTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/AudioscrobblerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/GroupTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/ProfileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/TagDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/TrackDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/_files/errorNoUserExists +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/_files/errorResponseStatusError +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/PostTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/PrivateDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/PublicDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/SimplePostTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883923.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883924.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883929.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883930.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884394.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884398.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884401.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884403.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427887192.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_428222530.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosExceptionGroupIdInvalid.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883923.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883924.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883929.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883930.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884394.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884398.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884401.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884403.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427887192.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_428222530.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testUserSearchExceptionEmailInvalid.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testUserSearchExceptionUsernameInvalid.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/ExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/FunctionalTestCase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/Namespace/BaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/Namespace/ImfsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/NirvanixTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/MailHideTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/ReCaptchaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/SimpyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/SlideShare/_files/demo.ppt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/SlideShareTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/BaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/DecoratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/ExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/NoSoapTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/SalesUseTaxBasicTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/StrikeIronTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/USAddressVerificationTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/ZipCodeInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/AuthorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/BlogInfoResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/CosmosResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/CosmosResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/DailyCountsResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/DailyCountsResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/GetInfoResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/KeyInfoResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/ResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/ResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/SearchResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/SearchResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagsResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagsResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TechnoratiTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TestCase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/UtilsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/WeblogTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/MISSING +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestAuthor.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestAuthorNullFields.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoErrorUrlNotWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoResult.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoResultUrlWithInvalidSchema.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogPostTagsError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogPostTagsErrorUrlNotWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogPostTagsSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogLink.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogLinkClaim.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogWeblogClaim.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogWeblogClaim2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteLink.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteUrlWithInvalidSchema.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteWeblogWithMissingInboundblogs.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestDailyCountsError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestDailyCountsResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestDailyCountsSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestGetInfoError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestGetInfoResult.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestGetInfoSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestKeyInfoError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestKeyInfoResult.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestKeyInfoSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestSearchResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestSearchSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagsResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTopTagsError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTopTagsSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestWeblogTwoAuthors.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/TwitterSearchTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/TwitterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Yahoo/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Yahoo/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Yahoo/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/README.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SaveHandler/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SaveHandler/DbTableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SessionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SessionTestHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/AutoDiscoverTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/ClientTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/Wsdl/ArrayOfTypeComplexStrategyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/Wsdl/ArrayOfTypeSequenceStrategyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/WsdlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/_files/cert_file +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/_files/commontypes.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/_files/wsdl_example.wsdl +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/schemas/wsdl.xsd +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/ControllerTestCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers/ErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers/ZendTestPhpUnitFooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/error/error.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/zend-test-php-unit-foo/bar.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/zend-test-php-unit-foo/baz.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/bootstrap.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/CharWrapLeftToRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/CharWrapRightToLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/CorrectEncoding.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/GenerateDummies.sh +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/GzippedFont.gz +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/InvalidFont.flf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/NoSmush.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/NoSmushRightToLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/OutputWidth50AlignRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/ParagraphOff.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/ParagraphOn.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/SmushDefault.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/SmushForced.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardAlignCenter.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardAlignLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardAlignRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardRightToLeftAlignCenter.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardRightToLeftAlignLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardRightToLeftAlignRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/WordWrapLeftToRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/WordWrapRightToLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/FigletTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/TableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/TimeSyncTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/CsvTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/GettextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/IniTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/QtTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/TbxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/TmxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/XliffTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/XmlTmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed2.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed3.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed3.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/de_AT/LC_TEST/translation-de_DE.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/en_GB/LC_OTHER/translation-en_US.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/de_AT/LC_TEST/translation-de_DE.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/en_GB/LC_OTHER/translation-en_US.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/de_AT/LC_TEST/translation-de_DE.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/en_GB/LC_OTHER/translation-en_US.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/de_AT/LC_TEST/translation-de_DE.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/en_GB/LC_OTHER/translation-en_US.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/de_AT/LC_TEST/translation-de_DE.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/en_GB/LC_OTHER/translation-en_US.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/de_AT/LC_TEST/translation-de_DE.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/en_GB/LC_OTHER/translation-en_US.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/de_AT/LC_TEST/translation-de_DE.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/en_GB/LC_OTHER/translation-en_US.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/de_AT/LC_TEST/translation-de_DE.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/en_GB/LC_OTHER/translation-en_US.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/de_AT/LC_TEST/translation-de_DE.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/en_GB/LC_OTHER/translation-en_US.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_bigendian.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_otherdelimiter.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_otherencoding.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_otherencoding.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_specialchars.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_withoutencoding.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_withoutencoding.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_withoutencoding.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/TranslateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Uri/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Uri/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Uri/_files/testVeryLongUriZF3712.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/UriTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AbstractTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AlnumTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AlphaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/BarcodeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/BetweenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/CcnumTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/DateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/DigitsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/EmailAddressTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/CountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/Crc32Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExcludeExtensionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExcludeMimeTypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExistsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExtensionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/FilesSizeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/HashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ImageSizeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/IsCompressedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/IsImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/Md5Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/MimeTypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/NotExistsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/Sha1Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/SizeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/UploadTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/badpicture.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/picture.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/test.zip +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize2.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize3.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize4.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/FloatTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/GreaterThanTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/HexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/HostnameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/IdenticalTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/InArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/IntTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/IpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/LessThanTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/NotEmptyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/RegexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/StringLengthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ValidateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/VersionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/ActionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/DeclareVarsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/DoctypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FieldsetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormCheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormErrorsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormFileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormLabelTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormMultiCheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormPasswordTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormRadioTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormResetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormSubmitTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormTextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormTextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadLinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadMetaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadScriptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadStyleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadTitleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlFlashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlListTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlPageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlQuicktimeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/InlineScriptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/JsonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/LayoutTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PaginationControlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PartialLoopTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PartialTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder/ContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder/RegistryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder/StandaloneContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PlaceholderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/RenderToPlaceholderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/TranslateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/UrlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/controllers/BarController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/controllers/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/bar/baz.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/foo/bar.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/foo/baz.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialActionCall.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialLoop.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialLoopCouter.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialLoopObject.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialObj.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialOne.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialThree.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialVars.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/controllers/BazController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/controllers/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz/bar-one.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz/bar-three.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz/bar-two.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo/bar.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo/nest.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo/nested.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/partialLoop.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/partialTwo.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/scripts/rendertoplaceholderscript.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/scripts/testPagination.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/FilterDir1/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir1/Stub1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir1/StubEmpty.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2/Datetime.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2/Stub1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2/Stub2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/test.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testParent.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testStrictVars.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testSubTemplate.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testZf995.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ViewTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Wildfire/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Wildfire/WildfireTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Wildfire/_files/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ClientTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/FaultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/Request/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/RequestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/Server/CacheTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/Server/FaultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ValueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class1/Subclass2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class3.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class4.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/ClassNonexistent.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Interface1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir2/Class2.php +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files/_testDir2 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files/_testDir1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/XmlRpc/Server +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/XmlRpc/Request +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/XmlRpc +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Wildfire/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Wildfire +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_templates +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs/FilterDir1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/bar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Validate/File/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Validate/File +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Validate +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Uri/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Uri +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Text/Figlet +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Text +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/zend-test-php-unit-foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap/schemas +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap/Wsdl +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Session/SaveHandler +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Session +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Yahoo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Technorati +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/SlideShare/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/SlideShare +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/Namespace +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Flickr +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Delicious +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Amazon +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Server/Reflection +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Server/Method +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Server +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_tempFiles/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_tempFiles +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Rest/responses +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Rest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/ProgressBar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/Element/String +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/Element/Object +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/Element +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/_files/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbTableSelect +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbSelect +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/User +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Extension +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mime +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Memory/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Memory +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure/Viscosity +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure/Flow +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure/Cooking +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox/subfolder +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.maildir +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log/Writer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log/Formatter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log/Filter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Loader/_files/ZfTest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Loader/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Loader +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Ldap +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/filters +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/layouts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Json/Server/Smd +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Json/Server +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Json +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/InfoCard/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/InfoCard +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http/Client/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http/Client +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/TestUtility +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Photos +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Health +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Docs +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Books/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Books +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/App +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/decorators +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/config +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/validator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/filter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/TransferAdapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Decorator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/_files/_testDir2 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/_files/TestNamespace +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/Word +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/File +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/File/Transfer/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/File/Transfer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/File +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Feed/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Feed/Entry +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Feed +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dom/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dom/Query +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dom +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/View +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/_files/locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/TestUtil +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Select +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Row +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Statement +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Select +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Profiler +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Testnamespace +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Date +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/view +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/foo-bar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/custom +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/filters +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts/admin/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts/admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers/Admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts/admin/helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts/admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/controllers/Admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/filters +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/Helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Router +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Response +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Request +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Plugin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Dispatcher +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Action/HelperBroker +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Action +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Console +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/Writer/temp +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/Writer/files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/Writer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Captcha +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Cache +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/Resolver +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Digest/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Digest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/BasicSqliteTest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Value +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Util +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Response +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Request +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Log-Writer-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Db-Profiler-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-wildfire-plugin-firephp +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-db-profiler-firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Log-Writer-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Db-Profiler-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Yahoo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Protocols +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Flickr +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Amazon +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene/feed-search +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/ProgressBar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Pdf +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/templates +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail/mbox/subfolder +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail/mbox +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail/maildir +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/MyLibrary +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Feeds +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%% + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Value + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Server + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Response + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Request + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Client + at dirrm %%DATADIR%%/library/Zend/XmlRpc + at dirrm %%DATADIR%%/library/Zend/Wildfire/Protocol + at dirrm %%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp + at dirrm %%DATADIR%%/library/Zend/Wildfire/Plugin + at dirrm %%DATADIR%%/library/Zend/Wildfire/Channel + at dirrm %%DATADIR%%/library/Zend/Wildfire + at dirrm %%DATADIR%%/library/Zend/View/Helper/Placeholder/Registry + at dirrm %%DATADIR%%/library/Zend/View/Helper/Placeholder/Container + at dirrm %%DATADIR%%/library/Zend/View/Helper/Placeholder + at dirrm %%DATADIR%%/library/Zend/View/Helper/Partial + at dirrm %%DATADIR%%/library/Zend/View/Helper + at dirrm %%DATADIR%%/library/Zend/View + at dirrm %%DATADIR%%/library/Zend/Validate/Hostname + at dirrm %%DATADIR%%/library/Zend/Validate/File + at dirrm %%DATADIR%%/library/Zend/Validate/Barcode + at dirrm %%DATADIR%%/library/Zend/Validate + at dirrm %%DATADIR%%/library/Zend/Uri + at dirrm %%DATADIR%%/library/Zend/Translate/Adapter + at dirrm %%DATADIR%%/library/Zend/Translate + at dirrm %%DATADIR%%/library/Zend/TimeSync + at dirrm %%DATADIR%%/library/Zend/Text/Table/Decorator + at dirrm %%DATADIR%%/library/Zend/Text/Table + at dirrm %%DATADIR%%/library/Zend/Text/Figlet + at dirrm %%DATADIR%%/library/Zend/Text + at dirrm %%DATADIR%%/library/Zend/Test/PHPUnit/Constraint + at dirrm %%DATADIR%%/library/Zend/Test/PHPUnit + at dirrm %%DATADIR%%/library/Zend/Test + at dirrm %%DATADIR%%/library/Zend/Soap/Wsdl/Strategy + at dirrm %%DATADIR%%/library/Zend/Soap/Wsdl/Parser + at dirrm %%DATADIR%%/library/Zend/Soap/Wsdl + at dirrm %%DATADIR%%/library/Zend/Soap/Server + at dirrm %%DATADIR%%/library/Zend/Soap/Client + at dirrm %%DATADIR%%/library/Zend/Soap/AutoDiscover + at dirrm %%DATADIR%%/library/Zend/Soap + at dirrm %%DATADIR%%/library/Zend/Session/Validator + at dirrm %%DATADIR%%/library/Zend/Session/SaveHandler + at dirrm %%DATADIR%%/library/Zend/Session + at dirrm %%DATADIR%%/library/Zend/Service/Yahoo + at dirrm %%DATADIR%%/library/Zend/Service/Twitter + at dirrm %%DATADIR%%/library/Zend/Service/Technorati + at dirrm %%DATADIR%%/library/Zend/Service/StrikeIron + at dirrm %%DATADIR%%/library/Zend/Service/SlideShare + at dirrm %%DATADIR%%/library/Zend/Service/Simpy + at dirrm %%DATADIR%%/library/Zend/Service/ReCaptcha/MailHide + at dirrm %%DATADIR%%/library/Zend/Service/ReCaptcha + at dirrm %%DATADIR%%/library/Zend/Service/Nirvanix/Namespace + at dirrm %%DATADIR%%/library/Zend/Service/Nirvanix + at dirrm %%DATADIR%%/library/Zend/Service/Flickr + at dirrm %%DATADIR%%/library/Zend/Service/Delicious + at dirrm %%DATADIR%%/library/Zend/Service/Amazon + at dirrm %%DATADIR%%/library/Zend/Service + at dirrm %%DATADIR%%/library/Zend/Server/Reflection/Function + at dirrm %%DATADIR%%/library/Zend/Server/Reflection + at dirrm %%DATADIR%%/library/Zend/Server/Method + at dirrm %%DATADIR%%/library/Zend/Server + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Storage/File + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Storage/Directory + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Storage + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/Weight + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/Similarity + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/Query + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Index + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Document + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8Num + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8 + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/TextNum + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Text + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis + at dirrm %%DATADIR%%/library/Zend/Search/Lucene + at dirrm %%DATADIR%%/library/Zend/Search + at dirrm %%DATADIR%%/library/Zend/Rest/Server + at dirrm %%DATADIR%%/library/Zend/Rest/Client/Result + at dirrm %%DATADIR%%/library/Zend/Rest/Client + at dirrm %%DATADIR%%/library/Zend/Rest + at dirrm %%DATADIR%%/library/Zend/Request + at dirrm %%DATADIR%%/library/Zend/ProgressBar/Adapter + at dirrm %%DATADIR%%/library/Zend/ProgressBar + at dirrm %%DATADIR%%/library/Zend/Pdf/Trailer + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Image + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Parsed + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/CidFont + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource + at dirrm %%DATADIR%%/library/Zend/Pdf/Parser + at dirrm %%DATADIR%%/library/Zend/Pdf/Filter/Compression + at dirrm %%DATADIR%%/library/Zend/Pdf/Filter + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParserDataSource + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser/Image + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser/Font/OpenType + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser/Font + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser + at dirrm %%DATADIR%%/library/Zend/Pdf/ElementFactory + at dirrm %%DATADIR%%/library/Zend/Pdf/Element/String + at dirrm %%DATADIR%%/library/Zend/Pdf/Element/Reference + at dirrm %%DATADIR%%/library/Zend/Pdf/Element/Object + at dirrm %%DATADIR%%/library/Zend/Pdf/Element + at dirrm %%DATADIR%%/library/Zend/Pdf/Color + at dirrm %%DATADIR%%/library/Zend/Pdf/Cmap/ByteEncoding + at dirrm %%DATADIR%%/library/Zend/Pdf/Cmap + at dirrm %%DATADIR%%/library/Zend/Pdf + at dirrm %%DATADIR%%/library/Zend/Paginator/ScrollingStyle + at dirrm %%DATADIR%%/library/Zend/Paginator/Adapter + at dirrm %%DATADIR%%/library/Zend/Paginator + at dirrm %%DATADIR%%/library/Zend/OpenId/Provider/User + at dirrm %%DATADIR%%/library/Zend/OpenId/Provider/Storage + at dirrm %%DATADIR%%/library/Zend/OpenId/Provider + at dirrm %%DATADIR%%/library/Zend/OpenId/Extension + at dirrm %%DATADIR%%/library/Zend/OpenId/Consumer/Storage + at dirrm %%DATADIR%%/library/Zend/OpenId/Consumer + at dirrm %%DATADIR%%/library/Zend/OpenId + at dirrm %%DATADIR%%/library/Zend/Mime + at dirrm %%DATADIR%%/library/Zend/Memory/Container + at dirrm %%DATADIR%%/library/Zend/Memory + at dirrm %%DATADIR%%/library/Zend/Measure/Viscosity + at dirrm %%DATADIR%%/library/Zend/Measure/Flow + at dirrm %%DATADIR%%/library/Zend/Measure/Cooking + at dirrm %%DATADIR%%/library/Zend/Measure + at dirrm %%DATADIR%%/library/Zend/Mail/Transport + at dirrm %%DATADIR%%/library/Zend/Mail/Storage/Writable + at dirrm %%DATADIR%%/library/Zend/Mail/Storage/Folder + at dirrm %%DATADIR%%/library/Zend/Mail/Storage + at dirrm %%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth + at dirrm %%DATADIR%%/library/Zend/Mail/Protocol/Smtp + at dirrm %%DATADIR%%/library/Zend/Mail/Protocol + at dirrm %%DATADIR%%/library/Zend/Mail/Part + at dirrm %%DATADIR%%/library/Zend/Mail/Message + at dirrm %%DATADIR%%/library/Zend/Mail + at dirrm %%DATADIR%%/library/Zend/Log/Writer + at dirrm %%DATADIR%%/library/Zend/Log/Formatter + at dirrm %%DATADIR%%/library/Zend/Log/Filter + at dirrm %%DATADIR%%/library/Zend/Log + at dirrm %%DATADIR%%/library/Zend/Locale/Math + at dirrm %%DATADIR%%/library/Zend/Locale/Data + at dirrm %%DATADIR%%/library/Zend/Locale + at dirrm %%DATADIR%%/library/Zend/Loader/PluginLoader + at dirrm %%DATADIR%%/library/Zend/Loader + at dirrm %%DATADIR%%/library/Zend/Ldap + at dirrm %%DATADIR%%/library/Zend/Layout/Controller/Plugin + at dirrm %%DATADIR%%/library/Zend/Layout/Controller/Action/Helper + at dirrm %%DATADIR%%/library/Zend/Layout/Controller/Action + at dirrm %%DATADIR%%/library/Zend/Layout/Controller + at dirrm %%DATADIR%%/library/Zend/Layout + at dirrm %%DATADIR%%/library/Zend/Json/Server/Smd + at dirrm %%DATADIR%%/library/Zend/Json/Server/Response + at dirrm %%DATADIR%%/library/Zend/Json/Server/Request + at dirrm %%DATADIR%%/library/Zend/Json/Server + at dirrm %%DATADIR%%/library/Zend/Json + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Security + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Element + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Assertion + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes256cbc + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes128cbc + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Rsa + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Adapter + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Pki + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher + at dirrm %%DATADIR%%/library/Zend/InfoCard/Adapter + at dirrm %%DATADIR%%/library/Zend/InfoCard + at dirrm %%DATADIR%%/library/Zend/Http/Client/Adapter + at dirrm %%DATADIR%%/library/Zend/Http/Client + at dirrm %%DATADIR%%/library/Zend/Http + at dirrm %%DATADIR%%/library/Zend/Gdata/YouTube/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/YouTube + at dirrm %%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Spreadsheets + at dirrm %%DATADIR%%/library/Zend/Gdata/Photos/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Photos + at dirrm %%DATADIR%%/library/Zend/Gdata/Media/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Media + at dirrm %%DATADIR%%/library/Zend/Gdata/Kind + at dirrm %%DATADIR%%/library/Zend/Gdata/Health/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Health + at dirrm %%DATADIR%%/library/Zend/Gdata/Geo/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Geo + at dirrm %%DATADIR%%/library/Zend/Gdata/Gbase/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Gbase + at dirrm %%DATADIR%%/library/Zend/Gdata/Gapps/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Gapps + at dirrm %%DATADIR%%/library/Zend/Gdata/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Exif/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Exif + at dirrm %%DATADIR%%/library/Zend/Gdata/DublinCore/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/DublinCore + at dirrm %%DATADIR%%/library/Zend/Gdata/Docs + at dirrm %%DATADIR%%/library/Zend/Gdata/Calendar/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Calendar + at dirrm %%DATADIR%%/library/Zend/Gdata/Books/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Books + at dirrm %%DATADIR%%/library/Zend/Gdata/App/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/App + at dirrm %%DATADIR%%/library/Zend/Gdata + at dirrm %%DATADIR%%/library/Zend/Form/Element + at dirrm %%DATADIR%%/library/Zend/Form/Decorator/Captcha + at dirrm %%DATADIR%%/library/Zend/Form/Decorator + at dirrm %%DATADIR%%/library/Zend/Form + at dirrm %%DATADIR%%/library/Zend/Filter/Word/Separator + at dirrm %%DATADIR%%/library/Zend/Filter/Word + at dirrm %%DATADIR%%/library/Zend/Filter/File + at dirrm %%DATADIR%%/library/Zend/Filter + at dirrm %%DATADIR%%/library/Zend/File/Transfer/Adapter + at dirrm %%DATADIR%%/library/Zend/File/Transfer + at dirrm %%DATADIR%%/library/Zend/File + at dirrm %%DATADIR%%/library/Zend/Feed/Entry + at dirrm %%DATADIR%%/library/Zend/Feed/Builder/Header + at dirrm %%DATADIR%%/library/Zend/Feed/Builder + at dirrm %%DATADIR%%/library/Zend/Feed + at dirrm %%DATADIR%%/library/Zend/Dom/Query + at dirrm %%DATADIR%%/library/Zend/Dom + at dirrm %%DATADIR%%/library/Zend/Dojo/View/Helper/Dojo + at dirrm %%DATADIR%%/library/Zend/Dojo/View/Helper + at dirrm %%DATADIR%%/library/Zend/Dojo/View + at dirrm %%DATADIR%%/library/Zend/Dojo/Form/Element + at dirrm %%DATADIR%%/library/Zend/Dojo/Form/Decorator + at dirrm %%DATADIR%%/library/Zend/Dojo/Form + at dirrm %%DATADIR%%/library/Zend/Dojo + at dirrm %%DATADIR%%/library/Zend/Db/Table/Select + at dirrm %%DATADIR%%/library/Zend/Db/Table/Rowset + at dirrm %%DATADIR%%/library/Zend/Db/Table/Row + at dirrm %%DATADIR%%/library/Zend/Db/Table + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Pdo + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Oracle + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Mysqli + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Db2 + at dirrm %%DATADIR%%/library/Zend/Db/Statement + at dirrm %%DATADIR%%/library/Zend/Db/Select + at dirrm %%DATADIR%%/library/Zend/Db/Profiler + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Pdo + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Oracle + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Mysqli + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Db2 + at dirrm %%DATADIR%%/library/Zend/Db/Adapter + at dirrm %%DATADIR%%/library/Zend/Db + at dirrm %%DATADIR%%/library/Zend/Date + at dirrm %%DATADIR%%/library/Zend/Currency + at dirrm %%DATADIR%%/library/Zend/Controller/Router/Route + at dirrm %%DATADIR%%/library/Zend/Controller/Router + at dirrm %%DATADIR%%/library/Zend/Controller/Response + at dirrm %%DATADIR%%/library/Zend/Controller/Request + at dirrm %%DATADIR%%/library/Zend/Controller/Plugin + at dirrm %%DATADIR%%/library/Zend/Controller/Dispatcher + at dirrm %%DATADIR%%/library/Zend/Controller/Action/HelperBroker + at dirrm %%DATADIR%%/library/Zend/Controller/Action/Helper/AutoComplete + at dirrm %%DATADIR%%/library/Zend/Controller/Action/Helper + at dirrm %%DATADIR%%/library/Zend/Controller/Action + at dirrm %%DATADIR%%/library/Zend/Controller + at dirrm %%DATADIR%%/library/Zend/Console/Getopt + at dirrm %%DATADIR%%/library/Zend/Console + at dirrm %%DATADIR%%/library/Zend/Config/Writer + at dirrm %%DATADIR%%/library/Zend/Config + at dirrm %%DATADIR%%/library/Zend/Captcha + at dirrm %%DATADIR%%/library/Zend/Cache/Frontend + at dirrm %%DATADIR%%/library/Zend/Cache/Backend + at dirrm %%DATADIR%%/library/Zend/Cache + at dirrm %%DATADIR%%/library/Zend/Auth/Storage + at dirrm %%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver + at dirrm %%DATADIR%%/library/Zend/Auth/Adapter/Http + at dirrm %%DATADIR%%/library/Zend/Auth/Adapter + at dirrm %%DATADIR%%/library/Zend/Auth + at dirrm %%DATADIR%%/library/Zend/Amf/Value/Messaging + at dirrm %%DATADIR%%/library/Zend/Amf/Value + at dirrm %%DATADIR%%/library/Zend/Amf/Util + at dirrm %%DATADIR%%/library/Zend/Amf/Server + at dirrm %%DATADIR%%/library/Zend/Amf/Response + at dirrm %%DATADIR%%/library/Zend/Amf/Request + at dirrm %%DATADIR%%/library/Zend/Amf/Parse/Amf3 + at dirrm %%DATADIR%%/library/Zend/Amf/Parse/Amf0 + at dirrm %%DATADIR%%/library/Zend/Amf/Parse + at dirrm %%DATADIR%%/library/Zend/Amf + at dirrm %%DATADIR%%/library/Zend/Acl/Role/Registry + at dirrm %%DATADIR%%/library/Zend/Acl/Role + at dirrm %%DATADIR%%/library/Zend/Acl/Resource + at dirrm %%DATADIR%%/library/Zend/Acl/Assert + at dirrm %%DATADIR%%/library/Zend/Acl + at dirrm %%DATADIR%%/library/Zend + at dirrm %%DATADIR%%/library +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project/_files/project1 +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project/_files +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project/Context +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Framework +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/_files +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection/_files +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/Tag +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Structure +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Provider +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Iterator +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/FileParser +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Action +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/System +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/IncludePathLoader +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Client +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Member +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Apache +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Reflection/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Reflection +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Console +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/bin +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/shrinksafe +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo/src/main/assembly +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo/src/main +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/webapp/WEB-INF +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/webapp +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java/org/dojotoolkit +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java/org +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh/robot +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh/_sounds +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Root +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Global +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests/profiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests/foo/page +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests/foo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/profiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/jslib +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/cldr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xmpp/widget/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xmpp/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xmpp +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xml +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/wire/ml +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/wire +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Wizard +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Toaster +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/SortList +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/RollingList +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Pager/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Pager +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Loader/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Loader +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/FisheyeList +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/FilePicker +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/DocTester +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Dialog/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Dialog +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/ColorPicker +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Calendar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/validate +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/uuid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/timing +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/testing +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/string +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/storage +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sql +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sketch/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sketch/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sketch +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/secure +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/rpc +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/robot +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/presentation/resources/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/presentation/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/presentation +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/off/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/off/docs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/off +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/math +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/resources/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/nls/en +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/dnd +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/lang/functional +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/lang/aspect +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/lang +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/jsonPath +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/json +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/io/proxy/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/io/proxy +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/io +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/image/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/image/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/image +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/html +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/languages +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/help +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/_grid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/_data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/cells +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/_grid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/gfx3d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/gfx/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/gfx +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/fx/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/fx/ext-dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/fx +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/flash +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding/digests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding/crypto +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding/compression +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/embed/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/embed/IE +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/embed +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/utils +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/tag +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/render +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/filter +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/ext-dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/contrib +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/date +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/data/s3 +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/cometd +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/color +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/collections +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/themes/ET +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/themes +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/scaler +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/plot3d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/plot2d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/axis2d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/action2d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/widget/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/widget/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/profiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/plugins +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/logger/logs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/logger +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/rpc +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/io +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/fx +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/dnd +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/date +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/data/util +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/data/api +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-cn +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/pt-br +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ko-kr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ja-jp +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/it-it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/es-es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-us +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-gb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/de-de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/_firebug +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/_base/_loader +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/_base +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/themeTesterImages +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/noir/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/noir +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/a11y +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/tests/_data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/layout/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_tree +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/plugins +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_base +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video/media/thumbs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video/media +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/uploader/UploadedFiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/uploader +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/images/users +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/cache +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/resources/silk/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/resources/silk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls/en +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mojo/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mojo/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mail +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/i18n +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts/img +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards/src/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/castle/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/castle +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo +%%DOJO%%@dirrm %%DATADIR%%/externals + at dirrm %%DATADIR%% +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/index +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_tempFiles/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/OpenId/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Memory/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/filters +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Db/Table/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/views/helpers +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/views/filters +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/helpers +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/filters +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Config/Writer/temp +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/_files +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/tests/Zend/Tool/Project/_files/project1 +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/tests/Zend/Tool/Framework +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/Docblock +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/library/Zend/Tool/Project/Structure +%%DOJO%%@exec mkdir -p %D/%%DATADIR%%/externals/dojo/dojox/analytics/logger/logs +%%DOJO%%@exec mkdir -p %D/%%DATADIR%%/externals/dojo/demos/uploader/UploadedFiles +%%DOJO%%@exec mkdir -p %D/%%DATADIR%%/externals/dojo/demos/skew/cache --- /dev/null +++ www/zend-framework/Makefile @@ -0,0 +1,140 @@ +# $MidnightBSD: mports/www/zend-framework/Makefile,v 1.1 2009/01/29 17:52:55 laffer1 Exp $ + +PORTNAME= ZendFramework +PORTVERSION= 1.7.3 +CATEGORIES= www +MASTER_SITES= http://framework.zend.com/releases/${DISTNAME}/ GENTOO/distfiles + +MAINTAINER= ports at MidnightBSD.org +COMMENT= A framework for developing PHP web applications +LICENSE= unknown + +NO_BUILD= yes +USE_PHP= spl +WANT_PHP_WEB= yes +USE_GETTEXT= yes + +SUB_FILES= pkg-message + +OPTIONS= \ + EDOJO "Install embedded Dojo" On \ + PDOJO "Install Dojo from ports" Off \ + INCUBATOR "Install incubator classes" Off \ + MYSQL "Install MySQL PDO support" Off \ + MYSQLI "Install MySQLi support" Off \ + DBLIB "Install DBLIB PDO support" Off \ + PGSQL "Install PostgreSQL PDO support" Off \ + ODBC "Install ODBC PDO support" Off \ + SQLITE "Install SQLite v3 PDO support" Off \ + REQPHP "Install required PHP dependencies" On \ + OPTPHP "Install optional PHP dependencies" Off + +#OCI "Install Oracle OCI 8 PDO support" Off \ + +.if !defined(NOPORTDOCS) +PORTDOCS= INSTALL.txt README.txt +.endif + +.include + +# Check for mutually-exclusive options +.if defined(WITH_EDOJO) && defined(WITH_PDOJO) +IGNORE= please select only one type of Dojo installation +.endif + +INSTALL_DIRS= library + +.if defined(WITH_EDOJO) +DOJO= "" +INSTALL_DIRS+= externals +CONFLICTS+= dojo-1.* +.else +DOJO= "@comment " +.endif +PLIST_SUB+= DOJO=${DOJO} + +.if defined(WITH_INCUBATOR) +INCUBATOR= "" +INSTALL_DIRS+= incubator +.else +INCUBATOR= "@comment " +.endif +PLIST_SUB+= INCUBATOR=${INCUBATOR} + +.if defined(WITH_PDOJO) +RUN_DEPENDS+= dojo>=0:${PORTSDIR}/www/dojo +.endif + +# Add all of the required and/or optional PHP extension dependencies, +# if chosen by the user. +# +# See http://framework.zend.com/manual/en/requirements.extensions.html for +# a table of what PHP extensions are required for what ZF classes. + +.if defined(WITH_REQPHP) +USE_PHP+= apc ctype curl dom gd hash iconv mbstring \ + memcache pdo session simplexml soap xml zlib +.endif +.if defined(WITH_OPTPHP) +USE_PHP+= bcmath bitset json posix +.endif + +.if defined(WITH_MYSQL) +USE_PHP+= pdo_mysql +.endif + +.if defined(WITH_MYSQLI) +USE_PHP+= mysqli +.endif + +.if defined(WITH_DBLIB) +RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_dblib.so:${PORTSDIR}/databases/php5-pdo_dblib +.endif + +.if defined(WITH_PGSQL) +RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_pgsql.so:${PORTSDIR}/databases/php5-pdo_pgsql +.endif + +#.if defined(WITH_OCI) +#RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_oci.so:${PORTSDIR}/databases/php5-pdo_oci +#.endif + +.if defined(WITH_ODBC) +RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_odbc.so:${PORTSDIR}/databases/php5-pdo_odbc +.endif + +.if defined(WITH_SQLITE) +USE_PHP+= pdo_sqlite +.endif + +do-install: + @cd ${WRKSRC} && ${COPYTREE_SHARE} "${INSTALL_DIRS}" ${DATADIR} + @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${DATADIR} + @${ECHO_CMD} '@exec ${CHOWN} -R ${WWWOWN}:${WWWGRP} \ + ${DATADIR:S|^${PREFIX}/|%D/|}' >> ${TMPPLIST} + @${FIND} ${DATADIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 + @${ECHO_CMD} '@exec ${FIND} ${DATADIR} -type f -print0 | \ + ${XARGS} -0 ${CHMOD} 644' >> ${TMPPLIST} + @${FIND} ${DATADIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 + @${ECHO_CMD} '@exec ${FIND} ${DATADIR} -type d -print0 | \ + ${XARGS} -0 ${CHMOD} 755' >> ${TMPPLIST} +.if !defined(NOPORTEXAMPLES) + @cd ${WRKSRC} && ${COPYTREE_SHARE} "demos tests" ${EXAMPLESDIR} + @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${EXAMPLESDIR} + @${ECHO_CMD} '@exec ${CHOWN} -R ${WWWOWN}:${WWWGRP} \ + ${EXAMPLESDIR:S|^${PREFIX}/|%D/|}' >> ${TMPPLIST} + @${FIND} ${EXAMPLESDIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 + @${ECHO_CMD} '@exec ${FIND} ${EXAMPLESDIR} -type f -print0 | \ + ${XARGS} -0 ${CHMOD} 644' >> ${TMPPLIST} + @${FIND} ${EXAMPLESDIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 + @${ECHO_CMD} '@exec ${FIND} ${EXAMPLESDIR} -type d -print0 | \ + ${XARGS} -0 ${CHMOD} 755' >> ${TMPPLIST} +.endif + +post-install: +.if !defined(NOPORTDOCS) + @${INSTALL} -d ${DOCSDIR} + @cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDOCS}" ${DOCSDIR} +.endif + +.include --- /dev/null +++ www/zend-framework/distinfo @@ -0,0 +1,3 @@ +MD5 (ZendFramework-1.7.3.tar.gz) = 2e85be48a81d41cad72b9ababe16a806 +SHA256 (ZendFramework-1.7.3.tar.gz) = 372a3a29eb4578e0dd4f2b1a8f614648dcf5f3fc290e4088679c5ac4ce883f47 +SIZE (ZendFramework-1.7.3.tar.gz) = 21197198 --- /dev/null +++ www/zend-framework/files/pkg-message.in @@ -0,0 +1,10 @@ +Now you need to adjust PHP's include_path to contain + `%%DATADIR%%/library' + +For example, insert: + include_path = ".:%%DATADIR%%/library" + +into `%%LOCALBASE%%/etc/php.ini'. + +For more information about the Zend Framework, please visit: +http://framework.zend.com/ From laffer1 at midnightbsd.org Thu Jan 1 12:32:00 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 1 Jan 2009 12:32:00 -0500 (EST) Subject: [Midnightbsd-cvs] src: param.h: Don't make this octal. Message-ID: <200901011732.n01HW09D019691@stargazer.midnightbsd.org> Log Message: ----------- Don't make this octal. Tags: ---- RELENG_0_2 Modified Files: -------------- src/sys/sys: param.h (r1.8.2.6 -> r1.8.2.7) -------------- next part -------------- Index: param.h =================================================================== RCS file: /home/cvs/src/sys/sys/param.h,v retrieving revision 1.8.2.6 retrieving revision 1.8.2.7 diff -L sys/sys/param.h -L sys/sys/param.h -u -r1.8.2.6 -r1.8.2.7 --- sys/sys/param.h +++ sys/sys/param.h @@ -61,7 +61,7 @@ #define __FreeBSD_version 601000 /* Master, propagated to newvers */ #undef __MidnightBSD_version -#define __MidnightBSD_version 002008 +#define __MidnightBSD_version 2008 #ifndef LOCORE #include From laffer1 at midnightbsd.org Thu Jan 1 12:49:43 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 1 Jan 2009 12:49:43 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: donation link Message-ID: <200901011749.n01Hnhpl021622@stargazer.midnightbsd.org> Log Message: ----------- donation link Modified Files: -------------- www/donate: index.html (r1.4 -> r1.5) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/donate/index.html,v retrieving revision 1.4 retrieving revision 1.5 diff -L donate/index.html -L donate/index.html -u -r1.4 -r1.5 --- donate/index.html +++ donate/index.html @@ -34,6 +34,16 @@

Please email luke@midnightbsd.org to make a request or when a request is filled, so that we may update this page. Requestors on this page should have at least one accepted contribution to MidnightBSD.

Donors, please contact the requestor directly and CC the above address. The MidnightBSD project cannot assist with aranging delivery and is not responsible for any transactions.

Check with your local post office for requirements to send out of the country if needed.

+ + +
+

+ + + +

+

@@ -74,4 +84,4 @@ - \ No newline at end of file + From ctriv at midnightbsd.org Thu Jan 1 15:25:30 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Thu, 1 Jan 2009 15:25:30 -0500 (EST) Subject: [Midnightbsd-cvs] mports: x11/xorg-cf-files: Force UseElfFormat to YES. Message-ID: <200901012025.n01KPUEr037398@stargazer.midnightbsd.org> Log Message: ----------- Force UseElfFormat to YES. mbsd has always been elf, and this fixes breakage in -CURRENT Modified Files: -------------- mports/x11/xorg-cf-files: Makefile (r1.2 -> r1.3) mports/x11/xorg-cf-files/files: patch-FreeBSD.cf (r1.2 -> r1.3) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/x11/xorg-cf-files/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L x11/xorg-cf-files/Makefile -L x11/xorg-cf-files/Makefile -u -r1.2 -r1.3 --- x11/xorg-cf-files/Makefile +++ x11/xorg-cf-files/Makefile @@ -8,7 +8,7 @@ PORTNAME= xorg-cf-files PORTVERSION= 1.0.2 -PORTREVISION= 1 +PORTREVISION= 2 CATEGORIES= x11 MAINTAINER= ports at MidnightBSD.org Index: patch-FreeBSD.cf =================================================================== RCS file: /home/cvs/mports/x11/xorg-cf-files/files/patch-FreeBSD.cf,v retrieving revision 1.2 retrieving revision 1.3 diff -L x11/xorg-cf-files/files/patch-FreeBSD.cf -L x11/xorg-cf-files/files/patch-FreeBSD.cf -u -r1.2 -r1.3 --- x11/xorg-cf-files/files/patch-FreeBSD.cf +++ x11/xorg-cf-files/files/patch-FreeBSD.cf @@ -1,6 +1,17 @@ ---- ./FreeBSD.cf.orig Tue Oct 16 22:57:20 2007 -+++ ./FreeBSD.cf Tue Oct 16 23:09:35 2007 -@@ -47,19 +47,10 @@ +--- ./FreeBSD.cf.orig 2005-05-04 00:14:57 -0400 ++++ ./FreeBSD.cf 2008-12-25 00:22:56 -0500 +@@ -5,9 +5,7 @@ + XCOMM + XCOMM platform: $XFree86: xc/config/cf/FreeBSD.cf,v 3.147 2004/01/28 01:46:21 dawes Exp $ + +-#ifndef UseElfFormat +-#define UseElfFormat DefaultToElfFormat +-#endif ++#define UseElfFormat YES + + #if UseElfFormat + #define OSBinaryFormat [ELF] +@@ -47,19 +45,10 @@ #define HasNdbm YES #define HasPutenv YES #define HasSnprintf YES @@ -22,7 +33,7 @@ #ifndef HasLibCrypt # define HasLibCrypt YES #endif -@@ -74,63 +65,28 @@ +@@ -74,63 +63,28 @@ #ifndef BuildPDFdocs # define BuildPDFdocs NO #endif @@ -94,7 +105,7 @@ #define AvoidNullMakeCommand YES #define StripInstalledPrograms YES -@@ -155,22 +111,9 @@ +@@ -155,22 +109,9 @@ #endif #ifndef HasMktemp @@ -117,7 +128,7 @@ #ifndef CcCmd #define CcCmd cc -@@ -195,41 +138,12 @@ +@@ -195,41 +136,12 @@ GccWarningOptions #endif #endif @@ -160,7 +171,7 @@ #endif /* -@@ -237,17 +151,14 @@ +@@ -237,17 +149,14 @@ * mechanism for specifying a subset of drivers in the OS.cf files yet. */ #ifndef BuildXF86DRI @@ -179,7 +190,7 @@ #define HasAgpGart YES #endif #if (defined(AlphaArchitecture) || defined(ia64Architecture) || \ -@@ -260,8 +171,7 @@ +@@ -260,8 +169,7 @@ * SSE and 3DNow will be autodetected, so binutils is the only * requirement for enabling this. By 4.2 they were all supported. */ @@ -189,7 +200,7 @@ # define HasX86Support YES # define HasMMXSupport YES # define Has3DNowSupport YES -@@ -311,8 +221,6 @@ +@@ -311,8 +219,6 @@ # define UseRpath YES #endif @@ -198,7 +209,7 @@ # ifndef RpathLoadFlags # if UseRpath # if UseElfFormat -@@ -333,7 +241,6 @@ +@@ -333,7 +239,6 @@ # endif # endif @@ -206,7 +217,7 @@ #ifndef LibraryRpathLoadFlags # if UseRpath -@@ -359,20 +266,13 @@ +@@ -359,20 +264,13 @@ #define GnuMallocLibrary -lgnumalloc #endif @@ -227,7 +238,7 @@ /* There are two options for building. One is to assume that the system has * many of the dependencies provided by the ports tree. The other is to just -@@ -449,7 +349,6 @@ +@@ -449,7 +347,6 @@ #define StandardDefines -DCSRG_BASED @@ -235,7 +246,7 @@ #define ServerOSDefines XFree86ServerOSDefines -DDDXTIME #define XawI18nDefines -DUSE_XWCHAR_STRING #define HasMakefileSafeInclude YES -@@ -462,17 +361,11 @@ +@@ -462,17 +359,11 @@ #define ForceNormalLib YES #endif #define HasMkstemp YES @@ -253,7 +264,7 @@ #ifdef i386Architecture # define OptimizedCDebugFlags DefaultGcc2i386Opt -@@ -507,9 +400,7 @@ +@@ -507,9 +398,7 @@ # define CompressManPages YES #endif @@ -263,7 +274,7 @@ #ifndef StaticLibrary #define StaticLibrary(libpath,libname) -Wl,-Bstatic Concat(-L,libpath) Concat(-l,libname) -Wl,-Bdynamic -@@ -561,13 +452,9 @@ +@@ -561,13 +450,9 @@ #ifndef HasCookieMaker /* Which versions have /dev/urandom? */ From laffer1 at midnightbsd.org Thu Jan 1 17:00:27 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 1 Jan 2009 17:00:27 -0500 (EST) Subject: [Midnightbsd-cvs] src: share/zoneinfo: 2008i Message-ID: <200901012200.n01M0RQM046333@stargazer.midnightbsd.org> Log Message: ----------- 2008i Modified Files: -------------- src/share/zoneinfo: MidnightBSD-upgrade (r1.3 -> r1.4) africa (r1.4 -> r1.5) asia (r1.4 -> r1.5) australasia (r1.4 -> r1.5) backward (r1.4 -> r1.5) europe (r1.4 -> r1.5) leapseconds (r1.4 -> r1.5) northamerica (r1.4 -> r1.5) southamerica (r1.4 -> r1.5) zone.tab (r1.4 -> r1.5) -------------- next part -------------- Index: australasia =================================================================== RCS file: /home/cvs/src/share/zoneinfo/australasia,v retrieving revision 1.4 retrieving revision 1.5 diff -L share/zoneinfo/australasia -L share/zoneinfo/australasia -u -r1.4 -r1.5 --- share/zoneinfo/australasia +++ share/zoneinfo/australasia @@ -1,4 +1,4 @@ -# @(#)australasia 8.8 +# @(#)australasia 8.9 #
 
 # This file also includes Pacific islands.
@@ -1346,7 +1346,7 @@
 # * Tonga will introduce DST in November
 #
 # I was given this link by John Letts:
-# 
+# 
 # http://news.bbc.co.uk/hi/english/world/asia-pacific/newsid_424000/424764.stm
 # 
 #
@@ -1356,7 +1356,7 @@
 # (12 + 1 hour DST).
 
 # From Arthur David Olson (1999-09-20):
-# According to 
 # http://www.tongaonline.com/news/sept1799.html
 # :
 # "Daylight Savings Time will take effect on Oct. 2 through April 15, 2000
Index: backward
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/backward,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/backward -L share/zoneinfo/backward -u -r1.4 -r1.5
--- share/zoneinfo/backward
+++ share/zoneinfo/backward
@@ -1,4 +1,4 @@
-# @(#)backward	8.4
+# @(#)backward	8.6
 
 # This file provides links between current names for time zones
 # and their old names.  Many names changed in late 1993.
@@ -24,8 +24,10 @@
 Link	Asia/Ashgabat		Asia/Ashkhabad
 Link	Asia/Chongqing		Asia/Chungking
 Link	Asia/Dhaka		Asia/Dacca
+Link	Asia/Kolkata		Asia/Calcutta
 Link	Asia/Macau		Asia/Macao
 Link	Asia/Jerusalem		Asia/Tel_Aviv
+Link	Asia/Ho_Chi_Minh	Asia/Saigon
 Link	Asia/Thimphu		Asia/Thimbu
 Link	Asia/Makassar		Asia/Ujung_Pandang
 Link	Asia/Ulaanbaatar	Asia/Ulan_Bator
Index: leapseconds
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/leapseconds,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/leapseconds -L share/zoneinfo/leapseconds -u -r1.4 -r1.5
--- share/zoneinfo/leapseconds
+++ share/zoneinfo/leapseconds
@@ -1,4 +1,4 @@
-# @(#)leapseconds	8.4
+# @(#)leapseconds	8.6
 
 # Allowance for leapseconds added to each timezone file.
 
@@ -44,8 +44,10 @@
 Leap	1997	Jun	30	23:59:60	+	S
 Leap	1998	Dec	31	23:59:60	+	S
 Leap	2005	Dec	31	23:59:60	+	S
+Leap	2008	Dec	31	23:59:60	+	S
 
 # INTERNATIONAL EARTH ROTATION AND REFERENCE SYSTEMS SERVICE (IERS)
+#
 # SERVICE INTERNATIONAL DE LA ROTATION TERRESTRE ET DES SYSTEMES DE REFERENCE
 #
 # SERVICE DE LA ROTATION TERRESTRE
@@ -53,30 +55,38 @@
 # 61, Av. de l'Observatoire 75014 PARIS (France)
 # Tel.      : 33 (0) 1 40 51 22 26
 # FAX       : 33 (0) 1 40 51 22 91
-# Internet  : services.iers at obspm.fr
+# e-mail    : services.iers at obspm.fr
+# http://hpiers.obspm.fr/eop-pc
 #
-# Paris, 28 June 2007
+# Paris, 4 July 2008
 #
-# Bulletin C 34
+# Bulletin C 36
 #
 # To authorities responsible
 # for the measurement and
 # distribution of time
 #
-# INFORMATION ON UTC - TAI
+# UTC TIME STEP
+# on the 1st of January 2009
+#
+# A positive leap second will be introduced at the end of December 2008.
+# The sequence of dates of the UTC second markers will be:		
+#
+# 2008 December 31,     23h 59m 59s
+# 2008 December 31,     23h 59m 60s
+# 2009 January   1,      0h  0m  0s
 #
-# NO positive leap second will be introduced at the end of December 2007.
-# The difference between Coordinated Universal Time UTC and the
-# International Atomic Time TAI is :		
+# The difference between UTC and the International Atomic Time TAI is:
 #
-# from 2006 January 1, 0h UTC, until further notice : UTC-TAI = -33 s
+# from 2006 January 1, 0h UTC, to 2009 January 1  0h UTC  : UTC-TAI = - 33s
+# from 2009 January 1, 0h UTC, until further notice       : UTC-TAI = - 34s
 #
 # Leap seconds can be introduced in UTC at the end of the months of December
-# or June,  depending on the evolution of UT1-TAI. Bulletin C is mailed every
-# six months, either to announce a time step in UTC, or to confirm that there
+# or June, depending on the evolution of UT1-TAI. Bulletin C is mailed every
+# six months, either to announce a time step in UTC or to confirm that there
 # will be no time step at the next possible date.
 #
 # Daniel GAMBIS
-# Director			
+# Head		
 # Earth Orientation Center of IERS
 # Observatoire de Paris, France
Index: zone.tab
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/zone.tab,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/zone.tab -L share/zoneinfo/zone.tab -u -r1.4 -r1.5
--- share/zoneinfo/zone.tab
+++ share/zoneinfo/zone.tab
@@ -1,4 +1,4 @@
-# @(#)zone.tab	8.13
+# @(#)zone.tab	8.21
 #
 # TZ zone descriptions
 #
@@ -42,13 +42,15 @@
 AQ	-6640+14001	Antarctica/DumontDUrville	Dumont-d'Urville Station, Terre Adelie
 AQ	-690022+0393524	Antarctica/Syowa	Syowa Station, E Ongul I
 AR	-3436-05827	America/Argentina/Buenos_Aires	Buenos Aires (BA, CF)
-AR	-3124-06411	America/Argentina/Cordoba	most locations (CB, CC, CN, ER, FM, LP, MN, NQ, RN, SA, SE, SF, SL)
+AR	-3124-06411	America/Argentina/Cordoba	most locations (CB, CC, CN, ER, FM, MN, SE, SF)
+AR	-2447-06525	America/Argentina/Salta	(SA, LP, NQ, RN)
 AR	-2411-06518	America/Argentina/Jujuy	Jujuy (JY)
 AR	-2649-06513	America/Argentina/Tucuman	Tucuman (TM)
 AR	-2828-06547	America/Argentina/Catamarca	Catamarca (CT), Chubut (CH)
 AR	-2926-06651	America/Argentina/La_Rioja	La Rioja (LR)
 AR	-3132-06831	America/Argentina/San_Juan	San Juan (SJ)
 AR	-3253-06849	America/Argentina/Mendoza	Mendoza (MZ)
+AR	-3319-06621	America/Argentina/San_Luis	San Luis (SL)
 AR	-5138-06913	America/Argentina/Rio_Gallegos	Santa Cruz (SC)
 AR	-5448-06818	America/Argentina/Ushuaia	Tierra del Fuego (TF)
 AS	-1416-17042	Pacific/Pago_Pago
@@ -91,7 +93,8 @@
 BR	-2332-04637	America/Sao_Paulo	S & SE Brazil (GO, DF, MG, ES, RJ, SP, PR, SC, RS)
 BR	-2027-05437	America/Campo_Grande	Mato Grosso do Sul
 BR	-1535-05605	America/Cuiaba	Mato Grosso
-BR	-0846-06354	America/Porto_Velho	W Para, Rondonia
+BR	-0226-05452	America/Santarem	W Para
+BR	-0846-06354	America/Porto_Velho	Rondonia
 BR	+0249-06040	America/Boa_Vista	Roraima
 BR	-0308-06001	America/Manaus	E Amazonas
 BR	-0640-06952	America/Eirunepe	W Amazonas
@@ -209,7 +212,7 @@
 IE	+5320-00615	Europe/Dublin
 IL	+3146+03514	Asia/Jerusalem
 IM	+5409-00428	Europe/Isle_of_Man
-IN	+2232+08822	Asia/Calcutta
+IN	+2232+08822	Asia/Kolkata
 IO	-0720+07225	Indian/Chagos
 IQ	+3321+04425	Asia/Baghdad
 IR	+3540+05126	Asia/Tehran
@@ -291,7 +294,7 @@
 NO	+5955+01045	Europe/Oslo
 NP	+2743+08519	Asia/Katmandu
 NR	-0031+16655	Pacific/Nauru
-NU	-1901+16955	Pacific/Niue
+NU	-1901-16955	Pacific/Niue
 NZ	-3652+17446	Pacific/Auckland	most locations
 NZ	-4357-17633	Pacific/Chatham	Chatham Islands
 OM	+2336+05835	Asia/Muscat
@@ -382,13 +385,13 @@
 US	+364947-0845057	America/Kentucky/Monticello	Eastern Time - Kentucky - Wayne County
 US	+394606-0860929	America/Indiana/Indianapolis	Eastern Time - Indiana - most locations
 US	+384038-0873143	America/Indiana/Vincennes	Eastern Time - Indiana - Daviess, Dubois, Knox & Martin Counties
-US	+411745-0863730	America/Indiana/Knox	Eastern Time - Indiana - Starke County
 US	+410305-0863611	America/Indiana/Winamac	Eastern Time - Indiana - Pulaski County
 US	+382232-0862041	America/Indiana/Marengo	Eastern Time - Indiana - Crawford County
+US	+382931-0871643	America/Indiana/Petersburg	Eastern Time - Indiana - Pike County
 US	+384452-0850402	America/Indiana/Vevay	Eastern Time - Indiana - Switzerland County
 US	+415100-0873900	America/Chicago	Central Time
 US	+375711-0864541	America/Indiana/Tell_City	Central Time - Indiana - Perry County
-US	+382931-0871643	America/Indiana/Petersburg	Central Time - Indiana - Pike County
+US	+411745-0863730	America/Indiana/Knox	Central Time - Indiana - Starke County
 US	+450628-0873651	America/Menominee	Central Time - Michigan - Dickinson, Gogebic, Iron & Menominee Counties
 US	+470659-1011757	America/North_Dakota/Center	Central Time - North Dakota - Oliver County
 US	+465042-1012439	America/North_Dakota/New_Salem	Central Time - North Dakota - Morton County (except Mandan area)
@@ -411,7 +414,7 @@
 VE	+1030-06656	America/Caracas
 VG	+1827-06437	America/Tortola
 VI	+1821-06456	America/St_Thomas
-VN	+1045+10640	Asia/Saigon
+VN	+1045+10640	Asia/Ho_Chi_Minh
 VU	-1740+16825	Pacific/Efate
 WF	-1318-17610	Pacific/Wallis
 WS	-1350-17144	Pacific/Apia
Index: africa
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/africa,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/africa -L share/zoneinfo/africa -u -r1.4 -r1.5
--- share/zoneinfo/africa
+++ share/zoneinfo/africa
@@ -1,4 +1,4 @@
-# @(#)africa	8.10
+# @(#)africa	8.17
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -387,9 +387,88 @@
 			 0:00	-	GMT
 
 # Mauritius
+
+# From Steffen Thorsen (2008-06-25):
+# Mauritius plans to observe DST from 2008-11-01 to 2009-03-31 on a trial
+# basis....
+# It seems that Mauritius observed daylight saving time from 1982-10-10 to 
+# 1983-03-20 as well, but that was not successful....
+# http://www.timeanddate.com/news/time/mauritius-daylight-saving-time.html
+
+# From Alex Krivenyshev (2008-06-25):
+# http://economicdevelopment.gov.mu/portal/site/Mainhomepage/menuitem.a42b24128104d9845dabddd154508a0c/?content_id=0a7cee8b5d69a110VgnVCM1000000a04a8c0RCRD
+
+# From Arthur David Olson (2008-06-30):
+# The www.timeanddate.com article cited by Steffen Thorsen notes that "A
+# final decision has yet to be made on the times that daylight saving
+# would begin and end on these dates." As a place holder, use midnight.
+
+# From Paul Eggert (2008-06-30):
+# Follow Thorsen on DST in 1982/1983, instead of Shanks & Pottenger.
+
+# From Steffen Thorsen (2008-07-10):
+# According to
+# 
+# http://www.lexpress.mu/display_article.php?news_id=111216
+# 
+# (in French), Mauritius will start and end their DST a few days earlier
+# than previously announced (2008-11-01 to 2009-03-31).  The new start
+# date is 2008-10-26 at 02:00 and the new end date is 2009-03-27 (no time
+# given, but it is probably at either 2 or 3 wall clock time).
+# 
+# A little strange though, since the article says that they moved the date 
+# to align itself with Europe and USA which also change time on that date, 
+# but that means they have not paid attention to what happened in 
+# USA/Canada last year (DST ends first Sunday in November). I also wonder 
+# why that they end on a Friday, instead of aligning with Europe which 
+# changes two days later.
+
+# From Alex Krivenyshev (2008-07-11):
+# Seems that English language article "The revival of daylight saving
+# time:  Energy conservation?"-# No. 16578 (07/11/2008) was originally
+# published on Monday, June 30, 2008...
+#
+# I guess that article in French "Le gouvernement avance l'introduction
+# de l'heure d'ete" stating that DST in Mauritius starting on October 26
+# and ending on March 27, 2009 is the most recent one.
+# ...
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_mauritius02.html
+# 
+
+# From Riad M. Hossen Ally (2008-08-03):
+# The Government of Mauritius weblink
+# 
+# http://www.gov.mu/portal/site/pmosite/menuitem.4ca0efdee47462e7440a600248a521ca/?content_id=3D4728ca68b2a5b110VgnVCM1000000a04a8c0RCRD
+# 
+# Cabinet Decision of July 18th, 2008 states as follows:
+#
+# 4. ...Cabinet has agreed to the introduction into the National Assembly
+# of the Time Bill which provides for the introduction of summer time in
+# Mauritius. The summer time period which will be of one hour ahead of
+# the standard time, will be aligned with that in Europe and the United
+# States of America. It will start at two o'clock in the morning on the
+# last Sunday of October and will end at two o'clock in the morning on
+# the last Sunday of March the following year. The summer time for the
+# year 2008 - 2009 will, therefore, be effective as from 26 October 2008
+# and end on 29 March 2009.
+
+# From Ed Maste (2008-10-07):
+# THE TIME BILL (No. XXVII of 2008) Explanatory Memorandum states the
+# beginning / ending of summer time is 2 o'clock standard time in the
+# morning of the last Sunday of October / last Sunday of March.
+# 
+# http://www.gov.mu/portal/goc/assemblysite/file/bill2708.pdf
+# 
+
+# Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
+Rule Mauritius	1982	only	-	Oct	10	0:00	1:00	S
+Rule Mauritius	1983	only	-	Mar	21	0:00	0	-
+Rule Mauritius	2008	max	-	Oct	lastSun	2:00s	1:00	S
+Rule Mauritius	2009	max	-	Mar	lastSun	2:00s	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone Indian/Mauritius	3:50:00 -	LMT	1907		# Port Louis
-			4:00	-	MUT	# Mauritius Time
+			4:00 Mauritius	MU%sT	# Mauritius Time
 # Agalega Is, Rodriguez
 # no information; probably like Indian/Mauritius
 
@@ -400,7 +479,93 @@
 
 # Morocco
 # See the `europe' file for Spanish Morocco (Africa/Ceuta).
+
+# From Alex Krivenyshev (2008-05-09):
+# Here is an article that Morocco plan to introduce Daylight Saving Time between
+# 1 June, 2008 and 27 September, 2008.
+#
+# "... Morocco is to save energy by adjusting its clock during summer so it will
+# be one hour ahead of GMT between 1 June and 27 September, according to
+# Communication Minister and Gov ernment Spokesman, Khalid Naciri...."
+#
+# 
+# http://www.worldtimezone.net/dst_news/dst_news_morocco01.html
+# 
+# OR
+# 
+# http://en.afrik.com/news11892.html
+# 
+
+# From Alex Krivenyshev (2008-05-09):
+# The Morocco time change can be confirmed on Morocco web site Maghreb Arabe Presse:
+# 
+# http://www.map.ma/eng/sections/box3/morocco_shifts_to_da/view
+# 
+#
+# Morocco shifts to daylight time on June 1st through September 27, Govt.
+# spokesman.
+
+# From Patrice Scattolin (2008-05-09):
+# According to this article:
+# 
+# http://www.avmaroc.com/actualite/heure-dete-comment-a127896.html
+# 
+# (and republished here:
+# 
+# http://www.actu.ma/heure-dete-comment_i127896_0.html
+# 
+# )
+# the changes occurs at midnight:
+#
+# saturday night may 31st at midnight (which in french is to be
+# intrepreted as the night between saturday and sunday)
+# sunday night the 28th  at midnight
+#
+# Seeing that the 28th is monday, I am guessing that she intends to say
+# the midnight of the 28th which is the midnight between sunday and
+# monday, which jives with other sources that say that it's inclusive
+# june1st to sept 27th.
+#
+# The decision was taken by decree *2-08-224 *but I can't find the decree
+# published on the web.
+#
+# It's also confirmed here:
+# 
+# http://www.maroc.ma/NR/exeres/FACF141F-D910-44B0-B7FA-6E03733425D1.htm
+# 
+# on a government portal as being  between june 1st and sept 27th (not yet
+# posted in english).
+#
+# The following google query will generate many relevant hits:
+# 
+# http://www.google.com/search?hl=en&q=Conseil+de+gouvernement+maroc+heure+avance&btnG=Search
+# 
+
+# From Alex Krivenyshev (2008-05-09):
+# Is Western Sahara (part which administrated by Morocco) going to follow
+# Morocco DST changes?  Any information?  What about other part of
+# Western Sahara - under administration of POLISARIO Front (also named
+# SADR Saharawi Arab Democratic Republic)?
+
+# From Arthur David Olson (2008-05-09):
+# XXX--guess that it is only Morocco for now; guess only 2008 for now.
+
+# From Steffen Thorsen (2008-08-27):
+# Morocco will change the clocks back on the midnight between August 31 
+# and September 1. They originally planned to observe DST to near the end 
+# of September:
+#
+# One article about it (in French):
+# 
+# http://www.menara.ma/fr/Actualites/Maroc/Societe/ci.retour_a_l_heure_gmt_a_partir_du_dimanche_31_aout_a_minuit_officiel_.default
+# 
+#
+# We have some further details posted here:
+# 
+# http://www.timeanddate.com/news/time/morocco-ends-dst-early-2008.html
+# 
 # RULE	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
+
 Rule	Morocco	1939	only	-	Sep	12	 0:00	1:00	S
 Rule	Morocco	1939	only	-	Nov	19	 0:00	0	-
 Rule	Morocco	1940	only	-	Feb	25	 0:00	1:00	S
@@ -416,11 +581,13 @@
 Rule	Morocco	1977	only	-	Sep	28	 0:00	0	-
 Rule	Morocco	1978	only	-	Jun	 1	 0:00	1:00	S
 Rule	Morocco	1978	only	-	Aug	 4	 0:00	0	-
+Rule	Morocco	2008	only	-	Jun	 1	 0:00	1:00	S
+Rule	Morocco	2008	only	-	Sep	 1	 0:00	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone Africa/Casablanca	-0:30:20 -	LMT	1913 Oct 26
 			 0:00	Morocco	WE%sT	1984 Mar 16
 			 1:00	-	CET	1986
-			 0:00	-	WET
+			 0:00	Morocco	WE%sT
 # Western Sahara
 Zone Africa/El_Aaiun	-0:52:48 -	LMT	1934 Jan
 			-1:00	-	WAT	1976 Apr 14
Index: MidnightBSD-upgrade
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/MidnightBSD-upgrade,v
retrieving revision 1.3
retrieving revision 1.4
diff -L share/zoneinfo/MidnightBSD-upgrade -L share/zoneinfo/MidnightBSD-upgrade -u -r1.3 -r1.4
--- share/zoneinfo/MidnightBSD-upgrade
+++ share/zoneinfo/MidnightBSD-upgrade
@@ -18,6 +18,6 @@
 
 __
 
-Last updated with tzdata2007k
+Last updated with tzdata2008i
 
 $MidnightBSD$
Index: southamerica
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/southamerica,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/southamerica -L share/zoneinfo/southamerica -u -r1.4 -r1.5
--- share/zoneinfo/southamerica
+++ share/zoneinfo/southamerica
@@ -1,4 +1,4 @@
-# @(#)southamerica	8.15
+# @(#)southamerica	8.33
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -164,9 +164,58 @@
 # From Paul Eggert (2007-12-22):
 # For dates after mid-2008, the following rules are my guesses and
 # are quite possibly wrong, but are more likely than no DST at all.
+
+# From Alexander Krivenyshev (2008-09-05):
+# As per message from Carlos Alberto Fonseca Arauz (Nicaragua),
+# Argentina will start DST on Sunday October 19, 2008.
+#
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_argentina03.html
+# 
+# OR
+# 
+# http://www.impulsobaires.com.ar/nota.php?id=57832 (in spanish)
+# 
+
+# From Rodrigo Severo (2008-10-06):
+# Here is some info available at a Gentoo bug related to TZ on Argentina's DST:
+# ...
+# ------- Comment #1 from [jmdocile]  2008-10-06 16:28 0000 -------
+# Hi, there is a problem with timezone-data-2008e and maybe with
+# timezone-data-2008f
+# Argentinian law [Number] 25.155 is no longer valid.
+# 
+# http://www.infoleg.gov.ar/infolegInternet/anexos/60000-64999/60036/norma.htm
+# 
+# The new one is law [Number] 26.350
+# 
+# http://www.infoleg.gov.ar/infolegInternet/anexos/135000-139999/136191/norma.htm
+# 
+# So there is no summer time in Argentina for now.
+
+# From Mariano Absatz (2008-10-20):
+# Decree 1693/2008 applies Law 26.350 for the summer 2008/2009 establishing DST in Argentina
+# From 2008-10-19 until 2009-03-15
+# 
+# http://www.boletinoficial.gov.ar/Bora.Portal/CustomControls/PdfContent.aspx?fp=16102008&pi=3&pf=4&s=0&sec=01
+# 
+#
+# Decree 1705/2008 excepting 12 Provinces from applying DST in the summer 2008/2009:
+# Catamarca, La Rioja, Mendoza, Salta, San Juan, San Luis, La Pampa, Neuquen, Rio Negro, Chubut, Santa Cruz
+# and Tierra del Fuego
+# 
+# http://www.boletinoficial.gov.ar/Bora.Portal/CustomControls/PdfContent.aspx?fp=17102008&pi=1&pf=1&s=0&sec=01
+# 
+#
+# Press release 235 dated Saturday October 18th, from the Government of the Province of Jujuy saying
+# it will not apply DST either (even when it was not included in Decree 1705/2008)
+# 
+# http://www.jujuy.gov.ar/index2/partes_prensa/18_10_08/235-181008.doc
+# 
+
 Rule	Arg	2007	only	-	Dec	30	0:00	1:00	S
 Rule	Arg	2008	max	-	Mar	Sun>=15	0:00	0	-
-Rule	Arg	2008	max	-	Oct	Sun>=1	0:00	1:00	S
+Rule	Arg	2008	max	-	Oct	Sun>=15	0:00	1:00	S
  
 # From Mariano Absatz (2004-05-21):
 # Today it was officially published that the Province of Mendoza is changing
@@ -228,10 +277,80 @@
 # http://www.sanjuan.gov.ar/prensa/archivo/000426.html
 # http://www.sanjuan.gov.ar/prensa/archivo/000441.html
 
+# From Alex Krivenyshev (2008-01-17):
+# Here are articles that Argentina Province San Luis is planning to end DST
+# as earlier as upcoming Monday January 21, 2008 or February 2008:
+#
+# Provincia argentina retrasa reloj y marca diferencia con resto del pais
+# (Argentine Province delayed clock and mark difference with the rest of the
+# country)
+# 
+# http://cl.invertia.com/noticias/noticia.aspx?idNoticia=200801171849_EFE_ET4373&idtel
+# 
+#
+# Es inminente que en San Luis atrasen una hora los relojes
+# (It is imminent in San Luis clocks one hour delay)
+# 
+# http://www.lagaceta.com.ar/vernotae.asp?id_nota=253414
+# 
+#
+# 
+# http://www.worldtimezone.net/dst_news/dst_news_argentina02.html
+# 
+
+# From Jesper Norgaard Welen (2008-01-18):
+# The page of the San Luis provincial government
+# 
+# http://www.sanluis.gov.ar/notas.asp?idCanal=0&id=22812
+# 
+# confirms what Alex Krivenyshev has earlier sent to the tz
+# emailing list about that San Luis plans to return to standard
+# time much earlier than the rest of the country. It also
+# confirms that upon request the provinces San Juan and Mendoza 
+# refused to follow San Luis in this change. 
+# 
+# The change is supposed to take place Monday the 21.st at 0:00
+# hours. As far as I understand it if this goes ahead, we need
+# a new timezone for San Luis (although there are also documented
+# independent changes in the southamerica file of San Luis in
+# 1990 and 1991 which has not been confirmed).
+
+# From Jesper Norgaard Welen (2008-01-25):
+# Unfortunately the below page has become defunct, about the San Luis
+# time change. Perhaps because it now is part of a group of pages "Most
+# important pages of 2008."
+#
+# You can use
+# 
+# http://www.sanluis.gov.ar/notas.asp?idCanal=8141&id=22834
+# 
+# instead it seems. Or use "Buscador" from the main page of the San Luis
+# government, and fill in "huso" and click OK, and you will get 3 pages
+# from which the first one is identical to the above.
+
+# From Mariano Absatz (2008-01-28):
+# I can confirm that the Province of San Luis (and so far only that
+# province) decided to go back to UTC-3 effective midnight Jan 20th 2008
+# (that is, Monday 21st at 0:00 is the time the clocks were delayed back
+# 1 hour), and they intend to keep UTC-3 as their timezone all year round
+# (that is, unless they change their mind any minute now).
+#
+# So we'll have to add yet another city to 'southamerica' (I think San
+# Luis city is the mos populated city in the Province, so it'd be
+# America/Argentina/San_Luis... of course I can't remember if San Luis's
+# history of particular changes goes along with Mendoza or San Juan :-(
+# (I only remember not being able to collect hard facts about San Luis
+# back in 2004, when these provinces changed to UTC-4 for a few days, I
+# mailed them personally and never got an answer).
+
+# From Paul Eggert (2008-06-30):
 # Unless otherwise specified, data are from Shanks & Pottenger through 1992,
 # from the IATA otherwise.  As noted below, Shanks & Pottenger say that
-# America/Cordoba split into 6 subregions during 1991/1992, but we
-# haven't verified this yet so for now we'll keep it a single region.
+# America/Cordoba split into 6 subregions during 1991/1992, one of which
+# was America/San_Luis, but we haven't verified this yet so for now we'll
+# keep America/Cordoba a single region rather than splitting it into the
+# other 5 subregions.
+
 #
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 #
@@ -244,16 +363,13 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	Arg	AR%sT
 #
-# Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN), Chaco (CC),
-# Formosa (FM), Salta (SA), Santiago del Estero (SE), Cordoba (CB),
-# San Luis (SL), La Pampa (LP), Neuquen (NQ), Rio Negro (RN)
+# Cordoba (CB), Santa Fe (SF), Entre Rios (ER), Corrientes (CN), Misiones (MN),
+# Chaco (CC), Formosa (FM), Santiago del Estero (SE)
 #
 # Shanks & Pottenger also make the following claims, which we haven't verified:
 # - Formosa switched to -3:00 on 1991-01-07.
 # - Misiones switched to -3:00 on 1990-12-29.
 # - Chaco switched to -3:00 on 1991-01-04.
-# - San Luis switched to -4:00 on 1990-03-14, then to -3:00 on 1990-10-15,
-#   then to -4:00 on 1991-03-01, then to -3:00 on 1991-06-01.
 # - Santiago del Estero switched to -4:00 on 1991-04-01,
 #   then to -3:00 on 1991-04-26.
 #
@@ -267,6 +383,18 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	Arg	AR%sT
 #
+# Salta (SA), La Pampa (LP), Neuquen (NQ), Rio Negro (RN)
+Zone America/Argentina/Salta -4:21:40 - LMT	1894 Oct 31
+			-4:16:48 -	CMT	1920 May
+			-4:00	-	ART	1930 Dec
+			-4:00	Arg	AR%sT	1969 Oct  5
+			-3:00	Arg	AR%sT	1991 Mar  3
+			-4:00	-	WART	1991 Oct 20
+			-3:00	Arg	AR%sT	1999 Oct  3
+			-4:00	Arg	AR%sT	2000 Mar  3
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
+#
 # Tucuman (TM)
 Zone America/Argentina/Tucuman -4:20:52 - LMT	1894 Oct 31
 			-4:16:48 -	CMT	1920 May
@@ -291,7 +419,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 Jun  1
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # San Juan (SJ)
 Zone America/Argentina/San_Juan -4:34:04 - LMT	1894 Oct 31
@@ -304,7 +433,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 May 31
 			-4:00	-	WART	2004 Jul 25
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Jujuy (JY)
 Zone America/Argentina/Jujuy -4:21:12 -	LMT	1894 Oct 31
@@ -318,7 +448,8 @@
 			-3:00	1:00	ARST	1992
 			-3:00	Arg	AR%sT	1999 Oct  3
 			-4:00	Arg	AR%sT	2000 Mar  3
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Catamarca (CT), Chubut (CH)
 Zone America/Argentina/Catamarca -4:23:08 - LMT	1894 Oct 31
@@ -331,7 +462,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 Jun  1
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Mendoza (MZ)
 Zone America/Argentina/Mendoza -4:35:16 - LMT	1894 Oct 31
@@ -348,7 +480,25 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 May 23
 			-4:00	-	WART	2004 Sep 26
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
+#
+# San Luis (SL)
+Zone America/Argentina/San_Luis -4:25:24 - LMT	1894 Oct 31
+			-4:16:48 -	CMT	1920 May
+			-4:00	-	ART	1930 Dec
+			-4:00	Arg	AR%sT	1969 Oct  5
+			-3:00	Arg	AR%sT	1990
+			-3:00	1:00	ARST	1990 Mar 14
+			-4:00	-	WART	1990 Oct 15
+			-4:00	1:00	WARST	1991 Mar  1
+			-4:00	-	WART	1991 Jun  1
+			-3:00	-	ART	1999 Oct  3
+			-4:00	1:00	WARST	2000 Mar  3
+			-3:00	-	ART	2004 May 31
+			-4:00	-	WART	2004 Jul 25
+			-3:00	Arg	AR%sT	2008 Jan 21
+			-3:00	-	ART
 #
 # Santa Cruz (SC)
 Zone America/Argentina/Rio_Gallegos -4:36:52 - LMT 1894 Oct 31
@@ -359,7 +509,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 Jun  1
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 #
 # Tierra del Fuego, Antartida e Islas del Atlantico Sur (TF)
 Zone America/Argentina/Ushuaia -4:33:12 - LMT 1894 Oct 31
@@ -370,7 +521,8 @@
 			-4:00	Arg	AR%sT	2000 Mar  3
 			-3:00	-	ART	2004 May 30
 			-4:00	-	WART	2004 Jun 20
-			-3:00	Arg	AR%sT
+			-3:00	Arg	AR%sT	2008 Oct 18
+			-3:00	-	ART
 
 # Aruba
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
@@ -456,12 +608,86 @@
 # Brazil will start DST on 2007-10-14 00:00 and end on 2008-02-17 00:00:
 # http://www.mme.gov.br/site/news/detail.do;jsessionid=BBA06811AFCAAC28F0285210913513DA?newsId=13975
 
+# From Paul Schulze (2008-06-24):
+# ...by law number 11.662 of April 24, 2008 (published in the "Diario
+# Oficial da Uniao"...) in Brazil there are changes in the timezones,
+# effective today (00:00am at June 24, 2008) as follows:
+#
+# a) The timezone UTC+5 is e[x]tinguished, with all the Acre state and the
+# part of the Amazonas state that had this timezone now being put to the
+# timezone UTC+4
+# b) The whole Para state now is put at timezone UTC+3, instead of just
+# part of it, as was before.
+#
+# This change follows a proposal of senator Tiao Viana of Acre state, that
+# proposed it due to concerns about open television channels displaying
+# programs inappropriate to youths in the states that had the timezone
+# UTC+5 too early in the night. In the occasion, some more corrections
+# were proposed, trying to unify the timezones of any given state. This
+# change modifies timezone rules defined in decree 2.784 of 18 June,
+# 1913.
+
+# From Rodrigo Severo (2008-06-24):
+# Just correcting the URL:
+# 
+# https://www.in.gov.br/imprensa/visualiza/index.jsp?jornal=3Ddo&secao=3D1&pagina=3D1&data=3D25/04/2008
+# 
+#
+# As a result of the above Decree I believe the America/Rio_Branco
+# timezone shall be modified from UTC-5 to UTC-4 and a new timezone shall
+# be created to represent the the west side of the Para State. I
+# suggest this new timezone be called Santarem as the most
+# important/populated city in the affected area.
+#
+# This new timezone would be the same as the Rio_Branco timezone up to
+# the 2008/06/24 change which would be to UTC-3 instead of UTC-4.
+
+# From Alex Krivenyshev (2008-06-24):
+# This is a quick reference page for New and Old Brazil Time Zones map.
+# 
+# http://www.worldtimezone.com/brazil-time-new-old.php
+# 
+#
+# - 4 time zones replaced by 3 time zones-eliminating time zone UTC- 05
+# (state Acre and the part of the Amazonas will be UTC/GMT- 04) - western
+# part of Par state is moving to one timezone UTC- 03 (from UTC -04).
+
 # From Paul Eggert (2002-10-10):
 # The official decrees referenced below are mostly taken from
 # 
 # Decretos sobre o Horario de Verao no Brasil
 # .
 
+# From Steffen Thorsen (2008-08-29):
+# As announced by the government and many newspapers in Brazil late
+# yesterday, Brazil will start DST on 2008-10-19 (need to change rule) and
+# it will end on 2009-02-15 (current rule for Brazil is fine). Based on
+# past years experience with the elections, there was a good chance that
+# the start was postponed to November, but it did not happen this year.
+#
+# It has not yet been posted to http://pcdsh01.on.br/DecHV.html
+#
+# An official page about it:
+# 
+# http://www.mme.gov.br/site/news/detail.do?newsId=16722
+# 
+# Note that this link does not always work directly, but must be accessed
+# by going to
+# 
+# http://www.mme.gov.br/first
+# 
+#
+# One example link that works directly:
+# 
+# http://jornale.com.br/index.php?option=com_content&task=view&id=13530&Itemid=54
+# (Portuguese)
+# 
+#
+# We have a written a short article about it as well:
+# 
+# http://www.timeanddate.com/news/time/brazil-dst-2008-2009.html
+# 
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 # Decree 20,466 (1931-10-01)
 # Decree 21,896 (1932-01-10)
@@ -578,13 +804,13 @@
 Rule	Brazil	2000	2001	-	Oct	Sun>=8	 0:00	1:00	S
 Rule	Brazil	2001	2006	-	Feb	Sun>=15	 0:00	0	-
 # Decree 4,399 (2002-10-01) repeals DST in AL, CE, MA, PB, PE, PI, RN, SE.
-# 
+# 4,399
 Rule	Brazil	2002	only	-	Nov	 3	 0:00	1:00	S
 # Decree 4,844 (2003-09-24; corrected 2003-09-26) repeals DST in BA, MT, TO.
-# 
+# 4,844
 Rule	Brazil	2003	only	-	Oct	19	 0:00	1:00	S
 # Decree 5,223 (2004-10-01) reestablishes DST in MT.
-# 
+# 5,223
 Rule	Brazil	2004	only	-	Nov	 2	 0:00	1:00	S
 # Decree 5,539 (2005-09-19),
 # adopted by the same states as before.
@@ -593,16 +819,36 @@
 # adopted by the same states as before.
 Rule	Brazil	2006	only	-	Nov	 5	 0:00	1:00	S
 Rule	Brazil	2007	only	-	Feb	25	 0:00	0	-
-# (Decree number not yet known)
-# http://www.brasil.gov.br/noticias/ultimas_noticias/horario_verao070920/
-# (2007-09-20) after a heads-up from Steffen Thorsen:
-Rule	Brazil	2007	max	-	Oct	Sun>=8	 0:00	1:00	S
-Rule	Brazil	2008	max	-	Feb	Sun>=15	 0:00	0	-
+# Decree 6,212 (2007-09-26),
+# adopted by the same states as before.
+Rule	Brazil	2007	only	-	Oct	Sun>=8	 0:00	1:00	S
+# From Frederico A. C. Neves (2008-09-10):
+# Acording to this decree
+# 
+# http://www.planalto.gov.br/ccivil_03/_Ato2007-2010/2008/Decreto/D6558.htm
+# 
+# [t]he DST period in Brazil now on will be from the 3rd Oct Sunday to the
+# 3rd Feb Sunday. There is an exception on the return date when this is
+# the Carnival Sunday then the return date will be the next Sunday...
+Rule	Brazil	2008	max	-	Oct	Sun>=15	0:00	1:00	S
+Rule	Brazil	2008	2011	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2012	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2013	2014	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2015	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2016	2022	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2023	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2024	2025	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2026	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2027	2033	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2034	only	-	Feb	Sun>=22	0:00	0	-
+Rule	Brazil	2035	2036	-	Feb	Sun>=15	0:00	0	-
+Rule	Brazil	2037	only	-	Feb	Sun>=22	0:00	0	-
+# From Arthur David Olson (2008-09-29):
+# The next is wrong in some years but is better than nothing.
+Rule	Brazil	2038	max	-	Feb	Sun>=15	0:00	0	-
+
 # The latest ruleset listed above says that the following states observe DST:
 # DF, ES, GO, MG, MS, MT, PR, RJ, RS, SC, SP.
-# For dates after mid-2008, the above rules with TO="max" are guesses
-# and are quite possibly wrong, but are more likely than no DST at all.
-
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 #
@@ -629,6 +875,13 @@
 			-3:00	Brazil	BR%sT	1988 Sep 12
 			-3:00	-	BRT
 #
+# west Para (PA)
+# West Para includes Altamira, Oribidos, Prainha, Oriximina, and Santarem.
+Zone America/Santarem	-3:38:48 -	LMT	1914
+			-4:00	Brazil	AM%sT	1988 Sep 12
+			-4:00	-	AMT	2008 Jun 24 00:00
+			-3:00	-	BRT
+#
 # Maranhao (MA), Piaui (PI), Ceara (CE), Rio Grande do Norte (RN),
 # Paraiba (PB)
 Zone America/Fortaleza	-2:34:00 -	LMT	1914
@@ -691,8 +944,7 @@
 			-4:00	-	AMT	2004 Oct  1
 			-4:00	Brazil	AM%sT
 #
-# west Para (PA), Rondonia (RO)
-# West Para includes Altamira, Oribidos, Prainha, Oriximina, and Santarem.
+# Rondonia (RO)
 Zone America/Porto_Velho -4:15:36 -	LMT	1914
 			-4:00	Brazil	AM%sT	1988 Sep 12
 			-4:00	-	AMT
@@ -719,13 +971,14 @@
 			-5:00	Brazil	AC%sT	1988 Sep 12
 			-5:00	-	ACT	1993 Sep 28
 			-5:00	Brazil	AC%sT	1994 Sep 22
-			-5:00	-	ACT
+			-5:00	-	ACT	2008 Jun 24 00:00
+			-4:00	-	AMT
 #
 # Acre (AC)
 Zone America/Rio_Branco	-4:31:12 -	LMT	1914
 			-5:00	Brazil	AC%sT	1988 Sep 12
-			-5:00	-	ACT
-
+			-5:00	-	ACT	2008 Jun 24 00:00
+			-4:00	-	AMT
 
 # Chile
 
@@ -759,6 +1012,26 @@
 # America/Santiago.  The pre-1980 Pacific/Easter data are dubious,
 # but we have no other source.
 
+# From German Poo-Caaman~o (2008-03-03):
+# Due to drought, Chile extends Daylight Time in three weeks.  This
+# is one-time change (Saturday 3/29 at 24:00 for America/Santiago
+# and Saturday 3/29 at 22:00 for Pacific/Easter)
+# The Supreme Decree is located at 
+# 
+# http://www.shoa.cl/servicios/supremo316.pdf
+# 
+# and the instructions for 2008 are located in:
+# 
+# http://www.horaoficial.cl/cambio.htm
+# .
+
+# From Jose Miguel Garrido (2008-03-05):
+# ...
+# You could see the announces of the change on 
+# 
+# http://www.shoa.cl/noticias/2008/04hora/hora.htm
+# .
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Chile	1927	1932	-	Sep	 1	0:00	1:00	S
 Rule	Chile	1928	1932	-	Apr	 1	0:00	0	-
@@ -789,7 +1062,11 @@
 Rule	Chile	1998	only	-	Sep	27	4:00u	1:00	S
 Rule	Chile	1999	only	-	Apr	 4	3:00u	0	-
 Rule	Chile	1999	max	-	Oct	Sun>=9	4:00u	1:00	S
-Rule	Chile	2000	max	-	Mar	Sun>=9	3:00u	0	-
+Rule	Chile	2000	2007	-	Mar	Sun>=9	3:00u	0	-
+# N.B.: the end of March 29 in Chile is March 30 in Universal time,
+# which is used below in specifying the transition.
+Rule	Chile	2008	only	-	Mar	30	3:00u	0	-
+Rule	Chile	2009	max	-	Mar	Sun>=9	3:00u	0	-
 # IATA SSIM anomalies: (1992-02) says 1992-03-14;
 # (1996-09) says 1998-03-08.  Ignore these.
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
Index: asia
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/asia,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/asia -L share/zoneinfo/asia -u -r1.4 -r1.5
--- share/zoneinfo/asia
+++ share/zoneinfo/asia
@@ -1,4 +1,4 @@
-# @(#)asia	8.14
+# @(#)asia	8.24
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -229,6 +229,28 @@
 # (could be true), for the moment I am assuming that those two
 # counties are mistakes in the astro.com data.
 
+# From Paul Eggert (2008-02-11):
+# I just now checked Google News for western news sources that talk
+# about China's single time zone, and couldn't find anything before 1986
+# talking about China being in one time zone.  (That article was: Jim
+# Mann, "A clumsy embrace for another western custom: China on daylight
+# time--sort of", Los Angeles Times, 1986-05-05.  By the way, this
+# article confirms the tz database's data claiming that China began
+# observing daylight saving time in 1986.
+#
+# From Thomas S. Mullaney (2008-02-11):
+# I think you're combining two subjects that need to treated 
+# separately: daylight savings (which, you're correct, wasn't 
+# implemented until the 1980s) and the unified time zone centered near 
+# Beijing (which was implemented in 1949). Briefly, there was also a 
+# "Lhasa Time" in Tibet and "Urumqi Time" in Xinjiang. The first was 
+# ceased, and the second eventually recognized (again, in the 1980s).
+#
+# From Paul Eggert (2008-06-30):
+# There seems to be a good chance China switched to a single time zone in 1949
+# rather than in 1980 as Shanks & Pottenger have it, but we don't have a
+# reliable documentary source saying so yet, so for now we still go with
+# Shanks & Pottenger.
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 # Changbai Time ("Long-white Time", Long-white = Heilongjiang area)
@@ -446,13 +468,13 @@
 
 # India
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Calcutta	5:53:28 -	LMT	1880	# Kolkata
+Zone	Asia/Kolkata	5:53:28 -	LMT	1880	# Kolkata
 			5:53:20	-	HMT	1941 Oct    # Howrah Mean Time?
 			6:30	-	BURT	1942 May 15 # Burma Time
 			5:30	-	IST	1942 Sep
 			5:30	1:00	IST	1945 Oct 15
 			5:30	-	IST
-# The following are like Asia/Calcutta:
+# The following are like Asia/Kolkata:
 #	Andaman Is
 #	Lakshadweep (Laccadive, Minicoy and Amindivi Is)
 #	Nicobar Is
@@ -660,6 +682,21 @@
 #
 # So we'll ignore the Economist's claim.
 
+# From Steffen Thorsen (2008-03-10):
+# The cabinet in Iraq abolished DST last week, according to the following
+# news sources (in Arabic):
+# 
+# http://www.aljeeran.net/wesima_articles/news-20080305-98602.html
+# 
+# 
+# http://www.aswataliraq.info/look/article.tpl?id=2047&IdLanguage=17&IdPublication=4&NrArticle=71743&NrIssue=1&NrSection=10
+# 
+#
+# We have published a short article in English about the change:
+# 
+# http://www.timeanddate.com/news/time/iraq-dumps-daylight-saving.html
+# 
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Iraq	1982	only	-	May	1	0:00	1:00	D
 Rule	Iraq	1982	1984	-	Oct	1	0:00	0	S
@@ -670,8 +707,8 @@
 # IATA SSIM (1991/1996) says Apr 1 12:01am UTC; guess the `:01' is a typo.
 # Shanks & Pottenger say Iraq did not observe DST 1992/1997; ignore this.
 #
-Rule	Iraq	1991	max	-	Apr	 1	3:00s	1:00	D
-Rule	Iraq	1991	max	-	Oct	 1	3:00s	0	S
+Rule	Iraq	1991	2007	-	Apr	 1	3:00s	1:00	D
+Rule	Iraq	1991	2007	-	Oct	 1	3:00s	0	S
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Baghdad	2:57:40	-	LMT	1890
 			2:57:36	-	BMT	1918	    # Baghdad Mean Time?
@@ -1361,6 +1398,42 @@
 # They decided not to adopt daylight-saving time....
 # http://www.mongolnews.mn/index.php?module=unuudur&sec=view&id=15742
 
+# From Deborah Goldsmith (2008-03-30):
+# We received a bug report claiming that the tz database UTC offset for
+# Asia/Choibalsan (GMT+09:00) is incorrect, and that it should be GMT
+# +08:00 instead. Different sources appear to disagree with the tz
+# database on this, e.g.:
+#
+# 
+# http://www.timeanddate.com/worldclock/city.html?n=1026
+# 
+# 
+# http://www.worldtimeserver.com/current_time_in_MN.aspx
+# 
+#
+# both say GMT+08:00.
+
+# From Steffen Thorsen (2008-03-31):
+# eznis airways, which operates several domestic flights, has a flight
+# schedule here:
+# 
+# http://www.eznis.com/Container.jsp?id=112
+# 
+# (click the English flag for English)
+#
+# There it appears that flights between Choibalsan and Ulaanbatar arrive
+# about 1:35 - 1:50 hours later in local clock time, no matter the
+# direction, while Ulaanbaatar-Khvod takes 2 hours in the Eastern
+# direction and 3:35 back, which indicates that Ulaanbatar and Khvod are
+# in different time zones (like we know about), while Choibalsan and
+# Ulaanbatar are in the same time zone (correction needed).
+
+# From Arthur David Olson (2008-05-19):
+# Assume that Choibalsan is indeed offset by 8:00.
+# XXX--in the absence of better information, assume that transition
+# was at the start of 2008-03-31 (the day of Steffen Thorsen's report);
+# this is almost surely wrong.
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Mongol	1983	1984	-	Apr	1	0:00	1:00	S
 Rule	Mongol	1983	only	-	Oct	1	0:00	0	-
@@ -1396,7 +1469,8 @@
 Zone	Asia/Choibalsan	7:38:00 -	LMT	1905 Aug
 			7:00	-	ULAT	1978
 			8:00	-	ULAT	1983 Apr
-			9:00	Mongol	CHO%sT	# Choibalsan Time
+			9:00	Mongol	CHO%sT	2008 Mar 31 # Choibalsan Time
+			8:00	Mongol	CHO%sT
 
 # Nepal
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
@@ -1446,10 +1520,45 @@
 # The minister told a news conference that the experiment had rather
 # shown 8 per cent higher consumption of electricity.
 
+# From Alex Krivenyshev (2008-05-15):
+# 
+# Here is an article that Pakistan plan to introduce Daylight Saving Time 
+# on June 1, 2008 for 3 months.
+# 
+# "... The federal cabinet on Wednesday announced a new conservation plan to help 
+# reduce load shedding by approving the closure of commercial centres at 9pm and 
+# moving clocks forward by one hour for the next three months. 
+# ...."
+# 
+# 
+# http://www.worldtimezone.net/dst_news/dst_news_pakistan01.html
+# 
+# OR
+# 
+# http://www.dailytimes.com.pk/default.asp?page=2008%5C05%5C15%5Cstory_15-5-2008_pg1_4
+# 
+
+# From Arthur David Olson (2008-05-19):
+# XXX--midnight transitions is a guess; 2008 only is a guess.
+
+# From Alexander Krivenyshev (2008-08-28):
+# Pakistan government has decided to keep the watches one-hour advanced
+# for another 2 months--plan to return to Standard Time on October 31
+# instead of August 31.
+#
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_pakistan02.html
+# 
+# OR
+# 
+# http://dailymailnews.com/200808/28/news/dmbrn03.html
+# 
 
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule Pakistan	2002	only	-	Apr	Sun>=2	0:01	1:00	S
 Rule Pakistan	2002	only	-	Oct	Sun>=2	0:01	0	-
+Rule Pakistan	2008	only	-	Jun	1	0:00	1:00	S
+Rule Pakistan	2008	only	-	Nov	1	0:00	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Karachi	4:28:12 -	LMT	1907
 			5:30	-	IST	1942 Sep
@@ -1569,6 +1678,23 @@
 # For lack of better information, predict that future changes will be
 # the 2nd Thursday of September at 02:00.
 
+# From Alexander Krivenyshev (2008-08-28):
+# Here is an article, that Mideast running on different clocks at Ramadan.
+#
+# Gaza Strip (as Egypt) ended DST at midnight Thursday (Aug 28, 2008), while
+# the West Bank will end Daylight Saving Time at midnight Sunday (Aug 31, 2008).
+#
+# 
+# http://www.guardian.co.uk/world/feedarticle/7759001
+# 
+# 
+# http://www.abcnews.go.com/International/wireStory?id=5676087
+# 
+# or
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_gazastrip01.html
+# 
+
 # The rules for Egypt are stolen from the `africa' file.
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule EgyptAsia	1957	only	-	May	10	0:00	1:00	S
@@ -1584,7 +1710,8 @@
 Rule Palestine	2005	only	-	Oct	 4	2:00	0	-
 Rule Palestine	2006	max	-	Apr	 1	0:00	1:00	S
 Rule Palestine	2006	only	-	Sep	22	0:00	0	-
-Rule Palestine	2007	max	-	Sep	Thu>=8	2:00	0	-
+Rule Palestine	2007	only	-	Sep	Thu>=8	2:00	0	-
+Rule Palestine	2008	max	-	Aug	lastThu	2:00	0	-
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Gaza	2:17:52	-	LMT	1900 Oct
@@ -1687,7 +1814,7 @@
 # kept their clocks set five and a half hours ahead of Greenwich Mean
 # Time (GMT), in line with neighbor India.
 # From Paul Eggert (2006-04-18):
-# People who live in regions under Tamil control can use TZ='Asia/Calcutta',
+# People who live in regions under Tamil control can use [TZ='Asia/Kolkata'],
 # as that zone has agreed with the Tamil areas since our cutoff date of 1970.
 
 # From K Sethu (2006-04-25):
@@ -1777,9 +1904,7 @@
 # From Paul Eggert (2007-03-29):
 # Today the AP reported "Syria will switch to summertime at midnight Thursday."
 # http://www.iht.com/articles/ap/2007/03/29/africa/ME-GEN-Syria-Time-Change.php
-# For lack of better info, assume the rule changed to "last Friday in March"
-# this year.
-Rule	Syria	2007	max	-	Mar	lastFri	0:00	1:00	S
+Rule	Syria	2007	only	-	Mar	lastFri	0:00	1:00	S
 # From Jesper Norgard (2007-10-27):
 # The sister center ICARDA of my work CIMMYT is confirming that Syria DST will
 # not take place 1.st November at 0:00 o'clock but 1.st November at 24:00 or
@@ -1801,10 +1926,52 @@
 # Council of Ministers also approved the commencement of work on 
 # identifying the winter time as of Friday, 2/11/2007 where the 60th 
 # minute delay at midnight Thursday 1/11/2007.
+Rule	Syria	2007	only	-	Nov	 Fri>=1	0:00	0	-
+
+# From Stephen Colebourne (2008-03-17):
+# For everyone's info, I saw an IATA time zone change for [Syria] for
+# this month (March 2008) in the last day or so...This is the data IATA
+# are now using:
+# Country     Time Standard   --- DST Start ---   --- DST End ---  DST
+# Name        Zone Variation   Time    Date        Time    Date
+# Variation
+# Syrian Arab
+# Republic    SY    +0200      2200  03APR08       2100  30SEP08   +0300
+#                              2200  02APR09       2100  30SEP09   +0300
+#                              2200  01APR10       2100  30SEP10   +0300
+
+# From Arthur David Olson (2008-03-17):
+# Here's a link to English-language coverage by the Syrian Arab News
+# Agency (SANA)...
+# 
+# http://www.sana.sy/eng/21/2008/03/11/165173.htm
+# ...which reads (in part) "The Cabinet approved the suggestion of the
+# Ministry of Electricity to begin daylight savings time on Friday April
+# 4th, advancing clocks one hour ahead on midnight of Thursday April 3rd."
+# Since Syria is two hours east of UTC, the 2200 and 2100 transition times
+# shown above match up with midnight in Syria.
+
+# From Arthur David Olson (2008-03-18):
+# My buest guess at a Syrian rule is "the Friday nearest April 1";
+# coding that involves either using a "Mar Fri>=29" construct that old time zone
+# compilers can't handle  or having multiple Rules (a la Israel).
+# For now, use "Apr Fri>=1", and go with IATA on a uniform Sep 30 end.
+
+# From Steffen Thorsen (2008-10-07):
+# Syria has now officially decided to end DST on 2008-11-01 this year,
+# according to the following article in the Syrian Arab News Agency (SANA).
+#
+# The article is in Arabic, and seems to tell that they will go back to
+# winter time on 2008-11-01 at 00:00 local daylight time (delaying/setting
+# clocks back 60 minutes).
 #
-# From Arthur David Olson (2007-10-30):
-# My best guess for the future is first Friday in November.
-Rule	Syria	2007	max	-	Nov	 Fri>=1	0:00	0	-
+# 
+# http://sana.sy/ara/2/2008/10/07/195459.htm
+# 
+
+Rule	Syria	2008	max	-	Apr	Fri>=1	0:00	1:00	S
+Rule	Syria	2008	max	-	Nov	1	0:00	0	-
+
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Asia/Damascus	2:25:12 -	LMT	1920	# Dimashq
 			2:00	Syria	EE%sT
@@ -1858,13 +2025,13 @@
 
 # Vietnam
 
-# From Paul Eggert (1993-11-18):
-# Saigon's official name is Thanh-Pho Ho Chi Minh, but it's too long.
-# We'll stick with the traditional name for now.
+# From Arthur David Olson (2008-03-18):
+# The English-language name of Vietnam's most populous city is "Ho Chi Min City";
+# we use Ho_Chi_Minh below to avoid a name of more than 14 characters.
 
 # From Shanks & Pottenger:
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone	Asia/Saigon	7:06:40 -	LMT	1906 Jun  9
+Zone	Asia/Ho_Chi_Minh	7:06:40 -	LMT	1906 Jun  9
 			7:06:20	-	SMT	1911 Mar 11 0:01 # Saigon MT?
 			7:00	-	ICT	1912 May
 			8:00	-	ICT	1931 May
Index: europe
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/europe,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/europe -L share/zoneinfo/europe -u -r1.4 -r1.5
--- share/zoneinfo/europe
+++ share/zoneinfo/europe
@@ -1,4 +1,4 @@
-# @(#)europe	8.12
+# @(#)europe	8.18
 # 
 
 # This data is by no means authoritative; if you think you know better,
@@ -457,7 +457,7 @@
 Rule	EU	1981	max	-	Mar	lastSun	 1:00u	1:00	S
 Rule	EU	1996	max	-	Oct	lastSun	 1:00u	0	-
 # The most recent directive covers the years starting in 2002.  See:
-# 
 # Directive 2000/84/EC of the European Parliament and of the Council
 # of 19 January 2001 on summer-time arrangements.
 # 
@@ -480,9 +480,48 @@
 Rule	C-Eur	1942	only	-	Nov	 2	 2:00s	0	-
 Rule	C-Eur	1943	only	-	Mar	29	 2:00s	1:00	S
 Rule	C-Eur	1943	only	-	Oct	 4	 2:00s	0	-
-Rule	C-Eur	1944	only	-	Apr	 3	 2:00s	1:00	S
+Rule	C-Eur	1944	1945	-	Apr	Mon>=1	 2:00s	1:00	S
 # Whitman gives 1944 Oct 7; go with Shanks & Pottenger.
 Rule	C-Eur	1944	only	-	Oct	 2	 2:00s	0	-
+# From Jesper Norgaard Welen (2008-07-13):
+#
+# I found what is probably a typo of 2:00 which should perhaps be 2:00s
+# in the C-Eur rule from tz database version 2008d (this part was
+# corrected in version 2008d). The circumstancial evidence is simply the
+# tz database itself, as seen below:
+#
+# Zone Europe/Paris 0:09:21 - LMT 1891 Mar 15  0:01
+#    0:00 France WE%sT 1945 Sep 16  3:00
+#
+# Zone Europe/Monaco 0:29:32 - LMT 1891 Mar 15
+#    0:00 France WE%sT 1945 Sep 16 3:00
+#
+# Zone Europe/Belgrade 1:22:00 - LMT 1884
+#    1:00 1:00 CEST 1945 Sep 16  2:00s
+#
+# Rule France 1945 only - Sep 16  3:00 0 -
+# Rule Belgium 1945 only - Sep 16  2:00s 0 -
+# Rule Neth 1945 only - Sep 16 2:00s 0 -
+#
+# The rule line to be changed is:
+#
+# Rule C-Eur 1945 only - Sep 16  2:00 0 -
+#
+# It seems that Paris, Monaco, Rule France, Rule Belgium all agree on
+# 2:00 standard time, e.g. 3:00 local time.  However there are no
+# countries that use C-Eur rules in September 1945, so the only items
+# affected are apparently these ficticious zones that translates acronyms
+# CET and MET:
+#
+# Zone CET  1:00 C-Eur CE%sT
+# Zone MET  1:00 C-Eur ME%sT
+#
+# It this is right then the corrected version would look like:
+#
+# Rule C-Eur 1945 only - Sep 16  2:00s 0 -
+#
+# A small step for mankind though 8-)
+Rule	C-Eur	1945	only	-	Sep	16	 2:00s	0	-
 Rule	C-Eur	1977	1980	-	Apr	Sun>=1	 2:00s	1:00	S
 Rule	C-Eur	1977	only	-	Sep	lastSun	 2:00s	0	-
 Rule	C-Eur	1978	only	-	Oct	 1	 2:00s	0	-
@@ -725,7 +764,8 @@
 Zone	Europe/Sofia	1:33:16 -	LMT	1880
 			1:56:56	-	IMT	1894 Nov 30 # Istanbul MT?
 			2:00	-	EET	1942 Nov  2  3:00
-			1:00	C-Eur	CE%sT	1945 Apr  2  3:00
+			1:00	C-Eur	CE%sT	1945
+			1:00	-	CET	1945 Apr 2 3:00
 			2:00	-	EET	1979 Mar 31 23:00
 			2:00	Bulg	EE%sT	1982 Sep 26  2:00
 			2:00	C-Eur	EE%sT	1991
@@ -1093,33 +1133,40 @@
 # [See tz-link.htm for the URL.]
 
 # From Joerg Schilling (2002-10-23):
-# In 1945, Berlin was switched to Moscow Summer time (GMT+4) by 
+# In 1945, Berlin was switched to Moscow Summer time (GMT+4) by
+# 
 # General [Nikolai] Bersarin.
 
 # From Paul Eggert (2003-03-08):
 # 
+# http://www.parlament-berlin.de/pds-fraktion.nsf/727459127c8b66ee8525662300459099/defc77cb784f180ac1256c2b0030274b/$FILE/bersarint.pdf
+# 
 # says that Bersarin issued an order to use Moscow time on May 20.
 # However, Moscow did not observe daylight saving in 1945, so
 # this was equivalent to CEMT (GMT+3), not GMT+4.
 
 
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Germany	1945	only	-	Apr	 2	2:00s	1:00	S
-Rule	Germany	1945	only	-	May	24	2:00	2:00	M # Midsummer
-Rule	Germany	1945	only	-	Sep	24	3:00	1:00	S
-Rule	Germany	1945	only	-	Nov	18	2:00s	0	-
 Rule	Germany	1946	only	-	Apr	14	2:00s	1:00	S
 Rule	Germany	1946	only	-	Oct	 7	2:00s	0	-
 Rule	Germany	1947	1949	-	Oct	Sun>=1	2:00s	0	-
-Rule	Germany	1947	only	-	Apr	 6	2:00s	1:00	S
+# http://www.ptb.de/de/org/4/44/441/salt.htm says the following transition
+# occurred at 3:00 MEZ, not the 2:00 MEZ given in Shanks & Pottenger.
+# Go with the PTB.
+Rule	Germany	1947	only	-	Apr	 6	3:00s	1:00	S
 Rule	Germany	1947	only	-	May	11	2:00s	2:00	M
 Rule	Germany	1947	only	-	Jun	29	3:00	1:00	S
 Rule	Germany	1948	only	-	Apr	18	2:00s	1:00	S
 Rule	Germany	1949	only	-	Apr	10	2:00s	1:00	S
+
+Rule SovietZone	1945	only	-	May	24	2:00	2:00	M # Midsummer
+Rule SovietZone	1945	only	-	Sep	24	3:00	1:00	S
+Rule SovietZone	1945	only	-	Nov	18	2:00s	0	-
+
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Europe/Berlin	0:53:28 -	LMT	1893 Apr
-			1:00	C-Eur	CE%sT	1945 Apr 2 2:00
+			1:00	C-Eur	CE%sT	1945 May 24 2:00
+			1:00 SovietZone	CE%sT	1946
 			1:00	Germany	CE%sT	1980
 			1:00	EU	CE%sT
 
@@ -1196,7 +1243,7 @@
 Zone	Europe/Budapest	1:16:20 -	LMT	1890 Oct
 			1:00	C-Eur	CE%sT	1918
 			1:00	Hungary	CE%sT	1941 Apr  6  2:00
-			1:00	C-Eur	CE%sT	1945 May  1 23:00
+			1:00	C-Eur	CE%sT	1945
 			1:00	Hungary	CE%sT	1980 Sep 28  2:00s
 			1:00	EU	CE%sT
 
@@ -2113,7 +2160,8 @@
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Europe/Belgrade	1:22:00	-	LMT	1884
 			1:00	-	CET	1941 Apr 18 23:00
-			1:00	C-Eur	CE%sT	1945 May  8  2:00s
+			1:00	C-Eur	CE%sT	1945
+			1:00	-	CET	1945 May 8 2:00s
 			1:00	1:00	CEST	1945 Sep 16  2:00s
 # Metod Kozelj reports that the legal date of
 # transition to EU rules was 1982-11-27, for all of Yugoslavia at the time.
@@ -2305,6 +2353,27 @@
 # (on a non-government server though) describing dates between 2002 and 2006:
 # http://www.alomaliye.com/bkk_2002_3769.htm
 
+# From Sue Williams (2008-08-11):
+# I spotted this news article about a potential change in Turkey.
+#
+# 
+# http://www.hurriyet.com.tr/english/domestic/9626174.asp?scr=1
+# 
+
+# From Sue Williams (2008-08-20):
+# This article says that around the end of March 2011, Turkey wants to
+# adjust the clocks forward by 1/2 hour and stay that way permanently.
+# The article indicates that this is a change in timezone offset in addition
+# to stopping observance of DST.
+# This proposal has not yet been approved.
+#
+# Read more here...
+#
+# Turkey to abandon daylight saving time in 2011
+# 
+# http://www.turkishdailynews.com.tr/article.php?enewsid=112989
+# 
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Turkey	1916	only	-	May	 1	0:00	1:00	S
 Rule	Turkey	1916	only	-	Oct	 1	0:00	0	-
Index: northamerica
===================================================================
RCS file: /home/cvs/src/share/zoneinfo/northamerica,v
retrieving revision 1.4
retrieving revision 1.5
diff -L share/zoneinfo/northamerica -L share/zoneinfo/northamerica -u -r1.4 -r1.5
--- share/zoneinfo/northamerica
+++ share/zoneinfo/northamerica
@@ -1,4 +1,4 @@
-# @(#)northamerica	8.20
+# @(#)northamerica	8.24
 # 
 
 # also includes Central America and the Caribbean
@@ -2076,8 +2076,8 @@
 # http://www.jonesbahamas.com/?c=45&a=10412
 
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
-Rule	Bahamas	1964	2006	-	Oct	lastSun	2:00	0	S
-Rule	Bahamas	1964	1986	-	Apr	lastSun	2:00	1:00	D
+Rule	Bahamas	1964	1975	-	Oct	lastSun	2:00	0	S
+Rule	Bahamas	1964	1975	-	Apr	lastSun	2:00	1:00	D
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	America/Nassau	-5:09:24 -	LMT	1912 Mar 2
 			-5:00	Bahamas	E%sT	1976
@@ -2205,6 +2205,52 @@
 # 
 # http://www.worldtimezone.com/dst_news/dst_news_cuba03.html
 
+# From Arthur David Olson (2008-03-09):
+# I'm in Maryland which is now observing United States Eastern Daylight
+# Time. At 9:44 local time I used RealPlayer to listen to
+# 
+# http://media.enet.cu/radioreloj
+# , a Cuban information station, and heard
+# the time announced as "ocho cuarenta y cuatro" ("eight forty-four"),
+# indicating that Cuba is still on standard time.
+
+# From Steffen Thorsen (2008-03-12):
+# It seems that Cuba will start DST on Sunday, 2007-03-16...
+# It was announced yesterday, according to this source (in Spanish):
+# 
+# http://www.nnc.cubaweb.cu/marzo-2008/cien-1-11-3-08.htm
+# 
+#
+# Some more background information is posted here:
+# 
+# http://www.timeanddate.com/news/time/cuba-starts-dst-march-16.html
+# 
+#
+# The article also says that Cuba has been observing DST since 1963,
+# while Shanks (and tzdata) has 1965 as the first date (except in the
+# 1940's). Many other web pages in Cuba also claim that it has been
+# observed since 1963, but with the exception of 1970 - an exception
+# which is not present in tzdata/Shanks. So there is a chance we need to
+# change some historic records as well.
+#
+# One example:
+# 
+# http://www.radiohc.cu/espanol/noticias/mar07/11mar/hor.htm
+# 
+
+# From Jesper Norgaard Welen (2008-03-13):
+# The Cuban time change has just been confirmed on the most authoritative
+# web site, the Granma.  Please check out
+# 
+# http://www.granma.cubaweb.cu/2008/03/13/nacional/artic10.html
+# 
+#
+# Basically as expected after Steffen Thorsens information, the change
+# will take place midnight between Saturday and Sunday.
+
+# From Arthur David Olson (2008-03-12):
+# Assume Sun>=15 (third Sunday) going forward.
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Cuba	1928	only	-	Jun	10	0:00	1:00	D
 Rule	Cuba	1928	only	-	Oct	10	0:00	0	S
@@ -2236,7 +2282,8 @@
 Rule	Cuba	1998	2003	-	Oct	lastSun	0:00s	0	S
 Rule	Cuba	2000	2006	-	Apr	Sun>=1	0:00s	1:00	D
 Rule	Cuba	2006	max	-	Oct	lastSun	0:00s	0	S
-Rule	Cuba	2007	max	-	Mar	Sun>=8	0:00s	1:00	D
+Rule	Cuba	2007	only	-	Mar	Sun>=8	0:00s	1:00	D
+Rule	Cuba	2008	max	-	Mar	Sun>=15	0:00s	1:00	D
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	America/Havana	-5:29:28 -	LMT	1890

From laffer1 at midnightbsd.org  Thu Jan  1 17:52:48 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 17:52:48 -0500 (EST)
Subject: [Midnightbsd-cvs] src: UPDATING: timezones are fun
Message-ID: <200901012252.n01Mqmck050859@stargazer.midnightbsd.org>

Log Message:
-----------
timezones are fun

Modified Files:
--------------
    src:
        UPDATING (r1.46 -> r1.47)

-------------- next part --------------
Index: UPDATING
===================================================================
RCS file: /home/cvs/src/UPDATING,v
retrieving revision 1.46
retrieving revision 1.47
diff -L UPDATING -L UPDATING -u -r1.46 -r1.47
--- UPDATING
+++ UPDATING
@@ -3,6 +3,9 @@
 Items affecting the mports and packages system can be found in
 /usr/mports/UPDATING. 
 
+20080101:
+	Update time zone data to 2008i.
+
 20081231:
 	Correct a problem where bluetooth and netgraph sockets are not
 	properly initialized.

From laffer1 at midnightbsd.org  Thu Jan  1 18:28:15 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 18:28:15 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: lang/php5: work in progress..
Message-ID: <200901012328.n01NSFE9053770@stargazer.midnightbsd.org>

Log Message:
-----------
work in progress.. upgrade php to 5.2.8

Modified Files:
--------------
    mports/lang/php5:
        Makefile (r1.21 -> r1.22)
        Makefile.ext (r1.10 -> r1.11)
        distinfo (r1.9 -> r1.10)
    mports/lang/php5/files:
        patch-configure.in (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile.ext
===================================================================
RCS file: /home/cvs/mports/lang/php5/Makefile.ext,v
retrieving revision 1.10
retrieving revision 1.11
diff -L lang/php5/Makefile.ext -L lang/php5/Makefile.ext -u -r1.10 -r1.11
--- lang/php5/Makefile.ext
+++ lang/php5/Makefile.ext
@@ -74,6 +74,10 @@
 CONFIGURE_ARGS+=--enable-exif
 .endif
 
+.if ${PHP_MODNAME} == "filter"
+CONFIGURE_ARGS+=--enable-filter
+.endif
+
 .if ${PHP_MODNAME} == "ftp"
 CONFIGURE_ARGS+=--enable-ftp \
 		--with-openssl-dir=${OPENSSLBASE}
@@ -118,6 +122,10 @@
 CONFIGURE_ARGS+=--with-gmp=${LOCALBASE}
 .endif
 
+.if ${PHP_MODNAME} == "hash"
+CONFIGURE_ARGS+=--enable-hash
+.endif
+
 .if ${PHP_MODNAME} == "iconv"
 CONFIGURE_ARGS+=--with-iconv=${LOCALBASE} \
 		--with-iconv-dir=${LOCALBASE}
@@ -140,10 +148,13 @@
 .if ${PHP_MODNAME} == "interbase"
 CONFIGURE_ARGS+=--with-interbase=${LOCALBASE}
 
-USE_GCC=	3.4+
 USE_FIREBIRD=	yes
 .endif
 
+.if ${PHP_MODNAME} == "json"
+CONFIGURE_ARGS+=--enable-json
+.endif
+
 .if ${PHP_MODNAME} == "ldap"
 CONFIGURE_ARGS+=--with-ldap=${LOCALBASE}
 
@@ -224,8 +235,7 @@
 .endif
 
 .if ${PHP_MODNAME} == "openssl"
-CONFIGURE_ARGS+=--with-openssl=${OPENSSLBASE} \
-		--with-openssl-dir=${OPENSSLBASE}
+CONFIGURE_ARGS+=--with-openssl=${OPENSSLBASE}
 
 LDFLAGS+=	-L${OPENSSLLIB} -lcrypto -lssl
 USE_OPENSSL=	yes
@@ -260,7 +270,6 @@
 USE_PHP=	pdo
 USE_PHP_BUILD=	yes
 
-USE_GCC=	3.4+
 USE_FIREBIRD=	yes
 .endif
 
@@ -373,7 +382,6 @@
 		--with-libxml-dir=${LOCALBASE}
 
 USE_GNOME=	libxml2
-USE_GCC=	3.4+
 
 USE_PHP=	session
 USE_PHP_BUILD=	yes
@@ -490,6 +498,11 @@
 USE_PHP_BUILD=	yes
 .endif
 
+.if ${PHP_MODNAME} == "zip"
+CONFIGURE_ARGS+=--enable-zip \
+		--with-zlib-dir=/usr
+.endif
+
 .if ${PHP_MODNAME} == "zlib"
 CONFIGURE_ARGS+=--with-zlib=/usr
 .endif
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/lang/php5/Makefile,v
retrieving revision 1.21
retrieving revision 1.22
diff -L lang/php5/Makefile -L lang/php5/Makefile -u -r1.21 -r1.22
--- lang/php5/Makefile
+++ lang/php5/Makefile
@@ -7,8 +7,8 @@
 #
 
 PORTNAME=	php5
-PORTVERSION=	5.2.6
-PORTREVISION?=	4
+PORTVERSION=	5.2.8
+PORTREVISION?=	0
 CATEGORIES?=	lang devel www
 MASTER_SITES=	${MASTER_SITE_PHP:S/$/:release/}
 MASTER_SITE_SUBDIR=	distributions/:release
@@ -56,7 +56,7 @@
 .include 
 
 .if !defined(WITHOUT_SUHOSIN)
-PATCHFILES+=	suhosin-patch-${PORTVERSION}-0.9.6.2.patch.gz:suhosin
+PATCHFILES+=	suhosin-patch-5.2.7-0.9.6.3.patch.gz:suhosin
 PATCH_SITES+=	http://download.suhosin.org/:suhosin
 PATCH_DIST_STRIP=	-p1
 PLIST_SUB+=	SUHOSIN=""
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/lang/php5/distinfo,v
retrieving revision 1.9
retrieving revision 1.10
diff -L lang/php5/distinfo -L lang/php5/distinfo -u -r1.9 -r1.10
--- lang/php5/distinfo
+++ lang/php5/distinfo
@@ -1,9 +1,9 @@
-MD5 (php-5.2.6.tar.bz2) = 7380ffecebd95c6edb317ef861229ebd
-SHA256 (php-5.2.6.tar.bz2) = 1892b2dd50b56ae2c9aec027fcd9035b76673f113555bc2bc1007bab8ae4db81
-SIZE (php-5.2.6.tar.bz2) = 9571312
-MD5 (suhosin-patch-5.2.6-0.9.6.2.patch.gz) = f2ec986341a314c271259dbe4d940858
-SHA256 (suhosin-patch-5.2.6-0.9.6.2.patch.gz) = dfdae803778e6ed6854ea3ad2948bbfedbfffc5a32dbc75a657b99092a9cc5e4
-SIZE (suhosin-patch-5.2.6-0.9.6.2.patch.gz) = 22986
-MD5 (php-5.2.6-mail-header.patch) = eb26be2469a173a3476220342c5fcd58
-SHA256 (php-5.2.6-mail-header.patch) = 7e546c22a19386c4d93bebddfb64ace9447774f748070794c7c41419c5c474ac
-SIZE (php-5.2.6-mail-header.patch) = 3420
+MD5 (php-5.2.8.tar.bz2) = 8760a833cf10433d3e72271ab0d0eccf
+SHA256 (php-5.2.8.tar.bz2) = a70600e13410213a637f1c9825e9c0d45c64de8cefb1929f8f5aa761b20b2b67
+SIZE (php-5.2.8.tar.bz2) = 9827180
+MD5 (suhosin-patch-5.2.7-0.9.6.3.patch.gz) = d455c3dd5b652046dbac2951a58f64fa
+SHA256 (suhosin-patch-5.2.7-0.9.6.3.patch.gz) = 85e6262f53014e393977d1efed2d3a7e686767a07f96b14b2c3f126f694aee46
+SIZE (suhosin-patch-5.2.7-0.9.6.3.patch.gz) = 23125
+MD5 (php-5.2.8-mail-header.patch) = 74bf3a2a123c284f908c4f5483ebe886
+SHA256 (php-5.2.8-mail-header.patch) = 9bd306145153a371f619d89996cb329bdc36791b22a50daf4afe7cc69c46dccb
+SIZE (php-5.2.8-mail-header.patch) = 3381
Index: patch-configure.in
===================================================================
RCS file: /home/cvs/mports/lang/php5/files/patch-configure.in,v
retrieving revision 1.2
retrieving revision 1.3
diff -L lang/php5/files/patch-configure.in -L lang/php5/files/patch-configure.in -u -r1.2 -r1.3
--- lang/php5/files/patch-configure.in
+++ lang/php5/files/patch-configure.in
@@ -1,6 +1,6 @@
---- configure.in.orig	Mon Jun  4 08:08:43 2007
-+++ configure.in	Mon Jun  4 08:13:47 2007
-@@ -233,7 +233,6 @@
+--- configure.in.orig	2008-12-05 07:58:47.000000000 +0100
++++ configure.in	2008-12-05 08:02:26.000000000 +0100
+@@ -270,7 +270,6 @@
  dnl .
  dnl -------------------------------------------------------------------------
  
@@ -8,7 +8,7 @@
  PHP_HELP_SEPARATOR([SAPI modules:])
  PHP_SHLIB_SUFFIX_NAMES
  PHP_SAPI=default
-@@ -258,7 +257,6 @@
+@@ -295,7 +294,6 @@
  
  if test "$enable_maintainer_zts" = "yes"; then
    PTHREADS_ASSIGN_VARS
@@ -16,7 +16,7 @@
  fi
  
  divert(3)
-@@ -1123,7 +1121,7 @@
+@@ -1136,7 +1134,7 @@
  EXPANDED_DATADIR=$datadir
  EXPANDED_PHP_CONFIG_FILE_PATH=`eval echo "$PHP_CONFIG_FILE_PATH"`
  EXPANDED_PHP_CONFIG_FILE_SCAN_DIR=`eval echo "$PHP_CONFIG_FILE_SCAN_DIR"`
@@ -25,13 +25,13 @@
  
  exec_prefix=$old_exec_prefix
  libdir=$old_libdir
-@@ -1295,22 +1293,19 @@
+@@ -1344,22 +1342,19 @@
  INLINE_CFLAGS="$INLINE_CFLAGS $standard_libtool_flag"
  CXXFLAGS="$CXXFLAGS $standard_libtool_flag"
  
--all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_CLI_TARGET)"
+-all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_ZEND_EX) \$(PHP_CLI_TARGET)"
 -install_targets="$install_modules install-build install-headers install-programs $install_pear"
-+all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_CLI_TARGET) \$(PHP_CGI_TARGET)"
++all_targets="$lcov_target \$(OVERALL_TARGET) \$(PHP_MODULES) \$(PHP_ZEND_EX) \$(PHP_CLI_TARGET) \$(PHP_CGI_TARGET)"
 +install_targets="$PHP_INSTALL_CLI_TARGET $PHP_INSTALL_CGI_TARGET $install_modules install-build install-headers install-programs $install_pear"
  
  case $PHP_SAPI in

From laffer1 at midnightbsd.org  Thu Jan  1 18:29:20 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 18:29:20 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: patch-main_safe_mode.c: remove outdated
	patch
Message-ID: <200901012329.n01NTKPF053844@stargazer.midnightbsd.org>

Log Message:
-----------
remove outdated patch

Removed Files:
-------------
    mports/lang/php5/files:
        patch-main_safe_mode.c

-------------- next part --------------
--- lang/php5/files/patch-main_safe_mode.c
+++ /dev/null
@@ -1,17 +0,0 @@
---- main/safe_mode.c.orig	2008-09-04 15:52:19.000000000 +0200
-+++ main/safe_mode.c	2008-09-04 15:52:35.000000000 +0200
-@@ -74,14 +74,6 @@
- 		}
- 	}
- 
--	/* 
--	 * If given filepath is a URL, allow - safe mode stuff
--	 * related to URL's is checked in individual functions
--	 */
--	wrapper = php_stream_locate_url_wrapper(filename, NULL, STREAM_LOCATE_WRAPPERS_ONLY TSRMLS_CC);
--	if (wrapper != NULL)
--		return 1;
--		
- 	/* First we see if the file is owned by the same user...
- 	 * If that fails, passthrough and check directory...
- 	 */

From laffer1 at midnightbsd.org  Thu Jan  1 18:49:21 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 18:49:21 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: We don't support php 4
Message-ID: <200901012349.n01NnLst055525@stargazer.midnightbsd.org>

Log Message:
-----------
We don't support php 4

Modified Files:
--------------
    mports/lang/php5-extensions:
        Makefile (r1.5 -> r1.6)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/lang/php5-extensions/Makefile,v
retrieving revision 1.5
retrieving revision 1.6
diff -L lang/php5-extensions/Makefile -L lang/php5-extensions/Makefile -u -r1.5 -r1.6
--- lang/php5-extensions/Makefile
+++ lang/php5-extensions/Makefile
@@ -19,7 +19,6 @@
 LICENSE=	agg
 
 DEFAULT_PHP_VER=5
-IGNORE_WITH_PHP=4
 USE_PHP_BUILD=	yes
 
 NO_BUILD=	yes

From laffer1 at midnightbsd.org  Thu Jan  1 19:26:38 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 19:26:38 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: x11/xterm: update to 237
Message-ID: <200901020026.n020QcD1058841@stargazer.midnightbsd.org>

Log Message:
-----------
update to 237

Modified Files:
--------------
    mports/x11/xterm:
        Makefile (r1.9 -> r1.10)
        distinfo (r1.8 -> r1.9)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/x11/xterm/Makefile,v
retrieving revision 1.9
retrieving revision 1.10
diff -L x11/xterm/Makefile -L x11/xterm/Makefile -u -r1.9 -r1.10
--- x11/xterm/Makefile
+++ x11/xterm/Makefile
@@ -7,7 +7,7 @@
 #
 
 PORTNAME=	xterm
-PORTVERSION=	235
+PORTVERSION=	237
 CATEGORIES=	x11
 MASTER_SITES=	ftp://invisible-island.net/xterm/ \
 		http://voodoo.bawue.com/download/
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/x11/xterm/distinfo,v
retrieving revision 1.8
retrieving revision 1.9
diff -L x11/xterm/distinfo -L x11/xterm/distinfo -u -r1.8 -r1.9
--- x11/xterm/distinfo
+++ x11/xterm/distinfo
@@ -1,3 +1,3 @@
-MD5 (xterm-235.tgz) = 5060cab9cef0ea09a24928f3c7fbde2b
-SHA256 (xterm-235.tgz) = c8a7ccb515b967a11dc2ac1061943cddbf0b6640de89f72590b1ff79e69a49cf
-SIZE (xterm-235.tgz) = 857714
+MD5 (xterm-237.tgz) = 6d5f9e124fd3e09487f47c66da8c7345
+SHA256 (xterm-237.tgz) = f3be160c230fcb38fba0824cf8a4334e8ff0bb93938e5e325be5e949cd2b3476
+SIZE (xterm-237.tgz) = 860424

From laffer1 at midnightbsd.org  Thu Jan  1 19:48:42 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 19:48:42 -0500 (EST)
Subject: [Midnightbsd-cvs] src: Makefile: geeze,
	fix the build/install of liblwres
Message-ID: <200901020048.n020mgAI060772@stargazer.midnightbsd.org>

Log Message:
-----------
geeze, fix the build/install of liblwres

Modified Files:
--------------
    src/lib/bind/lwres:
        Makefile (r1.6 -> r1.7)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/src/lib/bind/lwres/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L lib/bind/lwres/Makefile -L lib/bind/lwres/Makefile -u -r1.6 -r1.7
--- lib/bind/lwres/Makefile
+++ lib/bind/lwres/Makefile
@@ -10,7 +10,7 @@
 
 # Unlike other BIND libs, this should be installed unless the user says NO.
 .if ${MK_BIND_LIBS_LWRES} != "no"
-WITH_BIND_LIBS=
+MK_BIND_LIBS=	yes
 .endif
 
 .include	"${LIB_BIND_DIR}/config.mk"

From laffer1 at midnightbsd.org  Thu Jan  1 19:59:49 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 19:59:49 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: emulators/kqemu-kmod: Fix a few bugs with
	kqemu
Message-ID: <200901020059.n020xnF4061929@stargazer.midnightbsd.org>

Log Message:
-----------
Fix a few bugs with kqemu

Modified Files:
--------------
    mports/emulators/kqemu-kmod:
        Makefile (r1.3 -> r1.4)
    mports/emulators/kqemu-kmod/files:
        patch-kqemu-freebsd.c (r1.1 -> r1.2)

Added Files:
-----------
    mports/emulators/kqemu-kmod/files:
        patch-common-Makefile (r1.1)
        patch-fpucontext (r1.1)
        patch-tssworkaround (r1.1)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/emulators/kqemu-kmod/Makefile,v
retrieving revision 1.3
retrieving revision 1.4
diff -L emulators/kqemu-kmod/Makefile -L emulators/kqemu-kmod/Makefile -u -r1.3 -r1.4
--- emulators/kqemu-kmod/Makefile
+++ emulators/kqemu-kmod/Makefile
@@ -8,10 +8,10 @@
 
 PORTNAME=	kqemu
 PORTVERSION=	1.3.0.p11
+PORTREVISION=	1
 CATEGORIES=	emulators
-MASTER_SITES=	http://qemu.org/ \
-		http://fabrice.bellard.free.fr/qemu/ \
-		${MASTER_SITE_LOCAL}
+MASTER_SITES=	http://bellard.org/qemu/ \
+		${MASTER_SITE_FREEBSD_LOCAL}
 MASTER_SITE_SUBDIR=	nox
 PKGNAMESUFFIX=	-kmod
 DISTNAME=	${PORTNAME}-${PORTVERSION:C/.p/pre/}
@@ -24,10 +24,8 @@
 ONLY_FOR_ARCHS=	i386 amd64
 HAS_CONFIGURE=	yes
 USE_GMAKE=	yes
-USE_GCC=	3.4
 CONFIGURE_ARGS+=	--prefix=${PREFIX} --cc=${CC}
 
-
 USE_RC_SUBR=	kqemu
 
 .include 
--- /dev/null
+++ emulators/kqemu-kmod/files/patch-tssworkaround
@@ -0,0 +1,112 @@
+Index: kqemu-freebsd.c
+@@ -38,6 +38,14 @@
+ #else
+ #include 
+ #endif
++#ifdef __x86_64__
++#include 
++#include 
++#include 
++#include 
++#include 
++#include 
++#endif
+ 
+ #include "kqemu-kernel.h"
+ 
+@@ -248,6 +256,57 @@
+     va_end(ap);
+ }
+ 
++#ifdef __x86_64__
++int kqemu_cpu0gdtfixed;
++int kqemu_gdts_used;
++struct user_segment_descriptor *kqemu_gdts;
++struct region_descriptor kqemu_r_newgdt;
++extern  struct pcpu __pcpu[];
++
++/* called with interrupts disabled */
++void CDECL kqemu_tss_fixup(unsigned long kerngdtbase)
++{
++    int gsel_tss = GSEL(GPROC0_SEL, SEL_KPL);
++    unsigned cpuid = PCPU_GET(cpuid);
++    struct user_segment_descriptor *newgdt = gdt;
++
++    if (mp_ncpus <= 1 || kerngdtbase != (unsigned long)gdt)
++	/* UP host or gdt already moved, nothing to do */
++	return;
++    if (cpuid) {
++	/* move gdts of all but first cpu */
++	if (!kqemu_gdts)
++	    /*
++	     * XXX gdt is allocated as
++	     *	struct user_segment_descriptor gdt[NGDT * MAXCPU];
++	     * so it has room for the moved copies; need to allocate at
++	     * kldload (and only free if kqemu_gdts_used is zero) should this
++	     * change in the future
++	     */
++	    kqemu_gdts = &gdt[NGDT];
++	++kqemu_gdts_used;
++	newgdt = &kqemu_gdts[NGDT * (cpuid - 1)];
++	bcopy(gdt, newgdt, NGDT * sizeof(gdt[0]));
++	kqemu_r_newgdt.rd_limit = NGDT * sizeof(gdt[0]) - 1;
++	kqemu_r_newgdt.rd_base = (long) newgdt;
++    } else {
++	if (kqemu_cpu0gdtfixed)
++	    return;
++	++kqemu_cpu0gdtfixed;
++    }
++    gdt_segs[GPROC0_SEL].ssd_base = (long) &common_tss[cpuid];
++    ssdtosyssd(&gdt_segs[GPROC0_SEL],
++       (struct system_segment_descriptor *)&newgdt[GPROC0_SEL]);
++    if (cpuid) {
++	lgdt(&kqemu_r_newgdt);
++	wrmsr(MSR_GSBASE, (u_int64_t)&__pcpu[cpuid]);
++	wrmsr(MSR_KGSBASE, curthread->td_pcb->pcb_gsbase);
++	wrmsr(MSR_FSBASE, curthread->td_pcb->pcb_fsbase);
++    }
++    ltr(gsel_tss);
++}
++#endif
++
+ struct kqemu_instance { 
+ #if __FreeBSD_version >= 500000
+     TAILQ_ENTRY(kqemu_instance) kqemu_ent;
+Index: common/kernel.c
+@@ -1025,6 +1025,9 @@
+ #ifdef __x86_64__
+     uint16_t saved_ds, saved_es;
+     unsigned long fs_base, gs_base;
++#ifdef __FreeBSD__
++    struct kqemu_global_state *g = s->global_state;
++#endif
+ #endif
+     
+ #ifdef PROFILE
+@@ -1096,6 +1099,14 @@
+             apic_nmi_mask = apic_save_and_disable_nmi(s);
+         }
+ 
++#ifdef __FreeBSD__
++#ifdef __x86_64__
++        spin_lock(&g->lock);
++        asm volatile ("sgdt %0" : : "m" (s->kernel_gdt));
++        kqemu_tss_fixup(s->kernel_gdt.base);
++        spin_unlock(&g->lock);
++#endif
++#endif
+         /* load breakpoint registers and avoid setting them if in the
+            monitor address space. We suppose that no breakpoints are
+            set by the host OS for this process */
+Index: kqemu-kernel.h
+@@ -48,4 +48,10 @@
+ 
+ void CDECL kqemu_log(const char *fmt, ...);
+ 
++#ifdef __FreeBSD__
++#ifdef __x86_64__
++void CDECL kqemu_tss_fixup(unsigned long kerngdtbase);
++#endif
++#endif
++
+ #endif /* KQEMU_KERNEL_H */
--- /dev/null
+++ emulators/kqemu-kmod/files/patch-common-Makefile
@@ -0,0 +1,22 @@
+Index: common/Makefile
+@@ -47,9 +47,9 @@
+ ifeq ($(ARCH), x86_64)
+ COMMON_CFLAGS+=-mno-red-zone
+ endif
+-CFLAGS=$(COMMON_CFLAGS)
++CFLAGS=$(COMMON_CFLAGS) ${DEBUG_FLAGS}
+ MON_CFLAGS=$(COMMON_CFLAGS)
+-KERNEL_CFLAGS=$(COMMON_CFLAGS)
++KERNEL_CFLAGS=$(COMMON_CFLAGS) ${DEBUG_FLAGS}
+ 
+ # Disable SSP if GCC supports it
+ MON_CFLAGS+=$(call cc-option,$(MON_CC),-fno-stack-protector,)
+@@ -119,7 +119,7 @@
+ 	$(CC) $(CFLAGS) $(DEFINES) $(INCLUDES) -c -o $@ $<
+ 
+ %.o: %.S
+-	$(CC) $(DEFINES) $(INCLUDES) -D__ASSEMBLY__ -c -o $@ $<
++	$(CC) ${DEBUG_FLAGS} $(DEFINES) $(INCLUDES) -D__ASSEMBLY__ -c -o $@ $<
+ 
+ clean:
+ 	rm -f *.o *~ monitor-image.h genoffsets genmon monitor_def.h \
--- /dev/null
+++ emulators/kqemu-kmod/files/patch-fpucontext
@@ -0,0 +1,78 @@
+Index: common/kernel.c
+@@ -1240,6 +1240,11 @@
+             case MON_REQ_EXCEPTION:
+                 exec_exception(s->arg0);
+                 break;
++#ifdef __FreeBSD__
++            case MON_REQ_LOADFPUCONTEXT:
++                kqemu_loadfpucontext(s->arg0);
++                break;
++#endif
+             default:
+                 kqemu_log("invalid mon request: %d\n", s->mon_req);
+                 break;
+Index: common/kqemu_int.h
+@@ -523,6 +523,7 @@
+     MON_REQ_LOCK_USER_PAGE,
+     MON_REQ_UNLOCK_USER_PAGE,
+     MON_REQ_EXCEPTION,
++    MON_REQ_LOADFPUCONTEXT,
+ } MonitorRequest;
+ 
+ #define INTERRUPT_ENTRY_SIZE 16
+Index: common/monitor.c
+@@ -1995,8 +1995,13 @@
+         raise_exception_err(s, EXCP07_PREX, 0);
+     } else {
+         /* the host needs to restore the FPU state for us */
++#ifndef __FreeBSD__
+         s->mon_req = MON_REQ_EXCEPTION;
+         s->arg0 = 0x07;
++#else
++        s->mon_req = MON_REQ_LOADFPUCONTEXT;
++        s->arg0 = (unsigned long)s->cpu_state.cpl;
++#endif
+         monitor2kernel1(s);
+     }
+ }
+Index: kqemu-freebsd.c
+@@ -33,6 +33,11 @@
+ 
+ #include 
+ #include 
++#ifdef __x86_64__
++#include 
++#else
++#include 
++#endif
+ 
+ #include "kqemu-kernel.h"
+ 
+@@ -172,6 +177,15 @@
+ {
+ }
+ 
++void CDECL kqemu_loadfpucontext(unsigned long cpl)
++{
++#ifdef __x86_64__
++    fpudna();
++#else
++    npxdna();
++#endif
++}
++
+ #if __FreeBSD_version < 500000
+ static int
+ curpriority_cmp(struct proc *p)
+Index: kqemu-kernel.h
+@@ -40,6 +40,10 @@
+ void * CDECL kqemu_io_map(unsigned long page_index, unsigned int size);
+ void CDECL kqemu_io_unmap(void *ptr, unsigned int size);
+ 
++#ifdef __FreeBSD__
++void CDECL kqemu_loadfpucontext(unsigned long cpl);
++#endif
++
+ int CDECL kqemu_schedule(void);
+ 
+ void CDECL kqemu_log(const char *fmt, ...);
Index: patch-kqemu-freebsd.c
===================================================================
RCS file: /home/cvs/mports/emulators/kqemu-kmod/files/patch-kqemu-freebsd.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -L emulators/kqemu-kmod/files/patch-kqemu-freebsd.c -L emulators/kqemu-kmod/files/patch-kqemu-freebsd.c -u -r1.1 -r1.2
--- emulators/kqemu-kmod/files/patch-kqemu-freebsd.c
+++ emulators/kqemu-kmod/files/patch-kqemu-freebsd.c
@@ -1,12 +1,69 @@
 Index: kqemu-freebsd.c
-@@ -321,6 +321,9 @@
+@@ -222,9 +222,17 @@
+ int CDECL kqemu_schedule(void)
+ {
+     /* kqemu_log("kqemu_schedule\n"); */
++#if __FreeBSD_version < 700044
+     mtx_lock_spin(&sched_lock);
+     mi_switch(SW_VOL, NULL);
+     mtx_unlock_spin(&sched_lock);
++#else
++    /* -current no longer uses sched_lock */
++    struct thread *td = curthread;
++    thread_lock(td);
++    mi_switch(SW_VOL, NULL);
++    thread_unlock(td);
++#endif
+     return SIGPENDING(curthread);
+ }
+ #endif
+@@ -258,6 +266,10 @@
+ static struct clonedevs *kqemuclones;
+ static TAILQ_HEAD(,kqemu_instance) kqemuhead = TAILQ_HEAD_INITIALIZER(kqemuhead);
+ static eventhandler_tag clonetag;
++#ifndef D_NEEDMINOR
++/* see http://svn.freebsd.org/viewvc/base?view=revision&revision=179726 */
++#define D_NEEDMINOR 0
++#endif
+ #endif
+ 
+ static d_close_t kqemu_close;
+@@ -282,7 +294,7 @@
+ 	/* bmaj */	-1
+ #else
+ 	.d_version =	D_VERSION,
+-	.d_flags =	D_NEEDGIANT,
++	.d_flags =	D_NEEDGIANT | D_NEEDMINOR,
+ 	.d_open =	kqemu_open,
+ 	.d_ioctl =	kqemu_ioctl,
+ 	.d_close =	kqemu_close,
+@@ -334,8 +346,15 @@
  #if __FreeBSD_version >= 500000
      dev->si_drv1 = NULL;
      TAILQ_REMOVE(&kqemuhead, ks, kqemu_ent);
++#if __FreeBSD_version >= 700051
++    destroy_dev_sched(dev);
++#else
 +#if __FreeBSD_version >= 700024
 +    dev_relthread(dev); 
 +#endif
      destroy_dev(dev);
  #endif
++#endif
      free(ks, M_KQEMU);
-
+     --kqemu_ref_count;
+ }
+@@ -514,7 +533,13 @@
+ 	while ((ks = TAILQ_FIRST(&kqemuhead)) != NULL) {
+ 	    kqemu_destroy(ks);
+ 	}
++#if __FreeBSD_version >= 700051
++	drain_dev_clone_events();
++#endif
+ 	clone_cleanup(&kqemuclones);
++#if __FreeBSD_version >= 700051
++	destroy_dev_drain(&kqemu_cdevsw);
++#endif
+ #endif
+         kqemu_global_delete(kqemu_gs);
+         kqemu_gs = NULL;

From laffer1 at midnightbsd.org  Thu Jan  1 20:06:29 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:06:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: osversion assumption for
	__FreeBSD_version
Message-ID: <200901020106.n0216To2062810@stargazer.midnightbsd.org>

Log Message:
-----------
osversion assumption for __FreeBSD_version

Modified Files:
--------------
    mports/emulators/pearpc:
        Makefile (r1.4 -> r1.5)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/emulators/pearpc/Makefile,v
retrieving revision 1.4
retrieving revision 1.5
diff -L emulators/pearpc/Makefile -L emulators/pearpc/Makefile -u -r1.4 -r1.5
--- emulators/pearpc/Makefile
+++ emulators/pearpc/Makefile
@@ -8,7 +8,7 @@
 
 PORTNAME=	pearpc
 PORTVERSION=	0.4
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	emulators
 MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
 MASTER_SITE_SUBDIR=	${PORTNAME}
@@ -85,6 +85,11 @@
 post-extract:
 	@${REINPLACE_CMD} -e 's|-g -O2||;s|-O2||' ${WRKSRC}/configure
 
+pre-configure:
+# Assumes __FreeBSD_version value.  Change when current switches over.
+.if ${OSVERSION} > 700000
+	@${REINPLACE_CMD} -e 's|clock_settime\ ()|foobar()|' ${WRKSRC}/configure
+.endif
 
 post-configure:
 	@${REINPLACE_CMD} -e 's|-lpthread|${PTHREAD_LIBS}|g' ${WRKSRC}/Makefile

From laffer1 at midnightbsd.org  Thu Jan  1 20:19:16 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:19:16 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: security/vlock: update to 2.2.2
Message-ID: <200901020119.n021JG4x063964@stargazer.midnightbsd.org>

Log Message:
-----------
update to 2.2.2

Modified Files:
--------------
    mports/security/vlock:
        Makefile (r1.2 -> r1.3)
        distinfo (r1.1 -> r1.2)
        pkg-descr (r1.1 -> r1.2)

Added Files:
-----------
    mports/security/vlock/files:
        patch-configure (r1.1)

Removed Files:
-------------
    mports/security/vlock/files:
        patch-aa
        patch-ab
        patch-ac
        patch-ad
        patch-ae

-------------- next part --------------
Index: pkg-descr
===================================================================
RCS file: /home/cvs/mports/security/vlock/pkg-descr,v
retrieving revision 1.1
retrieving revision 1.2
diff -L security/vlock/pkg-descr -L security/vlock/pkg-descr -u -r1.1 -r1.2
--- security/vlock/pkg-descr
+++ security/vlock/pkg-descr
@@ -1,5 +1,4 @@
 This is a utility which locks a terminal so it can only be unlocked with the
 user's password (or the root password).  It uses PAM authentication by default.
 
-- George Reid
-services at nevernet.net
+WWW: http://freshmeat.net/projects/vlock
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/security/vlock/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L security/vlock/Makefile -L security/vlock/Makefile -u -r1.2 -r1.3
--- security/vlock/Makefile
+++ security/vlock/Makefile
@@ -2,22 +2,86 @@
 # Date created:		08 Oct 2000
 # Whom:			George Reid 
 #
-# $FreeBSD: ports/security/vlock/Makefile,v 1.5 2004/02/05 20:37:48 trevor Exp $
 # $MidnightBSD$
-#
+# $FreeBSD: ports/security/vlock/Makefile,v 1.9 2008/06/19 19:35:54 pav Exp $
 
 PORTNAME=	vlock
-PORTVERSION=	1.3
-PORTREVISION=	1
+PORTVERSION=	2.2.2
 CATEGORIES=	security
-MASTER_SITES=	${MASTER_SITE_SUNSITE}
-MASTER_SITE_SUBDIR=	utils/console
+MASTER_SITES=	http://cthulhu.c3d2.de/~toidinamai/vlock/archive/
 
 MAINTAINER=	ports at MidnightBSD.org
 COMMENT=	Locks a terminal
 LICENSE=	gpl2
 
+USE_GMAKE=	yes
+HAS_CONFIGURE=	yes
+CONFIGURE_ARGS=	--enable-plugins --enable-pam \
+		--prefix=${PREFIX} \
+		--mandir=${MANPREFIX}/man \
+		--with-modules="${VLOCKMODULES}" \
+		--with-scripts="${VLOCKSCRIPTS}" \
+		VLOCK_GROUP="${VLOCKGRP}" \
+		VLOCK_MODE="0750" \
+		EXTRA_CFLAGS="-I${LOCALBASE}/include" \
+		EXTRA_LDFLAGS="-L${LOCALBASE}/lib"
+
+OPTIONS=	ROOTPWD "Enable unlock using root password" on \
+		VLOCKSCRIPTS "Install sample hook scripts" off \
+		CACASAVER "Enable libcaca screensaver" off
+
+MANLANG=	""
 MAN1=		vlock.1
-PLIST_FILES=	bin/vlock
+MAN5=		vlock-plugins.5
+MAN8=		vlock-main.8
+
+# Default scripts/modules
+VLOCKSCRIPTS=
+VLOCKMODULES=	all.so new.so
+
+# Vlock group = vlock:*:129:
+VLOCKGRP=	vlock
+VLOCKGID=	129
+
+.include 
+
+.if !defined(WITHOUT_ROOTPWD)
+CONFIGURE_ARGS+=	--enable-root-password
+.else
+CONFIGURE_ARGS+=	--disable-root-password
+.endif
+
+.if !defined(WITHOUT_VLOCKSCRIPTS)
+VLOCKSCRIPTS+=	amarok.sh example_script.sh mplayer.sh
+PLIST_SUB+=	PL_VLOCKSCRIPTS=""
+.else
+PLIST_SUB+=	PL_VLOCKSCRIPTS="@comment "
+.endif
+
+.if !defined(WITHOUT_CACASAVER)
+BUILD_DEPENDS+=	${LOCALBASE}/lib/libcaca.a:${PORTSDIR}/graphics/libcaca
+VLOCKMODULES+=	caca.so
+PLIST_SUB+=	PL_CACASAVER=""
+.else
+PLIST_SUB+=	PL_CACASAVER="@comment "
+.endif
+
+post-patch:
+	@${REINPLACE_CMD} -e 's|-lncurses|-lm|' ${WRKSRC}/modules/Makefile
+
+pre-install:
+	if ! pw groupshow ${VLOCKGRP}; then pw groupadd ${VLOCKGRP} -g ${VLOCKGID}; fi
+
+post-install:
+.if !defined(NOPORTDOCS)
+	@${MKDIR} ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/COPYING ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/ChangeLog ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/PLUGINS ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README.X11 ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/SECURITY ${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/TODO ${DOCSDIR}
+.endif
 
-.include 
+.include 
Index: distinfo
===================================================================
RCS file: /home/cvs/mports/security/vlock/distinfo,v
retrieving revision 1.1
retrieving revision 1.2
diff -L security/vlock/distinfo -L security/vlock/distinfo -u -r1.1 -r1.2
--- security/vlock/distinfo
+++ security/vlock/distinfo
@@ -1,3 +1,3 @@
-MD5 (vlock-1.3.tar.gz) = d04076f9c5f12aadc4d5fbbabf8a0c12
-SHA256 (vlock-1.3.tar.gz) = 700b8f45b6b7cdaac2185a4796870ac378015db18a7414eebee5e5b6a4131daf
-SIZE (vlock-1.3.tar.gz) = 17188
+MD5 (vlock-2.2.2.tar.gz) = 51c389ee4ef814bf59063bc367437eb8
+SHA256 (vlock-2.2.2.tar.gz) = ea875250cad150872583b6ed2436470bc5e9c3a580d85554e31a2d5ae1d92fad
+SIZE (vlock-2.2.2.tar.gz) = 54732
--- security/vlock/files/patch-ac
+++ /dev/null
@@ -1,11 +0,0 @@
---- terminal.c.orig	Sun Oct  8 18:03:19 2000
-+++ terminal.c		Sun Oct  8 18:03:24 2000
-@@ -15,7 +15,7 @@
- #include 
- #include 
- #include 
--#include 
-+#include 
- #include "vlock.h"
- 
- 
--- /dev/null
+++ security/vlock/files/patch-configure
@@ -0,0 +1,25 @@
+--- configure.orig	2008-05-18 05:10:54 -0400
++++ configure	2009-01-01 20:16:02 -0500
+@@ -220,7 +220,8 @@
+   MODULEDIR="\$(LIBDIR)/vlock/modules"
+ 
+   CC=gcc
+-  DEFAULT_CFLAGS="-O2 -Wall -W -pedantic -std=gnu99"
++  #DEFAULT_CFLAGS="-O2 -Wall -W -pedantic -std=gnu99"
++  DEFAULT_CFLAGS="-pedantic -std=gnu99"
+   DEBUG_CFLAGS="-O0 -g -Wall -W -pedantic -std=gnu99"
+   CFLAGS="${DEFAULT_CFLAGS}"
+   LD=ld
+@@ -266,6 +267,12 @@
+       CRYPT_LIB=''
+       MODULES="all.so new.so"
+     ;;
++    MidnightBSD)
++      PAM_LIBS='-lpam'
++      DL_LIB=''
++      CRYPT_LIB=''
++      MODULES="all.so new.so"
++    ;;
+   esac
+ }
+ 
--- security/vlock/files/patch-ab
+++ /dev/null
@@ -1,11 +0,0 @@
---- signals.c.orig	Sun Oct  8 18:03:19 2000
-+++ signals.c		Sun Oct  8 18:03:24 2000
-@@ -16,7 +16,7 @@
- #include 
- #include 
- #include 
--#include 
-+#include 
- #include "vlock.h"
- 
- 
--- security/vlock/files/patch-ae
+++ /dev/null
@@ -1,39 +0,0 @@
---- input.c.orig	Thu Jan 14 03:19:14 1999
-+++ input.c	Fri Feb 28 13:48:38 2003
-@@ -60,11 +60,27 @@
- #error "Shadow and PAM don't mix!"
- #endif
- 
-+#if (__FreeBSD__ == 0)            /* 1.0 did not define __FreeBSD__ */
-+#define __FreeBSD_version 199401
-+#elsif __FreeBSD__ == 1          /* 1.1 defined it to be 1 */
-+#define __FreeBSD_version 199405
-+#else                           /* 2.0 and higher define it to be 2 */
-+#include           /* and this works */
-+#endif
-+
- #include 
-+#if defined (__FreeBSD_version) && (__FreeBSD_version > 500030)
-+#include 
-+#else
- #include 
-+#endif
- 
- static struct pam_conv PAM_conversation = {
-+#if defined (__FreeBSD_version) && (__FreeBSD_version > 500030)
-+    openpam_ttyconv,
-+#else
-     &misc_conv,
-+#endif
-     NULL
- };
- 
-@@ -291,7 +307,7 @@
-   setuid(getuid());
-   setgid(getgid());
- 
--  sprintf(prompt, "%s's password: ", username);
-+  snprintf(prompt, 99, "%s's password: ", username);
- #endif /* !USE_PAM */
- }
- 
--- security/vlock/files/patch-ad
+++ /dev/null
@@ -1,46 +0,0 @@
---- vlock.c.orig	Sun Oct  8 18:03:19 2000
-+++ vlock.c		Sun Oct  8 18:03:24 2000
-@@ -14,12 +14,10 @@
- #include 
- #include 
- #include 
--#include 
- #include 
- #include 
--#include 
--#include 
- #include 
-+#include 
- #include "vlock.h"
- #include "version.h"
- 
-@@ -37,20 +35,12 @@
- 
- int main(int argc, char **argv) {
- 
--  static struct option long_options[] = { /* For parsing long arguments */
--    {"current", 0, &o_lock_all, 0},
--    {"all", 0, &o_lock_all, 1},
--    {"version", no_argument, 0, O_VERSION},
--    {"help", no_argument, 0, O_HELP},
--    {0, 0, 0, 0},
--  };
-   int option_index; /* Unused */
-   int c;
-   struct vt_mode vtm;
- 
-   /* First we parse all the command line arguments */
--  while ((c = getopt_long(argc, argv, "acvh",
--			  long_options, &option_index)) != -1) {
-+  while ((c = getopt(argc, argv, "acvh")) != -1) {
-     switch(c) {
-     case 'c':
-       o_lock_all = 0;
-@@ -107,6 +97,7 @@
-     vtm.mode = VT_PROCESS;
-     vtm.relsig = SIGUSR1; /* handled by release_vt() */
-     vtm.acqsig = SIGUSR2; /* handled by acquire_vt() */
-+    vtm.frsig = SIGUSR1;  /* needed by FreeBSD */
-     ioctl(vfd, VT_SETMODE, &vtm);
-   }
- 
--- security/vlock/files/patch-aa
+++ /dev/null
@@ -1,36 +0,0 @@
---- Makefile.orig	Thu Jan 14 01:19:14 1999
-+++ Makefile	Wed Jun 16 17:23:34 2004
-@@ -1,24 +1,19 @@
- # vlock makefile
- 
--CC = gcc
--# remove the -DUSE_PAM, -ldl, and -lpam if you aren't using PAM
--RPM_OPT_FLAGS=-O2
--CFLAGS = $(RPM_OPT_FLAGS) -DUSE_PAM
--LDFLAGS = -ldl -lpam -lpam_misc
-+CFLAGS += -DUSE_PAM
-+LDFLAGS = -lpam
- 
- OBJS = vlock.o signals.o help.o terminal.o input.o
- 
--vlock: $(OBJS)
-+all:	vlock
- 
--vlock.man: vlock.1
--	groff -man -Tascii vlock.1 > vlock.man
-+vlock:	$(OBJS)
-+	cc $(OBJS) $(LDFLAGS) -o vlock
- 
--vlock.o: vlock.h version.h
--signals.o: vlock.h
--help.o: vlock.h
--terminal.o: vlock.h
--input.o: vlock.h
-+install:
-+	/usr/bin/install -c -s -o root -g wheel -m 4555 vlock ${PREFIX}/bin
-+	/usr/bin/install -c -o root -g wheel -m 444 vlock.1 ${MANPREFIX}/man/man1
- 
- clean:
--	rm -f $(OBJS) vlock core core.vlock
-+	rm -f $(OBJS) vlock vlock.core
- 

From laffer1 at midnightbsd.org  Thu Jan  1 20:19:31 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:19:31 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: pkg-plist: update to 2.2.2
Message-ID: <200901020119.n021JV9m064023@stargazer.midnightbsd.org>

Log Message:
-----------
update to 2.2.2

Added Files:
-----------
    mports/security/vlock:
        pkg-plist (r1.1)

-------------- next part --------------
--- /dev/null
+++ security/vlock/pkg-plist
@@ -0,0 +1,20 @@
+bin/vlock
+sbin/vlock-main
+lib/vlock/modules/all.so
+lib/vlock/modules/new.so
+%%PL_CACASAVER%%lib/vlock/modules/caca.so
+ at dirrm lib/vlock/modules
+%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/amarok
+%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/example_script
+%%PL_VLOCKSCRIPTS%%lib/vlock/scripts/mplayer
+%%PL_VLOCKSCRIPTS%%@dirrm lib/vlock/scripts
+ at dirrm lib/vlock
+%%PORTDOCS%%%%DOCSDIR%%/COPYING
+%%PORTDOCS%%%%DOCSDIR%%/ChangeLog
+%%PORTDOCS%%%%DOCSDIR%%/PLUGINS
+%%PORTDOCS%%%%DOCSDIR%%/README
+%%PORTDOCS%%%%DOCSDIR%%/README.X11
+%%PORTDOCS%%%%DOCSDIR%%/SECURITY
+%%PORTDOCS%%%%DOCSDIR%%/TODO
+%%PORTDOCS%%@dirrm %%DOCSDIR%%
+ at exec if ! pw groupshow vlock 2>/dev/null; then pw groupadd vlock -g 129; fi

From ctriv at midnightbsd.org  Thu Jan  1 20:33:18 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:33:18 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: bsd.mport.mk: Change OSVERSION to refer
	to the MidnightBSD
Message-ID: <200901020133.n021XI8r065447@stargazer.midnightbsd.org>

Log Message:
-----------
Change OSVERSION to refer to the MidnightBSD version, not the FreeBSD version.
Don't check for param.h in src, it could be version that isn't at all related to 
the actual system.  Check param.h in /usr/include, and if that fails, use sysctl.

Modified Files:
--------------
    mports/Mk:
        bsd.mport.mk (r1.131 -> r1.132)

-------------- next part --------------
Index: bsd.mport.mk
===================================================================
RCS file: /home/cvs/mports/Mk/bsd.mport.mk,v
retrieving revision 1.131
retrieving revision 1.132
diff -L Mk/bsd.mport.mk -L Mk/bsd.mport.mk -u -r1.131 -r1.132
--- Mk/bsd.mport.mk
+++ Mk/bsd.mport.mk
@@ -118,12 +118,10 @@
 OSREL!=	${UNAME} -r | ${SED} -e 's/[-(].*//'
 .endif
 
-# Get __FreeBSD_version
+# Get __MidnightBSD_version
 .if !defined(OSVERSION)
 .if exists(${DESTDIR}/usr/include/sys/param.h)
-OSVERSION!=	${AWK} '/^\#define[[:blank:]]__FreeBSD_version/ {print $$3}' < ${DESTDIR}/usr/include/sys/param.h
-.elif exists(${DESTDIR}/usr/src/sys/sys/param.h)
-OSVERSION!=	${AWK} '/^\#define[[:blank:]]__FreeBSD_version/ {print $$3}' < ${DESTDIR}/usr/src/sys/sys/param.h
+OSVERSION!=	${AWK} '/^\#define[[:blank:]]__MidnightBSD_version/ {print $$3}' < ${DESTDIR}/usr/include/sys/param.h
 .else
 OSVERSION!=	${SYSCTL} -n kern.osreldate
 .endif

From ctriv at midnightbsd.org  Thu Jan  1 20:34:04 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:34:04 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020134.n021Y4hp065513@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/astro/boinc-milkyway:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/astro/boinc-milkyway/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L astro/boinc-milkyway/Makefile -L astro/boinc-milkyway/Makefile -u -r1.2 -r1.3
--- astro/boinc-milkyway/Makefile
+++ astro/boinc-milkyway/Makefile
@@ -22,7 +22,7 @@
 
 ONLY_FOR_ARCHS=	i386 amd64
 
-.if ${OSVERSION} >= 700000
+.if ${OSVERSION} >= 3000
 LIB_DEPENDS+=	c.6:${PORTSDIR}/misc/compat6x
 .endif
 

From ctriv at midnightbsd.org  Thu Jan  1 20:35:46 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:35:46 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: gcc.mk: Fix OSVERSION.
Message-ID: <200901020135.n021Zkna065882@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/Mk/extensions:
        gcc.mk (r1.1 -> r1.2)

-------------- next part --------------
Index: gcc.mk
===================================================================
RCS file: /home/cvs/mports/Mk/extensions/gcc.mk,v
retrieving revision 1.1
retrieving revision 1.2
diff -L Mk/extensions/gcc.mk -L Mk/extensions/gcc.mk -u -r1.1 -r1.2
--- Mk/extensions/gcc.mk
+++ Mk/extensions/gcc.mk
@@ -40,7 +40,7 @@
 # the base system.
 # The third field is the version as USE_GCC would use.
 #
-GCCVERSION_030402=	502126 999999 3.4
+GCCVERSION_030402=	2000 999999 3.4
 GCCVERSION_040100=	999999 999999 4.1
 GCCVERSION_040200=	999999 999999 4.2
 GCCVERSION_040300=	999999 999999 4.3

From ctriv at midnightbsd.org  Thu Jan  1 20:36:29 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:36:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: bsd.mport.mk.pod: Clean up version
	variable documentation.
Message-ID: <200901020136.n021aT1g065949@stargazer.midnightbsd.org>

Log Message:
-----------
Clean up version variable documentation.

Modified Files:
--------------
    mports/Mk/docs:
        bsd.mport.mk.pod (r1.7 -> r1.8)

-------------- next part --------------
Index: bsd.mport.mk.pod
===================================================================
RCS file: /home/cvs/mports/Mk/docs/bsd.mport.mk.pod,v
retrieving revision 1.7
retrieving revision 1.8
diff -L Mk/docs/bsd.mport.mk.pod -L Mk/docs/bsd.mport.mk.pod -u -r1.7 -r1.8
--- Mk/docs/bsd.mport.mk.pod
+++ Mk/docs/bsd.mport.mk.pod
@@ -244,10 +244,6 @@
 
 The value of __MidnightBSD_version.
 
-=item FREEBSDVERSION 
-
-The version of FreeBSD closest to your version of MidnightBSD.
-
 =item PORTOBJFORMAT
 
 The object format ("aout" or "elf").

From ctriv at midnightbsd.org  Thu Jan  1 20:37:30 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:37:30 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020137.n021bUcj066045@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/devel/ZendOptimizer:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/devel/ZendOptimizer/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L devel/ZendOptimizer/Makefile -L devel/ZendOptimizer/Makefile -u -r1.2 -r1.3
--- devel/ZendOptimizer/Makefile
+++ devel/ZendOptimizer/Makefile
@@ -26,7 +26,7 @@
 .include 
 
 VER=		6.0
-.if ${OSVERSION} >= 700043
+.if ${OSVERSION} >= 3000
 LIB_DEPENDS+=	m.4:${PORTSDIR}/misc/compat6x
 .endif
 

From ctriv at midnightbsd.org  Thu Jan  1 20:42:02 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:42:02 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: devel/gvfs: We've always had libarchive,
	don't check OSVERSION
Message-ID: <200901020142.n021g22G066541@stargazer.midnightbsd.org>

Log Message:
-----------
We've always had libarchive, don't check OSVERSION to decide to use it.

Modified Files:
--------------
    mports/devel/gvfs:
        Makefile (r1.6 -> r1.7)
        pkg-plist (r1.1 -> r1.2)

-------------- next part --------------
Index: pkg-plist
===================================================================
RCS file: /home/cvs/mports/devel/gvfs/pkg-plist,v
retrieving revision 1.1
retrieving revision 1.2
diff -L devel/gvfs/pkg-plist -L devel/gvfs/pkg-plist -u -r1.1 -r1.2
--- devel/gvfs/pkg-plist
+++ devel/gvfs/pkg-plist
@@ -28,7 +28,7 @@
 lib/libgvfscommon.so.0
 %%FUSE%%libexec/gvfs-fuse-daemon
 libexec/gvfsd
-%%ARCHIVE%%libexec/gvfsd-archive
+libexec/gvfsd-archive
 libexec/gvfsd-burn
 %%CDDA%%libexec/gvfsd-cdda
 libexec/gvfsd-computer
@@ -44,7 +44,7 @@
 %%SMB%%libexec/gvfsd-smb-browse
 libexec/gvfsd-trash
 share/dbus-1/services/gvfs-daemon.service
-%%ARCHIVE%%share/gvfs/mounts/archive.mount
+share/gvfs/mounts/archive.mount
 share/gvfs/mounts/burn.mount
 %%CDDA%%share/gvfs/mounts/cdda.mount
 share/gvfs/mounts/computer.mount
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/devel/gvfs/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L devel/gvfs/Makefile -L devel/gvfs/Makefile -u -r1.6 -r1.7
--- devel/gvfs/Makefile
+++ devel/gvfs/Makefile
@@ -73,11 +73,4 @@
 PLIST_SUB+=	GPHOTO2="@comment "
 .endif
 
-.if ${OSVERSION} < 602112
-CONFIGURE_ARGS+=	--disable-archive
-PLIST_SUB+=	ARCHIVE="@comment "
-.else
-PLIST_SUB+=	ARCHIVE=""
-.endif
-
 .include 

From laffer1 at midnightbsd.org  Thu Jan  1 20:44:11 2009
From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:44:11 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: freebsd local not ours,
	add license
Message-ID: <200901020144.n021iB2m066666@stargazer.midnightbsd.org>

Log Message:
-----------
freebsd local not ours, add license

Modified Files:
--------------
    mports/graphics/wmicons:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/graphics/wmicons/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L graphics/wmicons/Makefile -L graphics/wmicons/Makefile -u -r1.2 -r1.3
--- graphics/wmicons/Makefile
+++ graphics/wmicons/Makefile
@@ -10,7 +10,7 @@
 PORTVERSION=	1.0
 PORTREVISION=   1
 CATEGORIES=	graphics windowmaker
-MASTER_SITES=	${MASTER_SITE_LOCAL:S|%SUBDIR%|kiri/wmicons|} \
+MASTER_SITES=	${MASTER_SITE_FREEBSD_LOCAL:S|%SUBDIR%|kiri/wmicons|} \
 		${MASTER_SITE_WINDOWMAKER} \
 		${MASTER_SITE_PORTS_JP} \
 		http://www.itlb.te.noda.tus.ac.jp/~manome/wmaker/archive/
@@ -24,6 +24,7 @@
 
 MAINTAINER=	ports at MidnightBSD.org
 COMMENT=	Icons mainly for use in Window Maker
+LICENSE=	unknown
 
 GNU_CONFIGURE=	yes
 

From ctriv at midnightbsd.org  Thu Jan  1 20:45:33 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:45:33 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020145.n021jXXR067035@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/devel/qt4-corelib:
        Makefile (r1.4 -> r1.5)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/devel/qt4-corelib/Makefile,v
retrieving revision 1.4
retrieving revision 1.5
diff -L devel/qt4-corelib/Makefile -L devel/qt4-corelib/Makefile -u -r1.4 -r1.5
--- devel/qt4-corelib/Makefile
+++ devel/qt4-corelib/Makefile
@@ -69,9 +69,10 @@
 	${HEAD} -n 27 ${WRKSRC}/global/qconfig.h > ${WRKDIR}/qconfig.tmp
 	${CHMOD} 644 ${WRKSRC}/global/qconfig.h
 	${CAT} ${WRKDIR}/qconfig.tmp ${FILESDIR}/qconfig.h.in > ${WRKSRC}/global/qconfig.h
-.if ${OSVERSION} >= 700042
-	${ECHO_CMD} "#define QT_VISIBILITY_AVAILABLE" >> ${WRKSRC}/global/qconfig.h
-.endif
+# this looks to be a newer GCC thing.
+#.if ${OSVERSION} >= 3000
+#	${ECHO_CMD} "#define QT_VISIBILITY_AVAILABLE" >> ${WRKSRC}/global/qconfig.h
+#.endif
 
 
 post-install:

From ctriv at midnightbsd.org  Thu Jan  1 20:46:08 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 20:46:08 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020146.n021k8gn067095@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/editors/zile:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/editors/zile/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L editors/zile/Makefile -L editors/zile/Makefile -u -r1.2 -r1.3
--- editors/zile/Makefile
+++ editors/zile/Makefile
@@ -25,11 +25,7 @@
 
 .include 
 
-.if ${OSVERSION} > 502010
 GNU_REGEX_H=	gnu/regex.h
-.else
-GNU_REGEX_H=	gnuregex.h
-.endif
 
 post-patch:
 	@${REINPLACE_CMD} -e \

From ctriv at midnightbsd.org  Thu Jan  1 21:31:29 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:31:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: patch-aa: Fix OSVERSION.
Message-ID: <200901020231.n022VTLB071392@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/graphics/png/files:
        patch-aa (r1.4 -> r1.5)

-------------- next part --------------
Index: patch-aa
===================================================================
RCS file: /home/cvs/mports/graphics/png/files/patch-aa,v
retrieving revision 1.4
retrieving revision 1.5
diff -L graphics/png/files/patch-aa -L graphics/png/files/patch-aa -u -r1.4 -r1.5
--- graphics/png/files/patch-aa
+++ graphics/png/files/patch-aa
@@ -1,17 +1,13 @@
---- scripts/makefile.freebsd.orig	2007-06-21 02:10:26.000000000 +0400
-+++ scripts/makefile.freebsd	2007-10-13 17:24:24.000000000 +0400
-@@ -8,26 +8,27 @@
+--- ./scripts/makefile.freebsd.orig	2007-06-20 18:10:26 -0400
++++ ./scripts/makefile.freebsd	2009-01-01 21:27:38 -0500
+@@ -8,26 +8,22 @@
  LIB=		png
  SHLIB_MAJOR=	${SHLIB_VER}
  SHLIB_MINOR=	0
 -NOPROFILE=	YES
-+.if (${OSVERSION} > 600007)
+-NOOBJ=          YES
 +NO_PROFILE=     YES
 +NO_OBJ=         YES
-+.else
-+NOPROFILE=      YES
- NOOBJ=          YES
-+.endif
  
  # where make install puts libpng.a and png.h
 -DESTDIR=	${PREFIX}
@@ -36,7 +32,7 @@
  
  SRCS=	png.c pngset.c pngget.c pngrutil.c pngtrans.c pngwutil.c \
  	pngread.c pngrio.c pngwio.c pngwrite.c pngrtran.c \
-@@ -45,4 +46,22 @@
+@@ -45,4 +41,22 @@
  writelock:
  	chmod a-w *.[ch35] $(DOCS) scripts/*
  

From ctriv at midnightbsd.org  Thu Jan  1 21:33:30 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:33:30 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020233.n022XUih071570@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/java/diablo-jre16:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/java/diablo-jre16/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L java/diablo-jre16/Makefile -L java/diablo-jre16/Makefile -u -r1.2 -r1.3
--- java/diablo-jre16/Makefile
+++ java/diablo-jre16/Makefile
@@ -51,15 +51,15 @@
 
 .include 
 
-.if ${OSVERSION} >= 700000
+.if ${OSVERSION} >= 3000
 JRE_OSREL=	freebsd7
 PLIST_SUB+=	RELEASENOTE="@comment "
-.elif ${OSVERSION} >= 600000
+.elif ${OSVERSION} >= 1000
 BROKEN=		required gethostbyname_r
 JRE_OSREL=	freebsd6
 PLIST_SUB+=	RELEASENOTE=""
 .else
-IGNORE=		only available for FreeBSD 6.x/i386 and FreeBSD 6.x/amd64 and later
+IGNORE=		Somehow, you have a copy of MidnightBSD 0.0.0.  Well done!
 .endif
 
 .if ${ARCH} == "i386"

From ctriv at midnightbsd.org  Thu Jan  1 21:37:45 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:37:45 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020237.n022bjif072095@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/lang/mono:
        Makefile (r1.6 -> r1.7)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/lang/mono/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L lang/mono/Makefile -L lang/mono/Makefile -u -r1.6 -r1.7
--- lang/mono/Makefile
+++ lang/mono/Makefile
@@ -77,12 +77,8 @@
 		${WRKSRC}/mcs/class/Managed.Windows.Forms/build-csproj \
 		${WRKSRC}/mcs/class/Managed.Windows.Forms/build-csproj2k5
 
-.if ${OSVERSION} >= 700000
-	@${REINPLACE_CMD} -e 's|freebsd6|freebsd7|g' \
-		${WRKSRC}/configure ${WRKSRC}/libgc/configure
-.endif
 
-tests: build
+test: build
 	@${ECHO_MSG} "===> Running mono regression tests"
 	@(cd ${WRKSRC}/mono/tests && ${SETENV} ${MAKE_ENV} ${GMAKE} \
 		${MAKE_FLAGS} Makefile ${MAKE_ARGS} test)

From ctriv at midnightbsd.org  Thu Jan  1 21:42:14 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 21:42:14 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: makefile.lib: Fix OSVERSION.
Message-ID: <200901020242.n022gE40072622@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/math/blas/files:
        makefile.lib (r1.3 -> r1.4)

-------------- next part --------------
Index: makefile.lib
===================================================================
RCS file: /home/cvs/mports/math/blas/files/makefile.lib,v
retrieving revision 1.3
retrieving revision 1.4
diff -L math/blas/files/makefile.lib -L math/blas/files/makefile.lib -u -r1.3 -r1.4
--- math/blas/files/makefile.lib
+++ math/blas/files/makefile.lib
@@ -2,11 +2,7 @@
 FFLAGS=	@FFLAGS@
 
 LIBDIR= ${PREFIX}/lib
-.if (${OSVERSION} > 600007)
 NO_PROFILE= no
-.else
-NOPROFILE= no
-.endif
 
 SHLIB_MAJOR= 2
 

From ctriv at midnightbsd.org  Thu Jan  1 22:01:29 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:01:29 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020301.n0231TAb074649@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/multimedia/ffmpeg:
        Makefile (r1.1 -> r1.2)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/multimedia/ffmpeg/Makefile,v
retrieving revision 1.1
retrieving revision 1.2
diff -L multimedia/ffmpeg/Makefile -L multimedia/ffmpeg/Makefile -u -r1.1 -r1.2
--- multimedia/ffmpeg/Makefile
+++ multimedia/ffmpeg/Makefile
@@ -244,12 +244,9 @@
 	@${REINPLACE_CMD} -e 's|faacD|NeAACD|' ${WRKSRC}/libavcodec/libfaad.c
 # {C,LD}FLAGS safeness
 # fix x264 math, use correct log base 2 from math(3)
-.if ${OSVERSION} <= 601000
 	@${REINPLACE_CMD} -E \
 		-e 's| log2| log|' \
 		${WRKSRC}/libavcodec/libx264.c
-.endif
-
 	${REINPLACE_CMD} -e 's|$$(libdir)/pkgconfig|${FAKE_DESTDIR}${PREFIX}/libdata/pkgconfig|' \
 		${WRKSRC}/common.mak ${WRKSRC}/subdir.mak
 	@${REINPLACE_CMD} -e 's|/etc/ffserver.conf|${PREFIX}/etc/ffserver.conf|' \

From ctriv at midnightbsd.org  Thu Jan  1 22:03:28 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:03:28 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020303.n0233S8d074791@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/net/iwi-firmware:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/net/iwi-firmware/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L net/iwi-firmware/Makefile -L net/iwi-firmware/Makefile -u -r1.2 -r1.3
--- net/iwi-firmware/Makefile
+++ net/iwi-firmware/Makefile
@@ -30,6 +30,6 @@
 		ipw-${PORTVERSION}-sniffer.fw:${DRIVERNAME}-sniffer.fw \
 		ipw-${PORTVERSION}-sniffer_ucode.fw:${DRIVERNAME}-ucode-sniffer.fw
 
-MIN7OSVERSION=	700006
+MIN7OSVERSION=	3000
 
 .include "${MASTERDIR}/Makefile"

From ctriv at midnightbsd.org  Thu Jan  1 22:05:51 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:05:51 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020305.n0235pQL075186@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/sysutils/hal:
        Makefile (r1.8 -> r1.9)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/sysutils/hal/Makefile,v
retrieving revision 1.8
retrieving revision 1.9
diff -L sysutils/hal/Makefile -L sysutils/hal/Makefile -u -r1.8 -r1.9
--- sysutils/hal/Makefile
+++ sysutils/hal/Makefile
@@ -72,15 +72,11 @@
 
 .include 
 
-.if ${OSVERSION} < 505000
-IGNORE=	not supported on FreeBSD prior to 5.5-RELEASE
-.endif
-
 .if (${ARCH}=="i386" || ${ARCH}=="amd64" || ${ARCH}=="ia64")
 RUN_DEPENDS+=	dmidecode:${PORTSDIR}/sysutils/dmidecode
 .endif
 
-.if ${OSVERSION} <= 601100
+.if ${OSVERSION} <= 3000
 NEEDS_MEDIA=	yes
 PLIST_SUB+=	MEDIA=""
 .else

From ctriv at midnightbsd.org  Thu Jan  1 22:06:56 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:06:56 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020306.n0236uAC075296@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/textproc/enchant:
        Makefile (r1.2 -> r1.3)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/textproc/enchant/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -L textproc/enchant/Makefile -L textproc/enchant/Makefile -u -r1.2 -r1.3
--- textproc/enchant/Makefile
+++ textproc/enchant/Makefile
@@ -71,11 +71,9 @@
 post-patch:
 	@${REINPLACE_CMD} -e 's|MKDIRPROG-mkdir|MKDIRPROG-mkdir -p|g' \
 		${WRKSRC}/install-sh
-.if ${OSVERSION} < 700042
 	@${REINPLACE_CMD} -E -e "s|-Wunsafe-loop-optimizations ||g" \
 		-e "s|-Wno-missing-field-initializers ||g" \
 		-e "s|-Wno-attributes ||g" \
 			${WRKSRC}/configure
-.endif
 
 .include 

From ctriv at midnightbsd.org  Thu Jan  1 22:08:17 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:08:17 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020308.n0238Hqs075391@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/www/squid:
        Makefile (r1.5 -> r1.6)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/www/squid/Makefile,v
retrieving revision 1.5
retrieving revision 1.6
diff -L www/squid/Makefile -L www/squid/Makefile -u -r1.5 -r1.6
--- www/squid/Makefile
+++ www/squid/Makefile
@@ -254,10 +254,9 @@
 storage_schemes=	ufs diskd null
 .if defined(WITH_SQUID_AUFS)
 storage_schemes+=	aufs
-.if ${OSVERSION}>=501000
-# Only document libmap.conf where it is available:
+
 EXTRA_PATCHES+=		${PATCHDIR}/extra-patch-src-cf.data.pre.aufs
-.endif
+
 # Nil aufs threads is default, set any other value via SQUID_CONFIGURE_ARGS
 CONFIGURE_ARGS+=	--with-pthreads
 CFLAGS+=	${PTHREAD_CFLAGS}
@@ -337,9 +336,6 @@
 .endif
 .if defined(WITH_SQUID_PF)
 CONFIGURE_ARGS+=	--enable-pf-transparent
-.if ${OSVERSION} < 502106
-IGNORE=		pf available only in FreeBSD 5.3 and newer
-.endif
 .endif
 
 .if defined(WITH_SQUID_IPFILTER)

From ctriv at midnightbsd.org  Thu Jan  1 22:10:03 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:10:03 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020310.n023A3np075614@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/x11/gnome-panel:
        Makefile (r1.4 -> r1.5)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/x11/gnome-panel/Makefile,v
retrieving revision 1.4
retrieving revision 1.5
diff -L x11/gnome-panel/Makefile -L x11/gnome-panel/Makefile -u -r1.4 -r1.5
--- x11/gnome-panel/Makefile
+++ x11/gnome-panel/Makefile
@@ -70,12 +70,6 @@
 	@${FIND} ${WRKSRC} -type f | \
 		${XARGS} -n 10 ${REINPLACE_CMD} -e \
 		's|"applications.menu"|"gnome-applications.menu"|'
-.if ( ${OSVERSION} > 600000 && ${OSVERSION} < 600006 ) || \
-	( ${OSVERSION} < 503101 )
-.for po in da.po it.po zh_CN.po zh_TW.po
-	@${REINPLACE_CMD} -e 's|%-|%|g' ${WRKSRC}/po/${po}
-.endfor
-.endif
 
 post-install:
 	${MKDIR} ${PREFIX}/share/gnome-panel

From ctriv at midnightbsd.org  Thu Jan  1 22:11:55 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:11:55 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Fix OSVERSION.
Message-ID: <200901020311.n023Bt6e075907@stargazer.midnightbsd.org>

Log Message:
-----------
Fix OSVERSION.

Modified Files:
--------------
    mports/x11/nvidia-driver:
        Makefile (r1.6 -> r1.7)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/x11/nvidia-driver/Makefile,v
retrieving revision 1.6
retrieving revision 1.7
diff -L x11/nvidia-driver/Makefile -L x11/nvidia-driver/Makefile -u -r1.6 -r1.7
--- x11/nvidia-driver/Makefile
+++ x11/nvidia-driver/Makefile
@@ -79,13 +79,8 @@
 post-patch: .SILENT
 # We should support -CURRENT: kill the check
 	${REINPLACE_CMD} '24,26d' ${WRKSRC}/src/nv-freebsd.h
-# Fix `agpvar.h' location on recent -CURRENT
-.if ${OSVERSION} >= 800004
-	${REINPLACE_CMD} -e 's,pci/agpvar\.h,dev/agp/agpvar.h,' \
-		${WRKSRC}/src/nv-freebsd.h
-.endif
 # Building with -Werror requires prototype for suser() which was moved
-.if ${OSVERSION} >= 700048
+.if ${OSVERSION} >= 3000
 	${REINPLACE_CMD} -e '15s,^,#include ,' \
 		${WRKSRC}/src/nvidia_os.c
 .endif

From ctriv at midnightbsd.org  Thu Jan  1 22:17:31 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Thu, 1 Jan 2009 22:17:31 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: Cleanup linking with sqlite.
Message-ID: <200901020317.n023HV33076423@stargazer.midnightbsd.org>

Log Message:
-----------
Cleanup linking with sqlite.  Use the system sqlite unless it's an old version
of mbsd.

Modified Files:
--------------
    mports/databases/qt4-sqlite3-plugin:
        Makefile (r1.3 -> r1.4)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/databases/qt4-sqlite3-plugin/Makefile,v
retrieving revision 1.3
retrieving revision 1.4
diff -L databases/qt4-sqlite3-plugin/Makefile -L databases/qt4-sqlite3-plugin/Makefile -u -r1.3 -r1.4
--- databases/qt4-sqlite3-plugin/Makefile
+++ databases/qt4-sqlite3-plugin/Makefile
@@ -21,8 +21,6 @@
 
 FAKE_OPTS=	trueprefix
 
-LIB_DEPENDS+=	sqlite3:${PORTSDIR}/databases/sqlite3
-
 USE_QT_VER=	4
 QT_COMPONENTS=	moc_build sql
 QT_NONSTANDARD=	yes
@@ -34,13 +32,25 @@
 		${DISTNAME}/include/QtSql \
 		${DISTNAME}/src/sql/kernel
 MAKEFILE=	${FILESDIR}/Makefile.bsd
+
+PLIST_SUB=	DB=${DB}
+
+
+.include 
+
+
+# old mbsd versions didn't come with sqlite in core.
+.if ${OSVERSION} < 2000
+LIB_DEPENDS+=	sqlite3:${PORTSDIR}/databases/sqlite3
+.endif
+
 MAKE_ENV+=	DB="${DB}" DRIVER="${DRIVER}" MOC="${MOC}" \
 		PLUGIN="${PLUGIN}" \
 		PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
 		PTHREAD_LIBS="${PTHREAD_LIBS}"
-PLIST_SUB=	DB=${DB}
 
-pre-fake:
-	@${MKDIR} ${FAKE_DESTDIR}${PREFIX}/lib/qt4/plugins/sqldrivers
+pre-install:
+	@${MKDIR} ${PREFIX}/lib/qt4/plugins/sqldrivers
+
 
-.include 
+.include 
\ No newline at end of file

From ctriv at midnightbsd.org  Fri Jan  2 21:13:12 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:13:12 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: graphics/poppler-qt4: add poppler-qt4
Message-ID: <200901030213.n032DCOx010668@stargazer.midnightbsd.org>

Log Message:
-----------
add poppler-qt4

Added Files:
-----------
    mports/graphics/poppler-qt4:
        Makefile (r1.1)
        pkg-plist (r1.1)

-------------- next part --------------
--- /dev/null
+++ graphics/poppler-qt4/pkg-plist
@@ -0,0 +1,12 @@
+ at comment $MidnightBSD: mports/graphics/poppler-qt4/pkg-plist,v 1.1 2009/01/03 02:13:12 ctriv Exp $
+include/poppler/qt4/poppler-qt4.h
+include/poppler/qt4/poppler-link.h
+include/poppler/qt4/poppler-annotation.h
+include/poppler/qt4/poppler-form.h
+include/poppler/qt4/poppler-page-transition.h
+lib/libpoppler-qt4.so.2
+lib/libpoppler-qt4.so
+lib/libpoppler-qt4.la
+lib/libpoppler-qt4.a
+libdata/pkgconfig/poppler-qt4.pc
+ at dirrm include/poppler/qt4
--- /dev/null
+++ graphics/poppler-qt4/Makefile
@@ -0,0 +1,19 @@
+# New ports collection makefile for:	poppler-qt4
+# Date created:		June 26, 2007
+# Whom:			Michael Johnson 
+#
+# $FreeBSD: ports/graphics/poppler-qt4/Makefile,v 1.9 2008/08/04 02:28:00 mezz Exp $
+#   $MCom: ports-stable/graphics/poppler-qt4/Makefile,v 1.3 2008/06/20 17:48:14 mezz Exp $
+#
+
+PORTREVISION=	0
+PKGNAMESUFFIX=	-qt4
+
+MAINTAINER=	gnome at FreeBSD.org
+COMMENT=	Qt4 bindings to poppler
+
+MASTERDIR=	${.CURDIR}/../../graphics/poppler
+SLAVEPORT=	qt4
+PLIST=		${.CURDIR}/pkg-plist
+
+.include "${MASTERDIR}/Makefile"

From ctriv at midnightbsd.org  Fri Jan  2 21:15:15 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:15:15 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: add poppler-qt4
Message-ID: <200901030215.n032FFF8011065@stargazer.midnightbsd.org>

Log Message:
-----------
add poppler-qt4

Modified Files:
--------------
    mports/graphics:
        Makefile (r1.83 -> r1.84)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/graphics/Makefile,v
retrieving revision 1.83
retrieving revision 1.84
diff -L graphics/Makefile -L graphics/Makefile -u -r1.83 -r1.84
--- graphics/Makefile
+++ graphics/Makefile
@@ -93,6 +93,7 @@
     SUBDIR += poppler-data
     SUBDIR += poppler-gtk
     SUBDIR += poppler-qt
+    SUBDIR += poppler-qt4
     SUBDIR += poppler-utils
     SUBDIR += popplerkit
     SUBDIR += py-cairo

From ctriv at midnightbsd.org  Fri Jan  2 21:23:14 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:23:14 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: misc/chmlib: Added chmlib-0.39
Message-ID: <200901030223.n032NE8R011764@stargazer.midnightbsd.org>

Log Message:
-----------
Added chmlib-0.39

Added Files:
-----------
    mports/misc/chmlib:
        Makefile (r1.1)
        distinfo (r1.1)
        pkg-descr (r1.1)
        pkg-plist (r1.1)
    mports/misc/chmlib/files:
        patch-chm_lib.c (r1.1)
        patch-chm_lib.h (r1.1)
        patch-ltmain.sh (r1.1)

-------------- next part --------------
--- /dev/null
+++ misc/chmlib/pkg-descr
@@ -0,0 +1,7 @@
+CHMLIB is a library for dealing with Microsoft ITSS/CHM format files. Right
+now, it is a very simple library, but sufficient for dealing with all of the
+.chm files I've come across. Due to the fairly well-designed indexing built
+into this particular file format, even a small library is able to gain
+reasonably good performance indexing into ITSS archives.
+
+WWW: http://morte.jedrea.com/~jedwin/projects/chmlib/
--- /dev/null
+++ misc/chmlib/pkg-plist
@@ -0,0 +1,9 @@
+bin/chm_http
+bin/enum_chmLib
+bin/enumdir_chmLib
+bin/extract_chmLib
+bin/test_chmLib
+include/chm_lib.h
+include/lzx.h
+lib/libchm.so
+lib/libchm.so.0
--- /dev/null
+++ misc/chmlib/Makefile
@@ -0,0 +1,24 @@
+# ex:ts=8
+#
+# $MidnightBSD: mports/misc/chmlib/Makefile,v 1.1 2009/01/03 02:23:12 ctriv Exp $
+#
+
+PORTNAME=	chmlib
+PORTVERSION=	0.39
+CATEGORIES=	misc
+MASTER_SITES=	http://www.jedrea.com/chmlib/
+
+MAINTAINER=	ports at MidnightBSD.org
+COMMENT=	A library for dealing with Microsoft ITSS/CHM format files
+LICENSE=	lgpl
+
+USE_BZIP2=	yes
+GNU_CONFIGURE=	yes
+CONFIGURE_ARGS=	--disable-io64 --disable-pread --exec-prefix=${PREFIX} --disable-static --enable-examples
+USE_GMAKE=	yes
+USE_LDCONFIG=	yes
+
+post-patch:
+	@${REINPLACE_CMD} -e "s,-lpthread,${PTHREAD_LIBS}," ${WRKSRC}/configure
+
+.include 
--- /dev/null
+++ misc/chmlib/distinfo
@@ -0,0 +1,3 @@
+MD5 (chmlib-0.39.tar.bz2) = debed1a0bdded7a12d3d967e497cea9c
+SHA256 (chmlib-0.39.tar.bz2) = d2305d449eb5a2922ed3e61714074b09aae2491aa0cdbb783ab33a1744e0ff41
+SIZE (chmlib-0.39.tar.bz2) = 263013
--- /dev/null
+++ misc/chmlib/files/patch-ltmain.sh
@@ -0,0 +1,15 @@
+--- ltmain.sh.orig	Mon Jun 19 09:26:24 2006
++++ ltmain.sh	Mon Jun 19 09:26:40 2006
+@@ -6003,10 +6003,12 @@
+ 	fi
+ 
+ 	# Install the pseudo-library for information purposes.
++	if /usr/bin/false ; then
+ 	name=`$echo "X$file" | $Xsed -e 's%^.*/%%'`
+ 	instname="$dir/$name"i
+ 	$show "$install_prog $instname $destdir/$name"
+ 	$run eval "$install_prog $instname $destdir/$name" || exit $?
++	fi
+ 
+ 	# Maybe install the static library, too.
+ 	test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library"
--- /dev/null
+++ misc/chmlib/files/patch-chm_lib.h
@@ -0,0 +1,25 @@
+--- src/chm_lib.h.orig	Fri Feb 25 21:26:09 2005
++++ src/chm_lib.h	Fri Feb 25 21:26:57 2005
+@@ -78,6 +78,12 @@
+     char               path[CHM_MAX_PATHLEN+1];
+ };
+ 
++typedef struct chmUnitInfo chmUnitInfo;
++typedef struct chm_dir {
++  int nentries;
++  char **info;
++} chm_dir;
++
+ /* open an ITS archive */
+ #ifdef PPC_BSTR
+ /* RWE 6/12/2003 */
+@@ -133,6 +139,7 @@
+                       CHM_ENUMERATOR e,
+                       void *context);
+ 
++chm_dir get_names(struct chmFile *h);
+ #ifdef __cplusplus
+ }
+ #endif
+
+
--- /dev/null
+++ misc/chmlib/files/patch-chm_lib.c
@@ -0,0 +1,20 @@
+--- src/chm_lib.c.orig	Tue Apr  8 10:33:30 2003
++++ src/chm_lib.c	Tue Apr  8 10:40:56 2003
+@@ -156,6 +156,17 @@
+ typedef __int64                 Int64;
+ typedef unsigned __int64        UInt64;
+ 
++/* FreeBSD */
++#elif __FreeBSD__
++#include 
++typedef unsigned char           UChar;
++typedef int16_t                 Int16;
++typedef uint16_t                UInt16;
++typedef int32_t                 Int32;
++typedef uint32_t                UInt32;
++typedef int64_t                 Int64;
++typedef uint64_t                UInt64;
++
+ /* I386, 32-bit, non-Windows */
+ /* Sparc        */
+ /* MIPS         */

From ctriv at midnightbsd.org  Fri Jan  2 21:23:28 2009
From: ctriv at midnightbsd.org (ctriv at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:23:28 -0500 (EST)
Subject: [Midnightbsd-cvs] mports: Makefile: added: chmlib,
	koffice-i18n-sr@Latn, wmweather+.
Message-ID: <200901030223.n032NSbS011814@stargazer.midnightbsd.org>

Log Message:
-----------
added: chmlib, koffice-i18n-sr at Latn, wmweather+.

Modified Files:
--------------
    mports/misc:
        Makefile (r1.52 -> r1.53)

-------------- next part --------------
Index: Makefile
===================================================================
RCS file: /home/cvs/mports/misc/Makefile,v
retrieving revision 1.52
retrieving revision 1.53
diff -L misc/Makefile -L misc/Makefile -u -r1.52 -r1.53
--- misc/Makefile
+++ misc/Makefile
@@ -4,6 +4,7 @@
     COMMENT = Miscellaneous utilities
 
     SUBDIR += brs
+    SUBDIR += chmlib
     SUBDIR += compat4x
     SUBDIR += compat5x
     SUBDIR += cpuid

From smultron at midnightbsd.org  Fri Jan  2 21:23:35 2009
From: smultron at midnightbsd.org (smultron at midnightbsd.org)
Date: Fri, 2 Jan 2009 21:23:35 -0500 (EST)
Subject: [Midnightbsd-cvs] www: /www: add xfce to featured
Message-ID: <200901030223.n032NZhl011884@stargazer.midnightbsd.org>

Log Message:
-----------
add xfce to featured

Modified Files:
--------------
    www:
        index.html (r1.62 -> r1.63)
    www/images/ports:
        001.png (r1.1 -> r1.2)
    www/featured:
        index.html (r1.6 -> r1.7)

-------------- next part --------------
Index: index.html
===================================================================
RCS file: /home/cvs/www/index.html,v
retrieving revision 1.62
retrieving revision 1.63
diff -L index.html -L index.html -u -r1.62 -r1.63
--- index.html
+++ index.html
@@ -49,6 +49,7 @@
 				
 				
Index: index.html =================================================================== RCS file: /home/cvs/www/featured/index.html,v retrieving revision 1.6 retrieving revision 1.7 diff -L featured/index.html -L featured/index.html -u -r1.6 -r1.7 --- featured/index.html +++ featured/index.html @@ -29,6 +29,13 @@

Featured Ports

+ -

Software descriptions taken from their respective Wikipedia articles


From ctriv at midnightbsd.org Fri Jan 2 21:40:53 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Fri, 2 Jan 2009 21:40:53 -0500 (EST) Subject: [Midnightbsd-cvs] mports: graphics/djvulibre-nox11: Added djvulibre-nox11-3.5.21 Message-ID: <200901030240.n032erHg013723@stargazer.midnightbsd.org> Log Message: ----------- Added djvulibre-nox11-3.5.21 Added Files: ----------- mports/graphics/djvulibre-nox11: Makefile (r1.1) distinfo (r1.1) pkg-descr (r1.1) pkg-plist (r1.1) mports/graphics/djvulibre-nox11/files: patch-config_ltmain.sh (r1.1) patch-configure (r1.1) patch-desktopfiles_Makefile.in (r1.1) patch-tools_any2djvu (r1.1) -------------- next part -------------- --- /dev/null +++ graphics/djvulibre-nox11/pkg-descr @@ -0,0 +1,14 @@ +DjVu is a web-centric format and software platform for distributing +documents and images. DjVu was originally developped at AT&T +Labs-Research. In March 2000, AT&T sold DjVu to LizardTech Inc. who +now distributes Windows/Mac plug-ins, and commercial encoders (mostly +on Windows) + +The LizardTech released the reference implementation of DjVu under +the GNU GPL in October 2000. DjVuLibre (which means free DjVu), is +an enhanced version of that code maintained by the original inventors +of DjVu. It is compatible with version 3.5 of the LizardTech DjVu +software suite. + +Author: Leon Bottou +WWW: http://djvu.sourceforge.net/ --- /dev/null +++ graphics/djvulibre-nox11/pkg-plist @@ -0,0 +1,62 @@ +%%ANY2DJVU%%bin/any2djvu +bin/bzz +bin/c44 +bin/cjb2 +bin/cpaldjvu +bin/csepdjvu +bin/ddjvu +bin/djvm +bin/djvmcvt +bin/djvudigital +bin/djvudump +bin/djvuextract +bin/djvumake +bin/djvups +bin/djvused +bin/djvuserve +bin/djvutoxml +bin/djvutxt +bin/djvuxmlparser +include/libdjvu/ddjvuapi.h +include/libdjvu/miniexp.h +lib/libdjvulibre.so +lib/libdjvulibre.so.21 +libdata/pkgconfig/ddjvuapi.pc +share/djvu/osi/cs/messages.xml +share/djvu/osi/de/libdjvu++.xml +share/djvu/osi/de/messages.xml +share/djvu/osi/desktop/djvulibre-mime.xml +share/djvu/osi/desktop/hi22-djvu.png +share/djvu/osi/desktop/hi32-djvu.png +share/djvu/osi/desktop/hi48-djvu.png +share/djvu/osi/desktop/register-djvu-mime +share/djvu/osi/en/djvutools-reference.xml +share/djvu/osi/en/libdjvu++.xml +share/djvu/osi/en/messages.xml +share/djvu/osi/en/unixgui-shared.xml +share/djvu/osi/en/unixgui-viewer.xml +share/djvu/osi/fr/libdjvu++.xml +share/djvu/osi/fr/messages.xml +share/djvu/osi/ja/libdjvu++.xml +share/djvu/osi/ja/messages.xml +share/djvu/osi/languages.xml +share/djvu/osi/zh/libdjvu++.xml +share/djvu/osi/zh/messages.xml +share/djvu/pubtext/DjVuMessages.dtd +share/djvu/pubtext/DjVuOCR.dtd +share/djvu/pubtext/DjVuXML-s.dtd + at dirrm share/djvu/pubtext + at dirrm share/djvu/osi/zh + at dirrm share/djvu/osi/ja + at dirrm share/djvu/osi/fr + at dirrm share/djvu/osi/en + at dirrm share/djvu/osi/desktop + at dirrm share/djvu/osi/de + at dirrm share/djvu/osi/cs + at dirrm share/djvu/osi + at dirrmtry share/djvu + at dirrmtry man/fr/man1 + at dirrmtry man/fr + at dirrmtry man/de/man1 + at dirrmtry man/de + at dirrm include/libdjvu --- /dev/null +++ graphics/djvulibre-nox11/Makefile @@ -0,0 +1,82 @@ +# Date Created: 20 July 1999 +# +# $MidnightBSD: mports/graphics/djvulibre-nox11/Makefile,v 1.1 2009/01/03 02:40:50 ctriv Exp $ +# + +PORTNAME= djvulibre +PORTVERSION= 3.5.21 +PORTREVISION= 0 +CATEGORIES= graphics www +MASTER_SITES= SF/djvu +PKGNAMESUFFIX= -nox11 + +MAINTAINER= ports at MidnightBSD.org +COMMENT= DjVu base libraries and utilities +LICENSE= gpl2 + +LIB_DEPENDS= jpeg.9:${PORTSDIR}/graphics/jpeg \ + tiff.4:${PORTSDIR}/graphics/tiff + +USE_ICONV= yes +USE_GNOME= gnomehack gnometarget +GNU_CONFIGURE= yes +CONFIGURE_ENV= JPEG_CFLAGS="-I${LOCALBASE}/include" \ + JPEG_LIBS="-L${LOCALBASE}/lib -ljpeg" \ + TIFF_CFLAGS="-I${LOCALBASE}/include" \ + TIFF_LIBS="-L${LOCALBASE}/lib -ltiff" \ + PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \ + PTHREAD_LIBS="${PTHREAD_LIBS}" \ + LOCALBASE="${LOCALBASE}" \ + CXX="${CXX}" +CONFIGURE_ARGS= --enable-threads=pthread --enable-shared +USE_LDCONFIG= yes + +OPTIONS= ANY2DJVU "Install any2djvu script (requires curl)" off + +MANLANG= "" ja +MAN1= bzz.1 c44.1 cjb2.1 cpaldjvu.1 csepdjvu.1 ddjvu.1 djvm.1 \ + djvmcvt.1 djvu.1 djvudump.1 djvuextract.1 djvumake.1 djvups.1 \ + djvused.1 djvuserve.1 djvutxt.1 +MAN1_EN= djvutoxml.1 djvuxml.1 djvuxmlparser.1 djvudigital.1 + +PORTDOCS= djvu2spec.djvu lizard2002.djvu + +CONFIGURE_ARGS+= --disable-djview --without-x + +.include + +.if defined(WITH_ANY2DJVU) +MAN1_EN+= any2djvu.1 +RUN_DEPENDS+= curl:${PORTSDIR}/ftp/curl +PLIST_SUB+= ANY2DJVU="" +.else +PLIST_SUB+= ANY2DJVU="@comment " +.endif + +post-patch: + @${REINPLACE_CMD} -e \ + 's|$${libdir}/pkgconfig|${PREFIX}/libdata/pkgconfig|' \ + ${WRKSRC}/libdjvu/Makefile.in + @${REINPLACE_CMD} -e '/-O\*/d ; \ + s|$$OPTS -O3|$$OPTS|g ; \ + s|$$OPTS -O2|$$OPTS|g ; \ + s|$$OPTS $$opt|$$OPTS|g' ${WRKSRC}/configure + @${FIND} ${WRKSRC} -name "Makefile.in" | ${XARGS} ${REINPLACE_CMD} -e \ + 's|= @CPPFLAGS|= $${FLAGS} @CPPFLAGS|g ; \ + s|@ $${FLAGS}|@|g ; \ + s|} $${FLAGS}|}|g ; \ + s|/netscape/|/djvulibre/|g ; \ + s|eucjp|eucJP|g ; \ + s|_PROGRAM} -m|} -m|g' +.if !defined(WITH_ANY2DJVU) + @${REINPLACE_CMD} -e 's,any2djvu,,' ${WRKSRC}/tools/Makefile.in +.endif + + +post-install: +.if !defined(NOPORTDOCS) + @${MKDIR} ${DOCSDIR} + ${INSTALL_DATA} ${PORTDOCS:S,^,${WRKSRC}/doc/,} ${DOCSDIR}/ +.endif + +.include --- /dev/null +++ graphics/djvulibre-nox11/distinfo @@ -0,0 +1,3 @@ +MD5 (djvulibre-3.5.21.tar.gz) = 4c6f3eb03ffbd067b6d2fe2344b0d9ad +SHA256 (djvulibre-3.5.21.tar.gz) = 39f80c1810be22c5ea7f6a44bbb449c3e29902895dcff9da6a8440891a67b8b4 +SIZE (djvulibre-3.5.21.tar.gz) = 2993718 --- /dev/null +++ graphics/djvulibre-nox11/files/patch-tools_any2djvu @@ -0,0 +1,95 @@ +--- tools/any2djvu.orig 2008-02-17 20:18:08.000000000 +0300 ++++ tools/any2djvu 2008-02-17 20:20:31.000000000 +0300 +@@ -1,11 +1,11 @@ +-#! /bin/bash -f ++#!/bin/sh + # CVS version control block - do not edit manually + # $RCSfile: any2djvu,v $ + # $Revision: 1.3 $ + # $Date: 2007/08/10 08:08:55 $ + # $Source: /cvsroot/djvu/djvulibre-3.5/tools/any2djvu,v $ + +-function copyright() ++copyright() + { + echo "Copyright (C) 2002 David Kreil " + echo "Modified by Barak A. Pearlmutter " +@@ -14,7 +14,7 @@ + echo "Released under the GNU GPL v2, 21-Oct-2002." + } + +-function warranty() ++warranty() + { + echo "This program is distributed in the hope that it will be useful," + echo "but WITHOUT ANY WARRANTY; without even the implied warranty of" +@@ -22,7 +22,7 @@ + echo "GNU General Public License for more details." + } + +-function disclaimer() ++disclaimer() + { + echo "By using this tool you accept the following disclaimer:" + echo " Because the any2djvu service is free of charge, there is no" +@@ -40,7 +40,7 @@ + ocr=1 + docformat=2 + +-function warn() ++warn() + { + echo "Notes:" + echo " - Internet connection is required." +@@ -53,7 +53,7 @@ + echo " - This software comes with NO WARRANTY." + } + +-function format_help() ++format_help() + { + echo "Codes for the formats of the input documents to use with -f" + echo " 1 - DjVu Document (for verification or OCR)" +@@ -67,7 +67,7 @@ + echo " 9 - Scanned Document - Color/Mixed - >400 dpi" + } + +-function usage() ++usage() + { + echo "Convert files from .ps/.ps.gz/.pdf to .djvu" + echo "Usage: $0 [options] [url] {filename(s)}" +@@ -123,13 +123,13 @@ + fi + + # check OCR option +-if [ ! "x$ocr" == x0 ] && [ ! "x$ocr" == x1 ]; then ++if [ ! "x$ocr" = x0 ] && [ ! "x$ocr" = x1 ]; then + echo 'error: -o OCR must be 0 or 1' + exit 2 + fi + + # if help is requested or docformat is not specified right - show help +-if [ "x$docformat" == x'help' ]; then ++if [ "x$docformat" = x'help' ]; then + format_help + exit 0 + fi +@@ -215,7 +215,7 @@ + -F ocr=$ocr -F legal=1 "$rurl/$rcgi" \ + | eval tee "'$log'" $shellopts + else +- wget $wgetopts -O - "$rurl/$rcgi?urlupload=$lurl/$in$cgiopts" \ ++ /usr/bin/fetch$wgetopts -o - "$rurl/$rcgi?urlupload=$lurl/$in$cgiopts" \ + | eval tee "'$log'" $shellopts + fi + l=`egrep 'href=djvu/.*\.djvu' "$log"` +@@ -225,7 +225,7 @@ + echo "error: something got wrong. check log file" + exit 1 + fi +- wget $wgetopts -O "$b.djvu" "$rurl/$l" ++ /usr/bin/fetch $wgetopts -o $b.djvu "$rurl/$l" + + [ -z "$doclean" ] || rm "$log" + [ -z $silent ] && ls -l "$b.djvu" --- /dev/null +++ graphics/djvulibre-nox11/files/patch-desktopfiles_Makefile.in @@ -0,0 +1,28 @@ +--- desktopfiles/Makefile.in.orig 2007-09-10 20:23:30.000000000 +0400 ++++ desktopfiles/Makefile.in 2007-09-10 20:55:26.000000000 +0400 +@@ -29,6 +29,7 @@ + + INSTALL = @INSTALL@ + INSTALL_PROGRAM = @INSTALL_PROGRAM@ ++INSTALL_SCRIPT = @INSTALL_SCRIPT@ + INSTALL_DATA = @INSTALL_DATA@ + XDG_MIME = @XDG_MIME@ + XDG_ICON_RESOURCE = @XDG_ICON_RESOURCE@ +@@ -71,7 +72,7 @@ + + install-djvu-files: FORCE + ${INSTALL} -d ${DESTDIR}${datadir_djvu} +- ${INSTALL_PROGRAM} register-djvu-mime ${DESTDIR}${datadir_djvu} ++ ${INSTALL_SCRIPT} register-djvu-mime ${DESTDIR}${datadir_djvu} + ${INSTALL_DATA} ${srcdir}/*djvu.png ${DESTDIR}${datadir_djvu} + ${INSTALL_DATA} ${srcdir}/*mime.xml ${DESTDIR}${datadir_djvu} + - at echo "Run ${datadir_djvu}/register-djvu-mime install" +@@ -79,7 +80,7 @@ + + install-djview-files: FORCE + ${INSTALL} -d ${DESTDIR}${datadir_djview} +- ${INSTALL_PROGRAM} register-djview-menu ${DESTDIR}${datadir_djview} ++ ${INSTALL_SCRIPT} register-djview-menu ${DESTDIR}${datadir_djview} + ${INSTALL_DATA} ${srcdir}/*djview3.png ${DESTDIR}${datadir_djview} + ${INSTALL_DATA} ${srcdir}/*djview3.desktop ${DESTDIR}${datadir_djview} + - at echo "Run ${datadir_djview}/register-djview-menu install" --- /dev/null +++ graphics/djvulibre-nox11/files/patch-configure @@ -0,0 +1,10 @@ +--- configure.orig 2008-08-26 14:48:20.000000000 +0400 ++++ configure 2008-08-26 14:48:36.000000000 +0400 +@@ -21689,6 +21689,7 @@ + __sync_lock_test_and_set(&l,1); + __sync_lock_release(&l); + __sync_add_and_fetch(&l,1); ++ __sync_bool_compare_and_swap(&l,&l,1); + return 0; + ; + return 0; --- /dev/null +++ graphics/djvulibre-nox11/files/patch-config_ltmain.sh @@ -0,0 +1,17 @@ +--- config/ltmain.sh.orig 2008-08-26 16:13:33.000000000 +0400 ++++ config/ltmain.sh 2008-08-26 16:14:40.000000000 +0400 +@@ -6002,14 +6002,6 @@ + IFS="$save_ifs" + fi + +- # Install the pseudo-library for information purposes. +- name=`$echo "X$file" | $Xsed -e 's%^.*/%%'` +- instname="$dir/$name"i +- $show "$install_prog $instname $destdir/$name" +- $run eval "$install_prog $instname $destdir/$name" || exit $? +- +- # Maybe install the static library, too. +- test -n "$old_library" && staticlibs="$staticlibs $dir/$old_library" + ;; + + *.lo) From ctriv at midnightbsd.org Fri Jan 2 21:42:35 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Fri, 2 Jan 2009 21:42:35 -0500 (EST) Subject: [Midnightbsd-cvs] mports: Makefile: add djvulibre-nox11 Message-ID: <200901030242.n032gZZp013837@stargazer.midnightbsd.org> Log Message: ----------- add djvulibre-nox11 Modified Files: -------------- mports/graphics: Makefile (r1.84 -> r1.85) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/graphics/Makefile,v retrieving revision 1.84 retrieving revision 1.85 diff -L graphics/Makefile -L graphics/Makefile -u -r1.84 -r1.85 --- graphics/Makefile +++ graphics/Makefile @@ -11,6 +11,7 @@ SUBDIR += cairo SUBDIR += cairomm SUBDIR += dia + SUBDIR += djvulibre-nox11 SUBDIR += dri SUBDIR += eog SUBDIR += etoile-distributedview From ctriv at midnightbsd.org Fri Jan 2 21:47:18 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Fri, 2 Jan 2009 21:47:18 -0500 (EST) Subject: [Midnightbsd-cvs] mports: bsd.mport.mk: Display the various stage messages in bold. Message-ID: <200901030247.n032lIf8014295@stargazer.midnightbsd.org> Log Message: ----------- Display the various stage messages in bold. Modified Files: -------------- mports/Mk: bsd.mport.mk (r1.132 -> r1.133) -------------- next part -------------- Index: bsd.mport.mk =================================================================== RCS file: /home/cvs/mports/Mk/bsd.mport.mk,v retrieving revision 1.132 retrieving revision 1.133 diff -L Mk/bsd.mport.mk -L Mk/bsd.mport.mk -u -r1.132 -r1.133 --- Mk/bsd.mport.mk +++ Mk/bsd.mport.mk @@ -2919,25 +2919,25 @@ .ORDER: ${_INSTALL_DEP} ${_INSTALL_SEQ} extract-message: - @${ECHO_MSG} "===> Extracting for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Extracting for ${PKGNAME}\033[0m" patch-message: - @${ECHO_MSG} "===> Patching for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Patching for ${PKGNAME}\033[0m" configure-message: - @${ECHO_MSG} "===> Configuring for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Configuring for ${PKGNAME}\033[0m" build-message: - @${ECHO_MSG} "===> Building for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Building for ${PKGNAME}\033[0m" fake-message: - @${ECHO_MSG} "===> Faking install for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Faking install for ${PKGNAME}\033[0m" install-message: .if !defined(DESTDIR) - @${ECHO_MSG} "===> Installing ${PKGFILE}" + @${ECHO_MSG} -e "\033[1m===> Installing ${PKGFILE}\033[0m" .else - @${ECHO_MSG} "===> Installing ${PKGFILE} into ${DESTDIR}" + @${ECHO_MSG} -e "\033[1m===> Installing ${PKGFILE} into ${DESTDIR}\033[0m" .endif package-message: - @${ECHO_MSG} "===> Building package for ${PKGNAME}" + @${ECHO_MSG} -e "\033[1m===> Building package for ${PKGNAME}\033[0m" done-message: - @${ECHO_MSG} "===> Done." + @${ECHO_MSG} -e "\033[1m===> Done.\033[0m" # Empty pre-* and post-* targets From smultron at midnightbsd.org Fri Jan 2 21:56:10 2009 From: smultron at midnightbsd.org (smultron at midnightbsd.org) Date: Fri, 2 Jan 2009 21:56:10 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: corrected description Message-ID: <200901030256.n032uAYs015278@stargazer.midnightbsd.org> Log Message: ----------- corrected description Modified Files: -------------- www/featured: index.html (r1.7 -> r1.8) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/featured/index.html,v retrieving revision 1.7 retrieving revision 1.8 diff -L featured/index.html -L featured/index.html -u -r1.7 -r1.8 --- featured/index.html +++ featured/index.html @@ -34,7 +34,7 @@ -

is a free software desktop environment for Unix and other Unix-like platforms, such as Linux, Solaris and BSD. It aims to be fast and lightweight, while still being visually appealing and easy to use. It is based on the GTK+ 2 toolkit (as is GNOME). It uses the Xfwm window manager, described below. Its configuration is entirely mouse-driven, and the configuration files are hidden from the casual user.

+

Xfce is a free software desktop environment for Unix and other Unix-like platforms, such as Linux, Solaris and BSD. It aims to be fast and lightweight, while still being visually appealing and easy to use. It is based on the GTK+ 2 toolkit (as is GNOME). It uses the Xfwm window manager, described below. Its configuration is entirely mouse-driven, and the configuration files are hidden from the casual user.

+ + + + + From laffer1 at midnightbsd.org Sat Jan 10 21:25:50 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:25:50 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: use footer include Message-ID: <200901110225.n0B2PoLD086588@stargazer.midnightbsd.org> Log Message: ----------- use footer include Modified Files: -------------- www: index.html (r1.63 -> r1.64) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/index.html,v retrieving revision 1.63 retrieving revision 1.64 diff -L index.html -L index.html -u -r1.63 -r1.64 --- index.html +++ index.html @@ -63,10 +63,10 @@

Security »

-

December 31, 2008

-

Correct a problem where bluetooth and netgraph sockets...

-

Read more...

-
+

December 31, 2008

+

Correct a problem where bluetooth and netgraph sockets...

+

Read more...

+

November 24, 2008

Correct a problem in arc4random which causes the device...

@@ -74,42 +74,6 @@
-

-
- - - - - - - + From laffer1 at midnightbsd.org Sat Jan 10 21:31:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:31:19 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: Add new security advisory. Message-ID: <200901110231.n0B2VJQq087128@stargazer.midnightbsd.org> Log Message: ----------- Add new security advisory. Fix footer. Modified Files: -------------- www/security: index.html (r1.12 -> r1.13) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/security/index.html,v retrieving revision 1.12 retrieving revision 1.13 diff -L security/index.html -L security/index.html -u -r1.12 -r1.13 --- security/index.html +++ security/index.html @@ -14,13 +14,19 @@
-
+

Security Updates

+
+

January 10, 2009

+

Fix two issues with MidnightBSD 0.2.1 and 0.3-CURRENT. The first is in OpenSSL and would allow applications that use OpenSSL to interpret an + invalid certificate as valid. The second is in lukemftpd(8) + that could allow long commands to be split into multiple commands.

+
-

December 31, 2008

-

Correct a problem where bluetooth and netgraph sockets were not initialized properly. This is available in RELENG_0_2, RELENG_0_1, and current.

-
+

December 31, 2008

+

Correct a problem where bluetooth and netgraph sockets were not initialized properly. This is available in RELENG_0_2, RELENG_0_1, and current.

+

November 24, 2008

Correct a problem in arc4random which causes the device not to get enough entropy for system services. ?Geom classes initialized at startup will still have problems. Update your system to @@ -114,42 +120,6 @@

A "symlink" exploit was found in the MidnightBSD jail system. A fix was made available. Please update your /etc/rc.d/jail file from cvs. Patches will not be created until our first release.

-

-
- -
- - - - - + From laffer1 at midnightbsd.org Sat Jan 10 21:40:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:40:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/netinet6: IPV6 and arc4random Message-ID: <200901110240.n0B2etoc088157@stargazer.midnightbsd.org> Log Message: ----------- IPV6 and arc4random Modified Files: -------------- src/sys/dev/random: randomdev.c (r1.2 -> r1.3) randomdev_soft.c (r1.4 -> r1.5) src/sys/netinet6: in6.h (r1.5 -> r1.6) in6_proto.c (r1.4 -> r1.5) nd6.h (r1.3 -> r1.4) nd6_nbr.c (r1.3 -> r1.4) -------------- next part -------------- Index: randomdev.c =================================================================== RCS file: /home/cvs/src/sys/dev/random/randomdev.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/random/randomdev.c -L sys/dev/random/randomdev.c -u -r1.2 -r1.3 --- sys/dev/random/randomdev.c +++ sys/dev/random/randomdev.c @@ -90,6 +90,7 @@ && (securelevel_gt(td->td_ucred, 0) == 0)) { (*random_systat.reseed)(); random_systat.seeded = 1; + arc4rand(NULL, 0, 1); /* Reseed arc4random as well. */ } return (0); Index: randomdev_soft.c =================================================================== RCS file: /home/cvs/src/sys/dev/random/randomdev_soft.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/random/randomdev_soft.c -L sys/dev/random/randomdev_soft.c -u -r1.4 -r1.5 --- sys/dev/random/randomdev_soft.c +++ sys/dev/random/randomdev_soft.c @@ -61,6 +61,7 @@ u_int, u_int, enum esource); static int random_yarrow_poll(int event,struct thread *td); static int random_yarrow_block(int flag); +static void random_yarrow_flush_reseed(void); struct random_systat random_yarrow = { .ident = "Software, Yarrow", @@ -70,7 +71,7 @@ .read = random_yarrow_read, .write = random_yarrow_write, .poll = random_yarrow_poll, - .reseed = random_yarrow_reseed, + .reseed = random_yarrow_flush_reseed, .seeded = 1, }; @@ -96,7 +97,7 @@ /* Harvested entropy */ static struct entropyfifo harvestfifo[ENTROPYSOURCE]; -/* <0 to end the kthread, 0 to let it run */ +/* <0 to end the kthread, 0 to let it run, 1 to flush the harvest queues */ static int random_kthread_control = 0; static struct proc *random_kthread_proc; @@ -241,7 +242,7 @@ local_count = 0; /* Process until told to stop */ - for (; random_kthread_control == 0;) { + for (; random_kthread_control >= 0;) { active = 0; @@ -276,6 +277,13 @@ KASSERT(local_count == 0, ("random_kthread: local_count %d", local_count)); + /* + * If a queue flush was commanded, it has now happened, + * and we can mark this by resetting the command. + */ + if (random_kthread_control == 1) + random_kthread_control = 0; + /* Found nothing, so don't belabour the issue */ if (!active) pause("-", hz / 10); @@ -400,3 +408,15 @@ return error; } + +/* Helper routine to perform explicit reseeds */ +static void +random_yarrow_flush_reseed(void) +{ + /* Command a entropy queue flush and wait for it to finish */ + random_kthread_control = 1; + while (random_kthread_control) + pause("-", hz / 10); + + random_yarrow_reseed(); +} Index: in6_proto.c =================================================================== RCS file: /home/cvs/src/sys/netinet6/in6_proto.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/netinet6/in6_proto.c -L sys/netinet6/in6_proto.c -u -r1.4 -r1.5 --- sys/netinet6/in6_proto.c +++ sys/netinet6/in6_proto.c @@ -393,6 +393,7 @@ #ifdef IPSTEALTH int ip6stealth = 0; #endif +int nd6_onlink_ns_rfc4861 = 0; /* allow 'on-link' nd6 NS (as in RFC 4861) */ /* icmp6 */ /* @@ -566,3 +567,6 @@ nd6_maxnudhint, CTLFLAG_RW, &nd6_maxnudhint, 0, ""); SYSCTL_INT(_net_inet6_icmp6, ICMPV6CTL_ND6_DEBUG, nd6_debug, CTLFLAG_RW, &nd6_debug, 0, ""); +SYSCTL_INT(_net_inet6_icmp6, ICMPV6CTL_ND6_ONLINKNSRFC4861, + nd6_onlink_ns_rfc4861, CTLFLAG_RW, &nd6_onlink_ns_rfc4861, 0, + "Accept 'on-link' nd6 NS in compliance with RFC 4861."); Index: in6.h =================================================================== RCS file: /home/cvs/src/sys/netinet6/in6.h,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/netinet6/in6.h -L sys/netinet6/in6.h -u -r1.5 -r1.6 --- sys/netinet6/in6.h +++ sys/netinet6/in6.h @@ -600,7 +600,9 @@ /* New entries should be added here from current IPV6CTL_MAXID value. */ /* to define items, should talk with KAME guys first, for *BSD compatibility */ #define IPV6CTL_STEALTH 45 -#define IPV6CTL_MAXID 46 + +#define ICMPV6CTL_ND6_ONLINKNSRFC4861 47 +#define IPV6CTL_MAXID 48 #endif /* __BSD_VISIBLE */ /* Index: nd6_nbr.c =================================================================== RCS file: /home/cvs/src/sys/netinet6/nd6_nbr.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/netinet6/nd6_nbr.c -L sys/netinet6/nd6_nbr.c -u -r1.3 -r1.4 --- sys/netinet6/nd6_nbr.c +++ sys/netinet6/nd6_nbr.c @@ -144,6 +144,24 @@ "(wrong ip6 dst)\n")); goto bad; } + } else if (!nd6_onlink_ns_rfc4861) { + struct sockaddr_in6 src_sa6; + + /* + * According to recent IETF discussions, it is not a good idea + * to accept a NS from an address which would not be deemed + * to be a neighbor otherwise. This point is expected to be + * clarified in future revisions of the specification. + */ + bzero(&src_sa6, sizeof(src_sa6)); + src_sa6.sin6_family = AF_INET6; + src_sa6.sin6_len = sizeof(src_sa6); + src_sa6.sin6_addr = saddr6; + if (!nd6_is_addr_neighbor(&src_sa6, ifp)) { + nd6log((LOG_INFO, "nd6_ns_input: " + "NS packet from non-neighbor\n")); + goto bad; + } } if (IN6_IS_ADDR_MULTICAST(&taddr6)) { Index: nd6.h =================================================================== RCS file: /home/cvs/src/sys/netinet6/nd6.h,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/netinet6/nd6.h -L sys/netinet6/nd6.h -u -r1.3 -r1.4 --- sys/netinet6/nd6.h +++ sys/netinet6/nd6.h @@ -340,6 +340,7 @@ extern struct nd_drhead nd_defrouter; extern struct nd_prhead nd_prefix; extern int nd6_debug; +extern int nd6_onlink_ns_rfc4861; #define nd6log(x) do { if (nd6_debug) log x; } while (/*CONSTCOND*/ 0) From laffer1 at midnightbsd.org Sat Jan 10 21:41:57 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:41:57 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/netinet6: icmp ipv6 Message-ID: <200901110241.n0B2fvlI088249@stargazer.midnightbsd.org> Log Message: ----------- icmp ipv6 Modified Files: -------------- src/sys/netinet6: icmp6.c (r1.4 -> r1.5) icmp6.c.orig (r1.1 -> r1.2) -------------- next part -------------- Index: icmp6.c.orig =================================================================== RCS file: /home/cvs/src/sys/netinet6/icmp6.c.orig,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/netinet6/icmp6.c.orig -L sys/netinet6/icmp6.c.orig -u -r1.1 -r1.2 --- sys/netinet6/icmp6.c.orig +++ sys/netinet6/icmp6.c.orig @@ -1,3 +1,4 @@ +/* $MidnightBSD$ */ /* $FreeBSD: src/sys/netinet6/icmp6.c,v 1.80 2007/07/05 16:29:39 delphij Exp $ */ /* $KAME: icmp6.c,v 1.211 2001/04/04 05:56:20 itojun Exp $ */ Index: icmp6.c =================================================================== RCS file: /home/cvs/src/sys/netinet6/icmp6.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/netinet6/icmp6.c -L sys/netinet6/icmp6.c -u -r1.4 -r1.5 --- sys/netinet6/icmp6.c +++ sys/netinet6/icmp6.c @@ -1118,6 +1118,15 @@ if (!validated) return; + /* + * In case the suggested mtu is less than IPV6_MMTU, we + * only need to remember that it was for above mentioned + * "alwaysfrag" case. + * Try to be as close to the spec as possible. + */ + if (mtu < IPV6_MMTU) + mtu = IPV6_MMTU - 8; + bzero(&inc, sizeof(inc)); inc.inc_flags = 1; /* IPv6 */ inc.inc6_faddr = *dst; From laffer1 at midnightbsd.org Sat Jan 10 21:42:32 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:42:32 -0500 (EST) Subject: [Midnightbsd-cvs] src: icmp6.c.orig: doh Message-ID: <200901110242.n0B2gWZN088329@stargazer.midnightbsd.org> Log Message: ----------- doh Removed Files: ------------- src/sys/netinet6: icmp6.c.orig -------------- next part -------------- --- sys/netinet6/icmp6.c.orig +++ /dev/null @@ -1,2785 +0,0 @@ -/* $MidnightBSD: src/sys/netinet6/icmp6.c.orig,v 1.2 2009/01/11 02:41:57 laffer1 Exp $ */ -/* $FreeBSD: src/sys/netinet6/icmp6.c,v 1.80 2007/07/05 16:29:39 delphij Exp $ */ -/* $KAME: icmp6.c,v 1.211 2001/04/04 05:56:20 itojun Exp $ */ - -/*- - * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. - * All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the project nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE PROJECT AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE PROJECT OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - */ - -/*- - * Copyright (c) 1982, 1986, 1988, 1993 - * The Regents of the University of California. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 4. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#)ip_icmp.c 8.2 (Berkeley) 1/4/94 - */ - -#include "opt_inet.h" -#include "opt_inet6.h" -#include "opt_ipsec.h" - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include -#include -#include -#include - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#ifdef IPSEC -#include -#include -#endif - -extern struct domain inet6domain; - -struct icmp6stat icmp6stat; - -extern struct inpcbinfo ripcbinfo; -extern struct inpcbhead ripcb; -extern int icmp6errppslim; -static int icmp6errpps_count = 0; -static struct timeval icmp6errppslim_last; -extern int icmp6_nodeinfo; - -static void icmp6_errcount __P((struct icmp6errstat *, int, int)); -static int icmp6_rip6_input __P((struct mbuf **, int)); -static int icmp6_ratelimit __P((const struct in6_addr *, const int, const int)); -static const char *icmp6_redirect_diag __P((struct in6_addr *, - struct in6_addr *, struct in6_addr *)); -static struct mbuf *ni6_input __P((struct mbuf *, int)); -static struct mbuf *ni6_nametodns __P((const char *, int, int)); -static int ni6_dnsmatch __P((const char *, int, const char *, int)); -static int ni6_addrs __P((struct icmp6_nodeinfo *, struct mbuf *, - struct ifnet **, struct in6_addr *)); -static int ni6_store_addrs __P((struct icmp6_nodeinfo *, struct icmp6_nodeinfo *, - struct ifnet *, int)); -static int icmp6_notify_error __P((struct mbuf **, int, int, int)); - - -void -icmp6_init(void) -{ - - mld6_init(); -} - -static void -icmp6_errcount(struct icmp6errstat *stat, int type, int code) -{ - switch (type) { - case ICMP6_DST_UNREACH: - switch (code) { - case ICMP6_DST_UNREACH_NOROUTE: - stat->icp6errs_dst_unreach_noroute++; - return; - case ICMP6_DST_UNREACH_ADMIN: - stat->icp6errs_dst_unreach_admin++; - return; - case ICMP6_DST_UNREACH_BEYONDSCOPE: - stat->icp6errs_dst_unreach_beyondscope++; - return; - case ICMP6_DST_UNREACH_ADDR: - stat->icp6errs_dst_unreach_addr++; - return; - case ICMP6_DST_UNREACH_NOPORT: - stat->icp6errs_dst_unreach_noport++; - return; - } - break; - case ICMP6_PACKET_TOO_BIG: - stat->icp6errs_packet_too_big++; - return; - case ICMP6_TIME_EXCEEDED: - switch (code) { - case ICMP6_TIME_EXCEED_TRANSIT: - stat->icp6errs_time_exceed_transit++; - return; - case ICMP6_TIME_EXCEED_REASSEMBLY: - stat->icp6errs_time_exceed_reassembly++; - return; - } - break; - case ICMP6_PARAM_PROB: - switch (code) { - case ICMP6_PARAMPROB_HEADER: - stat->icp6errs_paramprob_header++; - return; - case ICMP6_PARAMPROB_NEXTHEADER: - stat->icp6errs_paramprob_nextheader++; - return; - case ICMP6_PARAMPROB_OPTION: - stat->icp6errs_paramprob_option++; - return; - } - break; - case ND_REDIRECT: - stat->icp6errs_redirect++; - return; - } - stat->icp6errs_unknown++; -} - -/* - * A wrapper function for icmp6_error() necessary when the erroneous packet - * may not contain enough scope zone information. - */ -void -icmp6_error2(struct mbuf *m, int type, int code, int param, - struct ifnet *ifp) -{ - struct ip6_hdr *ip6; - - if (ifp == NULL) - return; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, sizeof(struct ip6_hdr), ); -#else - if (m->m_len < sizeof(struct ip6_hdr)) { - m = m_pullup(m, sizeof(struct ip6_hdr)); - if (m == NULL) - return; - } -#endif - - ip6 = mtod(m, struct ip6_hdr *); - - if (in6_setscope(&ip6->ip6_src, ifp, NULL) != 0) - return; - if (in6_setscope(&ip6->ip6_dst, ifp, NULL) != 0) - return; - - icmp6_error(m, type, code, param); -} - -/* - * Generate an error packet of type error in response to bad IP6 packet. - */ -void -icmp6_error(struct mbuf *m, int type, int code, int param) -{ - struct ip6_hdr *oip6, *nip6; - struct icmp6_hdr *icmp6; - u_int preplen; - int off; - int nxt; - - icmp6stat.icp6s_error++; - - /* count per-type-code statistics */ - icmp6_errcount(&icmp6stat.icp6s_outerrhist, type, code); - -#ifdef M_DECRYPTED /*not openbsd*/ - if (m->m_flags & M_DECRYPTED) { - icmp6stat.icp6s_canterror++; - goto freeit; - } -#endif - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, sizeof(struct ip6_hdr), ); -#else - if (m->m_len < sizeof(struct ip6_hdr)) { - m = m_pullup(m, sizeof(struct ip6_hdr)); - if (m == NULL) - return; - } -#endif - oip6 = mtod(m, struct ip6_hdr *); - - /* - * If the destination address of the erroneous packet is a multicast - * address, or the packet was sent using link-layer multicast, - * we should basically suppress sending an error (RFC 2463, Section - * 2.4). - * We have two exceptions (the item e.2 in that section): - * - the Pakcet Too Big message can be sent for path MTU discovery. - * - the Parameter Problem Message that can be allowed an icmp6 error - * in the option type field. This check has been done in - * ip6_unknown_opt(), so we can just check the type and code. - */ - if ((m->m_flags & (M_BCAST|M_MCAST) || - IN6_IS_ADDR_MULTICAST(&oip6->ip6_dst)) && - (type != ICMP6_PACKET_TOO_BIG && - (type != ICMP6_PARAM_PROB || - code != ICMP6_PARAMPROB_OPTION))) - goto freeit; - - /* - * RFC 2463, 2.4 (e.5): source address check. - * XXX: the case of anycast source? - */ - if (IN6_IS_ADDR_UNSPECIFIED(&oip6->ip6_src) || - IN6_IS_ADDR_MULTICAST(&oip6->ip6_src)) - goto freeit; - - /* - * If we are about to send ICMPv6 against ICMPv6 error/redirect, - * don't do it. - */ - nxt = -1; - off = ip6_lasthdr(m, 0, IPPROTO_IPV6, &nxt); - if (off >= 0 && nxt == IPPROTO_ICMPV6) { - struct icmp6_hdr *icp; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, off + sizeof(struct icmp6_hdr), ); - icp = (struct icmp6_hdr *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(icp, struct icmp6_hdr *, m, off, - sizeof(*icp)); - if (icp == NULL) { - icmp6stat.icp6s_tooshort++; - return; - } -#endif - if (icp->icmp6_type < ICMP6_ECHO_REQUEST || - icp->icmp6_type == ND_REDIRECT) { - /* - * ICMPv6 error - * Special case: for redirect (which is - * informational) we must not send icmp6 error. - */ - icmp6stat.icp6s_canterror++; - goto freeit; - } else { - /* ICMPv6 informational - send the error */ - } - } else { - /* non-ICMPv6 - send the error */ - } - - oip6 = mtod(m, struct ip6_hdr *); /* adjust pointer */ - - /* Finally, do rate limitation check. */ - if (icmp6_ratelimit(&oip6->ip6_src, type, code)) { - icmp6stat.icp6s_toofreq++; - goto freeit; - } - - /* - * OK, ICMP6 can be generated. - */ - - if (m->m_pkthdr.len >= ICMPV6_PLD_MAXLEN) - m_adj(m, ICMPV6_PLD_MAXLEN - m->m_pkthdr.len); - - preplen = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr); - M_PREPEND(m, preplen, M_DONTWAIT); - if (m && m->m_len < preplen) - m = m_pullup(m, preplen); - if (m == NULL) { - nd6log((LOG_DEBUG, "ENOBUFS in icmp6_error %d\n", __LINE__)); - return; - } - - nip6 = mtod(m, struct ip6_hdr *); - nip6->ip6_src = oip6->ip6_src; - nip6->ip6_dst = oip6->ip6_dst; - - in6_clearscope(&oip6->ip6_src); - in6_clearscope(&oip6->ip6_dst); - - icmp6 = (struct icmp6_hdr *)(nip6 + 1); - icmp6->icmp6_type = type; - icmp6->icmp6_code = code; - icmp6->icmp6_pptr = htonl((u_int32_t)param); - - /* - * icmp6_reflect() is designed to be in the input path. - * icmp6_error() can be called from both input and output path, - * and if we are in output path rcvif could contain bogus value. - * clear m->m_pkthdr.rcvif for safety, we should have enough scope - * information in ip header (nip6). - */ - m->m_pkthdr.rcvif = NULL; - - icmp6stat.icp6s_outhist[type]++; - icmp6_reflect(m, sizeof(struct ip6_hdr)); /* header order: IPv6 - ICMPv6 */ - - return; - - freeit: - /* - * If we can't tell whether or not we can generate ICMP6, free it. - */ - m_freem(m); -} - -/* - * Process a received ICMP6 message. - */ -int -icmp6_input(struct mbuf **mp, int *offp, int proto) -{ - struct mbuf *m = *mp, *n; - struct ip6_hdr *ip6, *nip6; - struct icmp6_hdr *icmp6, *nicmp6; - int off = *offp; - int icmp6len = m->m_pkthdr.len - *offp; - int code, sum, noff; - char ip6bufs[INET6_ADDRSTRLEN], ip6bufd[INET6_ADDRSTRLEN]; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, sizeof(struct icmp6_hdr), IPPROTO_DONE); - /* m might change if M_LOOP. So, call mtod after this */ -#endif - - /* - * Locate icmp6 structure in mbuf, and check - * that not corrupted and of at least minimum length - */ - - ip6 = mtod(m, struct ip6_hdr *); - if (icmp6len < sizeof(struct icmp6_hdr)) { - icmp6stat.icp6s_tooshort++; - goto freeit; - } - - /* - * calculate the checksum - */ -#ifndef PULLDOWN_TEST - icmp6 = (struct icmp6_hdr *)((caddr_t)ip6 + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, sizeof(*icmp6)); - if (icmp6 == NULL) { - icmp6stat.icp6s_tooshort++; - return IPPROTO_DONE; - } -#endif - code = icmp6->icmp6_code; - - if ((sum = in6_cksum(m, IPPROTO_ICMPV6, off, icmp6len)) != 0) { - nd6log((LOG_ERR, - "ICMP6 checksum error(%d|%x) %s\n", - icmp6->icmp6_type, sum, - ip6_sprintf(ip6bufs, &ip6->ip6_src))); - icmp6stat.icp6s_checksum++; - goto freeit; - } - - if (faithprefix_p != NULL && (*faithprefix_p)(&ip6->ip6_dst)) { - /* - * Deliver very specific ICMP6 type only. - * This is important to deliver TOOBIG. Otherwise PMTUD - * will not work. - */ - switch (icmp6->icmp6_type) { - case ICMP6_DST_UNREACH: - case ICMP6_PACKET_TOO_BIG: - case ICMP6_TIME_EXCEEDED: - break; - default: - goto freeit; - } - } - - icmp6stat.icp6s_inhist[icmp6->icmp6_type]++; - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_msg); - if (icmp6->icmp6_type < ICMP6_INFOMSG_MASK) - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_error); - - switch (icmp6->icmp6_type) { - case ICMP6_DST_UNREACH: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_dstunreach); - switch (code) { - case ICMP6_DST_UNREACH_NOROUTE: - code = PRC_UNREACH_NET; - break; - case ICMP6_DST_UNREACH_ADMIN: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_adminprohib); - code = PRC_UNREACH_PROTOCOL; /* is this a good code? */ - break; - case ICMP6_DST_UNREACH_ADDR: - code = PRC_HOSTDEAD; - break; - case ICMP6_DST_UNREACH_BEYONDSCOPE: - /* I mean "source address was incorrect." */ - code = PRC_PARAMPROB; - break; - case ICMP6_DST_UNREACH_NOPORT: - code = PRC_UNREACH_PORT; - break; - default: - goto badcode; - } - goto deliver; - break; - - case ICMP6_PACKET_TOO_BIG: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_pkttoobig); - - /* validation is made in icmp6_mtudisc_update */ - - code = PRC_MSGSIZE; - - /* - * Updating the path MTU will be done after examining - * intermediate extension headers. - */ - goto deliver; - break; - - case ICMP6_TIME_EXCEEDED: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_timeexceed); - switch (code) { - case ICMP6_TIME_EXCEED_TRANSIT: - code = PRC_TIMXCEED_INTRANS; - break; - case ICMP6_TIME_EXCEED_REASSEMBLY: - code = PRC_TIMXCEED_REASS; - break; - default: - goto badcode; - } - goto deliver; - break; - - case ICMP6_PARAM_PROB: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_paramprob); - switch (code) { - case ICMP6_PARAMPROB_NEXTHEADER: - code = PRC_UNREACH_PROTOCOL; - break; - case ICMP6_PARAMPROB_HEADER: - case ICMP6_PARAMPROB_OPTION: - code = PRC_PARAMPROB; - break; - default: - goto badcode; - } - goto deliver; - break; - - case ICMP6_ECHO_REQUEST: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_echo); - if (code != 0) - goto badcode; - if ((n = m_copy(m, 0, M_COPYALL)) == NULL) { - /* Give up remote */ - break; - } - if ((n->m_flags & M_EXT) != 0 - || n->m_len < off + sizeof(struct icmp6_hdr)) { - struct mbuf *n0 = n; - const int maxlen = sizeof(*nip6) + sizeof(*nicmp6); - int n0len; - - MGETHDR(n, M_DONTWAIT, n0->m_type); - n0len = n0->m_pkthdr.len; /* save for use below */ - if (n) - M_MOVE_PKTHDR(n, n0); - if (n && maxlen >= MHLEN) { - MCLGET(n, M_DONTWAIT); - if ((n->m_flags & M_EXT) == 0) { - m_free(n); - n = NULL; - } - } - if (n == NULL) { - /* Give up remote */ - m_freem(n0); - break; - } - /* - * Copy IPv6 and ICMPv6 only. - */ - nip6 = mtod(n, struct ip6_hdr *); - bcopy(ip6, nip6, sizeof(struct ip6_hdr)); - nicmp6 = (struct icmp6_hdr *)(nip6 + 1); - bcopy(icmp6, nicmp6, sizeof(struct icmp6_hdr)); - noff = sizeof(struct ip6_hdr); - /* new mbuf contains only ipv6+icmpv6 headers */ - n->m_len = noff + sizeof(struct icmp6_hdr); - /* - * Adjust mbuf. ip6_plen will be adjusted in - * ip6_output(). - */ - m_adj(n0, off + sizeof(struct icmp6_hdr)); - /* recalculate complete packet size */ - n->m_pkthdr.len = n0len + (noff - off); - n->m_next = n0; - } else { - nip6 = mtod(n, struct ip6_hdr *); - IP6_EXTHDR_GET(nicmp6, struct icmp6_hdr *, n, off, - sizeof(*nicmp6)); - noff = off; - } - nicmp6->icmp6_type = ICMP6_ECHO_REPLY; - nicmp6->icmp6_code = 0; - if (n) { - icmp6stat.icp6s_reflect++; - icmp6stat.icp6s_outhist[ICMP6_ECHO_REPLY]++; - icmp6_reflect(n, noff); - } - break; - - case ICMP6_ECHO_REPLY: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_echoreply); - if (code != 0) - goto badcode; - break; - - case MLD_LISTENER_QUERY: - case MLD_LISTENER_REPORT: - if (icmp6len < sizeof(struct mld_hdr)) - goto badlen; - if (icmp6->icmp6_type == MLD_LISTENER_QUERY) /* XXX: ugly... */ - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_mldquery); - else - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_mldreport); - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - mld6_input(m, off); - m = NULL; - goto freeit; - } - mld6_input(n, off); - /* m stays. */ - break; - - case MLD_LISTENER_DONE: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_mlddone); - if (icmp6len < sizeof(struct mld_hdr)) /* necessary? */ - goto badlen; - break; /* nothing to be done in kernel */ - - case MLD_MTRACE_RESP: - case MLD_MTRACE: - /* XXX: these two are experimental. not officially defined. */ - /* XXX: per-interface statistics? */ - break; /* just pass it to applications */ - - case ICMP6_WRUREQUEST: /* ICMP6_FQDN_QUERY */ - { - enum { WRU, FQDN } mode; - - if (!icmp6_nodeinfo) - break; - - if (icmp6len == sizeof(struct icmp6_hdr) + 4) - mode = WRU; - else if (icmp6len >= sizeof(struct icmp6_nodeinfo)) - mode = FQDN; - else - goto badlen; - -#define hostnamelen strlen(hostname) - if (mode == FQDN) { -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, sizeof(struct icmp6_nodeinfo), - IPPROTO_DONE); -#endif - n = m_copy(m, 0, M_COPYALL); - if (n) - n = ni6_input(n, off); - /* XXX meaningless if n == NULL */ - noff = sizeof(struct ip6_hdr); - } else { - u_char *p; - int maxlen, maxhlen; - - /* - * XXX: this combination of flags is pointless, - * but should we keep this for compatibility? - */ - if ((icmp6_nodeinfo & 5) != 5) - break; - - if (code != 0) - goto badcode; - maxlen = sizeof(*nip6) + sizeof(*nicmp6) + 4; - if (maxlen >= MCLBYTES) { - /* Give up remote */ - break; - } - MGETHDR(n, M_DONTWAIT, m->m_type); - if (n && maxlen > MHLEN) { - MCLGET(n, M_DONTWAIT); - if ((n->m_flags & M_EXT) == 0) { - m_free(n); - n = NULL; - } - } - if (n && !m_dup_pkthdr(n, m, M_DONTWAIT)) { - /* - * Previous code did a blind M_COPY_PKTHDR - * and said "just for rcvif". If true, then - * we could tolerate the dup failing (due to - * the deep copy of the tag chain). For now - * be conservative and just fail. - */ - m_free(n); - n = NULL; - } - if (n == NULL) { - /* Give up remote */ - break; - } - n->m_pkthdr.rcvif = NULL; - n->m_len = 0; - maxhlen = M_TRAILINGSPACE(n) - maxlen; - if (maxhlen > hostnamelen) - maxhlen = hostnamelen; - /* - * Copy IPv6 and ICMPv6 only. - */ - nip6 = mtod(n, struct ip6_hdr *); - bcopy(ip6, nip6, sizeof(struct ip6_hdr)); - nicmp6 = (struct icmp6_hdr *)(nip6 + 1); - bcopy(icmp6, nicmp6, sizeof(struct icmp6_hdr)); - p = (u_char *)(nicmp6 + 1); - bzero(p, 4); - bcopy(hostname, p + 4, maxhlen); /* meaningless TTL */ - noff = sizeof(struct ip6_hdr); - n->m_pkthdr.len = n->m_len = sizeof(struct ip6_hdr) + - sizeof(struct icmp6_hdr) + 4 + maxhlen; - nicmp6->icmp6_type = ICMP6_WRUREPLY; - nicmp6->icmp6_code = 0; - } -#undef hostnamelen - if (n) { - icmp6stat.icp6s_reflect++; - icmp6stat.icp6s_outhist[ICMP6_WRUREPLY]++; - icmp6_reflect(n, noff); - } - break; - } - - case ICMP6_WRUREPLY: - if (code != 0) - goto badcode; - break; - - case ND_ROUTER_SOLICIT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_routersolicit); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_router_solicit)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_rs_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_rs_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_ROUTER_ADVERT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_routeradvert); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_router_advert)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_ra_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_ra_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_NEIGHBOR_SOLICIT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_neighborsolicit); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_neighbor_solicit)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_ns_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_ns_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_NEIGHBOR_ADVERT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_neighboradvert); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_neighbor_advert)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - nd6_na_input(m, off, icmp6len); - m = NULL; - goto freeit; - } - nd6_na_input(n, off, icmp6len); - /* m stays. */ - break; - - case ND_REDIRECT: - icmp6_ifstat_inc(m->m_pkthdr.rcvif, ifs6_in_redirect); - if (code != 0) - goto badcode; - if (icmp6len < sizeof(struct nd_redirect)) - goto badlen; - if ((n = m_copym(m, 0, M_COPYALL, M_DONTWAIT)) == NULL) { - /* give up local */ - icmp6_redirect_input(m, off); - m = NULL; - goto freeit; - } - icmp6_redirect_input(n, off); - /* m stays. */ - break; - - case ICMP6_ROUTER_RENUMBERING: - if (code != ICMP6_ROUTER_RENUMBERING_COMMAND && - code != ICMP6_ROUTER_RENUMBERING_RESULT) - goto badcode; - if (icmp6len < sizeof(struct icmp6_router_renum)) - goto badlen; - break; - - default: - nd6log((LOG_DEBUG, - "icmp6_input: unknown type %d(src=%s, dst=%s, ifid=%d)\n", - icmp6->icmp6_type, ip6_sprintf(ip6bufs, &ip6->ip6_src), - ip6_sprintf(ip6bufd, &ip6->ip6_dst), - m->m_pkthdr.rcvif ? m->m_pkthdr.rcvif->if_index : 0)); - if (icmp6->icmp6_type < ICMP6_ECHO_REQUEST) { - /* ICMPv6 error: MUST deliver it by spec... */ - code = PRC_NCMDS; - /* deliver */ - } else { - /* ICMPv6 informational: MUST not deliver */ - break; - } - deliver: - if (icmp6_notify_error(&m, off, icmp6len, code)) { - /* In this case, m should've been freed. */ - return (IPPROTO_DONE); - } - break; - - badcode: - icmp6stat.icp6s_badcode++; - break; - - badlen: - icmp6stat.icp6s_badlen++; - break; - } - - /* deliver the packet to appropriate sockets */ - icmp6_rip6_input(&m, *offp); - - return IPPROTO_DONE; - - freeit: - m_freem(m); - return IPPROTO_DONE; -} - -static int -icmp6_notify_error(struct mbuf **mp, int off, int icmp6len, int code) -{ - struct mbuf *m = *mp; - struct icmp6_hdr *icmp6; - struct ip6_hdr *eip6; - u_int32_t notifymtu; - struct sockaddr_in6 icmp6src, icmp6dst; - - if (icmp6len < sizeof(struct icmp6_hdr) + sizeof(struct ip6_hdr)) { - icmp6stat.icp6s_tooshort++; - goto freeit; - } -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, - sizeof(struct icmp6_hdr) + sizeof(struct ip6_hdr), -1); - icmp6 = (struct icmp6_hdr *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, - sizeof(*icmp6) + sizeof(struct ip6_hdr)); - if (icmp6 == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - eip6 = (struct ip6_hdr *)(icmp6 + 1); - - /* Detect the upper level protocol */ - { - void (*ctlfunc) __P((int, struct sockaddr *, void *)); - u_int8_t nxt = eip6->ip6_nxt; - int eoff = off + sizeof(struct icmp6_hdr) + - sizeof(struct ip6_hdr); - struct ip6ctlparam ip6cp; - struct in6_addr *finaldst = NULL; - int icmp6type = icmp6->icmp6_type; - struct ip6_frag *fh; - struct ip6_rthdr *rth; - struct ip6_rthdr0 *rth0; - int rthlen; - - while (1) { /* XXX: should avoid infinite loop explicitly? */ - struct ip6_ext *eh; - - switch (nxt) { - case IPPROTO_HOPOPTS: - case IPPROTO_DSTOPTS: - case IPPROTO_AH: -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, - eoff + sizeof(struct ip6_ext), -1); - eh = (struct ip6_ext *)(mtod(m, caddr_t) + eoff); -#else - IP6_EXTHDR_GET(eh, struct ip6_ext *, m, - eoff, sizeof(*eh)); - if (eh == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - - if (nxt == IPPROTO_AH) - eoff += (eh->ip6e_len + 2) << 2; - else - eoff += (eh->ip6e_len + 1) << 3; - nxt = eh->ip6e_nxt; - break; - case IPPROTO_ROUTING: - /* - * When the erroneous packet contains a - * routing header, we should examine the - * header to determine the final destination. - * Otherwise, we can't properly update - * information that depends on the final - * destination (e.g. path MTU). - */ -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, eoff + sizeof(*rth), -1); - rth = (struct ip6_rthdr *) - (mtod(m, caddr_t) + eoff); -#else - IP6_EXTHDR_GET(rth, struct ip6_rthdr *, m, - eoff, sizeof(*rth)); - if (rth == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - rthlen = (rth->ip6r_len + 1) << 3; - /* - * XXX: currently there is no - * officially defined type other - * than type-0. - * Note that if the segment left field - * is 0, all intermediate hops must - * have been passed. - */ - if (rth->ip6r_segleft && - rth->ip6r_type == IPV6_RTHDR_TYPE_0) { - int hops; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, eoff + rthlen, -1); - rth0 = (struct ip6_rthdr0 *) - (mtod(m, caddr_t) + eoff); -#else - IP6_EXTHDR_GET(rth0, - struct ip6_rthdr0 *, m, - eoff, rthlen); - if (rth0 == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - /* just ignore a bogus header */ - if ((rth0->ip6r0_len % 2) == 0 && - (hops = rth0->ip6r0_len/2)) - finaldst = (struct in6_addr *)(rth0 + 1) + (hops - 1); - } - eoff += rthlen; - nxt = rth->ip6r_nxt; - break; - case IPPROTO_FRAGMENT: -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, 0, eoff + - sizeof(struct ip6_frag), -1); - fh = (struct ip6_frag *)(mtod(m, caddr_t) + - eoff); -#else - IP6_EXTHDR_GET(fh, struct ip6_frag *, m, - eoff, sizeof(*fh)); - if (fh == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - /* - * Data after a fragment header is meaningless - * unless it is the first fragment, but - * we'll go to the notify label for path MTU - * discovery. - */ - if (fh->ip6f_offlg & IP6F_OFF_MASK) - goto notify; - - eoff += sizeof(struct ip6_frag); - nxt = fh->ip6f_nxt; - break; - default: - /* - * This case includes ESP and the No Next - * Header. In such cases going to the notify - * label does not have any meaning - * (i.e. ctlfunc will be NULL), but we go - * anyway since we might have to update - * path MTU information. - */ - goto notify; - } - } - notify: -#ifndef PULLDOWN_TEST - icmp6 = (struct icmp6_hdr *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, - sizeof(*icmp6) + sizeof(struct ip6_hdr)); - if (icmp6 == NULL) { - icmp6stat.icp6s_tooshort++; - return (-1); - } -#endif - - /* - * retrieve parameters from the inner IPv6 header, and convert - * them into sockaddr structures. - * XXX: there is no guarantee that the source or destination - * addresses of the inner packet are in the same scope as - * the addresses of the icmp packet. But there is no other - * way to determine the zone. - */ - eip6 = (struct ip6_hdr *)(icmp6 + 1); - - bzero(&icmp6dst, sizeof(icmp6dst)); - icmp6dst.sin6_len = sizeof(struct sockaddr_in6); - icmp6dst.sin6_family = AF_INET6; - if (finaldst == NULL) - icmp6dst.sin6_addr = eip6->ip6_dst; - else - icmp6dst.sin6_addr = *finaldst; - if (in6_setscope(&icmp6dst.sin6_addr, m->m_pkthdr.rcvif, NULL)) - goto freeit; - bzero(&icmp6src, sizeof(icmp6src)); - icmp6src.sin6_len = sizeof(struct sockaddr_in6); - icmp6src.sin6_family = AF_INET6; - icmp6src.sin6_addr = eip6->ip6_src; - if (in6_setscope(&icmp6src.sin6_addr, m->m_pkthdr.rcvif, NULL)) - goto freeit; - icmp6src.sin6_flowinfo = - (eip6->ip6_flow & IPV6_FLOWLABEL_MASK); - - if (finaldst == NULL) - finaldst = &eip6->ip6_dst; - ip6cp.ip6c_m = m; - ip6cp.ip6c_icmp6 = icmp6; - ip6cp.ip6c_ip6 = (struct ip6_hdr *)(icmp6 + 1); - ip6cp.ip6c_off = eoff; - ip6cp.ip6c_finaldst = finaldst; - ip6cp.ip6c_src = &icmp6src; - ip6cp.ip6c_nxt = nxt; - - if (icmp6type == ICMP6_PACKET_TOO_BIG) { - notifymtu = ntohl(icmp6->icmp6_mtu); - ip6cp.ip6c_cmdarg = (void *)¬ifymtu; - icmp6_mtudisc_update(&ip6cp, 1); /*XXX*/ - } - - ctlfunc = (void (*) __P((int, struct sockaddr *, void *))) - (inet6sw[ip6_protox[nxt]].pr_ctlinput); - if (ctlfunc) { - (void) (*ctlfunc)(code, (struct sockaddr *)&icmp6dst, - &ip6cp); - } - } - *mp = m; - return (0); - - freeit: - m_freem(m); - return (-1); -} - -void -icmp6_mtudisc_update(struct ip6ctlparam *ip6cp, int validated) -{ - struct in6_addr *dst = ip6cp->ip6c_finaldst; - struct icmp6_hdr *icmp6 = ip6cp->ip6c_icmp6; - struct mbuf *m = ip6cp->ip6c_m; /* will be necessary for scope issue */ - u_int mtu = ntohl(icmp6->icmp6_mtu); - struct in_conninfo inc; - -#if 0 - /* - * RFC2460 section 5, last paragraph. - * even though minimum link MTU for IPv6 is IPV6_MMTU, - * we may see ICMPv6 too big with mtu < IPV6_MMTU - * due to packet translator in the middle. - * see ip6_output() and ip6_getpmtu() "alwaysfrag" case for - * special handling. - */ - if (mtu < IPV6_MMTU) - return; -#endif - - /* - * we reject ICMPv6 too big with abnormally small value. - * XXX what is the good definition of "abnormally small"? - */ - if (mtu < sizeof(struct ip6_hdr) + sizeof(struct ip6_frag) + 8) - return; - - if (!validated) - return; - - bzero(&inc, sizeof(inc)); - inc.inc_flags = 1; /* IPv6 */ - inc.inc6_faddr = *dst; - if (in6_setscope(&inc.inc6_faddr, m->m_pkthdr.rcvif, NULL)) - return; - - if (mtu < tcp_maxmtu6(&inc, NULL)) { - tcp_hc_updatemtu(&inc, mtu); - icmp6stat.icp6s_pmtuchg++; - } -} - -/* - * Process a Node Information Query packet, based on - * draft-ietf-ipngwg-icmp-name-lookups-07. - * - * Spec incompatibilities: - * - IPv6 Subject address handling - * - IPv4 Subject address handling support missing - * - Proxy reply (answer even if it's not for me) - * - joins NI group address at in6_ifattach() time only, does not cope - * with hostname changes by sethostname(3) - */ -#define hostnamelen strlen(hostname) -static struct mbuf * -ni6_input(struct mbuf *m, int off) -{ - struct icmp6_nodeinfo *ni6, *nni6; - struct mbuf *n = NULL; - u_int16_t qtype; - int subjlen; - int replylen = sizeof(struct ip6_hdr) + sizeof(struct icmp6_nodeinfo); - struct ni_reply_fqdn *fqdn; - int addrs; /* for NI_QTYPE_NODEADDR */ - struct ifnet *ifp = NULL; /* for NI_QTYPE_NODEADDR */ - struct in6_addr in6_subj; /* subject address */ - struct ip6_hdr *ip6; - int oldfqdn = 0; /* if 1, return pascal string (03 draft) */ - char *subj = NULL; - struct in6_ifaddr *ia6 = NULL; - - ip6 = mtod(m, struct ip6_hdr *); -#ifndef PULLDOWN_TEST - ni6 = (struct icmp6_nodeinfo *)(mtod(m, caddr_t) + off); -#else - IP6_EXTHDR_GET(ni6, struct icmp6_nodeinfo *, m, off, sizeof(*ni6)); - if (ni6 == NULL) { - /* m is already reclaimed */ - return (NULL); - } -#endif - - /* - * Validate IPv6 source address. - * The default configuration MUST be to refuse answering queries from - * global-scope addresses according to RFC4602. - * Notes: - * - it's not very clear what "refuse" means; this implementation - * simply drops it. - * - it's not very easy to identify global-scope (unicast) addresses - * since there are many prefixes for them. It should be safer - * and in practice sufficient to check "all" but loopback and - * link-local (note that site-local unicast was deprecated and - * ULA is defined as global scope-wise) - */ - if ((icmp6_nodeinfo & ICMP6_NODEINFO_GLOBALOK) == 0 && - !IN6_IS_ADDR_LOOPBACK(&ip6->ip6_src) && - !IN6_IS_ADDR_LINKLOCAL(&ip6->ip6_src)) - goto bad; - - /* - * Validate IPv6 destination address. - * - * The Responder must discard the Query without further processing - * unless it is one of the Responder's unicast or anycast addresses, or - * a link-local scope multicast address which the Responder has joined. - * [RFC4602, Section 5.] - */ - if (IN6_IS_ADDR_MULTICAST(&ip6->ip6_dst)) { - if (!IN6_IS_ADDR_MC_LINKLOCAL(&ip6->ip6_dst)) - goto bad; - /* else it's a link-local multicast, fine */ - } else { /* unicast or anycast */ - if ((ia6 = ip6_getdstifaddr(m)) == NULL) - goto bad; /* XXX impossible */ - - if ((ia6->ia6_flags & IN6_IFF_TEMPORARY) && - !(icmp6_nodeinfo & ICMP6_NODEINFO_TMPADDROK)) { - nd6log((LOG_DEBUG, "ni6_input: ignore node info to " - "a temporary address in %s:%d", - __FILE__, __LINE__)); - goto bad; - } - } - - /* validate query Subject field. */ - qtype = ntohs(ni6->ni_qtype); - subjlen = m->m_pkthdr.len - off - sizeof(struct icmp6_nodeinfo); - switch (qtype) { - case NI_QTYPE_NOOP: - case NI_QTYPE_SUPTYPES: - /* 07 draft */ - if (ni6->ni_code == ICMP6_NI_SUBJ_FQDN && subjlen == 0) - break; - /* FALLTHROUGH */ - case NI_QTYPE_FQDN: - case NI_QTYPE_NODEADDR: - case NI_QTYPE_IPV4ADDR: - switch (ni6->ni_code) { - case ICMP6_NI_SUBJ_IPV6: -#if ICMP6_NI_SUBJ_IPV6 != 0 - case 0: -#endif - /* - * backward compatibility - try to accept 03 draft - * format, where no Subject is present. - */ - if (qtype == NI_QTYPE_FQDN && ni6->ni_code == 0 && - subjlen == 0) { - oldfqdn++; - break; - } -#if ICMP6_NI_SUBJ_IPV6 != 0 - if (ni6->ni_code != ICMP6_NI_SUBJ_IPV6) - goto bad; -#endif - - if (subjlen != sizeof(struct in6_addr)) - goto bad; - - /* - * Validate Subject address. - * - * Not sure what exactly "address belongs to the node" - * means in the spec, is it just unicast, or what? - * - * At this moment we consider Subject address as - * "belong to the node" if the Subject address equals - * to the IPv6 destination address; validation for - * IPv6 destination address should have done enough - * check for us. - * - * We do not do proxy at this moment. - */ - /* m_pulldown instead of copy? */ - m_copydata(m, off + sizeof(struct icmp6_nodeinfo), - subjlen, (caddr_t)&in6_subj); - if (in6_setscope(&in6_subj, m->m_pkthdr.rcvif, NULL)) - goto bad; - - subj = (char *)&in6_subj; - if (IN6_ARE_ADDR_EQUAL(&ip6->ip6_dst, &in6_subj)) - break; - - /* - * XXX if we are to allow other cases, we should really - * be careful about scope here. - * basically, we should disallow queries toward IPv6 - * destination X with subject Y, - * if scope(X) > scope(Y). - * if we allow scope(X) > scope(Y), it will result in - * information leakage across scope boundary. - */ - goto bad; - - case ICMP6_NI_SUBJ_FQDN: - /* - * Validate Subject name with gethostname(3). - * - * The behavior may need some debate, since: - * - we are not sure if the node has FQDN as - * hostname (returned by gethostname(3)). - * - the code does wildcard match for truncated names. - * however, we are not sure if we want to perform - * wildcard match, if gethostname(3) side has - * truncated hostname. - */ - n = ni6_nametodns(hostname, hostnamelen, 0); - if (!n || n->m_next || n->m_len == 0) - goto bad; - IP6_EXTHDR_GET(subj, char *, m, - off + sizeof(struct icmp6_nodeinfo), subjlen); - if (subj == NULL) - goto bad; - if (!ni6_dnsmatch(subj, subjlen, mtod(n, const char *), - n->m_len)) { - goto bad; - } - m_freem(n); - n = NULL; - break; - - case ICMP6_NI_SUBJ_IPV4: /* XXX: to be implemented? */ - default: - goto bad; - } - break; - } - - /* refuse based on configuration. XXX ICMP6_NI_REFUSED? */ - switch (qtype) { - case NI_QTYPE_FQDN: - if ((icmp6_nodeinfo & ICMP6_NODEINFO_FQDNOK) == 0) - goto bad; - break; - case NI_QTYPE_NODEADDR: - case NI_QTYPE_IPV4ADDR: - if ((icmp6_nodeinfo & ICMP6_NODEINFO_NODEADDROK) == 0) - goto bad; - break; - } - - /* guess reply length */ - switch (qtype) { - case NI_QTYPE_NOOP: - break; /* no reply data */ - case NI_QTYPE_SUPTYPES: - replylen += sizeof(u_int32_t); - break; - case NI_QTYPE_FQDN: - /* XXX will append an mbuf */ - replylen += offsetof(struct ni_reply_fqdn, ni_fqdn_namelen); - break; - case NI_QTYPE_NODEADDR: - addrs = ni6_addrs(ni6, m, &ifp, (struct in6_addr *)subj); - if ((replylen += addrs * (sizeof(struct in6_addr) + - sizeof(u_int32_t))) > MCLBYTES) - replylen = MCLBYTES; /* XXX: will truncate pkt later */ - break; - case NI_QTYPE_IPV4ADDR: - /* unsupported - should respond with unknown Qtype? */ - break; - default: - /* - * XXX: We must return a reply with the ICMP6 code - * `unknown Qtype' in this case. However we regard the case - * as an FQDN query for backward compatibility. - * Older versions set a random value to this field, - * so it rarely varies in the defined qtypes. - * But the mechanism is not reliable... - * maybe we should obsolete older versions. - */ - qtype = NI_QTYPE_FQDN; - /* XXX will append an mbuf */ - replylen += offsetof(struct ni_reply_fqdn, ni_fqdn_namelen); - oldfqdn++; - break; - } - - /* allocate an mbuf to reply. */ - MGETHDR(n, M_DONTWAIT, m->m_type); - if (n == NULL) { - m_freem(m); - return (NULL); - } - M_MOVE_PKTHDR(n, m); /* just for recvif */ - if (replylen > MHLEN) { - if (replylen > MCLBYTES) { - /* - * XXX: should we try to allocate more? But MCLBYTES - * is probably much larger than IPV6_MMTU... - */ - goto bad; - } - MCLGET(n, M_DONTWAIT); - if ((n->m_flags & M_EXT) == 0) { - goto bad; - } - } - n->m_pkthdr.len = n->m_len = replylen; - - /* copy mbuf header and IPv6 + Node Information base headers */ - bcopy(mtod(m, caddr_t), mtod(n, caddr_t), sizeof(struct ip6_hdr)); - nni6 = (struct icmp6_nodeinfo *)(mtod(n, struct ip6_hdr *) + 1); - bcopy((caddr_t)ni6, (caddr_t)nni6, sizeof(struct icmp6_nodeinfo)); - - /* qtype dependent procedure */ - switch (qtype) { - case NI_QTYPE_NOOP: - nni6->ni_code = ICMP6_NI_SUCCESS; - nni6->ni_flags = 0; - break; - case NI_QTYPE_SUPTYPES: - { - u_int32_t v; - nni6->ni_code = ICMP6_NI_SUCCESS; - nni6->ni_flags = htons(0x0000); /* raw bitmap */ - /* supports NOOP, SUPTYPES, FQDN, and NODEADDR */ - v = (u_int32_t)htonl(0x0000000f); - bcopy(&v, nni6 + 1, sizeof(u_int32_t)); - break; - } - case NI_QTYPE_FQDN: - nni6->ni_code = ICMP6_NI_SUCCESS; - fqdn = (struct ni_reply_fqdn *)(mtod(n, caddr_t) + - sizeof(struct ip6_hdr) + sizeof(struct icmp6_nodeinfo)); - nni6->ni_flags = 0; /* XXX: meaningless TTL */ - fqdn->ni_fqdn_ttl = 0; /* ditto. */ - /* - * XXX do we really have FQDN in variable "hostname"? - */ - n->m_next = ni6_nametodns(hostname, hostnamelen, oldfqdn); - if (n->m_next == NULL) - goto bad; - /* XXX we assume that n->m_next is not a chain */ - if (n->m_next->m_next != NULL) - goto bad; - n->m_pkthdr.len += n->m_next->m_len; - break; - case NI_QTYPE_NODEADDR: - { - int lenlim, copied; - - nni6->ni_code = ICMP6_NI_SUCCESS; - n->m_pkthdr.len = n->m_len = - sizeof(struct ip6_hdr) + sizeof(struct icmp6_nodeinfo); - lenlim = M_TRAILINGSPACE(n); - copied = ni6_store_addrs(ni6, nni6, ifp, lenlim); - /* XXX: reset mbuf length */ - n->m_pkthdr.len = n->m_len = sizeof(struct ip6_hdr) + - sizeof(struct icmp6_nodeinfo) + copied; - break; - } - default: - break; /* XXX impossible! */ - } - - nni6->ni_type = ICMP6_NI_REPLY; - m_freem(m); - return (n); - - bad: - m_freem(m); - if (n) - m_freem(n); - return (NULL); -} -#undef hostnamelen - -/* - * make a mbuf with DNS-encoded string. no compression support. - * - * XXX names with less than 2 dots (like "foo" or "foo.section") will be - * treated as truncated name (two \0 at the end). this is a wild guess. - * - * old - return pascal string if non-zero - */ -static struct mbuf * -ni6_nametodns(const char *name, int namelen, int old) -{ - struct mbuf *m; - char *cp, *ep; - const char *p, *q; - int i, len, nterm; - - if (old) - len = namelen + 1; - else - len = MCLBYTES; - - /* because MAXHOSTNAMELEN is usually 256, we use cluster mbuf */ - MGET(m, M_DONTWAIT, MT_DATA); - if (m && len > MLEN) { - MCLGET(m, M_DONTWAIT); - if ((m->m_flags & M_EXT) == 0) - goto fail; - } - if (!m) - goto fail; - m->m_next = NULL; - - if (old) { - m->m_len = len; - *mtod(m, char *) = namelen; - bcopy(name, mtod(m, char *) + 1, namelen); - return m; - } else { - m->m_len = 0; - cp = mtod(m, char *); - ep = mtod(m, char *) + M_TRAILINGSPACE(m); - - /* if not certain about my name, return empty buffer */ - if (namelen == 0) - return m; - - /* - * guess if it looks like shortened hostname, or FQDN. - * shortened hostname needs two trailing "\0". - */ - i = 0; - for (p = name; p < name + namelen; p++) { - if (*p && *p == '.') - i++; - } - if (i < 2) - nterm = 2; - else - nterm = 1; - - p = name; - while (cp < ep && p < name + namelen) { - i = 0; - for (q = p; q < name + namelen && *q && *q != '.'; q++) - i++; - /* result does not fit into mbuf */ - if (cp + i + 1 >= ep) - goto fail; - /* - * DNS label length restriction, RFC1035 page 8. - * "i == 0" case is included here to avoid returning - * 0-length label on "foo..bar". - */ - if (i <= 0 || i >= 64) - goto fail; - *cp++ = i; - bcopy(p, cp, i); - cp += i; - p = q; - if (p < name + namelen && *p == '.') - p++; - } - /* termination */ - if (cp + nterm >= ep) - goto fail; - while (nterm-- > 0) - *cp++ = '\0'; - m->m_len = cp - mtod(m, char *); - return m; - } - - panic("should not reach here"); - /* NOTREACHED */ - - fail: - if (m) - m_freem(m); - return NULL; -} - -/* - * check if two DNS-encoded string matches. takes care of truncated - * form (with \0\0 at the end). no compression support. - * XXX upper/lowercase match (see RFC2065) - */ -static int -ni6_dnsmatch(const char *a, int alen, const char *b, int blen) -{ - const char *a0, *b0; - int l; - - /* simplest case - need validation? */ - if (alen == blen && bcmp(a, b, alen) == 0) - return 1; - - a0 = a; - b0 = b; - - /* termination is mandatory */ - if (alen < 2 || blen < 2) - return 0; - if (a0[alen - 1] != '\0' || b0[blen - 1] != '\0') - return 0; - alen--; - blen--; - - while (a - a0 < alen && b - b0 < blen) { - if (a - a0 + 1 > alen || b - b0 + 1 > blen) - return 0; - - if ((signed char)a[0] < 0 || (signed char)b[0] < 0) - return 0; - /* we don't support compression yet */ - if (a[0] >= 64 || b[0] >= 64) - return 0; - - /* truncated case */ - if (a[0] == 0 && a - a0 == alen - 1) - return 1; - if (b[0] == 0 && b - b0 == blen - 1) - return 1; - if (a[0] == 0 || b[0] == 0) - return 0; - - if (a[0] != b[0]) - return 0; - l = a[0]; - if (a - a0 + 1 + l > alen || b - b0 + 1 + l > blen) - return 0; - if (bcmp(a + 1, b + 1, l) != 0) - return 0; - - a += 1 + l; - b += 1 + l; - } - - if (a - a0 == alen && b - b0 == blen) - return 1; - else - return 0; -} - -/* - * calculate the number of addresses to be returned in the node info reply. - */ -static int -ni6_addrs(struct icmp6_nodeinfo *ni6, struct mbuf *m, struct ifnet **ifpp, - struct in6_addr *subj) -{ - struct ifnet *ifp; - struct in6_ifaddr *ifa6; - struct ifaddr *ifa; - int addrs = 0, addrsofif, iffound = 0; - int niflags = ni6->ni_flags; - - if ((niflags & NI_NODEADDR_FLAG_ALL) == 0) { - switch (ni6->ni_code) { - case ICMP6_NI_SUBJ_IPV6: - if (subj == NULL) /* must be impossible... */ - return (0); - break; - default: - /* - * XXX: we only support IPv6 subject address for - * this Qtype. - */ - return (0); - } - } - - IFNET_RLOCK(); - for (ifp = TAILQ_FIRST(&ifnet); ifp; ifp = TAILQ_NEXT(ifp, if_list)) { - addrsofif = 0; - TAILQ_FOREACH(ifa, &ifp->if_addrlist, ifa_list) { - if (ifa->ifa_addr->sa_family != AF_INET6) - continue; - ifa6 = (struct in6_ifaddr *)ifa; - - if ((niflags & NI_NODEADDR_FLAG_ALL) == 0 && - IN6_ARE_ADDR_EQUAL(subj, &ifa6->ia_addr.sin6_addr)) - iffound = 1; - - /* - * IPv4-mapped addresses can only be returned by a - * Node Information proxy, since they represent - * addresses of IPv4-only nodes, which perforce do - * not implement this protocol. - * [icmp-name-lookups-07, Section 5.4] - * So we don't support NI_NODEADDR_FLAG_COMPAT in - * this function at this moment. - */ - - /* What do we have to do about ::1? */ - switch (in6_addrscope(&ifa6->ia_addr.sin6_addr)) { - case IPV6_ADDR_SCOPE_LINKLOCAL: - if ((niflags & NI_NODEADDR_FLAG_LINKLOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_SITELOCAL: - if ((niflags & NI_NODEADDR_FLAG_SITELOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_GLOBAL: - if ((niflags & NI_NODEADDR_FLAG_GLOBAL) == 0) - continue; - break; - default: - continue; - } - - /* - * check if anycast is okay. - * XXX: just experimental. not in the spec. - */ - if ((ifa6->ia6_flags & IN6_IFF_ANYCAST) != 0 && - (niflags & NI_NODEADDR_FLAG_ANYCAST) == 0) - continue; /* we need only unicast addresses */ - if ((ifa6->ia6_flags & IN6_IFF_TEMPORARY) != 0 && - (icmp6_nodeinfo & ICMP6_NODEINFO_TMPADDROK) == 0) { - continue; - } - addrsofif++; /* count the address */ - } - if (iffound) { - *ifpp = ifp; - IFNET_RUNLOCK(); - return (addrsofif); - } - - addrs += addrsofif; - } - IFNET_RUNLOCK(); - - return (addrs); -} - -static int -ni6_store_addrs(struct icmp6_nodeinfo *ni6, struct icmp6_nodeinfo *nni6, - struct ifnet *ifp0, int resid) -{ - struct ifnet *ifp = ifp0 ? ifp0 : TAILQ_FIRST(&ifnet); - struct in6_ifaddr *ifa6; - struct ifaddr *ifa; - struct ifnet *ifp_dep = NULL; - int copied = 0, allow_deprecated = 0; - u_char *cp = (u_char *)(nni6 + 1); - int niflags = ni6->ni_flags; - u_int32_t ltime; - - if (ifp0 == NULL && !(niflags & NI_NODEADDR_FLAG_ALL)) - return (0); /* needless to copy */ - - IFNET_RLOCK(); - again: - - for (; ifp; ifp = TAILQ_NEXT(ifp, if_list)) { - for (ifa = ifp->if_addrlist.tqh_first; ifa; - ifa = ifa->ifa_list.tqe_next) { - if (ifa->ifa_addr->sa_family != AF_INET6) - continue; - ifa6 = (struct in6_ifaddr *)ifa; - - if ((ifa6->ia6_flags & IN6_IFF_DEPRECATED) != 0 && - allow_deprecated == 0) { - /* - * prefererred address should be put before - * deprecated addresses. - */ - - /* record the interface for later search */ - if (ifp_dep == NULL) - ifp_dep = ifp; - - continue; - } else if ((ifa6->ia6_flags & IN6_IFF_DEPRECATED) == 0 && - allow_deprecated != 0) - continue; /* we now collect deprecated addrs */ - - /* What do we have to do about ::1? */ - switch (in6_addrscope(&ifa6->ia_addr.sin6_addr)) { - case IPV6_ADDR_SCOPE_LINKLOCAL: - if ((niflags & NI_NODEADDR_FLAG_LINKLOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_SITELOCAL: - if ((niflags & NI_NODEADDR_FLAG_SITELOCAL) == 0) - continue; - break; - case IPV6_ADDR_SCOPE_GLOBAL: - if ((niflags & NI_NODEADDR_FLAG_GLOBAL) == 0) - continue; - break; - default: - continue; - } - - /* - * check if anycast is okay. - * XXX: just experimental. not in the spec. - */ - if ((ifa6->ia6_flags & IN6_IFF_ANYCAST) != 0 && - (niflags & NI_NODEADDR_FLAG_ANYCAST) == 0) - continue; - if ((ifa6->ia6_flags & IN6_IFF_TEMPORARY) != 0 && - (icmp6_nodeinfo & ICMP6_NODEINFO_TMPADDROK) == 0) { - continue; - } - - /* now we can copy the address */ - if (resid < sizeof(struct in6_addr) + - sizeof(u_int32_t)) { - /* - * We give up much more copy. - * Set the truncate flag and return. - */ - nni6->ni_flags |= NI_NODEADDR_FLAG_TRUNCATE; - IFNET_RUNLOCK(); - return (copied); - } - - /* - * Set the TTL of the address. - * The TTL value should be one of the following - * according to the specification: - * - * 1. The remaining lifetime of a DHCP lease on the - * address, or - * 2. The remaining Valid Lifetime of a prefix from - * which the address was derived through Stateless - * Autoconfiguration. - * - * Note that we currently do not support stateful - * address configuration by DHCPv6, so the former - * case can't happen. - */ - if (ifa6->ia6_lifetime.ia6t_expire == 0) - ltime = ND6_INFINITE_LIFETIME; - else { - if (ifa6->ia6_lifetime.ia6t_expire > - time_second) - ltime = htonl(ifa6->ia6_lifetime.ia6t_expire - time_second); - else - ltime = 0; - } - - bcopy(<ime, cp, sizeof(u_int32_t)); - cp += sizeof(u_int32_t); - - /* copy the address itself */ - bcopy(&ifa6->ia_addr.sin6_addr, cp, - sizeof(struct in6_addr)); - in6_clearscope((struct in6_addr *)cp); /* XXX */ - cp += sizeof(struct in6_addr); - - resid -= (sizeof(struct in6_addr) + sizeof(u_int32_t)); - copied += (sizeof(struct in6_addr) + sizeof(u_int32_t)); - } - if (ifp0) /* we need search only on the specified IF */ - break; - } - - if (allow_deprecated == 0 && ifp_dep != NULL) { - ifp = ifp_dep; - allow_deprecated = 1; - - goto again; - } - - IFNET_RUNLOCK(); - - return (copied); -} - -/* - * XXX almost dup'ed code with rip6_input. - */ -static int -icmp6_rip6_input(struct mbuf **mp, int off) -{ - struct mbuf *m = *mp; - struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *); - struct in6pcb *in6p; - struct in6pcb *last = NULL; - struct sockaddr_in6 fromsa; - struct icmp6_hdr *icmp6; - struct mbuf *opts = NULL; - -#ifndef PULLDOWN_TEST - /* this is assumed to be safe. */ - icmp6 = (struct icmp6_hdr *)((caddr_t)ip6 + off); -#else - IP6_EXTHDR_GET(icmp6, struct icmp6_hdr *, m, off, sizeof(*icmp6)); - if (icmp6 == NULL) { - /* m is already reclaimed */ - return (IPPROTO_DONE); - } -#endif - - /* - * XXX: the address may have embedded scope zone ID, which should be - * hidden from applications. - */ - bzero(&fromsa, sizeof(fromsa)); - fromsa.sin6_family = AF_INET6; - fromsa.sin6_len = sizeof(struct sockaddr_in6); - fromsa.sin6_addr = ip6->ip6_src; - if (sa6_recoverscope(&fromsa)) { - m_freem(m); - return (IPPROTO_DONE); - } - - INP_INFO_RLOCK(&ripcbinfo); - LIST_FOREACH(in6p, &ripcb, inp_list) { - INP_LOCK(in6p); - if ((in6p->inp_vflag & INP_IPV6) == 0) { - docontinue: - INP_UNLOCK(in6p); - continue; - } - if (in6p->in6p_ip6_nxt != IPPROTO_ICMPV6) - goto docontinue; - if (!IN6_IS_ADDR_UNSPECIFIED(&in6p->in6p_laddr) && - !IN6_ARE_ADDR_EQUAL(&in6p->in6p_laddr, &ip6->ip6_dst)) - goto docontinue; - if (!IN6_IS_ADDR_UNSPECIFIED(&in6p->in6p_faddr) && - !IN6_ARE_ADDR_EQUAL(&in6p->in6p_faddr, &ip6->ip6_src)) - goto docontinue; - if (in6p->in6p_icmp6filt - && ICMP6_FILTER_WILLBLOCK(icmp6->icmp6_type, - in6p->in6p_icmp6filt)) - goto docontinue; - if (last) { - struct mbuf *n = NULL; - - /* - * Recent network drivers tend to allocate a single - * mbuf cluster, rather than to make a couple of - * mbufs without clusters. Also, since the IPv6 code - * path tries to avoid m_pullup(), it is highly - * probable that we still have an mbuf cluster here - * even though the necessary length can be stored in an - * mbuf's internal buffer. - * Meanwhile, the default size of the receive socket - * buffer for raw sockets is not so large. This means - * the possibility of packet loss is relatively higher - * than before. To avoid this scenario, we copy the - * received data to a separate mbuf that does not use - * a cluster, if possible. - * XXX: it is better to copy the data after stripping - * intermediate headers. - */ - if ((m->m_flags & M_EXT) && m->m_next == NULL && - m->m_len <= MHLEN) { - MGET(n, M_DONTWAIT, m->m_type); - if (n != NULL) { - if (m_dup_pkthdr(n, m, M_NOWAIT)) { - bcopy(m->m_data, n->m_data, - m->m_len); - n->m_len = m->m_len; - } else { - m_free(n); - n = NULL; - } - } - } - if (n != NULL || - (n = m_copy(m, 0, (int)M_COPYALL)) != NULL) { - if (last->in6p_flags & IN6P_CONTROLOPTS) - ip6_savecontrol(last, n, &opts); - /* strip intermediate headers */ - m_adj(n, off); - SOCKBUF_LOCK(&last->in6p_socket->so_rcv); - if (sbappendaddr_locked( - &last->in6p_socket->so_rcv, - (struct sockaddr *)&fromsa, n, opts) - == 0) { - /* should notify about lost packet */ - m_freem(n); - if (opts) { - m_freem(opts); - } - SOCKBUF_UNLOCK( - &last->in6p_socket->so_rcv); - } else - sorwakeup_locked(last->in6p_socket); - opts = NULL; - } - INP_UNLOCK(last); - } - last = in6p; - } - if (last) { - if (last->in6p_flags & IN6P_CONTROLOPTS) - ip6_savecontrol(last, m, &opts); - /* strip intermediate headers */ - m_adj(m, off); - - /* avoid using mbuf clusters if possible (see above) */ - if ((m->m_flags & M_EXT) && m->m_next == NULL && - m->m_len <= MHLEN) { - struct mbuf *n; - - MGET(n, M_DONTWAIT, m->m_type); - if (n != NULL) { - if (m_dup_pkthdr(n, m, M_NOWAIT)) { - bcopy(m->m_data, n->m_data, m->m_len); - n->m_len = m->m_len; - - m_freem(m); - m = n; - } else { - m_freem(n); - n = NULL; - } - } - } - SOCKBUF_LOCK(&last->in6p_socket->so_rcv); - if (sbappendaddr_locked(&last->in6p_socket->so_rcv, - (struct sockaddr *)&fromsa, m, opts) == 0) { - m_freem(m); - if (opts) - m_freem(opts); - SOCKBUF_UNLOCK(&last->in6p_socket->so_rcv); - } else - sorwakeup_locked(last->in6p_socket); - INP_UNLOCK(last); - } else { - m_freem(m); - ip6stat.ip6s_delivered--; - } - INP_INFO_RUNLOCK(&ripcbinfo); - return IPPROTO_DONE; -} - -/* - * Reflect the ip6 packet back to the source. - * OFF points to the icmp6 header, counted from the top of the mbuf. - */ -void -icmp6_reflect(struct mbuf *m, size_t off) -{ - struct ip6_hdr *ip6; - struct icmp6_hdr *icmp6; - struct in6_ifaddr *ia; - int plen; - int type, code; - struct ifnet *outif = NULL; - struct in6_addr origdst, *src = NULL; - - /* too short to reflect */ - if (off < sizeof(struct ip6_hdr)) { - nd6log((LOG_DEBUG, - "sanity fail: off=%lx, sizeof(ip6)=%lx in %s:%d\n", - (u_long)off, (u_long)sizeof(struct ip6_hdr), - __FILE__, __LINE__)); - goto bad; - } - - /* - * If there are extra headers between IPv6 and ICMPv6, strip - * off that header first. - */ -#ifdef DIAGNOSTIC - if (sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr) > MHLEN) - panic("assumption failed in icmp6_reflect"); -#endif - if (off > sizeof(struct ip6_hdr)) { - size_t l; - struct ip6_hdr nip6; - - l = off - sizeof(struct ip6_hdr); - m_copydata(m, 0, sizeof(nip6), (caddr_t)&nip6); - m_adj(m, l); - l = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr); - if (m->m_len < l) { - if ((m = m_pullup(m, l)) == NULL) - return; - } - bcopy((caddr_t)&nip6, mtod(m, caddr_t), sizeof(nip6)); - } else /* off == sizeof(struct ip6_hdr) */ { - size_t l; - l = sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr); - if (m->m_len < l) { - if ((m = m_pullup(m, l)) == NULL) - return; - } - } - plen = m->m_pkthdr.len - sizeof(struct ip6_hdr); - ip6 = mtod(m, struct ip6_hdr *); - ip6->ip6_nxt = IPPROTO_ICMPV6; - icmp6 = (struct icmp6_hdr *)(ip6 + 1); - type = icmp6->icmp6_type; /* keep type for statistics */ - code = icmp6->icmp6_code; /* ditto. */ - - origdst = ip6->ip6_dst; - /* - * ip6_input() drops a packet if its src is multicast. - * So, the src is never multicast. - */ - ip6->ip6_dst = ip6->ip6_src; - - /* - * If the incoming packet was addressed directly to us (i.e. unicast), - * use dst as the src for the reply. - * The IN6_IFF_NOTREADY case should be VERY rare, but is possible - * (for example) when we encounter an error while forwarding procedure - * destined to a duplicated address of ours. - * Note that ip6_getdstifaddr() may fail if we are in an error handling - * procedure of an outgoing packet of our own, in which case we need - * to search in the ifaddr list. - */ - if (!IN6_IS_ADDR_MULTICAST(&origdst)) { - if ((ia = ip6_getdstifaddr(m))) { - if (!(ia->ia6_flags & - (IN6_IFF_ANYCAST|IN6_IFF_NOTREADY))) - src = &ia->ia_addr.sin6_addr; - } else { - struct sockaddr_in6 d; - - bzero(&d, sizeof(d)); - d.sin6_family = AF_INET6; - d.sin6_len = sizeof(d); - d.sin6_addr = origdst; - ia = (struct in6_ifaddr *) - ifa_ifwithaddr((struct sockaddr *)&d); - if (ia && - !(ia->ia6_flags & - (IN6_IFF_ANYCAST|IN6_IFF_NOTREADY))) { - src = &ia->ia_addr.sin6_addr; - } - } - } - - if (src == NULL) { - int e; - struct sockaddr_in6 sin6; - struct route_in6 ro; - - /* - * This case matches to multicasts, our anycast, or unicasts - * that we do not own. Select a source address based on the - * source address of the erroneous packet. - */ - bzero(&sin6, sizeof(sin6)); - sin6.sin6_family = AF_INET6; - sin6.sin6_len = sizeof(sin6); - sin6.sin6_addr = ip6->ip6_dst; /* zone ID should be embedded */ - - bzero(&ro, sizeof(ro)); - src = in6_selectsrc(&sin6, NULL, NULL, &ro, NULL, &outif, &e); - if (ro.ro_rt) - RTFREE(ro.ro_rt); /* XXX: we could use this */ - if (src == NULL) { - char ip6buf[INET6_ADDRSTRLEN]; - nd6log((LOG_DEBUG, - "icmp6_reflect: source can't be determined: " - "dst=%s, error=%d\n", - ip6_sprintf(ip6buf, &sin6.sin6_addr), e)); - goto bad; - } - } - - ip6->ip6_src = *src; - ip6->ip6_flow = 0; - ip6->ip6_vfc &= ~IPV6_VERSION_MASK; - ip6->ip6_vfc |= IPV6_VERSION; - ip6->ip6_nxt = IPPROTO_ICMPV6; - if (outif) - ip6->ip6_hlim = ND_IFINFO(outif)->chlim; - else if (m->m_pkthdr.rcvif) { - /* XXX: This may not be the outgoing interface */ - ip6->ip6_hlim = ND_IFINFO(m->m_pkthdr.rcvif)->chlim; - } else - ip6->ip6_hlim = ip6_defhlim; - - icmp6->icmp6_cksum = 0; - icmp6->icmp6_cksum = in6_cksum(m, IPPROTO_ICMPV6, - sizeof(struct ip6_hdr), plen); - - /* - * XXX option handling - */ - - m->m_flags &= ~(M_BCAST|M_MCAST); - - ip6_output(m, NULL, NULL, 0, NULL, &outif, NULL); - if (outif) - icmp6_ifoutstat_inc(outif, type, code); - - return; - - bad: - m_freem(m); - return; -} - -void -icmp6_fasttimo(void) -{ - - return; -} - -static const char * -icmp6_redirect_diag(struct in6_addr *src6, struct in6_addr *dst6, - struct in6_addr *tgt6) -{ - static char buf[1024]; - char ip6bufs[INET6_ADDRSTRLEN]; - char ip6bufd[INET6_ADDRSTRLEN]; - char ip6buft[INET6_ADDRSTRLEN]; - snprintf(buf, sizeof(buf), "(src=%s dst=%s tgt=%s)", - ip6_sprintf(ip6bufs, src6), ip6_sprintf(ip6bufd, dst6), - ip6_sprintf(ip6buft, tgt6)); - return buf; -} - -void -icmp6_redirect_input(struct mbuf *m, int off) -{ - struct ifnet *ifp; - struct ip6_hdr *ip6 = mtod(m, struct ip6_hdr *); - struct nd_redirect *nd_rd; - int icmp6len = ntohs(ip6->ip6_plen); - char *lladdr = NULL; - int lladdrlen = 0; - u_char *redirhdr = NULL; - int redirhdrlen = 0; - struct rtentry *rt = NULL; - int is_router; - int is_onlink; - struct in6_addr src6 = ip6->ip6_src; - struct in6_addr redtgt6; - struct in6_addr reddst6; - union nd_opts ndopts; - char ip6buf[INET6_ADDRSTRLEN]; - - if (!m) - return; - - ifp = m->m_pkthdr.rcvif; - - if (!ifp) - return; - - /* XXX if we are router, we don't update route by icmp6 redirect */ - if (ip6_forwarding) - goto freeit; - if (!icmp6_rediraccept) - goto freeit; - -#ifndef PULLDOWN_TEST - IP6_EXTHDR_CHECK(m, off, icmp6len,); - nd_rd = (struct nd_redirect *)((caddr_t)ip6 + off); -#else - IP6_EXTHDR_GET(nd_rd, struct nd_redirect *, m, off, icmp6len); - if (nd_rd == NULL) { - icmp6stat.icp6s_tooshort++; - return; - } -#endif - redtgt6 = nd_rd->nd_rd_target; - reddst6 = nd_rd->nd_rd_dst; - - if (in6_setscope(&redtgt6, m->m_pkthdr.rcvif, NULL) || - in6_setscope(&reddst6, m->m_pkthdr.rcvif, NULL)) { - goto freeit; - } - - /* validation */ - if (!IN6_IS_ADDR_LINKLOCAL(&src6)) { - nd6log((LOG_ERR, - "ICMP6 redirect sent from %s rejected; " - "must be from linklocal\n", - ip6_sprintf(ip6buf, &src6))); - goto bad; - } - if (ip6->ip6_hlim != 255) { - nd6log((LOG_ERR, - "ICMP6 redirect sent from %s rejected; " - "hlim=%d (must be 255)\n", - ip6_sprintf(ip6buf, &src6), ip6->ip6_hlim)); - goto bad; - } - { - /* ip6->ip6_src must be equal to gw for icmp6->icmp6_reddst */ - struct sockaddr_in6 sin6; - struct in6_addr *gw6; - - bzero(&sin6, sizeof(sin6)); - sin6.sin6_family = AF_INET6; - sin6.sin6_len = sizeof(struct sockaddr_in6); - bcopy(&reddst6, &sin6.sin6_addr, sizeof(reddst6)); - rt = rtalloc1((struct sockaddr *)&sin6, 0, 0UL); - if (rt) { - if (rt->rt_gateway == NULL || - rt->rt_gateway->sa_family != AF_INET6) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; no route " - "with inet6 gateway found for redirect dst: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - RTFREE_LOCKED(rt); - goto bad; - } - - gw6 = &(((struct sockaddr_in6 *)rt->rt_gateway)->sin6_addr); - if (bcmp(&src6, gw6, sizeof(struct in6_addr)) != 0) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "not equal to gw-for-src=%s (must be same): " - "%s\n", - ip6_sprintf(ip6buf, gw6), - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - RTFREE_LOCKED(rt); - goto bad; - } - } else { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "no route found for redirect dst: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - RTFREE_LOCKED(rt); - rt = NULL; - } - if (IN6_IS_ADDR_MULTICAST(&reddst6)) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "redirect dst must be unicast: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - - is_router = is_onlink = 0; - if (IN6_IS_ADDR_LINKLOCAL(&redtgt6)) - is_router = 1; /* router case */ - if (bcmp(&redtgt6, &reddst6, sizeof(redtgt6)) == 0) - is_onlink = 1; /* on-link destination case */ - if (!is_router && !is_onlink) { - nd6log((LOG_ERR, - "ICMP6 redirect rejected; " - "neither router case nor onlink case: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - /* validation passed */ - - icmp6len -= sizeof(*nd_rd); - nd6_option_init(nd_rd + 1, icmp6len, &ndopts); - if (nd6_options(&ndopts) < 0) { - nd6log((LOG_INFO, "icmp6_redirect_input: " - "invalid ND option, rejected: %s\n", - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - /* nd6_options have incremented stats */ - goto freeit; - } - - if (ndopts.nd_opts_tgt_lladdr) { - lladdr = (char *)(ndopts.nd_opts_tgt_lladdr + 1); - lladdrlen = ndopts.nd_opts_tgt_lladdr->nd_opt_len << 3; - } - - if (ndopts.nd_opts_rh) { - redirhdrlen = ndopts.nd_opts_rh->nd_opt_rh_len; - redirhdr = (u_char *)(ndopts.nd_opts_rh + 1); /* xxx */ - } - - if (lladdr && ((ifp->if_addrlen + 2 + 7) & ~7) != lladdrlen) { - nd6log((LOG_INFO, - "icmp6_redirect_input: lladdrlen mismatch for %s " - "(if %d, icmp6 packet %d): %s\n", - ip6_sprintf(ip6buf, &redtgt6), - ifp->if_addrlen, lladdrlen - 2, - icmp6_redirect_diag(&src6, &reddst6, &redtgt6))); - goto bad; - } - - /* RFC 2461 8.3 */ - nd6_cache_lladdr(ifp, &redtgt6, lladdr, lladdrlen, ND_REDIRECT, - is_onlink ? ND_REDIRECT_ONLINK : ND_REDIRECT_ROUTER); - - if (!is_onlink) { /* better router case. perform rtredirect. */ - /* perform rtredirect */ - struct sockaddr_in6 sdst; - struct sockaddr_in6 sgw; - struct sockaddr_in6 ssrc; - - bzero(&sdst, sizeof(sdst)); - bzero(&sgw, sizeof(sgw)); - bzero(&ssrc, sizeof(ssrc)); - sdst.sin6_family = sgw.sin6_family = ssrc.sin6_family = AF_INET6; - sdst.sin6_len = sgw.sin6_len = ssrc.sin6_len = - sizeof(struct sockaddr_in6); - bcopy(&redtgt6, &sgw.sin6_addr, sizeof(struct in6_addr)); - bcopy(&reddst6, &sdst.sin6_addr, sizeof(struct in6_addr)); - bcopy(&src6, &ssrc.sin6_addr, sizeof(struct in6_addr)); - rtredirect((struct sockaddr *)&sdst, (struct sockaddr *)&sgw, - (struct sockaddr *)NULL, RTF_GATEWAY | RTF_HOST, - (struct sockaddr *)&ssrc); - } - /* finally update cached route in each socket via pfctlinput */ - { - struct sockaddr_in6 sdst; - - bzero(&sdst, sizeof(sdst)); - sdst.sin6_family = AF_INET6; - sdst.sin6_len = sizeof(struct sockaddr_in6); - bcopy(&reddst6, &sdst.sin6_addr, sizeof(struct in6_addr)); - pfctlinput(PRC_REDIRECT_HOST, (struct sockaddr *)&sdst); -#ifdef IPSEC - key_sa_routechange((struct sockaddr *)&sdst); -#endif /* IPSEC */ - } - - freeit: - m_freem(m); - return; - - bad: - icmp6stat.icp6s_badredirect++; - m_freem(m); -} - -void -icmp6_redirect_output(struct mbuf *m0, struct rtentry *rt) -{ - struct ifnet *ifp; /* my outgoing interface */ - struct in6_addr *ifp_ll6; - struct in6_addr *router_ll6; - struct ip6_hdr *sip6; /* m0 as struct ip6_hdr */ - struct mbuf *m = NULL; /* newly allocated one */ - struct ip6_hdr *ip6; /* m as struct ip6_hdr */ - struct nd_redirect *nd_rd; - size_t maxlen; - u_char *p; - struct ifnet *outif = NULL; - struct sockaddr_in6 src_sa; - - icmp6_errcount(&icmp6stat.icp6s_outerrhist, ND_REDIRECT, 0); - - /* if we are not router, we don't send icmp6 redirect */ - if (!ip6_forwarding) - goto fail; - - /* sanity check */ - if (!m0 || !rt || !(rt->rt_flags & RTF_UP) || !(ifp = rt->rt_ifp)) - goto fail; - - /* - * Address check: - * the source address must identify a neighbor, and - * the destination address must not be a multicast address - * [RFC 2461, sec 8.2] - */ - sip6 = mtod(m0, struct ip6_hdr *); - bzero(&src_sa, sizeof(src_sa)); - src_sa.sin6_family = AF_INET6; - src_sa.sin6_len = sizeof(src_sa); - src_sa.sin6_addr = sip6->ip6_src; - if (nd6_is_addr_neighbor(&src_sa, ifp) == 0) - goto fail; - if (IN6_IS_ADDR_MULTICAST(&sip6->ip6_dst)) - goto fail; /* what should we do here? */ - - /* rate limit */ - if (icmp6_ratelimit(&sip6->ip6_src, ND_REDIRECT, 0)) - goto fail; - - /* - * Since we are going to append up to 1280 bytes (= IPV6_MMTU), - * we almost always ask for an mbuf cluster for simplicity. - * (MHLEN < IPV6_MMTU is almost always true) - */ -#if IPV6_MMTU >= MCLBYTES -# error assumption failed about IPV6_MMTU and MCLBYTES -#endif - MGETHDR(m, M_DONTWAIT, MT_HEADER); - if (m && IPV6_MMTU >= MHLEN) - MCLGET(m, M_DONTWAIT); - if (!m) - goto fail; - m->m_pkthdr.rcvif = NULL; - m->m_len = 0; - maxlen = M_TRAILINGSPACE(m); - maxlen = min(IPV6_MMTU, maxlen); - /* just for safety */ - if (maxlen < sizeof(struct ip6_hdr) + sizeof(struct icmp6_hdr) + - ((sizeof(struct nd_opt_hdr) + ifp->if_addrlen + 7) & ~7)) { - goto fail; - } - - { - /* get ip6 linklocal address for ifp(my outgoing interface). */ - struct in6_ifaddr *ia; - if ((ia = in6ifa_ifpforlinklocal(ifp, - IN6_IFF_NOTREADY| - IN6_IFF_ANYCAST)) == NULL) - goto fail; - ifp_ll6 = &ia->ia_addr.sin6_addr; - } - - /* get ip6 linklocal address for the router. */ - if (rt->rt_gateway && (rt->rt_flags & RTF_GATEWAY)) { - struct sockaddr_in6 *sin6; - sin6 = (struct sockaddr_in6 *)rt->rt_gateway; - router_ll6 = &sin6->sin6_addr; - if (!IN6_IS_ADDR_LINKLOCAL(router_ll6)) - router_ll6 = (struct in6_addr *)NULL; - } else - router_ll6 = (struct in6_addr *)NULL; - - /* ip6 */ - ip6 = mtod(m, struct ip6_hdr *); - ip6->ip6_flow = 0; - ip6->ip6_vfc &= ~IPV6_VERSION_MASK; - ip6->ip6_vfc |= IPV6_VERSION; - /* ip6->ip6_plen will be set later */ - ip6->ip6_nxt = IPPROTO_ICMPV6; - ip6->ip6_hlim = 255; - /* ip6->ip6_src must be linklocal addr for my outgoing if. */ - bcopy(ifp_ll6, &ip6->ip6_src, sizeof(struct in6_addr)); - bcopy(&sip6->ip6_src, &ip6->ip6_dst, sizeof(struct in6_addr)); - - /* ND Redirect */ - nd_rd = (struct nd_redirect *)(ip6 + 1); - nd_rd->nd_rd_type = ND_REDIRECT; - nd_rd->nd_rd_code = 0; - nd_rd->nd_rd_reserved = 0; - if (rt->rt_flags & RTF_GATEWAY) { - /* - * nd_rd->nd_rd_target must be a link-local address in - * better router cases. - */ - if (!router_ll6) - goto fail; - bcopy(router_ll6, &nd_rd->nd_rd_target, - sizeof(nd_rd->nd_rd_target)); - bcopy(&sip6->ip6_dst, &nd_rd->nd_rd_dst, - sizeof(nd_rd->nd_rd_dst)); - } else { - /* make sure redtgt == reddst */ - bcopy(&sip6->ip6_dst, &nd_rd->nd_rd_target, - sizeof(nd_rd->nd_rd_target)); - bcopy(&sip6->ip6_dst, &nd_rd->nd_rd_dst, - sizeof(nd_rd->nd_rd_dst)); - } - - p = (u_char *)(nd_rd + 1); - - if (!router_ll6) - goto nolladdropt; - - { - /* target lladdr option */ - struct rtentry *rt_router = NULL; - int len; - struct sockaddr_dl *sdl; - struct nd_opt_hdr *nd_opt; - char *lladdr; - - rt_router = nd6_lookup(router_ll6, 0, ifp); - if (!rt_router) - goto nolladdropt; - len = sizeof(*nd_opt) + ifp->if_addrlen; - len = (len + 7) & ~7; /* round by 8 */ - /* safety check */ - if (len + (p - (u_char *)ip6) > maxlen) - goto nolladdropt; - if (!(rt_router->rt_flags & RTF_GATEWAY) && - (rt_router->rt_flags & RTF_LLINFO) && - (rt_router->rt_gateway->sa_family == AF_LINK) && - (sdl = (struct sockaddr_dl *)rt_router->rt_gateway) && - sdl->sdl_alen) { - nd_opt = (struct nd_opt_hdr *)p; - nd_opt->nd_opt_type = ND_OPT_TARGET_LINKADDR; - nd_opt->nd_opt_len = len >> 3; - lladdr = (char *)(nd_opt + 1); - bcopy(LLADDR(sdl), lladdr, ifp->if_addrlen); - p += len; - } - } -nolladdropt:; - - m->m_pkthdr.len = m->m_len = p - (u_char *)ip6; - - /* just to be safe */ -#ifdef M_DECRYPTED /*not openbsd*/ - if (m0->m_flags & M_DECRYPTED) - goto noredhdropt; -#endif - if (p - (u_char *)ip6 > maxlen) - goto noredhdropt; - - { - /* redirected header option */ - int len; - struct nd_opt_rd_hdr *nd_opt_rh; - - /* - * compute the maximum size for icmp6 redirect header option. - * XXX room for auth header? - */ - len = maxlen - (p - (u_char *)ip6); - len &= ~7; - - /* This is just for simplicity. */ - if (m0->m_pkthdr.len != m0->m_len) { - if (m0->m_next) { - m_freem(m0->m_next); - m0->m_next = NULL; - } - m0->m_pkthdr.len = m0->m_len; - } - - /* - * Redirected header option spec (RFC2461 4.6.3) talks nothing - * about padding/truncate rule for the original IP packet. - * From the discussion on IPv6imp in Feb 1999, - * the consensus was: - * - "attach as much as possible" is the goal - * - pad if not aligned (original size can be guessed by - * original ip6 header) - * Following code adds the padding if it is simple enough, - * and truncates if not. - */ - if (m0->m_next || m0->m_pkthdr.len != m0->m_len) - panic("assumption failed in %s:%d", __FILE__, - __LINE__); - - if (len - sizeof(*nd_opt_rh) < m0->m_pkthdr.len) { - /* not enough room, truncate */ - m0->m_pkthdr.len = m0->m_len = len - - sizeof(*nd_opt_rh); - } else { - /* enough room, pad or truncate */ - size_t extra; - - extra = m0->m_pkthdr.len % 8; - if (extra) { - /* pad if easy enough, truncate if not */ - if (8 - extra <= M_TRAILINGSPACE(m0)) { - /* pad */ - m0->m_len += (8 - extra); - m0->m_pkthdr.len += (8 - extra); - } else { - /* truncate */ - m0->m_pkthdr.len -= extra; - m0->m_len -= extra; - } - } - len = m0->m_pkthdr.len + sizeof(*nd_opt_rh); - m0->m_pkthdr.len = m0->m_len = len - - sizeof(*nd_opt_rh); - } - - nd_opt_rh = (struct nd_opt_rd_hdr *)p; - bzero(nd_opt_rh, sizeof(*nd_opt_rh)); - nd_opt_rh->nd_opt_rh_type = ND_OPT_REDIRECTED_HEADER; - nd_opt_rh->nd_opt_rh_len = len >> 3; - p += sizeof(*nd_opt_rh); - m->m_pkthdr.len = m->m_len = p - (u_char *)ip6; - - /* connect m0 to m */ - m_tag_delete_chain(m0, NULL); - m0->m_flags &= ~M_PKTHDR; - m->m_next = m0; - m->m_pkthdr.len = m->m_len + m0->m_len; - m0 = NULL; - } -noredhdropt:; - if (m0) { - m_freem(m0); - m0 = NULL; - } - - /* XXX: clear embedded link IDs in the inner header */ - in6_clearscope(&sip6->ip6_src); - in6_clearscope(&sip6->ip6_dst); - in6_clearscope(&nd_rd->nd_rd_target); - in6_clearscope(&nd_rd->nd_rd_dst); - - ip6->ip6_plen = htons(m->m_pkthdr.len - sizeof(struct ip6_hdr)); - - nd_rd->nd_rd_cksum = 0; - nd_rd->nd_rd_cksum = in6_cksum(m, IPPROTO_ICMPV6, - sizeof(*ip6), ntohs(ip6->ip6_plen)); - - /* send the packet to outside... */ - ip6_output(m, NULL, NULL, 0, NULL, &outif, NULL); - if (outif) { - icmp6_ifstat_inc(outif, ifs6_out_msg); - icmp6_ifstat_inc(outif, ifs6_out_redirect); - } - icmp6stat.icp6s_outhist[ND_REDIRECT]++; - - return; - -fail: - if (m) - m_freem(m); - if (m0) - m_freem(m0); -} - -/* - * ICMPv6 socket option processing. - */ -int -icmp6_ctloutput(struct socket *so, struct sockopt *sopt) -{ - int error = 0; - int optlen; - struct inpcb *inp = sotoinpcb(so); - int level, op, optname; - - if (sopt) { - level = sopt->sopt_level; - op = sopt->sopt_dir; - optname = sopt->sopt_name; - optlen = sopt->sopt_valsize; - } else - level = op = optname = optlen = 0; - - if (level != IPPROTO_ICMPV6) { - return EINVAL; - } - - switch (op) { - case PRCO_SETOPT: - switch (optname) { - case ICMP6_FILTER: - { - struct icmp6_filter *p; - - if (optlen != sizeof(*p)) { - error = EMSGSIZE; - break; - } - if (inp->in6p_icmp6filt == NULL) { - error = EINVAL; - break; - } - error = sooptcopyin(sopt, inp->in6p_icmp6filt, optlen, - optlen); - break; - } - - default: - error = ENOPROTOOPT; - break; - } - break; - - case PRCO_GETOPT: - switch (optname) { - case ICMP6_FILTER: - { - if (inp->in6p_icmp6filt == NULL) { - error = EINVAL; - break; - } - error = sooptcopyout(sopt, inp->in6p_icmp6filt, - sizeof(struct icmp6_filter)); - break; - } - - default: - error = ENOPROTOOPT; - break; - } - break; - } - - return (error); -} - -/* - * Perform rate limit check. - * Returns 0 if it is okay to send the icmp6 packet. - * Returns 1 if the router SHOULD NOT send this icmp6 packet due to rate - * limitation. - * - * XXX per-destination/type check necessary? - * - * dst - not used at this moment - * type - not used at this moment - * code - not used at this moment - */ -static int -icmp6_ratelimit(const struct in6_addr *dst, const int type, - const int code) -{ - int ret; - - ret = 0; /* okay to send */ - - /* PPS limit */ - if (!ppsratecheck(&icmp6errppslim_last, &icmp6errpps_count, - icmp6errppslim)) { - /* The packet is subject to rate limit */ - ret++; - } - - return ret; -} From laffer1 at midnightbsd.org Sat Jan 10 21:43:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:43:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: vfs_mount.c: prevent nmount(2) local arbitrary code execution Message-ID: <200901110243.n0B2hVCU088421@stargazer.midnightbsd.org> Log Message: ----------- prevent nmount(2) local arbitrary code execution Modified Files: -------------- src/sys/kern: vfs_mount.c (r1.5 -> r1.6) -------------- next part -------------- Index: vfs_mount.c =================================================================== RCS file: /home/cvs/src/sys/kern/vfs_mount.c,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/kern/vfs_mount.c -L sys/kern/vfs_mount.c -u -r1.5 -r1.6 --- sys/kern/vfs_mount.c +++ sys/kern/vfs_mount.c @@ -1830,7 +1830,8 @@ } if (*t != NULL) continue; - sprintf(errmsg, "mount option <%s> is unknown", p); + snprintf(errmsg, sizeof(errmsg), + "mount option <%s> is unknown", p); printf("%s\n", errmsg); ret = EINVAL; } From laffer1 at midnightbsd.org Sat Jan 10 21:45:04 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 10 Jan 2009 21:45:04 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/netinet: fix incorrect tcp padding on options Message-ID: <200901110245.n0B2j4bl088692@stargazer.midnightbsd.org> Log Message: ----------- fix incorrect tcp padding on options Modified Files: -------------- src/sys/netinet: tcp.h (r1.3 -> r1.4) tcp_output.c (r1.5 -> r1.6) -------------- next part -------------- Index: tcp_output.c =================================================================== RCS file: /home/cvs/src/sys/netinet/tcp_output.c,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/netinet/tcp_output.c -L sys/netinet/tcp_output.c -u -r1.5 -r1.6 --- sys/netinet/tcp_output.c +++ sys/netinet/tcp_output.c @@ -1281,12 +1281,16 @@ for (mask = 1; mask < TOF_MAXOPT; mask <<= 1) { if ((to->to_flags & mask) != mask) continue; + if (optlen == TCP_MAXOLEN) + break; switch (to->to_flags & mask) { case TOF_MSS: while (optlen % 4) { optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_MAXSEG) + continue; optlen += TCPOLEN_MAXSEG; *optp++ = TCPOPT_MAXSEG; *optp++ = TCPOLEN_MAXSEG; @@ -1299,6 +1303,8 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_WINDOW) + continue; optlen += TCPOLEN_WINDOW; *optp++ = TCPOPT_WINDOW; *optp++ = TCPOLEN_WINDOW; @@ -1309,6 +1315,8 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_SACK_PERMITTED) + continue; optlen += TCPOLEN_SACK_PERMITTED; *optp++ = TCPOPT_SACK_PERMITTED; *optp++ = TCPOLEN_SACK_PERMITTED; @@ -1318,6 +1326,8 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } + if (TCP_MAXOLEN - optlen < TCPOLEN_TIMESTAMP) + continue; optlen += TCPOLEN_TIMESTAMP; *optp++ = TCPOPT_TIMESTAMP; *optp++ = TCPOLEN_TIMESTAMP; @@ -1356,7 +1366,7 @@ optlen += TCPOLEN_NOP; *optp++ = TCPOPT_NOP; } - if (TCP_MAXOLEN - optlen < 2 + TCPOLEN_SACK) + if (TCP_MAXOLEN - optlen < TCPOLEN_SACKHDR + TCPOLEN_SACK) continue; optlen += TCPOLEN_SACKHDR; *optp++ = TCPOPT_SACK; @@ -1387,9 +1397,15 @@ optlen += TCPOLEN_EOL; *optp++ = TCPOPT_EOL; } + /* + * According to RFC 793 (STD0007): + * "The content of the header beyond the End-of-Option option + * must be header padding (i.e., zero)." + * and later: "The padding is composed of zeros." + */ while (optlen % 4) { - optlen += TCPOLEN_NOP; - *optp++ = TCPOPT_NOP; + optlen += TCPOLEN_PAD; + *optp++ = TCPOPT_PAD; } KASSERT(optlen <= TCP_MAXOLEN, ("%s: TCP options too long", __func__)); Index: tcp.h =================================================================== RCS file: /home/cvs/src/sys/netinet/tcp.h,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/netinet/tcp.h -L sys/netinet/tcp.h -u -r1.3 -r1.4 --- sys/netinet/tcp.h +++ sys/netinet/tcp.h @@ -79,6 +79,8 @@ #define TCPOPT_EOL 0 #define TCPOLEN_EOL 1 +#define TCPOPT_PAD 0 /* padding after EOL */ +#define TCPOLEN_PAD 1 #define TCPOPT_NOP 1 #define TCPOLEN_NOP 1 #define TCPOPT_MAXSEG 2 From laffer1 at midnightbsd.org Mon Jan 12 17:31:34 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 17:31:34 -0500 (EST) Subject: [Midnightbsd-cvs] mports: net/GeoIP: update to 1.4.5, add free database update script Message-ID: <200901122231.n0CMVYqT032441@stargazer.midnightbsd.org> Log Message: ----------- update to 1.4.5, add free database update script Modified Files: -------------- mports/net/GeoIP: Makefile (r1.1 -> r1.2) distinfo (r1.1 -> r1.2) pkg-plist (r1.1 -> r1.2) Added Files: ----------- mports/net/GeoIP/files: geoipupdate.sh (r1.1) -------------- next part -------------- Index: pkg-plist =================================================================== RCS file: /home/cvs/mports/net/GeoIP/pkg-plist,v retrieving revision 1.1 retrieving revision 1.2 diff -L net/GeoIP/pkg-plist -L net/GeoIP/pkg-plist -u -r1.1 -r1.2 --- net/GeoIP/pkg-plist +++ net/GeoIP/pkg-plist @@ -1,5 +1,7 @@ bin/geoiplookup +bin/geoiplookup6 bin/geoipupdate +bin/geoipupdate.sh @unexec if cmp -s %D/etc/GeoIP.conf %D/etc/GeoIP.conf.default; then rm -f %D/etc/GeoIP.conf; fi etc/GeoIP.conf.default include/GeoIP.h Index: Makefile =================================================================== RCS file: /home/cvs/mports/net/GeoIP/Makefile,v retrieving revision 1.1 retrieving revision 1.2 diff -L net/GeoIP/Makefile -L net/GeoIP/Makefile -u -r1.1 -r1.2 --- net/GeoIP/Makefile +++ net/GeoIP/Makefile @@ -6,9 +6,10 @@ # PORTNAME= GeoIP -PORTVERSION= 1.4.4 +PORTVERSION= 1.4.5 CATEGORIES= net geography -MASTER_SITES= http://www.maxmind.com/download/geoip/api/c/ +MASTER_SITES= http://www.maxmind.com/download/geoip/api/c/ \ + http://mirror.mcx2.org/ MAINTAINER= ports at MidnightBSD.org COMMENT= Find the country that any IP address or hostname originates from @@ -21,4 +22,7 @@ MAN1= geoiplookup.1 geoipupdate.1 +post-install: + ${INSTALL_SCRIPT} ${FILESDIR}/geoipupdate.sh ${PREFIX}/bin/ + .include Index: distinfo =================================================================== RCS file: /home/cvs/mports/net/GeoIP/distinfo,v retrieving revision 1.1 retrieving revision 1.2 diff -L net/GeoIP/distinfo -L net/GeoIP/distinfo -u -r1.1 -r1.2 --- net/GeoIP/distinfo +++ net/GeoIP/distinfo @@ -1,3 +1,3 @@ -MD5 (GeoIP-1.4.4.tar.gz) = 27c1320e41e67b9ddcf4118e4eaccd1d -SHA256 (GeoIP-1.4.4.tar.gz) = a5b2ee9298eaf8c160ccab5b3e2ecc1c38cf67d9dd4e97419427f89d08cfb78e -SIZE (GeoIP-1.4.4.tar.gz) = 944698 +MD5 (GeoIP-1.4.5.tar.gz) = d95c34cf8ebd48e357b1812db5d75cf1 +SHA256 (GeoIP-1.4.5.tar.gz) = cd62034fe0206be243cbb43723520987978d8e55ee61872f34fd60a31f5c6b18 +SIZE (GeoIP-1.4.5.tar.gz) = 986844 --- /dev/null +++ net/GeoIP/files/geoipupdate.sh @@ -0,0 +1,5 @@ +#!/bin/sh +cd /tmp +fetch http://64.246.48.99/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz +gunzip GeoIP.dat.gz +mv -f GeoIP.dat /usr/local/share/GeoIP From laffer1 at midnightbsd.org Mon Jan 12 17:38:05 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 17:38:05 -0500 (EST) Subject: [Midnightbsd-cvs] mports: net/rsync: update to 3.0.5 Message-ID: <200901122238.n0CMc5gx040000@stargazer.midnightbsd.org> Log Message: ----------- update to 3.0.5 Modified Files: -------------- mports/net/rsync: Makefile (r1.9 -> r1.10) distinfo (r1.5 -> r1.6) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/net/rsync/Makefile,v retrieving revision 1.9 retrieving revision 1.10 diff -L net/rsync/Makefile -L net/rsync/Makefile -u -r1.9 -r1.10 --- net/rsync/Makefile +++ net/rsync/Makefile @@ -7,7 +7,7 @@ # PORTNAME= rsync -PORTVERSION= 3.0.4 +PORTVERSION= 3.0.5 CATEGORIES= net ipv6 MASTER_SITES= http://rsync.samba.org/ftp/%SUBDIR%/ \ ftp://ftp.samba.org/pub/%SUBDIR%/ \ Index: distinfo =================================================================== RCS file: /home/cvs/mports/net/rsync/distinfo,v retrieving revision 1.5 retrieving revision 1.6 diff -L net/rsync/distinfo -L net/rsync/distinfo -u -r1.5 -r1.6 --- net/rsync/distinfo +++ net/rsync/distinfo @@ -1,6 +1,6 @@ -MD5 (rsync-3.0.4.tar.gz) = 2b2d159c9bd1b5f8adfd8b13da3a1f3f -SHA256 (rsync-3.0.4.tar.gz) = 743a49cf01d2e4cf57be7bfbb02e04c0b20e7b7ec58195c20df710b991cede51 -SIZE (rsync-3.0.4.tar.gz) = 773083 -MD5 (rsync-patches-3.0.4.tar.gz) = a7697d7002f7789faede7109b420b94c -SHA256 (rsync-patches-3.0.4.tar.gz) = 5d654231fbf38ec0cec76989d466c7e8eaa72caacae2758817ca842a21777d2e -SIZE (rsync-patches-3.0.4.tar.gz) = 159292 +MD5 (rsync-3.0.5.tar.gz) = a130e736c011572cb423b6245e97fc4b +SHA256 (rsync-3.0.5.tar.gz) = 40ac20af81d4bc19ed82381371d731f7fb5a26fe4c1e4d4461b1255db63743cb +SIZE (rsync-3.0.5.tar.gz) = 776613 +MD5 (rsync-patches-3.0.5.tar.gz) = ada27361a483f7366b9bb3dab4cba0d0 +SHA256 (rsync-patches-3.0.5.tar.gz) = 64d98f844645832c3ed749c5508db2b0653fad52b4f67a78e3e7934924ee5cae +SIZE (rsync-patches-3.0.5.tar.gz) = 161055 From laffer1 at midnightbsd.org Mon Jan 12 20:01:11 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 20:01:11 -0500 (EST) Subject: [Midnightbsd-cvs] mports: www/moinmoin: update to 1.7.3 Message-ID: <200901130101.n0D11BXf056198@stargazer.midnightbsd.org> Log Message: ----------- update to 1.7.3 Modified Files: -------------- mports/www/moinmoin: Makefile (r1.3 -> r1.4) distinfo (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/www/moinmoin/Makefile,v retrieving revision 1.3 retrieving revision 1.4 diff -L www/moinmoin/Makefile -L www/moinmoin/Makefile -u -r1.3 -r1.4 --- www/moinmoin/Makefile +++ www/moinmoin/Makefile @@ -7,7 +7,7 @@ # PORTNAME= moinmoin -PORTVERSION= 1.7.1 +PORTVERSION= 1.7.3 CATEGORIES= www python MASTER_SITES= http://static.moinmo.in/files/ DISTNAME= moin-${PORTVERSION} Index: distinfo =================================================================== RCS file: /home/cvs/mports/www/moinmoin/distinfo,v retrieving revision 1.3 retrieving revision 1.4 diff -L www/moinmoin/distinfo -L www/moinmoin/distinfo -u -r1.3 -r1.4 --- www/moinmoin/distinfo +++ www/moinmoin/distinfo @@ -1,3 +1,3 @@ -MD5 (moin-1.7.1.tar.gz) = 871337b8171c91f9a6803e5376857e8d -SHA256 (moin-1.7.1.tar.gz) = f2818bf700257c240962a4861b4cb1bc200ee51aa7390f90fdd345db8e8d79d7 -SIZE (moin-1.7.1.tar.gz) = 5468224 +MD5 (moin-1.7.3.tar.gz) = 871e2b0f7f449eb280e39799d94c152d +SHA256 (moin-1.7.3.tar.gz) = 96dee7627eabcd9738ae3ff0e7ab2305ce940b5c616b7360da550d9d0fdbc580 +SIZE (moin-1.7.3.tar.gz) = 5519733 From laffer1 at midnightbsd.org Mon Jan 12 21:52:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 12 Jan 2009 21:52:38 -0500 (EST) Subject: [Midnightbsd-cvs] mports: mail/linux-thunderbird: 2.0.0.19 Message-ID: <200901130252.n0D2qcFK066736@stargazer.midnightbsd.org> Log Message: ----------- 2.0.0.19 Modified Files: -------------- mports/mail/linux-thunderbird: Makefile (r1.17 -> r1.18) distinfo (r1.14 -> r1.15) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/mail/linux-thunderbird/Makefile,v retrieving revision 1.17 retrieving revision 1.18 diff -L mail/linux-thunderbird/Makefile -L mail/linux-thunderbird/Makefile -u -r1.17 -r1.18 --- mail/linux-thunderbird/Makefile +++ mail/linux-thunderbird/Makefile @@ -7,7 +7,7 @@ # PORTNAME= thunderbird -PORTVERSION= 2.0.0.18 +PORTVERSION= 2.0.0.19 CATEGORIES= mail MASTER_SITE_SUBDIR?= ${PORTNAME}/releases/${PORTVERSION}/linux-i686/en-US Index: distinfo =================================================================== RCS file: /home/cvs/mports/mail/linux-thunderbird/distinfo,v retrieving revision 1.14 retrieving revision 1.15 diff -L mail/linux-thunderbird/distinfo -L mail/linux-thunderbird/distinfo -u -r1.14 -r1.15 --- mail/linux-thunderbird/distinfo +++ mail/linux-thunderbird/distinfo @@ -1,3 +1,3 @@ -MD5 (thunderbird-2.0.0.18.tar.gz) = dfa9df28bcfab6306998f6cfc9e6f077 -SHA256 (thunderbird-2.0.0.18.tar.gz) = 9ad998b83481e04781b2f80c737a58cdf919e3cda6974afb3105044e4220dc86 -SIZE (thunderbird-2.0.0.18.tar.gz) = 11482752 +MD5 (thunderbird-2.0.0.19.tar.gz) = 3f09642db3493d38ddde83470ce8d422 +SHA256 (thunderbird-2.0.0.19.tar.gz) = fbb9f4394c03d0c0054baeebb047420f2240eb1a5cf8a8f5cc9cd7b57bdb2e9a +SIZE (thunderbird-2.0.0.19.tar.gz) = 11484804 From laffer1 at midnightbsd.org Tue Jan 13 02:22:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 13 Jan 2009 02:22:19 -0500 (EST) Subject: [Midnightbsd-cvs] mports: databases/mysql51-server: update ot mysql 5.1.30 Message-ID: <200901130722.n0D7MJch092306@stargazer.midnightbsd.org> Log Message: ----------- update ot mysql 5.1.30 Modified Files: -------------- mports/databases/mysql51-server: Makefile (r1.11 -> r1.12) distinfo (r1.7 -> r1.8) mports/databases/mysql51-server/files: mysql-server.sh.in (r1.3 -> r1.4) patch-extra_yassl_Makefile.in (r1.2 -> r1.3) patch-extra_yassl_taocrypt_Makefile.in (r1.2 -> r1.3) patch-mysys_default.c (r1.4 -> r1.5) Removed Files: ------------- mports/databases/mysql51-server/files: patch-client_mysql_upgrade.c -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/Makefile,v retrieving revision 1.11 retrieving revision 1.12 diff -L databases/mysql51-server/Makefile -L databases/mysql51-server/Makefile -u -r1.11 -r1.12 --- databases/mysql51-server/Makefile +++ databases/mysql51-server/Makefile @@ -7,13 +7,13 @@ # PORTNAME?= mysql -PORTVERSION= 5.1.26 +PORTVERSION= 5.1.30 PORTREVISION= 0 CATEGORIES= databases MASTER_SITES= ${MASTER_SITE_MYSQL} MASTER_SITE_SUBDIR= MySQL-5.1 PKGNAMESUFFIX?= -server -DISTNAME= ${PORTNAME}-${PORTVERSION}-rc +DISTNAME= ${PORTNAME}-${PORTVERSION} MAINTAINER= ports at MidnightBSD.org COMMENT= Multithreaded SQL database (server) Index: distinfo =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/distinfo,v retrieving revision 1.7 retrieving revision 1.8 diff -L databases/mysql51-server/distinfo -L databases/mysql51-server/distinfo -u -r1.7 -r1.8 --- databases/mysql51-server/distinfo +++ databases/mysql51-server/distinfo @@ -1,3 +1,3 @@ -MD5 (mysql-5.1.26-rc.tar.gz) = db4b30ef40493e0bfe9ca17dd8220cf5 -SHA256 (mysql-5.1.26-rc.tar.gz) = 3a782d85b1aa5b2a47e67e80021e022c06c9d429f8afbc6cde1333d0bcb97dc6 -SIZE (mysql-5.1.26-rc.tar.gz) = 28111441 +MD5 (mysql-5.1.30.tar.gz) = b658e58887a74dce65224ae0fc8ee06a +SHA256 (mysql-5.1.30.tar.gz) = cca90f5209808829e5bc811c5c017a054a4f75188e939b1c1c8b270d0514f624 +SIZE (mysql-5.1.30.tar.gz) = 29050568 Index: patch-extra_yassl_Makefile.in =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/patch-extra_yassl_Makefile.in,v retrieving revision 1.2 retrieving revision 1.3 diff -L databases/mysql51-server/files/patch-extra_yassl_Makefile.in -L databases/mysql51-server/files/patch-extra_yassl_Makefile.in -u -r1.2 -r1.3 --- databases/mysql51-server/files/patch-extra_yassl_Makefile.in +++ databases/mysql51-server/files/patch-extra_yassl_Makefile.in @@ -1,11 +1,11 @@ ---- extra/yassl/Makefile.in.orig Thu Oct 26 14:02:58 2006 -+++ extra/yassl/Makefile.in Tue Nov 7 08:17:34 2006 -@@ -351,7 +351,7 @@ +--- extra/yassl/Makefile.in.orig 2008-10-11 23:58:20.000000000 +0200 ++++ extra/yassl/Makefile.in 2008-10-31 08:14:13.000000000 +0100 +@@ -355,7 +355,7 @@ yassl_libs = @yassl_libs@ yassl_taocrypt_extra_cxxflags = @yassl_taocrypt_extra_cxxflags@ zlib_dir = @zlib_dir@ -SUBDIRS = taocrypt src testsuite +SUBDIRS = taocrypt src - EXTRA_DIST = yassl.dsp yassl.dsw yassl.vcproj \ - CMakeLists.txt + EXTRA_DIST = CMakeLists.txt + all: all-recursive Index: patch-mysys_default.c =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/patch-mysys_default.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L databases/mysql51-server/files/patch-mysys_default.c -L databases/mysql51-server/files/patch-mysys_default.c -u -r1.4 -r1.5 --- databases/mysql51-server/files/patch-mysys_default.c +++ databases/mysql51-server/files/patch-mysys_default.c @@ -1,6 +1,6 @@ ---- mysys/default.c.orig 2008-04-08 13:23:13.000000000 +0200 -+++ mysys/default.c 2008-04-21 19:20:44.000000000 +0200 -@@ -623,7 +623,7 @@ +--- mysys/default.c.orig 2008-08-28 17:40:47.000000000 +0200 ++++ mysys/default.c 2008-09-16 08:20:23.000000000 +0200 +@@ -638,7 +638,7 @@ { MY_STAT stat_info; if (!my_stat(name,&stat_info,MYF(0))) @@ -9,11 +9,14 @@ /* Ignore world-writable regular files. This is mainly done to protect us to not read a file created by -@@ -1105,6 +1105,7 @@ - #ifdef DEFAULT_SYSCONFDIR +@@ -1091,7 +1091,10 @@ + + #if defined(DEFAULT_SYSCONFDIR) if (DEFAULT_SYSCONFDIR != "") - ADD_DIRECTORY(DEFAULT_SYSCONFDIR); -+ ADD_DIRECTORY(DEFAULT_SYSCONFDIR "/mysql/"); ++ { + errors += add_directory(alloc, DEFAULT_SYSCONFDIR, dirs); ++ errors += add_directory(alloc, DEFAULT_SYSCONFDIR "/mysql", dirs); ++ } + #endif /* DEFAULT_SYSCONFDIR */ + #endif - ADD_COMMON_DIRECTORIES(); - ADD_DIRECTORY("~/"); Index: mysql-server.sh.in =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/mysql-server.sh.in,v retrieving revision 1.3 retrieving revision 1.4 diff -L databases/mysql51-server/files/mysql-server.sh.in -L databases/mysql51-server/files/mysql-server.sh.in -u -r1.3 -r1.4 --- databases/mysql51-server/files/mysql-server.sh.in +++ databases/mysql51-server/files/mysql-server.sh.in @@ -1,8 +1,6 @@ #!/bin/sh # # $MidnightBSD$ -# $FreeBSD: ports/databases/mysql51-server/files/mysql-server.sh.in,v 1.4 2007/05/20 08:31:37 ale Exp $ -# # PROVIDE: mysql # REQUIRE: LOGIN @@ -37,9 +35,10 @@ mysql_limits_args="-e -U ${mysql_user}" pidfile="${mysql_dbdir}/`/bin/hostname`.pid" command="%%PREFIX%%/bin/mysqld_safe" -command_args="--defaults-extra-file=${mysql_dbdir}/my.cnf --user=${mysql_user} --datadir=${mysql_dbdir} --pid-file=${pidfile} ${mysql_args} > /dev/null &" +command_args="--defaults-extra-file=${mysql_dbdir}/my.cnf --user=${mysql_user} --datadir=${mysql_dbdir} --pid-file=${pidfile} ${mysql_args} > /dev/null 2>&1 &" procname="%%PREFIX%%/libexec/mysqld" start_precmd="${name}_prestart" +start_postcmd="${name}_poststart" mysql_install_db="%%PREFIX%%/bin/mysql_install_db" mysql_install_db_args="--ldata=${mysql_dbdir}" @@ -61,4 +60,14 @@ fi } +mysql_poststart() +{ + local timeout=15 + while [ ! -f "${pidfile}" -a ${timeout} -gt 0 ]; do + timeout=$(( timeout - 1 )) + sleep 1 + done + return 0 +} + run_rc_command "$1" Index: patch-extra_yassl_taocrypt_Makefile.in =================================================================== RCS file: /home/cvs/mports/databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in,v retrieving revision 1.2 retrieving revision 1.3 diff -L databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in -L databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in -u -r1.2 -r1.3 --- databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in +++ databases/mysql51-server/files/patch-extra_yassl_taocrypt_Makefile.in @@ -1,11 +1,11 @@ ---- extra/yassl/taocrypt/Makefile.in.orig Thu Oct 26 14:02:59 2006 -+++ extra/yassl/taocrypt/Makefile.in Tue Nov 7 08:18:38 2006 -@@ -351,7 +351,7 @@ +--- extra/yassl/taocrypt/Makefile.in.orig 2008-10-11 23:58:20.000000000 +0200 ++++ extra/yassl/taocrypt/Makefile.in 2008-10-31 08:15:56.000000000 +0100 +@@ -355,7 +355,7 @@ yassl_libs = @yassl_libs@ yassl_taocrypt_extra_cxxflags = @yassl_taocrypt_extra_cxxflags@ zlib_dir = @zlib_dir@ -SUBDIRS = src test benchmark +SUBDIRS = src - EXTRA_DIST = taocrypt.dsw taocrypt.dsp taocrypt.vcproj CMakeLists.txt $(wildcard mySTL/*.hpp) + EXTRA_DIST = CMakeLists.txt $(wildcard mySTL/*.hpp) all: all-recursive --- databases/mysql51-server/files/patch-client_mysql_upgrade.c +++ /dev/null @@ -1,13 +0,0 @@ ---- client/mysql_upgrade.c.orig 2008-01-29 22:42:00.000000000 +0100 -+++ client/mysql_upgrade.c 2008-02-14 08:29:52.000000000 +0100 -@@ -427,10 +427,6 @@ - - verbose("Looking for '%s' in: %s", tool_name, tool_path); - -- /* Make sure the tool exists */ -- if (my_access(tool_path, F_OK) != 0) -- die("Can't find '%s'", tool_path); -- - /* - Make sure it can be executed - */ From laffer1 at midnightbsd.org Tue Jan 13 02:22:34 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 13 Jan 2009 02:22:34 -0500 (EST) Subject: [Midnightbsd-cvs] mports: patch-client_mysql.cc: Message-ID: <200901130722.n0D7MYTK092361@stargazer.midnightbsd.org> Log Message: ----------- Added Files: ----------- mports/databases/mysql51-server/files: patch-client_mysql.cc (r1.1) -------------- next part -------------- --- /dev/null +++ databases/mysql51-server/files/patch-client_mysql.cc @@ -0,0 +1,27 @@ +--- client/mysql.cc.orig 2007-11-13 13:29:42 +0000 ++++ client/mysql.cc 2008-05-01 19:16:09 +0000 +@@ -2636,9 +2636,12 @@ + { + while((field = mysql_fetch_field(result))) + { +- tee_fprintf(PAGER, "%s", (field->name ? +- (field->name[0] ? field->name : +- "   ") : "NULL")); ++ tee_fputs("", PAGER); ++ if (field->name && field->name[0]) ++ xmlencode_print(field->name, field->name_length); ++ else ++ tee_fputs(field->name ? "   " : "NULL", PAGER); ++ tee_fputs("", PAGER); + } + (void) tee_fputs("", PAGER); + } +@@ -2651,7 +2654,7 @@ + for (uint i=0; i < mysql_num_fields(result); i++) + { + (void) tee_fputs("", PAGER); +- safe_put_field(cur[i],lengths[i]); ++ xmlencode_print(cur[i], lengths[i]); + (void) tee_fputs("", PAGER); + } + (void) tee_fputs("", PAGER); From laffer1 at midnightbsd.org Thu Jan 15 11:16:49 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 11:16:49 -0500 (EST) Subject: [Midnightbsd-cvs] src: /src: MidnightBSD 0.2.1-p6: Bind security update Message-ID: <200901151616.n0FGGnoD028092@stargazer.midnightbsd.org> Log Message: ----------- MidnightBSD 0.2.1-p6: Bind security update Tags: ---- RELENG_0_2 Modified Files: -------------- src: UPDATING (r1.38.2.14 -> r1.38.2.15) src/sys/conf: newvers.sh (r1.3.2.8 -> r1.3.2.9) src/contrib/bind9/lib/dns: openssldsa_link.c (r1.1.1.4 -> r1.1.1.4.2.1) opensslrsa_link.c (r1.1.1.4 -> r1.1.1.4.2.1) -------------- next part -------------- Index: newvers.sh =================================================================== RCS file: /home/cvs/src/sys/conf/newvers.sh,v retrieving revision 1.3.2.8 retrieving revision 1.3.2.9 diff -L sys/conf/newvers.sh -L sys/conf/newvers.sh -u -r1.3.2.8 -r1.3.2.9 --- sys/conf/newvers.sh +++ sys/conf/newvers.sh @@ -33,7 +33,7 @@ TYPE="MidnightBSD" REVISION="0.2.1" -BRANCH="RELEASE-p5" +BRANCH="RELEASE-p6" if [ "X${BRANCH_OVERRIDE}" != "X" ]; then BRANCH=${BRANCH_OVERRIDE} fi Index: UPDATING =================================================================== RCS file: /home/cvs/src/UPDATING,v retrieving revision 1.38.2.14 retrieving revision 1.38.2.15 diff -L UPDATING -L UPDATING -u -r1.38.2.14 -r1.38.2.15 --- UPDATING +++ UPDATING @@ -3,6 +3,12 @@ Items affecting the mports and packages system can be found in /usr/mports/UPDATING. +20090115: + MidnightBSD 0.2.1-RELEASE-p6 + + Correct an issue with BIND that allows for DNSSEC spoofing + attacks. + 20090110: MidnightBSD 0.2.1-RELEASE-p5 Index: opensslrsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/opensslrsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.1.1.4.2.1 diff -L contrib/bind9/lib/dns/opensslrsa_link.c -L contrib/bind9/lib/dns/opensslrsa_link.c -u -r1.1.1.4 -r1.1.1.4.2.1 --- contrib/bind9/lib/dns/opensslrsa_link.c +++ contrib/bind9/lib/dns/opensslrsa_link.c @@ -246,7 +246,7 @@ status = RSA_verify(type, digest, digestlen, sig->base, RSA_size(rsa), rsa); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); Index: openssldsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/openssldsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.1.1.4.2.1 diff -L contrib/bind9/lib/dns/openssldsa_link.c -L contrib/bind9/lib/dns/openssldsa_link.c -u -r1.1.1.4 -r1.1.1.4.2.1 --- contrib/bind9/lib/dns/openssldsa_link.c +++ contrib/bind9/lib/dns/openssldsa_link.c @@ -133,7 +133,7 @@ status = DSA_do_verify(digest, ISC_SHA1_DIGESTLENGTH, dsasig, dsa); DSA_SIG_free(dsasig); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); From laffer1 at midnightbsd.org Thu Jan 15 11:20:39 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 11:20:39 -0500 (EST) Subject: [Midnightbsd-cvs] src: lib/dns: bind security update with DNSSEC Message-ID: <200901151620.n0FGKckY028481@stargazer.midnightbsd.org> Log Message: ----------- bind security update with DNSSEC Modified Files: -------------- src/contrib/bind9/lib/dns: openssldsa_link.c (r1.1.1.4 -> r1.2) opensslrsa_link.c (r1.1.1.4 -> r1.2) -------------- next part -------------- Index: opensslrsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/opensslrsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.2 diff -L contrib/bind9/lib/dns/opensslrsa_link.c -L contrib/bind9/lib/dns/opensslrsa_link.c -u -r1.1.1.4 -r1.2 --- contrib/bind9/lib/dns/opensslrsa_link.c +++ contrib/bind9/lib/dns/opensslrsa_link.c @@ -246,7 +246,7 @@ status = RSA_verify(type, digest, digestlen, sig->base, RSA_size(rsa), rsa); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); Index: openssldsa_link.c =================================================================== RCS file: /home/cvs/src/contrib/bind9/lib/dns/openssldsa_link.c,v retrieving revision 1.1.1.4 retrieving revision 1.2 diff -L contrib/bind9/lib/dns/openssldsa_link.c -L contrib/bind9/lib/dns/openssldsa_link.c -u -r1.1.1.4 -r1.2 --- contrib/bind9/lib/dns/openssldsa_link.c +++ contrib/bind9/lib/dns/openssldsa_link.c @@ -133,7 +133,7 @@ status = DSA_do_verify(digest, ISC_SHA1_DIGESTLENGTH, dsasig, dsa); DSA_SIG_free(dsasig); - if (status == 0) + if (status != 1) return (dst__openssl_toresult(DST_R_VERIFYFAILURE)); return (ISC_R_SUCCESS); From laffer1 at midnightbsd.org Thu Jan 15 14:35:09 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 14:35:09 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: bind sec update Message-ID: <200901151935.n0FJZ9G6045359@stargazer.midnightbsd.org> Log Message: ----------- bind sec update Modified Files: -------------- www/security: index.html (r1.13 -> r1.14) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/security/index.html,v retrieving revision 1.13 retrieving revision 1.14 diff -L security/index.html -L security/index.html -u -r1.13 -r1.14 --- security/index.html +++ security/index.html @@ -17,6 +17,11 @@

Security Updates

+
+

January 15, 2009

+

Prevent a DNSSEC attack with BIND. This was corrected in 0.2.1 and 0.3-CURRENT. 0.1.x is no longer receiving security patches. It + is recommended that you upgrade to 0.2.1-RELEASE when possible.

+

January 10, 2009

Fix two issues with MidnightBSD 0.2.1 and 0.3-CURRENT. The first is in OpenSSL and would allow applications that use OpenSSL to interpret an From laffer1 at midnightbsd.org Thu Jan 15 14:38:51 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 14:38:51 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: add sec updates Message-ID: <200901151938.n0FJcpBO045543@stargazer.midnightbsd.org> Log Message: ----------- add sec updates Modified Files: -------------- www: index.html (r1.64 -> r1.65) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/index.html,v retrieving revision 1.64 retrieving revision 1.65 diff -L index.html -L index.html -u -r1.64 -r1.65 --- index.html +++ index.html @@ -63,14 +63,15 @@

Security »

-

December 31, 2008

-

Correct a problem where bluetooth and netgraph sockets...

-

Read more...

+

January 15, 2009

+

Prevent a DNSSEC attack with BIND. This was corrected in 0.2.1 and 0.3... +

+

Read more...

-

November 24, 2008

-

Correct a problem in arc4random which causes the device...

-

Read more...

+

January 10, 2009

+

Fix two issues with MidnightBSD 0.2.1 and 0.3-CURRENT. The first is in OpenSSL...

+

Read more...

From laffer1 at midnightbsd.org Thu Jan 15 18:20:54 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 18:20:54 -0500 (EST) Subject: [Midnightbsd-cvs] src: usr.sbin/boot0cfg: fix man page and add directions to go back to Message-ID: <200901152320.n0FNKs8R066717@stargazer.midnightbsd.org> Log Message: ----------- fix man page and add directions to go back to standard boot Modified Files: -------------- src/usr.sbin/boot0cfg: Makefile (r1.1.1.1 -> r1.2) boot0cfg.8 (r1.1.1.1 -> r1.2) boot0cfg.c (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: boot0cfg.c =================================================================== RCS file: /home/cvs/src/usr.sbin/boot0cfg/boot0cfg.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L usr.sbin/boot0cfg/boot0cfg.c -L usr.sbin/boot0cfg/boot0cfg.c -u -r1.1.1.1 -r1.2 --- usr.sbin/boot0cfg/boot0cfg.c +++ usr.sbin/boot0cfg/boot0cfg.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.c,v 1.19.2.1 2005/08/16 22:45:33 phk Exp $"); +__FBSDID("$FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.c,v 1.20 2005/07/15 08:04:32 phk Exp $"); #include #include Index: boot0cfg.8 =================================================================== RCS file: /home/cvs/src/usr.sbin/boot0cfg/boot0cfg.8,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L usr.sbin/boot0cfg/boot0cfg.8 -L usr.sbin/boot0cfg/boot0cfg.8 -u -r1.1.1.1 -r1.2 --- usr.sbin/boot0cfg/boot0cfg.8 +++ usr.sbin/boot0cfg/boot0cfg.8 @@ -22,9 +22,9 @@ .\" OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, .\" EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.8,v 1.29 2005/04/07 20:04:55 scottl Exp $ +.\" $FreeBSD: src/usr.sbin/boot0cfg/boot0cfg.8,v 1.32 2007/06/07 07:43:04 pav Exp $ .\" -.Dd February 21, 1999 +.Dd June 7, 2007 .Dt BOOT0CFG 8 .Os .Sh NAME @@ -43,7 +43,7 @@ .Ar disk .Sh DESCRIPTION The -.Fx +.Mx .Sq boot0 boot manager permits the operator to select from which disk and slice an i386 machine (PC) is booted. @@ -163,6 +163,13 @@ To enable just slices 1 and 2 in the menu: .Pp .Dl "boot0cfg -m 0x3 ad0" +.Pp +To go back to non-interactive booting, use +.Xr fdisk 8 +to install the default MBR: +.Pp +.Dl "fdisk -B ad0" +.Pp .Sh SEE ALSO .Xr geom 4 , .Xr boot 8 , Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.sbin/boot0cfg/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L usr.sbin/boot0cfg/Makefile -L usr.sbin/boot0cfg/Makefile -u -r1.1.1.1 -r1.2 --- usr.sbin/boot0cfg/Makefile +++ usr.sbin/boot0cfg/Makefile @@ -1,4 +1,4 @@ -# $FreeBSD: src/usr.sbin/boot0cfg/Makefile,v 1.8.12.1 2005/08/16 22:45:33 phk Exp $ +# $FreeBSD: src/usr.sbin/boot0cfg/Makefile,v 1.9 2005/07/15 08:04:32 phk Exp $ PROG= boot0cfg MAN= boot0cfg.8 From laffer1 at midnightbsd.org Thu Jan 15 23:21:33 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:21:33 -0500 (EST) Subject: [Midnightbsd-cvs] src: UPDATING: DNSSEC bind update. Message-ID: <200901160421.n0G4LXMi095273@stargazer.midnightbsd.org> Log Message: ----------- DNSSEC bind update. Modified Files: -------------- src: UPDATING (r1.50 -> r1.51) -------------- next part -------------- Index: UPDATING =================================================================== RCS file: /home/cvs/src/UPDATING,v retrieving revision 1.50 retrieving revision 1.51 diff -L UPDATING -L UPDATING -u -r1.50 -r1.51 --- UPDATING +++ UPDATING @@ -3,7 +3,10 @@ Items affecting the mports and packages system can be found in /usr/mports/UPDATING. -20080110: +20090115: + Fix a problem with DNSSEC and BIND. + +20090110: For applications using OpenSSL for SSL connections, an invalid SSL certificate may be interpreted as valid. This could for example be used by an attacker to perform a man-in-the-middle attack. @@ -13,10 +16,10 @@ Stop cross site request forgery attacks in lukemftpd -20080104: +20090104: Import GNU libreadline 5.2 -20080101: +20090101: Update time zone data to 2008i. 20081231: From laffer1 at midnightbsd.org Thu Jan 15 23:26:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:26:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: install-iso2img.sh: Make some needed changes. Message-ID: <200901160426.n0G4QVT2095746@stargazer.midnightbsd.org> Log Message: ----------- Make some needed changes. Switch to pax. Modified Files: -------------- src/nrelease: install-iso2img.sh (r1.2 -> r1.3) -------------- next part -------------- Index: install-iso2img.sh =================================================================== RCS file: /home/cvs/src/nrelease/install-iso2img.sh,v retrieving revision 1.2 retrieving revision 1.3 diff -L nrelease/install-iso2img.sh -L nrelease/install-iso2img.sh -u -r1.2 -r1.3 --- nrelease/install-iso2img.sh +++ nrelease/install-iso2img.sh @@ -1,7 +1,5 @@ #!/bin/sh # beerware license, written by Dario Freni (saturnero at freesbie.org) -# -# You can set some variables here. Edit them to fit your needs. # Set serial variable to 0 if you don't want serial console at all, # 1 if you want comconsole and 2 if you want comconsole and vidconsole @@ -41,9 +39,7 @@ mount /dev/${imgdev}a ${tmpdir}/img echo "Copying files to the image..." -( cd ${tmpdir}/iso && find . -print -depth | gcpio -dump ${tmpdir}/img ) -#bzcat ${tmpdir}/iso/dist/root.dist.bz2 | mtree -PUr -p ${tmpdir}/img 2>&= -#1 > /dev/null +( cd ${tmpdir}/iso && pax -rw . ${tmpdir}/img ) #echo "/dev/ufs/${UFS_LABEL} / ufs ro 1 1" > ${tmpdir}/img/etc/fstab From laffer1 at midnightbsd.org Thu Jan 15 23:40:21 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:40:21 -0500 (EST) Subject: [Midnightbsd-cvs] src: pf_table.c: MidnightBSDize Message-ID: <200901160440.n0G4eLVW097094@stargazer.midnightbsd.org> Log Message: ----------- MidnightBSDize Modified Files: -------------- src/sys/contrib/pf/net: pf_table.c (r1.2 -> r1.3) -------------- next part -------------- Index: pf_table.c =================================================================== RCS file: /home/cvs/src/sys/contrib/pf/net/pf_table.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/contrib/pf/net/pf_table.c -L sys/contrib/pf/net/pf_table.c -u -r1.2 -r1.3 --- sys/contrib/pf/net/pf_table.c +++ sys/contrib/pf/net/pf_table.c @@ -30,7 +30,7 @@ * */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #include "opt_inet.h" #include "opt_inet6.h" @@ -43,7 +43,7 @@ #include #include #include -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #include #endif @@ -51,8 +51,10 @@ #include #include #ifndef __FreeBSD__ +#ifndef __MidnightBSD__ #include #endif +#endif #include @@ -63,7 +65,7 @@ return (EINVAL); \ } while (0) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) static inline int _copyin(const void *uaddr, void *kaddr, size_t len) { @@ -176,7 +178,7 @@ #define senderr(e) do { rv = (e); goto _bad; } while (0) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) uma_zone_t pfr_ktable_pl; uma_zone_t pfr_kentry_pl; uma_zone_t pfr_kentry_pl2; @@ -248,6 +250,7 @@ pfr_initialize(void) { #ifndef __FreeBSD__ +#ifndef __MidnightBSD__ pool_init(&pfr_ktable_pl, sizeof(struct pfr_ktable), 0, 0, 0, "pfrktable", &pool_allocator_oldnointr); pool_init(&pfr_kentry_pl, sizeof(struct pfr_kentry), 0, 0, 0, @@ -255,6 +258,7 @@ pool_init(&pfr_kentry_pl2, sizeof(struct pfr_kentry), 0, 0, 0, "pfrkentry2", NULL); #endif +#endif pfr_sin.sin_len = sizeof(pfr_sin); pfr_sin.sin_family = AF_INET; @@ -641,13 +645,13 @@ w.pfrw_addr = addr; w.pfrw_free = kt->pfrkt_cnt; w.pfrw_flags = flags; -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rv = rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #endif if (!rv) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else @@ -693,13 +697,13 @@ w.pfrw_flags = flags; if (flags & PFR_FLAG_ATOMIC) s = splsoftnet(); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rv = rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #endif if (!rv) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rv = kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else @@ -819,7 +823,7 @@ w.pfrw_op = sweep ? PFRW_SWEEP : PFRW_ENQUEUE; w.pfrw_workq = workq; if (kt->pfrkt_ip4 != NULL) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w)) #else @@ -827,7 +831,7 @@ #endif printf("pfr_enqueue_addrs: IPv4 walktree failed.\n"); if (kt->pfrkt_ip6 != NULL) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w)) #else @@ -845,13 +849,13 @@ bzero(&w, sizeof(w)); w.pfrw_op = PFRW_MARK; -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w)) #else if (rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w)) #endif printf("pfr_mark_addrs: IPv4 walktree failed.\n"); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) if (kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w)) #else if (rn_walktree(kt->pfrkt_ip6, pfr_walktree, &w)) @@ -879,7 +883,7 @@ if (ADDR_NETWORK(ad)) { pfr_prepare_network(&mask, ad->pfra_af, ad->pfra_net); s = splsoftnet(); /* rn_lookup makes use of globals */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) PF_ASSERT(MA_OWNED); #endif ke = (struct pfr_kentry *)rn_lookup(&sa, &mask, head); @@ -1080,7 +1084,7 @@ head = kt->pfrkt_ip6; s = splsoftnet(); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) PF_ASSERT(MA_OWNED); #endif if (KENTRY_NETWORK(ke)) { @@ -1107,18 +1111,18 @@ head = kt->pfrkt_ip6; s = splsoftnet(); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) PF_ASSERT(MA_OWNED); #endif if (KENTRY_NETWORK(ke)) { pfr_prepare_network(&mask, ke->pfrke_af, ke->pfrke_net); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rn = rn_delete(&ke->pfrke_sa, &mask, head); #else rn = rn_delete(&ke->pfrke_sa, &mask, head, NULL); #endif } else -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) rn = rn_delete(&ke->pfrke_sa, NULL, head); #else rn = rn_delete(&ke->pfrke_sa, NULL, head, NULL); @@ -2044,7 +2048,7 @@ pfr_clean_node_mask(kt, &addrq); pfr_destroy_kentries(&addrq); } -#if defined(__FreeBSD__) && (__FreeBSD_version >= 500100) +#if defined(__MidnightBSD__) || (defined(__FreeBSD__) && (__FreeBSD_version >= 500100)) if (kt->pfrkt_ip4 != NULL) { RADIX_NODE_HEAD_DESTROY(kt->pfrkt_ip4); free((caddr_t)kt->pfrkt_ip4, M_RTABLE); @@ -2309,7 +2313,7 @@ switch (af) { #ifdef INET case AF_INET: -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); @@ -2318,7 +2322,7 @@ #endif /* INET */ #ifdef INET6 case AF_INET6: -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip6, pfr_walktree, &w); @@ -2344,13 +2348,13 @@ dyn->pfid_acnt4 = 0; dyn->pfid_acnt6 = 0; if (!dyn->pfid_af || dyn->pfid_af == AF_INET) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip4->rnh_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip4, pfr_walktree, &w); #endif if (!dyn->pfid_af || dyn->pfid_af == AF_INET6) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) kt->pfrkt_ip6->rnh_walktree(kt->pfrkt_ip6, pfr_walktree, &w); #else rn_walktree(kt->pfrkt_ip6, pfr_walktree, &w); From laffer1 at midnightbsd.org Thu Jan 15 23:43:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:43:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: pf_osfp.c: midnightbsdize Message-ID: <200901160443.n0G4htet097284@stargazer.midnightbsd.org> Log Message: ----------- midnightbsdize Modified Files: -------------- src/sys/contrib/pf/net: pf_osfp.c (r1.2 -> r1.3) -------------- next part -------------- Index: pf_osfp.c =================================================================== RCS file: /home/cvs/src/sys/contrib/pf/net/pf_osfp.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/contrib/pf/net/pf_osfp.c -L sys/contrib/pf/net/pf_osfp.c -u -r1.2 -r1.3 --- sys/contrib/pf/net/pf_osfp.c +++ sys/contrib/pf/net/pf_osfp.c @@ -17,7 +17,7 @@ * */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #include __FBSDID("$FreeBSD: src/sys/contrib/pf/net/pf_osfp.c,v 1.6 2007/07/03 12:16:07 mlaier Exp $"); #endif @@ -46,7 +46,7 @@ # define DPFPRINTF(format, x...) \ if (pf_status.debug >= PF_DEBUG_NOISY) \ printf(format , ##x) -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) typedef uma_zone_t pool_t; #else typedef struct pool pool_t; @@ -66,7 +66,7 @@ # define pool_put(pool, item) free(item) # define pool_init(pool, size, a, ao, f, m, p) (*(pool)) = (size) -# ifdef __FreeBSD__ +# if defined(__FreeBSD__) || defined(__MidnightBSD__) # define NTOHS(x) (x) = ntohs((u_int16_t)(x)) # endif @@ -301,14 +301,14 @@ } /* Initialize the OS fingerprint system */ -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) int #else void #endif pf_osfp_initialize(void) { -#if defined(__FreeBSD__) && defined(_KERNEL) +#if (defined(__MidnightBSD__) || defined(__FreeBSD__)) && defined(_KERNEL) int error = ENOMEM; do { @@ -324,7 +324,7 @@ "pfosfp", &pool_allocator_nointr); #endif SLIST_INIT(&pf_osfp_list); -#ifdef __FreeBSD__ +#if defined(__FreeBSD__) || defined(__MidnightBSD__) #ifdef _KERNEL return (error); #else @@ -333,7 +333,7 @@ #endif } -#if defined(__FreeBSD__) && (_KERNEL) +#if (defined(__MidnightBSD__) || defined(__FreeBSD__)) && (_KERNEL) void pf_osfp_cleanup(void) { From laffer1 at midnightbsd.org Thu Jan 15 23:49:24 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 15 Jan 2009 23:49:24 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Update for newer pf Message-ID: <200901160449.n0G4nOfm097867@stargazer.midnightbsd.org> Log Message: ----------- Update for newer pf Modified Files: -------------- src/sys/modules/pf: Makefile (r1.2 -> r1.3) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/pf/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/modules/pf/Makefile -L sys/modules/pf/Makefile -u -r1.2 -r1.3 --- sys/modules/pf/Makefile +++ sys/modules/pf/Makefile @@ -1,12 +1,16 @@ -# $FreeBSD: src/sys/modules/pf/Makefile,v 1.7.2.2 2006/03/22 15:56:32 yar Exp $ +# $MidnightBSD$ +# $FreeBSD: src/sys/modules/pf/Makefile,v 1.13 2007/07/03 12:46:06 mlaier Exp $ + +.include .PATH: ${.CURDIR}/../../contrib/pf/net .PATH: ${.CURDIR}/../../contrib/pf/netinet KMOD= pf SRCS = pf.c pf_if.c pf_subr.c pf_osfp.c pf_ioctl.c pf_norm.c pf_table.c \ + pf_ruleset.c \ in4_cksum.c \ - opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h + opt_pf.h opt_inet.h opt_inet6.h opt_bpf.h opt_mac.h CFLAGS+= -I${.CURDIR}/../../contrib/pf @@ -14,13 +18,18 @@ opt_inet.h: echo "#define INET 1" > opt_inet.h -.if !defined(NO_INET6) +.if ${MK_INET6_SUPPORT} != "no" opt_inet6.h: echo "#define INET6 1" > opt_inet6.h .endif opt_bpf.h: echo "#define DEV_BPF 1" > opt_bpf.h + +# pflog can be loaded as a module, have the additional checks turned on +opt_pf.h: + echo "#define DEV_PF 1" > opt_pf.h + echo "#define DEF_PFLOG 1" >> opt_pf.h .endif .include From laffer1 at midnightbsd.org Fri Jan 16 21:49:13 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Fri, 16 Jan 2009 21:49:13 -0500 (EST) Subject: [Midnightbsd-cvs] src: make.conf: Document mport maintainer mode. Message-ID: <200901170249.n0H2nDmB027971@stargazer.midnightbsd.org> Log Message: ----------- Document mport maintainer mode. Modified Files: -------------- src/share/examples/etc: make.conf (r1.4 -> r1.5) -------------- next part -------------- Index: make.conf =================================================================== RCS file: /home/cvs/src/share/examples/etc/make.conf,v retrieving revision 1.4 retrieving revision 1.5 diff -L share/examples/etc/make.conf -L share/examples/etc/make.conf -u -r1.4 -r1.5 --- share/examples/etc/make.conf +++ share/examples/etc/make.conf @@ -244,6 +244,11 @@ #SUPFILE= /usr/share/examples/cvsup/standard-supfile #PORTSSUPFILE= /usr/share/examples/cvsup/mports-supfile # +# +# mports developers may want to use mport maintainer mode to +# catch problems with plists +#MPORT_MAINTAINER_MODE=yes +# # top(1) uses a hash table for the user names. The size of this hash # can be tuned to match the number of local users. The table size should # be a prime number approximately twice as large as the number of lines in From laffer1 at midnightbsd.org Sat Jan 17 11:25:06 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 11:25:06 -0500 (EST) Subject: [Midnightbsd-cvs] src: network.subr: Emit a warning when the network_interfaces variable Message-ID: <200901171625.n0HGP6j3027336@stargazer.midnightbsd.org> Log Message: ----------- Emit a warning when the network_interfaces variable is not set to AUTO and change wpa_supplicant to down the interface at the start of the init routine. wpa_supplicant expects that it has exclusive access to the net80211 state. This stops errors trying to scan when it's already scanning causing a problem connecting. This was an issue for firmware based cards in particular. Do not bother ifconfig up(ing) the interface since it is downed again Modified Files: -------------- src/etc: network.subr (r1.2 -> r1.3) -------------- next part -------------- Index: network.subr =================================================================== RCS file: /home/cvs/src/etc/network.subr,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/network.subr -L etc/network.subr -u -r1.2 -r1.3 --- etc/network.subr +++ etc/network.subr @@ -23,7 +23,7 @@ # SUCH DAMAGE. # # $MidnightBSD$ -# $FreeBSD: src/etc/network.subr,v 1.164.2.2 2005/12/10 02:20:13 brooks Exp $ +# $FreeBSD: src/etc/network.subr,v 1.180.2.1 2007/11/08 05:52:23 thompsa Exp $ # # @@ -45,14 +45,11 @@ ifconfig_args=`ifconfig_getargs $1` if [ -n "${ifconfig_args}" ]; then ifconfig $1 up - eval "ifconfig $1 ${ifconfig_args}" + ifconfig $1 ${ifconfig_args} _cfg=0 fi if wpaif $1; then - if [ $_cfg -ne 0 ] ; then - ifconfig $1 up - fi /etc/rc.d/wpa_supplicant start $1 _cfg=0 # XXX: not sure this should count fi @@ -61,7 +58,9 @@ if [ $_cfg -ne 0 ] ; then ifconfig $1 up fi - /etc/rc.d/dhclient start $1 + if syncdhcpif $1; then + /etc/rc.d/dhclient start $1 + fi _cfg=0 fi @@ -69,33 +68,14 @@ } # ifconfig_down if -# Remove all inet entries from the $if interface. It returns -# 0 if inet entries were found and removed. It returns 1 if -# no entries were found or they could not be removed. +# returns 1 if wpa_supplicant or dhclient was stopped or +# the interface exists. # ifconfig_down() { [ -z "$1" ] && return 1 - _ifs="^" _cfg=1 - inetList="`ifconfig $1 | grep 'inet ' | tr "\n" "$_ifs"`" - - oldifs="$IFS" - IFS="$_ifs" - for _inet in $inetList ; do - # get rid of extraneous line - [ -z "$_inet" ] && break - - _inet=`expr "$_inet" : '.*\(inet \([0-9]\{1,3\}\.\)\{3\}[0-9]\{1,3\}\).*'` - - IFS="$oldifs" - ifconfig $1 ${_inet} delete - IFS="$_ifs" - _cfg=0 - done - IFS="$oldifs" - if wpaif $1; then /etc/rc.d/wpa_supplicant stop $1 _cfg=0 @@ -106,9 +86,39 @@ _cfg=0 fi + if ifexists $1; then + ifconfig $1 down + _cfg=0 + fi + return $_cfg } +# get_if_var if var [default] +# Return the value of the pseudo-hash corresponding to $if where +# $var is a string containg the sub-string "IF" which will be +# replaced with $if after the characters defined in _punct are +# replaced with '_'. If the variable is unset, replace it with +# $default if given. +get_if_var() +{ + if [ $# -ne 2 -a $# -ne 3 ]; then + err 3 'USAGE: get_if_var name var [default]' + fi + + _if=$1 + _punct=". - / +" + for _punct_c in $_punct; do + _if=`ltr ${_if} ${_punct_c} '_'` + done + _var=$2 + _default=$3 + + prefix=${_var%%IF*} + suffix=${_var##*IF} + eval echo \${${prefix}${_if}${suffix}-${_default}} +} + # _ifconfig_getargs if # Echos the arguments for the supplied interface to stdout. # returns 1 if empty. In general, ifconfig_getargs should be used @@ -120,9 +130,7 @@ return 1 fi - eval _args=\${ifconfig_$1-$ifconfig_DEFAULT} - - echo "$_args" + get_if_var $_ifn ifconfig_IF "$ifconfig_DEFAULT" } # ifconfig_getargs if @@ -138,12 +146,11 @@ for _arg in $_tmpargs; do case $_arg in - [Dd][Hh][Cc][Pp]) - ;; - [Nn][Oo][Aa][Uu][Tt][Oo]) - ;; - [Ww][Pp][Aa]) - ;; + [Dd][Hh][Cc][Pp]) ;; + [Nn][Oo][Aa][Uu][Tt][Oo]) ;; + [Nn][Oo][Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) ;; + [Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) ;; + [Ww][Pp][Aa]) ;; *) _args="$_args $_arg" ;; @@ -179,11 +186,40 @@ [Dd][Hh][Cc][Pp]) return 0 ;; + [Nn][Oo][Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 0 + ;; + [Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 0 + ;; esac done return 1 } +# syncdhcpif +# Returns 0 if the interface should be configured synchronously and +# 1 otherwise. +syncdhcpif() +{ + _tmpargs=`_ifconfig_getargs $1` + for _arg in $_tmpargs; do + case $_arg in + [Nn][Oo][Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 1 + ;; + [Ss][Yy][Nn][Cc][Dd][Hh][Cc][Pp]) + return 0 + ;; + esac + done + if checkyesno synchronous_dhclient; then + return 0 + else + return 1 + fi +} + # wpaif if # Returns 0 if the interface is a WPA interface and 1 otherwise. wpaif() @@ -199,6 +235,37 @@ return 1 } +# ipv6if if +# Returns 0 if the interface should be configured for IPv6 and +# 1 otherwise. +ipv6if() +{ + if ! checkyesno ipv6_enable; then + return 1 + fi + case "${ipv6_network_interfaces}" in + [Aa][Uu][Tt][Oo]) + return 0 + ;; + ''|[Nn][Oo][Nn][Ee]) + return 1 + ;; + esac + for v6if in ${ipv6_network_interfaces}; do + if [ "${v6if}" = "${1}" ]; then + return 0 + fi + done + return 1 +} + +# ifexists if +# Returns 0 if the interface exists and 1 otherwise. +ifexists() +{ + ifconfig -n $1 > /dev/null 2>&1 +} + # ipv4_up if # add IPv4 addresses to the interface $if ipv4_up() @@ -213,8 +280,32 @@ ipv4_down() { _if=$1 - ifalias_down ${_if} - ipv4_addrs_common ${_if} -alias + _ifs="^" + _ret=1 + + ifexists ${_if} || return 1 + + inetList="`ifconfig ${_if} | grep 'inet ' | tr "\n" "$_ifs"`" + + oldifs="$IFS" + IFS="$_ifs" + for _inet in $inetList ; do + # get rid of extraneous line + [ -z "$_inet" ] && break + + _inet=`expr "$_inet" : '.*\(inet \([0-9]\{1,3\}\.\)\{3\}[0-9]\{1,3\}\).*'` + + IFS="$oldifs" + ifconfig ${_if} ${_inet} delete + IFS="$_ifs" + _ret=0 + done + IFS="$oldifs" + + ifalias_down ${_if} && _ret=0 + ipv4_addrs_common ${_if} -alias && _ret=0 + + return $_ret } # ipv4_addrs_common if action @@ -227,7 +318,7 @@ _action=$2 # get ipv4-addresses - eval cidr_addr=\${ipv4_addrs_${_if}} + cidr_addr=`get_if_var $_if ipv4_addrs_IF` for _cidr in ${cidr_addr}; do _ipaddr=${_cidr%%/*} @@ -267,7 +358,7 @@ _ret=1 alias=0 while : ; do - eval ifconfig_args=\$ifconfig_$1_alias${alias} + ifconfig_args=`get_if_var $1 ifconfig_IF_alias${alias}` if [ -n "${ifconfig_args}" ]; then ifconfig $1 ${ifconfig_args} alias alias=$((${alias} + 1)) @@ -289,7 +380,7 @@ _ret=1 alias=0 while : ; do - eval ifconfig_args=\$ifconfig_$1_alias${alias} + ifconfig_args=`get_if_var $1 ifconfig_IF_alias${alias}` if [ -n "${ifconfig_args}" ]; then ifconfig $1 ${ifconfig_args} -alias alias=$((${alias} + 1)) @@ -362,26 +453,89 @@ debug "Destroyed clones: ${_list}" } +# Create netgraph nodes. +# +ng_mkpeer() { + ngctl -f - 2> /dev/null </dev/null 2>&1 + ifconfig $i tunnel ${peers} + ifconfig $i up + ;; + esac + done +} + +# ng_fec_create ifn +# Configure Fast EtherChannel for interface $ifn. Returns 0 if FEC +# arguments were found and configured; returns !0 otherwise. +ng_fec_create() { + local req_iface iface bogus + req_iface="$1" + + ngctl shutdown ${req_iface}: > /dev/null 2>&1 + + bogus="" + while true; do + iface=`ng_create_one fec dummy fec` + if [ -z "${iface}" ]; then + exit 2 + fi + if [ "${iface}" = "${req_iface}" ]; then + break + fi + bogus="${bogus} ${iface}" + done + + for iface in ${bogus}; do + ngctl shutdown ${iface}: + done +} + +fec_up() { + for i in ${fec_interfaces}; do + ng_fec_create $i + for j in `get_if_var $i fecconfig_IF`; do + case ${j} in '') continue ;; *) - ifconfig $i create >/dev/null 2>&1 - ifconfig $i tunnel ${peers} - ifconfig $i up + ngctl msg ${i}: add_iface "\"${j}\"" ;; esac done - ;; - esac + done } # @@ -392,7 +546,7 @@ ipx_up() { ifn="$1" - eval ifconfig_args=\$ifconfig_${ifn}_ipx + ifconfig_args=`get_if_var $ifn ifconfig_IF_ipx` if [ -n "${ifconfig_args}" ]; then ifconfig ${ifn} ${ifconfig_args} return 0 @@ -410,6 +564,8 @@ _ifs="^" _ret=1 + ifexists $1 || return 1 + ipxList="`ifconfig $1 | grep 'ipx ' | tr "\n" "$_ifs"`" oldifs="$IFS" @@ -439,7 +595,7 @@ _ifn_list="`ifconfig -l`" [ -z "$_ifn_list" ] && return 0 for _if in ${_ifn_list} ; do - eval _ifname=\$ifconfig_${_if}_name + _ifname=`get_if_var $_if ifconfig_IF_name` if [ ! -z "$_ifname" ]; then ifconfig $_if name $_ifname fi @@ -483,6 +639,10 @@ _tmplist="${_lo}${_tmplist}" ;; *) + if [ -z "$type" ]; then + warn "Values of network_interfaces other than"\ + "AUTO are deprecated" + fi _tmplist="${network_interfaces} ${cloned_interfaces}" ;; esac @@ -500,7 +660,7 @@ if dhcpif $_if; then _dhcplist="${_dhcplist}${_aprefix}${_if}" [ -z "$_aprefix" ] && _aprefix=' ' - elif [ -n "`_ifconfig_getargs $if`" ]; then + elif [ -n "`_ifconfig_getargs $_if`" ]; then _nodhcplist="${_nodhcplist}${_bprefix}${_if}" [ -z "$_bprefix" ] && _bprefix=' ' fi @@ -565,7 +725,7 @@ esac for i in $interfaces; do rtsol_interface=yes - eval prefix=\$ipv6_prefix_$i + prefix=`get_if_var $i ipv6_prefix_IF` if [ -n "${prefix}" ]; then rtsol_available=no rtsol_interface=no @@ -585,7 +745,7 @@ esac done fi - eval ipv6_ifconfig=\$ipv6_ifconfig_$i + ipv6_ifconfig=`get_if_var $i ipv6_ifconfig_IF` if [ -n "${ipv6_ifconfig}" ]; then rtsol_available=no rtsol_interface=no @@ -595,7 +755,7 @@ if [ ${rtsol_available} = yes -a ${rtsol_interface} = yes ] then case ${i} in - lo0|gif[0-9]*|stf[0-9]*|faith[0-9]*|lp[0-9]*|sl[0-9]*|tun[0-9]*) + lo0|gif[0-9]*|stf[0-9]*|faith[0-9]*|lp[0-9]*|sl[0-9]*|tun[0-9]*|pflog[0-9]*|pfsync[0-9]*) ;; *) rtsol_interfaces="${rtsol_interfaces} ${i}" @@ -620,7 +780,7 @@ for i in $interfaces; do alias=0 while : ; do - eval ipv6_ifconfig=\$ipv6_ifconfig_${i}_alias${alias} + ipv6_ifconfig=`get_if_var $i ipv6_ifconfig_IF_alias${alias}` if [ -z "${ipv6_ifconfig}" ]; then break; fi @@ -696,7 +856,7 @@ ;; *) for i in ${ipv6_static_routes}; do - eval ipv6_route_args=\$ipv6_route_${i} + ipv6_route_args=`get_if_var $i ipv6_route_IF` route add -inet6 ${ipv6_route_args} done ;; From laffer1 at midnightbsd.org Sat Jan 17 11:31:35 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 11:31:35 -0500 (EST) Subject: [Midnightbsd-cvs] src: src/etc: Remove pccard Message-ID: <200901171631.n0HGVZNv028010@stargazer.midnightbsd.org> Log Message: ----------- Remove pccard Modified Files: -------------- src/etc: netstart (r1.2 -> r1.3) src/etc/rc.d: Makefile (r1.10 -> r1.11) netif (r1.3 -> r1.4) Removed Files: ------------- src/etc/rc.d: pccard -------------- next part -------------- Index: netstart =================================================================== RCS file: /home/cvs/src/etc/netstart,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/netstart -L etc/netstart -u -r1.2 -r1.3 --- etc/netstart +++ etc/netstart @@ -38,7 +38,6 @@ . /etc/rc.subr load_rc_config 'XXX' -/etc/rc.d/pccard start /etc/rc.d/devd start /etc/rc.d/hostname start /etc/rc.d/ipmon start --- etc/rc.d/pccard +++ /dev/null @@ -1,71 +0,0 @@ -#!/bin/sh -# -# Copyright (c) 1996 The FreeBSD Project -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/etc/rc.d/pccard,v 1.30 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD: src/etc/rc.d/pccard,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: pccard -# REQUIRE: mountcritlocal -# KEYWORD: nojail - -. /etc/rc.subr - -name="pccard" -start_cmd="pccard_start" -stop_cmd=":" - -pccard_start() -{ - if [ ! -c /dev/card0 ]; then - exit 0 - fi - if checkyesno pccard_enable; then - echo -n 'Setup PC-CARD:' - - case ${pccard_mem} in - [Dd][Ee][Ff][Aa][Uu][Ll][Tt]) - pccardc pccardmem 0xd0000 1>/dev/null && echo -n ' memory' - ;; - *) - pccardc pccardmem ${pccard_mem} 1>/dev/null && echo -n ' memory' - ;; - esac - - if [ -n "${pccard_beep}" ]; then - pccardc beep ${pccard_beep} && echo -n ' beep' - fi - - if [ -n "${pccard_conf}" ]; then - pccardd_flags="${pccardd_flags} -f ${pccard_conf}" - fi - - pccardd ${pccardd_flags} && echo -n ' pccardd' - echo '.' - fi -} - -load_rc_config $name -run_rc_command "$1" Index: netif =================================================================== RCS file: /home/cvs/src/etc/rc.d/netif,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/netif -L etc/rc.d/netif -u -r1.3 -r1.4 --- etc/rc.d/netif +++ etc/rc.d/netif @@ -26,7 +26,7 @@ # $MidnightBSD$ # PROVIDE: netif -# REQUIRE: atm1 cleanvar ipfilter FILESYSTEMS pccard serial sppp sysctl +# REQUIRE: atm1 cleanvar ipfilter FILESYSTEMS serial sppp sysctl # KEYWORD: nojail . /etc/rc.subr Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.10 retrieving revision 1.11 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.10 -r1.11 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -27,7 +27,7 @@ network_ipv6 newsyslog nfsclient nfsd \ nfslocking nfsserver nisdomain nsswitch ntpd \ othermta \ - pccard pf pflog pfsync \ + pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ quota \ ramdisk ramdisk-own random rarpd rdate resolv root \ From laffer1 at midnightbsd.org Sat Jan 17 11:40:42 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 11:40:42 -0500 (EST) Subject: [Midnightbsd-cvs] src: netoptions: Add several new friendly net options. Message-ID: <200901171640.n0HGegk6029041@stargazer.midnightbsd.org> Log Message: ----------- Add several new friendly net options. Modified Files: -------------- src/etc/rc.d: netoptions (r1.3 -> r1.4) -------------- next part -------------- Index: netoptions =================================================================== RCS file: /home/cvs/src/etc/rc.d/netoptions,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/netoptions -L etc/rc.d/netoptions -u -r1.3 -r1.4 --- etc/rc.d/netoptions +++ etc/rc.d/netoptions @@ -5,14 +5,13 @@ # PROVIDE: netoptions # REQUIRE: FILESYSTEMS -# BEFORE: securelevel # KEYWORD: nojail . /etc/rc.subr load_rc_config 'XXX' -echo -n 'Additional TCP options:' +echo -n 'Additional IP options:' case ${log_in_vain} in [Nn][Oo] | '') log_in_vain=0 @@ -33,4 +32,46 @@ sysctl net.inet.tcp.log_in_vain="${log_in_vain}" >/dev/null sysctl net.inet.udp.log_in_vain="${log_in_vain}" >/dev/null ) + +case ${tcp_extensions} in +[Yy][Ee][Ss] | '') + ;; +*) + echo -n ' tcp extensions=NO' + sysctl net.inet.tcp.rfc1323=0 >/dev/null + ;; +esac + +case ${tcp_keepalive} in +[Nn][Oo]) + echo -n ' TCP keepalive=NO' + sysctl net.inet.tcp.always_keepalive=0 >/dev/null + ;; +esac + +case ${tcp_drop_synfin} in +[Yy][Ee][Ss]) + echo -n ' drop SYN+FIN packets=YES' + sysctl net.inet.tcp.drop_synfin=1 >/dev/null + ;; +esac + +case ${ip_portrange_first} in +[Nn][Oo] | '') + ;; +*) + echo -n " ip_portrange_first=$ip_portrange_first" + sysctl net.inet.ip.portrange.first=$ip_portrange_first >/dev/null + ;; +esac + +case ${ip_portrange_last} in +[Nn][Oo] | '') + ;; +*) + echo -n " ip_portrange_last=$ip_portrange_last" + sysctl net.inet.ip.portrange.last=$ip_portrange_last >/dev/null + ;; +esac + echo '.' From laffer1 at midnightbsd.org Sat Jan 17 12:16:42 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:16:42 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: change the name of pidfile not to conflict Message-ID: <200901171716.n0HHGgJ0032541@stargazer.midnightbsd.org> Log Message: ----------- change the name of pidfile not to conflict Modified Files: -------------- src/etc/rc.d: netif (r1.4 -> r1.5) wpa_supplicant (r1.3 -> r1.4) -------------- next part -------------- Index: wpa_supplicant =================================================================== RCS file: /home/cvs/src/etc/rc.d/wpa_supplicant,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/wpa_supplicant -L etc/rc.d/wpa_supplicant -u -r1.3 -r1.4 --- etc/rc.d/wpa_supplicant +++ etc/rc.d/wpa_supplicant @@ -32,8 +32,8 @@ load_rc_config $name -pidfile="/var/run/${name}/${ifn}.pid" -command_args="-B -q -i $ifn -c $conf_file -D $driver -P $pidfile" +pid_file="/var/run/${name}/${ifn}.pid" +command_args="-B -q -i $ifn -c $conf_file -D $driver -P $pid_file" required_files=$conf_file run_rc_command "$1" Index: netif =================================================================== RCS file: /home/cvs/src/etc/rc.d/netif,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/netif -L etc/rc.d/netif -u -r1.4 -r1.5 --- etc/rc.d/netif +++ etc/rc.d/netif @@ -38,15 +38,15 @@ cloneup_cmd="clone_up" clonedown_cmd="clone_down" extra_commands="cloneup clonedown" -_cmdifn= +cmdifn= network_start() { # Set the list of interfaces to work on. # - _cmdifn=$* + cmdifn=$* - if [ -z "$_cmdifn" ]; then + if [ -z "$cmdifn" ]; then # # We're operating as a general network start routine. # @@ -57,6 +57,9 @@ # Create cloned interfaces clone_up + # Create Fast EtherChannel interfaces + fec_up + # Create IPv6<-->IPv4 tunnels gif_up @@ -71,13 +74,16 @@ # Resync ipfilter /etc/rc.d/ipfilter resync fi + if [ -f /etc/rc.d/bridge -a -n "$cmdifn" ] ; then + /etc/rc.d/bridge start $cmdifn + fi } network_stop() { # Set the list of interfaces to work on. # - _cmdifn=$* + cmdifn=$* echo -n "Stopping network:" @@ -95,6 +101,8 @@ # configured interface(s). network_common() { + local _cooked_list _fail _func _verbose + _func= _verbose= @@ -108,15 +116,16 @@ # Set the scope of the command (all interfaces or just one). # _cooked_list= - if [ -n "$_cmdifn" ]; then + if [ -n "$cmdifn" ]; then # Don't check that the interfaces exist. We need to run # the down code even when the interface doesn't exist to # kill off wpa_supplicant. - _cooked_list="$_cmdifn" + _cooked_list="$cmdifn" else _cooked_list="`list_net_interfaces`" fi + _fail= for ifn in ${_cooked_list}; do if ${_func} ${ifn} ; then eval showstat_$ifn=1 From laffer1 at midnightbsd.org Sat Jan 17 12:20:22 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:20:22 -0500 (EST) Subject: [Midnightbsd-cvs] src: routing: Remove some of these options as they were moved to Message-ID: <200901171720.n0HHKMDf032955@stargazer.midnightbsd.org> Log Message: ----------- Remove some of these options as they were moved to netoptions Modified Files: -------------- src/etc/rc.d: routing (r1.2 -> r1.3) -------------- next part -------------- Index: routing =================================================================== RCS file: /home/cvs/src/etc/rc.d/routing,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/routing -L etc/rc.d/routing -u -r1.2 -r1.3 --- etc/rc.d/routing +++ etc/rc.d/routing @@ -3,7 +3,7 @@ # Configure routing and miscellaneous network tunables # # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/routing,v 1.141.2.1 2006/01/21 22:42:43 yar Exp $ +# $FreeBSD: src/etc/rc.d/routing,v 1.143 2007/05/02 15:49:30 mtm Exp $ # # PROVIDE: routing @@ -62,15 +62,6 @@ options_start() { echo -n 'Additional routing options:' - case ${tcp_extensions} in - [Yy][Ee][Ss] | '') - ;; - *) - echo -n ' tcp extensions=NO' - sysctl net.inet.tcp.rfc1323=0 >/dev/null - ;; - esac - case ${icmp_bmcastecho} in [Yy][Ee][Ss]) echo -n ' broadcast ping responses=YES' @@ -113,20 +104,6 @@ ;; esac - case ${tcp_keepalive} in - [Nn][Oo]) - echo -n ' TCP keepalive=NO' - sysctl net.inet.tcp.always_keepalive=0 >/dev/null - ;; - esac - - case ${tcp_drop_synfin} in - [Yy][Ee][Ss]) - echo -n ' drop SYN+FIN packets=YES' - sysctl net.inet.tcp.drop_synfin=1 >/dev/null - ;; - esac - case ${ipxgateway_enable} in [Yy][Ee][Ss]) echo -n ' IPX gateway=YES' @@ -141,24 +118,6 @@ ;; esac - case ${ip_portrange_first} in - [Nn][Oo] | '') - ;; - *) - echo -n " ip_portrange_first=$ip_portrange_first" - sysctl net.inet.ip.portrange.first=$ip_portrange_first >/dev/null - ;; - esac - - case ${ip_portrange_last} in - [Nn][Oo] | '') - ;; - *) - echo -n " ip_portrange_last=$ip_portrange_last" - sysctl net.inet.ip.portrange.last=$ip_portrange_last >/dev/null - ;; - esac - echo '.' } From laffer1 at midnightbsd.org Sat Jan 17 12:21:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:21:48 -0500 (EST) Subject: [Midnightbsd-cvs] src: pppoed: Make local Message-ID: <200901171721.n0HHLmEO033025@stargazer.midnightbsd.org> Log Message: ----------- Make local Modified Files: -------------- src/etc/rc.d: pppoed (r1.2 -> r1.3) -------------- next part -------------- Index: pppoed =================================================================== RCS file: /home/cvs/src/etc/rc.d/pppoed,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/pppoed -L etc/rc.d/pppoed -u -r1.2 -r1.3 --- etc/rc.d/pppoed +++ etc/rc.d/pppoed @@ -18,6 +18,7 @@ pppoed_start() { + local _opts if [ -n "${pppoed_provider}" ]; then pppoed_flags="${pppoed_flags} -p ${pppoed_provider}" fi From laffer1 at midnightbsd.org Sat Jan 17 12:24:51 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:24:51 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: Whack ppp-user... Message-ID: <200901171724.n0HHOpDC033141@stargazer.midnightbsd.org> Log Message: ----------- Whack ppp-user... merge and cleanup ppp Modified Files: -------------- src/etc/rc.d: ppp (r1.2 -> r1.3) Removed Files: ------------- src/etc/rc.d: ppp-user -------------- next part -------------- --- etc/rc.d/ppp-user +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -# -# $FreeBSD: src/etc/rc.d/ppp-user,v 1.7 2004/12/15 12:39:28 brian Exp $ -# $MidnightBSD: src/etc/rc.d/ppp-user,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: ppp-user -# REQUIRE: netif isdnd -# KEYWORD: nojail - -. /etc/rc.subr - -name="ppp" -rcvar=`set_rcvar` -start_precmd="ppp_precmd" -start_postcmd="ppp_postcmd" - -ppp_precmd() -{ - # Establish ppp mode. - # - if [ "${ppp_mode}" != "ddial" -a "${ppp_mode}" != "direct" \ - -a "${ppp_mode}" != "dedicated" \ - -a "${ppp_mode}" != "background" ]; then - ppp_mode="auto" - fi - - rc_flags="$rc_flags -quiet -${ppp_mode}" - - # Switch on NAT mode? - # - case ${ppp_nat} in - [Yy][Ee][Ss]) - rc_flags="$rc_flags -nat" - ;; - esac - - rc_flags="$rc_flags ${ppp_profile}" -} - -ppp_postcmd() -{ - # Re-Sync ipfilter so it picks up any new network interfaces - # - /etc/rc.d/ipfilter resync -} - -load_rc_config $name -run_rc_command "$1" Index: ppp =================================================================== RCS file: /home/cvs/src/etc/rc.d/ppp,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/ppp -L etc/rc.d/ppp -u -r1.2 -r1.3 --- etc/rc.d/ppp +++ etc/rc.d/ppp @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ppp,v 1.11.2.1 2006/01/21 22:42:43 yar Exp $ +# $FreeBSD: src/etc/rc.d/ppp,v 1.13.2.1 2007/10/31 16:42:41 emax Exp $ # $MidnightBSD$ # PROVIDE: ppp @@ -12,38 +12,106 @@ name="ppp" rcvar=`set_rcvar` command="/usr/sbin/${name}" -start_precmd="ppp_precmd" -start_postcmd="ppp_postcmd" +start_cmd="ppp_start" +stop_cmd="ppp_stop" +start_postcmd="ppp_poststart" -ppp_precmd() +ppp_start_profile() { + local _ppp_profile _ppp_mode _ppp_nat + + _ppp_profile=$1 + + # Check for ppp profile mode override. + # + eval _ppp_mode=\$ppp_${_ppp_profile}_mode + if [ -z "$_ppp_mode" ]; then + _ppp_mode=$ppp_mode + fi + + # Check for ppp profile nat override. + # + eval _ppp_nat=\$ppp_${_ppp_profile}_nat + if [ -z "$_ppp_nat" ]; then + _ppp_nat=$ppp_nat + fi + # Establish ppp mode. # - if [ "${ppp_mode}" != "ddial" -a "${ppp_mode}" != "direct" \ - -a "${ppp_mode}" != "dedicated" \ - -a "${ppp_mode}" != "background" ]; then - ppp_mode="auto" + if [ "${_ppp_mode}" != "ddial" -a "${_ppp_mode}" != "direct" \ + -a "${_ppp_mode}" != "dedicated" \ + -a "${_ppp_mode}" != "background" ]; then + _ppp_mode="auto" fi - rc_flags="$rc_flags -quiet -${ppp_mode}" + rc_flags="-quiet -${_ppp_mode}" # Switch on NAT mode? # - case ${ppp_nat} in + case ${_ppp_nat} in [Yy][Ee][Ss]) rc_flags="$rc_flags -nat" ;; esac - rc_flags="$rc_flags ${ppp_profile}" + # Run! + # + su -m $ppp_user -c "$command ${rc_flags} ${_ppp_profile}" +} + +ppp_start() +{ + local _ppp_profile _p + + _ppp_profile=$* + if [ -z "${_ppp_profile}" ]; then + _ppp_profile=$ppp_profile + fi + + echo -n "Starting PPP profile:" + + for _p in $_ppp_profile; do + echo -n " $_p" + ppp_start_profile $_p + done + + echo "." } -ppp_postcmd() +ppp_poststart() { - # Re-Sync ipfilter so it picks up any new network interfaces + # Re-Sync ipfilter and pf so they pick up any new network interfaces # /etc/rc.d/ipfilter resync + /etc/rc.d/pf resync +} + +ppp_stop_profile() { + local _ppp_profile + + _ppp_profile=$1 + + /bin/pkill -f "^${command}.*[[:space:]]${_ppp_profile}\$" || \ + echo -n "(not running)" +} + +ppp_stop() { + local _ppp_profile _p + + _ppp_profile=$* + if [ -z "${_ppp_profile}" ]; then + _ppp_profile=$ppp_profile + fi + + echo -n "Stopping PPP profile:" + + for _p in $_ppp_profile; do + echo -n " $_p" + ppp_stop_profile $_p + done + + echo "." } load_rc_config $name -run_rc_command "$1" +run_rc_command $* From laffer1 at midnightbsd.org Sat Jan 17 12:30:25 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:30:25 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add idmapd Message-ID: <200901171730.n0HHUPhT033873@stargazer.midnightbsd.org> Log Message: ----------- add idmapd Modified Files: -------------- src/etc/rc.d: Makefile (r1.11 -> r1.12) pf (r1.3 -> r1.4) pflog (r1.4 -> r1.5) pfsync (r1.3 -> r1.4) Added Files: ----------- src/etc/rc.d: hostid (r1.1) -------------- next part -------------- Index: pfsync =================================================================== RCS file: /home/cvs/src/etc/rc.d/pfsync,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/pfsync -L etc/rc.d/pfsync -u -r1.3 -r1.4 --- etc/rc.d/pfsync +++ etc/rc.d/pfsync @@ -1,7 +1,7 @@ #!/bin/sh # # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/pfsync,v 1.1.2.1 2005/10/08 03:32:54 yar Exp $ +# $FreeBSD: src/etc/rc.d/pfsync,v 1.5 2007/04/10 16:42:13 keramida Exp $ # # PROVIDE: pfsync @@ -15,33 +15,35 @@ start_precmd="pfsync_prestart" start_cmd="pfsync_start" stop_cmd="pfsync_stop" +required_modules="pf" pfsync_prestart() { + # XXX Currently pfsync cannot be a module as it must register + # a network protocol in a static kernel table. + if ! kldstat -q -m pfsync; then + warn "pfsync(4) must be statically compiled in the kernel." + return 1 + fi + case "$pfsync_syncdev" in '') warn "pfsync_syncdev is not set." return 1 ;; esac - - # load pf kernel module if needed - if ! kldstat -q -m pf ; then - if kldload pf ; then - info "pf module loaded." - else - warn "pf module failed to load." - return 1 - fi - fi - return 0 } pfsync_start() { + local _syncpeer + echo "Enabling pfsync." - ifconfig pfsync0 syncdev $pfsync_syncdev $pfsync_ifconfig up + if [ -n "${pfsync_syncpeer}" ]; then + _syncpeer="syncpeer ${pfsync_syncpeer}" + fi + ifconfig pfsync0 $_syncpeer syncdev $pfsync_syncdev $pfsync_ifconfig up } pfsync_stop() Index: pf =================================================================== RCS file: /home/cvs/src/etc/rc.d/pf,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/pf -L etc/rc.d/pf -u -r1.3 -r1.4 --- etc/rc.d/pf +++ etc/rc.d/pf @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/pf,v 1.7.2.4 2006/01/22 13:45:28 yar Exp $ +# $FreeBSD: src/etc/rc.d/pf,v 1.16 2007/04/09 08:53:40 des Exp $ # $MidnightBSD$ # PROVIDE: pf @@ -13,7 +13,6 @@ name="pf" rcvar=`set_rcvar` load_rc_config $name -start_precmd="pf_prestart" start_cmd="pf_start" stop_cmd="pf_stop" check_cmd="pf_check" @@ -22,25 +21,12 @@ status_cmd="pf_status" extra_commands="check reload resync status" required_files="$pf_rules" - -pf_prestart() -{ - # load pf kernel module if needed - if ! kldstat -q -m pf ; then - if kldload pf ; then - info 'pf module loaded.' - else - warn 'pf module failed to load.' - return 1 - fi - fi - return 0 -} +required_modules="pf" pf_start() { echo "Enabling pf." - $pf_program -Fall > /dev/null 2>&1 + $pf_program -F all > /dev/null 2>&1 $pf_program -f "$pf_rules" $pf_flags if ! $pf_program -s info | grep -q "Enabled" ; then $pf_program -e Index: pflog =================================================================== RCS file: /home/cvs/src/etc/rc.d/pflog,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/pflog -L etc/rc.d/pflog -u -r1.4 -r1.5 --- etc/rc.d/pflog +++ etc/rc.d/pflog @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/pflog,v 1.5.2.1 2006/01/22 13:40:47 yar Exp $ +# $FreeBSD: src/etc/rc.d/pflog,v 1.12 2007/04/09 08:53:40 des Exp $ # $MidnightBSD$ # PROVIDE: pflog @@ -22,19 +22,11 @@ pflog_prestart() { - # load pflog kernel module if needed - if ! kldstat -q -m pflog; then - if kldload pflog; then - info 'pflog module loaded.' - else - warn 'pflog module failed to load.' - return 1 - fi - fi + load_kld pflog || return 1 # set pflog0 interface to up state if ! ifconfig pflog0 up; then - warn 'could not not bring up pflog0.' + warn 'could not bring up pflog0.' return 1 fi --- /dev/null +++ etc/rc.d/hostid @@ -0,0 +1,98 @@ +#!/bin/sh +# +# Copyright (c) 2007 Pawel Jakub Dawidek +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $MidnightBSD: src/etc/rc.d/hostid,v 1.1 2009/01/17 17:30:24 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/hostid,v 1.7 2007/05/22 13:53:59 rse Exp $ +# + +# PROVIDE: hostid +# REQUIRE: root +# BEFORE: mountcritlocal +# KEYWORD: nojail + +. /etc/rc.subr + +name="hostid" +start_cmd="hostid_start" +stop_cmd=":" +reset_cmd="hostid_reset" +extra_commands="reset" +rcvar="hostid_enable" + +hostid_set() +{ + uuid=$1 + # Generate hostid based on hostuuid - take first four bytes from md5(uuid). + id=`echo -n $uuid | md5` + id="0x${id%????????????????????????}" + # Set both kern.hostuuid and kern.hostid. + echo "Setting hostuuid: ${uuid}." + ${SYSCTL_W} kern.hostuuid="${uuid}" >/dev/null + echo "Setting hostid: ${id}." + ${SYSCTL_W} kern.hostid=${id} >/dev/null +} + +hostid_hardware() +{ + uuid=`kenv smbios.system.uuid 2>/dev/null` + x="[0-9a-f]" + y=$x$x$x$x + case "${uuid}" in + $y$y-$y-$y-$y-$y$y$y) + echo "${uuid}" + ;; + esac +} + +hostid_reset() +{ + # First look for UUID in hardware. + uuid=`hostid_hardware` + if [ -z ${uuid} ]; then + # If not found, fall back to software-generated UUID. + uuid=`uuidgen` + fi + # Store newly generated UUID in ${hostid_file}. + echo $uuid > ${hostid_file} + if [ $? -ne 0 ]; then + warn "could not store hostuuid in ${hostid_file}." + fi + hostid_set $uuid +} + +hostid_start() +{ + # If ${hostid_file} already exists, we take UUID from there. + if [ -r ${hostid_file} ]; then + hostid_set `cat ${hostid_file}` + else + # No hostid file, generate UUID. + hostid_reset + fi +} + +load_rc_config $name +run_rc_command "$1" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.11 retrieving revision 1.12 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.11 -r1.12 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -13,9 +13,9 @@ firstboot fsck ftp-proxy ftpd \ gbde geli geli2 \ hcsecd \ - hostapd hostname \ + hostapd hostid hostname \ ike \ - inetd initrandom \ + idmapd inetd initrandom \ ip6addrctl ip6fw ipfilter ipfs ipfw ipmon \ ipnat ipsec ipxrouted isdnd \ jail \ From laffer1 at midnightbsd.org Sat Jan 17 12:30:42 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:30:42 -0500 (EST) Subject: [Midnightbsd-cvs] src: idmapd: Message-ID: <200901171730.n0HHUg6T033925@stargazer.midnightbsd.org> Log Message: ----------- Added Files: ----------- src/etc/rc.d: idmapd (r1.1) -------------- next part -------------- --- /dev/null +++ etc/rc.d/idmapd @@ -0,0 +1,19 @@ +#!/bin/sh +# +# $MidnightBSD: src/etc/rc.d/idmapd,v 1.1 2009/01/17 17:30:41 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/idmapd,v 1.1 2006/10/15 14:19:06 ceri Exp $ +# + +# PROVIDE: idmapd +# REQUIRE: rpcbind +# KEYWORD: nojail + +. /etc/rc.subr + +name="idmapd" + +load_rc_config $name +rcvar="idmapd_enable" +command="${idmapd:-/sbin/${name}}" +eval ${name}_flags=\"${idmapd_flags}\" +run_rc_command "$1" From laffer1 at midnightbsd.org Sat Jan 17 12:32:59 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:32:59 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add kernel Message-ID: <200901171732.n0HHWxJX034036@stargazer.midnightbsd.org> Log Message: ----------- add kernel Modified Files: -------------- src/etc/rc.d: Makefile (r1.12 -> r1.13) Added Files: ----------- src/etc/rc.d: kernel (r1.1) -------------- next part -------------- --- /dev/null +++ etc/rc.d/kernel @@ -0,0 +1,28 @@ +#!/bin/sh +# +# $MidnightBSD: src/etc/rc.d/kernel,v 1.1 2009/01/17 17:32:59 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/kernel,v 1.2 2006/07/30 12:54:37 mckay Exp $ +# + +# PROVIDE: kernel +# REQUIRE: mountcritremote +# KEYWORD: nojail + +. /etc/rc.subr + +name="kernel" +start_cmd="kernel_start" +stop_cmd=":" + +kernel_start() +{ + bootdir=$(dirname $(sysctl -n kern.bootfile)) + if [ "$bootdir" != /boot/kernel ] ; then + if [ ! -e /boot/kernel -o -h /boot/kernel ] ; then + ln -hfs ${bootdir} /boot/kernel + fi + fi +} + +load_rc_config $name +run_rc_command "$1" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.12 retrieving revision 1.13 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.12 -r1.13 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -19,7 +19,7 @@ ip6addrctl ip6fw ipfilter ipfs ipfw ipmon \ ipnat ipsec ipxrouted isdnd \ jail \ - kadmind kerberos keyserv kldxref kpasswdd \ + kadmind kerberos kernel keyserv kldxref kpasswdd \ ldconfig local localpkg lpd \ mixer motd mountcritlocal mountcritremote \ mountd moused mroute6d mrouted msgs \ From laffer1 at midnightbsd.org Sat Jan 17 12:35:27 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:35:27 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: Rename nfslocking -> lockd Message-ID: <200901171735.n0HHZRAO034420@stargazer.midnightbsd.org> Log Message: ----------- Rename nfslocking -> lockd Modified Files: -------------- src/etc/rc.d: Makefile (r1.13 -> r1.14) Added Files: ----------- src/etc/rc.d: lockd (r1.1) Removed Files: ------------- src/etc/rc.d: nfslocking -------------- next part -------------- --- /dev/null +++ etc/rc.d/lockd @@ -0,0 +1,43 @@ +#!/bin/sh +# +# FreeBSD History: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm +# $FreeBSD: src/etc/rc.d/lockd,v 1.18.6.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD: src/etc/rc.d/lockd,v 1.1 2009/01/17 17:35:26 laffer1 Exp $ + +# PROVIDE: lockd +# REQUIRE: nfsserver nfsclient nfsd rpcbind statd +# BEFORE: DAEMON +# KEYWORD: nojail + +. /etc/rc.subr + +name="lockd" +rcvar=rpc_lockd_enable +command="/usr/sbin/rpc.${name}" +start_precmd='lockd_precmd' +stop_precmd='checkyesno nfs_server_enable || checkyesno nfs_client_enable' +status_precmd=$stop_precmd + +# Make sure that we are either an NFS client or server, and that we get +# the correct flags from rc.conf(5). +# +lockd_precmd() +{ + local ret + ret=0 + + if ! checkyesno nfs_server_enable && ! checkyesno nfs_client_enable + then + ret=1 + fi + if ! checkyesno rpcbind_enable && \ + ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1 + then + force_depend rpcbind || ret=1 + fi + rc_flags=${rpc_lockd_flags} + return ${ret} +} + +load_rc_config $name +run_rc_command $1 --- etc/rc.d/nfslocking +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# -# $FreeBSD: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD: src/etc/rc.d/nfslocking,v 1.3 2007/09/28 22:17:23 laffer1 Exp $ - -# PROVIDE: nfslocking -# REQUIRE: nfsserver nfsclient nfsd -# BEFORE: DAEMON -# KEYWORD: nojail - -. /etc/rc.subr - -# Save the (one) commandline argument in case it gets clobbered. -arg=$1 - -# Either NFS client or server must be enabled or this must be a 'forcestart' -# for either of the daemons to start. -# -start_precmd='checkyesno nfs_server_enable || checkyesno nfs_client_enable || - [ -n "$rc_force" ]' -stop_precmd=$start_precmd -status_precmd=$start_precmd - -# rpc.statd -# -name="statd" -rcvar=rpc_statd_enable -command="/usr/sbin/rpc.${name}" -load_rc_config $name -run_rc_command "$arg" - -# rpc.lockd -# -name="lockd" -rcvar=rpc_lockd_enable -command="/usr/sbin/rpc.${name}" -load_rc_config $name -run_rc_command "$arg" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.13 retrieving revision 1.14 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.13 -r1.14 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -20,12 +20,12 @@ ipnat ipsec ipxrouted isdnd \ jail \ kadmind kerberos kernel keyserv kldxref kpasswdd \ - ldconfig local localpkg lpd \ + ldconfig local localpkg lockd lpd \ mixer motd mountcritlocal mountcritremote \ mountd moused mroute6d mrouted msgs \ named natd netif netoptions \ network_ipv6 newsyslog nfsclient nfsd \ - nfslocking nfsserver nisdomain nsswitch ntpd \ + nfsserver nisdomain nsswitch ntpd \ othermta \ pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ From laffer1 at midnightbsd.org Sat Jan 17 12:37:02 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:37:02 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add mountlate Message-ID: <200901171737.n0HHb2Q9034521@stargazer.midnightbsd.org> Log Message: ----------- add mountlate Modified Files: -------------- src/etc/rc.d: Makefile (r1.14 -> r1.15) Added Files: ----------- src/etc/rc.d: mountlate (r1.1) -------------- next part -------------- --- /dev/null +++ etc/rc.d/mountlate @@ -0,0 +1,37 @@ +#!/bin/sh +# +# $MidnightBSD: src/etc/rc.d/mountlate,v 1.1 2009/01/17 17:37:02 laffer1 Exp $ +# $FreeBSD: src/etc/rc.d/mountlate,v 1.2 2007/05/18 12:04:41 mtm Exp $ +# + +# PROVIDE: mountlate +# REQUIRE: DAEMON +# BEFORE: LOGIN +# KEYWORD: nojail + +. /etc/rc.subr + +name="mountlate" +start_cmd="mountlate_start" +stop_cmd=":" + +mountlate_start() +{ + # Mount "late" filesystems. + echo -n 'Mounting late file systems:' + mount -a -l + echo '.' + + case $? in + 0) + ;; + *) + echo 'Mounting /etc/fstab filesystems failed,' \ + ' startup aborted' + stop_boot true + ;; + esac +} + +load_rc_config $name +run_rc_command "$1" Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.14 retrieving revision 1.15 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.14 -r1.15 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -21,7 +21,7 @@ jail \ kadmind kerberos kernel keyserv kldxref kpasswdd \ ldconfig local localpkg lockd lpd \ - mixer motd mountcritlocal mountcritremote \ + mixer motd mountcritlocal mountcritremote mountlate \ mountd moused mroute6d mrouted msgs \ named natd netif netoptions \ network_ipv6 newsyslog nfsclient nfsd \ From laffer1 at midnightbsd.org Sat Jan 17 12:38:07 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:38:07 -0500 (EST) Subject: [Midnightbsd-cvs] src: mountcritlocal: add friendly message, remove netbsd tag Message-ID: <200901171738.n0HHc7Ka034581@stargazer.midnightbsd.org> Log Message: ----------- add friendly message, remove netbsd tag Modified Files: -------------- src/etc/rc.d: mountcritlocal (r1.3 -> r1.4) -------------- next part -------------- Index: mountcritlocal =================================================================== RCS file: /home/cvs/src/etc/rc.d/mountcritlocal,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/mountcritlocal -L etc/rc.d/mountcritlocal -u -r1.3 -r1.4 --- etc/rc.d/mountcritlocal +++ etc/rc.d/mountcritlocal @@ -1,8 +1,7 @@ #!/bin/sh # -# $NetBSD: mountcritlocal,v 1.7 2002/04/29 12:29:53 lukem Exp $ -# $FreeBSD: src/etc/rc.d/mountcritlocal,v 1.12 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/mountcritlocal,v 1.14.4.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD: src/etc/rc.d/mountcritlocal,v 1.3 2007/10/26 15:20:25 laffer1 # PROVIDE: mountcritlocal # REQUIRE: root @@ -27,6 +26,7 @@ esac # Mount everything except nfs filesystems. + echo -n 'Mounting local file systems:' mount_excludes='no' for i in ${netfs_types}; do fstype=${i%:*} @@ -34,6 +34,7 @@ done mount_excludes=${mount_excludes%,} mount -a -t ${mount_excludes} + echo '.' case $? in 0) From laffer1 at midnightbsd.org Sat Jan 17 12:39:28 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:39:28 -0500 (EST) Subject: [Midnightbsd-cvs] src: mountcritremote: fix some problems with this script Message-ID: <200901171739.n0HHdSpS034671@stargazer.midnightbsd.org> Log Message: ----------- fix some problems with this script Modified Files: -------------- src/etc/rc.d: mountcritremote (r1.4 -> r1.5) -------------- next part -------------- Index: mountcritremote =================================================================== RCS file: /home/cvs/src/etc/rc.d/mountcritremote,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/mountcritremote -L etc/rc.d/mountcritremote -u -r1.4 -r1.5 --- etc/rc.d/mountcritremote +++ etc/rc.d/mountcritremote @@ -1,6 +1,6 @@ -#/bin/sh +#!/bin/sh # -# $FreeBSD: src/etc/rc.d/mountcritremote,v 1.11.2.2 2006/01/08 09:21:53 rse Exp $ +# $FreeBSD: src/etc/rc.d/mountcritremote,v 1.16.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: mountcritremote @@ -26,11 +26,7 @@ case "`mount -d -a -t nfs 2> /dev/null`" in *mount_nfs*) # Handle absent nfs client support - if ! sysctl vfs.nfs >/dev/null 2>&1; then - kldload nfsclient || { warn 'nfs mount ' \ - 'requested, but no nfs client in kernel'; \ - return 1; } - fi + load_kld -m nfs nfsclient || return 1 ;; esac return 0 From laffer1 at midnightbsd.org Sat Jan 17 12:40:45 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:40:45 -0500 (EST) Subject: [Midnightbsd-cvs] src: mountd: add zfs support Message-ID: <200901171740.n0HHejvN035004@stargazer.midnightbsd.org> Log Message: ----------- add zfs support Modified Files: -------------- src/etc/rc.d: mountd (r1.2 -> r1.3) -------------- next part -------------- Index: mountd =================================================================== RCS file: /home/cvs/src/etc/rc.d/mountd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/mountd -L etc/rc.d/mountd -u -r1.2 -r1.3 --- etc/rc.d/mountd +++ etc/rc.d/mountd @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: mountd,v 1.11 2002/01/31 01:26:06 lukem Exp $ -# $FreeBSD: src/etc/rc.d/mountd,v 1.15.2.1 2005/09/21 20:27:50 rodrigc Exp $ +# $FreeBSD: src/etc/rc.d/mountd,v 1.19.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: mountd @@ -13,6 +12,7 @@ name="mountd" rcvar=`set_rcvar` command="/usr/sbin/${name}" +pidfile="/var/run/${name}.pid" required_files="/etc/exports" start_precmd="mountd_precmd" extra_commands="reload" @@ -36,6 +36,11 @@ checkyesno weak_mountd_authentication && rc_flags="-n" fi fi + + if checkyesno zfs_enable; then + rc_flags="${rc_flags} /etc/exports /etc/zfs/exports" + fi + rm -f /var/db/mountdtab ( umask 022 ; > /var/db/mountdtab ) return 0 From laffer1 at midnightbsd.org Sat Jan 17 12:41:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:41:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: FILESYSTEMS: add zfs support Message-ID: <200901171741.n0HHfVnu035064@stargazer.midnightbsd.org> Log Message: ----------- add zfs support Modified Files: -------------- src/etc/rc.d: FILESYSTEMS (r1.1 -> r1.2) -------------- next part -------------- Index: FILESYSTEMS =================================================================== RCS file: /home/cvs/src/etc/rc.d/FILESYSTEMS,v retrieving revision 1.1 retrieving revision 1.2 diff -L etc/rc.d/FILESYSTEMS -L etc/rc.d/FILESYSTEMS -u -r1.1 -r1.2 --- etc/rc.d/FILESYSTEMS +++ etc/rc.d/FILESYSTEMS @@ -4,7 +4,7 @@ # $MidnightBSD$ # PROVIDE: FILESYSTEMS -# REQUIRE: root mountcritlocal +# REQUIRE: root mountcritlocal zfs # This is a dummy dependency, for services which require file systems # to be mounted before starting. It also serves as the default early / From laffer1 at midnightbsd.org Sat Jan 17 12:42:15 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 12:42:15 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: remove netbsd tags Message-ID: <200901171742.n0HHgFrC035137@stargazer.midnightbsd.org> Log Message: ----------- remove netbsd tags Modified Files: -------------- src/etc/rc.d: DAEMON (r1.2 -> r1.3) SERVERS (r1.3 -> r1.4) -------------- next part -------------- Index: SERVERS =================================================================== RCS file: /home/cvs/src/etc/rc.d/SERVERS,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/SERVERS -L etc/rc.d/SERVERS -u -r1.3 -r1.4 --- etc/rc.d/SERVERS +++ etc/rc.d/SERVERS @@ -1,6 +1,5 @@ #!/bin/sh # -# $NetBSD: SERVERS,v 1.9 2002/03/22 04:33:57 thorpej Exp $ # $FreeBSD: src/etc/rc.d/SERVERS,v 1.5 2004/10/07 13:55:25 mtm Exp $ # $MidnightBSD$ Index: DAEMON =================================================================== RCS file: /home/cvs/src/etc/rc.d/DAEMON,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/DAEMON -L etc/rc.d/DAEMON -u -r1.2 -r1.3 --- etc/rc.d/DAEMON +++ etc/rc.d/DAEMON @@ -1,6 +1,5 @@ #!/bin/sh # -# $NetBSD: DAEMON,v 1.8 2002/03/22 04:33:57 thorpej Exp $ # $FreeBSD: src/etc/rc.d/DAEMON,v 1.5 2004/10/07 13:55:25 mtm Exp $ # $MidnightBSD$ From laffer1 at midnightbsd.org Sat Jan 17 13:26:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:26:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: add sync dhclient Message-ID: <200901171826.n0HIQc0V038715@stargazer.midnightbsd.org> Log Message: ----------- add sync dhclient Modified Files: -------------- src/etc/defaults: rc.conf (r1.20 -> r1.21) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.20 retrieving revision 1.21 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.20 -r1.21 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -100,6 +100,9 @@ dhclient_program="/sbin/dhclient" # Path to dhcp client program. dhclient_flags="" # Additional flags to pass to dhcp client. background_dhclient="NO" # Start dhcp client in the background. +#background_dhclient_fxp0="YES" # Start dhcp client on fxp0 in the background. +synchronous_dhclient="YES" # Start dhclient directly on configured + # interfaces during startup. firewall_enable="YES" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="DESKTOP" # Firewall type (see /etc/rc.firewall) From laffer1 at midnightbsd.org Sat Jan 17 13:37:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:37:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: Add defaults for several daemons. Message-ID: <200901171837.n0HIbcbK039532@stargazer.midnightbsd.org> Log Message: ----------- Add defaults for several daemons. Modified Files: -------------- src/etc/defaults: rc.conf (r1.21 -> r1.22) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.21 retrieving revision 1.22 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.21 -r1.22 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -77,7 +77,7 @@ #geli_da1_autodetach="NO" #geli_mirror_home_flags="-k /etc/geli/home.keys" -geli_swap_flags="-a aes -l 256 -s 4096 -d" # Options for GELI-encrypted +geli_swap_flags="-e aes -l 256 -s 4096 -d" # Options for GELI-encrypted # swap partitions. root_rw_mount="YES" # Set to NO to inhibit remounting root read-write. @@ -98,7 +98,8 @@ hostid_file="/etc/hostid" # File with hostuuid. nisdomainname="NO" # Set to NIS domain if using NIS (or NO). dhclient_program="/sbin/dhclient" # Path to dhcp client program. -dhclient_flags="" # Additional flags to pass to dhcp client. +dhclient_flags="" # Extra flags to pass to dhcp client. +#dhclient_flags_fxp0="" # Extra dhclient flags for fxp0 only background_dhclient="NO" # Start dhcp client in the background. #background_dhclient_fxp0="YES" # Start dhcp client on fxp0 in the background. synchronous_dhclient="YES" # Start dhclient directly on configured @@ -106,9 +107,19 @@ firewall_enable="YES" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="DESKTOP" # Firewall type (see /etc/rc.firewall) -firewall_quiet="YES" # Set to YES to suppress rule display +firewall_quiet="NO" # Set to YES to suppress rule display firewall_logging="NO" # Set to YES to enable events logging firewall_flags="" # Flags passed to ipfw when type is a file +firewall_myservices="" # List of TCP ports on which this host + # offers services +firewall_allowservices="" # List of IPs which has access to + # $firewall_myservices +firewall_trusted="" # List of IPs which has full access to this host +firewall_logdeny="NO" # Set to YES to log default denied incoming + # packets. +firewall_nologports="135-139,445 1026,1027 1433,1434" # List of TCP/UDP ports + # for which denied incoming packets are not + # logged. ip_portrange_first="NO" # Set first dynamically allocated port ip_portrange_last="NO" # Set last dynamically allocated port ike_enable="NO" # Enable IKE daemon (usually racoon or isakmpd) @@ -148,12 +159,11 @@ ftpproxy_flags="" # additional flags for ftp-proxy(8) pfsync_enable="NO" # Expose pf state to other hosts for syncing pfsync_syncdev="" # Interface for pfsync to work through +pfsync_syncpeer="" # IP address of pfsync peer host pfsync_ifconfig="" # Additional options to ifconfig(8) for pfsync tcp_extensions="YES" # Set to NO to turn off RFC1323 extensions. log_in_vain="0" # >=1 to log connects to ports w/o listeners. tcp_keepalive="YES" # Enable stale TCP connection timeout (or NO). -# For the following option you need to have TCP_DROP_SYNFIN set in your -# kernel. Please refer to LINT and NOTES for details. tcp_drop_synfin="NO" # Set to YES to drop TCP packets with SYN+FIN # NOTE: this violates the TCP specification icmp_drop_redirect="NO" # Set to YES to ignore ICMP REDIRECT packets @@ -167,6 +177,9 @@ #ifconfig_fxp0_name="net0" # Change interface name from fxp0 to net0. #ipv4_addrs_fxp0="192.168.0.1/24 192.168.1.1-5/28" # example IPv4 address entry. # +#autobridge_interfaces="bridge0" # List of bridges to check +#autobridge_bridge0="tap* vlan0" # Interface glob to automatically add to the bridge +# # If you have any sppp(4) interfaces above, you might also want to set # the following parameters. Refer to spppcontrol(8) for their meaning. sppp_interfaces="" # List of sppp interfaces. @@ -177,6 +190,10 @@ # Choose correct tunnel addrs. #gifconfig_gif0="10.1.1.1 10.1.2.1" # Examples typically for a router. #gifconfig_gif1="10.1.1.2 10.1.2.2" # Examples typically for a router. +fec_interfaces="" # List of Fast EtherChannels. +#fec_interfaces="fec0 fec1" +#fecconfig_fec0="fxp0 dc0" # Examples typically for two NICs +#fecconfig_fec1="em0 em1 bge0 bge1" # Examples typically for four NICs # User ppp configuration. ppp_enable="NO" # Start user-ppp (or NO). @@ -187,6 +204,12 @@ ppp_profile="papchap" # Which profile to use from /etc/ppp/ppp.conf. ppp_user="root" # Which user to run ppp as +# Start multiple instances of ppp at boot time +#ppp_profile="profile1 profile2 profile3" # Which profiles to use +#ppp_profile1_mode="ddial" # Override ppp mode for profile1 +#ppp_profile2_nat="NO" # Override nat mode for profile2 +# profile3 uses default ppp_mode and ppp_nat + ### Network daemon (miscellaneous) ### hostapd_enable="NO" # Run hostap daemon. syslogd_enable="YES" # Run syslog daemon (or NO). @@ -239,19 +262,24 @@ ### Network daemon (NFS): All need rpcbind_enable="YES" ### amd_enable="NO" # Run amd service with $amd_flags (or NO). +amd_program="/usr/sbin/amd" # path to amd, if you want a different one. amd_flags="-a /.amd_mnt -l syslog /host /etc/amd.map /net /etc/amd.map" amd_map_program="NO" # Can be set to "ypcat -k amd.master" nfs_client_enable="NO" # This host is an NFS client (or NO). nfs_access_cache="60" # Client cache timeout in seconds nfs_server_enable="NO" # This host is an NFS server (or NO). nfs_server_flags="-u -t -n 4" # Flags to nfsd (if enabled). +idmapd_enable="NO" # Run the NFS4 id mapper (YES/NO). +idmapd_flags="" # Additional flags for idmapd. mountd_enable="NO" # Run mountd (or NO). mountd_flags="-r" # Flags to mountd (if NFS server enabled). weak_mountd_authentication="NO" # Allow non-root mount requests to be served. nfs_reserved_port_only="NO" # Provide NFS only on secure port (or NO). nfs_bufpackets="" # bufspace (in packets) for client rpc_lockd_enable="NO" # Run NFS rpc.lockd needed for client/server. +rpc_lockd_flags="" # Flags to rpc.lockd (if enabled). rpc_statd_enable="NO" # Run NFS rpc.statd needed for client/server. +rpc_statd_flags="" # Flags to rpc.statd (if enabled). rpcbind_enable="NO" # Run the portmapper service (YES/NO). rpcbind_program="/usr/sbin/rpcbind" # path to rpcbind, if you want a different one. rpcbind_flags="" # Flags to rpcbind (if enabled). @@ -295,7 +323,11 @@ router_enable="NO" # Set to YES to enable a routing daemon. router="/sbin/routed" # Name of routing daemon to use if enabled. router_flags="-q" # Flags for routing daemon. -mrouted_enable="NO" # Do multicast routing (see /etc/mrouted.conf). +mrouted_enable="NO" # Do IPv4 multicast routing. +mrouted_program="/usr/sbin/mrouted" # Name of IPv4 multicast + # routing daemon. You need to + # install it from package or + # port. mrouted_flags="" # Flags for multicast routing daemon. ipxgateway_enable="NO" # Set to YES to enable IPX routing. ipxrouted_enable="NO" # Set to YES to run the IPX routing daemon. @@ -334,8 +366,8 @@ sdpd_username="nobody" # it initializes bthidd_enable="NO" # Enable bthidd(8) (or NO) -bthidd_config="/etc/bluetooth/bthidd.conf" # bthidd(8) configuration file -bthidd_hids="/var/db/bthidd.hids" # bthidd(8) known HID devices file +bthidd_config="/etc/bluetooth/bthidd.conf" # bthidd(8) configuration file +bthidd_hids="/var/db/bthidd.hids" # bthidd(8) known HID devices file ### Miscellaneous network options: ### icmp_bmcastecho="NO" # respond to broadcast ping packets @@ -424,18 +456,16 @@ saver="NO" # screen saver: Uses /boot/kernel/${saver}_saver.ko moused_nondefault_enable="YES" # Treat non-default mice as enabled unless # specifically overriden in rc.conf(5). -moused_enable="YES" # Run the mouse daemon. +moused_enable="NO" # Run the mouse daemon. moused_type="auto" # See man page for rc.conf(5) for available settings. moused_port="/dev/psm0" # Set to your mouse port. moused_flags="" # Any additional flags to moused. mousechar_start="NO" # if 0xd0-0xd3 default range is occupied in your # language code table, specify alternative range # start like mousechar_start=3, see vidcontrol(1) -allscreens_flags="-t off" # Set this vidcontrol mode for all virtual - # screens +allscreens_flags="" # Set this vidcontrol mode for all virtual screens allscreens_kbdflags="" # Set this kbdcontrol mode for all virtual screens - ############################################################## ### Mail Transfer Agent (MTA) options ###################### ############################################################## @@ -455,7 +485,7 @@ sendmail_msp_queue_enable="YES" # Dequeue stuck clientmqueue mail (YES/NO). sendmail_msp_queue_flags="-L sm-msp-queue -Ac -q30m" # Flags for sendmail_msp_queue daemon. -sendmail_rebuild_aliases="NO" # will not rebuild aliases on startup automatically +sendmail_rebuild_aliases="NO" # Run newaliases if necessary (YES/NO). ############################################################## @@ -469,17 +499,20 @@ cron_program="/usr/sbin/cron" # Which cron executable to run (if enabled). cron_dst="YES" # Handle DST transitions intelligently (YES/NO) cron_flags="" # Which options to pass to the cron daemon. -nscd_enable="NO" # Run the nsswitch caching daemon. lpd_enable="NO" # Run the line printer daemon. lpd_program="/usr/sbin/lpd" # path to lpd, if you want a different one. lpd_flags="" # Flags to lpd (if enabled). +nscd_enable="NO" # Run the nsswitch caching daemon. chkprintcap_enable="NO" # Run chkprintcap(8) before running lpd. chkprintcap_flags="-d" # Create missing directories by default. -dumpdev="NO" # Device to crashdump to (device name, AUTO, or NO). +dumpdev="AUTO" # Device to crashdump to (device name, AUTO, or NO). dumpdir="/var/crash" # Directory where crash dumps are to be stored savecore_flags="" # Used if dumpdev is enabled above, and present. enable_quotas="NO" # turn on quotas on startup (or NO). check_quotas="YES" # Check quotas on startup (or NO). +quotaon_flags="-a" # Turn quotas on for all file systems (if enabled) +quotaoff_flags="-a" # Turn quotas off for all file systems at shutdown +quotacheck_flags="-a" # Check all file system quotas (if enabled) accounting_enable="NO" # Turn on process accounting (or NO). ibcs2_enable="NO" # Ibcs2 (SCO) emulation loaded at startup (or NO). ibcs2_loaders="coff" # List of additional Ibcs2 loaders (or NO). @@ -547,12 +580,19 @@ # # To use rc's built-in jail infrastructure create entries for # each jail, specified in jail_list, with the following variables. -# NOTE: replace 'example' with the jail's name. +# NOTES: +# - replace 'example' with the jail's name. +# - except rootdir, hostname and ip, all of the following variables may be made +# global jail variables if you don't specify a jail name (ie. jail_interface). # #jail_example_rootdir="/usr/jail/default" # Jail's root directory #jail_example_hostname="default.domain.com" # Jail's hostname #jail_example_ip="192.168.0.10" # Jail's IP number +#jail_example_interface="" # Interface to create the IP alias on #jail_example_exec_start="/bin/sh /etc/rc" # command to execute in jail for starting +#jail_example_exec_afterstart0="/bin/sh command" # command to execute after the one for + # starting the jail. More than one can be + # specified using a trailing number #jail_example_exec_stop="/bin/sh /etc/rc.shutdown" # command to execute in jail for stopping #jail_example_devfs_enable="NO" # mount devfs in the jail #jail_example_fdescfs_enable="NO" # mount fdescfs in the jail From laffer1 at midnightbsd.org Sat Jan 17 13:42:03 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:42:03 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: Make the firewall quiet Message-ID: <200901171842.n0HIg3wh040053@stargazer.midnightbsd.org> Log Message: ----------- Make the firewall quiet Modified Files: -------------- src/etc/defaults: rc.conf (r1.22 -> r1.23) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.22 retrieving revision 1.23 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.22 -r1.23 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -107,7 +107,7 @@ firewall_enable="YES" # Set to YES to enable firewall functionality firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="DESKTOP" # Firewall type (see /etc/rc.firewall) -firewall_quiet="NO" # Set to YES to suppress rule display +firewall_quiet="YES" # Set to YES to suppress rule display firewall_logging="NO" # Set to YES to enable events logging firewall_flags="" # Flags passed to ipfw when type is a file firewall_myservices="" # List of TCP ports on which this host From laffer1 at midnightbsd.org Sat Jan 17 13:43:39 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 13:43:39 -0500 (EST) Subject: [Midnightbsd-cvs] src: sbin/gpt: update gpt(8) Message-ID: <200901171843.n0HIhdbL040175@stargazer.midnightbsd.org> Log Message: ----------- update gpt(8) Modified Files: -------------- src/sbin/gpt: Makefile (r1.1.1.1 -> r1.2) add.c (r1.1.1.1 -> r1.2) create.c (r1.1.1.1 -> r1.2) destroy.c (r1.1.1.1 -> r1.2) gpt.8 (r1.1.1.1 -> r1.2) gpt.c (r1.1.1.1 -> r1.2) gpt.h (r1.1.1.1 -> r1.2) label.c (r1.1.1.1 -> r1.2) map.c (r1.1.1.1 -> r1.2) map.h (r1.1.1.1 -> r1.2) migrate.c (r1.1.1.1 -> r1.2) recover.c (r1.1.1.1 -> r1.2) remove.c (r1.1.1.1 -> r1.2) show.c (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: show.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/show.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/show.c -L sbin/gpt/show.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/show.c +++ sbin/gpt/show.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/show.c,v 1.11.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/show.c,v 1.14 2006/06/22 22:22:32 marcel Exp $"); #include @@ -57,6 +57,7 @@ static uuid_t efi_slice = GPT_ENT_TYPE_EFI; static uuid_t mslinux = GPT_ENT_TYPE_MS_BASIC_DATA; static uuid_t freebsd = GPT_ENT_TYPE_FREEBSD; + static uuid_t hfs = GPT_ENT_TYPE_APPLE_HFS; static uuid_t linuxswap = GPT_ENT_TYPE_LINUX_SWAP; static uuid_t msr = GPT_ENT_TYPE_MS_RESERVED; static uuid_t swap = GPT_ENT_TYPE_FREEBSD_SWAP; @@ -85,6 +86,8 @@ return ("Linux swap"); if (uuid_equal(t, &msr, NULL)) return ("Windows reserved"); + if (uuid_equal(t, &hfs, NULL)) + return ("Apple HFS"); unfriendly: uuid_to_string(t, &s, NULL); Index: create.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/create.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/create.c -L sbin/gpt/create.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/create.c +++ sbin/gpt/create.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/create.c,v 1.10.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/create.c,v 1.11 2005/08/31 01:47:19 marcel Exp $"); #include Index: gpt.h =================================================================== RCS file: /home/cvs/src/sbin/gpt/gpt.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/gpt.h -L sbin/gpt/gpt.h -u -r1.1.1.1 -r1.2 --- sbin/gpt/gpt.h +++ sbin/gpt/gpt.h @@ -23,7 +23,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sbin/gpt/gpt.h,v 1.7.2.1 2005/09/06 23:59:01 marcel Exp $ + * $FreeBSD: src/sbin/gpt/gpt.h,v 1.11 2006/06/22 22:05:28 marcel Exp $ */ #ifndef _GPT_H_ @@ -36,6 +36,7 @@ void le_uuid_dec(void const *, uuid_t *); void le_uuid_enc(void *, uuid_t const *); +int parse_uuid(const char *, uuid_t *); struct mbr_part { uint8_t part_flag; /* bootstrap flags */ Index: map.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/map.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/map.c -L sbin/gpt/map.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/map.c +++ sbin/gpt/map.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/map.c,v 1.5.8.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/map.c,v 1.6 2005/08/31 01:47:19 marcel Exp $"); #include #include Index: label.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/label.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/label.c -L sbin/gpt/label.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/label.c +++ sbin/gpt/label.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/label.c,v 1.1.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/label.c,v 1.3 2006/10/04 18:20:25 marcel Exp $"); #include @@ -172,7 +172,6 @@ { char *p; int ch, fd; - uint32_t status; /* Get the label options */ while ((ch = getopt(argc, argv, "ab:f:i:l:s:t:")) != -1) { @@ -185,7 +184,7 @@ case 'b': if (block > 0) usage_label(); - block = strtol(optarg, &p, 10); + block = strtoll(optarg, &p, 10); if (*p != 0 || block < 1) usage_label(); break; @@ -209,31 +208,15 @@ case 's': if (size > 0) usage_label(); - size = strtol(optarg, &p, 10); + size = strtoll(optarg, &p, 10); if (*p != 0 || size < 1) usage_label(); break; case 't': if (!uuid_is_nil(&type, NULL)) usage_label(); - uuid_from_string(optarg, &type, &status); - if (status != uuid_s_ok) { - if (strcmp(optarg, "efi") == 0) { - uuid_t efi = GPT_ENT_TYPE_EFI; - type = efi; - } else if (strcmp(optarg, "swap") == 0) { - uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; - type = sw; - } else if (strcmp(optarg, "ufs") == 0) { - uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; - type = ufs; - } else if (strcmp(optarg, "linux") == 0 || - strcmp(optarg, "windows") == 0) { - uuid_t m = GPT_ENT_TYPE_MS_BASIC_DATA; - type = m; - } else - usage_label(); - } + if (parse_uuid(optarg, &type) != 0) + usage_label(); break; default: usage_label(); Index: remove.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/remove.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/remove.c -L sbin/gpt/remove.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/remove.c +++ sbin/gpt/remove.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/remove.c,v 1.4.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/remove.c,v 1.10 2006/10/04 18:20:25 marcel Exp $"); #include @@ -143,7 +143,6 @@ { char *p; int ch, fd; - uint32_t status; /* Get the remove options */ while ((ch = getopt(argc, argv, "ab:i:s:t:")) != -1) { @@ -156,7 +155,7 @@ case 'b': if (block > 0) usage_remove(); - block = strtol(optarg, &p, 10); + block = strtoll(optarg, &p, 10); if (*p != 0 || block < 1) usage_remove(); break; @@ -170,31 +169,15 @@ case 's': if (size > 0) usage_remove(); - size = strtol(optarg, &p, 10); + size = strtoll(optarg, &p, 10); if (*p != 0 || size < 1) usage_remove(); break; case 't': if (!uuid_is_nil(&type, NULL)) usage_remove(); - uuid_from_string(optarg, &type, &status); - if (status != uuid_s_ok) { - if (strcmp(optarg, "efi") == 0) { - uuid_t efi = GPT_ENT_TYPE_EFI; - type = efi; - } else if (strcmp(optarg, "swap") == 0) { - uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; - type = sw; - } else if (strcmp(optarg, "ufs") == 0) { - uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; - type = ufs; - } else if (strcmp(optarg, "linux") == 0 || - strcmp(optarg, "windows") == 0) { - uuid_t m = GPT_ENT_TYPE_MS_BASIC_DATA; - type = m; - } else - usage_remove(); - } + if (parse_uuid(optarg, &type) != 0) + usage_remove(); break; default: usage_remove(); Index: gpt.8 =================================================================== RCS file: /home/cvs/src/sbin/gpt/gpt.8,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/gpt.8 -L sbin/gpt/gpt.8 -u -r1.1.1.1 -r1.2 --- sbin/gpt/gpt.8 +++ sbin/gpt/gpt.8 @@ -22,9 +22,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/sbin/gpt/gpt.8,v 1.13.2.1 2005/09/06 23:59:01 marcel Exp $ +.\" $FreeBSD: src/sbin/gpt/gpt.8,v 1.17 2006/06/22 22:22:32 marcel Exp $ .\" -.Dd August 31, 2005 +.Dd June 22, 2006 .Os .Dt GPT 8 .Sh NAME @@ -130,7 +130,7 @@ The type is given as an UUID, but .Nm accepts -.Cm efi , swap , ufs , linux +.Cm efi , swap , ufs , hfs , linux and .Cm windows as aliases for the most commonly used partition types. @@ -224,7 +224,9 @@ option is used to read the label from the specified file. Only the first line is read from the file and the trailing newline character is stripped. -If the file name is the dash or minus sign (-), the label is read from +If the file name is the dash or minus sign +.Pq Fl , +the label is read from the standard input. The .Fl l Ar label @@ -286,7 +288,7 @@ The option has no effect on non-GPT partitions. With the .Fl u -option the GPT partition type is displayed as an UUID instead of in an +option the GPT partition type is displayed as an UUID instead of in a user friendly form. The .Fl l Index: gpt.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/gpt.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/gpt.c -L sbin/gpt/gpt.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/gpt.c +++ sbin/gpt/gpt.c @@ -27,7 +27,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/gpt.c,v 1.10.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/gpt.c,v 1.16.2.1 2007/11/09 02:29:43 jhb Exp $"); #include #include @@ -258,6 +258,62 @@ p[10 + i] = uuid->node[i]; } +int +parse_uuid(const char *s, uuid_t *uuid) +{ + uint32_t status; + + uuid_from_string(s, uuid, &status); + if (status == uuid_s_ok) + return (0); + + switch (*s) { + case 'e': + if (strcmp(s, "efi") == 0) { + uuid_t efi = GPT_ENT_TYPE_EFI; + *uuid = efi; + return (0); + } + break; + case 'h': + if (strcmp(s, "hfs") == 0) { + uuid_t hfs = GPT_ENT_TYPE_APPLE_HFS; + *uuid = hfs; + return (0); + } + break; + case 'l': + if (strcmp(s, "linux") == 0) { + uuid_t lnx = GPT_ENT_TYPE_MS_BASIC_DATA; + *uuid = lnx; + return (0); + } + break; + case 's': + if (strcmp(s, "swap") == 0) { + uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; + *uuid = sw; + return (0); + } + break; + case 'u': + if (strcmp(s, "ufs") == 0) { + uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; + *uuid = ufs; + return (0); + } + break; + case 'w': + if (strcmp(s, "windows") == 0) { + uuid_t win = GPT_ENT_TYPE_MS_BASIC_DATA; + *uuid = win; + return (0); + } + break; + } + return (EINVAL); +} + void* gpt_read(int fd, off_t lba, size_t count) { @@ -529,10 +585,16 @@ if (gpt_mbr(fd, 0LL) == -1) goto close; - if (gpt_gpt(fd, 1LL) == -1) - goto close; - if (gpt_gpt(fd, mediasz / secsz - 1LL) == -1) - goto close; + + /* + * Don't look for a GPT unless we have a valid PMBR. + */ + if (map_find(MAP_TYPE_PMBR) != NULL) { + if (gpt_gpt(fd, 1LL) == -1) + goto close; + if (gpt_gpt(fd, mediasz / secsz - 1LL) == -1) + goto close; + } return (fd); Index: recover.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/recover.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/recover.c -L sbin/gpt/recover.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/recover.c +++ sbin/gpt/recover.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/recover.c,v 1.7.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/recover.c,v 1.8 2005/08/31 01:47:19 marcel Exp $"); #include Index: map.h =================================================================== RCS file: /home/cvs/src/sbin/gpt/map.h,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/map.h -L sbin/gpt/map.h -u -r1.1.1.1 -r1.2 --- sbin/gpt/map.h +++ sbin/gpt/map.h @@ -23,7 +23,7 @@ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $FreeBSD: src/sbin/gpt/map.h,v 1.5.8.1 2005/09/06 23:59:01 marcel Exp $ + * $FreeBSD: src/sbin/gpt/map.h,v 1.6 2005/08/31 01:47:19 marcel Exp $ */ #ifndef _MAP_H_ Index: migrate.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/migrate.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/migrate.c -L sbin/gpt/migrate.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/migrate.c +++ sbin/gpt/migrate.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/migrate.c,v 1.13.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/migrate.c,v 1.16 2005/09/01 02:42:52 marcel Exp $"); #include #include Index: Makefile =================================================================== RCS file: /home/cvs/src/sbin/gpt/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/Makefile -L sbin/gpt/Makefile -u -r1.1.1.1 -r1.2 --- sbin/gpt/Makefile +++ sbin/gpt/Makefile @@ -1,4 +1,4 @@ -# $FreeBSD: src/sbin/gpt/Makefile,v 1.6.8.1 2005/09/06 23:59:01 marcel Exp $ +# $FreeBSD: src/sbin/gpt/Makefile,v 1.7 2005/09/01 02:49:20 marcel Exp $ PROG= gpt SRCS= add.c create.c destroy.c gpt.c label.c map.c migrate.c recover.c \ Index: add.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/add.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/add.c -L sbin/gpt/add.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/add.c +++ sbin/gpt/add.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/add.c,v 1.11.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/add.c,v 1.15 2006/10/04 18:20:25 marcel Exp $"); #include @@ -156,7 +156,6 @@ { char *p; int ch, fd; - uint32_t status; /* Get the migrate options */ while ((ch = getopt(argc, argv, "b:i:s:t:")) != -1) { @@ -164,7 +163,7 @@ case 'b': if (block > 0) usage_add(); - block = strtol(optarg, &p, 10); + block = strtoll(optarg, &p, 10); if (*p != 0 || block < 1) usage_add(); break; @@ -178,31 +177,15 @@ case 's': if (size > 0) usage_add(); - size = strtol(optarg, &p, 10); + size = strtoll(optarg, &p, 10); if (*p != 0 || size < 1) usage_add(); break; case 't': if (!uuid_is_nil(&type, NULL)) usage_add(); - uuid_from_string(optarg, &type, &status); - if (status != uuid_s_ok) { - if (strcmp(optarg, "efi") == 0) { - uuid_t efi = GPT_ENT_TYPE_EFI; - type = efi; - } else if (strcmp(optarg, "swap") == 0) { - uuid_t sw = GPT_ENT_TYPE_FREEBSD_SWAP; - type = sw; - } else if (strcmp(optarg, "ufs") == 0) { - uuid_t ufs = GPT_ENT_TYPE_FREEBSD_UFS; - type = ufs; - } else if (strcmp(optarg, "linux") == 0 || - strcmp(optarg, "windows") == 0) { - uuid_t m = GPT_ENT_TYPE_MS_BASIC_DATA; - type = m; - } else - usage_add(); - } + if (parse_uuid(optarg, &type) != 0) + usage_add(); break; default: usage_add(); Index: destroy.c =================================================================== RCS file: /home/cvs/src/sbin/gpt/destroy.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sbin/gpt/destroy.c -L sbin/gpt/destroy.c -u -r1.1.1.1 -r1.2 --- sbin/gpt/destroy.c +++ sbin/gpt/destroy.c @@ -25,7 +25,7 @@ */ #include -__FBSDID("$FreeBSD: src/sbin/gpt/destroy.c,v 1.5.2.1 2005/09/06 23:59:01 marcel Exp $"); +__FBSDID("$FreeBSD: src/sbin/gpt/destroy.c,v 1.6 2005/08/31 01:47:19 marcel Exp $"); #include From laffer1 at midnightbsd.org Sat Jan 17 17:23:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 17:23:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: ramdisk and ramdisk-own -> mdconfig and mdconfig2 statd Message-ID: <200901172223.n0HMNtmP058758@stargazer.midnightbsd.org> Log Message: ----------- ramdisk and ramdisk-own -> mdconfig and mdconfig2 statd is from nfslocking Modified Files: -------------- src/etc/rc.d: Makefile (r1.15 -> r1.16) Added Files: ----------- src/etc/rc.d: mdconfig (r1.1) mdconfig2 (r1.1) statd (r1.1) Removed Files: ------------- src/etc/rc.d: ramdisk ramdisk-own -------------- next part -------------- --- etc/rc.d/ramdisk +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2004 The FreeBSD Project -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/etc/rc.d/ramdisk,v 1.4 2004/10/07 13:55:26 mtm Exp $ -# $MidnightBSD: src/etc/rc.d/ramdisk,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: ramdisk -# REQUIRE: localswap -# BEFORE: mountcritlocal - -. /etc/rc.subr - -name="ramdisk" -stop_cmd="ramdisk_stop" -start_cmd="ramdisk_start" - -ramdisk_start() -{ - for unit in $ramdisk_units; do - eval mdoptions=\$ramdisk_${unit}_config - if [ "$mdoptions" = "${mdoptions##-t}" ]; then - echo "Type not specified for md$unit" - continue - fi - eval fsoptions=\$ramdisk_${unit}_newfs - - mdconfig -a $mdoptions -u $unit - newfs $fsoptions /dev/md$unit - done -} - -ramdisk_stop() -{ - for unit in $ramdisk_units - do - if [ -c /dev/md$unit ]; then - umount -f /dev/md$unit > /dev/null 2>&1 - mdconfig -d -u $unit - fi - done -} - -load_rc_config $name -run_rc_command "$1" - --- /dev/null +++ etc/rc.d/statd @@ -0,0 +1,43 @@ +#!/bin/sh +# +# FreeBSD History: src/etc/rc.d/nfslocking,v 1.11 2004/10/07 13:55:26 mtm Exp +# $FreeBSD: src/etc/rc.d/statd,v 1.17.6.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD: src/etc/rc.d/statd,v 1.1 2009/01/17 22:23:54 laffer1 Exp $ + +# PROVIDE: statd +# REQUIRE: nfsserver nfsclient nfsd rpcbind +# BEFORE: DAEMON +# KEYWORD: nojail + +. /etc/rc.subr + +name="statd" +rcvar=rpc_statd_enable +command="/usr/sbin/rpc.${name}" +start_precmd='statd_precmd' +stop_precmd='checkyesno nfs_server_enable || checkyesno nfs_client_enable' +status_precmd=$stop_precmd + +# Make sure that we are either an NFS client or server, and that we get +# the correct flags from rc.conf(5). +# +statd_precmd() +{ + local ret + ret=0 + + if ! checkyesno nfs_server_enable && ! checkyesno nfs_client_enable + then + ret=1 + fi + if ! checkyesno rpcbind_enable && \ + ! /etc/rc.d/rpcbind forcestatus 1>/dev/null 2>&1 + then + force_depend rpcbind || ret=1 + fi + rc_flags=${rpc_statd_flags} + return ${ret} +} + +load_rc_config $name +run_rc_command $1 --- /dev/null +++ etc/rc.d/mdconfig @@ -0,0 +1,198 @@ +#!/bin/sh +# +# Copyright (c) 2006 The FreeBSD Project +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $FreeBSD: src/etc/rc.d/mdconfig,v 1.5 2007/08/25 00:19:17 matteo Exp $ +# $MidnightBSD: src/etc/rc.d/mdconfig,v 1.1 2009/01/17 22:23:54 laffer1 Exp $ + +# PROVIDE: mdconfig +# REQUIRE: localswap +# BEFORE: mountcritlocal + +. /etc/rc.subr + +name="mdconfig" +stop_cmd="mdconfig_stop" +start_cmd="mdconfig_start" +start_precmd='[ -n "${_mdconfig_list}" ]' +required_modules="geom_md:g_md" + +is_readonly() +{ + local _mp _ret + + _mp=$1 + _ret=`mount | while read _line; do + case ${_line} in + *" ${_mp} "*read-only*) + echo "yes" + ;; + + *) + ;; + esac; + done` + + if [ -n "${_ret}" ]; then + return 0 + else + return 1 + fi +} + +init_variables() +{ + local _i + + _fs="" + _mp="" + _dev="/dev/${_md}" + eval _config=\$mdconfig_${_md} + eval _newfs=\$mdconfig_${_md}_newfs + + _type=${_config##*-t\ } + _type=${_type%%\ *} + if [ -z "${_type}" ]; then + err 1 "You need to specify \"-t \" in mdconfig_${_md}" + fi + + if [ "${_type}" = "vnode" ]; then + _file=${_config##*-f\ } + _file=${_file%%\ *} + if [ -z "${_file}" ]; then + err 2 "You need to specify \"-f \" in mdconfig_${_md} for vnode devices" + fi + if [ "${_file}" != "${_file%.uzip}" ]; then + _dev="/dev/${_md}.uzip" + fi + for _i in `df ${_file} 2>/dev/null`; do _fs=${_i}; done + fi + + # Debugging help. + debug "${_md} config: ${_config}" + debug "${_md} type: ${_type}" + debug "${_md} dev: ${_dev}" + debug "${_md} file: ${_file}" + debug "${_md} fs: ${_fs}" + debug "${_md} newfs flags: ${_newfs}" +} + +mdconfig_start() +{ + local _md _mp _config _type _dev _file _fs _newfs _fsck_cmd + + for _md in ${_mdconfig_list}; do + init_variables ${_md} + # Create md(4) devices of types swap, malloc and vnode if the + # file is on the root partition. + if [ "${_type}" != "vnode" -o "${_fs}" = "/" ]; then + if [ "${_type}" = "vnode" ]; then + if is_readonly ${_fs}; then + warn "${_fs} is mounted read-only, skipping ${_md}." + continue + fi + if [ "${_file}" != "${_file%.uzip}" ]; then + load_kld -m g_uzip geom_uzip || return 3 + # sleep a bit to allow creation of /dev/mdX.uzip + sleep 2 + fi + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + err 3 "${_md} already exists" + fi + echo "Creating ${_md} device (${_type})." + if ! mdconfig -a ${_config} -u ${_md}; then + echo "Creating ${_md} device failed, moving on." + continue + fi + # Skip fsck for uzip devices. + if [ "${_type}" = "vnode" ]; then + if [ "${_file}" != "${_file%.uzip}" ]; then + _fsck_cmd=":" + elif checkyesno background_fsck; then + _fsck_cmd="fsck -F" + else + _fsck_cmd="fsck" + fi + if ! eval ${_fsck_cmd} -p ${_dev} >/dev/null; then + echo "Fsck failed on ${_dev}, not mounting the filesystem." + continue + + fi + else + newfs ${_newfs} ${_dev} >/dev/null + fi + if mount -d ${_dev} 2>&1 >/dev/null; then + echo "Mounting ${_dev}." + mount ${_dev} + fi + fi + done +} + +mdconfig_stop() +{ + local _md _mp _config _type _dev _file _fs _newfs _i + + for _md in ${_mdconfig_list}; do + init_variables ${_md} + if [ "${_type}" != "vnode" -o "${_fs}" = "/" ]; then + for _i in `df ${_dev} 2>/dev/null`; do _mp=${_i}; done + if [ -z "${_mp}" -o "${_mp}" != "${_mp%%%}" ]; then + echo "Device ${_dev} isn't mounted." + else + echo "Umounting ${_dev}." + umount ${_dev} + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + echo "Destroying ${_md}." + mdconfig -d -u ${_md} + fi + fi + done +} + +_mdconfig_cmd="$1" +if [ $# -gt 0 ]; then + shift +fi +[ -n "$*" ] && _mdconfig_list="$*" + +load_rc_config $name + +_mdconfig_unit=0 +if [ -z "${_mdconfig_list}" ]; then + while :; do + eval _mdconfig_config=\$mdconfig_md${_mdconfig_unit} + if [ -z "${_mdconfig_config}" ]; then + break + else + _mdconfig_list="${_mdconfig_list}${_mdconfig_list:+ }md${_mdconfig_unit}" + _mdconfig_unit=$((${_mdconfig_unit} + 1)) + fi + done +fi + +run_rc_command "${_mdconfig_cmd}" --- etc/rc.d/ramdisk-own +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/sh - -# -# Copyright (c) 2004 The FreeBSD Project -# All rights reserved. -# -# Redistribution and use in source and binary forms, with or without -# modification, are permitted provided that the following conditions -# are met: -# 1. Redistributions of source code must retain the above copyright -# notice, this list of conditions and the following disclaimer. -# 2. Redistributions in binary form must reproduce the above copyright -# notice, this list of conditions and the following disclaimer in the -# documentation and/or other materials provided with the distribution. -# -# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -# SUCH DAMAGE. -# -# $FreeBSD: src/etc/rc.d/ramdisk-own,v 1.4 2004/11/16 04:14:28 wes Exp $ -# $MidnightBSD: src/etc/rc.d/ramdisk-own,v 1.2 2006/08/28 02:47:46 laffer1 Exp $ - -# PROVIDE: ramdisk-own -# REQUIRE: ramdisk mountcritlocal -# BEFORE: SERVERS - -. /etc/rc.subr - -name="ramdisk" -stop_cmd=":" -start_cmd="ramdisk_own_start" - -ramdisk_own_start() -{ - for unit in $ramdisk_units; do - device="/dev/md$unit" - dir=`mount | grep $device | cut -d' ' -f3` - - eval owner=\$ramdisk_${unit}_owner - eval perms=\$ramdisk_${unit}_perms - - [ "X$owner" != "X" ] && chown -f "$owner" $device $dir - [ "X$perms" != "X" ] && chmod -f "$perms" /dev/md$unit $dir - done -} - -load_rc_config $name -run_rc_command "$1" - Index: Makefile =================================================================== RCS file: /home/cvs/src/etc/rc.d/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -L etc/rc.d/Makefile -L etc/rc.d/Makefile -u -r1.15 -r1.16 --- etc/rc.d/Makefile +++ etc/rc.d/Makefile @@ -22,7 +22,7 @@ kadmind kerberos kernel keyserv kldxref kpasswdd \ ldconfig local localpkg lockd lpd \ mixer motd mountcritlocal mountcritremote mountlate \ - mountd moused mroute6d mrouted msgs \ + mdconfig mdconfig2 mountd moused mroute6d mrouted msgs \ named natd netif netoptions \ network_ipv6 newsyslog nfsclient nfsd \ nfsserver nisdomain nsswitch ntpd \ @@ -30,10 +30,10 @@ pf pflog pfsync \ powerd power_profile ppp pppoed pwcheck \ quota \ - ramdisk ramdisk-own random rarpd rdate resolv root \ + random rarpd rdate resolv root \ route6d routed routing rpcbind rtadvd rwho \ savecore sdpd securelevel sendmail \ - serial sound sppp swap1 \ + serial sound sppp statd swap1 \ syscons sysctl syslogd \ timed tmp \ ugidfw \ --- /dev/null +++ etc/rc.d/mdconfig2 @@ -0,0 +1,227 @@ +#!/bin/sh +# +# Copyright (c) 2006 The FreeBSD Project +# All rights reserved. +# +# Redistribution and use in source and binary forms, with or without +# modification, are permitted provided that the following conditions +# are met: +# 1. Redistributions of source code must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# 2. Redistributions in binary form must reproduce the above copyright +# notice, this list of conditions and the following disclaimer in the +# documentation and/or other materials provided with the distribution. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +# SUCH DAMAGE. +# +# $FreeBSD: src/etc/rc.d/mdconfig2,v 1.4 2006/12/31 10:37:18 yar Exp $ +# $MidnightBSD: src/etc/rc.d/mdconfig2,v 1.1 2009/01/17 22:23:54 laffer1 Exp $ + +# PROVIDE: mdconfig2 +# REQUIRE: mountcritremote +# BEFORE: SERVERS + +. /etc/rc.subr + +name="mdconfig2" +stop_cmd="mdconfig2_stop" +start_cmd="mdconfig2_start" +start_precmd='[ -n "${_mdconfig2_list}" ]' +required_modules="geom_md:g_md" + +is_readonly() +{ + local _mp _ret + + _mp=$1 + _ret=`mount | while read _line; do + case ${_line} in + *" ${_mp} "*read-only*) + echo "yes" + ;; + + *) + ;; + esac; + done` + + if [ -n "${_ret}" ]; then + return 0 + else + return 1 + fi +} + +init_variables() +{ + local _i + + _fs="" + _mp="" + _mounted="no" + _dev="/dev/${_md}" + eval _config=\$mdconfig_${_md} + eval _owner=\$mdconfig_${_md}_owner + eval _perms=\$mdconfig_${_md}_perms + eval _files=\$mdconfig_${_md}_files + eval _populate=\$mdconfig_${_md}_cmd + + _type=${_config##*-t\ } + _type=${_type%%\ *} + if [ -z "${_type}" ]; then + err 1 "You need to specify \"-t \" in mdconfig_${_md}" + fi + + if [ "${_type}" = "vnode" ]; then + _file=${_config##*-f\ } + _file=${_file%%\ *} + if [ -z "${_file}" ]; then + err 2 "You need to specify \"-f \" in mdconfig_${_md} for vnode devices" + fi + + if [ "${_file}" != "${_file%.uzip}" ]; then + _dev="/dev/${_md}.uzip" + fi + for _i in `df ${_file} 2>/dev/null`; do _fs=${_i}; done + fi + + # Debugging help. + debug "${_md} config: ${_config}" + debug "${_md} type: ${_type}" + debug "${_md} dev: ${_dev}" + debug "${_md} file: ${_file}" + debug "${_md} fs: ${_fs}" + debug "${_md} owner: ${_owner}" + debug "${_md} perms: ${_perms}" + debug "${_md} files: ${_files}" + debug "${_md} populate cmd: ${_populate}" +} + +mdconfig2_start() +{ + local _md _fs _mp _mounted _dev _config _type _file _owner _perms _files _populate _fsck_cmd _i + + for _md in ${_mdconfig2_list}; do + init_variables ${_md} + if [ ! -r ${_file} ]; then + err 3 "${_file} doesn't exist" + continue + fi + # First pass: create md(4) vnode devices from files stored on + # non-root partition. Swap and malloc md(4) devices have already + # been created. + if [ "${_type}" = "vnode" -a "${_fs}" != "/" ]; then + if [ "${_file}" != "${_file%.uzip}" ]; then + load_kld -m g_uzip geom_uzip || return 3 + fi + if is_readonly ${_fs}; then + warn "${_fs} is mounted read-only, skipping ${_md}." + continue + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + err 3 "${_md} already exists" + fi + echo "Creating ${_md} device (${_type})." + if ! mdconfig -a ${_config} -u ${_md}; then + echo "Creating ${_md} device failed, moving on." + continue + fi + # Skip fsck for uzip devices. + if [ "${_file}" != "${_file%.uzip}" ]; then + _fsck_cmd=":" + elif checkyesno background_fsck; then + _fsck_cmd="fsck -F" + else + _fsck_cmd="fsck" + fi + if ! eval ${_fsck_cmd} -p ${_dev} >/dev/null; then + echo "Fsck failed on ${_dev}, not mounting the filesystem." + continue + fi + if mount -d ${_dev} >/dev/null 2>&1; then + echo "Mounting ${_dev}." + mount ${_dev} + fi + fi + + for _i in `df ${_dev} 2>/dev/null`; do _mp=${_i}; done + if [ ! -z "${_mp}" -a "${_mp}" = "${_mp%%%}" ]; then + _mounted="yes" + fi + + if checkyesno _mounted; then + # Second pass: change permissions and ownership. + [ -z "${_owner}" ] || chown -f ${_owner} ${_dev} ${_mp} + [ -z "${_perms}" ] || chmod -f ${_perms} ${_dev} ${_mp} + + # Third pass: populate with foreign files. + if [ -n "${_files}" -o -n "${_populate}" ]; then + echo "Populating ${_dev}." + fi + if [ -n "${_files}" ]; then + cp -Rp ${_files} ${_mp} + fi + if [ -n "${_populate}" ]; then + eval ${_populate} + fi + fi + done +} + +mdconfig2_stop() +{ + local _md _fs _mp _mounted _dev _config _type _file _owner _perms _files _populate + + for _md in ${_mdconfig2_list}; do + init_variables ${_md} + if [ "${_type}" = "vnode" ]; then + for i in `df ${_dev} 2>/dev/null`; do _mp=$i; done + if [ ! -r "${_file}" -o "${_fs}" = "/" ]; then + continue + fi + if [ -z "${_mp}" -o "${_mp}" != "${_mp%%%}" ]; then + echo "Device ${_dev} isn't mounted." + else + echo "Umounting ${_dev}." + umount ${_dev} + fi + if mdconfig -l -u ${_md} >/dev/null 2>&1; then + echo "Destroying ${_md}." + mdconfig -d -u ${_md} + fi + fi + done +} + +_mdconfig2_cmd="$1" +if [ $# -gt 0 ]; then + shift +fi +[ -n "$*" ] && _mdconfig2_list="$*" + +load_rc_config $name + +_mdconfig2_unit=0 +if [ -z "${_mdconfig2_list}" ]; then + while :; do + eval _mdconfig2_config=\$mdconfig_md${_mdconfig2_unit} + if [ -z "${_mdconfig2_config}" ]; then + break + else + _mdconfig2_list="${_mdconfig2_list}${_mdconfig2_list:+ }md${_mdconfig2_unit}" + _mdconfig2_unit=$((${_mdconfig2_unit} + 1)) + fi + done +fi + +run_rc_command "${_mdconfig2_cmd}" From laffer1 at midnightbsd.org Sat Jan 17 19:00:27 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:00:27 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.conf: disable dumpdev since we encrypt swap. Message-ID: <200901180000.n0I00RZZ067541@stargazer.midnightbsd.org> Log Message: ----------- disable dumpdev since we encrypt swap. (regression fix) Modified Files: -------------- src/etc/defaults: rc.conf (r1.23 -> r1.24) -------------- next part -------------- Index: rc.conf =================================================================== RCS file: /home/cvs/src/etc/defaults/rc.conf,v retrieving revision 1.23 retrieving revision 1.24 diff -L etc/defaults/rc.conf -L etc/defaults/rc.conf -u -r1.23 -r1.24 --- etc/defaults/rc.conf +++ etc/defaults/rc.conf @@ -505,7 +505,7 @@ nscd_enable="NO" # Run the nsswitch caching daemon. chkprintcap_enable="NO" # Run chkprintcap(8) before running lpd. chkprintcap_flags="-d" # Create missing directories by default. -dumpdev="AUTO" # Device to crashdump to (device name, AUTO, or NO). +dumpdev="NO" # Device to crashdump to (device name, AUTO, or NO). dumpdir="/var/crash" # Directory where crash dumps are to be stored savecore_flags="" # Used if dumpdev is enabled above, and present. enable_quotas="NO" # turn on quotas on startup (or NO). From laffer1 at midnightbsd.org Sat Jan 17 19:02:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:02:19 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: tag Message-ID: <200901180002.n0I02Jfx067618@stargazer.midnightbsd.org> Log Message: ----------- tag Modified Files: -------------- src/sys/modules/ibcs2: Makefile (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/ibcs2/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/modules/ibcs2/Makefile -L sys/modules/ibcs2/Makefile -u -r1.1.1.1 -r1.2 --- sys/modules/ibcs2/Makefile +++ sys/modules/ibcs2/Makefile @@ -1,3 +1,4 @@ +# $MidnightBSD$ # $FreeBSD: src/sys/modules/ibcs2/Makefile,v 1.34 2002/08/12 07:20:15 alfred Exp $ .PATH: ${.CURDIR}/../../i386/ibcs2 From laffer1 at midnightbsd.org Sat Jan 17 19:04:40 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:04:40 -0500 (EST) Subject: [Midnightbsd-cvs] src: sysctl: enclose in quotes Message-ID: <200901180004.n0I04eJE067703@stargazer.midnightbsd.org> Log Message: ----------- enclose in quotes Modified Files: -------------- src/etc/rc.d: sysctl (r1.3 -> r1.4) -------------- next part -------------- Index: sysctl =================================================================== RCS file: /home/cvs/src/etc/rc.d/sysctl,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/sysctl -L etc/rc.d/sysctl -u -r1.3 -r1.4 --- etc/rc.d/sysctl +++ etc/rc.d/sysctl @@ -36,7 +36,7 @@ ${val}) ;; *) - sysctl ${var} + sysctl "${var}" ;; esac elif [ "$1" = "last" ]; then From laffer1 at midnightbsd.org Sat Jan 17 19:08:33 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:08:33 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: add stop command and fix lowest power profile testing Message-ID: <200901180008.n0I08Xp7068092@stargazer.midnightbsd.org> Log Message: ----------- add stop command and fix lowest power profile testing Modified Files: -------------- src/etc/rc.d: ipnat (r1.2 -> r1.3) power_profile (r1.3 -> r1.4) -------------- next part -------------- Index: power_profile =================================================================== RCS file: /home/cvs/src/etc/rc.d/power_profile,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/power_profile -L etc/rc.d/power_profile -u -r1.3 -r1.4 --- etc/rc.d/power_profile +++ etc/rc.d/power_profile @@ -16,6 +16,7 @@ . /etc/rc.subr name="power_profile" +stop_cmd=':' LOGGER="logger -t power_profile -p daemon.notice" # Set a given sysctl node to a value. @@ -77,7 +78,7 @@ # Set the various sysctls based on the profile's values. node="hw.acpi.cpu.cx_lowest" highest_value="C1" -lowest_value="`(sysctl -n hw.acpi.cpu.cx_supported | \ +lowest_value="`(sysctl -n dev.cpu.0.cx_supported | \ awk '{ print "C" split($0, a) }' -) 2> /dev/null`" eval value=\$${profile}_cx_lowest sysctl_set Index: ipnat =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipnat,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/ipnat -L etc/rc.d/ipnat -u -r1.2 -r1.3 --- etc/rc.d/ipnat +++ etc/rc.d/ipnat @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: ipnat,v 1.6 2000/09/19 13:04:38 lukem Exp $ -# $FreeBSD: src/etc/rc.d/ipnat,v 1.14 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/ipnat,v 1.15.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: ipnat @@ -14,31 +13,15 @@ name="ipnat" rcvar=`set_rcvar` load_rc_config $name -start_precmd="ipnat_precmd" start_cmd="ipnat_start" stop_cmd="${ipnat_program} -F -C" reload_cmd="${ipnat_program} -F -C -f ${ipnat_rules}" extra_commands="reload" - -ipnat_precmd() -{ - # Make sure ipfilter is loaded before continuing - if ! ${SYSCTL} net.inet.ipf.fr_pass >/dev/null 2>&1; then - if kldload ipl; then - info 'IP-filter module loaded.' - else - err 1 'IP-filter module failed to load.' - fi - fi - return 0 -} +required_files="${ipnat_rules}" +required_modules="ipl:ipfilter" ipnat_start() { - if [ ! -f ${ipnat_rules} ]; then - warn 'NO IPNAT RULES' - return 0 - fi echo "Installing NAT rules." ${ipnat_program} -CF -f ${ipnat_rules} ${ipnat_flags} } From laffer1 at midnightbsd.org Sat Jan 17 19:16:14 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:16:14 -0500 (EST) Subject: [Midnightbsd-cvs] src: ipsec: remove unneeded commands on ipsec reload Message-ID: <200901180016.n0I0GEsx068877@stargazer.midnightbsd.org> Log Message: ----------- remove unneeded commands on ipsec reload Modified Files: -------------- src/etc/rc.d: ipsec (r1.3 -> r1.4) -------------- next part -------------- Index: ipsec =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipsec,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ipsec -L etc/rc.d/ipsec -u -r1.3 -r1.4 --- etc/rc.d/ipsec +++ etc/rc.d/ipsec @@ -1,6 +1,5 @@ #!/bin/sh # -# $NetBSD: ipsec,v 1.7 2002/03/22 04:33:58 thorpej Exp $ # $FreeBSD: src/etc/rc.d/ipsec,v 1.11.2.2 2006/01/31 00:28:01 pjd Exp $ # $MidnightBSD$ @@ -53,8 +52,6 @@ ipsec_reload() { echo "Reloading ipsec manual keys/policies." - ${ipsec_program} -F - ${ipsec_program} -FP ${ipsec_program} -f "$ipsec_file" } From laffer1 at midnightbsd.org Sat Jan 17 19:17:36 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:17:36 -0500 (EST) Subject: [Midnightbsd-cvs] src: ipfw: Change the way ipfw module is loaded. Message-ID: <200901180017.n0I0Ha40068954@stargazer.midnightbsd.org> Log Message: ----------- Change the way ipfw module is loaded. Modified Files: -------------- src/etc/rc.d: ipfw (r1.5 -> r1.6) -------------- next part -------------- Index: ipfw =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipfw,v retrieving revision 1.5 retrieving revision 1.6 diff -L etc/rc.d/ipfw -L etc/rc.d/ipfw -u -r1.5 -r1.6 --- etc/rc.d/ipfw +++ etc/rc.d/ipfw @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ipfw,v 1.10.2.1 2006/01/21 22:42:43 yar Exp $ +# $FreeBSD: src/etc/rc.d/ipfw,v 1.15 2007/04/02 15:38:53 mtm Exp $ # $MidnightBSD$ # PROVIDE: ipfw @@ -14,20 +14,8 @@ name="ipfw" rcvar="firewall_enable" start_cmd="ipfw_start" -start_precmd="ipfw_precmd" stop_cmd="ipfw_stop" - -ipfw_precmd() -{ - if ! ${SYSCTL} net.inet.ip.fw.enable > /dev/null 2>&1; then - if ! kldload ipfw; then - warn unable to load firewall module. - return 1 - fi - fi - - return 0 -} +required_modules="ipfw" ipfw_start() { From laffer1 at midnightbsd.org Sat Jan 17 19:36:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:36:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: rc.subr: Add kld loader functions and make several changes with Message-ID: <200901180036.n0I0ac7N070577@stargazer.midnightbsd.org> Log Message: ----------- Add kld loader functions and make several changes with mounting Modified Files: -------------- src/etc: rc.subr (r1.10 -> r1.11) -------------- next part -------------- Index: rc.subr =================================================================== RCS file: /home/cvs/src/etc/rc.subr,v retrieving revision 1.10 retrieving revision 1.11 diff -L etc/rc.subr -L etc/rc.subr -u -r1.10 -r1.11 --- etc/rc.subr +++ etc/rc.subr @@ -41,6 +41,7 @@ # : ${rcvar_manpage:='rc.conf(5)'} +: ${RC_PID:=$$}; export RC_PID # # Operating System dependent/independent variables @@ -55,7 +56,8 @@ CMD_OSTYPE="${SYSCTL_N} kern.ostype" OSTYPE=`${CMD_OSTYPE}` ID="/usr/bin/id" -JID=`ps -p $$ -o jid=` +PS="/bin/ps -ww" +JID=`$PS -p $$ -o jid=` IDCMD="if [ -x $ID ]; then $ID -un; fi" SYSCTL_W="${SYSCTL}" @@ -144,6 +146,27 @@ echo $_revlist } +# stop_boot always +# If booting directly to multiuser or $always is enabled, +# send SIGTERM to the parent (/etc/rc) to abort the boot. +# Otherwise just exit. +# +stop_boot() +{ + local always + + if [ -n "$1" ] && checkyesno $1; then + always=true + else + always=false + fi + if [ "$autoboot" = yes -o "$always" = true ]; then + echo "ERROR: ABORTING BOOT (sending SIGTERM to parent)!" + kill -TERM ${RC_PID} + fi + exit 1 +} + # # mount_critical_filesystems type # Go through the list of critical filesystems as provided in @@ -244,16 +267,30 @@ _pref= if [ $_interpreter != "." ]; then # an interpreted script - read _interp < $_procname # read interpreter name - _interp=${_interp#\#!} # strip #! - set -- $_interp - case $1 in - */bin/env) - shift #drop env to get real name - ;; - esac - if [ $_interpreter != $1 ]; then - warn "\$command_interpreter $_interpreter != $1" + _script=${_chroot}${_chroot:+"/"}$_procname + if [ -r $_script ]; then + read _interp < $_script # read interpreter name + case "$_interp" in + \#!*) + _interp=${_interp#\#!} # strip #! + set -- $_interp + case $1 in + */bin/env) + shift # drop env to get real name + ;; + esac + if [ $_interpreter != $1 ]; then + warn "\$command_interpreter $_interpreter != $1" + fi + ;; + *) + warn "no shebang line in $_script" + set -- $_interpreter + ;; + esac + else + warn "cannot read shebang line from $_script" + set -- $_interpreter fi _interp="$* $_procname" # cleanup spaces, add _procname _interpbn=${1##*/} @@ -267,13 +304,10 @@ $_procname|$_procnamebn|${_procnamebn}:|"(${_procnamebn})"|"[${_procnamebn}]")' fi - _proccheck=' - ps 2>/dev/null -o "pid,jid,command" '"$_psargs"' | + _proccheck="\ + $PS 2>/dev/null -o pid= -o jid= -o command= $_psargs"' | while read _npid _jid '"$_fp_args"'; do - case "$_npid" in - PID) - continue;; - esac; '"$_fp_match"' + '"$_fp_match"' if [ "$JID" -eq "$_jid" ]; then echo -n "$_pref$_npid"; _pref=" "; @@ -399,12 +433,25 @@ # returned a zero exit code. # # required_dirs n If set, check for the existence of the given -# directories before running the default -# (re)start command. +# directories before running a (re)start command. # # required_files n If set, check for the readability of the given -# files before running the default (re)start -# command. +# files before running a (re)start command. +# +# required_modules n If set, ensure the given kernel modules are +# loaded before running a (re)start command. +# The check and possible loads are actually +# done after start_precmd so that the modules +# aren't loaded in vain, should the precmd +# return a non-zero status to indicate a error. +# If a word in the list looks like "foo:bar", +# "foo" is the KLD file name and "bar" is the +# module name. If a word looks like "foo~bar", +# "foo" is the KLD file name and "bar" is a +# egrep(1) pattern matching the module name. +# Otherwise the module name is assumed to be +# the same as the KLD file name, which is most +# common. See load_kld(). # # required_vars n If set, perform checkyesno on each of the # listed variables before running the default @@ -553,49 +600,31 @@ if [ "$_elem" != "$rc_arg" ]; then continue fi - # if there's a custom ${XXX_cmd}, # run that instead of the default # - eval _cmd=\$${rc_arg}_cmd _precmd=\$${rc_arg}_precmd \ - _postcmd=\$${rc_arg}_postcmd + eval _cmd=\$${rc_arg}_cmd \ + _precmd=\$${rc_arg}_precmd \ + _postcmd=\$${rc_arg}_postcmd + if [ -n "$_cmd" ]; then - # if the precmd failed and force - # isn't set, exit - # - if [ -n "$_precmd" ]; then - debug "run_rc_command: evaluating ${_precmd}()." - eval $_precmd $rc_extra_args - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi - - if [ -n "$_cmd" ]; then - debug "run_rc_command: evaluating ${_cmd}()." - eval $_cmd $rc_extra_args - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi - - if [ -n "$_postcmd" ]; then - debug "run_rc_command: evaluating ${_postcmd}()." - eval $_postcmd $rc_extra_args - _return=$? - fi + _run_rc_precmd || return 1 + _run_rc_doit "$_cmd $rc_extra_args" || return 1 + _run_rc_postcmd return $_return fi case "$rc_arg" in # default operations... status) + _run_rc_precmd || return 1 if [ -n "$rc_pid" ]; then echo "${name} is running as pid $rc_pid." else echo "${name} is not running." return 1 fi + _run_rc_postcmd ;; start) @@ -604,51 +633,14 @@ return 1 fi - if [ ! -x ${_chroot}${command} ]; then - info "run_rc_command: cannot run ($command)." + if [ ! -x ${_chroot}${_chroot:+"/"}${command} ]; then + warn "run_rc_command: cannot run $command" return 1 fi - # check for required variables, - # directories, and files - # - for _f in $required_vars; do - if ! checkyesno $_f; then - warn "\$${_f} is not enabled." - if [ -z "$rc_force" ]; then - return 1 - fi - fi - done - for _f in $required_dirs; do - if [ ! -d "${_f}/." ]; then - warn "${_f} is not a directory." - if [ -z "$rc_force" ]; then - return 1 - fi - fi - done - for _f in $required_files; do - if [ ! -r "${_f}" ]; then - warn "${_f} is not readable." - if [ -z "$rc_force" ]; then - return 1 - fi - fi - done - - # if the precmd failed and force - # isn't set, exit - # - if [ -n "${_precmd}" ]; then - debug "run_rc_command: evaluating ${_precmd}()." - eval $_precmd - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi + _run_rc_precmd || return 1 - # setup the command to run, and run it + # setup the full command to run # echo "Starting ${name}." if [ -n "$_chroot" ]; then @@ -671,105 +663,52 @@ fi fi - # if the cmd failed and force - # isn't set, exit + # run the full command # - debug "run_rc_command: _doit: $_doit" - eval $_doit - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 + _run_rc_doit "$_doit" || return 1 # finally, run postcmd # - if [ -n "${_postcmd}" ]; then - debug "run_rc_command: evaluating ${_postcmd}()." - eval $_postcmd - fi + _run_rc_postcmd ;; stop) if [ -z "$rc_pid" ]; then [ -n "$rc_fast" ] && return 0 - if [ -n "$pidfile" ]; then - echo 1>&2 \ - "${name} not running? (check $pidfile)." - else - echo 1>&2 "${name} not running?" - fi + _run_rc_notrunning return 1 fi - # if the precmd failed and force - # isn't set, exit - # - if [ -n "$_precmd" ]; then - eval $_precmd - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi + _run_rc_precmd || return 1 # send the signal to stop # echo "Stopping ${name}." - _doit="kill -${sig_stop:-TERM} $rc_pid" - if [ -n "$_user" ]; then - _doit="su -m $_user -c 'sh -c \"$_doit\"'" - fi - - # if the stop cmd failed and force - # isn't set, exit - # - eval $_doit - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 + _doit=$(_run_rc_killcmd "${sig_stop:-TERM}") + _run_rc_doit "$_doit" || return 1 # wait for the command to exit, # and run postcmd. wait_for_pids $rc_pid - if [ -n "$_postcmd" ]; then - eval $_postcmd - _return=$? - fi + + _run_rc_postcmd ;; reload) if [ -z "$rc_pid" ]; then - if [ -n "$pidfile" ]; then - echo 1>&2 \ - "${name} not running? (check $pidfile)." - else - echo 1>&2 "${name} not running?" - fi + _run_rc_notrunning return 1 fi - echo "Reloading ${name} config files." - if [ -n "$_precmd" ]; then - eval $_precmd - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi - _doit="kill -${sig_reload:-HUP} $rc_pid" - if [ -n "$_user" ]; then - _doit="su -m $_user -c 'sh -c \"$_doit\"'" - fi - eval $_doit - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 - if [ -n "$_postcmd" ]; then - eval $_postcmd - _return=$? - fi + + _run_rc_precmd || return 1 + + _doit=$(_run_rc_killcmd "${sig_reload:-HUP}") + _run_rc_doit "$_doit" || return 1 + + _run_rc_postcmd ;; restart) - if [ -n "$_precmd" ]; then - eval $_precmd $rc_extra_args - _return=$? - [ $_return -ne 0 ] && [ -z "$rc_force" ] && - return 1 - fi # prevent restart being called more # than once by any given script # @@ -778,29 +717,32 @@ fi _rc_restart_done=true - # run stop in a subshell to keep variables for start + _run_rc_precmd || return 1 + + # run those in a subshell to keep global variables ( run_rc_command ${_rc_prefix}stop $rc_extra_args ) - run_rc_command ${_rc_prefix}start $rc_extra_args + ( run_rc_command ${_rc_prefix}start $rc_extra_args ) + _return=$? + [ $_return -ne 0 ] && [ -z "$rc_force" ] && return 1 - if [ -n "$_postcmd" ]; then - eval $_postcmd $rc_extra_args - _return=$? - fi + _run_rc_postcmd ;; poll) + _run_rc_precmd || return 1 if [ -n "$rc_pid" ]; then wait_for_pids $rc_pid fi + _run_rc_postcmd ;; rcvar) echo "# $name" if [ -n "$rcvar" ]; then if checkyesno ${rcvar}; then - echo "\$${rcvar}=YES" + echo "${rcvar}=YES" else - echo "\$${rcvar}=NO" + echo "${rcvar}=NO" fi fi ;; @@ -819,6 +761,83 @@ } # +# Helper functions for run_rc_command: common code. +# They use such global variables besides the exported rc_* ones: +# +# name R/W +# ------------------ +# _precmd R +# _postcmd R +# _return W +# +_run_rc_precmd() +{ + check_required_before "$rc_arg" || return 1 + + if [ -n "$_precmd" ]; then + debug "run_rc_command: ${rc_arg}_precmd: $_precmd $rc_extra_args" + eval "$_precmd $rc_extra_args" + _return=$? + + # If precmd failed and force isn't set, request exit. + if [ $_return -ne 0 ] && [ -z "$rc_force" ]; then + return 1 + fi + fi + + check_required_after "$rc_arg" || return 1 + + return 0 +} + +_run_rc_postcmd() +{ + if [ -n "$_postcmd" ]; then + debug "run_rc_command: ${rc_arg}_postcmd: $_postcmd $rc_extra_args" + eval "$_postcmd $rc_extra_args" + _return=$? + fi + return 0 +} + +_run_rc_doit() +{ + debug "run_rc_command: doit: $*" + eval "$@" + _return=$? + + # If command failed and force isn't set, request exit. + if [ $_return -ne 0 ] && [ -z "$rc_force" ]; then + return 1 + fi + + return 0 +} + +_run_rc_notrunning() +{ + local _pidmsg + + if [ -n "$pidfile" ]; then + _pidmsg=" (check $pidfile)." + else + _pidmsg= + fi + echo 1>&2 "${name} not running?${_pidmsg}" +} + +_run_rc_killcmd() +{ + local _cmd + + _cmd="kill -$1 $rc_pid" + if [ -n "$_user" ]; then + _cmd="su -m ${_user} -c 'sh -c \"${_cmd}\"'" + fi + echo "$_cmd" +} + +# # run_rc_script file arg # Start the script `file' with `arg', and correctly handle the # return value from the script. If `file' ends with `.sh', it's @@ -1094,7 +1113,7 @@ return 1 fi if [ ! -d "$linkdir" ]; then - warn "$_me: the directory $linkdir does not exist" + warn "$_me: the directory $linkdir does not exist." return 1 fi if ! ln -sf $src $link; then @@ -1309,6 +1328,53 @@ /sbin/mdmfs $flags -s $1 md $2 } +# Code common to scripts that need to load a kernel module +# if it isn't in the kernel yet. Syntax: +# load_kld [-e regex] [-m module] file +# where -e or -m chooses the way to check if the module +# is already loaded: +# regex is egrep'd in the output from `kldstat -v', +# module is passed to `kldstat -m'. +# The default way is as though `-m file' were specified. +load_kld() +{ + local _loaded _mod _opt _re + + while getopts "e:m:" _opt; do + case "$_opt" in + e) _re="$OPTARG" ;; + m) _mod="$OPTARG" ;; + *) err 3 'USAGE: load_kld [-e regex] [-m module] file' ;; + esac + done + shift $(($OPTIND - 1)) + if [ $# -ne 1 ]; then + err 3 'USAGE: load_kld [-e regex] [-m module] file' + fi + _mod=${_mod:-$1} + _loaded=false + if [ -n "$_re" ]; then + if kldstat -v | egrep -q -e "$_re"; then + _loaded=true + fi + else + if kldstat -q -m "$_mod"; then + _loaded=true + fi + fi + if ! $_loaded; then + if ! kldload "$1"; then + warn "Unable to load kernel module $1" + return 1 + else + info "$1 kernel module loaded." + fi + else + debug "load_kld: $1 kernel module already loaded." + fi + return 0 +} + # ltr str src dst # Change every $src in $str to $dst. # Useful when /usr is not yet mounted and we cannot use tr(1), sed(1) nor @@ -1413,6 +1479,74 @@ done } +# check_required_{before|after} command +# Check for things required by the command before and after its precmd, +# respectively. The two separate functions are needed because some +# conditions should prevent precmd from being run while other things +# depend on precmd having already been run. +# +check_required_before() +{ + local _f + + case "$1" in + start) + for _f in $required_vars; do + if ! checkyesno $_f; then + warn "\$${_f} is not enabled." + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + + for _f in $required_dirs; do + if [ ! -d "${_f}/." ]; then + warn "${_f} is not a directory." + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + + for _f in $required_files; do + if [ ! -r "${_f}" ]; then + warn "${_f} is not readable." + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + ;; + esac + + return 0 +} + +check_required_after() +{ + local _f _args + + case "$1" in + start) + for _f in $required_modules; do + case "${_f}" in + *~*) _args="-e ${_f#*~} ${_f%%~*}" ;; + *:*) _args="-m ${_f#*:} ${_f%%:*}" ;; + *) _args="${_f}" ;; + esac + if ! load_kld ${_args}; then + if [ -z "$rc_force" ]; then + return 1 + fi + fi + done + ;; + esac + + return 0 +} + fi _rc_subr_loaded=: From laffer1 at midnightbsd.org Sat Jan 17 19:52:21 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 19:52:21 -0500 (EST) Subject: [Midnightbsd-cvs] src: modules/ndis: Message-ID: <200901180052.n0I0qLQM071817@stargazer.midnightbsd.org> Log Message: ----------- Modified Files: -------------- src/sys/modules/if_ndis: Makefile (r1.1.1.1 -> r1.2) src/sys/modules/ndis: Makefile (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/if_ndis/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/modules/if_ndis/Makefile -L sys/modules/if_ndis/Makefile -u -r1.1.1.1 -r1.2 --- sys/modules/if_ndis/Makefile +++ sys/modules/if_ndis/Makefile @@ -1,10 +1,10 @@ -# $FreeBSD: src/sys/modules/if_ndis/Makefile,v 1.5 2005/04/24 20:21:22 wpaul Exp $ +# $FreeBSD: src/sys/modules/if_ndis/Makefile,v 1.6 2005/09/27 18:10:35 mlaier Exp $ .PATH: ${.CURDIR}/../../dev/if_ndis KMOD= if_ndis SRCS= if_ndis.c if_ndis_pci.c if_ndis_pccard.c if_ndis_usb.c -SRCS+= opt_bdg.h device_if.h bus_if.h pci_if.h card_if.h pccarddevs.h +SRCS+= device_if.h bus_if.h pci_if.h card_if.h pccarddevs.h SRCS+= opt_usb.h usbdevs.h .include Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/ndis/Makefile,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/modules/ndis/Makefile -L sys/modules/ndis/Makefile -u -r1.1.1.1 -r1.2 --- sys/modules/ndis/Makefile +++ sys/modules/ndis/Makefile @@ -1,11 +1,11 @@ -# $FreeBSD: src/sys/modules/ndis/Makefile,v 1.10 2005/04/11 02:02:35 wpaul Exp $ +# $FreeBSD: src/sys/modules/ndis/Makefile,v 1.11 2005/09/27 18:10:36 mlaier Exp $ .PATH: ${.CURDIR}/../../compat/ndis KMOD= ndis SRCS= subr_pe.c subr_ndis.c subr_hal.c subr_ntoskrnl.c kern_ndis.c SRCS+= kern_windrv.c subr_usbd.c -SRCS+= opt_bdg.h device_if.h bus_if.h pci_if.h vnode_if.h +SRCS+= device_if.h bus_if.h pci_if.h vnode_if.h .if ${MACHINE_ARCH} == "amd64" SRCS+= winx64_wrap.S From laffer1 at midnightbsd.org Sat Jan 17 20:07:56 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 20:07:56 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: merge rc changes Message-ID: <200901180107.n0I17uqJ073168@stargazer.midnightbsd.org> Log Message: ----------- merge rc changes Modified Files: -------------- src/etc/rc.d: abi (r1.6 -> r1.7) accounting (r1.2 -> r1.3) amd (r1.5 -> r1.6) archdep (r1.3 -> r1.4) atm1 (r1.2 -> r1.3) bluetooth (r1.2 -> r1.3) cleanvar (r1.2 -> r1.3) dmesg (r1.2 -> r1.3) geli (r1.2 -> r1.3) hcsecd (r1.2 -> r1.3) hostname (r1.3 -> r1.4) ip6addrctl (r1.3 -> r1.4) ip6fw (r1.3 -> r1.4) Removed Files: ------------- src/etc/rc.d: bootconf.sh -------------- next part -------------- Index: dmesg =================================================================== RCS file: /home/cvs/src/etc/rc.d/dmesg,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/dmesg -L etc/rc.d/dmesg -u -r1.2 -r1.3 --- etc/rc.d/dmesg +++ etc/rc.d/dmesg @@ -7,7 +7,7 @@ # PROVIDE: dmesg # REQUIRE: mountcritremote cleanvar # BEFORE: DAEMON -# KEYWORD: Daemon nojail +# KEYWORD: nojail . /etc/rc.subr Index: abi =================================================================== RCS file: /home/cvs/src/etc/rc.d/abi,v retrieving revision 1.6 retrieving revision 1.7 diff -L etc/rc.d/abi -L etc/rc.d/abi -u -r1.6 -r1.7 --- etc/rc.d/abi +++ etc/rc.d/abi @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/abi,v 1.4.2.1 2006/01/17 06:37:48 dougb Exp $ +# $FreeBSD: src/etc/rc.d/abi,v 1.11 2006/12/30 22:53:19 yar Exp $ # $MidnightBSD$ # PROVIDE: abi @@ -16,21 +16,21 @@ sysv_start() { echo -n ' sysvipc' - kldload sysvmsg >/dev/null 2>&1 - kldload sysvsem >/dev/null 2>&1 - kldload sysvshm >/dev/null 2>&1 + load_kld sysvmsg + load_kld sysvsem + load_kld sysvshm } linux_start() { + local _tmpdir + echo -n ' linux' - if ! kldstat -v | grep -E 'linux(aout|elf)' > /dev/null; then - kldload linux > /dev/null 2>&1 - fi - if [ -x /compat/linux/sbin/ldconfig ]; then + load_kld -e 'linux(aout|elf)' linux + if [ -x /compat/linux/sbin/ldconfigDisabled ]; then _tmpdir=`mktemp -d -t linux-ldconfig` /compat/linux/sbin/ldconfig -C ${_tmpdir}/ld.so.cache - if ! cmp -s ${_tmpdir}/ld.so.cache /compat/linux/etc/ld.so.cache; then + if ! cmp -s ${_tmpdir}/ld.so.cache /compat/linux/etc/ld.so.cache; then cat ${_tmpdir}/ld.so.cache > /compat/linux/etc/ld.so.cache fi rm -rf ${_tmpdir} @@ -40,7 +40,7 @@ svr4_start() { echo -n ' svr4' - kldload svr4 > /dev/null 2>&1 + load_kld -m svr4elf svr4 } abi_start() Index: hostname =================================================================== RCS file: /home/cvs/src/etc/rc.d/hostname,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/hostname -L etc/rc.d/hostname -u -r1.3 -r1.4 --- etc/rc.d/hostname +++ etc/rc.d/hostname @@ -23,7 +23,7 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.d/hostname,v 1.8 2004/10/07 13:55:25 mtm Exp $ +# $FreeBSD: src/etc/rc.d/hostname,v 1.12 2007/04/02 22:53:07 des Exp $ # $MidnightBSD$ # PROVIDE: hostname @@ -31,6 +31,7 @@ # BEFORE: netif . /etc/rc.subr +. /etc/network.subr name="hostname" start_cmd="hostname_start" @@ -58,8 +59,21 @@ fi fi - /bin/hostname ${hostname} - echo "Setting hostname: `hostname`." + # Have we got a hostname yet? + # + if [ -z "${hostname}" ]; then + # Null hostname is probably OK if DHCP is in use. + # + if [ -z "`list_net_interfaces dhcp`" ]; then + warn "\$hostname is not set -- see ${rcvar_manpage}." + fi + return + fi + + # All right, it is safe to invoke hostname(1) now. + # + echo "Setting hostname: ${hostname}." + /bin/hostname "${hostname}" } load_rc_config $name Index: cleanvar =================================================================== RCS file: /home/cvs/src/etc/rc.d/cleanvar,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/cleanvar -L etc/rc.d/cleanvar -u -r1.2 -r1.3 --- etc/rc.d/cleanvar +++ etc/rc.d/cleanvar @@ -4,7 +4,7 @@ # $MidnightBSD$ # PROVIDE: cleanvar -# REQUIRE: mountcritlocal var +# REQUIRE: FILESYSTEMS var . /etc/rc.subr @@ -59,7 +59,7 @@ if [ -d /var/run -a ! -f /var/run/clean_var ]; then purgedir /var/run # And an initial utmp file - (cd /var/run && cp /dev/null utmp && chmod 644 utmp;) + (cd /var/run && cp /dev/null utmp && chmod 644 utmp) >/var/run/clean_var fi if [ -d /var/spool/lock -a ! -f /var/spool/lock/clean_var ]; then Index: hcsecd =================================================================== RCS file: /home/cvs/src/etc/rc.d/hcsecd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/hcsecd -L etc/rc.d/hcsecd -u -r1.2 -r1.3 --- etc/rc.d/hcsecd +++ etc/rc.d/hcsecd @@ -1,7 +1,8 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/hcsecd,v 1.4.2.1 2005/11/23 18:03:33 emax Exp $ # $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/hcsecd,v 1.5 2006/12/31 10:37:18 yar Exp $ +# # PROVIDE: hcsecd # REQUIRE: DAEMON @@ -14,21 +15,7 @@ command="/usr/sbin/${name}" pidfile="/var/run/${name}.pid" rcvar=`set_rcvar` -start_precmd="hcsecd_prestart" - -hcsecd_prestart() -{ - if ! kldstat -q -m ng_btsocket ; then - if kldload ng_btsocket > /dev/null 2>&1 ; then - info 'ng_btsocket module loaded' - else - warn 'ng_btsocket module failed to load' - return 1 - fi - fi - - return 0 -} +required_modules="ng_btsocket" load_rc_config $name config="${hcsecd_config:-/etc/bluetooth/${name}.conf}" Index: atm1 =================================================================== RCS file: /home/cvs/src/etc/rc.d/atm1,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/atm1 -L etc/rc.d/atm1 -u -r1.2 -r1.3 --- etc/rc.d/atm1 +++ etc/rc.d/atm1 @@ -24,9 +24,8 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # +# $FreeBSD: src/etc/rc.d/atm1,v 1.16 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/atm1,v 1.15 2004/10/07 13:55:25 mtm Exp $ -# # PROVIDE: atm1 # REQUIRE: root @@ -49,7 +48,7 @@ { if [ -n "${natm_interfaces}" ] ; then # Load the HARP pseudo interface - kldstat -v | grep -q if_harp || kldload if_harp + load_kld if_harp || return 1 # Load all the NATM drivers that we need for natm in ${natm_interfaces} ; do @@ -59,7 +58,7 @@ # Load loadable HARP drivers for dev in ${atm_load} ; do - kldstat -v | grep -q ${dev} || kldload ${dev} + load_kld ${dev} || return 1 done # Locate all probed ATM adapters Index: ip6addrctl =================================================================== RCS file: /home/cvs/src/etc/rc.d/ip6addrctl,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ip6addrctl -L etc/rc.d/ip6addrctl -u -r1.3 -r1.4 --- etc/rc.d/ip6addrctl +++ etc/rc.d/ip6addrctl @@ -4,7 +4,7 @@ # $MidnightBSD$ # PROVIDE: ip6addrctl -# REQUIRE: FILESYSTEMS netif +# REQUIRE: FILESYSTEMS netif # BEFORE: network_ipv6 # KEYWORD: nojail Index: archdep =================================================================== RCS file: /home/cvs/src/etc/rc.d/archdep,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/archdep -L etc/rc.d/archdep -u -r1.3 -r1.4 --- etc/rc.d/archdep +++ etc/rc.d/archdep @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/archdep,v 1.7.2.2 2006/01/17 07:12:38 dougb Exp $ +# $FreeBSD: src/etc/rc.d/archdep,v 1.14 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: archdep @@ -19,13 +19,13 @@ { if checkyesno ibcs2_enable; then echo -n ' ibcs2' - kldload ibcs2 > /dev/null 2>&1 + load_kld ibcs2 case ${ibcs2_loaders} in [Nn][Oo]) ;; *) for i in ${ibcs2_loaders}; do - kldload ibcs2_$i > /dev/null 2>&1 + load_kld ibcs2_$i done ;; esac @@ -34,6 +34,8 @@ archdep_start() { + local _arch + _arch=`${SYSCTL_N} hw.machine_arch` echo -n "Initial $_arch initialization:" case $_arch in Index: amd =================================================================== RCS file: /home/cvs/src/etc/rc.d/amd,v retrieving revision 1.5 retrieving revision 1.6 diff -L etc/rc.d/amd -L etc/rc.d/amd -u -r1.5 -r1.6 --- etc/rc.d/amd +++ etc/rc.d/amd @@ -47,7 +47,7 @@ ;; *) rc_flags="-p ${rc_flags}" - command_args=" > /var/run/amd.pid 2> /dev/null" + command_args="> /var/run/amd.pid 2> /dev/null" ;; esac return 0 Index: accounting =================================================================== RCS file: /home/cvs/src/etc/rc.d/accounting,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/accounting -L etc/rc.d/accounting -u -r1.2 -r1.3 --- etc/rc.d/accounting +++ etc/rc.d/accounting @@ -20,6 +20,8 @@ accounting_start() { + local _dir + _dir=`dirname "$accounting_file"` if [ ! -d `dirname "$_dir"` ]; then if ! mkdir -p "$_dir"; then Index: ip6fw =================================================================== RCS file: /home/cvs/src/etc/rc.d/ip6fw,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ip6fw -L etc/rc.d/ip6fw -u -r1.3 -r1.4 --- etc/rc.d/ip6fw +++ etc/rc.d/ip6fw @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/ip6fw,v 1.6 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/ip6fw,v 1.9 2007/04/02 15:38:53 mtm Exp $ # $MidnightBSD$ # PROVIDE: ip6fw @@ -13,21 +13,8 @@ name="ip6fw" rcvar=`set_rcvar ipv6_firewall` start_cmd="ip6fw_start" -start_precmd="ip6fw_prestart" stop_cmd="${SYSCTL_W} net.inet6.ip6.fw.enable=0" - -ip6fw_prestart() -{ - # Load IPv6 firewall module, if not already loaded - if ! ${SYSCTL} net.inet6.ip6.fw.enable > /dev/null 2>&1; then - kldload ip6fw && { - debug 'Kernel IPv6 firewall module loaded.' - return 0 - } - warn 'IPv6 firewall kernel module failed to load.' - return 1 - fi -} +required_modules="ipfw" ip6fw_start() { @@ -41,7 +28,7 @@ if [ -r "${ipv6_firewall_script}" ]; then /bin/sh "${ipv6_firewall_script}" echo 'IPv6 Firewall rules loaded.' - elif [ "`ip6fw l 65535`" = "65535 deny ipv6 from any to any" ]; then + elif [ "`ipfw show 65535`" = "65535 deny ip from any to any" ]; then warn 'IPv6 firewall rules have not been loaded. Default' \ ' to DENY all access.' fi @@ -50,7 +37,7 @@ # if checkyesno ipv6_firewall_logging; then echo 'IPv6 Firewall logging=YES' - sysctl net.inet6.ip6.fw.verbose=1 >/dev/null + sysctl net.inet.ip.fw.verbose=1 >/dev/null fi # Enable the firewall Index: geli =================================================================== RCS file: /home/cvs/src/etc/rc.d/geli,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/geli -L etc/rc.d/geli -u -r1.2 -r1.3 --- etc/rc.d/geli +++ etc/rc.d/geli @@ -24,8 +24,9 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.d/geli,v 1.2.2.2 2005/12/15 23:32:35 pjd Exp $ # $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/geli,v 1.4 2006/12/31 10:37:18 yar Exp $ +# # PROVIDE: disks # REQUIRE: initrandom @@ -34,20 +35,15 @@ . /etc/rc.subr name="geli" +start_precmd='[ -n "$(geli_make_list)" ]' start_cmd="geli_start" stop_cmd="geli_stop" +required_modules="geom_eli:g_eli" geli_start() { devices=`geli_make_list` - # If there are no devices return before loading geom_eli.ko. - if [ -z "${devices}" ]; then - return - fi - - kldstat -q -m g_eli || geli load || err 1 'geom_eli module failed to load.' - if [ -z "${geli_tries}" ]; then if [ -n "${geli_attach_attempts}" ]; then # Compatibility with rc.d/gbde. Index: bluetooth =================================================================== RCS file: /home/cvs/src/etc/rc.d/bluetooth,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/bluetooth -L etc/rc.d/bluetooth -u -r1.2 -r1.3 --- etc/rc.d/bluetooth +++ etc/rc.d/bluetooth @@ -24,8 +24,8 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/bluetooth,v 1.1.2.1 2005/11/23 18:03:33 emax Exp $ +# $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/bluetooth,v 1.3 2006/12/31 10:37:18 yar Exp $ # PROVIDE: bluetooth # REQUIRE: DAEMON @@ -37,6 +37,7 @@ rcvar= start_cmd="bluetooth_start" stop_cmd="bluetooth_stop" +required_modules="ng_bluetooth ng_hci ng_l2cap ng_btsocket" ############################################################################## # Read and parse Bluetooth device configuration file @@ -44,6 +45,8 @@ bluetooth_read_conf() { + local _err _file _line _namespace + _file=$1 _namespace=$2 _err=0 @@ -226,19 +229,15 @@ bluetooth_start() { - dev=$1 + local _file - # Automatically load modules - kldload ng_bluetooth > /dev/null 2>&1 - kldload ng_hci > /dev/null 2>&1 - kldload ng_l2cap > /dev/null 2>&1 - kldload ng_btsocket > /dev/null 2>&1 + dev=$1 # Try to figure out device type by looking at device name case "${dev}" in # sioX - serial/UART Bluetooth device sio*) - kldload ng_h4 > /dev/null 2>&1 + load_kld ng_h4 || return 1 hook="hook" --- etc/rc.d/bootconf.sh +++ /dev/null @@ -1,82 +0,0 @@ -#!/bin/sh -# -# $NetBSD: bootconf.sh,v 1.5 2002/03/25 03:22:10 wiz Exp $ -# $FreeBSD: src/etc/rc.d/bootconf.sh,v 1.4 2002/10/12 10:31:31 schweikh Exp $ -# $MidnightBSD: src/etc/rc.d/bootconf.sh,v 1.3 2007/10/26 14:12:39 laffer1 Exp $ - -# PROVIDE: bootconf -# REQUIRE: FILESYSTEMS - -bootconf_start() -{ - # Refer to newbtconf(8) for more information - # - - if [ ! -e /etc/etc.current ]; then - return 0 - fi - if [ -L /etc/etc.default ]; then - def=`ls -ld /etc/etc.default 2>&1` - default="${def##*-> etc.}" - else - default=current - fi - if [ "$default" = "current" ]; then - def=`ls -ld /etc/etc.current 2>&1` - default="${def##*-> etc.}" - fi - - spc="" - for i in /etc/etc.*; do - name="${i##/etc/etc.}" - case $name in - current|default|\*) - continue - ;; - *) - if [ "$name" = "$default" ]; then - echo -n "${spc}[${name}]" - else - echo -n "${spc}${name}" - fi - spc=" " - ;; - esac - done - echo - master=$$ - _DUMMY=/etc/passwd - conf=${_DUMMY} - while [ ! -d /etc/etc.$conf/. ]; do - trap "conf=$default; echo; echo Using default of $conf" ALRM - echo -n "Which configuration [$default] ? " - (sleep 30 && kill -ALRM $master) >/dev/null 2>&1 & - read conf - trap : ALRM - if [ -z $conf ]; then - conf=$default - fi - if [ ! -d /etc/etc.$conf/. ]; then - conf=${_DUMMY} - fi - done - - case $conf in - current|default) - ;; - *) - rm -f /etc/etc.current - ln -s /etc/etc.$conf /etc/etc.current - ;; - esac - - if [ -f /etc/rc.conf ]; then - . /etc/rc.conf - fi -} - -case "$1" in -*start) - bootconf_start - ;; -esac From laffer1 at midnightbsd.org Sat Jan 17 20:19:30 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sat, 17 Jan 2009 20:19:30 -0500 (EST) Subject: [Midnightbsd-cvs] src: etc/rc.d: merge rc changes Message-ID: <200901180119.n0I1JUgj074003@stargazer.midnightbsd.org> Log Message: ----------- merge rc changes Modified Files: -------------- src/etc/rc.d: ipfilter (r1.3 -> r1.4) isdnd (r1.4 -> r1.5) jail (r1.5 -> r1.6) kerberos (r1.2 -> r1.3) ldconfig (r1.2 -> r1.3) localpkg (r1.2 -> r1.3) lpd (r1.2 -> r1.3) natd (r1.2 -> r1.3) nfsclient (r1.2 -> r1.3) nfsserver (r1.2 -> r1.3) nsswitch (r1.3 -> r1.4) powerd (r1.3 -> r1.4) -------------- next part -------------- Index: kerberos =================================================================== RCS file: /home/cvs/src/etc/rc.d/kerberos,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/kerberos -L etc/rc.d/kerberos -u -r1.2 -r1.3 --- etc/rc.d/kerberos +++ etc/rc.d/kerberos @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/kerberos,v 1.4.2.1 2005/09/25 18:45:56 rwatson Exp $ +# $FreeBSD: src/etc/rc.d/kerberos,v 1.6.4.2 2008/01/29 07:15:46 mtm Exp $ # $MidnightBSD$ # PROVIDE: kerberos @@ -9,9 +9,9 @@ . /etc/rc.subr name="kerberos5" -load_rc_config $name rcvar="kerberos5_server_enable" -command="${kerberos5_server}" -command_args="${kerberos5_server_flags} &" +load_rc_config $name +command="${kerberos5_server}" +kerberos5_flags="${kerberos5_server_flags}" run_rc_command "$1" Index: isdnd =================================================================== RCS file: /home/cvs/src/etc/rc.d/isdnd,v retrieving revision 1.4 retrieving revision 1.5 diff -L etc/rc.d/isdnd -L etc/rc.d/isdnd -u -r1.4 -r1.5 --- etc/rc.d/isdnd +++ etc/rc.d/isdnd @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: isdnd,v 1.9 2002/04/10 23:37:13 martin Exp $ -# $FreeBSD: src/etc/rc.d/isdnd,v 1.20 2005/01/16 03:12:03 obrien Exp $ +# $FreeBSD: src/etc/rc.d/isdnd,v 1.23.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # # Mostly based on original script (/etc/rc.isdn) written by Hellmuth Michaelis @@ -23,16 +22,6 @@ { echo -n 'ISDN subsystem setup:' - # Check for pcvt driver (VT100/VT220 emulator) - # - if [ -x /usr/sbin/ispcvt ]; then - if /usr/sbin/ispcvt; then - # No vidcontrol if we are using pcvt - # - isdn_screenflags=NO - fi - fi - # Start isdnd # echo -n ' isdnd' Index: nfsclient =================================================================== RCS file: /home/cvs/src/etc/rc.d/nfsclient,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/nfsclient -L etc/rc.d/nfsclient -u -r1.2 -r1.3 --- etc/rc.d/nfsclient +++ etc/rc.d/nfsclient @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/nfsclient,v 1.5 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/nfsclient,v 1.6 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: nfsclient @@ -12,20 +12,8 @@ name="nfsclient" rcvar="nfs_client_enable" start_cmd="nfsclient_start" -start_precmd="nfsclient_precmd" stop_cmd="unmount_all" - -# Load nfs module if it was not compiled into the kernel -nfsclient_precmd() -{ - if ! sysctl vfs.nfs >/dev/null 2>&1; then - if ! kldload nfsclient; then - warn 'Could not load nfs client module' - return 1 - fi - fi - return 0 -} +required_modules="nfsclient:nfs" nfsclient_start() { Index: lpd =================================================================== RCS file: /home/cvs/src/etc/rc.d/lpd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/lpd -L etc/rc.d/lpd -u -r1.2 -r1.3 --- etc/rc.d/lpd +++ etc/rc.d/lpd @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: lpd,v 1.5 2002/03/22 04:33:59 thorpej Exp $ -# $FreeBSD: src/etc/rc.d/lpd,v 1.7 2005/03/02 02:46:47 brooks Exp $ +# $FreeBSD: src/etc/rc.d/lpd,v 1.8.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: lpd @@ -14,9 +13,9 @@ rcvar=`set_rcvar` command="/usr/sbin/${name}" required_files="/etc/printcap" -start_precmd="_chkprintcap" +start_precmd="chkprintcap" -_chkprintcap() +chkprintcap() { if checkyesno chkprintcap_enable ; then /usr/sbin/chkprintcap ${chkprintcap_flags} Index: ldconfig =================================================================== RCS file: /home/cvs/src/etc/rc.d/ldconfig,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/ldconfig -L etc/rc.d/ldconfig -u -r1.2 -r1.3 --- etc/rc.d/ldconfig +++ etc/rc.d/ldconfig @@ -1,8 +1,7 @@ #!/bin/sh # -# $NetBSD: ldconfig,v 1.5 2002/03/22 04:33:58 thorpej Exp $ -# $FreeBSD: src/etc/rc.d/ldconfig,v 1.14.2.1 2006/01/17 06:53:17 dougb Exp $ -# $MidnightBSD$ +# $FreeBSD: src/etc/rc.d/ldconfig,v 1.17.2.1.2.1 2008/01/28 07:58:31 dougb Exp $ +# $MidnightBSD$ # PROVIDE: ldconfig # REQUIRE: mountcritremote cleanvar @@ -17,6 +16,8 @@ ldconfig_start() { + local _files _ins + _ins= ldconfig=${ldconfig_command} checkyesno ldconfig_insecure && _ins="-i" @@ -24,7 +25,10 @@ _LDC="/lib /usr/lib" for i in ${ldconfig_local_dirs}; do if [ -d "${i}" ]; then - ldconfig_paths="${ldconfig_paths} `find ${i} -type f`" + _files=`find ${i} -type f` + if [ -n "${_files}" ]; then + ldconfig_paths="${ldconfig_paths} `cat ${_files} | sort -u`" + fi fi done for i in ${ldconfig_paths} /etc/ld-elf.so.conf; do @@ -39,11 +43,20 @@ amd64) for i in ${ldconfig_local32_dirs}; do if [ -d "${i}" ]; then - ldconfig32_paths="${ldconfig32_paths} `find ${i} -type f`" + _files=`find ${i} -type f` + if [ -n "${_files}" ]; then + ldconfig32_paths="${ldconfig32_paths} `cat ${_files} | sort -u`" + fi + fi + done + _LDC="" + for i in ${ldconfig32_paths}; do + if [ -r "${i}" ]; then + _LDC="${_LDC} ${i}" fi done - echo '32-bit compatibility ldconfig path:' ${ldconfig32_paths} - ${ldconfig} -32 -m ${_ins} ${ldconfig32_paths} + echo '32-bit compatibility ldconfig path:' ${_LDC} + ${ldconfig} -32 -m ${_ins} ${_LDC} ;; esac Index: natd =================================================================== RCS file: /home/cvs/src/etc/rc.d/natd,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/natd -L etc/rc.d/natd -u -r1.2 -r1.3 --- etc/rc.d/natd +++ etc/rc.d/natd @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/natd,v 1.3 2004/10/22 19:36:03 andre Exp $ +# $FreeBSD: src/etc/rc.d/natd,v 1.5 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: natd @@ -12,43 +12,31 @@ name="natd" rcvar=`set_rcvar` command="/sbin/${name}" +pidfile="/var/run/${name}.pid" start_precmd="natd_precmd" -start_cmd="natd_start" +required_modules="ipdivert" natd_precmd() { - if ! ${SYSCTL} net.inet.divert > /dev/null 2>&1; then - if ! kldload ipdivert; then - warn unable to load IPDIVERT module. - return 1 - fi - fi - - return 0 -} - -natd_start() -{ - dhcp_list="`list_net_interfaces dhcp`" - for ifn in ${dhcp_list}; do - case ${natd_interface} in - ${ifn}) - natd_flags="$natd_flags -dynamic" - ;; - *) - ;; - esac - done if [ -n "${natd_interface}" ]; then - if echo ${natd_interface} | \ - grep -q -E '^[0-9]+(\.[0-9]+){0,3}$'; then - natd_flags="$natd_flags -a ${natd_interface}" + dhcp_list="`list_net_interfaces dhcp`" + for ifn in ${dhcp_list}; do + case "${natd_interface}" in + ${ifn}) + rc_flags="$rc_flags -dynamic" + ;; + esac + done + + if echo "${natd_interface}" | \ + grep -q -E '^[0-9]+(\.[0-9]+){0,3}$'; then + rc_flags="$rc_flags -a ${natd_interface}" else - natd_flags="$natd_flags -n ${natd_interface}" + rc_flags="$rc_flags -n ${natd_interface}" fi fi - echo -n ' natd' - ${natd_program:-/sbin/natd} ${natd_flags} ${natd_ifarg} + + return 0 } load_rc_config $name Index: powerd =================================================================== RCS file: /home/cvs/src/etc/rc.d/powerd,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/powerd -L etc/rc.d/powerd -u -r1.3 -r1.4 --- etc/rc.d/powerd +++ etc/rc.d/powerd @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/powerd,v 1.2.2.1 2005/12/16 01:42:54 dougb Exp $ +# $FreeBSD: src/etc/rc.d/powerd,v 1.4 2006/08/27 11:04:39 cperciva Exp $ # $MidnightBSD$ # PROVIDE: powerd @@ -13,6 +13,13 @@ name="powerd" rcvar=`set_rcvar` command="/usr/sbin/${name}" +stop_postcmd=powerd_poststop + +powerd_poststop() +{ + sysctl dev.cpu.0.freq=`sysctl -n dev.cpu.0.freq_levels | + sed -e 's:/.*::'` > /dev/null +} load_rc_config $name run_rc_command "$1" Index: nsswitch =================================================================== RCS file: /home/cvs/src/etc/rc.d/nsswitch,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/nsswitch -L etc/rc.d/nsswitch -u -r1.3 -r1.4 --- etc/rc.d/nsswitch +++ etc/rc.d/nsswitch @@ -24,7 +24,7 @@ # SUCH DAMAGE. # # $MidnightBSD$ -# $FreeBSD: src/etc/rc.d/nsswitch,v 1.5.2.1 2006/04/04 14:27:55 flz Exp $ +# $FreeBSD: src/etc/rc.d/nsswitch,v 1.12 2006/12/30 22:53:20 yar Exp $ # # PROVIDE: nsswitch @@ -37,52 +37,10 @@ start_cmd="nsswitch_start" stop_cmd=":" -convert_host_conf() -{ - host_conf=$1; shift; - nsswitch_conf=$1; shift; - - while read line; do - line=${line##[ ]} - case $line in - hosts|local|file) - _nsswitch="${_nsswitch}${_nsswitch+ }files" - ;; - dns|bind) - _nsswitch="${_nsswitch}${_nsswitch+ }dns" - ;; - nis) - _nsswitch="${_nsswitch}${_nsswitch+ }nis" - ;; - '#'*) - ;; - *) - printf "Warning: unrecognized line [%s]", $line > "/dev/stderr" - ;; - - esac - done < $host_conf - - echo "hosts: $_nsswitch" > $nsswitch_conf -} - -generate_nsswitch_conf() -{ - nsswitch_conf=$1; shift; - - cat >$nsswitch_conf < $host_conf + echo "# Auto-generated from nsswitch.conf" > $host_conf for _s in ${_sources}; do case $_s in files) @@ -131,25 +89,11 @@ nsswitch_start() { - # Convert host.conf to nsswitch.conf if necessary - # - if [ -f "/etc/host.conf" -a ! -f "/etc/nsswitch.conf" ]; then - echo '' - echo 'Warning: /etc/host.conf is no longer used' - echo ' /etc/nsswitch.conf will be created for you' - convert_host_conf /etc/host.conf /etc/nsswitch.conf - fi - - # Generate default nsswitch.conf if none exists - # - if [ ! -f "/etc/nsswitch.conf" ]; then - echo 'Generating nsswitch.conf.' - generate_nsswitch_conf /etc/nsswitch.conf - fi - # Generate host.conf for compatibility # - if [ ! -f "/etc/host.conf" ]; then + if [ ! -f "/etc/host.conf" -o \ + "/etc/host.conf" -ot "/etc/nsswitch.conf" ] + then echo 'Generating host.conf.' generate_host_conf /etc/nsswitch.conf /etc/host.conf fi Index: jail =================================================================== RCS file: /home/cvs/src/etc/rc.d/jail,v retrieving revision 1.5 retrieving revision 1.6 diff -L etc/rc.d/jail -L etc/rc.d/jail -u -r1.5 -r1.6 --- etc/rc.d/jail +++ etc/rc.d/jail @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/jail,v 1.23.2.2 2005/08/16 08:43:06 pjd Exp $ +# $FreeBSD: src/etc/rc.d/jail,v 1.37.4.1 2008/01/29 00:22:33 dougb Exp $ # $MidnightBSD$ # PROVIDE: jail @@ -8,6 +8,12 @@ # BEFORE: securelevel # KEYWORD: nojail shutdown +# WARNING: This script deals with untrusted data (the data and +# processes inside the jails) and care must be taken when changing the +# code related to this! If you have any doubt whether a change is +# correct and have security impact, please get the patch reviewed by +# laffer1@ or ctriv@ prior to commit. + . /etc/rc.subr name="jail" @@ -27,66 +33,101 @@ return fi - eval jail_rootdir=\"\$jail_${_j}_rootdir\" - jail_devdir="${jail_rootdir}/dev" - jail_fdescdir="${jail_devdir}/fd" - jail_procdir="${jail_rootdir}/proc" - eval jail_hostname=\"\$jail_${_j}_hostname\" - eval jail_ip=\"\$jail_${_j}_ip\" - eval jail_exec=\"\$jail_${_j}_exec\" - eval jail_exec_start=\"\$jail_${_j}_exec_start\" - eval jail_exec_stop=\"\$jail_${_j}_exec_stop\" - if [ -n "${jail_exec}" ]; then + eval _rootdir=\"\$jail_${_j}_rootdir\" + _devdir="${_rootdir}/dev" + _fdescdir="${_devdir}/fd" + _procdir="${_rootdir}/proc" + eval _hostname=\"\$jail_${_j}_hostname\" + eval _ip=\"\$jail_${_j}_ip\" + eval _interface=\"\${jail_${_j}_interface:-${jail_interface}}\" + eval _exec=\"\$jail_${_j}_exec\" + eval _exec_start=\"\${jail_${_j}_exec_start:-${jail_exec_start}}\" + + i=1 + while [ true ]; do + eval _exec_afterstart${i}=\"\${jail_${_j}_exec_afterstart${i}:-\${jail_exec_afterstart${i}}}\" + [ -z "$(eval echo \"\$_exec_afterstart${i}\")" ] && break + i=$((i + 1)) + done + + eval _exec_stop=\"\${jail_${_j}_exec_stop:-${jail_exec_stop}}\" + if [ -n "${_exec}" ]; then # simple/backward-compatible execution - jail_exec_start="${jail_exec}" - jail_exec_stop="" + _exec_start="${_exec}" + _exec_stop="" else # flexible execution - if [ -z "${jail_exec_start}" ]; then - jail_exec_start="/bin/sh /etc/rc" - if [ -z "${jail_exec_stop}" ]; then - jail_exec_stop="/bin/sh /etc/rc.shutdown" + if [ -z "${_exec_start}" ]; then + _exec_start="/bin/sh /etc/rc" + if [ -z "${_exec_stop}" ]; then + _exec_stop="/bin/sh /etc/rc.shutdown" fi fi fi # The default jail ruleset will be used by rc.subr if none is specified. - eval jail_ruleset=\"\$jail_${_j}_devfs_ruleset\" - eval jail_devfs=\"\$jail_${_j}_devfs_enable\" - [ -z "${jail_devfs}" ] && jail_devfs="NO" - eval jail_fdescfs=\"\$jail_${_j}_fdescfs_enable\" - [ -z "${jail_fdescfs}" ] && jail_fdescfs="NO" - eval jail_procfs=\"\$jail_${_j}_procfs_enable\" - [ -z "${jail_procfs}" ] && jail_procfs="NO" + eval _ruleset=\"\${jail_${_j}_devfs_ruleset:-${jail_devfs_ruleset}}\" + eval _devfs=\"\${jail_${_j}_devfs_enable:-${jail_devfs_enable}}\" + [ -z "${_devfs}" ] && _devfs="NO" + eval _fdescfs=\"\${jail_${_j}_fdescfs_enable:-${jail_fdescfs_enable}}\" + [ -z "${_fdescfs}" ] && _fdescfs="NO" + eval _procfs=\"\${jail_${_j}_procfs_enable:-${jail_procfs_enable}}\" + [ -z "${_procfs}" ] && _procfs="NO" - eval jail_mount=\"\$jail_${_j}_mount_enable\" - [ -z "${jail_mount}" ] && jail_mount="NO" + eval _mount=\"\${jail_${_j}_mount_enable:-${jail_mount_enable}}\" + [ -z "${_mount}" ] && _mount="NO" # "/etc/fstab.${_j}" will be used for {,u}mount(8) if none is specified. - eval jail_fstab=\"\$jail_${_j}_fstab\" - [ -z "${jail_fstab}" ] && jail_fstab="/etc/fstab.${_j}" - eval jail_flags=\"\$jail_${_j}_flags\" - [ -z "${jail_flags}" ] && jail_flags="-l -U root" + eval _fstab=\"\${jail_${_j}_fstab:-${jail_fstab}}\" + [ -z "${_fstab}" ] && _fstab="/etc/fstab.${_j}" + eval _flags=\"\${jail_${_j}_flags:-${jail_flags}}\" + [ -z "${_flags}" ] && _flags="-l -U root" eval _consolelog=\"\${jail_${_j}_consolelog:-${jail_consolelog}}\" [ -z "${_consolelog}" ] && _consolelog="/var/log/jail_${_j}_console.log" # Debugging aid # - debug "$_j devfs enable: $jail_devfs" - debug "$_j fdescfs enable: $jail_fdescfs" - debug "$_j procfs enable: $jail_procfs" - debug "$_j mount enable: $jail_mount" - debug "$_j hostname: $jail_hostname" - debug "$_j ip: $jail_ip" - debug "$_j root: $jail_rootdir" - debug "$_j devdir: $jail_devdir" - debug "$_j fdescdir: $jail_fdescdir" - debug "$_j procdir: $jail_procdir" - debug "$_j ruleset: $jail_ruleset" - debug "$_j fstab: $jail_fstab" - debug "$_j exec start: $jail_exec_start" - debug "$_j exec stop: $jail_exec_stop" - debug "$_j flags: $jail_flags" + debug "$_j devfs enable: $_devfs" + debug "$_j fdescfs enable: $_fdescfs" + debug "$_j procfs enable: $_procfs" + debug "$_j mount enable: $_mount" + debug "$_j hostname: $_hostname" + debug "$_j ip: $_ip" + debug "$_j interface: $_interface" + debug "$_j root: $_rootdir" + debug "$_j devdir: $_devdir" + debug "$_j fdescdir: $_fdescdir" + debug "$_j procdir: $_procdir" + debug "$_j ruleset: $_ruleset" + debug "$_j fstab: $_fstab" + debug "$_j exec start: $_exec_start" + debug "$_j consolelog: $_consolelog" + + i=1 + while [ true ]; do + eval out=\"\${_exec_afterstart${i}:-''}\" + + if [ -z "$out" ]; then + break; + fi + + debug "$_j exec after start #${i}: ${out}" + i=$((i + 1)) + done + + debug "$_j exec stop: $_exec_stop" + debug "$_j flags: $_flags" debug "$_j consolelog: $_consolelog" + + if [ -z "${_hostname}" ]; then + err 3 "$name: No hostname has been defined for ${_j}" + fi + if [ -z "${_rootdir}" ]; then + err 3 "$name: No root directory has been defined for ${_j}" + fi + if [ -z "${_ip}" ]; then + err 3 "$name: No IP address has been defined for ${_j}" + fi + } # set_sysctl rc_knob mib msg @@ -175,24 +216,24 @@ { local _device _mountpt _rest - if checkyesno jail_fdescfs; then - if [ -d "${jail_fdescdir}" ] ; then - secure_umount ${jail_fdescdir} + if checkyesno _fdescfs; then + if [ -d "${_fdescdir}" ] ; then + secure_umount ${_fdescdir} fi fi - if checkyesno jail_devfs; then - if [ -d "${jail_devdir}" ] ; then - secure_umount ${jail_devdir} + if checkyesno _devfs; then + if [ -d "${_devdir}" ] ; then + secure_umount ${_devdir} fi fi - if checkyesno jail_procfs; then - if [ -d "${jail_procdir}" ] ; then - secure_umount ${jail_procdir} + if checkyesno _procfs; then + if [ -d "${_procdir}" ] ; then + secure_umount ${_procdir} fi fi - if checkyesno jail_mount; then - [ -f "${jail_fstab}" ] || warn "${jail_fstab} does not exist" - tail -r ${jail_fstab} | while read _device _mountpt _rest; do + if checkyesno _mount; then + [ -f "${_fstab}" ] || warn "${_fstab} does not exist" + tail -r ${_fstab} | while read _device _mountpt _rest; do case ":${_device}" in :#* | :) continue @@ -225,11 +266,11 @@ ;; esac if is_symlinked_mountpoint ${_mountpt}; then - warn "${_mountpt} has symlink as parent - not mounting from ${jail_fstab}" + warn "${_mountpt} has symlink as parent - not mounting from ${_fstab}" return fi - done <${jail_fstab} - mount -a -F "${jail_fstab}" + done <${_fstab} + mount -a -F "${_fstab}" } jail_start() @@ -250,30 +291,33 @@ do init_variables $_jail if [ -f /var/run/jail_${_jail}.id ]; then - echo -n " [${jail_hostname} already running (/var/run/jail_${_jail}.id exists)]" + echo -n " [${_hostname} already running (/var/run/jail_${_jail}.id exists)]" continue; fi - if checkyesno jail_mount; then - info "Mounting fstab for jail ${_jail} (${jail_fstab})" - if [ ! -f "${jail_fstab}" ]; then - err 3 "$name: ${jail_fstab} does not exist" + if [ -n "${_interface}" ]; then + ifconfig ${_interface} alias ${_ip} netmask 255.255.255.255 + fi + if checkyesno _mount; then + info "Mounting fstab for jail ${_jail} (${_fstab})" + if [ ! -f "${_fstab}" ]; then + err 3 "$name: ${_fstab} does not exist" fi jail_mount_fstab fi - if checkyesno jail_devfs; then + if checkyesno _devfs; then # If devfs is already mounted here, skip it. - df -t devfs "${jail_devdir}" >/dev/null + df -t devfs "${_devdir}" >/dev/null if [ $? -ne 0 ]; then - if is_symlinked_mountpoint ${jail_devdir}; then - warn "${jail_devdir} has symlink as parent - not starting jail ${_jail}" + if is_symlinked_mountpoint ${_devdir}; then + warn "${_devdir} has symlink as parent - not starting jail ${_jail}" continue fi - info "Mounting devfs on ${jail_devdir}" - devfs_mount_jail "${jail_devdir}" ${jail_ruleset} + info "Mounting devfs on ${_devdir}" + devfs_mount_jail "${_devdir}" ${_ruleset} # Transitional symlink for old binaries - if [ ! -L "${jail_devdir}/log" ]; then + if [ ! -L "${_devdir}/log" ]; then __pwd="`pwd`" - cd "${jail_devdir}" + cd "${_devdir}" ln -sf ../var/run/log log cd "$__pwd" fi @@ -283,36 +327,58 @@ # is a devfs(5) device of the same name. # Jail console output # __pwd="`pwd`" - # cd "${jail_devdir}" + # cd "${_devdir}" # ln -sf ../var/log/console console # cd "$__pwd" fi - if checkyesno jail_fdescfs; then - if is_symlinked_mountpoint ${jail_fdescdir}; then - warn "${jail_fdescdir} has symlink as parent, not mounting" - else - info "Mounting fdescfs on ${jail_fdescdir}" - mount -t fdescfs fdesc "${jail_fdescdir}" + if checkyesno _fdescfs; then + if is_symlinked_mountpoint ${_fdescdir}; then + warn "${_fdescdir} has symlink as parent, not mounting" + else + info "Mounting fdescfs on ${_fdescdir}" + mount -t fdescfs fdesc "${_fdescdir}" fi fi - if checkyesno jail_procfs; then - if is_symlinked_mountpoint ${jail_procdir}; then - warn "${jail_procdir} has symlink as parent, not mounting" + if checkyesno _procfs; then + if is_symlinked_mountpoint ${_procdir}; then + warn "${_procdir} has symlink as parent, not mounting" else - info "Mounting procfs onto ${jail_procdir}" - if [ -d "${jail_procdir}" ] ; then - mount -t procfs proc "${jail_procdir}" + info "Mounting procfs onto ${_procdir}" + if [ -d "${_procdir}" ] ; then + mount -t procfs proc "${_procdir}" fi fi fi _tmp_jail=${_tmp_dir}/jail.$$ - eval jail ${jail_flags} -i ${jail_rootdir} ${jail_hostname} \ - ${jail_ip} ${jail_exec_start} > ${_tmp_jail} 2>&1 - [ "$?" -eq 0 ] && echo -n " $jail_hostname" - _jail_id=$(head -1 ${_tmp_jail}) - tail +2 ${_tmp_jail} >${_consolelog} + eval jail ${_flags} -i ${_rootdir} ${_hostname} \ + ${_ip} ${_exec_start} > ${_tmp_jail} 2>&1 + + if [ "$?" -eq 0 ] ; then + _jail_id=$(head -1 ${_tmp_jail}) + i=1 + while [ true ]; do + eval out=\"\${_exec_afterstart${i}:-''}\" + + if [ -z "$out" ]; then + break; + fi + + jexec "${_jail_id}" ${out} + i=$((i + 1)) + done + + echo -n " $_hostname" + tail +2 ${_tmp_jail} >${_consolelog} + echo ${_jail_id} > /var/run/jail_${_jail}.id + else + jail_umount_fs + if [ -n "${_interface}" ]; then + ifconfig ${_interface} -alias ${_ip} + fi + echo " cannot start jail \"${_jail}\": " + tail +2 ${_tmp_jail} + fi rm -f ${_tmp_jail} - echo ${_jail_id} > /var/run/jail_${_jail}.id done rmdir ${_tmp_dir} echo '.' @@ -327,19 +393,22 @@ _jail_id=$(cat /var/run/jail_${_jail}.id) if [ ! -z "${_jail_id}" ]; then init_variables $_jail - if [ -n "${jail_exec_stop}" ]; then - eval env -i /usr/sbin/jexec ${_jail_id} ${jail_exec_stop} \ + if [ -n "${_exec_stop}" ]; then + eval env -i /usr/sbin/jexec ${_jail_id} ${_exec_stop} \ >> ${_consolelog} 2>&1 fi killall -j ${_jail_id} -TERM > /dev/null 2>&1 sleep 1 killall -j ${_jail_id} -KILL > /dev/null 2>&1 jail_umount_fs - echo -n " $jail_hostname" + echo -n " $_hostname" + fi + if [ -n "${_interface}" ]; then + ifconfig ${_interface} -alias ${_ip} fi rm /var/run/jail_${_jail}.id else - echo "cannot stop jail ${_jail}. No jail id in /var/run" + echo " cannot stop jail ${_jail}. No jail id in /var/run" fi done echo '.' Index: ipfilter =================================================================== RCS file: /home/cvs/src/etc/rc.d/ipfilter,v retrieving revision 1.3 retrieving revision 1.4 diff -L etc/rc.d/ipfilter -L etc/rc.d/ipfilter -u -r1.3 -r1.4 --- etc/rc.d/ipfilter +++ etc/rc.d/ipfilter @@ -1,7 +1,6 @@ #!/bin/sh # -# $NetBSD: ipfilter,v 1.10 2001/02/28 17:03:50 lukem Exp $ -# $FreeBSD: src/etc/rc.d/ipfilter,v 1.24 2005/07/07 05:59:44 jkim Exp $ +# $FreeBSD: src/etc/rc.d/ipfilter,v 1.28.4.1 2008/01/28 07:58:31 dougb Exp $ # $MidnightBSD$ # PROVIDE: ipfilter @@ -16,7 +15,7 @@ load_rc_config $name stop_precmd="test -f ${ipfilter_rules} -o -f ${ipv6_ipfilter_rules}" -start_precmd="ipfilter_prestart" +start_precmd="$stop_precmd" start_cmd="ipfilter_start" stop_cmd="ipfilter_stop" reload_precmd="$stop_precmd" @@ -26,35 +25,7 @@ status_precmd="$stop_precmd" status_cmd="ipfilter_status" extra_commands="reload resync status" - -ipfilter_loaded() -{ - if ! kldstat -v | grep "ipfilter$" > /dev/null 2>&1; then - return 1 - else - return 0 - fi -} - -ipfilter_prestart() -{ - # load ipfilter kernel module if needed - if ! ipfilter_loaded; then - if kldload ipl; then - info 'IP-filter module loaded.' - else - err 1 'IP-filter module failed to load.' - fi - fi - - # check for ipfilter rules - if [ ! -r "${ipfilter_rules}" ] && [ ! -r "${ipv6_ipfilter_rules}" ] - then - warn 'IP-filter: NO IPF RULES' - return 1 - fi - return 0 -} +required_modules="ipl:ipfilter" ipfilter_start() { @@ -93,11 +64,17 @@ if [ -r "${ipfilter_rules}" ]; then ${ipfilter_program:-/sbin/ipf} -I \ -f "${ipfilter_rules}" ${ipfilter_flags} + if [ $? -ne 0 ]; then + err 1 'Load of rules into alternate set failed; aborting reload' + fi fi ${ipfilter_program:-/sbin/ipf} -I -6 -Fa if [ -r "${ipv6_ipfilter_rules}" ]; then ${ipfilter_program:-/sbin/ipf} -I -6 \ -f "${ipv6_ipfilter_rules}" ${ipfilter_flags} + if [ $? -ne 0 ]; then + err 1 'Load of IPv6 rules into alternate set failed; aborting reload' + fi fi ${ipfilter_program:-/sbin/ipf} -s @@ -105,10 +82,6 @@ ipfilter_resync() { - # Don't resync if ipfilter is not loaded - if ! ipfilter_loaded; then - return - fi ${ipfilter_program:-/sbin/ipf} -y ${ipfilter_flags} } Index: localpkg =================================================================== RCS file: /home/cvs/src/etc/rc.d/localpkg,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/localpkg -L etc/rc.d/localpkg -u -r1.2 -r1.3 --- etc/rc.d/localpkg +++ etc/rc.d/localpkg @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/localpkg,v 1.5.2.2 2005/12/21 07:11:34 dougb Exp $ +# $FreeBSD: src/etc/rc.d/localpkg,v 1.8 2006/02/12 10:04:56 matteo Exp $ # $MidnightBSD$ # PROVIDE: localpkg @@ -48,6 +48,9 @@ find_local_scripts_old for script in `reverse_list ${slist} ${zlist}`; do if [ -x "${script}" ]; then + if [ `sysctl -n debug.bootverbose` -eq 1 ]; then + echo "==>" ${script} + fi (set -T trap 'exit 1' 2 ${script} stop) Index: nfsserver =================================================================== RCS file: /home/cvs/src/etc/rc.d/nfsserver,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.d/nfsserver -L etc/rc.d/nfsserver -u -r1.2 -r1.3 --- etc/rc.d/nfsserver +++ etc/rc.d/nfsserver @@ -1,6 +1,6 @@ #!/bin/sh # -# $FreeBSD: src/etc/rc.d/nfsserver,v 1.4 2004/10/07 13:55:26 mtm Exp $ +# $FreeBSD: src/etc/rc.d/nfsserver,v 1.5 2006/12/31 10:37:18 yar Exp $ # $MidnightBSD$ # PROVIDE: nfsserver @@ -11,20 +11,9 @@ name="nfsserver" rcvar="nfs_server_enable" -start_cmd="nfsserver_start" +start_cmd=":" stop_cmd=":" - -# Load nfs modules if they were not compiled into the kernel -nfsserver_start() -{ - if ! sysctl vfs.nfsrv >/dev/null 2>&1; then - if ! kldload nfsserver; then - warn 'Could not load NFS server module' - return 1 - fi - fi - return 0 -} +required_modules="nfsserver" load_rc_config $name run_rc_command "$1" From laffer1 at midnightbsd.org Sun Jan 18 14:28:02 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 18 Jan 2009 14:28:02 -0500 (EST) Subject: [Midnightbsd-cvs] src: compat/ndis: remove legacy freebsd version support. Message-ID: <200901181928.n0IJS28j085178@stargazer.midnightbsd.org> Log Message: ----------- remove legacy freebsd version support. Modified Files: -------------- src/sys/compat/ndis: kern_ndis.c (r1.3 -> r1.4) subr_ndis.c (r1.3 -> r1.4) subr_ntoskrnl.c (r1.3 -> r1.4) -------------- next part -------------- Index: subr_ndis.c =================================================================== RCS file: /home/cvs/src/sys/compat/ndis/subr_ndis.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/compat/ndis/subr_ndis.c -L sys/compat/ndis/subr_ndis.c -u -r1.3 -r1.4 --- sys/compat/ndis/subr_ndis.c +++ sys/compat/ndis/subr_ndis.c @@ -1,4 +1,3 @@ -/* $MidnightBSD$ */ /*- * Copyright (c) 2003 * Bill Paul . All rights reserved. @@ -648,11 +647,7 @@ * See if registry key is already in a list of known keys * included with the driver. */ -#if __FreeBSD_version < 502113 - TAILQ_FOREACH(e, &sc->ndis_ctx, link) { -#else TAILQ_FOREACH(e, device_get_sysctl_ctx(sc->ndis_dev), link) { -#endif oidp = e->entry; if (strcasecmp(oidp->oid_name, keystr) == 0) { if (strcmp((char *)oidp->oid_arg1, "UNSET") == 0) { @@ -757,11 +752,7 @@ /* See if the key already exists. */ -#if __FreeBSD_version < 502113 - TAILQ_FOREACH(e, &sc->ndis_ctx, link) { -#else TAILQ_FOREACH(e, device_get_sysctl_ctx(sc->ndis_dev), link) { -#endif oidp = e->entry; if (strcasecmp(oidp->oid_name, keystr) == 0) { /* Found it, set the value. */ @@ -1361,23 +1352,11 @@ block = (ndis_miniport_block *)adapter; sc = device_get_softc(block->nmb_physdeviceobj->do_devext); -#ifdef IFP2ENADDR - if (bcmp(IFP2ENADDR(sc->ifp), empty, ETHER_ADDR_LEN) == 0) -#elif __FreeBSD_version >= 700000 if (sc->ifp->if_addr == NULL || bcmp(IF_LLADDR(sc->ifp), empty, ETHER_ADDR_LEN) == 0) -#else - if (bcmp(sc->arpcom.ac_enaddr, empty, ETHER_ADDR_LEN) == 0) -#endif *status = NDIS_STATUS_FAILURE; else { -#ifdef IFP2ENADDR - *addr = IFP2ENADDR(sc->ifp); -#elif __FreeBSD_version >= 700000 *addr = IF_LLADDR(sc->ifp); -#else - *addr = sc->arpcom.ac_enaddr; -#endif *addrlen = ETHER_ADDR_LEN; *status = NDIS_STATUS_SUCCESS; } Index: kern_ndis.c =================================================================== RCS file: /home/cvs/src/sys/compat/ndis/kern_ndis.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/compat/ndis/kern_ndis.c -L sys/compat/ndis/kern_ndis.c -u -r1.3 -r1.4 --- sys/compat/ndis/kern_ndis.c +++ sys/compat/ndis/kern_ndis.c @@ -295,15 +295,6 @@ TAILQ_INIT(&sc->ndis_cfglist_head); -#if __FreeBSD_version < 502113 - /* Create the sysctl tree. */ - - sc->ndis_tree = SYSCTL_ADD_NODE(&sc->ndis_ctx, - SYSCTL_STATIC_CHILDREN(_hw), OID_AUTO, - device_get_nameunit(sc->ndis_dev), CTLFLAG_RD, 0, - device_get_desc(sc->ndis_dev)); - -#endif /* Add the driver-specific registry keys. */ while(1) { @@ -318,11 +309,7 @@ /* See if we already have a sysctl with this name */ oidp = NULL; -#if __FreeBSD_version < 502113 - TAILQ_FOREACH(e, &sc->ndis_ctx, link) { -#else TAILQ_FOREACH(e, device_get_sysctl_ctx(sc->ndis_dev), link) { -#endif oidp = e->entry; if (strcasecmp(oidp->oid_name, vals->nc_cfgkey) == 0) break; @@ -403,18 +390,11 @@ TAILQ_INSERT_TAIL(&sc->ndis_cfglist_head, cfg, link); cfg->ndis_oid = -#if __FreeBSD_version < 502113 - SYSCTL_ADD_STRING(&sc->ndis_ctx, SYSCTL_CHILDREN(sc->ndis_tree), - OID_AUTO, cfg->ndis_cfg.nc_cfgkey, flag, - cfg->ndis_cfg.nc_val, sizeof(cfg->ndis_cfg.nc_val), - cfg->ndis_cfg.nc_cfgdesc); -#else SYSCTL_ADD_STRING(device_get_sysctl_ctx(sc->ndis_dev), SYSCTL_CHILDREN(device_get_sysctl_tree(sc->ndis_dev)), OID_AUTO, cfg->ndis_cfg.nc_cfgkey, flag, cfg->ndis_cfg.nc_val, sizeof(cfg->ndis_cfg.nc_val), cfg->ndis_cfg.nc_cfgdesc); -#endif return(0); } @@ -436,11 +416,7 @@ sc = arg; -#if __FreeBSD_version < 502113 - clist = &sc->ndis_ctx; -#else clist = device_get_sysctl_ctx(sc->ndis_dev); -#endif while (!TAILQ_EMPTY(&sc->ndis_cfglist_head)) { cfg = TAILQ_FIRST(&sc->ndis_cfglist_head); @@ -568,20 +544,12 @@ device_t dev; struct resource_list *brl; struct resource_list_entry *brle; -#if __FreeBSD_version < 600022 - struct resource_list brl_rev; - struct resource_list_entry *n; -#endif int error = 0; sc = arg; block = sc->ndis_block; dev = sc->ndis_dev; -#if __FreeBSD_version < 600022 - SLIST_INIT(&brl_rev); -#endif - rl = malloc(sizeof(ndis_resource_list) + (sizeof(cm_partial_resource_desc) * (sc->ndis_rescnt - 1)), M_DEVBUF, M_NOWAIT|M_ZERO); @@ -598,37 +566,7 @@ if (brl != NULL) { -#if __FreeBSD_version < 600022 - /* - * We have a small problem. Some PCI devices have - * multiple I/O ranges. Windows orders them starting - * from lowest numbered BAR to highest. We discover - * them in that order too, but insert them into a singly - * linked list head first, which means when time comes - * to traverse the list, we enumerate them in reverse - * order. This screws up some drivers which expect the - * BARs to be in ascending order so that they can choose - * the "first" one as their register space. Unfortunately, - * in order to fix this, we have to create our own - * temporary list with the entries in reverse order. - */ - - SLIST_FOREACH(brle, brl, link) { - n = malloc(sizeof(struct resource_list_entry), - M_TEMP, M_NOWAIT); - if (n == NULL) { - error = ENOMEM; - goto bad; - } - bcopy((char *)brle, (char *)n, - sizeof(struct resource_list_entry)); - SLIST_INSERT_HEAD(&brl_rev, n, link); - } - - SLIST_FOREACH(brle, &brl_rev, link) { -#else STAILQ_FOREACH(brle, brl, link) { -#endif switch (brle->type) { case SYS_RES_IOPORT: prd->cprd_type = CmResourceTypePort; @@ -672,16 +610,6 @@ block->nmb_rlist = rl; -#if __FreeBSD_version < 600022 -bad: - - while (!SLIST_EMPTY(&brl_rev)) { - n = SLIST_FIRST(&brl_rev); - SLIST_REMOVE_HEAD(&brl_rev, link); - free (n, M_TEMP); - } -#endif - return(error); } Index: subr_ntoskrnl.c =================================================================== RCS file: /home/cvs/src/sys/compat/ndis/subr_ntoskrnl.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/compat/ndis/subr_ntoskrnl.c -L sys/compat/ndis/subr_ntoskrnl.c -u -r1.3 -r1.4 --- sys/compat/ndis/subr_ntoskrnl.c +++ sys/compat/ndis/subr_ntoskrnl.c @@ -45,9 +45,7 @@ #include #include -#if __FreeBSD_version > 502113 #include -#endif #include #include #include @@ -2703,11 +2701,7 @@ rl = BUS_GET_RESOURCE_LIST(device_get_parent(dev), dev); if (rl != NULL) { -#if __FreeBSD_version < 600022 - SLIST_FOREACH(rle, rl, link) { -#else STAILQ_FOREACH(rle, rl, link) { -#endif r = rle->res; if (r == NULL) @@ -2799,9 +2793,6 @@ KeReleaseSpinLock(&kq->kq_lock, irql); } -#if __FreeBSD_version < 502113 - mtx_lock(&Giant); -#endif kthread_exit(0); return; /* notreached */ } @@ -3560,9 +3551,6 @@ ntoskrnl_kth--; -#if __FreeBSD_version < 502113 - mtx_lock(&Giant); -#endif kthread_exit(0); return(0); /* notreached */ } @@ -3584,11 +3572,7 @@ DbgBreakPoint(void) { -#if __FreeBSD_version < 502113 - Debugger("DbgBreakPoint(): breakpoint"); -#else kdb_enter("DbgBreakPoint(): breakpoint"); -#endif } static void @@ -3829,14 +3813,9 @@ thread_lock(curthread); #ifdef NTOSKRNL_MULTIPLE_DPCS -#if __FreeBSD_version >= 502102 sched_bind(curthread, kq->kq_cpu); #endif -#endif sched_prio(curthread, PRI_MIN_KERN); -#if __FreeBSD_version < 600000 - curthread->td_base_pri = PRI_MIN_KERN; -#endif thread_unlock(curthread); while (1) { @@ -3869,9 +3848,6 @@ KeSetEvent(&kq->kq_done, IO_NO_INCREMENT, FALSE); } -#if __FreeBSD_version < 502113 - mtx_lock(&Giant); -#endif kthread_exit(0); return; /* notreached */ } From laffer1 at midnightbsd.org Sun Jan 18 14:29:08 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 18 Jan 2009 14:29:08 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/wi: Remove legacy freebsd support. Message-ID: <200901181929.n0IJT8u8085297@stargazer.midnightbsd.org> Log Message: ----------- Remove legacy freebsd support. Switch to "MidnightBSD" os name. Modified Files: -------------- src/sys/dev/aha: aha.c (r1.2 -> r1.3) src/sys/dev/ahb: ahb.c (r1.4 -> r1.5) src/sys/dev/aic: aic.c (r1.2 -> r1.3) src/sys/dev/aic7xxx: aic79xx.c (r1.1.1.3 -> r1.2) aic79xx_osm.h (r1.1.1.3 -> r1.2) aic7xxx.c (r1.1.1.3 -> r1.2) aic7xxx_osm.h (r1.1.1.3 -> r1.2) aic_osm_lib.c (r1.1.1.3 -> r1.2) aic_osm_lib.h (r1.1.1.3 -> r1.2) src/sys/dev/wds: wd7000.c (r1.2 -> r1.3) src/sys/dev/wi: if_wireg.h (r1.2 -> r1.3) -------------- next part -------------- Index: ahb.c =================================================================== RCS file: /home/cvs/src/sys/dev/ahb/ahb.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/ahb/ahb.c -L sys/dev/ahb/ahb.c -u -r1.4 -r1.5 --- sys/dev/ahb/ahb.c +++ sys/dev/ahb/ahb.c @@ -1229,7 +1229,7 @@ cpi->initiator_id = ahb->scsi_id; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "Adaptec", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: aic.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic/aic.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/aic/aic.c -L sys/dev/aic/aic.c -u -r1.2 -r1.3 --- sys/dev/aic/aic.c +++ sys/dev/aic/aic.c @@ -287,7 +287,7 @@ cpi->initiator_id = aic->initiator; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "Adaptec", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: aic_osm_lib.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic_osm_lib.c,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic_osm_lib.c -L sys/dev/aic7xxx/aic_osm_lib.c -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic_osm_lib.c +++ sys/dev/aic7xxx/aic_osm_lib.c @@ -131,23 +131,6 @@ void aic_calc_geometry(struct ccb_calc_geometry *ccg, int extended) { -#if __FreeBSD_version >= 500000 cam_calc_geometry(ccg, extended); -#else - uint32_t size_mb; - uint32_t secs_per_cylinder; - - size_mb = ccg->volume_size / ((1024L * 1024L) / ccg->block_size); - if (size_mb > 1024 && extended) { - ccg->heads = 255; - ccg->secs_per_track = 63; - } else { - ccg->heads = 64; - ccg->secs_per_track = 32; - } - secs_per_cylinder = ccg->heads * ccg->secs_per_track; - ccg->cylinders = ccg->volume_size / secs_per_cylinder; - ccg->ccb_h.status = CAM_REQ_CMP; -#endif } Index: aic79xx_osm.h =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic79xx_osm.h,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic79xx_osm.h -L sys/dev/aic7xxx/aic79xx_osm.h -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic79xx_osm.h +++ sys/dev/aic7xxx/aic79xx_osm.h @@ -43,9 +43,7 @@ #include #include #include /* For device_t */ -#if __FreeBSD_version >= 500000 #include -#endif #include #include #include @@ -59,13 +57,8 @@ #include -#if __FreeBSD_version >= 500000 #include #include -#else -#include -#include -#endif #include #include Index: aic7xxx_osm.h =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic7xxx_osm.h,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic7xxx_osm.h -L sys/dev/aic7xxx/aic7xxx_osm.h -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic7xxx_osm.h +++ sys/dev/aic7xxx/aic7xxx_osm.h @@ -42,20 +42,14 @@ #include #include #include /* For device_t */ -#if __FreeBSD_version >= 500000 #include -#endif #include #include #include #include #include -#if __FreeBSD_version < 500000 -#include -#else #define NPCI 1 -#endif #if NPCI > 0 #define AIC_PCI_CONFIG 1 @@ -67,13 +61,8 @@ #include #if NPCI > 0 -#if __FreeBSD_version >= 500000 #include #include -#else -#include -#include -#endif #endif #include Index: aic79xx.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic79xx.c,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic79xx.c -L sys/dev/aic7xxx/aic79xx.c -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic79xx.c +++ sys/dev/aic7xxx/aic79xx.c @@ -2234,7 +2234,6 @@ printerror = 0; } else if (ahd_sent_msg(ahd, AHDMSG_1B, MSG_BUS_DEV_RESET, TRUE)) { -#ifdef __FreeBSD__ /* * Don't mark the user's request for this BDR * as completing with CAM_BDR_SENT. CAM3 @@ -2246,7 +2245,6 @@ CAM_LUN_WILDCARD, SCB_LIST_NULL, ROLE_INITIATOR)) aic_set_transaction_status(scb, CAM_REQ_CMP); -#endif ahd_handle_devreset(ahd, &devinfo, CAM_LUN_WILDCARD, CAM_BDR_SENT, "Bus Device Reset", /*verbose_level*/0); @@ -5225,23 +5223,11 @@ { struct ahd_softc *ahd; -#ifndef __FreeBSD__ - ahd = malloc(sizeof(*ahd), M_DEVBUF, M_NOWAIT); - if (!ahd) { - printf("aic7xxx: cannot malloc softc!\n"); - free(name, M_DEVBUF); - return NULL; - } -#else ahd = device_get_softc((device_t)platform_arg); -#endif memset(ahd, 0, sizeof(*ahd)); ahd->seep_config = malloc(sizeof(*ahd->seep_config), M_DEVBUF, M_NOWAIT); if (ahd->seep_config == NULL) { -#ifndef __FreeBSD__ - free(ahd, M_DEVBUF); -#endif free(name, M_DEVBUF); return (NULL); } @@ -5427,9 +5413,6 @@ free(ahd->seep_config, M_DEVBUF); if (ahd->saved_stack != NULL) free(ahd->saved_stack, M_DEVBUF); -#ifndef __FreeBSD__ - free(ahd, M_DEVBUF); -#endif return; } Index: aic7xxx.c =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic7xxx.c,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic7xxx.c -L sys/dev/aic7xxx/aic7xxx.c -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic7xxx.c +++ sys/dev/aic7xxx/aic7xxx.c @@ -1280,7 +1280,6 @@ printerror = 0; } else if (ahc_sent_msg(ahc, AHCMSG_1B, MSG_BUS_DEV_RESET, TRUE)) { -#ifdef __FreeBSD__ /* * Don't mark the user's request for this BDR * as completing with CAM_BDR_SENT. CAM3 @@ -1294,7 +1293,6 @@ ROLE_INITIATOR)) { aic_set_transaction_status(scb, CAM_REQ_CMP); } -#endif ahc_compile_devinfo(&devinfo, initiator_role_id, target, @@ -3903,23 +3901,11 @@ struct ahc_softc *ahc; int i; -#ifndef __FreeBSD__ - ahc = malloc(sizeof(*ahc), M_DEVBUF, M_NOWAIT); - if (!ahc) { - printf("aic7xxx: cannot malloc softc!\n"); - free(name, M_DEVBUF); - return NULL; - } -#else ahc = device_get_softc((device_t)platform_arg); -#endif memset(ahc, 0, sizeof(*ahc)); ahc->seep_config = malloc(sizeof(*ahc->seep_config), M_DEVBUF, M_NOWAIT); if (ahc->seep_config == NULL) { -#ifndef __FreeBSD__ - free(ahc, M_DEVBUF); -#endif free(name, M_DEVBUF); return (NULL); } @@ -4112,9 +4098,6 @@ free(ahc->name, M_DEVBUF); if (ahc->seep_config != NULL) free(ahc->seep_config, M_DEVBUF); -#ifndef __FreeBSD__ - free(ahc, M_DEVBUF); -#endif return; } Index: aic_osm_lib.h =================================================================== RCS file: /home/cvs/src/sys/dev/aic7xxx/aic_osm_lib.h,v retrieving revision 1.1.1.3 retrieving revision 1.2 diff -L sys/dev/aic7xxx/aic_osm_lib.h -L sys/dev/aic7xxx/aic_osm_lib.h -u -r1.1.1.3 -r1.2 --- sys/dev/aic7xxx/aic_osm_lib.h +++ sys/dev/aic7xxx/aic_osm_lib.h @@ -36,9 +36,7 @@ */ /******************************** OS Includes *********************************/ -#if __FreeBSD_version >= 500000 #include -#endif /*************************** Library Symbol Mapping ***************************/ #define AIC_LIB_ENTRY_CONCAT(x, prefix) prefix ## x @@ -71,7 +69,6 @@ #define AIC_SHUTDOWN_RECOVERY AIC_CONST_ENTRY(_SHUTDOWN_RECOVERY) /********************************* Byte Order *********************************/ -#if __FreeBSD_version >= 500000 #define aic_htobe16(x) htobe16(x) #define aic_htobe32(x) htobe32(x) #define aic_htobe64(x) htobe64(x) @@ -85,21 +82,6 @@ #define aic_le16toh(x) le16toh(x) #define aic_le32toh(x) le32toh(x) #define aic_le64toh(x) le64toh(x) -#else -#define aic_htobe16(x) (x) -#define aic_htobe32(x) (x) -#define aic_htobe64(x) (x) -#define aic_htole16(x) (x) -#define aic_htole32(x) (x) -#define aic_htole64(x) (x) - -#define aic_be16toh(x) (x) -#define aic_be32toh(x) (x) -#define aic_be64toh(x) (x) -#define aic_le16toh(x) (x) -#define aic_le32toh(x) (x) -#define aic_le64toh(x) (x) -#endif /************************* Forward Declarations *******************************/ typedef device_t aic_dev_softc_t; @@ -125,17 +107,11 @@ } /****************************** Kernel Threads ********************************/ -#if __FreeBSD_version > 500005 #define aic_kthread_create(func, farg, proc_ptr, flags, stackpgs, fmtstr, arg) \ kthread_create(func, farg, proc_ptr, flags, stackpgs, fmtstr, arg) -#else -#define aic_kthread_create(func, farg, proc_ptr, flags, stackpgs, fmtstr, arg) \ - kthread_create(func, farg, proc_ptr, fmtstr, arg) -#endif /******************************* Bus Space/DMA ********************************/ -#if __FreeBSD_version >= 501102 #define aic_dma_tag_create(aic, parent_tag, alignment, boundary, \ lowaddr, highaddr, filter, filterarg, \ maxsize, nsegments, maxsegsz, flags, \ @@ -145,16 +121,6 @@ maxsize, nsegments, maxsegsz, flags, \ busdma_lock_mutex, &aic->platform_data->mtx, \ dma_tagp) -#else -#define aic_dma_tag_create(aic, parent_tag, alignment, boundary, \ - lowaddr, highaddr, filter, filterarg, \ - maxsize, nsegments, maxsegsz, flags, \ - dma_tagp) \ - bus_dma_tag_create(parent_tag, alignment, boundary, \ - lowaddr, highaddr, filter, filterarg, \ - maxsize, nsegments, maxsegsz, flags, \ - dma_tagp) -#endif #define aic_dma_tag_destroy(aic, tag) \ bus_dma_tag_destroy(tag) @@ -186,11 +152,7 @@ #include AIC_CORE_INCLUDE /***************************** Timer Facilities *******************************/ -#if __FreeBSD_version >= 500000 #define aic_timer_init(timer) callout_init(timer, /*mpsafe*/1) -#else -#define aic_timer_init callout_init -#endif #define aic_timer_stop callout_stop static __inline void aic_timer_reset(aic_timer_t *, u_int, Index: wd7000.c =================================================================== RCS file: /home/cvs/src/sys/dev/wds/wd7000.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/wds/wd7000.c -L sys/dev/wds/wd7000.c -u -r1.2 -r1.3 --- sys/dev/wds/wd7000.c +++ sys/dev/wds/wd7000.c @@ -1225,7 +1225,7 @@ cpi->hba_misc = 0; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "WD/FDC", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: aha.c =================================================================== RCS file: /home/cvs/src/sys/dev/aha/aha.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/aha/aha.c -L sys/dev/aha/aha.c -u -r1.2 -r1.3 --- sys/dev/aha/aha.c +++ sys/dev/aha/aha.c @@ -993,7 +993,7 @@ cpi->initiator_id = aha->scsi_id; cpi->bus_id = cam_sim_bus(sim); cpi->base_transfer_speed = 3300; - strncpy(cpi->sim_vid, "FreeBSD", SIM_IDLEN); + strncpy(cpi->sim_vid, "MidnightBSD", SIM_IDLEN); strncpy(cpi->hba_vid, "Adaptec", HBA_IDLEN); strncpy(cpi->dev_name, cam_sim_name(sim), DEV_IDLEN); cpi->unit_number = cam_sim_unit(sim); Index: if_wireg.h =================================================================== RCS file: /home/cvs/src/sys/dev/wi/if_wireg.h,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/wi/if_wireg.h -L sys/dev/wi/if_wireg.h -u -r1.2 -r1.3 --- sys/dev/wi/if_wireg.h +++ sys/dev/wi/if_wireg.h @@ -84,12 +84,12 @@ #ifdef __NetBSD__ #define OS_STRING_NAME "NetBSD" #endif -#ifdef __FreeBSD__ -#define OS_STRING_NAME "FreeBSD" -#endif #ifdef __OpenBSD__ #define OS_STRING_NAME "OpenBSD" #endif +#ifdef __MidnightBSD__ +#define OS_STRING_NAME "MidnightBSD" +#endif #define WI_DEFAULT_NODENAME OS_STRING_NAME " WaveLAN/IEEE node" From laffer1 at midnightbsd.org Sun Jan 18 14:27:18 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 18 Jan 2009 14:27:18 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/if_ndis: Remove the legacy freebsd version support. Message-ID: <200901181927.n0IJRIXZ085130@stargazer.midnightbsd.org> Log Message: ----------- Remove the legacy freebsd version support. Fix the mode setting for 48. Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.1.1.2 -> r1.2) if_ndis_pci.c (r1.1.1.1 -> r1.2) if_ndisvar.h (r1.1.1.2 -> r1.2) -------------- next part -------------- Index: if_ndis_pci.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis_pci.c,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L sys/dev/if_ndis/if_ndis_pci.c -L sys/dev/if_ndis/if_ndis_pci.c -u -r1.1.1.1 -r1.2 --- sys/dev/if_ndis/if_ndis_pci.c +++ sys/dev/if_ndis/if_ndis_pci.c @@ -187,11 +187,7 @@ rl = BUS_GET_RESOURCE_LIST(device_get_parent(dev), dev); if (rl != NULL) { -#if __FreeBSD_version < 600022 - SLIST_FOREACH(rle, rl, link) { -#else STAILQ_FOREACH(rle, rl, link) { -#endif switch (rle->type) { case SYS_RES_IOPORT: sc->ndis_io_rid = rle->rid; Index: if_ndisvar.h =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndisvar.h,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L sys/dev/if_ndis/if_ndisvar.h -L sys/dev/if_ndis/if_ndisvar.h -u -r1.1.1.2 -r1.2 --- sys/dev/if_ndis/if_ndisvar.h +++ sys/dev/if_ndis/if_ndisvar.h @@ -32,7 +32,7 @@ * $FreeBSD: src/sys/dev/if_ndis/if_ndisvar.h,v 1.27 2007/07/12 02:54:05 thompsa Exp $ */ -#define NDIS_DEFAULT_NODENAME "FreeBSD NDIS node" +#define NDIS_DEFAULT_NODENAME "MidnightBSD NDIS node" #define NDIS_NODENAME_LEN 32 /* For setting/getting OIDs from userspace. */ @@ -89,10 +89,6 @@ #define NDIS_INC(x) \ (x)->ndis_txidx = ((x)->ndis_txidx + 1) % NDIS_TXPKTS -#if __FreeBSD_version < 600007 -#define arpcom ic.ic_ac -#endif - #define NDIS_EVENTS 4 #define NDIS_EVTINC(x) (x) = ((x) + 1) % NDIS_EVENTS @@ -150,10 +146,6 @@ int ndis_if_flags; int ndis_skip; -#if __FreeBSD_version < 502113 - struct sysctl_ctx_list ndis_ctx; - struct sysctl_oid *ndis_tree; -#endif int ndis_devidx; interface_type ndis_iftype; driver_object *ndis_dobj; @@ -176,9 +168,6 @@ kspin_lock ndis_rxlock; struct taskqueue *ndis_tq; /* private task queue */ -#if __FreeBSD_version < 700000 - struct proc *ndis_tqproc; -#endif struct task ndis_scantask; int (*ndis_newstate)(struct ieee80211com *, enum ieee80211_state, int); Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.1.1.2 -r1.2 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -72,10 +72,6 @@ #include #include -#if __FreeBSD_version < 700046 -#include -#endif - #include #include @@ -144,10 +140,6 @@ static void ndis_resettask (device_object *, void *); static void ndis_inputtask (device_object *, void *); static int ndis_ioctl (struct ifnet *, u_long, caddr_t); -#if __FreeBSD_version < 700046 -static int ndis_wi_ioctl_get (struct ifnet *, u_long, caddr_t); -static int ndis_wi_ioctl_set (struct ifnet *, u_long, caddr_t); -#endif static int ndis_80211_ioctl_get (struct ifnet *, u_long, caddr_t); static int ndis_80211_ioctl_set (struct ifnet *, u_long, caddr_t); static int ndis_newstate (struct ieee80211com *, enum ieee80211_state, @@ -534,16 +526,11 @@ int i; sc = device_get_softc(dev); -#if __FreeBSD_version < 600031 - sc->ifp = &sc->arpcom.ac_if; - ifp = sc->ifp; -#else ifp = sc->ifp = if_alloc(IFT_ETHER); if (ifp == NULL) { error = ENOSPC; goto fail; } -#endif ifp->if_softc = sc; KeInitializeSpinLock(&sc->ndis_spinlock); @@ -559,10 +546,6 @@ } } -#if __FreeBSD_version < 502113 - sysctl_ctx_init(&sc->ndis_ctx); -#endif - /* Create sysctl registry nodes */ ndis_create_sysctls(sc); @@ -699,14 +682,6 @@ /* Check for task offload support. */ ndis_probe_offload(sc); -#if __FreeBSD_version < 502109 - /* - * An NDIS device was detected. Inform the world. - */ - device_printf(dev, "%s address: %6D\n", - sc->ndis_80211 ? "802.11" : "Ethernet", eaddr, ":"); -#endif - if_initname(ifp, device_get_name(dev), device_get_unit(dev)); ifp->if_mtu = ETHERMTU; ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; @@ -715,13 +690,9 @@ ifp->if_watchdog = ndis_watchdog; ifp->if_init = ndis_init; ifp->if_baudrate = 10000000; -#if __FreeBSD_version < 502114 - ifp->if_snd.ifq_maxlen = 50; -#else IFQ_SET_MAXLEN(&ifp->if_snd, 50); ifp->if_snd.ifq_drv_maxlen = 25; IFQ_SET_READY(&ifp->if_snd); -#endif ifp->if_capenable = ifp->if_capabilities; ifp->if_hwassist = sc->ndis_hwassist; @@ -733,22 +704,13 @@ uint32_t arg; int r; -#if __FreeBSD_version >= 700000 sc->ndis_tq = taskqueue_create("nids_taskq", M_NOWAIT | M_ZERO, taskqueue_thread_enqueue, &sc->ndis_tq); taskqueue_start_threads(&sc->ndis_tq, 1, PI_NET, "%s taskq", device_get_nameunit(dev)); -#else - sc->ndis_tq = taskqueue_create("ndis_taskq", M_NOWAIT | M_ZERO, - taskqueue_thread_enqueue, &sc->ndis_tq, &sc->sc_tqproc); - kthread_create(taskqueue_thread_loop, &sc->ndis_tq, &sc->sc_tqproc, - 0, 0, "%s taskq", device_get_nameunit(dev)); -#endif TASK_INIT(&sc->ndis_scantask, 0, ndis_scan, sc); -#if __FreeBSD_version >= 600007 ic->ic_ifp = ifp; -#endif ic->ic_phytype = IEEE80211_T_DS; ic->ic_opmode = IEEE80211_M_STA; ic->ic_caps = IEEE80211_C_IBSS; @@ -867,13 +829,13 @@ IEEE80211_RATE_BASIC|22); } if (isset(ic->ic_modecaps, IEEE80211_MODE_11G)) { - TESTSETRATE(IEEE80211_MODE_11G, 47); + TESTSETRATE(IEEE80211_MODE_11G, 48); TESTSETRATE(IEEE80211_MODE_11G, 72); TESTSETRATE(IEEE80211_MODE_11G, 96); TESTSETRATE(IEEE80211_MODE_11G, 108); } if (isset(ic->ic_modecaps, IEEE80211_MODE_11A)) { - TESTSETRATE(IEEE80211_MODE_11A, 47); + TESTSETRATE(IEEE80211_MODE_11A, 48); TESTSETRATE(IEEE80211_MODE_11A, 72); TESTSETRATE(IEEE80211_MODE_11A, 96); TESTSETRATE(IEEE80211_MODE_11A, 108); @@ -933,15 +895,9 @@ if (r == 0) ic->ic_caps |= IEEE80211_C_PMGT; bcopy(eaddr, &ic->ic_myaddr, sizeof(eaddr)); -#if __FreeBSD_version < 600007 - ieee80211_ifattach(ifp); - ieee80211_media_init(ifp, ieee80211_media_change, - ndis_media_status); -#else ieee80211_ifattach(ic); ieee80211_media_init(ic, ieee80211_media_change, ndis_media_status); -#endif ic->ic_scan_start = ndis_scan_start; ic->ic_scan_end = ndis_scan_end; ic->ic_set_channel = ndis_set_channel; @@ -1004,11 +960,7 @@ NDIS_UNLOCK(sc); ndis_stop(sc); if (sc->ndis_80211) -#if __FreeBSD_version < 600007 - ieee80211_ifdetach(ifp); -#else ieee80211_ifdetach(&sc->ic); -#endif else ether_ifdetach(ifp); } else @@ -1040,10 +992,8 @@ bus_release_resource(dev, SYS_RES_MEMORY, sc->ndis_altmem_rid, sc->ndis_res_altmem); -#if __FreeBSD_version >= 600031 if (ifp != NULL) if_free(ifp); -#endif if (sc->ndis_iftype == PCMCIABus) ndis_free_amem(sc); @@ -1076,9 +1026,6 @@ bus_dma_tag_destroy(sc->ndis_parent_tag); taskqueue_free(sc->ndis_tq); -#if __FreeBSD_version < 502113 - sysctl_ctx_free(&sc->ndis_ctx); -#endif return(0); } @@ -1699,13 +1646,8 @@ } NDIS_LOCK(sc); #ifdef LINK_STATE_UP -#if __FreeBSD_version > 600006 if_link_state_change(sc->ifp, LINK_STATE_UP); #else - sc->ifp->if_link_state = LINK_STATE_UP; - rt_ifmsg(sc->ifp); -#endif -#else device_printf(sc->ndis_dev, "link state changed to UP\n"); #endif /* LINK_STATE_UP */ } @@ -1716,13 +1658,8 @@ if (sc->ndis_80211) ieee80211_new_state(ic, IEEE80211_S_SCAN, 0); #ifdef LINK_STATE_DOWN -#if __FreeBSD_version > 600006 if_link_state_change(sc->ifp, LINK_STATE_DOWN); #else - sc->ifp->if_link_state = LINK_STATE_DOWN; - rt_ifmsg(sc->ifp); -#endif -#else device_printf(sc->ndis_dev, "link state changed to DOWN\n"); #endif /* LINK_STATE_DOWN */ } @@ -1768,11 +1705,7 @@ ifp = arg; -#if __FreeBSD_version < 502114 - if (ifp->if_snd.ifq_head != NULL) -#else if (!IFQ_DRV_IS_EMPTY(&ifp->if_snd)) -#endif ndis_start(ifp); return; } @@ -1812,11 +1745,7 @@ p0 = &sc->ndis_txarray[sc->ndis_txidx]; while(sc->ndis_txpending) { -#if __FreeBSD_version < 502114 - IF_DEQUEUE(&ifp->if_snd, m); -#else IFQ_DRV_DEQUEUE(&ifp->if_snd, m); -#endif if (m == NULL) break; @@ -1827,13 +1756,8 @@ break; if (ndis_mtop(m, &sc->ndis_txarray[sc->ndis_txidx])) { -#if __FreeBSD_version >= 502114 IFQ_DRV_PREPEND(&ifp->if_snd, m); -#endif NDIS_UNLOCK(sc); -#if __FreeBSD_version < 502114 - IF_PREPEND(&ifp->if_snd, m); -#endif return; } @@ -2002,12 +1926,7 @@ sc->ndis_link = 0; #ifdef LINK_STATE_UNKNOWN -#if __FreeBSD_version > 600006 if_link_state_change(sc->ifp, LINK_STATE_UNKNOWN); -#else - sc->ifp->if_link_state = LINK_STATE_DOWN; - rt_ifmsg(sc->ifp); -#endif #endif /* LINK_STATE_UNKNOWN */ if (ic->ic_opmode != IEEE80211_M_MONITOR) { @@ -2334,15 +2253,10 @@ /* Set WEP */ -#if __FreeBSD_version < 600007 - if (ic->ic_flags & IEEE80211_F_WEPON) { -#else if (ic->ic_flags & IEEE80211_F_PRIVACY && !(ic->ic_flags & IEEE80211_F_WPA)) { -#endif int keys_set = 0; -#if __FreeBSD_version >= 600007 if (ic->ic_bss->ni_authmode == IEEE80211_AUTH_SHARED) { len = sizeof(arg); arg = NDIS_80211_AUTHMODE_SHARED; @@ -2350,14 +2264,11 @@ ndis_set_info(sc, OID_802_11_AUTHENTICATION_MODE, &arg, &len); } -#endif for (i = 0; i < IEEE80211_WEP_NKID; i++) { if (ic->ic_nw_keys[i].wk_keylen) { -#if __FreeBSD_version >= 600007 if (ic->ic_nw_keys[i].wk_cipher->ic_cipher != IEEE80211_CIPHER_WEP) continue; -#endif bzero((char *)&wep, sizeof(wep)); wep.nw_keylen = ic->ic_nw_keys[i].wk_keylen; @@ -2755,7 +2666,6 @@ * reporting isn't supported prior to FreeBSD 6.x. */ -#if __FreeBSD_version >= 600007 len = sizeof(arg); rval = ndis_get_info(sc, OID_802_11_AUTHENTICATION_MODE, &arg, &len); if (rval) @@ -2789,7 +2699,6 @@ break; } } -#endif len = sizeof(arg); rval = ndis_get_info(sc, OID_802_11_WEP_STATUS, &arg, &len); @@ -2798,19 +2707,11 @@ device_printf (sc->ndis_dev, "get wep status failed: %d\n", rval); -#if __FreeBSD_version < 600007 - if (arg == NDIS_80211_WEPSTAT_ENABLED) - ic->ic_flags |= IEEE80211_F_WEPON; - else - ic->ic_flags &= ~IEEE80211_F_WEPON; -#else if (arg == NDIS_80211_WEPSTAT_ENABLED) ic->ic_flags |= IEEE80211_F_PRIVACY|IEEE80211_F_DROPUNENC; else ic->ic_flags &= ~(IEEE80211_F_PRIVACY|IEEE80211_F_DROPUNENC); -#endif - return; } @@ -2867,11 +2768,7 @@ case SIOCGIFMEDIA: case SIOCSIFMEDIA: if (sc->ndis_80211) { -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif if (error == ENETRESET) { ndis_setstate_80211(sc); /*ndis_init(sc);*/ @@ -3003,28 +2900,11 @@ NDIS_EVTINC(sc->ndis_evtcidx); NDIS_UNLOCK(sc); break; -#if __FreeBSD_version < 700046 - case SIOCGIFGENERIC: - case SIOCSIFGENERIC: - if (sc->ndis_80211 && NDIS_INITIALIZED(sc)) { - if (command == SIOCGIFGENERIC) - error = ndis_wi_ioctl_get(ifp, command, data); - else - error = ndis_wi_ioctl_set(ifp, command, data); - } else - error = ENOTTY; - if (error != ENOTTY) - break; -#endif default: do_80211: sc->ndis_skip = 1; if (sc->ndis_80211) { -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif if (error == ENETRESET) { ndis_setstate_80211(sc); error = 0; @@ -3040,126 +2920,6 @@ return(error); } -#if __FreeBSD_version < 700046 -static int -ndis_wi_ioctl_get(ifp, command, data) - struct ifnet *ifp; - u_long command; - caddr_t data; -{ - struct wi_req wreq; - struct ifreq *ifr; - struct ndis_softc *sc; - ndis_80211_bssid_list_ex *bl; - ndis_wlan_bssid_ex *wb; - struct wi_apinfo *api; - int error, i, j, len, maxaps; - - sc = ifp->if_softc; - ifr = (struct ifreq *)data; - error = copyin(ifr->ifr_data, &wreq, sizeof(wreq)); - if (error) - return (error); - - switch (wreq.wi_type) { - case WI_RID_READ_APS: - len = 0; - error = ndis_set_info(sc, OID_802_11_BSSID_LIST_SCAN, - NULL, &len); - if (error == 0) - tsleep(&error, PPAUSE|PCATCH, "ssidscan", hz * 2); - len = 0; - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, NULL, &len); - if (error != ENOSPC) - len = 65536; - bl = malloc(len, M_DEVBUF, M_NOWAIT|M_ZERO); - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); - if (error) { - free(bl, M_DEVBUF); - break; - } - maxaps = (2 * wreq.wi_len - sizeof(int)) / sizeof(*api); - maxaps = MIN(maxaps, bl->nblx_items); - wreq.wi_len = (maxaps * sizeof(*api) + sizeof(int)) / 2; - *(int *)&wreq.wi_val = maxaps; - api = (struct wi_apinfo *)&((int *)&wreq.wi_val)[1]; - wb = bl->nblx_bssid; - while (maxaps--) { - bzero(api, sizeof(*api)); - bcopy(&wb->nwbx_macaddr, &api->bssid, - sizeof(api->bssid)); - api->namelen = wb->nwbx_ssid.ns_ssidlen; - bcopy(&wb->nwbx_ssid.ns_ssid, &api->name, api->namelen); - if (wb->nwbx_privacy) - api->capinfo |= IEEE80211_CAPINFO_PRIVACY; - /* XXX Where can we get noise information? */ - api->signal = wb->nwbx_rssi + 149; /* XXX */ - api->quality = api->signal; - api->channel = - ieee80211_mhz2ieee(wb->nwbx_config.nc_dsconfig / - 1000, 0); - /* In "auto" infrastructure mode, this is useless. */ - if (wb->nwbx_netinfra == NDIS_80211_NET_INFRA_IBSS) - api->capinfo |= IEEE80211_CAPINFO_IBSS; - if (wb->nwbx_len > sizeof(ndis_wlan_bssid)) { - j = sizeof(ndis_80211_rates_ex); - /* handle other extended things */ - } else - j = sizeof(ndis_80211_rates); - for (i = api->rate = 0; i < j; i++) - api->rate = MAX(api->rate, 5 * - (wb->nwbx_supportedrates[i] & 0x7f)); - api++; - wb = (ndis_wlan_bssid_ex *)((char *)wb + wb->nwbx_len); - } - free(bl, M_DEVBUF); - error = copyout(&wreq, ifr->ifr_data, sizeof(wreq)); - break; - default: - error = ENOTTY; - break; - } - return (error); -} - -static int -ndis_wi_ioctl_set(ifp, command, data) - struct ifnet *ifp; - u_long command; - caddr_t data; -{ - struct wi_req wreq; - struct ifreq *ifr; - struct ndis_softc *sc; - uint32_t foo; - int error, len; - - error = priv_check(curthread, PRIV_DRIVER); - if (error) - return (error); - - sc = ifp->if_softc; - ifr = (struct ifreq *)data; - error = copyin(ifr->ifr_data, &wreq, sizeof(wreq)); - if (error) - return (error); - - switch (wreq.wi_type) { - case WI_RID_SCAN_APS: - case WI_RID_SCAN_REQ: /* arguments ignored */ - len = sizeof(foo); - foo = 0; - error = ndis_set_info(sc, OID_802_11_BSSID_LIST_SCAN, &foo, - &len); - break; - default: - error = ENOTTY; - break; - } - return (error); -} -#endif - static int ndis_80211_ioctl_get(struct ifnet *ifp, u_long command, caddr_t data) { @@ -3195,11 +2955,7 @@ RtlFreeAnsiString(&as); break; default: -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif break; } @@ -3362,11 +3118,7 @@ RtlFreeUnicodeString(&us); break; default: -#if __FreeBSD_version < 600007 - error = ieee80211_ioctl(ifp, command, data); -#else error = ieee80211_ioctl(&sc->ic, command, data); -#endif if (error == ENETRESET) { ndis_setstate_80211(sc); error = 0; From laffer1 at midnightbsd.org Mon Jan 19 17:02:26 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:02:26 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/bwi: Add bwi to MidnightBSD. Message-ID: <200901192202.n0JM2QYs074527@stargazer.midnightbsd.org> Log Message: ----------- Add bwi to MidnightBSD. bwi is a very limited broadcom wireless nic adapter from DragonFly, NetBSD, and OpenBSD. This is not connected to the build and requires a firmware which is hard to come by. Added Files: ----------- src/sys/dev/bwi: bitops.h (r1.1) bwimac.c (r1.1) bwimac.h (r1.1) bwiphy.c (r1.1) bwiphy.h (r1.1) bwirf.c (r1.1) bwirf.h (r1.1) if_bwi.c (r1.1) if_bwi_pci.c (r1.1) if_bwireg.h (r1.1) if_bwivar.h (r1.1) -------------- next part -------------- --- /dev/null +++ sys/dev/bwi/bwiphy.h @@ -0,0 +1,224 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwiphy.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwiphy.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BWI_PHY_H +#define _BWI_PHY_H + +struct bwi_gains { + int16_t tbl_gain1; + int16_t tbl_gain2; + int16_t phy_gain; +}; + +int bwi_phy_attach(struct bwi_mac *); +void bwi_phy_clear_state(struct bwi_phy *); + +int bwi_phy_calibrate(struct bwi_mac *); +void bwi_phy_set_bbp_atten(struct bwi_mac *, uint16_t); + +void bwi_set_gains(struct bwi_mac *, const struct bwi_gains *); +int16_t bwi_nrssi_read(struct bwi_mac *, uint16_t); +void bwi_nrssi_write(struct bwi_mac *, uint16_t, int16_t); + +uint16_t bwi_phy_read(struct bwi_mac *, uint16_t); +void bwi_phy_write(struct bwi_mac *, uint16_t, uint16_t); + +static __inline void +bwi_phy_init(struct bwi_mac *_mac) +{ + _mac->mac_phy.phy_init(_mac); +} + +#define PHY_WRITE(mac, ctrl, val) bwi_phy_write((mac), (ctrl), (val)) +#define PHY_READ(mac, ctrl) bwi_phy_read((mac), (ctrl)) + +#define PHY_SETBITS(mac, ctrl, bits) \ + PHY_WRITE((mac), (ctrl), PHY_READ((mac), (ctrl)) | (bits)) +#define PHY_CLRBITS(mac, ctrl, bits) \ + PHY_WRITE((mac), (ctrl), PHY_READ((mac), (ctrl)) & ~(bits)) +#define PHY_FILT_SETBITS(mac, ctrl, filt, bits) \ + PHY_WRITE((mac), (ctrl), (PHY_READ((mac), (ctrl)) & (filt)) | (bits)) + +#define BWI_PHYR_NRSSI_THR_11B 0x020 +#define BWI_PHYR_BBP_ATTEN 0x060 +#define BWI_PHYR_TBL_CTRL_11A 0x072 +#define BWI_PHYR_TBL_DATA_LO_11A 0x073 +#define BWI_PHYR_TBL_DATA_HI_11A 0x074 +#define BWI_PHYR_TBL_CTRL_11G 0x472 +#define BWI_PHYR_TBL_DATA_LO_11G 0x473 +#define BWI_PHYR_TBL_DATA_HI_11G 0x474 +#define BWI_PHYR_NRSSI_THR_11G 0x48a +#define BWI_PHYR_NRSSI_CTRL 0x803 +#define BWI_PHYR_NRSSI_DATA 0x804 +#define BWI_PHYR_RF_LO 0x810 + +/* + * PHY Tables + */ +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/FineFrequency + * G PHY + */ +#define BWI_PHY_FREQ_11G_REV1 \ + 0x0089, 0x02e9, 0x0409, 0x04e9, 0x05a9, 0x0669, 0x0709, 0x0789, \ + 0x0829, 0x08a9, 0x0929, 0x0989, 0x0a09, 0x0a69, 0x0ac9, 0x0b29, \ + 0x0ba9, 0x0be9, 0x0c49, 0x0ca9, 0x0d09, 0x0d69, 0x0da9, 0x0e09, \ + 0x0e69, 0x0ea9, 0x0f09, 0x0f49, 0x0fa9, 0x0fe9, 0x1029, 0x1089, \ + 0x10c9, 0x1109, 0x1169, 0x11a9, 0x11e9, 0x1229, 0x1289, 0x12c9, \ + 0x1309, 0x1349, 0x1389, 0x13c9, 0x1409, 0x1449, 0x14a9, 0x14e9, \ + 0x1529, 0x1569, 0x15a9, 0x15e9, 0x1629, 0x1669, 0x16a9, 0x16e8, \ + 0x1728, 0x1768, 0x17a8, 0x17e8, 0x1828, 0x1868, 0x18a8, 0x18e8, \ + 0x1928, 0x1968, 0x19a8, 0x19e8, 0x1a28, 0x1a68, 0x1aa8, 0x1ae8, \ + 0x1b28, 0x1b68, 0x1ba8, 0x1be8, 0x1c28, 0x1c68, 0x1ca8, 0x1ce8, \ + 0x1d28, 0x1d68, 0x1dc8, 0x1e08, 0x1e48, 0x1e88, 0x1ec8, 0x1f08, \ + 0x1f48, 0x1f88, 0x1fe8, 0x2028, 0x2068, 0x20a8, 0x2108, 0x2148, \ + 0x2188, 0x21c8, 0x2228, 0x2268, 0x22c8, 0x2308, 0x2348, 0x23a8, \ + 0x23e8, 0x2448, 0x24a8, 0x24e8, 0x2548, 0x25a8, 0x2608, 0x2668, \ + 0x26c8, 0x2728, 0x2787, 0x27e7, 0x2847, 0x28c7, 0x2947, 0x29a7, \ + 0x2a27, 0x2ac7, 0x2b47, 0x2be7, 0x2ca7, 0x2d67, 0x2e47, 0x2f67, \ + 0x3247, 0x3526, 0x3646, 0x3726, 0x3806, 0x38a6, 0x3946, 0x39e6, \ + 0x3a66, 0x3ae6, 0x3b66, 0x3bc6, 0x3c45, 0x3ca5, 0x3d05, 0x3d85, \ + 0x3de5, 0x3e45, 0x3ea5, 0x3ee5, 0x3f45, 0x3fa5, 0x4005, 0x4045, \ + 0x40a5, 0x40e5, 0x4145, 0x4185, 0x41e5, 0x4225, 0x4265, 0x42c5, \ + 0x4305, 0x4345, 0x43a5, 0x43e5, 0x4424, 0x4464, 0x44c4, 0x4504, \ + 0x4544, 0x4584, 0x45c4, 0x4604, 0x4644, 0x46a4, 0x46e4, 0x4724, \ + 0x4764, 0x47a4, 0x47e4, 0x4824, 0x4864, 0x48a4, 0x48e4, 0x4924, \ + 0x4964, 0x49a4, 0x49e4, 0x4a24, 0x4a64, 0x4aa4, 0x4ae4, 0x4b23, \ + 0x4b63, 0x4ba3, 0x4be3, 0x4c23, 0x4c63, 0x4ca3, 0x4ce3, 0x4d23, \ + 0x4d63, 0x4da3, 0x4de3, 0x4e23, 0x4e63, 0x4ea3, 0x4ee3, 0x4f23, \ + 0x4f63, 0x4fc3, 0x5003, 0x5043, 0x5083, 0x50c3, 0x5103, 0x5143, \ + 0x5183, 0x51e2, 0x5222, 0x5262, 0x52a2, 0x52e2, 0x5342, 0x5382, \ + 0x53c2, 0x5402, 0x5462, 0x54a2, 0x5502, 0x5542, 0x55a2, 0x55e2, \ + 0x5642, 0x5682, 0x56e2, 0x5722, 0x5782, 0x57e1, 0x5841, 0x58a1, \ + 0x5901, 0x5961, 0x59c1, 0x5a21, 0x5aa1, 0x5b01, 0x5b81, 0x5be1, \ + 0x5c61, 0x5d01, 0x5d80, 0x5e20, 0x5ee0, 0x5fa0, 0x6080, 0x61c0 + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/noise_table + */ +/* G PHY Revision 1 */ +#define BWI_PHY_NOISE_11G_REV1 \ + 0x013c, 0x01f5, 0x031a, 0x0631, 0x0001, 0x0001, 0x0001, 0x0001 +/* G PHY generic */ +#define BWI_PHY_NOISE_11G \ + 0x5484, 0x3c40, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000, 0x0000 + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/rotor_table + * G PHY Revision 1 + */ +#define BWI_PHY_ROTOR_11G_REV1 \ + 0xfeb93ffd, 0xfec63ffd, 0xfed23ffd, 0xfedf3ffd, \ + 0xfeec3ffe, 0xfef83ffe, 0xff053ffe, 0xff113ffe, \ + 0xff1e3ffe, 0xff2a3fff, 0xff373fff, 0xff443fff, \ + 0xff503fff, 0xff5d3fff, 0xff693fff, 0xff763fff, \ + 0xff824000, 0xff8f4000, 0xff9b4000, 0xffa84000, \ + 0xffb54000, 0xffc14000, 0xffce4000, 0xffda4000, \ + 0xffe74000, 0xfff34000, 0x00004000, 0x000d4000, \ + 0x00194000, 0x00264000, 0x00324000, 0x003f4000, \ + 0x004b4000, 0x00584000, 0x00654000, 0x00714000, \ + 0x007e4000, 0x008a3fff, 0x00973fff, 0x00a33fff, \ + 0x00b03fff, 0x00bc3fff, 0x00c93fff, 0x00d63fff, \ + 0x00e23ffe, 0x00ef3ffe, 0x00fb3ffe, 0x01083ffe, \ + 0x01143ffe, 0x01213ffd, 0x012e3ffd, 0x013a3ffd, \ + 0x01473ffd + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/noise_scale_table + */ +/* G PHY Revision [0,2] */ +#define BWI_PHY_NOISE_SCALE_11G_REV2 \ + 0x6c77, 0x5162, 0x3b40, 0x3335, 0x2f2d, 0x2a2a, 0x2527, 0x1f21, \ + 0x1a1d, 0x1719, 0x1616, 0x1414, 0x1414, 0x1400, 0x1414, 0x1614, \ + 0x1716, 0x1a19, 0x1f1d, 0x2521, 0x2a27, 0x2f2a, 0x332d, 0x3b35, \ + 0x5140, 0x6c62, 0x0077 +/* G PHY Revsion 7 */ +#define BWI_PHY_NOISE_SCALE_11G_REV7 \ + 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, \ + 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa400, 0xa4a4, 0xa4a4, \ + 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, 0xa4a4, \ + 0xa4a4, 0xa4a4, 0x00a4 +/* G PHY generic */ +#define BWI_PHY_NOISE_SCALE_11G \ + 0xd8dd, 0xcbd4, 0xbcc0, 0xb6b7, 0xb2b0, 0xadad, 0xa7a9, 0x9fa1, \ + 0x969b, 0x9195, 0x8f8f, 0x8a8a, 0x8a8a, 0x8a00, 0x8a8a, 0x8f8a, \ + 0x918f, 0x9695, 0x9f9b, 0xa7a1, 0xada9, 0xb2ad, 0xb6b0, 0xbcb7, \ + 0xcbc0, 0xd8d4, 0x00dd + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/sigma_square_table + */ +/* G PHY Revision 2 */ +#define BWI_PHY_SIGMA_SQ_11G_REV2 \ + 0x007a, 0x0075, 0x0071, 0x006c, 0x0067, 0x0063, 0x005e, 0x0059, \ + 0x0054, 0x0050, 0x004b, 0x0046, 0x0042, 0x003d, 0x003d, 0x003d, \ + 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, \ + 0x003d, 0x003d, 0x0000, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, \ + 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, 0x003d, \ + 0x0042, 0x0046, 0x004b, 0x0050, 0x0054, 0x0059, 0x005e, 0x0063, \ + 0x0067, 0x006c, 0x0071, 0x0075, 0x007a +/* G PHY Revision (2,7] */ +#define BWI_PHY_SIGMA_SQ_11G_REV7 \ + 0x00de, 0x00dc, 0x00da, 0x00d8, 0x00d6, 0x00d4, 0x00d2, 0x00cf, \ + 0x00cd, 0x00ca, 0x00c7, 0x00c4, 0x00c1, 0x00be, 0x00be, 0x00be, \ + 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, \ + 0x00be, 0x00be, 0x0000, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, \ + 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, 0x00be, \ + 0x00c1, 0x00c4, 0x00c7, 0x00ca, 0x00cd, 0x00cf, 0x00d2, 0x00d4, \ + 0x00d6, 0x00d8, 0x00da, 0x00dc, 0x00de + +/* + * http://bcm-specs.sipsolutions.net/APHYSetup/retard_table + * G PHY + */ +#define BWI_PHY_DELAY_11G_REV1 \ + 0xdb93cb87, 0xd666cf64, 0xd1fdd358, 0xcda6d826, \ + 0xca38dd9f, 0xc729e2b4, 0xc469e88e, 0xc26aee2b, \ + 0xc0def46c, 0xc073fa62, 0xc01d00d5, 0xc0760743, \ + 0xc1560d1e, 0xc2e51369, 0xc4ed18ff, 0xc7ac1ed7, \ + 0xcb2823b2, 0xcefa28d9, 0xd2f62d3f, 0xd7bb3197, \ + 0xdce53568, 0xe1fe3875, 0xe7d13b35, 0xed663d35, \ + 0xf39b3ec4, 0xf98e3fa7, 0x00004000, 0x06723fa7, \ + 0x0c653ec4, 0x129a3d35, 0x182f3b35, 0x1e023875, \ + 0x231b3568, 0x28453197, 0x2d0a2d3f, 0x310628d9, \ + 0x34d823b2, 0x38541ed7, 0x3b1318ff, 0x3d1b1369, \ + 0x3eaa0d1e, 0x3f8a0743, 0x3fe300d5, 0x3f8dfa62, \ + 0x3f22f46c, 0x3d96ee2b, 0x3b97e88e, 0x38d7e2b4, \ + 0x35c8dd9f, 0x325ad826, 0x2e03d358, 0x299acf64, \ + 0x246dcb87 + +#endif /* !_BWI_PHY_H */ --- /dev/null +++ sys/dev/bwi/bwirf.c @@ -0,0 +1,2497 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwirf.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwirf.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" +#include "bwiphy.h" + +#define RF_LO_WRITE(mac, lo) bwi_rf_lo_write((mac), (lo)) + +#define BWI_RF_2GHZ_CHAN(chan) \ + (ieee80211_ieee2mhz((chan), IEEE80211_CHAN_2GHZ) - 2400) + +#define BWI_DEFAULT_IDLE_TSSI 52 + +struct rf_saveregs { + uint16_t phy_15; + uint16_t phy_2a; + uint16_t phy_35; + uint16_t phy_60; + uint16_t phy_429; + uint16_t phy_802; + uint16_t phy_811; + uint16_t phy_812; + uint16_t phy_814; + uint16_t phy_815; + + uint16_t rf_43; + uint16_t rf_52; + uint16_t rf_7a; +}; + +#define SAVE_RF_REG(mac, regs, n) (regs)->rf_##n = RF_READ((mac), 0x##n) +#define RESTORE_RF_REG(mac, regs, n) RF_WRITE((mac), 0x##n, (regs)->rf_##n) + +#define SAVE_PHY_REG(mac, regs, n) (regs)->phy_##n = PHY_READ((mac), 0x##n) +#define RESTORE_PHY_REG(mac, regs, n) PHY_WRITE((mac), 0x##n, (regs)->phy_##n) + +static int bwi_rf_calc_txpower(int8_t *, uint8_t, const int16_t[]); +static void bwi_rf_work_around(struct bwi_mac *, u_int); +static int bwi_rf_gain_max_reached(struct bwi_mac *, int); +static uint16_t bwi_rf_calibval(struct bwi_mac *); +static uint16_t bwi_rf_get_tp_ctrl2(struct bwi_mac *); +static uint32_t bwi_rf_lo_devi_measure(struct bwi_mac *, uint16_t); +static void bwi_rf_lo_measure(struct bwi_mac *, + const struct bwi_rf_lo *, struct bwi_rf_lo *, uint8_t); +static uint8_t _bwi_rf_lo_update(struct bwi_mac *, uint16_t); + +static void bwi_rf_lo_write(struct bwi_mac *, const struct bwi_rf_lo *); + +static void bwi_rf_set_nrssi_ofs_11g(struct bwi_mac *); +static void bwi_rf_calc_nrssi_slope_11b(struct bwi_mac *); +static void bwi_rf_calc_nrssi_slope_11g(struct bwi_mac *); +static void bwi_rf_set_nrssi_thr_11b(struct bwi_mac *); +static void bwi_rf_set_nrssi_thr_11g(struct bwi_mac *); + +static void bwi_rf_init_sw_nrssi_table(struct bwi_mac *); + +static int bwi_rf_calc_rssi_bcm2050(struct bwi_mac *, + const struct bwi_rxbuf_hdr *); +static int bwi_rf_calc_rssi_bcm2053(struct bwi_mac *, + const struct bwi_rxbuf_hdr *); +static int bwi_rf_calc_rssi_bcm2060(struct bwi_mac *, + const struct bwi_rxbuf_hdr *); + +static void bwi_rf_on_11a(struct bwi_mac *); +static void bwi_rf_on_11bg(struct bwi_mac *); + +static void bwi_rf_off_11a(struct bwi_mac *); +static void bwi_rf_off_11bg(struct bwi_mac *); +static void bwi_rf_off_11g_rev5(struct bwi_mac *); + +static const int8_t bwi_txpower_map_11b[BWI_TSSI_MAX] = + { BWI_TXPOWER_MAP_11B }; +static const int8_t bwi_txpower_map_11g[BWI_TSSI_MAX] = + { BWI_TXPOWER_MAP_11G }; + +static __inline int16_t +bwi_nrssi_11g(struct bwi_mac *mac) +{ + int16_t val; + +#define NRSSI_11G_MASK __BITS(13, 8) + + val = (int16_t)__SHIFTOUT(PHY_READ(mac, 0x47f), NRSSI_11G_MASK); + if (val >= 32) + val -= 64; + return val; + +#undef NRSSI_11G_MASK +} + +static __inline struct bwi_rf_lo * +bwi_get_rf_lo(struct bwi_mac *mac, uint16_t rf_atten, uint16_t bbp_atten) +{ + int n; + + n = rf_atten + (14 * (bbp_atten / 2)); + KASSERT(n < BWI_RFLO_MAX, ("n %d", n)); + + return &mac->mac_rf.rf_lo[n]; +} + +static __inline int +bwi_rf_lo_isused(struct bwi_mac *mac, const struct bwi_rf_lo *lo) +{ + struct bwi_rf *rf = &mac->mac_rf; + int idx; + + idx = lo - rf->rf_lo; + KASSERT(idx >= 0 && idx < BWI_RFLO_MAX, ("idx %d", idx)); + + return isset(rf->rf_lo_used, idx); +} + +void +bwi_rf_write(struct bwi_mac *mac, uint16_t ctrl, uint16_t data) +{ + struct bwi_softc *sc = mac->mac_sc; + + CSR_WRITE_2(sc, BWI_RF_CTRL, ctrl); + CSR_WRITE_2(sc, BWI_RF_DATA_LO, data); +} + +uint16_t +bwi_rf_read(struct bwi_mac *mac, uint16_t ctrl) +{ + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_softc *sc = mac->mac_sc; + + ctrl |= rf->rf_ctrl_rd; + if (rf->rf_ctrl_adj) { + /* XXX */ + if (ctrl < 0x70) + ctrl += 0x80; + else if (ctrl < 0x80) + ctrl += 0x70; + } + + CSR_WRITE_2(sc, BWI_RF_CTRL, ctrl); + return CSR_READ_2(sc, BWI_RF_DATA_LO); +} + +int +bwi_rf_attach(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t type, manu; + uint8_t rev; + + /* + * Get RF manufacture/type/revision + */ + if (sc->sc_bbp_id == BWI_BBPID_BCM4317) { + /* + * Fake a BCM2050 RF + */ + manu = BWI_RF_MANUFACT_BCM; + type = BWI_RF_T_BCM2050; + if (sc->sc_bbp_rev == 0) + rev = 3; + else if (sc->sc_bbp_rev == 1) + rev = 4; + else + rev = 5; + } else { + uint32_t val; + + CSR_WRITE_2(sc, BWI_RF_CTRL, BWI_RF_CTRL_RFINFO); + val = CSR_READ_2(sc, BWI_RF_DATA_HI); + val <<= 16; + + CSR_WRITE_2(sc, BWI_RF_CTRL, BWI_RF_CTRL_RFINFO); + val |= CSR_READ_2(sc, BWI_RF_DATA_LO); + + manu = __SHIFTOUT(val, BWI_RFINFO_MANUFACT_MASK); + type = __SHIFTOUT(val, BWI_RFINFO_TYPE_MASK); + rev = __SHIFTOUT(val, BWI_RFINFO_REV_MASK); + } + device_printf(sc->sc_dev, "RF: manu 0x%03x, type 0x%04x, rev %u\n", + manu, type, rev); + + /* + * Verify whether the RF is supported + */ + rf->rf_ctrl_rd = 0; + rf->rf_ctrl_adj = 0; + switch (mac->mac_phy.phy_mode) { + case IEEE80211_MODE_11A: + if (manu != BWI_RF_MANUFACT_BCM || + type != BWI_RF_T_BCM2060 || + rev != 1) { + device_printf(sc->sc_dev, "only BCM2060 rev 1 RF " + "is supported for 11A PHY\n"); + return ENXIO; + } + rf->rf_ctrl_rd = BWI_RF_CTRL_RD_11A; + rf->rf_on = bwi_rf_on_11a; + rf->rf_off = bwi_rf_off_11a; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2060; + break; + case IEEE80211_MODE_11B: + if (type == BWI_RF_T_BCM2050) { + rf->rf_ctrl_rd = BWI_RF_CTRL_RD_11BG; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2050; + } else if (type == BWI_RF_T_BCM2053) { + rf->rf_ctrl_adj = 1; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2053; + } else { + device_printf(sc->sc_dev, "only BCM2050/BCM2053 RF " + "is supported for 11B PHY\n"); + return ENXIO; + } + rf->rf_on = bwi_rf_on_11bg; + rf->rf_off = bwi_rf_off_11bg; + rf->rf_calc_nrssi_slope = bwi_rf_calc_nrssi_slope_11b; + rf->rf_set_nrssi_thr = bwi_rf_set_nrssi_thr_11b; + break; + case IEEE80211_MODE_11G: + if (type != BWI_RF_T_BCM2050) { + device_printf(sc->sc_dev, "only BCM2050 RF " + "is supported for 11G PHY\n"); + return ENXIO; + } + rf->rf_ctrl_rd = BWI_RF_CTRL_RD_11BG; + rf->rf_on = bwi_rf_on_11bg; + if (mac->mac_rev >= 5) + rf->rf_off = bwi_rf_off_11g_rev5; + else + rf->rf_off = bwi_rf_off_11bg; + rf->rf_calc_nrssi_slope = bwi_rf_calc_nrssi_slope_11g; + rf->rf_set_nrssi_thr = bwi_rf_set_nrssi_thr_11g; + rf->rf_calc_rssi = bwi_rf_calc_rssi_bcm2050; + break; + default: + device_printf(sc->sc_dev, "unsupported PHY mode\n"); + return ENXIO; + } + + rf->rf_type = type; + rf->rf_rev = rev; + rf->rf_manu = manu; + rf->rf_curchan = IEEE80211_CHAN_ANY; + rf->rf_ant_mode = BWI_ANT_MODE_AUTO; + return 0; +} + +void +bwi_rf_set_chan(struct bwi_mac *mac, u_int chan, int work_around) +{ + struct bwi_softc *sc = mac->mac_sc; + + if (chan == IEEE80211_CHAN_ANY) + return; + + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_CHAN, chan); + + /* TODO: 11A */ + + if (work_around) + bwi_rf_work_around(mac, chan); + + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(chan)); + + if (chan == 14) { + if (sc->sc_locale == BWI_SPROM_LOCALE_JAPAN) + HFLAGS_CLRBITS(mac, BWI_HFLAG_NOT_JAPAN); + else + HFLAGS_SETBITS(mac, BWI_HFLAG_NOT_JAPAN); + CSR_SETBITS_2(sc, BWI_RF_CHAN_EX, (1 << 11)); /* XXX */ + } else { + CSR_CLRBITS_2(sc, BWI_RF_CHAN_EX, 0x840); /* XXX */ + } + DELAY(8000); /* DELAY(2000); */ + + mac->mac_rf.rf_curchan = chan; +} + +void +bwi_rf_get_gains(struct bwi_mac *mac) +{ +#define SAVE_PHY_MAX 15 +#define SAVE_RF_MAX 3 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x52, 0x43, 0x7a }; + static const uint16_t save_phy_regs[SAVE_PHY_MAX] = { + 0x0429, 0x0001, 0x0811, 0x0812, + 0x0814, 0x0815, 0x005a, 0x0059, + 0x0058, 0x000a, 0x0003, 0x080f, + 0x0810, 0x002b, 0x0015 + }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t save_phy[SAVE_PHY_MAX]; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t trsw; + int i, j, loop1_max, loop1, loop2; + + /* + * Save PHY/RF registers for later restoration + */ + for (i = 0; i < SAVE_PHY_MAX; ++i) + save_phy[i] = PHY_READ(mac, save_phy_regs[i]); + PHY_READ(mac, 0x2d); /* dummy read */ + + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + + PHY_CLRBITS(mac, 0x429, 0xc000); + PHY_SETBITS(mac, 0x1, 0x8000); + + PHY_SETBITS(mac, 0x811, 0x2); + PHY_CLRBITS(mac, 0x812, 0x2); + PHY_SETBITS(mac, 0x811, 0x1); + PHY_CLRBITS(mac, 0x812, 0x1); + + PHY_SETBITS(mac, 0x814, 0x1); + PHY_CLRBITS(mac, 0x815, 0x1); + PHY_SETBITS(mac, 0x814, 0x2); + PHY_CLRBITS(mac, 0x815, 0x2); + + PHY_SETBITS(mac, 0x811, 0xc); + PHY_SETBITS(mac, 0x812, 0xc); + PHY_SETBITS(mac, 0x811, 0x30); + PHY_FILT_SETBITS(mac, 0x812, 0xffcf, 0x10); + + PHY_WRITE(mac, 0x5a, 0x780); + PHY_WRITE(mac, 0x59, 0xc810); + PHY_WRITE(mac, 0x58, 0xd); + PHY_SETBITS(mac, 0xa, 0x2000); + + PHY_SETBITS(mac, 0x814, 0x4); + PHY_CLRBITS(mac, 0x815, 0x4); + + PHY_FILT_SETBITS(mac, 0x3, 0xff9f, 0x40); + + if (rf->rf_rev == 8) { + loop1_max = 15; + RF_WRITE(mac, 0x43, loop1_max); + } else { + loop1_max = 9; + RF_WRITE(mac, 0x52, 0x0); + RF_FILT_SETBITS(mac, 0x43, 0xfff0, loop1_max); + } + + bwi_phy_set_bbp_atten(mac, 11); + + if (phy->phy_rev >= 3) + PHY_WRITE(mac, 0x80f, 0xc020); + else + PHY_WRITE(mac, 0x80f, 0x8020); + PHY_WRITE(mac, 0x810, 0); + + PHY_FILT_SETBITS(mac, 0x2b, 0xffc0, 0x1); + PHY_FILT_SETBITS(mac, 0x2b, 0xc0ff, 0x800); + PHY_SETBITS(mac, 0x811, 0x100); + PHY_CLRBITS(mac, 0x812, 0x3000); + + if ((sc->sc_card_flags & BWI_CARD_F_EXT_LNA) && + phy->phy_rev >= 7) { + PHY_SETBITS(mac, 0x811, 0x800); + PHY_SETBITS(mac, 0x812, 0x8000); + } + RF_CLRBITS(mac, 0x7a, 0xff08); + + /* + * Find out 'loop1/loop2', which will be used to calculate + * max loopback gain later + */ + j = 0; + for (i = 0; i < loop1_max; ++i) { + for (j = 0; j < 16; ++j) { + RF_WRITE(mac, 0x43, i); + + if (bwi_rf_gain_max_reached(mac, j)) + goto loop1_exit; + } + } +loop1_exit: + loop1 = i; + loop2 = j; + + /* + * Find out 'trsw', which will be used to calculate + * TRSW(TX/RX switch) RX gain later + */ + if (loop2 >= 8) { + PHY_SETBITS(mac, 0x812, 0x30); + trsw = 0x1b; + for (i = loop2 - 8; i < 16; ++i) { + trsw -= 3; + if (bwi_rf_gain_max_reached(mac, i)) + break; + } + } else { + trsw = 0x18; + } + + /* + * Restore saved PHY/RF registers + */ + /* First 4 saved PHY registers need special processing */ + for (i = 4; i < SAVE_PHY_MAX; ++i) + PHY_WRITE(mac, save_phy_regs[i], save_phy[i]); + + bwi_phy_set_bbp_atten(mac, mac->mac_tpctl.bbp_atten); + + for (i = 0; i < SAVE_RF_MAX; ++i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + PHY_WRITE(mac, save_phy_regs[2], save_phy[2] | 0x3); + DELAY(10); + PHY_WRITE(mac, save_phy_regs[2], save_phy[2]); + PHY_WRITE(mac, save_phy_regs[3], save_phy[3]); + PHY_WRITE(mac, save_phy_regs[0], save_phy[0]); + PHY_WRITE(mac, save_phy_regs[1], save_phy[1]); + + /* + * Calculate gains + */ + rf->rf_lo_gain = (loop2 * 6) - (loop1 * 4) - 11; + rf->rf_rx_gain = trsw * 2; + DPRINTF(mac->mac_sc, "lo gain: %u, rx gain: %u\n", + rf->rf_lo_gain, rf->rf_rx_gain); + +#undef SAVE_RF_MAX +#undef SAVE_PHY_MAX +} + +void +bwi_rf_init(struct bwi_mac *mac) +{ + struct bwi_rf *rf = &mac->mac_rf; + + if (rf->rf_type == BWI_RF_T_BCM2060) { + /* TODO: 11A */ + } else { + if (rf->rf_flags & BWI_RF_F_INITED) + RF_WRITE(mac, 0x78, rf->rf_calib); + else + bwi_rf_init_bcm2050(mac); + } +} + +static void +bwi_rf_off_11a(struct bwi_mac *mac) +{ + RF_WRITE(mac, 0x4, 0xff); + RF_WRITE(mac, 0x5, 0xfb); + + PHY_SETBITS(mac, 0x10, 0x8); + PHY_SETBITS(mac, 0x11, 0x8); + + PHY_WRITE(mac, 0x15, 0xaa00); +} + +static void +bwi_rf_off_11bg(struct bwi_mac *mac) +{ + PHY_WRITE(mac, 0x15, 0xaa00); +} + +static void +bwi_rf_off_11g_rev5(struct bwi_mac *mac) +{ + PHY_SETBITS(mac, 0x811, 0x8c); + PHY_CLRBITS(mac, 0x812, 0x8c); +} + +static void +bwi_rf_work_around(struct bwi_mac *mac, u_int chan) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + + if (chan == IEEE80211_CHAN_ANY) { + device_printf(sc->sc_dev, "%s invalid channel!!\n", __func__); + return; + } + + if (rf->rf_type != BWI_RF_T_BCM2050 || rf->rf_rev >= 6) + return; + + if (chan <= 10) + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(chan + 4)); + else + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(1)); + DELAY(1000); + CSR_WRITE_2(sc, BWI_RF_CHAN, BWI_RF_2GHZ_CHAN(chan)); +} + +static __inline struct bwi_rf_lo * +bwi_rf_lo_find(struct bwi_mac *mac, const struct bwi_tpctl *tpctl) +{ + uint16_t rf_atten, bbp_atten; + int remap_rf_atten; + + remap_rf_atten = 1; + if (tpctl == NULL) { + bbp_atten = 2; + rf_atten = 3; + } else { + if (tpctl->tp_ctrl1 == 3) + remap_rf_atten = 0; + + bbp_atten = tpctl->bbp_atten; + rf_atten = tpctl->rf_atten; + + if (bbp_atten > 6) + bbp_atten = 6; + } + + if (remap_rf_atten) { +#define MAP_MAX 10 + static const uint16_t map[MAP_MAX] = + { 11, 10, 11, 12, 13, 12, 13, 12, 13, 12 }; + +#if 0 + KASSERT(rf_atten < MAP_MAX, ("rf_atten %d", rf_atten)); + rf_atten = map[rf_atten]; +#else + if (rf_atten >= MAP_MAX) { + rf_atten = 0; /* XXX */ + } else { + rf_atten = map[rf_atten]; + } +#endif +#undef MAP_MAX + } + + return bwi_get_rf_lo(mac, rf_atten, bbp_atten); +} + +void +bwi_rf_lo_adjust(struct bwi_mac *mac, const struct bwi_tpctl *tpctl) +{ + const struct bwi_rf_lo *lo; + + lo = bwi_rf_lo_find(mac, tpctl); + RF_LO_WRITE(mac, lo); +} + +static void +bwi_rf_lo_write(struct bwi_mac *mac, const struct bwi_rf_lo *lo) +{ + uint16_t val; + + val = (uint8_t)lo->ctrl_lo; + val |= ((uint8_t)lo->ctrl_hi) << 8; + + PHY_WRITE(mac, BWI_PHYR_RF_LO, val); +} + +static int +bwi_rf_gain_max_reached(struct bwi_mac *mac, int idx) +{ + PHY_FILT_SETBITS(mac, 0x812, 0xf0ff, idx << 8); + PHY_FILT_SETBITS(mac, 0x15, 0xfff, 0xa000); + PHY_SETBITS(mac, 0x15, 0xf000); + + DELAY(20); + + return (PHY_READ(mac, 0x2d) >= 0xdfc); +} + +/* XXX use bitmap array */ +static __inline uint16_t +bitswap4(uint16_t val) +{ + uint16_t ret; + + ret = (val & 0x8) >> 3; + ret |= (val & 0x4) >> 1; + ret |= (val & 0x2) << 1; + ret |= (val & 0x1) << 3; + return ret; +} + +static __inline uint16_t +bwi_phy812_value(struct bwi_mac *mac, uint16_t lpd) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t lo_gain, ext_lna, loop; + + if ((phy->phy_flags & BWI_PHY_F_LINKED) == 0) + return 0; + + lo_gain = rf->rf_lo_gain; + if (rf->rf_rev == 8) + lo_gain += 0x3e; + else + lo_gain += 0x26; + + if (lo_gain >= 0x46) { + lo_gain -= 0x46; + ext_lna = 0x3000; + } else if (lo_gain >= 0x3a) { + lo_gain -= 0x3a; + ext_lna = 0x1000; + } else if (lo_gain >= 0x2e) { + lo_gain -= 0x2e; + ext_lna = 0x2000; + } else { + lo_gain -= 0x10; + ext_lna = 0; + } + + for (loop = 0; loop < 16; ++loop) { + lo_gain -= (6 * loop); + if (lo_gain < 6) + break; + } + + if (phy->phy_rev >= 7 && (sc->sc_card_flags & BWI_CARD_F_EXT_LNA)) { + if (ext_lna) + ext_lna |= 0x8000; + ext_lna |= (loop << 8); + switch (lpd) { + case 0x011: + return 0x8f92; + case 0x001: + return (0x8092 | ext_lna); + case 0x101: + return (0x2092 | ext_lna); + case 0x100: + return (0x2093 | ext_lna); + default: + panic("unsupported lpd\n"); + } + } else { + ext_lna |= (loop << 8); + switch (lpd) { + case 0x011: + return 0xf92; + case 0x001: + case 0x101: + return (0x92 | ext_lna); + case 0x100: + return (0x93 | ext_lna); + default: + panic("unsupported lpd\n"); + } + } + + panic("never reached\n"); + return 0; +} + +void +bwi_rf_init_bcm2050(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 3 +#define SAVE_PHY_COMM_MAX 4 +#define SAVE_PHY_11G_MAX 6 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x0043, 0x0051, 0x0052 }; + static const uint16_t save_phy_regs_comm[SAVE_PHY_COMM_MAX] = + { 0x0015, 0x005a, 0x0059, 0x0058 }; + static const uint16_t save_phy_regs_11g[SAVE_PHY_11G_MAX] = + { 0x0811, 0x0812, 0x0814, 0x0815, 0x0429, 0x0802 }; + + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy_comm[SAVE_PHY_COMM_MAX]; + uint16_t save_phy_11g[SAVE_PHY_11G_MAX]; + uint16_t phyr_35, phyr_30 = 0, rfr_78, phyr_80f = 0, phyr_810 = 0; + uint16_t bphy_ctrl = 0, bbp_atten, rf_chan_ex; + uint16_t phy812_val; + uint16_t calib; + uint32_t test_lim, test; + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + int i; + + /* + * Save registers for later restoring + */ + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + save_phy_comm[i] = PHY_READ(mac, save_phy_regs_comm[i]); + + if (phy->phy_mode == IEEE80211_MODE_11B) { + phyr_30 = PHY_READ(mac, 0x30); + bphy_ctrl = CSR_READ_2(sc, BWI_BPHY_CTRL); + + PHY_WRITE(mac, 0x30, 0xff); + CSR_WRITE_2(sc, BWI_BPHY_CTRL, 0x3f3f); + } else if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + for (i = 0; i < SAVE_PHY_11G_MAX; ++i) { + save_phy_11g[i] = + PHY_READ(mac, save_phy_regs_11g[i]); + } + + PHY_SETBITS(mac, 0x814, 0x3); + PHY_CLRBITS(mac, 0x815, 0x3); + PHY_CLRBITS(mac, 0x429, 0x8000); + PHY_CLRBITS(mac, 0x802, 0x3); + + phyr_80f = PHY_READ(mac, 0x80f); + phyr_810 = PHY_READ(mac, 0x810); + + if (phy->phy_rev >= 3) + PHY_WRITE(mac, 0x80f, 0xc020); + else + PHY_WRITE(mac, 0x80f, 0x8020); + PHY_WRITE(mac, 0x810, 0); + + phy812_val = bwi_phy812_value(mac, 0x011); + PHY_WRITE(mac, 0x812, phy812_val); + if (phy->phy_rev < 7 || + (sc->sc_card_flags & BWI_CARD_F_EXT_LNA) == 0) + PHY_WRITE(mac, 0x811, 0x1b3); + else + PHY_WRITE(mac, 0x811, 0x9b3); + } + CSR_SETBITS_2(sc, BWI_RF_ANTDIV, 0x8000); + + phyr_35 = PHY_READ(mac, 0x35); + PHY_CLRBITS(mac, 0x35, 0x80); + + bbp_atten = CSR_READ_2(sc, BWI_BBP_ATTEN); + rf_chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + if (phy->phy_version == 0) { + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0x122); + } else { + if (phy->phy_version >= 2) + PHY_FILT_SETBITS(mac, 0x3, 0xffbf, 0x40); + CSR_SETBITS_2(sc, BWI_RF_CHAN_EX, 0x2000); + } + + calib = bwi_rf_calibval(mac); + + if (phy->phy_mode == IEEE80211_MODE_11B) + RF_WRITE(mac, 0x78, 0x26); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x011); + PHY_WRITE(mac, 0x812, phy812_val); + } + + PHY_WRITE(mac, 0x15, 0xbfaf); + PHY_WRITE(mac, 0x2b, 0x1403); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x001); + PHY_WRITE(mac, 0x812, phy812_val); + } + + PHY_WRITE(mac, 0x15, 0xbfa0); + + RF_SETBITS(mac, 0x51, 0x4); + if (rf->rf_rev == 8) { + RF_WRITE(mac, 0x43, 0x1f); + } else { + RF_WRITE(mac, 0x52, 0); + RF_FILT_SETBITS(mac, 0x43, 0xfff0, 0x9); + } + + test_lim = 0; + PHY_WRITE(mac, 0x58, 0); + for (i = 0; i < 16; ++i) { + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0xc810); + + PHY_WRITE(mac, 0x58, 0xd); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xefb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x100); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xfff0); + DELAY(20); + + test_lim += PHY_READ(mac, 0x2d); + + PHY_WRITE(mac, 0x58, 0); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + } + ++test_lim; + test_lim >>= 9; + + DELAY(10); + + test = 0; + PHY_WRITE(mac, 0x58, 0); + for (i = 0; i < 16; ++i) { + int j; + + rfr_78 = (bitswap4(i) << 1) | 0x20; + RF_WRITE(mac, 0x78, rfr_78); + DELAY(10); + + /* NB: This block is slight different than the above one */ + for (j = 0; j < 16; ++j) { + PHY_WRITE(mac, 0x5a, 0xd80); + PHY_WRITE(mac, 0x59, 0xc810); + + PHY_WRITE(mac, 0x58, 0xd); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xefb0); + DELAY(10); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x100); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xfff0); + DELAY(10); + + test += PHY_READ(mac, 0x2d); + + PHY_WRITE(mac, 0x58, 0); + if ((phy->phy_flags & BWI_PHY_F_LINKED) || + phy->phy_rev >= 2) { + phy812_val = bwi_phy812_value(mac, 0x101); + PHY_WRITE(mac, 0x812, phy812_val); + } + PHY_WRITE(mac, 0x15, 0xafb0); + } + + ++test; + test >>= 8; + + if (test > test_lim) + break; + } + if (i > 15) + rf->rf_calib = rfr_78; + else + rf->rf_calib = calib; + if (rf->rf_calib != 0xffff) { + DPRINTF(sc, "RF calibration value: 0x%04x\n", rf->rf_calib); + rf->rf_flags |= BWI_RF_F_INITED; + } + + /* + * Restore trashes registers + */ + PHY_WRITE(mac, save_phy_regs_comm[0], save_phy_comm[0]); + + for (i = 0; i < SAVE_RF_MAX; ++i) { + int pos = (i + 1) % SAVE_RF_MAX; + + RF_WRITE(mac, save_rf_regs[pos], save_rf[pos]); + } + for (i = 1; i < SAVE_PHY_COMM_MAX; ++i) + PHY_WRITE(mac, save_phy_regs_comm[i], save_phy_comm[i]); + + CSR_WRITE_2(sc, BWI_BBP_ATTEN, bbp_atten); + if (phy->phy_version != 0) + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, rf_chan_ex); + + PHY_WRITE(mac, 0x35, phyr_35); + bwi_rf_work_around(mac, rf->rf_curchan); + + if (phy->phy_mode == IEEE80211_MODE_11B) { + PHY_WRITE(mac, 0x30, phyr_30); + CSR_WRITE_2(sc, BWI_BPHY_CTRL, bphy_ctrl); + } else if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + /* XXX Spec only says when PHY is linked (gmode) */ + CSR_CLRBITS_2(sc, BWI_RF_ANTDIV, 0x8000); + + for (i = 0; i < SAVE_PHY_11G_MAX; ++i) { + PHY_WRITE(mac, save_phy_regs_11g[i], + save_phy_11g[i]); + } + + PHY_WRITE(mac, 0x80f, phyr_80f); + PHY_WRITE(mac, 0x810, phyr_810); + } + +#undef SAVE_PHY_11G_MAX +#undef SAVE_PHY_COMM_MAX +#undef SAVE_RF_MAX +} + +static uint16_t +bwi_rf_calibval(struct bwi_mac *mac) +{ + /* http://bcm-specs.sipsolutions.net/RCCTable */ + static const uint16_t rf_calibvals[] = { + 0x2, 0x3, 0x1, 0xf, 0x6, 0x7, 0x5, 0xf, + 0xa, 0xb, 0x9, 0xf, 0xe, 0xf, 0xd, 0xf + }; + uint16_t val, calib; + int idx; + + val = RF_READ(mac, BWI_RFR_BBP_ATTEN); + idx = __SHIFTOUT(val, BWI_RFR_BBP_ATTEN_CALIB_IDX); + KASSERT(idx < (int)(sizeof(rf_calibvals) / sizeof(rf_calibvals[0])), + ("idx %d", idx)); + + calib = rf_calibvals[idx] << 1; + if (val & BWI_RFR_BBP_ATTEN_CALIB_BIT) + calib |= 0x1; + calib |= 0x20; + + return calib; +} + +static __inline int32_t +_bwi_adjust_devide(int32_t num, int32_t den) +{ + if (num < 0) + return (num / den); + else + return (num + den / 2) / den; +} + +/* + * http://bcm-specs.sipsolutions.net/TSSI_to_DBM_Table + * "calculating table entries" + */ +static int +bwi_rf_calc_txpower(int8_t *txpwr, uint8_t idx, const int16_t pa_params[]) +{ + int32_t m1, m2, f, dbm; + int i; + + m1 = _bwi_adjust_devide(16 * pa_params[0] + idx * pa_params[1], 32); + m2 = imax(_bwi_adjust_devide(32768 + idx * pa_params[2], 256), 1); + +#define ITER_MAX 16 + + f = 256; + for (i = 0; i < ITER_MAX; ++i) { + int32_t q, d; + + q = _bwi_adjust_devide( + f * 4096 - _bwi_adjust_devide(m2 * f, 16) * f, 2048); + d = abs(q - f); + f = q; + + if (d < 2) + break; + } + if (i == ITER_MAX) + return EINVAL; + +#undef ITER_MAX + + dbm = _bwi_adjust_devide(m1 * f, 8192); + if (dbm < -127) + dbm = -127; + else if (dbm > 128) + dbm = 128; + + *txpwr = dbm; + return 0; +} + +int +bwi_rf_map_txpower(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t sprom_ofs, val, mask; + int16_t pa_params[3]; + int error = 0, i, ant_gain, reg_txpower_max; + + /* + * Find out max TX power + */ + val = bwi_read_sprom(sc, BWI_SPROM_MAX_TXPWR); + if (phy->phy_mode == IEEE80211_MODE_11A) { + rf->rf_txpower_max = __SHIFTOUT(val, + BWI_SPROM_MAX_TXPWR_MASK_11A); + } else { + rf->rf_txpower_max = __SHIFTOUT(val, + BWI_SPROM_MAX_TXPWR_MASK_11BG); + + if ((sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) && + phy->phy_mode == IEEE80211_MODE_11G) + rf->rf_txpower_max -= 3; + } + if (rf->rf_txpower_max <= 0) { + device_printf(sc->sc_dev, "invalid max txpower in sprom\n"); + rf->rf_txpower_max = 74; + } + DPRINTF(sc, "max txpower from sprom: %d dBm\n", rf->rf_txpower_max); + + /* + * Find out region/domain max TX power, which is adjusted + * by antenna gain and 1.5 dBm fluctuation as mentioned + * in v3 spec. + */ + val = bwi_read_sprom(sc, BWI_SPROM_ANT_GAIN); + if (phy->phy_mode == IEEE80211_MODE_11A) + ant_gain = __SHIFTOUT(val, BWI_SPROM_ANT_GAIN_MASK_11A); + else + ant_gain = __SHIFTOUT(val, BWI_SPROM_ANT_GAIN_MASK_11BG); + if (ant_gain == 0xff) { + device_printf(sc->sc_dev, "invalid antenna gain in sprom\n"); + ant_gain = 2; + } + ant_gain *= 4; + DPRINTF(sc, "ant gain %d dBm\n", ant_gain); + + reg_txpower_max = 90 - ant_gain - 6; /* XXX magic number */ + DPRINTF(sc, "region/domain max txpower %d dBm\n", reg_txpower_max); + + /* + * Force max TX power within region/domain TX power limit + */ + if (rf->rf_txpower_max > reg_txpower_max) + rf->rf_txpower_max = reg_txpower_max; + DPRINTF(sc, "max txpower %d dBm\n", rf->rf_txpower_max); + + /* + * Create TSSI to TX power mapping + */ + + if (sc->sc_bbp_id == BWI_BBPID_BCM4301 && + rf->rf_type != BWI_RF_T_BCM2050) { + rf->rf_idle_tssi0 = BWI_DEFAULT_IDLE_TSSI; + bcopy(bwi_txpower_map_11b, rf->rf_txpower_map0, + sizeof(rf->rf_txpower_map0)); + goto back; + } + +#define IS_VALID_PA_PARAM(p) ((p) != 0 && (p) != -1) +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + + /* + * Extract PA parameters + */ + if (phy->phy_mode == IEEE80211_MODE_11A) + sprom_ofs = BWI_SPROM_PA_PARAM_11A; + else + sprom_ofs = BWI_SPROM_PA_PARAM_11BG; + for (i = 0; i < N(pa_params); ++i) + pa_params[i] = (int16_t)bwi_read_sprom(sc, sprom_ofs + (i * 2)); + + for (i = 0; i < N(pa_params); ++i) { + /* + * If one of the PA parameters from SPROM is not valid, + * fall back to the default values, if there are any. + */ + if (!IS_VALID_PA_PARAM(pa_params[i])) { + const int8_t *txpower_map; + + if (phy->phy_mode == IEEE80211_MODE_11A) { + device_printf(sc->sc_dev, + "no tssi2dbm table for 11a PHY\n"); + return ENXIO; + } + + if (phy->phy_mode == IEEE80211_MODE_11G) { + DPRINTF(sc, "%s\n", "use default 11g TSSI map"); + txpower_map = bwi_txpower_map_11g; + } else { + txpower_map = bwi_txpower_map_11b; + } + + rf->rf_idle_tssi0 = BWI_DEFAULT_IDLE_TSSI; + bcopy(txpower_map, rf->rf_txpower_map0, + sizeof(rf->rf_txpower_map0)); + goto back; + } + } + +#undef N + + /* + * All of the PA parameters from SPROM are valid. + */ + + /* + * Extract idle TSSI from SPROM. + */ + val = bwi_read_sprom(sc, BWI_SPROM_IDLE_TSSI); + DPRINTF(sc, "sprom idle tssi: 0x%04x\n", val); + + if (phy->phy_mode == IEEE80211_MODE_11A) + mask = BWI_SPROM_IDLE_TSSI_MASK_11A; + else + mask = BWI_SPROM_IDLE_TSSI_MASK_11BG; + + rf->rf_idle_tssi0 = (int)__SHIFTOUT(val, mask); + if (!IS_VALID_PA_PARAM(rf->rf_idle_tssi0)) + rf->rf_idle_tssi0 = 62; + +#undef IS_VALID_PA_PARAM + + /* + * Calculate TX power map, which is indexed by TSSI + */ + device_printf(sc->sc_dev, "TSSI-TX power map:\n"); + for (i = 0; i < BWI_TSSI_MAX; ++i) { + error = bwi_rf_calc_txpower(&rf->rf_txpower_map0[i], i, + pa_params); + if (error) { + device_printf(sc->sc_dev, + "bwi_rf_calc_txpower failed\n"); + break; + } + if (i != 0 && i % 8 == 0) + printf("\n"); + printf("%d ", rf->rf_txpower_map0[i]); + } + printf("\n"); +back: + DPRINTF(sc, "idle tssi0: %d\n", rf->rf_idle_tssi0); + return error; +} + +void +bwi_rf_lo_update(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_tpctl *tpctl = &mac->mac_tpctl; + struct rf_saveregs regs; + uint16_t ant_div, chan_ex; + uint8_t devi_ctrl; + u_int orig_chan; + + /* + * Save RF/PHY registers for later restoration + */ + orig_chan = rf->rf_curchan; + bzero(®s, sizeof(regs)); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + SAVE_PHY_REG(mac, ®s, 429); + SAVE_PHY_REG(mac, ®s, 802); + + PHY_WRITE(mac, 0x429, regs.phy_429 & 0x7fff); + PHY_WRITE(mac, 0x802, regs.phy_802 & 0xfffc); + } + + ant_div = CSR_READ_2(sc, BWI_RF_ANTDIV); + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div | 0x8000); + chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + SAVE_PHY_REG(mac, ®s, 15); + SAVE_PHY_REG(mac, ®s, 2a); + SAVE_PHY_REG(mac, ®s, 35); + SAVE_PHY_REG(mac, ®s, 60); + SAVE_RF_REG(mac, ®s, 43); + SAVE_RF_REG(mac, ®s, 7a); + SAVE_RF_REG(mac, ®s, 52); + if (phy->phy_flags & BWI_PHY_F_LINKED) { + SAVE_PHY_REG(mac, ®s, 811); + SAVE_PHY_REG(mac, ®s, 812); + SAVE_PHY_REG(mac, ®s, 814); + SAVE_PHY_REG(mac, ®s, 815); + } + + /* Force to channel 6 */ + bwi_rf_set_chan(mac, 6, 0); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x429, regs.phy_429 & 0x7fff); + PHY_WRITE(mac, 0x802, regs.phy_802 & 0xfffc); + bwi_mac_dummy_xmit(mac); + } + RF_WRITE(mac, 0x43, 0x6); + + bwi_phy_set_bbp_atten(mac, 2); + + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, 0); + + PHY_WRITE(mac, 0x2e, 0x7f); + PHY_WRITE(mac, 0x80f, 0x78); + PHY_WRITE(mac, 0x35, regs.phy_35 & 0xff7f); + RF_WRITE(mac, 0x7a, regs.rf_7a & 0xfff0); + PHY_WRITE(mac, 0x2b, 0x203); + PHY_WRITE(mac, 0x2a, 0x8a3); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x814, regs.phy_814 | 0x3); + PHY_WRITE(mac, 0x815, regs.phy_815 & 0xfffc); + PHY_WRITE(mac, 0x811, 0x1b3); + PHY_WRITE(mac, 0x812, 0xb2); + } + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + tpctl->tp_ctrl2 = bwi_rf_get_tp_ctrl2(mac); + PHY_WRITE(mac, 0x80f, 0x8078); + + /* + * Measure all RF LO + */ + devi_ctrl = _bwi_rf_lo_update(mac, regs.rf_7a); + + /* + * Restore saved RF/PHY registers + */ + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x15, 0xe300); + PHY_WRITE(mac, 0x812, (devi_ctrl << 8) | 0xa0); + DELAY(5); + PHY_WRITE(mac, 0x812, (devi_ctrl << 8) | 0xa2); + DELAY(2); + PHY_WRITE(mac, 0x812, (devi_ctrl << 8) | 0xa3); + } else { + PHY_WRITE(mac, 0x15, devi_ctrl | 0xefa0); + } + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + tpctl = NULL; + bwi_rf_lo_adjust(mac, tpctl); + + PHY_WRITE(mac, 0x2e, 0x807f); + if (phy->phy_flags & BWI_PHY_F_LINKED) + PHY_WRITE(mac, 0x2f, 0x202); + else + PHY_WRITE(mac, 0x2f, 0x101); + + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, chan_ex); + + RESTORE_PHY_REG(mac, ®s, 15); + RESTORE_PHY_REG(mac, ®s, 2a); + RESTORE_PHY_REG(mac, ®s, 35); + RESTORE_PHY_REG(mac, ®s, 60); + + RESTORE_RF_REG(mac, ®s, 43); + RESTORE_RF_REG(mac, ®s, 7a); + + regs.rf_52 &= 0xf0; + regs.rf_52 |= (RF_READ(mac, 0x52) & 0xf); + RF_WRITE(mac, 0x52, regs.rf_52); + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div); + + if (phy->phy_flags & BWI_PHY_F_LINKED) { + RESTORE_PHY_REG(mac, ®s, 811); + RESTORE_PHY_REG(mac, ®s, 812); + RESTORE_PHY_REG(mac, ®s, 814); + RESTORE_PHY_REG(mac, ®s, 815); + RESTORE_PHY_REG(mac, ®s, 429); + RESTORE_PHY_REG(mac, ®s, 802); + } + + bwi_rf_set_chan(mac, orig_chan, 1); +} + +static uint32_t +bwi_rf_lo_devi_measure(struct bwi_mac *mac, uint16_t ctrl) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint32_t devi = 0; + int i; + + if (phy->phy_flags & BWI_PHY_F_LINKED) + ctrl <<= 8; + + for (i = 0; i < 8; ++i) { + if (phy->phy_flags & BWI_PHY_F_LINKED) { + PHY_WRITE(mac, 0x15, 0xe300); + PHY_WRITE(mac, 0x812, ctrl | 0xb0); + DELAY(5); + PHY_WRITE(mac, 0x812, ctrl | 0xb2); + DELAY(2); + PHY_WRITE(mac, 0x812, ctrl | 0xb3); + DELAY(4); + PHY_WRITE(mac, 0x15, 0xf300); + } else { + PHY_WRITE(mac, 0x15, ctrl | 0xefa0); + DELAY(2); + PHY_WRITE(mac, 0x15, ctrl | 0xefe0); + DELAY(4); + PHY_WRITE(mac, 0x15, ctrl | 0xffe0); + } + DELAY(8); + devi += PHY_READ(mac, 0x2d); + } + return devi; +} + +static uint16_t +bwi_rf_get_tp_ctrl2(struct bwi_mac *mac) +{ + uint32_t devi_min; + uint16_t tp_ctrl2 = 0; + int i; + + RF_WRITE(mac, 0x52, 0); + DELAY(10); + devi_min = bwi_rf_lo_devi_measure(mac, 0); + + for (i = 0; i < 16; ++i) { + uint32_t devi; + + RF_WRITE(mac, 0x52, i); + DELAY(10); + devi = bwi_rf_lo_devi_measure(mac, 0); + + if (devi < devi_min) { + devi_min = devi; + tp_ctrl2 = i; + } + } + return tp_ctrl2; +} + +static uint8_t +_bwi_rf_lo_update(struct bwi_mac *mac, uint16_t orig_rf7a) +{ +#define RF_ATTEN_LISTSZ 14 +#define BBP_ATTEN_MAX 4 /* half */ + + static const int rf_atten_list[RF_ATTEN_LISTSZ] = + { 3, 1, 5, 7, 9, 2, 0, 4, 6, 8, 1, 2, 3, 4 }; + static const int rf_atten_init_list[RF_ATTEN_LISTSZ] = + { 0, 3, 1, 5, 7, 3, 2, 0, 4, 6, -1, -1, -1, -1 }; + static const int rf_lo_measure_order[RF_ATTEN_LISTSZ] = + { 3, 1, 5, 7, 9, 2, 0, 4, 6, 8, 10, 11, 12, 13 }; + + struct ifnet *ifp = mac->mac_sc->sc_ic.ic_ifp; + struct bwi_rf_lo lo_save, *lo; + uint8_t devi_ctrl = 0; + int idx, adj_rf7a = 0; + + bzero(&lo_save, sizeof(lo_save)); + for (idx = 0; idx < RF_ATTEN_LISTSZ; ++idx) { + int init_rf_atten = rf_atten_init_list[idx]; + int rf_atten = rf_atten_list[idx]; + int bbp_atten; + + for (bbp_atten = 0; bbp_atten < BBP_ATTEN_MAX; ++bbp_atten) { + uint16_t tp_ctrl2, rf7a; + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + if (idx == 0) { + bzero(&lo_save, sizeof(lo_save)); + } else if (init_rf_atten < 0) { + lo = bwi_get_rf_lo(mac, + rf_atten, 2 * bbp_atten); + bcopy(lo, &lo_save, sizeof(lo_save)); + } else { + lo = bwi_get_rf_lo(mac, + init_rf_atten, 0); + bcopy(lo, &lo_save, sizeof(lo_save)); + } + + devi_ctrl = 0; + adj_rf7a = 0; + + /* + * XXX + * Linux driver overflows 'val' + */ + if (init_rf_atten >= 0) { + int val; + + val = rf_atten * 2 + bbp_atten; + if (val > 14) { + adj_rf7a = 1; + if (val > 17) + devi_ctrl = 1; + if (val > 19) + devi_ctrl = 2; + } + } + } else { + lo = bwi_get_rf_lo(mac, + rf_atten, 2 * bbp_atten); + if (!bwi_rf_lo_isused(mac, lo)) + continue; + bcopy(lo, &lo_save, sizeof(lo_save)); + + devi_ctrl = 3; + adj_rf7a = 0; + } + + RF_WRITE(mac, BWI_RFR_ATTEN, rf_atten); + + tp_ctrl2 = mac->mac_tpctl.tp_ctrl2; + if (init_rf_atten < 0) + tp_ctrl2 |= (3 << 4); + RF_WRITE(mac, BWI_RFR_TXPWR, tp_ctrl2); + + DELAY(10); + + bwi_phy_set_bbp_atten(mac, bbp_atten * 2); + + rf7a = orig_rf7a & 0xfff0; + if (adj_rf7a) + rf7a |= 0x8; + RF_WRITE(mac, 0x7a, rf7a); + + lo = bwi_get_rf_lo(mac, + rf_lo_measure_order[idx], bbp_atten * 2); + bwi_rf_lo_measure(mac, &lo_save, lo, devi_ctrl); + } + } + return devi_ctrl; + +#undef RF_ATTEN_LISTSZ +#undef BBP_ATTEN_MAX +} + +static void +bwi_rf_lo_measure(struct bwi_mac *mac, const struct bwi_rf_lo *src_lo, + struct bwi_rf_lo *dst_lo, uint8_t devi_ctrl) +{ +#define LO_ADJUST_MIN 1 +#define LO_ADJUST_MAX 8 +#define LO_ADJUST(hi, lo) { .ctrl_hi = hi, .ctrl_lo = lo } + static const struct bwi_rf_lo rf_lo_adjust[LO_ADJUST_MAX] = { + LO_ADJUST(1, 1), + LO_ADJUST(1, 0), + LO_ADJUST(1, -1), + LO_ADJUST(0, -1), + LO_ADJUST(-1, -1), + LO_ADJUST(-1, 0), + LO_ADJUST(-1, 1), + LO_ADJUST(0, 1) + }; +#undef LO_ADJUST + + struct bwi_rf_lo lo_min; + uint32_t devi_min; + int found, loop_count, adjust_state; + + bcopy(src_lo, &lo_min, sizeof(lo_min)); + RF_LO_WRITE(mac, &lo_min); + devi_min = bwi_rf_lo_devi_measure(mac, devi_ctrl); + + loop_count = 12; /* XXX */ + adjust_state = 0; + do { + struct bwi_rf_lo lo_base; + int i, fin; + + found = 0; + if (adjust_state == 0) { + i = LO_ADJUST_MIN; + fin = LO_ADJUST_MAX; + } else if (adjust_state % 2 == 0) { + i = adjust_state - 1; + fin = adjust_state + 1; + } else { + i = adjust_state - 2; + fin = adjust_state + 2; + } + + if (i < LO_ADJUST_MIN) + i += LO_ADJUST_MAX; + KASSERT(i <= LO_ADJUST_MAX && i >= LO_ADJUST_MIN, ("i %d", i)); + + if (fin > LO_ADJUST_MAX) + fin -= LO_ADJUST_MAX; + KASSERT(fin <= LO_ADJUST_MAX && fin >= LO_ADJUST_MIN, + ("fin %d", fin)); + + bcopy(&lo_min, &lo_base, sizeof(lo_base)); + for (;;) { + struct bwi_rf_lo lo; + + lo.ctrl_hi = lo_base.ctrl_hi + + rf_lo_adjust[i - 1].ctrl_hi; + lo.ctrl_lo = lo_base.ctrl_lo + + rf_lo_adjust[i - 1].ctrl_lo; + + if (abs(lo.ctrl_lo) < 9 && abs(lo.ctrl_hi) < 9) { + uint32_t devi; + + RF_LO_WRITE(mac, &lo); + devi = bwi_rf_lo_devi_measure(mac, devi_ctrl); + if (devi < devi_min) { + devi_min = devi; + adjust_state = i; + found = 1; + bcopy(&lo, &lo_min, sizeof(lo_min)); + } + } + if (i == fin) + break; + if (i == LO_ADJUST_MAX) + i = LO_ADJUST_MIN; + else + ++i; + } + } while (loop_count-- && found); + + bcopy(&lo_min, dst_lo, sizeof(*dst_lo)); + +#undef LO_ADJUST_MIN +#undef LO_ADJUST_MAX +} + +static void +bwi_rf_calc_nrssi_slope_11b(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 3 +#define SAVE_PHY_MAX 8 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x7a, 0x52, 0x43 }; + static const uint16_t save_phy_regs[SAVE_PHY_MAX] = + { 0x30, 0x26, 0x15, 0x2a, 0x20, 0x5a, 0x59, 0x58 }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy[SAVE_PHY_MAX]; + uint16_t ant_div, bbp_atten, chan_ex; + int16_t nrssi[2]; + int i; + + /* + * Save RF/PHY registers for later restoration + */ + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + for (i = 0; i < SAVE_PHY_MAX; ++i) + save_phy[i] = PHY_READ(mac, save_phy_regs[i]); + + ant_div = CSR_READ_2(sc, BWI_RF_ANTDIV); + bbp_atten = CSR_READ_2(sc, BWI_BBP_ATTEN); + chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + /* + * Calculate nrssi0 + */ + if (phy->phy_rev >= 5) + RF_CLRBITS(mac, 0x7a, 0xff80); + else + RF_CLRBITS(mac, 0x7a, 0xfff0); + PHY_WRITE(mac, 0x30, 0xff); + + CSR_WRITE_2(sc, BWI_BPHY_CTRL, 0x7f7f); + + PHY_WRITE(mac, 0x26, 0); + PHY_SETBITS(mac, 0x15, 0x20); + PHY_WRITE(mac, 0x2a, 0x8a3); + RF_SETBITS(mac, 0x7a, 0x80); + + nrssi[0] = (int16_t)PHY_READ(mac, 0x27); + + /* + * Calculate nrssi1 + */ + RF_CLRBITS(mac, 0x7a, 0xff80); + if (phy->phy_version >= 2) + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0x40); + else if (phy->phy_version == 0) + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0x122); + else + CSR_CLRBITS_2(sc, BWI_RF_CHAN_EX, 0xdfff); + + PHY_WRITE(mac, 0x20, 0x3f3f); + PHY_WRITE(mac, 0x15, 0xf330); + + RF_WRITE(mac, 0x5a, 0x60); + RF_CLRBITS(mac, 0x43, 0xff0f); + + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0x810); + PHY_WRITE(mac, 0x58, 0xd); + + DELAY(20); + + nrssi[1] = (int16_t)PHY_READ(mac, 0x27); + + /* + * Restore saved RF/PHY registers + */ + PHY_WRITE(mac, save_phy_regs[0], save_phy[0]); + RF_WRITE(mac, save_rf_regs[0], save_rf[0]); + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div); + + for (i = 1; i < 4; ++i) + PHY_WRITE(mac, save_phy_regs[i], save_phy[i]); + + bwi_rf_work_around(mac, rf->rf_curchan); + + if (phy->phy_version != 0) + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, chan_ex); + + for (; i < SAVE_PHY_MAX; ++i) + PHY_WRITE(mac, save_phy_regs[i], save_phy[i]); + + for (i = 1; i < SAVE_RF_MAX; ++i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + /* + * Install calculated narrow RSSI values + */ + if (nrssi[0] == nrssi[1]) + rf->rf_nrssi_slope = 0x10000; + else + rf->rf_nrssi_slope = 0x400000 / (nrssi[0] - nrssi[1]); + if (nrssi[0] <= -4) { + rf->rf_nrssi[0] = nrssi[0]; + rf->rf_nrssi[1] = nrssi[1]; + } + +#undef SAVE_RF_MAX +#undef SAVE_PHY_MAX +} + +static void +bwi_rf_set_nrssi_ofs_11g(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 2 +#define SAVE_PHY_COMM_MAX 10 +#define SAVE_PHY6_MAX 8 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x7a, 0x43 }; + static const uint16_t save_phy_comm_regs[SAVE_PHY_COMM_MAX] = { + 0x0001, 0x0811, 0x0812, 0x0814, + 0x0815, 0x005a, 0x0059, 0x0058, + 0x000a, 0x0003 + }; + static const uint16_t save_phy6_regs[SAVE_PHY6_MAX] = { + 0x002e, 0x002f, 0x080f, 0x0810, + 0x0801, 0x0060, 0x0014, 0x0478 + }; + + struct bwi_phy *phy = &mac->mac_phy; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy_comm[SAVE_PHY_COMM_MAX]; + uint16_t save_phy6[SAVE_PHY6_MAX]; + uint16_t rf7b = 0xffff; + int16_t nrssi; + int i, phy6_idx = 0; + + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + save_phy_comm[i] = PHY_READ(mac, save_phy_comm_regs[i]); + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + + PHY_CLRBITS(mac, 0x429, 0x8000); + PHY_FILT_SETBITS(mac, 0x1, 0x3fff, 0x4000); + PHY_SETBITS(mac, 0x811, 0xc); + PHY_FILT_SETBITS(mac, 0x812, 0xfff3, 0x4); + PHY_CLRBITS(mac, 0x802, 0x3); + + if (phy->phy_rev >= 6) { + for (i = 0; i < SAVE_PHY6_MAX; ++i) + save_phy6[i] = PHY_READ(mac, save_phy6_regs[i]); + + PHY_WRITE(mac, 0x2e, 0); + PHY_WRITE(mac, 0x2f, 0); + PHY_WRITE(mac, 0x80f, 0); + PHY_WRITE(mac, 0x810, 0); + PHY_SETBITS(mac, 0x478, 0x100); + PHY_SETBITS(mac, 0x801, 0x40); + PHY_SETBITS(mac, 0x60, 0x40); + PHY_SETBITS(mac, 0x14, 0x200); + } + + RF_SETBITS(mac, 0x7a, 0x70); + RF_SETBITS(mac, 0x7a, 0x80); + + DELAY(30); + + nrssi = bwi_nrssi_11g(mac); + if (nrssi == 31) { + for (i = 7; i >= 4; --i) { + RF_WRITE(mac, 0x7b, i); + DELAY(20); + nrssi = bwi_nrssi_11g(mac); + if (nrssi < 31 && rf7b == 0xffff) + rf7b = i; + } + if (rf7b == 0xffff) + rf7b = 4; + } else { + struct bwi_gains gains; + + RF_CLRBITS(mac, 0x7a, 0xff80); + + PHY_SETBITS(mac, 0x814, 0x1); + PHY_CLRBITS(mac, 0x815, 0x1); + PHY_SETBITS(mac, 0x811, 0xc); + PHY_SETBITS(mac, 0x812, 0xc); + PHY_SETBITS(mac, 0x811, 0x30); + PHY_SETBITS(mac, 0x812, 0x30); + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0x810); + PHY_WRITE(mac, 0x58, 0xd); + if (phy->phy_version == 0) + PHY_WRITE(mac, 0x3, 0x122); + else + PHY_SETBITS(mac, 0xa, 0x2000); + PHY_SETBITS(mac, 0x814, 0x4); + PHY_CLRBITS(mac, 0x815, 0x4); + PHY_FILT_SETBITS(mac, 0x3, 0xff9f, 0x40); + RF_SETBITS(mac, 0x7a, 0xf); + + bzero(&gains, sizeof(gains)); + gains.tbl_gain1 = 3; + gains.tbl_gain2 = 0; + gains.phy_gain = 1; + bwi_set_gains(mac, &gains); + + RF_FILT_SETBITS(mac, 0x43, 0xf0, 0xf); + DELAY(30); + + nrssi = bwi_nrssi_11g(mac); + if (nrssi == -32) { + for (i = 0; i < 4; ++i) { + RF_WRITE(mac, 0x7b, i); + DELAY(20); + nrssi = bwi_nrssi_11g(mac); + if (nrssi > -31 && rf7b == 0xffff) + rf7b = i; + } + if (rf7b == 0xffff) + rf7b = 3; + } else { + rf7b = 0; + } + } + RF_WRITE(mac, 0x7b, rf7b); + + /* + * Restore saved RF/PHY registers + */ + if (phy->phy_rev >= 6) { + for (phy6_idx = 0; phy6_idx < 4; ++phy6_idx) { + PHY_WRITE(mac, save_phy6_regs[phy6_idx], + save_phy6[phy6_idx]); + } + } + + /* Saved PHY registers 0, 1, 2 are handled later */ + for (i = 3; i < SAVE_PHY_COMM_MAX; ++i) + PHY_WRITE(mac, save_phy_comm_regs[i], save_phy_comm[i]); + + for (i = SAVE_RF_MAX - 1; i >= 0; --i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + PHY_SETBITS(mac, 0x802, 0x3); + PHY_SETBITS(mac, 0x429, 0x8000); + + bwi_set_gains(mac, NULL); + + if (phy->phy_rev >= 6) { + for (; phy6_idx < SAVE_PHY6_MAX; ++phy6_idx) { + PHY_WRITE(mac, save_phy6_regs[phy6_idx], + save_phy6[phy6_idx]); + } + } + + PHY_WRITE(mac, save_phy_comm_regs[0], save_phy_comm[0]); + PHY_WRITE(mac, save_phy_comm_regs[2], save_phy_comm[2]); + PHY_WRITE(mac, save_phy_comm_regs[1], save_phy_comm[1]); + +#undef SAVE_RF_MAX +#undef SAVE_PHY_COMM_MAX +#undef SAVE_PHY6_MAX +} + +static void +bwi_rf_calc_nrssi_slope_11g(struct bwi_mac *mac) +{ +#define SAVE_RF_MAX 3 +#define SAVE_PHY_COMM_MAX 4 +#define SAVE_PHY3_MAX 8 + + static const uint16_t save_rf_regs[SAVE_RF_MAX] = + { 0x7a, 0x52, 0x43 }; + static const uint16_t save_phy_comm_regs[SAVE_PHY_COMM_MAX] = + { 0x15, 0x5a, 0x59, 0x58 }; + static const uint16_t save_phy3_regs[SAVE_PHY3_MAX] = { + 0x002e, 0x002f, 0x080f, 0x0810, + 0x0801, 0x0060, 0x0014, 0x0478 + }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint16_t save_rf[SAVE_RF_MAX]; + uint16_t save_phy_comm[SAVE_PHY_COMM_MAX]; + uint16_t save_phy3[SAVE_PHY3_MAX]; + uint16_t ant_div, bbp_atten, chan_ex; + struct bwi_gains gains; + int16_t nrssi[2]; + int i, phy3_idx = 0; + + if (rf->rf_rev >= 9) + return; + else if (rf->rf_rev == 8) + bwi_rf_set_nrssi_ofs_11g(mac); + + PHY_CLRBITS(mac, 0x429, 0x8000); + PHY_CLRBITS(mac, 0x802, 0x3); + + /* + * Save RF/PHY registers for later restoration + */ + ant_div = CSR_READ_2(sc, BWI_RF_ANTDIV); + CSR_SETBITS_2(sc, BWI_RF_ANTDIV, 0x8000); + + for (i = 0; i < SAVE_RF_MAX; ++i) + save_rf[i] = RF_READ(mac, save_rf_regs[i]); + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + save_phy_comm[i] = PHY_READ(mac, save_phy_comm_regs[i]); + + bbp_atten = CSR_READ_2(sc, BWI_BBP_ATTEN); + chan_ex = CSR_READ_2(sc, BWI_RF_CHAN_EX); + + if (phy->phy_rev >= 3) { + for (i = 0; i < SAVE_PHY3_MAX; ++i) + save_phy3[i] = PHY_READ(mac, save_phy3_regs[i]); + + PHY_WRITE(mac, 0x2e, 0); + PHY_WRITE(mac, 0x810, 0); + + if (phy->phy_rev == 4 || phy->phy_rev == 6 || + phy->phy_rev == 7) { + PHY_SETBITS(mac, 0x478, 0x100); + PHY_SETBITS(mac, 0x810, 0x40); + } else if (phy->phy_rev == 3 || phy->phy_rev == 5) { + PHY_CLRBITS(mac, 0x810, 0x40); + } + + PHY_SETBITS(mac, 0x60, 0x40); + PHY_SETBITS(mac, 0x14, 0x200); + } + + /* + * Calculate nrssi0 + */ + RF_SETBITS(mac, 0x7a, 0x70); + + bzero(&gains, sizeof(gains)); + gains.tbl_gain1 = 0; + gains.tbl_gain2 = 8; + gains.phy_gain = 0; + bwi_set_gains(mac, &gains); + + RF_CLRBITS(mac, 0x7a, 0xff08); + if (phy->phy_rev >= 2) { + PHY_FILT_SETBITS(mac, 0x811, 0xffcf, 0x30); + PHY_FILT_SETBITS(mac, 0x812, 0xffcf, 0x10); + } + + RF_SETBITS(mac, 0x7a, 0x80); + DELAY(20); + nrssi[0] = bwi_nrssi_11g(mac); + + /* + * Calculate nrssi1 + */ + RF_CLRBITS(mac, 0x7a, 0xff80); + if (phy->phy_version >= 2) + PHY_FILT_SETBITS(mac, 0x3, 0xff9f, 0x40); + CSR_SETBITS_2(sc, BWI_RF_CHAN_EX, 0x2000); + + RF_SETBITS(mac, 0x7a, 0xf); + PHY_WRITE(mac, 0x15, 0xf330); + if (phy->phy_rev >= 2) { + PHY_FILT_SETBITS(mac, 0x812, 0xffcf, 0x20); + PHY_FILT_SETBITS(mac, 0x811, 0xffcf, 0x20); + } + + bzero(&gains, sizeof(gains)); + gains.tbl_gain1 = 3; + gains.tbl_gain2 = 0; + gains.phy_gain = 1; + bwi_set_gains(mac, &gains); + + if (rf->rf_rev == 8) { + RF_WRITE(mac, 0x43, 0x1f); + } else { + RF_FILT_SETBITS(mac, 0x52, 0xff0f, 0x60); + RF_FILT_SETBITS(mac, 0x43, 0xfff0, 0x9); + } + PHY_WRITE(mac, 0x5a, 0x480); + PHY_WRITE(mac, 0x59, 0x810); + PHY_WRITE(mac, 0x58, 0xd); + DELAY(20); + + nrssi[1] = bwi_nrssi_11g(mac); + + /* + * Install calculated narrow RSSI values + */ + if (nrssi[1] == nrssi[0]) + rf->rf_nrssi_slope = 0x10000; + else + rf->rf_nrssi_slope = 0x400000 / (nrssi[0] - nrssi[1]); + if (nrssi[0] >= -4) { + rf->rf_nrssi[0] = nrssi[1]; + rf->rf_nrssi[1] = nrssi[0]; + } + + /* + * Restore saved RF/PHY registers + */ + if (phy->phy_rev >= 3) { + for (phy3_idx = 0; phy3_idx < 4; ++phy3_idx) { + PHY_WRITE(mac, save_phy3_regs[phy3_idx], + save_phy3[phy3_idx]); + } + } + if (phy->phy_rev >= 2) { + PHY_CLRBITS(mac, 0x812, 0x30); + PHY_CLRBITS(mac, 0x811, 0x30); + } + + for (i = 0; i < SAVE_RF_MAX; ++i) + RF_WRITE(mac, save_rf_regs[i], save_rf[i]); + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, ant_div); + CSR_WRITE_2(sc, BWI_BBP_ATTEN, bbp_atten); + CSR_WRITE_2(sc, BWI_RF_CHAN_EX, chan_ex); + + for (i = 0; i < SAVE_PHY_COMM_MAX; ++i) + PHY_WRITE(mac, save_phy_comm_regs[i], save_phy_comm[i]); + + bwi_rf_work_around(mac, rf->rf_curchan); + PHY_SETBITS(mac, 0x802, 0x3); + bwi_set_gains(mac, NULL); + PHY_SETBITS(mac, 0x429, 0x8000); + + if (phy->phy_rev >= 3) { + for (; phy3_idx < SAVE_PHY3_MAX; ++phy3_idx) { + PHY_WRITE(mac, save_phy3_regs[phy3_idx], + save_phy3[phy3_idx]); + } + } + + bwi_rf_init_sw_nrssi_table(mac); + bwi_rf_set_nrssi_thr_11g(mac); + +#undef SAVE_RF_MAX +#undef SAVE_PHY_COMM_MAX +#undef SAVE_PHY3_MAX +} + +static void +bwi_rf_init_sw_nrssi_table(struct bwi_mac *mac) +{ + struct bwi_rf *rf = &mac->mac_rf; + int d, i; + + d = 0x1f - rf->rf_nrssi[0]; + for (i = 0; i < BWI_NRSSI_TBLSZ; ++i) { + int val; + + val = (((i - d) * rf->rf_nrssi_slope) / 0x10000) + 0x3a; + if (val < 0) + val = 0; + else if (val > 0x3f) + val = 0x3f; + + rf->rf_nrssi_table[i] = val; + } +} + +void +bwi_rf_init_hw_nrssi_table(struct bwi_mac *mac, uint16_t adjust) +{ + int i; + + for (i = 0; i < BWI_NRSSI_TBLSZ; ++i) { + int16_t val; + + val = bwi_nrssi_read(mac, i); + + val -= adjust; + if (val < -32) + val = -32; + else if (val > 31); + val = 31; + + bwi_nrssi_write(mac, i, val); + } +} + +static void +bwi_rf_set_nrssi_thr_11b(struct bwi_mac *mac) +{ + struct bwi_rf *rf = &mac->mac_rf; + int32_t thr; + + if (rf->rf_type != BWI_RF_T_BCM2050 || + (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) == 0) + return; + + /* + * Calculate nrssi threshold + */ + if (rf->rf_rev >= 6) { + thr = (rf->rf_nrssi[1] - rf->rf_nrssi[0]) * 32; + thr += 20 * (rf->rf_nrssi[0] + 1); + thr /= 40; + } else { + thr = rf->rf_nrssi[1] - 5; + } + if (thr < 0) + thr = 0; + else if (thr > 0x3e) + thr = 0x3e; + + PHY_READ(mac, BWI_PHYR_NRSSI_THR_11B); /* dummy read */ + PHY_WRITE(mac, BWI_PHYR_NRSSI_THR_11B, (((uint16_t)thr) << 8) | 0x1c); + + if (rf->rf_rev >= 6) { + PHY_WRITE(mac, 0x87, 0xe0d); + PHY_WRITE(mac, 0x86, 0xc0b); + PHY_WRITE(mac, 0x85, 0xa09); + PHY_WRITE(mac, 0x84, 0x808); + PHY_WRITE(mac, 0x83, 0x808); + PHY_WRITE(mac, 0x82, 0x604); + PHY_WRITE(mac, 0x81, 0x302); + PHY_WRITE(mac, 0x80, 0x100); + } +} + +static __inline int32_t +_nrssi_threshold(const struct bwi_rf *rf, int32_t val) +{ + val *= (rf->rf_nrssi[1] - rf->rf_nrssi[0]); + val += (rf->rf_nrssi[0] << 6); + if (val < 32) + val += 31; + else + val += 32; + val >>= 6; + if (val < -31) + val = -31; + else if (val > 31) + val = 31; + return val; +} + +static void +bwi_rf_set_nrssi_thr_11g(struct bwi_mac *mac) +{ + int32_t thr1, thr2; + uint16_t thr; + + /* + * Find the two nrssi thresholds + */ + if ((mac->mac_phy.phy_flags & BWI_PHY_F_LINKED) == 0 || + (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) == 0) { + int16_t nrssi; + + nrssi = bwi_nrssi_read(mac, 0x20); + if (nrssi >= 32) + nrssi -= 64; + + if (nrssi < 3) { + thr1 = 0x2b; + thr2 = 0x27; + } else { + thr1 = 0x2d; + thr2 = 0x2b; + } + } else { + /* TODO Interfere mode */ + thr1 = _nrssi_threshold(&mac->mac_rf, 0x11); + thr2 = _nrssi_threshold(&mac->mac_rf, 0xe); + } + +#define NRSSI_THR1_MASK __BITS(5, 0) +#define NRSSI_THR2_MASK __BITS(11, 6) + + thr = __SHIFTIN((uint32_t)thr1, NRSSI_THR1_MASK) | + __SHIFTIN((uint32_t)thr2, NRSSI_THR2_MASK); + PHY_FILT_SETBITS(mac, BWI_PHYR_NRSSI_THR_11G, 0xf000, thr); + +#undef NRSSI_THR1_MASK +#undef NRSSI_THR2_MASK +} + +void +bwi_rf_clear_tssi(struct bwi_mac *mac) +{ + /* XXX use function pointer */ + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11A) { + /* TODO:11A */ + } else { + uint16_t val; + int i; + + val = __SHIFTIN(BWI_INVALID_TSSI, BWI_LO_TSSI_MASK) | + __SHIFTIN(BWI_INVALID_TSSI, BWI_HI_TSSI_MASK); + + for (i = 0; i < 2; ++i) { + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, + BWI_COMM_MOBJ_TSSI_DS + (i * 2), val); + } + + for (i = 0; i < 2; ++i) { + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, + BWI_COMM_MOBJ_TSSI_OFDM + (i * 2), val); + } + } +} + +void +bwi_rf_clear_state(struct bwi_rf *rf) +{ + int i; + + rf->rf_flags &= ~BWI_RF_CLEAR_FLAGS; + bzero(rf->rf_lo, sizeof(rf->rf_lo)); + bzero(rf->rf_lo_used, sizeof(rf->rf_lo_used)); + + rf->rf_nrssi_slope = 0; + rf->rf_nrssi[0] = BWI_INVALID_NRSSI; + rf->rf_nrssi[1] = BWI_INVALID_NRSSI; + + for (i = 0; i < BWI_NRSSI_TBLSZ; ++i) + rf->rf_nrssi_table[i] = i; + + rf->rf_lo_gain = 0; + rf->rf_rx_gain = 0; + + bcopy(rf->rf_txpower_map0, rf->rf_txpower_map, + sizeof(rf->rf_txpower_map)); + rf->rf_idle_tssi = rf->rf_idle_tssi0; +} + +static void +bwi_rf_on_11a(struct bwi_mac *mac) +{ + /* TODO:11A */ +} + +static void +bwi_rf_on_11bg(struct bwi_mac *mac) +{ + struct bwi_phy *phy = &mac->mac_phy; + + PHY_WRITE(mac, 0x15, 0x8000); + PHY_WRITE(mac, 0x15, 0xcc00); + if (phy->phy_flags & BWI_PHY_F_LINKED) + PHY_WRITE(mac, 0x15, 0xc0); + else + PHY_WRITE(mac, 0x15, 0); + + bwi_rf_set_chan(mac, 6 /* XXX */, 1); +} + +void +bwi_rf_set_ant_mode(struct bwi_mac *mac, int ant_mode) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t val; + + KASSERT(ant_mode == BWI_ANT_MODE_0 || + ant_mode == BWI_ANT_MODE_1 || + ant_mode == BWI_ANT_MODE_AUTO, ("ant_mode %d", ant_mode)); + + HFLAGS_CLRBITS(mac, BWI_HFLAG_AUTO_ANTDIV); + + if (phy->phy_mode == IEEE80211_MODE_11B) { + /* NOTE: v4/v3 conflicts, take v3 */ + if (mac->mac_rev == 2) + val = BWI_ANT_MODE_AUTO; + else + val = ant_mode; + val <<= 7; + PHY_FILT_SETBITS(mac, 0x3e2, 0xfe7f, val); + } else { /* 11a/g */ + /* XXX reg/value naming */ + val = ant_mode << 7; + PHY_FILT_SETBITS(mac, 0x401, 0x7e7f, val); + + if (ant_mode == BWI_ANT_MODE_AUTO) + PHY_CLRBITS(mac, 0x42b, 0x100); + + if (phy->phy_mode == IEEE80211_MODE_11A) { + /* TODO:11A */ + } else { /* 11g */ + if (ant_mode == BWI_ANT_MODE_AUTO) + PHY_SETBITS(mac, 0x48c, 0x2000); + else + PHY_CLRBITS(mac, 0x48c, 0x2000); + + if (phy->phy_rev >= 2) { + PHY_SETBITS(mac, 0x461, 0x10); + PHY_FILT_SETBITS(mac, 0x4ad, 0xff00, 0x15); + if (phy->phy_rev == 2) { + PHY_WRITE(mac, 0x427, 0x8); + } else { + PHY_FILT_SETBITS(mac, 0x427, + 0xff00, 0x8); + } + + if (phy->phy_rev >= 6) + PHY_WRITE(mac, 0x49b, 0xdc); + } + } + } + + /* XXX v4 set AUTO_ANTDIV unconditionally */ + if (ant_mode == BWI_ANT_MODE_AUTO) + HFLAGS_SETBITS(mac, BWI_HFLAG_AUTO_ANTDIV); + + val = ant_mode << 8; + MOBJ_FILT_SETBITS_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_TX_BEACON, + 0xfc3f, val); + MOBJ_FILT_SETBITS_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_TX_ACK, + 0xfc3f, val); + MOBJ_FILT_SETBITS_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_TX_PROBE_RESP, + 0xfc3f, val); + + /* XXX what's these */ + if (phy->phy_mode == IEEE80211_MODE_11B) + CSR_SETBITS_2(sc, 0x5e, 0x4); + + CSR_WRITE_4(sc, 0x100, 0x1000000); + if (mac->mac_rev < 5) + CSR_WRITE_4(sc, 0x10c, 0x1000000); + + mac->mac_rf.rf_ant_mode = ant_mode; +} + +int +bwi_rf_get_latest_tssi(struct bwi_mac *mac, int8_t tssi[], uint16_t ofs) +{ + int i; + + for (i = 0; i < 4; ) { + uint16_t val; + + val = MOBJ_READ_2(mac, BWI_COMM_MOBJ, ofs + i); + tssi[i++] = (int8_t)__SHIFTOUT(val, BWI_LO_TSSI_MASK); + tssi[i++] = (int8_t)__SHIFTOUT(val, BWI_HI_TSSI_MASK); + } + + for (i = 0; i < 4; ++i) { + if (tssi[i] == BWI_INVALID_TSSI) + return EINVAL; + } + return 0; +} + +int +bwi_rf_tssi2dbm(struct bwi_mac *mac, int8_t tssi, int8_t *txpwr) +{ + struct bwi_rf *rf = &mac->mac_rf; + int pwr_idx; + + pwr_idx = rf->rf_idle_tssi + (int)tssi - rf->rf_base_tssi; +#if 0 + if (pwr_idx < 0 || pwr_idx >= BWI_TSSI_MAX) + return EINVAL; +#else + if (pwr_idx < 0) + pwr_idx = 0; + else if (pwr_idx >= BWI_TSSI_MAX) + pwr_idx = BWI_TSSI_MAX - 1; +#endif + + *txpwr = rf->rf_txpower_map[pwr_idx]; + return 0; +} + +static int +bwi_rf_calc_rssi_bcm2050(struct bwi_mac *mac, const struct bwi_rxbuf_hdr *hdr) +{ + uint16_t flags1, flags3; + int rssi, lna_gain; + + rssi = hdr->rxh_rssi; + flags1 = le16toh(hdr->rxh_flags1); + flags3 = le16toh(hdr->rxh_flags3); + +#define NEW_BCM2050_RSSI +#ifdef NEW_BCM2050_RSSI + if (flags1 & BWI_RXH_F1_OFDM) { + if (rssi > 127) + rssi -= 256; + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 17; + else + rssi -= 4; + return rssi; + } + + if (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) { + struct bwi_rf *rf = &mac->mac_rf; + + if (rssi >= BWI_NRSSI_TBLSZ) + rssi = BWI_NRSSI_TBLSZ - 1; + + rssi = ((31 - (int)rf->rf_nrssi_table[rssi]) * -131) / 128; + rssi -= 67; + } else { + rssi = ((31 - rssi) * -149) / 128; + rssi -= 68; + } + + if (mac->mac_phy.phy_mode != IEEE80211_MODE_11G) + return rssi; + + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 20; + + lna_gain = __SHIFTOUT(le16toh(hdr->rxh_phyinfo), + BWI_RXH_PHYINFO_LNAGAIN); +#if 0 + DPRINTF(mac->mac_sc, "lna_gain %d, phyinfo 0x%04x\n", + lna_gain, le16toh(hdr->rxh_phyinfo)); +#endif + switch (lna_gain) { + case 0: + rssi += 27; + break; + case 1: + rssi += 6; + break; + case 2: + rssi += 12; + break; + case 3: + /* + * XXX + * According to v3 spec, we should do _nothing_ here, + * but it seems that the result RSSI will be too low + * (relative to what ath(4) says). Raise it a little + * bit. + */ + rssi += 5; + break; + default: + panic("impossible lna gain %d", lna_gain); + } +#else /* !NEW_BCM2050_RSSI */ + lna_gain = 0; /* shut up gcc warning */ + + if (flags1 & BWI_RXH_F1_OFDM) { + if (rssi > 127) + rssi -= 256; + rssi = (rssi * 73) / 64; + + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 25; + else + rssi -= 3; + return rssi; + } + + if (mac->mac_sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) { + struct bwi_rf *rf = &mac->mac_rf; + + if (rssi >= BWI_NRSSI_TBLSZ) + rssi = BWI_NRSSI_TBLSZ - 1; + + rssi = ((31 - (int)rf->rf_nrssi_table[rssi]) * -131) / 128; + rssi -= 57; + } else { + rssi = ((31 - rssi) * -149) / 128; + rssi -= 68; + } + + if (mac->mac_phy.phy_mode != IEEE80211_MODE_11G) + return rssi; + + if (flags3 & BWI_RXH_F3_BCM2050_RSSI) + rssi += 25; +#endif /* NEW_BCM2050_RSSI */ + return rssi; +} + +static int +bwi_rf_calc_rssi_bcm2053(struct bwi_mac *mac, const struct bwi_rxbuf_hdr *hdr) +{ + uint16_t flags1; + int rssi; + + rssi = (((int)hdr->rxh_rssi - 11) * 103) / 64; + + flags1 = le16toh(hdr->rxh_flags1); + if (flags1 & BWI_RXH_F1_BCM2053_RSSI) + rssi -= 109; + else + rssi -= 83; + return rssi; +} + +static int +bwi_rf_calc_rssi_bcm2060(struct bwi_mac *mac, const struct bwi_rxbuf_hdr *hdr) +{ + int rssi; + + rssi = hdr->rxh_rssi; + if (rssi > 127) + rssi -= 256; + return rssi; +} --- /dev/null +++ sys/dev/bwi/bitops.h @@ -0,0 +1,81 @@ +/* + * Copyright (c) 2004, 2005 David Young. All rights reserved. + * + * Programmed for NetBSD by David Young. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of David Young may not be used to endorse or promote + * products derived from this software without specific prior + * written permission. + * + * THIS SOFTWARE IS PROVIDED BY David Young ``AS IS'' AND ANY + * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, + * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A + * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL David + * Young BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, + * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED + * TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND + * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY + * OF SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bitops.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bitops.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BITOPS_H +#define _BITOPS_H + +/* + * __BIT(n): Return a bitmask with bit m set, where the least + * significant bit is bit 0. + * + * __BITS(m, n): Return a bitmask with bits m through n, inclusive, + * set. It does not matter whether m>n or m<=n. The + * least significant bit is bit 0. + * + * A "bitfield" is a span of consecutive bits defined by a bitmask, + * where 1s select the bits in the bitfield. __SHIFTIN, __SHIFTOUT, + * and SHIFTOUT_MASK help read and write bitfields from device registers. + * + * __SHIFTIN(v, mask): Left-shift bits `v' into the bitfield + * defined by `mask', and return them. No + * side-effects. + * + * __SHIFTOUT(v, mask): Extract and return the bitfield selected + * by `mask' from `v', right-shifting the + * bits so that the rightmost selected bit + * is at bit 0. No side-effects. + * + * __SHIFTOUT_MASK(mask): Right-shift the bits in `mask' so that + * the rightmost non-zero bit is at bit + * 0. This is useful for finding the + * greatest unsigned value that a bitfield + * can hold. No side-effects. Note that + * SHIFTOUT_MASK(m) = SHIFTOUT(m, m). + */ + +/* __BIT(n): nth bit, where __BIT(0) == 0x1. */ +#define __BIT(__n) (((__n) == 32) ? 0 : ((uint32_t)1 << (__n))) + +/* __BITS(m, n): bits m through n, m < n. */ +#define __BITS(__m, __n) \ + ((__BIT(MAX((__m), (__n)) + 1) - 1) ^ (__BIT(MIN((__m), (__n))) - 1)) + +/* Find least significant bit that is set */ +#define __LOWEST_SET_BIT(__mask) ((((__mask) - 1) & (__mask)) ^ (__mask)) + +#define __SHIFTOUT(__x, __mask) (((__x) & (__mask)) / __LOWEST_SET_BIT(__mask)) +#define __SHIFTIN(__x, __mask) ((__x) * __LOWEST_SET_BIT(__mask)) +#define __SHIFTOUT_MASK(__mask) __SHIFTOUT((__mask), (__mask)) + +#endif /* !_BITOPS_H */ --- /dev/null +++ sys/dev/bwi/if_bwi_pci.c @@ -0,0 +1,283 @@ +/*- + * Copyright (c) 2002-2007 Sam Leffler, Errno Consulting + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer, + * without modification. + * 2. Redistributions in binary form must reproduce at minimum a disclaimer + * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any + * redistribution must be conditioned upon including a substantially + * similar Disclaimer requirement for further binary redistribution. + * + * NO WARRANTY + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY + * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL + * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, + * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER + * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF + * THE POSSIBILITY OF SUCH DAMAGES. + */ + +#include + +/* + * PCI/Cardbus front-end for the Broadcom Wireless LAN controller driver. + */ + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include + +#include +#include +#include + +#include +#include +#include + +#include +#include + +#include "if_bwivar.h" +#include "if_bwireg.h" +#include "bitops.h" + +/* + * PCI glue. + */ + +struct bwi_pci_softc { + struct bwi_softc sc_sc; +}; + +#define BS_BAR 0x10 +#define PCIR_RETRY_TIMEOUT 0x41 + +static const struct bwi_dev { + uint16_t vid; + uint16_t did; + const char *desc; +} bwi_devices[] = { + { PCI_VENDOR_BROADCOM, 0x4301,"Broadcom BCM4301 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4307,"Broadcom BCM4307 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4311,"Broadcom BCM4311 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4312,"Broadcom BCM4312 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4320,"Broadcom BCM4306v1 802.11 Wireless Lan"}, + { PCI_VENDOR_BROADCOM, 0x4321,"Broadcom BCM4306v2 802.11 Wireless Lan"}, + { PCI_VENDOR_BROADCOM, 0x4325,"Broadcom BCM4306v3 802.11 Wireless Lan"}, + { PCI_VENDOR_BROADCOM, 0x4324,"Broadcom BCM4309 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4318,"Broadcom BCM4318 802.11 Wireless Lan" }, + { PCI_VENDOR_BROADCOM, 0x4319,"Broadcom BCM4319 802.11 Wireless Lan" } +}; + +static int +bwi_pci_probe(device_t dev) +{ + const struct bwi_dev *b; + uint16_t did, vid; + + did = pci_get_device(dev); + vid = pci_get_vendor(dev); + + for (b = bwi_devices; b->desc != NULL; ++b) { + if (b->did == did && b->vid == vid) { + device_set_desc(dev, b->desc); + return BUS_PROBE_DEFAULT; + } + } + return ENXIO; +} + +static u_int32_t +bwi_pci_setup(device_t dev) +{ + u_int32_t cmd; + + /* + * Enable memory mapping and bus mastering. + */ + cmd = pci_read_config(dev, PCIR_COMMAND, 4); + cmd |= PCIM_CMD_MEMEN | PCIM_CMD_BUSMASTEREN; + pci_write_config(dev, PCIR_COMMAND, cmd, 4); + cmd = pci_read_config(dev, PCIR_COMMAND, 4); + if ((cmd & PCIM_CMD_MEMEN) == 0) { + device_printf(dev, "failed to enable memory mapping\n"); + return 0; + } + if ((cmd & PCIM_CMD_BUSMASTEREN) == 0) { + device_printf(dev, "failed to enable bus mastering\n"); + return 0; + } + + /* + * Disable retry timeout to keep PCI Tx retries from + * interfering with C3 CPU state. + */ + pci_write_config(dev, PCIR_RETRY_TIMEOUT, 0, 1); + + return 1; +} + +static int +bwi_pci_attach(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + struct bwi_softc *sc = &psc->sc_sc; + int error = ENXIO; + + sc->sc_dev = dev; + + if (!bwi_pci_setup(dev)) + goto bad; + + /* + * Setup memory-mapping of PCI registers. + */ + sc->sc_mem_rid = BWI_PCIR_BAR; + sc->sc_mem_res = bus_alloc_resource_any(dev, SYS_RES_MEMORY, + &sc->sc_mem_rid, RF_ACTIVE); + if (sc->sc_mem_res == NULL) { + device_printf(dev, "cannot map register space\n"); + goto bad; + } + sc->sc_mem_bt = rman_get_bustag(sc->sc_mem_res); + sc->sc_mem_bh = rman_get_bushandle(sc->sc_mem_res); + /* + * Mark device invalid so any interrupts (shared or otherwise) + * that arrive before the card is setup are discarded. + */ + sc->sc_invalid = 1; + + /* + * Arrange interrupt line. + */ + sc->sc_irq_rid = 0; + sc->sc_irq_res = bus_alloc_resource_any(dev, SYS_RES_IRQ, + &sc->sc_irq_rid, + RF_SHAREABLE|RF_ACTIVE); + if (sc->sc_irq_res == NULL) { + device_printf(dev, "could not map interrupt\n"); + goto bad1; + } + if (bus_setup_intr(dev, sc->sc_irq_res, + INTR_TYPE_NET | INTR_MPSAFE, + NULL, bwi_intr, sc, &sc->sc_irq_handle)) { + device_printf(dev, "could not establish interrupt\n"); + goto bad2; + } + + /* Get more PCI information */ + sc->sc_pci_did = pci_get_device(dev); + sc->sc_pci_revid = pci_get_revid(dev); + sc->sc_pci_subvid = pci_get_subvendor(dev); + sc->sc_pci_subdid = pci_get_subdevice(dev); + + error = bwi_attach(sc); + if (error == 0) /* success */ + return 0; + + bus_teardown_intr(dev, sc->sc_irq_res, sc->sc_irq_handle); +bad2: + bus_release_resource(dev, SYS_RES_IRQ, 0, sc->sc_irq_res); +bad1: + bus_release_resource(dev, SYS_RES_MEMORY, BS_BAR, sc->sc_mem_res); +bad: + return (error); +} + +static int +bwi_pci_detach(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + struct bwi_softc *sc = &psc->sc_sc; + + /* check if device was removed */ + sc->sc_invalid = !bus_child_present(dev); + + bwi_detach(sc); + + bus_generic_detach(dev); + bus_teardown_intr(dev, sc->sc_irq_res, sc->sc_irq_handle); + bus_release_resource(dev, SYS_RES_IRQ, 0, sc->sc_irq_res); + + bus_release_resource(dev, SYS_RES_MEMORY, BS_BAR, sc->sc_mem_res); + + return (0); +} + +static int +bwi_pci_shutdown(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + + bwi_shutdown(&psc->sc_sc); + return (0); +} + +static int +bwi_pci_suspend(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + + bwi_suspend(&psc->sc_sc); + + return (0); +} + +static int +bwi_pci_resume(device_t dev) +{ + struct bwi_pci_softc *psc = device_get_softc(dev); + + if (!bwi_pci_setup(dev)) + return ENXIO; + + bwi_resume(&psc->sc_sc); + + return (0); +} + +static device_method_t bwi_pci_methods[] = { + /* Device interface */ + DEVMETHOD(device_probe, bwi_pci_probe), + DEVMETHOD(device_attach, bwi_pci_attach), + DEVMETHOD(device_detach, bwi_pci_detach), + DEVMETHOD(device_shutdown, bwi_pci_shutdown), + DEVMETHOD(device_suspend, bwi_pci_suspend), + DEVMETHOD(device_resume, bwi_pci_resume), + + { 0,0 } +}; +static driver_t bwi_driver = { + "bwi", + bwi_pci_methods, + sizeof (struct bwi_pci_softc) +}; +static devclass_t bwi_devclass; +DRIVER_MODULE(if_bwi, pci, bwi_driver, bwi_devclass, 0, 0); +DRIVER_MODULE(bwi, cardbus, bwi_driver, bwi_devclass, 0, 0); +MODULE_VERSION(if_bwi, 1); +MODULE_DEPEND(if_bwi, wlan, 1, 1, 1); /* 802.11 media layer */ +MODULE_DEPEND(if_bwi, firmware, 1, 1, 1); /* firmware support */ +MODULE_DEPEND(if_bwi, wlan_amrr, 1, 1, 1); --- /dev/null +++ sys/dev/bwi/bwirf.h @@ -0,0 +1,149 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwirf.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwirf.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BWI_RF_H +#define _BWI_RF_H + +int bwi_rf_attach(struct bwi_mac *); +void bwi_rf_clear_state(struct bwi_rf *); + +int bwi_rf_map_txpower(struct bwi_mac *); +void bwi_rf_lo_adjust(struct bwi_mac *, const struct bwi_tpctl *); +void bwi_rf_set_chan(struct bwi_mac *, u_int, int); +void bwi_rf_get_gains(struct bwi_mac *); +void bwi_rf_init(struct bwi_mac *); +void bwi_rf_init_bcm2050(struct bwi_mac *); +void bwi_rf_lo_update(struct bwi_mac *); +void bwi_rf_init_hw_nrssi_table(struct bwi_mac *, uint16_t); +void bwi_rf_set_ant_mode(struct bwi_mac *, int); + +void bwi_rf_clear_tssi(struct bwi_mac *); +int bwi_rf_get_latest_tssi(struct bwi_mac *, int8_t[], uint16_t); +int bwi_rf_tssi2dbm(struct bwi_mac *, int8_t, int8_t *); + +void bwi_rf_write(struct bwi_mac *, uint16_t, uint16_t); +uint16_t bwi_rf_read(struct bwi_mac *, uint16_t); + +static __inline void +bwi_rf_off(struct bwi_mac *_mac) +{ + _mac->mac_rf.rf_off(_mac); + /* TODO:LED */ + + _mac->mac_rf.rf_flags &= ~BWI_RF_F_ON; +} + +static __inline void +bwi_rf_on(struct bwi_mac *_mac) +{ + if (_mac->mac_rf.rf_flags & BWI_RF_F_ON) + return; + + _mac->mac_rf.rf_on(_mac); + /* TODO: LED */ + + _mac->mac_rf.rf_flags |= BWI_RF_F_ON; +} + +static __inline void +bwi_rf_calc_nrssi_slope(struct bwi_mac *_mac) +{ + _mac->mac_rf.rf_calc_nrssi_slope(_mac); +} + +static __inline void +bwi_rf_set_nrssi_thr(struct bwi_mac *_mac) +{ + _mac->mac_rf.rf_set_nrssi_thr(_mac); +} + +static __inline int +bwi_rf_calc_rssi(struct bwi_mac *_mac, const struct bwi_rxbuf_hdr *_hdr) +{ + return _mac->mac_rf.rf_calc_rssi(_mac, _hdr); +} + +#define RF_WRITE(mac, ofs, val) bwi_rf_write((mac), (ofs), (val)) +#define RF_READ(mac, ofs) bwi_rf_read((mac), (ofs)) + +#define RF_SETBITS(mac, ofs, bits) \ + RF_WRITE((mac), (ofs), RF_READ((mac), (ofs)) | (bits)) +#define RF_CLRBITS(mac, ofs, bits) \ + RF_WRITE((mac), (ofs), RF_READ((mac), (ofs)) & ~(bits)) +#define RF_FILT_SETBITS(mac, ofs, filt, bits) \ + RF_WRITE((mac), (ofs), (RF_READ((mac), (ofs)) & (filt)) | (bits)) + +#define BWI_RFR_ATTEN 0x43 + +#define BWI_RFR_TXPWR 0x52 +#define BWI_RFR_TXPWR1_MASK __BITS(6, 4) + +#define BWI_RFR_BBP_ATTEN 0x60 +#define BWI_RFR_BBP_ATTEN_CALIB_BIT __BIT(0) +#define BWI_RFR_BBP_ATTEN_CALIB_IDX __BITS(4, 1) + +/* + * TSSI -- TX power maps + */ +/* + * http://bcm-specs.sipsolutions.net/TSSI_to_DBM_Table + * B PHY + */ +#define BWI_TXPOWER_MAP_11B \ + 0x4d, 0x4c, 0x4b, 0x4a, 0x4a, 0x49, 0x48, 0x47, \ + 0x47, 0x46, 0x45, 0x45, 0x44, 0x43, 0x42, 0x42, \ + 0x41, 0x40, 0x3f, 0x3e, 0x3d, 0x3c, 0x3b, 0x3a, \ + 0x39, 0x38, 0x37, 0x36, 0x35, 0x34, 0x32, 0x31, \ + 0x30, 0x2f, 0x2d, 0x2c, 0x2b, 0x29, 0x28, 0x26, \ + 0x25, 0x23, 0x21, 0x1f, 0x1d, 0x1a, 0x17, 0x14, \ + 0x10, 0x0c, 0x06, 0x00, -7, -7, -7, -7, \ + -7, -7, -7, -7, -7, -7, -7, -7 +/* + * http://bcm-specs.sipsolutions.net/TSSI_to_DBM_Table + * G PHY + */ +#define BWI_TXPOWER_MAP_11G \ + 77, 77, 77, 76, 76, 76, 75, 75, \ + 74, 74, 73, 73, 73, 72, 72, 71, \ + 71, 70, 70, 69, 68, 68, 67, 67, \ + 66, 65, 65, 64, 63, 63, 62, 61, \ + 60, 59, 58, 57, 56, 55, 54, 53, \ + 52, 50, 49, 47, 45, 43, 40, 37, \ + 33, 28, 22, 14, 5, -7, -20, -20, \ + -20, -20, -20, -20, -20, -20, -20, -20 + +#endif /* !_BWI_RF_H */ --- /dev/null +++ sys/dev/bwi/bwiphy.c @@ -0,0 +1,962 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwiphy.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwiphy.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" +#include "bwiphy.h" + +static void bwi_phy_init_11a(struct bwi_mac *); +static void bwi_phy_init_11g(struct bwi_mac *); +static void bwi_phy_init_11b_rev2(struct bwi_mac *); +static void bwi_phy_init_11b_rev4(struct bwi_mac *); +static void bwi_phy_init_11b_rev5(struct bwi_mac *); +static void bwi_phy_init_11b_rev6(struct bwi_mac *); + +static void bwi_phy_config_11g(struct bwi_mac *); +static void bwi_phy_config_agc(struct bwi_mac *); + +static void bwi_tbl_write_2(struct bwi_mac *mac, uint16_t, uint16_t); +static void bwi_tbl_write_4(struct bwi_mac *mac, uint16_t, uint32_t); + +#define SUP_BPHY(num) { .rev = num, .init = bwi_phy_init_11b_rev##num } + +static const struct { + uint8_t rev; + void (*init)(struct bwi_mac *); +} bwi_sup_bphy[] = { + SUP_BPHY(2), + SUP_BPHY(4), + SUP_BPHY(5), + SUP_BPHY(6) +}; + +#undef SUP_BPHY + +#define BWI_PHYTBL_WRSSI 0x1000 +#define BWI_PHYTBL_NOISE_SCALE 0x1400 +#define BWI_PHYTBL_NOISE 0x1800 +#define BWI_PHYTBL_ROTOR 0x2000 +#define BWI_PHYTBL_DELAY 0x2400 +#define BWI_PHYTBL_RSSI 0x4000 +#define BWI_PHYTBL_SIGMA_SQ 0x5000 +#define BWI_PHYTBL_WRSSI_REV1 0x5400 +#define BWI_PHYTBL_FREQ 0x5800 + +static const uint16_t bwi_phy_freq_11g_rev1[] = + { BWI_PHY_FREQ_11G_REV1 }; +static const uint16_t bwi_phy_noise_11g_rev1[] = + { BWI_PHY_NOISE_11G_REV1 }; +static const uint16_t bwi_phy_noise_11g[] = + { BWI_PHY_NOISE_11G }; +static const uint32_t bwi_phy_rotor_11g_rev1[] = + { BWI_PHY_ROTOR_11G_REV1 }; +static const uint16_t bwi_phy_noise_scale_11g_rev2[] = + { BWI_PHY_NOISE_SCALE_11G_REV2 }; +static const uint16_t bwi_phy_noise_scale_11g_rev7[] = + { BWI_PHY_NOISE_SCALE_11G_REV7 }; +static const uint16_t bwi_phy_noise_scale_11g[] = + { BWI_PHY_NOISE_SCALE_11G }; +static const uint16_t bwi_phy_sigma_sq_11g_rev2[] = + { BWI_PHY_SIGMA_SQ_11G_REV2 }; +static const uint16_t bwi_phy_sigma_sq_11g_rev7[] = + { BWI_PHY_SIGMA_SQ_11G_REV7 }; +static const uint32_t bwi_phy_delay_11g_rev1[] = + { BWI_PHY_DELAY_11G_REV1 }; + +void +bwi_phy_write(struct bwi_mac *mac, uint16_t ctrl, uint16_t data) +{ + struct bwi_softc *sc = mac->mac_sc; + + /* TODO: 11A */ + CSR_WRITE_2(sc, BWI_PHY_CTRL, ctrl); + CSR_WRITE_2(sc, BWI_PHY_DATA, data); +} + +uint16_t +bwi_phy_read(struct bwi_mac *mac, uint16_t ctrl) +{ + struct bwi_softc *sc = mac->mac_sc; + + /* TODO: 11A */ + CSR_WRITE_2(sc, BWI_PHY_CTRL, ctrl); + return CSR_READ_2(sc, BWI_PHY_DATA); +} + +int +bwi_phy_attach(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + uint8_t phyrev, phytype, phyver; + uint16_t val; + int i; + + /* Get PHY type/revision/version */ + val = CSR_READ_2(sc, BWI_PHYINFO); + phyrev = __SHIFTOUT(val, BWI_PHYINFO_REV_MASK); + phytype = __SHIFTOUT(val, BWI_PHYINFO_TYPE_MASK); + phyver = __SHIFTOUT(val, BWI_PHYINFO_VER_MASK); + device_printf(sc->sc_dev, "PHY: type %d, rev %d, ver %d\n", + phytype, phyrev, phyver); + + /* + * Verify whether the revision of the PHY type is supported + * Convert PHY type to ieee80211_phymode + */ + switch (phytype) { + case BWI_PHYINFO_TYPE_11A: + if (phyrev >= 4) { + device_printf(sc->sc_dev, "unsupported 11A PHY, " + "rev %u\n", phyrev); + return ENXIO; + } + phy->phy_init = bwi_phy_init_11a; + phy->phy_mode = IEEE80211_MODE_11A; + phy->phy_tbl_ctrl = BWI_PHYR_TBL_CTRL_11A; + phy->phy_tbl_data_lo = BWI_PHYR_TBL_DATA_LO_11A; + phy->phy_tbl_data_hi = BWI_PHYR_TBL_DATA_HI_11A; + device_printf(sc->sc_dev, "PHY: 802.11A attach\n"); + break; + case BWI_PHYINFO_TYPE_11B: +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + for (i = 0; i < N(bwi_sup_bphy); ++i) { + if (phyrev == bwi_sup_bphy[i].rev) { + phy->phy_init = bwi_sup_bphy[i].init; + break; + } + } + if (i == N(bwi_sup_bphy)) { + device_printf(sc->sc_dev, "unsupported 11B PHY, " + "rev %u\n", phyrev); + return ENXIO; + } +#undef N + phy->phy_mode = IEEE80211_MODE_11B; + device_printf(sc->sc_dev, "PHY: 802.11B attach\n"); + break; + case BWI_PHYINFO_TYPE_11G: + if (phyrev > 8) { + device_printf(sc->sc_dev, "unsupported 11G PHY, " + "rev %u\n", phyrev); + return ENXIO; + } + phy->phy_init = bwi_phy_init_11g; + phy->phy_mode = IEEE80211_MODE_11G; + phy->phy_tbl_ctrl = BWI_PHYR_TBL_CTRL_11G; + phy->phy_tbl_data_lo = BWI_PHYR_TBL_DATA_LO_11G; + phy->phy_tbl_data_hi = BWI_PHYR_TBL_DATA_HI_11G; + device_printf(sc->sc_dev, "PHY: 802.11G attach\n"); + break; + default: + device_printf(sc->sc_dev, "unsupported PHY type %d\n", + phytype); + return ENXIO; + } + phy->phy_rev = phyrev; + phy->phy_version = phyver; + return 0; +} + +void +bwi_phy_set_bbp_atten(struct bwi_mac *mac, uint16_t bbp_atten) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint16_t mask = __BITS(3, 0); + + if (phy->phy_version == 0) { + CSR_FILT_SETBITS_2(mac->mac_sc, BWI_BBP_ATTEN, ~mask, + __SHIFTIN(bbp_atten, mask)); + } else { + if (phy->phy_version > 1) + mask <<= 2; + else + mask <<= 3; + PHY_FILT_SETBITS(mac, BWI_PHYR_BBP_ATTEN, ~mask, + __SHIFTIN(bbp_atten, mask)); + } +} + +int +bwi_phy_calibrate(struct bwi_mac *mac) +{ + struct bwi_phy *phy = &mac->mac_phy; + + /* Dummy read */ + CSR_READ_4(mac->mac_sc, BWI_MAC_STATUS); + + /* Don't re-init */ + if (phy->phy_flags & BWI_PHY_F_CALIBRATED) + return 0; + + if (phy->phy_mode == IEEE80211_MODE_11G && phy->phy_rev == 1) { + bwi_mac_reset(mac, 0); + bwi_phy_init_11g(mac); + bwi_mac_reset(mac, 1); + } + + phy->phy_flags |= BWI_PHY_F_CALIBRATED; + return 0; +} + +static void +bwi_tbl_write_2(struct bwi_mac *mac, uint16_t ofs, uint16_t data) +{ + struct bwi_phy *phy = &mac->mac_phy; + + KASSERT(phy->phy_tbl_ctrl != 0 && phy->phy_tbl_data_lo != 0, + ("phy_tbl_ctrl %d phy_tbl_data_lo %d", + phy->phy_tbl_ctrl, phy->phy_tbl_data_lo)); + PHY_WRITE(mac, phy->phy_tbl_ctrl, ofs); + PHY_WRITE(mac, phy->phy_tbl_data_lo, data); +} + +static void +bwi_tbl_write_4(struct bwi_mac *mac, uint16_t ofs, uint32_t data) +{ + struct bwi_phy *phy = &mac->mac_phy; + + KASSERT(phy->phy_tbl_data_lo != 0 && phy->phy_tbl_data_hi != 0 && + phy->phy_tbl_ctrl != 0, + ("phy_tbl_data_lo %d phy_tbl_data_hi %d phy_tbl_ctrl %d", + phy->phy_tbl_data_lo, phy->phy_tbl_data_hi, phy->phy_tbl_ctrl)); + + PHY_WRITE(mac, phy->phy_tbl_ctrl, ofs); + PHY_WRITE(mac, phy->phy_tbl_data_hi, data >> 16); + PHY_WRITE(mac, phy->phy_tbl_data_lo, data & 0xffff); +} + +void +bwi_nrssi_write(struct bwi_mac *mac, uint16_t ofs, int16_t data) +{ + PHY_WRITE(mac, BWI_PHYR_NRSSI_CTRL, ofs); + PHY_WRITE(mac, BWI_PHYR_NRSSI_DATA, (uint16_t)data); +} + +int16_t +bwi_nrssi_read(struct bwi_mac *mac, uint16_t ofs) +{ + PHY_WRITE(mac, BWI_PHYR_NRSSI_CTRL, ofs); + return (int16_t)PHY_READ(mac, BWI_PHYR_NRSSI_DATA); +} + +static void +bwi_phy_init_11a(struct bwi_mac *mac) +{ + /* TODO:11A */ +} + +static void +bwi_phy_init_11g(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + const struct bwi_tpctl *tpctl = &mac->mac_tpctl; + + if (phy->phy_rev == 1) + bwi_phy_init_11b_rev5(mac); + else + bwi_phy_init_11b_rev6(mac); + + if (phy->phy_rev >= 2 || (phy->phy_flags & BWI_PHY_F_LINKED)) + bwi_phy_config_11g(mac); + + if (phy->phy_rev >= 2) { + PHY_WRITE(mac, 0x814, 0); + PHY_WRITE(mac, 0x815, 0); + + if (phy->phy_rev == 2) { + PHY_WRITE(mac, 0x811, 0); + PHY_WRITE(mac, 0x15, 0xc0); + } else if (phy->phy_rev > 5) { + PHY_WRITE(mac, 0x811, 0x400); + PHY_WRITE(mac, 0x15, 0xc0); + } + } + + if (phy->phy_rev >= 2 || (phy->phy_flags & BWI_PHY_F_LINKED)) { + uint16_t val; + + val = PHY_READ(mac, 0x400) & 0xff; + if (val == 3 || val == 5) { + PHY_WRITE(mac, 0x4c2, 0x1816); + PHY_WRITE(mac, 0x4c3, 0x8006); + if (val == 5) { + PHY_FILT_SETBITS(mac, 0x4cc, + 0xff, 0x1f00); + } + } + } + + if ((phy->phy_rev <= 2 && (phy->phy_flags & BWI_PHY_F_LINKED)) || + phy->phy_rev >= 2) + PHY_WRITE(mac, 0x47e, 0x78); + + if (rf->rf_rev == 8) { + PHY_SETBITS(mac, 0x801, 0x80); + PHY_SETBITS(mac, 0x43e, 0x4); + } + + if (phy->phy_rev >= 2 && (phy->phy_flags & BWI_PHY_F_LINKED)) + bwi_rf_get_gains(mac); + + if (rf->rf_rev != 8) + bwi_rf_init(mac); + + if (tpctl->tp_ctrl2 == 0xffff) { + bwi_rf_lo_update(mac); + } else { + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev == 8) { + RF_WRITE(mac, 0x52, + (tpctl->tp_ctrl1 << 4) | tpctl->tp_ctrl2); + } else { + RF_FILT_SETBITS(mac, 0x52, 0xfff0, tpctl->tp_ctrl1); + } + + if (phy->phy_rev >= 6) { + PHY_FILT_SETBITS(mac, 0x36, 0xfff, + tpctl->tp_ctrl2 << 12); + } + + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) + PHY_WRITE(mac, 0x2e, 0x8075); + else + PHY_WRITE(mac, 0x2e, 0x807f); + + if (phy->phy_rev < 2) + PHY_WRITE(mac, 0x2f, 0x101); + else + PHY_WRITE(mac, 0x2f, 0x202); + } + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + bwi_rf_lo_adjust(mac, tpctl); + PHY_WRITE(mac, 0x80f, 0x8078); + } + + if ((sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) == 0) { + bwi_rf_init_hw_nrssi_table(mac, 0xffff /* XXX */); + bwi_rf_set_nrssi_thr(mac); + } else if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + if (rf->rf_nrssi[0] == BWI_INVALID_NRSSI) { + KASSERT(rf->rf_nrssi[1] == BWI_INVALID_NRSSI, + ("rf_nrssi[1] %d", rf->rf_nrssi[1])); + bwi_rf_calc_nrssi_slope(mac); + } else { + KASSERT(rf->rf_nrssi[1] != BWI_INVALID_NRSSI, + ("rf_nrssi[1] %d", rf->rf_nrssi[1])); + bwi_rf_set_nrssi_thr(mac); + } + } + + if (rf->rf_rev == 8) + PHY_WRITE(mac, 0x805, 0x3230); + + bwi_mac_init_tpctl_11bg(mac); + + if (sc->sc_bbp_id == BWI_BBPID_BCM4306 && sc->sc_bbp_pkg == 2) { + PHY_CLRBITS(mac, 0x429, 0x4000); + PHY_CLRBITS(mac, 0x4c3, 0x8000); + } +} + +static void +bwi_phy_init_11b_rev2(struct bwi_mac *mac) +{ + /* TODO:11B */ + if_printf(mac->mac_sc->sc_ic.ic_ifp, + "%s is not implemented yet\n", __func__); +} + +static void +bwi_phy_init_11b_rev4(struct bwi_mac *mac) +{ + /* TODO:11B */ + if_printf(mac->mac_sc->sc_ic.ic_ifp, + "%s is not implemented yet\n", __func__); +} + +static void +bwi_phy_init_11b_rev5(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + u_int orig_chan; + + if (phy->phy_version == 1) + RF_SETBITS(mac, 0x7a, 0x50); + + if (sc->sc_pci_subvid != PCI_VENDOR_BROADCOM && + sc->sc_pci_subdid != BWI_PCI_SUBDEVICE_BU4306) { + uint16_t ofs, val; + + val = 0x2120; + for (ofs = 0xa8; ofs < 0xc7; ++ofs) { + PHY_WRITE(mac, ofs, val); + val += 0x202; + } + } + + PHY_FILT_SETBITS(mac, 0x35, 0xf0ff, 0x700); + + if (rf->rf_type == BWI_RF_T_BCM2050) + PHY_WRITE(mac, 0x38, 0x667); + + if ((phy->phy_flags & BWI_PHY_F_LINKED) || phy->phy_rev >= 2) { + if (rf->rf_type == BWI_RF_T_BCM2050) { + RF_SETBITS(mac, 0x7a, 0x20); + RF_SETBITS(mac, 0x51, 0x4); + } + + CSR_WRITE_2(sc, BWI_RF_ANTDIV, 0); + + PHY_SETBITS(mac, 0x802, 0x100); + PHY_SETBITS(mac, 0x42b, 0x2000); + PHY_WRITE(mac, 0x1c, 0x186a); + + PHY_FILT_SETBITS(mac, 0x13, 0xff, 0x1900); + PHY_FILT_SETBITS(mac, 0x35, 0xffc0, 0x64); + PHY_FILT_SETBITS(mac, 0x5d, 0xff80, 0xa); + } + + /* TODO: bad_frame_preempt? */ + + if (phy->phy_version == 1) { + PHY_WRITE(mac, 0x26, 0xce00); + PHY_WRITE(mac, 0x21, 0x3763); + PHY_WRITE(mac, 0x22, 0x1bc3); + PHY_WRITE(mac, 0x23, 0x6f9); + PHY_WRITE(mac, 0x24, 0x37e); + } else { + PHY_WRITE(mac, 0x26, 0xcc00); + } + PHY_WRITE(mac, 0x30, 0xc6); + + CSR_WRITE_2(sc, BWI_BPHY_CTRL, BWI_BPHY_CTRL_INIT); + + if (phy->phy_version == 1) + PHY_WRITE(mac, 0x20, 0x3e1c); + else + PHY_WRITE(mac, 0x20, 0x301c); + + if (phy->phy_version == 0) + CSR_WRITE_2(sc, BWI_PHY_MAGIC_REG1, BWI_PHY_MAGIC_REG1_VAL1); + + /* Force to channel 7 */ + orig_chan = rf->rf_curchan; + bwi_rf_set_chan(mac, 7, 0); + + if (rf->rf_type != BWI_RF_T_BCM2050) { + RF_WRITE(mac, 0x75, 0x80); + RF_WRITE(mac, 0x79, 0x81); + } + + RF_WRITE(mac, 0x50, 0x20); + RF_WRITE(mac, 0x50, 0x23); + + if (rf->rf_type == BWI_RF_T_BCM2050) { + RF_WRITE(mac, 0x50, 0x20); + RF_WRITE(mac, 0x5a, 0x70); + } + + RF_WRITE(mac, 0x5b, 0x7b); + RF_WRITE(mac, 0x5c, 0xb0); + RF_SETBITS(mac, 0x7a, 0x7); + + bwi_rf_set_chan(mac, orig_chan, 0); + + PHY_WRITE(mac, 0x14, 0x80); + PHY_WRITE(mac, 0x32, 0xca); + PHY_WRITE(mac, 0x2a, 0x88a3); + + bwi_mac_set_tpctl_11bg(mac, NULL); + + if (rf->rf_type == BWI_RF_T_BCM2050) + RF_WRITE(mac, 0x5d, 0xd); + + CSR_FILT_SETBITS_2(sc, BWI_PHY_MAGIC_REG1, 0xffc0, 0x4); +} + +static void +bwi_phy_init_11b_rev6(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + uint16_t val, ofs; + u_int orig_chan; + + PHY_WRITE(mac, 0x3e, 0x817a); + RF_SETBITS(mac, 0x7a, 0x58); + + if (rf->rf_rev == 4 || rf->rf_rev == 5) { + RF_WRITE(mac, 0x51, 0x37); + RF_WRITE(mac, 0x52, 0x70); + RF_WRITE(mac, 0x53, 0xb3); + RF_WRITE(mac, 0x54, 0x9b); + RF_WRITE(mac, 0x5a, 0x88); + RF_WRITE(mac, 0x5b, 0x88); + RF_WRITE(mac, 0x5d, 0x88); + RF_WRITE(mac, 0x5e, 0x88); + RF_WRITE(mac, 0x7d, 0x88); + HFLAGS_SETBITS(mac, BWI_HFLAG_MAGIC1); + } else if (rf->rf_rev == 8) { + RF_WRITE(mac, 0x51, 0); + RF_WRITE(mac, 0x52, 0x40); + RF_WRITE(mac, 0x53, 0xb7); + RF_WRITE(mac, 0x54, 0x98); + RF_WRITE(mac, 0x5a, 0x88); + RF_WRITE(mac, 0x5b, 0x6b); + RF_WRITE(mac, 0x5c, 0xf); + if (sc->sc_card_flags & BWI_CARD_F_ALT_IQ) { + RF_WRITE(mac, 0x5d, 0xfa); + RF_WRITE(mac, 0x5e, 0xd8); + } else { + RF_WRITE(mac, 0x5d, 0xf5); + RF_WRITE(mac, 0x5e, 0xb8); + } + RF_WRITE(mac, 0x73, 0x3); + RF_WRITE(mac, 0x7d, 0xa8); + RF_WRITE(mac, 0x7c, 0x1); + RF_WRITE(mac, 0x7e, 0x8); + } + + val = 0x1e1f; + for (ofs = 0x88; ofs < 0x98; ++ofs) { + PHY_WRITE(mac, ofs, val); + val -= 0x202; + } + + val = 0x3e3f; + for (ofs = 0x98; ofs < 0xa8; ++ofs) { + PHY_WRITE(mac, ofs, val); + val -= 0x202; + } + + val = 0x2120; + for (ofs = 0xa8; ofs < 0xc8; ++ofs) { + PHY_WRITE(mac, ofs, (val & 0x3f3f)); + val += 0x202; + } + + if (phy->phy_mode == IEEE80211_MODE_11G) { + RF_SETBITS(mac, 0x7a, 0x20); + RF_SETBITS(mac, 0x51, 0x4); + PHY_SETBITS(mac, 0x802, 0x100); + PHY_SETBITS(mac, 0x42b, 0x2000); + PHY_WRITE(mac, 0x5b, 0); + PHY_WRITE(mac, 0x5c, 0); + } + + /* Force to channel 7 */ + orig_chan = rf->rf_curchan; + if (orig_chan >= 8) + bwi_rf_set_chan(mac, 1, 0); + else + bwi_rf_set_chan(mac, 13, 0); + + RF_WRITE(mac, 0x50, 0x20); + RF_WRITE(mac, 0x50, 0x23); + + DELAY(40); + + if (rf->rf_rev < 6 || rf->rf_rev == 8) { + RF_SETBITS(mac, 0x7c, 0x2); + RF_WRITE(mac, 0x50, 0x20); + } + if (rf->rf_rev <= 2) { + RF_WRITE(mac, 0x7c, 0x20); + RF_WRITE(mac, 0x5a, 0x70); + RF_WRITE(mac, 0x5b, 0x7b); + RF_WRITE(mac, 0x5c, 0xb0); + } + + RF_FILT_SETBITS(mac, 0x7a, 0xf8, 0x7); + + bwi_rf_set_chan(mac, orig_chan, 0); + + PHY_WRITE(mac, 0x14, 0x200); + if (rf->rf_rev >= 6) + PHY_WRITE(mac, 0x2a, 0x88c2); + else + PHY_WRITE(mac, 0x2a, 0x8ac0); + PHY_WRITE(mac, 0x38, 0x668); + + bwi_mac_set_tpctl_11bg(mac, NULL); + + if (rf->rf_rev <= 5) { + PHY_FILT_SETBITS(mac, 0x5d, 0xff80, 0x3); + if (rf->rf_rev <= 2) + RF_WRITE(mac, 0x5d, 0xd); + } + + if (phy->phy_version == 4) { + CSR_WRITE_2(sc, BWI_PHY_MAGIC_REG1, BWI_PHY_MAGIC_REG1_VAL2); + PHY_CLRBITS(mac, 0x61, 0xf000); + } else { + PHY_FILT_SETBITS(mac, 0x2, 0xffc0, 0x4); + } + + if (phy->phy_mode == IEEE80211_MODE_11B) { + CSR_WRITE_2(sc, BWI_BBP_ATTEN, BWI_BBP_ATTEN_MAGIC2); + PHY_WRITE(mac, 0x16, 0x410); + PHY_WRITE(mac, 0x17, 0x820); + PHY_WRITE(mac, 0x62, 0x7); + + bwi_rf_init_bcm2050(mac); + bwi_rf_lo_update(mac); + if (sc->sc_card_flags & BWI_CARD_F_SW_NRSSI) { + bwi_rf_calc_nrssi_slope(mac); + bwi_rf_set_nrssi_thr(mac); + } + bwi_mac_init_tpctl_11bg(mac); + } else { + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0); + } +} + +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + +static void +bwi_phy_config_11g(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + const uint16_t *tbl; + uint16_t wrd_ofs1, wrd_ofs2; + int i, n; + + if (phy->phy_rev == 1) { + PHY_WRITE(mac, 0x406, 0x4f19); + PHY_FILT_SETBITS(mac, 0x429, 0xfc3f, 0x340); + PHY_WRITE(mac, 0x42c, 0x5a); + PHY_WRITE(mac, 0x427, 0x1a); + + /* Fill frequency table */ + for (i = 0; i < N(bwi_phy_freq_11g_rev1); ++i) { + bwi_tbl_write_2(mac, BWI_PHYTBL_FREQ + i, + bwi_phy_freq_11g_rev1[i]); + } + + /* Fill noise table */ + for (i = 0; i < N(bwi_phy_noise_11g_rev1); ++i) { + bwi_tbl_write_2(mac, BWI_PHYTBL_NOISE + i, + bwi_phy_noise_11g_rev1[i]); + } + + /* Fill rotor table */ + for (i = 0; i < N(bwi_phy_rotor_11g_rev1); ++i) { + /* NB: data length is 4 bytes */ + bwi_tbl_write_4(mac, BWI_PHYTBL_ROTOR + i, + bwi_phy_rotor_11g_rev1[i]); + } + } else { + bwi_nrssi_write(mac, 0xba98, (int16_t)0x7654); /* XXX */ + + if (phy->phy_rev == 2) { + PHY_WRITE(mac, 0x4c0, 0x1861); + PHY_WRITE(mac, 0x4c1, 0x271); + } else if (phy->phy_rev > 2) { + PHY_WRITE(mac, 0x4c0, 0x98); + PHY_WRITE(mac, 0x4c1, 0x70); + PHY_WRITE(mac, 0x4c9, 0x80); + } + PHY_SETBITS(mac, 0x42b, 0x800); + + /* Fill RSSI table */ + for (i = 0; i < 64; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_RSSI + i, i); + + /* Fill noise table */ + for (i = 0; i < sizeof(bwi_phy_noise_11g); ++i) { + bwi_tbl_write_2(mac, BWI_PHYTBL_NOISE + i, + bwi_phy_noise_11g[i]); + } + } + + /* + * Fill noise scale table + */ + if (phy->phy_rev <= 2) { + tbl = bwi_phy_noise_scale_11g_rev2; + n = N(bwi_phy_noise_scale_11g_rev2); + } else if (phy->phy_rev >= 7 && (PHY_READ(mac, 0x449) & 0x200)) { + tbl = bwi_phy_noise_scale_11g_rev7; + n = N(bwi_phy_noise_scale_11g_rev7); + } else { + tbl = bwi_phy_noise_scale_11g; + n = N(bwi_phy_noise_scale_11g); + } + for (i = 0; i < n; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_NOISE_SCALE + i, tbl[i]); + + /* + * Fill sigma square table + */ + if (phy->phy_rev == 2) { + tbl = bwi_phy_sigma_sq_11g_rev2; + n = N(bwi_phy_sigma_sq_11g_rev2); + } else if (phy->phy_rev > 2 && phy->phy_rev <= 8) { + tbl = bwi_phy_sigma_sq_11g_rev7; + n = N(bwi_phy_sigma_sq_11g_rev7); + } else { + tbl = NULL; + n = 0; + } + for (i = 0; i < n; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_SIGMA_SQ + i, tbl[i]); + + if (phy->phy_rev == 1) { + /* Fill delay table */ + for (i = 0; i < N(bwi_phy_delay_11g_rev1); ++i) { + bwi_tbl_write_4(mac, BWI_PHYTBL_DELAY + i, + bwi_phy_delay_11g_rev1[i]); + } + + /* Fill WRSSI (Wide-Band RSSI) table */ + for (i = 4; i < 20; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_WRSSI_REV1 + i, 0x20); + + bwi_phy_config_agc(mac); + + wrd_ofs1 = 0x5001; + wrd_ofs2 = 0x5002; + } else { + /* Fill WRSSI (Wide-Band RSSI) table */ + for (i = 0; i < 0x20; ++i) + bwi_tbl_write_2(mac, BWI_PHYTBL_WRSSI + i, 0x820); + + bwi_phy_config_agc(mac); + + PHY_READ(mac, 0x400); /* Dummy read */ + PHY_WRITE(mac, 0x403, 0x1000); + bwi_tbl_write_2(mac, 0x3c02, 0xf); + bwi_tbl_write_2(mac, 0x3c03, 0x14); + + wrd_ofs1 = 0x401; + wrd_ofs2 = 0x402; + } + + if (!(BWI_IS_BRCM_BU4306(sc) && sc->sc_pci_revid == 0x17)) { + bwi_tbl_write_2(mac, wrd_ofs1, 0x2); + bwi_tbl_write_2(mac, wrd_ofs2, 0x1); + } + + /* phy->phy_flags & BWI_PHY_F_LINKED ? */ + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) + PHY_WRITE(mac, 0x46e, 0x3cf); +} + +#undef N + +/* + * Configure Automatic Gain Controller + */ +static void +bwi_phy_config_agc(struct bwi_mac *mac) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint16_t ofs; + + ofs = phy->phy_rev == 1 ? 0x4c00 : 0; + + bwi_tbl_write_2(mac, ofs, 0xfe); + bwi_tbl_write_2(mac, ofs + 1, 0xd); + bwi_tbl_write_2(mac, ofs + 2, 0x13); + bwi_tbl_write_2(mac, ofs + 3, 0x19); + + if (phy->phy_rev == 1) { + bwi_tbl_write_2(mac, 0x1800, 0x2710); + bwi_tbl_write_2(mac, 0x1801, 0x9b83); + bwi_tbl_write_2(mac, 0x1802, 0x9b83); + bwi_tbl_write_2(mac, 0x1803, 0xf8d); + PHY_WRITE(mac, 0x455, 0x4); + } + + PHY_FILT_SETBITS(mac, 0x4a5, 0xff, 0x5700); + PHY_FILT_SETBITS(mac, 0x41a, 0xff80, 0xf); + PHY_FILT_SETBITS(mac, 0x41a, 0xc07f, 0x2b80); + PHY_FILT_SETBITS(mac, 0x48c, 0xf0ff, 0x300); + + RF_SETBITS(mac, 0x7a, 0x8); + + PHY_FILT_SETBITS(mac, 0x4a0, 0xfff0, 0x8); + PHY_FILT_SETBITS(mac, 0x4a1, 0xf0ff, 0x600); + PHY_FILT_SETBITS(mac, 0x4a2, 0xf0ff, 0x700); + PHY_FILT_SETBITS(mac, 0x4a0, 0xf0ff, 0x100); + + if (phy->phy_rev == 1) + PHY_FILT_SETBITS(mac, 0x4a2, 0xfff0, 0x7); + + PHY_FILT_SETBITS(mac, 0x488, 0xff00, 0x1c); + PHY_FILT_SETBITS(mac, 0x488, 0xc0ff, 0x200); + PHY_FILT_SETBITS(mac, 0x496, 0xff00, 0x1c); + PHY_FILT_SETBITS(mac, 0x489, 0xff00, 0x20); + PHY_FILT_SETBITS(mac, 0x489, 0xc0ff, 0x200); + PHY_FILT_SETBITS(mac, 0x482, 0xff00, 0x2e); + PHY_FILT_SETBITS(mac, 0x496, 0xff, 0x1a00); + PHY_FILT_SETBITS(mac, 0x481, 0xff00, 0x28); + PHY_FILT_SETBITS(mac, 0x481, 0xff, 0x2c00); + + if (phy->phy_rev == 1) { + PHY_WRITE(mac, 0x430, 0x92b); + PHY_FILT_SETBITS(mac, 0x41b, 0xffe1, 0x2); + } else { + PHY_CLRBITS(mac, 0x41b, 0x1e); + PHY_WRITE(mac, 0x41f, 0x287a); + PHY_FILT_SETBITS(mac, 0x420, 0xfff0, 0x4); + + if (phy->phy_rev >= 6) { + PHY_WRITE(mac, 0x422, 0x287a); + PHY_FILT_SETBITS(mac, 0x420, 0xfff, 0x3000); + } + } + + PHY_FILT_SETBITS(mac, 0x4a8, 0x8080, 0x7874); + PHY_WRITE(mac, 0x48e, 0x1c00); + + if (phy->phy_rev == 1) { + PHY_FILT_SETBITS(mac, 0x4ab, 0xf0ff, 0x600); + PHY_WRITE(mac, 0x48b, 0x5e); + PHY_FILT_SETBITS(mac, 0x48c, 0xff00, 0x1e); + PHY_WRITE(mac, 0x48d, 0x2); + } + + bwi_tbl_write_2(mac, ofs + 0x800, 0); + bwi_tbl_write_2(mac, ofs + 0x801, 7); + bwi_tbl_write_2(mac, ofs + 0x802, 16); + bwi_tbl_write_2(mac, ofs + 0x803, 28); + + if (phy->phy_rev >= 6) { + PHY_CLRBITS(mac, 0x426, 0x3); + PHY_CLRBITS(mac, 0x426, 0x1000); + } +} + +void +bwi_set_gains(struct bwi_mac *mac, const struct bwi_gains *gains) +{ + struct bwi_phy *phy = &mac->mac_phy; + uint16_t tbl_gain_ofs1, tbl_gain_ofs2, tbl_gain; + int i; + + if (phy->phy_rev <= 1) { + tbl_gain_ofs1 = 0x5000; + tbl_gain_ofs2 = tbl_gain_ofs1 + 16; + } else { + tbl_gain_ofs1 = 0x400; + tbl_gain_ofs2 = tbl_gain_ofs1 + 8; + } + + for (i = 0; i < 4; ++i) { + if (gains != NULL) { + tbl_gain = gains->tbl_gain1; + } else { + /* Bit swap */ + tbl_gain = (i & 0x1) << 1; + tbl_gain |= (i & 0x2) >> 1; + } + bwi_tbl_write_2(mac, tbl_gain_ofs1 + i, tbl_gain); + } + + for (i = 0; i < 16; ++i) { + if (gains != NULL) + tbl_gain = gains->tbl_gain2; + else + tbl_gain = i; + bwi_tbl_write_2(mac, tbl_gain_ofs2 + i, tbl_gain); + } + + if (gains == NULL || (gains != NULL && gains->phy_gain != -1)) { + uint16_t phy_gain1, phy_gain2; + + if (gains != NULL) { + phy_gain1 = + ((uint16_t)gains->phy_gain << 14) | + ((uint16_t)gains->phy_gain << 6); + phy_gain2 = phy_gain1; + } else { + phy_gain1 = 0x4040; + phy_gain2 = 0x4000; + } + PHY_FILT_SETBITS(mac, 0x4a0, 0xbfbf, phy_gain1); + PHY_FILT_SETBITS(mac, 0x4a1, 0xbfbf, phy_gain1); + PHY_FILT_SETBITS(mac, 0x4a2, 0xbfbf, phy_gain2); + } + bwi_mac_dummy_xmit(mac); +} + +void +bwi_phy_clear_state(struct bwi_phy *phy) +{ + phy->phy_flags &= ~BWI_CLEAR_PHY_FLAGS; +} --- /dev/null +++ sys/dev/bwi/if_bwivar.h @@ -0,0 +1,679 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/if_bwivar.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/if_bwivar.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _IF_BWIVAR_H +#define _IF_BWIVAR_H + +#define BWI_ALIGN 0x1000 +#define BWI_RING_ALIGN BWI_ALIGN +#define BWI_BUS_SPACE_MAXADDR 0x3fffffff + +#define BWI_TX_NRING 6 +#define BWI_TXRX_NRING 6 +#define BWI_TX_NDESC 128 +#define BWI_RX_NDESC 64 +#define BWI_TXSTATS_NDESC 64 +#define BWI_TX_NSPRDESC 2 +#define BWI_TX_DATA_RING 1 + +/* XXX Onoe/Sample/AMRR probably need different configuration */ +#define BWI_SHRETRY 7 +#define BWI_LGRETRY 4 +#define BWI_SHRETRY_FB 3 +#define BWI_LGRETRY_FB 2 + +#define BWI_NOISE_FLOOR -95 /* TODO: noise floor calc */ +#define BWI_FRAME_MIN_LEN(hdr) \ + ((hdr) + sizeof(struct ieee80211_frame_ack) + IEEE80211_CRC_LEN) + +#define CSR_READ_4(sc, reg) \ + bus_space_read_4((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg)) +#define CSR_READ_2(sc, reg) \ + bus_space_read_2((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg)) + +#define CSR_WRITE_4(sc, reg, val) \ + bus_space_write_4((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg), (val)) +#define CSR_WRITE_2(sc, reg, val) \ + bus_space_write_2((sc)->sc_mem_bt, (sc)->sc_mem_bh, (reg), (val)) + +#define CSR_SETBITS_4(sc, reg, bits) \ + CSR_WRITE_4((sc), (reg), CSR_READ_4((sc), (reg)) | (bits)) +#define CSR_SETBITS_2(sc, reg, bits) \ + CSR_WRITE_2((sc), (reg), CSR_READ_2((sc), (reg)) | (bits)) + +#define CSR_FILT_SETBITS_4(sc, reg, filt, bits) \ + CSR_WRITE_4((sc), (reg), (CSR_READ_4((sc), (reg)) & (filt)) | (bits)) +#define CSR_FILT_SETBITS_2(sc, reg, filt, bits) \ + CSR_WRITE_2((sc), (reg), (CSR_READ_2((sc), (reg)) & (filt)) | (bits)) + +#define CSR_CLRBITS_4(sc, reg, bits) \ + CSR_WRITE_4((sc), (reg), CSR_READ_4((sc), (reg)) & ~(bits)) +#define CSR_CLRBITS_2(sc, reg, bits) \ + CSR_WRITE_2((sc), (reg), CSR_READ_2((sc), (reg)) & ~(bits)) + +#define BWI_DEBUG +#ifdef BWI_DEBUG +#define DPRINTF(sc, fmt, ...) device_printf(sc->sc_dev, fmt, __VA_ARGS__) +#else +#define DPRINTF(sc, fmt, ...) ((void)0) +#endif + +struct bwi_desc32 { + /* Little endian */ + uint32_t ctrl; + uint32_t addr; /* BWI_DESC32_A_ */ +} __packed; + +#define BWI_DESC32_A_FUNC_TXRX 0x1 +#define BWI_DESC32_A_FUNC_MASK __BITS(31, 30) +#define BWI_DESC32_A_ADDR_MASK __BITS(29, 0) + +#define BWI_DESC32_C_BUFLEN_MASK __BITS(12, 0) +#define BWI_DESC32_C_ADDRHI_MASK __BITS(17, 16) +#define BWI_DESC32_C_EOR __BIT(28) +#define BWI_DESC32_C_INTR __BIT(29) +#define BWI_DESC32_C_FRAME_END __BIT(30) +#define BWI_DESC32_C_FRAME_START __BIT(31) + +struct bwi_desc64 { + /* Little endian */ + uint32_t ctrl0; + uint32_t ctrl1; + uint32_t addr_lo; + uint32_t addr_hi; +} __packed; + +struct bwi_rxbuf_hdr { + /* Little endian */ + uint16_t rxh_buflen; /* exclude bwi_rxbuf_hdr */ + uint8_t rxh_pad1[2]; + uint16_t rxh_flags1; /* BWI_RXH_F1_ */ + uint8_t rxh_rssi; + uint8_t rxh_sq; + uint16_t rxh_phyinfo; /* BWI_RXH_PHYINFO_ */ + uint16_t rxh_flags3; /* BWI_RXH_F3_ */ + uint16_t rxh_flags2; /* BWI_RXH_F2_ */ + uint16_t rxh_tsf; + uint8_t rxh_pad3[14]; /* Padded to 30bytes */ +} __packed; + +#define BWI_RXH_F1_BCM2053_RSSI __BIT(14) +#define BWI_RXH_F1_SHPREAMBLE __BIT(7) +#define BWI_RXH_F1_OFDM __BIT(0) + +#define BWI_RXH_F2_TYPE2FRAME __BIT(2) + +#define BWI_RXH_F3_BCM2050_RSSI __BIT(10) + +#define BWI_RXH_PHYINFO_LNAGAIN __BITS(15, 14) + +struct bwi_txbuf_hdr { + /* Little endian */ + uint32_t txh_mac_ctrl; /* BWI_TXH_MAC_C_ */ + uint8_t txh_fc[2]; + uint16_t txh_unknown1; + uint16_t txh_phy_ctrl; /* BWI_TXH_PHY_C_ */ + uint8_t txh_ivs[16]; + uint8_t txh_addr1[IEEE80211_ADDR_LEN]; + uint16_t txh_unknown2; + uint8_t txh_rts_fb_plcp[4]; + uint16_t txh_rts_fb_duration; + uint8_t txh_fb_plcp[4]; + uint16_t txh_fb_duration; + uint8_t txh_pad2[2]; + uint16_t txh_id; /* BWI_TXH_ID_ */ + uint16_t txh_unknown3; + uint8_t txh_rts_plcp[6]; + uint8_t txh_rts_fc[2]; + uint16_t txh_rts_duration; + uint8_t txh_rts_ra[IEEE80211_ADDR_LEN]; + uint8_t txh_rts_ta[IEEE80211_ADDR_LEN]; + uint8_t txh_pad3[2]; + uint8_t txh_plcp[6]; +} __packed; + +#define BWI_TXH_ID_RING_MASK __BITS(15, 13) +#define BWI_TXH_ID_IDX_MASK __BITS(12, 0) + +#define BWI_TXH_PHY_C_OFDM __BIT(0) +#define BWI_TXH_PHY_C_SHPREAMBLE __BIT(4) +#define BWI_TXH_PHY_C_ANTMODE_MASK __BITS(9, 8) + +#define BWI_TXH_MAC_C_ACK __BIT(0) +#define BWI_TXH_MAC_C_FIRST_FRAG __BIT(3) +#define BWI_TXH_MAC_C_HWSEQ __BIT(4) +#define BWI_TXH_MAC_C_FB_OFDM __BIT(8) + +struct bwi_txstats { + /* Little endian */ + uint8_t txs_pad1[4]; + uint16_t txs_id; + uint8_t txs_flags; /* BWI_TXS_F_ */ + uint8_t txs_txcnt; /* BWI_TXS_TXCNT_ */ + uint8_t txs_pad2[2]; + uint16_t txs_seq; + uint16_t txs_unknown; + uint8_t txs_pad3[2]; /* Padded to 16bytes */ +} __packed; + +#define BWI_TXS_TXCNT_DATA __BITS(7, 4) + +#define BWI_TXS_F_ACKED __BIT(0) +#define BWI_TXS_F_PENDING __BIT(5) + +struct bwi_ring_data { + uint32_t rdata_txrx_ctrl; + bus_dmamap_t rdata_dmap; + bus_addr_t rdata_paddr; + void *rdata_desc; +}; + +struct bwi_txbuf { + struct mbuf *tb_mbuf; + bus_dmamap_t tb_dmap; + + struct ieee80211_node *tb_ni; + int tb_rate_idx[2]; +}; + +struct bwi_txbuf_data { + struct bwi_txbuf tbd_buf[BWI_TX_NDESC]; + int tbd_used; + int tbd_idx; +}; + +struct bwi_rxbuf { + struct mbuf *rb_mbuf; + bus_addr_t rb_paddr; + bus_dmamap_t rb_dmap; +}; + +struct bwi_rxbuf_data { + struct bwi_rxbuf rbd_buf[BWI_RX_NDESC]; + bus_dmamap_t rbd_tmp_dmap; + int rbd_idx; +}; + +struct bwi_txstats_data { + bus_dma_tag_t stats_ring_dtag; + bus_dmamap_t stats_ring_dmap; + bus_addr_t stats_ring_paddr; + void *stats_ring; + + bus_dma_tag_t stats_dtag; + bus_dmamap_t stats_dmap; + bus_addr_t stats_paddr; + struct bwi_txstats *stats; + + uint32_t stats_ctrl_base; + int stats_idx; +}; + +struct bwi_fwhdr { + /* Big endian */ + uint8_t fw_type; /* BWI_FW_T_ */ + uint8_t fw_gen; /* BWI_FW_GEN */ + uint8_t fw_pad[2]; + uint32_t fw_size; +#define fw_iv_cnt fw_size +} __packed; + +#define BWI_FWHDR_SZ sizeof(struct bwi_fwhdr) + +#define BWI_FW_T_UCODE 'u' +#define BWI_FW_T_PCM 'p' +#define BWI_FW_T_IV 'i' + +#define BWI_FW_GEN_1 1 + +#define BWI_FW_VERSION3 3 +#define BWI_FW_VERSION4 4 +#define BWI_FW_VERSION3_REVMAX 0x128 + +#define BWI_FW_PATH "bwi_v%d_" +#define BWI_FW_UCODE_PATH BWI_FW_PATH "ucode%d" +#define BWI_FW_PCM_PATH BWI_FW_PATH "pcm%d" +#define BWI_FW_IV_PATH BWI_FW_PATH "b0g0initvals%d" +#define BWI_FW_IV_EXT_PATH BWI_FW_PATH "b0g0bsinitvals%d" + +struct bwi_fw_iv { + /* Big endian */ + uint16_t iv_ofs; + union { + uint32_t val32; + uint16_t val16; + } iv_val; +} __packed; + +#define BWI_FW_IV_OFS_MASK __BITS(14, 0) +#define BWI_FW_IV_IS_32BIT __BIT(15) + +struct bwi_led { + uint8_t l_flags; /* BWI_LED_F_ */ + uint8_t l_act; /* BWI_LED_ACT_ */ +}; + +#define BWI_LED_F_ACTLOW 0x1 + +enum bwi_clock_mode { + BWI_CLOCK_MODE_SLOW, + BWI_CLOCK_MODE_FAST, + BWI_CLOCK_MODE_DYN +}; + +struct bwi_regwin { + uint32_t rw_flags; /* BWI_REGWIN_F_ */ + uint16_t rw_type; /* BWI_REGWIN_T_ */ + uint8_t rw_id; + uint8_t rw_rev; +}; + +#define BWI_REGWIN_F_EXIST 0x1 + +#define BWI_CREATE_REGWIN(rw, id, type, rev) \ +do { \ + (rw)->rw_flags = BWI_REGWIN_F_EXIST; \ + (rw)->rw_type = (type); \ + (rw)->rw_id = (id); \ + (rw)->rw_rev = (rev); \ +} while (0) + +#define BWI_REGWIN_EXIST(rw) ((rw)->rw_flags & BWI_REGWIN_F_EXIST) +#define BWI_GPIO_REGWIN(sc) \ + (BWI_REGWIN_EXIST(&(sc)->sc_com_regwin) ? \ + &(sc)->sc_com_regwin : &(sc)->sc_bus_regwin) + +struct bwi_mac; + +struct bwi_phy { + enum ieee80211_phymode phy_mode; + int phy_rev; + int phy_version; + + uint32_t phy_flags; /* BWI_PHY_F_ */ + uint16_t phy_tbl_ctrl; + uint16_t phy_tbl_data_lo; + uint16_t phy_tbl_data_hi; + + void (*phy_init)(struct bwi_mac *); +}; + +#define BWI_PHY_F_CALIBRATED 0x1 +#define BWI_PHY_F_LINKED 0x2 +#define BWI_CLEAR_PHY_FLAGS (BWI_PHY_F_CALIBRATED) + +/* TX power control */ +struct bwi_tpctl { + uint16_t bbp_atten; /* BBP attenuation: 4bits */ + uint16_t rf_atten; /* RF attenuation */ + uint16_t tp_ctrl1; /* ??: 3bits */ + uint16_t tp_ctrl2; /* ??: 4bits */ +}; + +#define BWI_RF_ATTEN_FACTOR 4 +#define BWI_RF_ATTEN_MAX0 9 +#define BWI_RF_ATTEN_MAX1 31 +#define BWI_BBP_ATTEN_MAX 11 +#define BWI_TPCTL1_MAX 7 + +struct bwi_rf_lo { + int8_t ctrl_lo; + int8_t ctrl_hi; +}; + +struct bwi_rf { + uint16_t rf_type; /* BWI_RF_T_ */ + uint16_t rf_manu; + int rf_rev; + + uint32_t rf_flags; /* BWI_RF_F_ */ + +#define BWI_RFLO_MAX 56 + struct bwi_rf_lo rf_lo[BWI_RFLO_MAX]; + uint8_t rf_lo_used[8]; + +#define BWI_INVALID_NRSSI -1000 + int16_t rf_nrssi[2]; /* Narrow RSSI */ + int32_t rf_nrssi_slope; + +#define BWI_NRSSI_TBLSZ 64 + int8_t rf_nrssi_table[BWI_NRSSI_TBLSZ]; + + uint16_t rf_lo_gain; /* loopback gain */ + uint16_t rf_rx_gain; /* TRSW RX gain */ + + uint16_t rf_calib; /* RF calibration value */ + u_int rf_curchan; /* current channel */ + + uint16_t rf_ctrl_rd; + int rf_ctrl_adj; + void (*rf_off)(struct bwi_mac *); + void (*rf_on)(struct bwi_mac *); + + void (*rf_set_nrssi_thr)(struct bwi_mac *); + void (*rf_calc_nrssi_slope)(struct bwi_mac *); + int (*rf_calc_rssi) + (struct bwi_mac *, + const struct bwi_rxbuf_hdr *); + +#define BWI_TSSI_MAX 64 + int8_t rf_txpower_map0[BWI_TSSI_MAX]; + /* Indexed by TSSI */ + int rf_idle_tssi0; + + int8_t rf_txpower_map[BWI_TSSI_MAX]; + int rf_idle_tssi; + + int rf_base_tssi; + + int rf_txpower_max; /* dBm */ + + int rf_ant_mode; /* BWI_ANT_MODE_ */ +}; + +#define BWI_RF_F_INITED 0x1 +#define BWI_RF_F_ON 0x2 +#define BWI_RF_CLEAR_FLAGS (BWI_RF_F_INITED) + +#define BWI_ANT_MODE_0 0 +#define BWI_ANT_MODE_1 1 +#define BWI_ANT_MODE_UNKN 2 +#define BWI_ANT_MODE_AUTO 3 + +struct bwi_softc; +struct firmware; + +struct bwi_mac { + struct bwi_regwin mac_regwin; /* MUST be first field */ +#define mac_rw_flags mac_regwin.rw_flags +#define mac_type mac_regwin.rw_type +#define mac_id mac_regwin.rw_id +#define mac_rev mac_regwin.rw_rev + + struct bwi_softc *mac_sc; + + struct bwi_phy mac_phy; /* PHY I/F */ + struct bwi_rf mac_rf; /* RF I/F */ + + struct bwi_tpctl mac_tpctl; /* TX power control */ + uint32_t mac_flags; /* BWI_MAC_F_ */ + + const struct firmware *mac_ucode; + const struct firmware *mac_pcm; + const struct firmware *mac_iv; + const struct firmware *mac_iv_ext; +}; + +#define BWI_MAC_F_BSWAP 0x1 +#define BWI_MAC_F_TPCTL_INITED 0x2 +#define BWI_MAC_F_HAS_TXSTATS 0x4 +#define BWI_MAC_F_INITED 0x8 +#define BWI_MAC_F_ENABLED 0x10 +#define BWI_MAC_F_LOCKED 0x20 /* for debug */ +#define BWI_MAC_F_TPCTL_ERROR 0x40 + +#define BWI_CREATE_MAC(mac, sc, id, rev) \ +do { \ + BWI_CREATE_REGWIN(&(mac)->mac_regwin, \ + (id), \ + BWI_REGWIN_T_D11, \ + (rev)); \ + (mac)->mac_sc = (sc); \ +} while (0) + +#define BWI_MAC_MAX 2 +#define BWI_LED_MAX 4 + +enum bwi_bus_space { + BWI_BUS_SPACE_30BIT = 1, + BWI_BUS_SPACE_32BIT, + BWI_BUS_SPACE_64BIT +}; + +#define BWI_TX_RADIOTAP_PRESENT \ + ((1 << IEEE80211_RADIOTAP_FLAGS) | \ + (1 << IEEE80211_RADIOTAP_RATE) | \ + (1 << IEEE80211_RADIOTAP_CHANNEL)) + +struct bwi_tx_radiotap_hdr { + struct ieee80211_radiotap_header wt_ihdr; + uint8_t wt_flags; + uint8_t wt_rate; + uint16_t wt_chan_freq; + uint16_t wt_chan_flags; +}; + +#define BWI_RX_RADIOTAP_PRESENT \ + ((1 << IEEE80211_RADIOTAP_TSFT) | \ + (1 << IEEE80211_RADIOTAP_FLAGS) | \ + (1 << IEEE80211_RADIOTAP_RATE) | \ + (1 << IEEE80211_RADIOTAP_CHANNEL) | \ + (1 << IEEE80211_RADIOTAP_DBM_ANTSIGNAL) | \ + (1 << IEEE80211_RADIOTAP_DBM_ANTNOISE)) + +struct bwi_rx_radiotap_hdr { + struct ieee80211_radiotap_header wr_ihdr; + uint64_t wr_tsf; + uint8_t wr_flags; + uint8_t wr_rate; + uint16_t wr_chan_freq; + uint16_t wr_chan_flags; + int8_t wr_antsignal; + int8_t wr_antnoise; + /* TODO: sq */ +}; + +struct bwi_node { + struct ieee80211_node ni; /* must be the first */ + struct ieee80211_amrr_node amn; +}; + +struct bwi_softc { + struct ifnet *sc_ifp; + struct ieee80211com sc_ic; + struct ieee80211_amrr sc_amrr; + uint32_t sc_flags; /* BWI_F_ */ + device_t sc_dev; + struct mtx sc_mtx; + int sc_invalid; + + uint32_t sc_cap; /* BWI_CAP_ */ + uint16_t sc_bbp_id; /* BWI_BBPID_ */ + uint8_t sc_bbp_rev; + uint8_t sc_bbp_pkg; + + uint8_t sc_pci_revid; + uint16_t sc_pci_did; + uint16_t sc_pci_subvid; + uint16_t sc_pci_subdid; + + uint16_t sc_card_flags; /* BWI_CARD_F_ */ + uint16_t sc_pwron_delay; + int sc_locale; + + int sc_irq_rid; + struct resource *sc_irq_res; + void *sc_irq_handle; + + int sc_mem_rid; + struct resource *sc_mem_res; + bus_space_tag_t sc_mem_bt; + bus_space_handle_t sc_mem_bh; + + struct callout sc_calib_ch; + struct callout sc_amrr_ch; + + struct bwi_regwin *sc_cur_regwin; + struct bwi_regwin sc_com_regwin; + struct bwi_regwin sc_bus_regwin; + + int sc_nmac; + struct bwi_mac sc_mac[BWI_MAC_MAX]; + + struct bwi_led sc_leds[BWI_LED_MAX]; + + enum bwi_bus_space sc_bus_space; + bus_dma_tag_t sc_parent_dtag; + + bus_dma_tag_t sc_buf_dtag; + struct bwi_txbuf_data sc_tx_bdata[BWI_TX_NRING]; + struct bwi_rxbuf_data sc_rx_bdata; + + bus_dma_tag_t sc_txring_dtag; + struct bwi_ring_data sc_tx_rdata[BWI_TX_NRING]; + bus_dma_tag_t sc_rxring_dtag; + struct bwi_ring_data sc_rx_rdata; + + struct bwi_txstats_data *sc_txstats; + + int sc_tx_timer; + + struct bpf_if *sc_drvbpf; + struct bwi_tx_radiotap_hdr sc_tx_th; + int sc_tx_th_len; + struct bwi_rx_radiotap_hdr sc_rx_th; + int sc_rx_th_len; + + int (*sc_newstate) + (struct ieee80211com *, + enum ieee80211_state, int); + + int (*sc_init_tx_ring)(struct bwi_softc *, int); + void (*sc_free_tx_ring)(struct bwi_softc *, int); + + int (*sc_init_rx_ring)(struct bwi_softc *); + void (*sc_free_rx_ring)(struct bwi_softc *); + + int (*sc_init_txstats)(struct bwi_softc *); + void (*sc_free_txstats)(struct bwi_softc *); + + void (*sc_setup_rxdesc) + (struct bwi_softc *, int, bus_addr_t, int); + void (*sc_rxeof)(struct bwi_softc *); + + void (*sc_setup_txdesc) + (struct bwi_softc *, struct bwi_ring_data *, + int, bus_addr_t, int); + void (*sc_start_tx) + (struct bwi_softc *, uint32_t, int); + + void (*sc_txeof_status)(struct bwi_softc *); + + /* Sysctl variables */ + int sc_fw_version; /* BWI_FW_VERSION[34] */ + int sc_dwell_time; /* milliseconds */ +}; + +#define BWI_F_BUS_INITED 0x1 +#define BWI_F_PROMISC 0x2 + +#define BWI_LOCK_INIT(sc) \ + mtx_init(&(sc)->sc_mtx, device_get_nameunit((sc)->sc_dev), \ + MTX_NETWORK_LOCK, MTX_DEF | MTX_RECURSE); +#define BWI_LOCK_DESTROY(sc) mtx_destroy(&(sc)->sc_mtx) +#define BWI_LOCK(sc) mtx_lock(&sc->sc_mtx) +#define BWI_UNLOCK(sc) mtx_unlock(&sc->sc_mtx) +#define BWI_LOCK_ASSERT(sc) mtx_assert(&sc->sc_mtx, MA_OWNED) + +int bwi_attach(struct bwi_softc *); +int bwi_detach(struct bwi_softc *); +void bwi_suspend(struct bwi_softc *); +void bwi_resume(struct bwi_softc *); +int bwi_shutdown(struct bwi_softc *); +void bwi_intr(void *); + +int bwi_bus_init(struct bwi_softc *, struct bwi_mac *mac); + +uint16_t bwi_read_sprom(struct bwi_softc *, uint16_t); +int bwi_regwin_switch(struct bwi_softc *, struct bwi_regwin *, + struct bwi_regwin **); +int bwi_regwin_is_enabled(struct bwi_softc *, struct bwi_regwin *); +void bwi_regwin_enable(struct bwi_softc *, struct bwi_regwin *, + uint32_t); +void bwi_regwin_disable(struct bwi_softc *, struct bwi_regwin *, + uint32_t); +uint8_t bwi_rate2plcp(uint8_t); /* XXX belongs to 802.11 */ + +#define abs(a) __builtin_abs(a) + +enum ieee80211_modtype { + IEEE80211_MODTYPE_DS, + IEEE80211_MODTYPE_PBCC, + IEEE80211_MODTYPE_OFDM +}; +#define IEEE80211_MODTYPE_CCK IEEE80211_MODTYPE_DS + +/* + * Contention window (slots). + */ +#define IEEE80211_CW_MAX 1023 /* aCWmax */ +#define IEEE80211_CW_MIN_0 31 /* DS/CCK aCWmin, ERP aCWmin(0) */ +#define IEEE80211_CW_MIN_1 15 /* OFDM aCWmin, ERP aCWmin(1) */ + +/* + * SIFS (microseconds). + */ +#define IEEE80211_DUR_SIFS 10 /* DS/CCK/ERP SIFS */ +#define IEEE80211_DUR_OFDM_SIFS 16 /* OFDM SIFS */ + +/* + * Slot time (microseconds). + */ +#define IEEE80211_DUR_SLOT 20 /* DS/CCK slottime, ERP long slottime */ +#define IEEE80211_DUR_SHSLOT 9 /* ERP short slottime */ +#define IEEE80211_DUR_OFDM_SLOT 9 /* OFDM slottime */ + +/* + * DIFS (microseconds). + */ +#define IEEE80211_DUR_DIFS(sifs, slot) ((sifs) + 2 * (slot)) + +/* XXX does not belong here */ +struct ieee80211_ds_plcp_hdr { + uint8_t i_signal; + uint8_t i_service; + uint16_t i_length; + uint16_t i_crc; +} __packed; + +enum ieee80211_modtype ieee80211_rate2modtype(uint8_t rate); +uint8_t ieee80211_ack_rate(struct ieee80211_node *ni, uint8_t rate); +uint16_t ieee80211_txtime(struct ieee80211_node *ni, u_int len, + uint8_t rs_rate, uint32_t flags); +uint8_t ieee80211_plcp2rate(uint8_t, int); + +#endif /* !_IF_BWIVAR_H */ --- /dev/null +++ sys/dev/bwi/bwimac.c @@ -0,0 +1,1901 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwimac.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwimac.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include + +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" +#include "bwiphy.h" + +struct bwi_retry_lim { + uint16_t shretry; + uint16_t shretry_fb; + uint16_t lgretry; + uint16_t lgretry_fb; +}; + +static int bwi_mac_test(struct bwi_mac *); +static int bwi_mac_get_property(struct bwi_mac *); + +static void bwi_mac_set_retry_lim(struct bwi_mac *, + const struct bwi_retry_lim *); +static void bwi_mac_set_ackrates(struct bwi_mac *, + const struct ieee80211_rateset *); + +static int bwi_mac_gpio_init(struct bwi_mac *); +static int bwi_mac_gpio_fini(struct bwi_mac *); +static void bwi_mac_opmode_init(struct bwi_mac *); +static void bwi_mac_hostflags_init(struct bwi_mac *); +static void bwi_mac_bss_param_init(struct bwi_mac *); + +static int bwi_mac_fw_alloc(struct bwi_mac *); +static void bwi_mac_fw_free(struct bwi_mac *); +static int bwi_mac_fw_load(struct bwi_mac *); +static int bwi_mac_fw_init(struct bwi_mac *); +static int bwi_mac_fw_load_iv(struct bwi_mac *, const struct firmware *); + +static void bwi_mac_setup_tpctl(struct bwi_mac *); +static void bwi_mac_adjust_tpctl(struct bwi_mac *, int, int); + +static void bwi_mac_lock(struct bwi_mac *); +static void bwi_mac_unlock(struct bwi_mac *); + +static const uint8_t bwi_sup_macrev[] = { 2, 4, 5, 6, 7, 9, 10 }; + +void +bwi_tmplt_write_4(struct bwi_mac *mac, uint32_t ofs, uint32_t val) +{ + struct bwi_softc *sc = mac->mac_sc; + + if (mac->mac_flags & BWI_MAC_F_BSWAP) + val = bswap32(val); + + CSR_WRITE_4(sc, BWI_MAC_TMPLT_CTRL, ofs); + CSR_WRITE_4(sc, BWI_MAC_TMPLT_DATA, val); +} + +void +bwi_hostflags_write(struct bwi_mac *mac, uint64_t flags) +{ + uint64_t val; + + val = flags & 0xffff; + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_LO, val); + + val = (flags >> 16) & 0xffff; + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_MI, val); + + /* HI has unclear meaning, so leave it as it is */ +} + +uint64_t +bwi_hostflags_read(struct bwi_mac *mac) +{ + uint64_t flags, val; + + /* HI has unclear meaning, so don't touch it */ + flags = 0; + + val = MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_MI); + flags |= val << 16; + + val = MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_HFLAGS_LO); + flags |= val; + + return flags; +} + +uint16_t +bwi_memobj_read_2(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t data_reg; + int ofs; + + data_reg = BWI_MOBJ_DATA; + ofs = ofs0 / 4; + + if (ofs0 % 4 != 0) + data_reg = BWI_MOBJ_DATA_UNALIGN; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + return CSR_READ_2(sc, data_reg); +} + +uint32_t +bwi_memobj_read_4(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0) +{ + struct bwi_softc *sc = mac->mac_sc; + int ofs; + + ofs = ofs0 / 4; + if (ofs0 % 4 != 0) { + uint32_t ret; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + ret = CSR_READ_2(sc, BWI_MOBJ_DATA_UNALIGN); + ret <<= 16; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(obj_id, ofs + 1)); + ret |= CSR_READ_2(sc, BWI_MOBJ_DATA); + + return ret; + } else { + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + return CSR_READ_4(sc, BWI_MOBJ_DATA); + } +} + +void +bwi_memobj_write_2(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0, + uint16_t v) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t data_reg; + int ofs; + + data_reg = BWI_MOBJ_DATA; + ofs = ofs0 / 4; + + if (ofs0 % 4 != 0) + data_reg = BWI_MOBJ_DATA_UNALIGN; + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + CSR_WRITE_2(sc, data_reg, v); +} + +void +bwi_memobj_write_4(struct bwi_mac *mac, uint16_t obj_id, uint16_t ofs0, + uint32_t v) +{ + struct bwi_softc *sc = mac->mac_sc; + int ofs; + + ofs = ofs0 / 4; + if (ofs0 % 4 != 0) { + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + CSR_WRITE_2(sc, BWI_MOBJ_DATA_UNALIGN, v >> 16); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(obj_id, ofs + 1)); + CSR_WRITE_2(sc, BWI_MOBJ_DATA, v & 0xffff); + } else { + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, BWI_MOBJ_CTRL_VAL(obj_id, ofs)); + CSR_WRITE_4(sc, BWI_MOBJ_DATA, v); + } +} + +int +bwi_mac_lateattach(struct bwi_mac *mac) +{ + int error; + + if (mac->mac_rev >= 5) + CSR_READ_4(mac->mac_sc, BWI_STATE_HI); /* dummy read */ + + bwi_mac_reset(mac, 1); + + error = bwi_phy_attach(mac); + if (error) + return error; + + error = bwi_rf_attach(mac); + if (error) + return error; + + /* Link 11B/G PHY, unlink 11A PHY */ + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11A) + bwi_mac_reset(mac, 0); + else + bwi_mac_reset(mac, 1); + + error = bwi_mac_test(mac); + if (error) + return error; + + error = bwi_mac_get_property(mac); + if (error) + return error; + + error = bwi_rf_map_txpower(mac); + if (error) + return error; + + bwi_rf_off(mac); + CSR_WRITE_2(mac->mac_sc, BWI_BBP_ATTEN, BWI_BBP_ATTEN_MAGIC); + bwi_regwin_disable(mac->mac_sc, &mac->mac_regwin, 0); + + return 0; +} + +int +bwi_mac_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + int error, i; + + /* Clear MAC/PHY/RF states */ + bwi_mac_setup_tpctl(mac); + bwi_rf_clear_state(&mac->mac_rf); + bwi_phy_clear_state(&mac->mac_phy); + + /* Enable MAC and linked it to PHY */ + if (!bwi_regwin_is_enabled(sc, &mac->mac_regwin)) + bwi_mac_reset(mac, 1); + + /* Initialize backplane */ + error = bwi_bus_init(sc, mac); + if (error) + return error; + + /* XXX work around for hardware bugs? */ + if (sc->sc_bus_regwin.rw_rev <= 5 && + sc->sc_bus_regwin.rw_type != BWI_REGWIN_T_PCIE) { + CSR_SETBITS_4(sc, BWI_CONF_LO, + __SHIFTIN(BWI_CONF_LO_SERVTO, BWI_CONF_LO_SERVTO_MASK) | + __SHIFTIN(BWI_CONF_LO_REQTO, BWI_CONF_LO_REQTO_MASK)); + } + + /* Calibrate PHY */ + error = bwi_phy_calibrate(mac); + if (error) { + device_printf(sc->sc_dev, "PHY calibrate failed\n"); + return error; + } + + /* Prepare to initialize firmware */ + CSR_WRITE_4(sc, BWI_MAC_STATUS, + BWI_MAC_STATUS_UCODE_JUMP0 | + BWI_MAC_STATUS_IHREN); + + /* + * Load and initialize firmwares + */ + error = bwi_mac_fw_alloc(mac); + if (error) + return error; + + error = bwi_mac_fw_load(mac); + if (error) + return error; + + error = bwi_mac_gpio_init(mac); + if (error) + return error; + + error = bwi_mac_fw_init(mac); + if (error) + return error; + + /* + * Turn on RF + */ + bwi_rf_on(mac); + + /* TODO: LED, hardware rf enabled is only related to LED setting */ + + /* + * Initialize PHY + */ + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0); + bwi_phy_init(mac); + + /* TODO: interference mitigation */ + + /* + * Setup antenna mode + */ + bwi_rf_set_ant_mode(mac, mac->mac_rf.rf_ant_mode); + + /* + * Initialize operation mode (RX configuration) + */ + bwi_mac_opmode_init(mac); + + /* XXX what's these */ + if (mac->mac_rev < 3) { + CSR_WRITE_2(sc, 0x60e, 0); + CSR_WRITE_2(sc, 0x610, 0x8000); + CSR_WRITE_2(sc, 0x604, 0); + CSR_WRITE_2(sc, 0x606, 0x200); + } else { + CSR_WRITE_4(sc, 0x188, 0x80000000); + CSR_WRITE_4(sc, 0x18c, 0x2000000); + } + + /* + * Initialize TX/RX interrupts' mask + */ + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, BWI_INTR_TIMER1); + for (i = 0; i < BWI_TXRX_NRING; ++i) { + uint32_t intrs; + + if (BWI_TXRX_IS_RX(i)) + intrs = BWI_TXRX_RX_INTRS; + else + intrs = BWI_TXRX_TX_INTRS; + CSR_WRITE_4(sc, BWI_TXRX_INTR_MASK(i), intrs); + } + + /* XXX what's this */ + CSR_SETBITS_4(sc, BWI_STATE_LO, 0x100000); + + /* Setup MAC power up delay */ + CSR_WRITE_2(sc, BWI_MAC_POWERUP_DELAY, sc->sc_pwron_delay); + + /* Set MAC regwin revision */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_MACREV, mac->mac_rev); + + /* + * Initialize host flags + */ + bwi_mac_hostflags_init(mac); + + /* + * Initialize BSS parameters + */ + bwi_mac_bss_param_init(mac); + + /* + * Initialize TX rings + */ + for (i = 0; i < BWI_TX_NRING; ++i) { + error = sc->sc_init_tx_ring(sc, i); + if (error) { + device_printf(sc->sc_dev, + "can't initialize %dth TX ring\n", i); + return error; + } + } + + /* + * Initialize RX ring + */ + error = sc->sc_init_rx_ring(sc); + if (error) { + device_printf(sc->sc_dev, "can't initialize RX ring\n"); + return error; + } + + /* + * Initialize TX stats if the current MAC uses that + */ + if (mac->mac_flags & BWI_MAC_F_HAS_TXSTATS) { + error = sc->sc_init_txstats(sc); + if (error) { + device_printf(sc->sc_dev, + "can't initialize TX stats ring\n"); + return error; + } + } + + /* XXX what's these */ + CSR_WRITE_2(sc, 0x612, 0x50); /* Force Pre-TBTT to 80? */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, 0x416, 0x50); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, 0x414, 0x1f4); + + mac->mac_flags |= BWI_MAC_F_INITED; + return 0; +} + +void +bwi_mac_reset(struct bwi_mac *mac, int link_phy) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t flags, state_lo, status; + + flags = BWI_STATE_LO_FLAG_PHYRST | BWI_STATE_LO_FLAG_PHYCLKEN; + if (link_phy) + flags |= BWI_STATE_LO_FLAG_PHYLNK; + bwi_regwin_enable(sc, &mac->mac_regwin, flags); + DELAY(2000); + + state_lo = CSR_READ_4(sc, BWI_STATE_LO); + state_lo |= BWI_STATE_LO_GATED_CLOCK; + state_lo &= ~__SHIFTIN(BWI_STATE_LO_FLAG_PHYRST, + BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1000); + + state_lo &= ~BWI_STATE_LO_GATED_CLOCK; + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1000); + + CSR_WRITE_2(sc, BWI_BBP_ATTEN, 0); + + status = CSR_READ_4(sc, BWI_MAC_STATUS); + status |= BWI_MAC_STATUS_IHREN; + if (link_phy) + status |= BWI_MAC_STATUS_PHYLNK; + else + status &= ~BWI_MAC_STATUS_PHYLNK; + CSR_WRITE_4(sc, BWI_MAC_STATUS, status); + + if (link_phy) { + DPRINTF(sc, "%s\n", "PHY is linked"); + mac->mac_phy.phy_flags |= BWI_PHY_F_LINKED; + } else { + DPRINTF(sc, "%s\n", "PHY is unlinked"); + mac->mac_phy.phy_flags &= ~BWI_PHY_F_LINKED; + } +} + +void +bwi_mac_set_tpctl_11bg(struct bwi_mac *mac, const struct bwi_tpctl *new_tpctl) +{ + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_tpctl *tpctl = &mac->mac_tpctl; + + if (new_tpctl != NULL) { + KASSERT(new_tpctl->bbp_atten <= BWI_BBP_ATTEN_MAX, + ("bbp_atten %d", new_tpctl->bbp_atten)); + KASSERT(new_tpctl->rf_atten <= + (rf->rf_rev < 6 ? BWI_RF_ATTEN_MAX0 + : BWI_RF_ATTEN_MAX1), + ("rf_atten %d", new_tpctl->rf_atten)); + KASSERT(new_tpctl->tp_ctrl1 <= BWI_TPCTL1_MAX, + ("tp_ctrl1 %d", new_tpctl->tp_ctrl1)); + + tpctl->bbp_atten = new_tpctl->bbp_atten; + tpctl->rf_atten = new_tpctl->rf_atten; + tpctl->tp_ctrl1 = new_tpctl->tp_ctrl1; + } + + /* Set BBP attenuation */ + bwi_phy_set_bbp_atten(mac, tpctl->bbp_atten); + + /* Set RF attenuation */ + RF_WRITE(mac, BWI_RFR_ATTEN, tpctl->rf_atten); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_RF_ATTEN, + tpctl->rf_atten); + + /* Set TX power */ + if (rf->rf_type == BWI_RF_T_BCM2050) { + RF_FILT_SETBITS(mac, BWI_RFR_TXPWR, ~BWI_RFR_TXPWR1_MASK, + __SHIFTIN(tpctl->tp_ctrl1, BWI_RFR_TXPWR1_MASK)); + } + + /* Adjust RF Local Oscillator */ + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11G) + bwi_rf_lo_adjust(mac, tpctl); +} + +static int +bwi_mac_test(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t orig_val, val; + +#define TEST_VAL1 0xaa5555aa +#define TEST_VAL2 0x55aaaa55 + + /* Save it for later restoring */ + orig_val = MOBJ_READ_4(mac, BWI_COMM_MOBJ, 0); + + /* Test 1 */ + MOBJ_WRITE_4(mac, BWI_COMM_MOBJ, 0, TEST_VAL1); + val = MOBJ_READ_4(mac, BWI_COMM_MOBJ, 0); + if (val != TEST_VAL1) { + device_printf(sc->sc_dev, "TEST1 failed\n"); + return ENXIO; + } + + /* Test 2 */ + MOBJ_WRITE_4(mac, BWI_COMM_MOBJ, 0, TEST_VAL2); + val = MOBJ_READ_4(mac, BWI_COMM_MOBJ, 0); + if (val != TEST_VAL2) { + device_printf(sc->sc_dev, "TEST2 failed\n"); + return ENXIO; + } + + /* Restore to the original value */ + MOBJ_WRITE_4(mac, BWI_COMM_MOBJ, 0, orig_val); + + val = CSR_READ_4(sc, BWI_MAC_STATUS); + if ((val & ~BWI_MAC_STATUS_PHYLNK) != BWI_MAC_STATUS_IHREN) { + device_printf(sc->sc_dev, "%s failed, MAC status 0x%08x\n", + __func__, val); + return ENXIO; + } + + val = CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + if (val != 0) { + device_printf(sc->sc_dev, "%s failed, intr status %08x\n", + __func__, val); + return ENXIO; + } + +#undef TEST_VAL2 +#undef TEST_VAL1 + + return 0; +} + +static void +bwi_mac_setup_tpctl(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_tpctl *tpctl = &mac->mac_tpctl; + + /* Calc BBP attenuation */ + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev < 6) + tpctl->bbp_atten = 0; + else + tpctl->bbp_atten = 2; + + /* Calc TX power CTRL1?? */ + tpctl->tp_ctrl1 = 0; + if (rf->rf_type == BWI_RF_T_BCM2050) { + if (rf->rf_rev == 1) + tpctl->tp_ctrl1 = 3; + else if (rf->rf_rev < 6) + tpctl->tp_ctrl1 = 2; + else if (rf->rf_rev == 8) + tpctl->tp_ctrl1 = 1; + } + + /* Empty TX power CTRL2?? */ + tpctl->tp_ctrl2 = 0xffff; + + /* + * Calc RF attenuation + */ + if (phy->phy_mode == IEEE80211_MODE_11A) { + tpctl->rf_atten = 0x60; + goto back; + } + + if (BWI_IS_BRCM_BCM4309G(sc) && sc->sc_pci_revid < 0x51) { + tpctl->rf_atten = sc->sc_pci_revid < 0x43 ? 2 : 3; + goto back; + } + + tpctl->rf_atten = 5; + + if (rf->rf_type != BWI_RF_T_BCM2050) { + if (rf->rf_type == BWI_RF_T_BCM2053 && rf->rf_rev == 1) + tpctl->rf_atten = 6; + goto back; + } + + /* + * NB: If we reaches here and the card is BRCM_BCM4309G, + * then the card's PCI revision must >= 0x51 + */ + + /* BCM2050 RF */ + switch (rf->rf_rev) { + case 1: + if (phy->phy_mode == IEEE80211_MODE_11G) { + if (BWI_IS_BRCM_BCM4309G(sc) || BWI_IS_BRCM_BU4306(sc)) + tpctl->rf_atten = 3; + else + tpctl->rf_atten = 1; + } else { + if (BWI_IS_BRCM_BCM4309G(sc)) + tpctl->rf_atten = 7; + else + tpctl->rf_atten = 6; + } + break; + case 2: + if (phy->phy_mode == IEEE80211_MODE_11G) { + /* + * NOTE: Order of following conditions is critical + */ + if (BWI_IS_BRCM_BCM4309G(sc)) + tpctl->rf_atten = 3; + else if (BWI_IS_BRCM_BU4306(sc)) + tpctl->rf_atten = 5; + else if (sc->sc_bbp_id == BWI_BBPID_BCM4320) + tpctl->rf_atten = 4; + else + tpctl->rf_atten = 3; + } else { + tpctl->rf_atten = 6; + } + break; + case 4: + case 5: + tpctl->rf_atten = 1; + break; + case 8: + tpctl->rf_atten = 0x1a; + break; + } +back: + DPRINTF(sc, "bbp atten: %u, rf atten: %u, ctrl1: %u, ctrl2: %u\n", + tpctl->bbp_atten, tpctl->rf_atten, + tpctl->tp_ctrl1, tpctl->tp_ctrl2); +} + +void +bwi_mac_dummy_xmit(struct bwi_mac *mac) +{ +#define PACKET_LEN 5 + static const uint32_t packet_11a[PACKET_LEN] = + { 0x000201cc, 0x00d40000, 0x00000000, 0x01000000, 0x00000000 }; + static const uint32_t packet_11bg[PACKET_LEN] = + { 0x000b846e, 0x00d40000, 0x00000000, 0x01000000, 0x00000000 }; + + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + const uint32_t *packet; + uint16_t val_50c; + int wait_max, i; + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11A) { + wait_max = 30; + packet = packet_11a; + val_50c = 1; + } else { + wait_max = 250; + packet = packet_11bg; + val_50c = 0; + } + + for (i = 0; i < PACKET_LEN; ++i) + TMPLT_WRITE_4(mac, i * 4, packet[i]); + + CSR_READ_4(sc, BWI_MAC_STATUS); /* dummy read */ + + CSR_WRITE_2(sc, 0x568, 0); + CSR_WRITE_2(sc, 0x7c0, 0); + CSR_WRITE_2(sc, 0x50c, val_50c); + CSR_WRITE_2(sc, 0x508, 0); + CSR_WRITE_2(sc, 0x50a, 0); + CSR_WRITE_2(sc, 0x54c, 0); + CSR_WRITE_2(sc, 0x56a, 0x14); + CSR_WRITE_2(sc, 0x568, 0x826); + CSR_WRITE_2(sc, 0x500, 0); + CSR_WRITE_2(sc, 0x502, 0x30); + + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev <= 5) + RF_WRITE(mac, 0x51, 0x17); + + for (i = 0; i < wait_max; ++i) { + if (CSR_READ_2(sc, 0x50e) & 0x80) + break; + DELAY(10); + } + for (i = 0; i < 10; ++i) { + if (CSR_READ_2(sc, 0x50e) & 0x400) + break; + DELAY(10); + } + for (i = 0; i < 10; ++i) { + if ((CSR_READ_2(sc, 0x690) & 0x100) == 0) + break; + DELAY(10); + } + + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev <= 5) + RF_WRITE(mac, 0x51, 0x37); +#undef PACKET_LEN +} + +void +bwi_mac_init_tpctl_11bg(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_tpctl tpctl_orig; + int restore_tpctl = 0; + + KASSERT(phy->phy_mode != IEEE80211_MODE_11A, + ("phy_mode %d", phy->phy_mode)); + + if (BWI_IS_BRCM_BU4306(sc)) + return; + + PHY_WRITE(mac, 0x28, 0x8018); + CSR_CLRBITS_2(sc, BWI_BBP_ATTEN, 0x20); + + if (phy->phy_mode == IEEE80211_MODE_11G) { + if ((phy->phy_flags & BWI_PHY_F_LINKED) == 0) + return; + PHY_WRITE(mac, 0x47a, 0xc111); + } + if (mac->mac_flags & BWI_MAC_F_TPCTL_INITED) + return; + + if (phy->phy_mode == IEEE80211_MODE_11B && phy->phy_rev >= 2 && + rf->rf_type == BWI_RF_T_BCM2050) { + RF_SETBITS(mac, 0x76, 0x84); + } else { + struct bwi_tpctl tpctl; + + /* Backup original TX power control variables */ + bcopy(&mac->mac_tpctl, &tpctl_orig, sizeof(tpctl_orig)); + restore_tpctl = 1; + + bcopy(&mac->mac_tpctl, &tpctl, sizeof(tpctl)); + tpctl.bbp_atten = 11; + tpctl.tp_ctrl1 = 0; +#ifdef notyet + if (rf->rf_rev >= 6 && rf->rf_rev <= 8) + tpctl.rf_atten = 31; + else +#endif + tpctl.rf_atten = 9; + + bwi_mac_set_tpctl_11bg(mac, &tpctl); + } + + bwi_mac_dummy_xmit(mac); + + mac->mac_flags |= BWI_MAC_F_TPCTL_INITED; + rf->rf_base_tssi = PHY_READ(mac, 0x29); + DPRINTF(sc, "base tssi %d\n", rf->rf_base_tssi); + + if (abs(rf->rf_base_tssi - rf->rf_idle_tssi) >= 20) { + device_printf(sc->sc_dev, "base tssi measure failed\n"); + mac->mac_flags |= BWI_MAC_F_TPCTL_ERROR; + } + + if (restore_tpctl) + bwi_mac_set_tpctl_11bg(mac, &tpctl_orig); + else + RF_CLRBITS(mac, 0x76, 0x84); + + bwi_rf_clear_tssi(mac); +} + +void +bwi_mac_detach(struct bwi_mac *mac) +{ + bwi_mac_fw_free(mac); +} + +static __inline int +bwi_fwimage_is_valid(struct bwi_softc *sc, const struct firmware *fw, + uint8_t fw_type) +{ + const struct bwi_fwhdr *hdr; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + + if (fw->datasize < sizeof(*hdr)) { + if_printf(ifp, "invalid firmware (%s): invalid size %zu\n", + fw->name, fw->datasize); + return 0; + } + + hdr = (const struct bwi_fwhdr *)fw->data; + + if (fw_type != BWI_FW_T_IV) { + /* + * Don't verify IV's size, it has different meaning + */ + if (be32toh(hdr->fw_size) != fw->datasize - sizeof(*hdr)) { + if_printf(ifp, "invalid firmware (%s): size mismatch, " + "fw %u, real %zu\n", fw->name, + be32toh(hdr->fw_size), + fw->datasize - sizeof(*hdr)); + return 0; + } + } + + if (hdr->fw_type != fw_type) { + if_printf(ifp, "invalid firmware (%s): type mismatch, " + "fw \'%c\', target \'%c\'\n", fw->name, + hdr->fw_type, fw_type); + return 0; + } + + if (hdr->fw_gen != BWI_FW_GEN_1) { + if_printf(ifp, "invalid firmware (%s): wrong generation, " + "fw %d, target %d\n", fw->name, + hdr->fw_gen, BWI_FW_GEN_1); + return 0; + } + return 1; +} + +/* + * XXX Error cleanup + */ +static int +bwi_mac_fw_alloc(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + char fwname[64]; + int idx; + + if (mac->mac_ucode == NULL) { + snprintf(fwname, sizeof(fwname), BWI_FW_UCODE_PATH, + sc->sc_fw_version, + mac->mac_rev >= 5 ? 5 : mac->mac_rev); + + mac->mac_ucode = firmware_get(fwname); + if (mac->mac_ucode == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + + if (!bwi_fwimage_is_valid(sc, mac->mac_ucode, BWI_FW_T_UCODE)) + return EINVAL; + } + + if (mac->mac_pcm == NULL) { + snprintf(fwname, sizeof(fwname), BWI_FW_PCM_PATH, + sc->sc_fw_version, + mac->mac_rev < 5 ? 4 : 5); + + mac->mac_pcm = firmware_get(fwname); + if (mac->mac_pcm == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + + if (!bwi_fwimage_is_valid(sc, mac->mac_pcm, BWI_FW_T_PCM)) + return EINVAL; + } + + if (mac->mac_iv == NULL) { + /* TODO: 11A */ + if (mac->mac_rev == 2 || mac->mac_rev == 4) { + idx = 2; + } else if (mac->mac_rev >= 5 && mac->mac_rev <= 10) { + idx = 5; + } else { + if_printf(ifp, "no suitible IV for MAC rev %d\n", + mac->mac_rev); + return ENODEV; + } + + snprintf(fwname, sizeof(fwname), BWI_FW_IV_PATH, + sc->sc_fw_version, idx); + + mac->mac_iv = firmware_get(fwname); + if (mac->mac_iv == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + if (!bwi_fwimage_is_valid(sc, mac->mac_iv, BWI_FW_T_IV)) + return EINVAL; + } + + if (mac->mac_iv_ext == NULL) { + /* TODO: 11A */ + if (mac->mac_rev == 2 || mac->mac_rev == 4 || + mac->mac_rev >= 11) { + /* No extended IV */ + goto back; + } else if (mac->mac_rev >= 5 && mac->mac_rev <= 10) { + idx = 5; + } else { + if_printf(ifp, "no suitible ExtIV for MAC rev %d\n", + mac->mac_rev); + return ENODEV; + } + + snprintf(fwname, sizeof(fwname), BWI_FW_IV_EXT_PATH, + sc->sc_fw_version, idx); + + mac->mac_iv_ext = firmware_get(fwname); + if (mac->mac_iv_ext == NULL) { + if_printf(ifp, "request firmware %s failed\n", fwname); + return ENOMEM; + } + if (!bwi_fwimage_is_valid(sc, mac->mac_iv_ext, BWI_FW_T_IV)) + return EINVAL; + } +back: + return 0; +} + +static void +bwi_mac_fw_free(struct bwi_mac *mac) +{ + if (mac->mac_ucode != NULL) { + firmware_put(mac->mac_ucode, FIRMWARE_UNLOAD); + mac->mac_ucode = NULL; + } + + if (mac->mac_pcm != NULL) { + firmware_put(mac->mac_pcm, FIRMWARE_UNLOAD); + mac->mac_pcm = NULL; + } + + if (mac->mac_iv != NULL) { + firmware_put(mac->mac_iv, FIRMWARE_UNLOAD); + mac->mac_iv = NULL; + } + + if (mac->mac_iv_ext != NULL) { + firmware_put(mac->mac_iv_ext, FIRMWARE_UNLOAD); + mac->mac_iv_ext = NULL; + } +} + +static int +bwi_mac_fw_load(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + const uint32_t *fw; + uint16_t fw_rev; + int fw_len, i; + + /* + * Load ucode image + */ + fw = (const uint32_t *) + ((const uint8_t *)mac->mac_ucode->data + BWI_FWHDR_SZ); + fw_len = (mac->mac_ucode->datasize - BWI_FWHDR_SZ) / sizeof(uint32_t); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL( + BWI_FW_UCODE_MOBJ | BWI_WR_MOBJ_AUTOINC, 0)); + for (i = 0; i < fw_len; ++i) { + CSR_WRITE_4(sc, BWI_MOBJ_DATA, be32toh(fw[i])); + DELAY(10); + } + + /* + * Load PCM image + */ + fw = (const uint32_t *) + ((const uint8_t *)mac->mac_pcm->data + BWI_FWHDR_SZ); + fw_len = (mac->mac_pcm->datasize - BWI_FWHDR_SZ) / sizeof(uint32_t); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(BWI_FW_PCM_MOBJ, 0x01ea)); + CSR_WRITE_4(sc, BWI_MOBJ_DATA, 0x4000); + + CSR_WRITE_4(sc, BWI_MOBJ_CTRL, + BWI_MOBJ_CTRL_VAL(BWI_FW_PCM_MOBJ, 0x01eb)); + for (i = 0; i < fw_len; ++i) { + CSR_WRITE_4(sc, BWI_MOBJ_DATA, be32toh(fw[i])); + DELAY(10); + } + + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, BWI_ALL_INTRS); + CSR_WRITE_4(sc, BWI_MAC_STATUS, + BWI_MAC_STATUS_UCODE_START | + BWI_MAC_STATUS_IHREN | + BWI_MAC_STATUS_INFRA); + +#define NRETRY 200 + + for (i = 0; i < NRETRY; ++i) { + uint32_t intr_status; + + intr_status = CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + if (intr_status == BWI_INTR_READY) + break; + DELAY(10); + } + if (i == NRETRY) { + if_printf(ifp, "firmware (ucode&pcm) loading timed out\n"); + return ETIMEDOUT; + } + +#undef NRETRY + + CSR_READ_4(sc, BWI_MAC_INTR_STATUS); /* dummy read */ + + fw_rev = MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_FWREV); + if (fw_rev > BWI_FW_VERSION3_REVMAX) { + if_printf(ifp, "firmware version 4 is not supported yet\n"); + return ENODEV; + } + + if_printf(ifp, "firmware rev 0x%04x, patch level 0x%04x\n", fw_rev, + MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_FWPATCHLV)); + return 0; +} + +static int +bwi_mac_gpio_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_regwin *old, *gpio_rw; + uint32_t filt, bits; + int error; + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_GPOSEL_MASK); + /* TODO:LED */ + + CSR_SETBITS_2(sc, BWI_MAC_GPIO_MASK, 0xf); + + filt = 0x1f; + bits = 0xf; + if (sc->sc_bbp_id == BWI_BBPID_BCM4301) { + filt |= 0x60; + bits |= 0x60; + } + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) { + CSR_SETBITS_2(sc, BWI_MAC_GPIO_MASK, 0x200); + filt |= 0x200; + bits |= 0x200; + } + + gpio_rw = BWI_GPIO_REGWIN(sc); + error = bwi_regwin_switch(sc, gpio_rw, &old); + if (error) + return error; + + CSR_FILT_SETBITS_4(sc, BWI_GPIO_CTRL, filt, bits); + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_mac_gpio_fini(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_regwin *old, *gpio_rw; + int error; + + gpio_rw = BWI_GPIO_REGWIN(sc); + error = bwi_regwin_switch(sc, gpio_rw, &old); + if (error) + return error; + + CSR_WRITE_4(sc, BWI_GPIO_CTRL, 0); + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_mac_fw_load_iv(struct bwi_mac *mac, const struct firmware *fw) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + const struct bwi_fwhdr *hdr; + const struct bwi_fw_iv *iv; + int n, i, iv_img_size; + + /* Get the number of IVs in the IV image */ + hdr = (const struct bwi_fwhdr *)fw->data; + n = be32toh(hdr->fw_iv_cnt); + DPRINTF(sc, "IV count %d\n", n); + + /* Calculate the IV image size, for later sanity check */ + iv_img_size = fw->datasize - sizeof(*hdr); + + /* Locate the first IV */ + iv = (const struct bwi_fw_iv *) + ((const uint8_t *)fw->data + sizeof(*hdr)); + + for (i = 0; i < n; ++i) { + uint16_t iv_ofs, ofs; + int sz = 0; + + if (iv_img_size < sizeof(iv->iv_ofs)) { + if_printf(ifp, "invalid IV image, ofs\n"); + return EINVAL; + } + iv_img_size -= sizeof(iv->iv_ofs); + sz += sizeof(iv->iv_ofs); + + iv_ofs = be16toh(iv->iv_ofs); + + ofs = __SHIFTOUT(iv_ofs, BWI_FW_IV_OFS_MASK); + if (ofs >= 0x1000) { + if_printf(ifp, "invalid ofs (0x%04x) " + "for %dth iv\n", ofs, i); + return EINVAL; + } + + if (iv_ofs & BWI_FW_IV_IS_32BIT) { + uint32_t val32; + + if (iv_img_size < sizeof(iv->iv_val.val32)) { + if_printf(ifp, "invalid IV image, val32\n"); + return EINVAL; + } + iv_img_size -= sizeof(iv->iv_val.val32); + sz += sizeof(iv->iv_val.val32); + + val32 = be32toh(iv->iv_val.val32); + CSR_WRITE_4(sc, ofs, val32); + } else { + uint16_t val16; + + if (iv_img_size < sizeof(iv->iv_val.val16)) { + if_printf(ifp, "invalid IV image, val16\n"); + return EINVAL; + } + iv_img_size -= sizeof(iv->iv_val.val16); + sz += sizeof(iv->iv_val.val16); + + val16 = be16toh(iv->iv_val.val16); + CSR_WRITE_2(sc, ofs, val16); + } + + iv = (const struct bwi_fw_iv *)((const uint8_t *)iv + sz); + } + + if (iv_img_size != 0) { + if_printf(ifp, "invalid IV image, size left %d\n", iv_img_size); + return EINVAL; + } + return 0; +} + +static int +bwi_mac_fw_init(struct bwi_mac *mac) +{ + struct ifnet *ifp = mac->mac_sc->sc_ic.ic_ifp; + int error; + + error = bwi_mac_fw_load_iv(mac, mac->mac_iv); + if (error) { + if_printf(ifp, "load IV failed\n"); + return error; + } + + if (mac->mac_iv_ext != NULL) { + error = bwi_mac_fw_load_iv(mac, mac->mac_iv_ext); + if (error) + if_printf(ifp, "load ExtIV failed\n"); + } + return error; +} + +static void +bwi_mac_opmode_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ieee80211com *ic = &sc->sc_ic; + uint32_t mac_status; + uint16_t pre_tbtt; + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_INFRA); + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_INFRA); + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_PASS_BCN); + + /* Set probe resp timeout to infinite */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_PROBE_RESP_TO, 0); + + /* + * TODO: factor out following part + */ + + mac_status = CSR_READ_4(sc, BWI_MAC_STATUS); + mac_status &= ~(BWI_MAC_STATUS_OPMODE_HOSTAP | + BWI_MAC_STATUS_PASS_CTL | + BWI_MAC_STATUS_PASS_BADPLCP | + BWI_MAC_STATUS_PASS_BADFCS | + BWI_MAC_STATUS_PROMISC); + mac_status |= BWI_MAC_STATUS_INFRA; + + /* Always turn on PROMISC on old hardware */ + if (mac->mac_rev < 5) + mac_status |= BWI_MAC_STATUS_PROMISC; + + switch (ic->ic_opmode) { + case IEEE80211_M_IBSS: + mac_status &= ~BWI_MAC_STATUS_INFRA; + break; + case IEEE80211_M_HOSTAP: + mac_status |= BWI_MAC_STATUS_OPMODE_HOSTAP; + break; + case IEEE80211_M_MONITOR: +#if 0 + /* Do you want data from your microwave oven? */ + mac_status |= BWI_MAC_STATUS_PASS_CTL | + BWI_MAC_STATUS_PASS_BADPLCP | + BWI_MAC_STATUS_PASS_BADFCS; +#else + mac_status |= BWI_MAC_STATUS_PASS_CTL; +#endif + /* Promisc? */ + break; + default: + break; + } + + if (ic->ic_ifp->if_flags & IFF_PROMISC) + mac_status |= BWI_MAC_STATUS_PROMISC; + + CSR_WRITE_4(sc, BWI_MAC_STATUS, mac_status); + + if (ic->ic_opmode != IEEE80211_M_IBSS && + ic->ic_opmode != IEEE80211_M_HOSTAP) { + if (sc->sc_bbp_id == BWI_BBPID_BCM4306 && sc->sc_bbp_rev == 3) + pre_tbtt = 100; + else + pre_tbtt = 50; + } else { + pre_tbtt = 2; + } + CSR_WRITE_2(sc, BWI_MAC_PRE_TBTT, pre_tbtt); +} + +static void +bwi_mac_hostflags_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_rf *rf = &mac->mac_rf; + uint64_t host_flags; + + if (phy->phy_mode == IEEE80211_MODE_11A) + return; + + host_flags = HFLAGS_READ(mac); + host_flags |= BWI_HFLAG_SYM_WA; + + if (phy->phy_mode == IEEE80211_MODE_11G) { + if (phy->phy_rev == 1) + host_flags |= BWI_HFLAG_GDC_WA; + if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) + host_flags |= BWI_HFLAG_OFDM_PA; + } else if (phy->phy_mode == IEEE80211_MODE_11B) { + if (phy->phy_rev >= 2 && rf->rf_type == BWI_RF_T_BCM2050) + host_flags &= ~BWI_HFLAG_GDC_WA; + } else { + panic("unknown PHY mode %u\n", phy->phy_mode); + } + + HFLAGS_WRITE(mac, host_flags); +} + +static void +bwi_mac_bss_param_init(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_phy *phy = &mac->mac_phy; + struct bwi_retry_lim lim; + uint16_t cw_min; + + /* + * Set short/long retry limits + */ + bzero(&lim, sizeof(lim)); + lim.shretry = BWI_SHRETRY; + lim.shretry_fb = BWI_SHRETRY_FB; + lim.lgretry = BWI_LGRETRY; + lim.lgretry_fb = BWI_LGRETRY_FB; + bwi_mac_set_retry_lim(mac, &lim); + + /* + * Implicitly prevent firmware from sending probe response + * by setting its "probe response timeout" to 1us. + */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_PROBE_RESP_TO, 1); + + /* + * XXX MAC level acknowledge and CW min/max should depend + * on the char rateset of the IBSS/BSS to join. + */ + + /* + * Set MAC level acknowledge rates + */ + bwi_mac_set_ackrates(mac, &sc->sc_ic.ic_sup_rates[phy->phy_mode]); + + /* + * Set CW min + */ + if (phy->phy_mode == IEEE80211_MODE_11B) + cw_min = IEEE80211_CW_MIN_0; + else + cw_min = IEEE80211_CW_MIN_1; + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_CWMIN, cw_min); + + /* + * Set CW max + */ + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_CWMAX, + IEEE80211_CW_MAX); +} + +static void +bwi_mac_set_retry_lim(struct bwi_mac *mac, const struct bwi_retry_lim *lim) +{ + /* Short/Long retry limit */ + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_SHRETRY, + lim->shretry); + MOBJ_WRITE_2(mac, BWI_80211_MOBJ, BWI_80211_MOBJ_LGRETRY, + lim->lgretry); + + /* Short/Long retry fallback limit */ + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_SHRETRY_FB, + lim->shretry_fb); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_LGRETEY_FB, + lim->lgretry_fb); +} + +static void +bwi_mac_set_ackrates(struct bwi_mac *mac, const struct ieee80211_rateset *rs) +{ + int i; + + /* XXX not standard conforming */ + for (i = 0; i < rs->rs_nrates; ++i) { + enum ieee80211_modtype modtype; + uint16_t ofs; + + modtype = ieee80211_rate2modtype(rs->rs_rates[i]); + switch (modtype) { + case IEEE80211_MODTYPE_DS: + ofs = 0x4c0; + break; + case IEEE80211_MODTYPE_OFDM: + ofs = 0x480; + break; + default: + panic("unsupported modtype %u\n", modtype); + } + ofs += (bwi_rate2plcp(rs->rs_rates[i]) & 0xf) * 2; + + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, ofs + 0x20, + MOBJ_READ_2(mac, BWI_COMM_MOBJ, ofs)); + } +} + +int +bwi_mac_start(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_ENABLE); + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, BWI_INTR_READY); + + /* Flush pending bus writes */ + CSR_READ_4(sc, BWI_MAC_STATUS); + CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + + return bwi_mac_config_ps(mac); +} + +int +bwi_mac_stop(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + int error, i; + + error = bwi_mac_config_ps(mac); + if (error) + return error; + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_ENABLE); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_MAC_STATUS); + +#define NRETRY 10000 + for (i = 0; i < NRETRY; ++i) { + if (CSR_READ_4(sc, BWI_MAC_INTR_STATUS) & BWI_INTR_READY) + break; + DELAY(1); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "can't stop MAC\n"); + return ETIMEDOUT; + } +#undef NRETRY + + return 0; +} + +int +bwi_mac_config_ps(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + uint32_t status; + + status = CSR_READ_4(sc, BWI_MAC_STATUS); + + status &= ~BWI_MAC_STATUS_HW_PS; + status |= BWI_MAC_STATUS_WAKEUP; + CSR_WRITE_4(sc, BWI_MAC_STATUS, status); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_MAC_STATUS); + + if (mac->mac_rev >= 5) { + int i; + +#define NRETRY 100 + for (i = 0; i < NRETRY; ++i) { + if (MOBJ_READ_2(mac, BWI_COMM_MOBJ, + BWI_COMM_MOBJ_UCODE_STATE) != BWI_UCODE_STATE_PS) + break; + DELAY(10); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "config PS failed\n"); + return ETIMEDOUT; + } +#undef NRETRY + } + return 0; +} + +void +bwi_mac_reset_hwkeys(struct bwi_mac *mac) +{ + /* TODO: firmware crypto */ + MOBJ_READ_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_KEYTABLE_OFS); +} + +void +bwi_mac_shutdown(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + int i; + + if (mac->mac_flags & BWI_MAC_F_HAS_TXSTATS) + sc->sc_free_txstats(sc); + + sc->sc_free_rx_ring(sc); + + for (i = 0; i < BWI_TX_NRING; ++i) + sc->sc_free_tx_ring(sc, i); + + bwi_rf_off(mac); + + /* TODO:LED */ + + bwi_mac_gpio_fini(mac); + + bwi_rf_off(mac); /* XXX again */ + CSR_WRITE_2(sc, BWI_BBP_ATTEN, BWI_BBP_ATTEN_MAGIC); + bwi_regwin_disable(sc, &mac->mac_regwin, 0); + + mac->mac_flags &= ~BWI_MAC_F_INITED; +} + +static int +bwi_mac_get_property(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + enum bwi_bus_space old_bus_space; + uint32_t val; + + /* + * Byte swap + */ + val = CSR_READ_4(sc, BWI_MAC_STATUS); + if (val & BWI_MAC_STATUS_BSWAP) { + DPRINTF(sc, "%s\n", "need byte swap"); + mac->mac_flags |= BWI_MAC_F_BSWAP; + } + + /* + * DMA address space + */ + old_bus_space = sc->sc_bus_space; + + val = CSR_READ_4(sc, BWI_STATE_HI); + if (__SHIFTOUT(val, BWI_STATE_HI_FLAGS_MASK) & + BWI_STATE_HI_FLAG_64BIT) { + /* 64bit address */ + sc->sc_bus_space = BWI_BUS_SPACE_64BIT; + DPRINTF(sc, "%s\n", "64bit bus space"); + } else { + uint32_t txrx_reg = BWI_TXRX_CTRL_BASE + BWI_TX32_CTRL; + + CSR_WRITE_4(sc, txrx_reg, BWI_TXRX32_CTRL_ADDRHI_MASK); + if (CSR_READ_4(sc, txrx_reg) & BWI_TXRX32_CTRL_ADDRHI_MASK) { + /* 32bit address */ + sc->sc_bus_space = BWI_BUS_SPACE_32BIT; + DPRINTF(sc, "%s\n", "32bit bus space"); + } else { + /* 30bit address */ + sc->sc_bus_space = BWI_BUS_SPACE_30BIT; + DPRINTF(sc, "%s\n", "30bit bus space"); + } + } + + if (old_bus_space != 0 && old_bus_space != sc->sc_bus_space) { + device_printf(sc->sc_dev, "MACs bus space mismatch!\n"); + return ENXIO; + } + return 0; +} + +void +bwi_mac_updateslot(struct bwi_mac *mac, int shslot) +{ + uint16_t slot_time; + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11B) + return; + + if (shslot) + slot_time = IEEE80211_DUR_SHSLOT; + else + slot_time = IEEE80211_DUR_SLOT; + + CSR_WRITE_2(mac->mac_sc, BWI_MAC_SLOTTIME, + slot_time + BWI_MAC_SLOTTIME_ADJUST); + MOBJ_WRITE_2(mac, BWI_COMM_MOBJ, BWI_COMM_MOBJ_SLOTTIME, slot_time); +} + +int +bwi_mac_attach(struct bwi_softc *sc, int id, uint8_t rev) +{ + struct bwi_mac *mac; + int i; + + KASSERT(sc->sc_nmac <= BWI_MAC_MAX && sc->sc_nmac >= 0, + ("sc_nmac %d", sc->sc_nmac)); + + if (sc->sc_nmac == BWI_MAC_MAX) { + device_printf(sc->sc_dev, "too many MACs\n"); + return 0; + } + + /* + * More than one MAC is only supported by BCM4309 + */ + if (sc->sc_nmac != 0 && + sc->sc_pci_did != PCI_PRODUCT_BROADCOM_BCM4309) { + DPRINTF(sc, "%s\n", "ignore second MAC"); + return 0; + } + + mac = &sc->sc_mac[sc->sc_nmac]; + + /* XXX will this happen? */ + if (BWI_REGWIN_EXIST(&mac->mac_regwin)) { + device_printf(sc->sc_dev, "%dth MAC already attached\n", + sc->sc_nmac); + return 0; + } + + /* + * Test whether the revision of this MAC is supported + */ +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + for (i = 0; i < N(bwi_sup_macrev); ++i) { + if (bwi_sup_macrev[i] == rev) + break; + } + if (i == N(bwi_sup_macrev)) { + device_printf(sc->sc_dev, "MAC rev %u is " + "not supported\n", rev); + return ENXIO; + } +#undef N + + BWI_CREATE_MAC(mac, sc, id, rev); + sc->sc_nmac++; + + if (mac->mac_rev < 5) { + mac->mac_flags |= BWI_MAC_F_HAS_TXSTATS; + DPRINTF(sc, "%s\n", "has TX stats"); + } + + device_printf(sc->sc_dev, "MAC: rev %u\n", rev); + return 0; +} + +static __inline void +bwi_mac_balance_atten(int *bbp_atten0, int *rf_atten0) +{ + int bbp_atten, rf_atten, rf_atten_lim = -1; + + bbp_atten = *bbp_atten0; + rf_atten = *rf_atten0; + + /* + * RF attenuation affects TX power BWI_RF_ATTEN_FACTOR times + * as much as BBP attenuation, so we try our best to keep RF + * attenuation within range. BBP attenuation will be clamped + * later if it is out of range during balancing. + * + * BWI_RF_ATTEN_MAX0 is used as RF attenuation upper limit. + */ + + /* + * Use BBP attenuation to balance RF attenuation + */ + if (rf_atten < 0) + rf_atten_lim = 0; + else if (rf_atten > BWI_RF_ATTEN_MAX0) + rf_atten_lim = BWI_RF_ATTEN_MAX0; + + if (rf_atten_lim >= 0) { + bbp_atten += (BWI_RF_ATTEN_FACTOR * (rf_atten - rf_atten_lim)); + rf_atten = rf_atten_lim; + } + + /* + * If possible, use RF attenuation to balance BBP attenuation + * NOTE: RF attenuation is still kept within range. + */ + while (rf_atten < BWI_RF_ATTEN_MAX0 && bbp_atten > BWI_BBP_ATTEN_MAX) { + bbp_atten -= BWI_RF_ATTEN_FACTOR; + ++rf_atten; + } + while (rf_atten > 0 && bbp_atten < 0) { + bbp_atten += BWI_RF_ATTEN_FACTOR; + --rf_atten; + } + + /* RF attenuation MUST be within range */ + KASSERT(rf_atten >= 0 && rf_atten <= BWI_RF_ATTEN_MAX0, + ("rf_atten %d", rf_atten)); + + /* + * Clamp BBP attenuation + */ + if (bbp_atten < 0) + bbp_atten = 0; + else if (bbp_atten > BWI_BBP_ATTEN_MAX) + bbp_atten = BWI_BBP_ATTEN_MAX; + + *rf_atten0 = rf_atten; + *bbp_atten0 = bbp_atten; +} + +static void +bwi_mac_adjust_tpctl(struct bwi_mac *mac, int rf_atten_adj, int bbp_atten_adj) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + struct bwi_tpctl tpctl; + int bbp_atten, rf_atten, tp_ctrl1; + + bcopy(&mac->mac_tpctl, &tpctl, sizeof(tpctl)); + + /* NOTE: Use signed value to do calulation */ + bbp_atten = tpctl.bbp_atten; + rf_atten = tpctl.rf_atten; + tp_ctrl1 = tpctl.tp_ctrl1; + + bbp_atten += bbp_atten_adj; + rf_atten += rf_atten_adj; + + bwi_mac_balance_atten(&bbp_atten, &rf_atten); + + if (rf->rf_type == BWI_RF_T_BCM2050 && rf->rf_rev == 2) { + if (rf_atten <= 1) { + if (tp_ctrl1 == 0) { + tp_ctrl1 = 3; + bbp_atten += 2; + rf_atten += 2; + } else if (sc->sc_card_flags & BWI_CARD_F_PA_GPIO9) { + bbp_atten += + (BWI_RF_ATTEN_FACTOR * (rf_atten - 2)); + rf_atten = 2; + } + } else if (rf_atten > 4 && tp_ctrl1 != 0) { + tp_ctrl1 = 0; + if (bbp_atten < 3) { + bbp_atten += 2; + rf_atten -= 3; + } else { + bbp_atten -= 2; + rf_atten -= 2; + } + } + bwi_mac_balance_atten(&bbp_atten, &rf_atten); + } + + tpctl.bbp_atten = bbp_atten; + tpctl.rf_atten = rf_atten; + tpctl.tp_ctrl1 = tp_ctrl1; + + bwi_mac_lock(mac); + bwi_mac_set_tpctl_11bg(mac, &tpctl); + bwi_mac_unlock(mac); +} + +/* + * http://bcm-specs.sipsolutions.net/RecalculateTransmissionPower + */ +void +bwi_mac_calibrate_txpower(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct bwi_rf *rf = &mac->mac_rf; + int8_t tssi[4], tssi_avg, cur_txpwr; + int error, i, ofdm_tssi; + int txpwr_diff, rf_atten_adj, bbp_atten_adj; + + if (mac->mac_flags & BWI_MAC_F_TPCTL_ERROR) { + DPRINTF(sc, "%s\n", "tpctl error happened, can't set txpower"); + return; + } + + if (BWI_IS_BRCM_BU4306(sc)) { + DPRINTF(sc, "%s\n", "BU4306, can't set txpower"); + return; + } + + /* + * Save latest TSSI and reset the related memory objects + */ + ofdm_tssi = 0; + error = bwi_rf_get_latest_tssi(mac, tssi, BWI_COMM_MOBJ_TSSI_DS); + if (error) { + DPRINTF(sc, "%s\n", "no DS tssi"); + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11B) + return; + + error = bwi_rf_get_latest_tssi(mac, tssi, + BWI_COMM_MOBJ_TSSI_OFDM); + if (error) { + DPRINTF(sc, "%s\n", "no OFDM tssi"); + return; + } + + for (i = 0; i < 4; ++i) { + tssi[i] += 0x20; + tssi[i] &= 0x3f; + } + ofdm_tssi = 1; + } + bwi_rf_clear_tssi(mac); + + DPRINTF(sc, "tssi0 %d, tssi1 %d, tssi2 %d, tssi3 %d\n", + tssi[0], tssi[1], tssi[2], tssi[3]); + + /* + * Calculate RF/BBP attenuation adjustment based on + * the difference between desired TX power and sampled + * TX power. + */ + /* +8 == "each incremented by 1/2" */ + tssi_avg = (tssi[0] + tssi[1] + tssi[2] + tssi[3] + 8) / 4; + if (ofdm_tssi && (HFLAGS_READ(mac) & BWI_HFLAG_PWR_BOOST_DS)) + tssi_avg -= 13; + + DPRINTF(sc, "tssi avg %d\n", tssi_avg); + + error = bwi_rf_tssi2dbm(mac, tssi_avg, &cur_txpwr); + if (error) + return; + DPRINTF(sc, "current txpower %d\n", cur_txpwr); + + txpwr_diff = rf->rf_txpower_max - cur_txpwr; /* XXX ni_txpower */ + + rf_atten_adj = -howmany(txpwr_diff, 8); + bbp_atten_adj = -(txpwr_diff / 2) - + (BWI_RF_ATTEN_FACTOR * rf_atten_adj); + + if (rf_atten_adj == 0 && bbp_atten_adj == 0) { + DPRINTF(sc, "%s\n", "no need to adjust RF/BBP attenuation"); + /* TODO: LO */ + return; + } + + DPRINTF(sc, "rf atten adjust %d, bbp atten adjust %d\n", + rf_atten_adj, bbp_atten_adj); + bwi_mac_adjust_tpctl(mac, rf_atten_adj, bbp_atten_adj); + /* TODO: LO */ +} + +static void +bwi_mac_lock(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ieee80211com *ic = &sc->sc_ic; + + KASSERT((mac->mac_flags & BWI_MAC_F_LOCKED) == 0, + ("mac_flags 0x%x", mac->mac_flags)); + + if (mac->mac_rev < 3) + bwi_mac_stop(mac); + else if (ic->ic_opmode != IEEE80211_M_HOSTAP) + bwi_mac_config_ps(mac); + + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_RFLOCK); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_MAC_STATUS); + DELAY(10); + + mac->mac_flags |= BWI_MAC_F_LOCKED; +} + +static void +bwi_mac_unlock(struct bwi_mac *mac) +{ + struct bwi_softc *sc = mac->mac_sc; + struct ieee80211com *ic = &sc->sc_ic; + + KASSERT(mac->mac_flags & BWI_MAC_F_LOCKED, + ("mac_flags 0x%x", mac->mac_flags)); + + CSR_READ_2(sc, BWI_PHYINFO); /* dummy read */ + + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_RFLOCK); + + if (mac->mac_rev < 3) + bwi_mac_start(mac); + else if (ic->ic_opmode != IEEE80211_M_HOSTAP) + bwi_mac_config_ps(mac); + + mac->mac_flags &= ~BWI_MAC_F_LOCKED; +} + +void +bwi_mac_set_promisc(struct bwi_mac *mac, int promisc) +{ + struct bwi_softc *sc = mac->mac_sc; + + if (mac->mac_rev < 5) /* Promisc is always on */ + return; + + if (promisc) + CSR_SETBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_PROMISC); + else + CSR_CLRBITS_4(sc, BWI_MAC_STATUS, BWI_MAC_STATUS_PROMISC); +} --- /dev/null +++ sys/dev/bwi/if_bwireg.h @@ -0,0 +1,503 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/if_bwireg.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/if_bwireg.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _IF_BWIREG_H +#define _IF_BWIREG_H + +/* + * Registers for all of the register windows + */ +#define BWI_FLAGS 0xf18 +#define BWI_FLAGS_INTR_MASK __BITS(5, 0) + +#define BWI_IMSTATE 0xf90 +#define BWI_IMSTATE_INBAND_ERR __BIT(17) +#define BWI_IMSTATE_TIMEOUT __BIT(18) + +#define BWI_INTRVEC 0xf94 + +#define BWI_STATE_LO 0xf98 +#define BWI_STATE_LO_RESET __BIT(0) +#define BWI_STATE_LO_DISABLE1 __BIT(1) +#define BWI_STATE_LO_DISABLE2 __BIT(2) +#define BWI_STATE_LO_CLOCK __BIT(16) +#define BWI_STATE_LO_GATED_CLOCK __BIT(17) +#define BWI_STATE_LO_FLAG_PHYCLKEN __BIT(0) +#define BWI_STATE_LO_FLAG_PHYRST __BIT(1) +#define BWI_STATE_LO_FLAG_PHYLNK __BIT(11) +#define BWI_STATE_LO_FLAGS_MASK __BITS(29, 18) + +#define BWI_STATE_HI 0xf9c +#define BWI_STATE_HI_SERROR __BIT(0) +#define BWI_STATE_HI_BUSY __BIT(2) +#define BWI_STATE_HI_FLAG_MAGIC1 0x1 +#define BWI_STATE_HI_FLAG_MAGIC2 0x2 +#define BWI_STATE_HI_FLAG_64BIT 0x1000 +#define BWI_STATE_HI_FLAGS_MASK __BITS(28, 16) + +#define BWI_CONF_LO 0xfa8 +#define BWI_CONF_LO_SERVTO_MASK __BITS(2, 0) /* service timeout */ +#define BWI_CONF_LO_SERVTO 2 +#define BWI_CONF_LO_REQTO_MASK __BITS(6, 4) /* request timeout */ +#define BWI_CONF_LO_REQTO 3 + + +#define BWI_ID_LO 0xff8 +#define BWI_ID_LO_BUSREV_MASK __BITS(31, 28) +/* Bus revision */ +#define BWI_BUSREV_0 0 +#define BWI_BUSREV_1 1 + +#define BWI_ID_HI 0xffc +#define BWI_ID_HI_REGWIN_REV(v) (((v) & 0xf) | (((v) & 0x7000) >> 8)) +#define BWI_ID_HI_REGWIN_TYPE(v) (((v) & 0x8ff0) >> 4) +#define BWI_ID_HI_REGWIN_VENDOR_MASK __BITS(31, 16) + +/* + * Registers for common register window + */ +#define BWI_INFO 0x0 +#define BWI_INFO_BBPID_MASK __BITS(15, 0) +#define BWI_INFO_BBPREV_MASK __BITS(19, 16) +#define BWI_INFO_BBPPKG_MASK __BITS(23, 20) +#define BWI_INFO_NREGWIN_MASK __BITS(27, 24) + +#define BWI_CAPABILITY 0x4 +#define BWI_CAP_CLKMODE __BIT(18) + +#define BWI_CONTROL 0x28 +#define BWI_CONTROL_MAGIC0 0x3a4 +#define BWI_CONTROL_MAGIC1 0xa4 +#define BWI_PLL_ON_DELAY 0xb0 +#define BWI_FREQ_SEL_DELAY 0xb4 + +#define BWI_CLOCK_CTRL 0xb8 +#define BWI_CLOCK_CTRL_CLKSRC __BITS(2, 0) +#define BWI_CLOCK_CTRL_SLOW __BIT(11) +#define BWI_CLOCK_CTRL_IGNPLL __BIT(12) +#define BWI_CLOCK_CTRL_NODYN __BIT(13) +#define BWI_CLOCK_CTRL_FDIV __BITS(31, 16) /* freq divisor */ + +/* Possible values for BWI_CLOCK_CTRL_CLKSRC */ +#define BWI_CLKSRC_LP_OSC 0 /* Low power oscillator */ +#define BWI_CLKSRC_CS_OSC 1 /* Crystal oscillator */ +#define BWI_CLKSRC_PCI 2 +#define BWI_CLKSRC_MAX 3 /* Maximum of clock source */ +/* Min/Max frequency for given clock source */ +#define BWI_CLKSRC_LP_OSC_FMIN 25000 +#define BWI_CLKSRC_LP_OSC_FMAX 43000 +#define BWI_CLKSRC_CS_OSC_FMIN 19800000 +#define BWI_CLKSRC_CS_OSC_FMAX 20200000 +#define BWI_CLKSRC_PCI_FMIN 25000000 +#define BWI_CLKSRC_PCI_FMAX 34000000 + +#define BWI_CLOCK_INFO 0xc0 +#define BWI_CLOCK_INFO_FDIV __BITS(31, 16) /* freq divisor */ + +/* + * Registers for bus register window + */ +#define BWI_BUS_ADDR 0x50 +#define BWI_BUS_ADDR_MAGIC 0xfd8 + +#define BWI_BUS_DATA 0x54 + +#define BWI_BUS_CONFIG 0x108 +#define BWI_BUS_CONFIG_PREFETCH __BIT(2) +#define BWI_BUS_CONFIG_BURST __BIT(3) +#define BWI_BUS_CONFIG_MRM __BIT(5) + +/* + * Register for MAC + */ +#define BWI_TXRX_INTR_STATUS_BASE 0x20 +#define BWI_TXRX_INTR_MASK_BASE 0x24 +#define BWI_TXRX_INTR_STATUS(i) (BWI_TXRX_INTR_STATUS_BASE + ((i) * 8)) +#define BWI_TXRX_INTR_MASK(i) (BWI_TXRX_INTR_MASK_BASE + ((i) * 8)) + +#define BWI_MAC_STATUS 0x120 +#define BWI_MAC_STATUS_ENABLE __BIT(0) +#define BWI_MAC_STATUS_UCODE_START __BIT(1) +#define BWI_MAC_STATUS_UCODE_JUMP0 __BIT(2) +#define BWI_MAC_STATUS_IHREN __BIT(10) +#define BWI_MAC_STATUS_GPOSEL_MASK __BITS(15, 14) +#define BWI_MAC_STATUS_BSWAP __BIT(16) +#define BWI_MAC_STATUS_INFRA __BIT(17) +#define BWI_MAC_STATUS_OPMODE_HOSTAP __BIT(18) +#define BWI_MAC_STATUS_RFLOCK __BIT(19) +#define BWI_MAC_STATUS_PASS_BCN __BIT(20) +#define BWI_MAC_STATUS_PASS_BADPLCP __BIT(21) +#define BWI_MAC_STATUS_PASS_CTL __BIT(22) +#define BWI_MAC_STATUS_PASS_BADFCS __BIT(23) +#define BWI_MAC_STATUS_PROMISC __BIT(24) +#define BWI_MAC_STATUS_HW_PS __BIT(25) +#define BWI_MAC_STATUS_WAKEUP __BIT(26) +#define BWI_MAC_STATUS_PHYLNK __BIT(31) + +#define BWI_MAC_INTR_STATUS 0x128 +#define BWI_MAC_INTR_MASK 0x12c + +#define BWI_MAC_TMPLT_CTRL 0x130 +#define BWI_MAC_TMPLT_DATA 0x134 + +#define BWI_MAC_PS_STATUS 0x140 + +#define BWI_MOBJ_CTRL 0x160 +#define BWI_MOBJ_CTRL_VAL(objid, ofs) ((objid) << 16 | (ofs)) +#define BWI_MOBJ_DATA 0x164 +#define BWI_MOBJ_DATA_UNALIGN 0x166 +/* + * Memory object IDs + */ +#define BWI_WR_MOBJ_AUTOINC 0x100 /* Auto-increment wr */ +#define BWI_RD_MOBJ_AUTOINC 0x200 /* Auto-increment rd */ +/* Firmware ucode object */ +#define BWI_FW_UCODE_MOBJ 0x0 +/* Common object */ +#define BWI_COMM_MOBJ 0x1 +#define BWI_COMM_MOBJ_FWREV 0x0 +#define BWI_COMM_MOBJ_FWPATCHLV 0x2 +#define BWI_COMM_MOBJ_SLOTTIME 0x10 +#define BWI_COMM_MOBJ_MACREV 0x16 +#define BWI_COMM_MOBJ_TX_ACK 0x22 +#define BWI_COMM_MOBJ_UCODE_STATE 0x40 +#define BWI_COMM_MOBJ_SHRETRY_FB 0x44 +#define BWI_COMM_MOBJ_LGRETEY_FB 0x46 +#define BWI_COMM_MOBJ_TX_BEACON 0x54 +#define BWI_COMM_MOBJ_KEYTABLE_OFS 0x56 +#define BWI_COMM_MOBJ_TSSI_DS 0x58 +#define BWI_COMM_MOBJ_HFLAGS_LO 0x5e +#define BWI_COMM_MOBJ_HFLAGS_MI 0x60 +#define BWI_COMM_MOBJ_HFLAGS_HI 0x62 +#define BWI_COMM_MOBJ_RF_ATTEN 0x64 +#define BWI_COMM_MOBJ_TSSI_OFDM 0x70 +#define BWI_COMM_MOBJ_PROBE_RESP_TO 0x74 +#define BWI_COMM_MOBJ_CHAN 0xa0 +#define BWI_COMM_MOBJ_KEY_ALGO 0x100 +#define BWI_COMM_MOBJ_TX_PROBE_RESP 0x188 +#define BWI_HFLAG_AUTO_ANTDIV 0x1ULL +#define BWI_HFLAG_SYM_WA 0x2ULL /* ??? SYM work around */ +#define BWI_HFLAG_PWR_BOOST_DS 0x8ULL +#define BWI_HFLAG_GDC_WA 0x20ULL /* ??? GDC work around */ +#define BWI_HFLAG_OFDM_PA 0x40ULL +#define BWI_HFLAG_NOT_JAPAN 0x80ULL +#define BWI_HFLAG_MAGIC1 0x200ULL +#define BWI_UCODE_STATE_PS 4 +#define BWI_LO_TSSI_MASK __BITS(7, 0) +#define BWI_HI_TSSI_MASK __BITS(15, 8) +#define BWI_INVALID_TSSI 0x7f +/* 802.11 object */ +#define BWI_80211_MOBJ 0x2 +#define BWI_80211_MOBJ_CWMIN 0xc +#define BWI_80211_MOBJ_CWMAX 0x10 +#define BWI_80211_MOBJ_SHRETRY 0x18 +#define BWI_80211_MOBJ_LGRETRY 0x1c +/* Firmware PCM object */ +#define BWI_FW_PCM_MOBJ 0x3 +/* MAC address of pairwise keys */ +#define BWI_PKEY_ADDR_MOBJ 0x4 + +#define BWI_TXSTATUS0 0x170 +#define BWI_TXSTATUS0_VALID __BIT(0) +#define BWI_TXSTATUS0_ACKED __BIT(1) +#define BWI_TXSTATUS0_FREASON_MASK __BITS(4, 2) /* Failure reason */ +#define BWI_TXSTATUS0_AMPDU __BIT(5) +#define BWI_TXSTATUS0_PENDING __BIT(6) +#define BWI_TXSTATUS0_PM __BIT(7) +#define BWI_TXSTATUS0_RTS_TXCNT_MASK __BITS(11, 8) +#define BWI_TXSTATUS0_DATA_TXCNT_MASK __BITS(15, 12) +#define BWI_TXSTATUS0_TXID_MASK __BITS(31, 16) +#define BWI_TXSTATUS1 0x174 + +#define BWI_TXRX_CTRL_BASE 0x200 +#define BWI_TX32_CTRL 0x0 +#define BWI_TX32_RINGINFO 0x4 +#define BWI_TX32_INDEX 0x8 +#define BWI_TX32_STATUS 0xc +#define BWI_TX32_STATUS_STATE_MASK __BITS(15, 12) +#define BWI_TX32_STATUS_STATE_DISABLED 0 +#define BWI_TX32_STATUS_STATE_IDLE 2 +#define BWI_TX32_STATUS_STATE_STOPPED 3 +#define BWI_RX32_CTRL 0x10 +#define BWI_RX32_CTRL_HDRSZ_MASK __BITS(7, 1) +#define BWI_RX32_RINGINFO 0x14 +#define BWI_RX32_INDEX 0x18 +#define BWI_RX32_STATUS 0x1c +#define BWI_RX32_STATUS_INDEX_MASK __BITS(11, 0) +#define BWI_RX32_STATUS_STATE_MASK __BITS(15, 12) +#define BWI_RX32_STATUS_STATE_DISABLED 0 +/* Shared by 32bit TX/RX CTRL */ +#define BWI_TXRX32_CTRL_ENABLE __BIT(0) +#define BWI_TXRX32_CTRL_ADDRHI_MASK __BITS(17, 16) +/* Shared by 32bit TX/RX RINGINFO */ +#define BWI_TXRX32_RINGINFO_FUNC_TXRX 0x1 +#define BWI_TXRX32_RINGINFO_FUNC_MASK __BITS(31, 30) +#define BWI_TXRX32_RINGINFO_ADDR_MASK __BITS(29, 0) + +#define BWI_PHYINFO 0x3e0 +#define BWI_PHYINFO_REV_MASK __BITS(3, 0) +#define BWI_PHYINFO_TYPE_MASK __BITS(11, 8) +#define BWI_PHYINFO_TYPE_11A 0 +#define BWI_PHYINFO_TYPE_11B 1 +#define BWI_PHYINFO_TYPE_11G 2 +#define BWI_PHYINFO_TYPE_11N 4 +#define BWI_PHYINFO_TYPE_11LP 5 +#define BWI_PHYINFO_VER_MASK __BITS(15, 12) + +#define BWI_RF_ANTDIV 0x3e2 /* Antenna Diversity?? */ + +#define BWI_PHY_MAGIC_REG1 0x3e4 +#define BWI_PHY_MAGIC_REG1_VAL1 0x3000 +#define BWI_PHY_MAGIC_REG1_VAL2 0x9 + +#define BWI_BBP_ATTEN 0x3e6 +#define BWI_BBP_ATTEN_MAGIC 0xf4 +#define BWI_BBP_ATTEN_MAGIC2 0x8140 + +#define BWI_BPHY_CTRL 0x3ec +#define BWI_BPHY_CTRL_INIT 0x3f22 + +#define BWI_RF_CHAN 0x3f0 +#define BWI_RF_CHAN_EX 0x3f4 + +#define BWI_RF_CTRL 0x3f6 +/* Register values for BWI_RF_CTRL */ +#define BWI_RF_CTRL_RFINFO 0x1 +/* XXX extra bits for reading from radio */ +#define BWI_RF_CTRL_RD_11A 0x40 +#define BWI_RF_CTRL_RD_11BG 0x80 +#define BWI_RF_DATA_HI 0x3f8 +#define BWI_RF_DATA_LO 0x3fa +/* Values read from BWI_RF_DATA_{HI,LO} after BWI_RF_CTRL_RFINFO */ +#define BWI_RFINFO_MANUFACT_MASK __BITS(11, 0) +#define BWI_RF_MANUFACT_BCM 0x17f /* XXX */ +#define BWI_RFINFO_TYPE_MASK __BITS(27, 12) +#define BWI_RF_T_BCM2050 0x2050 +#define BWI_RF_T_BCM2053 0x2053 +#define BWI_RF_T_BCM2060 0x2060 +#define BWI_RFINFO_REV_MASK __BITS(31, 28) + +#define BWI_PHY_CTRL 0x3fc +#define BWI_PHY_DATA 0x3fe + +#define BWI_ADDR_FILTER_CTRL 0x420 +#define BWI_ADDR_FILTER_CTRL_SET 0x20 +#define BWI_ADDR_FILTER_MYADDR 0 +#define BWI_ADDR_FILTER_BSSID 3 +#define BWI_ADDR_FILTER_DATA 0x422 + +#define BWI_MAC_GPIO_CTRL 0x49c +#define BWI_MAC_GPIO_MASK 0x49e +#define BWI_MAC_PRE_TBTT 0x612 +#define BWI_MAC_SLOTTIME 0x684 +#define BWI_MAC_SLOTTIME_ADJUST 510 +#define BWI_MAC_POWERUP_DELAY 0x6a8 + +/* + * Special registers + */ +/* + * GPIO control + * If common regwin exists, then it is within common regwin, + * else it is in bus regwin. + */ +#define BWI_GPIO_CTRL 0x6c + +#define PCI_VENDOR_BROADCOM 0x14e4 /* Broadcom */ +#define PCI_PRODUCT_BROADCOM_BCM4309 0x4324 + +/* + * Extended PCI registers + */ +#define BWI_PCIR_BAR PCIR_BAR(0) +#define BWI_PCIR_SEL_REGWIN 0x80 +/* Register value for BWI_PCIR_SEL_REGWIN */ +#define BWI_PCIM_REGWIN(id) (((id) * 0x1000) + 0x18000000) +#define BWI_PCIR_GPIO_IN 0xb0 +#define BWI_PCIR_GPIO_OUT 0xb4 +#define BWI_PCIM_GPIO_OUT_CLKSRC __BIT(4) +#define BWI_PCIR_GPIO_ENABLE 0xb8 +/* Register values for BWI_PCIR_GPIO_{IN,OUT,ENABLE} */ +#define BWI_PCIM_GPIO_PWR_ON __BIT(6) +#define BWI_PCIM_GPIO_PLL_PWR_OFF __BIT(7) +#define BWI_PCIR_INTCTL 0x94 + +/* + * PCI subdevice IDs + */ +#define BWI_PCI_SUBDEVICE_BU4306 0x416 +#define BWI_PCI_SUBDEVICE_BCM4309G 0x421 + +#define BWI_IS_BRCM_BU4306(sc) \ + ((sc)->sc_pci_subvid == PCI_VENDOR_BROADCOM && \ + (sc)->sc_pci_subdid == BWI_PCI_SUBDEVICE_BU4306) +#define BWI_IS_BRCM_BCM4309G(sc) \ + ((sc)->sc_pci_subvid == PCI_VENDOR_BROADCOM && \ + (sc)->sc_pci_subdid == BWI_PCI_SUBDEVICE_BCM4309G) + +/* + * EEPROM start address + */ +#define BWI_SPROM_START 0x1000 +#define BWI_SPROM_11BG_EADDR 0x48 +#define BWI_SPROM_11A_EADDR 0x54 +#define BWI_SPROM_CARD_INFO 0x5c +#define BWI_SPROM_CARD_INFO_LOCALE __BITS(11, 8) +#define BWI_SPROM_LOCALE_JAPAN 5 +#define BWI_SPROM_PA_PARAM_11BG 0x5e +#define BWI_SPROM_GPIO01 0x64 +#define BWI_SPROM_GPIO_0 __BITS(7, 0) +#define BWI_SPROM_GPIO_1 __BITS(15, 8) +#define BWI_SPROM_GPIO23 0x66 +#define BWI_SPROM_GPIO_2 __BITS(7, 0) +#define BWI_SPROM_GPIO_3 __BITS(15, 8) +#define BWI_SPROM_MAX_TXPWR 0x68 +#define BWI_SPROM_MAX_TXPWR_MASK_11BG __BITS(7, 0) /* XXX */ +#define BWI_SPROM_MAX_TXPWR_MASK_11A __BITS(15, 8) /* XXX */ +#define BWI_SPROM_PA_PARAM_11A 0x6a +#define BWI_SPROM_IDLE_TSSI 0x70 +#define BWI_SPROM_IDLE_TSSI_MASK_11BG __BITS(7, 0) /* XXX */ +#define BWI_SPROM_IDLE_TSSI_MASK_11A __BITS(15, 8) /* XXX */ +#define BWI_SPROM_CARD_FLAGS 0x72 +#define BWI_SPROM_ANT_GAIN 0x74 +#define BWI_SPROM_ANT_GAIN_MASK_11A __BITS(7, 0) +#define BWI_SPROM_ANT_GAIN_MASK_11BG __BITS(15, 8) + +/* + * SPROM card flags + */ +#define BWI_CARD_F_BT_COEXIST __BIT(0) /* Bluetooth coexist */ +#define BWI_CARD_F_PA_GPIO9 __BIT(1) /* GPIO 9 controls PA */ +#define BWI_CARD_F_SW_NRSSI __BIT(3) +#define BWI_CARD_F_NO_SLOWCLK __BIT(5) /* no slow clock */ +#define BWI_CARD_F_EXT_LNA __BIT(12) /* external LNA */ +#define BWI_CARD_F_ALT_IQ __BIT(15) /* alternate I/Q */ + +/* + * SPROM GPIO + */ +#define BWI_LED_ACT_LOW __BIT(7) +#define BWI_LED_ACT_MASK __BITS(6, 0) +#define BWI_LED_ACT_OFF 0 +#define BWI_LED_ACT_ON 1 +#define BWI_LED_ACT_ACTIVE 2 +#define BWI_LED_ACT_RFEN 3 +#define BWI_LED_ACT_5GHZ 4 +#define BWI_LED_ACT_2GHZ 5 +#define BWI_LED_ACT_11G 6 +#define BWI_LED_ACT_MID 7 +#define BWI_LED_ACT_FAST 8 +#define BWI_LED_ACT_UNKN 9 +#define BWI_LED_ACT_RUN 10 +#define BWI_LED_ACT_NULL 11 + +/* + * BBP IDs + */ +#define BWI_BBPID_BCM4301 0x4301 +#define BWI_BBPID_BCM4306 0x4306 +#define BWI_BBPID_BCM4317 0x4317 +#define BWI_BBPID_BCM4320 0x4320 +#define BWI_BBPID_BCM4321 0x4321 + +/* + * Register window types + */ +#define BWI_REGWIN_T_CC 0x800 //CC +#define BWI_REGWIN_T_ILINE20 0x801 +#define BWI_REGWIN_T_SDRAM 0x803 +#define BWI_REGWIN_T_PCI 0x804 //BUSPCI +#define BWI_REGWIN_T_MIPS 0x805 +#define BWI_REGWIN_T_ENET 0x806 +#define BWI_REGWIN_T_CODEC 0x807 +#define BWI_REGWIN_T_USB 0x808 +#define BWI_REGWIN_T_ADSL 0x809 +#define BWI_REGWIN_T_ILINE100 0x80a +#define BWI_REGWIN_T_IPSEC 0x80b +#define BWI_REGWIN_T_PCMCIA 0x80d +#define BWI_REGWIN_T_SOCRAM 0x80e +#define BWI_REGWIN_T_MEMC 0x80f +#define BWI_REGWIN_T_EXTIF 0x811 +#define BWI_REGWIN_T_D11 0x812 //MAC +#define BWI_REGWIN_T_MIPS33 0x816 +#define BWI_REGWIN_T_USB11H 0x817 +#define BWI_REGWIN_T_USB11D 0x818 +#define BWI_REGWIN_T_USB20H 0x819 +#define BWI_REGWIN_T_USB20D 0x81a +#define BWI_REGWIN_T_SDIOH 0x81b +#define BWI_REGWIN_T_ROBO 0x81c +#define BWI_REGWIN_T_ATA100 0x81d +#define BWI_REGWIN_T_SATAXOR 0x81e +#define BWI_REGWIN_T_GIGETH 0x81f +#define BWI_REGWIN_T_PCIE 0x820 +#define BWI_REGWIN_T_SRAMC 0x822 +#define BWI_REGWIN_T_MINIMAC 0x823 + +/* + * MAC interrupts + */ +#define BWI_INTR_READY __BIT(0) +#define BWI_INTR_BEACON __BIT(1) +#define BWI_INTR_TBTT __BIT(2) +#define BWI_INTR_EO_ATIM __BIT(5) /* End of ATIM */ +#define BWI_INTR_PMQ __BIT(6) /* XXX?? */ +#define BWI_INTR_MAC_TXERR __BIT(9) +#define BWI_INTR_PHY_TXERR __BIT(11) +#define BWI_INTR_TIMER1 __BIT(14) +#define BWI_INTR_RX_DONE __BIT(15) +#define BWI_INTR_TX_FIFO __BIT(16) /* XXX?? */ +#define BWI_INTR_NOISE __BIT(18) +#define BWI_INTR_RF_DISABLED __BIT(28) +#define BWI_INTR_TX_DONE __BIT(29) + +#define BWI_INIT_INTRS \ + (BWI_INTR_READY | BWI_INTR_BEACON | BWI_INTR_TBTT | \ + BWI_INTR_EO_ATIM | BWI_INTR_PMQ | BWI_INTR_MAC_TXERR | \ + BWI_INTR_PHY_TXERR | BWI_INTR_RX_DONE | BWI_INTR_TX_FIFO | \ + BWI_INTR_NOISE | BWI_INTR_RF_DISABLED | BWI_INTR_TX_DONE) +#define BWI_ALL_INTRS 0xffffffff + +/* + * TX/RX interrupts + */ +#define BWI_TXRX_INTR_ERROR (__BIT(15) | __BIT(14) | __BITS(12, 10)) +#define BWI_TXRX_INTR_RX __BIT(16) +#define BWI_TXRX_TX_INTRS BWI_TXRX_INTR_ERROR +#define BWI_TXRX_RX_INTRS (BWI_TXRX_INTR_ERROR | BWI_TXRX_INTR_RX) +#define BWI_TXRX_IS_RX(i) ((i) % 3 == 0) + +#endif /* !_IF_BWIREG_H */ --- /dev/null +++ sys/dev/bwi/if_bwi.c @@ -0,0 +1,3838 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/if_bwi.c,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/if_bwi.c,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#include + +#include "opt_inet.h" + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include + +#ifdef INET +#include +#include +#endif + +#include + +#include +#include + +#include "bitops.h" +#include "if_bwireg.h" +#include "if_bwivar.h" +#include "bwimac.h" +#include "bwirf.h" + +struct bwi_clock_freq { + u_int clkfreq_min; + u_int clkfreq_max; +}; + +struct bwi_myaddr_bssid { + uint8_t myaddr[IEEE80211_ADDR_LEN]; + uint8_t bssid[IEEE80211_ADDR_LEN]; +} __packed; + +static void bwi_init(void *); +static int bwi_ioctl(struct ifnet *, u_long, caddr_t); +static void bwi_start(struct ifnet *); +static void bwi_watchdog(struct ifnet *); +static void bwi_scan_start(struct ieee80211com *); +static void bwi_set_channel(struct ieee80211com *); +static void bwi_scan_end(struct ieee80211com *); +static int bwi_newstate(struct ieee80211com *, enum ieee80211_state, int); +static void bwi_updateslot(struct ifnet *); +static struct ieee80211_node *bwi_node_alloc(struct ieee80211_node_table *); +static void bwi_newassoc(struct ieee80211_node *, int); +static void bwi_amrr_timeout(void *); +static int bwi_media_change(struct ifnet *); + +static void bwi_calibrate(void *); + +static int bwi_calc_rssi(struct bwi_softc *, const struct bwi_rxbuf_hdr *); +static __inline uint8_t bwi_ofdm_plcp2rate(const uint32_t *); +static __inline uint8_t bwi_ds_plcp2rate(const struct ieee80211_ds_plcp_hdr *); +static void bwi_rx_radiotap(struct bwi_softc *, struct mbuf *, + struct bwi_rxbuf_hdr *, const void *, int); + +static void bwi_stop(struct bwi_softc *); +static int bwi_newbuf(struct bwi_softc *, int, int); +static int bwi_encap(struct bwi_softc *, int, struct mbuf *, + struct ieee80211_node *); + +static void bwi_init_rxdesc_ring32(struct bwi_softc *, uint32_t, + bus_addr_t, int, int); +static void bwi_reset_rx_ring32(struct bwi_softc *, uint32_t); + +static int bwi_init_tx_ring32(struct bwi_softc *, int); +static int bwi_init_rx_ring32(struct bwi_softc *); +static int bwi_init_txstats32(struct bwi_softc *); +static void bwi_free_tx_ring32(struct bwi_softc *, int); +static void bwi_free_rx_ring32(struct bwi_softc *); +static void bwi_free_txstats32(struct bwi_softc *); +static void bwi_setup_rx_desc32(struct bwi_softc *, int, bus_addr_t, int); +static void bwi_setup_tx_desc32(struct bwi_softc *, struct bwi_ring_data *, + int, bus_addr_t, int); +static void bwi_rxeof32(struct bwi_softc *); +static void bwi_start_tx32(struct bwi_softc *, uint32_t, int); +static void bwi_txeof_status32(struct bwi_softc *); + +static int bwi_init_tx_ring64(struct bwi_softc *, int); +static int bwi_init_rx_ring64(struct bwi_softc *); +static int bwi_init_txstats64(struct bwi_softc *); +static void bwi_free_tx_ring64(struct bwi_softc *, int); +static void bwi_free_rx_ring64(struct bwi_softc *); +static void bwi_free_txstats64(struct bwi_softc *); +static void bwi_setup_rx_desc64(struct bwi_softc *, int, bus_addr_t, int); +static void bwi_setup_tx_desc64(struct bwi_softc *, struct bwi_ring_data *, + int, bus_addr_t, int); +static void bwi_rxeof64(struct bwi_softc *); +static void bwi_start_tx64(struct bwi_softc *, uint32_t, int); +static void bwi_txeof_status64(struct bwi_softc *); + +static void bwi_rxeof(struct bwi_softc *, int); +static void _bwi_txeof(struct bwi_softc *, uint16_t, int, int); +static void bwi_txeof(struct bwi_softc *); +static void bwi_txeof_status(struct bwi_softc *, int); +static void bwi_enable_intrs(struct bwi_softc *, uint32_t); +static void bwi_disable_intrs(struct bwi_softc *, uint32_t); + +static int bwi_dma_alloc(struct bwi_softc *); +static void bwi_dma_free(struct bwi_softc *); +static int bwi_dma_ring_alloc(struct bwi_softc *, bus_dma_tag_t, + struct bwi_ring_data *, bus_size_t, + uint32_t); +static int bwi_dma_mbuf_create(struct bwi_softc *); +static void bwi_dma_mbuf_destroy(struct bwi_softc *, int, int); +static int bwi_dma_txstats_alloc(struct bwi_softc *, uint32_t, bus_size_t); +static void bwi_dma_txstats_free(struct bwi_softc *); +static void bwi_dma_ring_addr(void *, bus_dma_segment_t *, int, int); +static void bwi_dma_buf_addr(void *, bus_dma_segment_t *, int, + bus_size_t, int); + +static void bwi_power_on(struct bwi_softc *, int); +static int bwi_power_off(struct bwi_softc *, int); +static int bwi_set_clock_mode(struct bwi_softc *, enum bwi_clock_mode); +static int bwi_set_clock_delay(struct bwi_softc *); +static void bwi_get_clock_freq(struct bwi_softc *, struct bwi_clock_freq *); +static int bwi_get_pwron_delay(struct bwi_softc *sc); +static void bwi_set_addr_filter(struct bwi_softc *, uint16_t, + const uint8_t *); +static void bwi_set_bssid(struct bwi_softc *, const uint8_t *); +static int bwi_set_chan(struct bwi_softc *, struct ieee80211_channel *); + +static void bwi_get_card_flags(struct bwi_softc *); +static void bwi_get_eaddr(struct bwi_softc *, uint16_t, uint8_t *); + +static int bwi_bus_attach(struct bwi_softc *); +static int bwi_bbp_attach(struct bwi_softc *); +static int bwi_bbp_power_on(struct bwi_softc *, enum bwi_clock_mode); +static void bwi_bbp_power_off(struct bwi_softc *); + +static const char *bwi_regwin_name(const uint16_t type); +static uint32_t bwi_regwin_disable_bits(struct bwi_softc *); +static void bwi_regwin_info(struct bwi_softc *, uint16_t *, uint8_t *); +static int bwi_regwin_select(struct bwi_softc *, int); + +static void bwi_led_attach(struct bwi_softc *); +static void bwi_led_newstate(struct bwi_softc *, enum ieee80211_state); + +static const struct { + uint16_t did_min; + uint16_t did_max; + uint16_t bbp_id; +} bwi_bbpid_map[] = { + { 0x4301, 0x4301, 0x4301 }, + { 0x4305, 0x4307, 0x4307 }, + { 0x4403, 0x4403, 0x4402 }, + { 0x4610, 0x4615, 0x4610 }, + { 0x4710, 0x4715, 0x4710 }, + { 0x4720, 0x4725, 0x4309 } +}; + +static const struct { + uint16_t bbp_id; + int nregwin; +} bwi_regwin_count[] = { + { 0x4301, 5 }, + { 0x4306, 6 }, + { 0x4307, 5 }, + { 0x4310, 8 }, + { 0x4401, 3 }, + { 0x4402, 3 }, + { 0x4610, 9 }, + { 0x4704, 9 }, + { 0x4710, 9 }, + { 0x5365, 7 } +}; + +#define CLKSRC(src) \ +[BWI_CLKSRC_ ## src] = { \ + .freq_min = BWI_CLKSRC_ ##src## _FMIN, \ + .freq_max = BWI_CLKSRC_ ##src## _FMAX \ +} + +static const struct { + u_int freq_min; + u_int freq_max; +} bwi_clkfreq[BWI_CLKSRC_MAX] = { + CLKSRC(LP_OSC), + CLKSRC(CS_OSC), + CLKSRC(PCI) +}; + +#undef CLKSRC + +static const uint8_t bwi_zero_addr[IEEE80211_ADDR_LEN]; + +uint16_t +bwi_read_sprom(struct bwi_softc *sc, uint16_t ofs) +{ + return CSR_READ_2(sc, ofs + BWI_SPROM_START); +} + +static __inline void +bwi_setup_desc32(struct bwi_softc *sc, struct bwi_desc32 *desc_array, + int ndesc, int desc_idx, bus_addr_t paddr, int buf_len, + int tx) +{ + struct bwi_desc32 *desc = &desc_array[desc_idx]; + uint32_t ctrl, addr, addr_hi, addr_lo; + + addr_lo = __SHIFTOUT(paddr, BWI_DESC32_A_ADDR_MASK); + addr_hi = __SHIFTOUT(paddr, BWI_DESC32_A_FUNC_MASK); + + addr = __SHIFTIN(addr_lo, BWI_DESC32_A_ADDR_MASK) | + __SHIFTIN(BWI_DESC32_A_FUNC_TXRX, BWI_DESC32_A_FUNC_MASK); + + ctrl = __SHIFTIN(buf_len, BWI_DESC32_C_BUFLEN_MASK) | + __SHIFTIN(addr_hi, BWI_DESC32_C_ADDRHI_MASK); + if (desc_idx == ndesc - 1) + ctrl |= BWI_DESC32_C_EOR; + if (tx) { + /* XXX */ + ctrl |= BWI_DESC32_C_FRAME_START | + BWI_DESC32_C_FRAME_END | + BWI_DESC32_C_INTR; + } + + desc->addr = htole32(addr); + desc->ctrl = htole32(ctrl); +} + +int +bwi_attach(struct bwi_softc *sc) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp; + struct bwi_mac *mac; + struct bwi_phy *phy; + int i, error, bands; + + BWI_LOCK_INIT(sc); + + bwi_power_on(sc, 1); + + error = bwi_bbp_attach(sc); + if (error) + goto fail; + + error = bwi_bbp_power_on(sc, BWI_CLOCK_MODE_FAST); + if (error) + goto fail; + + if (BWI_REGWIN_EXIST(&sc->sc_com_regwin)) { + error = bwi_set_clock_delay(sc); + if (error) + goto fail; + + error = bwi_set_clock_mode(sc, BWI_CLOCK_MODE_FAST); + if (error) + goto fail; + + error = bwi_get_pwron_delay(sc); + if (error) + goto fail; + } + + error = bwi_bus_attach(sc); + if (error) + goto fail; + + bwi_get_card_flags(sc); + + bwi_led_attach(sc); + + for (i = 0; i < sc->sc_nmac; ++i) { + struct bwi_regwin *old; + + mac = &sc->sc_mac[i]; + error = bwi_regwin_switch(sc, &mac->mac_regwin, &old); + if (error) + goto fail; + + error = bwi_mac_lateattach(mac); + if (error) + goto fail; + + error = bwi_regwin_switch(sc, old, NULL); + if (error) + goto fail; + } + + /* + * XXX First MAC is known to exist + * TODO2 + */ + mac = &sc->sc_mac[0]; + phy = &mac->mac_phy; + + bwi_bbp_power_off(sc); + + error = bwi_dma_alloc(sc); + if (error) + goto fail; + + ifp = sc->sc_ifp = if_alloc(IFT_ETHER); + if (ifp == NULL) { + device_printf(sc->sc_dev, "can not if_alloc()\n"); + error = ENOSPC; + goto fail; + } + + /* set these up early for if_printf use */ + if_initname(ifp, device_get_name(sc->sc_dev), + device_get_unit(sc->sc_dev)); + + callout_init(&sc->sc_calib_ch, CALLOUT_MPSAFE); + callout_init(&sc->sc_amrr_ch, CALLOUT_MPSAFE); + + ifp->if_softc = sc; + ifp->if_flags = IFF_BROADCAST | IFF_SIMPLEX | IFF_MULTICAST; + ifp->if_init = bwi_init; + ifp->if_ioctl = bwi_ioctl; + ifp->if_start = bwi_start; + ifp->if_watchdog = bwi_watchdog; + IFQ_SET_MAXLEN(&ifp->if_snd, IFQ_MAXLEN); + ifp->if_snd.ifq_drv_maxlen = IFQ_MAXLEN; + IFQ_SET_READY(&ifp->if_snd); + + /* Get locale */ + sc->sc_locale = __SHIFTOUT(bwi_read_sprom(sc, BWI_SPROM_CARD_INFO), + BWI_SPROM_CARD_INFO_LOCALE); + DPRINTF(sc, "locale: %d\n", sc->sc_locale); + + /* + * Setup ratesets, phytype, channels and get MAC address + */ + bands = 0; + if (phy->phy_mode == IEEE80211_MODE_11B || + phy->phy_mode == IEEE80211_MODE_11G) { + + if (phy->phy_mode == IEEE80211_MODE_11B) { + setbit(&bands, IEEE80211_MODE_11B); + ic->ic_phytype = IEEE80211_T_DS; + } else { + ic->ic_phytype = IEEE80211_T_OFDM; + setbit(&bands, IEEE80211_MODE_11G); + } + + bwi_get_eaddr(sc, BWI_SPROM_11BG_EADDR, ic->ic_myaddr); + if (IEEE80211_IS_MULTICAST(ic->ic_myaddr)) { + bwi_get_eaddr(sc, BWI_SPROM_11A_EADDR, ic->ic_myaddr); + if (IEEE80211_IS_MULTICAST(ic->ic_myaddr)) { + device_printf(sc->sc_dev, + "invalid MAC address: %6D\n", + ic->ic_myaddr, ":"); + } + } + } else if (phy->phy_mode == IEEE80211_MODE_11A) { + /* TODO:11A */ + setbit(&bands, IEEE80211_MODE_11A); + error = ENXIO; + goto fail; + } else { + panic("unknown phymode %d\n", phy->phy_mode); + } + /* XXX use locale */ + ieee80211_init_channels(ic, 0, CTRY_DEFAULT, bands, 0, 1); + + sc->sc_fw_version = BWI_FW_VERSION3; + + ic->ic_ifp = ifp; + ic->ic_caps = IEEE80211_C_SHSLOT | + IEEE80211_C_SHPREAMBLE | + IEEE80211_C_WPA | + IEEE80211_C_MONITOR; + ic->ic_state = IEEE80211_S_INIT; + ic->ic_opmode = IEEE80211_M_STA; + + ic->ic_updateslot = bwi_updateslot; + + ieee80211_ifattach(ic); + + ic->ic_headroom = sizeof(struct bwi_txbuf_hdr); + ic->ic_flags_ext |= IEEE80211_FEXT_SWBMISS; + + /* override default methods */ + sc->sc_newstate = ic->ic_newstate; + ic->ic_newstate = bwi_newstate; + ic->ic_scan_start = bwi_scan_start; + ic->ic_scan_end = bwi_scan_end; + ic->ic_set_channel = bwi_set_channel; + ic->ic_node_alloc = bwi_node_alloc; + ic->ic_newassoc = bwi_newassoc; + /* complete initialization */ + ieee80211_media_init(ic, bwi_media_change, ieee80211_media_status); + ieee80211_amrr_init(&sc->sc_amrr, ic, + IEEE80211_AMRR_MIN_SUCCESS_THRESHOLD, + IEEE80211_AMRR_MAX_SUCCESS_THRESHOLD); + + /* + * Attach radio tap + */ + bpfattach2(ifp, DLT_IEEE802_11_RADIO, + sizeof(struct ieee80211_frame) + sizeof(sc->sc_tx_th), + &sc->sc_drvbpf); + + sc->sc_tx_th_len = roundup(sizeof(sc->sc_tx_th), sizeof(uint32_t)); + sc->sc_tx_th.wt_ihdr.it_len = htole16(sc->sc_tx_th_len); + sc->sc_tx_th.wt_ihdr.it_present = htole32(BWI_TX_RADIOTAP_PRESENT); + + sc->sc_rx_th_len = roundup(sizeof(sc->sc_rx_th), sizeof(uint32_t)); + sc->sc_rx_th.wr_ihdr.it_len = htole16(sc->sc_rx_th_len); + sc->sc_rx_th.wr_ihdr.it_present = htole32(BWI_RX_RADIOTAP_PRESENT); + + if (bootverbose) + ieee80211_announce(ic); + + return (0); +fail: + BWI_LOCK_DESTROY(sc); + return (error); +} + +int +bwi_detach(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ifp; + int i; + + bwi_stop(sc); + callout_stop(&sc->sc_amrr_ch); + ieee80211_ifdetach(&sc->sc_ic); + + for (i = 0; i < sc->sc_nmac; ++i) + bwi_mac_detach(&sc->sc_mac[i]); + bwi_dma_free(sc); + if_free(ifp); + + BWI_LOCK_DESTROY(sc); + + return (0); +} + +void +bwi_suspend(struct bwi_softc *sc) +{ + bwi_stop(sc); +} + +void +bwi_resume(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ifp; + + if (ifp->if_flags & IFF_UP) { + bwi_init(sc); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + bwi_start(ifp); + } +} + +int +bwi_shutdown(struct bwi_softc *sc) +{ + bwi_stop(sc); + return 0; +} + +static void +bwi_power_on(struct bwi_softc *sc, int with_pll) +{ + uint32_t gpio_in, gpio_out, gpio_en; + uint16_t status; + + gpio_in = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_IN, 4); + if (gpio_in & BWI_PCIM_GPIO_PWR_ON) + goto back; + + gpio_out = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, 4); + gpio_en = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, 4); + + gpio_out |= BWI_PCIM_GPIO_PWR_ON; + gpio_en |= BWI_PCIM_GPIO_PWR_ON; + if (with_pll) { + /* Turn off PLL first */ + gpio_out |= BWI_PCIM_GPIO_PLL_PWR_OFF; + gpio_en |= BWI_PCIM_GPIO_PLL_PWR_OFF; + } + + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, gpio_out, 4); + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, gpio_en, 4); + DELAY(1000); + + if (with_pll) { + /* Turn on PLL */ + gpio_out &= ~BWI_PCIM_GPIO_PLL_PWR_OFF; + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, gpio_out, 4); + DELAY(5000); + } + +back: + /* Clear "Signaled Target Abort" */ + status = pci_read_config(sc->sc_dev, PCIR_STATUS, 2); + status &= ~PCIM_STATUS_STABORT; + pci_write_config(sc->sc_dev, PCIR_STATUS, status, 2); +} + +static int +bwi_power_off(struct bwi_softc *sc, int with_pll) +{ + uint32_t gpio_out, gpio_en; + + pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_IN, 4); /* dummy read */ + gpio_out = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, 4); + gpio_en = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, 4); + + gpio_out &= ~BWI_PCIM_GPIO_PWR_ON; + gpio_en |= BWI_PCIM_GPIO_PWR_ON; + if (with_pll) { + gpio_out |= BWI_PCIM_GPIO_PLL_PWR_OFF; + gpio_en |= BWI_PCIM_GPIO_PLL_PWR_OFF; + } + + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, gpio_out, 4); + pci_write_config(sc->sc_dev, BWI_PCIR_GPIO_ENABLE, gpio_en, 4); + return 0; +} + +int +bwi_regwin_switch(struct bwi_softc *sc, struct bwi_regwin *rw, + struct bwi_regwin **old_rw) +{ + int error; + + if (old_rw != NULL) + *old_rw = NULL; + + if (!BWI_REGWIN_EXIST(rw)) + return EINVAL; + + if (sc->sc_cur_regwin != rw) { + error = bwi_regwin_select(sc, rw->rw_id); + if (error) { + device_printf(sc->sc_dev, "can't select regwin %d\n", + rw->rw_id); + return error; + } + } + + if (old_rw != NULL) + *old_rw = sc->sc_cur_regwin; + sc->sc_cur_regwin = rw; + return 0; +} + +static int +bwi_regwin_select(struct bwi_softc *sc, int id) +{ + uint32_t win = BWI_PCIM_REGWIN(id); + int i; + +#define RETRY_MAX 50 + for (i = 0; i < RETRY_MAX; ++i) { + pci_write_config(sc->sc_dev, BWI_PCIR_SEL_REGWIN, win, 4); + if (pci_read_config(sc->sc_dev, BWI_PCIR_SEL_REGWIN, 4) == win) + return 0; + DELAY(10); + } +#undef RETRY_MAX + + return ENXIO; +} + +static void +bwi_regwin_info(struct bwi_softc *sc, uint16_t *type, uint8_t *rev) +{ + uint32_t val; + + val = CSR_READ_4(sc, BWI_ID_HI); + *type = BWI_ID_HI_REGWIN_TYPE(val); + *rev = BWI_ID_HI_REGWIN_REV(val); + + DPRINTF(sc, "regwin: %s (0x%03x), rev %d, vendor 0x%04x\n", + bwi_regwin_name(*type), *type, *rev, __SHIFTOUT(val, BWI_ID_HI_REGWIN_VENDOR_MASK)); +} + +static int +bwi_bbp_attach(struct bwi_softc *sc) +{ +#define N(arr) (int)(sizeof(arr) / sizeof(arr[0])) + uint16_t bbp_id, rw_type; + uint8_t rw_rev; + uint32_t info; + int error, nregwin, i; + + /* + * Get 0th regwin information + * NOTE: 0th regwin should exist + */ + error = bwi_regwin_select(sc, 0); + if (error) { + device_printf(sc->sc_dev, "can't select regwin 0\n"); + return error; + } + bwi_regwin_info(sc, &rw_type, &rw_rev); + + /* + * Find out BBP id + */ + bbp_id = 0; + info = 0; + if (rw_type == BWI_REGWIN_T_CC) { + info = CSR_READ_4(sc, BWI_INFO); + bbp_id = __SHIFTOUT(info, BWI_INFO_BBPID_MASK); + + BWI_CREATE_REGWIN(&sc->sc_com_regwin, 0, rw_type, rw_rev); + + sc->sc_cap = CSR_READ_4(sc, BWI_CAPABILITY); + } else { + for (i = 0; i < N(bwi_bbpid_map); ++i) { + if (sc->sc_pci_did >= bwi_bbpid_map[i].did_min && + sc->sc_pci_did <= bwi_bbpid_map[i].did_max) { + bbp_id = bwi_bbpid_map[i].bbp_id; + break; + } + } + if (bbp_id == 0) { + device_printf(sc->sc_dev, "no BBP id for device id " + "0x%04x\n", sc->sc_pci_did); + return ENXIO; + } + + info = __SHIFTIN(sc->sc_pci_revid, BWI_INFO_BBPREV_MASK) | + __SHIFTIN(0, BWI_INFO_BBPPKG_MASK); + } + + /* + * Find out number of regwins + */ + nregwin = 0; + if (rw_type == BWI_REGWIN_T_CC && rw_rev >= 4) { + nregwin = __SHIFTOUT(info, BWI_INFO_NREGWIN_MASK); + } else { + for (i = 0; i < N(bwi_regwin_count); ++i) { + if (bwi_regwin_count[i].bbp_id == bbp_id) { + nregwin = bwi_regwin_count[i].nregwin; + break; + } + } + if (nregwin == 0) { + device_printf(sc->sc_dev, "no number of win for " + "BBP id 0x%04x\n", bbp_id); + return ENXIO; + } + } + + /* Record BBP id/rev for later using */ + sc->sc_bbp_id = bbp_id; + sc->sc_bbp_rev = __SHIFTOUT(info, BWI_INFO_BBPREV_MASK); + sc->sc_bbp_pkg = __SHIFTOUT(info, BWI_INFO_BBPPKG_MASK); + device_printf(sc->sc_dev, "BBP: id 0x%04x, rev 0x%x, pkg %d\n", + sc->sc_bbp_id, sc->sc_bbp_rev, sc->sc_bbp_pkg); + + DPRINTF(sc, "nregwin %d, cap 0x%08x\n", nregwin, sc->sc_cap); + + /* + * Create rest of the regwins + */ + + /* Don't re-create common regwin, if it is already created */ + i = BWI_REGWIN_EXIST(&sc->sc_com_regwin) ? 1 : 0; + + for (; i < nregwin; ++i) { + /* + * Get regwin information + */ + error = bwi_regwin_select(sc, i); + if (error) { + device_printf(sc->sc_dev, + "can't select regwin %d\n", i); + return error; + } + bwi_regwin_info(sc, &rw_type, &rw_rev); + + /* + * Try attach: + * 1) Bus (PCI/PCIE) regwin + * 2) MAC regwin + * Ignore rest types of regwin + */ + if (rw_type == BWI_REGWIN_T_PCI || + rw_type == BWI_REGWIN_T_PCIE) { + if (BWI_REGWIN_EXIST(&sc->sc_bus_regwin)) { + device_printf(sc->sc_dev, + "bus regwin already exists\n"); + } else { + BWI_CREATE_REGWIN(&sc->sc_bus_regwin, i, + rw_type, rw_rev); + } + } else if (rw_type == BWI_REGWIN_T_D11) { + /* XXX ignore return value */ + bwi_mac_attach(sc, i, rw_rev); + } + } + + /* At least one MAC shold exist */ + if (!BWI_REGWIN_EXIST(&sc->sc_mac[0].mac_regwin)) { + device_printf(sc->sc_dev, "no MAC was found\n"); + return ENXIO; + } + KASSERT(sc->sc_nmac > 0, ("no mac's")); + + /* Bus regwin must exist */ + if (!BWI_REGWIN_EXIST(&sc->sc_bus_regwin)) { + device_printf(sc->sc_dev, "no bus regwin was found\n"); + return ENXIO; + } + + /* Start with first MAC */ + error = bwi_regwin_switch(sc, &sc->sc_mac[0].mac_regwin, NULL); + if (error) + return error; + + return 0; +#undef N +} + +int +bwi_bus_init(struct bwi_softc *sc, struct bwi_mac *mac) +{ + struct bwi_regwin *old, *bus; + uint32_t val; + int error; + + bus = &sc->sc_bus_regwin; + KASSERT(sc->sc_cur_regwin == &mac->mac_regwin, ("not cur regwin")); + + /* + * Tell bus to generate requested interrupts + */ + if (bus->rw_rev < 6 && bus->rw_type == BWI_REGWIN_T_PCI) { + /* + * NOTE: Read BWI_FLAGS from MAC regwin + */ + val = CSR_READ_4(sc, BWI_FLAGS); + + error = bwi_regwin_switch(sc, bus, &old); + if (error) + return error; + + CSR_SETBITS_4(sc, BWI_INTRVEC, (val & BWI_FLAGS_INTR_MASK)); + } else { + uint32_t mac_mask; + + mac_mask = 1 << mac->mac_id; + + error = bwi_regwin_switch(sc, bus, &old); + if (error) + return error; + + val = pci_read_config(sc->sc_dev, BWI_PCIR_INTCTL, 4); + val |= mac_mask << 8; + pci_write_config(sc->sc_dev, BWI_PCIR_INTCTL, val, 4); + } + + if (sc->sc_flags & BWI_F_BUS_INITED) + goto back; + + if (bus->rw_type == BWI_REGWIN_T_PCI) { + /* + * Enable prefetch and burst + */ + CSR_SETBITS_4(sc, BWI_BUS_CONFIG, + BWI_BUS_CONFIG_PREFETCH | BWI_BUS_CONFIG_BURST); + + if (bus->rw_rev < 5) { + struct bwi_regwin *com = &sc->sc_com_regwin; + + /* + * Configure timeouts for bus operation + */ + + /* + * Set service timeout and request timeout + */ + CSR_SETBITS_4(sc, BWI_CONF_LO, + __SHIFTIN(BWI_CONF_LO_SERVTO, BWI_CONF_LO_SERVTO_MASK) | + __SHIFTIN(BWI_CONF_LO_REQTO, BWI_CONF_LO_REQTO_MASK)); + + /* + * If there is common regwin, we switch to that regwin + * and switch back to bus regwin once we have done. + */ + if (BWI_REGWIN_EXIST(com)) { + error = bwi_regwin_switch(sc, com, NULL); + if (error) + return error; + } + + /* Let bus know what we have changed */ + CSR_WRITE_4(sc, BWI_BUS_ADDR, BWI_BUS_ADDR_MAGIC); + CSR_READ_4(sc, BWI_BUS_ADDR); /* Flush */ + CSR_WRITE_4(sc, BWI_BUS_DATA, 0); + CSR_READ_4(sc, BWI_BUS_DATA); /* Flush */ + + if (BWI_REGWIN_EXIST(com)) { + error = bwi_regwin_switch(sc, bus, NULL); + if (error) + return error; + } + } else if (bus->rw_rev >= 11) { + /* + * Enable memory read multiple + */ + CSR_SETBITS_4(sc, BWI_BUS_CONFIG, BWI_BUS_CONFIG_MRM); + } + } else { + /* TODO:PCIE */ + } + + sc->sc_flags |= BWI_F_BUS_INITED; +back: + return bwi_regwin_switch(sc, old, NULL); +} + +static void +bwi_get_card_flags(struct bwi_softc *sc) +{ +#define PCI_VENDOR_APPLE 0x106b +#define PCI_VENDOR_DELL 0x1028 + sc->sc_card_flags = bwi_read_sprom(sc, BWI_SPROM_CARD_FLAGS); + if (sc->sc_card_flags == 0xffff) + sc->sc_card_flags = 0; + + if (sc->sc_pci_subvid == PCI_VENDOR_DELL && + sc->sc_bbp_id == BWI_BBPID_BCM4301 && + sc->sc_pci_revid == 0x74) + sc->sc_card_flags |= BWI_CARD_F_BT_COEXIST; + + if (sc->sc_pci_subvid == PCI_VENDOR_APPLE && + sc->sc_pci_subdid == 0x4e && /* XXX */ + sc->sc_pci_revid > 0x40) + sc->sc_card_flags |= BWI_CARD_F_PA_GPIO9; + + DPRINTF(sc, "card flags 0x%04x\n", sc->sc_card_flags); +#undef PCI_VENDOR_DELL +#undef PCI_VENDOR_APPLE +} + +static void +bwi_get_eaddr(struct bwi_softc *sc, uint16_t eaddr_ofs, uint8_t *eaddr) +{ + int i; + + for (i = 0; i < 3; ++i) { + *((uint16_t *)eaddr + i) = + htobe16(bwi_read_sprom(sc, eaddr_ofs + 2 * i)); + } +} + +static void +bwi_get_clock_freq(struct bwi_softc *sc, struct bwi_clock_freq *freq) +{ + struct bwi_regwin *com; + uint32_t val; + u_int div; + int src; + + bzero(freq, sizeof(*freq)); + com = &sc->sc_com_regwin; + + KASSERT(BWI_REGWIN_EXIST(com), ("regwin does not exist")); + KASSERT(sc->sc_cur_regwin == com, ("wrong regwin")); + KASSERT(sc->sc_cap & BWI_CAP_CLKMODE, ("wrong clock mode")); + + /* + * Calculate clock frequency + */ + src = -1; + div = 0; + if (com->rw_rev < 6) { + val = pci_read_config(sc->sc_dev, BWI_PCIR_GPIO_OUT, 4); + if (val & BWI_PCIM_GPIO_OUT_CLKSRC) { + src = BWI_CLKSRC_PCI; + div = 64; + } else { + src = BWI_CLKSRC_CS_OSC; + div = 32; + } + } else if (com->rw_rev < 10) { + val = CSR_READ_4(sc, BWI_CLOCK_CTRL); + + src = __SHIFTOUT(val, BWI_CLOCK_CTRL_CLKSRC); + if (src == BWI_CLKSRC_LP_OSC) { + div = 1; + } else { + div = (__SHIFTOUT(val, BWI_CLOCK_CTRL_FDIV) + 1) << 2; + + /* Unknown source */ + if (src >= BWI_CLKSRC_MAX) + src = BWI_CLKSRC_CS_OSC; + } + } else { + val = CSR_READ_4(sc, BWI_CLOCK_INFO); + + src = BWI_CLKSRC_CS_OSC; + div = (__SHIFTOUT(val, BWI_CLOCK_INFO_FDIV) + 1) << 2; + } + + KASSERT(src >= 0 && src < BWI_CLKSRC_MAX, ("bad src %d", src)); + KASSERT(div != 0, ("div zero")); + + DPRINTF(sc, "clksrc %s\n", + src == BWI_CLKSRC_PCI ? "PCI" : + (src == BWI_CLKSRC_LP_OSC ? "LP_OSC" : "CS_OSC")); + + freq->clkfreq_min = bwi_clkfreq[src].freq_min / div; + freq->clkfreq_max = bwi_clkfreq[src].freq_max / div; + + DPRINTF(sc, "clkfreq min %u, max %u\n", + freq->clkfreq_min, freq->clkfreq_max); +} + +static int +bwi_set_clock_mode(struct bwi_softc *sc, enum bwi_clock_mode clk_mode) +{ + struct bwi_regwin *old, *com; + uint32_t clk_ctrl, clk_src; + int error, pwr_off = 0; + + com = &sc->sc_com_regwin; + if (!BWI_REGWIN_EXIST(com)) + return 0; + + if (com->rw_rev >= 10 || com->rw_rev < 6) + return 0; + + /* + * For common regwin whose rev is [6, 10), the chip + * must be capable to change clock mode. + */ + if ((sc->sc_cap & BWI_CAP_CLKMODE) == 0) + return 0; + + error = bwi_regwin_switch(sc, com, &old); + if (error) + return error; + + if (clk_mode == BWI_CLOCK_MODE_FAST) + bwi_power_on(sc, 0); /* Don't turn on PLL */ + + clk_ctrl = CSR_READ_4(sc, BWI_CLOCK_CTRL); + clk_src = __SHIFTOUT(clk_ctrl, BWI_CLOCK_CTRL_CLKSRC); + + switch (clk_mode) { + case BWI_CLOCK_MODE_FAST: + clk_ctrl &= ~BWI_CLOCK_CTRL_SLOW; + clk_ctrl |= BWI_CLOCK_CTRL_IGNPLL; + break; + case BWI_CLOCK_MODE_SLOW: + clk_ctrl |= BWI_CLOCK_CTRL_SLOW; + break; + case BWI_CLOCK_MODE_DYN: + clk_ctrl &= ~(BWI_CLOCK_CTRL_SLOW | + BWI_CLOCK_CTRL_IGNPLL | + BWI_CLOCK_CTRL_NODYN); + if (clk_src != BWI_CLKSRC_CS_OSC) { + clk_ctrl |= BWI_CLOCK_CTRL_NODYN; + pwr_off = 1; + } + break; + } + CSR_WRITE_4(sc, BWI_CLOCK_CTRL, clk_ctrl); + + if (pwr_off) + bwi_power_off(sc, 0); /* Leave PLL as it is */ + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_set_clock_delay(struct bwi_softc *sc) +{ + struct bwi_regwin *old, *com; + int error; + + com = &sc->sc_com_regwin; + if (!BWI_REGWIN_EXIST(com)) + return 0; + + error = bwi_regwin_switch(sc, com, &old); + if (error) + return error; + + if (sc->sc_bbp_id == BWI_BBPID_BCM4321) { + if (sc->sc_bbp_rev == 0) + CSR_WRITE_4(sc, BWI_CONTROL, BWI_CONTROL_MAGIC0); + else if (sc->sc_bbp_rev == 1) + CSR_WRITE_4(sc, BWI_CONTROL, BWI_CONTROL_MAGIC1); + } + + if (sc->sc_cap & BWI_CAP_CLKMODE) { + if (com->rw_rev >= 10) { + CSR_FILT_SETBITS_4(sc, BWI_CLOCK_INFO, 0xffff, 0x40000); + } else { + struct bwi_clock_freq freq; + + bwi_get_clock_freq(sc, &freq); + CSR_WRITE_4(sc, BWI_PLL_ON_DELAY, + howmany(freq.clkfreq_max * 150, 1000000)); + CSR_WRITE_4(sc, BWI_FREQ_SEL_DELAY, + howmany(freq.clkfreq_max * 15, 1000000)); + } + } + + return bwi_regwin_switch(sc, old, NULL); +} + +static void +bwi_init(void *xsc) +{ + struct bwi_softc *sc = xsc; + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp = ic->ic_ifp; + struct bwi_mac *mac; + int error; + + BWI_LOCK(sc); + + DPRINTF(sc, "%s\n", __func__); + + bwi_stop(sc); + + bwi_bbp_power_on(sc, BWI_CLOCK_MODE_FAST); + + /* TODO: 2 MAC */ + + mac = &sc->sc_mac[0]; + error = bwi_regwin_switch(sc, &mac->mac_regwin, NULL); + if (error) + goto back; + + error = bwi_mac_init(mac); + if (error) + goto back; + + bwi_bbp_power_on(sc, BWI_CLOCK_MODE_DYN); + + bcopy(IF_LLADDR(ifp), ic->ic_myaddr, sizeof(ic->ic_myaddr)); + + bwi_set_bssid(sc, bwi_zero_addr); /* Clear BSSID */ + bwi_set_addr_filter(sc, BWI_ADDR_FILTER_MYADDR, ic->ic_myaddr); + + bwi_mac_reset_hwkeys(mac); + + if ((mac->mac_flags & BWI_MAC_F_HAS_TXSTATS) == 0) { + int i; + +#define NRETRY 1000 + /* + * Drain any possible pending TX status + */ + for (i = 0; i < NRETRY; ++i) { + if ((CSR_READ_4(sc, BWI_TXSTATUS0) & + BWI_TXSTATUS0_VALID) == 0) + break; + CSR_READ_4(sc, BWI_TXSTATUS1); + } + if (i == NRETRY) + if_printf(ifp, "can't drain TX status\n"); +#undef NRETRY + } + + if (mac->mac_phy.phy_mode == IEEE80211_MODE_11G) + bwi_mac_updateslot(mac, 1); + + /* Start MAC */ + error = bwi_mac_start(mac); + if (error) + goto back; + + /* Enable intrs */ + bwi_enable_intrs(sc, BWI_INIT_INTRS); + + ifp->if_drv_flags |= IFF_DRV_RUNNING; + ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; + + if (ic->ic_opmode != IEEE80211_M_MONITOR) { + if (ic->ic_roaming != IEEE80211_ROAMING_MANUAL) + ieee80211_new_state(ic, IEEE80211_S_SCAN, -1); + } else { + ieee80211_new_state(ic, IEEE80211_S_RUN, -1); + } +back: + if (error) + bwi_stop(sc); + BWI_UNLOCK(sc); +} + +static int +bwi_ioctl(struct ifnet *ifp, u_long cmd, caddr_t req) +{ +#define IS_RUNNING(ifp) \ + ((ifp->if_flags & IFF_UP) && (ifp->if_drv_flags & IFF_DRV_RUNNING)) + struct bwi_softc *sc = ifp->if_softc; + int error = 0; + + BWI_LOCK(sc); + + switch (cmd) { + case SIOCSIFFLAGS: + if (IS_RUNNING(ifp)) { + struct bwi_mac *mac; + int promisc = -1; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", + sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + if ((ifp->if_flags & IFF_PROMISC) && + (sc->sc_flags & BWI_F_PROMISC) == 0) { + promisc = 1; + sc->sc_flags |= BWI_F_PROMISC; + } else if ((ifp->if_flags & IFF_PROMISC) == 0 && + (sc->sc_flags & BWI_F_PROMISC)) { + promisc = 0; + sc->sc_flags &= ~BWI_F_PROMISC; + } + + if (promisc >= 0) + bwi_mac_set_promisc(mac, promisc); + } + + if (ifp->if_flags & IFF_UP) { + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + bwi_init(sc); + } else { + if (ifp->if_drv_flags & IFF_DRV_RUNNING) + bwi_stop(sc); + } + break; + default: + error = ieee80211_ioctl(&sc->sc_ic, cmd, req); + break; + } + + if (error == ENETRESET) { + if (IS_RUNNING(ifp)) + bwi_init(sc); + error = 0; + } + BWI_UNLOCK(sc); + + return error; +#undef IS_RUNNING +} + +static void +bwi_start(struct ifnet *ifp) +{ + struct bwi_softc *sc = ifp->if_softc; + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[BWI_TX_DATA_RING]; + struct ieee80211_frame *wh; + struct ieee80211_node *ni; + struct ether_header *eh; + struct ieee80211_key *k; + struct mbuf *m; + int trans, idx; + + BWI_LOCK(sc); + if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) || + (ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + BWI_UNLOCK(sc); + return; + } + + trans = 0; + idx = tbd->tbd_idx; + + while (tbd->tbd_buf[idx].tb_mbuf == NULL) { + IF_DEQUEUE(&ic->ic_mgtq, m); + if (m != NULL) { + ni = (struct ieee80211_node *)m->m_pkthdr.rcvif; + m->m_pkthdr.rcvif = NULL; + } else { + if (ic->ic_state != IEEE80211_S_RUN) + break; + + IFQ_DRV_DEQUEUE(&ifp->if_snd, m); /* XXX: LOCK */ + if (m == NULL) + break; + + if (m->m_len < sizeof(*eh)) { + m = m_pullup(m, sizeof(*eh)); + if (m == NULL) { + ifp->if_oerrors++; + continue; + } + } + eh = mtod(m, struct ether_header *); + + ni = ieee80211_find_txnode(ic, eh->ether_dhost); + if (ni == NULL) { + m_freem(m); + ifp->if_oerrors++; + continue; + } + + /* TODO: PS */ + + BPF_MTAP(ifp, m); + + m = ieee80211_encap(ic, m, ni); + if (m == NULL) { + ieee80211_free_node(ni); + ifp->if_oerrors++; + continue; + } + } + + if (ic->ic_rawbpf != NULL) + bpf_mtap(ic->ic_rawbpf, m); + + wh = mtod(m, struct ieee80211_frame *); + if (wh->i_fc[1] & IEEE80211_FC1_WEP) { + k = ieee80211_crypto_encap(ic, ni, m); + if (k == NULL) { + ieee80211_free_node(ni); + m_freem(m); + ifp->if_oerrors++; + continue; + } + } + wh = NULL; /* Catch any invalid use */ + + if (bwi_encap(sc, idx, m, ni) != 0) { + /* 'm' is freed in bwi_encap() if we reach here */ + if (ni != NULL) + ieee80211_free_node(ni); + ifp->if_oerrors++; + continue; + } + + trans = 1; + tbd->tbd_used++; + idx = (idx + 1) % BWI_TX_NDESC; + + if (tbd->tbd_used + BWI_TX_NSPRDESC >= BWI_TX_NDESC) { + ifp->if_drv_flags |= IFF_DRV_OACTIVE; + break; + } + } + tbd->tbd_idx = idx; + + if (trans) + sc->sc_tx_timer = 5; + ifp->if_timer = 1; + BWI_UNLOCK(sc); +} + +static void +bwi_watchdog(struct ifnet *ifp) +{ + struct bwi_softc *sc = ifp->if_softc; + + BWI_LOCK(sc); + ifp->if_timer = 0; + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) && sc->sc_tx_timer) { + if (--sc->sc_tx_timer == 0) { + if_printf(ifp, "watchdog timeout\n"); + ifp->if_oerrors++; + /* TODO */ + } else { + ifp->if_timer = 1; + } + } + BWI_UNLOCK(sc); +} + +static void +bwi_stop(struct bwi_softc *sc) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp = ic->ic_ifp; + struct bwi_mac *mac; + int i, error, pwr_off = 0; + + BWI_LOCK(sc); + + DPRINTF(sc, "%s\n", __func__); + + ieee80211_new_state(ic, IEEE80211_S_INIT, -1); + + if (ifp->if_drv_flags & IFF_DRV_RUNNING) { + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + bwi_disable_intrs(sc, BWI_ALL_INTRS); + CSR_READ_4(sc, BWI_MAC_INTR_MASK); + bwi_mac_stop(mac); + } + + for (i = 0; i < sc->sc_nmac; ++i) { + struct bwi_regwin *old_rw; + + mac = &sc->sc_mac[i]; + if ((mac->mac_flags & BWI_MAC_F_INITED) == 0) + continue; + + error = bwi_regwin_switch(sc, &mac->mac_regwin, &old_rw); + if (error) + continue; + + bwi_mac_shutdown(mac); + pwr_off = 1; + + bwi_regwin_switch(sc, old_rw, NULL); + } + + if (pwr_off) + bwi_bbp_power_off(sc); + + sc->sc_tx_timer = 0; + ifp->if_timer = 0; + ifp->if_drv_flags &= ~(IFF_DRV_RUNNING | IFF_DRV_OACTIVE); + BWI_UNLOCK(sc); +} + +void +bwi_intr(void *xsc) +{ + struct bwi_softc *sc = xsc; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + uint32_t intr_status; + uint32_t txrx_intr_status[BWI_TXRX_NRING]; + int i, txrx_error; + + BWI_LOCK(sc); + + if ((ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) { + BWI_UNLOCK(sc); + return; + } + /* + * Get interrupt status + */ + intr_status = CSR_READ_4(sc, BWI_MAC_INTR_STATUS); + if (intr_status == 0xffffffff) { /* Not for us */ + BWI_UNLOCK(sc); + return; + } + +#if 0 + if_printf(ifp, "intr status 0x%08x\n", intr_status); +#endif + + intr_status &= CSR_READ_4(sc, BWI_MAC_INTR_MASK); + if (intr_status == 0) { /* Nothing is interesting */ + BWI_UNLOCK(sc); + return; + } + + txrx_error = 0; +#if 0 + if_printf(ifp, "TX/RX intr"); +#endif + for (i = 0; i < BWI_TXRX_NRING; ++i) { + uint32_t mask; + + if (BWI_TXRX_IS_RX(i)) + mask = BWI_TXRX_RX_INTRS; + else + mask = BWI_TXRX_TX_INTRS; + + txrx_intr_status[i] = + CSR_READ_4(sc, BWI_TXRX_INTR_STATUS(i)) & mask; + +#if 0 + printf(", %d 0x%08x", i, txrx_intr_status[i]); +#endif + + if (txrx_intr_status[i] & BWI_TXRX_INTR_ERROR) { + if_printf(ifp, "intr fatal TX/RX (%d) error 0x%08x\n", + i, txrx_intr_status[i]); + txrx_error = 1; + } + } +#if 0 + printf("\n"); +#endif + + /* + * Acknowledge interrupt + */ + CSR_WRITE_4(sc, BWI_MAC_INTR_STATUS, intr_status); + + for (i = 0; i < BWI_TXRX_NRING; ++i) + CSR_WRITE_4(sc, BWI_TXRX_INTR_STATUS(i), txrx_intr_status[i]); + + /* Disable all interrupts */ + bwi_disable_intrs(sc, BWI_ALL_INTRS); + + if (intr_status & BWI_INTR_PHY_TXERR) + if_printf(ifp, "intr PHY TX error\n"); + + if (txrx_error) { + /* TODO: reset device */ + } + + if (intr_status & BWI_INTR_TBTT) { + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + bwi_mac_config_ps((struct bwi_mac *)sc->sc_cur_regwin); + } + + if (intr_status & BWI_INTR_EO_ATIM) + if_printf(ifp, "EO_ATIM\n"); + + if (intr_status & BWI_INTR_PMQ) { + for (;;) { + if ((CSR_READ_4(sc, BWI_MAC_PS_STATUS) & 0x8) == 0) + break; + } + CSR_WRITE_2(sc, BWI_MAC_PS_STATUS, 0x2); + } + + if (intr_status & BWI_INTR_NOISE) + if_printf(ifp, "intr noise\n"); + + if (txrx_intr_status[0] & BWI_TXRX_INTR_RX) + sc->sc_rxeof(sc); + + if (txrx_intr_status[3] & BWI_TXRX_INTR_RX) + sc->sc_txeof_status(sc); + + if (intr_status & BWI_INTR_TX_DONE) + bwi_txeof(sc); + + /* TODO:LED */ + + /* Re-enable interrupts */ + bwi_enable_intrs(sc, BWI_INIT_INTRS); + BWI_UNLOCK(sc); +} + +static void +bwi_scan_start(struct ieee80211com *ic) +{ +} + +static void +bwi_set_channel(struct ieee80211com *ic) +{ + struct ifnet *ifp = ic->ic_ifp; + struct bwi_softc *sc = ifp->if_softc; + int error; + + BWI_LOCK(sc); + error = bwi_set_chan(sc, ic->ic_curchan); + if (error) + if_printf(ifp, "can't set channel to %u\n", + ieee80211_chan2ieee(ic, ic->ic_curchan)); + BWI_UNLOCK(sc); +} + +static void +bwi_scan_end(struct ieee80211com *ic) +{ +} + +static int +bwi_newstate(struct ieee80211com *ic, enum ieee80211_state nstate, int arg) +{ + struct ifnet *ifp = ic->ic_ifp; + struct bwi_softc *sc = ifp->if_softc; + struct bwi_mac *mac; + struct ieee80211_node *ni; + int error; + + BWI_LOCK(sc); + + callout_stop(&sc->sc_calib_ch); + callout_stop(&sc->sc_amrr_ch); + + bwi_led_newstate(sc, nstate); + + if (nstate == IEEE80211_S_INIT) + goto back; + + if (ic->ic_opmode == IEEE80211_M_MONITOR) { + /* Nothing to do */ + } else if (nstate == IEEE80211_S_RUN) { + ni = ic->ic_bss; + + bwi_set_bssid(sc, ic->ic_bss->ni_bssid); + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + /* Initial TX power calibration */ + bwi_mac_calibrate_txpower(mac); + + if (ic->ic_opmode == IEEE80211_M_STA) { + /* fake a join to init the tx rate */ + bwi_newassoc(ni, 1); + } + + if (ic->ic_opmode != IEEE80211_M_MONITOR) { + /* start automatic rate control timer */ + if (ic->ic_fixed_rate == IEEE80211_FIXED_RATE_NONE) + callout_reset(&sc->sc_amrr_ch, hz / 2, + bwi_amrr_timeout, sc); + } + } else { + bwi_set_bssid(sc, bwi_zero_addr); + } + +back: + error = sc->sc_newstate(ic, nstate, arg); + + if (nstate == IEEE80211_S_RUN) { + /* XXX 15 seconds */ + callout_reset(&sc->sc_calib_ch, hz * 15, bwi_calibrate, sc); + } + BWI_UNLOCK(sc); + + return error; +} + +/* ARGUSED */ +static struct ieee80211_node * +bwi_node_alloc(struct ieee80211_node_table *nt __unused) +{ + struct bwi_node *bn; + + bn = malloc(sizeof(struct bwi_node), M_80211_NODE, M_NOWAIT | M_ZERO); + return bn != NULL ? &bn->ni : NULL; +} + +static void +bwi_newassoc(struct ieee80211_node *ni, int isnew) +{ + struct bwi_softc *sc = ni->ni_ic->ic_ifp->if_softc; + int i; + + ieee80211_amrr_node_init(&sc->sc_amrr, &((struct bwi_node *)ni)->amn); + + /* set rate to some reasonable initial value */ + for (i = ni->ni_rates.rs_nrates - 1; + i > 0 && (ni->ni_rates.rs_rates[i] & IEEE80211_RATE_VAL) > 72; + i--); + ni->ni_txrate = i; +} + +static void +bwi_iter_func(void *arg, struct ieee80211_node *ni) +{ + struct bwi_softc *sc = arg; + struct bwi_node *bn = (struct bwi_node *)ni; + + ieee80211_amrr_choose(&sc->sc_amrr, ni, &bn->amn); +} + +static void +bwi_amrr_timeout(void *arg) +{ + struct bwi_softc *sc = arg; + struct ieee80211com *ic = &sc->sc_ic; + + BWI_LOCK(sc); + if (ic->ic_opmode == IEEE80211_M_STA) + bwi_iter_func(sc, ic->ic_bss); + else + ieee80211_iterate_nodes(&ic->ic_sta, bwi_iter_func, sc); + BWI_UNLOCK(sc); + + callout_reset(&sc->sc_amrr_ch, hz / 2, bwi_amrr_timeout, sc); +} + +static int +bwi_media_change(struct ifnet *ifp) +{ +#define IS_RUNNING(ifp) \ + ((ifp->if_flags & IFF_UP) && (ifp->if_drv_flags & IFF_DRV_RUNNING)) + struct bwi_softc *sc = ifp->if_softc; + + BWI_LOCK(sc); + if (ieee80211_media_change(ifp) == ENETRESET && IS_RUNNING(ifp)) + bwi_init(ifp->if_softc); + BWI_UNLOCK(sc); + + return 0; +#undef IS_RUNNING +} + +static int +bwi_dma_alloc(struct bwi_softc *sc) +{ + int error, i, has_txstats; + bus_addr_t lowaddr = 0; + bus_size_t tx_ring_sz, rx_ring_sz, desc_sz = 0; + uint32_t txrx_ctrl_step = 0; + + has_txstats = 0; + for (i = 0; i < sc->sc_nmac; ++i) { + if (sc->sc_mac[i].mac_flags & BWI_MAC_F_HAS_TXSTATS) { + has_txstats = 1; + break; + } + } + + switch (sc->sc_bus_space) { + case BWI_BUS_SPACE_30BIT: + case BWI_BUS_SPACE_32BIT: + if (sc->sc_bus_space == BWI_BUS_SPACE_30BIT) + lowaddr = BWI_BUS_SPACE_MAXADDR; + else + lowaddr = BUS_SPACE_MAXADDR_32BIT; + desc_sz = sizeof(struct bwi_desc32); + txrx_ctrl_step = 0x20; + + sc->sc_init_tx_ring = bwi_init_tx_ring32; + sc->sc_free_tx_ring = bwi_free_tx_ring32; + sc->sc_init_rx_ring = bwi_init_rx_ring32; + sc->sc_free_rx_ring = bwi_free_rx_ring32; + sc->sc_setup_rxdesc = bwi_setup_rx_desc32; + sc->sc_setup_txdesc = bwi_setup_tx_desc32; + sc->sc_rxeof = bwi_rxeof32; + sc->sc_start_tx = bwi_start_tx32; + if (has_txstats) { + sc->sc_init_txstats = bwi_init_txstats32; + sc->sc_free_txstats = bwi_free_txstats32; + sc->sc_txeof_status = bwi_txeof_status32; + } + break; + + case BWI_BUS_SPACE_64BIT: + lowaddr = BUS_SPACE_MAXADDR; /* XXX */ + desc_sz = sizeof(struct bwi_desc64); + txrx_ctrl_step = 0x40; + + sc->sc_init_tx_ring = bwi_init_tx_ring64; + sc->sc_free_tx_ring = bwi_free_tx_ring64; + sc->sc_init_rx_ring = bwi_init_rx_ring64; + sc->sc_free_rx_ring = bwi_free_rx_ring64; + sc->sc_setup_rxdesc = bwi_setup_rx_desc64; + sc->sc_setup_txdesc = bwi_setup_tx_desc64; + sc->sc_rxeof = bwi_rxeof64; + sc->sc_start_tx = bwi_start_tx64; + if (has_txstats) { + sc->sc_init_txstats = bwi_init_txstats64; + sc->sc_free_txstats = bwi_free_txstats64; + sc->sc_txeof_status = bwi_txeof_status64; + } + break; + } + + KASSERT(lowaddr != 0, ("lowaddr zero")); + KASSERT(desc_sz != 0, ("desc_sz zero")); + KASSERT(txrx_ctrl_step != 0, ("txrx_ctrl_step zero")); + + tx_ring_sz = roundup(desc_sz * BWI_TX_NDESC, BWI_RING_ALIGN); + rx_ring_sz = roundup(desc_sz * BWI_RX_NDESC, BWI_RING_ALIGN); + + /* + * Create top level DMA tag + */ + error = bus_dma_tag_create(bus_get_dma_tag(sc->sc_dev), /* parent */ + BWI_ALIGN, 0, /* alignment, bounds */ + lowaddr, /* lowaddr */ + BUS_SPACE_MAXADDR, /* highaddr */ + NULL, NULL, /* filter, filterarg */ + MAXBSIZE, /* maxsize */ + BUS_SPACE_UNRESTRICTED, /* nsegments */ + BUS_SPACE_MAXSIZE_32BIT, /* maxsegsize */ + BUS_DMA_ALLOCNOW, /* flags */ + NULL, NULL, /* lockfunc, lockarg */ + &sc->sc_parent_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create parent DMA tag\n"); + return error; + } + +#define TXRX_CTRL(idx) (BWI_TXRX_CTRL_BASE + (idx) * txrx_ctrl_step) + + /* + * Create TX ring DMA stuffs + */ + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_RING_ALIGN, 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + tx_ring_sz, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &sc->sc_txring_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create TX ring DMA tag\n"); + return error; + } + + for (i = 0; i < BWI_TX_NRING; ++i) { + error = bwi_dma_ring_alloc(sc, sc->sc_txring_dtag, + &sc->sc_tx_rdata[i], tx_ring_sz, + TXRX_CTRL(i)); + if (error) { + device_printf(sc->sc_dev, "%dth TX ring " + "DMA alloc failed\n", i); + return error; + } + } + + /* + * Create RX ring DMA stuffs + */ + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_RING_ALIGN, 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + rx_ring_sz, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &sc->sc_rxring_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create RX ring DMA tag\n"); + return error; + } + + error = bwi_dma_ring_alloc(sc, sc->sc_rxring_dtag, &sc->sc_rx_rdata, + rx_ring_sz, TXRX_CTRL(0)); + if (error) { + device_printf(sc->sc_dev, "RX ring DMA alloc failed\n"); + return error; + } + + if (has_txstats) { + error = bwi_dma_txstats_alloc(sc, TXRX_CTRL(3), desc_sz); + if (error) { + device_printf(sc->sc_dev, + "TX stats DMA alloc failed\n"); + return error; + } + } + +#undef TXRX_CTRL + + return bwi_dma_mbuf_create(sc); +} + +static void +bwi_dma_free(struct bwi_softc *sc) +{ + if (sc->sc_txring_dtag != NULL) { + int i; + + for (i = 0; i < BWI_TX_NRING; ++i) { + struct bwi_ring_data *rd = &sc->sc_tx_rdata[i]; + + if (rd->rdata_desc != NULL) { + bus_dmamap_unload(sc->sc_txring_dtag, + rd->rdata_dmap); + bus_dmamem_free(sc->sc_txring_dtag, + rd->rdata_desc, + rd->rdata_dmap); + } + } + bus_dma_tag_destroy(sc->sc_txring_dtag); + } + + if (sc->sc_rxring_dtag != NULL) { + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + + if (rd->rdata_desc != NULL) { + bus_dmamap_unload(sc->sc_rxring_dtag, rd->rdata_dmap); + bus_dmamem_free(sc->sc_rxring_dtag, rd->rdata_desc, + rd->rdata_dmap); + } + bus_dma_tag_destroy(sc->sc_rxring_dtag); + } + + bwi_dma_txstats_free(sc); + bwi_dma_mbuf_destroy(sc, BWI_TX_NRING, 1); + + if (sc->sc_parent_dtag != NULL) + bus_dma_tag_destroy(sc->sc_parent_dtag); +} + +static int +bwi_dma_ring_alloc(struct bwi_softc *sc, bus_dma_tag_t dtag, + struct bwi_ring_data *rd, bus_size_t size, + uint32_t txrx_ctrl) +{ + int error; + + error = bus_dmamem_alloc(dtag, &rd->rdata_desc, + BUS_DMA_WAITOK | BUS_DMA_ZERO, + &rd->rdata_dmap); + if (error) { + device_printf(sc->sc_dev, "can't allocate DMA mem\n"); + return error; + } + + error = bus_dmamap_load(dtag, rd->rdata_dmap, rd->rdata_desc, size, + bwi_dma_ring_addr, &rd->rdata_paddr, + BUS_DMA_WAITOK); + if (error) { + device_printf(sc->sc_dev, "can't load DMA mem\n"); + bus_dmamem_free(dtag, rd->rdata_desc, rd->rdata_dmap); + rd->rdata_desc = NULL; + return error; + } + + rd->rdata_txrx_ctrl = txrx_ctrl; + return 0; +} + +static int +bwi_dma_txstats_alloc(struct bwi_softc *sc, uint32_t ctrl_base, + bus_size_t desc_sz) +{ + struct bwi_txstats_data *st; + bus_size_t dma_size; + int error; + + st = malloc(sizeof(*st), M_DEVBUF, M_WAITOK | M_ZERO); + sc->sc_txstats = st; + + /* + * Create TX stats descriptor DMA stuffs + */ + dma_size = roundup(desc_sz * BWI_TXSTATS_NDESC, BWI_RING_ALIGN); + + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_RING_ALIGN, + 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + dma_size, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &st->stats_ring_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create txstats ring " + "DMA tag\n"); + return error; + } + + error = bus_dmamem_alloc(st->stats_ring_dtag, &st->stats_ring, + BUS_DMA_WAITOK | BUS_DMA_ZERO, + &st->stats_ring_dmap); + if (error) { + device_printf(sc->sc_dev, "can't allocate txstats ring " + "DMA mem\n"); + bus_dma_tag_destroy(st->stats_ring_dtag); + st->stats_ring_dtag = NULL; + return error; + } + + error = bus_dmamap_load(st->stats_ring_dtag, st->stats_ring_dmap, + st->stats_ring, dma_size, + bwi_dma_ring_addr, &st->stats_ring_paddr, + BUS_DMA_WAITOK); + if (error) { + device_printf(sc->sc_dev, "can't load txstats ring DMA mem\n"); + bus_dmamem_free(st->stats_ring_dtag, st->stats_ring, + st->stats_ring_dmap); + bus_dma_tag_destroy(st->stats_ring_dtag); + st->stats_ring_dtag = NULL; + return error; + } + + /* + * Create TX stats DMA stuffs + */ + dma_size = roundup(sizeof(struct bwi_txstats) * BWI_TXSTATS_NDESC, + BWI_ALIGN); + + error = bus_dma_tag_create(sc->sc_parent_dtag, + BWI_ALIGN, + 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + dma_size, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &st->stats_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create txstats DMA tag\n"); + return error; + } + + error = bus_dmamem_alloc(st->stats_dtag, (void **)&st->stats, + BUS_DMA_WAITOK | BUS_DMA_ZERO, + &st->stats_dmap); + if (error) { + device_printf(sc->sc_dev, "can't allocate txstats DMA mem\n"); + bus_dma_tag_destroy(st->stats_dtag); + st->stats_dtag = NULL; + return error; + } + + error = bus_dmamap_load(st->stats_dtag, st->stats_dmap, st->stats, + dma_size, bwi_dma_ring_addr, &st->stats_paddr, + BUS_DMA_WAITOK); + if (error) { + device_printf(sc->sc_dev, "can't load txstats DMA mem\n"); + bus_dmamem_free(st->stats_dtag, st->stats, st->stats_dmap); + bus_dma_tag_destroy(st->stats_dtag); + st->stats_dtag = NULL; + return error; + } + + st->stats_ctrl_base = ctrl_base; + return 0; +} + +static void +bwi_dma_txstats_free(struct bwi_softc *sc) +{ + struct bwi_txstats_data *st; + + if (sc->sc_txstats == NULL) + return; + st = sc->sc_txstats; + + if (st->stats_ring_dtag != NULL) { + bus_dmamap_unload(st->stats_ring_dtag, st->stats_ring_dmap); + bus_dmamem_free(st->stats_ring_dtag, st->stats_ring, + st->stats_ring_dmap); + bus_dma_tag_destroy(st->stats_ring_dtag); + } + + if (st->stats_dtag != NULL) { + bus_dmamap_unload(st->stats_dtag, st->stats_dmap); + bus_dmamem_free(st->stats_dtag, st->stats, st->stats_dmap); + bus_dma_tag_destroy(st->stats_dtag); + } + + free(st, M_DEVBUF); +} + +static void +bwi_dma_ring_addr(void *arg, bus_dma_segment_t *seg, int nseg, int error) +{ + KASSERT(nseg == 1, ("too many segments\n")); + *((bus_addr_t *)arg) = seg->ds_addr; +} + +static int +bwi_dma_mbuf_create(struct bwi_softc *sc) +{ + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + int i, j, k, ntx, error; + + /* + * Create TX/RX mbuf DMA tag + */ + error = bus_dma_tag_create(sc->sc_parent_dtag, + 1, + 0, + BUS_SPACE_MAXADDR, + BUS_SPACE_MAXADDR, + NULL, NULL, + MCLBYTES, + 1, + BUS_SPACE_MAXSIZE_32BIT, + BUS_DMA_ALLOCNOW, + NULL, NULL, + &sc->sc_buf_dtag); + if (error) { + device_printf(sc->sc_dev, "can't create mbuf DMA tag\n"); + return error; + } + + ntx = 0; + + /* + * Create TX mbuf DMA map + */ + for (i = 0; i < BWI_TX_NRING; ++i) { + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[i]; + + for (j = 0; j < BWI_TX_NDESC; ++j) { + error = bus_dmamap_create(sc->sc_buf_dtag, 0, + &tbd->tbd_buf[j].tb_dmap); + if (error) { + device_printf(sc->sc_dev, "can't create " + "%dth tbd, %dth DMA map\n", i, j); + + ntx = i; + for (k = 0; k < j; ++k) { + bus_dmamap_destroy(sc->sc_buf_dtag, + tbd->tbd_buf[k].tb_dmap); + } + goto fail; + } + } + } + ntx = BWI_TX_NRING; + + /* + * Create RX mbuf DMA map and a spare DMA map + */ + error = bus_dmamap_create(sc->sc_buf_dtag, 0, + &rbd->rbd_tmp_dmap); + if (error) { + device_printf(sc->sc_dev, + "can't create spare RX buf DMA map\n"); + goto fail; + } + + for (j = 0; j < BWI_RX_NDESC; ++j) { + error = bus_dmamap_create(sc->sc_buf_dtag, 0, + &rbd->rbd_buf[j].rb_dmap); + if (error) { + device_printf(sc->sc_dev, "can't create %dth " + "RX buf DMA map\n", j); + + for (k = 0; k < j; ++k) { + bus_dmamap_destroy(sc->sc_buf_dtag, + rbd->rbd_buf[j].rb_dmap); + } + bus_dmamap_destroy(sc->sc_buf_dtag, + rbd->rbd_tmp_dmap); + goto fail; + } + } + + return 0; +fail: + bwi_dma_mbuf_destroy(sc, ntx, 0); + return error; +} + +static void +bwi_dma_mbuf_destroy(struct bwi_softc *sc, int ntx, int nrx) +{ + int i, j; + + if (sc->sc_buf_dtag == NULL) + return; + + for (i = 0; i < ntx; ++i) { + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[i]; + + for (j = 0; j < BWI_TX_NDESC; ++j) { + struct bwi_txbuf *tb = &tbd->tbd_buf[j]; + + if (tb->tb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, + tb->tb_dmap); + m_freem(tb->tb_mbuf); + } + if (tb->tb_ni != NULL) + ieee80211_free_node(tb->tb_ni); + bus_dmamap_destroy(sc->sc_buf_dtag, tb->tb_dmap); + } + } + + if (nrx) { + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + + bus_dmamap_destroy(sc->sc_buf_dtag, rbd->rbd_tmp_dmap); + for (j = 0; j < BWI_RX_NDESC; ++j) { + struct bwi_rxbuf *rb = &rbd->rbd_buf[j]; + + if (rb->rb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, + rb->rb_dmap); + m_freem(rb->rb_mbuf); + } + bus_dmamap_destroy(sc->sc_buf_dtag, rb->rb_dmap); + } + } + + bus_dma_tag_destroy(sc->sc_buf_dtag); + sc->sc_buf_dtag = NULL; +} + +static void +bwi_enable_intrs(struct bwi_softc *sc, uint32_t enable_intrs) +{ + CSR_SETBITS_4(sc, BWI_MAC_INTR_MASK, enable_intrs); +} + +static void +bwi_disable_intrs(struct bwi_softc *sc, uint32_t disable_intrs) +{ + CSR_CLRBITS_4(sc, BWI_MAC_INTR_MASK, disable_intrs); +} + +static int +bwi_init_tx_ring32(struct bwi_softc *sc, int ring_idx) +{ + struct bwi_ring_data *rd; + struct bwi_txbuf_data *tbd; + uint32_t val, addr_hi, addr_lo; + + KASSERT(ring_idx < BWI_TX_NRING, ("ring_idx %d", ring_idx)); + rd = &sc->sc_tx_rdata[ring_idx]; + tbd = &sc->sc_tx_bdata[ring_idx]; + + tbd->tbd_idx = 0; + tbd->tbd_used = 0; + + bzero(rd->rdata_desc, sizeof(struct bwi_desc32) * BWI_TX_NDESC); + bus_dmamap_sync(sc->sc_txring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); + + addr_lo = __SHIFTOUT(rd->rdata_paddr, BWI_TXRX32_RINGINFO_ADDR_MASK); + addr_hi = __SHIFTOUT(rd->rdata_paddr, BWI_TXRX32_RINGINFO_FUNC_MASK); + + val = __SHIFTIN(addr_lo, BWI_TXRX32_RINGINFO_ADDR_MASK) | + __SHIFTIN(BWI_TXRX32_RINGINFO_FUNC_TXRX, + BWI_TXRX32_RINGINFO_FUNC_MASK); + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_RINGINFO, val); + + val = __SHIFTIN(addr_hi, BWI_TXRX32_CTRL_ADDRHI_MASK) | + BWI_TXRX32_CTRL_ENABLE; + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_CTRL, val); + + return 0; +} + +static void +bwi_init_rxdesc_ring32(struct bwi_softc *sc, uint32_t ctrl_base, + bus_addr_t paddr, int hdr_size, int ndesc) +{ + uint32_t val, addr_hi, addr_lo; + + addr_lo = __SHIFTOUT(paddr, BWI_TXRX32_RINGINFO_ADDR_MASK); + addr_hi = __SHIFTOUT(paddr, BWI_TXRX32_RINGINFO_FUNC_MASK); + + val = __SHIFTIN(addr_lo, BWI_TXRX32_RINGINFO_ADDR_MASK) | + __SHIFTIN(BWI_TXRX32_RINGINFO_FUNC_TXRX, + BWI_TXRX32_RINGINFO_FUNC_MASK); + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_RINGINFO, val); + + val = __SHIFTIN(hdr_size, BWI_RX32_CTRL_HDRSZ_MASK) | + __SHIFTIN(addr_hi, BWI_TXRX32_CTRL_ADDRHI_MASK) | + BWI_TXRX32_CTRL_ENABLE; + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_CTRL, val); + + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_INDEX, + (ndesc - 1) * sizeof(struct bwi_desc32)); +} + +static int +bwi_init_rx_ring32(struct bwi_softc *sc) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + int i, error; + + sc->sc_rx_bdata.rbd_idx = 0; + + for (i = 0; i < BWI_RX_NDESC; ++i) { + error = bwi_newbuf(sc, i, 1); + if (error) { + device_printf(sc->sc_dev, + "can't allocate %dth RX buffer\n", i); + return error; + } + } + bus_dmamap_sync(sc->sc_rxring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); + + bwi_init_rxdesc_ring32(sc, rd->rdata_txrx_ctrl, rd->rdata_paddr, + sizeof(struct bwi_rxbuf_hdr), BWI_RX_NDESC); + return 0; +} + +static int +bwi_init_txstats32(struct bwi_softc *sc) +{ + struct bwi_txstats_data *st = sc->sc_txstats; + bus_addr_t stats_paddr; + int i; + + bzero(st->stats, BWI_TXSTATS_NDESC * sizeof(struct bwi_txstats)); + bus_dmamap_sync(st->stats_dtag, st->stats_dmap, BUS_DMASYNC_PREWRITE); + + st->stats_idx = 0; + + stats_paddr = st->stats_paddr; + for (i = 0; i < BWI_TXSTATS_NDESC; ++i) { + bwi_setup_desc32(sc, st->stats_ring, BWI_TXSTATS_NDESC, i, + stats_paddr, sizeof(struct bwi_txstats), 0); + stats_paddr += sizeof(struct bwi_txstats); + } + bus_dmamap_sync(st->stats_ring_dtag, st->stats_ring_dmap, + BUS_DMASYNC_PREWRITE); + + bwi_init_rxdesc_ring32(sc, st->stats_ctrl_base, + st->stats_ring_paddr, 0, BWI_TXSTATS_NDESC); + return 0; +} + +static void +bwi_setup_rx_desc32(struct bwi_softc *sc, int buf_idx, bus_addr_t paddr, + int buf_len) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + + KASSERT(buf_idx < BWI_RX_NDESC, ("buf_idx %d", buf_idx)); + bwi_setup_desc32(sc, rd->rdata_desc, BWI_RX_NDESC, buf_idx, + paddr, buf_len, 0); +} + +static void +bwi_setup_tx_desc32(struct bwi_softc *sc, struct bwi_ring_data *rd, + int buf_idx, bus_addr_t paddr, int buf_len) +{ + KASSERT(buf_idx < BWI_TX_NDESC, ("buf_idx %d", buf_idx)); + bwi_setup_desc32(sc, rd->rdata_desc, BWI_TX_NDESC, buf_idx, + paddr, buf_len, 1); +} + +static int +bwi_init_tx_ring64(struct bwi_softc *sc, int ring_idx) +{ + /* TODO:64 */ + return EOPNOTSUPP; +} + +static int +bwi_init_rx_ring64(struct bwi_softc *sc) +{ + /* TODO:64 */ + return EOPNOTSUPP; +} + +static int +bwi_init_txstats64(struct bwi_softc *sc) +{ + /* TODO:64 */ + return EOPNOTSUPP; +} + +static void +bwi_setup_rx_desc64(struct bwi_softc *sc, int buf_idx, bus_addr_t paddr, + int buf_len) +{ + /* TODO:64 */ +} + +static void +bwi_setup_tx_desc64(struct bwi_softc *sc, struct bwi_ring_data *rd, + int buf_idx, bus_addr_t paddr, int buf_len) +{ + /* TODO:64 */ +} + +static void +bwi_dma_buf_addr(void *arg, bus_dma_segment_t *seg, int nseg, + bus_size_t mapsz __unused, int error) +{ + if (!error) { + KASSERT(nseg == 1, ("too many segments(%d)\n", nseg)); + *((bus_addr_t *)arg) = seg->ds_addr; + } +} + +static int +bwi_newbuf(struct bwi_softc *sc, int buf_idx, int init) +{ + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + struct bwi_rxbuf *rxbuf = &rbd->rbd_buf[buf_idx]; + struct bwi_rxbuf_hdr *hdr; + bus_dmamap_t map; + bus_addr_t paddr; + struct mbuf *m; + int error; + + KASSERT(buf_idx < BWI_RX_NDESC, ("buf_idx %d", buf_idx)); + + m = m_getcl(init ? M_WAIT : M_DONTWAIT, MT_DATA, M_PKTHDR); + if (m == NULL) { + error = ENOBUFS; + + /* + * If the NIC is up and running, we need to: + * - Clear RX buffer's header. + * - Restore RX descriptor settings. + */ + if (init) + return error; + else + goto back; + } + m->m_len = m->m_pkthdr.len = MCLBYTES; + + /* + * Try to load RX buf into temporary DMA map + */ + error = bus_dmamap_load_mbuf(sc->sc_buf_dtag, rbd->rbd_tmp_dmap, m, + bwi_dma_buf_addr, &paddr, + init ? BUS_DMA_WAITOK : BUS_DMA_NOWAIT); + if (error) { + m_freem(m); + + /* + * See the comment above + */ + if (init) + return error; + else + goto back; + } + + if (!init) + bus_dmamap_unload(sc->sc_buf_dtag, rxbuf->rb_dmap); + rxbuf->rb_mbuf = m; + rxbuf->rb_paddr = paddr; + + /* + * Swap RX buf's DMA map with the loaded temporary one + */ + map = rxbuf->rb_dmap; + rxbuf->rb_dmap = rbd->rbd_tmp_dmap; + rbd->rbd_tmp_dmap = map; + +back: + /* + * Clear RX buf header + */ + hdr = mtod(rxbuf->rb_mbuf, struct bwi_rxbuf_hdr *); + bzero(hdr, sizeof(*hdr)); + bus_dmamap_sync(sc->sc_buf_dtag, rxbuf->rb_dmap, BUS_DMASYNC_PREWRITE); + + /* + * Setup RX buf descriptor + */ + sc->sc_setup_rxdesc(sc, buf_idx, rxbuf->rb_paddr, + rxbuf->rb_mbuf->m_len - sizeof(*hdr)); + return error; +} + +static void +bwi_set_addr_filter(struct bwi_softc *sc, uint16_t addr_ofs, + const uint8_t *addr) +{ + int i; + + CSR_WRITE_2(sc, BWI_ADDR_FILTER_CTRL, + BWI_ADDR_FILTER_CTRL_SET | addr_ofs); + + for (i = 0; i < (IEEE80211_ADDR_LEN / 2); ++i) { + uint16_t addr_val; + + addr_val = (uint16_t)addr[i * 2] | + (((uint16_t)addr[(i * 2) + 1]) << 8); + CSR_WRITE_2(sc, BWI_ADDR_FILTER_DATA, addr_val); + } +} + +static int +bwi_set_chan(struct bwi_softc *sc, struct ieee80211_channel *c) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_mac *mac; + uint16_t flags; + u_int chan; + + BWI_LOCK(sc); + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + chan = ieee80211_chan2ieee(ic, c); + + bwi_rf_set_chan(mac, chan, 0); + + /* + * Setup radio tap channel freq and flags + */ + if (IEEE80211_IS_CHAN_G(c)) + flags = IEEE80211_CHAN_G; + else + flags = IEEE80211_CHAN_B; + + sc->sc_tx_th.wt_chan_freq = sc->sc_rx_th.wr_chan_freq = + htole16(c->ic_freq); + sc->sc_tx_th.wt_chan_flags = sc->sc_rx_th.wr_chan_flags = + htole16(flags); + + BWI_UNLOCK(sc); + + return 0; +} + +static void +bwi_rxeof(struct bwi_softc *sc, int end_idx) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + struct ieee80211com *ic = &sc->sc_ic; + struct ifnet *ifp = ic->ic_ifp; + int idx; + + idx = rbd->rbd_idx; + while (idx != end_idx) { + struct bwi_rxbuf *rb = &rbd->rbd_buf[idx]; + struct bwi_rxbuf_hdr *hdr; + struct ieee80211_frame_min *wh; + struct ieee80211_node *ni; + struct mbuf *m; + const uint8_t *plcp; + uint16_t flags2; + int buflen, wh_ofs, hdr_extra, rssi; + + m = rb->rb_mbuf; + bus_dmamap_sync(sc->sc_buf_dtag, rb->rb_dmap, + BUS_DMASYNC_POSTREAD); + + if (bwi_newbuf(sc, idx, 0)) { + ifp->if_ierrors++; + goto next; + } + + hdr = mtod(m, struct bwi_rxbuf_hdr *); + flags2 = le16toh(hdr->rxh_flags2); + + hdr_extra = 0; + if (flags2 & BWI_RXH_F2_TYPE2FRAME) + hdr_extra = 2; + wh_ofs = hdr_extra + 6; /* XXX magic number */ + + buflen = le16toh(hdr->rxh_buflen); + if (buflen < BWI_FRAME_MIN_LEN(wh_ofs)) { + if_printf(ifp, "zero length data, hdr_extra %d\n", + hdr_extra); + ifp->if_ierrors++; + m_freem(m); + goto next; + } + + plcp = ((const uint8_t *)(hdr + 1) + hdr_extra); + rssi = bwi_calc_rssi(sc, hdr); + + m->m_pkthdr.rcvif = ifp; + m->m_len = m->m_pkthdr.len = buflen + sizeof(*hdr); + m_adj(m, sizeof(*hdr) + wh_ofs); + + /* RX radio tap */ + if (sc->sc_drvbpf != NULL) + bwi_rx_radiotap(sc, m, hdr, plcp, rssi); + + m_adj(m, -IEEE80211_CRC_LEN); + + wh = mtod(m, struct ieee80211_frame_min *); + ni = ieee80211_find_rxnode(ic, wh); + + ieee80211_input(ic, m, ni, rssi - BWI_NOISE_FLOOR, + BWI_NOISE_FLOOR, le16toh(hdr->rxh_tsf)); + ieee80211_free_node(ni); +next: + idx = (idx + 1) % BWI_RX_NDESC; + } + + rbd->rbd_idx = idx; + bus_dmamap_sync(sc->sc_rxring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); +} + +static void +bwi_rxeof32(struct bwi_softc *sc) +{ + uint32_t val, rx_ctrl; + int end_idx; + + rx_ctrl = sc->sc_rx_rdata.rdata_txrx_ctrl; + + val = CSR_READ_4(sc, rx_ctrl + BWI_RX32_STATUS); + end_idx = __SHIFTOUT(val, BWI_RX32_STATUS_INDEX_MASK) / + sizeof(struct bwi_desc32); + + bwi_rxeof(sc, end_idx); + + CSR_WRITE_4(sc, rx_ctrl + BWI_RX32_INDEX, + end_idx * sizeof(struct bwi_desc32)); +} + +static void +bwi_rxeof64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +bwi_reset_rx_ring32(struct bwi_softc *sc, uint32_t rx_ctrl) +{ + int i; + + CSR_WRITE_4(sc, rx_ctrl + BWI_RX32_CTRL, 0); + +#define NRETRY 10 + + for (i = 0; i < NRETRY; ++i) { + uint32_t status; + + status = CSR_READ_4(sc, rx_ctrl + BWI_RX32_STATUS); + if (__SHIFTOUT(status, BWI_RX32_STATUS_STATE_MASK) == + BWI_RX32_STATUS_STATE_DISABLED) + break; + + DELAY(1000); + } + if (i == NRETRY) + device_printf(sc->sc_dev, "reset rx ring timedout\n"); + +#undef NRETRY + + CSR_WRITE_4(sc, rx_ctrl + BWI_RX32_RINGINFO, 0); +} + +static void +bwi_free_txstats32(struct bwi_softc *sc) +{ + bwi_reset_rx_ring32(sc, sc->sc_txstats->stats_ctrl_base); +} + +static void +bwi_free_rx_ring32(struct bwi_softc *sc) +{ + struct bwi_ring_data *rd = &sc->sc_rx_rdata; + struct bwi_rxbuf_data *rbd = &sc->sc_rx_bdata; + int i; + + bwi_reset_rx_ring32(sc, rd->rdata_txrx_ctrl); + + for (i = 0; i < BWI_RX_NDESC; ++i) { + struct bwi_rxbuf *rb = &rbd->rbd_buf[i]; + + if (rb->rb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, rb->rb_dmap); + m_freem(rb->rb_mbuf); + rb->rb_mbuf = NULL; + } + } +} + +static void +bwi_free_tx_ring32(struct bwi_softc *sc, int ring_idx) +{ + struct bwi_ring_data *rd; + struct bwi_txbuf_data *tbd; + struct ifnet *ifp = sc->sc_ic.ic_ifp; + uint32_t state, val; + int i; + + KASSERT(ring_idx < BWI_TX_NRING, ("ring_idx %d", ring_idx)); + rd = &sc->sc_tx_rdata[ring_idx]; + tbd = &sc->sc_tx_bdata[ring_idx]; + +#define NRETRY 10 + + for (i = 0; i < NRETRY; ++i) { + val = CSR_READ_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_STATUS); + state = __SHIFTOUT(val, BWI_TX32_STATUS_STATE_MASK); + if (state == BWI_TX32_STATUS_STATE_DISABLED || + state == BWI_TX32_STATUS_STATE_IDLE || + state == BWI_TX32_STATUS_STATE_STOPPED) + break; + + DELAY(1000); + } + if (i == NRETRY) { + if_printf(ifp, "wait for TX ring(%d) stable timed out\n", + ring_idx); + } + + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_CTRL, 0); + for (i = 0; i < NRETRY; ++i) { + val = CSR_READ_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_STATUS); + state = __SHIFTOUT(val, BWI_TX32_STATUS_STATE_MASK); + if (state == BWI_TX32_STATUS_STATE_DISABLED) + break; + + DELAY(1000); + } + if (i == NRETRY) + if_printf(ifp, "reset TX ring (%d) timed out\n", ring_idx); + +#undef NRETRY + + DELAY(1000); + + CSR_WRITE_4(sc, rd->rdata_txrx_ctrl + BWI_TX32_RINGINFO, 0); + + for (i = 0; i < BWI_TX_NDESC; ++i) { + struct bwi_txbuf *tb = &tbd->tbd_buf[i]; + + if (tb->tb_mbuf != NULL) { + bus_dmamap_unload(sc->sc_buf_dtag, tb->tb_dmap); + m_freem(tb->tb_mbuf); + tb->tb_mbuf = NULL; + } + if (tb->tb_ni != NULL) { + ieee80211_free_node(tb->tb_ni); + tb->tb_ni = NULL; + } + } +} + +static void +bwi_free_txstats64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +bwi_free_rx_ring64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +bwi_free_tx_ring64(struct bwi_softc *sc, int ring_idx) +{ + /* TODO:64 */ +} + +/* XXX does not belong here */ +uint8_t +bwi_rate2plcp(uint8_t rate) +{ + rate &= IEEE80211_RATE_VAL; + + switch (rate) { + case 2: return 0xa; + case 4: return 0x14; + case 11: return 0x37; + case 22: return 0x6e; + case 44: return 0xdc; + + case 12: return 0xb; + case 18: return 0xf; + case 24: return 0xa; + case 36: return 0xe; + case 48: return 0x9; + case 72: return 0xd; + case 96: return 0x8; + case 108: return 0xc; + + default: + panic("unsupported rate %u\n", rate); + } +} + +/* XXX does not belong here */ +#define IEEE80211_OFDM_PLCP_RATE_MASK __BITS(3, 0) +#define IEEE80211_OFDM_PLCP_LEN_MASK __BITS(16, 5) + +static __inline void +bwi_ofdm_plcp_header(uint32_t *plcp0, int pkt_len, uint8_t rate) +{ + uint32_t plcp; + + plcp = __SHIFTIN(bwi_rate2plcp(rate), IEEE80211_OFDM_PLCP_RATE_MASK) | + __SHIFTIN(pkt_len, IEEE80211_OFDM_PLCP_LEN_MASK); + *plcp0 = htole32(plcp); +} + +#define IEEE80211_DS_PLCP_SERVICE_LOCKED 0x04 +#define IEEE80211_DS_PLCL_SERVICE_PBCC 0x08 +#define IEEE80211_DS_PLCP_SERVICE_LENEXT5 0x20 +#define IEEE80211_DS_PLCP_SERVICE_LENEXT6 0x40 +#define IEEE80211_DS_PLCP_SERVICE_LENEXT7 0x80 + +static __inline void +bwi_ds_plcp_header(struct ieee80211_ds_plcp_hdr *plcp, int pkt_len, + uint8_t rate) +{ + int len, service, pkt_bitlen; + + pkt_bitlen = pkt_len * NBBY; + len = howmany(pkt_bitlen * 2, rate); + + service = IEEE80211_DS_PLCP_SERVICE_LOCKED; + if (rate == (11 * 2)) { + int pkt_bitlen1; + + /* + * PLCP service field needs to be adjusted, + * if TX rate is 11Mbytes/s + */ + pkt_bitlen1 = len * 11; + if (pkt_bitlen1 - pkt_bitlen >= NBBY) + service |= IEEE80211_DS_PLCP_SERVICE_LENEXT7; + } + + plcp->i_signal = bwi_rate2plcp(rate); + plcp->i_service = service; + plcp->i_length = htole16(len); + /* NOTE: do NOT touch i_crc */ +} + +static __inline void +bwi_plcp_header(void *plcp, int pkt_len, uint8_t rate) +{ + enum ieee80211_modtype modtype; + + /* + * Assume caller has zeroed 'plcp' + */ + + modtype = ieee80211_rate2modtype(rate); + if (modtype == IEEE80211_MODTYPE_OFDM) + bwi_ofdm_plcp_header(plcp, pkt_len, rate); + else if (modtype == IEEE80211_MODTYPE_DS) + bwi_ds_plcp_header(plcp, pkt_len, rate); + else + panic("unsupport modulation type %u\n", modtype); +} + +static int +bwi_encap(struct bwi_softc *sc, int idx, struct mbuf *m, + struct ieee80211_node *ni) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_ring_data *rd = &sc->sc_tx_rdata[BWI_TX_DATA_RING]; + struct bwi_txbuf_data *tbd = &sc->sc_tx_bdata[BWI_TX_DATA_RING]; + struct bwi_txbuf *tb = &tbd->tbd_buf[idx]; + struct bwi_mac *mac; + struct bwi_txbuf_hdr *hdr; + struct ieee80211_frame *wh; + uint8_t rate, rate_fb; + uint32_t mac_ctrl; + uint16_t phy_ctrl; + bus_addr_t paddr; + int pkt_len, error; +#if 0 + const uint8_t *p; + int i; +#endif + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + wh = mtod(m, struct ieee80211_frame *); + + /* Get 802.11 frame len before prepending TX header */ + pkt_len = m->m_pkthdr.len + IEEE80211_CRC_LEN; + + /* + * Find TX rate + */ + bzero(tb->tb_rate_idx, sizeof(tb->tb_rate_idx)); + if (IEEE80211_IS_MULTICAST(wh->i_addr1)) + rate = rate_fb = ic->ic_mcast_rate; + else if (ic->ic_fixed_rate == IEEE80211_FIXED_RATE_NONE) { + rate = ni->ni_rates.rs_rates[ni->ni_txrate] & IEEE80211_RATE_VAL; + rate_fb = (ni->ni_txrate > 0) ? + ni->ni_rates.rs_rates[ni->ni_txrate-1] & IEEE80211_RATE_VAL : rate; + } else + rate = rate_fb = ic->ic_fixed_rate; + + /* + * TX radio tap + */ + if (bpf_peers_present(sc->sc_drvbpf)) { + sc->sc_tx_th.wt_flags = 0; + if (wh->i_fc[1] & IEEE80211_FC1_WEP) + sc->sc_tx_th.wt_flags |= IEEE80211_RADIOTAP_F_WEP; + if (ieee80211_rate2modtype(rate) == IEEE80211_MODTYPE_DS && + (ic->ic_flags & IEEE80211_F_SHPREAMBLE) && + rate != (1 * 2)) { + sc->sc_tx_th.wt_flags |= IEEE80211_RADIOTAP_F_SHORTPRE; + } + sc->sc_tx_th.wt_rate = rate; + + bpf_mtap2(sc->sc_drvbpf, &sc->sc_tx_th, sc->sc_tx_th_len, m); + } + + /* + * Setup the embedded TX header + */ + M_PREPEND(m, sizeof(*hdr), M_DONTWAIT); + if (m == NULL) { + if_printf(ic->ic_ifp, "prepend TX header failed\n"); + return ENOBUFS; + } + hdr = mtod(m, struct bwi_txbuf_hdr *); + + bzero(hdr, sizeof(*hdr)); + + bcopy(wh->i_fc, hdr->txh_fc, sizeof(hdr->txh_fc)); + bcopy(wh->i_addr1, hdr->txh_addr1, sizeof(hdr->txh_addr1)); + + if (!IEEE80211_IS_MULTICAST(wh->i_addr1)) { + uint16_t dur; + uint8_t ack_rate; + + ack_rate = ieee80211_ack_rate(ni, rate_fb); + dur = ieee80211_txtime(ni, + sizeof(struct ieee80211_frame_ack) + IEEE80211_CRC_LEN, + ack_rate, ic->ic_flags & ~IEEE80211_F_SHPREAMBLE); + + hdr->txh_fb_duration = htole16(dur); + } + + hdr->txh_id = __SHIFTIN(BWI_TX_DATA_RING, BWI_TXH_ID_RING_MASK) | + __SHIFTIN(idx, BWI_TXH_ID_IDX_MASK); + + bwi_plcp_header(hdr->txh_plcp, pkt_len, rate); + bwi_plcp_header(hdr->txh_fb_plcp, pkt_len, rate_fb); + + phy_ctrl = __SHIFTIN(mac->mac_rf.rf_ant_mode, + BWI_TXH_PHY_C_ANTMODE_MASK); + if (ieee80211_rate2modtype(rate) == IEEE80211_MODTYPE_OFDM) + phy_ctrl |= BWI_TXH_PHY_C_OFDM; + else if ((ic->ic_flags & IEEE80211_F_SHPREAMBLE) && rate != (2 * 1)) + phy_ctrl |= BWI_TXH_PHY_C_SHPREAMBLE; + + mac_ctrl = BWI_TXH_MAC_C_HWSEQ | BWI_TXH_MAC_C_FIRST_FRAG; + if (!IEEE80211_IS_MULTICAST(wh->i_addr1)) + mac_ctrl |= BWI_TXH_MAC_C_ACK; + if (ieee80211_rate2modtype(rate_fb) == IEEE80211_MODTYPE_OFDM) + mac_ctrl |= BWI_TXH_MAC_C_FB_OFDM; + + hdr->txh_mac_ctrl = htole32(mac_ctrl); + hdr->txh_phy_ctrl = htole16(phy_ctrl); + + /* Catch any further usage */ + hdr = NULL; + wh = NULL; + + /* DMA load */ + error = bus_dmamap_load_mbuf(sc->sc_buf_dtag, tb->tb_dmap, m, + bwi_dma_buf_addr, &paddr, BUS_DMA_NOWAIT); + if (error && error != EFBIG) { + if_printf(ic->ic_ifp, "can't load TX buffer (1) %d\n", error); + goto back; + } + + if (error) { /* error == EFBIG */ + struct mbuf *m_new; + + m_new = m_defrag(m, M_DONTWAIT); + if (m_new == NULL) { + if_printf(ic->ic_ifp, "can't defrag TX buffer\n"); + error = ENOBUFS; + goto back; + } else { + m = m_new; + } + + error = bus_dmamap_load_mbuf(sc->sc_buf_dtag, tb->tb_dmap, m, + bwi_dma_buf_addr, &paddr, + BUS_DMA_NOWAIT); + if (error) { + if_printf(ic->ic_ifp, "can't load TX buffer (2) %d\n", + error); + goto back; + } + } + error = 0; + + bus_dmamap_sync(sc->sc_buf_dtag, tb->tb_dmap, BUS_DMASYNC_PREWRITE); + + tb->tb_mbuf = m; + tb->tb_ni = ni; + +#if 0 + p = mtod(m, const uint8_t *); + for (i = 0; i < m->m_pkthdr.len; ++i) { + if (i != 0 && i % 8 == 0) + printf("\n"); + printf("%02x ", p[i]); + } + printf("\n"); + + if_printf(ic->ic_ifp, "idx %d, pkt_len %d, buflen %d\n", + idx, pkt_len, m->m_pkthdr.len); +#endif + + /* Setup TX descriptor */ + sc->sc_setup_txdesc(sc, rd, idx, paddr, m->m_pkthdr.len); + bus_dmamap_sync(sc->sc_txring_dtag, rd->rdata_dmap, + BUS_DMASYNC_PREWRITE); + + /* Kick start */ + sc->sc_start_tx(sc, rd->rdata_txrx_ctrl, idx); + +back: + if (error) + m_freem(m); + return error; +} + +static void +bwi_start_tx32(struct bwi_softc *sc, uint32_t tx_ctrl, int idx) +{ + idx = (idx + 1) % BWI_TX_NDESC; + CSR_WRITE_4(sc, tx_ctrl + BWI_TX32_INDEX, + idx * sizeof(struct bwi_desc32)); +} + +static void +bwi_start_tx64(struct bwi_softc *sc, uint32_t tx_ctrl, int idx) +{ + /* TODO:64 */ +} + +static void +bwi_txeof_status32(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ic.ic_ifp; + uint32_t val, ctrl_base; + int end_idx; + + ctrl_base = sc->sc_txstats->stats_ctrl_base; + + val = CSR_READ_4(sc, ctrl_base + BWI_RX32_STATUS); + end_idx = __SHIFTOUT(val, BWI_RX32_STATUS_INDEX_MASK) / + sizeof(struct bwi_desc32); + + bwi_txeof_status(sc, end_idx); + + CSR_WRITE_4(sc, ctrl_base + BWI_RX32_INDEX, + end_idx * sizeof(struct bwi_desc32)); + + if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) == 0) + ifp->if_start(ifp); +} + +static void +bwi_txeof_status64(struct bwi_softc *sc) +{ + /* TODO:64 */ +} + +static void +_bwi_txeof(struct bwi_softc *sc, uint16_t tx_id, int acked, int data_txcnt) +{ + struct ifnet *ifp = sc->sc_ic.ic_ifp; + struct bwi_txbuf_data *tbd; + struct bwi_txbuf *tb; + int ring_idx, buf_idx; + struct ieee80211_node *ni; + + if (tx_id == 0) { + if_printf(ifp, "zero tx id\n"); + return; + } + +#if 0 + if_printf(ifp, "acked %d, data_txcnt %d\n", acked, data_txcnt); +#endif + + ring_idx = __SHIFTOUT(tx_id, BWI_TXH_ID_RING_MASK); + buf_idx = __SHIFTOUT(tx_id, BWI_TXH_ID_IDX_MASK); + + KASSERT(ring_idx == BWI_TX_DATA_RING, ("ring_idx %d", ring_idx)); + KASSERT(buf_idx < BWI_TX_NDESC, ("buf_idx %d", buf_idx)); +#if 0 + if_printf(ifp, "txeof idx %d\n", buf_idx); +#endif + + tbd = &sc->sc_tx_bdata[ring_idx]; + KASSERT(tbd->tbd_used > 0, ("tbd_used %d", tbd->tbd_used)); + tbd->tbd_used--; + + tb = &tbd->tbd_buf[buf_idx]; + + bus_dmamap_unload(sc->sc_buf_dtag, tb->tb_dmap); + + ni = tb->tb_ni; + if (tb->tb_ni != NULL) { + struct bwi_node *bn = (struct bwi_node *) tb->tb_ni; + + /* XXX only for unicast frames */ + /* Feed back 'acked and data_txcnt' */ + if (acked) + bn->amn.amn_success++; + bn->amn.amn_txcnt++; + bn->amn.amn_retrycnt += data_txcnt-1; + + /* + * Do any tx complete callback. Note this must + * be done before releasing the node reference. + */ + if (tb->tb_mbuf->m_flags & M_TXCB) + ieee80211_process_callback(ni, tb->tb_mbuf, !acked); + + ieee80211_free_node(tb->tb_ni); + tb->tb_ni = NULL; + } + m_freem(tb->tb_mbuf); + tb->tb_mbuf = NULL; + + if (tbd->tbd_used == 0) + sc->sc_tx_timer = 0; + + ifp->if_drv_flags &= ~IFF_DRV_OACTIVE; +} + +static void +bwi_txeof_status(struct bwi_softc *sc, int end_idx) +{ + struct bwi_txstats_data *st = sc->sc_txstats; + int idx; + + bus_dmamap_sync(st->stats_dtag, st->stats_dmap, BUS_DMASYNC_POSTREAD); + + idx = st->stats_idx; + while (idx != end_idx) { + const struct bwi_txstats *stats = &st->stats[idx]; + + if ((stats->txs_flags & BWI_TXS_F_PENDING) == 0) { + int data_txcnt; + + data_txcnt = __SHIFTOUT(stats->txs_txcnt, + BWI_TXS_TXCNT_DATA); + _bwi_txeof(sc, le16toh(stats->txs_id), + stats->txs_flags & BWI_TXS_F_ACKED, + data_txcnt); + } + idx = (idx + 1) % BWI_TXSTATS_NDESC; + } + st->stats_idx = idx; +} + +static void +bwi_txeof(struct bwi_softc *sc) +{ + struct ifnet *ifp = sc->sc_ic.ic_ifp; + + for (;;) { + uint32_t tx_status0, tx_status1; + uint16_t tx_id; + int data_txcnt; + + tx_status0 = CSR_READ_4(sc, BWI_TXSTATUS0); + if ((tx_status0 & BWI_TXSTATUS0_VALID) == 0) + break; + tx_status1 = CSR_READ_4(sc, BWI_TXSTATUS1); + + tx_id = __SHIFTOUT(tx_status0, BWI_TXSTATUS0_TXID_MASK); + data_txcnt = __SHIFTOUT(tx_status0, + BWI_TXSTATUS0_DATA_TXCNT_MASK); + + if (tx_status0 & (BWI_TXSTATUS0_AMPDU | BWI_TXSTATUS0_PENDING)) + continue; + + _bwi_txeof(sc, le16toh(tx_id), tx_status0 & BWI_TXSTATUS0_ACKED, + data_txcnt); + } + + if ((ifp->if_drv_flags & IFF_DRV_OACTIVE) == 0) + ifp->if_start(ifp); +} + +static int +bwi_bbp_power_on(struct bwi_softc *sc, enum bwi_clock_mode clk_mode) +{ + bwi_power_on(sc, 1); + return bwi_set_clock_mode(sc, clk_mode); +} + +static void +bwi_bbp_power_off(struct bwi_softc *sc) +{ + bwi_set_clock_mode(sc, BWI_CLOCK_MODE_SLOW); + bwi_power_off(sc, 1); +} + +static int +bwi_get_pwron_delay(struct bwi_softc *sc) +{ + struct bwi_regwin *com, *old; + struct bwi_clock_freq freq; + uint32_t val; + int error; + + com = &sc->sc_com_regwin; + KASSERT(BWI_REGWIN_EXIST(com), ("no regwin")); + + if ((sc->sc_cap & BWI_CAP_CLKMODE) == 0) + return 0; + + error = bwi_regwin_switch(sc, com, &old); + if (error) + return error; + + bwi_get_clock_freq(sc, &freq); + + val = CSR_READ_4(sc, BWI_PLL_ON_DELAY); + sc->sc_pwron_delay = howmany((val + 2) * 1000000, freq.clkfreq_min); + DPRINTF(sc, "power on delay %u\n", sc->sc_pwron_delay); + + return bwi_regwin_switch(sc, old, NULL); +} + +static int +bwi_bus_attach(struct bwi_softc *sc) +{ + struct bwi_regwin *bus, *old; + int error; + + bus = &sc->sc_bus_regwin; + + error = bwi_regwin_switch(sc, bus, &old); + if (error) + return error; + + if (!bwi_regwin_is_enabled(sc, bus)) + bwi_regwin_enable(sc, bus, 0); + + /* Disable interripts */ + CSR_WRITE_4(sc, BWI_INTRVEC, 0); + + return bwi_regwin_switch(sc, old, NULL); +} +//kir+ +static const char * +bwi_regwin_name(const uint16_t type) +{ + switch (type) { + case BWI_REGWIN_T_CC: + return "chipcommon"; + case BWI_REGWIN_T_ILINE20: + return "iline20"; + case BWI_REGWIN_T_SDRAM: + return "sdram"; + case BWI_REGWIN_T_PCI: + return "pci"; + case BWI_REGWIN_T_MIPS: + return "mips"; + case BWI_REGWIN_T_ENET: + return "enet mac"; + case BWI_REGWIN_T_CODEC: + return "v90 codec"; + case BWI_REGWIN_T_USB: + return "usb 1.1 host/device"; + case BWI_REGWIN_T_ADSL: + return "ADSL"; + case BWI_REGWIN_T_ILINE100: + return "iline100"; + case BWI_REGWIN_T_IPSEC: + return "ipsec"; + case BWI_REGWIN_T_PCMCIA: + return "pcmcia"; + case BWI_REGWIN_T_SOCRAM: + return "internal memory"; + case BWI_REGWIN_T_MEMC: + return "memc sdram"; + case BWI_REGWIN_T_EXTIF: + return "external interface"; + case BWI_REGWIN_T_D11: + return "802.11 MAC"; + case BWI_REGWIN_T_MIPS33: + return "mips3302"; + case BWI_REGWIN_T_USB11H: + return "usb 1.1 host"; + case BWI_REGWIN_T_USB11D: + return "usb 1.1 device"; + case BWI_REGWIN_T_USB20H: + return "usb 2.0 host"; + case BWI_REGWIN_T_USB20D: + return "usb 2.0 device"; + case BWI_REGWIN_T_SDIOH: + return "sdio host"; + case BWI_REGWIN_T_ROBO: + return "roboswitch"; + case BWI_REGWIN_T_ATA100: + return "parallel ATA"; + case BWI_REGWIN_T_SATAXOR: + return "serial ATA & XOR DMA"; + case BWI_REGWIN_T_GIGETH: + return "gigabit ethernet"; + case BWI_REGWIN_T_PCIE: + return "pci express"; + case BWI_REGWIN_T_SRAMC: + return "SRAM controller"; + case BWI_REGWIN_T_MINIMAC: + return "MINI MAC/phy"; + } + return "unknown"; +} + +static uint32_t +bwi_regwin_disable_bits(struct bwi_softc *sc) +{ + uint32_t busrev; + + /* XXX cache this */ + busrev = __SHIFTOUT(CSR_READ_4(sc, BWI_ID_LO), BWI_ID_LO_BUSREV_MASK); + DPRINTF(sc, "bus rev %u\n", busrev); + + if (busrev == BWI_BUSREV_0) + return BWI_STATE_LO_DISABLE1; + else if (busrev == BWI_BUSREV_1) + return BWI_STATE_LO_DISABLE2; + else + return (BWI_STATE_LO_DISABLE1 | BWI_STATE_LO_DISABLE2); +} + +int +bwi_regwin_is_enabled(struct bwi_softc *sc, struct bwi_regwin *rw) +{ + uint32_t val, disable_bits; + + disable_bits = bwi_regwin_disable_bits(sc); + val = CSR_READ_4(sc, BWI_STATE_LO); + + if ((val & (BWI_STATE_LO_CLOCK | + BWI_STATE_LO_RESET | + disable_bits)) == BWI_STATE_LO_CLOCK) { + DPRINTF(sc, "%s is enabled\n", bwi_regwin_name(rw->rw_type)); + return 1; + } else { + DPRINTF(sc, "%s is disabled\n", bwi_regwin_name(rw->rw_type)); + return 0; + } +} + +void +bwi_regwin_disable(struct bwi_softc *sc, struct bwi_regwin *rw, uint32_t flags) +{ + uint32_t state_lo, disable_bits; + int i; + + state_lo = CSR_READ_4(sc, BWI_STATE_LO); + + /* + * If current regwin is in 'reset' state, it was already disabled. + */ + if (state_lo & BWI_STATE_LO_RESET) { + DPRINTF(sc, "%s was already disabled\n", bwi_regwin_name(rw->rw_type)); + return; + } + + disable_bits = bwi_regwin_disable_bits(sc); + + /* + * Disable normal clock + */ + state_lo = BWI_STATE_LO_CLOCK | disable_bits; + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* + * Wait until normal clock is disabled + */ +#define NRETRY 1000 + for (i = 0; i < NRETRY; ++i) { + state_lo = CSR_READ_4(sc, BWI_STATE_LO); + if (state_lo & disable_bits) + break; + DELAY(10); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "%s disable clock timeout\n", + bwi_regwin_name(rw->rw_type)); + } + + for (i = 0; i < NRETRY; ++i) { + uint32_t state_hi; + + state_hi = CSR_READ_4(sc, BWI_STATE_HI); + if ((state_hi & BWI_STATE_HI_BUSY) == 0) + break; + DELAY(10); + } + if (i == NRETRY) { + device_printf(sc->sc_dev, "%s wait BUSY unset timeout\n", + bwi_regwin_name(rw->rw_type)); + } +#undef NRETRY + + /* + * Reset and disable regwin with gated clock + */ + state_lo = BWI_STATE_LO_RESET | disable_bits | + BWI_STATE_LO_CLOCK | BWI_STATE_LO_GATED_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); + + /* Reset and disable regwin */ + state_lo = BWI_STATE_LO_RESET | disable_bits | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); +} + +void +bwi_regwin_enable(struct bwi_softc *sc, struct bwi_regwin *rw, uint32_t flags) +{ + uint32_t state_lo, state_hi, imstate; + + bwi_regwin_disable(sc, rw, flags); + + /* Reset regwin with gated clock */ + state_lo = BWI_STATE_LO_RESET | + BWI_STATE_LO_CLOCK | + BWI_STATE_LO_GATED_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); + + state_hi = CSR_READ_4(sc, BWI_STATE_HI); + if (state_hi & BWI_STATE_HI_SERROR) + CSR_WRITE_4(sc, BWI_STATE_HI, 0); + + imstate = CSR_READ_4(sc, BWI_IMSTATE); + if (imstate & (BWI_IMSTATE_INBAND_ERR | BWI_IMSTATE_TIMEOUT)) { + imstate &= ~(BWI_IMSTATE_INBAND_ERR | BWI_IMSTATE_TIMEOUT); + CSR_WRITE_4(sc, BWI_IMSTATE, imstate); + } + + /* Enable regwin with gated clock */ + state_lo = BWI_STATE_LO_CLOCK | + BWI_STATE_LO_GATED_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); + + /* Enable regwin with normal clock */ + state_lo = BWI_STATE_LO_CLOCK | + __SHIFTIN(flags, BWI_STATE_LO_FLAGS_MASK); + CSR_WRITE_4(sc, BWI_STATE_LO, state_lo); + + /* Flush pending bus write */ + CSR_READ_4(sc, BWI_STATE_LO); + DELAY(1); +} + +static void +bwi_set_bssid(struct bwi_softc *sc, const uint8_t *bssid) +{ + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_mac *mac; + struct bwi_myaddr_bssid buf; + const uint8_t *p; + uint32_t val; + int n, i; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + bwi_set_addr_filter(sc, BWI_ADDR_FILTER_BSSID, bssid); + + bcopy(ic->ic_myaddr, buf.myaddr, sizeof(buf.myaddr)); + bcopy(bssid, buf.bssid, sizeof(buf.bssid)); + + n = sizeof(buf) / sizeof(val); + p = (const uint8_t *)&buf; + for (i = 0; i < n; ++i) { + int j; + + val = 0; + for (j = 0; j < sizeof(val); ++j) + val |= ((uint32_t)(*p++)) << (j * 8); + + TMPLT_WRITE_4(mac, 0x20 + (i * sizeof(val)), val); + } +} + +static void +bwi_updateslot(struct ifnet *ifp) +{ + struct bwi_softc *sc = ifp->if_softc; + struct ieee80211com *ic = &sc->sc_ic; + struct bwi_mac *mac; + + BWI_LOCK(sc); + if (ifp->if_drv_flags & IFF_DRV_RUNNING) { + DPRINTF(sc, "%s\n", __func__); + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + bwi_mac_updateslot(mac, (ic->ic_flags & IEEE80211_F_SHSLOT)); + } + BWI_UNLOCK(sc); +} + +static void +bwi_calibrate(void *xsc) +{ + struct bwi_softc *sc = xsc; + struct ieee80211com *ic = &sc->sc_ic; + + if (ic->ic_state == IEEE80211_S_RUN) { + struct bwi_mac *mac; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + if (ic->ic_opmode != IEEE80211_M_MONITOR) + bwi_mac_calibrate_txpower(mac); + + /* XXX 15 seconds */ + callout_reset(&sc->sc_calib_ch, hz * 15, bwi_calibrate, sc); + } +} + +static int +bwi_calc_rssi(struct bwi_softc *sc, const struct bwi_rxbuf_hdr *hdr) +{ + struct bwi_mac *mac; + + KASSERT(sc->sc_cur_regwin->rw_type == BWI_REGWIN_T_D11, + ("current regwin type %d", sc->sc_cur_regwin->rw_type)); + mac = (struct bwi_mac *)sc->sc_cur_regwin; + + return bwi_rf_calc_rssi(mac, hdr); +} + +static __inline uint8_t +bwi_ofdm_plcp2rate(const uint32_t *plcp0) +{ + uint32_t plcp; + uint8_t plcp_rate; + + plcp = le32toh(*plcp0); + plcp_rate = __SHIFTOUT(plcp, IEEE80211_OFDM_PLCP_RATE_MASK); + return ieee80211_plcp2rate(plcp_rate, 1); +} + +static __inline uint8_t +bwi_ds_plcp2rate(const struct ieee80211_ds_plcp_hdr *hdr) +{ + return ieee80211_plcp2rate(hdr->i_signal, 0); +} + +static void +bwi_rx_radiotap(struct bwi_softc *sc, struct mbuf *m, + struct bwi_rxbuf_hdr *hdr, const void *plcp, int rssi) +{ + const struct ieee80211_frame_min *wh; + uint16_t flags1; + uint8_t rate; + + flags1 = htole16(hdr->rxh_flags1); + if (flags1 & BWI_RXH_F1_OFDM) + rate = bwi_ofdm_plcp2rate(plcp); + else + rate = bwi_ds_plcp2rate(plcp); + + sc->sc_rx_th.wr_flags = IEEE80211_RADIOTAP_F_FCS; + if (flags1 & BWI_RXH_F1_SHPREAMBLE) + sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_SHORTPRE; + + wh = mtod(m, const struct ieee80211_frame_min *); + if (wh->i_fc[1] & IEEE80211_FC1_WEP) + sc->sc_rx_th.wr_flags |= IEEE80211_RADIOTAP_F_WEP; + + sc->sc_rx_th.wr_tsf = hdr->rxh_tsf; /* No endian convertion */ + sc->sc_rx_th.wr_rate = rate; + sc->sc_rx_th.wr_antsignal = rssi; + sc->sc_rx_th.wr_antnoise = BWI_NOISE_FLOOR; + + bpf_mtap2(sc->sc_drvbpf, &sc->sc_rx_th, sc->sc_rx_th_len, m); +} + +static void +bwi_led_attach(struct bwi_softc *sc) +{ +#define PCI_VENDOR_COMPAQ 0x0e11 + const static uint8_t led_default_act[BWI_LED_MAX] = { + BWI_LED_ACT_ACTIVE, + BWI_LED_ACT_2GHZ, + BWI_LED_ACT_5GHZ, + BWI_LED_ACT_OFF + }; + + uint16_t gpio, val[BWI_LED_MAX]; + int i; + + gpio = bwi_read_sprom(sc, BWI_SPROM_GPIO01); + val[0] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_0); + val[1] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_1); + + gpio = bwi_read_sprom(sc, BWI_SPROM_GPIO23); + val[2] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_2); + val[3] = __SHIFTOUT(gpio, BWI_SPROM_GPIO_3); + + for (i = 0; i < BWI_LED_MAX; ++i) { + struct bwi_led *led = &sc->sc_leds[i]; + + if (val[i] == 0xff) { + led->l_act = led_default_act[i]; + if (i == 0 && sc->sc_pci_subvid == PCI_VENDOR_COMPAQ) + led->l_act = BWI_LED_ACT_RFEN; + } else { + if (val[i] & BWI_LED_ACT_LOW) + led->l_flags |= BWI_LED_F_ACTLOW; + led->l_act = __SHIFTOUT(val[i], BWI_LED_ACT_MASK); + } + + DPRINTF(sc, "%dth led, act %d, lowact %d\n", + i, led->l_act, led->l_flags & BWI_LED_F_ACTLOW); + } +#undef PCI_VENDOR_COMPAQ +} + +static void +bwi_led_newstate(struct bwi_softc *sc, enum ieee80211_state nstate) +{ + struct ieee80211com *ic = &sc->sc_ic; + uint16_t val; + int i; + + if ((ic->ic_ifp->if_drv_flags & IFF_DRV_RUNNING) == 0) + return; + + val = CSR_READ_2(sc, BWI_MAC_GPIO_CTRL); + for (i = 0; i < BWI_LED_MAX; ++i) { + struct bwi_led *led = &sc->sc_leds[i]; + int on; + + if (led->l_act == BWI_LED_ACT_UNKN || + led->l_act == BWI_LED_ACT_NULL) { + /* Don't touch it */ + continue; + } + + switch (led->l_act) { + case BWI_LED_ACT_ON: /* Always on */ + on = 1; + break; + case BWI_LED_ACT_OFF: /* Always off */ + case BWI_LED_ACT_5GHZ: /* TODO: 11A */ + case BWI_LED_ACT_MID: /* Blinking ones */ + case BWI_LED_ACT_FAST: + on = 0; + break; + default: + on = 1; + switch (nstate) { + case IEEE80211_S_INIT: + on = 0; + break; + case IEEE80211_S_RUN: + if (led->l_act == BWI_LED_ACT_11G && + ic->ic_curmode != IEEE80211_MODE_11G) + on = 0; + break; + default: + if (led->l_act == BWI_LED_ACT_RUN || + led->l_act == BWI_LED_ACT_ACTIVE) + on = 0; + break; + } + break; + } + + if (led->l_flags & BWI_LED_F_ACTLOW) + on = !on; + + if (on) + val |= (1 << i); + else + val &= ~(1 << i); + } + CSR_WRITE_2(sc, BWI_MAC_GPIO_CTRL, val); +} + +/* + * Covert PLCP signal/rate field to net80211 rate (.5Mbits/s) + */ +uint8_t +ieee80211_plcp2rate(uint8_t plcp, int ofdm) +{ + if (!ofdm) { + switch (plcp) { + /* IEEE Std 802.11b-1999 page 15, subclause 18.2.3.3 */ + case 0x0a: + case 0x14: + case 0x37: + case 0x6e: + /* IEEE Std 802.11g-2003 page 19, subclause 19.3.2.1 */ + case 0xdc: + return plcp / 5; + } + } else { +#define _OFDM_PLCP2RATE_MAX 16 + + /* IEEE Std 802.11a-1999 page 14, subclause 17.3.4.1 */ + static const uint8_t ofdm_plcp2rate[_OFDM_PLCP2RATE_MAX] = { + [0xb] = 12, + [0xf] = 18, + [0xa] = 24, + [0xe] = 36, + [0x9] = 48, + [0xd] = 72, + [0x8] = 96, + [0xc] = 108 + }; + if (plcp < _OFDM_PLCP2RATE_MAX) + return ofdm_plcp2rate[plcp]; + +#undef _OFDM_PLCP2RATE_MAX + } + return 0; +} + +enum ieee80211_modtype +ieee80211_rate2modtype(uint8_t rate) +{ + rate &= IEEE80211_RATE_VAL; + if (rate == 22 || rate < 12) + return IEEE80211_MODTYPE_DS; + else if (rate == 44) + return IEEE80211_MODTYPE_PBCC; + else + return IEEE80211_MODTYPE_OFDM; +} + +uint8_t +ieee80211_ack_rate(struct ieee80211_node *ni, uint8_t rate) +{ + const struct ieee80211_rateset *rs = &ni->ni_rates; + uint8_t ack_rate = 0; + enum ieee80211_modtype modtype; + int i; + + rate &= IEEE80211_RATE_VAL; + + modtype = ieee80211_rate2modtype(rate); + + for (i = 0; i < rs->rs_nrates; ++i) { + uint8_t rate1 = rs->rs_rates[i] & IEEE80211_RATE_VAL; + + if (rate1 > rate) { + if (ack_rate != 0) + return ack_rate; + else + break; + } + + if ((rs->rs_rates[i] & IEEE80211_RATE_BASIC) && + ieee80211_rate2modtype(rate1) == modtype) + ack_rate = rate1; + } + + switch (rate) { + /* CCK */ + case 2: + case 4: + case 11: + case 22: + ack_rate = rate; + break; + + /* PBCC */ + case 44: + ack_rate = 22; + break; + + /* OFDM */ + case 12: + case 18: + ack_rate = 12; + break; + case 24: + case 36: + ack_rate = 24; + break; + case 48: + case 72: + case 96: + case 108: + ack_rate = 48; + break; + default: + panic("unsupported rate %d\n", rate); + } + return ack_rate; +} + +/* IEEE Std 802.11a-1999, page 9, table 79 */ +#define IEEE80211_OFDM_SYM_TIME 4 +#define IEEE80211_OFDM_PREAMBLE_TIME 16 +#define IEEE80211_OFDM_SIGNAL_TIME 4 +/* IEEE Std 802.11g-2003, page 44 */ +#define IEEE80211_OFDM_SIGNAL_EXT_TIME 6 + +/* IEEE Std 802.11a-1999, page 7, figure 107 */ +#define IEEE80211_OFDM_PLCP_SERVICE_NBITS 16 +#define IEEE80211_OFDM_TAIL_NBITS 6 + +#define IEEE80211_OFDM_NBITS(frmlen) \ + (IEEE80211_OFDM_PLCP_SERVICE_NBITS + \ + ((frmlen) * NBBY) + \ + IEEE80211_OFDM_TAIL_NBITS) + +#define IEEE80211_OFDM_NBITS_PER_SYM(kbps) \ + (((kbps) * IEEE80211_OFDM_SYM_TIME) / 1000) + +#define IEEE80211_OFDM_NSYMS(kbps, frmlen) \ + howmany(IEEE80211_OFDM_NBITS((frmlen)), \ + IEEE80211_OFDM_NBITS_PER_SYM((kbps))) + +#define IEEE80211_OFDM_TXTIME(kbps, frmlen) \ + (IEEE80211_OFDM_PREAMBLE_TIME + \ + IEEE80211_OFDM_SIGNAL_TIME + \ + (IEEE80211_OFDM_NSYMS((kbps), (frmlen)) * IEEE80211_OFDM_SYM_TIME)) + +/* IEEE Std 802.11b-1999, page 28, subclause 18.3.4 */ +#define IEEE80211_CCK_PREAMBLE_LEN 144 +#define IEEE80211_CCK_PLCP_HDR_TIME 48 +#define IEEE80211_CCK_SHPREAMBLE_LEN 72 +#define IEEE80211_CCK_SHPLCP_HDR_TIME 24 + +#define IEEE80211_CCK_NBITS(frmlen) ((frmlen) * NBBY) +#define IEEE80211_CCK_TXTIME(kbps, frmlen) \ + (((IEEE80211_CCK_NBITS((frmlen)) * 1000) + (kbps) - 1) / (kbps)) + +uint16_t +ieee80211_txtime(struct ieee80211_node *ni, u_int len, uint8_t rs_rate, + uint32_t flags) +{ + struct ieee80211com *ic = ni->ni_ic; + enum ieee80211_modtype modtype; + uint16_t txtime; + int rate; + + rs_rate &= IEEE80211_RATE_VAL; + + rate = rs_rate * 500; /* ieee80211 rate -> kbps */ + + modtype = ieee80211_rate2modtype(rs_rate); + if (modtype == IEEE80211_MODTYPE_OFDM) { + /* + * IEEE Std 802.11a-1999, page 37, equation (29) + * IEEE Std 802.11g-2003, page 44, equation (42) + */ + txtime = IEEE80211_OFDM_TXTIME(rate, len); + if (ic->ic_curmode == IEEE80211_MODE_11G) + txtime += IEEE80211_OFDM_SIGNAL_EXT_TIME; + } else { + /* + * IEEE Std 802.11b-1999, page 28, subclause 18.3.4 + * IEEE Std 802.11g-2003, page 45, equation (43) + */ + if (modtype == IEEE80211_MODTYPE_PBCC) + ++len; + txtime = IEEE80211_CCK_TXTIME(rate, len); + + /* + * Short preamble is not applicable for DS 1Mbits/s + */ + if (rs_rate != 2 && (flags & IEEE80211_F_SHPREAMBLE)) { + txtime += IEEE80211_CCK_SHPREAMBLE_LEN + + IEEE80211_CCK_SHPLCP_HDR_TIME; + } else { + txtime += IEEE80211_CCK_PREAMBLE_LEN + + IEEE80211_CCK_PLCP_HDR_TIME; + } + } + return txtime; +} --- /dev/null +++ sys/dev/bwi/bwimac.h @@ -0,0 +1,99 @@ +/* + * Copyright (c) 2007 The DragonFly Project. All rights reserved. + * + * This code is derived from software contributed to The DragonFly Project + * by Sepherosa Ziehau + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in + * the documentation and/or other materials provided with the + * distribution. + * 3. Neither the name of The DragonFly Project nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific, prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED + * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, + * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT + * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $MidnightBSD: src/sys/dev/bwi/bwimac.h,v 1.1 2009/01/19 22:02:25 laffer1 Exp $ + * $DragonFly: src/sys/dev/netif/bwi/bwimac.h,v 1.1 2007/09/08 06:15:54 sephe Exp $ + */ + +#ifndef _BWI_MAC_H +#define _BWI_MAC_H + +int bwi_mac_attach(struct bwi_softc *, int, uint8_t); +int bwi_mac_lateattach(struct bwi_mac *); +void bwi_mac_detach(struct bwi_mac *); +int bwi_mac_init(struct bwi_mac *); +void bwi_mac_reset(struct bwi_mac *, int); +int bwi_mac_start(struct bwi_mac *); +int bwi_mac_stop(struct bwi_mac *); +void bwi_mac_shutdown(struct bwi_mac *); +void bwi_mac_updateslot(struct bwi_mac *, int); +void bwi_mac_set_promisc(struct bwi_mac *, int); + +void bwi_mac_calibrate_txpower(struct bwi_mac *); +void bwi_mac_set_tpctl_11bg(struct bwi_mac *, + const struct bwi_tpctl *); +void bwi_mac_init_tpctl_11bg(struct bwi_mac *); +void bwi_mac_dummy_xmit(struct bwi_mac *); +void bwi_mac_reset_hwkeys(struct bwi_mac *); +int bwi_mac_config_ps(struct bwi_mac *); + +uint16_t bwi_memobj_read_2(struct bwi_mac *, uint16_t, uint16_t); +uint32_t bwi_memobj_read_4(struct bwi_mac *, uint16_t, uint16_t); +void bwi_memobj_write_2(struct bwi_mac *, uint16_t, uint16_t, + uint16_t); +void bwi_memobj_write_4(struct bwi_mac *, uint16_t, uint16_t, + uint32_t); +void bwi_tmplt_write_4(struct bwi_mac *, uint32_t, uint32_t); +void bwi_hostflags_write(struct bwi_mac *, uint64_t); +uint64_t bwi_hostflags_read(struct bwi_mac *); + +#define MOBJ_WRITE_2(mac, objid, ofs, val) \ + bwi_memobj_write_2((mac), (objid), (ofs), (val)) +#define MOBJ_WRITE_4(mac, objid, ofs, val) \ + bwi_memobj_write_4((mac), (objid), (ofs), (val)) +#define MOBJ_READ_2(mac, objid, ofs) \ + bwi_memobj_read_2((mac), (objid), (ofs)) +#define MOBJ_READ_4(mac, objid, ofs) \ + bwi_memobj_read_4((mac), (objid), (ofs)) + +#define MOBJ_SETBITS_4(mac, objid, ofs, bits) \ + MOBJ_WRITE_4((mac), (objid), (ofs), \ + MOBJ_READ_4((mac), (objid), (ofs)) | (bits)) +#define MOBJ_CLRBITS_4(mac, objid, ofs, bits) \ + MOBJ_WRITE_4((mac), (objid), (ofs), \ + MOBJ_READ_4((mac), (objid), (ofs)) & ~(bits)) + +#define MOBJ_FILT_SETBITS_2(mac, objid, ofs, filt, bits) \ + MOBJ_WRITE_2((mac), (objid), (ofs), \ + (MOBJ_READ_2((mac), (objid), (ofs)) & (filt)) | (bits)) + +#define TMPLT_WRITE_4(mac, ofs, val) bwi_tmplt_write_4((mac), (ofs), (val)) + +#define HFLAGS_WRITE(mac, flags) bwi_hostflags_write((mac), (flags)) +#define HFLAGS_READ(mac) bwi_hostflags_read((mac)) +#define HFLAGS_CLRBITS(mac, bits) \ + HFLAGS_WRITE((mac), HFLAGS_READ((mac)) | (bits)) +#define HFLAGS_SETBITS(mac, bits) \ + HFLAGS_WRITE((mac), HFLAGS_READ((mac)) & ~(bits)) + +#endif /* !_BWI_MAC_H */ From laffer1 at midnightbsd.org Mon Jan 19 17:03:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:03:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: add bwi Message-ID: <200901192203.n0JM3t5K074676@stargazer.midnightbsd.org> Log Message: ----------- add bwi Added Files: ----------- src/sys/modules/bwi: Makefile (r1.1) -------------- next part -------------- --- /dev/null +++ sys/modules/bwi/Makefile @@ -0,0 +1,14 @@ +# $MidnightBSD: src/sys/modules/bwi/Makefile,v 1.1 2009/01/19 22:03:55 laffer1 Exp $ + +.PATH: ${.CURDIR}/../../dev/bwi + +KMOD= if_bwi + +SRCS= if_bwi.c if_bwi_pci.c bwimac.c bwiphy.c bwirf.c +SRCS+= device_if.h bus_if.h pci_if.h opt_inet.h opt_bwi.h + +opt_bwi.h: + echo '#define BWI_DEBUG 1' > opt_bwi.h + echo '#define BWI_DEBUG_VERBOSE 1' >> opt_bwi.h + +.include From laffer1 at midnightbsd.org Mon Jan 19 17:10:33 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:10:33 -0500 (EST) Subject: [Midnightbsd-cvs] src: README: Describe firmware situation. Message-ID: <200901192210.n0JMAXHi075701@stargazer.midnightbsd.org> Log Message: ----------- Describe firmware situation. (damn binary blobs) Added Files: ----------- src/sys/contrib/dev/bwi: README (r1.1) -------------- next part -------------- --- /dev/null +++ sys/contrib/dev/bwi/README @@ -0,0 +1,16 @@ +The bwi firmware is not available for distribution +with MidnightBSD. You must find it on the Internet. + +Look for v3 firmware. v4 will not work. Any device +requiring the newer firmware is not supported. + +One might find files like: + +a0g0bsinitvals2.fw b0g0bsinitvals2.fw ucode11.fw +a0g0bsinitvals5.fw b0g0bsinitvals5.fw ucode2.fw +a0g0initvals2.fw b0g0initvals2.fw ucode4.fw +a0g0initvals5.fw b0g0initvals5.fw ucode5.fw +a0g1bsinitvals5.fw pcm4.fw +a0g1initvals5.fw pcm5.fw + +$MidnightBSD: src/sys/contrib/dev/bwi/README,v 1.1 2009/01/19 22:10:32 laffer1 Exp $ From laffer1 at midnightbsd.org Mon Jan 19 17:11:08 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:11:08 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Add firmware makefile Message-ID: <200901192211.n0JMB8e8075798@stargazer.midnightbsd.org> Log Message: ----------- Add firmware makefile Added Files: ----------- src/sys/modules/bwifw: Makefile (r1.1) -------------- next part -------------- --- /dev/null +++ sys/modules/bwifw/Makefile @@ -0,0 +1,35 @@ +# $MidnightBSD: src/sys/modules/bwifw/Makefile,v 1.1 2009/01/19 22:11:07 laffer1 Exp $ + +.PATH: ${.CURDIR}/../../contrib/dev/bwi + +FWNAME= bwi_v3 +FWFILE= wl_apsta.o +_FWIMGS=ucode11 ucode2 ucode4 ucode5 \ + a0g0bsinitvals2 a0g0bsinitvals5 a0g0initvals2 \ + a0g0initvals5 a0g1bsinitvals5 a0g1initvals5 \ + b0g0bsinitvals2 b0g0bsinitvals5 b0g0initvals2 b0g0initvals5 \ + pcm4 pcm5 +FWIMGS= ${_FWIMGS:C/.*/&.fw/} +#CLEANFILES+=${FWFILE} ${FWIMGS} v3 + +#SUBDIR= fwcutter +#FWCUTTER= fwcutter/b43-fwcutter + +KMOD= ${FWNAME} +FIRMWS= ${_FWIMGS:C/.*/&.fw:${KMOD}_&/} + +bwi_v3: ${FWIMGS} + +# NB: the cutter has v3/v4 pathname prefixes built-in; yech +#${FWIMGS}: ${FWCUTTER} ${FWFILE} +# ln -s . v3; ${FWCUTTER} -w . ${FWFILE}; rm v3 + +${FWCUTTER}: fwcutter + +# NB: can't get make to use .PATH so do it explicitly +#BWI = ${.CURDIR}/../../contrib/dev/bwi + +#${FWFILE}: ${FWFILE}.uu +# uudecode -p < ${BWI}/${FWFILE}.uu > ${.TARGET} + +.include From laffer1 at midnightbsd.org Mon Jan 19 17:19:40 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:19:40 -0500 (EST) Subject: [Midnightbsd-cvs] src: sys/conf: Add bwi Message-ID: <200901192219.n0JMJeJB076487@stargazer.midnightbsd.org> Log Message: ----------- Add bwi Modified Files: -------------- src/sys/conf: files (r1.13 -> r1.14) options (r1.7 -> r1.8) -------------- next part -------------- Index: options =================================================================== RCS file: /home/cvs/src/sys/conf/options,v retrieving revision 1.7 retrieving revision 1.8 diff -L sys/conf/options -L sys/conf/options -u -r1.7 -r1.8 --- sys/conf/options +++ sys/conf/options @@ -723,6 +723,10 @@ ATH_DIAGAPI opt_ath.h ATH_TX99_DIAG opt_ath.h +# options for Broadcom wireless driver +BWI_DEBUG opt_bwi.h +BWI_DEBUG_VERBOSE opt_bwi.h + # dcons options DCONS_BUF_SIZE opt_dcons.h DCONS_POLL_HZ opt_dcons.h Index: files =================================================================== RCS file: /home/cvs/src/sys/conf/files,v retrieving revision 1.13 retrieving revision 1.14 diff -L sys/conf/files -L sys/conf/files -u -r1.13 -r1.14 --- sys/conf/files +++ sys/conf/files @@ -493,6 +493,11 @@ dev/bktr/bktr_os.c optional bktr pci dev/bktr/bktr_tuner.c optional bktr pci dev/bktr/msp34xx.c optional bktr pci +dev/bwi/if_bwi.c optional bwi +dev/bwi/if_bwi_pci.c optional bwi pci +dev/bwi/bwimac.c optional bwi +dev/bwi/bwiphy.c optional bwi +dev/bwi/bwirf.c optional bwi dev/buslogic/bt.c optional bt dev/buslogic/bt_eisa.c optional bt eisa dev/buslogic/bt_isa.c optional bt isa From laffer1 at midnightbsd.org Mon Jan 19 17:22:52 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:22:52 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/bwi: don't enable BWI_DEBUG here, use the opt_bwi.h for that. Message-ID: <200901192222.n0JMMqkY076958@stargazer.midnightbsd.org> Log Message: ----------- don't enable BWI_DEBUG here, use the opt_bwi.h for that. Modified Files: -------------- src/sys/dev/bwi: bwimac.c (r1.1 -> r1.2) bwirf.c (r1.1 -> r1.2) if_bwi.c (r1.1 -> r1.2) if_bwivar.h (r1.1 -> r1.2) -------------- next part -------------- Index: if_bwivar.h =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/if_bwivar.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/if_bwivar.h -L sys/dev/bwi/if_bwivar.h -u -r1.1 -r1.2 --- sys/dev/bwi/if_bwivar.h +++ sys/dev/bwi/if_bwivar.h @@ -85,7 +85,6 @@ #define CSR_CLRBITS_2(sc, reg, bits) \ CSR_WRITE_2((sc), (reg), CSR_READ_2((sc), (reg)) & ~(bits)) -#define BWI_DEBUG #ifdef BWI_DEBUG #define DPRINTF(sc, fmt, ...) device_printf(sc->sc_dev, fmt, __VA_ARGS__) #else Index: bwirf.c =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/bwirf.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/bwirf.c -L sys/dev/bwi/bwirf.c -u -r1.1 -r1.2 --- sys/dev/bwi/bwirf.c +++ sys/dev/bwi/bwirf.c @@ -38,6 +38,7 @@ #include #include "opt_inet.h" +#include "opt_bwi.h" #include #include Index: bwimac.c =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/bwimac.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/bwimac.c -L sys/dev/bwi/bwimac.c -u -r1.1 -r1.2 --- sys/dev/bwi/bwimac.c +++ sys/dev/bwi/bwimac.c @@ -38,6 +38,7 @@ #include #include "opt_inet.h" +#include "opt_bwi.h" #include #include Index: if_bwi.c =================================================================== RCS file: /home/cvs/src/sys/dev/bwi/if_bwi.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/dev/bwi/if_bwi.c -L sys/dev/bwi/if_bwi.c -u -r1.1 -r1.2 --- sys/dev/bwi/if_bwi.c +++ sys/dev/bwi/if_bwi.c @@ -38,6 +38,7 @@ #include #include "opt_inet.h" +#include "opt_bwi.h" #include #include From laffer1 at midnightbsd.org Mon Jan 19 17:28:38 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:28:38 -0500 (EST) Subject: [Midnightbsd-cvs] src: man/man4: Add bwi.4 (initial man page) from DragonFly Message-ID: <200901192228.n0JMScgs077623@stargazer.midnightbsd.org> Log Message: ----------- Add bwi.4 (initial man page) from DragonFly Modified Files: -------------- src/share/man/man4: Makefile (r1.11 -> r1.12) Added Files: ----------- src/share/man/man4: bwi.4 (r1.1) -------------- next part -------------- --- /dev/null +++ share/man/man4/bwi.4 @@ -0,0 +1,123 @@ +.\" +.\" Copyright (c) 2007 The DragonFly Project. All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in +.\" the documentation and/or other materials provided with the +.\" distribution. +.\" 3. Neither the name of The DragonFly Project nor the names of its +.\" contributors may be used to endorse or promote products derived +.\" from this software without specific, prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS +.\" ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT +.\" LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS +.\" FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE +.\" COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY OR CONSEQUENTIAL DAMAGES (INCLUDING, +.\" BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; +.\" LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED +.\" AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +.\" OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +.\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $MidnightBSD: src/share/man/man4/bwi.4,v 1.1 2009/01/19 22:28:38 laffer1 Exp $ +.\" $DragonFly: src/share/man/man4/bwi.4,v 1.8 2008/05/01 12:34:06 sephe Exp $ +.\" +.Dd January 19, 2009 +.Dt BWI 4 +.Os +.Sh NAME +.Nm bwi +.Nd Broadcom BCM430x/4318 IEEE 802.11b/g wireless network driver +.Sh SYNOPSIS +To load the driver as a module at boot time, place the +following line in +.Pa /boot/loader.conf : +.Bd -literal -offset indent +if_bwi_load="YES" +.Ed +.Sh DESCRIPTION +The +.Nm +driver provides support for Broadcom BCM430x/4318 wireless network adapters. +For more information on configuring this device, see +.Xr ifconfig 8 . +.Ss MIB Variables +The following per-interface variables are implemented in the +.Va hw.bwi Ns Em X +branch of the +.Xr sysctl 3 +MIB. +.Bl -tag -width ".Va txpwr_calib" +.It Va debug +Debug flags. +.It Va dwell_time +Channel dwell time during scan (msec). +.It Va fw_version +Firmware version. +.It Va led_idle +Number of ticks before LED enters idle state. +.It Va led_blink +Allow LED to blink. +.It Va txpwr_calib +Enable software TX power calibration. +.El +.Sh HARDWARE +The following cards are among those supported by the +.Nm +driver: +.Pp +.Bl -column -compact "Buffalo WLI-PCI-G54S" "BCM4318" "CardBus" "b/g" -offset 6n +.Em "Card Chip Bus Standard" +Linksys WPC54Gv3 BCM4318 CardBus b/g +Linksys WPC54GSv2 BCM4318 CardBus b/g +Buffalo WLI-CB-G54S BCM4318 CardBus b/g +Buffalo WLI-PCI-G54S BCM4306 PCI b/g +Dell Wireless 1470 BCM4318 Mini PCI b/g +Dell Truemobile 1400 BCM4309 Mini PCI b/g +.El +.Sh FILES +The firmware for the adapter is not shipped with +.Dx +and must be obtained separately. +An archive with firmware files that are known to work can be found at: +.Bd -literal -offset indent +http://leaf.dragonflybsd.org/~sephe/bwi/v3.tbz +.Ed +.Pp +The firmware files have to reside in +.Pa /etc/firmware/bwi +and will be loaded when the interface is brought up. +.Sh SEE ALSO +.Xr arp 4 , +.Xr cardbus 4 , +.Xr ifmedia 4 , +.Xr pci 4 , +.Xr wlan_ratectl 4 , +.Xr ifconfig 8 , +.Xr wpa_supplicant 8 +.Sh HISTORY +The +.Nm +driver first appeared in +.Dx 1.11 . +.Sh AUTHORS +.An -nosplit +The +.Nm +driver was written by +.An Sepherosa Ziehau . +.Pp +The hardware specification was reverse engineered by the people at +.Pa http://bcm-specs.sipsolutions.net . +Thanks go also to johill and mb on the #bcm-specs channel. +.Sh BUGS +BCM4306 and BCM4309 chips do not work properly on channel 1, 2 and 3. Index: Makefile =================================================================== RCS file: /home/cvs/src/share/man/man4/Makefile,v retrieving revision 1.11 retrieving revision 1.12 diff -L share/man/man4/Makefile -L share/man/man4/Makefile -u -r1.11 -r1.12 --- share/man/man4/Makefile +++ share/man/man4/Makefile @@ -39,6 +39,7 @@ bpf.4 \ bridge.4 \ bt.4 \ + bwi.4 \ cardbus.4 \ carp.4 \ ccd.4 \ From laffer1 at midnightbsd.org Mon Jan 19 17:40:09 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 19 Jan 2009 17:40:09 -0500 (EST) Subject: [Midnightbsd-cvs] src: bwi.4: Document the "temporary" firmware installation procedure and Message-ID: <200901192240.n0JMe9oK079005@stargazer.midnightbsd.org> Log Message: ----------- Document the "temporary" firmware installation procedure and make a few other adjustments for MidnightBSD. This must get better. Modified Files: -------------- src/share/man/man4: bwi.4 (r1.1 -> r1.2) -------------- next part -------------- Index: bwi.4 =================================================================== RCS file: /home/cvs/src/share/man/man4/bwi.4,v retrieving revision 1.1 retrieving revision 1.2 diff -L share/man/man4/bwi.4 -L share/man/man4/bwi.4 -u -r1.1 -r1.2 --- share/man/man4/bwi.4 +++ share/man/man4/bwi.4 @@ -86,16 +86,20 @@ .El .Sh FILES The firmware for the adapter is not shipped with -.Dx +.Mx and must be obtained separately. An archive with firmware files that are known to work can be found at: .Bd -literal -offset indent http://leaf.dragonflybsd.org/~sephe/bwi/v3.tbz .Ed .Pp -The firmware files have to reside in -.Pa /etc/firmware/bwi -and will be loaded when the interface is brought up. +The firmware files are built as part of the bwifw module and +must be loaded for +.Nm +to work. Place the files in +.Pa /usr/src/sys/contrib/dev/bwi +and build bwifw in +.Pa /usr/src/sys/modules/bwifw .Sh SEE ALSO .Xr arp 4 , .Xr cardbus 4 , @@ -108,13 +112,21 @@ The .Nm driver first appeared in -.Dx 1.11 . +.Dx 1.11 +and +.Mx 0.3 .Sh AUTHORS .An -nosplit The .Nm driver was written by .An Sepherosa Ziehau . +It was later ported to +.Fx 7.0 , +then brought into +.Mx 0.3 +by +.An Lucas Holt . .Pp The hardware specification was reverse engineered by the people at .Pa http://bcm-specs.sipsolutions.net . From laffer1 at midnightbsd.org Tue Jan 20 10:32:52 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 10:32:52 -0500 (EST) Subject: [Midnightbsd-cvs] mports: Makefile: science was missing Message-ID: <200901201532.n0KFWqBX088628@stargazer.midnightbsd.org> Log Message: ----------- science was missing Modified Files: -------------- mports: Makefile (r1.39 -> r1.40) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/Makefile,v retrieving revision 1.39 retrieving revision 1.40 diff -L Makefile -L Makefile -u -r1.39 -r1.40 --- Makefile +++ Makefile @@ -35,6 +35,7 @@ SUBDIR += palm SUBDIR += ports-mgmt SUBDIR += print +SUBDIR += science SUBDIR += security SUBDIR += shells SUBDIR += sysutils From laffer1 at midnightbsd.org Tue Jan 20 10:33:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 10:33:48 -0500 (EST) Subject: [Midnightbsd-cvs] mports: Makefile: tweak whitespace Message-ID: <200901201533.n0KFXmev088736@stargazer.midnightbsd.org> Log Message: ----------- tweak whitespace Modified Files: -------------- mports/science: Makefile (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/science/Makefile,v retrieving revision 1.3 retrieving revision 1.4 diff -L science/Makefile -L science/Makefile -u -r1.3 -r1.4 --- science/Makefile +++ science/Makefile @@ -1,8 +1,8 @@ # $MidnightBSD$ - COMMENT= science +COMMENT= science - SUBDIR += cfitsio - SUBDIR += openbabel +SUBDIR += cfitsio +SUBDIR += openbabel .include From laffer1 at midnightbsd.org Tue Jan 20 10:35:13 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 10:35:13 -0500 (EST) Subject: [Midnightbsd-cvs] mports: mports/dns: Change the description to something a little more Message-ID: <200901201535.n0KFZDHr089139@stargazer.midnightbsd.org> Log Message: ----------- Change the description to something a little more reasonable. Modified Files: -------------- mports/dns: Makefile (r1.15 -> r1.16) mports/science: Makefile (r1.4 -> r1.5) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/dns/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -L dns/Makefile -L dns/Makefile -u -r1.15 -r1.16 --- dns/Makefile +++ dns/Makefile @@ -1,22 +1,21 @@ # $MidnightBSD$ -# - COMMENT = Domain Name Service tools +COMMENT = Domain Name Service tools - SUBDIR += ares - SUBDIR += bind9 - SUBDIR += bind94 - SUBDIR += bind95 - SUBDIR += bindgraph - SUBDIR += c-ares - SUBDIR += ddclient - SUBDIR += ez-ipupdate - SUBDIR += inadyn - SUBDIR += libidn - SUBDIR += mdnsd - SUBDIR += nslint - SUBDIR += p5-Net-DNS - SUBDIR += p5-Net-DNS-Resolver-Programmable - SUBDIR += pdnsd +SUBDIR += ares +SUBDIR += bind9 +SUBDIR += bind94 +SUBDIR += bind95 +SUBDIR += bindgraph +SUBDIR += c-ares +SUBDIR += ddclient +SUBDIR += ez-ipupdate +SUBDIR += inadyn +SUBDIR += libidn +SUBDIR += mdnsd +SUBDIR += nslint +SUBDIR += p5-Net-DNS +SUBDIR += p5-Net-DNS-Resolver-Programmable +SUBDIR += pdnsd .include Index: Makefile =================================================================== RCS file: /home/cvs/mports/science/Makefile,v retrieving revision 1.4 retrieving revision 1.5 diff -L science/Makefile -L science/Makefile -u -r1.4 -r1.5 --- science/Makefile +++ science/Makefile @@ -1,6 +1,6 @@ # $MidnightBSD$ -COMMENT= science +COMMENT= Scientific applications SUBDIR += cfitsio SUBDIR += openbabel From laffer1 at midnightbsd.org Tue Jan 20 11:32:51 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 11:32:51 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Disable debugging by default, but leave the option handy Message-ID: <200901201632.n0KGWpIQ047056@stargazer.midnightbsd.org> Log Message: ----------- Disable debugging by default, but leave the option handy for me. Modified Files: -------------- src/sys/modules/bwi: Makefile (r1.1 -> r1.2) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/sys/modules/bwi/Makefile,v retrieving revision 1.1 retrieving revision 1.2 diff -L sys/modules/bwi/Makefile -L sys/modules/bwi/Makefile -u -r1.1 -r1.2 --- sys/modules/bwi/Makefile +++ sys/modules/bwi/Makefile @@ -8,7 +8,7 @@ SRCS+= device_if.h bus_if.h pci_if.h opt_inet.h opt_bwi.h opt_bwi.h: - echo '#define BWI_DEBUG 1' > opt_bwi.h - echo '#define BWI_DEBUG_VERBOSE 1' >> opt_bwi.h + echo '#define BWI_DEBUG 0' > opt_bwi.h +# echo '#define BWI_DEBUG_VERBOSE 1' >> opt_bwi.h .include From laffer1 at midnightbsd.org Tue Jan 20 12:39:35 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 12:39:35 -0500 (EST) Subject: [Midnightbsd-cvs] src: NOTES: add bwi(4) Message-ID: <200901201739.n0KHdZ15055454@stargazer.midnightbsd.org> Log Message: ----------- add bwi(4) Modified Files: -------------- src/sys/i386/conf: NOTES (r1.7 -> r1.8) -------------- next part -------------- Index: NOTES =================================================================== RCS file: /home/cvs/src/sys/i386/conf/NOTES,v retrieving revision 1.7 retrieving revision 1.8 diff -L sys/i386/conf/NOTES -L sys/i386/conf/NOTES -u -r1.7 -r1.8 --- sys/i386/conf/NOTES +++ sys/i386/conf/NOTES @@ -574,6 +574,7 @@ # (requires sppp) # arl: Aironet Arlan 655 wireless adapters. # ath: Atheros a/b/g WiFi adapters (requires ath_hal and wlan) +# bwi: Broadcom WiFi adapters. # ce: Cronyx Tau-PCI/32 sync single/dual port G.703/E1 serial adaptor # with 32 HDLC subchannels (requires sppp (default), or NETGRAPH if # NETGRAPH_CRONYX is configured) @@ -683,6 +684,8 @@ device ath_rate_sample # SampleRate rate control for the ath driver #device wlan # 802.11 layer +device bwi # Broadcom wireless 430x + # # ATA raid adapters # From laffer1 at midnightbsd.org Tue Jan 20 12:40:39 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 12:40:39 -0500 (EST) Subject: [Midnightbsd-cvs] src: DEFAULTS: Midnightize this Message-ID: <200901201740.n0KHedAL055815@stargazer.midnightbsd.org> Log Message: ----------- Midnightize this Modified Files: -------------- src/sys/i386/conf: DEFAULTS (r1.2 -> r1.3) -------------- next part -------------- Index: DEFAULTS =================================================================== RCS file: /home/cvs/src/sys/i386/conf/DEFAULTS,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/i386/conf/DEFAULTS -L sys/i386/conf/DEFAULTS -u -r1.2 -r1.3 --- sys/i386/conf/DEFAULTS +++ sys/i386/conf/DEFAULTS @@ -1,6 +1,7 @@ # -# DEFAULTS -- Default kernel configuration file for FreeBSD/i386 +# DEFAULTS -- Default kernel configuration file for MidnightBSD/i386 # +# $MidnightBSD$ # $FreeBSD: src/sys/i386/conf/DEFAULTS,v 1.10 2007/06/11 00:38:06 marcel Exp $ machine i386 From laffer1 at midnightbsd.org Tue Jan 20 12:45:25 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 12:45:25 -0500 (EST) Subject: [Midnightbsd-cvs] src: GENERIC: add commented out bwi(4) Message-ID: <200901201745.n0KHjPHV056426@stargazer.midnightbsd.org> Log Message: ----------- add commented out bwi(4) Modified Files: -------------- src/sys/i386/conf: GENERIC (r1.16 -> r1.17) -------------- next part -------------- Index: GENERIC =================================================================== RCS file: /home/cvs/src/sys/i386/conf/GENERIC,v retrieving revision 1.16 retrieving revision 1.17 diff -L sys/i386/conf/GENERIC -L sys/i386/conf/GENERIC -u -r1.16 -r1.17 --- sys/i386/conf/GENERIC +++ sys/i386/conf/GENERIC @@ -251,6 +251,8 @@ device ath_hal # Atheros Hardwar Abstraction Layer device ath_rate_sample # Atheros rate sampling. device awi # BayStack 660 and others +#device bwi # Broadcom Wireless 4300 +#device bwifw # Broadcom Wireless firmware (normally module) device ral # Ralink Technology RT2500 wireless NICs. device wi # WaveLAN/Intersil/Symbol 802.11 wireless NICs. #device wl # Older non 802.11 Wavelan wireless NIC. From laffer1 at midnightbsd.org Tue Jan 20 13:18:19 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 13:18:19 -0500 (EST) Subject: [Midnightbsd-cvs] src: GENERIC: Switch to new wiki page for documenation on kernel Message-ID: <200901201818.n0KIIJuf059867@stargazer.midnightbsd.org> Log Message: ----------- Switch to new wiki page for documenation on kernel Modified Files: -------------- src/sys/i386/conf: GENERIC (r1.17 -> r1.18) -------------- next part -------------- Index: GENERIC =================================================================== RCS file: /home/cvs/src/sys/i386/conf/GENERIC,v retrieving revision 1.17 retrieving revision 1.18 diff -L sys/i386/conf/GENERIC -L sys/i386/conf/GENERIC -u -r1.17 -r1.18 --- sys/i386/conf/GENERIC +++ sys/i386/conf/GENERIC @@ -1,10 +1,7 @@ # # GENERIC -- Generic kernel configuration file for MidnightBSD/i386 # -# The FreeBSD handbook is a good reference for kernel configuration information -# until we write our own documentation. -# -# http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/handbook/kernelconfig-config.html +# http://www.midnightbsd.org/wiki/KernelConfig # # An exhaustive list of options and more detailed explanations of the # device lines is also present in the ../../conf/NOTES and NOTES files. From laffer1 at midnightbsd.org Tue Jan 20 13:50:01 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 13:50:01 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/usb: add HUAWEI E220 Modem Message-ID: <200901201850.n0KIo13p063514@stargazer.midnightbsd.org> Log Message: ----------- add HUAWEI E220 Modem Modified Files: -------------- src/sys/dev/usb: ubsa.c (r1.3 -> r1.4) usbdevs (r1.4 -> r1.5) -------------- next part -------------- Index: usbdevs =================================================================== RCS file: /home/cvs/src/sys/dev/usb/usbdevs,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/usb/usbdevs -L sys/dev/usb/usbdevs -u -r1.4 -r1.5 --- sys/dev/usb/usbdevs +++ sys/dev/usb/usbdevs @@ -1382,6 +1382,7 @@ /* HUAWEI products */ product HUAWEI MOBILE 0x1001 Huawei Mobile +product HUAWEI E220 0x1003 Huawei E220 HSDPA USB Modem /* HUAWEI 3com products */ product HUAWEI3COM WUB320G 0x0009 Aolynk WUB320g Index: ubsa.c =================================================================== RCS file: /home/cvs/src/sys/dev/usb/ubsa.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/dev/usb/ubsa.c -L sys/dev/usb/ubsa.c -u -r1.3 -r1.4 --- sys/dev/usb/ubsa.c +++ sys/dev/usb/ubsa.c @@ -235,6 +235,8 @@ { USB_VENDOR_OPTION, USB_PRODUCT_OPTION_GT3GPLUS }, /* Huawei Mobile */ { USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_MOBILE }, + /* Huawei E220 USB Modem */ + { USB_VENDOR_HUAWEI, USB_PRODUCT_HUAWEI_E220 }, { 0, 0 } }; From laffer1 at midnightbsd.org Tue Jan 20 13:51:43 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 13:51:43 -0500 (EST) Subject: [Midnightbsd-cvs] src: ubsa.4: add Huawei Technologies Mobile and E220 G3 Modem Message-ID: <200901201851.n0KIphNO063915@stargazer.midnightbsd.org> Log Message: ----------- add Huawei Technologies Mobile and E220 G3 Modem Modified Files: -------------- src/share/man/man4: ubsa.4 (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: ubsa.4 =================================================================== RCS file: /home/cvs/src/share/man/man4/ubsa.4,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man4/ubsa.4 -L share/man/man4/ubsa.4 -u -r1.1.1.1 -r1.2 --- share/man/man4/ubsa.4 +++ share/man/man4/ubsa.4 @@ -71,6 +71,8 @@ .It Peracom single port serial adapter .It +Huawei Technologies Mobile and E220 G3 Modem +.It Vodafone Mobile Connect 3G datacard .El .Sh SEE ALSO From laffer1 at midnightbsd.org Tue Jan 20 14:29:07 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:29:07 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: use pause(9) instead of a tsleep() on a stack variable Message-ID: <200901201929.n0KJT7gR067802@stargazer.midnightbsd.org> Log Message: ----------- use pause(9) instead of a tsleep() on a stack variable Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.2 -> r1.3) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.2 -r1.3 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -3291,7 +3291,7 @@ return; } - tsleep(&error, PWAIT, "ssidscan", hz * 3); + pause("ssidscan", hz * 3); if (!NDIS_INITIALIZED(sc)) /* The interface was downed while we were sleeping */ return; From laffer1 at midnightbsd.org Tue Jan 20 14:32:22 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:32:22 -0500 (EST) Subject: [Midnightbsd-cvs] src: man/man9: remove old man pages Message-ID: <200901201932.n0KJWMrA068604@stargazer.midnightbsd.org> Log Message: ----------- remove old man pages Removed Files: ------------- src/share/man/man9: MUTEX_PROFILING.9 VFS_VPTOFH.9 devsw.9 vm_page_unmanage.9 -------------- next part -------------- --- share/man/man9/vm_page_unmanage.9 +++ /dev/null @@ -1,57 +0,0 @@ -.\" -.\" Copyright (C) 2001 Chad David . All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice(s), this list of conditions and the following disclaimer as -.\" the first lines of this file unmodified other than the possible -.\" addition of one or more copyright notices. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice(s), this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY -.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY -.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -.\" DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/vm_page_unmanage.9,v 1.3 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD: src/share/man/man9/vm_page_unmanage.9,v 1.2 2006/12/27 03:04:25 laffer1 Exp $ -.\" -.Dd July 17, 2001 -.Dt VM_PAGE_UNMANAGE 9 -.Os -.Sh NAME -.Nm vm_page_unmanage -.Nd "make a page unmanaged" -.Sh SYNOPSIS -.In sys/param.h -.In vm/vm.h -.In vm/vm_page.h -.Ft void -.Fn vm_page_unmanage "vm_page_t m" -.Sh DESCRIPTION -The -.Fn vm_page_unmanage -function flags that the page should no longer be managed by the VM system like -other pages. -The page is removed from any page queue it may be on, and after its -.Dv PG_UNMANAGED -flag is set, the page daemon will ignore it (if the page is -currently wired, it will not be removed from its current queue). -.Pp -Unmanaged pages are used by -.Dv OBJT_PHYS -objects to provide physical memory backed storage. -.Sh AUTHORS -This manual page was written by -.An Chad David Aq davidc at acns.ab.ca . --- share/man/man9/devsw.9 +++ /dev/null @@ -1,76 +0,0 @@ -.\" -.\" Copyright (C) 2001 Chad David . All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice(s), this list of conditions and the following disclaimer as -.\" the first lines of this file unmodified other than the possible -.\" addition of one or more copyright notices. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice(s), this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY -.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY -.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES -.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR -.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER -.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH -.\" DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/devsw.9,v 1.7 2005/06/28 20:15:18 hmp Exp $ -.\" -.Dd July 9, 2001 -.Dt DEVSW 9 -.Os -.Sh NAME -.Nm devsw -.Nd returns the -.Vt cdevsw -structure -.Sh SYNOPSIS -.In sys/param.h -.In sys/conf.h -.Ft "struct cdevsw *" -.Fn devsw "dev_t dev" -.Sh DESCRIPTION -The -.Fn devsw -function returns a pointer to the -.Vt cdevsw -structure associated -with this character device ID. -If -.Fa dev->si_cdevsw -is set it is -returned; otherwise, the -.Xr major 9 -offset into the -.Va cdevsw -array is returned. -.Pp -Its argument is: -.Bl -tag -width ".Fa dev" -.It Fa dev -The device whose -.Vt cdevsw -entry should be returned. -.El -.Sh RETURN VALUES -A pointer to a -.Vt cdevsw -structure. -.Sh SEE ALSO -.Xr major 9 , -.Xr minor 9 , -.Xr umajor 9 , -.Xr uminor 9 -.Sh AUTHORS -This manual page was written by -.An Chad David Aq davidc at acns.ab.ca . --- share/man/man9/MUTEX_PROFILING.9 +++ /dev/null @@ -1,189 +0,0 @@ -.\"- -.\" Copyright (c) 2004 Dag-Erling Co?dan Sm?rgrav -.\" Copyright (c) 2005 Robert N. M. Watson -.\" All rights reserved. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice, this list of conditions and the following disclaimer. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice, this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" 3. The name of the author may not be used to endorse or promote products -.\" derived from this software without specific prior written permission. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND -.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE -.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS -.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) -.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT -.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY -.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF -.\" SUCH DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/MUTEX_PROFILING.9,v 1.11 2005/06/15 13:31:23 ru Exp $ -.\" -.Dd January 7, 2005 -.Dt MUTEX_PROFILING 9 -.Os -.Sh NAME -.Nm MUTEX_PROFILING -.Nd kernel mutex profiling support -.Sh SYNOPSIS -.Cd "options MUTEX_PROFILING" -.Sh DESCRIPTION -The -.Dv MUTEX_PROFILING -kernel option adds support for measuring and reporting mutex use and -contention statistics. -These statistics are collated by -.Dq acquisition point . -Acquisition points are -distinct places in the kernel source code (identified by source file -name and line number) where a mutex is acquired. -.Pp -For each acquisition point, the following statistics are accumulated: -.Bl -bullet -.It -The total number of non-recursive acquisitions. -.It -The total time the mutex was held after being acquired at this point. -.It -The longest time the mutex was ever continuously held after being -acquired at this point. -.It -The total number of times the mutex was already held by another thread -when this point was reached, requiring a spin or a sleep. -.It -The total number of time another thread tried to acquire the mutex -while it was held after having been acquired at this point. -.El -.Pp -In addition, the average hold time is derived from the total hold time -and the number of acquisitions. -.Pp -The -.Dv MUTEX_PROFILING -kernel option also adds the following -.Xr sysctl 8 -variables to control and monitor the profiling code: -.Bl -tag -width indent -.It Va debug.mutex.prof.enable -Enable or disable the mutex profiling code. -This defaults to 0 (off). -.It Va debug.mutex.prof.reset -Reset the current mutex profiling buffers. -.It Va debug.mutex.prof.acquisitions -The total number of mutex acquisitions recorded. -.It Va debug.mutex.prof.records -The total number of acquisition points recorded. -Note that only active acquisition points (i.e., points that have been -reached at least once) are counted. -.It Va debug.mutex.prof.maxrecords -The maximum number of acquisition points the profiling code is capable -of monitoring. -Since it would not be possible to call -.Xr malloc 9 -from within the mutex profiling code, this is a static limit. -The number of records can be changed with the -.Dv MPROF_BUFFERS -kernel option. -.It Va debug.mutex.prof.rejected -The number of acquisition points that were ignored after the table -filled up. -.It Va debug.mutex.prof.hashsize -The size of the hash table used to map acquisition points to -statistics records. -The hash size can be changed with the -.Dv MPROF_HASH_SIZE -kernel option. -.It Va debug.mutex.prof.collisions -The number of hash collisions in the acquisition point hash table. -.It Va debug.mutex.prof.stats -The actual profiling statistics in plain text. -The columns are as follows, from left to right: -.Bl -tag -width ".Va cnt_hold" -.It Va max -The longest continuous hold time in microseconds. -.It Va total -The total (accumulated) hold time in microseconds. -.It Va count -The total number of acquisitions. -.It Va avg -The average hold time in microseconds, derived from the total hold time -and the number of acquisitions. -.It Va cnt_hold -The number of times the mutex was held and another thread attempted to -lock the mutex. -.It Va cnt_lock -The number of times the mutex was already locked when this point was -reached. -.It Va name -The name of the acquisition point, derived from the source file name -and line number, followed by the name of the mutex in parentheses. -.El -.El -.Sh SEE ALSO -.Xr sysctl 8 , -.Xr mutex 9 -.Sh HISTORY -Mutex profiling support appeared in -.Fx 5.0 . -.Sh AUTHORS -.An -nosplit -The -.Nm -code was written by -.An Eivind Eklund Aq eivind at FreeBSD.org , -.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org -and -.An Robert Watson Aq rwatson at FreeBSD.org . -This manual page was written by -.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org . -.Sh NOTES -The -.Dv MUTEX_PROFILING -option increases the size of -.Vt "struct mtx" , -so a kernel built with that option will not work with modules built -without it. -.Pp -The -.Dv MUTEX_PROFILING -option also prevents inlining of the mutex code, which results in a -fairly severe performance penalty. -It should therefore only be enabled on systems where mutex profiling -is actually needed. -.Dv MUTEX_PROFILING -will introduce a substantial performance overhead that is easily -monitorable using other profiling tools, so combining profiling tools -with -.Dv MUTEX_PROFILING -is not recommended. -.Pp -Measurements are made and stored in nanoseconds using -.Xr nanotime 9 , -but are presented in microseconds. -This should still be sufficient for the locks one would be most -interested in profiling (those that are held long and/or acquired -often). -.Pp -.Dv MUTEX_PROFILING -should generally not be used in combination with other debugging options, as -the results may be strongly affected by interactions between the features. -In particular, -.Dv MUTEX_PROFILING -will report higher than normal -.Xr uma 9 -lock contention when run with -.Dv INVARIANTS -due to extra locking that occurs when -.Dv INVARIANTS -is present; likewise, using it in combination with -.Dv WITNESS -will lead to much higher lock hold times and contention in profiling output. --- share/man/man9/VFS_VPTOFH.9 +++ /dev/null @@ -1,61 +0,0 @@ -.\" -*- nroff -*- -.\" -.\" Copyright (c) 1996 Doug Rabson -.\" -.\" All rights reserved. -.\" -.\" This program is free software. -.\" -.\" Redistribution and use in source and binary forms, with or without -.\" modification, are permitted provided that the following conditions -.\" are met: -.\" 1. Redistributions of source code must retain the above copyright -.\" notice, this list of conditions and the following disclaimer. -.\" 2. Redistributions in binary form must reproduce the above copyright -.\" notice, this list of conditions and the following disclaimer in the -.\" documentation and/or other materials provided with the distribution. -.\" -.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR -.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES -.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. -.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, -.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT -.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF -.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -.\" -.\" $FreeBSD: src/share/man/man9/VFS_VPTOFH.9,v 1.9 2003/10/23 06:24:55 hmp Exp $ -.\" -.Dd July 24, 1996 -.Os -.Dt VFS_VPTOFH 9 -.Sh NAME -.Nm VFS_VPTOFH -.Nd turn a vnode into an NFS filehandle -.Sh SYNOPSIS -.In sys/param.h -.In sys/mount.h -.In sys/vnode.h -.Ft int -.Fn VFS_VPTOFH "struct vnode *vp" "struct fid *fhp" -.Sh DESCRIPTION -This is used by the NFS server to create an opaque filehandle which -uniquely identifies the file and which can be used by an NFS client -to access the file in the future. -.Pp -Its arguments are: -.Bl -tag -width fhp -.It Fa vp -The vnode to make a filehandle for. -.It Fa fhp -Return parameter for the filehandle. -.El -.Sh SEE ALSO -.Xr VFS 9 , -.Xr VFS_FHTOVP 9 , -.Xr vnode 9 -.Sh AUTHORS -This manual page was written by -.An Doug Rabson . From laffer1 at midnightbsd.org Tue Jan 20 14:37:49 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:37:49 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: stop kernel panics when ndis fails to attach and it's Message-ID: <200901201937.n0KJbn4c069182@stargazer.midnightbsd.org> Log Message: ----------- stop kernel panics when ndis fails to attach and it's not a wifi device Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.3 -> r1.4) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.3 -r1.4 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -966,7 +966,8 @@ } else NDIS_UNLOCK(sc); - taskqueue_drain(sc->ndis_tq, &sc->ndis_scantask); + if (sc->ndis_80211) + taskqueue_drain(sc->ndis_tq, &sc->ndis_scantask); if (sc->ndis_tickitem != NULL) IoFreeWorkItem(sc->ndis_tickitem); @@ -1025,7 +1026,8 @@ if (sc->ndis_iftype == PCIBus) bus_dma_tag_destroy(sc->ndis_parent_tag); - taskqueue_free(sc->ndis_tq); + if (sc->ndis_80211) + taskqueue_free(sc->ndis_tq); return(0); } From laffer1 at midnightbsd.org Tue Jan 20 14:40:54 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:40:54 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: Fix a problem with broadcom and marvell wifi using ndis. Message-ID: <200901201940.n0KJes3q069600@stargazer.midnightbsd.org> Log Message: ----------- Fix a problem with broadcom and marvell wifi using ndis. Scan results are not stored properly as some do not give a desired buffer length. Make a default. This fixes problems with some macbooks too Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.4 -> r1.5) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.4 retrieving revision 1.5 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.4 -r1.5 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -2544,13 +2544,20 @@ return(ENOENT); } - len = 4; - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, NULL, &len); - if (error != ENOSPC) - len = 65536; + len = sizeof(uint32_t) + (sizeof(ndis_wlan_bssid_ex) * 16); + bl = malloc(len, M_TEMP, M_NOWAIT | M_ZERO); + if (bl == NULL) + return (ENOMEM); - bl = malloc(len, M_TEMP, M_NOWAIT|M_ZERO); error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + if (error == ENOSPC) { + free(bl, M_TEMP); + bl = malloc(len, M_TEMP, M_NOWAIT | M_ZERO); + if (bl == NULL) + return (ENOMEM); + + error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + } if (error) { free(bl, M_TEMP); device_printf(sc->ndis_dev, "bssid_list failed\n"); @@ -3317,13 +3324,22 @@ uint8_t rates[2+IEEE80211_RATE_MAXSIZE]; uint8_t *frm, *efrm; - len = 0; noise = -96; - error = ndis_get_info(sc, OID_802_11_BSSID_LIST, NULL, &len); - if (error != ENOSPC) - len = 65536; + + len = sizeof(uint32_t) + (sizeof(ndis_wlan_bssid_ex) * 16); bl = malloc(len, M_DEVBUF, M_NOWAIT | M_ZERO); + if (bl == NULL) + return; + error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + if (error == ENOSPC) { + free(bl, M_DEVBUF); + bl = malloc(len, M_DEVBUF, M_NOWAIT | M_ZERO); + if (bl == NULL) + return; + + error = ndis_get_info(sc, OID_802_11_BSSID_LIST, bl, &len); + } if (error) { DPRINTF(("%s: failed to read\n", __func__)); free(bl, M_DEVBUF); From laffer1 at midnightbsd.org Tue Jan 20 14:44:28 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:44:28 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: cast to printf properly Message-ID: <200901201944.n0KJiSKa069813@stargazer.midnightbsd.org> Log Message: ----------- cast to printf properly Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.5 -> r1.6) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.5 retrieving revision 1.6 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.5 -r1.6 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -2432,7 +2432,7 @@ else bcopy(ifp->if_broadcastaddr, bssid, len); - DPRINTF(("Setting BSSID to %6D\n", &bssid, ":")); + DPRINTF(("Setting BSSID to %6D\n", (uint8_t *)&bssid, ":")); rval = ndis_set_info(sc, OID_802_11_BSSID, &bssid, &len); if (rval) device_printf(sc->ndis_dev, From laffer1 at midnightbsd.org Tue Jan 20 14:53:11 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:53:11 -0500 (EST) Subject: [Midnightbsd-cvs] src: if_ndis.c: This fix was found in freebsd pr 124225 Description: Message-ID: <200901201953.n0KJrB2Q070766@stargazer.midnightbsd.org> Log Message: ----------- This fix was found in freebsd pr 124225 Description: Normally, when packets are queued to the ndis network interface, ndis_start() is called to move packets from the interface send queue to the underlying NDIS driver. If the network link is down or the underlying driver is busy transmitting data, ndis_start() just returns. When the link goes up, ndis_starttask() is supposed to be called after ndis_ticktask() in order to transmit already queued packets. After a watchdog timeout, ndis_starttask() is likewise supposed to be called after ndis_resettask(). Unfortunately, work items used for triggering calls to ndis_ticktask(), ndis_starttask() and ndis_resettask() are placed on separarate task lists which are handled by separate kernel processes, thus losing ordering information about when the tasks should be performed in relation to each other. If the interface send queue is full after a watchdog timeout or link up event and the tasks were handled in the wrong order then further attempts to send packets via the interface results in ENOBUFS ("No buffer space available"). How-To-Repeat: Use the ndis driver for a wireless network card in an area with many APs on nearby channels and on a machine with many active tcp connections, causing link to temporarily go down every few hours, and the interface send queue to be filled while the link is temporarily down. Fix: A proper fix is to ensure that related tasks are handled in the correct order. The following kludge justs add extra attempts at scheduling calls to ndis_starttask() as part of the processing of ndis_ticktask() and ndis_resettask(). It depends on defensive coding in IoQueueWorkItem(), i.e. that nothing is done if the work item is already queued. Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.6 -> r1.7) -------------- next part -------------- Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.6 retrieving revision 1.7 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.6 -r1.7 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -1564,6 +1564,7 @@ IoQueueWorkItem(sc->ndis_tickitem, (io_workitem_func)ndis_ticktask_wrap, WORKQUEUE_CRITICAL, sc); + /* XXX: startitem might be handled before tickitem */ IoQueueWorkItem(sc->ndis_startitem, (io_workitem_func)ndis_starttask_wrap, WORKQUEUE_CRITICAL, ifp); @@ -1647,6 +1648,11 @@ ieee80211_new_state(ic, IEEE80211_S_RUN, -1); } NDIS_LOCK(sc); + /* XXX: Start kludge */ + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_starttask_wrap, + WORKQUEUE_CRITICAL, sc->ifp); + /* XXX: End kludge */ #ifdef LINK_STATE_UP if_link_state_change(sc->ifp, LINK_STATE_UP); #else @@ -3146,6 +3152,11 @@ sc = arg; ndis_reset_nic(sc); + /* XXX: Start kludge */ + IoQueueWorkItem(sc->ndis_startitem, + (io_workitem_func)ndis_starttask_wrap, + WORKQUEUE_CRITICAL, sc->ifp); + /* XXX: End kludge */ return; } @@ -3165,6 +3176,7 @@ IoQueueWorkItem(sc->ndis_resetitem, (io_workitem_func)ndis_resettask_wrap, WORKQUEUE_CRITICAL, sc); + /* XXX: startitem might be handled before resetitem */ IoQueueWorkItem(sc->ndis_startitem, (io_workitem_func)ndis_starttask_wrap, WORKQUEUE_CRITICAL, ifp); From laffer1 at midnightbsd.org Tue Jan 20 14:31:08 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 14:31:08 -0500 (EST) Subject: [Midnightbsd-cvs] src: man/man9: update section 9 of the manual Message-ID: <200901201931.n0KJV8qA068473@stargazer.midnightbsd.org> Log Message: ----------- update section 9 of the manual Modified Files: -------------- src/share/man/man9: BUS_SETUP_INTR.9 (r1.1.1.1 -> r1.2) DECLARE_GEOM_CLASS.9 (r1.1.1.1 -> r1.2) EVENTHANDLER.9 (r1.1.1.1 -> r1.2) Makefile (r1.2 -> r1.3) SYSCALL_MODULE.9 (r1.1.1.1 -> r1.2) VFS.9 (r1.1.1.1 -> r1.2) VFS_LOCK_GIANT.9 (r1.1.1.1 -> r1.2) VFS_ROOT.9 (r1.1.1.1 -> r1.2) VFS_SET.9 (r1.1.1.1 -> r1.2) VFS_SYNC.9 (r1.1.1.1 -> r1.2) VOP_FSYNC.9 (r1.1.1.1 -> r1.2) VOP_LISTEXTATTR.9 (r1.1.1.1 -> r1.2) VOP_OPENCLOSE.9 (r1.1.1.1 -> r1.2) VOP_REMOVE.9 (r1.1.1.1 -> r1.2) VOP_RENAME.9 (r1.1.1.1 -> r1.2) acl.9 (r1.1.1.1 -> r1.2) alloc_unr.9 (r1.1.1.2 -> r1.2) atomic.9 (r1.1.1.1 -> r1.2) bios.9 (r1.1.1.1 -> r1.2) bpf.9 (r1.1.1.1 -> r1.2) buf.9 (r1.1.1.1 -> r1.2) bus_alloc_resource.9 (r1.1.1.1 -> r1.2) bus_dma.9 (r1.1.1.1 -> r1.2) bus_space.9 (r1.1.1.1 -> r1.2) condvar.9 (r1.1.1.1 -> r1.2) contigmalloc.9 (r1.1.1.1 -> r1.2) critical_enter.9 (r1.1.1.1 -> r1.2) crypto.9 (r1.1.1.1 -> r1.2) device_add_child.9 (r1.1.1.1 -> r1.2) device_get_softc.9 (r1.1.1.1 -> r1.2) device_set_driver.9 (r1.1.1.1 -> r1.2) disk.9 (r1.1.1.1 -> r1.2) driver.9 (r1.1.1.1 -> r1.2) extattr.9 (r1.1.1.1 -> r1.2) firmware.9 (r1.2 -> r1.3) g_bio.9 (r1.1.1.1 -> r1.2) g_consumer.9 (r1.1.1.1 -> r1.2) hash.9 (r1.1 -> r1.2) hashinit.9 (r1.1.1.1 -> r1.2) ieee80211_ioctl.9 (r1.1.1.2 -> r1.2) ifnet.9 (r1.1.1.1 -> r1.2) ithread.9 (r1.1.1.1 -> r1.2) kobj.9 (r1.1.1.1 -> r1.2) ktr.9 (r1.1.1.1 -> r1.2) lock.9 (r1.1.1.1 -> r1.2) mac.9 (r1.1.1.1 -> r1.2) make_dev.9 (r1.1.1.1 -> r1.2) mbuf.9 (r1.2 -> r1.3) memguard.9 (r1.1.1.1 -> r1.2) mi_switch.9 (r1.1.1.1 -> r1.2) microtime.9 (r1.1.1.1 -> r1.2) module.9 (r1.1.1.1 -> r1.2) mtx_pool.9 (r1.1.1.1 -> r1.2) mutex.9 (r1.1.1.2 -> r1.2) namei.9 (r1.1.1.1 -> r1.2) p_candebug.9 (r1.1.1.1 -> r1.2) pci.9 (r1.1.1.1 -> r1.2) pfil.9 (r1.1.1.1 -> r1.2) pmap_extract.9 (r1.1.1.1 -> r1.2) pmap_remove.9 (r1.1.1.1 -> r1.2) pmap_zero_page.9 (r1.2 -> r1.3) printf.9 (r1.1.1.1 -> r1.2) pseudofs.9 (r1.1.1.1 -> r1.2) rman.9 (r1.1.1.1 -> r1.2) rtentry.9 (r1.1.1.1 -> r1.2) sbuf.9 (r1.1.1.1 -> r1.2) securelevel_gt.9 (r1.1.1.1 -> r1.2) selrecord.9 (r1.1.1.1 -> r1.2) sema.9 (r1.1.1.1 -> r1.2) sleep.9 (r1.2 -> r1.3) sleepqueue.9 (r1.1.1.1 -> r1.2) style.9 (r1.1.1.1 -> r1.2) suser.9 (r1.1.1.1 -> r1.2) sx.9 (r1.1.1.1 -> r1.2) sysctl_add_oid.9 (r1.1.1.1 -> r1.2) sysctl_ctx_init.9 (r1.1.1.1 -> r1.2) taskqueue.9 (r1.1.1.1 -> r1.2) thread_exit.9 (r1.1.1.1 -> r1.2) time.9 (r1.1.1.1 -> r1.2) timeout.9 (r1.1.1.1 -> r1.2) uio.9 (r1.1.1.1 -> r1.2) utopia.9 (r1.1.1.1 -> r1.2) vflush.9 (r1.1.1.1 -> r1.2) vgone.9 (r1.1.1.1 -> r1.2) vhold.9 (r1.1.1.1 -> r1.2) vm_map.9 (r1.1.1.1 -> r1.2) vm_map_stack.9 (r1.1.1.1 -> r1.2) vm_page_deactivate.9 (r1.1.1.1 -> r1.2) vm_page_free.9 (r1.2 -> r1.3) vm_page_grab.9 (r1.2 -> r1.3) vm_page_hold.9 (r1.2 -> r1.3) vm_page_insert.9 (r1.2 -> r1.3) vm_page_io.9 (r1.2 -> r1.3) vm_page_lookup.9 (r1.2 -> r1.3) vm_page_protect.9 (r1.2 -> r1.3) vm_page_rename.9 (r1.2 -> r1.3) vm_page_sleep_busy.9 (r1.2 -> r1.3) vm_page_wakeup.9 (r1.2 -> r1.3) vm_page_wire.9 (r1.2 -> r1.3) vm_page_zero_fill.9 (r1.2 -> r1.3) vm_set_page_size.9 (r1.2 -> r1.3) vn_fullpath.9 (r1.2 -> r1.3) vn_isdisk.9 (r1.2 -> r1.3) vnode.9 (r1.2 -> r1.3) vput.9 (r1.2 -> r1.3) vref.9 (r1.2 -> r1.3) vrele.9 (r1.2 -> r1.3) vslock.9 (r1.2 -> r1.3) watchdog.9 (r1.2 -> r1.3) zero_copy.9 (r1.2 -> r1.3) zone.9 (r1.2 -> r1.3) Added Files: ----------- src/share/man/man9: LOCK_PROFILING.9 (r1.1) VOP_VPTOFH.9 (r1.1) config_intrhook.9 (r1.1) cr_cansee.9 (r1.1) device_get_sysctl.9 (r1.1) kqueue.9 (r1.1) locking.9 (r1.1) p_cansee.9 (r1.1) priv.9 (r1.1) redzone.9 (r1.1) rwlock.9 (r1.1) sf_buf.9 (r1.1) socket.9 (r1.1) stack.9 (r1.1) sysctl.9 (r1.1) usbdi.9 (r1.1) vfs_getopt.9 (r1.1) -------------- next part -------------- Index: printf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/printf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/printf.9 -L share/man/man9/printf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/printf.9 +++ share/man/man9/printf.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/printf.9,v 1.6.2.1 2005/08/18 15:01:24 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/printf.9,v 1.8 2006/09/08 14:05:03 ru Exp $ .\" -.Dd August 10, 2004 +.Dd September 8, 2006 .Dt PRINTF 9 .Os .Sh NAME @@ -90,7 +90,7 @@ for example, \e10 gives octal and \e20 gives hexadecimal. The arguments are made up of a sequence of bit identifiers. Each bit identifier begins with an integer value which is the number of the -bit this identifier describes. +bit (starting from 1) this identifier describes. The rest of the identifier is a string of characters containing the name of the bit. The string is terminated by either the bit number at the start of the next @@ -140,7 +140,11 @@ .Fn uprintf functions return the number of characters displayed. .Sh EXAMPLES -This example demonstrates the use of the \&%b and \&%D conversion specifiers. +This example demonstrates the use of the +.Cm \&%b +and +.Cm \&%D +conversion specifiers. The function .Bd -literal -offset indent void Index: vm_page_hold.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_hold.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_hold.9 -L share/man/man9/vm_page_hold.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_hold.9 +++ share/man/man9/vm_page_hold.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_hold.9,v 1.4 2002/04/05 08:05:11 davidc Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_HOLD 9 Index: contigmalloc.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/contigmalloc.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/contigmalloc.9 -L share/man/man9/contigmalloc.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/contigmalloc.9 +++ share/man/man9/contigmalloc.9 @@ -23,9 +23,9 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/contigmalloc.9,v 1.6 2005/02/22 17:20:20 brueffer Exp $ +.\" $FreeBSD: src/share/man/man9/contigmalloc.9,v 1.7 2007/07/19 17:23:20 alc Exp $ .\" -.Dd August 10, 2004 +.Dd July 19, 2007 .Dt CONTIGMALLOC 9 .Os .Sh NAME @@ -77,7 +77,14 @@ .Bl -tag -width indent .It Dv M_ZERO Causes the allocated physical memory to be zero filled. +.It Dv M_NOWAIT +Causes +.Fn contigmalloc +to return +.Dv NULL +if the request cannot be immediately fulfilled due to resource shortage. .El +.Pp Other flags (if present) are ignored. .Pp The @@ -88,10 +95,11 @@ The .Fn contigmalloc function does not sleep waiting for memory resources to be freed up, -but instead scans available physical memory a small number of times -for a suitably sized free address range before giving up. -Memory allocation is done on a first-fit basis, starting from the -top of the provided address range. +but instead actively reclaims pages before giving up. +However, unless +.Dv M_NOWAIT +is specified, it may select a page for reclamation that must first be +written to backing storage, causing it to sleep. .Sh RETURN VALUES The .Fn contigmalloc --- /dev/null +++ share/man/man9/vfs_getopt.9 @@ -0,0 +1,198 @@ +.\" +.\" Copyright (C) 2007 Chad David . All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/vfs_getopt.9,v 1.2 2007/03/04 19:04:39 ru Exp $ +.\" +.Dd February 28, 2007 +.Dt VFS_GETOPT 9 +.Os +.Sh NAME +.Nm vfs_getopt , +.Nm vfs_getopts , +.Nm vfs_flagopt , +.Nm vfs_scanopt , +.Nm vfs_copyopt , +.Nm vfs_filteropt +.Nd "manipulate mount options and their values" +.Sh SYNOPSIS +.In sys/param.h +.In sys/mount.h +.Ft int +.Fo vfs_getopt +.Fa "struct vfsoptlist *opts" "const char *name" "void **buf" "int *len" +.Fc +.Ft "char *" +.Fn vfs_getops "struct vfsoptlist *opts" "const char *name" "int *error" +.Ft int +.Fo vfs_flagopt +.Fa "struct vfsoptlist *opts" "const char *name" "u_int *flags" "u_int flag" +.Fc +.Ft int +.Fo vfs_scanopt +.Fa "struct vfsoptlist *opts" "const char *name" "const char *fmt" ... +.Fc +.Ft int +.Fo vfs_copyopt +.Fa "struct vfsoptlist *opts" "const char *name" "void *dest" "int len" +.Fc +.Ft int +.Fo vfs_filteropt +.Fa "struct vfsoptlist *opts" "const char **legal" +.Fc +.Sh DESCRIPTION +The +.Fn vfs_getopt +function sets +.Fa buf +to point to the value of the named mount option, and sets +.Fa len +to the length of the value if it is not +.Dv NULL . +The +.Fa buf +argument +will point to the actual value, and does not need to be freed or released +(and probably should not be modified). +.Pp +The +.Fn vfs_getopts +function +returns the value of the specified option if it is a string (i.e., +.Dv NUL +terminated). +.Pp +The +.Fn vfs_flagopt +function determines if an option exists. +If the option does exist, and +.Fa flags +is not +.Dv NULL , +.Fa flag +is added to those already set in +.Fa flags . +If the option does not exist, and +.Fa flags +is not +.Dv NULL , +.Fa flag +is removed from those already set in +.Fa flags . +An example of typical usage is: +.Bd -literal +if (vfs_flagopt(mp->mnt_optnew, "wormlike", NULL, 0)) + vfs_flagopt(mp->mnt_optnew, "appendok", &(mp->flags), F_APPENDOK); +.Ed +.Pp +The +.Fn vfs_scanopt +function performs a +.Xr vsscanf 3 +with the options value, using the given format, +into the specified variable arguments. +The value must be a string (i.e., +.Dv NUL +terminated). +.Pp +The +.Fn vfs_copyopt +function creates a copy of the options value. +The +.Fa len +argument must match the length of the options value exactly +(i.e., a larger buffer will still cause +.Fn vfs_copyout +to fail with +.Er EINVAL ) . +.Pp +The +.Fn vfs_filteropt +function ensures that no unknown options were specified. +A option is valid if its name matches one of the names in the +list of legal names. +An option may be prefixed with 'no', and still be considered valid. +.Sh RETURN VALUES +The +.Fn vfs_getopt +function returns 0 if the option was found; otherwise, +.Er ENOENT +is returned. +.Pp +The +.Fn vfs_getops +function returns the specified option if it is found, and is +.Dv NUL +terminated. +If the option was found, but is not +.Dv NUL +terminated, +.Fa error +is set to +.Er EINVAL +and +.Dv NULL +is returned. +If the option was not found, +.Fa error +is set to 0, and +.Dv NULL +is returned. +.Pp +The +.Fn vfs_flagopt +function returns 1 if the option was found, and 0 if it was not. +.Pp +The +.Fn vfs_scanopt +function returns 0 if the option was not found, or was not +.Dv NUL +terminated; otherwise, the return value of +.Xr vsscanf 3 +is returned. +If +.Xr vsscanf 3 +returns 0, it will be returned unchanged; therefore, a return value of 0 does +not always mean the option does not exist, or is not a valid string. +.Pp +The +.Fn vfs_copyopt +function returns 0 if the copy was successful, +.Er EINVAL +if the option was found but the lengths did not match, and +.Er ENOENT +if the option was not found. +.Pp +The +.Fn vfs_filteropt +function returns 0 if all of the options are legal; otherwise, +.Er EINVAL +is returned. +.Sh AUTHORS +.An -nosplit +This manual page was written by +.An Chad David Aq davidc at FreeBSD.org +and +.An Ruslan Ermilov Aq ru at FreeBSD.org . Index: device_add_child.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/device_add_child.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/device_add_child.9 -L share/man/man9/device_add_child.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/device_add_child.9 +++ share/man/man9/device_add_child.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/device_add_child.9,v 1.19 2004/07/03 18:29:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/device_add_child.9,v 1.25 2006/09/12 15:48:22 imp Exp $ .\" -.Dd May 13, 2004 +.Dd September 12, 2006 .Dt DEVICE_ADD_CHILD 9 .Os .Sh NAME @@ -67,8 +67,8 @@ as PCI) to allow each driver to check each device instance for a match. For busses which rely on supplied probe hints where only one -driver can have a change of probing the device, the driver name should -specified as the device name. +driver can have a chance of probing the device, the driver name should +be specified as the device name. .Pp Normally unit numbers will be chosen automatically by the system and a unit number of @@ -96,8 +96,10 @@ .Pp When adding a device in the context of .Xr DEVICE_IDENTIFY 9 -routine, some care must be taken to ensure that the device has not -already been added to the tree. +routine, the +.Xr device_find_child 9 +routine should be used to ensure that the device has not already been +added to the tree. Because the device name and .Vt devclass_t are associated at probe time (not child addition time), previous @@ -106,10 +108,18 @@ Authors of bus drivers must likewise be careful when adding children when they are loaded and unloaded to avoid duplication of children devices. +.Pp +Identify routines should use +.Xr BUS_ADD_CHILD 9 +instead of +.Xr device_add_child 9 . .Sh RETURN VALUES The new device if successful, NULL otherwise. .Sh SEE ALSO -.Xr device 9 +.Xr BUS_ADD_CHILD 9 , +.Xr device 9 , +.Xr device_find_child 9 , +.Xr DEVICE_IDENTIFY 9 .Sh AUTHORS This manual page was written by .An Doug Rabson . Index: sysctl_ctx_init.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sysctl_ctx_init.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sysctl_ctx_init.9 -L share/man/man9/sysctl_ctx_init.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sysctl_ctx_init.9 +++ share/man/man9/sysctl_ctx_init.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sysctl_ctx_init.9,v 1.12 2004/07/03 18:29:24 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sysctl_ctx_init.9,v 1.14 2007/07/27 19:55:42 remko Exp $ .\" .Dd July 15, 2000 .Dt SYSCTL_CTX_INIT 9 @@ -135,7 +135,8 @@ as the oid number when creating an oid. However, during registration of the oid in the tree, this number is changed to the first available number -greater than 99. +greater than or equal to +.Dv CTL_AUTO_START . If the first step of context deletion fails, re-registration of the oid does not change the already assigned oid number (which is different from OID_AUTO). @@ -225,6 +226,7 @@ .Sh SEE ALSO .Xr queue 3 , .Xr sysctl 8 , +.Xr sysctl 9 , .Xr sysctl_add_oid 9 , .Xr sysctl_remove_oid 9 .Sh HISTORY Index: extattr.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/extattr.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/extattr.9 -L share/man/man9/extattr.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/extattr.9 +++ share/man/man9/extattr.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/extattr.9,v 1.15 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/extattr.9,v 1.17 2007/03/06 08:13:21 mckusick Exp $ .\" .Dd December 23, 1999 .Os Index: securelevel_gt.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/securelevel_gt.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/securelevel_gt.9 -L share/man/man9/securelevel_gt.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/securelevel_gt.9 +++ share/man/man9/securelevel_gt.9 @@ -24,9 +24,9 @@ .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. -.\" $FreeBSD: src/share/man/man9/securelevel_gt.9,v 1.1 2004/03/07 15:22:08 josef Exp $ +.\" $FreeBSD: src/share/man/man9/securelevel_gt.9,v 1.2 2007/06/02 20:15:59 remko Exp $ .\" -.Dd March 6, 2004 +.Dd June 2, 2007 .Dt SECURELEVEL_GT 9 .Os .Sh NAME @@ -68,4 +68,4 @@ .Er EPERM if condition evaluated to true, and 0 otherwise. .Sh SEE ALSO -.Xr securelevel 8 +.Xr securelevel 7 Index: vm_page_zero_fill.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_zero_fill.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_zero_fill.9 -L share/man/man9/vm_page_zero_fill.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_zero_fill.9 +++ share/man/man9/vm_page_zero_fill.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_zero_fill.9,v 1.3 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_ZERO_FILL 9 Index: pseudofs.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pseudofs.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pseudofs.9 -L share/man/man9/pseudofs.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pseudofs.9 +++ share/man/man9/pseudofs.9 @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pseudofs.9,v 1.5 2004/07/03 18:29:24 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pseudofs.9,v 1.6 2007/04/20 15:38:06 brueffer Exp $ .\" -.Dd September 30, 2001 +.Dd April 20, 2007 .Dt PSEUDOFS 9 .Os .Sh NAME @@ -54,6 +54,7 @@ .\" Insert more info here .Sh SEE ALSO .Xr linprocfs 5 , +.Xr linsysfs 5 , .Xr procfs 5 , .Xr sbuf 9 , .Xr vnode 9 Index: VFS_SET.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_SET.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_SET.9 -L share/man/man9/VFS_SET.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_SET.9 +++ share/man/man9/VFS_SET.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_SET.9,v 1.9 2005/01/18 20:37:11 ru Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_SET.9,v 1.11 2007/04/05 21:17:52 pjd Exp $ .\" -.Dd December 2, 2001 +.Dd April 5, 2007 .Dt VFS_SET 9 .Os .Sh NAME @@ -70,6 +70,11 @@ Loopback file system layer. .It Dv VFCF_UNICODE File names are stored as Unicode. +.It Dv VFCF_JAIL +can be mounted from within a jail if +.Va security.jail.mount_allowed +sysctl is set to +.Dv 1 . .El .Sh PSEUDOCODE .Bd -literal @@ -96,6 +101,8 @@ VFS_SET(myfs_vfsops, skelfs, 0); .Ed .Sh SEE ALSO +.Xr jail 2 , +.Xr jail 8 , .Xr DECLARE_MODULE 9 , .Xr vfsconf 9 , .Xr vfs_modevent 9 --- /dev/null +++ share/man/man9/VOP_VPTOFH.9 @@ -0,0 +1,60 @@ +.\" -*- nroff -*- +.\" +.\" Copyright (c) 1996 Doug Rabson +.\" +.\" All rights reserved. +.\" +.\" This program is free software. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/VOP_VPTOFH.9,v 1.10 2007/02/16 14:27:59 pjd Exp $ +.\" +.Dd February 16, 2007 +.Os +.Dt VOP_VPTOFH 9 +.Sh NAME +.Nm VOP_VPTOFH +.Nd turn a vnode into an NFS filehandle +.Sh SYNOPSIS +.In sys/param.h +.In sys/vnode.h +.Ft int +.Fn VOP_VPTOFH "struct vnode *vp" "struct fid *fhp" +.Sh DESCRIPTION +This is used by the NFS server to create an opaque filehandle which +uniquely identifies the file and which can be used by an NFS client +to access the file in the future. +.Pp +Its arguments are: +.Bl -tag -width fhp +.It Fa vp +The vnode to make a filehandle for. +.It Fa fhp +Return parameter for the filehandle. +.El +.Sh SEE ALSO +.Xr VFS 9 , +.Xr VFS_FHTOVP 9 , +.Xr vnode 9 +.Sh AUTHORS +This manual page was written by +.An Doug Rabson . Index: pfil.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pfil.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pfil.9 -L share/man/man9/pfil.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pfil.9 +++ share/man/man9/pfil.9 @@ -26,7 +26,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pfil.9,v 1.20 2005/01/21 08:36:40 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pfil.9,v 1.22 2006/09/18 15:24:20 ru Exp $ .\" .Dd September 29, 2004 .Dt PFIL 9 @@ -145,7 +145,7 @@ might sleep! .Sh SEE ALSO .Xr bpf 4 , -.Xr bridge 4 +.Xr if_bridge 4 .Sh HISTORY The .Nm @@ -196,10 +196,12 @@ host byte order contrary to the above statements. .Pp The -.Xr bridge 4 -diverts inbound +.Xr if_bridge 4 +diverts .Dv AF_INET -traffic, but contrary to the above +and +.Dv AF_INET6 +traffic according to its sysctl settings, but contrary to the above statements, the data is provided in host byte order. .Pp When a Index: bios.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bios.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bios.9 -L share/man/man9/bios.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bios.9 +++ share/man/man9/bios.9 @@ -1,4 +1,4 @@ -.\" $FreeBSD: src/share/man/man9/bios.9,v 1.13.10.1 2005/08/14 18:48:54 murray Exp $ +.\" $FreeBSD: src/share/man/man9/bios.9,v 1.16 2005/11/18 10:52:24 ru Exp $ .\" .\" Copyright (c) 1997 Michael Smith .\" All rights reserved. @@ -24,13 +24,14 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.Dd August 1, 1997 +.Dd August 9, 2005 .Dt BIOS 9 .Os .Sh NAME .Nm bios_sigsearch , .Nm bios32_SDlookup , -.Nm bios32 +.Nm bios32 , +.Nm bios_oem_strings .Nd interact with PC BIOS .Sh SYNOPSIS .In sys/param.h @@ -50,6 +51,23 @@ .Vt extern struct bios32_SDentry PCIbios ; .Vt extern struct SMBIOS_table SMBIOStable ; .Vt extern struct DMI_table DMItable ; +.Ft int +.Fn bios_oem_strings "struct bios_oem *oem" "u_char *buffer" "size_t maxlen" +.Bd -literal +struct bios_oem_signature { + char * anchor; /* search anchor string in BIOS memory */ + size_t offset; /* offset from anchor (may be negative) */ + size_t totlen; /* total length of BIOS string to copy */ +}; +struct bios_oem_range { + u_int from; /* shouldn't be below 0xe0000 */ + u_int to; /* shouldn't be above 0xfffff */ +}; +struct bios_oem { + struct bios_oem_range range; + struct bios_oem_signature signature[]; +}; +.Ed .Sh DESCRIPTION These functions provide a general-purpose interface for dealing with the BIOS functions and data encountered on x86 PC-architecture systems. @@ -75,6 +93,46 @@ If the signature is found, its effective physical address is returned. If no signature is found, zero is returned. +.It Fn bios_oem_strings +Searches a given BIOS memory range for one or more strings, +and composes a printable concatenation of those found. +The routine expects a structure describing the BIOS address +.Fa range +(within +.Li 0xe0000 +- +.Li 0xfffff ) , +and a { +.Dv NULL , Li 0 , 0 +} -terminated array of +.Vt bios_oem_signature +structures which define the +.Va anchor +string, an +.Va offset +from the beginning of the match (which may be negative), and +.Va totlen +number of bytes to be collected from BIOS memory starting at that offset. +Unmatched anchors are ignored, whereas matches are copied from BIOS memory +starting at their corresponding +.Vt offset +with unprintable characters being replaced with space, and consecutive spaces +being suppressed. +This composed string is stored in +.Fa buffer +up to the given +.Fa maxlen +bytes (including trailing +.Ql \e0 , +and any trailing space surpressed). +If an error is encountered, i.e.\& trying to read out of said BIOS range, +other invalid input, or +.Fa buffer +overflow, a negative integer is returned, otherwise the +length of the composed string is returned. +In particular, a return +value of 0 means that none of the given anchor strings were found in +the specified BIOS memory range. .It Fn BIOS_VADDRTOPADDR Returns the effective physical address which corresponds to the kernel virtual address Index: vm_page_deactivate.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_deactivate.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vm_page_deactivate.9 -L share/man/man9/vm_page_deactivate.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vm_page_deactivate.9 +++ share/man/man9/vm_page_deactivate.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_page_deactivate.9,v 1.2 2001/08/08 10:04:08 ru Exp $ +.\" $FreeBSD: src/share/man/man9/vm_page_deactivate.9,v 1.3 2007/02/25 06:51:11 ru Exp $ .\" .Dd July 24, 2001 .Dt VM_PAGE_DEACTIVATE 9 @@ -44,7 +44,6 @@ function moves the given page to the inactive queue as long as it is unmanaged and is not wired. .Sh SEE ALSO -.Xr vm_page_unmanage 9 , .Xr vm_page_wire 9 .Sh AUTHORS This manual page was written by --- /dev/null +++ share/man/man9/socket.9 @@ -0,0 +1,338 @@ +.\"- +.\" Copyright (c) 2006 Robert N. M. Watson +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/socket.9,v 1.2 2006/12/16 10:32:10 rwatson Exp $ +.\" +.Dd December 14, 2006 +.Dt SOCKET 9 +.Os +.Sh NAME +.Nm socket +.Nd "kernel socket interface" +.Sh SYNOPSIS +.In sys/socket.h +.In sys/socketvar.h +.Ft int +.Fn sobind "struct socket *so" "struct sockaddr *nam" "struct thread *td" +.Ft void +.Fn soclose "struct socket *so" +.Ft int +.Fn soconnect "struct socket *so" "struct sockaddr *nam" "struct thread *td" +.Ft int +.Fo socreate +.Fa "int dom" "struct socket **aso" "int type" "int proto" +.Fa "struct ucred *cred" "struct thread *td" +.Fc +.Ft int +.Fn sogetopt "struct socket *so" "struct sockopt *sopt" +.Ft int +.Fo soreceive +.Fa "struct socket *so" "struct sockaddr **psa" "struct uio *uio" +.Fa "struct mbuf **mp0" "struct mbuf **controlp" "int *flagsp" +.Fc +.Ft int +.Fn sosetopt "struct socket *so" "struct sockopt *sopt" +.Ft int +.Fo sosend +.Fa "struct socket *so" "struct sockaddr *addr" "struct uio *uio" +.Fa "struct mbuf *top" "struct mbuf *control" "int flags" "struct thread *td" +.Fc +.Ft int +.Fn soshutdown "struct socket *so" "int how" +.Sh DESCRIPTION +The kernel +.Nm +programming interface permits in-kernel consumers to interact with +local and network socket objects in a manner similar to that permitted using +the +.Xr socket 2 +user API. +These interfaces are appropriate for use by distributed file systems and +other network-aware kernel services. +While the user API operates on file descriptors, the kernel interfaces +operate directly on +.Vt "struct socket" +pointers. +.Pp +Except where otherwise indicated, +.Nm +functions may sleep, and are not appropriate for use in an +.Xr ithread 9 +context or while holding non-sleepable kernel locks. +.Ss Creating and Destroying Sockets +A new socket may be created using +.Fn socreate . +As with +.Xr socket 2 , +arguments specify the requested domain, type, and protocol via +.Fa dom , type , +and +.Fa proto . +The socket is returned via +.Fa aso +on success. +In addition, the credential used to authorize operations associated with the +socket will be passed via +.Fa cred +(and will be cached for the lifetime of the socket), and the thread +performing the operation via +.Fa td . +.Em Warning : +authorization of the socket creation operation will be performed +using the thread credential for some protocols (such as raw sockets). +.Pp +Sockets may be closed and freed using +.Fn soclose , +which has similar semantics to +.Xr close 2 . +.Ss Connections and Addresses +The +.Fn sobind +function is equivalent to the +.Xr bind 2 +system call, and binds the socket +.Fa so +to the address +.Fa nam . +The operation would be authorized using the credential on thread +.Fa td . +.Pp +The +.Fn soconnect +function is equivalent to the +.Xr connect 2 +system call, and initiates a connection on the socket +.Fa so +to the address +.Fa nam . +The operation will be authorized using the credential on thread +.Fa td . +Unlike the user system call, +.Fn soconnect +returns immediately; the caller may +.Xr msleep 9 +on +.Fa so->so_timeo +while holding the socket mutex and waiting for the +.Dv SS_ISCONNECTING +flag to clear or +.Fa so->so_error +to become non-zero. +If +.Fn soconnect +fails, the caller must manually clear the +.Dv SS_ISCONNECTING +flag. +.Pp +The +.Fn soshutdown +function is equivalent to the +.Xr shutdown 2 +system call, and causes part or all of a connection on a socket to be closed +down. +.Ss Socket Options +The +.Fn sogetopt +function is equivalent to the +.Xr getsockopt 2 +system call, and retrieves a socket option on socket +.Fa so . +The +.Fn sosetopt +function is equivalent to the +.Xr setsockopt 2 +system call, and sets a socket option on socket +.Fa so . +.Pp +The second argument in both +.Fn sogetopt +and +.Fn sosetopt +is the +.Fa sopt +pointer to a +.Vt "struct sopt" +describing the socket option operation. +The caller-allocated structure must be zeroed, and then have its fields +initialized to specify socket option operation arguments: +.Bl -tag -width ".Va sopt_valsize" +.It Va sopt_dir +Set to +.Dv SOPT_SET +or +.Dv SOPT_GET +depending on whether this is a get or set operation. +.It Va sopt_level +Specify the level in the network stack the operation is targeted at; for +example, +.Dv SOL_SOCKET . +.It Va sopt_name +Specify the name of the socket option to set. +.It Va sopt_val +Kernel space pointer to the argument value for the socket option. +.It Va sopt_valsize +Size of the argument value in bytes. +.El +.Ss Socket I/O +The +.Fn soreceive +function is equivalent to the +.Xr recvmsg 2 +system call, and attempts to receive bytes of data from the socket +.Fa so , +optionally blocking awaiting for data if none is ready to read. +Data may be retrieved directly to kernel or user memory via the +.Fa uio +argument, or as an mbuf chain returned to the caller via +.Fa mp0 , +avoiding a data copy. +Only one of the +.Fa uio +or +.Fa mp0 +pointers may be +.Pf non- Dv NULL . +The caller may optionally retrieve a socket address on a protocol with the +.Dv PR_ADDR +capability by providing storage via +.Pf non- Dv NULL +.Fa psa +argument. +The caller may optionally retrieve control data mbufs via a +.Pf non- Dv NULL +.Fa controlp +argument. +Optional flags may be passed to +.Fn soreceive +via a +.Pf non- Dv NULL +.Fa flagsp +argument, and use the same flag name space as the +.Xr recvmsg 2 +system call. +.Pp +The +.Fn sosend +function is equivalent to the +.Xr sendmsg 2 +system call, and attempts to send bytes of data via the socket +.Fa so , +optionally blocking if data cannot be immediately sent. +Data may be sent directly from kernel or user memory via the +.Fa uio +argument, or as an mbuf chain via +.Fa top , +avoiding a data copy. +Only one of the +.Fa uio +or +.Fa top +pointers may be +.Pf non- Dv NULL . +An optional destination address may be specified via a +.Pf non- Dv NULL +.Fa addr +argument, which may result in an implicit connect if supported by the +protocol. +The caller may optionally send control data mbufs via a +.Pf non- Dv NULL +.Fa control +argument. +Flags may be passed to +.Fn sosend +using the +.Fa flags +argument, and use the same flag name space as the +.Xr sendmsg 2 +system call. +.Pp +Kernel callers running in +.Xr ithread 9 +context, or with a mutex held, will wish to use non-blocking sockets and pass +the +.Dv MSG_DONTWAIT +flag in order to prevent these functions from sleeping. +.Sh SEE ALSO +.Xr bind 2 , +.Xr close 2 , +.Xr connect 2 , +.Xr getsockopt 2 , +.Xr recv 2 , +.Xr send 2 , +.Xr setsockopt 2 , +.Xr shutdown 2 , +.Xr socket 2 , +.Xr ng_ksocket 4 , +.Xr ithread 9 , +.Xr msleep 9 , +.Xr ucred 9 +.Sh HISTORY +The +.Xr socket 2 +system call appeared in +.Bx 4.2 . +This manual page was introduced in +.Fx 7.0 . +.Sh AUTHORS +This manual page was written by +.An Robert Watson . +.Sh BUGS +The use of explicitly passed credentials, credentials hung from explicitly +passed threads, the credential on +.Dv curthread , +and the cached credential from +socket creation time is inconsistent, and may lead to unexpected behaviour. +It is possible that several of the +.Fa td +arguments should be +.Fa cred +arguments, or simply not be present at all. +.Pp +The caller may need to manually clear +.Dv SS_ISCONNECTING +if +.Fn soconnect +returns an error. +.Pp +The +.Dv MSG_DONTWAIT +flag is not implemented for +.Fn sosend , +and may not always work with +.Fn soreceive +when zero copy sockets are enabled. +.Pp +This manual page does not describe how to register socket upcalls or monitor +a socket for readability/writability without using blocking I/O. +.Pp +The +.Fn soref +and +.Fn sorele +functions are not described, and in most cases should not be used, due to +confusing and potentially incorrect interactions when +.Fn sorele +is last called after +.Fn soclose . Index: time.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/time.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/time.9 -L share/man/man9/time.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/time.9 +++ share/man/man9/time.9 @@ -29,7 +29,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/time.9,v 1.16 2005/06/15 13:31:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/time.9,v 1.17 2006/03/02 19:47:41 ru Exp $ .\" .Dd September 17, 2004 .Dt TIME 9 @@ -43,8 +43,8 @@ .In sys/time.h .Pp .Vt extern struct timeval boottime ; -.Vt extern struct time_t time_second ; -.Vt extern struct timeval time_uptime ; +.Vt extern time_t time_second ; +.Vt extern time_t time_uptime ; .Sh DESCRIPTION The .Va boottime @@ -71,7 +71,6 @@ functions can be used to get the current time more accurately and in an atomic manner. Similarly, the -The .Xr binuptime 9 , .Xr getbinuptime 9 , .Xr microuptime 9 , --- /dev/null +++ share/man/man9/stack.9 @@ -0,0 +1,119 @@ +.\" +.\" Copyright (c) 2007 Robert N. M. Watson +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/stack.9,v 1.5.2.1 2007/12/04 15:22:31 rwatson Exp $ +.\" +.Dd February 27, 2007 +.Dt STACK 9 +.Os +.Sh NAME +.Nm stack +.Nd kernel thread stack tracing routines +.Sh SYNOPSIS +.In sys/param.h> +.In sys/stack.h +.Pp +In kernel configuration files: +.Cd "options DDB" +.Ft struct stack * +.Fn stack_create "void" +.Ft void +.Fn stack_destroy "struct stack *st" +.Ft int +.Fn stack_put "struct stack *st" "vm_offset_t pc" +.Ft void +.Fn stack_copy "struct stack *src" "struct stack dst" +.Ft void +.Fn stack_zero "struct stack *st" +.Ft void +.Fn stack_print "struct stack *st" +.Ft void +.Fn stack_sbuf_print "struct sbuf sb*" "struct stack *st" +.Ft void +.Fn stack_save "struct stack *st" +.Sh DESCRIPTION +The +.Nm +KPI allows querying of kernel stack trace information and the automated +generation of kernel stack trace strings for the purposes of debugging and +tracing. +.Nm +relies on the presence of +.Xr DDB 4 , +and all use of these functions must be made conditional on +.Nm DDB +being compiled in the kernel. +.Pp +Each stack trace is described by a +.Vt "struct stack" . +Before a trace may be created or otherwise manipulated, storage for the trace +must be allocated with +.Fn stack_create , +which may sleep. +Memory associated with a trace may be freed by calling +.Fn stack_destroy . +.Pp +A trace of the current kernel thread's call stack may be captured using +.Fn stack_save . +.Pp +.Fn stack_print +may be used to print a stack trace using the kernel +.Xr printf 9 . +.Pp +.Fn stack_sbuf_print +may be used to construct a human-readable string, including conversion (where +possible) from a simple kernel instruction pointer to a named symbol and +offset. +The argument +.Ar sb +must be an initialized +.Dv struct sbuf +as described in +.Xr sbuf 9 . +This function may sleep if an auto-extending +.Dv struct sbuf +is used. +.Pp +The utility functions +.Nm stack_zero , +.Nm stack_copy , +and +.Nm stack_put +may be used to manipulate stack data structures directly. +.Sh SEE ALSO +.Xr DDB 4 , +.Xr printf 9 , +.Xr sbuf 9 +.Sh AUTHORS +.An -nosplit +The +.Xr stack 9 +function suite was created by +.An Antoine Brodin . +.Pp +This manual page was written by +.An Robert Watson . Index: alloc_unr.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/alloc_unr.9,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L share/man/man9/alloc_unr.9 -L share/man/man9/alloc_unr.9 -u -r1.1.1.2 -r1.2 --- share/man/man9/alloc_unr.9 +++ share/man/man9/alloc_unr.9 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/alloc_unr.9,v 1.2.2.1 2006/01/24 17:02:38 joel Exp $ +.\" $FreeBSD: src/share/man/man9/alloc_unr.9,v 1.3 2005/11/24 09:25:09 joel Exp $ .\" .Dd March 23, 2005 .Dt ALLOC_UNR 9 Index: make_dev.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/make_dev.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/make_dev.9 -L share/man/man9/make_dev.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/make_dev.9 +++ share/man/man9/make_dev.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/make_dev.9,v 1.17 2005/03/28 10:28:57 brueffer Exp $ +.\" $FreeBSD: src/share/man/man9/make_dev.9,v 1.23 2007/05/09 05:05:50 brueffer Exp $ .\" -.Dd March 28, 2005 +.Dd May 6, 2007 .Os .Dt MAKE_DEV 9 .Sh NAME @@ -38,14 +38,14 @@ .Sh SYNOPSIS .In sys/param.h .In sys/conf.h -.Ft struct cdev +.Ft struct cdev * .Fn make_dev "struct cdevsw *cdevsw" "int minor" "uid_t uid" "gid_t gid" "int perms" "const char *fmt" ... -.Ft struct cdev -.Fn make_dev_alias "struct cdev pdev" "const char *fmt" ... +.Ft struct cdev * +.Fn make_dev_alias "struct cdev *pdev" "const char *fmt" ... .Ft void -.Fn destroy_dev "struct cdev dev" +.Fn destroy_dev "struct cdev *dev" .Ft void -.Fn dev_depends "struct cdev pdev" "struct cdev cdev" +.Fn dev_depends "struct cdev *pdev" "struct cdev *cdev" .Sh DESCRIPTION The .Fn make_dev @@ -57,9 +57,19 @@ The device will be owned by .Va uid , with the group ownership as -.Va gid , -and with the name as specified in -.Va name . +.Va gid . +The name is the expansion of +.Va fmt +and following arguments as +.Xr printf 9 +would print it. +The name determines its path under +.Pa /dev +or other +.Xr devfs 5 +mount point and may contain slash +.Ql / +characters to denote subdirectories. The permissions of the file specified in .Va perms are defined in @@ -102,6 +112,24 @@ .Fn make_dev . .Pp The +.Fa cdev +returned by +.Fn make_dev +and +.Fn make_dev_alias +has two fields, +.Fa si_drv1 +and +.Fa si_drv2 , +that are available to store state. +Both fields are of type +.Ft void * . +These are designed to replace the +.Fa minor +argument to +.Fn make_dev . +.Pp +The .Fn destroy_dev function takes the returned .Fa cdev Index: ieee80211_ioctl.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ieee80211_ioctl.9,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L share/man/man9/ieee80211_ioctl.9 -L share/man/man9/ieee80211_ioctl.9 -u -r1.1.1.2 -r1.2 --- share/man/man9/ieee80211_ioctl.9 +++ share/man/man9/ieee80211_ioctl.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ieee80211_ioctl.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/ieee80211_ioctl.9,v 1.5 2007/07/01 10:25:06 thompsa Exp $ .\" $Id: ieee80211_ioctl.9,v 1.5 2004/03/04 12:33:27 bruce Exp $ .\" .Dd March 2, 2004 @@ -55,11 +55,6 @@ .Fn ieee80211_cfgset functions implement a legacy interface for getting and setting 802.11 interface attributes respectively. -The interface is compatible with the RIDs implemented by the legacy -.Xr owi 4 -driver and used by the -.Xr wicontrol 8 -utility. .Pp .\" The @@ -79,9 +74,7 @@ to use this as the catch-all in a switch statement to avoid code duplication. .\" .Sh SEE ALSO -.Xr owi 4 , .Xr ifconfig 8 , -.Xr wicontrol 8 , .Xr ieee80211 9 , .Xr ifnet 9 .Sh HISTORY Index: sema.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sema.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sema.9 -L share/man/man9/sema.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sema.9 +++ share/man/man9/sema.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sema.9,v 1.9 2004/07/07 19:57:15 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sema.9,v 1.11 2007/03/30 18:07:26 julian Exp $ .\" -.Dd June 14, 2004 +.Dd February 1, 2006 .Dt SEMA 9 .Os .Sh NAME @@ -125,6 +125,8 @@ .El .Sh SEE ALSO .Xr condvar 9 , +.Xr locking 9 , .Xr mtx_pool 9 , .Xr mutex 9 , +.Xr rwlock 9 , .Xr sx 9 Index: vhold.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vhold.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vhold.9 -L share/man/man9/vhold.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vhold.9 +++ share/man/man9/vhold.9 @@ -24,13 +24,13 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vhold.9,v 1.3.2.1 2005/09/24 01:59:38 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/vhold.9,v 1.5 2007/04/01 09:48:59 maxim Exp $ .\" -.Dd November 21, 2001 +.Dd April 1, 2007 .Dt VHOLD 9 .Os .Sh NAME -.Nm vhold , vdrop +.Nm vhold , vdrop , vdropl .Nd "acquire/release a hold on a vnode" .Sh SYNOPSIS .In sys/param.h @@ -39,6 +39,8 @@ .Fn vhold "struct vnode *vp" .Ft void .Fn vdrop "struct vnode *vp" +.Ft void +.Fn vdropl "struct vnode *vp" .Sh DESCRIPTION The .Fn vhold @@ -50,13 +52,29 @@ .Pp The .Fn vdrop -function decrements the +and +.Fn vdropl +functions decrement the .Va v_holdcnt of the vnode. If the holdcount is less than or equal to zero prior to calling -.Fn vdrop , +.Fn vdrop +or +.Fn vdropl , the system will panic. If the vnode is no longer referenced, it will be freed. +.Pp +The difference between +.Fn vdrop +and +.Fn vdropl +is that +.Fn vdrop +locks the vnode interlock and then calls +.Fn vdropl +while +.Fn vdropl +expects the interlock to already be locked. .Sh SEE ALSO .Xr vbusy 9 , .Xr vfree 9 Index: module.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/module.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/module.9 -L share/man/man9/module.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/module.9 +++ share/man/man9/module.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/module.9,v 1.10 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/module.9,v 1.11 2007/07/19 11:22:34 flz Exp $ .\" -.Dd March 1, 2001 +.Dd July 19, 2007 .Dt MODULE 9 .Os .Sh NAME @@ -85,7 +85,7 @@ .Pp The module should return .Er EOPNOTSUPP -for unrecognized values of +for unsupported and unrecognized values of .Fa what . .Sh EXAMPLES .Bd -literal Index: rman.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/rman.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/rman.9 -L share/man/man9/rman.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/rman.9 +++ share/man/man9/rman.9 @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/rman.9,v 1.6 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/rman.9,v 1.9 2007/04/29 19:46:33 jmg Exp $ .\" -.Dd March 15, 2005 +.Dd April 29, 2007 .Dt RMAN 9 .Os .Sh NAME @@ -139,7 +139,28 @@ function initializes the region descriptor, pointed to by the .Fa rm argument, for use with the resource management functions. +It is required that the fields +.Va rm_type +and +.Va rm_descr +of +.Vt "struct rman" +be set before calling +.Fn rman_init . +The field +.Va rm_type +shall be set to +.Dv RMAN_ARRAY . +The field +.Va rm_descr +shall be set to a string that describes the resource to be managed. It also initializes any mutexes associated with the structure. +If +.Fn rman_init +fails to initalize the mutex, it will return +.Er ENOMEM ; otherwise it will return 0 and +.Fa rm +will be initalized. .Pp The .Fn rman_fini @@ -167,10 +188,15 @@ and .Fa end arguments specify the bounds of the region. -.Pp -.Em NOTE : -This interface is not robust against programming errors which -add multiple copies of the same region. +If successful, +.Fn rman_manage_region +will return 0. +If the region overlaps with an existing region, it will return +.Er EBUSY . +.Er ENOMEM +will be return when +.Fn rman_manage_region +failed to allocate memory for the region. .Pp The .Fn rman_reserve_resource_bound @@ -316,7 +342,6 @@ .Fn rman_get_device function returns a pointer to the device which reserved the resource .Fa r . -.Pp .Sh SEE ALSO .Xr bus_activate_resource 9 , .Xr bus_alloc_resource 9 , Index: bus_space.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bus_space.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bus_space.9 -L share/man/man9/bus_space.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bus_space.9 +++ share/man/man9/bus_space.9 @@ -56,7 +56,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bus_space.9,v 1.2 2005/06/25 08:59:05 ru Exp $ +.\" $FreeBSD: src/share/man/man9/bus_space.9,v 1.4 2006/09/18 14:31:03 ru Exp $ .\" .Dd June 13, 2005 .Dt BUS_SPACE 9 @@ -68,6 +68,10 @@ .Nm bus_space_copy_region_2 , .Nm bus_space_copy_region_4 , .Nm bus_space_copy_region_8 , +.Nm bus_space_copy_region_stream_1 , +.Nm bus_space_copy_region_stream_2 , +.Nm bus_space_copy_region_stream_4 , +.Nm bus_space_copy_region_stream_8 , .Nm bus_space_free , .Nm bus_space_map , .Nm bus_space_read_1 , @@ -78,20 +82,40 @@ .Nm bus_space_read_multi_2 , .Nm bus_space_read_multi_4 , .Nm bus_space_read_multi_8 , +.Nm bus_space_read_multi_stream_1 , +.Nm bus_space_read_multi_stream_2 , +.Nm bus_space_read_multi_stream_4 , +.Nm bus_space_read_multi_stream_8 , .Nm bus_space_read_region_1 , .Nm bus_space_read_region_2 , .Nm bus_space_read_region_4 , .Nm bus_space_read_region_8 , +.Nm bus_space_read_region_stream_1 , +.Nm bus_space_read_region_stream_2 , +.Nm bus_space_read_region_stream_4 , +.Nm bus_space_read_region_stream_8 , +.Nm bus_space_read_stream_1 , +.Nm bus_space_read_stream_2 , +.Nm bus_space_read_stream_4 , +.Nm bus_space_read_stream_8 , +.Nm bus_space_set_multi_1 , +.Nm bus_space_set_multi_2 , +.Nm bus_space_set_multi_4 , +.Nm bus_space_set_multi_8 , +.Nm bus_space_set_multi_stream_1 , +.Nm bus_space_set_multi_stream_2 , +.Nm bus_space_set_multi_stream_4 , +.Nm bus_space_set_multi_stream_8 , .Nm bus_space_set_region_1 , .Nm bus_space_set_region_2 , .Nm bus_space_set_region_4 , .Nm bus_space_set_region_8 , +.Nm bus_space_set_region_stream_1 , +.Nm bus_space_set_region_stream_2 , +.Nm bus_space_set_region_stream_4 , +.Nm bus_space_set_region_stream_8 , .Nm bus_space_subregion , .Nm bus_space_unmap , -.Nm bus_space_set_multi_1 , -.Nm bus_space_set_multi_2 , -.Nm bus_space_set_multi_4 , -.Nm bus_space_set_multi_8 , .Nm bus_space_write_1 , .Nm bus_space_write_2 , .Nm bus_space_write_4 , @@ -100,10 +124,22 @@ .Nm bus_space_write_multi_2 , .Nm bus_space_write_multi_4 , .Nm bus_space_write_multi_8 , +.Nm bus_space_write_multi_stream_1 , +.Nm bus_space_write_multi_stream_2 , +.Nm bus_space_write_multi_stream_4 , +.Nm bus_space_write_multi_stream_8 , .Nm bus_space_write_region_1 , .Nm bus_space_write_region_2 , .Nm bus_space_write_region_4 , -.Nm bus_space_write_region_8 +.Nm bus_space_write_region_8 , +.Nm bus_space_write_region_stream_1 , +.Nm bus_space_write_region_stream_2 , +.Nm bus_space_write_region_stream_4 , +.Nm bus_space_write_region_stream_8 , +.Nm bus_space_write_stream_1 , +.Nm bus_space_write_stream_2 , +.Nm bus_space_write_stream_4 , +.Nm bus_space_write_stream_8 .Nd "bus space manipulation functions" .Sh SYNOPSIS .In machine/bus.h @@ -147,6 +183,22 @@ .Fo bus_space_read_8 .Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" .Fc +.Ft u_int8_t +.Fo bus_space_read_stream_1 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc +.Ft u_int16_t +.Fo bus_space_read_stream_2 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc +.Ft u_int32_t +.Fo bus_space_read_stream_4 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc +.Ft u_int64_t +.Fo bus_space_read_stream_8 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" "bus_size_t offset" +.Fc .Ft void .Fo bus_space_write_1 .Fa "bus_space_tag_t space" "bus_space_handle_t handle" @@ -168,6 +220,26 @@ .Fa "bus_size_t offset" "u_int64_t value" .Fc .Ft void +.Fo bus_space_write_stream_1 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int8_t value" +.Fc +.Ft void +.Fo bus_space_write_stream_2 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int16_t value" +.Fc +.Ft void +.Fo bus_space_write_stream_4 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int32_t value" +.Fc +.Ft void +.Fo bus_space_write_stream_8 +.Fa "bus_space_tag_t space" "bus_space_handle_t handle" +.Fa "bus_size_t offset" "u_int64_t value" +.Fc +.Ft void .Fo bus_space_barrier .Fa "bus_space_tag_t space" "bus_space_handle_t handle" .Fa "bus_size_t offset" "bus_size_t length" "int flags" @@ -197,6 +269,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_read_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_write_region_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" @@ -221,6 +317,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_write_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_copy_region_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" @@ -245,6 +365,30 @@ .Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" .Fc .Ft void +.Fo bus_space_copy_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_copy_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_copy_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_copy_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t srchandle" "bus_size_t srcoffset" +.Fa "bus_space_handle_t dsthandle" "bus_size_t dstoffset" "bus_size_t count" +.Fc +.Ft void .Fo bus_space_set_region_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" @@ -269,6 +413,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_set_region_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_region_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_region_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_region_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t value" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_read_multi_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" @@ -293,6 +461,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_read_multi_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_multi_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_multi_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_read_multi_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_write_multi_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" @@ -317,6 +509,30 @@ .Fa "bus_size_t count" .Fc .Ft void +.Fo bus_space_write_multi_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_multi_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_multi_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_write_multi_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t *datap" +.Fa "bus_size_t count" +.Fc +.Ft void .Fo bus_space_set_multi_1 .Fa "bus_space_tag_t space" .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" @@ -340,6 +556,30 @@ .Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t value" .Fa "bus_size_t count" .Fc +.Ft void +.Fo bus_space_set_multi_stream_1 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int8_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_multi_stream_2 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int16_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_multi_stream_4 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int32_t value" +.Fa "bus_size_t count" +.Fc +.Ft void +.Fo bus_space_set_multi_stream_8 +.Fa "bus_space_tag_t space" +.Fa "bus_space_handle_t handle" "bus_size_t offset" "u_int64_t value" +.Fa "bus_size_t count" +.Fc .Sh DESCRIPTION The .Nm @@ -1356,6 +1596,58 @@ argument error), that indicates a software bug which should cause a panic. In that case, they will never return. +.Sh STREAM FUNCTIONS +Most of the +.Nm +functions imply a host byte-order and a bus byte-order and take care of +any translation for the caller. +In some cases, however, hardware may map a FIFO or some other memory region +for which the caller may want to use multi-word, yet untranslated access. +Access to these types of memory regions should be with the +.Fn bus_space_*_stream_N +functions. +.Pp +.Bl -tag -compact +.It Fn bus_space_read_stream_1 +.It Fn bus_space_read_stream_2 +.It Fn bus_space_read_stream_4 +.It Fn bus_space_read_stream_8 +.It Fn bus_space_read_multi_stream_1 +.It Fn bus_space_read_multi_stream_2 +.It Fn bus_space_read_multi_stream_4 +.It Fn bus_space_read_multi_stream_8 +.It Fn bus_space_read_region_stream_1 +.It Fn bus_space_read_region_stream_2 +.It Fn bus_space_read_region_stream_4 +.It Fn bus_space_read_region_stream_8 +.It Fn bus_space_write_stream_1 +.It Fn bus_space_write_stream_2 +.It Fn bus_space_write_stream_4 +.It Fn bus_space_write_stream_8 +.It Fn bus_space_write_multi_stream_1 +.It Fn bus_space_write_multi_stream_2 +.It Fn bus_space_write_multi_stream_4 +.It Fn bus_space_write_multi_stream_8 +.It Fn bus_space_write_region_stream_1 +.It Fn bus_space_write_region_stream_2 +.It Fn bus_space_write_region_stream_4 +.It Fn bus_space_write_region_stream_8 +.It Fn bus_space_copy_region_stream_1 +.It Fn bus_space_copy_region_stream_2 +.It Fn bus_space_copy_region_stream_4 +.It Fn bus_space_copy_region_stream_8 +.It Fn bus_space_set_multi_stream_1 +.It Fn bus_space_set_multi_stream_2 +.It Fn bus_space_set_multi_stream_4 +.It Fn bus_space_set_multi_stream_8 +.It Fn bus_space_set_region_stream_1 +.It Fn bus_space_set_region_stream_2 +.It Fn bus_space_set_region_stream_4 +.It Fn bus_space_set_region_stream_8 +.El +.Pp +These functions are defined just as their non-stream counterparts, +except that they provide no byte-order translation. .Sh COMPATIBILITY The current .Nx Index: critical_enter.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/critical_enter.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/critical_enter.9 -L share/man/man9/critical_enter.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/critical_enter.9 +++ share/man/man9/critical_enter.9 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/critical_enter.9,v 1.7.14.1 2005/10/14 18:34:29 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/critical_enter.9,v 1.8 2005/10/05 19:48:21 jhb Exp $ .\" .Dd October 5, 2005 .Dt CRITICAL_ENTER 9 Index: vm_page_sleep_busy.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_sleep_busy.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_sleep_busy.9 -L share/man/man9/vm_page_sleep_busy.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_sleep_busy.9 +++ share/man/man9/vm_page_sleep_busy.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_sleep_busy.9,v 1.2 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_SLEEP_BUSY 9 Index: pmap_extract.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pmap_extract.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pmap_extract.9 -L share/man/man9/pmap_extract.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pmap_extract.9 +++ share/man/man9/pmap_extract.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pmap_extract.9,v 1.3 2004/07/06 07:02:31 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pmap_extract.9,v 1.4 2007/01/28 16:23:55 rwatson Exp $ .\" .Dd July 21, 2003 .Dt PMAP_EXTRACT 9 @@ -55,13 +55,6 @@ the given page protection. .Sh IMPLEMENTATION NOTES Currently, the page protection requested by the caller is not verified. -.Pp -In the -.Fn pmap_extract_and_hold -function, the -.Va Giant -lock is held for the duration of the call to ensure that only a single -caller is present. .Sh RETURN VALUES The .Fn pmap_extract Index: VOP_OPENCLOSE.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_OPENCLOSE.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_OPENCLOSE.9 -L share/man/man9/VOP_OPENCLOSE.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_OPENCLOSE.9 +++ share/man/man9/VOP_OPENCLOSE.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_OPENCLOSE.9,v 1.18 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_OPENCLOSE.9,v 1.19 2007/06/05 10:48:29 kib Exp $ .\" -.Dd July 24, 1996 +.Dd June 5, 2007 .Os .Dt VOP_OPEN 9 .Sh NAME @@ -39,7 +39,7 @@ .In sys/param.h .In sys/vnode.h .Ft int -.Fn VOP_OPEN "struct vnode *vp" "int mode" "struct ucred *cred" "struct thread *td" "int fdidx" +.Fn VOP_OPEN "struct vnode *vp" "int mode" "struct ucred *cred" "struct thread *td" "struct file *fp" .Ft int .Fn VOP_CLOSE "struct vnode *vp" "int mode" "struct ucred *cred" "struct thread *td" .Sh DESCRIPTION @@ -57,14 +57,21 @@ The access mode required by the calling process. .It Fa td The thread which is accessing the file. +.It Fa fp +The file being opened. .El .Pp -Additionally, -.Fn VOP_OPEN -can accept a file descriptor number in -.Fa fdidx ; -this is useful for file systems which require such information, e.g., +Pointer to the file +.Fa fp +is useful for file systems which require such information, e.g., .Xr fdescfs 5 . +Use +.Ql NULL +as +.Fa fp +argument to +.Fn VOP_OPEN +for in-kernel opens. .Pp The access mode is a set of flags, including .Dv FREAD , @@ -85,20 +92,13 @@ .Fa vn_close expects an unlocked, referenced vnode and will dereference the vnode prior to returning. -.Sh IMPLEMENTATION NOTES -The -.Fa fdidx -argument to -.Fn VOP_OPEN -is currently unused, use -.Ql \-1 -for the meantime; however, this will change in future. .Sh RETURN VALUES Zero is returned on success, otherwise an error code is returned. .Sh PSEUDOCODE .Bd -literal int -vop_open(struct vnode *vp, int mode, struct ucred *cred, struct thread *td) +vop_open(struct vnode *vp, int mode, struct ucred *cred, struct thread *td, + struct file *fp) { /* * Most file systems don't do much here. Index: mac.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mac.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/mac.9 -L share/man/man9/mac.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/mac.9 +++ share/man/man9/mac.9 @@ -31,9 +31,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mac.9,v 1.15 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/mac.9,v 1.17 2006/07/11 16:26:40 joel Exp $ .\" -.Dd February 16, 2002 +.Dd July 10, 2006 .Dt MAC 9 .Os .Sh NAME @@ -152,7 +152,7 @@ policies. .Sh ENTRY POINTS System service and module authors should reference the -.%T "FreeBSD Developer's Handbook" +.%T "FreeBSD Architecture Handbook" for information on the MAC Framework APIs. .Sh SEE ALSO .Xr acl 3 , @@ -172,8 +172,8 @@ .Xr vaccess_acl_posix1e 9 , .Xr VFS 9 .Rs -.%T "The FreeBSD Developers' Handbook" -.%O "http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/developers-handbook/" +.%T "The FreeBSD Architecture Handbook" +.%O "http://www.FreeBSD.org/doc/en_US.ISO8859-1/books/arch-handbook/" .Re .Sh HISTORY The Index: vm_page_rename.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_rename.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_rename.9 -L share/man/man9/vm_page_rename.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_rename.9 +++ share/man/man9/vm_page_rename.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_rename.9,v 1.2 2001/08/08 10:04:08 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_RENAME 9 Index: hash.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/hash.9,v retrieving revision 1.1 retrieving revision 1.2 diff -L share/man/man9/hash.9 -L share/man/man9/hash.9 -u -r1.1 -r1.2 --- share/man/man9/hash.9 +++ share/man/man9/hash.9 @@ -24,39 +24,39 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $OpenBSD: hash.9,v 1.5 2003/04/17 05:08:39 jmc Exp $ -.\" $FreeBSD: src/share/man/man9/hash.9,v 1.1.2.1 2006/04/04 19:50:02 andre Exp $ +.\" $FreeBSD: src/share/man/man9/hash.9,v 1.4 2007/04/09 22:55:14 thompsa Exp $ .\" -.Dd December 8, 2001 +.Dd April 3, 2007 .Dt HASH 9 .Os .Sh NAME -.Nm hash -.\" XXX - Should all these be .Nm as well? -.\" .Nm hash32 , -.\" .Nm hash32_buf , -.\" .Nm hash32_str , -.\" .Nm hash32_strn , -.\" .Nm hash32_stre , -.\" .Nm hash32_strne +.Nm hash , +.Nm hash32 , +.Nm hash32_buf , +.Nm hash32_str , +.Nm hash32_strn , +.Nm hash32_stre , +.Nm hash32_strne .Nd general kernel hashing functions .Sh SYNOPSIS -.Fd #include +.In sys/hash.h .Ft uint32_t -.Fn hash32_buf "void *buf" "size_t len" "uint32_t hash" +.Fn hash32_buf "const void *buf" "size_t len" "uint32_t hash" .Ft uint32_t -.Fn hash32_str "void *buf" "uint32_t hash" +.Fn hash32_str "const void *buf" "uint32_t hash" .Ft uint32_t -.Fn hash32_strn "void *buf" "size_t len" "uint32_t hash" +.Fn hash32_strn "const void *buf" "size_t len" "uint32_t hash" .Ft uint32_t -.Fn hash32_stre "void *buf" "int end" "char **ep" "uint32_t hash" +.Fn hash32_stre "const void *buf" "int end" "const char **ep" "uint32_t hash" .Ft uint32_t -.Fn hash32_strne "void *buf" "size_t len" "int end" "char **ep" "uint32_t hash" +.Fn hash32_strne "const void *buf" "size_t len" "int end" "const char **ep" "uint32_t hash" .Sh DESCRIPTION The .Fn hash32 functions are used to give a consistent and general interface to a decent hashing algorithm within the kernel. -These functions can be used to hash ASCII +These functions can be used to hash +.Tn ASCII .Dv NUL terminated strings, as well as blocks of memory. .Pp @@ -119,6 +119,7 @@ void sample_init(void) { + hashtbl = hashinit(numwanted, type, flags, &mask); } Index: buf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/buf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/buf.9 -L share/man/man9/buf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/buf.9 +++ share/man/man9/buf.9 @@ -29,7 +29,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/buf.9,v 1.17 2005/02/15 09:27:00 ru Exp $ +.\" $FreeBSD: src/share/man/man9/buf.9,v 1.18 2006/02/13 21:34:18 joel Exp $ .\" .Dd December 22, 1998 .Dt BUF 9 @@ -138,7 +138,6 @@ buffer cache from being freed. This can complicate the life of the paging system. -.Pp .\" .Sh SEE ALSO .\" .Xr 9 .Sh HISTORY Index: SYSCALL_MODULE.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/SYSCALL_MODULE.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/SYSCALL_MODULE.9 -L share/man/man9/SYSCALL_MODULE.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/SYSCALL_MODULE.9 +++ share/man/man9/SYSCALL_MODULE.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/SYSCALL_MODULE.9,v 1.6 2005/01/07 09:02:40 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/SYSCALL_MODULE.9,v 1.7 2006/04/15 12:04:18 maxim Exp $ .\" .Dd January 7, 2005 .Dt SYSCALL_MODULE 9 @@ -40,7 +40,7 @@ .In sys/proc.h .In sys/module.h .In sys/sysent.h -.Fn SYSCALL_MODULE name "int *offset" "struct sysent new_sysent" "modeventhand_t evh" "void *arg" +.Fn SYSCALL_MODULE name "int *offset" "struct sysent *new_sysent" "modeventhand_t evh" "void *arg" .Sh DESCRIPTION The .Fn SYSCALL_MODULE @@ -58,8 +58,8 @@ .Vt "struct sysent" where the syscall is allocated. .It Fa new_sysent -The function implementing the syscall and the number of arguments this -function needs (see +is a pointer to a structure that specifies the function implementing +the syscall and the number of arguments this function needs (see .In sys/sysent.h ) . .It Fa evh A pointer to the kernel module event handler function with the argument --- /dev/null +++ share/man/man9/priv.9 @@ -0,0 +1,123 @@ +.\"- +.\" Copyright (c) 2006 nCircle Network Security, Inc. +.\" All rights reserved. +.\" +.\" This software was developed by Robert N. M. Watson for the TrustedBSD +.\" Project under contract to nCircle Network Security, Inc. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR, NCIRCLE NETWORK SECURITY, +.\" INC., OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +.\" SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED +.\" TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +.\" PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +.\" LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +.\" NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +.\" SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/priv.9,v 1.6 2007/06/26 23:12:05 rwatson Exp $ +.\" +.Dd August 30, 2006 +.Dt PRIV 9 +.Os +.Sh NAME +.Nm priv +.Nd kernel privilege checking API +.Sh SYNOPSIS +.In sys/priv.h +.Ft int +.Fn priv_check "struct thread *td" "int priv" +.Ft int +.Fn priv_check_cred "struct ucred *cred" "int priv" "int flags" +.Sh DESCRIPTION +The +.Nm +interfaces check to see if specific system privileges are granted to the +passed thread, +.Fa td , +or credential, +.Fa cred . +This interface replaces the +.Xr suser 9 +privilege checking interface. +Privileges typically represent rights in one of two categories: the right to +manage a particular component of the system, or an exemption to a specific +policy or access control list. +The caller identifies the desired privilege via the +.Fa priv +argument. +The optional flags argument, +.Fa flags , +is currently unused. +.Ss Privilege Policies +Privileges are typically granted based on one of two base system policies: +the superuser policy, which grants privilege based on the effective (or +sometimes real) UID having a value of 0, and the +.Xr jail 2 +policy, which permits only certain privileges to be granted to processes in a +jail. +The set of available privileges may also be influenced by the TrustedBSD MAC +Framework, described in +.Xr mac 9 . +.Sh IMPLEMENTATION NOTES +When adding a new privilege check to a code path, first check the complete +list of current privileges in +.Pa sys/priv.h +to see if one already exists for the class of privilege required. +Only if there is not an exact match should a new privilege be added to the +privilege list. +As privilege numbers becomes encoded in the kernel module ABI, privilege +constants must not be changed as any kernel modules depending on privileges +will then need to be recompiled. +When adding a new privilege, be certain to also determine whether it should +be listed in +.Fn prison_priv_check , +which includes a complete list of privileges granted to the root user in +.Xr jail 2 . +.Pp +Certain catch-all privileges exist, such as +.Dv PRIV_DRIVER , +intended to be used by device drivers, rather than adding a new +driver-specific privilege. +.Sh RETURN VALUES +Typically, 0 will be returned for success, and +.Er EPERM +will be returned on failure. +Most consumers of +.Nm +will wish to directly return the error code from a failed privilege check to +user space; a small number will wish to translate it to another error code +appropriate to a specific context. +.Pp +When designing new APIs, it is preferable to return explicit errors from a +call if privilege is not granted rather than changing the semantics of the +call but returning success. +For example, the behavior exhibited by +.Xr stat 2 , +in which the generation field is optionally zero'd out when there is +insufficient privilege is highly undesirable, as it results in frequent +privilege checks, and the caller is unable to tell if an access control +failure occurred. +.Sh SEE ALSO +.Xr jail 2 , +.Xr mac 9 , +.Xr suser 9 , +.Xr ucred 9 +.Sh AUTHORS +The +.Nm +API and implementation were created by +.An Robert Watson +under contract to +nCircle Network Security, Inc. Index: VOP_FSYNC.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_FSYNC.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_FSYNC.9 -L share/man/man9/VOP_FSYNC.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_FSYNC.9 +++ share/man/man9/VOP_FSYNC.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_FSYNC.9,v 1.15 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_FSYNC.9,v 1.16 2007/05/12 13:10:55 pav Exp $ .\" .Dd July 24, 1996 .Os @@ -38,7 +38,7 @@ .In sys/param.h .In sys/vnode.h .Ft int -.Fn VOP_FSYNC "struct vnode *vp" "struct ucred *cred" "int waitfor" "struct thread *td" +.Fn VOP_FSYNC "struct vnode *vp" "int waitfor" "struct thread *td" .Sh DESCRIPTION This call flushes any dirty file system buffers for the file. It is used to implement the @@ -51,8 +51,6 @@ .Bl -tag -width waitfor .It Fa vp The vnode of the file. -.It Fa cred -The caller's credentials. .It Fa waitfor Whether the function should wait for I/O to complete. Possible values are: @@ -84,7 +82,7 @@ .Sh PSEUDOCODE .Bd -literal int -vop_fsync(struct vnode *vp, struct ucred *cred, int waitfor, struct thread *td) +vop_fsync(struct vnode *vp, int waitfor, struct thread *td) { struct buf *bp; struct buf *nbp; Index: driver.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/driver.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/driver.9 -L share/man/man9/driver.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/driver.9 +++ share/man/man9/driver.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/driver.9,v 1.11 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/driver.9,v 1.12 2005/08/08 12:16:53 brian Exp $ .\" .Dd June 16, 1998 .Dt DRIVER 9 @@ -45,7 +45,7 @@ static int foo_frob(device_t, int, int); static int foo_twiddle(device_t, char *); -static struct device_method_t foo_methods[] = { +static device_method_t foo_methods[] = { /* Methods from the device interface */ DEVMETHOD(device_probe, foo_probe), DEVMETHOD(device_attach, foo_attach), Index: vm_page_free.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_free.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_free.9 -L share/man/man9/vm_page_free.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_free.9 +++ share/man/man9/vm_page_free.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_free.9,v 1.2 2001/08/08 10:04:08 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 2001 .Dt VM_PAGE_FREE 9 Index: VFS_SYNC.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_SYNC.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_SYNC.9 -L share/man/man9/VFS_SYNC.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_SYNC.9 +++ share/man/man9/VFS_SYNC.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_SYNC.9,v 1.15 2005/06/15 13:31:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_SYNC.9,v 1.16 2007/05/12 13:10:55 pav Exp $ .\" .Dd January 7, 2005 .Os @@ -39,7 +39,7 @@ .In sys/mount.h .In sys/vnode.h .Ft int -.Fn VFS_SYNC "struct mount *mp" "int waitfor" "struct ucred *cred" "struct thread *td" +.Fn VFS_SYNC "struct mount *mp" "int waitfor" "struct thread *td" .Sh DESCRIPTION The .Fn VFS_SYNC @@ -61,8 +61,6 @@ .It Dv MNT_LAZY push data not written by file system syncer .El -.It Fa cred -The caller's credentials. .It Fa td The calling thread. .El Index: sbuf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sbuf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sbuf.9 -L share/man/man9/sbuf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sbuf.9 +++ share/man/man9/sbuf.9 @@ -23,12 +23,13 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sbuf.9,v 1.24 2004/07/09 11:44:49 des Exp $ +.\" $FreeBSD: src/share/man/man9/sbuf.9,v 1.26 2006/09/18 15:24:20 ru Exp $ .\" .Dd July 9, 2004 .Dt SBUF 9 .Os .Sh NAME +.Nm sbuf , .Nm sbuf_new , .Nm sbuf_clear , .Nm sbuf_setpos , @@ -92,7 +93,7 @@ .Fn sbuf_delete "struct sbuf *s" .Sh DESCRIPTION The -.Nm sbuf +.Nm family of functions allows one to safely allocate, construct and release bounded null-terminated strings in kernel space. Instead of arrays of characters, these functions operate on structures @@ -308,35 +309,48 @@ or it is reinitialized to a sufficiently short string using .Fn sbuf_cpy . .Sh RETURN VALUES +The .Fn sbuf_new -returns +function returns .Dv NULL if it failed to allocate a storage buffer, and a pointer to the new .Fa sbuf otherwise. .Pp +The .Fn sbuf_setpos -returns \-1 if +function returns \-1 if .Fa pos was invalid, and zero otherwise. .Pp +The .Fn sbuf_cat , .Fn sbuf_cpy , .Fn sbuf_printf , .Fn sbuf_putc , and .Fn sbuf_trim +functions all return \-1 if the buffer overflowed, and zero otherwise. .Pp +The .Fn sbuf_overflowed +function returns a non-zero value if the buffer overflowed, and zero otherwise. .Pp +The .Fn sbuf_data and .Fn sbuf_len -return +functions return .Dv NULL and \-1, respectively, if the buffer overflowed. +.Pp +The +.Fn sbuf_copyin +function +returns \-1 if copying string from userland failed, and number of bytes +copied otherwise. .Sh SEE ALSO .Xr printf 3 , .Xr strcat 3 , @@ -346,13 +360,13 @@ .Xr printf 9 .Sh HISTORY The -.Nm sbuf +.Nm family of functions first appeared in .Fx 4.4 . .Sh AUTHORS .An -nosplit The -.Nm sbuf +.Nm family of functions was designed by .An Poul-Henning Kamp Aq phk at FreeBSD.org and implemented by Index: sysctl_add_oid.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sysctl_add_oid.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sysctl_add_oid.9 -L share/man/man9/sysctl_add_oid.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sysctl_add_oid.9 +++ share/man/man9/sysctl_add_oid.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sysctl_add_oid.9,v 1.20 2004/07/03 18:29:24 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sysctl_add_oid.9,v 1.21 2006/04/28 10:45:27 rwatson Exp $ .\" .Dd July 15, 2000 .Dt SYSCTL_ADD_OID 9 @@ -496,6 +496,7 @@ .Em "Care should be taken to free all oids once they are no longer needed!" .Sh SEE ALSO .Xr sysctl 8 , +.Xr sysctl 9 , .Xr sysctl_ctx_free 9 , .Xr sysctl_ctx_init 9 .Sh HISTORY Index: selrecord.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/selrecord.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/selrecord.9 -L share/man/man9/selrecord.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/selrecord.9 +++ share/man/man9/selrecord.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/selrecord.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/selrecord.9,v 1.4 2007/06/14 22:38:50 njl Exp $ .\" -.Dd March 20, 2002 +.Dd June 13, 2007 .Dt SELRECORD 9 .Os .Sh NAME @@ -86,6 +86,13 @@ .Xr poll 2 when they wake up. .Pp +The contents of +.Fa *sip +must be zeroed, such as by softc initialization, before any call to +.Fn selrecord +or +.Fn selwakeup , +otherwise a panic may occur. .Fn selwakeup acquires and releases .Va sellock Index: VFS.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS.9 -L share/man/man9/VFS.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS.9 +++ share/man/man9/VFS.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS.9,v 1.11.2.1 2005/07/27 02:11:20 scottl Exp $ +.\" $FreeBSD: src/share/man/man9/VFS.9,v 1.12 2005/07/27 02:08:59 scottl Exp $ .\" .Dd July 24, 1996 .Os --- /dev/null +++ share/man/man9/p_cansee.9 @@ -0,0 +1,93 @@ +.\" +.\" Copyright (c) 2003 Joseph Koshy +.\" Copyright (c) 2006 Ceri Davies +.\" +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/p_cansee.9,v 1.1 2006/11/19 13:35:03 ceri Exp $ +.\" +.Dd November 19, 2006 +.Os +.Dt P_CANSEE 9 +.Sh NAME +.Nm p_cansee +.Nd determine visibility of a process +.Sh SYNOPSIS +.In sys/param.h +.In sys/proc.h +.Ft int +.Fn p_cansee "struct thread *td" "struct proc *p" +.Sh DESCRIPTION +This function can be used to determine if a given process +.Fa p +is visible to the thread +.Fa td , +where the notion of +.Dq visibility +may be read as +.Dq "awareness of existence" . +.Pp +The function is implemented using +.Xr cr_cansee 9 , +and the dependencies on +.Xr sysctl 8 +variables documented in the +.Xr cr_cansee 9 +manual page apply. +.Sh RETURN VALUES +The +.Fn p_cansee +function +returns +.Li 0 +if the process denoted by +.Fa p +is visible by thread +.Fa td , +or a non-zero error return value otherwise. +.Sh ERRORS +.Bl -tag -width Er +.It Bq Er ESRCH +Process +.Fa p +is not visible to thread +.Fa td +as determined by +.Xr cr_cansee 9 . +.It Bq Er ESRCH +Thread +.Fa td +has been jailed and process +.Fa p +does not belong to the same jail as +.Fa td . +.It Bq Er ESRCH +The MAC subsystem denied visibility. +.El +.Sh SEE ALSO +.Xr jail 2 , +.Xr sysctl 8 , +.Xr cr_cansee 9 , +.Xr mac 9 , +.Xr p_candebug 9 , +.Xr prison_check 9 --- /dev/null +++ share/man/man9/sf_buf.9 @@ -0,0 +1,141 @@ +.\" +.\" Copyright (c) 2007 Seccuris Inc. +.\" All rights reserved. +.\" +.\" This documentation was written by Robert N. M. Watson under contract to +.\" Seccuris Inc. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/sf_buf.9,v 1.2 2007/01/31 09:40:31 rwatson Exp $ +.\" +.Dd January 28, 2007 +.Dt SF_BUF 9 +.Os +.Sh NAME +.Nm sf_buf +.Nd manage temporary kernel address space mapping for memory pages +.Sh SYNOPSIS +.In sys/sf_buf.h +.Ft struct sf_buf * +.Fn sf_buf_alloc "struct vm_page *m" "int flags" +.Ft void +.Fn sf_buf_free "struct sf_buf *sf" +.Ft vm_offset_t +.Fn sf_buf_kva "struct sf_buf *sf" +.Ft struct vm_page * +.Fn sf_buf_page "struct sf_buf *sf" +.Sh DESCRIPTION +The +.Nm +interface, historically the +.Xr sendfile 2 +buffer interface, allows kernel subsystems to manage temporary kernel address +space mappings for physical memory pages. +On systems with a direct memory map region (allowing all physical pages to be +visible in the kernel address space at all times), the +.Vt "struct sf_buf" +will point to an address in the direct map region; on systems without a +direct memory map region, the +.Vt "struct sf_buf" +will manage a temporary kernel address space mapping valid for the lifetime +of the +.Vt "struct sf_buf". +.Pp +Call +.Fn sf_buf_alloc +to allocate a +.Vt "struct sf_buf" +for a physical memory page. +.Fn sf_buf_alloc +is not responsible for arranging for the page to be present in physical +memory; the caller should already have arranged for the page to be wired, +i.e., by calling +.Xr vm_page_wire 9 . +Several flags may be passed to +.Fn sf_buf_alloc : +.Bl -tag -width SFB_CPUPRIVATE +.It Dv SFB_CATCH +Cause +.Fn sf_buf_alloc +to abort and return +.Dv NULL +if a signal is received waiting for a +.Vt "struct sf_buf" +to become available. +.It Dv SFB_NOWAIT +Cause +.Fn sf_buf_alloc +to return +.Dv NULL +rather than sleeping if a +.Vt "struct sf_buf" +is not immediately available. +.It Dv SFB_CPUPRIVATE +Cause +.Fn sf_buf_alloc +to only arrange that the temporary mapping be valid on the current CPU, +avoiding unnecessary TLB shootdowns for mappings that will only be accessed +on a single CPU at a time. +The caller must ensure that accesses to the virtual address occur only on the +CPU from which +.Fn sf_buf_alloc +was invoked, perhaps by using +.Fn sched_pin . +.El +.Pp +Call +.Fn sf_buf_kva +to return a kernel mapped address for the page. +.Pp +Call +.Fn sf_buf_page +to return a pointer to the page originally passed into +.Fn sf_buf_alloc . +.Pp +Call +.Fn sf_buf_free +to release the +.Vt "struct sf_buf" +reference. +The caller is responsible for releasing any wiring they have previously +acquired on the physical page; +.Fn sf_buf_free +releases only the temporary kernel address space mapping, not the page +itself. +.Pp +Uses of this interface include managing mappings of borrowed pages from user +memory, such as in zero-copy socket I/O, or pages of memory from the buffer +cache referenced by mbuf external storage for +.Xr sendfile 2 . +.Sh SEE ALSO +.Xr sendfile 2 , +.Xr vm_page_wire 9 +.Sh AUTHORS +The +.Vt "struct sf_buf" +API was designed and implemented by +.An Alan L. Cox . +This manual page was written by +.An Robert N. M. Watson . Index: kobj.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/kobj.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/kobj.9 -L share/man/man9/kobj.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/kobj.9 +++ share/man/man9/kobj.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/kobj.9,v 1.16 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/kobj.9,v 1.17 2006/10/28 10:57:35 maxim Exp $ .\" .Dd April 4, 2000 .Dt KOBJ 9 @@ -83,7 +83,7 @@ specified by the class and initialise it by zeroing the memory and installing a pointer to the class' method dispatch table. Objects created in this way should be freed by calling -.Fn kobj_free . +.Fn kobj_delete . .Pp Clients which would like to manage the allocation of memory themselves should call Index: Makefile =================================================================== RCS file: /home/cvs/src/share/man/man9/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/Makefile -L share/man/man9/Makefile -u -r1.2 -r1.3 --- share/man/man9/Makefile +++ share/man/man9/Makefile @@ -1,4 +1,5 @@ -# $FreeBSD: src/share/man/man9/Makefile,v 1.260.2.5 2006/02/23 02:13:29 mlaier Exp $ +# $MidnightBSD$ +# $FreeBSD: src/share/man/man9/Makefile,v 1.310.2.1.2.1 2008/02/15 15:19:26 brueffer Exp $ MAN= accept_filter.9 \ accf_data.9 \ @@ -38,8 +39,10 @@ byteorder.9 \ cd.9 \ condvar.9 \ + config_intrhook.9 \ contigmalloc.9 \ copy.9 \ + cr_cansee.9 \ critical_enter.9 \ cr_seeothergids.9 \ cr_seeotheruids.9 \ @@ -72,6 +75,7 @@ device_get_parent.9 \ device_get_softc.9 \ device_get_state.9 \ + device_get_sysctl.9 \ device_get_unit.9 \ DEVICE_IDENTIFY.9 \ device_ids.9 \ @@ -85,7 +89,6 @@ DEVICE_SHUTDOWN.9 \ DEV_MODULE.9 \ devstat.9 \ - devsw.9 \ devtoname.9 \ disk.9 \ domain.9 \ @@ -127,9 +130,12 @@ kernacc.9 \ kernel_mount.9 \ kobj.9 \ + kqueue.9 \ kthread.9 \ ktr.9 \ lock.9 \ + locking.9 \ + LOCK_PROFILING.9 \ mac.9 \ make_dev.9 \ malloc.9 \ @@ -149,11 +155,11 @@ MODULE_VERSION.9 \ mtx_pool.9 \ mutex.9 \ - MUTEX_PROFILING.9 \ namei.9 \ panic.9 \ pbuf.9 \ p_candebug.9 \ + p_cansee.9 \ pci.9 \ pfil.9 \ pfind.9 \ @@ -185,10 +191,12 @@ pmap_zero_page.9 \ printf.9 \ prison_check.9 \ + priv.9 \ pseudofs.9 \ psignal.9 \ random.9 \ random_harvest.9 \ + redzone.9 \ resettodr.9 \ resource_int_value.9 \ rijndael.9 \ @@ -196,21 +204,26 @@ rtalloc.9 \ rtentry.9 \ runqueue.9 \ + rwlock.9 \ sbuf.9 \ scheduler.9 \ securelevel_gt.9 \ selrecord.9 \ sema.9 \ + sf_buf.9 \ signal.9 \ sleep.9 \ sleepqueue.9 \ + socket.9 \ spl.9 \ + stack.9 \ store.9 \ style.9 \ suser.9 \ swi.9 \ sx.9 \ SYSCALL_MODULE.9 \ + sysctl.9 \ sysctl_add_oid.9 \ sysctl_ctx_init.9 \ taskqueue.9 \ @@ -221,6 +234,7 @@ ucred.9 \ uidinfo.9 \ uio.9 \ + usbdi.9 \ utopia.9 \ vaccess.9 \ vaccess_acl_posix1e.9 \ @@ -232,6 +246,7 @@ vfsconf.9 \ VFS_FHTOVP.9 \ vfs_getnewfsid.9 \ + vfs_getopt.9 \ vfs_getvfs.9 \ VFS_LOCK_GIANT.9 \ VFS_MOUNT.9 \ @@ -249,7 +264,6 @@ VFS_UNMOUNT.9 \ vfs_unmountall.9 \ VFS_VGET.9 \ - VFS_VPTOFH.9 \ vget.9 \ vgone.9 \ vhold.9 \ @@ -292,7 +306,6 @@ vm_page_protect.9 \ vm_page_rename.9 \ vm_page_sleep_busy.9 \ - vm_page_unmanage.9 \ vm_page_wakeup.9 \ vm_page_wire.9 \ vm_page_zero_fill.9 \ @@ -331,6 +344,7 @@ VOP_SETACL.9 \ VOP_SETEXTATTR.9 \ VOP_STRATEGY.9 \ + VOP_VPTOFH.9 \ vput.9 \ vref.9 \ vrele.9 \ @@ -368,6 +382,7 @@ bus_dma.9 bus_dmamap_destroy.9 \ bus_dma.9 bus_dmamap_load.9 \ bus_dma.9 bus_dmamap_load_mbuf.9 \ + bus_dma.9 bus_dmamap_load_mbuf_sg.9 \ bus_dma.9 bus_dmamap_load_uio.9 \ bus_dma.9 bus_dmamap_sync.9 \ bus_dma.9 bus_dmamap_unload.9 \ @@ -380,6 +395,83 @@ MLINKS+=BUS_SETUP_INTR.9 bus_setup_intr.9 \ BUS_SETUP_INTR.9 BUS_TEARDOWN_INTR.9 \ BUS_SETUP_INTR.9 bus_teardown_intr.9 +MLINKS+=bus_space.9 bus_space_barrier.9 \ + bus_space.9 bus_space_copy_region_1.9 \ + bus_space.9 bus_space_copy_region_2.9 \ + bus_space.9 bus_space_copy_region_4.9 \ + bus_space.9 bus_space_copy_region_8.9 \ + bus_space.9 bus_space_copy_region_stream_1.9 \ + bus_space.9 bus_space_copy_region_stream_2.9 \ + bus_space.9 bus_space_copy_region_stream_4.9 \ + bus_space.9 bus_space_copy_region_stream_8.9 \ + bus_space.9 bus_space_free.9 \ + bus_space.9 bus_space_map.9 \ + bus_space.9 bus_space_read_1.9 \ + bus_space.9 bus_space_read_2.9 \ + bus_space.9 bus_space_read_4.9 \ + bus_space.9 bus_space_read_8.9 \ + bus_space.9 bus_space_read_multi_1.9 \ + bus_space.9 bus_space_read_multi_2.9 \ + bus_space.9 bus_space_read_multi_4.9 \ + bus_space.9 bus_space_read_multi_8.9 \ + bus_space.9 bus_space_read_multi_stream_1.9 \ + bus_space.9 bus_space_read_multi_stream_2.9 \ + bus_space.9 bus_space_read_multi_stream_4.9 \ + bus_space.9 bus_space_read_multi_stream_8.9 \ + bus_space.9 bus_space_read_region_1.9 \ + bus_space.9 bus_space_read_region_2.9 \ + bus_space.9 bus_space_read_region_4.9 \ + bus_space.9 bus_space_read_region_8.9 \ + bus_space.9 bus_space_read_region_stream_1.9 \ + bus_space.9 bus_space_read_region_stream_2.9 \ + bus_space.9 bus_space_read_region_stream_4.9 \ + bus_space.9 bus_space_read_region_stream_8.9 \ + bus_space.9 bus_space_read_stream_1.9 \ + bus_space.9 bus_space_read_stream_2.9 \ + bus_space.9 bus_space_read_stream_4.9 \ + bus_space.9 bus_space_read_stream_8.9 \ + bus_space.9 bus_space_set_multi_1.9 \ + bus_space.9 bus_space_set_multi_2.9 \ + bus_space.9 bus_space_set_multi_4.9 \ + bus_space.9 bus_space_set_multi_8.9 \ + bus_space.9 bus_space_set_multi_stream_1.9 \ + bus_space.9 bus_space_set_multi_stream_2.9 \ + bus_space.9 bus_space_set_multi_stream_4.9 \ + bus_space.9 bus_space_set_multi_stream_8.9 \ + bus_space.9 bus_space_set_region_1.9 \ + bus_space.9 bus_space_set_region_2.9 \ + bus_space.9 bus_space_set_region_4.9 \ + bus_space.9 bus_space_set_region_8.9 \ + bus_space.9 bus_space_set_region_stream_1.9 \ + bus_space.9 bus_space_set_region_stream_2.9 \ + bus_space.9 bus_space_set_region_stream_4.9 \ + bus_space.9 bus_space_set_region_stream_8.9 \ + bus_space.9 bus_space_subregion.9 \ + bus_space.9 bus_space_unmap.9 \ + bus_space.9 bus_space_write_1.9 \ + bus_space.9 bus_space_write_2.9 \ + bus_space.9 bus_space_write_4.9 \ + bus_space.9 bus_space_write_8.9 \ + bus_space.9 bus_space_write_multi_1.9 \ + bus_space.9 bus_space_write_multi_2.9 \ + bus_space.9 bus_space_write_multi_4.9 \ + bus_space.9 bus_space_write_multi_8.9 \ + bus_space.9 bus_space_write_multi_stream_1.9 \ + bus_space.9 bus_space_write_multi_stream_2.9 \ + bus_space.9 bus_space_write_multi_stream_4.9 \ + bus_space.9 bus_space_write_multi_stream_8.9 \ + bus_space.9 bus_space_write_region_1.9 \ + bus_space.9 bus_space_write_region_2.9 \ + bus_space.9 bus_space_write_region_4.9 \ + bus_space.9 bus_space_write_region_8.9 \ + bus_space.9 bus_space_write_region_stream_1.9 \ + bus_space.9 bus_space_write_region_stream_2.9 \ + bus_space.9 bus_space_write_region_stream_4.9 \ + bus_space.9 bus_space_write_region_stream_8.9 \ + bus_space.9 bus_space_write_stream_1.9 \ + bus_space.9 bus_space_write_stream_2.9 \ + bus_space.9 bus_space_write_stream_4.9 \ + bus_space.9 bus_space_write_stream_8.9 MLINKS+=byteorder.9 be16dec.9 \ byteorder.9 be16enc.9 \ byteorder.9 be16toh.9 \ @@ -416,7 +508,10 @@ condvar.9 cv_timedwait_sig.9 \ condvar.9 cv_wait.9 \ condvar.9 cv_wait_sig.9 \ + condvar.9 cv_wait_unlock.9 \ condvar.9 cv_wmesg.9 +MLINKS+=config_intrhook.9 config_intrhook_disestablish.9 \ + config_intrhook.9 config_intrhook_establish.9 MLINKS+=contigmalloc.9 contigfree.9 MLINKS+=copy.9 copyin.9 \ copy.9 copyinstr.9 \ @@ -424,20 +519,20 @@ copy.9 copystr.9 MLINKS+=critical_enter.9 critical.9 \ critical_enter.9 critical_exit.9 -MLINKS+=crypto.9 crypto_get_driverid.9 \ - crypto.9 crypto_register.9 \ - crypto.9 crypto_kregister.9 \ - crypto.9 crypto_unregister.9 \ - crypto.9 crypto_unregister_all.9 \ +MLINKS+=crypto.9 crypto_dispatch.9 \ crypto.9 crypto_done.9 \ - crypto.9 crypto_kdone.9 \ - crypto.9 crypto_newsession.9 \ + crypto.9 crypto_freereq.9 \ crypto.9 crypto_freesession.9 \ - crypto.9 crypto_dispatch.9 \ + crypto.9 crypto_get_driverid.9 \ + crypto.9 crypto_getreq.9 \ crypto.9 crypto_kdispatch.9 \ + crypto.9 crypto_kdone.9 \ + crypto.9 crypto_kregister.9 \ + crypto.9 crypto_newsession.9 \ + crypto.9 crypto_register.9 \ crypto.9 crypto_unblock.9 \ - crypto.9 crypto_getreq.9 \ - crypto.9 crypto_freereq.9 + crypto.9 crypto_unregister.9 \ + crypto.9 crypto_unregister_all.9 MLINKS+=devclass_add_driver.9 devclass_delete_driver.9 \ devclass_add_driver.9 devclass_find_driver.9 MLINKS+=device_add_child.9 device_add_child_ordered.9 @@ -449,6 +544,8 @@ device_get_state.9 device_is_alive.9 \ device_get_state.9 device_is_attached.9 \ device_get_state.9 device_unbusy.9 +MLINKS+=device_get_sysctl.9 device_get_sysctl_ctx.9 \ + device_get_sysctl.9 device_get_sysctl_tree.9 MLINKS+=device_ids.9 major.9 \ device_ids.9 minor.9 \ device_ids.9 umajor.9 \ @@ -467,19 +564,19 @@ disk.9 disk_destroy.9 MLINKS+=domain.9 DOMAIN_SET.9 \ domain.9 net_add_domain.9 \ - domain.9 pfctlinput2.9 \ domain.9 pfctlinput.9 \ + domain.9 pfctlinput2.9 \ domain.9 pffindproto.9 \ domain.9 pffindtype.9 MLINKS+=DRIVER_MODULE.9 MULTI_DRIVER_MODULE.9 MLINKS+=EVENTHANDLER.9 EVENTHANDLER_DECLARE.9 \ EVENTHANDLER.9 EVENTHANDLER_DEREGISTER.9 \ EVENTHANDLER.9 eventhandler_deregister.9 \ + EVENTHANDLER.9 eventhandler_find_list.9 \ EVENTHANDLER.9 EVENTHANDLER_INVOKE.9 \ + EVENTHANDLER.9 eventhandler_prune_list.9 \ EVENTHANDLER.9 EVENTHANDLER_REGISTER.9 \ - EVENTHANDLER.9 eventhandler_register.9 \ - EVENTHANDLER.9 eventhandler_find_list.9 \ - EVENTHANDLER.9 eventhandler_prune_list.9 + EVENTHANDLER.9 eventhandler_register.9 MLINKS+=fetch.9 fubyte.9 \ fetch.9 fuswintr.9 \ fetch.9 fusword.9 \ @@ -501,8 +598,15 @@ MLINKS+=g_provider.9 g_destroy_provider.9 \ g_provider.9 g_error_provider.9 \ g_provider.9 g_new_providerf.9 +MLINKS+=hash.9 hash32.9 \ + hash.9 hash32_buf.9 \ + hash.9 hash32_str.9 \ + hash.9 hash32_stre.9 \ + hash.9 hash32_strn.9 \ + hash.9 hash32_strne.9 MLINKS+=hashinit.9 hashdestroy.9 \ - hashinit.9 phashinit.9 + hashinit.9 phashinit.9 \ + hashinit.9 hashinit_flags.9 MLINKS+=ieee80211.9 ieee80211_attach.9 \ ieee80211.9 ieee80211_chan2ieee.9 \ ieee80211.9 ieee80211_chan2mode.9 \ @@ -572,6 +676,20 @@ kobj.9 kobj_create.9 \ kobj.9 kobj_delete.9 \ kobj.9 kobj_init.9 +MLINKS+=kqueue.9 knlist_add.9 \ + kqueue.9 knlist_clear.9 \ + kqueue.9 knlist_delete.9 \ + kqueue.9 knlist_destroy.9 \ + kqueue.9 knlist_empty.9 \ + kqueue.9 knlist_init.9 \ + kqueue.9 knlist_remove.9 \ + kqueue.9 knlist_remove_inevent.9 \ + kqueue.9 knote_fdclose.9 \ + kqueue.9 KNOTE_LOCKED.9 \ + kqueue.9 KNOTE_UNLOCKED.9 \ + kqueue.9 kqfd_register.9 \ + kqueue.9 kqueue_add_filteropts.9 \ + kqueue.9 kqueue_del_filteropts.9 MLINKS+=kthread.9 kproc_shutdown.9 \ kthread.9 kproc_start.9 \ kthread.9 kthread_create.9 \ @@ -591,6 +709,7 @@ lock.9 lockmgr.9 \ lock.9 lockmgr_printinfo.9 \ lock.9 lockstatus.9 +MLINKS+=LOCK_PROFILING.9 MUTEX_PROFILING.9 MLINKS+=make_dev.9 destroy_dev.9 \ make_dev.9 dev_depends.9 \ make_dev.9 make_dev_alias.9 @@ -720,6 +839,7 @@ mutex.9 mtx_lock_spin_flags.9 \ mutex.9 mtx_owned.9 \ mutex.9 mtx_recursed.9 \ + mutex.9 mtx_sleep.9 \ mutex.9 MTX_SYSINIT.9 \ mutex.9 mtx_trylock.9 \ mutex.9 mtx_trylock_flags.9 \ @@ -737,6 +857,7 @@ pci.9 pci_enable_busmaster.9 \ pci.9 pci_enable_io.9 \ pci.9 pci_find_bsf.9 \ + pci.9 pci_find_dbsf.9 \ pci.9 pci_find_device.9 \ pci.9 pci_get_powerstate.9 \ pci.9 pci_read_config.9 \ @@ -763,6 +884,8 @@ MLINKS+=printf.9 log.9 \ printf.9 tprintf.9 \ printf.9 uprintf.9 +MLINKS+=priv.9 priv_check.9 \ + priv.9 priv_check_cred.9 MLINKS+=psignal.9 gsignal.9 \ psignal.9 pgsignal.9 MLINKS+=random.9 arc4rand.9 \ @@ -775,7 +898,6 @@ rman.9 rman_await_resource.9 \ rman.9 rman_deactivate_resource.9 \ rman.9 rman_fini.9 \ - rman.9 rman_fini.9 \ rman.9 rman_get_bushandle.9 \ rman.9 rman_get_bustag.9 \ rman.9 rman_get_device.9 \ @@ -797,12 +919,25 @@ rman.9 rman_set_virtual.9 MLINKS+=rtalloc.9 rtalloc1.9 \ rtalloc.9 rtalloc_ign.9 \ - rtalloc.9 rtfree.9 \ - rtalloc.9 RTFREE.9 + rtalloc.9 RTFREE.9 \ + rtalloc.9 rtfree.9 MLINKS+=runqueue.9 chooseproc.9 \ runqueue.9 procrunnable.9 \ runqueue.9 remrunqueue.9 \ runqueue.9 setrunqueue.9 +MLINKS+=rwlock.9 rw_assert.9 \ + rwlock.9 rw_destroy.9 \ + rwlock.9 rw_downgrade.9 \ + rwlock.9 rw_init.9 \ + rwlock.9 rw_initialized.9 \ + rwlock.9 rw_rlock.9 \ + rwlock.9 rw_runlock.9 \ + rwlock.9 rw_sleep.9 \ + rwlock.9 RW_SYSINIT.9 \ + rwlock.9 rw_try_upgrade.9 \ + rwlock.9 rw_wlock.9 \ + rwlock.9 rw_wowned.9 \ + rwlock.9 rw_wunlock.9 MLINKS+=sbuf.9 sbuf_bcat.9 \ sbuf.9 sbuf_bcopyin.9 \ sbuf.9 sbuf_bcpy.9 \ @@ -841,6 +976,10 @@ sema.9 sema_trywait.9 \ sema.9 sema_value.9 \ sema.9 sema_wait.9 +MLINKS+=sf_buf.9 sf_buf_alloc.9 \ + sf_buf.9 sf_buf_free.9 \ + sf_buf.9 sf_buf_kva.9 \ + sf_buf.9 sf_buf_page.9 MLINKS+=signal.9 cursig.9 \ signal.9 execsigs.9 \ signal.9 issignal.9 \ @@ -868,6 +1007,8 @@ signal.9 SIG_STOPSIGMASK.9 \ signal.9 trapsignal.9 MLINKS+=sleep.9 msleep.9 \ + sleep.9 msleep_spin.9 \ + sleep.9 pause.9 \ sleep.9 tsleep.9 \ sleep.9 wakeup.9 \ sleep.9 wakeup_one.9 @@ -888,6 +1029,15 @@ sleepqueue.9 sleepq_timedwait_sig.9 \ sleepqueue.9 sleepq_wait.9 \ sleepqueue.9 sleepq_wait_sig.9 +MLINKS+=socket.9 sobind.9 \ + socket.9 soclose.9 \ + socket.9 soconnect.9 \ + socket.9 socreate.9 \ + socket.9 sogetopt.9 \ + socket.9 soreceive.9 \ + socket.9 sosetopt.9 \ + socket.9 sosend.9 \ + socket.9 soshutdown.9 MLINKS+=spl.9 spl0.9 \ spl.9 splbio.9 \ spl.9 splclock.9 \ @@ -900,6 +1050,14 @@ spl.9 spltty.9 \ spl.9 splvm.9 \ spl.9 splx.9 +MLINKS+=stack.9 stack_copy.9 \ + stack.9 stack_create.9 \ + stack.9 stack_destroy.9 \ + stack.9 stack_printf.9 \ + stack.9 stack_put.9 \ + stack.9 stack_save.9 \ + stack.9 stack_sbuf_print.9 \ + stack.9 stack_zero.9 MLINKS+=store.9 subyte.9 \ store.9 suswintr.9 \ store.9 susword.9 \ @@ -911,14 +1069,31 @@ sx.9 sx_destroy.9 \ sx.9 sx_downgrade.9 \ sx.9 sx_init.9 \ + sx.9 sx_init_flags.9 \ sx.9 sx_slock.9 \ sx.9 sx_sunlock.9 \ sx.9 SX_SYSINIT.9 \ sx.9 sx_try_slock.9 \ sx.9 sx_try_upgrade.9 \ sx.9 sx_try_xlock.9 \ + sx.9 sx_sleep.9 \ + sx.9 sx_unlock.9 \ + sx.9 sx_xholder.9 \ sx.9 sx_xlock.9 \ + sx.9 sx_xlocked.9 \ sx.9 sx_xunlock.9 +MLINKS+=sysctl.9 SYSCTL_DECL.9 \ + sysctl.9 SYSCTL_INT.9 \ + sysctl.9 SYSCTL_LONG.9 \ + sysctl.9 SYSCTL_NODE.9 \ + sysctl.9 SYSCTL_OPAQUE.9 \ + sysctl.9 SYSCTL_PROC.9 \ + sysctl.9 SYSCTL_STRING.9 \ + sysctl.9 SYSCTL_STRUCT.9 \ + sysctl.9 SYSCTL_UINT.9 \ + sysctl.9 SYSCTL_ULONG.9 \ + sysctl.9 SYSCTL_XINT.9 \ + sysctl.9 SYSCTL_XLONG.9 MLINKS+=sysctl_add_oid.9 SYSCTL_ADD_INT.9 \ sysctl_add_oid.9 SYSCTL_ADD_LONG.9 \ sysctl_add_oid.9 SYSCTL_ADD_NODE.9 \ @@ -971,13 +1146,68 @@ uidinfo.9 uihashinit.9 \ uidinfo.9 uihold.9 MLINKS+=uio.9 uiomove.9 +MLINKS+=usbdi.9 usbd_abort_default_pipe.9 \ + usbdi.9 usbd_abort_pipe.9 \ + usbdi.9 usbd_alloc_buffer.9 \ + usbdi.9 usbd_alloc_xfer.9 \ + usbdi.9 usbd_clear_endpoint_stall.9 \ + usbdi.9 usbd_clear_endpoint_stall_async.9 \ + usbdi.9 usbd_clear_endpoint_toggle.9 \ + usbdi.9 usbd_close_pipe.9 \ + usbdi.9 usbd_device2interface_handle.9 \ + usbdi.9 usbd_do_request.9 \ + usbdi.9 usbd_do_request_async.9 \ + usbdi.9 usbd_do_request_flags.9 \ + usbdi.9 usbd_do_request_flags_pipe.9 \ + usbdi.9 usbd_endpoint_count.9 \ + usbdi.9 usbd_errstr.9 \ + usbdi.9 usbd_find_edesc.9 \ + usbdi.9 usbd_find_idesc.9 \ + usbdi.9 usbd_free_buffer.9 \ + usbdi.9 usbd_free_xfer.9 \ + usbdi.9 usbd_get_buffer.9 \ + usbdi.9 usbd_get_config.9 \ + usbdi.9 usbd_get_config_desc.9 \ + usbdi.9 usbd_get_config_desc_full.9 \ + usbdi.9 usbd_get_config_descriptor.9 \ + usbdi.9 usbd_get_device_descriptor.9 \ + usbdi.9 usbd_get_endpoint_descriptor.9 \ + usbdi.9 usbd_get_interface_altindex.9 \ + usbdi.9 usbd_get_interface_descriptor.9 \ + usbdi.9 usbd_get_no_alts.9 \ + usbdi.9 usbd_get_quirks.9 \ + usbdi.9 usbd_get_speed.9 \ + usbdi.9 usbd_get_string.9 \ + usbdi.9 usbd_get_string_desc.9 \ + usbdi.9 usbd_get_xfer_status.9 \ + usbdi.9 usbd_interface2device_handle.9 \ + usbdi.9 usbd_interface2endpoint_descriptor.9 \ + usbdi.9 usbd_interface_count.9 \ + usbdi.9 usbd_open_pipe.9 \ + usbdi.9 usbd_open_pipe_intr.9 \ + usbdi.9 usbd_pipe2device_handle.9 \ + usbdi.9 usbd_set_config_index.9 \ + usbdi.9 usbd_set_config_no.9 \ + usbdi.9 usbd_set_interface.9 \ + usbdi.9 usbd_setup_default_xfer.9 \ + usbdi.9 usbd_setup_isoc_xfer.9 \ + usbdi.9 usbd_setup_xfer.9 \ + usbdi.9 usbd_sync_transfer.9 \ + usbdi.9 usbd_transfer.9 \ + usbdi.9 usb_find_desc.9 MLINKS+=vcount.9 count_dev.9 MLINKS+=vfsconf.9 vfs_modevent.9 \ vfsconf.9 vfs_register.9 \ vfsconf.9 vfs_unregister.9 +MLINKS+=vfs_getopt.9 vfs_getopts.9 \ + vfs_getopt.9 vfs_flagopt.9 \ + vfs_getopt.9 vfs_scanopt.9 \ + vfs_getopt.9 vfs_copyopt.9 \ + vfs_getopt.9 vfs_filteropt.9 MLINKS+=VFS_LOCK_GIANT.9 VFS_UNLOCK_GIANT.9 MLINKS+=vgone.9 vgonel.9 -MLINKS+=vhold.9 vdrop.9 +MLINKS+=vhold.9 vdrop.9 \ + vhold.9 vdropl.9 MLINKS+=vm_map_lock.9 vm_map_lock_downgrade.9 \ vm_map_lock.9 vm_map_lock_read.9 \ vm_map_lock.9 vm_map_lock_upgrade.9 \ Index: microtime.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/microtime.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/microtime.9 -L share/man/man9/microtime.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/microtime.9 +++ share/man/man9/microtime.9 @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/microtime.9,v 1.10.2.1 2005/11/04 22:08:40 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/microtime.9,v 1.11 2005/10/13 16:01:28 jhb Exp $ .\" .Dd September 16, 2004 .Dt MICROTIME 9 Index: vm_page_io.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_io.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_io.9 -L share/man/man9/vm_page_io.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_io.9 +++ share/man/man9/vm_page_io.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_io.9,v 1.5 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_IO_START 9 Index: sx.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sx.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sx.9 -L share/man/man9/sx.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sx.9 +++ share/man/man9/sx.9 @@ -24,25 +24,31 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sx.9,v 1.31 2005/01/12 21:48:25 ru Exp $ +.\" $FreeBSD: src/share/man/man9/sx.9,v 1.41.2.1 2007/11/27 14:08:14 attilio Exp $ .\" -.Dd January 5, 2005 +.Dd November 25, 2007 .Dt SX 9 .Os .Sh NAME .Nm sx , .Nm sx_init , +.Nm sx_init_flags , .Nm sx_destroy , .Nm sx_slock , .Nm sx_xlock , +.Nm sx_slock_sig , +.Nm sx_xlock_sig , .Nm sx_try_slock , .Nm sx_try_xlock , .Nm sx_sunlock , .Nm sx_xunlock , +.Nm sx_unlock , .Nm sx_try_upgrade , .Nm sx_downgrade , +.Nm sx_sleep , +.Nm sx_xholder , +.Nm sx_xlocked , .Nm sx_assert , -.Nm sx_unlock , .Nm SX_SYSINIT .Nd kernel shared/exclusive lock .Sh SYNOPSIS @@ -52,12 +58,18 @@ .Ft void .Fn sx_init "struct sx *sx" "const char *description" .Ft void +.Fn sx_init_flags "struct sx *sx" "const char *description" "int opts" +.Ft void .Fn sx_destroy "struct sx *sx" .Ft void .Fn sx_slock "struct sx *sx" .Ft void .Fn sx_xlock "struct sx *sx" .Ft int +.Fn sx_slock_sig "struct sx *sx" +.Ft int +.Fn sx_xlock_sig "struct sx *sx" +.Ft int .Fn sx_try_slock "struct sx *sx" .Ft int .Fn sx_try_xlock "struct sx *sx" @@ -65,28 +77,36 @@ .Fn sx_sunlock "struct sx *sx" .Ft void .Fn sx_xunlock "struct sx *sx" +.Ft void +.Fn sx_unlock "struct sx *sx" .Ft int .Fn sx_try_upgrade "struct sx *sx" .Ft void .Fn sx_downgrade "struct sx *sx" +.Ft int +.Fn sx_sleep "void *chan" "struct sx *sx" "int priority" "const char *wmesg" "int timo" +.Ft "struct thread *" +.Fn sx_xholder "struct sx *sx" +.Ft int +.Fn sx_xlocked "struct sx *sx" +.Pp +.Cd "options INVARIANTS" +.Cd "options INVARIANT_SUPPORT" .Ft void .Fn sx_assert "struct sx *sx" "int what" -.\" -.Ss Nm Ss utility macros -.Fn sx_unlock "struct sx *sx" +.In sys/kernel.h .Fn SX_SYSINIT "name" "struct sx *sx" "const char *description" -.\" -.Ss Kernel options -.Cd "options INVARIANTS" -.Cd "options INVARIANT_SUPPORT" .Sh DESCRIPTION Shared/exclusive locks are used to protect data that are read far more often than they are written. -Mutexes are inherently more efficient than shared/exclusive locks, so +Shared/exclusive locks do not implement priority propagation like mutexes and +reader/writer locks to prevent priority inversions, so shared/exclusive locks should be used prudently. .Pp -Shared/exclusive locks are created with -.Fn sx_init , +Shared/exclusive locks are created with either +.Fn sx_init +or +.Fn sx_init_flags where .Fa sx is a pointer to space for a @@ -95,10 +115,46 @@ .Fa description is a pointer to a null-terminated character string that describes the shared/exclusive lock. +The +.Fa opts +argument to +.Fn sx_init_flags +specifies a set of optional flags to alter the behavior of +.Fa sx . +It contains one or more of the following flags: +.Bl -tag -width SX_ADAPTIVESPIN +.It Dv SX_ADAPTIVESPIN +If the kernel is compiled with +.Cd "options ADAPTIVE_SX" , +then lock operations for +.Fa sx +will spin instead of sleeping while an exclusive lock holder is executing on +another CPU. +.It Dv SX_DUPOK +Witness should not log messages about duplicate locks being acquired. +.It Dv SX_NOWITNESS +Instruct +.Xr witness 4 +to ignore this lock. +.It Dv SX_NOPROFILE +Do not profile this lock. +.It Dv SX_RECURSE +Allow threads to recursively acquire exclusive locks for +.Fa sx . +.It Dv SX_QUIET +Do not log any operations for this lock via +.Xr ktr 4 . +.El +.Pp Shared/exclusive locks are destroyed with .Fn sx_destroy . +The lock +.Fa sx +must not be locked by any thread when it is destroyed. +.Pp Threads acquire and release a shared lock by calling -.Fn sx_slock +.Fn sx_slock , +.Fn sx_slock_sig or .Fn sx_try_slock and @@ -106,7 +162,8 @@ or .Fn sx_unlock . Threads acquire and release an exclusive lock by calling -.Fn sx_xlock +.Fn sx_xlock , +.Fn sx_xlock_sig or .Fn sx_try_xlock and @@ -132,6 +189,20 @@ immediately; otherwise the exclusive lock will be acquired and a non-zero value will be returned. .Pp +.Fn sx_slock_sig +and +.Fn sx_xlock_sig +do the same as their normal versions but performing an interruptible sleep. +They return a non-zero value if the sleep has been interrupted by a signal +or an interrupt, otherwise 0. +.Pp +A thread can atomically release a shared/exclusive lock while waiting for an +event by calling +.Fn sx_sleep . +For more details on the parameters to this function, +see +.Xr sleep 9 . +.Pp When compiled with .Cd "options INVARIANTS" and @@ -143,29 +214,58 @@ for the assertions specified in .Fa what , and panics if they are not met. -The following assertions are supported: -.Bl -tag -width ".Dv SX_UNLOCKED" -.It Dv SX_LOCKED +One of the following assertions must be specified: +.Bl -tag -width ".Dv SA_UNLOCKED" +.It Dv SA_LOCKED Assert that the current thread has either a shared or an exclusive lock on the .Vt sx lock pointed to by the first argument. -.It Dv SX_SLOCKED +.It Dv SA_SLOCKED Assert that the current thread has a shared lock on the .Vt sx lock pointed to by the first argument. -.It Dv SX_XLOCKED +.It Dv SA_XLOCKED Assert that the current thread has an exclusive lock on the .Vt sx lock pointed to by the first argument. -.It Dv SX_UNLOCKED +.It Dv SA_UNLOCKED Assert that the current thread has no lock on the .Vt sx lock pointed to by the first argument. .El .Pp +In addition, one of the following optional assertions may be included with +either an +.Dv SA_LOCKED , +.Dv SA_SLOCKED , +or +.Dv SA_XLOCKED +assertion: +.Bl -tag -width ".Dv SA_NOTRECURSED" +.It Dv SA_RECURSED +Assert that the current thread has a recursed lock on +.Fa sx . +.It Dv SA_NOTRECURSED +Assert that the current thread does not have a recursed lock on +.Fa sx . +.El +.Pp +.Fn sx_xholder +will return a pointer to the thread which currently holds an exclusive lock on +.Fa sx . +If no thread holds an exclusive lock on +.Fa sx , +then +.Dv NULL +is returned instead. +.Pp +.Fn sx_xlocked +will return non-zero if the current thread holds the exclusive lock; +otherwise, it will return zero. +.Pp For ease of programming, .Fn sx_unlock is provided as a macro frontend to the respective functions, @@ -206,10 +306,11 @@ lock after acquiring a mutex, then the second thread would effectively end up sleeping while holding a mutex, which is not allowed. .Sh SEE ALSO -.Xr condvar 9 , -.Xr mtx_pool 9 , +.Xr locking 9 , +.Xr lock 9 , .Xr mutex 9 , .Xr panic 9 , +.Xr rwlock 9 , .Xr sema 9 .Sh BUGS Currently there is no way to assert that a lock is not held. @@ -220,8 +321,8 @@ In the .No non- Ns Dv WITNESS case, the -.Dv SX_LOCKED +.Dv SA_LOCKED and -.Dv SX_SLOCKED +.Dv SA_SLOCKED assertions merely check that some thread holds a shared lock. They do not ensure that the current thread holds a shared lock. Index: vn_fullpath.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vn_fullpath.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vn_fullpath.9 -L share/man/man9/vn_fullpath.9 -u -r1.2 -r1.3 --- share/man/man9/vn_fullpath.9 +++ share/man/man9/vn_fullpath.9 @@ -26,7 +26,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vn_fullpath.9,v 1.4 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd January 11, 2004 .Dt VN_FULLPATH 9 Index: vm_page_protect.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_protect.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_protect.9 -L share/man/man9/vm_page_protect.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_protect.9 +++ share/man/man9/vm_page_protect.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_protect.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 14, 2001 .Dt VM_PAGE_PROTECT 9 Index: utopia.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/utopia.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/utopia.9 -L share/man/man9/utopia.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/utopia.9 +++ share/man/man9/utopia.9 @@ -25,7 +25,7 @@ .\" .\" Author: Hartmut Brandt .\" -.\" $FreeBSD: src/share/man/man9/utopia.9,v 1.7 2004/07/07 07:56:58 ru Exp $ +.\" $FreeBSD: src/share/man/man9/utopia.9,v 1.8 2006/12/14 14:33:13 mpp Exp $ .\" .Dd May 8, 2003 .Dt UTOPIA 9 @@ -245,7 +245,7 @@ .It Va chip This points to a function vector for chip specific functions. Two fields -in this vector are publically available: +in this vector are publicly available: .Bl -tag -width indent .It Va type This is the type of the detected PHY chip. Index: bpf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bpf.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bpf.9 -L share/man/man9/bpf.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bpf.9 +++ share/man/man9/bpf.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bpf.9,v 1.6 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/bpf.9,v 1.7 2006/12/13 06:27:20 ru Exp $ .\" -.Dd May 19, 2004 +.Dd December 13, 2006 .Dt BPF 9 .Os .\" @@ -51,7 +51,7 @@ .Fn bpf_mtap2 "struct bpf_if *bp" "void *data" "u_int dlen" "struct mbuf *m" .Ft u_int .Fo bpf_filter -.Fa "const struct bpf_insn *pc " "u_char *pkt" "u_int *wirelen" "u_int *buflen" +.Fa "const struct bpf_insn *pc " "u_char *pkt" "u_int wirelen" "u_int buflen" .Fc .Ft int .Fn bpf_validate "const struct bpf_insn *fcode" "int flen" @@ -217,6 +217,12 @@ is the length of the original packet and .Fa buflen is the amount of data present. +The +.Fa buflen +value of 0 is special; it indicates that the +.Fa pkt +is actually a pointer to an mbuf chain +.Pq Vt "struct mbuf *" . .Pp The .Fn bpf_validate Index: vm_page_lookup.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_lookup.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_lookup.9 -L share/man/man9/vm_page_lookup.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_lookup.9 +++ share/man/man9/vm_page_lookup.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_lookup.9,v 1.2 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_LOOKUP 9 Index: pmap_zero_page.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pmap_zero_page.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/pmap_zero_page.9 -L share/man/man9/pmap_zero_page.9 -u -r1.2 -r1.3 --- share/man/man9/pmap_zero_page.9 +++ share/man/man9/pmap_zero_page.9 @@ -24,7 +24,6 @@ .\" SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/pmap_zero_page.9,v 1.3 2004/07/06 07:02:31 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 21, 2003 .Dt PMAP_ZERO 9 Index: vm_set_page_size.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_set_page_size.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_set_page_size.9 -L share/man/man9/vm_set_page_size.9 -u -r1.2 -r1.3 --- share/man/man9/vm_set_page_size.9 +++ share/man/man9/vm_set_page_size.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_set_page_size.9,v 1.4 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_SET_PAGE_SIZE 9 Index: g_bio.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/g_bio.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/g_bio.9 -L share/man/man9/g_bio.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/g_bio.9 +++ share/man/man9/g_bio.9 @@ -1,5 +1,5 @@ .\" -.\" Copyright (c) 2004 Pawel Jakub Dawidek +.\" Copyright (c) 2004-2006 Pawel Jakub Dawidek .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without @@ -22,9 +22,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/g_bio.9,v 1.9 2004/08/04 21:35:05 pjd Exp $ +.\" $FreeBSD: src/share/man/man9/g_bio.9,v 1.13 2007/05/06 12:48:39 wkoszek Exp $ .\" -.Dd January 16, 2004 +.Dd November 1, 2006 .Dt G_BIO 9 .Os .Sh NAME @@ -39,7 +39,11 @@ .Ft "struct bio *" .Fn g_new_bio void .Ft "struct bio *" +.Fn g_alloc_bio void +.Ft "struct bio *" .Fn g_clone_bio "struct bio *bp" +.Ft "struct bio *" +.Fn g_duplicate_bio "struct bio *bp" .Ft void .Fn g_destroy_bio "struct bio *bp" .Ft void @@ -71,6 +75,8 @@ Attributes are named by ascii strings and are stored in the .Va bio_attribute field. +.It Dv BIO_FLUSH +Tells underlying providers to flush their write caches. .El .It Va bio_flags Available flags: @@ -138,6 +144,13 @@ .Vt bio structure. .Pp +.Fn g_alloc_bio +- same as +.Fn g_new_bio , +but always succeeds (allocates bio with the +.Dv M_WAITOK +malloc flag). +.Pp The .Fn g_clone_bio function allocates a new @@ -174,6 +187,13 @@ Schedule the clone on its own consumer. .El .Pp +.Fn g_duplicate_bio +- same as +.Fn g_clone_bio , +but always succeeds (allocates bio with the +.Dv M_WAITOK +malloc flag). +.Pp The .Fn g_destroy_bio function deallocates and destroys the given @@ -213,7 +233,7 @@ struct bio *cbp; printf("Request received: "); - g_print_bio(); + g_print_bio(bp); printf("\\n"); sc = bp->bio_to->geom->softc; Index: sleepqueue.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sleepqueue.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/sleepqueue.9 -L share/man/man9/sleepqueue.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/sleepqueue.9 +++ share/man/man9/sleepqueue.9 @@ -21,9 +21,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sleepqueue.9,v 1.12 2005/04/19 16:30:25 jkoshy Exp $ +.\" $FreeBSD: src/share/man/man9/sleepqueue.9,v 1.16 2007/09/28 11:13:40 gabor Exp $ .\" -.Dd March 10, 2004 +.Dd August 13, 2007 .Dt SLEEPQUEUE 9 .Os .Sh NAME @@ -54,11 +54,11 @@ .Ft void .Fn sleepq_abort "struct thread *td" .Ft void -.Fn sleepq_add "void *wchan" "struct mtx *lock" "const char *wmesg" "int flags" +.Fn sleepq_add "void *wchan" "struct lock_object *lock" "const char *wmesg" "int flags" "int queue" .Ft struct sleepqueue * .Fn sleepq_alloc "void" .Ft void -.Fn sleepq_broadcast "void *wchan" "int flags" "int pri" +.Fn sleepq_broadcast "void *wchan" "int flags" "int pri" "int queue" .Ft int .Fn sleepq_calc_signal_retval "int sig" .Ft int @@ -74,7 +74,7 @@ .Ft void .Fn sleepq_remove "struct thread *td" "void *wchan" .Ft void -.Fn sleepq_signal "void *wchan" "int flags" "int pri" +.Fn sleepq_signal "void *wchan" "int flags" "int pri" "int queue" .Ft void .Fn sleepq_set_timeout "void *wchan" "int timo" .Ft int @@ -91,6 +91,8 @@ Each queue is associated with a specific wait channel when it is active, and only one queue may be associated with a wait channel at any given point in time. +The implementation of each wait channel splits its sleepqueue into 2 sub-queues +in order to enable some optimizations on threads' wakeups. An active queue holds a list of threads that are blocked on the associated wait channel. Threads that are not blocked on a wait channel have an associated inactive @@ -157,12 +159,12 @@ must be locked by a prior call to .Fn sleepq_lock when this function is called. -If a mutex is specified via the +If a lock is specified via the .Fa lock argument, and if the kernel was compiled with .Cd "options INVARIANTS" , then the sleep queue code will perform extra checks to ensure that -the mutex is used by all threads sleeping on +the lock is used by all threads sleeping on .Fa wchan . The .Fa wmesg @@ -172,18 +174,25 @@ .Fa flags parameter is a bitmask consisting of the type of sleep queue being slept on and zero or more optional flags. +The +.Fa queue +parameter specifies the sub-queue, in which the contending thread will be +inserted. .Pp -There are currently two types of sleep queues: +There are currently three types of sleep queues: .Pp .Bl -tag -width ".Dv SLEEPQ_CONDVAR" -compact .It Dv SLEEPQ_CONDVAR A sleep queue used to implement condition variables. -.It Dv SLEEPQ_MSLEEP +.It Dv SLEEPQ_SLEEP A sleep queue used to implement -.Xr msleep 9 , +.Xr sleep 9 , .Xr wakeup 9 and .Xr wakeup_one 9 . +.It Dv SLEEPQ_PAUSE +A sleep queue used to implement +.Xr pause 9 . .El .Pp There is currently only one optional flag: @@ -307,6 +316,9 @@ must be locked by a prior call to .Fn sleepq_lock before calling any of these functions. +The +.Fa queue +argument specifies the sub-queue, from which threads need to be woken up. .Pp A thread in an interruptible sleep can be interrupted by another thread via the @@ -336,7 +348,7 @@ channel. .Pp The sleep queue interface is currently used to implement the -.Xr msleep 9 +.Xr sleep 9 and .Xr condvar 9 interfaces. @@ -344,6 +356,6 @@ than manipulating sleep queues directly. .Sh SEE ALSO .Xr condvar 9 , -.Xr msleep 9 , .Xr runqueue 9 , -.Xr scheduler 9 +.Xr scheduler 9 , +.Xr sleep 9 Index: vm_map.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_map.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vm_map.9 -L share/man/man9/vm_map.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vm_map.9 +++ share/man/man9/vm_map.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_map.9,v 1.9 2005/01/15 12:28:00 ru Exp $ +.\" $FreeBSD: src/share/man/man9/vm_map.9,v 1.10 2007/01/27 18:58:33 rwatson Exp $ .\" .Dd September 26, 2004 .Dt VM_MAP 9 @@ -144,7 +144,7 @@ .It Dv MAP_DISABLE_COREDUMP Do not include the mapping in a core dump. .It Dv MAP_PREFAULT_MADVISE -Specify that the request from a user process calling +Specify that the request is from a user process calling .Xr madvise 2 . .El .Pp --- /dev/null +++ share/man/man9/redzone.9 @@ -0,0 +1,123 @@ +.\" Copyright (c) 2006 Pawel Jakub Dawidek +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHORS OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/redzone.9,v 1.1 2006/01/31 11:09:20 pjd Exp $ +.\" +.Dd January 31, 2006 +.Dt REDZONE 9 +.Os +.Sh NAME +.Nm RedZone +.Nd "buffer corruptions detector" +.Sh SYNOPSIS +.Cd "options DEBUG_REDZONE" +.Sh DESCRIPTION +.Nm +detects buffer underflow and buffer overflow bugs at runtime. +Currently +.Nm +only detects buffer corruptions for memory allocated with +.Xr malloc 9 . +When such corruption is detected two backtraces are printed on the console. +The first one shows from where memory was allocated, the second one shows from +where memory was freed. +By default the system will not panic when buffer corruption is detected. +This can be changed by setting the +.Va vm.redzone.panic +.Xr sysctl 8 +variable to 1. +The amount of extra memory allocated for +.Nm Ns 's +needs is stored in the +.Va vm.redzone.extra_mem +.Xr sysctl 8 +variable. +.Sh EXAMPLE +The example below shows the logs from the detection of a buffer underflow and a +buffer overflow. +.Bd -literal -offset indent +REDZONE: Buffer underflow detected. 2 bytes corrupted before 0xc8688580 (16 bytes allocated). +Allocation backtrace: +#0 0xc0583e4e at redzone_setup+0x3c +#1 0xc04a23fa at malloc+0x19e +#2 0xcdeb69ca at redzone_modevent+0x60 +#3 0xc04a3f3c at module_register_init+0x82 +#4 0xc049d96a at linker_file_sysinit+0x8e +#5 0xc049dc7c at linker_load_file+0xed +#6 0xc04a041f at linker_load_module+0xc4 +#7 0xc049e883 at kldload+0x116 +#8 0xc05d9b3d at syscall+0x325 +#9 0xc05c944f at Xint0x80_syscall+0x1f +Free backtrace: +#0 0xc0583f92 at redzone_check+0xd4 +#1 0xc04a2422 at free+0x1c +#2 0xcdeb69a6 at redzone_modevent+0x3c +#3 0xc04a438d at module_unload+0x61 +#4 0xc049e0b3 at linker_file_unload+0x89 +#5 0xc049e979 at kern_kldunload+0x96 +#6 0xc049ea00 at kldunloadf+0x2c +#7 0xc05d9b3d at syscall+0x325 +#8 0xc05c944f at Xint0x80_syscall+0x1f + +REDZONE: Buffer overflow detected. 4 bytes corrupted after 0xc8688590 (16 bytes allocated). +Allocation backtrace: +#0 0xc0583e4e at redzone_setup+0x3c +#1 0xc04a23fa at malloc+0x19e +#2 0xcdeb69ca at redzone_modevent+0x60 +#3 0xc04a3f3c at module_register_init+0x82 +#4 0xc049d96a at linker_file_sysinit+0x8e +#5 0xc049dc7c at linker_load_file+0xed +#6 0xc04a041f at linker_load_module+0xc4 +#7 0xc049e883 at kldload+0x116 +#8 0xc05d9b3d at syscall+0x325 +#9 0xc05c944f at Xint0x80_syscall+0x1f +Free backtrace: +#0 0xc0584020 at redzone_check+0x162 +#1 0xc04a2422 at free+0x1c +#2 0xcdeb69a6 at redzone_modevent+0x3c +#3 0xc04a438d at module_unload+0x61 +#4 0xc049e0b3 at linker_file_unload+0x89 +#5 0xc049e979 at kern_kldunload+0x96 +#6 0xc049ea00 at kldunloadf+0x2c +#7 0xc05d9b3d at syscall+0x325 +#8 0xc05c944f at Xint0x80_syscall+0x1f +.Ed +.Sh SEE ALSO +.Xr sysctl 8 , +.Xr malloc 9 , +.Xr memguard 9 +.Sh HISTORY +.Nm +first appeared in +.Fx 7.0 . +.Sh AUTHORS +.An Pawel Jakub Dawidek Aq pjd at FreeBSD.org +.Sh BUGS +Currently, +.Nm +does not cooperate with +.Xr memguard 9 . +Allocations from a memory type controlled by +.Xr memguard 9 +are simply skipped, so buffer corruptions will not be detected there. --- /dev/null +++ share/man/man9/cr_cansee.9 @@ -0,0 +1,92 @@ +.\" +.\" Copyright (c) 2006 Ceri Davies +.\" +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/cr_cansee.9,v 1.1 2006/11/19 13:35:03 ceri Exp $ +.\" +.Dd November 19, 2006 +.Os +.Dt CR_CANSEE 9 +.Sh NAME +.Nm cr_cansee +.Nd "determine visibility of objects given their user credentials" +.Sh SYNOPSIS +.In sys/param.h +.In sys/systm.h +.In sys/ucred.h +.Ft int +.Fn cr_cansee "struct ucred *u1" "struct ucred *u2" +.Sh DESCRIPTION +This function determines the visibility of objects in the +kernel based on the real user IDs and group IDs in the credentials +.Fa u1 +and +.Fa u2 +associated with them. +.Pp +The visibility of objects is influenced by the +.Xr sysctl 8 +variables +.Va security.bsd.see_other_gids +and +.Va security.bsd.see_other_uids , +as per the description in +.Xr cr_seeothergids 9 +and +.Xr cr_seeotheruids 9 +respectively. +.Sh RETURN VALUES +This function returns zero if the object with credential +.Fa u1 +can +.Dq see +the object with credential +.Fa u2 , +or +.Er ESRCH +otherwise. +.Sh ERRORS +.Bl -tag -width Er +.It Bq Er ESRCH +The object with credential +.Fa u1 +cannot +.Dq see +the object with credential +.Fa u2 . +.It Bq Er ESRCH +The object with credential +.Fa u1 +has been jailed and the object with credential +.Fa u2 +does not belong to the same jail as +.Fa u1 . +.It Bq Er ESRCH +The MAC subsystem denied visibility. +.El +.Sh SEE ALSO +.Xr cr_seeothergids 9 , +.Xr cr_seeotheruids 9 , +.Xr mac 9 , +.Xr p_cansee 9 Index: DECLARE_GEOM_CLASS.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/DECLARE_GEOM_CLASS.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/DECLARE_GEOM_CLASS.9 -L share/man/man9/DECLARE_GEOM_CLASS.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/DECLARE_GEOM_CLASS.9 +++ share/man/man9/DECLARE_GEOM_CLASS.9 @@ -22,9 +22,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/DECLARE_GEOM_CLASS.9,v 1.4 2005/01/13 09:33:06 ru Exp $ +.\" $FreeBSD: src/share/man/man9/DECLARE_GEOM_CLASS.9,v 1.5 2007/09/20 10:52:08 gabor Exp $ .\" -.Dd January 6, 2005 +.Dd August 13, 2007 .Dt DECLARE_GEOM_CLASS 9 .Os .Sh NAME @@ -110,7 +110,7 @@ .Sh EXAMPLES Example class declaration. .Bd -literal -offset indent -static struct geom * +static struct g_geom * g_example_taste(struct g_class *mp, struct g_provider *pp, int flags __unused) { Index: VOP_REMOVE.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_REMOVE.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_REMOVE.9 -L share/man/man9/VOP_REMOVE.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_REMOVE.9 +++ share/man/man9/VOP_REMOVE.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_REMOVE.9,v 1.14 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_REMOVE.9,v 1.15 2006/11/04 23:58:15 pjd Exp $ .\" .Dd July 24, 1996 .Os @@ -80,16 +80,6 @@ */ ...; - /* - * Careful about trying to remove ".". XXX this should be handled - * higher up. - */ - if (dvp == vp) - vrele(vp); - else - vput(vp); - vput(dvp); - return error; } .Ed Index: vm_map_stack.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_map_stack.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vm_map_stack.9 -L share/man/man9/vm_map_stack.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vm_map_stack.9 +++ share/man/man9/vm_map_stack.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_map_stack.9,v 1.4 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/vm_map_stack.9,v 1.5 2006/12/14 14:33:13 mpp Exp $ .\" .Dd July 19, 2003 .Dt VM_MAP_STACK 9 @@ -100,7 +100,7 @@ or if there is already a mapping at the address which would result, or if .Fa max_ssize -could not be accomodated within the current mapping, +could not be accommodated within the current mapping, .Dv KERN_NO_SPACE is returned. .Pp Index: condvar.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/condvar.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/condvar.9 -L share/man/man9/condvar.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/condvar.9 +++ share/man/man9/condvar.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/condvar.9,v 1.11 2004/11/08 18:15:11 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/condvar.9,v 1.21 2007/06/05 20:53:18 imp Exp $ .\" -.Dd December 11, 2000 +.Dd June 5, 2007 .Dt CONDVAR 9 .Os .Sh NAME @@ -35,6 +35,7 @@ .Nm cv_destroy , .Nm cv_wait , .Nm cv_wait_sig , +.Nm cv_wait_unlock , .Nm cv_timedwait , .Nm cv_timedwait_sig , .Nm cv_signal , @@ -51,13 +52,15 @@ .Ft void .Fn cv_destroy "struct cv *cvp" .Ft void -.Fn cv_wait "struct cv *cvp" "struct mtx *mp" +.Fn cv_wait "struct cv *cvp" "lock" .Ft int -.Fn cv_wait_sig "struct cv *cvp" "struct mtx *mp" +.Fn cv_wait_sig "struct cv *cvp" "lock" +.Ft void +.Fn cv_wait_unlock "struct cv *cvp" "lock" .Ft int -.Fn cv_timedwait "struct cv *cvp" "struct mtx *mp" "int timo" +.Fn cv_timedwait "struct cv *cvp" "lock" "int timo" .Ft int -.Fn cv_timedwait_sig "struct cv *cvp" "struct mtx *mp" "int timo" +.Fn cv_timedwait_sig "struct cv *cvp" "lock" "int timo" .Ft void .Fn cv_signal "struct cv *cvp" .Ft void @@ -84,6 +87,7 @@ Threads wait on condition variables by calling .Fn cv_wait , .Fn cv_wait_sig , +.Fn cv_wait_unlock , .Fn cv_timedwait , or .Fn cv_timedwait_sig . @@ -105,26 +109,45 @@ as set by the initial call to .Fn cv_init . .Pp +The +.Fa lock +argument is a pointer to either a +.Xr mutex 9 , +.Xr rwlock 9 , +or +.Xr sx 9 +lock. +A +.Xr mutex 9 +argument must be initialized with +.Dv MTX_DEF +and not +.Dv MTX_SPIN . A thread must hold -.Fa mp +.Fa lock before calling .Fn cv_wait , .Fn cv_wait_sig , +.Fn cv_wait_unlock , .Fn cv_timedwait , or .Fn cv_timedwait_sig . When a thread waits on a condition, -.Fa mp -is atomically released before the thread is blocked, then atomically reacquired +.Fa lock +is atomically released before the thread is blocked, then reacquired before the function call returns. +The +.Fn cv_wait_unlock +function does not reacquire the lock before returning. All waiters must pass the same -.Fa mp +.Fa lock in conjunction with .Fa cvp . .Pp When .Fn cv_wait , .Fn cv_wait_sig , +.Fn cv_wait_unlock , .Fn cv_timedwait , and .Fn cv_timedwait_sig @@ -169,9 +192,9 @@ will fail if: .Bl -tag -width Er .It Bq Er EINTR -An unmasked signal was caught. +A signal was caught and the system call should be interrupted. .It Bq Er ERESTART -A masked signal was caught. +A signal was caught and the system call should be restarted. .El .Pp .Fn cv_timedwait @@ -183,8 +206,10 @@ Timeout expired. .El .Sh SEE ALSO -.Xr msleep 9 , +.Xr locking 9 , .Xr mtx_pool 9 , .Xr mutex 9 , +.Xr rwlock 9 , .Xr sema 9 , +.Xr sleep 9 , .Xr sx 9 Index: p_candebug.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/p_candebug.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/p_candebug.9 -L share/man/man9/p_candebug.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/p_candebug.9 +++ share/man/man9/p_candebug.9 @@ -25,15 +25,16 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/p_candebug.9,v 1.3 2004/07/06 07:26:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/p_candebug.9,v 1.5 2006/11/19 13:36:04 ceri Exp $ .\" -.Dd November 11, 2003 +.Dd November 19, 2006 .Os .Dt P_CANDEBUG 9 .Sh NAME .Nm p_candebug .Nd determine debuggability of a process .Sh SYNOPSIS +.In sys/param.h .In sys/proc.h .Ft int .Fn p_candebug "struct thread *td" "struct proc *p" @@ -128,10 +129,10 @@ The MAC subsystem denied debuggability. .El .Sh SEE ALSO -.Xr intro 2 , .Xr jail 2 , .Xr sysctl 8 , .Xr cr_seeothergids 9 , .Xr cr_seeotheruids 9 , .Xr mac 9 , +.Xr p_cansee 9 , .Xr prison_check 9 Index: vslock.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vslock.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vslock.9 -L share/man/man9/vslock.9 -u -r1.2 -r1.3 --- share/man/man9/vslock.9 +++ share/man/man9/vslock.9 @@ -35,7 +35,6 @@ .\" POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vslock.9,v 1.15 2004/08/16 03:12:10 green Exp $ -.\" $MidnightBSD$ .\" .Dd August 10, 2004 .Dt VSLOCK 9 Index: style.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/style.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/style.9 -L share/man/man9/style.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/style.9 +++ share/man/man9/style.9 @@ -24,7 +24,7 @@ .\" SUCH DAMAGE. .\" .\" From: @(#)style 1.14 (Berkeley) 4/28/95 -.\" $FreeBSD: src/share/man/man9/style.9,v 1.121 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/style.9,v 1.123 2007/01/28 20:51:04 joel Exp $ .\" .Dd February 10, 2005 .Dt STYLE 9 @@ -46,7 +46,7 @@ * Style guide for FreeBSD. Based on the CSRG's KNF (Kernel Normal Form). * * @(#)style 1.14 (Berkeley) 4/28/95 - * $FreeBSD: src/share/man/man9/style.9,v 1.121 2005/06/28 20:15:18 hmp Exp $ + * $FreeBSD: src/share/man/man9/style.9,v 1.123 2007/01/28 20:51:04 joel Exp $ */ /* @@ -65,7 +65,8 @@ line of the comment having a dash after the star like so: .Bd -literal /*- - * Copyright (c) 1984-2025 John Q. Public. All Rights Reserved. + * Copyright (c) 1984-2025 John Q. Public + * All rights reserved. * * Long, boring license goes here, but redacted for brevity */ @@ -110,7 +111,7 @@ #endif #include -__FBSDID("$FreeBSD: src/share/man/man9/style.9,v 1.121 2005/06/28 20:15:18 hmp Exp $"); +__FBSDID("$FreeBSD: src/share/man/man9/style.9,v 1.123 2007/01/28 20:51:04 joel Exp $"); .Ed .Pp Leave another blank line before the header files. @@ -473,7 +474,7 @@ while ((ch = getopt(argc, argv, "abNn:")) != -1) switch (ch) { /* Indent the switch. */ case 'a': /* Don't indent the case. */ - aflag = 1; + aflag = 1; /* Indent case body one tab. */ /* FALLTHROUGH */ case 'b': bflag = 1; Index: vm_page_insert.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_insert.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_insert.9 -L share/man/man9/vm_page_insert.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_insert.9 +++ share/man/man9/vm_page_insert.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_insert.9,v 1.3 2001/08/08 10:04:08 ru Exp $ -.\" $MidnightBSD$ .\" .Dd July 17, 2001 .Dt VM_PAGE_INSERT 9 Index: VFS_LOCK_GIANT.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_LOCK_GIANT.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_LOCK_GIANT.9 -L share/man/man9/VFS_LOCK_GIANT.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_LOCK_GIANT.9 +++ share/man/man9/VFS_LOCK_GIANT.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_LOCK_GIANT.9,v 1.1.2.1 2005/09/25 18:51:45 rwatson Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_LOCK_GIANT.9,v 1.5 2006/01/03 14:00:22 rwatson Exp $ .\" .Dd September 21, 2005 .Dt VFS_LOCK_GIANT 9 @@ -33,9 +33,10 @@ .Sh NAME .Nm VFS_LOCK_GIANT , .Nm VFS_UNLOCK_GIANT -.Nd "Conditionally lock and unlock Giant around entry into VFS" +.Nd "conditionally lock and unlock Giant around entry into VFS" .Sh SYNOPSIS .In sys/param.h +.In sys/mount.h .In sys/vnode.h .Ft int .Fn VFS_LOCK_GIANT "struct mount *mp" @@ -44,16 +45,18 @@ .Sh DESCRIPTION .Fn VFS_LOCK_GIANT will conditionally acquire the -.Dv Giant +.Va Giant lock if the file system referenced by .Fa mp -is marked as MPSAFE or not, returning a flag indicating whether Giant was +is marked as MPSAFE or not, returning a flag indicating whether +.Va Giant +was set, which may later be passed to .Fn VFS_UNLOCK_GIANT . The value of .Fa mp will typically be derived from the mount pointer in a -.Xr vnode +.Vt vnode on which a VFS operation will be performed. .Pp .Fn VFS_UNLOCK_GIANT @@ -63,7 +66,7 @@ .Fa vfslocked argument is non-zero. It is expected that the argument will be derived from the return values of -.Vn VFS_LOCK_GIANT +.Fn VFS_LOCK_GIANT or .Xr NDHASGIANT 9 . .Sh RETURN VALUES @@ -76,6 +79,7 @@ .Xr NDHASGIANT 9 , .Xr vnode 9 .Sh AUTHORS +.An -nosplit MPSAFE VFS support for .Fx was implemented by @@ -84,7 +88,6 @@ This manual page was written by .An Robert Watson . .Sh BUGS -.Pp Non-MPSAFE file systems exist, requiring callers conditional locking and unlocking of .Va Giant . --- /dev/null +++ share/man/man9/kqueue.9 @@ -0,0 +1,375 @@ +.\" Copyright 2006 John-Mark Gurney +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/kqueue.9,v 1.6 2006/12/29 22:30:10 jmg Exp $ +.\" +.Dd December 28, 2006 +.Dt KQUEUE 9 +.Os +.Sh NAME +.Nm kqueue_add_filteropts , kqueue_del_filteropts , +.Nm kqfd_register , +.Nm knote_fdclose , +.Nm knlist_add , knlist_remove , knlist_remove_inevent , knlist_empty , +.Nm knlist_init , knlist_destroy , knlist_clear , knlist_delete , +.Nm KNOTE_LOCKED , KNOTE_UNLOCKED +.Nd "event delivery subsystem" +.Sh SYNOPSIS +.In sys/event.h +.Ft int +.Fn kqueue_add_filteropts "int filt" "struct filterops *filtops" +.Ft int +.Fn kqueue_del_filteropts "int filt" +.Ft int +.Fn kqfd_register "int fd" "struct kevent *kev" "struct thread *td" "int waitok" +.Ft void +.Fn knote_fdclose "struct thread *td" "int fd" +.Ft void +.Fn knlist_add "struct knlist *knl" "struct knote *kn" "int islocked" +.Ft void +.Fn knlist_remove "struct knlist *knl" "struct knote *kn" "int islocked" +.Ft void +.Fn knlist_remove_inevent "struct knlist *knl" "struct knote *kn" +.Ft int +.Fn knlist_empty "struct knlist *knl" +.Ft void +.Fo knlist_init +.Fa "struct knlist *knl" +.Fa "void *lock" +.Fa "void \*[lp]*kl_lock\*[rp]\*[lp]void *\*[rp]" +.Fa "void \*[lp]*kl_unlock\*[rp]\*[lp]void *\*[rp]" +.Fa "int \*[lp]*kl_locked\*[rp]\*[lp]void *\*[rp]" +.Fc +.Ft void +.Fn knlist_destroy "struct knlist *knl" +.Ft void +.Fn knlist_clear "struct knlist *knl" "int islocked" +.Ft void +.Fn knlist_delete "struct knlist *knl" "struct thread *td" "int islocked" +.Ft void +.Fn KNOTE_LOCKED "struct knlist *knl" "long hint" +.Ft void +.Fn KNOTE_UNLOCKED "struct knlist *knl" "long hint" +.Sh DESCRIPTION +The functions +.Fn kqueue_add_filteropts +and +.Fn kqueue_del_filteropts +allow for the addition and removal of a filter type. +The filter is statically defined by the +.Dv EVFILT_* +macros. +The function +.Fn kqueue_add_filteropts +will make +.Fa filt +available. +The +.Vt "struct filterops" +has the following members: +.Bl -tag -width ".Va f_attach" +.It Va f_isfd +If +.Va f_isfd +is set, +.Va ident +in +.Vt "struct kevent" +is taken to be a file descriptor. +In this case, the +.Vt knote +passed into +.Va f_attach +will have the +.Va kn_fp +member initialized to the +.Vt "struct file *" +that represents the file descriptor. +.It Va f_attach +The +.Va f_attach +function will be called when attaching a +.Vt knote +to the object. +The method should call +.Fn knlist_add +to add the +.Vt knote +to the list that was initialized with +.Fn knlist_init . +The call to +.Fn knlist_add +is only necessary if the object can have multiple +.Vt knotes +associated with it. +If there is no +.Vt knlist +to call +.Fn knlist_add +with, the function +.Va f_attach +must clear the +.Dv KN_DETACHED +bit of +.Va kn_status +in the +.Vt knote . +The function shall return 0 on success, or appropriate error for the failure. +During +.Va f_attach , +it is valid to change the +.Va kn_fops +pointer to a different pointer. +This will change the +.Va f_event +and +.Va f_detach +functions called when processing the +.Vt knote . +.It Va f_detach +The +.Va f_detach +function will be called to detach the +.Vt knote +if the +.Vt knote +has not already been detached by a call to +.Fn knlist_remove . +.It Va f_event +The +.Va f_event +function will be called to update the status of the +.Vt knote . +If the function returns 0, it will be assumed that the object is not +ready (or no longer ready) to be woken up. +The +.Fa hint +argument will be 0 when scanning +.Vt knotes +to see which are triggered. +Otherwise, the +.Fa hint +argument will be the value passed to either +.Dv KNOTE_LOCKED +or +.Dv KNOTE_UNLOCKED . +The +.Va kn_data +value should be updated as necessary to reflect the current value, such as +number of bytes available for reading, or buffer space available for writing. +If the note needs to be removed, +.Fn knlist_remove_inevent +must be called. +The function +.Fn knlist_remove_inevent +will remove the note from the list, the +.Va f_detach +function will not be called and the +.Vt knote +will not be returned as an event. +.Pp +Locks +.Em must not +be acquired in +.Va f_event . +If a lock is required in +.Va f_event , +it must be obtained in the +.Fa kl_lock +function of the +.Vt knlist +that the +.Va knote +was added to. +.El +.Pp +The function +.Fn kqfd_register +will register the +.Vt kevent +on the kqueue file descriptor +.Fa fd . +If it is safe to sleep, +.Fa waitok +should be set. +.Pp +The function +.Fn knote_fdclose +is used to delete all +.Vt knotes +associated with +.Fa fd . +Once returned, there will no longer be any +.Vt knotes +associated with the +.Fa fd . +The +.Vt knotes +removed will never be returned from a +.Xr kevent 2 +call, so if userland uses the +.Vt knote +to track resources, they will be leaked. +The +.Fn FILEDESC_LOCK +lock must be held over the call to +.Fn knote_fdclose +so that file descriptors cannot be added or removed. +.Pp +The +.Fn knlist_* +family of functions are for managing +.Vt knotes +associated with an object. +A +.Vt knlist +is not required, but is commonly used. +If used, the +.Vt knlist +must be initialized with the +.Fn knlist_init +function. +If +.Fa lock +is +.Dv NULL , +an internal lock will be used and the remaining arguments will be ignored. +The +.Fa kl_lock , kl_unlock +and +.Fa kl_locked +functions will be used to manipulate a +.Fa lock . +If the argument is +.Dv NULL , +default routines operating on +.Vt "struct mtx *" +will be used. +The +.Vt knlist +structure may be embedded into the object structure. +The +.Fa lock +will be held over calls to +.Va f_event . +If +.Dv NULL +is passed for the mutex, a private mutex will be used. +The function +.Fn knlist_empty +requires that a +.Fa lock +be held. +The function +.Fn knlist_clear +is used to remove all +.Vt knotes +associated with the list. +The +.Fa islocked +argument declares if +.Fa lock +has been acquired. +All +.Vt knotes +will be marked as detached, and +.Dv EV_ONESHOT +will be set so that the +.Vt knote +will be deleted after the next scan. +The +.Fn knlist_destroy +function is used to destroy a +.Vt knlist . +There must be no +.Vt knotes +associated with the +.Vt knlist +.Fn ( knlist_empty +returns true) +and no more +.Vt knotes +may be attached to the object. +A +.Vt knlist +may be emptied by calling +.Fn knlist_clear . +.Pp +The macros +.Fn KNOTE_LOCKED +and +.Fn KNOTE_UNLOCKED +are used to notify +.Vt knotes +about events associated with the object. +It will iterate over all +.Vt knotes +on the list calling the +.Va f_event +function associated with the +.Vt knote . +The macro +.Fn KNOTE_LOCKED +must be used if the lock associated with the +.Fa knl +passed in is held. +The function +.Fn KNOTE_UNLOCKED +will acquire the lock before iterating over the list of +.Vt knotes . +.Sh RETURN VALUES +The function +.Fn kqueue_add_filteropts +will return zero on success, +.Er EINVAL +in the case of an invalid +.Fa filt , +or +.Er EEXIST +if the filter has already been installed. +.Pp +The function +.Fn kqueue_del_filteropts +will return zero on success, +.Er EINVAL +in the case of an invalid +.Fa filt , +or +.Er EBUSY +if the filter is still in use. +.Pp +The function +.Fn kqfd_register +will return zero on success, +.Er EBADF +if the file descriptor is not a kqueue, or any of the possible values returned +by +.Xr kevent 2 . +.Sh SEE ALSO +.Xr kevent 2 , +.Xr kqueue 2 +.Sh AUTHORS +This +manual page was written by +.An John-Mark Gurney Aq jmg at FreeBSD.org . Index: zero_copy.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/zero_copy.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/zero_copy.9 -L share/man/man9/zero_copy.9 -u -r1.2 -r1.3 --- share/man/man9/zero_copy.9 +++ share/man/man9/zero_copy.9 @@ -23,8 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/zero_copy.9,v 1.7 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/zero_copy.9,v 1.8 2006/05/15 20:58:05 wilko Exp $ .\" .Dd December 5, 2004 .Dt ZERO_COPY 9 @@ -91,8 +90,7 @@ For receiving data, in order to take advantage of the zero copy receive code, the user must have a NIC that is configured for an MTU greater than the architecture page size. -(E.g., for alpha this would be 8KB, for i386, -it would be 4KB.) +(E.g., for i386 it would be 4KB.) Additionally, in order for zero copy receive to work, packet payloads must be at least a page in size and page aligned. .Pp Index: VOP_RENAME.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_RENAME.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_RENAME.9 -L share/man/man9/VOP_RENAME.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_RENAME.9 +++ share/man/man9/VOP_RENAME.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_RENAME.9,v 1.21 2005/01/28 10:43:05 ru Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_RENAME.9,v 1.22 2006/11/04 23:59:51 pjd Exp $ .\" .Dd July 24, 1996 .Os @@ -104,34 +104,13 @@ } /* - * Check if just deleting a link name. + * POSIX: "If the old argument and the new argument + * both refer to links to the same existing file, + * the rename() function shall return successfully + * and perform no other action." + * The upper layers already handle this case. */ - if (fvp == tvp) { - if (fvp->v_type == VDIR) { - error = EINVAL; - goto abortit; - } - - /* - * Release destination. - */ - vput(tdvp); - vput(tvp); - - /* - * Delete source. Pretty bizarre stuff. - */ - vrele(fdvp); - vrele(fvp); - fcnp->cn_flags &= ~MODMASK; - fcnp->cn_flags |= LOCKPARENT | LOCKLEAF; - fcnp->cn_nameiop = DELETE; - VREF(fdvp); - error = relookup(fdvp, &fvp, fcnp); - if (error == 0) - vrele(fdvp); - return VOP_REMOVE(fdvp, fvp, fcnp); - } + KASSERT(fvp != tvp, ("vop_rename: source and destination are the same")); if (fvp is immutable) { error = EPERM; Index: uio.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/uio.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/uio.9 -L share/man/man9/uio.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/uio.9 +++ share/man/man9/uio.9 @@ -23,9 +23,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/uio.9,v 1.19 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/uio.9,v 1.21 2006/11/29 20:24:56 alfred Exp $ .\" -.Dd February 2, 1997 +.Dd December 8, 2006 .Os .Dt UIO 9 .Sh NAME @@ -38,13 +38,13 @@ .Pp .Bd -literal struct uio { - struct iovec *uio_iov; - int uio_iovcnt; - off_t uio_offset; - int uio_resid; - enum uio_seg uio_segflg; - enum uio_rw uio_rw; - struct thread *uio_td; + struct iovec *uio_iov; /* scatter/gather list */ + int uio_iovcnt; /* length of scatter/gather list */ + off_t uio_offset; /* offset in target object */ + int uio_resid; /* remaining bytes to copy */ + enum uio_seg uio_segflg; /* address space */ + enum uio_rw uio_rw; /* operation */ + struct thread *uio_td; /* owner */ }; .Ed .Ft int @@ -87,7 +87,7 @@ .It Va uio_offset The offset into the device. .It Va uio_resid -The number of bytes to process. +The remaining number of bytes to process, updated after transfer. .It Va uio_segflg One of the following flags: .Bl -tag -width ".Dv UIO_USERSPACE" @@ -112,14 +112,20 @@ space. .El .Sh RETURN VALUES +On success .Fn uiomove -can return -.Er EFAULT -from the invoked +will return 0, on error it will return an appropriate errno. +.Sh ERRORS +.Fn uiomove +will fail and return the following error code if: +.Bl -tag -width Er +.It Bq Er EFAULT +The invoked .Xr copyin 9 or .Xr copyout 9 -in case the transfer was to/from a process's address space. +returned +.Er EFAULT .Sh EXAMPLES The idea is that the driver maintains a private buffer for its data, and processes the request in chunks of maximal the size of this Index: vn_isdisk.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vn_isdisk.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vn_isdisk.9 -L share/man/man9/vn_isdisk.9 -u -r1.2 -r1.3 --- share/man/man9/vn_isdisk.9 +++ share/man/man9/vn_isdisk.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vn_isdisk.9,v 1.6 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 9, 2001 .Dt VN_ISDISK 9 --- /dev/null +++ share/man/man9/LOCK_PROFILING.9 @@ -0,0 +1,203 @@ +.\"- +.\" Copyright (c) 2004 Dag-Erling Co?dan Sm?rgrav +.\" Copyright (c) 2005 Robert N. M. Watson +.\" Copyright (c) 2006 Kip Macy +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" 3. The name of the author may not be used to endorse or promote products +.\" derived from this software without specific prior written permission. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/LOCK_PROFILING.9,v 1.2 2006/12/01 17:46:25 ru Exp $ +.\" +.Dd November 11, 2006 +.Dt LOCK_PROFILING 9 +.Os +.Sh NAME +.Nm LOCK_PROFILING +.Nd kernel lock profiling support +.Sh SYNOPSIS +.Cd "options LOCK_PROFILING" +.Sh DESCRIPTION +The +.Dv LOCK_PROFILING +kernel option adds support for measuring and reporting lock use and +contention statistics. +These statistics are collated by +.Dq acquisition point . +Acquisition points are +distinct places in the kernel source code (identified by source file +name and line number) where a lock is acquired. +.Pp +For each acquisition point, the following statistics are accumulated: +.Bl -bullet +.It +The longest time the lock was ever continuously held after being +acquired at this point. +.It +The total time the lock was held after being acquired at this point. +.It +The total time that threads have spent waiting to acquire the lock. +.It +The total number of non-recursive acquisitions. +.It +The total number of times the lock was already held by another thread +when this point was reached, requiring a spin or a sleep. +.It +The total number of times another thread tried to acquire the lock +while it was held after having been acquired at this point. +.El +.Pp +In addition, the average hold time and average wait time are derived +from the total hold time +and total wait time respectively and the number of acquisitions. +.Pp +The +.Dv LOCK_PROFILING +kernel option also adds the following +.Xr sysctl 8 +variables to control and monitor the profiling code: +.Bl -tag -width indent +.It Va debug.lock.prof.enable +Enable or disable the lock profiling code. +This defaults to 0 (off). +.It Va debug.lock.prof.reset +Reset the current lock profiling buffers. +.It Va debug.lock.prof.acquisitions +The total number of lock acquisitions recorded. +.It Va debug.lock.prof.records +The total number of acquisition points recorded. +Note that only active acquisition points (i.e., points that have been +reached at least once) are counted. +.It Va debug.lock.prof.maxrecords +The maximum number of acquisition points the profiling code is capable +of monitoring. +Since it would not be possible to call +.Xr malloc 9 +from within the lock profiling code, this is a static limit. +The number of records can be changed with the +.Dv LPROF_BUFFERS +kernel option. +.It Va debug.lock.prof.rejected +The number of acquisition points that were ignored after the table +filled up. +.It Va debug.lock.prof.hashsize +The size of the hash table used to map acquisition points to +statistics records. +The hash size can be changed with the +.Dv LPROF_HASH_SIZE +kernel option. +.It Va debug.lock.prof.collisions +The number of hash collisions in the acquisition point hash table. +.It Va debug.lock.prof.stats +The actual profiling statistics in plain text. +The columns are as follows, from left to right: +.Bl -tag -width ".Va cnt_hold" +.It Va max +The longest continuous hold time in microseconds. +.It Va total +The total (accumulated) hold time in microseconds. +.It Va wait_total +The total (accumulated) wait time in microseconds. +.It Va count +The total number of acquisitions. +.It Va avg +The average hold time in microseconds, derived from the total hold time +and the number of acquisitions. +.It Va wait_avg +The average wait time in microseconds, derived from the total wait time +and the number of acquisitions. +.It Va cnt_hold +The number of times the lock was held and another thread attempted to +acquire the lock. +.It Va cnt_lock +The number of times the lock was already held when this point was +reached. +.It Va name +The name of the acquisition point, derived from the source file name +and line number, followed by the name of the lock in parentheses. +.El +.El +.Sh SEE ALSO +.Xr sysctl 8 , +.Xr mutex 9 +.Sh HISTORY +Mutex profiling support appeared in +.Fx 5.0 . +Generalized lock profiling support appeared in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm MUTEX_PROFILING +code was written by +.An Eivind Eklund Aq eivind at FreeBSD.org , +.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org +and +.An Robert Watson Aq rwatson at FreeBSD.org . +The +.Nm +code was written by +.An Kip Macy Aq kmacy at FreeBSD.org . +This manual page was written by +.An Dag-Erling Sm\(/orgrav Aq des at FreeBSD.org . +.Sh NOTES +The +.Dv LOCK_PROFILING +option increases the size of +.Vt "struct lock_object" , +so a kernel built with that option will not work with modules built +without it. +.Pp +The +.Dv LOCK_PROFILING +option also prevents inlining of the mutex code, which can result in a +fairly severe performance penalty. +This is, however, not always the case. +.Dv LOCK_PROFILING +can introduce a substantial performance overhead that is easily +monitorable using other profiling tools, so combining profiling tools +with +.Dv LOCK_PROFILING +is not recommended. +.Pp +Measurements are made and stored in nanoseconds using +.Xr nanotime 9 , +(on architectures without a synchronized TSC) but are presented in microseconds. +This should still be sufficient for the locks one would be most +interested in profiling (those that are held long and/or acquired +often). +.Pp +.Dv LOCK_PROFILING +should generally not be used in combination with other debugging options, as +the results may be strongly affected by interactions between the features. +In particular, +.Dv LOCK_PROFILING +will report higher than normal +.Xr uma 9 +lock contention when run with +.Dv INVARIANTS +due to extra locking that occurs when +.Dv INVARIANTS +is present; likewise, using it in combination with +.Dv WITNESS +will lead to much higher lock hold times and contention in profiling output. --- /dev/null +++ share/man/man9/device_get_sysctl.9 @@ -0,0 +1,58 @@ +.\" -*- nroff -*- +.\" +.\" Copyright (c) 2006 M. Warner Losh +.\" +.\" All rights reserved. +.\" +.\" This program is free software. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE DEVELOPERS ``AS IS'' AND ANY EXPRESS OR +.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES +.\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. +.\" IN NO EVENT SHALL THE DEVELOPERS BE LIABLE FOR ANY DIRECT, INDIRECT, +.\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT +.\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, +.\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY +.\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT +.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF +.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/device_get_sysctl.9,v 1.2 2006/09/30 17:09:59 ru Exp $ +.\" +.Dd May 23, 2006 +.Dt DEVICE_GET_SYSCTL 9 +.Os +.Sh NAME +.Nm device_get_sysctl_ctx , +.Nm device_get_sysctl_tree +.Nd manipulate the sysctl oid tree for driver specific sysctl nodes +.Sh SYNOPSIS +.In sys/param.h +.In sys/bus.h +.Ft "struct sysctl_ctx_list *" +.Fn device_get_sysctl_ctx "device_t dev" +.Ft "struct sysctl_oid *" +.Fn device_get_sysctl_tree "device_t dev" +.Sh DESCRIPTION +The newbus system automatically adds a sysctl node for each device +in the system. +This node can be accessed with the +.Fn device_get_sysctl_tree +function. +The context for the node can be obtained with the +.Fn device_get_sysctl_ctl +function. +.Sh SEE ALSO +.Xr device 9 +.Sh AUTHORS +This manual page was written by +.An Warner Losh . Index: ifnet.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ifnet.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/ifnet.9 -L share/man/man9/ifnet.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/ifnet.9 +++ share/man/man9/ifnet.9 @@ -26,9 +26,9 @@ .\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ifnet.9,v 1.50.2.1 2005/08/18 15:01:24 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/ifnet.9,v 1.53 2007/03/14 13:19:50 bms Exp $ .\" -.Dd June 10, 2005 +.Dd March 14, 2007 .Os .Dt IFNET 9 .Sh NAME @@ -103,19 +103,9 @@ .Ft void .Fn \*(lp*if_start\*(rp "struct ifnet *ifp" .Ft int -.Fn \*(lp*if_done\*(rp "struct ifnet *ifp" -.Ft int .Fn \*(lp*if_ioctl\*(rp "struct ifnet *ifp" "int cmd" "caddr_t data" .Ft void .Fn \*(lp*if_watchdog\*(rp "struct ifnet *ifp" -.Ft int -.Fn \*(lp*if_poll_recv\*(rp "struct ifnet *ifp" "int *quotap" -.Ft int -.Fn \*(lp*if_poll_xmit\*(rp "struct ifnet *ifp" "int *quotap" -.Ft void -.Fn \*(lp*if_poll_inttrn\*(rp "struct ifnet *ifp" -.Ft void -.Fn \*(lp*if_poll_slowinput\*(rp "struct ifnet *ifp" "struct mbuf *m" .Ft void .Fn \*(lp*if_init\*(rp "void *if_softc" .Ft int @@ -1024,7 +1014,7 @@ .Va ifnet_addrs . ) The .Fa ifp -must have been allocted by +must have been allocated by .Fn if_alloc . .It Fn if_detach Shut down and unlink the specified Index: g_consumer.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/g_consumer.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/g_consumer.9 -L share/man/man9/g_consumer.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/g_consumer.9 +++ share/man/man9/g_consumer.9 @@ -22,7 +22,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/g_consumer.9,v 1.7 2004/07/06 08:21:12 ru Exp $ +.\" $FreeBSD: src/share/man/man9/g_consumer.9,v 1.8 2006/03/17 13:13:18 des Exp $ .\" .Dd January 16, 2004 .Dt G_CONSUMER 9 @@ -60,11 +60,9 @@ .It The geom .Fa gp -has to have -.Va start -and -.Va access -methods defined. +has to have an +.Va orphan +method defined. .It The topology lock has to be held. .El Index: VOP_LISTEXTATTR.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VOP_LISTEXTATTR.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VOP_LISTEXTATTR.9 -L share/man/man9/VOP_LISTEXTATTR.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VOP_LISTEXTATTR.9 +++ share/man/man9/VOP_LISTEXTATTR.9 @@ -28,7 +28,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VOP_LISTEXTATTR.9,v 1.6.2.1 2005/08/31 00:27:35 rodrigc Exp $ +.\" $FreeBSD: src/share/man/man9/VOP_LISTEXTATTR.9,v 1.7 2005/08/19 12:17:47 rodrigc Exp $ .\" .Dd August 19, 2005 .Os Index: EVENTHANDLER.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/EVENTHANDLER.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/EVENTHANDLER.9 -L share/man/man9/EVENTHANDLER.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/EVENTHANDLER.9 +++ share/man/man9/EVENTHANDLER.9 @@ -21,7 +21,7 @@ .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. -.\" $FreeBSD: src/share/man/man9/EVENTHANDLER.9,v 1.3 2005/01/07 19:41:00 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/EVENTHANDLER.9,v 1.4 2005/10/11 16:05:35 keramida Exp $ .\" .Dd January 7, 2005 .Dt EVENTHANDLER 9 @@ -139,7 +139,7 @@ A pointer to a callback function. Argument .Fa arg -is a passed to the callback function +is passed to the callback function .Fa func as its first argument when it is invoked. .It Fa priority Index: vflush.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vflush.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vflush.9 -L share/man/man9/vflush.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vflush.9 +++ share/man/man9/vflush.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vflush.9,v 1.5 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/vflush.9,v 1.6 2006/06/08 04:39:02 maxim Exp $ .\" .Dd November 21, 2001 .Dt VFLUSH 9 @@ -61,7 +61,7 @@ If set, busy vnodes will be forcibly closed. .It Dv SKIPSYSTEM If set, vnodes with the -.Dv VSYSTEM +.Dv VV_SYSTEM flag set will be skipped. .It Dv WRITECLOSE If set, only regular files currently opened for writing will be removed. Index: bus_dma.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bus_dma.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bus_dma.9 -L share/man/man9/bus_dma.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bus_dma.9 +++ share/man/man9/bus_dma.9 @@ -57,10 +57,10 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bus_dma.9,v 1.25.2.1 2005/12/08 01:41:54 scottl Exp $ +.\" $FreeBSD: src/share/man/man9/bus_dma.9,v 1.40 2007/03/06 17:32:49 jhb Exp $ .\" $NetBSD: bus_dma.9,v 1.25 2002/10/14 13:43:16 wiz Exp $ .\" -.Dd December 5, 2005 +.Dd March 6, 2007 .Dt BUS_DMA 9 .Os .Sh NAME @@ -133,7 +133,7 @@ DMA mappings, handling cache issues, bus specific features and limitations. .Sh STRUCTURES AND TYPES -.Bl -tag -width compact +.Bl -tag -width indent .It Vt bus_dma_tag_t A machine-dependent (MD) opaque type that describes the characteristics of DMA transactions. @@ -143,17 +143,17 @@ to contribute to the constraints of those transactions. .It Vt bus_dma_filter_t Client specified address filter having the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft int .Fn "client_filter" "void *filtarg" "bus_addr_t testaddr" .El -.sp +.Pp Address filters can be specified during tag creation to allow for devices whose DMA address restrictions cannot be specified by a single window. The .Fa filtarg -is client specified during tag creation to be passed to all +argument is specified by the client during tag creation to be passed to all invocations of the callback. The .Fa testaddr @@ -163,16 +163,17 @@ to .Ql trunc_page(testaddr) + PAGE_SIZE - 1 , inclusive. -The filter function should return zero for any mapping in this range -that can be accommodated by the device and non-zero otherwise. +The filter function should return zero if any mapping in this range +can be accommodated by the device and non-zero otherwise. .It Vt bus_dma_segment_t A machine-dependent type that describes individual DMA segments. +It contains the following fields: .Bd -literal bus_addr_t ds_addr; bus_size_t ds_len; .Ed -.sp +.Pp The .Fa ds_addr field contains the device visible address of the DMA segment, and @@ -187,9 +188,12 @@ One map is used for each memory allocation that will be loaded. Maps can be reused once they have been unloaded. Multiple maps can be associated with one DMA tag. -While the value of the map may evaluate to NULL on some platforms under -certain conditions, it should never be assumed that it will be NULL in all -cases. +While the value of the map may evaluate to +.Dv NULL +on some platforms under certain conditions, +it should never be assumed that it will be +.Dv NULL +in all cases. .It Vt bus_dmamap_callback_t Client specified callback for receiving mapping information resulting from the load of a @@ -197,12 +201,12 @@ via .Fn bus_dmamap_load . Callbacks are of the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft void .Fn "client_callback" "void *callback_arg" "bus_dma_segment_t *segs" \ "int nseg" "int error" .El -.sp +.Pp The .Fa callback_arg is the callback argument passed to dmamap load functions. @@ -210,13 +214,13 @@ .Fa segs and .Fa nseg -parameters describe an array of +arguments describe an array of .Vt bus_dma_segment_t structures that represent the mapping. This array is only valid within the scope of the callback function. The success or failure of the mapping is indicated by the .Fa error -parameter. +argument. More information on the use of callbacks can be found in the description of the individual dmamap load functions. .It Vt bus_dmamap_callback2_t @@ -227,14 +231,14 @@ .Fn bus_dmamap_load_uio or .Fn bus_dmamap_load_mbuf . -.sp +.Pp Callback2s are of the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft void .Fn "client_callback2" "void *callback_arg" "bus_dma_segment_t *segs" \ "int nseg" "bus_size_t mapsize" "int error" .El -.sp +.Pp Callback2's behavior is the same as .Vt bus_dmamap_callback_t with the addition that the length of the data mapped is provided via @@ -257,22 +261,22 @@ All operations specified below are performed from the host memory point of view, where a read implies data coming from the device to the host memory, and a write implies data going from the host memory to the device. -Alternately, the operations can be thought of in terms of driver operations, +Alternatively, the operations can be thought of in terms of driver operations, where reading a network packet or storage sector corresponds to a read operation in .Nm . -.Bl -tag -width BUS_DMASYNC_POSTWRITE +.Bl -tag -width ".Dv BUS_DMASYNC_POSTWRITE" .It Dv BUS_DMASYNC_PREREAD Perform any synchronization required prior to an update of host memory by the -DMA read operation. +device. .It Dv BUS_DMASYNC_PREWRITE Perform any synchronization required after an update of host memory by the CPU -and prior to DMA write operations. +and prior to device access to host memory. .It Dv BUS_DMASYNC_POSTREAD -Perform any synchronization required after DMA read operations and prior to -CPU access to host memory. +Perform any synchronization required after an update of host memory by the +device and prior to CPU access to host memory. .It Dv BUS_DMASYNC_POSTWRITE -Perform any synchronization required after DMA write operations. +Perform any synchronization required after device access to host memory. .El .It Vt bus_dma_lock_t Client specified lock/mutex manipulation method. @@ -287,48 +291,57 @@ will not be called since the function loading the map should be holding the appropriate locks. This method is of the format: -.Bl -tag -width compact +.Bl -tag -width indent .It Ft void .Fn "lockfunc" "void *lockfunc_arg" "bus_dma_lock_op_t op" .El -.sp +.Pp +The +.Fa lockfuncarg +argument is specified by the client during tag creation to be passed to all +invocations of the callback. +The +.Fa op +argument specifies the lock operation to perform. +.Pp Two .Vt lockfunc implementations are provided for convenience. .Fn busdma_lock_mutex -performs standard mutex operations on the sleep mutex provided via the +performs standard mutex operations on the sleep mutex provided via .Fa lockfuncarg . -passed into -.Fn bus_dma_tag_create . .Fn dflt_lock will generate a system panic if it is called. It is substituted into the tag when .Fa lockfunc -is passed as NULL to -.Fn bus_dma_tag_create . +is passed as +.Dv NULL +to +.Fn bus_dma_tag_create +and is useful for tags that should not be used with deferred load operations. .It Vt bus_dma_lock_op_t Operations to be performed by the client-specified .Fn lockfunc . -.Bl -tag -width BUS_DMA_UNLOCK +.Bl -tag -width ".Dv BUS_DMA_UNLOCK" .It Dv BUS_DMA_LOCK Acquires and/or locks the client locking primitive. .It Dv BUS_DMA_UNLOCK Releases and/or unlocks the client locking primitive. .El .El -.sp .Sh FUNCTIONS -.Bl -tag -width compact +.Bl -tag -width indent .It Fn bus_dma_tag_create "parent" "alignment" "boundary" "lowaddr" \ "highaddr" "*filtfunc" "*filtfuncarg" "maxsize" "nsegments" "maxsegsz" \ "flags" "lockfunc" "lockfuncarg" "*dmat" Allocates a device specific DMA tag, and initializes it according to the arguments provided: -.Bl -tag -width *filtfuncarg -compact +.Bl -tag -width ".Fa filtfuncarg" .It Fa parent Indicates restrictions between the parent bridge, CPU memory, and the device. -May be NULL, if no DMA restrictions are to be inherited. +Each device must use a master parent tag by calling +.Fn bus_get_dma_tag . .It Fa alignment Alignment constraint, in bytes, of any mappings created using this tag. The alignment must be a power of 2. @@ -337,7 +350,7 @@ for byte alignment. Hardware requiring DMA transfers to start on a multiple of 4K would specify -.Em 4096. +.Em 4096 . .It Fa boundary Boundary constraint, in bytes, of the target DMA memory region. The boundary indicates the set of addresses, all multiples of the @@ -347,8 +360,7 @@ maximum segment size. .Ql 0 indicates that there are no boundary restrictions. -.It Fa lowaddr -.It Fa highaddr +.It Fa lowaddr , highaddr Bounds of the window of bus address space that .Em cannot be directly accessed by the device. @@ -372,11 +384,13 @@ is used to bounce requests that would otherwise conflict with the exclusion window. .It Fa filtfunc -Optional filter function (may be NULL) to be called for any attempt to +Optional filter function (may be +.Dv NULL ) +to be called for any attempt to map memory into the window described by .Fa lowaddr and -.Fa highaddr. +.Fa highaddr . A filter function is only required when the single window described by .Fa lowaddr @@ -387,7 +401,8 @@ that overlaps the exclusion window. .It Fa filtfuncarg Argument passed to all calls to the filter function for this tag. -May be NULL. +May be +.Dv NULL . .It Fa maxsize Maximum size, in bytes, of the sum of all segment lengths in a given DMA mapping associated with this tag. @@ -403,7 +418,7 @@ .Fa dmat . .It Fa flags Are as follows: -.Bl -tag -width "BUS_DMA_ALLOCNOW" -compact +.Bl -tag -width ".Dv BUS_DMA_ALLOCNOW" .It Dv BUS_DMA_ALLOCNOW Pre-allocate enough resources to handle at least one map load operation on this tag. @@ -418,9 +433,13 @@ It should be treated only as a minor optimization. .El .It Fa lockfunc -Optional lock manipulation function (may be NULL) to be called when busdma +Optional lock manipulation function (may be +.Dv NULL ) +to be called when busdma needs to manipulate a lock on behalf of the client. -If NULL is specified, +If +.Dv NULL +is specified, .Fn dflt_lock is used. .It Fa lockfuncarg @@ -451,7 +470,7 @@ .It Fn bus_dmamap_create "dmat" "flags" "*mapp" Allocates and initializes a DMA map. Arguments are as follows: -.Bl -tag -width nsegments -compact +.Bl -tag -width ".Fa nsegments" .It Fa dmat DMA tag. .It Fa flags @@ -471,7 +490,7 @@ .It Fn bus_dmamap_destroy "dmat" "map" Frees all resources associated with a given DMA map. Arguments are as follows: -.Bl -tag -width dmat -compact +.Bl -tag -width ".Fa dmat" .It Fa dmat DMA tag used to allocate .Fa map . @@ -493,10 +512,10 @@ .Fa map . This call will always return immediately and will not block for any reason. Arguments are as follows: -.Bl -tag -width buflen -compact +.Bl -tag -width ".Fa buflen" .It Fa dmat DMA tag used to allocate -.Fa map. +.Fa map . .It Fa map A DMA map without a currently active mapping. .It Fa buf @@ -515,15 +534,15 @@ See below for specific flags and error codes that control this behavior. .It Fa flags Are as follows: -.Bl -tag -width BUS_DMA_NOWAIT -compact -.It Er BUS_DMA_NOWAIT +.Bl -tag -width ".Dv BUS_DMA_NOWAIT" +.It Dv BUS_DMA_NOWAIT The load should not be deferred in case of insufficient mapping resources, and instead should return immediately with an appropriate error. .El .El .Pp Return values to the caller are as follows: -.Bl -tag -width EINPROGRESS -compact +.Bl -tag -width ".Er EINPROGRESS" .It 0 The callback has been called and completed. The status of the mapping has been delivered to the callback. @@ -536,7 +555,7 @@ .It Er ENOMEM The load request has failed due to insufficient resources, and the caller specifically used the -.Fa BUS_DMA_NOWAIT +.Dv BUS_DMA_NOWAIT flag. .It Er EINVAL The load request was invalid. @@ -558,7 +577,7 @@ When the callback is called, it is presented with an error value indicating the disposition of the mapping. Error may be one of the following: -.Bl -tag -width EINPROGRESS -compact +.Bl -tag -width ".Er EINPROGRESS" .It 0 The mapping was successful and the .Fa dm_segs @@ -581,7 +600,7 @@ argument is also passed to the callback routine, which contains the mbuf chain's packet header length. The -.Fa BUS_DMA_NOWAIT +.Dv BUS_DMA_NOWAIT flag is implied, thus no callback deferral will happen. .Pp Mbuf chains are assumed to be in kernel virtual address space. @@ -617,7 +636,7 @@ i.e. .Fa uio->uio_resid . The -.Fa BUS_DMA_NOWAIT +.Dv BUS_DMA_NOWAIT flag is implied, thus no callback deferral will happen. Returns the same errors as .Fn bus_dmamap_load . @@ -638,7 +657,7 @@ .It Fn bus_dmamap_unload "dmat" "map" Unloads a DMA map. Arguments are as follows: -.Bl -tag -width dmam -compact +.Bl -tag -width ".Fa dmam" .It Fa dmat DMA tag used to allocate .Fa map . @@ -655,7 +674,7 @@ Performs synchronization of a device visible mapping with the CPU visible memory referenced by that mapping. Arguments are as follows: -.Bl -tag -width dmat -compact +.Bl -tag -width ".Fa dmat" .It Fa dmat DMA tag used to allocate .Fa map . @@ -669,38 +688,44 @@ .Fa op . .El .Pp +The .Fn bus_dmamap_sync -is the method used to ensure that CPU and device DMA access to shared +function +is the method used to ensure that CPU's and device's direct +memory access (DMA) to shared memory is coherent. -For example, the CPU might be used to setup the contents of a buffer -that is to be DMA'ed into a device. +For example, the CPU might be used to set up the contents of a buffer +that is to be made available to a device. To ensure that the data are visible via the device's mapping of that -memory, the buffer must be loaded and a dma sync operation of -.Dv BUS_DMASYNC_PREREAD -must be performed. -Additional sync operations must be performed after every CPU write -to this memory if additional DMA reads are to be performed. -Conversely, for the DMA write case, the buffer must be loaded, -and a dma sync operation of +memory, the buffer must be loaded and a DMA sync operation of +.Dv BUS_DMASYNC_PREWRITE +must be performed after the CPU has updated the buffer and before the device +access is initiated. +If the CPU modifies this buffer again later, another .Dv BUS_DMASYNC_PREWRITE -must be performed. -The CPU will only be able to see the results of this DMA write -once the DMA has completed and a -.Dv BUS_DMASYNC_POSTWRITE -operation has been performed. +sync operation must be performed before an additional device +access. +Conversely, suppose a device updates memory that is to be read by a CPU. +In this case, the buffer must be loaded, and a DMA sync operation of +.Dv BUS_DMASYNC_PREREAD +must be performed before the device access is initiated. +The CPU will only be able to see the results of this memory update +once the DMA operation has completed and a +.Dv BUS_DMASYNC_POSTREAD +sync operation has been performed. .Pp -If DMA read and write operations are not preceded and followed by the +If read and write operations are not preceded and followed by the appropriate synchronization operations, behavior is undefined. .It Fn bus_dmamem_alloc "dmat" "**vaddr" "flags" "*mapp" Allocates memory that is mapped into KVA at the address returned in .Fa vaddr -that is permanently loaded into the newly created +and that is permanently loaded into the newly created .Vt bus_dmamap_t returned via .Fa mapp . Arguments are as follows: -.Bl -tag -width alignment -compact +.Bl -tag -width ".Fa alignment" .It Fa dmat DMA tag describing the constraints of the DMA mapping. .It Fa vaddr @@ -708,7 +733,7 @@ the allocated region. .It Fa flags Flags are defined as follows: -.Bl -tag -width BUS_DMA_NOWAIT -compact +.Bl -tag -width ".Dv BUS_DMA_NOWAIT" .It Dv BUS_DMA_WAITOK The routine can safely wait (sleep) for resources. .It Dv BUS_DMA_NOWAIT @@ -724,6 +749,9 @@ Use of this flag does not remove the requirement of using bus_dmamap_sync, but it may reduce the cost of performing these operations. +The +.Dv BUS_DMA_COHERENT +flag is currently implemented on sparc64 and arm. .It Dv BUS_DMA_ZERO Causes the allocated memory to be set to all zeros. .El @@ -735,7 +763,9 @@ .Pp The size of memory to be allocated is .Fa maxsize -as specified in +as specified in the call to +.Fn bus_dma_tag_create +for .Fa dmat . .Pp The current implementation of @@ -753,7 +783,7 @@ referenced by the returned map, the synchronization requirements as described in the .Fn bus_dmamap_sync -section still apply and should be used to achieve portability on architecutures +section still apply and should be used to achieve portability on architectures without coherent buses. .Pp Returns @@ -766,7 +796,7 @@ Any mappings will be invalidated. Arguments are as follows: -.Bl -tag -width vaddr -compact +.Bl -tag -width ".Fa vaddr" .It Fa dmat DMA tag. .It Fa vaddr @@ -783,14 +813,84 @@ .Er ENOMEM is returned. All -routines that are not of type, -.Vt void , +routines that are not of type +.Vt void will return 0 on success or an error -code, as discussed above. +code on failure as discussed above. .Pp All .Vt void routines will succeed if provided with valid arguments. +.Sh LOCKING +Two locking protocols are used by +.Nm . +The first is a private global lock that is used to synchronize access to the +bounce buffer pool on the architectures that make use of them. +This lock is strictly a leaf lock that is only used internally to +.Nm +and is not exposed to clients of the API. +.Pp +The second protocol involves protecting various resources stored in the tag. +Since almost all +.Nm +operations are done through requests from the driver that created the tag, +the most efficient way to protect the tag resources is through the lock that +the driver uses. +In cases where +.Nm +acts on its own without being called by the driver, the lock primitive +specified in the tag is acquired and released automatically. +An example of this is when the +.Fn bus_dmamap_load +callback function is called from a deferred context instead of the driver +context. +This means that certain +.Nm +functions must always be called with the same lock held that is specified in the +tag. +These functions include: +.Pp +.Bl -item -offset indent -compact +.It +.Fn bus_dmamap_load +.It +.Fn bus_dmamap_load_uio +.It +.Fn bus_dmamap_load_mbuf +.It +.Fn bus_dmamap_load_mbuf_sg +.It +.Fn bus_dmamap_unload +.It +.Fn bus_dmamap_sync +.El +.Pp +There is one exception to this rule. +It is common practice to call some of these functions during driver start-up +without any locks held. +So long as there is a guarantee of no possible concurrent use of the tag by +different threads during this operation, it is safe to not hold a lock for +these functions. +.Pp +Certain +.Nm +operations should not be called with the driver lock held, either because +they are already protected by an internal lock, or because they might sleep +due to memory or resource allocation. +The following functions must not be +called with any non-sleepable locks held: +.Pp +.Bl -item -offset indent -compact +.It +.Fn bus_dma_tag_create +.It +.Fn bus_dmamap_create +.It +.Fn bus_dmamem_alloc +.El +.Pp +All other functions do not have a locking protocol and can thus be +called with or without any system or driver locks held. .Sh SEE ALSO .Xr devclass 9 , .Xr device 9 , Index: mutex.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mutex.9,v retrieving revision 1.1.1.2 retrieving revision 1.2 diff -L share/man/man9/mutex.9 -L share/man/man9/mutex.9 -u -r1.1.1.2 -r1.2 --- share/man/man9/mutex.9 +++ share/man/man9/mutex.9 @@ -26,14 +26,15 @@ .\" SUCH DAMAGE. .\" .\" from BSDI $Id: mutex.4,v 1.1.2.3 1998/04/27 22:53:13 ewv Exp $ -.\" $FreeBSD: src/share/man/man9/mutex.9,v 1.47.2.1 2005/09/21 21:09:36 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/mutex.9,v 1.55 2007/03/30 18:07:26 julian Exp $ .\" -.Dd February 16, 2005 +.Dd December 21, 2006 .Dt MUTEX 9 .Os .Sh NAME .Nm mutex , .Nm mtx_init , +.Nm mtx_destroy , .Nm mtx_lock , .Nm mtx_lock_spin , .Nm mtx_lock_flags , @@ -44,7 +45,7 @@ .Nm mtx_unlock_spin , .Nm mtx_unlock_flags , .Nm mtx_unlock_spin_flags , -.Nm mtx_destroy , +.Nm mtx_sleep , .Nm mtx_initialized , .Nm mtx_owned , .Nm mtx_recursed , @@ -58,6 +59,8 @@ .Ft void .Fn mtx_init "struct mtx *mutex" "const char *name" "const char *type" "int opts" .Ft void +.Fn mtx_destroy "struct mtx *mutex" +.Ft void .Fn mtx_lock "struct mtx *mutex" .Ft void .Fn mtx_lock_spin "struct mtx *mutex" @@ -77,8 +80,8 @@ .Fn mtx_unlock_flags "struct mtx *mutex" "int flags" .Ft void .Fn mtx_unlock_spin_flags "struct mtx *mutex" "int flags" -.Ft void -.Fn mtx_destroy "struct mtx *mutex" +.Ft int +.Fn mtx_sleep "void *chan" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" .Ft int .Fn mtx_initialized "struct mtx *mutex" .Ft int @@ -91,7 +94,7 @@ .Ft void .Fn mtx_assert "struct mtx *mutex" "int what" .In sys/kernel.h -.Fn MTX_SYSINIT "name" "struct mutex *mtx" "const char *description" "int opts" +.Fn MTX_SYSINIT "name" "struct mtx *mtx" "const char *description" "int opts" .Sh DESCRIPTION Mutexes are the most basic and primary method of thread synchronization. The major design considerations for mutexes are: @@ -305,6 +308,15 @@ when it is destroyed. .Pp The +.Fn mtx_sleep +function is used to atomically release +.Fa mtx +while waiting for an event. +For more details on the parameters to this function, +see +.Xr sleep 9 . +.Pp +The .Fn mtx_initialized function returns non-zero if .Fa mutex @@ -434,6 +446,8 @@ to ignore this lock. .It Dv MTX_DUPOK Witness should not log messages about duplicate locks being acquired. +.It Dv MTX_NOPROFILE +Do not profile this lock. .El .Ss Lock and Unlock Flags The flags passed to the @@ -495,11 +509,13 @@ No locks are needed when calling these functions. .Sh SEE ALSO .Xr condvar 9 , -.Xr msleep 9 , +.Xr LOCK_PROFILING 9 , +.Xr locking 9 , .Xr mtx_pool 9 , -.Xr MUTEX_PROFILING 9 , .Xr panic 9 , +.Xr rwlock 9 , .Xr sema 9 , +.Xr sleep 9 , .Xr sx 9 .Sh HISTORY These Index: pmap_remove.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pmap_remove.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pmap_remove.9 -L share/man/man9/pmap_remove.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pmap_remove.9 +++ share/man/man9/pmap_remove.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pmap_remove.9,v 1.2 2004/07/06 07:02:31 ru Exp $ +.\" $FreeBSD: src/share/man/man9/pmap_remove.9,v 1.3 2006/04/03 21:17:36 peter Exp $ .\" .Dd July 21, 2003 .Dt PMAP_REMOVE 9 @@ -42,7 +42,7 @@ .Ft void .Fn pmap_remove_all "vm_page_t m" .Ft void -.Fn pmap_remove_pages "pmap_t pmap" "vm_offset_t sva" "vm_offset_t eva" +.Fn pmap_remove_pages "pmap_t pmap" .Sh DESCRIPTION The .Fn pmap_remove @@ -72,12 +72,8 @@ .Pp The .Fn pmap_remove_pages -function removes all pages from the physical map -.Fa pmap , -within the range of physical addresses bounded by -.Fa sva -and -.Fa eva . +function removes all user pages from the physical map +.Fa pmap . This function is called when a process exits to run down its address space more quickly than would be the case for calling .Fn pmap_remove . Index: suser.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/suser.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/suser.9 -L share/man/man9/suser.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/suser.9 +++ share/man/man9/suser.9 @@ -12,11 +12,7 @@ .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. -.\" 3. All advertising materials mentioning features or use of this software -.\" must display the following acknowledgement: -.\" This product includes software developed for the FreeBSD Project -.\" by Julian R Elischer -.\" 4. The name of the author may not be used to endorse or promote products +.\" 3. The name of the author may not be used to endorse or promote products .\" derived from this software without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR @@ -31,18 +27,17 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/suser.9,v 1.28 2005/01/12 21:48:25 ru Exp $ +.\" $FreeBSD: src/share/man/man9/suser.9,v 1.34 2007/08/30 15:03:21 danger Exp $ .\" -.Dd April 2, 2002 +.Dd August 30, 2007 .Dt SUSER 9 .Os .Sh NAME .Nm suser , .Nm suser_cred -.Nd check if credentials have superuser privilege +.Nd check if credentials have superuser privileges .Sh SYNOPSIS -.In sys/param.h -.In sys/systm.h +.In sys/priv.h .Ft int .Fn suser "struct thread *td" .Ft int @@ -54,6 +49,12 @@ .Fn suser_cred functions check if the credentials given include superuser powers. .Pp +These interfaces have now been obsoleted by +.Xr priv 9 , +and are provided only for compatibility with third party kernel modules that +have not yet been updated to the new interface. +They should not be used in any new kernel code. +.Pp The .Fn suser function is the most common, and should be used unless special @@ -66,37 +67,17 @@ powers should be extended to imprisoned roots, or when the credential to be checked is the real user rather than the effective user. .Pp -By default, a process does not command superuser powers if it has -been imprisoned by the -.Xr jail 2 -system call. -There are cases however where this is appropriate, and this can -be done by passing -.Dv SUSER_ALLOWJAIL -in the -.Fa flag -argument to the -.Fn suser_cred -function. -It is important to review carefully in each case that -this does not weaken the prison. -Generally, only where the action is protected by -.Xr chroot 2 -implicit in the -.Xr jail 2 -call should such powers be granted. -.Pp -By default, the credential checked is the effective user. -There are cases -where it is instead necessary to check the real user (for example, when -determining if resource limits should be applied), and this can be done -by passing the -.Dv SUSER_RUID -flag in the -.Fa flag -argument to the -.Fn suser_cred -function. +Whether or not a privilege is permitted in a +.Xr jail 8 +depends on logic in +.Fn prison_priv_check . +.Pp +In general, privileges are assigned based on the effective user ID; in some +cases, the real user ID may be used. +.Pp +The +.Fa flags +field is currently unused. .Pp The .Fn suser @@ -123,7 +104,8 @@ in which a TRUE response indicates superuser powers. .Sh SEE ALSO .Xr chroot 2 , -.Xr jail 2 +.Xr jail 2 , +.Xr priv 9 .Sh BUGS The .Fn suser Index: vref.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vref.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vref.9 -L share/man/man9/vref.9 -u -r1.2 -r1.3 --- share/man/man9/vref.9 +++ share/man/man9/vref.9 @@ -27,7 +27,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vref.9,v 1.13 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 1996 .Os Index: sleep.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/sleep.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/sleep.9 -L share/man/man9/sleep.9 -u -r1.2 -r1.3 --- share/man/man9/sleep.9 +++ share/man/man9/sleep.9 @@ -23,14 +23,15 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/sleep.9,v 1.45 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/sleep.9,v 1.61 2007/03/30 18:07:26 julian Exp $ .\" -.Dd December 17, 1998 +.Dd February 27, 2007 .Os .Dt SLEEP 9 .Sh NAME -.Nm sleep , .Nm msleep , +.Nm msleep_spin , +.Nm pause , .Nm tsleep , .Nm wakeup .Nd wait for events @@ -39,80 +40,65 @@ .In sys/systm.h .In sys/proc.h .Ft int -.Fn tsleep "void *ident" "int priority" "const char *wmesg" "int timo" +.Fn msleep "void *chan" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" .Ft int -.Fn msleep "void *ident" "struct mtx *mtx" "int priority" "const char *wmesg" "int timo" +.Fn msleep_spin "void *chan" "struct mtx *mtx" "const char *wmesg" "int timo" .Ft void -.Fn wakeup "void *ident" +.Fn pause "const char *wmesg" "int timo" +.Ft int +.Fn tsleep "void *chan" "int priority" "const char *wmesg" "int timo" +.Ft void +.Fn wakeup "void *chan" .Ft void -.Fn wakeup_one "void *ident" +.Fn wakeup_one "void *chan" .Sh DESCRIPTION The functions -.Fn tsleep +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +.Fn pause , +.Fn wakeup , and -.Fn wakeup -handle event-based process blocking. -If a process must wait for an -external event, it is put on sleep by -.Fn tsleep . +.Fn wakeup_one +handle event-based thread blocking. +If a thread must wait for an +external event, it is put to sleep by +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +or +.Fn pause . +Threads may also wait using one of the locking primitive sleep routines +.Xr mtx_sleep 9 , +.Xr rw_sleep 9 , +or +.Xr sx_sleep 9 . +.Pp The parameter -.Fa ident +.Fa chan is an arbitrary address that uniquely identifies the event on which -the process is being asleep. -All processes sleeping on a single -.Fa ident +the thread is being put to sleep. +All threads sleeping on a single +.Fa chan are woken up later by .Fn wakeup , often called from inside an interrupt routine, to indicate that the -resource the process was blocking on is available now. +resource the thread was blocking on is available now. .Pp The parameter -.Fa wmesg -is a string describing the sleep condition for tools like -.Xr ps 1 . -Due to the limited space of those programs to display arbitrary strings, -this message should not be longer than 6 characters. -.Pp -The -.Fn wakeup_one -function is used to make the first process in the queue that is -sleeping on the parameter -.Fa ident -runnable. -This can prevent the system from becoming saturated -when a large number of processes are sleeping on the same address, -but only one of them can actually do any useful work when made -runnable. -.Pp -The -.Fn tsleep -function is the general sleep call. -Suspends the current process until a wakeup is -performed on the specified identifier. -The process will then be made +.Fa priority +specifies a new priority for the thread as well as some optional flags. +If the new priority is not 0, +then the thread will be made runnable with the specified -.Fa priority . -Sleeps at most -.Fa timo -\&/ hz seconds (0 means no timeout). -If the -.Va Giant -lock is not held, and -.Fa mtx -is -.Dv NULL , -then -.Fa timo -must be non-zero. +.Fa priority +when it resumes. If .Fa priority includes the .Dv PCATCH -flag, signals are checked before and after sleeping, else signals are +flag, signals are checked before and after sleeping, otherwise signals are not checked. -Returns 0 if awakened, -.Er EWOULDBLOCK -if the timeout expires. If .Dv PCATCH is set and a signal needs to be delivered, @@ -124,48 +110,206 @@ (return .Er EINTR ) . .Pp -The -.Fn msleep -function is a variation on tsleep. The parameter -.Fa mtx -is a mutex which will be released before sleeping and reacquired before -.Fn msleep -returns. +.Fa wmesg +is a string describing the sleep condition for tools like +.Xr ps 1 . +Due to the limited space of those programs to display arbitrary strings, +this message should not be longer than 6 characters. +.Pp +The parameter +.Fa timo +specifies a timeout for the sleep. +If +.Fa timo +is not 0, +then the thread will sleep for at most +.Fa timo No / Va hz +seconds. +If the timeout expires, +then the sleep function will return +.Er EWOULDBLOCK . +.Pp +Several of the sleep functions including +.Fn msleep , +.Fn msleep_spin , +and the locking primitive sleep routines specify an additional lock +parameter. +The lock will be released before sleeping and reacquired +before the sleep routine returns. If .Fa priority includes the .Dv PDROP -flag, the -.Fa mtx -parameter will not be reacquired before returning. -The mutex is -used to ensure that a condition can be checked atomically, and -that the current process can be suspended without missing a +flag, then +the lock will not be reacquired before returning. +The lock is used to ensure that a condition can be checked atomically, +and that the current thread can be suspended without missing a change to the condition, or an associated wakeup. +In addition, all of the sleep routines will fully drop the +.Va Giant +mutex +(even if recursed) +while the thread is suspended and will reacquire the +.Va Giant +mutex before the function returns. +.Pp +To avoid lost wakeups, +either a lock should be used to protect against races, +or a timeout should be specified to place an upper bound on the delay due +to a lost wakeup. +As a result, +the +.Fn tsleep +function should only be invoked with a timeout of 0 when the +.Va Giant +mutex is held. +.Pp +The +.Fn msleep +function requires that +.Fa mtx +reference a default, i.e. non-spin, mutex. +Its use is deprecated in favor of +.Xr mtx_sleep 9 +which provides identical behavior. +.Pp +The +.Fn msleep_spin +function requires that +.Fa mtx +reference a spin mutex. +The +.Fn msleep_spin +function does not accept a +.Fa priority +parameter and thus does not support changing the current thread's priority, +the +.Dv PDROP +flag, +or catching signals via the +.Dv PCATCH +flag. +.Pp +The +.Fn pause +function is a wrapper around +.Fn tsleep +that suspends execution of the current thread for the indicated timeout. +The thread can not be awakened early by signals or calls to +.Fn wakeup +or +.Fn wakeup_one . +.Pp +The +.Fn wakeup_one +function makes the first thread in the queue that is sleeping on the +parameter +.Fa chan +runnable. +This reduces the load when a large number of threads are sleeping on +the same address, but only one of them can actually do any useful work +when made runnable. +.Pp +Due to the way it works, the +.Fn wakeup_one +function requires that only related threads sleep on a specific +.Fa chan +address. +It is the programmer's responsibility to choose a unique +.Fa chan +value. +The older +.Fn wakeup +function did not require this, though it was never good practice +for threads to share a +.Fa chan +value. +When converting from +.Fn wakeup +to +.Fn wakeup_one , +pay particular attention to ensure that no other threads wait on the +same +.Fa chan . .Sh RETURN VALUES -See above. +If the thread is awakened by a call to +.Fn wakeup +or +.Fn wakeup_one , +the +.Fn msleep , +.Fn msleep_spin , +.Fn tsleep , +and locking primitive sleep functions return 0. +Otherwise, a non-zero error code is returned. +.Sh ERRORS +.Fn msleep , +.Fn msleep_spin , +.Fn tsleep , +and the locking primitive sleep functions will fail if: +.Bl -tag -width Er +.It Bq Er EINTR +The +.Dv PCATCH +flag was specified, a signal was caught, and the system call should be +interrupted. +.It Bq Er ERESTART +The +.Dv PCATCH +flag was specified, a signal was caught, and the system call should be +restarted. +.It Bq Er EWOULDBLOCK +A non-zero timeout was specified and the timeout expired. +.El .Sh SEE ALSO .Xr ps 1 , +.Xr locking 9 , .Xr malloc 9 , -.Xr mi_switch 9 +.Xr mi_switch 9 , +.Xr mtx_sleep 9 , +.Xr rw_sleep 9 , +.Xr sx_sleep 9 .Sh HISTORY -The sleep/wakeup process synchronization mechanism is very old. -It -appeared in a very early version of +The functions +.Fn sleep +and +.Fn wakeup +were present in +.At v1 . +They were probably also present in the preceding +PDP-7 version of .Ux . +They were the basic process synchronization model. .Pp The .Fn tsleep function appeared in -.Bx 4.4 . -.Pp +.Bx 4.4 +and added the parameters +.Fa wmesg +and +.Fa timo . The .Fn sleep -function used to be the traditional form. -It did not let you specify a timeout or a -.Fa wmesg , -hence it was discontinued. +function was removed in +.Fx 2.2 . +The +.Fn wakeup_one +function appeared in +.Fx 2.2 . +The +.Fn msleep +function appeared in +.Fx 5.0 , +and the +.Fn msleep_spin +function appeared in +.Fx 6.2 . +The +.Fn pause +function appeared in +.Fx 7.0 . .Sh AUTHORS .An -nosplit This manual page was written by Index: atomic.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/atomic.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/atomic.9 -L share/man/man9/atomic.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/atomic.9 +++ share/man/man9/atomic.9 @@ -21,9 +21,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/atomic.9,v 1.11.10.1 2005/10/06 18:12:04 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/atomic.9,v 1.13 2005/11/18 10:52:24 ru Exp $ .\" -.Dd October 27, 2000 +.Dd September 27, 2005 .Os .Dt ATOMIC 9 .Sh NAME Index: rtentry.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/rtentry.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/rtentry.9 -L share/man/man9/rtentry.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/rtentry.9 +++ share/man/man9/rtentry.9 @@ -26,7 +26,7 @@ .\" OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/rtentry.9,v 1.24 2005/01/21 08:36:40 ru Exp $ +.\" $FreeBSD: src/share/man/man9/rtentry.9,v 1.25 2007/08/05 07:38:09 maxim Exp $ .\" .Dd October 7, 2004 .Os @@ -263,7 +263,7 @@ .Dv RMX_RTTUNIT per second. .It Vt "u_long rmx_rttvar" ; -The average deviation of the round-type time to this destination, in +The average deviation of the round-trip time to this destination, in units of .Dv RMX_RTTUNIT per second. Index: device_get_softc.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/device_get_softc.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/device_get_softc.9 -L share/man/man9/device_get_softc.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/device_get_softc.9 +++ share/man/man9/device_get_softc.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/device_get_softc.9,v 1.10.10.2 2005/11/04 22:10:13 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/device_get_softc.9,v 1.13 2005/11/18 10:52:24 ru Exp $ .\" .Dd August 2, 2005 .Dt DEVICE_GET_SOFTC 9 @@ -60,8 +60,8 @@ .Sh RETURN VALUES The pointer to the driver-specific instance variable is returned. .Sh SEE ALSO -.Xr DEVICE_PROBE 9 , .Xr device 9 , +.Xr DEVICE_PROBE 9 , .Xr device_set_softc 9 , .Xr driver 9 .Sh AUTHORS Index: mi_switch.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mi_switch.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/mi_switch.9 -L share/man/man9/mi_switch.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/mi_switch.9 +++ share/man/man9/mi_switch.9 @@ -34,7 +34,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mi_switch.9,v 1.19 2005/01/29 20:05:07 ru Exp $ +.\" $FreeBSD: src/share/man/man9/mi_switch.9,v 1.20 2007/03/09 22:41:01 jhb Exp $ .\" .Dd November 24, 1996 .Dt MI_SWITCH 9 @@ -65,13 +65,13 @@ can be enumerated as follows: .Bl -enum -offset indent .It -From within -.Xr sleep 9 , -.Xr tsleep 9 -and -.Xr msleep 9 +From within a function such as +.Xr cv_wait 9 , +.Xr mtx_lock , +or +.Xr tsleep 9 when the current thread -voluntarily relinquishes the CPU to wait for some resource to become +voluntarily relinquishes the CPU to wait for some resource or lock to become available. .It After handling a trap @@ -157,6 +157,7 @@ .Va sched_lock mutex held. .Sh SEE ALSO +.Xr cv_wait 9 , .Xr issignal 9 , .Xr mutex 9 , .Xr runqueue 9 , Index: vm_page_wakeup.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_wakeup.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_wakeup.9 -L share/man/man9/vm_page_wakeup.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_wakeup.9 +++ share/man/man9/vm_page_wakeup.9 @@ -24,8 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vm_page_wakeup.9,v 1.2 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/vm_page_wakeup.9,v 1.3 2006/02/13 21:34:19 joel Exp $ .\" .Dd July 14, 2001 .Dt VM_PAGE_BUSY 9 @@ -68,7 +67,6 @@ flag on the page, and calls .Fn vm_page_flash in case somebody has been waiting for it. -.Pp .Sh SEE ALSO .Xr vm_page_sleep_busy 9 , .Xr wakeup 9 Index: memguard.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/memguard.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/memguard.9 -L share/man/man9/memguard.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/memguard.9 +++ share/man/man9/memguard.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/memguard.9,v 1.1 2005/02/22 17:18:27 brueffer Exp $ +.\" $FreeBSD: src/share/man/man9/memguard.9,v 1.5 2006/09/18 15:24:20 ru Exp $ .\" -.Dd February 22, 2005 +.Dd January 31, 2006 .Dt MEMGUARD 9 .Os .Sh NAME @@ -47,42 +47,38 @@ and .Fn free for a particular malloc type. -.Nm -takes over -.Dv M_SUBPROC -allocations by default. -.Sh FILES -.Bl -tag -width ".Pa src/sys/kern/kern_malloc.c" -compact -.It Pa src/sys/kern/kern_malloc.c -File to replace the malloc type in -.El .Sh EXAMPLES -The following steps are necessary to use -.Nm : -.Bl -enum -.It -Put the -.Dv DEBUG_MEMGUARD -option into your kernel config. -.It -Open -.Pa src/sys/kern/kern_malloc.c -in your favourite editor. -Look for lines containing -.Dq Li "XXX CHANGEME!" -and replace -.Dv M_SUBPROC -with the appropriate malloc type. -This might require additional but small/simple -code modifications -(e.g., if the malloc type is declared out of scope). -.It -Build and install your kernel. -Tune the -.Va vm.memguard_divisor -boot-time tunable, which is used to scale how much of +To use +.Nm +for memory type compiled into the kernel, one has to add the +following line to the +.Pa /boot/loader.conf : +.Bd -literal -offset indent +vm.memguard.desc= +.Ed +.Pp +Where +.Ar memory_type +is a short description of memory type to monitor. +The short description of memory type is the second argument to +.Xr MALLOC_DEFINE 9 , +so one has to find it in the kernel source. +.Pp +To use +.Nm +for memory type defined in a kernel module, one has to set +.Va vm.memguard.desc +.Xr sysctl 8 +variable before loading the module: +.Bd -literal -offset indent +sysctl vm.memguard.desc= +.Ed +.Pp +The +.Va vm.memguard.divisor +boot-time tunable is used to scale how much of .Va kmem_map -you want to allot for +one wants to allocate for .Nm . The default is 10, so .Va kmem_size Ns /10 @@ -93,12 +89,12 @@ .Va vm.kmem_size .Xr sysctl 8 variable. -.El .Sh SEE ALSO .Xr sysctl 8 , .Xr vmstat 8 , .Xr contigmalloc 9 , -.Xr malloc 9 +.Xr malloc 9 , +.Xr redzone 9 .Sh HISTORY .Nm first appeared in --- /dev/null +++ share/man/man9/locking.9 @@ -0,0 +1,357 @@ +.\" Copyright (c) 2007 Julian Elischer (julian - freebsd org ) +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/locking.9,v 1.11 2007/08/09 21:09:56 julian Exp $ +.\" +.Dd March 14, 2007 +.Dt LOCKING 9 +.Os +.Sh NAME +.Nm locking +.Nd kernel synchronization primitives +.Sh SYNOPSIS +All sorts of stuff to go here. +.Pp +.Sh DESCRIPTION +The +.Em FreeBSD +kernel is written to run across multiple CPUs and as such requires +several different synchronization primitives to allow the developers +to safely access and manipulate the many data types required. +.Pp +These include: +.Bl -enum +.It +Spin Mutexes +.It +Sleep Mutexes +.It +pool Mutexes +.It +Shared-Exclusive locks +.It +Reader-Writer locks +.It +Turnstiles +.It +Semaphores +.It +Condition variables +.It +Sleep/wakeup +.It +Giant +.It +Lockmanager locks +.El +.Pp +The primitives interact and have a number of rules regarding how +they can and can not be combined. +There are too many for the average +human mind and they keep changing. +(if you disagree, please write replacement text) :-) +.Pp +Some of these primitives may be used at the low (interrupt) level and +some may not. +.Pp +There are strict ordering requirements and for some of the types this +is checked using the +.Xr witness 4 +code. +.Pp +.Ss SPIN Mutexes +Mutexes are the basic primitive. +You either hold it or you don't. +If you don't own it then you just spin, waiting for the holder (on +another CPU) to release it. +Hopefully they are doing something fast. +You +.Em must not +do anything that deschedules the thread while you +are holding a SPIN mutex. +.Ss Mutexes +Basically (regular) mutexes will deschedule the thread if the +mutex can not be acquired. +A non-spin mutex can be considered to be equivalent +to getting a write lock on an +.Em rw_lock +(see below), and in fact non-spin mutexes and rw_locks may soon become the same thing. +As in spin mutexes, you either get it or you don't. +You may only call the +.Xr sleep 9 +call via +.Fn msleep +or the new +.Fn mtx_sleep +variant. +These will atomically drop the mutex and reacquire it +as part of waking up. +This is often however a +.Em BAD +idea because it generally relies on you having +such a good knowledge of all the call graph above you +and what assumptions it is making that there are a lot +of ways to make hard-to-find mistakes. +For example you MUST re-test all the assumptions you made before, +all the way up the call graph to where you got the lock. +You can not just assume that mtx_sleep can be inserted anywhere. +If any caller above you has any mutex or +rwlock, your sleep, will cause a panic. +If the sleep only happens rarely it may be years before the +bad code path is found. +.Ss Pool Mutexes +A variant of regular mutexes where the allocation of the mutex is handled +more by the system. +.Ss Rw_locks +Reader/writer locks allow shared access to protected data by multiple threads, +or exclusive access by a single thread. +The threads with shared access are known as +.Em readers +since they should only read the protected data. +A thread with exclusive access is known as a +.Em writer +since it may modify protected data. +.Pp +Although reader/writer locks look very similar to +.Xr sx 9 +(see below) locks, their usage pattern is different. +Reader/writer locks can be treated as mutexes (see above and +.Xr mutex 9 ) +with shared/exclusive semantics. +More specifically, regular mutexes can be +considered to be equivalent to a write-lock on an +.Em rw_lock. +In the future this may in fact +become literally the fact. +An +.Em rw_lock +can be locked while holding a regular mutex, but +can +.Em not +be held while sleeping. +The +.Em rw_lock +locks have priority propagation like mutexes, but priority +can be propagated only to an exclusive holder. +This limitation comes from the fact that shared owners +are anonymous. +Another important property is that shared holders of +.Em rw_lock +can recurse, but exclusive locks are not allowed to recurse. +This ability should not be used lightly and +.Em may go away. +Users of recursion in any locks should be prepared to +defend their decision against vigorous criticism. +.Ss Sx_locks +Shared/exclusive locks are used to protect data that are read far more often +than they are written. +Mutexes are inherently more efficient than shared/exclusive locks, so +shared/exclusive locks should be used prudently. +The main reason for using an +.Em sx_lock +is that a thread may hold a shared or exclusive lock on an +.Em sx_lock +lock while sleeping. +As a consequence of this however, an +.Em sx_lock +lock may not be acquired while holding a mutex. +The reason for this is that, if one thread slept while holding an +.Em sx_lock +lock while another thread blocked on the same +.Em sx_lock +lock after acquiring a mutex, then the second thread would effectively +end up sleeping while holding a mutex, which is not allowed. +The +.Em sx_lock +should be considered to be closely related to +.Xr sleep 9 . +In fact it could in some cases be +considered a conditional sleep. +.Ss Turnstiles +Turnstiles are used to hold a queue of threads blocked on +non-sleepable locks. +Sleepable locks use condition variables to implement their queues. +Turnstiles differ from a sleep queue in that turnstile queue's +are assigned to a lock held by an owning thread. +Thus, when one thread is enqueued onto a turnstile, it can lend its +priority to the owning thread. +If this sounds confusing, we need to describe it better. +.Ss Semaphores +.Ss Condition variables +Condition variables are used in conjunction with mutexes to wait for +conditions to occur. +A thread must hold the mutex before calling the +.Fn cv_wait* , +functions. +When a thread waits on a condition, the mutex +is atomically released before the thread is blocked, then reacquired +before the function call returns. +.Ss Giant +Giant is a special instance of a sleep lock. +It has several special characteristics. +.Bl -enum +.It +It is recursive. +.It +Drivers can request that Giant be locked around them, but this is +going away. +.It +You can sleep while it has recursed, but other recursive locks cannot. +.It +Giant must be locked first before other locks. +.It +There are places in the kernel that drop Giant and pick it back up +again. +Sleep locks will do this before sleeping. +Parts of the Network or VM code may do this as well, depending on the +setting of a sysctl. +This means that you cannot count on Giant keeping other code from +running if your code sleeps, even if you want it to. +.El +.Ss Sleep/wakeup +The functions +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +.Fn pause , +.Fn wakeup , +and +.Fn wakeup_one +handle event-based thread blocking. +If a thread must wait for an external event, it is put to sleep by +.Fn tsleep , +.Fn msleep , +.Fn msleep_spin , +or +.Fn pause . +Threads may also wait using one of the locking primitive sleep routines +.Xr mtx_sleep 9 , +.Xr rw_sleep 9 , +or +.Xr sx_sleep 9 . +.Pp +The parameter +.Fa chan +is an arbitrary address that uniquely identifies the event on which +the thread is being put to sleep. +All threads sleeping on a single +.Fa chan +are woken up later by +.Fn wakeup , +often called from inside an interrupt routine, to indicate that the +resource the thread was blocking on is available now. +.Pp +Several of the sleep functions including +.Fn msleep , +.Fn msleep_spin , +and the locking primitive sleep routines specify an additional lock +parameter. +The lock will be released before sleeping and reacquired +before the sleep routine returns. +If +.Fa priority +includes the +.Dv PDROP +flag, then the lock will not be reacquired before returning. +The lock is used to ensure that a condition can be checked atomically, +and that the current thread can be suspended without missing a +change to the condition, or an associated wakeup. +In addition, all of the sleep routines will fully drop the +.Va Giant +mutex +(even if recursed) +while the thread is suspended and will reacquire the +.Va Giant +mutex before the function returns. +.Pp +.Ss lockmanager locks +Largely deprecated. +See the +.Xr lock 9 +page for more information. +I don't know what the downsides are but I'm sure someone will fill in this part. +.Sh Usage tables. +.Ss Interaction table. +The following table shows what you can and can not do if you hold +one of the synchronization primitives discussed here: +(someone who knows what they are talking about should write this table) +.Bl -column ".Ic xxxxxxxxxxxxxxxxxxxx" ".Xr XXXXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXX" -offset indent +.It Xo +.Em "You have: You want:" Ta Spin_mtx Ta Slp_mtx Ta sx_lock Ta rw_lock Ta sleep +.Xc +.It Ic SPIN mutex Ta \&ok Ta \&no Ta \&no Ta \&no Ta \&no-3 +.It Ic Sleep mutex Ta \&ok Ta \&ok-1 Ta \&no Ta \&ok Ta \&no-3 +.It Ic sx_lock Ta \&ok Ta \&no Ta \&ok-2 Ta \&no Ta \&ok-4 +.It Ic rw_lock Ta \&ok Ta \&ok Ta \&no Ta \&ok-2 Ta \&no-3 +.El +.Pp +.Em *1 +Recursion is defined per lock. +Lock order is important. +.Pp +.Em *2 +readers can recurse though writers can not. +Lock order is important. +.Pp +.Em *3 +There are calls atomically release this primitive when going to sleep +and reacquire it on wakeup (e.g. +.Fn mtx_sleep , +.Fn rw_sleep +and +.Fn msleep_spin +). +.Pp +.Em *4 +Though one can sleep holding an sx lock, one can also use +.Fn sx_sleep +which atomically release this primitive when going to sleep and +reacquire it on wakeup. +.Ss Context mode table. +The next table shows what can be used in different contexts. +At this time this is a rather easy to remember table. +.Bl -column ".Ic Xxxxxxxxxxxxxxxxxxxx" ".Xr XXXXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXXXX" ".Xr XXXXX" -offset indent +.It Xo +.Em "Context:" Ta Spin_mtx Ta Slp_mtx Ta sx_lock Ta rw_lock Ta sleep +.Xc +.It interrupt: Ta \&ok Ta \&no Ta \&no Ta \&no Ta \&no +.It idle: Ta \&ok Ta \&no Ta \&no Ta \&no Ta \&no +.El +.Sh SEE ALSO +.Xr condvar 9 , +.Xr lock 9 , +.Xr mtx_pool 9 , +.Xr mutex 9 , +.Xr rwlock 9 , +.Xr sema 9 , +.Xr sleep 9 , +.Xr sx 9 , +.Xr LOCK_PROFILING 9 , +.Xr WITNESS 9 +.Sh HISTORY +These +functions appeared in +.Bsx 4.1 +through +.Fx 7.0 Index: zone.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/zone.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/zone.9 -L share/man/man9/zone.9 -u -r1.2 -r1.3 --- share/man/man9/zone.9 +++ share/man/man9/zone.9 @@ -23,10 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/zone.9,v 1.26 2004/01/25 11:39:41 des Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/zone.9,v 1.28 2006/10/21 16:08:21 ru Exp $ .\" -.Dd July 21, 2003 +.Dd October 2, 2006 .Dt ZONE 9 .Os .Sh NAME @@ -66,27 +65,9 @@ are not, and provides functions for allocating items from the zone and for releasing them back (which makes them available for later use). .Pp -The zone allocator stores state information inside the items proper -while they are not allocated, -so structures that will be managed by the zone allocator -and wish to use the type stable property of zones by leaving some fields -pre-filled between allocations, must reserve -two pointers at the very beginning for internal use by the zone -allocator, as follows: -.Bd -literal -offset indent -struct my_item { - struct my_item *z_rsvd1; - struct my_item *z_rsvd2; - /* rest of structure */ -}; -.Ed -.Pp -Alternatively they should assume those entries corrupted -after each allocation. After the first allocation of an item, it will have been cleared to zeroes, however subsequent allocations -will retain the contents as of the last free, with the exception of the -fields mentioned above. +will retain the contents as of the last free. .Pp The .Fn uma_zcreate Index: disk.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/disk.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/disk.9 -L share/man/man9/disk.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/disk.9 +++ share/man/man9/disk.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/disk.9,v 1.7 2004/06/21 14:11:45 mpp Exp $ +.\" $FreeBSD: src/share/man/man9/disk.9,v 1.10 2007/05/05 17:12:15 pjd Exp $ .\" .Dd February 18, 2004 .Dt DISK 9 @@ -35,7 +35,7 @@ .Nd kernel disk storage API .Sh SYNOPSIS .In geom/geom_disk.h -.Ft struct *disk +.Ft struct disk * .Fn disk_alloc void .Ft void .Fn disk_create "struct disk *disk" "int version" @@ -94,8 +94,10 @@ (maintained by device driver), .Dv DISKFLAG_OPEN (maintained by storage framework), -and .Dv DISKFLAG_CANDELETE +(maintained by device driver), +and +.Dv DISKFLAG_CANFLUSHCACHE (maintained by device driver). .It Vt "const char *" Va d_name Holds the name of the storage device class, e.g., @@ -170,6 +172,8 @@ Please see .Pa src/sys/geom/notes for details. +.It Vt char Va d_ident[DISK_IDENT_SIZE] +This field can and should be used to store disk's serial number. .El .Ss Driver Private Data This field may be used by the device driver to store a pointer to Index: VFS_ROOT.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/VFS_ROOT.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/VFS_ROOT.9 -L share/man/man9/VFS_ROOT.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/VFS_ROOT.9 +++ share/man/man9/VFS_ROOT.9 @@ -26,9 +26,9 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/VFS_ROOT.9,v 1.10 2004/07/12 09:06:51 alfred Exp $ +.\" $FreeBSD: src/share/man/man9/VFS_ROOT.9,v 1.12 2006/09/18 15:24:20 ru Exp $ .\" -.Dd July 24, 1996 +.Dd August 26, 2006 .Os .Dt VFS_ROOT 9 .Sh NAME @@ -39,14 +39,23 @@ .In sys/mount.h .In sys/vnode.h .Ft int -.Fn VFS_ROOT "struct mount *mp" "struct vnode **vpp" "struct thread *td" +.Fn VFS_ROOT "struct mount *mp" "int flags" "struct vnode **vpp" "struct thread *td" .Sh DESCRIPTION Return a locked vnode for the root directory of the file system. .Pp Its arguments are: -.Bl -tag -width vpp +.Bl -tag -width flags .It Fa mp The file system. +.It Fa flags +The lock type. +Could be +.Dv LK_EXCLUSIVE +or +.Dv LK_SHARED . +File system is free to ignore the +.Fa flags +argument and instead acquire an exclusive lock. .It Fa vpp Return parameter for the root vnode. .It Fa td Index: pci.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/pci.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/pci.9 -L share/man/man9/pci.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/pci.9 +++ share/man/man9/pci.9 @@ -23,9 +23,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/pci.9,v 1.9 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/pci.9,v 1.10 2007/09/30 11:05:13 marius Exp $ .\" -.Dd January 22, 2005 +.Dd September 30, 2007 .Dt PCI 9 .Os .Sh NAME @@ -39,6 +39,7 @@ .Nm pci_set_powerstate , .Nm pci_get_powerstate , .Nm pci_find_bsf , +.Nm pci_find_dbsf , .Nm pci_find_device .Nd PCI bus interface .Sh SYNOPSIS @@ -65,6 +66,8 @@ .Ft device_t .Fn pci_find_bsf "uint8_t bus" "uint8_t slot" "uint8_t func" .Ft device_t +.Fn pci_find_dbsf "uint32_t domain" "uint8_t bus" "uint8_t slot" "uint8_t func" +.Ft device_t .Fn pci_find_device "uint16_t vendor" "uint16_t device" .Sh DESCRIPTION The @@ -198,6 +201,30 @@ number actually refers to the number of the device on the bus, which does not necessarily indicate its geographic location in terms of a physical slot. +Note that in case the system has multiple PCI domains, +the +.Fn pci_find_bsf +function only searches the first one. +Actually, it is equivalent to: +.Bd -literal -offset indent +pci_find_dbsf(0, bus, slot, func); +.Ed +.Pp +The +.Fn pci_find_dbsf +function looks up the +.Vt device_t +of a PCI device, given its +.Fa domain , +.Fa bus , +.Fa slot , +and +.Fa func . +The +.Fa slot +number actually refers to the number of the device on the bus, +which does not necessarily indicate its geographic location +in terms of a physical slot. .Pp The .Fn pci_find_device --- /dev/null +++ share/man/man9/rwlock.9 @@ -0,0 +1,286 @@ +.\" Copyright (c) 2006 Gleb Smirnoff +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/rwlock.9,v 1.10.2.1 2007/11/27 14:08:14 attilio Exp $ +.\" +.Dd November 25, 2007 +.Dt RWLOCK 9 +.Os +.Sh NAME +.Nm rwlock , +.Nm rw_init , +.Nm rw_init_flags, +.Nm rw_destroy , +.Nm rw_rlock , +.Nm rw_wlock , +.Nm rw_runlock , +.Nm rw_wunlock , +.Nm rw_try_upgrade , +.Nm rw_downgrade , +.Nm rw_sleep , +.Nm rw_initialized , +.Nm rw_wowned , +.Nm rw_assert , +.Nm RW_SYSINIT +.Nd kernel reader/writer lock +.Sh SYNOPSIS +.In sys/param.h +.In sys/lock.h +.In sys/rwlock.h +.Ft void +.Fn rw_init "struct rwlock *rw" "const char *name" +.Ft void +.Fn rw_init_flags "struct rwlock *rw" "const char *name" "int opts" +.Ft void +.Fn rw_destroy "struct rwlock *rw" +.Ft void +.Fn rw_rlock "struct rwlock *rw" +.Ft void +.Fn rw_wlock "struct rwlock *rw" +.Ft void +.Fn rw_runlock "struct rwlock *rw" +.Ft void +.Fn rw_wunlock "struct rwlock *rw" +.Ft int +.Fn rw_try_upgrade "struct rwlock *rw" +.Ft void +.Fn rw_downgrade "struct rwlock *rw" +.Ft int +.Fn rw_sleep "void *chan" "struct rwlock *rw" "int priority" "const char *wmesg" "int timo" +.Ft int +.Fn rw_initialized "struct rwlock *rw" +.Ft int +.Fn rw_wowned "struct rwlock *rw" +.Pp +.Cd "options INVARIANTS" +.Cd "options INVARIANT_SUPPORT" +.Ft void +.Fn rw_assert "struct rwlock *rw" "int what" +.In sys/kernel.h +.Fn RW_SYSINIT "name" "struct rwlock *rw" "const char *desc" +.Sh DESCRIPTION +Reader/writer locks allow shared access to protected data by multiple threads, +or exclusive access by a single thread. +The threads with shared access are known as +.Em readers +since they only read the protected data. +A thread with exclusive access is known as a +.Em writer +since it can modify protected data. +.Pp +Although reader/writer locks look very similar to +.Xr sx 9 +locks, their usage pattern is different. +Reader/writer locks can be treated as mutexes (see +.Xr mutex 9 ) +with shared/exclusive semantics. +Unlike +.Xr sx 9 , +an +.Nm +can be locked while holding a non-spin mutex, and an +.Nm +cannot be held while sleeping. +The +.Nm +locks have priority propagation like mutexes, but priority +can be propagated only to an exclusive holder. +This limitation comes from the fact that shared owners +are anonymous. +Another important property is that shared holders of +.Nm +can recurse, +and exclusive locks can be made recursive selectively. +.Ss Macros and Functions +.Bl -tag -width indent +.It Fn rw_init "struct rwlock *rw" "const char *name" +Initialize structure located at +.Fa rw +as reader/writer lock, described by name +.Fa name . +The description is used solely for debugging purposes. +This function must be called before any other operations +on the lock. +.It Fn rw_init_flags "struct rwlock *rw" "const char *name" "int opts" +Initialize the rw lock just like the +.Fn rw_init +function, but specifying a set of optional flags to alter the +behaviour of +.Fa rw , +through the +.Fa opts +argument. +It contains one or more of the following flags: +.Bl -tag -width ".Dv RW_NOPROFILE" +.It Dv RW_DUPOK +Witness should not log messages about duplicate locks being acquired. +.It Dv RW_NOPROFILE +Do not profile this lock. +.It Dv RW_NOWITNESS +Instruct +.Xr witness 4 +to ignore this lock. +.It Dv RW_QUIET +Do not log any operations for this lock via +.Xr ktr 4 . +.It Dv RW_RECURSE +Allow threads to recursively acquire exclusive locks for +.Fa rw . +.It Fn rw_rlock "struct rwlock *rw" +Lock +.Fa rw +as a reader. +If any thread holds this lock exclusively, the current thread blocks, +and its priority is propagated to the exclusive holder. +The +.Fn rw_rlock +function can be called when the thread has already acquired reader +access on +.Fa rw . +This is called +.Dq "recursing on a lock" . +.It Fn rw_wlock "struct rwlock *rw" +Lock +.Fa rw +as a writer. +If there are any shared owners of the lock, the current thread blocks. +The +.Fn rw_wlock +function can be called recursively only if +.Fa rw +has been initialized with the +.Dv RW_RECURSE +option enabled. +.It Fn rw_runlock "struct rwlock *rw" +This function releases a shared lock previously acquired by +.Fn rw_rlock . +.It Fn rw_wunlock "struct rwlock *rw" +This function releases an exclusive lock previously acquired by +.Fn rw_wlock . +.It Fn rw_try_upgrade "struct rwlock *rw" +Attempt to upgrade a single shared lock to an exclusive lock. +The current thread must hold a shared lock of +.Fa rw . +This will only succeed if the current thread holds the only shared lock on +.Fa rw , +and it only holds a single shared lock. +If the attempt succeeds +.Fn rw_try_upgrade +will return a non-zero value, +and the current thread will hold an exclusive lock. +If the attempt fails +.Fn rw_try_upgrade +will return zero, +and the current thread will still hold a shared lock. +.It Fn rw_downgrade "struct rwlock *rw" +Convert an exclusive lock into a single shared lock. +The current thread must hold an exclusive lock of +.Fa rw . +.It Fn rw_sleep "void *chan" "struct rwlock *rw" "int priority" "const char *wmesg" "int timo" +Atomically release +.Fa rw +while waiting for an event. +For more details on the parameters to this function, +see +.Xr sleep 9 . +.It Fn rw_initialized "struct rwlock *rw" +This function returns non-zero if +.Fa rw +has been initialized, and zero otherwise. +.It Fn rw_destroy "struct rwlock *rw" +This functions destroys a lock previously initialized with +.Fn rw_init . +The +.Fa rw +lock must be unlocked. +.It Fn rw_wowned "struct rwlock *rw" +This function returns a non-zero value if the current thread owns an +exclusive lock on +.Fa rw . +.It Fn rw_assert "struct rwlock *rw" "int what" +This function allows assertions specified in +.Fa what +to be made about +.Fa rw . +If the assertions are not true and the kernel is compiled +with +.Cd "options INVARIANTS" +and +.Cd "options INVARIANT_SUPPORT" , +the kernel will panic. +Currently the following assertions are supported: +.Bl -tag -width ".Dv RA_UNLOCKED" +.It Dv RA_LOCKED +Assert that current thread holds either a shared or exclusive lock +of +.Fa rw . +.It Dv RA_RLOCKED +Assert that current thread holds a shared lock of +.Fa rw . +.It Dv RA_WLOCKED +Assert that current thread holds an exclusive lock of +.Fa rw . +.It Dv RA_UNLOCKED +Assert that current thread holds neither a shared nor exclusive lock of +.Fa rw . +.El +.El +.Sh SEE ALSO +.Xr locking 9 , +.Xr mutex 9 , +.Xr panic 9 , +.Xr sema 9 , +.Xr sx 9 +.Sh HISTORY +These +functions appeared in +.Fx 7.0 . +.Sh AUTHORS +.An -nosplit +The +.Nm +facility was written by +.An "John Baldwin" . +This manual page was written by +.An "Gleb Smirnoff" . +.Sh BUGS +If +.Dv WITNESS +is not included in the kernel, +then it is impossible to assert that the current thread does or does not +hold a read lock. +In the +.Pf non- Dv WITNESS +case, the +.Dv RA_LOCKED +and +.Dv RA_RLOCKED +assertions merely check that some thread holds a read lock. +.Pp +Reader/writer is a bit of an awkward name. +An +.Nm +can also be called a +.Dq Robert Watson +lock if desired. Index: vm_page_wire.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_wire.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_wire.9 -L share/man/man9/vm_page_wire.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_wire.9 +++ share/man/man9/vm_page_wire.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_wire.9,v 1.3 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 13, 2001 .Dt VM_PAGE_WIRE 9 --- /dev/null +++ share/man/man9/usbdi.9 @@ -0,0 +1,1253 @@ +.\" +.\" Copyright (c) 2005 Ian Dowse +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/usbdi.9,v 1.2 2006/12/14 14:33:13 mpp Exp $ +.Dd December 30, 2005 +.Os +.Dt USBDI 9 +.Sh NAME +.Nm usb_detach_wait , +.Nm usb_detach_wakeup , +.Nm usb_find_desc , +.Nm usbd_abort_default_pipe , +.Nm usbd_abort_pipe , +.Nm usbd_alloc_buffer , +.Nm usbd_alloc_xfer , +.Nm usbd_bulk_transfer , +.Nm usbd_clear_endpoint_stall , +.Nm usbd_clear_endpoint_stall_async , +.Nm usbd_clear_endpoint_toggle , +.Nm usbd_close_pipe , +.Nm usbd_device2interface_handle , +.Nm usbd_devinfo , +.Nm usbd_do_request , +.Nm usbd_do_request_async , +.Nm usbd_do_request_flags , +.Nm usbd_do_request_flags_pipe , +.Nm usbd_dopoll , +.Nm usbd_endpoint_count , +.Nm usbd_errstr , +.Nm usbd_fill_deviceinfo , +.Nm usbd_find_edesc , +.Nm usbd_find_idesc , +.Nm usbd_free_buffer , +.Nm usbd_free_xfer , +.Nm usbd_get_buffer , +.Nm usbd_get_config , +.Nm usbd_get_config_desc , +.Nm usbd_get_config_desc_full , +.Nm usbd_get_config_descriptor , +.Nm usbd_get_device_descriptor , +.Nm usbd_get_endpoint_descriptor , +.Nm usbd_get_interface_altindex , +.Nm usbd_get_interface_descriptor , +.Nm usbd_get_no_alts , +.Nm usbd_get_quirks , +.Nm usbd_get_speed , +.Nm usbd_get_string , +.Nm usbd_get_string_desc , +.Nm usbd_get_xfer_status , +.Nm usbd_interface2device_handle , +.Nm usbd_interface2endpoint_descriptor , +.Nm usbd_interface_count , +.Nm usbd_intr_transfer , +.Nm usbd_open_pipe , +.Nm usbd_open_pipe_intr , +.Nm usbd_pipe2device_handle , +.Nm usbd_ratecheck , +.Nm usbd_set_config_index , +.Nm usbd_set_config_no , +.Nm usbd_set_interface , +.Nm usbd_set_polling , +.Nm usbd_setup_default_xfer , +.Nm usbd_setup_isoc_xfer , +.Nm usbd_setup_xfer , +.Nm usbd_sync_transfer , +.Nm usbd_transfer +.Nd Universal Serial Bus driver programming interface +.Sh SYNOPSIS +.In dev/usb/usb.h +.In dev/usb/usbdi.h +.In dev/usb/usbdi_util.h +.Pp +.Ft void +.Fn usb_detach_wait "device_ptr_t dv" +.Ft void +.Fn usb_detach_wakeup "device_ptr_t dv" +.Ft "const usb_descriptor_t *" +.Fn usb_find_desc "usbd_device_handle dev" "int type" "int subtype" +.Ft usbd_status +.Fn usbd_abort_default_pipe "usbd_device_handle dev" +.Ft usbd_status +.Fn usbd_abort_pipe "usbd_pipe_handle pipe" +.Ft "void *" +.Fn usbd_alloc_buffer "usbd_xfer_handle xfer" "u_int32_t size" +.Ft usbd_xfer_handle +.Fn usbd_alloc_xfer "usbd_device_handle dev" +.Ft usbd_status +.Fo usbd_bulk_transfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "u_int16_t flags" +.Fa "u_int32_t timeout" +.Fa "void *buf" +.Fa "u_int32_t *size" +.Fa "char *lbl" +.Fc +.Ft usbd_status +.Fn usbd_clear_endpoint_stall "usbd_pipe_handle pipe" +.Ft usbd_status +.Fn usbd_clear_endpoint_stall_async "usbd_pipe_handle" +.Ft void +.Fn usbd_clear_endpoint_toggle "usbd_pipe_handle pipe" +.Ft usbd_status +.Fn usbd_close_pipe "usbd_pipe_handle pipe" +.Ft usbd_status +.Fo usbd_device2interface_handle +.Fa "usbd_device_handle dev" +.Fa "u_int8_t ifaceno" +.Fa "usbd_interface_handle *iface" +.Fc +.Ft void +.Fn usbd_devinfo "usbd_device_handle dev" "int showclass" "char *cp" +.Ft usbd_status +.Fo usbd_do_request +.Fa "usbd_device_handle dev" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fc +.Ft usbd_status +.Fo usbd_do_request_async +.Fa "usbd_device_handle dev" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fc +.Ft usbd_status +.Fo usbd_do_request_flags +.Fa "usbd_device_handle dev" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fa "u_int16_t flags" +.Fa "int *actlen" +.Fa "u_int32_t timo" +.Fc +.Ft usbd_status +.Fo usbd_do_request_flags_pipe +.Fa "usbd_device_handle dev" +.Fa "usbd_pipe_handle pipe" +.Fa "usb_device_request_t *req" +.Fa "void *data" +.Fa "u_int16_t flags" +.Fa "int *actlen" +.Fa "u_int32_t timeout" +.Fc +.Ft void +.Fn usbd_dopoll "usbd_interface_handle iface" +.Ft usbd_status +.Fn usbd_endpoint_count "usbd_interface_handle iface" "u_int8_t *count" +.Ft "const char *" +.Fn usbd_errstr "usbd_status err" +.Ft void +.Fo usbd_fill_deviceinfo +.Fa "usbd_device_handle dev" +.Fa "struct usb_device_info *di" +.Fa "int usedev" +.Fc +.Ft "usb_endpoint_descriptor_t *" +.Fo usbd_find_edesc +.Fa "usb_config_descriptor_t *cd" +.Fa "int ifaceidx" +.Fa "int altidx" +.Fa "int endptidx" +.Fc +.Ft "usb_interface_descriptor_t *" +.Fn usbd_find_idesc "usb_config_descriptor_t *cd" "int ifaceidx" "int altidx" +.Ft void +.Fn usbd_free_buffer "usbd_xfer_handle xfer" +.Ft usbd_status +.Fn usbd_free_xfer "usbd_xfer_handle xfer" +.Ft "void *" +.Fn usbd_get_buffer "usbd_xfer_handle xfer" +.Ft usbd_status +.Fn usbd_get_config "usbd_device_handle dev" "u_int8_t *conf" +.Ft usbd_status +.Fo usbd_get_config_desc +.Fa "usbd_device_handle dev" +.Fa "int confidx" +.Fa "usb_config_descriptor_t *d" +.Fc +.Ft usbd_status +.Fo usbd_get_config_desc_full +.Fa "usbd_device_handle dev" +.Fa "int conf" +.Fa "void *d" +.Fa "int size" +.Fc +.Ft "usb_config_descriptor_t *" +.Fn usbd_get_config_descriptor "usbd_device_handle dev" +.Ft "usb_device_descriptor_t *" +.Fn usbd_get_device_descriptor "usbd_device_handle dev" +.Ft "usb_endpoint_descriptor_t *" +.Fo usbd_get_endpoint_descriptor +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t address" +.Fc +.Ft int +.Fn usbd_get_interface_altindex "usbd_interface_handle iface" +.Ft "usb_interface_descriptor_t *" +.Fn usbd_get_interface_descriptor "usbd_interface_handle iface" +.Ft int +.Fn usbd_get_no_alts "usb_config_descriptor_t *cdesc" "int ifaceno" +.Ft "const struct usbd_quirks *" +.Fn usbd_get_quirks "usbd_device_handle dev" +.Ft int +.Fn usbd_get_speed "usbd_device_handle dev" +.Ft usbd_status +.Fn usbd_get_string "usbd_device_handle dev" "int si" "char *buf" +.Ft usbd_status +.Fo usbd_get_string_desc +.Fa "usbd_device_handle dev" +.Fa "int sindex" +.Fa "int langid" +.Fa "usb_string_descriptor_t *sdesc" +.Fa "int *sizep" +.Fc +.Ft void +.Fo usbd_get_xfer_status +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_private_handle *priv" +.Fa "void **buffer" +.Fa "u_int32_t *count" +.Fa "usbd_status *status" +.Fc +.Ft void +.Fo usbd_interface2device_handle +.Fa "usbd_interface_handle iface" +.Fa "usbd_device_handle *dev" +.Fc +.Ft "usb_endpoint_descriptor_t *" +.Fo usbd_interface2endpoint_descriptor +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t index" +.Fc +.Ft usbd_status +.Fn usbd_interface_count "usbd_device_handle dev" "u_int8_t *count" +.Ft usbd_status +.Fo usbd_intr_transfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "u_int16_t flags" +.Fa "u_int32_t timeout" +.Fa "void *buf" +.Fa "u_int32_t *size" +.Fa "char *lbl" +.Fc +.Ft usbd_status +.Fo usbd_open_pipe +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t address" +.Fa "u_int8_t flags" +.Fa "usbd_pipe_handle *pipe" +.Fc +.Ft usbd_status +.Fo usbd_open_pipe_intr +.Fa "usbd_interface_handle iface" +.Fa "u_int8_t address" +.Fa "u_int8_t flags" +.Fa "usbd_pipe_handle *pipe" +.Fa "usbd_private_handle priv" +.Fa "void *buffer" +.Fa "u_int32_t len" +.Fa "usbd_callback cb" +.Fa "int ival" +.Fc +.Ft usbd_device_handle +.Fn usbd_pipe2device_handle "usbd_pipe_handle pipe" +.Ft int +.Fn usbd_ratecheck "struct timeval *last" +.Ft usbd_status +.Fn usbd_set_config_index "usbd_device_handle dev" "int index" "int msg" +.Ft usbd_status +.Fn usbd_set_config_no "usbd_device_handle dev" "int no" "int msg" +.Ft usbd_status +.Fn usbd_set_interface "usbd_interface_handle iface" "int altidx" +.Ft void +.Fn usbd_set_polling "usbd_device_handle dev" "int on" +.Ft void +.Fo usbd_setup_default_xfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_device_handle dev" +.Fa "usbd_private_handle priv" +.Fa "u_int32_t timeout" +.Fa "usb_device_request_t *req" +.Fa "void *buffer" +.Fa "u_int32_t length" +.Fa "u_int16_t flags" +.Fa "usbd_callback callback" +.Fc +.Ft void +.Fo usbd_setup_isoc_xfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "usbd_private_handle priv" +.Fa "u_int16_t *frlengths" +.Fa "u_int32_t nframes" +.Fa "u_int16_t flags" +.Fa "usbd_callback callback" +.Fc +.Ft void +.Fo usbd_setup_xfer +.Fa "usbd_xfer_handle xfer" +.Fa "usbd_pipe_handle pipe" +.Fa "usbd_private_handle priv" +.Fa "void *buffer" +.Fa "u_int32_t length" +.Fa "u_int16_t flags" +.Fa "u_int32_t timeout" +.Fa "usbd_callback callback" +.Fc +.Ft usbd_status +.Fn usbd_sync_transfer "usbd_xfer_handle xfer" +.Ft usbd_status +.Fn usbd_transfer "usbd_xfer_handle xfer" +.Sh DESCRIPTION +The Universal Serial Bus (USB) driver programming interface provides +USB peripheral drivers with a host controller independent API for +controlling and communicating with USB peripherals. +.Pp +Typically, drivers will first use some combination of the functions +.Fn usbd_set_config_no , +.Fn usbd_get_config_descriptor , +.Fn usbd_set_interface , +.Fn usbd_get_interface_descriptor , +.Fn usbd_device2interface_handle , +.Fn usbd_endpoint_count +and +.Fn usbd_interface2endpoint_descriptor +to query the device's properties and prepare it for use. +Drivers can then perform requests on the USB control pipe using +.Fn usbd_do_request , +they can open pipes using the functions +.Fn usbd_open_pipe +and +.Fn usbd_open_pipe_intr , +and perform transfers over these pipes using +.Fn usbd_alloc_xfer , +.Fn usbd_setup_xfer +and +.Fn usbd_transfer . +Finally, the functions +.Fn usbd_abort_pipe , +.Fn usbd_close_pipe +and +.Fn usbd_free_xfer +are used to cancel outstanding transfers, close open pipes and deallocate +transfer structures. +.Pp +The +.Fn usbd_get_device_descriptor +function returns a pointer to the USB device descriptor for +.Fa dev . +See +.Sx "USB Descriptors" +below for information about the USB device descriptor. +.Pp +The +.Fn usbd_get_config_desc +function retrieves the specified configuration descriptor from the device. +The +.Fa confidx +parameter specifies the configuration descriptor index, which must be less +than the +.Fa bNumConfigurations +value in the device descriptor. +The function +.Fn usbd_get_config_desc_full +retrieves a full configuration descriptor, which has all related interface +and endpoint descriptors appended to a normal configuration descriptor. +The parameter +.Fa d +should point to memory that is at least +.Fa size +bytes in length, and this should be at least as long as the +.Fa wTotalLength +value from the configuration descriptor. +See +.Sx "USB Descriptors" +below for information about the USB configuration descriptor. +.Pp +The +.Fn usbd_get_config +function retrieves the current configuration number from the device, i.e.\& +the +.Fa bConfigurationValue +value from the configuration that is active. +If the device is unconfigured then +.Dv USB_UNCONFIG_NO +is returned. +The current configuration can be changed by calling either +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +The difference between these functions is that +.Fn usbd_set_config_index +accepts a configuration index number that is less than the +.Fa bNumConfigurations +value from the device descriptor, whereas +.Fn usbd_set_config_no +requires the +.Fa bConfigurationValue +value of the desired configuration to be provided instead. +To unconfigure the device, supply a configuration index of +.Dv USB_UNCONFIG_INDEX +to +.Fn usbd_set_config_index , +or else specify a configuration number of +.Dv USB_UNCONFIG_NO +to +.Fn usbd_set_config_no . +.Pp +The +.Fn usbd_get_config_descriptor +function returns a pointer to an in-memory copy of the full configuration +descriptor of the configuration that is currently active. +The returned pointer remains valid until the device configuration +is changed using +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +If the device is unconfigured then +.Dv NULL +is returned instead. +.Pp +The function +.Fn usbd_interface_count +returns the number of interfaces available in the current device +configuration. +The +.Fn usbd_get_no_alts +function determines the number of alternate interfaces in a full +configuration descriptor by counting the interface descriptors with +.Fa bInterfaceNumber +equal to +.Fa ifaceno +(the count includes alternate index zero). +The +.Fn usbd_find_idesc +function locates an interface descriptor within a full configuration +descriptor. +The +.Fa ifaceidx +parameter specifies the interface index number, which should be less than +the number of interfaces in the configuration descriptor (i.e.\& the value +returned by +.Fn usbd_interface_count +or the +.Fa bNumInterface +field from the configuration descriptor). +An alternate interface can be specified using a non-zero +.Fa altidx , +which should be less than the value returned by +.Fn usbd_get_no_alts . +The return value is a pointer to the requested interface descriptor +within the full configuration descriptor, or +.Dv NULL +if the specified interface descriptor does not exist. +Note that the +.Fa altidx +parameter specifies the alternate setting by index number starting +at zero; it is not the alternate setting number defined in the +interface descriptor. +.Pp +The function +.Fn usbd_find_edesc +locates an endpoint descriptor within a full configuration descriptor. +The +.Fa ifaceidx +and +.Fa altidx +parameters are the same as described for +.Fn usbd_find_idesc , +and the +.Fa endptidx +parameter is an endpoint index number that should be less than the +.Fa bNumEndpoints +field in the interface descriptor. +The return value is a pointer to the requested endpoint descriptor +within the full configuration descriptor, or +.Dv NULL +if the specified endpoint descriptor does not exist. +Note that the +.Fa altidx +and +.Fa endptidx +parameters are index numbers starting at zero; they are not the +alternate setting and endpoint address defined in the descriptors. +.Pp +The +.Fn usbd_get_speed +function returns the device speed. +This can be +.Dv USB_SPEED_LOW , +.Dv USB_SPEED_FULL +or +.Dv USB_SPEED_HIGH . +.Pp +USB devices optionally support string descriptors, which can be +retrieved using the +.Fn usbd_get_string +or +.Fn usbd_get_string_desc +functions. +Device, configuration and interface descriptors reference strings by +an index number that can be supplied to these functions. +The +.Fn usbd_get_string +function should be used unless a non-default language is required. +It requires that +.Fa buf +points to a buffer of at least +.Dv USB_MAX_STRING_LEN +bytes in size. +The +.Fa si +parameter specified which string to retrieve. +.Pp +The +.Fn usb_find_desc +function searches through the in-memory full configuration descriptor +for the active configuration and finds the first descriptor that has a +.Fa bDescriptorType +equal to +.Fa type , +and if +.Fa subtype +is not equal to +.Dv USBD_SUBTYPE_ANY , +the descriptor must also have a +.Fa bDescriptorSubtype +equal to +.Fa subtype . +If found, then a pointer to the descriptor is returned. +Otherwise, +.Fn usb_find_desc +returns +.Dv NULL . +The returned pointer is valid until the device configuration is changed using +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +.Pp +The USB driver interface uses opaque interface handles to refer to +configuration interfaces. +These handles remain valid until the device configuration is changed using +.Fn usbd_set_config_index +or +.Fn usbd_set_config_no . +The +.Fn usbd_device2interface_handle +function retrieves an interface handle. +The +.Fa ifaceno +parameter is an interface index number starting at zero. +If the device is configured and the specified interface exists, then +.Dv USBD_NORMAL_COMPLETION +is returned and the interface handle is stored in +.Fa *iface . +Otherwise an error code is returned and +.Fa *iface +is not changed. +The +.Fn usbd_interface2device_handle +function retrieves the device handle from an interface handle. +This is just for convenience to save passing around the device +handle as well as the interface handle. +The +.Fn usbd_set_interface +function changes the alternate setting number for an interface to +the alternate setting identified by the zero-based index number +.Fa altidx . +This operation invalidates any existing endpoints on this +interface and their descriptors. +The +.Fn usbd_get_interface_altindex +function returns the current alternative setting index as was +specified when calling +.Fn usbd_set_interface . +The +.Fn usbd_endpoint_count +function retrieves the number of endpoints associated with the +specified interface. +The +.Fn usbd_interface2endpoint_descriptor +function returns a pointer to an in-memory endpoint descriptor for +the endpoint that has an index number of +.Fa index . +This pointer remains valid until the configuration or alternate setting +number are changed. +The function +.Fn usbd_get_endpoint_descriptor +is like +.Fn usbd_interface2endpoint_descriptor +but it accepts a +.Fa bEndpointAddress +address value instead of an index. +.Pp +The +.Fn usbd_fill_deviceinfo +function fills out a +.Vt usb_device_info +structure with information about the device. +The vendor and product names come from the device itself, falling back to +a table lookup or just providing the IDs in hexadecimal. +If +.Fa usedev +is zero then +.Fn usbd_fill_deviceinfo +will not attempt to retrieve the vendor and product names from the +device. +The usb_device_info structure is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +struct usb_device_info { + u_int8_t udi_bus; + u_int8_t udi_addr; /* device address */ + usb_event_cookie_t udi_cookie; + char udi_product[USB_MAX_STRING_LEN]; + char udi_vendor[USB_MAX_STRING_LEN]; + char udi_release[8]; + u_int16_t udi_productNo; + u_int16_t udi_vendorNo; + u_int16_t udi_releaseNo; + u_int8_t udi_class; + u_int8_t udi_subclass; + u_int8_t udi_protocol; + u_int8_t udi_config; + u_int8_t udi_speed; +#define USB_SPEED_LOW 1 +#define USB_SPEED_FULL 2 +#define USB_SPEED_HIGH 3 + int udi_power; /* power consumption in mA */ + int udi_nports; + char udi_devnames[USB_MAX_DEVNAMES][USB_MAX_DEVNAMELEN]; + /* hub only: addresses of devices on ports */ + u_int8_t udi_ports[16]; +#define USB_PORT_ENABLED 0xff +#define USB_PORT_SUSPENDED 0xfe +#define USB_PORT_POWERED 0xfd +} +.Ed +.Pp +The +.Fn usbd_devinfo +function generates a string description of the USB device. +The +.Fa cp +argument should point to a 1024-byte buffer (XXX the maximum length +is approximately 320 chars, but there is no sanity checking and everything uses +1024-character buffers). +Device class information is included if the +.Fa showclass +parameter is non-zero. +.Pp +The +.Fn usbd_get_quirks +function returns information from a table of devices that require +special workarounds in order to function correctly. +The returned structure is defined in +.In dev/usb/usb_quirks.h +as follows: +.Bd -literal +struct usbd_quirks { + u_int32_t uq_flags; /* Device problems */ +}; +.Ed +.Pp +See +.In dev/usb/usb_quirks.h +for a list of all currently defined quirks. +.Pp +USB control requests are performed via +.Vt usb_device_request_t +structures, defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bmRequestType; + uByte bRequest; + uWord wValue; + uWord wIndex; + uWord wLength; +} UPACKED usb_device_request_t; +.Ed +.Pp +The +.Fn usbd_do_request +function performs a single request synchronously. +The +.Fa req +parameter should point to a properly initialized +.Vt usb_device_request_t , +and when the +.Fa wLength +field is non-zero, +.Fa data +should point at a buffer that is at least +.Fa wLength +bytes in length. +The request timeout is set to 5 seconds, so the operation will fail +with +.Er USBD_TIMEOUT +if the device does not respond within that time. +The +.Fn usbd_do_request_async +function is like +.Fn usbd_do_request , +but it does not wait for the request to complete before returning. +This routine does not block so it can be used from contexts where +sleeping is not allowed. +Note that there is no notification mechanism to report when the +operation completed nor is there a way to determine whether the +request succeeded, so this function is of limited use. +See +.Fn usbd_setup_default_xfer +and +.Fn usbd_transfer +for a way to invoke an asynchronous callback upon completion of +a control request. +The +.Fn usbd_do_request_flags +function is like +.Fn usbd_do_request , +but additional flags can be specified, the timeout is configurable, +and the actual number of bytes transferred is made available to the +caller. +The +.Fn usbd_do_request_flags_pipe +function uses a specified pipe instead of the default pipe. +.Pp +The function +.Fn usbd_open_pipe +creates a pipe connected to a specified endpoint on a specified interface. +The parameter +.Fa address +should be the +.Fa bEndpointAddress +value from one of this interface's endpoint descriptors. +If +.Fa flags +contains +.Dv USBD_EXCLUSIVE_USE +then the operation will only succeed if there are no open pipes +already connected to the specified endpoint. +The +.Fn usbd_open_pipe_intr +function creates an interrupt pipe connected to the specified endpoint. +The parameter +.Fa address +should be the +.Fa bEndpointAddress +value from one of this interface's endpoint descriptors. +The +.Fa flags +parameter is passed to +.Fn usbd_setup_xfer . +The +.Fa buffer +and +.Fa len +parameters define a buffer that is to be used for the interrupt transfers. +The callback to be invoked each time a transfer completes is specified by +.Fa cb , +and +.Fa priv +is an argument to be passed to the callback function. +The +.Fa ival +parameter specifies the maximum acceptable interval between transfers; +in practice the transfers may occur more frequently. +The function +.Fn usbd_pipe2device_handle +returns the device associated with the specified +.Fa pipe . +.Pp +The +.Fn usbd_abort_pipe +function aborts all active or waiting transfers on the specified pipe. +Each transfer is aborted with a +.Dv USBD_CANCELLED +status; callback routines must detect this error code to ensure that +they do not attempt to initiate a new transfer in response to one being +aborted. +This routine blocks while it is waiting for the hardware to complete +processing of aborted transfers, so it is only safe to call it in +contexts where sleeping is allowed. +The function +.Fn usbd_abort_default_pipe +aborts all active or waiting transfers on the default pipe. +Like +.Fn usbd_abort_pipe , +it blocks waiting for the hardware processing to complete. +.Pp +When a pipe has no active or waiting transfers, the pipe may be closed +using the +.Fn usbd_close_pipe +function. +Once a pipe is closed, its pipe handle becomes invalid and may no longer +be used. +.Pp +USB transfer handles are allocated using the function +.Fn usbd_alloc_xfer +and may be freed using +.Fn usbd_free_xfer . +.Pp +The function +.Fn usbd_setup_xfer +initializes a transfer handle with the details of a transfer to or from +a USB device. +The +.Fa xfer +parameter specifies the transfer handle to initialize, +.Fa pipe +specifies the pipe on which the transfer is to take place, and +.Fa priv +is an argument that will be passed to callback function. +The arguments +.Fa buffer +and +.Fa length +define the data buffer for the transfer. +If +.Fa length +is zero then the +.Fa buffer +may be +.Dv NULL . +The +.Fa flags +parameter may contain the following flags: +.Bl -tag -width ".Dv USBD_FORCE_SHORT_XFER" +.It Dv USBD_NO_COPY +This is used in association with +.Fn usbd_alloc_buffer +and +.Fn usbd_free_buffer +to use a dedicated DMA-capable buffer for the transfer. +.It Dv USBD_SYNCHRONOUS +Wait for the transfer to compete in +.Fn usbd_transfer . +.It Dv USBD_SHORT_XFER_OK +Permit transfers shorter than the requested data length. +.It Dv USBD_FORCE_SHORT_XFER +Force a short transfer at the end of a write operation to let the +device know that the transfer has ended. +.El +.Pp +The +.Fa timeout +parameter specifies a timeout for the transfer in milliseconds. +A value of +.Dv USBD_NO_TIMEOUT +indicates that no timeout should be configured. +The parameter +.Fa callback +specifies the function to call when the transfer completes. +Note that +.Fn usbd_setup_xfer +does not actually initiate the transfer. +The +.Fn usbd_setup_default_xfer +initializes a control transfer for the default pipe. +The +.Fa req +parameter should point at a completed +.Vt usb_device_request_t +structure. +The function +.Fa usbd_setup_isoc_xfer +initializes a transfer for an isochronous pipe. +.Pp +The function +.Fn usbd_transfer +initiates a transfer. +Normally it returns +.Dv USBD_IN_PROGRESS +to indicate that the transfer has been queued. +If the USB stack is operating in polling mode, or if the transfer +is synchronous, then +.Dv USBD_NORMAL_COMPLETION +may be returned. +Other return values indicate that the transfer could not be +initiated due to an error. +The +.Fn usbd_sync_transfer +function executes a transfer synchronously. +It will sleep waiting for the transfer to complete and then return +the transfer status. +Note that if the transfer has a callback routine, this will be +invoked before +.Fn usbd_sync_transfer +returns. +.Pp +The +.Fn usbd_intr_transfer +and +.Fn usbd_bulk_transfer +functions set up a transfer and wait synchronously for it to complete +but they allows signals to interrupt the wait. +They returns +.Dv USBD_INTERRUPTED +if the transfer was interrupted by a signal. +XXX these two functions are identical apart from their names. +.Pp +The function +.Fn usbd_get_xfer_status +retrieves various information from a completed transfer. +If the +.Fa priv +parameter is not NULL then the callback private argument is +stored in +.Fa *priv . +If +.Fa buffer +is not NULL then the transfer buffer pointer is stored in +.Fa *buffer . +The actual number of bytes transferred is stored in +.Fa *count +if +.Fa count is not NULL. +Finally, the transfer status is stored in +.Fa *status +if +.Fa status +is not NULL. +.Pp +The +.Fn usbd_clear_endpoint_stall +function clears an endpoint stall condition synchronously, i.e.\& +it sleeps waiting for the stall clear request to complete. +The function +.Fn usbd_clear_endpoint_stall_async +performs the same function asynchronously, but it provides no +way to determine when the request completed, or whether it was +successful. +The +.Fn usbd_clear_endpoint_toggle +function instructs the host controller driver to reset the toggle bit +on a pipe. +This is used when manually clearing an endpoint stall using a +control pipe request, in order to ensure that the host controller +driver and the USB device restart with the same toggle value. +.Pp +Normally the USB subsystem maps and copies data to and from +DMA-capable memory each time a transfer is performed. +The function +.Fn usbd_alloc_buffer +allocates a permanent DMA-capable buffer associated with the +transfer to avoid this overhead. +The return value is the virtual address of the buffer. +Any time that +.Fn usbd_setup_xfer +is called on the transfer with the +.Dv USBD_NO_COPY +flag enabled, the allocated buffer will be used directly and +the +.Fa buffer +argument passed to +.Fn usbd_setup_xfer +will be ignored. +The +.Fn usbd_get_buffer +function returns a pointer to the virtual address of a buffer previously +allocated by +.Fn usbd_alloc_buffer . +Finally, +.Fn usbd_free_buffer +deallocates the buffer. +.Pp +The +.Fn usbd_errstr +function converts a status code into a string for display. +.Pp +The function +.Fn usbd_set_polling +enables or disables polling mode. +In polling mode, all operations will busy-wait for the device to +respond, so its use is effectively limited to boot time and kernel +debuggers. +It is important to match up calls that enable and disable polling +mode, because the implementation just increments a polling reference +count when +.Fa on +is non-zero and decrements it when +.Fa on +is zero. +The +.Fn usbd_dopoll +causes the host controller driver to poll for any activity. +This should only be used when polling mode is enabled. +.Pp +The +.Fn usbd_ratecheck +function is used to limit the rate at which error messages are +printed to approximately once per second. +The +.Fa last +argument should point at a persistent +.Vt "struct timeval" . +A value of 1 will be returned if a message should be printed, but if +.Fn usbd_ratecheck +has already been called with the same +.Vt "struct timeval" +parameter in the last second then 0 is returned and the error message +should be suppressed. +.Pp +The functions +.Fn usb_detach_wait +and +.Fn usb_detach_wakeup +are used to wait for references to drain before completing the +detachment of a device. +The +.Fn usb_detach_wait +function will wait up to 60 seconds to receive a signal from +.Fn usb_detach_wait . +.Ss "USB Descriptors" +The USB specification defines a number of standard descriptors by +which USB devices report their attributes. +These descriptors are fixed-format structures that all USB devices +make available through USB control pipe requests. +.Pp +Every USB device has exactly one USB device descriptor. +The USB subsystem retrieves this automatically when a device is +attached, and a copy of the descriptor is kept in memory. +The +.Fn usbd_get_device_descriptor +function returns a pointer to the descriptor. +The device descriptor structure is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uWord bcdUSB; +#define UD_USB_2_0 0x0200 +#define UD_IS_USB2(d) (UGETW((d)->bcdUSB) >= UD_USB_2_0) + uByte bDeviceClass; + uByte bDeviceSubClass; + uByte bDeviceProtocol; + uByte bMaxPacketSize; + /* The fields below are not part of the initial descriptor. */ + uWord idVendor; + uWord idProduct; + uWord bcdDevice; + uByte iManufacturer; + uByte iProduct; + uByte iSerialNumber; + uByte bNumConfigurations; +} UPACKED usb_device_descriptor_t; +#define USB_DEVICE_DESCRIPTOR_SIZE 18 +.Ed +.Pp +USB devices have at least one configuration descriptor. +The +.Fa bNumConfigurations +field of the device descriptor specifies the number of configuration +descriptors that a device supports. +The +.Fn usbd_get_config_desc +function retrieves a particular configuration descriptor from the device +and the +.Fn usbd_get_config_desc_full +function retrieves a full +.Fa wTotalLength +length configuration descriptor, which includes all related interface +and endpoint descriptors. +Only one configuration may be active at a time. +The +.Fn usbd_set_config_index +function activates a specified configuration. +The configuration descriptor structure is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uWord wTotalLength; + uByte bNumInterface; + uByte bConfigurationValue; + uByte iConfiguration; + uByte bmAttributes; +#define UC_BUS_POWERED 0x80 +#define UC_SELF_POWERED 0x40 +#define UC_REMOTE_WAKEUP 0x20 + uByte bMaxPower; /* max current in 2 mA units */ +#define UC_POWER_FACTOR 2 +} UPACKED usb_config_descriptor_t; +#define USB_CONFIG_DESCRIPTOR_SIZE 9 +.Ed +.Pp +Each device configuration provides one or more interfaces. +The +.Fa bNumInterface +field of the configuration descriptor specifies the number of +interfaces associated with a device configuration. +Interfaces are described by an interface descriptor, which is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uByte bInterfaceNumber; + uByte bAlternateSetting; + uByte bNumEndpoints; + uByte bInterfaceClass; + uByte bInterfaceSubClass; + uByte bInterfaceProtocol; + uByte iInterface; +} UPACKED usb_interface_descriptor_t; +#define USB_INTERFACE_DESCRIPTOR_SIZE 9 +.Ed +.Pp +Configurations may also have alternate interfaces with the same +.Fa bInterfaceNumber +but different +.Fa bAlternateSetting +values. +These alternate interface settings may be selected by passing a +non-zero +.Fa altidx +parameter to +.Fn usbd_set_interface . +.Pp +Interfaces have zero or more endpoints, and each endpoint has an +endpoint descriptor. +Note that endpoint zero, which is always present, does not have an +endpoint descriptor, and it is never included in the +.Fa bNumEndpoints +count of endpoints. +The endpoint descriptor is defined in +.In dev/usb/usb.h +as follows: +.Bd -literal +typedef struct { + uByte bLength; + uByte bDescriptorType; + uByte bEndpointAddress; +#define UE_GET_DIR(a) ((a) & 0x80) +#define UE_SET_DIR(a,d) ((a) | (((d)&1) << 7)) +#define UE_DIR_IN 0x80 +#define UE_DIR_OUT 0x00 +#define UE_ADDR 0x0f +#define UE_GET_ADDR(a) ((a) & UE_ADDR) + uByte bmAttributes; +#define UE_XFERTYPE 0x03 +#define UE_CONTROL 0x00 +#define UE_ISOCHRONOUS 0x01 +#define UE_BULK 0x02 +#define UE_INTERRUPT 0x03 +#define UE_GET_XFERTYPE(a) ((a) & UE_XFERTYPE) +#define UE_ISO_TYPE 0x0c +#define UE_ISO_ASYNC 0x04 +#define UE_ISO_ADAPT 0x08 +#define UE_ISO_SYNC 0x0c +#define UE_GET_ISO_TYPE(a) ((a) & UE_ISO_TYPE) + uWord wMaxPacketSize; + uByte bInterval; +} UPACKED usb_endpoint_descriptor_t; +#define USB_ENDPOINT_DESCRIPTOR_SIZE 7 +.Ed +.Sh RETURN VALUES +Many functions return a +.Vt usbd_status +type to indicate the outcome of the operation. +If the operation completed successfully then +.Dv USBD_NORMAL_COMPLETION +is returned. +Operations that have been started but not yet completed will return +.Dv USBD_IN_PROGRESS . +Other errors usually indicate a problem. +Error codes can be converted to strings using +.Fn usbd_errstr . +.Sh ERRORS +.Bl -tag -width ".Er USBD_PENDING_REQUESTS" +.It Bq Er USBD_PENDING_REQUESTS +A pipe could not be closed because there are active requests. +.It Bq Er USBD_NOT_STARTED +The transfer has not yet been started. +.It Bq Er USBD_INVAL +An invalid value was supplied. +.It Bq Er USBD_NOMEM +An attempt to allocate memory failed. +.It Bq Er USBD_CANCELLED +The transfer was aborted. +.It Bq Er USBD_BAD_ADDRESS +The specified endpoint address was not found. +.It Bq Er USBD_IN_USE +The endpoint is already in use, or the configuration cannot be changed +because some of its endpoints are in use. +.It Bq Er USBD_NO_ADDR +No free USB devices addresses were found to assign to the device. +.It Bq Er USBD_SET_ADDR_FAILED +The device address could not be set. +.It Bq Er USBD_NO_POWER +Insufficient power was available for the device. +.It Bq Er USBD_TOO_DEEP +Too many levels of chained hubs were found. +.It Bq Er USBD_IOERROR +There was an error communicating with the device. +.It Bq Er USBD_NOT_CONFIGURED +An operation that requires an active configuration was attempted while +the device was in an unconfigured state. +.It Bq Er USBD_TIMEOUT +A transfer timed out. +.It Bq Er USBD_SHORT_XFER +A transfer that disallowed short data lengths completed with less than +the requested length transferred. +.It Bq Er USBD_STALLED +A transfer failed because the pipe is stalled. +.It Bq Er USBD_INTERRUPTED +An interruptible operation caught a signal. +.El +.Sh SEE ALSO +.Xr usb 4 +.Sh HISTORY +The USB driver interface first appeared in +.Fx 3.0 . +.Sh AUTHORS +The USB driver was written by +.An Lennart Augustsson +for the +.Nx +project. +.Pp +.An -nosplit +This manual page was written by +.An Ian Dowse Aq iedowse at FreeBSD.org . Index: timeout.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/timeout.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/timeout.9 -L share/man/man9/timeout.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/timeout.9 +++ share/man/man9/timeout.9 @@ -34,7 +34,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/timeout.9,v 1.28.2.2 2005/12/05 20:07:33 jhb Exp $ +.\" $FreeBSD: src/share/man/man9/timeout.9,v 1.31 2005/12/01 19:16:35 jhb Exp $ .\" .Dd September 8, 2005 .Dt TIMEOUT 9 --- /dev/null +++ share/man/man9/config_intrhook.9 @@ -0,0 +1,105 @@ +.\" +.\" Copyright (C) 2006 M. Warner Losh . All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice(s), this list of conditions and the following disclaimer as +.\" the first lines of this file unmodified other than the possible +.\" addition of one or more copyright notices. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice(s), this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDER(S) ``AS IS'' AND ANY +.\" EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +.\" DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER(S) BE LIABLE FOR ANY +.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES +.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +.\" CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +.\" DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/config_intrhook.9,v 1.4 2006/12/14 14:33:13 mpp Exp $ +.\" +.Dd September 24, 2006 +.Dt CONFIG_INTRHOOK 9 +.Os +.Sh NAME +.Nm config_intrhook +.Nd schedule a function to be run after interrupts have been enabled, +but before root is mounted +.Sh SYNOPSIS +.In sys/kernel.h +.Ft int +.Fn config_intrhook_establish "struct intr_config_hook *hook" +.Ft void +.Fn config_intrhook_disestablish "struct intr_config_hook *hook" +.Sh DESCRIPTION +The +.Fn config_intrhook_establish +function schedules a function to be run after interrupts have been +enabled, but before root is mounted. +If the system has already passed this point in its initialization, +the function is called immediately. +.Pp +The +.Fn config_intrhook_disestablish +function removes the entry from the hook queue. +.Pp +Before root is mounted, all the previously established hooks are +run. +The boot process is then stalled until all handlers remove their hook +from the hook queue with +.Fn config_intrhook_disestablish . +The boot process then proceeds to attempt to mount the root file +system. +Any driver that can potentially provide devices they wish to be +mounted as root must use either this hook, or probe all these devices +in the initial probe. +Since interrupts are disabled during the probe process, many drivers +need a method to probe for devices with interrupts enabled. +.Pp +The requests are made with the +.Vt intr_config_hook +structure. +This structure is defined as follows: +.Bd -literal +struct intr_config_hook { + TAILQ_ENTRY(intr_config_hook) ich_links;/* Private */ + void (*ich_func)(void *arg); /* function to call */ + void *ich_arg; /* Argument to call */ +}; +.Ed +.Pp +Storage for the +.Vt intr_config_hook +structure must be provided by the driver. +It must be stable from just before the hook is established until +after the hook is disestablished. +.Pp +Specifically, hooks are run at +.Fn SI_SUB_INT_CONFIG_HOOKS , +which is immediately after the scheduler is started, +and just before the root file system device is discovered. +.Sh RETURN VALUES +A zero return value means the hook was successfully added to the queue +(with either deferred or immediate execution). +A non-zero return value means the hook could not be added to the queue +because it was already on the queue. +.Sh SEE ALSO +.Xr DEVICE_ATTACH 9 +.Sh HISTORY +These functions were introduced in +.Fx 3.0 +with the CAM subsystem, but are available for any driver to use. +.Sh AUTHORS +.An -nosplit +The functions were written by +.An Justin Gibbs Aq gibbs at FreeBSD.org . +This manual page was written by +.An M. Warner Losh Aq imp at FreeBSD.org . Index: vrele.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vrele.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vrele.9 -L share/man/man9/vrele.9 -u -r1.2 -r1.3 --- share/man/man9/vrele.9 +++ share/man/man9/vrele.9 @@ -27,7 +27,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vrele.9,v 1.12 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 1996 .Os Index: BUS_SETUP_INTR.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/BUS_SETUP_INTR.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/BUS_SETUP_INTR.9 -L share/man/man9/BUS_SETUP_INTR.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/BUS_SETUP_INTR.9 +++ share/man/man9/BUS_SETUP_INTR.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/BUS_SETUP_INTR.9,v 1.18 2005/01/06 17:11:56 keramida Exp $ +.\" $FreeBSD: src/share/man/man9/BUS_SETUP_INTR.9,v 1.20 2007/03/01 14:33:29 ru Exp $ .\" -.Dd January 6, 2005 +.Dd March 1, 2007 .Dt BUS_SETUP_INTR 9 .Os .Sh NAME @@ -37,11 +37,21 @@ .In sys/param.h .In sys/bus.h .Ft int -.Fn BUS_SETUP_INTR "device_t dev" "device_t child" "struct resource *irq" "int flags" "driver_intr_t *intr" "void *arg" "void **cookiep" +.Fo BUS_SETUP_INTR +.Fa "device_t dev" "device_t child" "struct resource *irq" "int flags" +.Fa "driver_filter_t *filter" "driver_intr_t *ithread" "void *arg" +.Fa "void **cookiep" +.Fc .Ft int -.Fn bus_setup_intr "device_t dev" "struct resource *r" "int flags" "driver_intr_t handler" "void *arg" "void **cookiep" +.Fo bus_setup_intr +.Fa "device_t dev" "struct resource *r" "int flags" +.Fa "driver_filter_t filter" "driver_intr_t ithread" "void *arg" +.Fa "void **cookiep" +.Fc .Ft int -.Fn BUS_TEARDOWN_INTR "device_t dev" "device_t child" "struct resource *irq" "void *cookiep" +.Fo BUS_TEARDOWN_INTR +.Fa "device_t dev" "device_t child" "struct resource *irq" "void *cookiep" +.Fc .Ft int .Fn bus_teardown_intr "device_t dev" "struct resource *r" "void *cookiep" .Sh DESCRIPTION @@ -61,11 +71,6 @@ .Fa flags also tell the interrupt handlers about certain device driver characteristics. -.Dv INTR_FAST -means the handler is for a timing-critical function. -Extra care is take to speed up these handlers. -Use of this implies -.Dv INTR_EXCL . .Dv INTR_EXCL marks the handler as being an exclusive handler for this interrupt. @@ -79,8 +84,16 @@ marks the interrupt as being a good source of entropy - this may be used by the entropy device .Pa /dev/random . -The handler -.Fa intr +.Pp +To define a time-critical handler (previously known as +.Dv INTR_FAST ) +that will not execute any potentially blocking operation, use the +.Fa filter +argument. +Otherwise, use the +.Fa ithread +argument. +The defined handler will be called with the value .Fa arg as its only argument. Index: thread_exit.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/thread_exit.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/thread_exit.9 -L share/man/man9/thread_exit.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/thread_exit.9 +++ share/man/man9/thread_exit.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/thread_exit.9,v 1.2 2002/12/09 14:29:34 ru Exp $ +.\" $FreeBSD: src/share/man/man9/thread_exit.9,v 1.3 2007/03/09 22:41:01 jhb Exp $ .\" .Dd July 5, 2002 .Dt THREAD_EXIT 9 @@ -58,6 +58,6 @@ mutex held. .Sh SEE ALSO .Xr mi_switch 9 , -.Xr msleep 9 , .Xr mutex 9 , -.Xr runqueue 9 +.Xr runqueue 9 , +.Xr sleep 9 Index: ithread.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ithread.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/ithread.9 -L share/man/man9/ithread.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/ithread.9 +++ share/man/man9/ithread.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ithread.9,v 1.11 2004/07/05 17:12:52 ru Exp $ +.\" $FreeBSD: src/share/man/man9/ithread.9,v 1.12 2006/08/25 19:04:42 pav Exp $ .\" -.Dd February 10, 2001 +.Dd August 25, 2006 .Dt ITHREAD 9 .Os .Sh NAME @@ -202,6 +202,12 @@ and .Dv INTR_ENTROPY flags are not valid for software interrupt handlers. +.Pp +It is not permitted to sleep in an interrupt thread; hence, any memory +or zone allocations in an interrupt thread should be specified with the +.Dv M_NOWAIT +flag set. +Any allocation errors must be handled thereafter. .Sh RETURN VALUES The .Fn ithread_add_handler , @@ -340,7 +346,9 @@ .El .Sh SEE ALSO .Xr kthread 9 , -.Xr swi 9 +.Xr malloc 9 , +.Xr swi 9 , +.Xr uma 9 .Sh HISTORY Interrupt threads and their corresponding API first appeared in .Fx 5.0 . --- /dev/null +++ share/man/man9/sysctl.9 @@ -0,0 +1,304 @@ +.\" +.\" Copyright (c) 2006 Robert N. M. Watson +.\" All rights reserved. +.\" +.\" Redistribution and use in source and binary forms, with or without +.\" modification, are permitted provided that the following conditions +.\" are met: +.\" 1. Redistributions of source code must retain the above copyright +.\" notice, this list of conditions and the following disclaimer. +.\" 2. Redistributions in binary form must reproduce the above copyright +.\" notice, this list of conditions and the following disclaimer in the +.\" documentation and/or other materials provided with the distribution. +.\" +.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND +.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE +.\" ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE +.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS +.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) +.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT +.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY +.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +.\" SUCH DAMAGE. +.\" +.\" $FreeBSD: src/share/man/man9/sysctl.9,v 1.8 2006/12/14 14:33:13 mpp Exp $ +.\" +.Dd November 23, 2006 +.Dt SYSCTL 9 +.Os +.Sh NAME +.Nm SYSCTL_DECL , +.Nm SYSCTL_INT , +.Nm SYSCTL_LONG , +.Nm SYSCTL_NODE , +.Nm SYSCTL_OPAQUE , +.Nm SYSCTL_PROC , +.Nm SYSCTL_STRING , +.Nm SYSCTL_STRUCT , +.Nm SYSCTL_UINT , +.Nm SYSCTL_ULONG , +.Nm SYSCTL_XINT , +.Nm SYSCTL_XLONG +.Nd Static sysctl declaration functions +.Sh SYNOPSIS +.In sys/types.h +.In sys/sysctl.h +.Fn SYSCTL_DECL name +.Fn SYSCTL_INT parent nbr name access ptr val descr +.Fn SYSCTL_LONG parent nbr name access ptr val descr +.Fn SYSCTL_NODE parent nbr name access handler descr +.Fn SYSCTL_OPAQUE parent nbr name access ptr len fmt descr +.Fn SYSCTL_PROC parent nbr name access ptr arg handler fmt descr +.Fn SYSCTL_STRING parent nbr name access arg len descr +.Fn SYSCTL_STRUCT parent nbr name access ptr type descr +.Fn SYSCTL_UINT parent nbr name access ptr val descr +.Fn SYSCTL_ULONG parent nbr name access ptr val descr +.Fn SYSCTL_XINT parent nbr name access ptr val descr +.Fn SYSCTL_XLONG parent nbr name access ptr val descr +.Sh DESCRIPTION +The +.Nm SYSCTL +kernel interfaces allow code to statically declare +.Xr sysctl 8 +MIB entries, which will be initialized when the kernel module containing the +declaration is initialized. +When the module is unloaded, the sysctl will be automatically destroyed. +.Pp +Sysctl nodes are created in a hierarchical tree, with all static nodes being +represented by named C data structures; in order to create a new node under +an existing node in the tree, the structure representing the desired parent +node must be declared in the current context using +.Fn SYSCTL_DECL . +.Pp +New nodes are declared using one of +.Fn SYSCTL_INT , +.Fn SYSCTL_LONG , +.Fn SYSCTL_NODE , +.Fn SYSCTL_OPAQUE , +.Fn SYSCTL_PROC , +.Fn SYSCTL_STRING , +.Fn SYSCTL_STRUCT , +.Fn SYSCTL_UINT , +.Fn SYSCTL_ULONG , +.Fn SYSCTL_XINT , +and +.Fn SYSCTL_XLONG . +Each macro accepts a parent name, as declared using +.Fn SYSCTL_DECL , +an OID number, typically +.Dv OID_AUTO , +a node name, a set of control and access flags, and a description. +Depending on the macro, a pointer to a variable supporting the MIB entry, a +size, a value, and a function pointer implementing the MIB entry may also be +present. +.Pp +For most of the above macros, declaring a type as part of the access flags is +not necessary \[em] however, when declaring a sysctl implemented by a function, +including a type in the access mask is required: +.Bl -tag -width ".Dv CTLTYPE_STRING" +.It Dv CTLTYPE_NODE +This is a node intended to be a parent for other nodes. +.It Dv CTLTYPE_INT +This is a signed integer. +.It Dv CTLTYPE_STRING +This is a nul-terminated string stored in a character array. +.It Dv CTLTYPE_QUAD +This is a 64-bit signed integer. +.It Dv CTLTYPE_OPAQUE +This is an opaque data structure. +.It Dv CTLTYPE_STRUCT +Alias for +.Dv CTLTYPE_OPAQUE. +.It Dv CTLTYPE_UINT +This is an unsigned integer. +.It Dv CTLTYPE_LONG +This is a signed long. +.It Dv CTLTYPE_ULONG +This is an unsigned long. +.El +.Pp +All sysctl types except for new node declarations require one or more flags +to be set indicating the read and write disposition of the sysctl: +.Bl -tag -width ".Dv CTLFLAG_ANYBODY" +.It Dv CTLFLAG_RD +This is a read-only sysctl. +.It Dv CTLFLAG_WR +This is a writable sysctl. +.It Dv CTLFLAG_RW +This sysctl is readable and writable. +.It Dv CTLFLAG_ANYBODY +Any user or process can write to this sysctl. +.It Dv CTLFLAG_SECURE +This sysctl can be written to only if the effective securelevel of the +process is \[<=] 0. +.It Dv CTLFLAG_PRISON +This sysctl can be written to by processes in +.Xr jail 2 . +.It Dv CTLFLAG_SKIP +When iterating the sysctl name space, do not list this sysctl. +.It Dv CTLFLAG_TUN +Also declare a system tunable with the same name to initialize this variable. +.It Dv CTLFLAG_RDTUN +Also declare a system tunable with the same name to initialize this variable; +however, the run-time variable is read-only. +.El +.Pp +When creating new sysctls, careful attention should be paid to the security +implications of the monitoring or management interface being created. +Most sysctls present in the kernel are read-only or writable only by the +superuser. +Sysctls exporting extensive information on system data structures and +operation, especially those implemented using procedures, will wish to +implement access control to limit the undesired exposure of information about +other processes, network connections, etc. +.Pp +The following top level sysctl name spaces are commonly used: +.Bl -tag -width ".Va regression" +.It Va compat +Compatibility layer information. +.It Va debug +Debugging information. +Various name spaces exist under +.Va debug . +.It Va hw +Hardware and device driver information. +.It Va kern +Kernel behavior tuning; generally deprecated in favor of more specific +name spaces. +.It Va machdep +Machine-dependent configuration parameters. +.It Va net +Network subsystem. +Various protocols have name spaces under +.Va net . +.It Va regression +Regression test configuration and information. +.It Va security +Security and security-policy configuration and information. +.It Va sysctl +Reserved name space for the implementation of sysctl. +.It Va user +Configuration settings relating to user application behavior. +Generally, configuring applications using kernel sysctls is discouraged. +.It Va vfs +Virtual file system configuration and information. +.It Va vm +Virtual memory subsystem configuration and information. +.El +.Sh EXAMPLES +Sample use of +.Fn SYSCTL_DECL +to declare the +.Va security +sysctl tree for use by new nodes: +.Bd -literal -offset indent +SYSCTL_DECL(_security); +.Ed +.Pp +Examples of integer, opaque, string, and procedure sysctls follow: +.Bd -literal -offset indent +/* + * Example of a constant integer value. Notice that the control + * flags are CTLFLAG_RD, the variable pointer is NULL, and the + * value is declared. + * If sysctl(8) should print this value in hex, use 'SYSCTL_XINT'. + */ +SYSCTL_INT(_debug_sizeof, OID_AUTO, bio, CTLFLAG_RD, NULL, + sizeof(struct bio), "sizeof(struct bio)"); + +/* + * Example of a variable integer value. Notice that the control + * flags are CTLFLAG_RW, the variable pointer is set, and the + * value is 0. + */ +static int doingcache = 1; /* 1 => enable the cache */ +SYSCTL_INT(_debug, OID_AUTO, vfscache, CTLFLAG_RW, &doingcache, 0, + "Enable name cache"); + +/* + * Example of a variable string value. Notice that the control + * flags are CTLFLAG_RW, that the variable pointer and string + * size are set. Unlike newer sysctls, this older sysctl uses a + * static oid number. + */ +char kernelname[MAXPATHLEN] = "/kernel"; /* XXX bloat */ +SYSCTL_STRING(_kern, KERN_BOOTFILE, bootfile, CTLFLAG_RW, + kernelname, sizeof(kernelname), "Name of kernel file booted"); + +/* + * Example of an opaque data type exported by sysctl. Notice that + * the variable pointer and size are provided, as well as a format + * string for sysctl(8). + */ +static l_fp pps_freq; /* scaled frequence offset (ns/s) */ +SYSCTL_OPAQUE(_kern_ntp_pll, OID_AUTO, pps_freq, CTLFLAG_RD, + &pps_freq, sizeof(pps_freq), "I", ""); + +/* + * Example of a procedure based sysctl exporting string + * information. Notice that the data type is declared, the NULL + * variable pointer and 0 size, the function pointer, and the + * format string for sysctl(8). + */ +SYSCTL_PROC(_kern_timecounter, OID_AUTO, hardware, CTLTYPE_STRING | + CTLFLAG_RW, NULL, 0, sysctl_kern_timecounter_hardware, "A", + ""); +.Ed +.Sh SYSCTL NAMING +When adding, modifying, or removing sysctl names, it is important to be +aware that these interfaces may be used by users, libraries, applications, +or documentation (such as published books), and are implicitly published application interfaces. +As with other application interfaces, caution must be taken not to break +existing applications, and to think about future use of new name spaces so as +to avoid the need to rename or remove interfaces that might be depended on in +the future. +.Pp +The semantics chosen for a new sysctl should be as clear as possible, +and the name of the sysctl must closely reflect its semantics. +Therefore the sysctl name deserves a fair amount of consideration. +It should be short but yet representative of the sysctl meaning. +If the name consists of several words, they should be separated by +underscore characters, as in +.Va compute_summary_at_mount . +Underscore characters may be omitted only if the name consists of not more +than two words, each being not longer than four characters, as in +.Va bootfile . +For boolean sysctls, negative logic should be totally avoided. +That is, do not use names like +.Va no_foobar +or +.Va foobar_disable . +They are confusing and lead to configuration errors. +Use positive logic instead: +.Va foobar , +.Va foobar_enable . +.Pp +A temporary sysctl node that should not be relied upon must be designated +as such by a leading underscore character in its name. For example: +.Va _dirty_hack . +.Sh SEE ALSO +.Xr sysctl 8 , +.Xr sysctl_add_oid 9 , +.Xr sysctl_ctx_free 9 , +.Xr sysctl_ctx_init 9 , +.Xr sysctl_remove_oid 9 +.Sh HISTORY +The +.Xr sysctl 8 +utility first appeared in +.Bx 4.4 . +.Sh AUTHORS +.An -nosplit +The +.Nm sysctl +implementation originally found in +.Bx +has been extensively rewritten by +.An Poul-Henning Kamp +in order to add support for name lookups, name space iteration, and dynamic +addition of MIB nodes. +.Pp +This man page was written by +.An Robert N. M. Watson . Index: taskqueue.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/taskqueue.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/taskqueue.9 -L share/man/man9/taskqueue.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/taskqueue.9 +++ share/man/man9/taskqueue.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/taskqueue.9,v 1.20 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/taskqueue.9,v 1.21 2007/07/09 06:24:10 jmg Exp $ .\" .Dd May 19, 2005 .Dt TASKQUEUE 9 @@ -160,6 +160,12 @@ and the value of .Va ta_pending as its second argument. +After the function +.Va ta_func +returns, +.Xr wakeup 9 +is called on the task pointer passed to +.Fn taskqueue_enqueue . .Pp The .Fn taskqueue_drain Index: watchdog.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/watchdog.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/watchdog.9 -L share/man/man9/watchdog.9 -u -r1.2 -r1.3 --- share/man/man9/watchdog.9 +++ share/man/man9/watchdog.9 @@ -22,8 +22,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/watchdog.9,v 1.3 2004/07/06 07:39:50 ru Exp $ -.\" $MidnightBSD$ +.\" $FreeBSD: src/share/man/man9/watchdog.9,v 1.6 2007/03/28 21:21:22 brueffer Exp $ .\" .Dd February 28, 2004 .Dt WATCHDOG 9 @@ -36,6 +35,7 @@ .Ft void .Fn watchdog_fn "void *private" "u_int cmd" "int *error" .Fn EVENTHANDLER_REGISTER watchdog_list watchdog_fn private 0 +.Fn EVENTHANDLER_DEREGISTER watchdog_list eventhandler_tag .Sh DESCRIPTION To implement a watchdog in software or hardware, only a single function needs to be written and registered on the global @@ -51,17 +51,21 @@ is zero, the watchdog must be disabled and the .Fa error argument left untouched. +If the watchdog cannot be disabled, the +.Fa error +argument must be set to +.Dv EOPNOTSUPP . .Pp Else the watchdog should be reset and configured to a timeout of .Pq 1 << Pq Fa cmd No & Dv WD_INTERVAL nanoseconds or larger and the .Fa error -argument be set to zero. +argument be set to zero to signal arming of a watchdog. .Pp If the watchdog cannot be configured to the proposed timeout, it must be disabled and the .Fa error -argument left untouched. +argument left as is (to avoid hiding the arming of another watchdog). .Pp There is no specification of what the watchdog should do when it times out, but a hardware reset or similar Index: mtx_pool.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mtx_pool.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/mtx_pool.9 -L share/man/man9/mtx_pool.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/mtx_pool.9 +++ share/man/man9/mtx_pool.9 @@ -25,7 +25,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mtx_pool.9,v 1.5 2003/09/14 13:41:59 ru Exp $ +.\" $FreeBSD: src/share/man/man9/mtx_pool.9,v 1.8 2007/03/30 18:07:26 julian Exp $ .\" .Dd March 25, 2002 .Dt MTX_POOL 9 @@ -64,7 +64,7 @@ .Sh DESCRIPTION Mutex pools are designed to be used as short term leaf mutexes; i.e., the last mutex one might acquire before calling -.Xr msleep 9 . +.Xr mtx_sleep 9 . They operate using a shared pool of mutexes. A mutex may be chosen from the pool based on a supplied pointer, which may or may not point to anything valid, @@ -110,7 +110,7 @@ No initialization or destruction overhead. .It Can be used with -.Xr msleep 9 . +.Xr mtx_sleep 9 . .El .Pp And the following disadvantages: @@ -176,9 +176,8 @@ on each mutex in the specified pool, deallocates the memory associated with the pool, and assigns NULL to the pool pointer. -.Pp .Sh SEE ALSO -.Xr msleep 9 , +.Xr locking 9 .Xr mutex 9 .Sh HISTORY These routines first appeared in Index: ktr.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/ktr.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/ktr.9 -L share/man/man9/ktr.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/ktr.9 +++ share/man/man9/ktr.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/ktr.9,v 1.9 2005/06/15 13:31:23 ru Exp $ +.\" $FreeBSD: src/share/man/man9/ktr.9,v 1.13 2006/10/16 07:59:05 danger Exp $ .\" -.Dd February 15, 2001 +.Dd December 27, 2005 .Dt KTR 9 .Os .Sh NAME @@ -51,6 +51,8 @@ .Fn CTR4 "u_int mask" "char *format" "arg1" "arg2" "arg3" "arg4" .Ft void .Fn CTR5 "u_int mask" "char *format" "arg1" "arg2" "arg3" "arg4" "arg5" +.Ft void +.Fn CTR6 "u_int mask" "char *format" "arg1" "arg2" "arg3" "arg4" "arg5" "arg6" .Sh DESCRIPTION KTR provides a circular buffer of events that can be logged in a .Xr printf 9 @@ -143,3 +145,13 @@ so that if one CPU halts or starts spinning, then the log messages it emitted just prior to halting or spinning will not be drowned out by events from the other CPUs. +.Pp +The arguments given in +.Fn CTRx +macros are stored as +.Vt u_long , +so do not pass arguments larger than size of an +.Vt u_long +type. +For example passing 64bit arguments on 32bit architectures will give incorrect +results. Index: bus_alloc_resource.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/bus_alloc_resource.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/bus_alloc_resource.9 -L share/man/man9/bus_alloc_resource.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/bus_alloc_resource.9 +++ share/man/man9/bus_alloc_resource.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/bus_alloc_resource.9,v 1.21 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/bus_alloc_resource.9,v 1.23 2007/05/27 20:49:08 imp Exp $ .\" .Dd May 18, 2000 .Dt BUS_ALLOC_RESOURCE 9 @@ -90,10 +90,10 @@ points to a bus specific handle that identifies the resource being allocated. For ISA this is an index into an array of resources that have been setup for this device by either the PnP mechanism, or via the hints mechanism. -For PCCARD, similar things are used as of writing, -but that may change in the future with newcard. -For PCI it just happens to be the offset into pci config space which has -a word that describes the resource. +For PCCARD, this is an index into the array of resources described by the PC Card's +CIS entry. +For PCI, the offset into pci config space which has the BAR to use to access +the resource. The bus methods are free to change the RIDs that they are given as a parameter. You must not depend on the value you gave it earlier. .It @@ -159,7 +159,7 @@ .Va irqid should be saved in the softc of the device after these calls. .Bd -literal - struct resource *portres, irqres; + struct resource *portres, *irqres; int portid, irqid; portid = 0; Index: vput.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vput.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vput.9 -L share/man/man9/vput.9 -u -r1.2 -r1.3 --- share/man/man9/vput.9 +++ share/man/man9/vput.9 @@ -27,7 +27,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vput.9,v 1.11 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd July 24, 1996 .Os Index: acl.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/acl.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/acl.9 -L share/man/man9/acl.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/acl.9 +++ share/man/man9/acl.9 @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/acl.9,v 1.14 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/acl.9,v 1.15 2006/02/13 21:34:18 joel Exp $ .\" .Dd December 23, 1999 .Os @@ -135,7 +135,6 @@ to the associated file. .El .El -.Pp .Sh IMPLEMENTATION NOTES .Bd -literal typedef mode_t *acl_permset_t; Index: device_set_driver.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/device_set_driver.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/device_set_driver.9 -L share/man/man9/device_set_driver.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/device_set_driver.9 +++ share/man/man9/device_set_driver.9 @@ -26,7 +26,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/device_set_driver.9,v 1.3 2003/10/23 06:19:45 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/device_set_driver.9,v 1.4 2007/02/09 21:12:21 brueffer Exp $ .\" .Dd April 21, 2003 .Dt DEVICE_SET_DRIVER 9 @@ -45,9 +45,7 @@ It is typically used in .Xr DEVICE_IDENTIFY 9 functions to add devices to a bus that does not support doing so -automatically, such as the -.Xr isa 4 -bus. +automatically, such as the ISA bus. .Sh SEE ALSO .Xr device 9 .Sh AUTHORS Index: crypto.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/crypto.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/crypto.9 -L share/man/man9/crypto.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/crypto.9 +++ share/man/man9/crypto.9 @@ -15,9 +15,9 @@ .\" MERCHANTABILITY OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR .\" PURPOSE. .\" -.\" $FreeBSD: src/share/man/man9/crypto.9,v 1.5 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/crypto.9,v 1.14 2007/09/19 16:28:46 brueffer Exp $ .\" -.Dd October 14, 2002 +.Dd September 19, 2007 .Dt CRYPTO 9 .Os .Sh NAME @@ -62,7 +62,7 @@ struct cryptoini { int cri_alg; int cri_klen; - int cri_rnd; + int cri_mlen; caddr_t cri_key; u_int8_t cri_iv[EALG_MAX_BLOCK_LEN]; struct cryptoini *cri_next; @@ -74,6 +74,10 @@ int crd_inject; int crd_flags; struct cryptoini CRD_INI; +#define crd_iv CRD_INI.cri_iv +#define crd_key CRD_INI.cri_key +#define crd_alg CRD_INI.cri_alg +#define crd_klen CRD_INI.cri_klen struct cryptodesc *crd_next; }; @@ -171,30 +175,33 @@ Currently supported algorithms are: .Pp .Bl -tag -width ".Dv CRYPTO_RIPEMD160_HMAC" -compact -.It Dv CRYPTO_DES_CBC -.It Dv CRYPTO_3DES_CBC +.It Dv CRYPTO_AES_CBC +.It Dv CRYPTO_ARC4 .It Dv CRYPTO_BLF_CBC +.It Dv CRYPTO_CAMELLIA_CBC .It Dv CRYPTO_CAST_CBC +.It Dv CRYPTO_DES_CBC +.It Dv CRYPTO_3DES_CBC .It Dv CRYPTO_SKIPJACK_CBC +.It Dv CRYPTO_MD5 .It Dv CRYPTO_MD5_HMAC -.It Dv CRYPTO_SHA1_HMAC -.It Dv CRYPTO_RIPEMD160_HMAC .It Dv CRYPTO_MD5_KPDK -.It Dv CRYPTO_SHA1_KPDK -.It Dv CRYPTO_AES_CBC -.It Dv CRYPTO_ARC4 -.It Dv CRYPTO_MD5 +.It Dv CRYPTO_RIPEMD160_HMAC .It Dv CRYPTO_SHA1 -.It Dv CRYPTO_SHA2_HMAC +.It Dv CRYPTO_SHA1_HMAC +.It Dv CRYPTO_SHA1_KPDK +.It Dv CRYPTO_SHA2_256_HMAC +.It Dv CRYPTO_SHA2_384_HMAC +.It Dv CRYPTO_SHA2_512_HMAC .It Dv CRYPTO_NULL_HMAC .It Dv CRYPTO_NULL_CBC .El .It Va cri_klen Specifies the length of the key in bits, for variable-size key algorithms. -.It Va cri_rnd -Specifies the number of rounds to be used with the algorithm, for -variable-round algorithms. +.It Va cri_mlen +Specifies how many bytes from the calculated hash should be copied back. +0 means entire hash. .It Va cri_key Contains the key to be used with the algorithm. .It Va cri_iv @@ -278,11 +285,27 @@ .It Va crp_flags Is a bitmask of flags associated with this request. Currently defined flags are: -.Bl -tag -width ".Dv CRYPTO_F_IMBUF" +.Bl -tag -width ".Dv CRYPTO_F_CBIFSYNC" .It Dv CRYPTO_F_IMBUF The buffer pointed to by .Va crp_buf is an mbuf chain. +.It Dv CRYPTO_F_IOV +The buffer pointed to by +.Va crp_buf +is an +.Vt uio +structure. +.It Dv CRYPTO_F_REL +Must return data in the same place. +.It Dv CRYPTO_F_BATCH +Batch operation if possible. +.It Dv CRYPTO_F_CBIMM +Do callback immediately instead of doing it from a dedicated kernel thread. +.It Dv CRYPTO_F_DONE +Operation completed. +.It Dv CRYPTO_F_CBIFSYNC +Do callback immediately if operation is synchronous. .El .It Va crp_buf Points to the input buffer. @@ -302,6 +325,23 @@ on the input buffer. The various fields are: .Bl -tag -width ".Va crd_inject" +.It Va crd_iv +The field where IV should be provided when the +.Dv CRD_F_IV_EXPLICIT +flag is given. +.It Va crd_key +When the +.Dv CRD_F_KEY_EXPLICIT +flag is given, the +.Va crd_key +points to a buffer with encryption or authentication key. +.It Va crd_alg +An algorithm to use. +Must be the same as the one given at newsession time. +.It Va crd_klen +The +.Va crd_key +key length. .It Va crd_skip The offset in the input buffer where processing should start. .It Va crd_len @@ -318,7 +358,7 @@ inserted. .It Va crd_flags The following flags are defined: -.Bl -tag -width ".Dv CRD_F_IV_EXPLICIT" +.Bl -tag -width 3n .It Dv CRD_F_ENCRYPT For encryption algorithms, this bit is set when encryption is required (when not set, decryption is performed). @@ -343,8 +383,8 @@ .It Dv CRD_F_IV_EXPLICIT For encryption algorithms, this bit is set when the IV is explicitly provided by the consumer in the -.Va cri_iv -fields. +.Va crd_iv +field. Otherwise, for encryption operations the IV is provided for by the driver used to perform the operation, whereas for decryption operations it is pointed to by the @@ -355,6 +395,14 @@ by the consumer, and does not precede the data (some .Xr ipsec 4 configurations, and the encrypted swap are two such examples). +.It Dv CRD_F_KEY_EXPLICIT +For encryption and authentication (MAC) algorithms, this bit is set when the key +is explicitly provided by the consumer in the +.Va crd_key +field for the given operation. +Otherwise, the key is taken at newsession time from the +.Va cri_key +field. .It Dv CRD_F_COMP For compression algorithms, this bit is set when compression is required (when not set, decompression is performed). Index: vm_page_grab.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vm_page_grab.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vm_page_grab.9 -L share/man/man9/vm_page_grab.9 -u -r1.2 -r1.3 --- share/man/man9/vm_page_grab.9 +++ share/man/man9/vm_page_grab.9 @@ -25,7 +25,6 @@ .\" DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vm_page_grab.9,v 1.3 2005/06/28 20:15:18 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd August 7, 2001 .Dt VM_PAGE_GRAB 9 Index: hashinit.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/hashinit.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/hashinit.9 -L share/man/man9/hashinit.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/hashinit.9 +++ share/man/man9/hashinit.9 @@ -23,13 +23,13 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/hashinit.9,v 1.2 2005/01/21 08:36:40 ru Exp $ +.\" $FreeBSD: src/share/man/man9/hashinit.9,v 1.4 2007/01/27 23:06:00 ru Exp $ .\" .Dd October 10, 2004 .Dt HASHINIT 9 .Os .Sh NAME -.Nm hashinit , hashdestroy , phashinit +.Nm hashinit , hashinit_flags, hashdestroy , phashinit .Nd manage kernel hash tables .Sh SYNOPSIS .In sys/malloc.h @@ -38,12 +38,17 @@ .Ft "void *" .Fn hashinit "int nelements" "struct malloc_type *type" "u_long *hashmask" .Ft void +.Fo hashinit_flags +.Fa "int nelements" "struct malloc_type *type" "u_long *hashmask" "int flags" +.Fc +.Ft void .Fn hashdestroy "void *hashtbl" "struct malloc_type *type" "u_long hashmask" .Ft "void *" .Fn phashinit "int nelements" "struct malloc_type *type" "u_long *nentries" .Sh DESCRIPTION The -.Fn hashinit +.Fn hashinit , +.Fn hashinit_flags and .Fn phashinit functions allocate space for hash tables of size given by the argument @@ -59,6 +64,13 @@ function allocates hash tables that are sized to the largest prime number less than or equal to argument .Fa nelements . +The +.Fn hashinit_flags +function operates like +.Fn hashinit +but also accepts an additional argument +.Fa flags +which control various options during allocation. Allocated hash tables are contiguous arrays of .Xr LIST_HEAD 3 entries, allocated using @@ -80,6 +92,20 @@ should be the bit mask returned by the call to .Fn hashinit that allocated the hash table. +The argument +.Fa flags +must be used with one of the following values. +.Pp +.Bl -tag -width ".Dv HASH_NOWAIT" -offset indent -compact +.It Dv HASH_NOWAIT +Any malloc performed by the +.Fn hashinit_flags +function will not be allowed to wait, and therefore may fail. +.It Dv HASH_WAITOK +Any malloc performed by the +.Fn hashinit_flags +function is allowed to wait for memory. +.El .Sh IMPLEMENTATION NOTES The largest prime hash value chosen by .Fn phashinit Index: mbuf.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/mbuf.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/mbuf.9 -L share/man/man9/mbuf.9 -u -r1.2 -r1.3 --- share/man/man9/mbuf.9 +++ share/man/man9/mbuf.9 @@ -22,9 +22,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/mbuf.9,v 1.58.2.2 2006/03/23 23:24:33 sam Exp $ +.\" $FreeBSD: src/share/man/man9/mbuf.9,v 1.65 2007/02/26 15:17:19 bms Exp $ .\" -.Dd March 15, 2006 +.Dd February 26, 2007 .Dt MBUF 9 .Os .\" @@ -51,14 +51,10 @@ .Fa "int type" .Fc .Fn MEXTFREE "struct mbuf *mbuf" -.Fn MEXT_ADD_REF "struct mbuf *mbuf" -.Fn MEXT_REM_REF "struct mbuf *mbuf" .Fn MFREE "struct mbuf *mbuf" "struct mbuf *successor" .\" .Ss Mbuf utility macros .Fn mtod "struct mbuf *mbuf" "type" -.Ft int -.Fn MEXT_IS_REF "struct mbuf *mbuf" .Fn M_ALIGN "struct mbuf *mbuf" "u_int len" .Fn MH_ALIGN "struct mbuf *mbuf" "u_int len" .Ft int @@ -101,6 +97,8 @@ .Ft struct mbuf * .Fn m_pullup "struct mbuf *mbuf" "int len" .Ft struct mbuf * +.Fn m_pulldown "struct mbuf *mbuf" "int offset" "int len" "int *offsetp" +.Ft struct mbuf * .Fn m_copym "struct mbuf *mbuf" "int offset" "int len" "int how" .Ft struct mbuf * .Fn m_copypacket "struct mbuf *mbuf" "int how" @@ -233,9 +231,8 @@ .Bd -literal /* mbuf types */ #define MT_DATA 1 /* dynamic (data) allocation */ -#define MT_HEADER 2 /* packet header */ +#define MT_HEADER MT_DATA /* packet header */ #define MT_SONAME 8 /* socket name */ -#define MT_FTABLE 11 /* fragment reassembly header */ #define MT_CONTROL 14 /* extra-data protocol message */ #define MT_OOBDATA 15 /* expedited data */ .Ed @@ -302,18 +299,6 @@ .Pp The allocation and management of the reference counter is handled by the subsystem. -The developer can check whether the reference count for the -external storage of a given -.Vt mbuf -is greater than 1 with the -.Dv MEXT_IS_REF -macro. -Similarly, the developer can directly add and remove references, -if absolutely necessary, with the use of the -.Dv MEXT_ADD_REF -and -.Dv MEXT_REM_REF -macros. .Pp The system also supplies a default type of external storage buffer called an .Vt mbuf cluster . @@ -660,6 +645,10 @@ .Fa mbuf , so they are accessible with .Fn mtod mbuf type . +It is important to remember that this may involve +reallocating some mbufs and moving data so all pointers +referencing data within the old mbuf chain +must be recalculated or made invalid. Return the new .Vt mbuf chain on success, @@ -676,6 +665,42 @@ must be less than .Dv MHLEN . .\" +.It Fn m_pulldown mbuf offset len offsetp +Arrange that +.Fa len +bytes between +.Fa offset +and +.Fa offset + len +in the +.Vt mbuf chain +are contiguous and lay in the data area of +.Fa mbuf , +so they are accessible with +.Fn mtod mbuf type . +.Fa len must be smaller than, or equal to, the size of an +.Vt mbuf cluster . +Return a pointer to an intermediate +.Vt mbuf +in the chain containing the requested region; +the offset in the data region of the +.Vt mbuf chain +to the data contained in the returned mbuf is stored in +.Fa *offsetp . +If +.Fa offp +is NULL, the region may be accessed using +.Fn mtod mbuf type . +If +.Fa offp +is non-NULL, the region may be accessed using +.Fn mtod mbuf uint8_t + *offsetp . +The region of the mbuf chain between its beginning and +.Fa off +is not modified, therefore it is safe to hold pointers to data within +this region before calling +.Fn m_pulldown . +.\" .It Fn m_copym mbuf offset len how Make a copy of an .Vt mbuf chain @@ -1135,7 +1160,35 @@ Besides being used for network packets, they were used to store various dynamic structures, such as routing table entries, interface addresses, protocol control blocks, etc. +In more recent +.Fx +use of +.Vt mbufs +is almost entirely limited to packet storage, with +.Xr uma 9 +zones being used directly to store other network-related memory. +.Pp +Historically, the +.Vt mbuf +allocator has been a special-purpose memory allocator able to run in +interrupt contexts and allocating from a special kernel address space map. +As of +.Fx 5.3 , +the +.Vt mbuf +allocator is a wrapper around +.Xr uma 9 , +allowing caching of +.Vt mbufs , +clusters, and +.Vt mbuf ++ cluster pairs in per-CPU caches, as well as bringing other benefits of +slab allocation. .Sh AUTHORS The original .Nm manual page was written by Yar Tikhiy. +The +.Xr uma 9 +.Vt mbuf +allocator was written by Bosko Milekic. Index: vgone.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vgone.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/vgone.9 -L share/man/man9/vgone.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/vgone.9 +++ share/man/man9/vgone.9 @@ -24,7 +24,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/vgone.9,v 1.4 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/vgone.9,v 1.5 2006/06/07 16:51:54 jkoshy Exp $ .\" .Dd November 21, 2001 .Dt VGONE 9 @@ -50,7 +50,7 @@ If the vnode has a .Va v_usecount of zero, and its -.Dv VDOOMED +.Dv VI_DOOMED flag is not set, it is moved to the head of the free list as in most cases the vnode is about to be reused, or its file system being unmounted. @@ -66,8 +66,6 @@ while .Fn vgonel expects the interlock to already be locked. -.Sh SEE ALSO -.Xr vclean 9 .Sh AUTHORS This manual page was written by .An Chad David Aq davidc at acns.ab.ca . Index: lock.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/lock.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/lock.9 -L share/man/man9/lock.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/lock.9 +++ share/man/man9/lock.9 @@ -24,9 +24,9 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH .\" DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/lock.9,v 1.12 2005/06/28 20:15:18 hmp Exp $ +.\" $FreeBSD: src/share/man/man9/lock.9,v 1.17 2007/06/21 16:39:25 brueffer Exp $ .\" -.Dd July 9, 2001 +.Dd June 20, 2006 .Dt LOCK 9 .Os .Sh NAME @@ -63,14 +63,14 @@ A pointer to the lock to initialize. .It Fa prio The priority passed to -.Xr msleep 9 . +.Xr sleep 9 . .It Fa wmesg The lock message. This is used for both debugging output and -.Xr msleep 9 . +.Xr sleep 9 . .It Fa timo The timeout value passed to -.Xr msleep 9 . +.Xr sleep 9 . .It Fa flags The flags the lock is to be initialized with. .Bl -tag -width ".Dv LG_CANRECURSE" @@ -80,10 +80,8 @@ Fail after a sleep. .It Dv LK_CANRECURSE Allow recursive exclusive locks. -.It Dv LK_REENABLE -Re-enable the lock after a drain. -.It Dv LK_NOPAUSE -Disable the spinlock while acquiring the lock. +.It Dv LK_NOSHARE +Allow exclusive locks only. .It Dv LK_TIMELOCK Use .Fa timo @@ -140,6 +138,8 @@ .It Dv LK_UPGRADE Upgrade a shared lock to an exclusive lock. If this call fails, the shared lock is lost. +During the upgrade, the shared lock could +be temporarily dropped. Attempts to upgrade an exclusive lock will cause a .Xr panic 9 . .It Dv LK_RELEASE @@ -272,7 +272,12 @@ .Xr panic 9 will be the result of trying. .Sh SEE ALSO -.Xr msleep 9 , +.Xr condvar 9 , +.Xr locking 9 , +.Xr mutex 9 , +.Xr rwlock 9 , +.Xr sleep 9 , +.Xr sx 9 , .Xr mtx_assert 9 , .Xr panic 9 , .Xr VOP_PRINT 9 Index: firmware.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/firmware.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/firmware.9 -L share/man/man9/firmware.9 -u -r1.2 -r1.3 --- share/man/man9/firmware.9 +++ share/man/man9/firmware.9 @@ -21,7 +21,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $FreeBSD: src/share/man/man9/firmware.9,v 1.2.2.2 2006/03/23 07:41:32 hrs Exp $ +.\" $FreeBSD: src/share/man/man9/firmware.9,v 1.6 2007/02/15 17:52:17 luigi Exp $ .\" .Dd January 6, 2006 .Os @@ -43,73 +43,224 @@ const void *data; /* location of image */ size_t datasize; /* size of image in bytes */ unsigned int version; /* version of the image */ - int refcnt; /* held references */ - struct firmware *parent; /* not null if a subimage */ - linker_file_t file; /* loadable module */ }; .Ed -.Ft struct firmware * +.Ft "const struct firmware *" .Fo firmware_register .Fa "const char *imagename" .Fa "const void *data" .Fa "size_t datasize" .Fa "unsigned int version" -.Fa "struct firmware *parent" +.Fa "const struct firmware *parent" .Fc .Ft int .Fn firmware_unregister "const char *imagename" -.Ft struct firmware * +.Ft "const struct firmware *" .Fn firmware_get "const char *imagename" .Ft void -.Fn firmware_put "struct firmware *fp" "int flags" +.Fn firmware_put "const struct firmware *fp" "int flags" .Sh DESCRIPTION -The firmware abstraction provides a convenient interface for loading firmware -images into the kernel. -Specially crafted kernel modules are used to hold the firmware images. +The +.Nm firmware +abstraction provides a convenient interface for loading +.Nm firmware images +into the kernel, and for accessing such images from kernel components. +.Pp +A +.Nm firmware image +(or +.Nm image +for brevity) +is an opaque block of data residing in kernel memory. +It is associated to a unique +.Nm imagename +which constitutes a search key, and to an integer +.Nm version +number, which is also an opaque piece of information for the +firmware subsystem. +.Pp +An image is registered with the +.Nm firmware +subsystem by calling the function +.Fn firmware_register , +and unregistered by calling +.Fn firmware_unregister . +These functions are usually (but not exclusively) called by +specially crafted kernel modules that contain the firmware image. +The modules can be statically compiled in the kernel, or loaded by +.Nm /boot/loader , +manually at runtime, or on demand by the firmware subsystem. +.Pp +.Nm Clients +of the firmware subsystem can request access to a given image +by calling the function +.Fn firmware_get +with the +.Nm imagename +they want as an argument. If a matching image is not already registered, +the firmware subsystem will try to load it using the +mechanisms specified below (typically, a kernel module +with +.Nm the same name +as the image). +.Sh API DESCRIPTION +The kernel +.Nm firmware API +is made of the following functions: .Pp -The function -.Fn firmware_register -is used on load of such modules to register contained firmware images. -The arguments to .Fn firmware_register -include a name that identifies the image for later requests to the firmware -system, a pointer to the actual image, the size of the image and an optional -parent image. -The parent image is used to keep track of references to a given module so that -it can be unloaded on last reference. +registers with the kernel an image of size +.Nm datasize +located at address +.Nm data , +under the name +.Nm imagename . +.Pp +The function returns NULL on error (e.g. because an +image with the same name already exists, or the image +table is full), or a +.Ft const struct firmware * +pointer to the image requested. .Pp -The function .Fn firmware_unregister -removes the firmware image identified by the name from the system if there -are no pending references or returns an error otherwise. +tries to unregister the firmware image +.Nm imagename +from the system. The function is successful and returns 0 +if there are no pending references to the image, otherwise +it does not unregister the image and returns EBUSY. .Pp -The function .Fn firmware_get returns the requested firmware image. -If the image is not yet registered with the system +If the image is not yet registered with the system, +the function tries to load it. +This involves the linker subsystem and disk access, so .Fn firmware_get -tries to load a module with the corresponding name. -This involves the linker subsystem and disk access which is why -.Fn firmware_get -must not be called with any locks (except for Giant). -On success +must not be called with any locks (except for +.Va Giant ) . +The caller must also have a process context so filesystem state such as +the root vnode is defined (e.g. you cannot load from a taskqueue thread). +.Pp +On success, .Fn firmware_get returns a pointer to the image description and increases the reference count -for this image. +for this image. On failure, the function returns NULL. .Pp -The function .Fn firmware_put -is used to drop the reference to a firmware image. -The flags argument may be set to +drops a reference to a firmware image. +The +.Fa flags +argument may be set to .Dv FIRMWARE_UNLOAD -to indicate that the caller wishes to unload the corresponding module if the -image becomes unreferenced. +to indicate that +firmware_put is free to reclaim resources associated with +the firmware image if this is the last reference. +.Sh FIRMWARE LOADING MECHANISMS +As mentioned before, any component of the system can register +firmware images at any time by simply calling +.Fn firmware_register . +.Pp +This is typically done when a module containing +a firmware image is given control, +whether compiled in, or preloaded by +.Nm /boot/loader , +or manually loaded with +.Xr kldload 8 . +However, a system can implement additional mechanisms to bring +these images in memory before calling +.Fn firmware_register . +.Pp +When +.Fn firmware_get +does not find the requested image, it tries to load it using +one of the available loading mechanisms. +At the moment, there is only one, namely +.Nm Loadable kernel modules : +.Pp +A firmware image named +.Nm foo +is looked up by trying to load the module named +.Nm foo.ko , +using the facilities described in +.Xr kld 4 . +In particular, images are looked up in the directories specified +by the sysctl variable +.Nm kern.module_path +which on most systems defaults to +.Nm /boot/kernel;/boot/modules . +.Pp +Note that in case a module contains multiple images, +the caller should first request a +.Fn firmware_get +for the first image contained in the module, followed by requests +for the other images. +.Sh BUILDING FIRMWARE LOADABLE MODULES +A firmware module is built by embedding the +.Nm firmware image +into a suitable loadable kernel module that calls +.Fn firmware_register +on loading, and +.Fn firmware_unregister +on unloading. +.Pp +Various system scripts and makefiles let you build a module +by simply writing a Makefile with the following entries: +.Bd -literal + + KMOD= imagename + FIRMWS= image_file:imagename[:version] + .include + +.Ed +where KMOD is the basename of the module; FIRMWS is a list of +colon-separated tuples indicating the image_file's to be embedded +in the module, the imagename and version of each firmware image. +.Pp +If you need to embed firmware images into a system, you should write +appropriate entries in the file, e.g. this example is +from +.Nm sys/arm/xscale/ixp425/files.ixp425: +.Bd -literal +ixp425_npe_fw.c optional npe_fw \\ + compile-with "${AWK} -f $S/tools/fw_stub.awk \\ + IxNpeMicrocode.dat:npe_fw -mnpe -c${.TARGET}" \\ + no-implicit-rule before-depend local \\ + clean "ixp425_npe_fw.c" +# +# NB: ld encodes the path in the binary symbols generated for the +# firmware image so link the file to the object directory to +# get known values for reference in the _fw.c file. +# +IxNpeMicrocode.fwo optional npe_fw \\ + dependency "IxNpeMicrocode.dat" \\ + compile-with "${LD} -b binary -d -warn-common \\ + -r -d -o ${.TARGET} IxNpeMicrocode.dat" \\ + no-implicit-rule \\ + clean "IxNpeMicrocode.fwo" +IxNpeMicrocode.dat optional npe_fw \\ + dependency ".PHONY" \\ + compile-with "if [ -e $S/arm/xscale/ixp425/IxNpeMicrocode.dat ]; \\ + then \\ + ln -sf $S/arm/xscale/ixp425/IxNpeMicrocode.dat .; \\ + else echo 'WARNING, no IxNpeMicrocode.dat file; you must obtain this from the Intel web site'; false; \\ + fi" \\ + no-obj no-implicit-rule \\ + clean "IxNpeMicrocode.dat" +.Ed +.Pp +Note that generating the firmware modules in this way requires +the availability of the following tools: +.Xr awk , +.Xr Make , +the compiler and the linker. .Sh SEE ALSO -.Xr module 9 +.Xr module 9 , +.Xr kld 4 .Pp -.Pa /usr/share/examples/kld +.Pa /usr/share/examples/kld/firmware .Sh HISTORY -The firmware system was introduced in +The +.Nm firmware +system was introduced in .Fx 6.1 . .Sh AUTHORS This manual page was written by Index: namei.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/namei.9,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L share/man/man9/namei.9 -L share/man/man9/namei.9 -u -r1.1.1.1 -r1.2 --- share/man/man9/namei.9 +++ share/man/man9/namei.9 @@ -31,9 +31,9 @@ .\" If you integrate this manpage in another OS, I'd appreciate a note .\" - eivind at FreeBSD.org .\" -.\" $FreeBSD: src/share/man/man9/namei.9,v 1.26.2.1 2005/09/25 18:51:45 rwatson Exp $ +.\" $FreeBSD: src/share/man/man9/namei.9,v 1.29 2005/12/13 17:07:52 ru Exp $ .\" -.Dd May 27, 2003 +.Dd September 21, 2005 .Os .Dt NAMEI 9 .Sh NAME @@ -82,7 +82,7 @@ in which case the caller must later release .Va Giant based on the results of -.Fn NDHASGIANT. +.Fn NDHASGIANT . .Pp The .Fn NDINIT Index: vnode.9 =================================================================== RCS file: /home/cvs/src/share/man/man9/vnode.9,v retrieving revision 1.2 retrieving revision 1.3 diff -L share/man/man9/vnode.9 -L share/man/man9/vnode.9 -u -r1.2 -r1.3 --- share/man/man9/vnode.9 +++ share/man/man9/vnode.9 @@ -25,7 +25,6 @@ .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" .\" $FreeBSD: src/share/man/man9/vnode.9,v 1.29 2005/06/28 20:15:19 hmp Exp $ -.\" $MidnightBSD$ .\" .Dd May 20, 2003 .Os From laffer1 at midnightbsd.org Tue Jan 20 15:10:05 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 15:10:05 -0500 (EST) Subject: [Midnightbsd-cvs] src: dev/if_ndis: sc->ndis_txidx should be cycle between 0 and Message-ID: <200901202010.n0KKA5Df072609@stargazer.midnightbsd.org> Log Message: ----------- sc->ndis_txidx should be cycle between 0 and sc->ndis_maxpkts, not NDIS_TXPKTS and don't allocate unused extra spaces for sc->ndis_txarray and sc->ndis_txpool. Modified Files: -------------- src/sys/dev/if_ndis: if_ndis.c (r1.7 -> r1.8) if_ndisvar.h (r1.2 -> r1.3) -------------- next part -------------- Index: if_ndisvar.h =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndisvar.h,v retrieving revision 1.2 retrieving revision 1.3 diff -L sys/dev/if_ndis/if_ndisvar.h -L sys/dev/if_ndis/if_ndisvar.h -u -r1.2 -r1.3 --- sys/dev/if_ndis/if_ndisvar.h +++ sys/dev/if_ndis/if_ndisvar.h @@ -87,7 +87,7 @@ #define NDIS_TXPKTS 64 #define NDIS_INC(x) \ - (x)->ndis_txidx = ((x)->ndis_txidx + 1) % NDIS_TXPKTS + (x)->ndis_txidx = ((x)->ndis_txidx + 1) % (x)->ndis_maxpkts #define NDIS_EVENTS 4 #define NDIS_EVTINC(x) (x) = ((x) + 1) % NDIS_EVENTS Index: if_ndis.c =================================================================== RCS file: /home/cvs/src/sys/dev/if_ndis/if_ndis.c,v retrieving revision 1.7 retrieving revision 1.8 diff -L sys/dev/if_ndis/if_ndis.c -L sys/dev/if_ndis/if_ndis.c -u -r1.7 -r1.8 --- sys/dev/if_ndis/if_ndis.c +++ sys/dev/if_ndis/if_ndis.c @@ -643,12 +643,12 @@ sc->ndis_maxpkts = 10; sc->ndis_txarray = malloc(sizeof(ndis_packet *) * - NDIS_TXPKTS, M_DEVBUF, M_NOWAIT|M_ZERO); + sc->ndis_maxpkts, M_DEVBUF, M_NOWAIT|M_ZERO); /* Allocate a pool of ndis_packets for TX encapsulation. */ NdisAllocatePacketPool(&i, &sc->ndis_txpool, - NDIS_TXPKTS, PROTOCOL_RESERVED_SIZE_IN_PACKET); + sc->ndis_maxpkts, PROTOCOL_RESERVED_SIZE_IN_PACKET); if (i != NDIS_STATUS_SUCCESS) { sc->ndis_txpool = NULL; From laffer1 at midnightbsd.org Tue Jan 20 15:13:55 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 15:13:55 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: Remove FreeBSD_version definition completely. Message-ID: <200901202013.n0KKDtZ8072961@stargazer.midnightbsd.org> Log Message: ----------- Remove FreeBSD_version definition completely. Modified Files: -------------- src/include: Makefile (r1.6 -> r1.7) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/include/Makefile,v retrieving revision 1.6 retrieving revision 1.7 diff -L include/Makefile -L include/Makefile -u -r1.6 -r1.7 --- include/Makefile +++ include/Makefile @@ -85,8 +85,6 @@ echo "#ifdef _KERNEL" >> osreldate.h; \ echo "#error \" cannot be used in the kernel, use \"" >> osreldate.h; \ echo "#else" >> osreldate.h; \ - echo "#undef __FreeBSD_version" >> osreldate.h; \ - echo "#define __FreeBSD_version $$RELDATE" >> osreldate.h; \ echo "#undef __MidnightBSD_version" >> osreldate.h; \ echo "#define __MidnightBSD_version $$RELDATE" >> osreldate.h; \ echo "#endif" >> osreldate.h From laffer1 at midnightbsd.org Tue Jan 20 15:31:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 15:31:48 -0500 (EST) Subject: [Midnightbsd-cvs] mports: config.guess: this still isn't good, but it's at least not Message-ID: <200901202031.n0KKVmap074880@stargazer.midnightbsd.org> Log Message: ----------- this still isn't good, but it's at least not totally wrong Modified Files: -------------- mports/Templates: config.guess (r1.1.1.1 -> r1.2) -------------- next part -------------- Index: config.guess =================================================================== RCS file: /home/cvs/mports/Templates/config.guess,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -L Templates/config.guess -L Templates/config.guess -u -r1.1.1.1 -r1.2 --- Templates/config.guess +++ Templates/config.guess @@ -768,22 +768,8 @@ case ${LIBC} in gnu) kernel_only='k' ;; esac echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} exit 0 ;; - *:MidnightBSD:*:*|*:GNU/FreeBSD:*:*) - # Determine whether the default compiler uses glibc. - eval $set_cc_for_build - sed 's/^ //' << EOF >$dummy.c - #include - #if __GLIBC__ >= 2 - LIBC=gnu - #else - LIBC= - #endif -EOF - eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=` - # GNU/FreeBSD systems have a "k" prefix to indicate we are using - # FreeBSD's kernel, but not the complete OS. - case ${LIBC} in gnu) kernel_only='k' ;; esac - echo ${UNAME_MACHINE}-unknown-${kernel_only}freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`${LIBC:+-$LIBC} + *:MidnightBSD:*:*) + echo ${UNAME_MACHINE}-unknown-midnightbsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` exit 0 ;; i*:CYGWIN*:*) echo ${UNAME_MACHINE}-pc-cygwin From laffer1 at midnightbsd.org Tue Jan 20 16:10:48 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:10:48 -0500 (EST) Subject: [Midnightbsd-cvs] src: pcc/mip: WIP: Update to .99 Message-ID: <200901202110.n0KLAmFT079125@stargazer.midnightbsd.org> Log Message: ----------- WIP: Update to .99 Added Files: ----------- src/usr.bin/pcc/ccom: softfloat.c (r1.1) src/usr.bin/pcc/i386: flocal.c (r1.1) src/usr.bin/pcc/mip: compat.h (r1.1) -------------- next part -------------- --- /dev/null +++ usr.bin/pcc/i386/flocal.c @@ -0,0 +1,234 @@ +/* $Id: flocal.c,v 1.16 2008/12/19 20:26:50 ragge Exp $ */ +/* + * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * Redistributions of source code and documentation must retain the above + * copyright notice, this list of conditions and the following disclaimer. + * Redistributions in binary form must reproduce the above copyright + * notice, this list of conditionsand the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed or owned by Caldera + * International, Inc. + * Neither the name of Caldera International, Inc. nor the names of other + * contributors may be used to endorse or promote products derived from + * this software without specific prior written permission. + * + * USE OF THE SOFTWARE PROVIDED FOR UNDER THIS LICENSE BY CALDERA + * INTERNATIONAL, INC. AND CONTRIBUTORS ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED + * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE + * DISCLAIMED. IN NO EVENT SHALL CALDERA INTERNATIONAL, INC. BE LIABLE + * FOR ANY DIRECT, INDIRECT INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OFLIABILITY, WHETHER IN CONTRACT, + * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING + * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + */ +#include + +#include "defines.h" +#include "defs.h" + +void +prchars(int *s) +{ + printf("\t.byte 0%o,0%o\n", s[0], s[1]); +} + + +void +setloc(int l) +{ + static int lastloc = -1; + static char *loctbl[] = + { "text", "data", "section .rodata", "section .rodata", "bss" }; + if (l == lastloc) + return; + printf("\t.%s\n", loctbl[l]); + lastloc = l; +} + +#ifdef FCOM + + +/* + PDP11-780/VAX - SPECIFIC PRINTING ROUTINES +*/ + +/* + * Called just before return from a subroutine. + */ +void +goret(int type) +{ +} + +/* + * Print out a label. + */ +void +prlabel(int k) +{ + printf(LABFMT ":\n", k); +} + +/* + * Print naming for location. + * name[0] is location type. + */ +void +prnloc(char *name) +{ + if (*name == '0') + setloc(DATA); + else + fatal("unhandled prnloc %c", *name); + printf("%s:\n", name+1); +} + +/* + * Print integer constant. + */ +void +prconi(FILE *fp, int type, ftnint n) +{ + fprintf(fp, "\t%s\t%ld\n", (type==TYSHORT ? ".word" : ".long"), n); +} + +/* + * Print address constant, given as a label number. + */ +void +prcona(ftnint a) +{ + printf("\t.long\t" LABFMT "\n", (int)a); +} + +/* + * Print out a floating constant. + */ +void +prconr(FILE *fp, int type, double x) +{ + fprintf(fp, "\t%s\t0f%e\n", (type==TYREAL ? ".float" : ".double"), x); +} + +void +preven(int k) +{ + if (k > 1) + printf("\t.align\t%d\n", k); +} + +/* + * Convert a tag and offset into the symtab table to a string. + * An external string is never longer than XL bytes. + */ +char * +memname(int stg, int mem) +{ +#define MLEN (XL + 10) + char *s = malloc(MLEN); + + switch(stg) { + case STGCOMMON: + case STGEXT: + snprintf(s, MLEN, "%s", varstr(XL, extsymtab[mem].extname)); + break; + + case STGBSS: + case STGINIT: + snprintf(s, MLEN, "v.%d", mem); + break; + + case STGCONST: + snprintf(s, MLEN, ".L%d", mem); + break; + + case STGEQUIV: + snprintf(s, MLEN, "q.%d", mem); + break; + + default: + fatal1("memname: invalid vstg %d", stg); + } + return(s); +} + +void +prlocvar(char *s, ftnint len) +{ + printf("\t.lcomm\t%s,%ld\n", s, len); +} + + +void +prext(char *name, ftnint leng, int init) +{ + if(leng == 0) + printf("\t.globl\t%s\n", name); + else + printf("\t.comm\t%s,%ld\n", name, leng); +} + +void +prendproc() +{ +} + +void +prtail() +{ +} + +void +prolog(struct entrypoint *ep, struct bigblock *argvec) +{ + /* Ignore for now. ENTRY is not supported */ +} + + + +void +prdbginfo() +{ +} + +static void +fcheck(NODE *p, void *arg) +{ + NODE *r, *l; + + switch (p->n_op) { + case CALL: /* fix arguments */ + for (r = p->n_right; r->n_op == CM; r = r->n_left) { + r->n_right = mkunode(FUNARG, r->n_right, 0, + r->n_right->n_type); + } + l = talloc(); + *l = *r; + r->n_op = FUNARG; + r->n_left = l; + r->n_type = l->n_type; + break; + } +} + +/* + * Called just before the tree is written out to pass2. + */ +void p2tree(NODE *p); +void +p2tree(NODE *p) +{ + walkf(p, fcheck, 0); +} +#endif /* FCOM */ --- /dev/null +++ usr.bin/pcc/ccom/softfloat.c @@ -0,0 +1,318 @@ +/* $Id: softfloat.c,v 1.2 2008/09/12 16:27:26 ragge Exp $ */ + +/* + * Copyright (c) 2008 Anders Magnusson. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +#ifdef SOFTFLOAT + +#include "manifest.h" +#include "pass1.h" + + +/* + * Floating point emulation to be used when cross-compiling. + * Currently only supports F- and D-float, used in DEC machines. + * Should be trivial to add other emulations. + * + * XXX - assumes that: + * - long long is (at least) 64 bits + * - int is at least 32 bits. + * - short is 16 bits. + */ + +#ifdef FDFLOAT + +/* + * Useful macros to manipulate the float. + */ +#define DSIGN(w) (((w).fd1 >> 15) & 1) +#define DSIGNSET(w,s) ((w).fd1 = (s << 15) | ((w).fd1 & 077777)) +#define DEXP(w) (((w).fd1 >> 7) & 0377) +#define DEXPSET(w,e) ((w).fd1 = (((e) & 0377) << 7) | ((w).fd1 & 0100177)) +#define DMANTH(w) ((w).fd1 & 0177) +#define DMANTHSET(w,m) ((w).fd1 = ((m) & 0177) | ((w).fd1 & 0177600)) + +typedef unsigned int lword; +typedef unsigned long long dword; + +#define MAXMANT 0x100000000000000LL + +/* + * Returns a zero dfloat. + */ +static SF +nulldf(void) +{ + SF rv; + + rv.fd1 = rv.fd2 = rv.fd3 = rv.fd4 = 0; + return rv; +} + +/* + * Convert a (u)longlong to dfloat. + * XXX - fails on too large (> 55 bits) numbers. + */ +SF +soft_cast(CONSZ ll, TWORD t) +{ + int i; + SF rv; + + rv = nulldf(); + if (ll == 0) + return rv; /* fp is zero */ + if (ll < 0) + DSIGNSET(rv,1), ll = -ll; + for (i = 0; ll > 0; i++, ll <<= 1) + ; + DEXPSET(rv, 192-i); + DMANTHSET(rv, ll >> 56); + rv.fd2 = ll >> 40; + rv.fd3 = ll >> 24; + rv.fd4 = ll >> 8; + return rv; +} + +/* + * multiply two dfloat. Use chop, not round. + */ +SF +soft_mul(SF p1, SF p2) +{ + SF rv; + lword a1[2], a2[2], res[4]; + dword sum; + + res[0] = res[1] = res[2] = res[3] = 0; + + /* move mantissa into lwords */ + a1[0] = p1.fd4 | (p1.fd3 << 16); + a1[1] = p1.fd2 | DMANTH(p1) << 16 | 0x800000; + + a2[0] = p2.fd4 | (p2.fd3 << 16); + a2[1] = p2.fd2 | DMANTH(p2) << 16 | 0x800000; + +#define MULONE(x,y,r) sum += (dword)a1[x] * (dword)a2[y]; sum += res[r]; \ + res[r] = sum; sum >>= 32; + + sum = 0; + MULONE(0, 0, 0); + MULONE(1, 0, 1); + res[2] = sum; + sum = 0; + MULONE(0, 1, 1); + MULONE(1, 1, 2); + res[3] = sum; + + rv.fd1 = 0; + DSIGNSET(rv, DSIGN(p1) ^ DSIGN(p2)); + DEXPSET(rv, DEXP(p1) + DEXP(p2) - 128); + if (res[3] & 0x8000) { + res[3] = (res[3] << 8) | (res[2] >> 24); + res[2] = (res[2] << 8) | (res[1] >> 24); + } else { + DEXPSET(rv, DEXP(rv) - 1); + res[3] = (res[3] << 9) | (res[2] >> 23); + res[2] = (res[2] << 9) | (res[1] >> 23); + } + DMANTHSET(rv, res[3] >> 16); + rv.fd2 = res[3]; + rv.fd3 = res[2] >> 16; + rv.fd4 = res[2]; + return rv; +} + +SF +soft_div(SF t, SF n) +{ + SF rv; + dword T, N, K; + int c; + +#define SHL(x,b) ((dword)(x) << b) + T = SHL(1,55) | SHL(DMANTH(t), 48) | + SHL(t.fd2, 32) | SHL(t.fd3, 16) | t.fd4; + N = SHL(1,55) | SHL(DMANTH(n), 48) | + SHL(n.fd2, 32) | SHL(n.fd3, 16) | n.fd4; + + c = T > N; + for (K = 0; (K & 0x80000000000000ULL) == 0; ) { + if (T >= N) { + T -= N; + K |= 1; + } + T <<= 1; + K <<= 1; + } + rv.fd1 = 0; + DSIGNSET(rv, DSIGN(t) ^ DSIGN(n)); + DEXPSET(rv, DEXP(t) - DEXP(n) + 128 + c); + DMANTHSET(rv, K >> 48); + rv.fd2 = K >> 32; + rv.fd3 = K >> 16; + rv.fd4 = K; + return rv; +} + +/* + * Negate a float number. Easy. + */ +SF +soft_neg(SF sf) +{ + int sign = DSIGN(sf) == 0; + DSIGNSET(sf, sign); + return sf; +} + +/* + * Return true if fp number is zero. + */ +int +soft_isz(SF sf) +{ + return (DEXP(sf) == 0); +} + +/* + * Convert a fp number to a CONSZ. + */ +CONSZ +soft_val(SF sf) +{ + CONSZ mant; + int exp = DEXP(sf) - 128; + + mant = SHL(1,55) | SHL(DMANTH(sf), 48) | + SHL(sf.fd2, 32) | SHL(sf.fd3, 16) | sf.fd4; + + while (exp < 0) + mant >>= 1, exp++; + while (exp > 0) + mant <<= 1, exp--; + return mant; +} + +SF +soft_plus(SF x1, SF x2) +{ + cerror("soft_plus"); + return x1; +} + +SF +soft_minus(SF x1, SF x2) +{ + cerror("soft_minus"); + return x1; +} + +/* + * Convert a hex constant to floating point number. + */ +NODE * +fhexcon(char *s) +{ + cerror("fhexcon"); + return NULL; +} + +/* + * Convert a floating-point constant to D-float and store it in a NODE. + */ +NODE * +floatcon(char *s) +{ + NODE *p; + dword mant; + SF fl, flexp, exp5; + int exp, negexp, bexp; + + exp = 0; + mant = 0; +#define ADDTO(sum, val) sum = sum * 10 + val - '0' + for (; *s >= '0' && *s <= '9'; s++) { + if (mant= '0' && *s <= '9'; s++) { + if (mant= '0' && *s <= '9'; s++) + ADDTO(eexp, *s); + if (sign) + eexp = -eexp; + exp = exp + eexp; + } + + negexp = 1; + if (exp<0) { + negexp = -1; + exp = -exp; + } + + + flexp = soft_cast(1, INT); + exp5 = soft_cast(5, INT); + bexp = exp; + fl = soft_cast(mant, INT); + + for (; exp; exp >>= 1) { + if (exp&01) + flexp = soft_mul(flexp, exp5); + exp5 = soft_mul(exp5, exp5); + } + if (negexp<0) + fl = soft_div(fl, flexp); + else + fl = soft_mul(fl, flexp); + + DEXPSET(fl, DEXP(fl) + negexp*bexp); + p = block(FCON, NIL, NIL, DOUBLE, 0, MKSUE(DOUBLE)); /* XXX type */ + p->n_dcon = fl; + return p; +} +#else +#error missing softfloat definition +#endif +#endif --- /dev/null +++ usr.bin/pcc/mip/compat.h @@ -0,0 +1,45 @@ +/* + * Just compatibility function prototypes. + * Public domain. + */ + +#ifndef COMPAT_H +#define COMPAT_H + +#include + +#ifndef HAVE_STRLCPY +size_t strlcpy(char *dst, const char *src, size_t siz); +#endif + +#ifndef HAVE_STRLCAT +size_t strlcat(char *dst, const char *src, size_t siz); +#endif + +#ifndef HAVE_GETOPT +extern char *optarg; +extern int optind; +int getopt(int, char **, char *); +#endif + +#ifndef HAVE_BASENAME +char *basename(char *); +#endif + +#ifndef HAVE_MKSTEMP +int mkstemp(char *); +#endif + +#ifndef HAVE_FFS +int ffs(int); +#endif + +#ifndef HAVE_SNPRINTF +int snprintf(char *str, size_t count, const char *fmt, ...); +#endif + +#ifndef HAVE_VSNPRINTF +int vsnprintf(char *str, size_t count, const char *fmt, va_list args); +#endif + +#endif From laffer1 at midnightbsd.org Tue Jan 20 16:09:44 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:09:44 -0500 (EST) Subject: [Midnightbsd-cvs] src: usr.bin/pcc: WIP: Update to .99 Message-ID: <200901202109.n0KL9iWd078711@stargazer.midnightbsd.org> Log Message: ----------- WIP: Update to .99 Modified Files: -------------- src/usr.bin/pcc: ccconfig.h (r1.1 -> r1.2) config.h (r1.3 -> r1.4) src/usr.bin/pcc/cc: Makefile (r1.8 -> r1.9) cc.c (r1.2 -> r1.3) src/usr.bin/pcc/ccom: Makefile (r1.2 -> r1.3) ccom.1 (r1.1 -> r1.2) cgram.y (r1.1 -> r1.2) gcc_compat.c (r1.1 -> r1.2) init.c (r1.1 -> r1.2) inline.c (r1.1 -> r1.2) main.c (r1.2 -> r1.3) optim.c (r1.1 -> r1.2) pass1.h (r1.1 -> r1.2) pftn.c (r1.1 -> r1.2) scan.l (r1.1 -> r1.2) stabs.c (r1.1 -> r1.2) symtabs.c (r1.1 -> r1.2) trees.c (r1.1 -> r1.2) src/usr.bin/pcc/cpp: Makefile (r1.6 -> r1.7) cpp.c (r1.3 -> r1.4) cpp.h (r1.2 -> r1.3) cpy.y (r1.1 -> r1.2) scanner.l (r1.1 -> r1.2) token.c (r1.1 -> r1.2) src/usr.bin/pcc/i386: code.c (r1.1 -> r1.2) local.c (r1.1 -> r1.2) local2.c (r1.1 -> r1.2) macdefs.h (r1.1 -> r1.2) order.c (r1.1 -> r1.2) table.c (r1.1 -> r1.2) src/usr.bin/pcc/mip: common.c (r1.1 -> r1.2) compat.c (r1.1 -> r1.2) manifest.h (r1.1 -> r1.2) match.c (r1.1 -> r1.2) mkext.c (r1.1 -> r1.2) node.h (r1.1 -> r1.2) optim2.c (r1.1 -> r1.2) pass2.h (r1.1 -> r1.2) protos.h (r1.1 -> r1.2) reader.c (r1.1 -> r1.2) regs.c (r1.1 -> r1.2) Added Files: ----------- src/usr.bin/pcc/amd64: code.c (r1.1) local.c (r1.1) local2.c (r1.1) macdefs.h (r1.1) order.c (r1.1) table.c (r1.1) src/usr.bin/pcc/cpp: pcpp.1 (r1.1) src/usr.bin/pcc/sparc64: code.c (r1.1) local.c (r1.1) local2.c (r1.1) macdefs.h (r1.1) order.c (r1.1) table.c (r1.1) Removed Files: ------------- src/usr.bin/pcc/cpp: cpp.1 -------------- next part -------------- --- /dev/null +++ usr.bin/pcc/amd64/order.c @@ -0,0 +1,273 @@ +/* $Id: order.c,v 1.1 2008/11/27 05:25:15 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +# include "pass2.h" + +#include + +int canaddr(NODE *); + +/* is it legal to make an OREG or NAME entry which has an + * offset of off, (from a register of r), if the + * resulting thing had type t */ +int +notoff(TWORD t, int r, CONSZ off, char *cp) +{ + return(0); /* YES */ +} + +/* + * Turn a UMUL-referenced node into OREG. + * Be careful about register classes, this is a place where classes change. + */ +void +offstar(NODE *p, int shape) +{ + NODE *r; + + if (x2debug) + printf("offstar(%p)\n", p); + + if (isreg(p)) + return; /* Is already OREG */ + + r = p->n_right; + if( p->n_op == PLUS || p->n_op == MINUS ){ + if( r->n_op == ICON ){ + if (isreg(p->n_left) == 0) + (void)geninsn(p->n_left, INAREG); + /* Converted in ormake() */ + return; + } + if (r->n_op == LS && r->n_right->n_op == ICON && + r->n_right->n_lval == 2 && p->n_op == PLUS) { + if (isreg(p->n_left) == 0) + (void)geninsn(p->n_left, INAREG); + if (isreg(r->n_left) == 0) + (void)geninsn(r->n_left, INAREG); + return; + } + } + (void)geninsn(p, INAREG); +} + +/* + * Do the actual conversion of offstar-found OREGs into real OREGs. + */ +void +myormake(NODE *q) +{ + NODE *p, *r; + + if (x2debug) + printf("myormake(%p)\n", q); + + p = q->n_left; + if (p->n_op == PLUS && (r = p->n_right)->n_op == LS && + r->n_right->n_op == ICON && r->n_right->n_lval == 2 && + p->n_left->n_op == REG && r->n_left->n_op == REG) { + q->n_op = OREG; + q->n_lval = 0; + q->n_rval = R2PACK(p->n_left->n_rval, r->n_left->n_rval, 0); + tfree(p); + } +} + +/* + * Shape matches for UMUL. Cooperates with offstar(). + */ +int +shumul(NODE *p, int shape) +{ + + if (x2debug) + printf("shumul(%p)\n", p); + + /* Turns currently anything into OREG on x86 */ + if (shape & SOREG) + return SROREG; + return SRNOPE; +} + +/* + * Rewrite operations on binary operators (like +, -, etc...). + * Called as a result of table lookup. + */ +int +setbin(NODE *p) +{ + + if (x2debug) + printf("setbin(%p)\n", p); + return 0; + +} + +/* setup for assignment operator */ +int +setasg(NODE *p, int cookie) +{ + if (x2debug) + printf("setasg(%p)\n", p); + return(0); +} + +/* setup for unary operator */ +int +setuni(NODE *p, int cookie) +{ + return 0; +} + +/* + * Special handling of some instruction register allocation. + */ +struct rspecial * +nspecial(struct optab *q) +{ + switch (q->op) { + case OPLOG: + { + static struct rspecial s[] = { { NEVER, EAX }, { 0 } }; + return s; + } + + case STASG: + case STARG: + { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NEVER, ECX }, { 0 } }; + return s; + } + + case DIV: + if (q->lshape == SBREG) { + static struct rspecial s[] = { + { NEVER, AL }, { NEVER, AH }, + { NLEFT, AL }, { NRES, AL }, + { NORIGHT, AH }, { NORIGHT, AL }, { 0 } }; + return s; + } else if (q->lshape == SAREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NLEFT, EAX }, { NRES, EAX }, + { NORIGHT, EDX }, { NORIGHT, EAX }, { 0 } }; + return s; + } else if (q->lshape & SCREG) { + static struct rspecial s[] = { + { NEVER, RAX }, { NEVER, RDX }, + { NLEFT, RAX }, { NRES, RAX }, + { NORIGHT, RDX }, { NORIGHT, RAX }, { 0 } }; + return s; + } + break; + case MOD: + if (q->lshape == SBREG) { + static struct rspecial s[] = { + { NEVER, AL }, { NEVER, AH }, + { NLEFT, AL }, { NRES, AH }, + { NORIGHT, AH }, { NORIGHT, AL }, { 0 } }; + return s; + } else if (q->lshape == SAREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NLEFT, EAX }, { NRES, EDX }, + { NORIGHT, EDX }, { NORIGHT, EAX }, { 0 } }; + return s; + } else if (q->lshape & SCREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NEVER, ECX }, { NRES, RAX }, { 0 } }; + return s; + } + break; + case MUL: + if (q->lshape == SBREG) { + static struct rspecial s[] = { + { NEVER, AL }, { NEVER, AH }, + { NLEFT, AL }, { NRES, AL }, { 0 } }; + return s; + } else if (q->lshape & SCREG) { + static struct rspecial s[] = { + { NEVER, EAX }, { NEVER, EDX }, + { NEVER, ECX }, { NRES, RAX }, { 0 } }; + return s; + } + break; + case LS: + case RS: + static struct rspecial s[] = { + { NRIGHT, CL }, { NOLEFT, RCX }, { 0 } }; + return s; + break; + + default: + break; + } + comperr("nspecial entry %d", q - table); + return 0; /* XXX gcc */ +} + +/* + * Set evaluation order of a binary node if it differs from default. + */ +int +setorder(NODE *p) +{ + return 0; /* nothing differs on x86 */ +} + +/* + * set registers in calling conventions live. + */ +int * +livecall(NODE *p) +{ + static int r[] = { EAX, EBX, -1 }; + int off = 1; + +#ifdef TLS + if (p->n_left->n_op == ICON && + strcmp(p->n_left->n_name, "___tls_get_addr at PLT") == 0) + off--; +#endif + + return kflag ? &r[off] : &r[2]; +} + +/* + * Signal whether the instruction is acceptable for this target. + */ +int +acceptable(struct optab *op) +{ + return 1; +} --- /dev/null +++ usr.bin/pcc/amd64/macdefs.h @@ -0,0 +1,337 @@ +/* $Id: macdefs.h,v 1.2 2008/12/10 17:59:30 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +/* + * Machine-dependent defines for both passes. + */ + +/* + * Convert (multi-)character constant to integer. + */ +#define makecc(val,i) lastcon = (lastcon<<8)|((val<<24)>>24); + +#define ARGINIT 64 /* # bits above fp where arguments start */ +#define AUTOINIT 0 /* # bits below fp where automatics start */ + +/* + * Storage space requirements + */ +#define SZCHAR 8 +#define SZBOOL 8 +#define SZSHORT 16 +#define SZINT 32 +#define SZLONG 64 +#define SZPOINT(t) 64 +#define SZLONGLONG 64 +#define SZFLOAT 32 +#define SZDOUBLE 64 +#define SZLDOUBLE 128 + +/* + * Alignment constraints + */ +#define ALCHAR 8 +#define ALBOOL 8 +#define ALSHORT 16 +#define ALINT 32 +#define ALLONG 64 +#define ALPOINT 64 +#define ALLONGLONG 64 +#define ALFLOAT 32 +#define ALDOUBLE 64 +#define ALLDOUBLE 128 +#define ALSTRUCT 128 +#define ALSTACK 64 +#define ALMAX 128 + +/* + * Min/max values. + */ +#define MIN_CHAR -128 +#define MAX_CHAR 127 +#define MAX_UCHAR 255 +#define MIN_SHORT -32768 +#define MAX_SHORT 32767 +#define MAX_USHORT 65535 +#define MIN_INT (-0x7fffffff-1) +#define MAX_INT 0x7fffffff +#define MAX_UNSIGNED 0xffffffff +#define MIN_LONG MIN_LONGLONG +#define MAX_LONG MAX_LONGLONG +#define MAX_ULONG MAX_ULONGLONG +#define MIN_LONGLONG 0x8000000000000000LL +#define MAX_LONGLONG 0x7fffffffffffffffLL +#define MAX_ULONGLONG 0xffffffffffffffffULL + +/* Default char is signed */ +#undef CHAR_UNSIGNED +#define BOOL_TYPE CHAR /* what used to store _Bool */ +#if defined(os_mirbsd) || defined(os_win32) +#define WCHAR_TYPE USHORT /* ISO 10646 16-bit Unicode */ +#else +#define WCHAR_TYPE INT /* what used to store wchar_t */ +#endif + +/* + * Use large-enough types. + */ +typedef long long CONSZ; +typedef unsigned long long U_CONSZ; +typedef long long OFFSZ; + +#define CONFMT "%lld" /* format for printing constants */ +#define LABFMT ".L%d" /* format for printing labels */ +#define STABLBL ".LL%d" /* format for stab (debugging) labels */ +#ifdef LANG_F77 +#define BLANKCOMMON "_BLNK_" +#define MSKIREG (M(TYSHORT)|M(TYLONG)) +#define TYIREG TYLONG +#define FSZLENG FSZLONG +#define AUTOREG EBP +#define ARGREG EBP +#define ARGOFFSET 8 +#endif + +#define BACKAUTO /* stack grows negatively for automatics */ +#define BACKTEMP /* stack grows negatively for temporaries */ + +#undef FIELDOPS /* no bit-field instructions */ +#define RTOLBYTES /* bytes are numbered right to left */ + +#define ENUMSIZE(high,low) INT /* enums are always stored in full int */ + +#define FINDMOPS /* i386 has instructions that modifies memory */ + +/* Definitions mostly used in pass2 */ + +#define BYTEOFF(x) ((x)&03) +#define wdal(k) (BYTEOFF(k)==0) +#define BITOOR(x) (x) /* bit offset to oreg offset XXX die! */ + +#define STOARG(p) +#define STOFARG(p) +#define STOSTARG(p) +#define genfcall(a,b) gencall(a,b) + +#define szty(t) (((t) == DOUBLE || (t) == FLOAT || (t) == LONG || \ + (t) == ULONG || (t) == LONGLONG || (t) == ULONGLONG) ? 2 : \ + (t) == LDOUBLE ? 4 : 1) + +/* + * The x86 has a bunch of register classes, most of them interfering + * with each other. All registers are given a sequential number to + * identify it which must match rnames[] in local2.c. + * Class membership and overlaps are defined in the macros RSTATUS + * and ROVERLAP below. + * + * The classes used on x86 are: + * A - short and int regs + * B - char regs + * C - long long regs + * D - floating point + */ +#define EAX 000 /* Scratch and return register */ +#define EDX 001 /* Scratch and secondary return register */ +#define ECX 002 /* Scratch (and shift count) register */ +#define EBX 003 /* GDT pointer or callee-saved temporary register */ +#define ESI 004 /* Callee-saved temporary register */ +#define EDI 005 /* Callee-saved temporary register */ +#define EBP 006 /* Frame pointer */ +#define ESP 007 /* Stack pointer */ + +#define AL 010 +#define AH 011 +#define DL 012 +#define DH 013 +#define CL 014 +#define CH 015 +#define BL 016 +#define BH 017 + +#define RAX 020 +#define RDX 021 +#define RCX 022 +#define RBX 023 +#define RSI 024 +#define RDI 025 +#define RBP 026 +#define RSP 027 +#define R08 030 +#define R09 031 +#define R10 032 +#define R11 033 +#define R12 034 +#define R13 035 +#define R14 036 +#define R15 037 + +/* The 8 math registers in class D lacks names */ + +#define MAXREGS 050 /* 40 registers */ + +#define RSTATUS \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|PERMREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, 0, 0, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, 0, 0, \ + SCREG|TEMPREG, SCREG|TEMPREG, SCREG|TEMPREG, SCREG|TEMPREG, \ + SCREG|PERMREG, SCREG|PERMREG, SCREG|PERMREG, SCREG|PERMREG, \ + SDREG, SDREG, SDREG, SDREG, SDREG, SDREG, SDREG, SDREG, + +#define ROVERLAP \ + /* 8 basic registers */\ + { AL, AH, RAX, -1 },\ + { DL, DH, RDX, -1 },\ + { CL, CH, RCX, -1 },\ + { BL, BH, RBX, -1 },\ + { RSI, -1 },\ + { RDI, -1 },\ + { RBP, -1 },\ + { RSP, -1 },\ +\ + /* 8 char registers */\ + { EAX, RAX, -1 },\ + { EAX, RAX, -1 },\ + { EDX, RDX, -1 },\ + { EDX, RDX, -1 },\ + { ECX, RCX, -1 },\ + { ECX, RCX, -1 },\ + { EBX, RBX, -1 },\ + { EBX, RBX, -1 },\ +\ + /* 16 long-long-emulating registers */\ + { EAX, AL, AH, -1 },\ + { EDX, DL, DH, -1 },\ + { ECX, CL, CH, -1 },\ + { EBX, BL, BH, -1 },\ + { ESI, -1 },\ + { EDI, -1 },\ + { EBP, -1 },\ + { ESP, -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ +\ + /* The fp registers do not overlap with anything */\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 },\ + { -1 }, + + +/* Return a register class based on the type of the node */ +#define PCLASS(p) (p->n_type <= UCHAR ? SBREG : \ + (p->n_type == LONG || p->n_type == ULONG || \ + p->n_type == LONGLONG || p->n_type == ULONGLONG ? SCREG : \ + (p->n_type >= FLOAT && p->n_type <= LDOUBLE ? SDREG : SAREG))) + +#define NUMCLASS 4 /* highest number of reg classes used */ + +int COLORMAP(int c, int *r); +#define GCLASS(x) (x < 8 ? CLASSA : x < 16 ? CLASSB : x < 32 ? CLASSC : CLASSD) +#define DECRA(x,y) (((x) >> (y*8)) & 255) /* decode encoded regs */ +#define ENCRD(x) (x) /* Encode dest reg in n_reg */ +#define ENCRA1(x) ((x) << 8) /* A1 */ +#define ENCRA2(x) ((x) << 16) /* A2 */ +#define ENCRA(x,y) ((x) << (8+y*8)) /* encode regs in int */ +/* XXX - return char in al? */ +#define RETREG(x) (x == CHAR || x == UCHAR ? AL : \ + x == LONG || x == ULONG || \ + x == LONGLONG || x == ULONGLONG ? RAX : \ + x == FLOAT || x == DOUBLE || x == LDOUBLE ? 32 : EAX) + +//#define R2REGS 1 /* permit double indexing */ + +/* XXX - to die */ +#define FPREG RBP /* frame pointer */ +#define STKREG RSP /* stack pointer */ + +#define SHSTR (MAXSPECIAL+1) /* short struct */ +#define SFUNCALL (MAXSPECIAL+2) /* struct assign after function call */ +#define SPCON (MAXSPECIAL+3) /* positive nonnamed constant */ + +/* + * Specials that indicate the applicability of machine idioms. + */ +#define SMIXOR (MAXSPECIAL+4) +#define SMILWXOR (MAXSPECIAL+5) +#define SMIHWXOR (MAXSPECIAL+6) + +/* + * i386-specific symbol table flags. + */ +#define SSECTION SLOCAL1 +#define STLS SLOCAL2 +#define SNOUNDERSCORE SLOCAL3 +#define SSTDCALL SLOCAL2 +#define SDLLINDIRECT SLOCAL3 + +/* + * i386-specific node flags. + */ +#define FSTDCALL 0x01 + +/* + * i386-specific interpass stuff. + */ + +#define TARGET_IPP_MEMBERS \ + int ipp_argstacksize; + +/* + * Extended assembler macros. + */ +void targarg(char *w, void *arg); +#define XASM_TARGARG(w, ary) \ + (w[1] == 'b' || w[1] == 'h' || w[1] == 'w' || w[1] == 'k' ? \ + w++, targarg(w, ary), 1 : 0) +int numconv(void *ip, void *p, void *q); +#define XASM_NUMCONV(ip, p, q) numconv(ip, p, q) + +/* + * builtins. + */ +#define TARGET_BUILTINS \ + { "__builtin_frame_address", i386_builtin_frame_address }, \ + { "__builtin_return_address", i386_builtin_return_address }, + +#define NODE struct node +struct node; +NODE *i386_builtin_frame_address(NODE *f, NODE *a); +NODE *i386_builtin_return_address(NODE *f, NODE *a); +#undef NODE --- /dev/null +++ usr.bin/pcc/amd64/table.c @@ -0,0 +1,1568 @@ +/* $Id: table.c,v 1.1 2008/11/27 05:25:15 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +# include "pass2.h" + +# define TLL TLONG|TULONG|TLONGLONG|TULONGLONG +# define ANYSIGNED TINT|TSHORT|TCHAR +# define ANYUSIGNED TUNSIGNED|TUSHORT|TUCHAR +# define ANYFIXED ANYSIGNED|ANYUSIGNED +# define TUWORD TUNSIGNED +# define TSWORD TINT +# define TWORD TUWORD|TSWORD +#define SHINT SAREG /* short and int */ +#define ININT INAREG +#define SHCH SBREG /* shape for char */ +#define INCH INBREG +#define SHLL SCREG /* shape for long long */ +#define INLL INCREG +#define SHFL SDREG /* shape for float/double */ +#define INFL INDREG /* shape for float/double */ + +struct optab table[] = { +/* First entry must be an empty entry */ +{ -1, FOREFF, SANY, TANY, SANY, TANY, 0, 0, "", }, + +/* PCONVs are usually not necessary */ +{ PCONV, INAREG, + SAREG, TWORD|TPOINT, + SAREG, TWORD|TPOINT, + 0, RLEFT, + "", }, + +/* + * A bunch conversions of integral<->integral types + * There are lots of them, first in table conversions to itself + * and then conversions from each type to the others. + */ + +/* itself to itself, including pointers */ + +/* convert (u)char to (u)char. */ +{ SCONV, INCH, + SHCH, TCHAR|TUCHAR, + SHCH, TCHAR|TUCHAR, + 0, RLEFT, + "", }, + +/* convert pointer to (u)longlong. */ +{ SCONV, INLL, + SHLL, TLL|TPOINT, + SHLL, TLL, + 0, RLEFT, + "", }, + +/* convert double <-> float. nothing to do here */ +{ SCONV, INFL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + "", }, + +/* convert pointers to pointers and ints. */ +{ SCONV, ININT, + SHINT, TPOINT|TWORD, + SANY, TPOINT, + 0, RLEFT, + "", }, + +/* char to something */ + +/* convert char to (unsigned) short. */ +{ SCONV, ININT, + SBREG|SOREG|SNAME, TCHAR, + SAREG, TSHORT|TUSHORT, + NASL|NAREG, RESC1, + " movsbw AL,A1\n", }, + +/* convert unsigned char to (u)short. */ +{ SCONV, ININT, + SHCH|SOREG|SNAME, TUCHAR, + SAREG, TSHORT|TUSHORT, + NASL|NAREG, RESC1, + " movzbw AL,A1\n", }, + +/* convert signed char to int (or pointer). */ +{ SCONV, ININT, + SHCH|SOREG|SNAME, TCHAR, + SAREG, TWORD|TPOINT, + NASL|NAREG, RESC1, + " movsbl AL,A1\n", }, + +/* convert unsigned char to (u)int. */ +{ SCONV, ININT, + SHCH|SOREG|SNAME, TUCHAR, + SAREG, TWORD, + NASL|NAREG, RESC1, + " movzbl AL,A1\n", }, + +/* convert char to (u)long long */ +{ SCONV, INLL, + SHCH|SOREG|SNAME, TCHAR, + SANY, TLL, + NCREG|NCSL, RESC1, + " movsbq AL,A1\n", }, + +/* convert unsigned char to (u)long long */ +{ SCONV, INLL, + SHCH|SOREG|SNAME, TUCHAR, + SANY, TLL, + NCREG|NCSL, RESC1, + " movzbq AL,A1\n", }, + +/* convert char (in register) to double XXX - use NTEMP */ +{ SCONV, INFL, + SHCH|SOREG|SNAME, TCHAR, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NAREG|NASL|NDREG, RESC2, + " movsbl AL,A1\n pushl A1\n" /* XXX fpconv */ + " fildl (%rsp)\n addl $8,%rsp\n", }, + +/* convert (u)char (in register) to double XXX - use NTEMP */ +{ SCONV, INFL, + SHCH|SOREG|SNAME, TUCHAR, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NAREG|NASL|NDREG, RESC2, + " movzbl AL,A1\n pushl A1\n" /* XXX fpconv */ + " fildl (%rsp)\n addl $8,%rsp\n", }, + +/* short to something */ + +/* convert short (in memory) to char */ +{ SCONV, INCH, + SNAME|SOREG, TSHORT|TUSHORT, + SHCH, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + " movb AL,A1\n", }, + +/* convert short (in reg) to char. */ +{ SCONV, INCH, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL|NBREG|NBSL, RESC1, + "ZM", }, + +/* convert short to (u)int. */ +{ SCONV, ININT, + SAREG|SOREG|SNAME, TSHORT, + SAREG, TWORD, + NASL|NAREG, RESC1, + " movswl AL,A1\n", }, + +/* convert unsigned short to (u)int. */ +{ SCONV, ININT, + SAREG|SOREG|SNAME, TUSHORT, + SAREG, TWORD, + NASL|NAREG, RESC1, + " movzwl AL,A1\n", }, + +/* convert short to (u)long long */ +{ SCONV, INLL, + SAREG|SOREG|SNAME, TSHORT, + SHLL, TLL, + NCREG|NCSL, RESC1, + " movswq AL,A1\n", }, + +/* convert unsigned short to (u)long long */ +{ SCONV, INLL, + SAREG|SOREG|SNAME, TUSHORT, + SHLL, TLL, + NCREG|NCSL, RESC1, + " movzwq AL,A1\n", }, + +/* convert short (in memory) to float/double */ +{ SCONV, INFL, + SOREG|SNAME, TSHORT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, + " fild AL\n", }, /* XXX fpconv */ + +/* convert short (in register) to float/double */ +{ SCONV, INFL, + SAREG, TSHORT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NTEMP|NDREG, RESC1, /* XXX fpconv */ + " pushw AL\n fild (%rsp)\n addl $8,%rsp\n", }, + +/* convert unsigned short to double XXX - use NTEMP */ +{ SCONV, INFL, + SAREG|SOREG|SNAME, TUSHORT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NAREG|NASL|NDREG|NTEMP, RESC2, + " movzwl AL,A1\n pushl A1\n" /* XXX fpconv */ + " fildl (%rsp)\n addl $8,%esp\n", }, + +/* int to something */ + +/* convert int to char. This is done when register is loaded */ +{ SCONV, INCH, + SAREG, TWORD|TPOINT, + SANY, TCHAR|TUCHAR, + NSPECIAL|NBREG|NBSL, RESC1, + "ZM", }, + +/* convert int to short. Nothing to do */ +{ SCONV, INAREG, + SAREG, TWORD, + SANY, TSHORT|TUSHORT, + 0, RLEFT, + "", }, + +/* convert signed int to (u)long long */ +{ SCONV, INLL, + SHINT, TSWORD, + SHLL, TLL, + NSPECIAL|NCREG|NCSL, RESC1, + " cltd\n", }, + +/* convert unsigned int to (u)long long */ +{ SCONV, INLL, + SHINT|SOREG|SNAME, TUWORD|TPOINT, + SHLL, TLL, + NCSL|NCREG, RESC1, + " movzlq AL,A1\n\n", }, + +/* convert int (in memory) to double */ +{ SCONV, INFL, + SOREG|SNAME, TWORD, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, + " fildl AL\n", }, + +/* convert int (in register) to double */ +{ SCONV, INFL, + SAREG, TWORD, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NTEMP|NDREG, RESC1, /* XXX fpconv */ + " pushl AL\n fildl (%esp)\n addl $8,%esp\n", }, + +/* long long to something */ + +/* convert (u)long long to (u)char (mem->reg) */ +{ SCONV, INCH, + SOREG|SNAME, TLL, + SANY, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + " movb AL,A1\n", }, + +/* convert (u)long long to (u)char (reg->reg, hopefully nothing) */ +{ SCONV, INCH, + SHLL, TLL, + SANY, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + "ZS", }, + +/* convert (u)long long to (u)short (mem->reg) */ +{ SCONV, INAREG, + SOREG|SNAME, TLL, + SAREG, TSHORT|TUSHORT, + NAREG|NASL, RESC1, + " movw AL,A1\n", }, + +/* convert (u)long long to (u)short (reg->reg, hopefully nothing) */ +{ SCONV, INAREG, + SHLL|SOREG|SNAME, TLL, + SAREG, TSHORT|TUSHORT, + NAREG|NASL, RESC1, + "ZS", }, + +/* convert long long to int (mem->reg) */ +{ SCONV, INAREG, + SOREG|SNAME, TLL, + SAREG, TWORD|TPOINT, + NAREG|NASL, RESC1, + " movl AL,A1\n", }, + +/* convert long long to int (reg->reg, hopefully nothing) */ +{ SCONV, INAREG, + SHLL|SOREG|SNAME, TLL, + SAREG, TWORD|TPOINT, + NAREG|NASL, RESC1, + "ZS", }, + +/* convert long long (in memory) to floating */ +{ SCONV, INFL, + SOREG|SNAME, TLONGLONG, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, /* XXX fpconv */ + " fildq AL\n", }, + +/* convert long long (in register) to floating */ +{ SCONV, INFL, + SHLL, TLONGLONG, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + NTEMP|NDREG, RESC1, /* XXX fpconv */ + " pushq AL\n\n" + " fildq (%esp)\n addl $8,%esp\n", }, + +/* convert unsigned long long to floating */ +{ SCONV, INFL, + SCREG, TULONGLONG, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NDREG, RESC1, /* XXX fpconv */ + "ZJ", }, + +/* float to something */ + +#if 0 /* go via int by adding an extra sconv in clocal() */ +/* convert float/double to (u) char. XXX should use NTEMP here */ +{ SCONV, INCH, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHCH, TWORD|TSHORT|TUSHORT|TCHAR|TUCHAR, + NBREG, RESC1, /* XXX fpconv */ + " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, + +/* convert float/double to (u) int/short/char. XXX should use NTEMP here */ +{ SCONV, INCH, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHCH, TWORD|TSHORT|TUSHORT|TCHAR|TUCHAR, + NCREG, RESC1, /* XXX fpconv */ + " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, +#endif + +/* convert float/double to (u)int. XXX should use NTEMP here */ +{ SCONV, INAREG, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SAREG, TWORD, + NAREG, RESC1, /* XXX fpconv */ +#ifdef notdef /* Must round down and nothing else */ + " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, +#else + " subl $12,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpl 8(%esp)\n" + " movl 8(%esp),A1\n" + " fldcw 4(%esp)\n" + " addl $12,%esp\n", }, +#endif + +/* convert float/double (in register) to (unsigned) long long */ +/* XXX - unsigned is not handled correct */ +{ SCONV, INLL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHLL, TLONGLONG|TULONGLONG, + NCREG, RESC1, /* XXX fpconv */ +#ifdef notdef /* Must round down and nothing else */ + " subl $8,%esp\n fistpq (%esp)\n" + " popl A1\n popl U1\n", }, +#else + " subl $16,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpq 8(%esp)\n" + " movl 8(%esp),A1\n" + " movl 12(%esp),U1\n" + " fldcw 4(%esp)\n" + " addl $16,%esp\n", }, +#endif + +/* slut sconv */ + +/* + * Subroutine calls. + */ + +{ CALL, FOREFF, + SCON, TANY, + SANY, TANY, + 0, 0, + " call CL\nZC", }, + +{ UCALL, FOREFF, + SCON, TANY, + SAREG, TWORD|TPOINT, + 0, 0, + " call CL\n", }, + +{ CALL, INAREG, + SCON, TANY, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INAREG, + SCON, TANY, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\n", }, + +{ CALL, INBREG, + SCON, TANY, + SBREG, TCHAR|TUCHAR, + NBREG, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INBREG, + SCON, TANY, + SBREG, TCHAR|TUCHAR, + NBREG, RESC1, /* should be 0 */ + " call CL\n", }, + +{ CALL, INCREG, + SCON, TANY, + SCREG, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INCREG, + SCON, TANY, + SCREG, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call CL\n", }, + +{ CALL, INDREG, + SCON, TANY, + SDREG, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ UCALL, INDREG, + SCON, TANY, + SDREG, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ CALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call *AL\nZC", }, + +{ UCALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call *AL\nZC", }, + +{ CALL, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ CALL, INBREG, + SAREG, TANY, + SANY, TANY, + NBREG|NBSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INBREG, + SAREG, TANY, + SANY, TANY, + NBREG|NBSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ CALL, INCREG, + SAREG, TANY, + SANY, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INCREG, + SAREG, TANY, + SANY, TANY, + NCREG|NCSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ CALL, INDREG, + SAREG, TANY, + SANY, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ UCALL, INDREG, + SAREG, TANY, + SANY, TANY, + NDREG|NDSL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +/* struct return */ +{ USTCALL, FOREFF, + SCON, TANY, + SANY, TANY, + NAREG|NASL, 0, + " call CL\nZC", }, + +{ USTCALL, INAREG, + SCON, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ USTCALL, INAREG, + SNAME|SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +{ STCALL, FOREFF, + SCON, TANY, + SANY, TANY, + NAREG|NASL, 0, + " call CL\nZC", }, + +{ STCALL, INAREG, + SCON, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call CL\nZC", }, + +{ STCALL, INAREG, + SNAME|SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, /* should be 0 */ + " call *AL\nZC", }, + +/* + * The next rules handle all binop-style operators. + */ +{ PLUS, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " faddl AR\n", }, + +{ PLUS, INFL|FOREFF, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " faddp\n", }, + +{ PLUS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL|TPOINT, + SONE, TANY, + 0, RLEFT, + " incq AL\n", }, + +{ PLUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SONE, TANY, + 0, RLEFT, + " incl AL\n", }, + +{ PLUS, INLL, + SCREG, TLL|TPOINT, + SCON, TWORD, + NCREG|NCSL, RESC1, + " leaq CR(AL),A1\n", }, + +{ PLUS, INAREG, + SAREG, TWORD, + SCON, TANY, + NAREG|NASL, RESC1, + " leal CR(AL),A1\n", }, + +{ PLUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " incw AL\n", }, + +{ PLUS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SONE, TANY, + 0, RLEFT, + " incb AL\n", }, + +{ PLUS, INAREG, + SAREG, TWORD, + SAREG, TWORD, + NAREG|NASL|NASR, RESC1, + " leal (AL,AR),A1\n", }, + +{ MINUS, INLL|FOREFF, + SCREG|SNAME|SOREG, TLL|TPOINT, + SONE, TANY, + 0, RLEFT, + " decq AL\n", }, + +{ MINUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SONE, TANY, + 0, RLEFT, + " decl AL\n", }, + +{ MINUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " decw AL\n", }, + +{ MINUS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SONE, TANY, + 0, RLEFT, + " decb AL\n", }, + +/* address as register offset, negative */ +{ MINUS, INAREG, + SAREG, TWORD|TPOINT, + SPCON, TANY, + NAREG|NASL, RESC1, + " leal -CR(AL),A1\n", }, + +{ MINUS, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " fsubl AR\n", }, + +{ MINUS, INFL|FOREFF, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fsubZAp\n", }, + +/* Simple r/m->reg ops */ +/* m/r |= r */ +{ OPSIMP, INLL|FOREFF|FORCC, + SHLL|SNAME|SOREG, TLL|TPOINT, + SHLL, TLL|TPOINT, + 0, RLEFT|RESCC, + " Oq AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INLL|FOREFF|FORCC, + SHLL, TLL|TPOINT, + SHLL|SNAME|SOREG, TLL|TPOINT, + 0, RLEFT|RESCC, + " Oq AR,AL\n", }, + +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD, + SAREG, TWORD, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG, TWORD|TPOINT, + SAREG|SNAME|SOREG, TWORD|TPOINT, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + SHINT, TSHORT|TUSHORT, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT, TSHORT|TUSHORT, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +/* m/r |= r */ +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* m/r |= const */ +{ OPSIMP, INLL|FOREFF|FORCC, + SCREG|SNAME|SOREG, TLL, + SCON, TWORD, + 0, RLEFT|RESCC, + " Oq AR,AL\n", }, + +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD, + SCON, TWORD, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + SCON, TANY, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SCON, TANY, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INLL|FOREFF, + SHLL, TLL|TPOINT, + SHLL|SNAME|SOREG, TLL|TPOINT, + 0, RLEFT, + " Oq AR,AL\n", }, + +/* + * The next rules handle all shift operators. + */ +/* r/m <<= r */ +{ LS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL, + SHLL, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " salq AR,AL\n", }, + +/* r/m <<= const */ +{ LS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL, + SCON, TANY, + 0, RLEFT, + " salq AR,AL\n", }, + +/* r/m <<= r */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sall AR,AL\n", }, + +/* r/m <<= const */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TWORD, + SCON, TANY, + 0, RLEFT, + " sall AR,AL\n", }, + +/* r/m <<= r */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shlw AR,AL\n", }, + +/* r/m <<= const */ +{ LS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SCON, TANY, + 0, RLEFT, + " shlw AR,AL\n", }, + +{ LS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " salb AR,AL\n", }, + +{ LS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SCON, TANY, + 0, RLEFT, + " salb AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLONG|TLONGLONG, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarq AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TLONG|TLONGLONG, + SCON, TANY, + 0, RLEFT, + " sarq AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TULONG|TULONGLONG, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrq AR,AL\n", }, + +{ RS, INLL|FOREFF, + SHLL|SNAME|SOREG, TULONG|TULONGLONG, + SCON, TANY, + 0, RLEFT, + " shrq AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSWORD, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSWORD, + SCON, TANY, + 0, RLEFT, + " sarl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUWORD, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUWORD, + SCON, TANY, + 0, RLEFT, + " shrl AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarw AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT, + SCON, TANY, + 0, RLEFT, + " sarw AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUSHORT, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrw AR,AL\n", }, + +{ RS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TUSHORT, + SCON, TANY, + 0, RLEFT, + " shrw AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " sarb AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TCHAR, + SCON, TANY, + 0, RLEFT, + " sarb AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TUCHAR, + SHCH, TCHAR|TUCHAR, + NSPECIAL, RLEFT, + " shrb AR,AL\n", }, + +{ RS, INCH|FOREFF, + SHCH|SNAME|SOREG, TUCHAR, + SCON, TANY, + 0, RLEFT, + " shrb AR,AL\n", }, + +/* + * The next rules takes care of assignments. "=". + */ +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL|TPOINT, + SMIXOR, TANY, + 0, RDEST, + " xorq AL,AL\n\n", }, + +{ ASSIGN, FOREFF|INLL, + SHLL, TLL|TPOINT, + SCON, TANY, + 0, RDEST, + " movabs AR,AL\n", }, + +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TWORD, + SMIXOR, TANY, + 0, RDEST, + " xorl AL,AL\n", }, + +{ ASSIGN, FOREFF, + SAREG|SNAME|SOREG, TWORD, + SCON, TANY, + 0, 0, + " movl AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TWORD, + SCON, TANY, + 0, RDEST, + " movl AR,AL\n", }, + +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + 0, RDEST, + " xorw AL,AL\n", }, + +{ ASSIGN, FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SCON, TANY, + 0, 0, + " movw AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TSHORT|TUSHORT, + SCON, TANY, + 0, RDEST, + " movw AR,AL\n", }, + +{ ASSIGN, FOREFF, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SCON, TANY, + 0, 0, + " movb AR,AL\n", }, + +{ ASSIGN, FOREFF|INCH, + SHCH, TCHAR|TUCHAR, + SCON, TANY, + 0, RDEST, + " movb AR,AL\n", }, + +{ ASSIGN, FOREFF|INLL, + SHLL|SNAME|SOREG, TLL, + SHLL, TLL, + 0, RDEST, + " movq AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG|SNAME|SOREG, TWORD|TPOINT, + SAREG, TWORD|TPOINT, + 0, RDEST, + " movl AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TWORD|TPOINT, + SAREG|SNAME|SOREG, TWORD|TPOINT, + 0, RDEST, + " movl AR,AL\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + 0, RDEST, + " movw AR,AL\n", }, + +{ ASSIGN, FOREFF|INCH, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + SHCH, TCHAR|TUCHAR|TWORD, + 0, RDEST, + " movb AR,AL\n", }, + +{ ASSIGN, FOREFF|INBREG, + SFLD, TCHAR|TUCHAR, + SBREG|SCON, TCHAR|TUCHAR, + NAREG|NBREG, RDEST, + " movb AR,A2\n" + " movzbl A2,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movb AR,AD\n" + "FZE", }, + +{ ASSIGN, FOREFF|INAREG, + SFLD, TSHORT|TUSHORT, + SAREG|SCON, TSHORT|TUSHORT, + NAREG, RDEST, + " movw AR,A1\n" + " movzwl A1,ZN\n" + " andl $N,AL\n" + " sall $H,ZN\n" + " andl $M,ZN\n" + " orl ZN,AL\n" + "F movw AR,AD\n" + "FZE", }, + +{ ASSIGN, FOREFF|INAREG, + SFLD, TWORD, + SAREG|SNAME|SOREG|SCON, TWORD, + NAREG, RDEST, + " movl AR,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movl AR,AD\n" + "FZE", }, + +{ ASSIGN, INDREG|FOREFF, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + "", }, /* This will always be in the correct register */ + +/* order of table entries is very important here! */ +{ ASSIGN, INFL, + SNAME|SOREG, TLDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + " fst AL\n", }, + +{ ASSIGN, FOREFF, + SNAME|SOREG, TLDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, 0, + " fstpt AL\n", }, + +{ ASSIGN, INFL, + SNAME|SOREG, TDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + " fstl AL\n", }, + +{ ASSIGN, FOREFF, + SNAME|SOREG, TDOUBLE, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, 0, + " fstpl AL\n", }, + +{ ASSIGN, INFL, + SNAME|SOREG, TFLOAT, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, RDEST, + " fsts AL\n", }, + +{ ASSIGN, FOREFF, + SNAME|SOREG, TFLOAT, + SHFL, TFLOAT|TDOUBLE|TLDOUBLE, + 0, 0, + " fstps AL\n", }, +/* end very important order */ + +{ ASSIGN, INFL|FOREFF, + SHFL, TLDOUBLE, + SHFL|SOREG|SNAME, TLDOUBLE, + 0, RDEST, + " fldt AR\n", }, + +{ ASSIGN, INFL|FOREFF, + SHFL, TDOUBLE, + SHFL|SOREG|SNAME, TDOUBLE, + 0, RDEST, + " fldl AR\n", }, + +{ ASSIGN, INFL|FOREFF, + SHFL, TFLOAT, + SHFL|SOREG|SNAME, TFLOAT, + 0, RDEST, + " flds AR\n", }, + +/* Do not generate memcpy if return from funcall */ +#if 0 +{ STASG, INAREG|FOREFF, + SOREG|SNAME|SAREG, TPTRTO|TSTRUCT, + SFUNCALL, TPTRTO|TSTRUCT, + 0, RRIGHT, + "", }, +#endif + +{ STASG, INAREG|FOREFF, + SOREG|SNAME, TANY, + SAREG|SOREG|SNAME, TPTRTO|TANY, + NSPECIAL, RRIGHT, + "ZQ", }, + +/* + * DIV/MOD/MUL + */ +{ DIV, INLL, + SCREG, TLONG|TLONGLONG, + SCREG|SNAME|SOREG, TLL, + NSPECIAL, RDEST, + " cltd\n idivq AR\n", }, + +{ DIV, INAREG, + SAREG, TULONG|TULONGLONG|TPOINT, + SAREG|SNAME|SOREG, TULONG|TULONGLONG|TPOINT, + NSPECIAL, RDEST, + " xorq %rdx,%rdx\n divq AR\n", }, + +{ DIV, INAREG, + SAREG, TSWORD, + SAREG|SNAME|SOREG, TWORD, + NSPECIAL, RDEST, + " cltd\n idivl AR\n", }, + +{ DIV, INAREG, + SAREG, TUWORD, + SAREG|SNAME|SOREG, TUWORD, + NSPECIAL, RDEST, + " xorl %edx,%edx\n divl AR\n", }, + +{ DIV, INAREG, + SAREG, TUSHORT, + SAREG|SNAME|SOREG, TUSHORT, + NSPECIAL, RDEST, + " xorl %edx,%edx\n divw AR\n", }, + +{ DIV, INCH, + SHCH, TUCHAR, + SHCH|SNAME|SOREG, TUCHAR, + NSPECIAL, RDEST, + " xorb %ah,%ah\n divb AR\n", }, + +{ DIV, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " fdivl AR\n", }, + +{ DIV, INFL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fdivZAp\n", }, + +{ MOD, INLL, + SCREG, TLONG|TLONGLONG, + SCREG|SNAME|SOREG, TLONG|TLONGLONG, + NCREG|NSPECIAL, RESC1, + " cltd\n idivq AR\n", }, + +{ MOD, INLL, + SCREG, TLL|TPOINT, + SCREG|SNAME|SOREG, TULONG|TULONGLONG|TPOINT, + NCREG|NSPECIAL, RESC1, + " xorq %rdx,%rdx\n divq AR\n", }, + +{ MOD, INAREG, + SAREG, TSWORD, + SAREG|SNAME|SOREG, TSWORD, + NAREG|NSPECIAL, RESC1, + " cltd\n idivl AR\n", }, + +{ MOD, INAREG, + SAREG, TWORD, + SAREG|SNAME|SOREG, TUWORD, + NAREG|NSPECIAL, RESC1, + " xorl %edx,%edx\n divl AR\n", }, + +{ MOD, INAREG, + SAREG, TUSHORT, + SAREG|SNAME|SOREG, TUSHORT, + NAREG|NSPECIAL, RESC1, + " xorl %edx,%edx\n divw AR\n", }, + +{ MOD, INCH, + SHCH, TUCHAR, + SHCH|SNAME|SOREG, TUCHAR, + NBREG|NSPECIAL, RESC1, + " xorb %ah,%ah\n divb AR\n", }, + +{ MUL, INLL, + SCREG, TLL|TPOINT, + SCREG|SNAME|SOREG|SCON, TLL|TPOINT, + 0, RLEFT, + " imulq AR,AL\n", }, + +{ MUL, INAREG, + SAREG, TWORD, + SAREG|SNAME|SOREG|SCON, TWORD, + 0, RLEFT, + " imull AR,AL\n", }, + +{ MUL, INAREG, + SAREG, TSHORT|TUSHORT, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + 0, RLEFT, + " imulw AR,AL\n", }, + +{ MUL, INCH, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + NSPECIAL, RDEST, + " imulb AR\n", }, + +{ MUL, INFL, + SHFL, TDOUBLE, + SNAME|SOREG, TDOUBLE, + 0, RLEFT, + " fmull AR\n", }, + +{ MUL, INFL, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fmulp\n", }, + +/* + * Indirection operators. + */ +{ UMUL, INLL, + SANY, TANY, + SOREG, TLL|TPOINT, + NCREG, RESC1, + " movq AL,A1\n", }, + +{ UMUL, INAREG, + SANY, TWORD, + SOREG, TWORD, + NAREG|NASL, RESC1, + " movl AL,A1\n", }, + +{ UMUL, INCH, + SANY, TANY, + SOREG, TCHAR|TUCHAR, + NBREG|NBSL, RESC1, + " movb AL,A1\n", }, + +{ UMUL, INAREG, + SANY, TANY, + SOREG, TSHORT|TUSHORT, + NAREG|NASL, RESC1, + " movw AL,A1\n", }, + +{ UMUL, INFL, + SANY, TANY, + SOREG, TLDOUBLE, + NDREG|NDSL, RESC1, + " fldt AL\n", }, + +{ UMUL, INFL, + SANY, TANY, + SOREG, TDOUBLE, + NDREG|NDSL, RESC1, + " fldl AL\n", }, + +{ UMUL, INFL, + SANY, TANY, + SOREG, TFLOAT, + NDREG|NDSL, RESC1, + " flds AL\n", }, + +/* + * Logical/branching operators + */ + +/* Comparisions, take care of everything */ +{ OPLOG, FORCC, + SCON, TWORD, + SHLL|SOREG|SNAME, TLL|TPOINT, + 0, RESCC, + " cmpq AR,AL\n", }, + +{ OPLOG, FORCC, + SHLL, TLL|TPOINT, + SHLL|SOREG|SNAME, TLL|TPOINT, + 0, RESCC, + " cmpq AR,AL\n", }, + +{ OPLOG, FORCC, + SHLL|SOREG|SNAME, TLL|TPOINT, + SHLL, TLL|TPOINT, + 0, RESCC, + " cmpq AR,AL\n", }, + +{ OPLOG, FORCC, + SAREG|SOREG|SNAME, TWORD, + SCON|SAREG, TWORD, + 0, RESCC, + " cmpl AR,AL\n", }, + +{ OPLOG, FORCC, + SCON|SAREG, TWORD, + SAREG|SOREG|SNAME, TWORD, + 0, RESCC, + " cmpl AR,AL\n", }, + +{ OPLOG, FORCC, + SAREG|SOREG|SNAME, TSHORT|TUSHORT, + SCON|SAREG, TANY, + 0, RESCC, + " cmpw AR,AL\n", }, + +{ OPLOG, FORCC, + SBREG|SOREG|SNAME, TCHAR|TUCHAR, + SCON|SBREG, TANY, + 0, RESCC, + " cmpb AR,AL\n", }, + +{ OPLOG, FORCC, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NSPECIAL, 0, + "ZG", }, + +{ OPLOG, FORCC, + SOREG|SNAME, TDOUBLE|TFLOAT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + NSPECIAL, 0, + "ZG", }, + +#if 0 +/* Ppro and later only */ +{ OPLOG, FORCC, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + SDREG, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RESCC, + "ZA fucomip %st,%st(1)\n", }, +#endif + +{ OPLOG, FORCC, + SANY, TANY, + SANY, TANY, + REWRITE, 0, + "diediedie!", }, + +/* AND/OR/ER/NOT */ +{ AND, INAREG|FOREFF, + SCREG|SOREG|SNAME, TLL, + SCON, TWORD, + 0, RLEFT, + " andq AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SCREG|SOREG|SNAME, TLL, + SCREG, TLL, + 0, RLEFT, + " andq AR,AL\n", }, + +{ AND, INCREG|FOREFF, + SCREG, TLL, + SCREG|SOREG|SNAME, TLL, + 0, RLEFT, + " andq AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG|SOREG|SNAME, TWORD, + SCON|SAREG, TWORD, + 0, RLEFT, + " andl AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG, TWORD, + SAREG|SOREG|SNAME, TWORD, + 0, RLEFT, + " andl AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG|SOREG|SNAME, TSHORT|TUSHORT, + SCON|SAREG, TSHORT|TUSHORT, + 0, RLEFT, + " andw AR,AL\n", }, + +{ AND, INAREG|FOREFF, + SAREG, TSHORT|TUSHORT, + SAREG|SOREG|SNAME, TSHORT|TUSHORT, + 0, RLEFT, + " andw AR,AL\n", }, + +{ AND, INBREG|FOREFF, + SBREG|SOREG|SNAME, TCHAR|TUCHAR, + SCON|SBREG, TCHAR|TUCHAR, + 0, RLEFT, + " andb AR,AL\n", }, + +{ AND, INBREG|FOREFF, + SBREG, TCHAR|TUCHAR, + SBREG|SOREG|SNAME, TCHAR|TUCHAR, + 0, RLEFT, + " andb AR,AL\n", }, +/* AND/OR/ER/NOT */ + +/* + * Jumps. + */ +{ GOTO, FOREFF, + SCON, TANY, + SANY, TANY, + 0, RNOP, + " jmp LL\n", }, + +#if defined(GCC_COMPAT) || defined(LANG_F77) +{ GOTO, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, RNOP, + " jmp *AL\n", }, +#endif + +/* + * Convert LTYPE to reg. + */ +{ OPLTYPE, FORCC|INLL, + SCREG, TLL|TPOINT, + SMIXOR, TANY, + NCREG, RESC1, + " xorq A1,A1\n", }, + +{ OPLTYPE, INLL, + SANY, TANY, + SCREG|SCON|SOREG|SNAME, TLL|TPOINT, + NCREG, RESC1, + " movq AL,A1\n", }, + +{ OPLTYPE, FORCC|INAREG, + SAREG, TWORD, + SMIXOR, TANY, + NAREG|NASL, RESC1, + " xorl A1,A1\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SAREG|SCON|SOREG|SNAME, TWORD, + NAREG|NASL, RESC1, + " movl AL,A1\n", }, + +{ OPLTYPE, INBREG, + SANY, TANY, + SBREG|SOREG|SNAME|SCON, TCHAR|TUCHAR, + NBREG, RESC1, + " movb AL,A1\n", }, + +{ OPLTYPE, FORCC|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + NAREG, RESC1, + " xorw A1,A1\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SAREG|SOREG|SNAME|SCON, TSHORT|TUSHORT, + NAREG, RESC1, + " movw AL,A1\n", }, + +{ OPLTYPE, INDREG, + SANY, TLDOUBLE, + SOREG|SNAME, TLDOUBLE, + NDREG, RESC1, + " fldt AL\n", }, + +{ OPLTYPE, INDREG, + SANY, TDOUBLE, + SOREG|SNAME, TDOUBLE, + NDREG, RESC1, + " fldl AL\n", }, + +{ OPLTYPE, INDREG, + SANY, TFLOAT, + SOREG|SNAME, TFLOAT, + NDREG, RESC1, + " flds AL\n", }, + +/* Only used in ?: constructs. The stack already contains correct value */ +{ OPLTYPE, INDREG, + SANY, TFLOAT|TDOUBLE|TLDOUBLE, + SDREG, TFLOAT|TDOUBLE|TLDOUBLE, + NDREG, RESC1, + "", }, + +/* + * Negate a word. + */ + +{ UMINUS, INCREG|FOREFF, + SCREG, TLL|TPOINT, + SCREG, TLL|TPOINT, + 0, RLEFT, + " negq AL\n", }, + +{ UMINUS, INAREG|FOREFF, + SAREG, TWORD, + SAREG, TWORD, + 0, RLEFT, + " negl AL\n", }, + +{ UMINUS, INAREG|FOREFF, + SAREG, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + 0, RLEFT, + " negw AL\n", }, + +{ UMINUS, INBREG|FOREFF, + SBREG, TCHAR|TUCHAR, + SBREG, TCHAR|TUCHAR, + 0, RLEFT, + " negb AL\n", }, + +{ UMINUS, INFL|FOREFF, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + SHFL, TLDOUBLE|TDOUBLE|TFLOAT, + 0, RLEFT, + " fchs\n", }, + +{ COMPL, INCREG, + SCREG, TLL, + SANY, TANY, + 0, RLEFT, + " notq AL\n", }, + +{ COMPL, INAREG, + SAREG, TWORD, + SANY, TANY, + 0, RLEFT, + " notl AL\n", }, + +{ COMPL, INAREG, + SAREG, TSHORT|TUSHORT, + SANY, TANY, + 0, RLEFT, + " notw AL\n", }, + +{ COMPL, INBREG, + SBREG, TCHAR|TUCHAR, + SANY, TANY, + 0, RLEFT, + " notb AL\n", }, + +# define DF(x) FORREW,SANY,TANY,SANY,TANY,REWRITE,x,"" + +{ UMUL, DF( UMUL ), }, + +{ ASSIGN, DF(ASSIGN), }, + +{ STASG, DF(STASG), }, + +{ FLD, DF(FLD), }, + +{ OPLEAF, DF(NAME), }, + +/* { INIT, DF(INIT), }, */ + +{ OPUNARY, DF(UMINUS), }, + +{ OPANY, DF(BITYPE), }, + +{ FREE, FREE, FREE, FREE, FREE, FREE, FREE, FREE, "help; I'm in trouble\n" }, +}; + +int tablesize = sizeof(table)/sizeof(table[0]); --- /dev/null +++ usr.bin/pcc/amd64/local2.c @@ -0,0 +1,1163 @@ +/* $Id: local2.c,v 1.1 2008/11/27 05:25:15 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + +# include "pass2.h" +# include +# include + +static int stkpos; + +void +deflab(int label) +{ + printf(LABFMT ":\n", label); +} + +static int regoff[7]; +static TWORD ftype; + +/* + * Print out the prolog assembler. + * addto and regoff are already calculated. + */ +static void +prtprolog(struct interpass_prolog *ipp, int addto) +{ + static int lwnr; + int i; + + printf(" pushl %%ebp\n"); + printf(" movl %%esp,%%ebp\n"); + if (addto) + printf(" subl $%d,%%esp\n", addto); + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) + fprintf(stdout, " movl %s,-%d(%s)\n", + rnames[i], regoff[i], rnames[FPREG]); + if (kflag == 0) + return; + + /* if ebx are not saved to stack, it must be moved into another reg */ + /* check and emit the move before GOT stuff */ + if (!TESTBIT(ipp->ipp_regs, EBX)) { + struct interpass *ip = (struct interpass *)ipp; + + ip = DLIST_PREV(ip, qelem); + ip = DLIST_PREV(ip, qelem); + ip = DLIST_PREV(ip, qelem); + if (ip->type != IP_NODE || ip->ip_node->n_op != ASSIGN || + ip->ip_node->n_left->n_op != REG) + comperr("prtprolog pic error"); + ip = (struct interpass *)ipp; + ip = DLIST_NEXT(ip, qelem); + if (ip->type != IP_NODE || ip->ip_node->n_op != ASSIGN || + ip->ip_node->n_left->n_op != REG) + comperr("prtprolog pic error2"); + printf(" movl %s,%s\n", + rnames[ip->ip_node->n_right->n_rval], + rnames[ip->ip_node->n_left->n_rval]); + tfree(ip->ip_node); + DLIST_REMOVE(ip, qelem); + } + printf(" call .LW%d\n", ++lwnr); + printf(".LW%d:\n", lwnr); + printf(" popl %%ebx\n"); + printf(" addl $_GLOBAL_OFFSET_TABLE_+[.-.LW%d], %%ebx\n", lwnr); +} + +/* + * calculate stack size and offsets + */ +static int +offcalc(struct interpass_prolog *ipp) +{ + int i, addto; + + addto = p2maxautooff; + if (addto >= AUTOINIT/SZCHAR) + addto -= AUTOINIT/SZCHAR; + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) { + addto += SZINT/SZCHAR; + regoff[i] = addto; + } + return addto; +} + +void +prologue(struct interpass_prolog *ipp) +{ + int addto; + + ftype = ipp->ipp_type; + +#ifdef LANG_F77 + if (ipp->ipp_vis) + printf(" .globl %s\n", ipp->ipp_name); + printf(" .align 4\n"); + printf("%s:\n", ipp->ipp_name); +#endif + /* + * We here know what register to save and how much to + * add to the stack. + */ + addto = offcalc(ipp); + prtprolog(ipp, addto); +} + +void +eoftn(struct interpass_prolog *ipp) +{ + int i; + + if (ipp->ipp_ip.ip_lbl == 0) + return; /* no code needs to be generated */ + + /* return from function code */ + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) + fprintf(stdout, " movl -%d(%s),%s\n", + regoff[i], rnames[FPREG], rnames[i]); + + /* struct return needs special treatment */ + if (ftype == STRTY || ftype == UNIONTY) { + printf(" movl 8(%%ebp),%%eax\n"); + printf(" leave\n"); + printf(" ret $%d\n", 4); + } else { + printf(" leave\n"); + } + printf("\t.size %s,.-%s\n", ipp->ipp_name, + ipp->ipp_name); +} + +/* + * add/sub/... + * + * Param given: + */ +void +hopcode(int f, int o) +{ + char *str; + + switch (o) { + case PLUS: + str = "add"; + break; + case MINUS: + str = "sub"; + break; + case AND: + str = "and"; + break; + case OR: + str = "or"; + break; + case ER: + str = "xor"; + break; + default: + comperr("hopcode2: %d", o); + str = 0; /* XXX gcc */ + } + printf("%s%c", str, f); +} + +/* + * Return type size in bytes. Used by R2REGS, arg 2 to offset(). + */ +int +tlen(p) NODE *p; +{ + switch(p->n_type) { + case CHAR: + case UCHAR: + return(1); + + case SHORT: + case USHORT: + return(SZSHORT/SZCHAR); + + case DOUBLE: + return(SZDOUBLE/SZCHAR); + + case INT: + case UNSIGNED: + return(SZINT/SZCHAR); + + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + return SZLONGLONG/SZCHAR; + + default: + if (!ISPTR(p->n_type)) + comperr("tlen type %d not pointer"); + return SZPOINT(p->n_type)/SZCHAR; + } +} + +/* + * Emit code to compare two longlong numbers. + */ +static void +twollcomp(NODE *p) +{ + int o = p->n_op; + int s = getlab(); + int e = p->n_label; + int cb1, cb2; + + if (o >= ULE) + o -= (ULE-LE); + switch (o) { + case NE: + cb1 = 0; + cb2 = NE; + break; + case EQ: + cb1 = NE; + cb2 = 0; + break; + case LE: + case LT: + cb1 = GT; + cb2 = LT; + break; + case GE: + case GT: + cb1 = LT; + cb2 = GT; + break; + + default: + cb1 = cb2 = 0; /* XXX gcc */ + } + if (p->n_op >= ULE) + cb1 += 4, cb2 += 4; + expand(p, 0, " cmpl UR,UL\n"); + if (cb1) cbgen(cb1, s); + if (cb2) cbgen(cb2, e); + expand(p, 0, " cmpl AR,AL\n"); + cbgen(p->n_op, e); + deflab(s); +} + +int +fldexpand(NODE *p, int cookie, char **cp) +{ + CONSZ val; + + if (p->n_op == ASSIGN) + p = p->n_left; + switch (**cp) { + case 'S': + printf("%d", UPKFSZ(p->n_rval)); + break; + case 'H': + printf("%d", UPKFOFF(p->n_rval)); + break; + case 'M': + case 'N': + val = (CONSZ)1 << UPKFSZ(p->n_rval); + --val; + val <<= UPKFOFF(p->n_rval); + printf("0x%llx", (**cp == 'M' ? val : ~val) & 0xffffffff); + break; + default: + comperr("fldexpand"); + } + return 1; +} + +static void +bfext(NODE *p) +{ + int ch = 0, sz = 0; + + if (ISUNSIGNED(p->n_right->n_type)) + return; + switch (p->n_right->n_type) { + case CHAR: + ch = 'b'; + sz = 8; + break; + case SHORT: + ch = 'w'; + sz = 16; + break; + case INT: + ch = 'l'; + sz = 32; + break; + case LONG: + ch = 'q'; + sz = 64; + break; + default: + comperr("bfext"); + } + + sz -= UPKFSZ(p->n_left->n_rval); + printf("\tshl%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n\tsar%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n"); +} + +/* + * Push a structure on stack as argument. + * the scratch registers are already free here + */ +static void +starg(NODE *p) +{ + FILE *fp = stdout; + + fprintf(fp, " subl $%d,%%esp\n", p->n_stsize); + fprintf(fp, " pushl $%d\n", p->n_stsize); + expand(p, 0, " pushl AL\n"); + expand(p, 0, " leal 8(%esp),A1\n"); + expand(p, 0, " pushl A1\n"); + fprintf(fp, " call memcpy\n"); + fprintf(fp, " addl $12,%%esp\n"); +} + +/* + * Compare two floating point numbers. + */ +static void +fcomp(NODE *p) +{ + + if (p->n_left->n_op == REG) { + if (p->n_su & DORIGHT) + expand(p, 0, " fxch\n"); + expand(p, 0, " fucompp\n"); /* emit compare insn */ + } else if (p->n_left->n_type == DOUBLE) + expand(p, 0, " fcompl AL\n"); /* emit compare insn */ + else if (p->n_left->n_type == FLOAT) + expand(p, 0, " fcomp AL\n"); /* emit compare insn */ + else + comperr("bad compare %p\n", p); + expand(p, 0, " fnstsw %ax\n"); /* move status reg to ax */ + + switch (p->n_op) { + case EQ: + expand(p, 0, " andb $64,%ah\n jne LC\n"); + break; + case NE: + expand(p, 0, " andb $64,%ah\n je LC\n"); + break; + case LE: + expand(p, 0, " andb $65,%ah\n cmpb $1,%ah\n jne LC\n"); + break; + case LT: + expand(p, 0, " andb $65,%ah\n je LC\n"); + break; + case GT: + expand(p, 0, " andb $1,%ah\n jne LC\n"); + break; + case GE: + expand(p, 0, " andb $65,%ah\n jne LC\n"); + break; + default: + comperr("fcomp op %d\n", p->n_op); + } +} + +/* + * Convert an unsigned long long to floating point number. + */ +static void +ulltofp(NODE *p) +{ + static int loadlab; + int jmplab; + + if (loadlab == 0) { + loadlab = getlab(); + expand(p, 0, " .data\n"); + printf(LABFMT ": .long 0,0x80000000,0x403f\n", loadlab); + expand(p, 0, " .text\n"); + } + jmplab = getlab(); + expand(p, 0, " pushl UL\n pushl AL\n"); + expand(p, 0, " fildq (%esp)\n"); + expand(p, 0, " addl $8,%esp\n"); + expand(p, 0, " cmpl $0,UL\n"); + printf(" jge " LABFMT "\n", jmplab); + printf(" fldt " LABFMT "\n", loadlab); + printf(" faddp %%st,%%st(1)\n"); + printf(LABFMT ":\n", jmplab); +} + +static int +argsiz(NODE *p) +{ + TWORD t = p->n_type; + + if (t < LONG || t == FLOAT || t > BTMASK) + return 4; + if (t == LONG || t == ULONG || t == LONGLONG || t == ULONGLONG || + t == DOUBLE) + return 8; + if (t == LDOUBLE) + return 16; + if (t == STRTY || t == UNIONTY) + return p->n_stsize; + comperr("argsiz"); + return 0; +} + +void +zzzcode(NODE *p, int c) +{ + NODE *r, *l; + int pr, lr, s; + char *ch; + + switch (c) { + case 'A': /* swap st0 and st1 if right is evaluated second */ + if ((p->n_su & DORIGHT) == 0) { + if (logop(p->n_op)) + printf(" fxch\n"); + else + printf("r"); + } + break; + + case 'C': /* remove from stack after subroutine call */ + if (p->n_left->n_flags & FSTDCALL) + break; + pr = p->n_qual; + if (p->n_op == STCALL || p->n_op == USTCALL) + pr += 4; + if (p->n_op == UCALL) + return; /* XXX remove ZC from UCALL */ + if (pr) + printf(" addl $%d, %s\n", pr, rnames[ESP]); + break; + + case 'E': /* Perform bitfield sign-extension */ + bfext(p); + break; + + case 'F': /* Structure argument */ + if (p->n_stalign != 0) /* already on stack */ + starg(p); + break; + + case 'G': /* Floating point compare */ + fcomp(p); + break; + + case 'J': /* convert unsigned long long to floating point */ + ulltofp(p); + break; + + case 'M': /* Output sconv move, if needed */ + l = getlr(p, 'L'); + /* XXX fixneed: regnum */ + pr = DECRA(p->n_reg, 0); + lr = DECRA(l->n_reg, 0); + if ((pr == AL && lr == EAX) || (pr == BL && lr == EBX) || + (pr == CL && lr == ECX) || (pr == DL && lr == EDX)) + ; + else + printf(" movb %%%cl,%s\n", + rnames[lr][2], rnames[pr]); + l->n_rval = l->n_reg = p->n_reg; /* XXX - not pretty */ + break; + + case 'N': /* output extended reg name */ + printf("%s", rnames[getlr(p, '1')->n_rval]); + break; + + case 'S': /* emit eventual move after cast from longlong */ + pr = DECRA(p->n_reg, 0); + lr = p->n_left->n_rval; + switch (p->n_type) { + case CHAR: + case UCHAR: + if (rnames[pr][2] == 'l' && rnames[lr][2] == 'x' && + rnames[pr][1] == rnames[lr][1]) + break; + if (rnames[lr][2] == 'x') { + printf("\tmovb %%%cl,%s\n", + rnames[lr][1], rnames[pr]); + break; + } + /* Must go via stack */ + s = BITOOR(freetemp(1)); + printf("\tmovl %%e%ci,%d(%%rbp)\n", rnames[lr][1], s); + printf("\tmovb %d(%%rbp),%s\n", s, rnames[pr]); + comperr("SCONV1 %s->%s", rnames[lr], rnames[pr]); + break; + + case SHORT: + case USHORT: + if (rnames[lr][1] == rnames[pr][2] && + rnames[lr][2] == rnames[pr][3]) + break; + printf("\tmovw %%%c%c,%%%s\n", + rnames[lr][1], rnames[lr][2], rnames[pr]+2); + comperr("SCONV2 %s->%s", rnames[lr], rnames[pr]); + break; + case INT: + case UNSIGNED: + if (rnames[lr][1] == rnames[pr][2] && + rnames[lr][2] == rnames[pr][3]) + break; + printf("\tmovl %%e%c%c,%s\n", + rnames[lr][1], rnames[lr][2], rnames[pr]); + comperr("SCONV3 %s->%s", rnames[lr], rnames[pr]); + break; + + default: + if (rnames[lr][1] == rnames[pr][2] && + rnames[lr][2] == rnames[pr][3]) + break; + comperr("SCONV4 %s->%s", rnames[lr], rnames[pr]); + break; + } + break; + + default: + comperr("zzzcode %c", c); + } +} + +/*ARGSUSED*/ +int +rewfld(NODE *p) +{ + return(1); +} + +int canaddr(NODE *); +int +canaddr(NODE *p) +{ + int o = p->n_op; + + if (o==NAME || o==REG || o==ICON || o==OREG || + (o==UMUL && shumul(p->n_left, SOREG))) + return(1); + return(0); +} + +/* + * Does the bitfield shape match? + */ +int +flshape(NODE *p) +{ + int o = p->n_op; + + if (o == OREG || o == REG || o == NAME) + return SRDIR; /* Direct match */ + if (o == UMUL && shumul(p->n_left, SOREG)) + return SROREG; /* Convert into oreg */ + return SRREG; /* put it into a register */ +} + +/* INTEMP shapes must not contain any temporary registers */ +/* XXX should this go away now? */ +int +shtemp(NODE *p) +{ + return 0; +#if 0 + int r; + + if (p->n_op == STARG ) + p = p->n_left; + + switch (p->n_op) { + case REG: + return (!istreg(p->n_rval)); + + case OREG: + r = p->n_rval; + if (R2TEST(r)) { + if (istreg(R2UPK1(r))) + return(0); + r = R2UPK2(r); + } + return (!istreg(r)); + + case UMUL: + p = p->n_left; + return (p->n_op != UMUL && shtemp(p)); + } + + if (optype(p->n_op) != LTYPE) + return(0); + return(1); +#endif +} + +void +adrcon(CONSZ val) +{ + printf("$" CONFMT, val); +} + +void +conput(FILE *fp, NODE *p) +{ + int val = p->n_lval; + + switch (p->n_op) { + case ICON: + if (p->n_name[0] != '\0') { + fprintf(fp, "%s", p->n_name); + if (val) + fprintf(fp, "+%d", val); + } else + fprintf(fp, "%d", val); + return; + + default: + comperr("illegal conput, p %p", p); + } +} + +/*ARGSUSED*/ +void +insput(NODE *p) +{ + comperr("insput"); +} + +/* + * Write out the upper address, like the upper register of a 2-register + * reference, or the next memory location. + */ +void +upput(NODE *p, int size) +{ + + size /= SZCHAR; + switch (p->n_op) { + case REG: + fprintf(stdout, "%%%s", &rnames[p->n_rval][3]); + break; + + case NAME: + case OREG: + p->n_lval += size; + adrput(stdout, p); + p->n_lval -= size; + break; + case ICON: + fprintf(stdout, "$" CONFMT, p->n_lval >> 32); + break; + default: + comperr("upput bad op %d size %d", p->n_op, size); + } +} + +void +adrput(FILE *io, NODE *p) +{ + int r; + /* output an address, with offsets, from p */ + + if (p->n_op == FLD) + p = p->n_left; + + switch (p->n_op) { + + case NAME: + if (p->n_name[0] != '\0') { + fputs(p->n_name, io); + if (p->n_lval != 0) + fprintf(io, "+" CONFMT, p->n_lval); + } else + fprintf(io, CONFMT, p->n_lval); + return; + + case OREG: + r = p->n_rval; + if (p->n_name[0]) + printf("%s%s", p->n_name, p->n_lval ? "+" : ""); + if (p->n_lval) + fprintf(io, "%d", (int)p->n_lval); + if (R2TEST(r)) { + fprintf(io, "(%s,%s,8)", rnames[R2UPK1(r)], + rnames[R2UPK2(r)]); + } else + fprintf(io, "(%s)", rnames[p->n_rval]); + return; + case ICON: +#ifdef PCC_DEBUG + /* Sanitycheck for PIC, to catch adressable constants */ + if (kflag && p->n_name[0]) { + static int foo; + + if (foo++ == 0) { + printf("\nfailing...\n"); + fwalk(p, e2print, 0); + comperr("pass2 conput"); + } + } +#endif + /* addressable value of the constant */ + fputc('$', io); + conput(io, p); + return; + + case REG: + switch (p->n_type) { + case LONGLONG: + case ULONGLONG: + fprintf(io, "%%%c%c%c", rnames[p->n_rval][0], + rnames[p->n_rval][1], rnames[p->n_rval][2]); + break; + case SHORT: + case USHORT: + fprintf(io, "%%%s", &rnames[p->n_rval][2]); + break; + default: + fprintf(io, "%s", rnames[p->n_rval]); + } + return; + + default: + comperr("illegal address, op %d, node %p", p->n_op, p); + return; + + } +} + +static char * +ccbranches[] = { + "je", /* jumpe */ + "jne", /* jumpn */ + "jle", /* jumple */ + "jl", /* jumpl */ + "jge", /* jumpge */ + "jg", /* jumpg */ + "jbe", /* jumple (jlequ) */ + "jb", /* jumpl (jlssu) */ + "jae", /* jumpge (jgequ) */ + "ja", /* jumpg (jgtru) */ +}; + + +/* printf conditional and unconditional branches */ +void +cbgen(int o, int lab) +{ + if (o < EQ || o > UGT) + comperr("bad conditional branch: %s", opst[o]); + printf(" %s " LABFMT "\n", ccbranches[o-EQ], lab); +} + +static void +fixcalls(NODE *p, void *arg) +{ + /* Prepare for struct return by allocating bounce space on stack */ + switch (p->n_op) { + case STCALL: + case USTCALL: + if (p->n_stsize+p2autooff > stkpos) + stkpos = p->n_stsize+p2autooff; + break; + } +} + +/* + * Must store floats in memory if there are two function calls involved. + */ +static int +storefloat(struct interpass *ip, NODE *p) +{ + int l, r; + + switch (optype(p->n_op)) { + case BITYPE: + l = storefloat(ip, p->n_left); + r = storefloat(ip, p->n_right); + if (p->n_op == CM) + return 0; /* arguments, don't care */ + if (callop(p->n_op)) + return 1; /* found one */ +#define ISF(p) ((p)->n_type == FLOAT || (p)->n_type == DOUBLE || \ + (p)->n_type == LDOUBLE) + if (ISF(p->n_left) && ISF(p->n_right) && l && r) { + /* must store one. store left */ + struct interpass *nip; + TWORD t = p->n_left->n_type; + NODE *ll; + int off; + + off = BITOOR(freetemp(szty(t))); + ll = mklnode(OREG, off, FPREG, t); + nip = ipnode(mkbinode(ASSIGN, ll, p->n_left, t)); + p->n_left = mklnode(OREG, off, FPREG, t); + DLIST_INSERT_BEFORE(ip, nip, qelem); + } + return l|r; + + case UTYPE: + l = storefloat(ip, p->n_left); + if (callop(p->n_op)) + l = 1; + return l; + default: + return 0; + } +} + +void +myreader(struct interpass *ipole) +{ + struct interpass *ip; + + stkpos = p2autooff; + DLIST_FOREACH(ip, ipole, qelem) { + if (ip->type != IP_NODE) + continue; + walkf(ip->ip_node, fixcalls, 0); + storefloat(ip, ip->ip_node); + } + if (stkpos > p2autooff) + p2autooff = stkpos; + if (stkpos > p2maxautooff) + p2maxautooff = stkpos; + if (x2debug) + printip(ipole); +} + +/* + * Remove some PCONVs after OREGs are created. + */ +static void +pconv2(NODE *p, void *arg) +{ + NODE *q; + + if (p->n_op == PLUS) { + if (p->n_type == (PTR|SHORT) || p->n_type == (PTR|USHORT)) { + if (p->n_right->n_op != ICON) + return; + if (p->n_left->n_op != PCONV) + return; + if (p->n_left->n_left->n_op != OREG) + return; + q = p->n_left->n_left; + nfree(p->n_left); + p->n_left = q; + /* + * This will be converted to another OREG later. + */ + } + } +} + +void +mycanon(NODE *p) +{ + walkf(p, pconv2, 0); +} + +void +myoptim(struct interpass *ip) +{ +} + +void +rmove(int s, int d, TWORD t) +{ + int sl, sh, dl, dh; + + switch (t) { + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + printf(" movq %s,%s\n", rnames[s], rnames[d]); + break; + case CHAR: + case UCHAR: + printf(" movb %s,%s\n", rnames[s], rnames[d]); + break; + case FLOAT: + case DOUBLE: + case LDOUBLE: +#ifdef notdef + /* a=b()*c(); will generate this */ + comperr("bad float rmove: %d %d", s, d); +#endif + break; + default: + printf(" movl %s,%s\n", rnames[s], rnames[d]); + } +} + +/* + * For class c, find worst-case displacement of the number of + * registers in the array r[] indexed by class. + */ +int +COLORMAP(int c, int *r) +{ + int num; + + switch (c) { + case CLASSA: + num = r[CLASSB] > 4 ? 4 : r[CLASSB]; + num += 2*r[CLASSC]; + num += r[CLASSA]; + return num < 6; + case CLASSB: + num = r[CLASSA]; + num += 2*r[CLASSC]; + num += r[CLASSB]; + return num < 4; + case CLASSC: + num = r[CLASSA]; + num += r[CLASSB] > 4 ? 4 : r[CLASSB]; + num += 2*r[CLASSC]; + return num < 5; + case CLASSD: + return r[CLASSD] < DREGCNT; + } + return 0; /* XXX gcc */ +} + +char *rnames[] = { + "%eax", "%edx", "%ecx", "%ebx", "%esi", "%edi", "%ebp", "%esp", + "%al", "%ah", "%dl", "%dh", "%cl", "%ch", "%bl", "%bh", + "%rax", "%rdx", "%rcx", "%rbx", "%rsi", "%rdi", "%rbp", "%rsp", + "%r08", "%r09", "%r10", "%r11", "%r12", "%r13", "%r14", "%r15", + "%st0", "%st1", "%st2", "%st3", "%st4", "%st5", "%st6", "%st7", +}; + +/* + * Return a class suitable for a specific type. + */ +int +gclass(TWORD t) +{ + if (t == CHAR || t == UCHAR) + return CLASSB; + if (t == LONG || t == ULONG || t == LONGLONG || t == ULONGLONG) + return CLASSC; + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) + return CLASSD; + return CLASSA; +} + +/* + * Calculate argument sizes. + */ +void +lastcall(NODE *p) +{ + NODE *op = p; + int size = 0; + + p->n_qual = 0; + if (p->n_op != CALL && p->n_op != FORTCALL && p->n_op != STCALL) + return; + for (p = p->n_right; p->n_op == CM; p = p->n_left) + size += argsiz(p->n_right); + size += argsiz(p); + if (kflag) + size -= 4; + op->n_qual = size; /* XXX */ +} + +/* + * Special shapes. + */ +int +special(NODE *p, int shape) +{ + int o = p->n_op; + + switch (shape) { + case SFUNCALL: + if (o == STCALL || o == USTCALL) + return SRREG; + break; + case SPCON: + if (o != ICON || p->n_name[0] || + p->n_lval < 0 || p->n_lval > 0x7fffffff) + break; + return SRDIR; + case SMIXOR: + return tshape(p, SZERO); + case SMILWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || p->n_lval & 0xffffffff) + break; + return SRDIR; + case SMIHWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || (p->n_lval >> 32) != 0) + break; + return SRDIR; + } + return SRNOPE; +} + +/* + * Target-dependent command-line options. + */ +void +mflags(char *str) +{ +} + +/* + * Do something target-dependent for xasm arguments. + */ +int +myxasm(struct interpass *ip, NODE *p) +{ + struct interpass *ip2; + NODE *in = 0, *ut = 0; + TWORD t; + char *w; + int reg; + int cw; + + cw = xasmcode(p->n_name); + if (cw & (XASMASG|XASMINOUT)) + ut = p->n_left; + if ((cw & XASMASG) == 0) + in = p->n_left; + + switch (XASMVAL(cw)) { + case 'D': reg = EDI; break; + case 'S': reg = ESI; break; + case 'a': reg = EAX; break; + case 'b': reg = EBX; break; + case 'c': reg = ECX; break; + case 'd': reg = EDX; break; + case 't': reg = 0; break; + case 'u': reg = 1; break; + case 'A': reg = EAXEDX; break; + case 'q': /* XXX let it be CLASSA as for now */ + p->n_name = tmpstrdup(p->n_name); + w = strchr(p->n_name, 'q'); + *w = 'r'; + return 0; + default: + return 0; + } + p->n_name = tmpstrdup(p->n_name); + for (w = p->n_name; *w; w++) + ; + w[-1] = 'r'; /* now reg */ + t = p->n_left->n_type; + if (reg == EAXEDX) { + p->n_label = CLASSC; + } else { + p->n_label = CLASSA; + if (t == CHAR || t == UCHAR) { + p->n_label = CLASSB; + reg = reg * 2 + 8; + } + } + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) { + p->n_label = CLASSD; + reg += 037; + } + + if (in && ut) + in = tcopy(in); + p->n_left = mklnode(REG, 0, reg, t); + if (ut) { + ip2 = ipnode(mkbinode(ASSIGN, ut, tcopy(p->n_left), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + } + if (in) { + ip2 = ipnode(mkbinode(ASSIGN, tcopy(p->n_left), in, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + return 1; +} + +void +targarg(char *w, void *arg) +{ + NODE **ary = arg; + NODE *p, *q; + + p = ary[(int)w[1]-'0']->n_left; + if (optype(p->n_op) != LTYPE) + comperr("bad xarg op %d", p->n_op); + q = tcopy(p); + if (q->n_op == REG) { + if (*w == 'k') { + q->n_type = INT; + } else if (*w != 'w') { + if (q->n_type > UCHAR) { + regno(q) = regno(q)*2+8; + if (*w == 'h') + regno(q)++; + } + q->n_type = INT; + } else + q->n_type = SHORT; + } + adrput(stdout, q); + tfree(q); +} + +/* + * target-specific conversion of numeric arguments. + */ +int +numconv(void *ip, void *p1, void *q1) +{ + NODE *p = p1, *q = q1; + int cw = xasmcode(q->n_name); + + switch (XASMVAL(cw)) { + case 'a': + case 'b': + case 'c': + case 'd': + p->n_name = tmpcalloc(2); + p->n_name[0] = XASMVAL(cw); + return 1; + default: + return 0; + } +} --- /dev/null +++ usr.bin/pcc/amd64/code.c @@ -0,0 +1,290 @@ +/* $Id: code.c,v 1.2 2008/12/10 17:59:30 mickey Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +# include "pass1.h" + +NODE *funarg(NODE *, int *); +int argreg(TWORD, int *); + +int lastloc = -1; + +/* + * Define everything needed to print out some data (or text). + * This means segment, alignment, visibility, etc. + */ +void +defloc(struct symtab *sp) +{ + extern char *nextsect; + static char *loctbl[] = { "text", "data", "section .rodata" }; + TWORD t; + int s; + + if (sp == NULL) { + lastloc = -1; + return; + } + t = sp->stype; + s = ISFTN(t) ? PROG : ISCON(cqual(t, sp->squal)) ? RDATA : DATA; +#ifdef TLS + if (sp->sflags & STLS) { + if (s != DATA) + cerror("non-data symbol in tls section"); + nextsect = ".tdata"; + } +#endif + if (nextsect) { + printf(" .section %s\n", nextsect); + nextsect = NULL; + s = -1; + } else if (s != lastloc) + printf(" .%s\n", loctbl[s]); + lastloc = s; + while (ISARY(t)) + t = DECREF(t); + if (sp->ssue->suealign > ALCHAR) + printf(" .align %d\n", sp->ssue->suealign/ALCHAR); + if (sp->sclass == EXTDEF) + printf(" .globl %s\n", exname(sp->soname)); + if (ISFTN(t)) + printf("\t.type %s, at function\n", exname(sp->soname)); + if (sp->slevel == 0) + printf("%s:\n", exname(sp->soname)); + else + printf(LABFMT ":\n", sp->soffset); +} + +/* + * code for the end of a function + * deals with struct return here + */ +void +efcode() +{ + extern int gotnr; + NODE *p, *q; + + gotnr = 0; /* new number for next fun */ + if (cftnsp->stype != STRTY+FTN && cftnsp->stype != UNIONTY+FTN) + return; + /* Create struct assignment */ + q = block(OREG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); + q->n_rval = EBP; + q->n_lval = 8; /* return buffer offset */ + q = buildtree(UMUL, q, NIL); + p = block(REG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); + p = buildtree(UMUL, p, NIL); + p = buildtree(ASSIGN, q, p); + ecomp(p); +} + +/* + * code for the beginning of a function; a is an array of + * indices in symtab for the arguments; n is the number + */ +void +bfcode(struct symtab **a, int cnt) +{ + struct symtab *sp2; + extern int gotnr; + NODE *n, *p; + int i; + + if (cftnsp->stype == STRTY+FTN || cftnsp->stype == UNIONTY+FTN) { + /* Function returns struct, adjust arg offset */ + for (i = 0; i < cnt; i++) + sp[i]->soffset += SZPOINT(LONG); + } + + if (kflag) { + /* Put ebx in temporary */ + n = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + n->n_rval = EBX; + p = tempnode(0, INT, 0, MKSUE(INT)); + gotnr = regno(p); + ecomp(buildtree(ASSIGN, p, n)); + } + + /* recalculate the arg offset and create TEMP moves */ + for (n = 0, i = 0; i < cnt; i++) { + sp = a[i]; + + if (n < 6) { + p = tempnode(0, sp->stype, sp->sdf, sp->ssue); + q = block(REG, NIL, NIL, sp->stype, sp->sdf, sp->ssue); + q->n_rval = argreg(sp->stype, &n); + p = buildtree(ASSIGN, p, q); + sp->soffset = regno(p->n_left); + sp->sflags |= STNODE; + ecomp(p); + } else { + sp->soffset += SZLONG * n; + if (xtemps) { + /* put stack args in temps if optimizing */ + p = tempnode(0, sp->stype, sp->sdf, sp->ssue); + p = buildtree(ASSIGN, p, buildtree(NAME, 0, 0)); + sp->soffset = regno(p->n_left); + sp->sflags |= STNODE; + ecomp(p); + } + } + } +} + + +/* + * by now, the automatics and register variables are allocated + */ +void +bccode() +{ + SETOFF(autooff, SZINT); +} + +/* called just before final exit */ +/* flag is 1 if errors, 0 if none */ +void +ejobcode(int flag ) +{ + if (errors) + return; + +#define _MKSTR(x) #x +#define MKSTR(x) _MKSTR(x) +#define OS MKSTR(TARGOS) + printf("\t.ident \"PCC: %s (%s)\"\n\t.end\n", PACKAGE_STRING, OS); +} + +void +bjobcode() +{ +} + +static const int argregsi[] = { RDI, RSI, RDX, RCX, R09, R08 }; + +int +argreg(TWORD t, int *n) +{ + switch (t) { + case FLOAT: + case DOUBLE: + case LDOUBLE: + return FR6 - *n - 2; + case LONGLONG: + case ULONGLONG: + /* TODO */; + default: + return argregsi[(*n)++]; + } +} + +NODE * +funarg(NODE *p, int *n) +{ + NODE *r; + int sz; + + if (p->n_op == CM) { + p->n_left = funarg(p->n_left, n); + p->n_right = funarg(p->n_right, n); + return p; + } + + if (*n >= 6) { + *n++; + r = block(OREG, NIL, NIL, p->n_type|PTR, 0, + MKSUE(p->n_type|PTR)); + r->n_rval = RBP; + r->n_lval = 16 + (*n - 6) * 8; + } else { + r = block(REG, NIL, NIL, p->n_type, 0, 0); + r->n_lval = 0; + r->n_rval = argreg(p->n_type, n); + } + p = block(ASSIGN, r, p, p->n_type, 0, 0); + clocal(p); + + return p; +} + +/* + * Called with a function call with arguments as argument. + * This is done early in buildtree() and only done once. + * Returns p. + */ +NODE * +funcode(NODE *p) +{ + extern int gotnr; + NODE *r, *l; + int n = 0; + + p->n_right = funarg(p->n_right, &n); + + if (kflag == 0) + return p; + /* Create an ASSIGN node for ebx */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + l = buildtree(ASSIGN, l, tempnode(gotnr, INT, 0, MKSUE(INT))); + if (p->n_right->n_op != CM) { + p->n_right = block(CM, l, p->n_right, INT, 0, MKSUE(INT)); + } else { + for (r = p->n_right; r->n_left->n_op == CM; r = r->n_left) + ; + r->n_left = block(CM, l, r->n_left, INT, 0, MKSUE(INT)); + } + return p; +} + +/* + * return the alignment of field of type t + */ +int +fldal(unsigned int t) +{ + uerror("illegal field type"); + return(ALINT); +} + +/* fix up type of field p */ +void +fldty(struct symtab *p) +{ +} + +/* + * XXX - fix genswitch. + */ +int +mygenswitch(int num, TWORD type, struct swents **p, int n) +{ + return 0; +} --- /dev/null +++ usr.bin/pcc/amd64/local.c @@ -0,0 +1,1117 @@ +/* $Id: local.c,v 1.2 2008/12/14 21:16:58 ragge Exp $ */ +/* + * Copyright (c) 2008 Michael Shalayeff + * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. The name of the author may not be used to endorse or promote products + * derived from this software without specific prior written permission + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES + * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. + * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT + * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, + * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY + * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT + * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF + * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + */ + + +#include "pass1.h" + +/* this file contains code which is dependent on the target machine */ + +/* + * Check if a constant is too large for a type. + */ +static int +toolarge(TWORD t, CONSZ con) +{ + U_CONSZ ucon = con; + + switch (t) { + case ULONG: + case LONG: + case ULONGLONG: + case LONGLONG: + break; /* cannot be too large */ +#define SCHK(i) case i: if (con > MAX_##i || con < MIN_##i) return 1; break +#define UCHK(i) case i: if (ucon > MAX_##i) return 1; break + SCHK(INT); + SCHK(SHORT); + case BOOL: + SCHK(CHAR); + UCHK(UNSIGNED); + UCHK(USHORT); + UCHK(UCHAR); + default: + cerror("toolarge"); + } + return 0; +} + +#define IALLOC(sz) (isinlining ? permalloc(sz) : tmpalloc(sz)) + +/* + * Make a symtab entry for PIC use. + */ +static struct symtab * +picsymtab(char *p, char *s, char *s2) +{ + struct symtab *sp = IALLOC(sizeof(struct symtab)); + size_t len = strlen(p) + strlen(s) + strlen(s2) + 1; + + sp->sname = sp->soname = IALLOC(len); + strlcpy(sp->soname, p, len); + strlcat(sp->soname, s, len); + strlcat(sp->soname, s2, len); + sp->sclass = EXTERN; + sp->sflags = sp->slevel = 0; + return sp; +} + +int gotnr; /* tempnum for GOT register */ +int argstacksize; + +/* + * Create a reference for an extern variable. + */ +static NODE * +picext(NODE *p) +{ + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@GOT"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, PTR|VOID, 0, MKSUE(VOID)); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; +} + +/* + * Create a reference for a static variable. + */ +static NODE * +picstatic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + if (p->n_sp->slevel > 0) { + char buf[32]; + snprintf(buf, 32, LABFMT, (int)p->n_sp->soffset); + sp = picsymtab("", buf, "@GOTOFF"); + } else + sp = picsymtab("", p->n_sp->soname, "@GOTOFF"); + sp->sclass = STATIC; + sp->stype = p->n_sp->stype; + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; +} + +#ifdef TLS +/* + * Create a reference for a TLS variable. + */ +static NODE * +tlspic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + + /* + * creates: + * leal var at TLSGD(%ebx),%eax + * call ___tls_get_addr at PLT + */ + + /* calc address of var at TLSGD */ + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@TLSGD"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + + /* assign to %eax */ + r = block(REG, NIL, NIL, PTR|VOID, 0, MKSUE(VOID)); + r->n_rval = EAX; + q = buildtree(ASSIGN, r, q); + + /* call ___tls_get_addr */ + sp2 = lookup("___tls_get_addr at PLT", 0); + sp2->stype = EXTERN|INT|FTN; + r = nametree(sp2); + r = buildtree(ADDROF, r, NIL); + r = block(UCALL, r, NIL, INT, 0, MKSUE(INT)); + + /* fusion both parts together */ + q = buildtree(COMOP, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsnonpic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + int ext = p->n_sp->sclass; + + sp = picsymtab("", p->n_sp->soname, + ext == EXTERN ? "@INDNTPOFF" : "@NTPOFF"); + q = xbcon(0, sp, INT); + if (ext == EXTERN) + q = block(UMUL, q, NIL, PTR|VOID, 0, MKSUE(VOID)); + + sp2 = lookup("%gs:0", 0); + sp2->stype = EXTERN|INT; + r = nametree(sp2); + + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsref(NODE *p) +{ + if (kflag) + return (tlspic(p)); + else + return (tlsnonpic(p)); +} +#endif + +/* clocal() is called to do local transformations on + * an expression tree preparitory to its being + * written out in intermediate code. + * + * the major essential job is rewriting the + * automatic variables and arguments in terms of + * REG and OREG nodes + * conversion ops which are not necessary are also clobbered here + * in addition, any special features (such as rewriting + * exclusive or) are easily handled here as well + */ +NODE * +clocal(NODE *p) +{ + + register struct symtab *q; + register NODE *r, *l; + register int o; + register int m; + TWORD t; + +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal: %p\n", p); + fwalk(p, eprint, 0); + } +#endif + switch( o = p->n_op ){ + + case NAME: + if ((q = p->n_sp) == NULL) + return p; /* Nothing to care about */ + + switch (q->sclass) { + + case PARAM: + case AUTO: + /* fake up a structure reference */ + r = block(REG, NIL, NIL, PTR+STRTY, 0, 0); + r->n_lval = 0; + r->n_rval = FPREG; + p = stref(block(STREF, r, p, 0, 0, 0)); + break; + + case USTATIC: + if (kflag == 0) + break; + /* FALLTHROUGH */ + case STATIC: +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); + break; + } +#endif + if (kflag == 0) { + if (q->slevel == 0) + break; + p->n_lval = 0; + } else if (blevel > 0) + p = picstatic(p); + break; + + case REGISTER: + p->n_op = REG; + p->n_lval = 0; + p->n_rval = q->soffset; + break; + + case EXTERN: + case EXTDEF: +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); + break; + } +#endif + if (kflag == 0) + break; + if (blevel > 0) + p = picext(p); + break; + } + break; + + case ADDROF: + if (kflag == 0 || blevel == 0) + break; + /* char arrays may end up here */ + l = p->n_left; + if (l->n_op != NAME || + (l->n_type != ARY+CHAR && l->n_type != ARY+WCHAR_TYPE)) + break; + l = p; + p = picstatic(p->n_left); + nfree(l); + if (p->n_op != UMUL) + cerror("ADDROF error"); + l = p; + p = p->n_left; + nfree(l); + break; + + case UCALL: + case USTCALL: + if (kflag == 0) + break; + /* Change to CALL node with ebx as argument */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + p->n_right = buildtree(ASSIGN, l, + tempnode(gotnr, INT, 0, MKSUE(INT))); + p->n_op -= (UCALL-CALL); + break; + + case CBRANCH: + l = p->n_left; + + /* + * Remove unnecessary conversion ops. + */ + if (clogop(l->n_op) && l->n_left->n_op == SCONV) { + if (coptype(l->n_op) != BITYPE) + break; + if (l->n_right->n_op == ICON) { + r = l->n_left->n_left; + if (r->n_type >= FLOAT && r->n_type <= LDOUBLE) + break; + if (ISPTR(r->n_type)) + break; /* no opt for pointers */ + if (toolarge(r->n_type, l->n_right->n_lval)) + break; + /* Type must be correct */ + t = r->n_type; + nfree(l->n_left); + l->n_left = r; + l->n_type = t; + l->n_right->n_type = t; + } + } + break; + + case PCONV: + /* Remove redundant PCONV's. Be careful */ + l = p->n_left; + if (l->n_op == ICON) { + l->n_lval = (unsigned)l->n_lval; + goto delp; + } + if (l->n_type < INT || l->n_type == LONGLONG || + l->n_type == ULONGLONG) { + /* float etc? */ + p->n_left = block(SCONV, l, NIL, + UNSIGNED, 0, MKSUE(UNSIGNED)); + break; + } + /* if left is SCONV, cannot remove */ + if (l->n_op == SCONV) + break; + + /* avoid ADDROF TEMP */ + if (l->n_op == ADDROF && l->n_left->n_op == TEMP) + break; + + /* if conversion to another pointer type, just remove */ + if (p->n_type > BTMASK && l->n_type > BTMASK) + goto delp; + break; + + delp: l->n_type = p->n_type; + l->n_qual = p->n_qual; + l->n_df = p->n_df; + l->n_sue = p->n_sue; + nfree(p); + p = l; + break; + + case SCONV: + l = p->n_left; + + if (p->n_type == l->n_type) { + nfree(p); + return l; + } + + if ((p->n_type & TMASK) == 0 && (l->n_type & TMASK) == 0 && + btdims[p->n_type].suesize == btdims[l->n_type].suesize) { + if (p->n_type != FLOAT && p->n_type != DOUBLE && + l->n_type != FLOAT && l->n_type != DOUBLE && + l->n_type != LDOUBLE && p->n_type != LDOUBLE) { + if (l->n_op == NAME || l->n_op == UMUL || + l->n_op == TEMP) { + l->n_type = p->n_type; + nfree(p); + return l; + } + } + } + + if (DEUNSIGN(p->n_type) == INT && DEUNSIGN(l->n_type) == INT && + coptype(l->n_op) == BITYPE) { + l->n_type = p->n_type; + nfree(p); + return l; + } + + o = l->n_op; + m = p->n_type; + + if (o == ICON) { + CONSZ val = l->n_lval; + + if (!ISPTR(m)) /* Pointers don't need to be conv'd */ + switch (m) { + case BOOL: + l->n_lval = l->n_lval != 0; + break; + case CHAR: + l->n_lval = (char)val; + break; + case UCHAR: + l->n_lval = val & 0377; + break; + case SHORT: + l->n_lval = (short)val; + break; + case USHORT: + l->n_lval = val & 0177777; + break; + case UNSIGNED: + l->n_lval = val & 0xffffffff; + break; + case INT: + l->n_lval = (int)val; + break; + case LONG: + case LONGLONG: + l->n_lval = (long long)val; + break; + case ULONG: + case ULONGLONG: + l->n_lval = val; + break; + case VOID: + break; + case LDOUBLE: + case DOUBLE: + case FLOAT: + l->n_op = FCON; + l->n_dcon = val; + break; + default: + cerror("unknown type %d", m); + } + l->n_type = m; + l->n_sue = MKSUE(m); + nfree(p); + return l; + } else if (l->n_op == FCON) { + l->n_lval = l->n_dcon; + l->n_sp = NULL; + l->n_op = ICON; + l->n_type = m; + l->n_sue = MKSUE(m); + nfree(p); + return clocal(l); + } + if (DEUNSIGN(p->n_type) == SHORT && + DEUNSIGN(l->n_type) == SHORT) { + nfree(p); + p = l; + } + if ((p->n_type == CHAR || p->n_type == UCHAR || + p->n_type == SHORT || p->n_type == USHORT) && + (l->n_type == FLOAT || l->n_type == DOUBLE || + l->n_type == LDOUBLE)) { + p = block(SCONV, p, NIL, p->n_type, p->n_df, p->n_sue); + p->n_left->n_type = INT; + return p; + } + break; + + case MOD: + case DIV: + if (o == DIV && p->n_type != CHAR && p->n_type != SHORT) + break; + if (o == MOD && p->n_type != CHAR && p->n_type != SHORT) + break; + /* make it an int division by inserting conversions */ + p->n_left = block(SCONV, p->n_left, NIL, INT, 0, MKSUE(INT)); + p->n_right = block(SCONV, p->n_right, NIL, INT, 0, MKSUE(INT)); + p = block(SCONV, p, NIL, p->n_type, 0, MKSUE(p->n_type)); + p->n_left->n_type = INT; + break; + + case PMCONV: + case PVCONV: + r = p; + p = buildtree(o == PMCONV ? MUL : DIV, p->n_left, p->n_right); + nfree(r); + break; + + case FORCE: + /* put return value in return reg */ + p->n_op = ASSIGN; + p->n_right = p->n_left; + p->n_left = block(REG, NIL, NIL, p->n_type, 0, MKSUE(INT)); + p->n_left->n_rval = p->n_left->n_type == BOOL ? + RETREG(CHAR) : RETREG(p->n_type); + break; + + case LS: + case RS: + /* shift count must be in a char + * unless longlong, where it must be int */ + if (p->n_type == LONGLONG || p->n_type == ULONGLONG) { + if (p->n_right->n_type != INT) + p->n_right = block(SCONV, p->n_right, NIL, + INT, 0, MKSUE(INT)); + break; + } + if (p->n_right->n_type == CHAR || p->n_right->n_type == UCHAR) + break; + p->n_right = block(SCONV, p->n_right, NIL, + CHAR, 0, MKSUE(CHAR)); + break; + } +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal end: %p\n", p); + fwalk(p, eprint, 0); + } +#endif + return(p); +} + +/* + * Change CALL references to either direct (static) or PLT. + */ +static void +fixnames(NODE *p, void *arg) +{ + struct symtab *sp; + struct suedef *sue; + NODE *q; + char *c; + int isu; + + if ((cdope(p->n_op) & CALLFLG) == 0) + return; + isu = 0; + q = p->n_left; + sue = q->n_sue; + if (q->n_op == UMUL) + q = q->n_left, isu = 1; + + if (q->n_op == PLUS && q->n_left->n_op == TEMP && + q->n_right->n_op == ICON) { + sp = q->n_right->n_sp; + + if (sp == NULL) + return; /* nothing to do */ + if (sp->sclass == STATIC && !ISFTN(sp->stype)) + return; /* function pointer */ + + if (sp->sclass != STATIC && sp->sclass != EXTERN && + sp->sclass != EXTDEF) + cerror("fixnames"); + + if ((c = strstr(sp->soname, "@GOT")) == NULL) + cerror("fixnames2"); + if (isu) { + memcpy(c, "@PLT", sizeof("@PLT")); + } else + *c = 0; + + nfree(q->n_left); + q = q->n_right; + if (isu) + nfree(p->n_left->n_left); + nfree(p->n_left); + p->n_left = q; + q->n_sue = sue; + } +} + +void +myp2tree(NODE *p) +{ + struct symtab *sp; + + if (kflag) + walkf(p, fixnames, 0); /* XXX walkf not needed */ + if (p->n_op != FCON) + return; + +#if 0 + /* put floating constants in memory */ + setloc1(RDATA); + defalign(ALLDOUBLE); + deflab1(i = getlab()); + ninval(0, btdims[p->n_type].suesize, p); +#endif + + sp = IALLOC(sizeof(struct symtab)); + sp->sclass = STATIC; + sp->ssue = MKSUE(p->n_type); + sp->slevel = 1; /* fake numeric label */ + sp->soffset = getlab(); + sp->sflags = 0; + sp->stype = p->n_type; + sp->squal = (CON >> TSHIFT); + + defloc(sp); + ninval(0, sp->ssue->suesize, p); + + p->n_op = NAME; + p->n_lval = 0; + p->n_sp = sp; +} + +/*ARGSUSED*/ +int +andable(NODE *p) +{ + return(1); /* all names can have & taken on them */ +} + +/* + * at the end of the arguments of a ftn, set the automatic offset + */ +void +cendarg() +{ + autooff = AUTOINIT; +} + +/* + * Return 1 if a variable of type type is OK to put in register. + */ +int +cisreg(TWORD t) +{ + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) + return 0; /* not yet */ + return 1; +} + +/* + * return a node, for structure references, which is suitable for + * being added to a pointer of type t, in order to be off bits offset + * into a structure + * t, d, and s are the type, dimension offset, and sizeoffset + * For pdp10, return the type-specific index number which calculation + * is based on its size. For example, short a[3] would return 3. + * Be careful about only handling first-level pointers, the following + * indirections must be fullword. + */ +NODE * +offcon(OFFSZ off, TWORD t, union dimfun *d, struct suedef *sue) +{ + register NODE *p; + + if (xdebug) + printf("offcon: OFFSZ %lld type %x dim %p siz %d\n", + off, t, d, sue->suesize); + + p = bcon(0); + p->n_lval = off/SZCHAR; /* Default */ + return(p); +} + +/* + * Allocate off bits on the stack. p is a tree that when evaluated + * is the multiply count for off, t is a storeable node where to write + * the allocated address. + */ +void +spalloc(NODE *t, NODE *p, OFFSZ off) +{ + NODE *sp; + + p = buildtree(MUL, p, bcon(off/SZCHAR)); /* XXX word alignment? */ + + /* sub the size from sp */ + sp = block(REG, NIL, NIL, p->n_type, 0, MKSUE(INT)); + sp->n_lval = 0; + sp->n_rval = STKREG; + ecomp(buildtree(MINUSEQ, sp, p)); + + /* save the address of sp */ + sp = block(REG, NIL, NIL, PTR+INT, t->n_df, t->n_sue); + sp->n_lval = 0; + sp->n_rval = STKREG; + t->n_type = sp->n_type; + ecomp(buildtree(ASSIGN, t, sp)); /* Emit! */ + +} + +/* + * Print out a string of characters. + * Assume that the assembler understands C-style escape + * sequences. + */ +void +instring(struct symtab *sp) +{ + char *s, *str = sp->sname; + + defloc(sp); + + /* be kind to assemblers and avoid long strings */ + printf("\t.ascii \""); + for (s = str; *s != 0; ) { + if (*s++ == '\\') { + (void)esccon(&s); + } + if (s - str > 60) { + fwrite(str, 1, s - str, stdout); + printf("\"\n\t.ascii \""); + str = s; + } + } + fwrite(str, 1, s - str, stdout); + printf("\\0\"\n"); +} + +/* + * Print out a wide string by calling ninval(). + */ +void +inwstring(struct symtab *sp) +{ + char *s = sp->sname; + NODE *p; + + defloc(sp); + p = xbcon(0, NULL, WCHAR_TYPE); + do { + if (*s++ == '\\') + p->n_lval = esccon(&s); + else + p->n_lval = (unsigned char)s[-1]; + ninval(0, (MKSUE(WCHAR_TYPE))->suesize, p); + } while (s[-1] != 0); + nfree(p); +} + + +static int inbits, inval; + +/* + * set fsz bits in sequence to zero. + */ +void +zbits(OFFSZ off, int fsz) +{ + int m; + + if (idebug) + printf("zbits off %lld, fsz %d inbits %d\n", off, fsz, inbits); + if ((m = (inbits % SZCHAR))) { + m = SZCHAR - m; + if (fsz < m) { + inbits += fsz; + return; + } else { + fsz -= m; + printf("\t.byte %d\n", inval); + inval = inbits = 0; + } + } + if (fsz >= SZCHAR) { + printf("\t.zero %d\n", fsz/SZCHAR); + fsz -= (fsz/SZCHAR) * SZCHAR; + } + if (fsz) { + inval = 0; + inbits = fsz; + } +} + +/* + * Initialize a bitfield. + */ +void +infld(CONSZ off, int fsz, CONSZ val) +{ + if (idebug) + printf("infld off %lld, fsz %d, val %lld inbits %d\n", + off, fsz, val, inbits); + val &= ((CONSZ)1 << fsz)-1; + while (fsz + inbits >= SZCHAR) { + inval |= (val << inbits); + printf("\t.byte %d\n", inval & 255); + fsz -= (SZCHAR - inbits); + val >>= (SZCHAR - inbits); + inval = inbits = 0; + } + if (fsz) { + inval |= (val << inbits); + inbits += fsz; + } +} + +/* + * print out a constant node, may be associated with a label. + * Do not free the node after use. + * off is bit offset from the beginning of the aggregate + * fsz is the number of bits this is referring to + */ +void +ninval(CONSZ off, int fsz, NODE *p) +{ + union { float f; double d; long double l; int i[3]; } u; + struct symtab *q; + char *c; + TWORD t; + int i; + + t = p->n_type; + if (t > BTMASK) + t = INT; /* pointer */ + + while (p->n_op == SCONV || p->n_op == PCONV) { + NODE *l = p->n_left; + l->n_type = p->n_type; + p = l; + } + + if (kflag && (p->n_op == PLUS || p->n_op == UMUL)) { + if (p->n_op == UMUL) + p = p->n_left; + p = p->n_right; + q = p->n_sp; + + if ((c = strstr(q->soname, "@GOT")) != NULL) + *c = 0; /* ignore GOT ref here */ + } + if (p->n_op != ICON && p->n_op != FCON) + cerror("ninval: init node not constant"); + + if (p->n_op == ICON && p->n_sp != NULL && DEUNSIGN(t) != INT) + uerror("element not constant"); + + switch (t) { + case LONGLONG: + case ULONGLONG: + i = (p->n_lval >> 32); + p->n_lval &= 0xffffffff; + p->n_type = INT; + ninval(off, 32, p); + p->n_lval = i; + ninval(off+32, 32, p); + break; + case INT: + case UNSIGNED: + printf("\t.long 0x%x", (int)p->n_lval); + if ((q = p->n_sp) != NULL) { + if ((q->sclass == STATIC && q->slevel > 0)) { + printf("+" LABFMT, q->soffset); + } else { + printf("+%s", exname(q->soname)); + } + } + printf("\n"); + break; + case SHORT: + case USHORT: + printf("\t.short 0x%x\n", (int)p->n_lval & 0xffff); + break; + case BOOL: + if (p->n_lval > 1) + p->n_lval = p->n_lval != 0; + /* FALLTHROUGH */ + case CHAR: + case UCHAR: + printf("\t.byte %d\n", (int)p->n_lval & 0xff); + break; + case LDOUBLE: + u.i[2] = 0; + u.l = (long double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + /* XXX probably broken on most hosts */ + printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[2], u.i[1], u.i[0]); +#else + printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[0], u.i[1], u.i[2]); +#endif + break; + case DOUBLE: + u.d = (double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + printf("\t.long\t0x%x,0x%x\n", u.i[1], u.i[0]); +#else + printf("\t.long\t0x%x,0x%x\n", u.i[0], u.i[1]); +#endif + break; + case FLOAT: + u.f = (float)p->n_dcon; + printf("\t.long\t0x%x\n", u.i[0]); + break; + default: + cerror("ninval"); + } +} + +/* make a name look like an external name in the local machine */ +char * +exname(char *p) +{ + return (p == NULL ? "" : p); +} + +/* + * map types which are not defined on the local machine + */ +TWORD +ctype(TWORD type) +{ + switch (BTYPE(type)) { + case LONG: + MODTYPE(type,LONG); + break; + + case ULONG: + MODTYPE(type,ULONG); + + } + return (type); +} + +void +calldec(NODE *p, NODE *q) +{ +} + +void +extdec(struct symtab *q) +{ +} + +/* make a common declaration for id, if reasonable */ +void +defzero(struct symtab *sp) +{ + int off; + +#ifdef TLS + if (sp->sflags & STLS) { + if (sp->sclass == EXTERN) + sp->sclass = EXTDEF; + simpleinit(sp, bcon(0)); + return; + } +#endif + + off = tsize(sp->stype, sp->sdf, sp->ssue); + off = (off+(SZCHAR-1))/SZCHAR; + printf(" .%scomm ", sp->sclass == STATIC ? "l" : ""); + if (sp->slevel == 0) + printf("%s,0%o\n", exname(sp->soname), off); + else + printf(LABFMT ",0%o\n", sp->soffset, off); +} + +static char * +section2string(char *name, int len) +{ + char *s; + int n; + + if (strncmp(name, "link_set", 8) == 0) { + const char *postfix = ",\"aw\", at progbits"; + n = len + strlen(postfix) + 1; + s = IALLOC(n); + strlcpy(s, name, n); + strlcat(s, postfix, n); + return s; + } + + return newstring(name, len); +} + +char *nextsect; +#ifdef TLS +static int gottls; +#endif +static char *alias; +static int constructor; +static int destructor; + +/* + * Give target the opportunity of handling pragmas. + */ +int +mypragma(char **ary) +{ +#ifdef TLS + if (strcmp(ary[1], "tls") == 0 && ary[2] == NULL) { + gottls = 1; + return 1; + } +#endif + if (strcmp(ary[1], "constructor") == 0 || strcmp(ary[1], "init") == 0) { + constructor = 1; + return 1; + } + if (strcmp(ary[1], "destructor") == 0 || strcmp(ary[1], "fini") == 0) { + destructor = 1; + return 1; + } + if (strcmp(ary[1], "section") == 0 && ary[2] != NULL) { + nextsect = section2string(ary[2], strlen(ary[2])); + return 1; + } + if (strcmp(ary[1], "alias") == 0 && ary[2] != NULL) { + alias = tmpstrdup(ary[2]); + return 1; + } + + return 0; +} + +/* + * Called when a identifier has been declared. + */ +void +fixdef(struct symtab *sp) +{ +#ifdef TLS + /* may have sanity checks here */ + if (gottls) + sp->sflags |= STLS; + gottls = 0; +#endif + if (alias != NULL && (sp->sclass != PARAM)) { + printf("\t.globl %s\n", exname(sp->soname)); + printf("%s = ", exname(sp->soname)); + printf("%s\n", exname(alias)); + alias = NULL; + } + if ((constructor || destructor) && (sp->sclass != PARAM)) { + printf("\t.section .%ctors,\"aw\", at progbits\n", + constructor ? 'c' : 'd'); + printf("\t.p2align 2\n"); + printf("\t.long %s\n", exname(sp->sname)); + constructor = destructor = 0; + } +} + +NODE * +i386_builtin_return_address(NODE *f, NODE *a) +{ + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; + + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + f = block(PLUS, f, bcon(4), INCREF(PTR+VOID), 0, MKSUE(VOID)); + f = buildtree(UMUL, f, NIL); + + return f; +bad: + uerror("bad argument to __builtin_return_address"); + return bcon(0); +} + +NODE * +i386_builtin_frame_address(NODE *f, NODE *a) +{ + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; + + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + return f; +bad: + uerror("bad argument to __builtin_frame_address"); + return bcon(0); +} + +void +pass1_lastchance(struct interpass *ip) +{ +} Index: cc.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cc/cc.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/cc/cc.c -L usr.bin/pcc/cc/cc.c -u -r1.2 -r1.3 --- usr.bin/pcc/cc/cc.c +++ usr.bin/pcc/cc/cc.c @@ -1,4 +1,4 @@ -/* $Id: cc.c,v 1.61 2007/09/26 14:48:47 ragge Exp $ */ +/* $Id: cc.c,v 1.136 2008/12/22 02:04:11 gmcgarry Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -47,21 +47,35 @@ * * This file should be rewritten readable. */ +#include "config.h" + #include +#ifdef HAVE_SYS_WAIT_H #include +#endif -#include #include +#include +#include +#ifdef HAVE_LIBGEN_H +#include +#endif #include +#include +#include +#include #include -#include +#ifdef HAVE_UNISTD_H #include -#include -#include -#include -#include +#endif + +#ifdef WIN32 +#include +#include +#include +#endif -#include "../config.h" +#include "compat.h" #include "ccconfig.h" /* C command */ @@ -72,34 +86,79 @@ /* * Many specific definitions, should be declared elsewhere. */ -#define STDINC "/usr/include/" -#define SBSIZE 10000 -#define MAXINC 100 -#define MAXFIL 100 +#ifndef STDINC +#define STDINC "/usr/include/" +#endif + +#ifndef LIBDIR +#define LIBDIR "/usr/lib/" +#endif + +#ifndef PREPROCESSOR +#define PREPROCESSOR "pcpp" +#endif + +#ifndef COMPILER +#define COMPILER "pccom"; +#endif + +#ifndef ASSEMBLER +#define ASSEMBLER "as" +#endif + +#ifndef LINKER +#define LINKER "ld" +#endif + +#define OS MKS(TARGOS) +#define MACH MKS(TARGMACH) +#ifndef PCCINCDIR +#define PCCINCDIR LIBDIR "pcc/" MACH "-" OS "/" PACKAGE_VERSION "/include" +#endif +#ifndef PCCLIBDIR +#define PCCLIBDIR LIBDIR "pcc/" MACH "-" OS "/" PACKAGE_VERSION "/lib" +#endif + +#define MAXFIL 10000 #define MAXLIB 10000 #define MAXAV 10000 #define MAXOPT 100 char *tmp3; char *tmp4; -char *outfile; -char *copy(char *as),*setsuf(char *as, char ch); -int getsuf(char []); +char *outfile, *ermfile; +char *Bprefix(char *); +char *copy(char *, int),*setsuf(char *, char); +int getsuf(char *); int main(int, char *[]); void error(char *, ...); -void errorx(int eval, char *, ...); -int nodup(char **, char *); +void errorx(int, char *, ...); int callsys(char [], char *[]); int cunlink(char *); -void dexit(int eval); +void dexit(int); void idexit(int); -char *gettmp(); +char *gettmp(void); +void *ccmalloc(int size); +#ifdef WIN32 +char *win32pathsubst(char *); +#endif char *av[MAXAV]; char *clist[MAXFIL]; char *llist[MAXLIB]; +char *aslist[MAXAV]; char alist[20]; char *xlist[100]; int xnum; +char *mlist[100]; +char *flist[100]; +char *wlist[100]; +char *idirafter; +int nm; +int nf; +int nw; +int sspflag; +int Cflag; +int Vflag; int dflag; int pflag; int sflag; @@ -117,205 +176,416 @@ int pgflag; int exfail; int Xflag; -int nostartfiles, Bstatic; +int Wallflag; +int Wflag; +int nostartfiles, Bstatic, shared; int nostdinc, nostdlib; int onlyas; int pthreads; +int xcflag; +int ascpp; -char *pass0 = LIBEXECDIR "/pccom"; -char *passp = LIBEXECDIR "/pcpp"; +char *passp = LIBEXECDIR PREPROCESSOR; +char *pass0 = LIBEXECDIR COMPILER; +char *as = ASSEMBLER; +char *ld = LINKER; char *Bflag; char *cppadd[] = CPPADD; +#ifdef DYNLINKER char *dynlinker[] = DYNLINKER; +#endif +#ifdef CRT0FILE char *crt0file = CRT0FILE; +#endif +#ifdef CRT0FILE_PROFILE +char *crt0file_profile = CRT0FILE_PROFILE; +#endif +#ifdef STARTFILES char *startfiles[] = STARTFILES; char *endfiles[] = ENDFILES; +#endif +#ifdef STARTFILES_T +char *startfiles_T[] = STARTFILES_T; +char *endfiles_T[] = ENDFILES_T; +#endif +#ifdef STARTFILES_S +char *startfiles_S[] = STARTFILES_S; +char *endfiles_S[] = ENDFILES_S; +#endif +#ifdef MULTITARGET +char *mach = DEFMACH; +struct cppmd { + char *mach; + char *cppmdadd[MAXCPPMDARGS]; +}; + +struct cppmd cppmds[] = CPPMDADDS; +#else char *cppmdadd[] = CPPMDADD; +#endif #ifdef LIBCLIBS char *libclibs[] = LIBCLIBS; #else char *libclibs[] = { "-lc", NULL }; #endif +#ifdef LIBCLIBS_PROFILE +char *libclibs_profile[] = LIBCLIBS_PROFILE; +#else +char *libclibs_profile[] = { "-lc_p", NULL }; +#endif #ifndef STARTLABEL #define STARTLABEL "__start" #endif +char *incdir = STDINC; +char *libdir = LIBDIR; +char *pccincdir = PCCINCDIR; +char *pcclibdir = PCCLIBDIR; + +/* handle gcc warning emulations */ +struct Wflags { + char *name; + int flags; +#define INWALL 1 +#define NEGATIVE 2 +} Wflags[] = { + { "-Werror", 0 }, + { "-Wshadow", 0 }, + { "-Wno-shadow", NEGATIVE }, + { "-Wpointer-sign", INWALL }, + { "-Wno-pointer-sign", NEGATIVE }, + { "-Wsign-compare", 0 }, + { "-Wno-sign-compare", NEGATIVE }, + { "-Wunknown-pragmas", INWALL }, + { "-Wno-unknown-pragmas", NEGATIVE }, + { "-Wunreachable-code", 0 }, + { "-Wno-unreachable-code", NEGATIVE }, + { 0, 0 }, +}; + +#define SZWFL (sizeof(Wflags)/sizeof(Wflags[0])) int main(int argc, char *argv[]) { + struct Wflags *Wf; char *t, *u; char *assource; char **pv, *ptemp[MAXOPT], **pvt; - int nc, nl, i, j, c, nxo, na; + int nc, nl, nas, i, j, c, nxo, na; +#ifdef MULTITARGET + int k; +#endif - i = nc = nl = nxo = 0; +#ifdef WIN32 + /* have to prefix path early. -B may override */ + incdir = win32pathsubst(incdir); + libdir = win32pathsubst(libdir); + pccincdir = win32pathsubst(pccincdir); + pcclibdir = win32pathsubst(pcclibdir); + passp = win32pathsubst(passp); + pass0 = win32pathsubst(pass0); +#endif + + i = nc = nl = nas = nxo = 0; pv = ptemp; while(++i < argc) { - if (argv[i][0] == '-') - switch (argv[i][1]) { - default: - goto passa; + if (argv[i][0] == '-') { + switch (argv[i][1]) { + default: + goto passa; +#ifdef notyet + /* must add library options first (-L/-l/...) */ + error("unrecognized option `-%c'", argv[i][1]); + break; +#endif - case 'B': /* other search paths for binaries */ - Bflag = &argv[i][2]; - break; + case '-': /* double -'s */ + if (strcmp(argv[i], "--version") == 0) { + printf("%s\n", VERSSTR); + return 0; + } else if (strcmp(argv[i], "--param") == 0) + /* NOTHING YET */; + else + error("unrecognized option %s", argv[i]); + break; - case 'X': - Xflag++; - break; - case 'W': /* Ignore (most of) W-flags */ - if (strncmp(argv[i], "-Wl,", 4) == 0) { - /* options to the linker */ - t = &argv[i][4]; - while ((u = strchr(t, ','))) { - *u++ = 0; + case 'B': /* other search paths for binaries */ + Bflag = &argv[i][2]; + break; + +#ifdef MULTITARGET + case 'b': + t = &argv[i][2]; + if (*t == '\0' && i + 1 < argc) { + t = argv[i+1]; + i++; + } + if (strncmp(t, "?", 1) == 0) { + /* show machine targets */ + printf("Available machine targets:"); + for (j=0; cppmds[j].mach; j++) + printf(" %s",cppmds[j].mach); + printf("\n"); + exit(0); + } + for (j=0; cppmds[j].mach; j++) + if (strcmp(t, cppmds[j].mach) == 0) { + mach = cppmds[j].mach; + break; + } + if (cppmds[j].mach == NULL) + errorx(1, "unknown target arch %s", t); + break; +#endif + + case 'X': + Xflag++; + break; + case 'W': /* Ignore (most of) W-flags */ + if (strncmp(argv[i], "-Wl,", 4) == 0) { + /* options to the linker */ + t = &argv[i][4]; + while ((u = strchr(t, ','))) { + *u++ = 0; + llist[nl++] = t; + t = u; + } llist[nl++] = t; - t = u; + } else if (strncmp(argv[i], "-Wa,", 4) == 0) { + /* options to the assembler */ + t = &argv[i][4]; + while ((u = strchr(t, ','))) { + *u++ = 0; + aslist[nas++] = t; + t = u; + } + aslist[nas++] = t; + } else if (strncmp(argv[i], "-Wp,", 4) == 0) { + /* preprocessor */ + if (!strncmp(argv[i], "-Wp,-C", 6)) + Cflag++; + else if (!strncmp(argv[i], "-Wp,-V", 6)) + Vflag++; + } else if (strcmp(argv[i], "-Wall") == 0) { + Wallflag = 1; + } else if (strcmp(argv[i], "-WW") == 0) { + Wflag = 1; + } else { + /* check and set if available */ + for (Wf = Wflags; Wf->name; Wf++) { + if (strcmp(argv[i], Wf->name)) + continue; + wlist[nw++] = Wf->name; + } } - llist[nl++] = t; - } - break; + break; - case 'f': /* GCC compatibility flags */ - if (strcmp(argv[i], "-fPIC") == 0) - kflag = F_PIC; - if (strcmp(argv[i], "-fpic") == 0) - kflag = F_pic; - /* silently ignore the rest */ - break; + case 'f': /* GCC compatibility flags */ + if (strcmp(argv[i], "-fPIC") == 0) + kflag = F_PIC; + else if (strcmp(argv[i], "-fpic") == 0) + kflag = F_pic; + else if (strcmp(argv[i], + "-fsigned-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-fno-signed-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-funsigned-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-fno-unsigned-char") == 0) + flist[nf++] = argv[i]; + else if (strcmp(argv[i], + "-fstack-protector") == 0) { + flist[nf++] = argv[i]; + sspflag++; + } else if (strcmp(argv[i], + "-fstack-protector-all") == 0) { + flist[nf++] = argv[i]; + sspflag++; + } else if (strcmp(argv[i], + "-fno-stack-protector") == 0) { + flist[nf++] = argv[i]; + sspflag = 0; + } else if (strcmp(argv[i], + "-fno-stack-protector-all") == 0) { + flist[nf++] = argv[i]; + sspflag = 0; + } + /* silently ignore the rest */ + break; - case 'g': /* create debug output */ - gflag++; - break; + case 'g': /* create debug output */ + gflag++; + break; - case 'i': - if (strcmp(argv[i], "-isystem") == 0) { - *pv++ = "-S"; - *pv++ = argv[++i]; - } else if (strcmp(argv[i], "-include") == 0) { - *pv++ = "-i"; - *pv++ = argv[++i]; - } else - goto passa; - break; + case 'i': + if (strcmp(argv[i], "-isystem") == 0) { + *pv++ = "-S"; + *pv++ = argv[++i]; + } else if (strcmp(argv[i], "-include") == 0) { + *pv++ = "-i"; + *pv++ = argv[++i]; + } else if (strcmp(argv[i], "-idirafter") == 0) { + idirafter = argv[++i]; + } else + goto passa; + break; - case 'k': /* generate PIC code */ - kflag = F_pic; - break; + case 'k': /* generate PIC code */ + kflag = F_pic; + break; - case 'n': /* handle -n flags */ - if (strcmp(argv[i], "-nostdinc") == 0) - nostdinc++; - if (strcmp(argv[i], "-nostdlib") == 0) { - nostdlib++; - nostartfiles++; - } else if (strcmp(argv[i], "-nostartfiles") == 0) - nostartfiles = 1; - else - goto passa; - break; + case 'm': /* target-dependent options */ + mlist[nm++] = argv[i]; + break; - case 'p': - if (strcmp(argv[i], "-pg") == 0) - pgflag++; - else if (strcmp(argv[i], "-pthread") == 0) - pthreads++; - else - errorx(1, "unknown option %s", argv[i]); - break; + case 'n': /* handle -n flags */ + if (strcmp(argv[i], "-nostdinc") == 0) + nostdinc++; + else if (strcmp(argv[i], "-nostdlib") == 0) { + nostdlib++; + nostartfiles++; + } else if (strcmp(argv[i], "-nostartfiles") == 0) + nostartfiles = 1; + else + goto passa; + break; - case 'x': - xlist[xnum++] = argv[i]; - break; - case 't': - tflag++; - break; - case 'S': - sflag++; - cflag++; - break; - case 'o': - if (outfile) - errorx(8, "too many -o"); - outfile = argv[++i]; - break; - case 'O': - Oflag++; - break; - case 'E': - Eflag++; - break; - case 'P': - pflag++; - *pv++ = argv[i]; - case 'c': - cflag++; - break; + case 'p': + if (strcmp(argv[i], "-pg") == 0 || + strcmp(argv[i], "-p") == 0) + pgflag++; + else if (strcmp(argv[i], "-pthread") == 0) + pthreads++; + else if (strcmp(argv[i], "-pipe") == 0) + /* NOTHING YET */; + else + errorx(1, "unknown option %s", argv[i]); + break; + + case 'x': + t = &argv[i][2]; + if (*t == 0) + t = argv[++i]; + if (strcmp(t, "c") == 0) + xcflag = 1; /* default */ + else if (strcmp(t, "assembler-with-cpp") == 0) + ascpp = 1; +#ifdef notyet + else if (strcmp(t, "c++") == 0) + cxxflag++; +#endif + else + xlist[xnum++] = argv[i]; + break; + case 't': + tflag++; + break; + case 'S': + sflag++; + cflag++; + break; + case 'o': + if (outfile) + errorx(8, "too many -o"); + outfile = argv[++i]; + break; + case 'O': + if (argv[i][2] == '0') + Oflag = 0; + else + Oflag++; + break; + case 'E': + Eflag++; + break; + case 'P': + pflag++; + *pv++ = argv[i]; + case 'c': + cflag++; + break; #if 0 - case '2': - if(argv[i][2] == '\0') - pref = "/lib/crt2.o"; - else { - pref = "/lib/crt20.o"; - } - break; + case '2': + if(argv[i][2] == '\0') + pref = "/lib/crt2.o"; + else { + pref = "/lib/crt20.o"; + } + break; #endif - case 'D': - case 'I': - case 'U': - case 'C': - *pv++ = argv[i]; - if (argv[i][2] == 0) - *pv++ = argv[++i]; - if (pv >= ptemp+MAXOPT) - { - error("Too many DIUC options"); - --pv; + case 'C': + Cflag = 1; + break; + case 'D': + case 'I': + case 'U': + *pv++ = argv[i]; + if (argv[i][2] == 0) + *pv++ = argv[++i]; + if (pv >= ptemp+MAXOPT) { + error("Too many DIU options"); + --pv; } - break; + break; - case 'M': - Mflag++; - break; + case 'M': + Mflag++; + break; - case 'd': - dflag++; - strncpy(alist, argv[i], 19); - break; - case 'v': - printf("%s\n", VERSSTR); - vflag++; - break; + case 'd': + dflag++; + strlcpy(alist, argv[i], sizeof (alist)); + break; + case 'v': + printf("%s\n", VERSSTR); + vflag++; + break; - case 's': - if (strcmp(argv[i], "-static") == 0) - Bstatic = 1; - else - goto passa; - break; + case 's': + if (strcmp(argv[i], "-static") == 0) + Bstatic = 1; + else if (strcmp(argv[i], "-shared") == 0) { + shared = 1; +#ifndef os_win32 + nostdlib = 1; +#endif + } else if (strncmp(argv[i], "-std", 4) == 0) { + /* ignore gcc -std= */; + } else + goto passa; + break; + } } else { passa: t = argv[i]; if (*argv[i] == '-' && argv[i][1] == 'L') ; else if((c=getsuf(t))=='c' || c=='S' || c=='i' || - c=='s'|| Eflag) { + c=='s'|| Eflag || xcflag) { clist[nc++] = t; - if (nc>=MAXFIL) - { + if (nc>=MAXFIL) { error("Too many source files"); exit(1); - } + } t = setsuf(t, 'o'); } - if (nodup(llist, t)) { + + /* Check for duplicate .o files. */ + for (j = getsuf(t) == 'o' ? 0 : nl; j < nl; j++) { + if (strcmp(llist[j], t) == 0) + break; + } + if (j == nl) { llist[nl++] = t; - if (nl >= MAXLIB) - { + if (nl >= MAXLIB) { error("Too many object/library files"); exit(1); - } + } if (getsuf(t)=='o') nxo++; } @@ -329,31 +599,30 @@ if (outfile && clist[0] && strcmp(outfile, clist[0]) == 0) errorx(8, "output file will be clobbered"); #if 0 - for(i=0, j=0; iname; Wf++) { + if (Wf->flags != INWALL) + continue; + av[na++] = Wf->name; + } + } + if (Wflag) { + /* set all positive flags */ + for (Wf = Wflags; Wf->name; Wf++) { + if (Wf->flags == NEGATIVE) + continue; + av[na++] = Wf->name; + } + } + for (j = 0; j < nw; j++) + av[na++] = wlist[j]; + for (j = 0; j < nf; j++) + av[na++] = flist[j]; if (vflag) av[na++] = "-v"; + if (pgflag) + av[na++] = "-p"; if (gflag) av[na++] = "-g"; +#ifdef os_darwin + /* darwin always wants PIC compilation */ + if (!Bstatic) + av[na++] = "-k"; +#else if (kflag) av[na++] = "-k"; +#endif if (Oflag) { av[na++] = "-xtemps"; + av[na++] = "-xdeljumps"; + av[na++] = "-xinline"; } for (j = 0; j < xnum; j++) av[na++] = xlist[j]; - av[na++] = tmp4; + for (j = 0; j < nm; j++) + av[na++] = mlist[j]; + if (getsuf(clist[i])=='i') + av[na++] = clist[i]; + else + av[na++] = tmp4; /* created by cpp */ if (pflag || exfail) { cflag++; @@ -440,11 +767,11 @@ } if(sflag) { if (outfile) - assource = tmp3 = outfile; + tmp3 = outfile; else - assource = tmp3 = setsuf(clist[i], 's'); + tmp3 = setsuf(clist[i], 's'); } - av[na++] = tmp3; + ermfile = av[na++] = tmp3; #if 0 if (proflag) { av[3] = "-XP"; @@ -466,21 +793,30 @@ */ assemble: na = 0; - av[na++] = "as"; + av[na++] = as; + for (j = 0; j < nas; j++) + av[na++] = aslist[j]; +#if defined(os_sunos) && defined(mach_sparc64) + av[na++] = "-m64"; +#endif +#if defined(os_darwin) + if (Bstatic) + av[na++] = "-static"; +#endif if (vflag) av[na++] = "-v"; if (kflag) av[na++] = "-k"; av[na++] = "-o"; if (outfile && cflag) - av[na++] = outfile; + ermfile = av[na++] = outfile; else - av[na++] = setsuf(clist[i], 'o'); - av[na++] = onlyas ? tmp4 : assource; + ermfile = av[na++] = setsuf(clist[i], 'o'); + av[na++] = assource; if (dflag) av[na++] = alist; av[na++] = 0; - if (callsys("/bin/as", av)) { + if (callsys(as, av)) { cflag++; eflag++; cunlink(tmp4); @@ -498,26 +834,86 @@ nocom: if (cflag==0 && nl!=0) { j = 0; - av[j++] = "ld"; + av[j++] = ld; +#ifndef MSLINKER if (vflag) av[j++] = "-v"; +#endif +#if !defined(os_sunos) && !defined(os_win32) && !defined(os_darwin) av[j++] = "-X"; - av[j++] = "-d"; - av[j++] = "-e"; - av[j++] = STARTLABEL; - if (Bstatic == 0) { /* Dynamic linkage */ - for (i = 0; dynlinker[i]; i++) - av[j++] = dynlinker[i]; - } else - av[j++] = "-Bstatic"; +#endif + if (shared) { + av[j++] = "-shared"; +#ifdef os_win32 + av[j++] = "-Bdynamic"; +#endif +#ifndef os_sunos + } else { +#ifndef os_win32 +#ifndef os_darwin + av[j++] = "-d"; +#endif + av[j++] = "-e"; + av[j++] = STARTLABEL; +#endif +#endif + if (Bstatic == 0) { /* Dynamic linkage */ +#ifdef DYNLINKER + for (i = 0; dynlinker[i]; i++) + av[j++] = dynlinker[i]; +#endif + } else { +#ifdef os_darwin + av[j++] = "-static"; +#else + av[j++] = "-Bstatic"; +#endif + } + } if (outfile) { +#ifdef MSLINKER +#define OUTSTR "/OUT:" + char *s = copy(OUTSTR, i = strlen(outfile)); + strlcat(s, outfile, sizeof(OUTSTR) + i); + av[j++] = s; +#else av[j++] = "-o"; av[j++] = outfile; +#endif } - if (!nostartfiles) { - av[j++] = crt0file; - for (i = 0; startfiles[i]; i++) - av[j++] = startfiles[i]; +#ifdef STARTFILES_S + if (shared) { + if (!nostartfiles) { + for (i = 0; startfiles_S[i]; i++) + av[j++] = Bprefix(startfiles_S[i]); + } + } else +#endif + { + if (!nostartfiles) { +#ifdef CRT0FILE_PROFILE + if (pgflag) { + av[j++] = Bprefix(crt0file_profile); + } else +#endif + { +#ifdef CRT0FILE + av[j++] = Bprefix(crt0file); +#endif + } +#ifdef STARTFILES_T + if (Bstatic) { + for (i = 0; startfiles_T[i]; i++) + av[j++] = Bprefix(startfiles_T[i]); + } else +#endif + { +#ifdef STARTFILES + for (i = 0; startfiles[i]; i++) + av[j++] = Bprefix(startfiles[i]); +#endif + } + } } i = 0; while(i= MAXAV) error("Too many ld options"); } +#ifndef MACHOABI + /* darwin assembler doesn't want -g */ + if (gflag) + av[j++] = "-g"; +#endif #if 0 if (gflag) av[j++] = "-lg"; #endif if (pthreads) av[j++] = "-lpthread"; - if (!nostdlib) - for (i = 0; libclibs[i]; i++) - av[j++] = libclibs[i]; + if (!nostdlib) { +#ifdef MSLINKER +#define DL "/LIBPATH:" +#else +#define DL "-L" +#endif + char *s = copy(DL, i = strlen(pcclibdir)); + strlcat(s, pcclibdir, sizeof(DL) + i); + av[j++] = s; +#ifdef os_win32 + s = copy(DL, i = strlen(libdir)); + strlcat(s, libdir, sizeof(DL) + i); + av[j++] = s; +#endif + if (pgflag) { + for (i = 0; libclibs_profile[i]; i++) + av[j++] = Bprefix(libclibs_profile[i]); + } else { + for (i = 0; libclibs[i]; i++) + av[j++] = Bprefix(libclibs[i]); + } + } if (!nostartfiles) { - for (i = 0; endfiles[i]; i++) - av[j++] = endfiles[i]; +#ifdef STARTFILES_S + if (shared) { + for (i = 0; endfiles_S[i]; i++) + av[j++] = Bprefix(endfiles_S[i]); + } else +#endif + { +#ifdef STARTFILES_T + if (Bstatic) { + for (i = 0; endfiles_T[i]; i++) + av[j++] = Bprefix(endfiles_T[i]); + } else +#endif + { +#ifdef STARTFILES + for (i = 0; endfiles[i]; i++) + av[j++] = Bprefix(endfiles[i]); +#endif + } + } } av[j++] = 0; - eflag |= callsys("/bin/ld", av); + eflag |= callsys(ld, av); if (nc==1 && nxo==1 && eflag==0) cunlink(setsuf(clist[0], 'o')); else if (nc > 0 && eflag == 0) { @@ -572,6 +1010,10 @@ cunlink(tmp3); cunlink(tmp4); } + if (exfail || eflag) + cunlink(ermfile); + if (eval == 100) + _exit(eval); exit(eval); } @@ -612,14 +1054,47 @@ dexit(eval); } +char * +Bprefix(char *s) +{ + char *suffix; + char *str; + int i; + +#ifdef os_win32 + + /* put here to save sprinkling it ~everywhere */ + s = win32pathsubst(s); + + if (Bflag == NULL) + return s; + suffix = strrchr(s, '/'); + if (suffix == NULL) + suffix = strrchr(s, '\\'); + +#else + + if (Bflag == NULL || s[0] != '/') + return s; + suffix = strrchr(s, '/'); + +#endif + + if (suffix == NULL) + suffix = s; + + str = copy(Bflag, i = strlen(suffix)); + strlcat(str, suffix, strlen(Bflag) + i + 1); + return str; +} + int -getsuf(as) -char as[]; +getsuf(char *s) { - register char *s; + register char *p; - if ((s = strrchr(as, '.')) && s[1] != '\0' && s[2] == '\0') - return s[1]; + if ((p = strrchr(s, '.')) && p[1] != '\0' && p[2] == '\0') + return p[1]; return(0); } @@ -629,16 +1104,71 @@ char * setsuf(char *s, char ch) { - s = copy(basename(s)); - s[strlen(s) - 1] = ch; + char *p; + + s = copy(basename(s), 2); + if ((p = strrchr(s, '.')) == NULL) { + p = s + strlen(s); + p[0] = '.'; + } + p[1] = ch; + p[2] = '\0'; return(s); } +#ifdef WIN32 int -callsys(char f[], char *v[]) +callsys(char *f, char *v[]) { - int status; - pid_t t; + int t; + char cmd[MAX_PATH]; + int len; + STARTUPINFO si; + PROCESS_INFORMATION pi; + DWORD exitCode; + BOOL ok; + + len = strlcpy(cmd, f, MAX_PATH); + for (t = 1; v[t] && len < MAX_PATH; t++) { + len = strlcat(cmd, " ", MAX_PATH); + len = strlcat(cmd, v[t], MAX_PATH); + } + + if (vflag) + printf("%s\n", cmd); + + ZeroMemory(&si, sizeof(STARTUPINFO)); + si.cb = sizeof(STARTUPINFO); + ZeroMemory(&pi, sizeof(PROCESS_INFORMATION)); + + ok = CreateProcess(NULL, // the executable program + cmd, // the command line arguments + NULL, // ignored + NULL, // ignored + TRUE, // inherit handles + HIGH_PRIORITY_CLASS, + NULL, // ignored + NULL, // ignored + &si, + &pi); + + if (!ok) { + fprintf(stderr, "Can't find %s\n", f); + return 100; + } + + WaitForSingleObject(pi.hProcess, INFINITE); + GetExitCodeProcess(pi.hProcess, &exitCode); + return (exitCode != 0); +} + +#else + +int +callsys(char *f, char *v[]) +{ + int t, status = 0; + pid_t p; char *s; if (vflag) { @@ -648,82 +1178,94 @@ fprintf(stderr, "\n"); } - if ((t=fork())==0) { + if ((p = fork()) == 0) { if (Bflag) { size_t len = strlen(Bflag) + 8; char *a = malloc(len); - if (a == NULL) - errorx(1, "callsys: malloc failed\n"); + if (a == NULL) { + error("callsys: malloc failed"); + exit(1); + } if ((s = strrchr(f, '/'))) { strlcpy(a, Bflag, len); strlcat(a, s, len); execv(a, v); } } - execv(f, v); + execvp(f, v); if ((s = strrchr(f, '/'))) execvp(s+1, v); - printf("Can't find %s\n", f); - exit(100); - } else - if (t == -1) { + fprintf(stderr, "Can't find %s\n", f); + _exit(100); + } else { + if (p == -1) { printf("Try again\n"); return(100); } - while(t!=wait(&status)); - if ((t=(status&0377)) != 0 && t!=14) { - if (t!=2) /* interrupt */ - errorx(8, "Fatal error in %s", f); - dexit(eflag); } - return((status>>8) & 0377); + while (waitpid(p, &status, 0) == -1 && errno == EINTR) + ; + if (WIFEXITED(status)) + return (WEXITSTATUS(status)); + if (WIFSIGNALED(status)) + dexit(eflag ? eflag : 1); + errorx(8, "Fatal error in %s", f); + + return 0; } +#endif +/* + * Make a copy of string as, mallocing extra bytes in the string. + */ char * -copy(char *as) +copy(char *s, int extra) { - char *p; - - if ((p = strdup(as)) == NULL) - errorx(8, "no space for file names"); + int len = strlen(s)+1; + char *rv; - return p; + rv = ccmalloc(len+extra); + strlcpy(rv, s, len); + return rv; } int -nodup(l, os) -char **l, *os; +cunlink(char *f) { - register char *t, *s; - register int c; - - s = os; - if (getsuf(s) != 'o') - return(1); - while((t = *l++)) { - while((c = *s++)) - if (c != *t++) - break; - if (*t=='\0' && c=='\0') - return(0); - s = os; - } - return(1); + if (f==0 || Xflag) + return(0); + return (unlink(f)); } -int -cunlink(f) -char *f; +#ifdef WIN32 +char * +gettmp(void) { - if (f==0 || Xflag) - return(0); - return(unlink(f)); +#define BUFFSIZE 1000 + DWORD pathSize; + char pathBuffer[BUFFSIZE]; + char tempFilename[MAX_PATH]; + UINT uniqueNum; + + pathSize = GetTempPath(BUFFSIZE, pathBuffer); + if (pathSize < BUFFSIZE) + pathBuffer[pathSize] = 0; + else + pathBuffer[0] = 0; + uniqueNum = GetTempFileName(pathBuffer, "ctm", 0, tempFilename); + if (uniqueNum == 0) { + fprintf(stderr, "%s:\n", pathBuffer); + exit(8); + } + return copy(tempFilename, 0); } +#else + char * -gettmp() +gettmp(void) { - char *sfn = strdup("/tmp/ctm.XXXXXX"); + char *sfn = copy("/tmp/ctm.XXXXXX", 0); int fd = -1; if ((fd = mkstemp(sfn)) == -1) { @@ -731,6 +1273,43 @@ exit(8); } close(fd); - return sfn; } +#endif + +void * +ccmalloc(int size) +{ + void *rv; + + if ((rv = malloc(size)) == NULL) + error("malloc failed"); + return rv; +} + +#ifdef WIN32 + +char * +win32pathsubst(char *s) +{ + char env[1024]; + char *rv; + int len; + + len = ExpandEnvironmentStrings(s, env, sizeof(env)); + if (len <= 0) + return s; + + while (env[len-1] == '/' || env[len-1] == '\\' || env[len-1] == '\0') + env[--len] = 0; + + len += 3; + rv = ccmalloc(len); + strlcpy(rv, "\"", len); + strlcat(rv, env, len); + strlcat(rv, "\"", len); + + return rv; +} + +#endif Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cc/Makefile,v retrieving revision 1.8 retrieving revision 1.9 diff -L usr.bin/pcc/cc/Makefile -L usr.bin/pcc/cc/Makefile -u -r1.8 -r1.9 --- usr.bin/pcc/cc/Makefile +++ usr.bin/pcc/cc/Makefile @@ -5,8 +5,8 @@ TARGOS= midnightbsd TARGMACH= ${MACHINE_ARCH} -CFLAGS+= -DLIBEXECDIR=\"/usr/libexec\" -CFLAGS+= -I${.CURDIR}/.. +CFLAGS+= -DLIBEXECDIR=\"/usr/libexec/\" +CFLAGS+= -I${.CURDIR}/.. -I${.CURDIR}/../mip/ CFLAGS+= -Dmach_${TARGMACH} -Dos_${TARGOS} BINDIR= /usr/bin Index: inline.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/inline.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/inline.c -L usr.bin/pcc/ccom/inline.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/inline.c +++ usr.bin/pcc/ccom/inline.c @@ -1,6 +1,6 @@ -/* $Id: inline.c,v 1.17 2007/09/09 10:01:01 ragge Exp $ */ +/* $Id: inline.c,v 1.25 2008/11/28 15:23:57 ragge Exp $ */ /* - * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). + * Copyright (c) 2003, 2008 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -32,104 +32,135 @@ #include /* + * Simple description of how the inlining works: + * A function found with the keyword "inline" is always saved. + * If it also has the keyword "extern" it is written out thereafter. + * If it has the keyword "static" it will be written out if it is referenced. + * inlining will only be done if -xinline is given, and only if it is + * possible to inline the function. + */ +static void printip(struct interpass *pole); + +/* * ilink from ipole points to the next struct in the list of functions. */ static struct istat { - struct istat *ilink; - char *name; - int type; -#define NOTYETR 0 /* saved but not yet referenced */ -#define NOTYETW 1 /* saved and referenced but not yet written out */ -#define WRITTEN 2 /* is written out */ -#define NOTYETD 3 /* referenced but not yet saved */ + SLIST_ENTRY(istat) link; + struct symtab *sp; + int flags; +#define CANINL 1 /* function is possible to inline */ +#define WRITTEN 2 /* function is written out */ +#define REFD 4 /* Referenced but not yet written out */ + int *args; /* Array of arg temp numbers */ + int nargs; /* number of args in array */ + int retval; /* number of return temporary, if any */ struct interpass shead; -} *ipole, *cifun; +} *cifun; + +static SLIST_HEAD(, istat) ipole = { NULL, &ipole.q_forw }; +static int nlabs; #define IP_REF (MAXIP+1) +#ifdef PCC_DEBUG +#define SDEBUG(x) if (sdebug) printf x +#else +#define SDEBUG(x) +#endif -int isinlining, recovernodes; +int isinlining; int inlnodecnt, inlstatcnt; -#define ialloc() permalloc(sizeof(struct istat)); inlstatcnt++ -#define nalloc() permalloc(sizeof(NODE)) +#define SZSI sizeof(struct istat) +#define ialloc() memset(permalloc(SZSI), 0, SZSI); inlstatcnt++ static void -tcnt(NODE *p) +tcnt(NODE *p, void *arg) { inlnodecnt++; + if (nlabs > 1 && (p->n_op == REG || p->n_op == OREG) && + regno(p) == FPREG) + SLIST_FIRST(&ipole)->flags &= ~CANINL; /* no stack refs */ + if (nflag) + printf("locking node %p\n", p); } static struct istat * -findfun(char *name) +findfun(struct symtab *sp) { - struct istat *is = ipole; - while (is) { - if (is->name == name) + struct istat *is; + + SLIST_FOREACH(is, &ipole, link) + if (is->sp == sp) return is; - is = is->ilink; - } return NULL; } static void -refnode(char *str) +refnode(struct symtab *sp) { struct interpass *ip; - if (sdebug) - printf("refnode(%s)\n", str); + SDEBUG(("refnode(%s)\n", sp->sname)); ip = permalloc(sizeof(*ip)); ip->type = IP_REF; - ip->ip_name = str; + ip->ip_name = (char *)sp; inline_addarg(ip); } void inline_addarg(struct interpass *ip) { + extern NODE *cftnod; + +// SDEBUG(("inline_addarg(%p)\n", ip)); DLIST_INSERT_BEFORE(&cifun->shead, ip, qelem); + if (ip->type == IP_DEFLAB) + nlabs++; if (ip->type == IP_NODE) - walkf(ip->ip_node, tcnt); /* Count as saved */ + walkf(ip->ip_node, tcnt, 0); /* Count as saved */ + if (cftnod) + cifun->retval = regno(cftnod); } /* * Called to setup for inlining of a new function. */ void -inline_start(char *name) +inline_start(struct symtab *sp) { struct istat *is; - if (sdebug) - printf("inline_start(\"%s\")\n", name); + SDEBUG(("inline_start(\"%s\")\n", sp->sname)); if (isinlining) cerror("already inlining function"); - if ((is = findfun(name)) == 0) { - is = ialloc(); - is->ilink = ipole; - ipole = is; - is->name = name; - is->type = NOTYETR; + if ((is = findfun(sp)) != 0) { + if (!DLIST_ISEMPTY(&is->shead, qelem)) + uerror("inline function already defined"); } else { - if (is->type != NOTYETD) - cerror("inline function already defined"); - is->type = NOTYETW; + is = ialloc(); + is->sp = sp; + SLIST_INSERT_FIRST(&ipole, is, link); + DLIST_INIT(&is->shead, qelem); } - DLIST_INIT(&is->shead, qelem); cifun = is; + nlabs = 0; isinlining++; } void inline_end() { - if (sdebug) - printf("inline_end()\n"); + SDEBUG(("inline_end()\n")); + if (sdebug)printip(&cifun->shead); isinlining = 0; + if (cifun->sp->sclass == EXTDEF) { + cifun->flags |= REFD; + inline_prtout(); + } } /* @@ -138,49 +169,85 @@ * The function may not be defined when inline_ref() is called. */ void -inline_ref(char *name) +inline_ref(struct symtab *sp) { - struct istat *w = ipole; + struct istat *w; - if (sdebug) - printf("inline_ref(\"%s\")\n", name); + SDEBUG(("inline_ref(\"%s\")\n", sp->sname)); + if (sp->sclass == SNULL) + return; /* only inline, no references */ if (isinlining) { - refnode(name); + refnode(sp); } else { - while (w != NULL) { - if (w->name == name) { - if (w->type == NOTYETR) - w->type = NOTYETW; - return; /* setup for writeout */ - } - w = w->ilink; + SLIST_FOREACH(w,&ipole, link) { + if (w->sp != sp) + continue; + w->flags |= REFD; + return; } /* function not yet defined, print out when found */ w = ialloc(); - w->ilink = ipole; - ipole = w; - w->name = name; - w->type = NOTYETD; + w->sp = sp; + w->flags |= REFD; + SLIST_INSERT_FIRST(&ipole, w, link); + DLIST_INIT(&w->shead, qelem); } } static void puto(struct istat *w) { + struct interpass_prolog *ipp, *epp, *pp; struct interpass *ip, *nip; + extern int crslab; + int lbloff = 0; - /* if -O, list will be saved again so foreach cannot be used */ - ip = DLIST_NEXT(&w->shead, qelem); - while (ip != (&w->shead)) { - nip = DLIST_NEXT(ip, qelem); - DLIST_REMOVE(ip, qelem); - if (ip->type == IP_REF) - inline_ref(ip->ip_name); - else - pass2_compile(ip); - ip = nip; + /* Copy the saved function and print it out */ + ipp = 0; /* XXX data flow analysis */ + DLIST_FOREACH(ip, &w->shead, qelem) { + switch (ip->type) { + case IP_EPILOG: + case IP_PROLOG: + if (ip->type == IP_PROLOG) { + ipp = (struct interpass_prolog *)ip; + /* fix label offsets */ + lbloff = crslab - ipp->ip_lblnum; + } else { + epp = (struct interpass_prolog *)ip; + crslab += (epp->ip_lblnum - ipp->ip_lblnum); + } + pp = tmpalloc(sizeof(struct interpass_prolog)); + memcpy(pp, ip, sizeof(struct interpass_prolog)); + pp->ip_lblnum += lbloff; +#ifdef PCC_DEBUG + if (ip->type == IP_EPILOG && crslab != pp->ip_lblnum) + cerror("puto: %d != %d", crslab, pp->ip_lblnum); +#endif + pass2_compile((struct interpass *)pp); + break; + + case IP_REF: + inline_ref((struct symtab *)ip->ip_name); + break; + + default: + nip = tmpalloc(sizeof(struct interpass)); + *nip = *ip; + if (nip->type == IP_NODE) { + NODE *p; + + p = nip->ip_node = tcopy(nip->ip_node); + if (p->n_op == GOTO) + p->n_left->n_lval += lbloff; + else if (p->n_op == CBRANCH) + p->n_right->n_lval += lbloff; + } else if (nip->type == IP_DEFLAB) + nip->ip_lbl += lbloff; + pass2_compile(nip); + break; + } } - DLIST_INIT(&w->shead, qelem); + w->flags |= WRITTEN; } /* @@ -189,21 +256,246 @@ void inline_prtout() { - struct istat *w = ipole; + struct istat *w; int gotone = 0; - if (w == NULL) - return; - recovernodes++; - while (w != NULL) { - if (w->type == NOTYETW) { + SLIST_FOREACH(w, &ipole, link) { + if ((w->flags & (REFD|WRITTEN)) == REFD && + !DLIST_ISEMPTY(&w->shead, qelem)) { + defloc(w->sp); puto(w); - w->type = WRITTEN; + w->flags |= WRITTEN; gotone++; } - w = w->ilink; } if (gotone) inline_prtout(); - recovernodes--; +} + +#if 1 +static void +printip(struct interpass *pole) +{ + static char *foo[] = { + 0, "NODE", "PROLOG", "STKOFF", "EPILOG", "DEFLAB", "DEFNAM", "ASM" }; + struct interpass *ip; + struct interpass_prolog *ipplg, *epplg; + + DLIST_FOREACH(ip, pole, qelem) { + if (ip->type > MAXIP) + printf("IP(%d) (%p): ", ip->type, ip); + else + printf("%s (%p): ", foo[ip->type], ip); + switch (ip->type) { + case IP_NODE: printf("\n"); +#ifdef PCC_DEBUG + fwalk(ip->ip_node, eprint, 0); break; +#endif + case IP_PROLOG: + ipplg = (struct interpass_prolog *)ip; + printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", + ipplg->ipp_name, ipplg->ipp_vis ? "(local)" : "", + ipplg->ipp_regs[0], ipplg->ipp_autos, ipplg->ip_tmpnum, + ipplg->ip_lblnum); + break; + case IP_EPILOG: + epplg = (struct interpass_prolog *)ip; + printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", + epplg->ipp_name, epplg->ipp_vis ? "(local)" : "", + epplg->ipp_regs[0], epplg->ipp_autos, epplg->ip_tmpnum, + epplg->ip_lblnum); + break; + case IP_DEFLAB: printf(LABFMT "\n", ip->ip_lbl); break; + case IP_DEFNAM: printf("\n"); break; + case IP_ASM: printf("%s\n", ip->ip_asm); break; + default: + break; + } + } +} +#endif + +static int toff; + +static NODE * +mnode(int *n, NODE *p) +{ + NODE *q; + int num = *n + toff; + + if (p->n_op == CM) { + q = p->n_right; + q = tempnode(num, q->n_type, q->n_df, q->n_sue); + n--; + p->n_right = buildtree(ASSIGN, q, p->n_right); + p->n_left = mnode(n, p->n_left); + p->n_op = COMOP; + } else { + p = pconvert(p); + q = tempnode(num, p->n_type, p->n_df, p->n_sue); + p = buildtree(ASSIGN, q, p); + } + return p; +} + +static void +rtmps(NODE *p, void *arg) +{ + if (p->n_op == TEMP) + regno(p) += toff; +} + +/* + * Inline a function. Returns the return value. + * There are two major things that must be converted when + * inlining a function: + * - Label numbers must be updated with an offset. + * - The stack block must be relocated (add to REG or OREG). + * - Temporaries should be updated (but no must) + */ +NODE * +inlinetree(struct symtab *sp, NODE *f, NODE *ap) +{ + extern int crslab, tvaloff; + struct istat *is = findfun(sp); + struct interpass *ip, *ipf, *ipl; + int lmin, stksz, L0, L1, L2; + OFFSZ stkoff; + NODE *p, *rp; + + if (is == NULL) { + inline_ref(sp); /* prototype of not yet declared inline ftn */ + return NIL; + } + + SDEBUG(("inlinetree(%p,%p) OK %d\n", f, ap, is->flags & CANINL)); + + if ((is->flags & CANINL) == 0 || xinline == 0) { + if (is->sp->sclass == STATIC || is->sp->sclass == USTATIC) + is->flags |= REFD; /* if static inline, emit */ + return NIL; + } + +#ifdef mach_i386 + if (kflag) { + is->flags |= REFD; /* if static inline, emit */ + return NIL; /* XXX cannot handle hidden ebx arg */ + } +#endif + + stksz = stkoff = 0; + /* emit jumps to surround inline function */ + branch(L0 = getlab()); + plabel(L1 = getlab()); + L2 = getlab(); + SDEBUG(("branch labels %d,%d,%d\n", L0, L1, L2)); + + ipf = DLIST_NEXT(&is->shead, qelem); /* prolog */ + ipl = DLIST_PREV(&is->shead, qelem); /* epilog */ + + /* Fix label & temp offsets */ +#define IPP(x) ((struct interpass_prolog *)x) + SDEBUG(("pre-offsets crslab %d tvaloff %d\n", crslab, tvaloff)); + lmin = crslab - IPP(ipf)->ip_lblnum; + crslab += (IPP(ipl)->ip_lblnum - IPP(ipf)->ip_lblnum) + 1; + toff = tvaloff - IPP(ipf)->ip_tmpnum; + tvaloff += (IPP(ipl)->ip_tmpnum - IPP(ipf)->ip_tmpnum) + 1; + SDEBUG(("offsets crslab %d lmin %d tvaloff %d toff %d\n", + crslab, lmin, tvaloff, toff)); + + /* traverse until first real label */ + ipf = DLIST_NEXT(ipf, qelem); + do + ipf = DLIST_NEXT(ipf, qelem); + while (ipf->type != IP_DEFLAB); + + /* traverse backwards to last label */ + do + ipl = DLIST_PREV(ipl, qelem); + while (ipl->type != IP_DEFLAB); + + /* So, walk over all statements and emit them */ + for (ip = ipf; ip != ipl; ip = DLIST_NEXT(ip, qelem)) { + switch (ip->type) { + case IP_NODE: + p = tcopy(ip->ip_node); + if (p->n_op == GOTO) + p->n_left->n_lval += lmin; + else if (p->n_op == CBRANCH) + p->n_right->n_lval += lmin; + walkf(p, rtmps, 0); +#ifdef PCC_DEBUG + if (sdebug) { + printf("converted node\n"); + fwalk(ip->ip_node, eprint, 0); + fwalk(p, eprint, 0); + } +#endif + send_passt(IP_NODE, p); + break; + + case IP_DEFLAB: + SDEBUG(("converted label %d to %d\n", + ip->ip_lbl, ip->ip_lbl + lmin)); + send_passt(IP_DEFLAB, ip->ip_lbl + lmin); + break; + + case IP_ASM: + send_passt(IP_ASM, ip->ip_asm); + break; + + case IP_REF: + inline_ref((struct symtab *)ip->ip_name); + break; + + default: + cerror("bad inline stmt %d", ip->type); + } + } + SDEBUG(("last label %d to %d\n", ip->ip_lbl, ip->ip_lbl + lmin)); + send_passt(IP_DEFLAB, ip->ip_lbl + lmin); + + branch(L2); + plabel(L0); + + rp = block(GOTO, bcon(L1), NIL, INT, 0, MKSUE(INT)); + if (is->retval) + p = tempnode(is->retval + toff, DECREF(sp->stype), + sp->sdf, sp->ssue); + else + p = bcon(0); + rp = buildtree(COMOP, rp, p); + + if (is->nargs) { + p = mnode(&is->args[is->nargs-1], ap); + rp = buildtree(COMOP, p, rp); + } + + tfree(f); + return rp; +} + +void +inline_args(struct symtab **sp, int nargs) +{ + struct istat *cf; + int i; + + SDEBUG(("inline_args\n")); + cf = cifun; + /* + * First handle arguments. We currently do not inline anything if: + * - function has varargs + * - function args are volatile, checked if no temp node is asg'd. + */ + if (nargs) { + for (i = 0; i < nargs; i++) + if ((sp[i]->sflags & STNODE) == 0) + return; /* not temporary */ + cf->args = permalloc(sizeof(int)*nargs); + for (i = 0; i < nargs; i++) + cf->args[i] = sp[i]->soffset; + } + cf->nargs = nargs; + cf->flags |= CANINL; } Index: scan.l =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/scan.l,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/scan.l -L usr.bin/pcc/ccom/scan.l -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/scan.l +++ usr.bin/pcc/ccom/scan.l @@ -1,5 +1,5 @@ %{ -/* $Id: scan.l,v 1.61 2007/09/19 17:20:26 ragge Exp $ */ +/* $Id: scan.l,v 1.81 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2002 Anders Magnusson. All rights reserved. @@ -38,6 +38,7 @@ IS (u|U|l|L)* %{ +#include #include #include #include @@ -48,30 +49,29 @@ static NODE *cvtdig(int radix); static NODE *charcon(void); static void control(int); -static NODE *floatcon(void); -static NODE *fhexcon(void); -int notype, parbal; +static void pragma(void); +int notype, parbal, inattr, parlvl; +static int resw(TWORD, int); -#define CPP_PRAGMA 1 #define CPP_IDENT 2 #define CPP_LINE 3 #define CPP_HASH 4 #ifdef STABS -#define STABS_LINE(x) if (gflag && blevel) stabs_line(x) +#define STABS_LINE(x) if (gflag && cftnsp) stabs_line(x) #else #define STABS_LINE(x) #endif #if defined(FLEX_SCANNER) && YY_FLEX_SUBMINOR_VERSION >= 31 -/* Hack to avoid unneccessary warnings */ +/* Hack to avoid unnecessary warnings */ FILE *yyget_in (void); FILE *yyget_out (void); int yyget_leng (void); char *yyget_text (void); -void yyset_in (FILE * in_str ); -void yyset_out (FILE * out_str ); +void yyset_in (FILE *); +void yyset_out (FILE *); int yyget_debug (void); -void yyset_debug (int bdebug ); +void yyset_debug (int); int yylex_destroy (void); extern int yyget_lineno (void); extern void yyset_lineno (int); @@ -95,9 +95,9 @@ "case" { return(C_CASE); } "char" { yylval.nodep = mkty((TWORD)CHAR, 0, MKSUE(CHAR)); notype=1; return(C_TYPE); } -"const" { yylval.nodep = - block(QUALIFIER, NIL, NIL, CON, 0, 0); - return(C_QUALIFIER); } +"_Complex" { yylval.nodep = mkty((TWORD)COMPLEX, 0, MKSUE(DOUBLE)); + notype=1; return(C_TYPE); } +"const" { return resw(CON, C_QUALIFIER); } "continue" { return(C_CONTINUE); } "default" { return(C_DEFAULT); } "do" { return(C_DO); } @@ -125,60 +125,48 @@ notype=1; return(C_TYPE); } "sizeof" { return(C_SIZEOF); } "static" { yylval.intval = STATIC; return(C_CLASS); } -"struct" { yylval.intval = INSTRUCT; notype=1; return(C_STRUCT); } +"struct" { yylval.intval = STNAME; notype=1; return(C_STRUCT); } "switch" { return(C_SWITCH); } "typedef" { yylval.intval = TYPEDEF; return(C_CLASS); } -"union" { yylval.intval = INUNION; notype=1; return(C_STRUCT); } +"union" { yylval.intval = UNAME; notype=1; return(C_STRUCT); } "unsigned" { yylval.nodep = mkty((TWORD)UNSIGNED, 0, MKSUE(UNSIGNED)); notype=1; return(C_TYPE); } "void" { yylval.nodep = mkty((TWORD)VOID, 0, MKSUE(VOID)); notype=1; return(C_TYPE); } -"volatile" { yylval.nodep = - block(QUALIFIER, NIL, NIL, VOL, 0, 0); - return(C_QUALIFIER); } +"volatile" { return resw(VOL, C_QUALIFIER); } "while" { return(C_WHILE); } -{L}({L}|{D})* { struct symtab *s; - int i; +{L}({L}|{D})* { struct symtab *s; + int i = 0; - yylval.strp = addname(yytext); - if ((i = gcc_keyword(yylval.strp, - &yylval.nodep)) != 0) - return i; -// printf("str: %s notype %d parbal %d\n", yytext, notype, parbal); - if (!notype) { - s = lookup(yylval.strp, SNOCREAT); - if (s && s->sclass == TYPEDEF) - return notype=1, C_TYPENAME; - } - return(C_NAME); + yylval.strp = addname(yytext); +#ifdef GCC_COMPAT + if ((i = gcc_keyword(yylval.strp, &yylval.nodep)) > 0) + return i; +#endif + if (i == 0) { + if (notype) + return(C_NAME); + s = lookup(yylval.strp, SNOCREAT); + return s && s->sclass == TYPEDEF ? + notype=1, C_TYPENAME : C_NAME; } + } 0[xX]{H}+{IS}? { yylval.nodep = cvtdig(16); return(C_ICON); } 0{D}+{IS}? { yylval.nodep = cvtdig(8); return(C_ICON); } {D}+{IS}? { yylval.nodep = cvtdig(10); return(C_ICON); } L?'(\\.|[^\\'])+' { yylval.nodep = charcon(); return(C_ICON); } -{D}+{E}{FS}? { yylval.nodep = floatcon(); return(C_FCON); } -{D}*"."{D}+({E})?{FS}? { yylval.nodep = floatcon(); return(C_FCON); } -{D}+"."{D}*({E})?{FS}? { yylval.nodep = floatcon(); return(C_FCON); } -0[xX]{H}*"."{H}+{P}{FS}? { yylval.nodep = fhexcon(); return(C_FCON); } -0[xX]{H}+"."{P}{FS}? { yylval.nodep = fhexcon(); return(C_FCON); } -0[xX]{H}+{P}{FS}? { yylval.nodep = fhexcon(); return(C_FCON); } - -L?\"(\\.|[^\\"])*\" { - char *c = yytext; - int i = yyleng-2, rv; - - if (*c++ == 'L') { - c++, i--; - rv = C_WSTRING; - } else - rv = C_STRING; - c[i] = 0; /* last " */ - yylval.strp = c; - return rv; - } +{D}+{E}{FS}? { yylval.nodep = floatcon(yytext); return(C_FCON); } +{D}*"."{D}+({E})?{FS}? { yylval.nodep = floatcon(yytext); return(C_FCON); } +{D}+"."{D}*({E})?{FS}? { yylval.nodep = floatcon(yytext); return(C_FCON); } +0[xX]{H}*"."{H}+{P}{FS}? { yylval.nodep = fhexcon(yytext); return(C_FCON); } +0[xX]{H}+"."{P}{FS}? { yylval.nodep = fhexcon(yytext); return(C_FCON); } +0[xX]{H}+{P}{FS}? { yylval.nodep = fhexcon(yytext); return(C_FCON); } + +L?\"(\\.|[^\\"])*\" { yylval.strp = yytext; return C_STRING; } + "..." { return(C_ELLIPSIS); } ">>=" { yylval.intval = RSEQ; return(C_ASOP); } "<<=" { yylval.intval = LSEQ; return(C_ASOP); } @@ -203,12 +191,16 @@ "!=" { yylval.intval = NE; return(C_EQUOP); } ";" { notype = 0; return(';'); } ("{"|"<%") { notype = 0; return('{'); } -("}"|"%>") { return('}'); } +("}"|"%>") { if (rpole) notype = 1; return('}'); } "," { if (parbal) notype = 0; return(','); } ":" { return(':'); } "=" { return('='); } "(" { parbal++; notype = 0; return('('); } -")" { parbal--; if (parbal==0) { notype = 0; } return(')'); } +")" { parbal--; + if (parbal==0) { notype = 0; } + if (inattr && parlvl == parbal) + inattr = 0; + return(')'); } ("["|"<:") { return('['); } ("]"|":>") { return(']'); } "." { yylval.intval = DOT; return(C_STROP); } @@ -225,7 +217,7 @@ "^" { return('^'); } "|" { return('|'); } "?" { return('?'); } -^#pragma[ \t].* { control(CPP_PRAGMA); } +^#pragma[ \t].* { pragma(); } ^#ident[ \t].* { control(CPP_IDENT); } ^#line[ \t].* { control(CPP_LINE); } ^#.* { control(CPP_HASH); } @@ -246,6 +238,25 @@ return(1); } +int +resw(TWORD t, int rv) +{ + if (inattr) { + yylval.strp = addname(yytext); + return C_NAME; + } + + switch (rv) { + case C_QUALIFIER: + yylval.nodep = block(QUALIFIER, NIL, NIL, t, 0, 0); + return C_QUALIFIER; + default: + cerror("resw"); + } + return 0; +} + +#ifndef SOFTFLOAT /* * XXX floatcon() and fhexcon() should be in support libraries for * the target floating point. @@ -266,9 +277,9 @@ } NODE * -floatcon(void) +floatcon(char *s) { - return f2(yytext); + return f2(s); } static int @@ -283,10 +294,9 @@ } NODE * -fhexcon(void) +fhexcon(char *c) { char buf[500]; - char *c = yytext; unsigned long long num1, num2; /* XXX - convert it to a decimal float number and use strtod */ @@ -307,6 +317,7 @@ snprintf(buf, sizeof(buf), "%llu.%lluE%s", num1, num2, c); return f2(buf); } +#endif unsigned int esccon(char **sptr) @@ -325,9 +336,13 @@ case '\"': val = '\"'; break; case 'x': val = strtoul(wr, &wr, 16); break; case '0': case '1': case '2': case '3': case '4': - case '5': case '6': case '7': case '8': case '9': - wr--; - val = strtoul(wr, &wr, 8); + case '5': case '6': case '7': + val = wr[-1] - '0'; + if (*wr >= '0' && *wr <= '7') { + val = (val << 3) + (*wr++ - '0'); + if (*wr >= '0' && *wr <= '7') + val = (val << 3) + (*wr++ - '0'); + } break; default: val = wr[-1]; } @@ -387,8 +402,7 @@ ntype = UNSIGNED; } ntype = ctype(ntype); - p = block(ICON, NIL, NIL, ntype, 0, MKSUE(ntype)); - p->n_lval = v; + p = xbcon(v, NULL, ntype); ASGLVAL(p->n_slval, v); return p; @@ -432,7 +446,6 @@ wr++; /* Skip initial '#' */ switch (t) { - case CPP_PRAGMA: case CPP_IDENT: return; /* Just skip these for now. */ @@ -447,6 +460,8 @@ lineno = val - 1; while (*wr && *wr != '\"') wr++; + if (*wr == 0) + return; if (*wr++ != '\"') goto bad; eptr = wr; @@ -465,3 +480,62 @@ bad: werror("%s: illegal control", yytext); } + +/* + * split a pragma string in parts. + */ +static char ** +splitup(char *str) +{ + char *s, **ary; + int i; + + /* count ws. at least needed array size, add 2 to terminate */ + for (i = 2, s = str; *s; s++) + if (*s == ' ' || *s == '\t' || + *s == '(' || *s == ')' || *s == ',') + i++; + ary = tmpalloc(sizeof(char *)*i); + for (i = 0, s = strtok(str, " \t(,)"); s; s = strtok(NULL, " \t(,)")) + ary[i++] = s; + ary[i] = NULL; + return ary; +} + +int pragma_allpacked; +int pragma_packed, pragma_aligned; +char *pragma_renamed; + +/* + * got a full pragma line. Split it up here. + */ +static void +pragma() +{ + char **ary; + + ary = splitup(yytext); + if (ary[1] == NULL) + goto bad; + if (strcmp(ary[1], "pack") == 0) { + pragma_allpacked = ary[2] ? atoi(ary[2]) : 0; + } else if (strcmp(ary[1], "packed") == 0) { + pragma_packed = ary[2] ? atoi(ary[2]) : 1; + } else if (strcmp(ary[1], "aligned") == 0) { + pragma_aligned = ary[2] ? atoi(ary[2]) : 1; + } else if (strcmp(ary[1], "rename") == 0) { + pragma_renamed = newstring(ary[2], strlen(ary[2])); + } else if (mypragma(ary)) { + return; + } else { +bad: + if (Wunknown_pragmas) + werror("unknown pragma"); + } +} + +void +cunput(char c) +{ + unput(c); +} Index: pftn.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/pftn.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/pftn.c -L usr.bin/pcc/ccom/pftn.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/pftn.c +++ usr.bin/pcc/ccom/pftn.c @@ -1,4 +1,4 @@ -/* $Id: pftn.c,v 1.171 2007/09/23 20:00:22 ragge Exp $ */ +/* $Id: pftn.c,v 1.241 2008/12/14 17:19:50 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -69,49 +69,41 @@ #include /* XXX - for strcmp */ -struct symtab *spname; +#include "cgram.h" + struct symtab *cftnsp; -static int strunem; /* currently parsed member type */ int arglistcnt, dimfuncnt; /* statistics */ int symtabcnt, suedefcnt; /* statistics */ int autooff, /* the next unused automatic offset */ maxautooff, /* highest used automatic offset in function */ - argoff, /* the next unused argument offset */ - strucoff; /* the next structure offset position */ + argoff; /* the next unused argument offset */ int retlab = NOLAB; /* return label for subroutine */ int brklab; int contlab; int flostat; -int instruct, blevel; +int blevel; int reached, prolab; struct params; -#define ISSTR(ty) (ty == STRTY || ty == UNIONTY || ty == ENUMTY) +#define ISSTR(ty) (ty == STRTY || ty == UNIONTY) #define ISSOU(ty) (ty == STRTY || ty == UNIONTY) #define MKTY(p, t, d, s) r = talloc(); *r = *p; \ r = argcast(r, t, d, s); *p = *r; nfree(r); /* - * Info stored for delaying string printouts. - */ -struct strsched { - struct strsched *next; - int locctr; - struct symtab *sym; -} *strpole; - -/* * Linked list stack while reading in structs. */ struct rstack { struct rstack *rnext; - int rinstruct; - int rclass; - int rstrucoff; - struct params *rlparam; + int rsou; + int rstr; struct symtab *rsym; -}; + struct symtab *rb; + struct suedef *rsue; + int flags; +#define LASTELM 1 +} *rpole; /* * Linked list for parameter (and struct elements) declaration. @@ -127,6 +119,7 @@ static NODE *arrstk[10]; static int arrstkp; static int intcompare; +static NODE *parlink; void fixtype(NODE *p, int class); int fixclass(int class, TWORD type); @@ -135,9 +128,9 @@ void inforce(OFFSZ n); void vfdalign(int n); static void ssave(struct symtab *); -static void strprint(void); static void alprint(union arglist *al, int in); static void lcommadd(struct symtab *sp); +extern int fun_inline; int ddebug = 0; @@ -161,6 +154,9 @@ p = q->n_sp; + if (p->sname == NULL) + cerror("defining null identifier"); + #ifdef PCC_DEBUG if (ddebug) { printf("defid(%s (%p), ", p->sname, p); @@ -195,16 +191,13 @@ if (blevel == 1) { switch (class) { default: - if (!(class&FIELD)) + if (!(class&FIELD) && !ISFTN(type)) uerror("declared argument %s missing", p->sname ); case MOS: - case STNAME: case MOU: - case UNAME: - case MOE: - case ENAME: case TYPEDEF: + case PARAM: ; } } @@ -228,10 +221,11 @@ changed = 0; for (temp = type; temp & TMASK; temp = DECREF(temp)) { if (ISARY(temp)) { - if (dsym->ddim == 0) { + if (dsym->ddim == NOOFFSET) { dsym->ddim = ddef->ddim; changed = 1; - } else if (ddef->ddim != 0 && dsym->ddim!=ddef->ddim) { + } else if (ddef->ddim != NOOFFSET && + dsym->ddim!=ddef->ddim) { goto mismatch; } ++dsym; @@ -252,9 +246,7 @@ #endif /* check that redeclarations are to the same structure */ - if ((temp == STRTY || temp == UNIONTY || temp == ENUMTY) && - p->ssue != q->n_sue && - class != STNAME && class != UNAME && class != ENAME) { + if ((temp == STRTY || temp == UNIONTY) && p->ssue != q->n_sue) { goto mismatch; } @@ -265,99 +257,87 @@ printf(" previous class: %s\n", scnames(scl)); #endif - if (class&FIELD) { - /* redefinition */ - if (!falloc(p, class&FLDSIZ, 1, NIL)) { - /* successful allocation */ - ssave(p); - return; - } - /* blew it: resume at end of switch... */ - } else switch(class) { + if (class & FIELD) + return; + switch(class) { case EXTERN: switch( scl ){ case STATIC: case USTATIC: - if( slev==0 ) return; + if( slev==0 ) + goto done; break; case EXTDEF: case EXTERN: case FORTRAN: case UFORTRAN: - return; + goto done; + case SNULL: + if (p->sflags & SINLINE) { + p->sclass = EXTDEF; + inline_ref(p); + goto done; } + break; + } break; case STATIC: if (scl==USTATIC || (scl==EXTERN && blevel==0)) { p->sclass = STATIC; - return; + goto done; } if (changed || (scl == STATIC && blevel == slev)) - return; /* identical redeclaration */ + goto done; /* identical redeclaration */ break; case USTATIC: if (scl==STATIC || scl==USTATIC) - return; + goto done; break; case TYPEDEF: if (scl == class) - return; + goto done; break; case UFORTRAN: if (scl == UFORTRAN || scl == FORTRAN) - return; + goto done; break; case FORTRAN: if (scl == UFORTRAN) { p->sclass = FORTRAN; - return; + goto done; } break; case MOU: case MOS: - if (scl == class) { - if (oalloc(p, &strucoff)) - break; - if (class == MOU) - strucoff = 0; - ssave(p); - return; - } - break; - - case MOE: - break; + goto done; case EXTDEF: switch (scl) { case EXTERN: p->sclass = EXTDEF; - return; + goto done; case USTATIC: p->sclass = STATIC; - return; + goto done; } break; - case STNAME: - case UNAME: - case ENAME: - if (scl != class) - break; - if (p->ssue->suesize == 0) - return; /* previous entry just a mention */ - break; - case AUTO: case REGISTER: - ; /* mismatch.. */ + if (blevel == slev) + goto redec; + break; /* mismatch.. */ + case SNULL: + if (fun_inline && ISFTN(type)) + goto done; + break; } mismatch: @@ -368,12 +348,12 @@ if (blevel == slev || class == EXTERN || class == FORTRAN || class == UFORTRAN) { if (ISSTR(class) && !ISSTR(p->sclass)) { - uerror("redeclaration of %s", p->sname); +redec: uerror("redeclaration of %s", p->sname); return; } } if (blevel == 0) - uerror("redeclaration of %s", p->sname); + goto redec; q->n_sp = p = hide(p); enter: /* make a new entry */ @@ -387,24 +367,9 @@ p->sclass = class; p->slevel = blevel; p->soffset = NOOFFSET; - p->suse = lineno; - if (class == STNAME || class == UNAME || class == ENAME) { - p->ssue = permalloc(sizeof(struct suedef)); - suedefcnt++; - p->ssue->suesize = 0; - p->ssue->suelem = NULL; - p->ssue->suealign = ALSTRUCT; - } else { - switch (BTYPE(type)) { - case STRTY: - case UNIONTY: - case ENUMTY: - p->ssue = q->n_sue; - break; - default: - p->ssue = MKSUE(BTYPE(type)); - } - } + if (q->n_sue == NULL) + cerror("q->n_sue == NULL"); + p->ssue = q->n_sue; /* copy dimensions */ p->sdf = q->n_df; @@ -415,7 +380,6 @@ /* allocate offsets */ if (class&FIELD) { (void) falloc(p, class&FLDSIZ, 0, NIL); /* new entry */ - ssave(p); } else switch (class) { case REGISTER: @@ -427,47 +391,45 @@ else oalloc(p, &autooff); break; - case STATIC: - case EXTDEF: - p->soffset = getlab(); -#ifdef GCC_COMPAT - { extern char *renname; - if (renname) - gcc_rename(p, renname); - renname = NULL; + case PARAM: + if (ISARY(p->stype)) { + /* remove array type on parameters before oalloc */ + p->stype += (PTR-ARY); + p->sdf++; } -#endif + if (arrstkp) + dynalloc(p, &argoff); + else + oalloc(p, &argoff); break; - + + case STATIC: + case EXTDEF: case EXTERN: case UFORTRAN: case FORTRAN: p->soffset = getlab(); -#ifdef notdef - /* Cannot reset level here. What does the standard say??? */ - p->slevel = 0; -#endif -#ifdef GCC_COMPAT - { extern char *renname; - if (renname) - gcc_rename(p, renname); - renname = NULL; - } -#endif + if (pragma_renamed) + p->soname = pragma_renamed; + pragma_renamed = NULL; break; + case MOU: + rpole->rstr = 0; + /* FALLTHROUGH */ case MOS: - oalloc(p, &strucoff); + oalloc(p, &rpole->rstr); if (class == MOU) - strucoff = 0; - ssave(p); + rpole->rstr = 0; break; - - case MOE: - p->soffset = strucoff++; - ssave(p); + case SNULL: +#ifdef notdef + if (fun_inline) { + p->slevel = 1; + p->soffset = getlab(); + } +#endif break; - } #ifdef STABS @@ -475,12 +437,13 @@ stabs_newsym(p); #endif +done: + fixdef(p); /* Leave last word to target */ #ifdef PCC_DEBUG if (ddebug) printf( " sdf, ssue, offset: %p, %p, %d\n", p->sdf, p->ssue, p->soffset); #endif - } void @@ -492,13 +455,10 @@ p->next = NULL; p->sym = sym; - if (lparam == NULL) { - p->prev = (struct params *)&lpole; + if ((p->prev = lparam) == NULL) lpole = p; - } else { + else lparam->next = p; - p->prev = lparam; - } lparam = p; } @@ -508,22 +468,24 @@ void ftnend() { + extern NODE *cftnod; extern struct savbc *savbc; extern struct swdef *swpole; + extern int tvaloff; char *c; if (retlab != NOLAB && nerrors == 0) { /* inside a real function */ plabel(retlab); + if (cftnod) + ecomp(buildtree(FORCE, cftnod, NIL)); efcode(); /* struct return handled here */ - c = cftnsp->sname; -#ifdef GCC_COMPAT - c = gcc_findname(cftnsp); -#endif + c = cftnsp->soname; SETOFF(maxautooff, ALCHAR); - send_passt(IP_EPILOG, 0, maxautooff/SZCHAR, c, - cftnsp->stype, cftnsp->sclass == EXTDEF, retlab); + send_passt(IP_EPILOG, maxautooff/SZCHAR, c, + cftnsp->stype, cftnsp->sclass == EXTDEF, retlab, tvaloff); } + cftnod = NIL; tcheck(); brklab = contlab = retlab = NOLAB; flostat = 0; @@ -537,6 +499,7 @@ } savbc = NULL; lparam = NULL; + cftnsp = NULL; maxautooff = autooff = AUTOINIT; reached = 1; @@ -544,11 +507,13 @@ inline_end(); inline_prtout(); - strprint(); - tmpfree(); /* Release memory resources */ } +static struct symtab nulsym = { + NULL, 0, 0, 0, 0, "null", "null", INT, 0, NULL, NULL +}; + void dclargs() { @@ -556,15 +521,12 @@ union arglist *al, *al2, *alb; struct params *a; struct symtab *p, **parr = NULL; /* XXX gcc */ - char *c; int i; - argoff = ARGINIT; - /* * Deal with fun(void) properly. */ - if (nparams == 1 && lparam->sym->stype == VOID) + if (nparams == 1 && lparam->sym && lparam->sym->stype == VOID) goto done; /* @@ -575,11 +537,13 @@ parr = tmpalloc(sizeof(struct symtab *) * nparams); if (nparams) - for (a = lparam, i = 0; a != NULL && a != (struct params *)&lpole; - a = a->prev) { - + for (a = lparam, i = 0; a != NULL; a = a->prev) { p = a->sym; parr[i++] = p; + if (p == NULL) { + uerror("parameter %d name missing", i); + p = &nulsym; /* empty symtab */ + } if (p->stype == FARG) { p->stype = INT; p->ssue = MKSUE(INT); @@ -591,8 +555,6 @@ werror("function declared as argument"); p->stype = INCREF(p->stype); } - /* always set aside space, even for register arguments */ - oalloc(p, &argoff); #ifdef STABS if (gflag) stabs_newsym(p); @@ -618,41 +580,66 @@ if (chkftn(al, alb)) uerror("function doesn't match prototype"); intcompare = 0; + } + + if (oldstyle && nparams) { + /* Must recalculate offset for oldstyle args here */ + argoff = ARGINIT; + for (i = 0; i < nparams; i++) { + parr[i]->soffset = NOOFFSET; + oalloc(parr[i], &argoff); + } + } + done: cendarg(); - c = cftnsp->sname; -#ifdef GCC_COMPAT - c = gcc_findname(cftnsp); -#endif -#if 0 - prolab = getlab(); - send_passt(IP_PROLOG, -1, -1, c, cftnsp->stype, - cftnsp->sclass == EXTDEF, prolab); -#endif + plabel(prolab); /* after prolog, used in optimization */ retlab = getlab(); bfcode(parr, nparams); - if (xtemps) { - /* put arguments in temporaries */ - for (i = 0; i < nparams; i++) { - NODE *q, *r, *s; - - p = parr[i]; - if (p->stype == STRTY || p->stype == UNIONTY || - cisreg(p->stype) == 0) - continue; - spname = p; - q = buildtree(NAME, 0, 0); - r = tempnode(0, p->stype, p->sdf, p->ssue); - s = buildtree(ASSIGN, r, q); - p->soffset = r->n_lval; - p->sflags |= STNODE; - ecomp(s); - } - plabel(getlab()); /* used when spilling */ - } + if (fun_inline && xinline) + inline_args(parr, nparams); + plabel(getlab()); /* used when spilling */ + if (parlink) + ecomp(parlink); + parlink = NIL; lparam = NULL; nparams = 0; + symclear(1); /* In case of function pointer args */ +} + +/* + * Struct/union/enum symtab construction. + */ +static void +defstr(struct symtab *sp, int class) +{ + sp->ssue = permalloc(sizeof(struct suedef)); + memset(sp->ssue, 0, sizeof(struct suedef)); + sp->sclass = class; + if (class == STNAME) + sp->stype = STRTY; + else if (class == UNAME) + sp->stype = UNIONTY; + else if (class == ENAME) + sp->stype = ENUMTY; +} + +/* + * Declare a struct/union/enum tag. + * If not found, create a new tag with UNDEF type. + */ +static struct symtab * +deftag(char *name, int class) +{ + struct symtab *sp; + + if ((sp = lookup(name, STAGNAME))->ssue == NULL) { + /* New tag */ + defstr(sp, class); + } else if (sp->sclass != class) + uerror("tag %s redeclared", name); + return sp; } /* @@ -661,194 +648,246 @@ NODE * rstruct(char *tag, int soru) { - struct symtab *p; - NODE *q; + struct symtab *sp; - p = (struct symtab *)lookup(tag, STAGNAME); - switch (p->stype) { + sp = deftag(tag, soru); + return mkty(sp->stype, 0, sp->ssue); +} - case UNDEF: - def: - q = block(NAME, NIL, NIL, 0, 0, 0); - q->n_sp = p; - q->n_type = (soru&INSTRUCT) ? STRTY : - ((soru&INUNION) ? UNIONTY : ENUMTY); - defid(q, (soru&INSTRUCT) ? STNAME : - ((soru&INUNION) ? UNAME : ENAME)); - nfree(q); - break; +static int enumlow, enumhigh; +int enummer; - case STRTY: - if (soru & INSTRUCT) - break; - goto def; +/* + * Declare a member of enum. + */ +void +moedef(char *name) +{ + struct symtab *sp; - case UNIONTY: - if (soru & INUNION) - break; - goto def; + sp = lookup(name, SNORMAL); + if (sp->stype == UNDEF || (sp->slevel < blevel)) { + if (sp->stype != UNDEF) + sp = hide(sp); + sp->stype = INT; /* always */ + sp->ssue = MKSUE(INT); + sp->sclass = MOE; + sp->soffset = enummer; + } else + uerror("%s redeclared", name); + if (enummer < enumlow) + enumlow = enummer; + if (enummer > enumhigh) + enumhigh = enummer; + enummer++; +} - case ENUMTY: - if (!(soru&(INUNION|INSTRUCT))) - break; - goto def; +/* + * Declare an enum tag. Complain if already defined. + */ +struct symtab * +enumhd(char *name) +{ + struct symtab *sp; + + enummer = enumlow = enumhigh = 0; + if (name == NULL) + return NULL; + sp = deftag(name, ENAME); + if (sp->stype != ENUMTY) { + if (sp->slevel == blevel) + uerror("%s redeclared", name); + sp = hide(sp); + defstr(sp, ENAME); } - q = mkty(p->stype, 0, p->ssue); - q->n_sue = p->ssue; - return q; + sp->ssue->sylnk = sp; /* ourselves */ + return sp; } -void -moedef(char *name) +/* + * finish declaration of an enum + */ +NODE * +enumdcl(struct symtab *sp) { - NODE *q; + NODE *p; + TWORD t; - q = block(NAME, NIL, NIL, MOETY, 0, 0); - q->n_sp = lookup(name, 0); - defid(q, MOE); - nfree(q); +#ifdef ENUMSIZE + t = ENUMSIZE(enumhigh, enumlow); +#else + if (enumhigh <= MAX_CHAR && enumlow >= MIN_CHAR) + t = ctype(CHAR); + else if (enumhigh <= MAX_SHORT && enumlow >= MIN_SHORT) + t = ctype(SHORT); + else + t = ctype(INT); +#endif + if (sp) { + sp->stype = t; + sp->ssue = MKSUE(t); + } + p = mkty(t, 0, MKSUE(t)); + p->n_sp = sp; + return p; +} + +/* + * Handle reference to an enum + */ +NODE * +enumref(char *name) +{ + struct symtab *sp; + NODE *p; + + sp = lookup(name, STAGNAME); + +#ifdef notdef + /* + * 6.7.2.3 Clause 2: + * "A type specifier of the form 'enum identifier' without an + * enumerator list shall only appear after the type it specifies + * is complete." + */ + if (sp->sclass != ENAME) + uerror("enum %s undeclared", name); +#endif + if (sp->sclass == SNULL) { + /* declare existence of enum */ + sp = enumhd(name); + sp->stype = ENUMTY; + } + + p = mkty(sp->stype, 0, sp->ssue); + p->n_sp = sp; + return p; } /* * begining of structure or union declaration */ struct rstack * -bstruct(char *name, int soru) +bstruct(char *name, int soru, struct suedef *sue) { struct rstack *r; - struct symtab *s; - NODE *q; + struct symtab *sp; - if (name != NULL) - s = lookup(name, STAGNAME); - else - s = NULL; + if (name != NULL) { + sp = deftag(name, soru); + if (sp->ssue->suealign != 0) { + if (sp->slevel < blevel) { + sp = hide(sp); + defstr(sp, soru); + } else + uerror("%s redeclared", name); + } + } else + sp = NULL; - r = tmpalloc(sizeof(struct rstack)); - r->rinstruct = instruct; - r->rclass = strunem; - r->rstrucoff = strucoff; - - strucoff = 0; - instruct = soru; - q = block(NAME, NIL, NIL, 0, 0, 0); - q->n_sp = s; - if (instruct==INSTRUCT) { - strunem = MOS; - q->n_type = STRTY; - if (s != NULL) - defid(q, STNAME); - } else if(instruct == INUNION) { - strunem = MOU; - q->n_type = UNIONTY; - if (s != NULL) - defid(q, UNAME); - } else { /* enum */ - strunem = MOE; - q->n_type = ENUMTY; - if (s != NULL) - defid(q, ENAME); - } - r->rsym = q->n_sp; - r->rlparam = lparam; - nfree(q); + r = tmpcalloc(sizeof(struct rstack)); + r->rsou = soru; + r->rsym = sp; + r->rb = NULL; + r->rsue = sue; + r->rnext = rpole; + rpole = r; return r; } /* * Called after a struct is declared to restore the environment. + * Alignment and packing are handled here. + * - If ALSTRUCT is defined, this will be the struct alignment and the + * struct size will be a multiple of ALSTRUCT, otherwise it will use + * the alignment of the largest struct member. + * - If suep->suealigned is set, then it will specify the alignment. + * - If suep->suepacked is set, it will pack all struct members. */ NODE * -dclstruct(struct rstack *r) +dclstruct(struct rstack *r, struct suedef *suep) { NODE *n; - struct params *l, *m; struct suedef *sue; - struct symtab *p; - int al, sa, sz; - TWORD temp; - int i, high, low; + struct symtab *sp; + int al, sa, sz, coff; + struct suedef sues; + + if (suep && r->rsue) { /* merge */ + if (suep->suealigned == 0) + suep->suealigned = r->rsue->suealigned; + if (suep->suepacked == 0) + suep->suepacked = r->rsue->suepacked; + } else if (suep == NULL) + suep = r->rsue; + if (suep == NULL) + suep = memset(&sues, 0, sizeof sues); + + if (pragma_allpacked && !suep->suepacked) + suep->suepacked = pragma_allpacked; if (r->rsym == NULL) { sue = permalloc(sizeof(struct suedef)); + memset(sue, 0, sizeof(struct suedef)); suedefcnt++; - sue->suesize = 0; - sue->suealign = ALSTRUCT; } else sue = r->rsym->ssue; -#ifdef PCC_DEBUG - if (ddebug) - printf("dclstruct(%s)\n", r->rsym ? r->rsym->sname : "??"); -#endif - temp = (instruct&INSTRUCT)?STRTY:((instruct&INUNION)?UNIONTY:ENUMTY); - instruct = r->rinstruct; - strunem = r->rclass; +#ifdef ALSTRUCT al = ALSTRUCT; +#else + al = ALCHAR; +#endif - high = low = 0; - - if ((l = r->rlparam) == NULL) - l = lpole; - else - l = l->next; - - /* memory for the element array must be allocated first */ - for (m = l, i = 1; m != NULL; m = m->next) - i++; - sue->suelem = permalloc(sizeof(struct symtab *) * i); - - for (i = 0; l != NULL; l = l->next) { - sue->suelem[i++] = p = l->sym; - - if (p == NULL) - cerror("gummy structure member"); - if (temp == ENUMTY) { - if (p->soffset < low) - low = p->soffset; - if (p->soffset > high) - high = p->soffset; - p->ssue = sue; - continue; - } - sa = talign(p->stype, p->ssue); - if (p->sclass & FIELD) { - sz = p->sclass&FLDSIZ; - } else { - sz = tsize(p->stype, p->sdf, p->ssue); + /* + * extract size and alignment, recalculate offsets + * if struct should be packed. + */ + coff = 0; + sue->sylnk = r->rb; + for (sp = r->rb; sp; sp = sp->snext) { + sa = talign(sp->stype, sp->ssue); + if (sp->sclass & FIELD) + sz = sp->sclass&FLDSIZ; + else + sz = tsize(sp->stype, sp->sdf, sp->ssue); + if (suep->suepacked && r->rsou == STNAME) { + sp->soffset = coff; + coff += sz; + rpole->rstr = coff; } - if (sz > strucoff) - strucoff = sz; /* for use with unions */ + if (sz > rpole->rstr) + rpole->rstr = sz; /* for use with unions */ /* * set al, the alignment, to the lcm of the alignments * of the members. */ - SETOFF(al, sa); + if (suep->suepacked == 0) + SETOFF(al, sa); } - sue->suelem[i] = NULL; - SETOFF(strucoff, al); - if (temp == ENUMTY) { - TWORD ty; + /* If alignment given is larger that calculated, expand */ + if (suep->suealigned) + SETOFF(al, suep->suealigned); -#ifdef ENUMSIZE - ty = ENUMSIZE(high,low); -#else - if ((char)high == high && (char)low == low) - ty = ctype(CHAR); - else if ((short)high == high && (short)low == low) - ty = ctype(SHORT); - else - ty = ctype(INT); -#endif - strucoff = tsize(ty, 0, MKSUE(ty)); - sue->suealign = al = talign(ty, MKSUE(ty)); - } + SETOFF(rpole->rstr, al); - sue->suesize = strucoff; + sue->suesize = rpole->rstr; sue->suealign = al; + sue->suealigned = suep->suealigned; + sue->suepacked = suep->suepacked; + +#ifdef PCC_DEBUG + if (ddebug) { + printf("dclstruct(%s): size=%d, align=%d\n", + r->rsym ? r->rsym->sname : "??", + sue->suesize, sue->suealign); + } +#endif + + pragma_packed = pragma_aligned = 0; #ifdef STABS if (gflag) @@ -857,25 +896,77 @@ #ifdef PCC_DEBUG if (ddebug>1) { - int i; - - printf("\tsize %d align %d elem %p\n", - sue->suesize, sue->suealign, sue->suelem); - for (i = 0; sue->suelem[i] != NULL; ++i) { - printf("\tmember %s(%p)\n", - sue->suelem[i]->sname, sue->suelem[i]); + printf("\tsize %d align %d link %p\n", + sue->suesize, sue->suealign, sue->sylnk); + for (sp = sue->sylnk; sp != NULL; sp = sp->snext) { + printf("\tmember %s(%p)\n", sp->sname, sp); } } #endif - strucoff = r->rstrucoff; - if ((lparam = r->rlparam) != NULL) - lparam->next = NULL; - n = mkty(temp, 0, sue); + rpole = r->rnext; + n = mkty(r->rsou == STNAME ? STRTY : UNIONTY, 0, sue); return n; } /* + * Add a new member to the current struct or union being declared. + */ +void +soumemb(NODE *n, char *name, int class) +{ + struct symtab *sp, *lsp; + int incomp; + + if (rpole == NULL) + cerror("soumemb"); + + /* check if tag name exists */ + lsp = NULL; + for (sp = rpole->rb; sp != NULL; lsp = sp, sp = sp->snext) + if (*name != '*' && sp->sname == name) + uerror("redeclaration of %s", name); + + sp = getsymtab(name, SMOSNAME); + if (rpole->rb == NULL) + rpole->rb = sp; + else + lsp->snext = sp; + n->n_sp = sp; + if ((class & FIELD) == 0) + class = rpole->rsou == STNAME ? MOS : MOU; + defid(n, class); + + /* + * 6.7.2.1 clause 16: + * "...the last member of a structure with more than one + * named member may have incomplete array type;" + */ + if (ISARY(sp->stype) && sp->sdf->ddim == NOOFFSET) + incomp = 1; + else + incomp = 0; + if ((rpole->flags & LASTELM) || (rpole->rb == sp && incomp == 1)) + uerror("incomplete array in struct"); + if (incomp == 1) + rpole->flags |= LASTELM; + + /* + * 6.7.2.1 clause 2: + * "...such a structure shall not be a member of a structure + * or an element of an array." + */ + if (rpole->rsou == STNAME && sp->ssue->sylnk) { + struct symtab *lnk; + + for (lnk = sp->ssue->sylnk; lnk->snext; lnk = lnk->snext) + ; + if (ISARY(lnk->stype) && lnk->sdf->ddim == NOOFFSET) + uerror("incomplete struct in struct"); + } +} + +/* * error printing routine in parser */ void yyerror(char *s); @@ -900,74 +991,44 @@ ftnarg(NODE *p) { NODE *q; - struct symtab *s; #ifdef PCC_DEBUG if (ddebug > 2) printf("ftnarg(%p)\n", p); #endif /* - * Enter argument onto param stack. - * Do not declare parameters until later (in dclargs); - * the function must be declared first. - * put it on the param stack in reverse order, due to the - * nature of the stack it will be reclaimed correct. + * Push argument symtab entries onto param stack in reverse order, + * due to the nature of the stack it will be reclaimed correct. */ for (; p->n_op != NAME; p = p->n_left) { - if (p->n_op == (UCALL) && p->n_left->n_op == NAME) + if (p->n_op == UCALL && p->n_left->n_op == NAME) return; /* Nothing to enter */ if (p->n_op == CALL && p->n_left->n_op == NAME) break; } p = p->n_right; - blevel = 1; - while (p->n_op == CM) { q = p->n_right; if (q->n_op != ELLIPSIS) { - s = lookup((char *)q->n_sp, 0); - if (s->stype != UNDEF) { - if (s->slevel > 0) - uerror("parameter '%s' redefined", - s->sname); - s = hide(s); - } - s->soffset = NOOFFSET; - s->sclass = PARAM; - s->stype = q->n_type; - s->sdf = q->n_df; - s->ssue = q->n_sue; - ssave(s); + ssave(q->n_sp); nparams++; #ifdef PCC_DEBUG if (ddebug > 2) printf(" saving sym %s (%p) from (%p)\n", - s->sname, s, q); + q->n_sp->sname, q->n_sp, q); #endif } p = p->n_left; } - s = lookup((char *)p->n_sp, 0); - if (s->stype != UNDEF) { - if (s->slevel > 0) - uerror("parameter '%s' redefined", s->sname); - s = hide(s); - } - s->soffset = NOOFFSET; - s->sclass = PARAM; - s->stype = p->n_type; - s->sdf = p->n_df; - s->ssue = p->n_sue; - ssave(s); + ssave(p->n_sp); if (p->n_type != VOID) nparams++; - blevel = 0; #ifdef PCC_DEBUG if (ddebug > 2) printf(" saving sym %s (%p) from (%p)\n", - s->sname, s, p); + nparams ? p->n_sp->sname : "", p->n_sp, p); #endif } @@ -1001,35 +1062,9 @@ } } - switch( BTYPE(ty) ){ - - case UNIONTY: - case ENUMTY: - case STRTY: - return((unsigned int)sue->suealign); - case BOOL: - return (ALBOOL); - case CHAR: - case UCHAR: - return (ALCHAR); - case FLOAT: - return (ALFLOAT); - case LDOUBLE: - return (ALLDOUBLE); - case DOUBLE: - return (ALDOUBLE); - case LONGLONG: - case ULONGLONG: - return (ALLONGLONG); - case LONG: - case ULONG: - return (ALLONG); - case SHORT: - case USHORT: - return (ALSHORT); - default: - return (ALINT); - } + if (sue->suealign == 0) + uerror("no alignment"); + return sue->suealign; } /* compute the size associated with type ty, @@ -1052,6 +1087,8 @@ case PTR: return( SZPOINT(ty) * mult ); case ARY: + if (d->ddim == NOOFFSET) + return 0; mult *= d->ddim; d++; continue; @@ -1074,7 +1111,7 @@ return(SZINT); } } else { - if (sue->suelem == NULL) + if (sue->suealign == 0) uerror("unknown structure/union/enum"); } @@ -1082,146 +1119,59 @@ } /* - * Write last part of wide string. - * Do not bother to save wide strings. + * Save string (and print it out). If wide then wide string. */ NODE * -wstrend(char *str) +strend(int wide, char *str) { - struct symtab *sp = getsymtab(str, SSTRING|STEMP); - struct strsched *sc = tmpalloc(sizeof(struct strsched)); - NODE *p = block(NAME, NIL, NIL, WCHAR_TYPE+ARY, - tmpalloc(sizeof(union dimfun)), MKSUE(WCHAR_TYPE)); - int i; - char *c; - - sp->sclass = ILABEL; - sp->soffset = getlab(); - sp->stype = WCHAR_TYPE+ARY; - - sc = tmpalloc(sizeof(struct strsched)); - sc->locctr = STRNG; - sc->sym = sp; - sc->next = strpole; - strpole = sc; - - /* length calculation, used only for sizeof */ - for (i = 0, c = str; *c; ) { - if (*c++ == '\\') - (void)esccon(&c); - i++; - } - p->n_df->ddim = (i+1) * ((MKSUE(WCHAR_TYPE))->suesize/SZCHAR); - p->n_sp = sp; - return(p); -} - -/* - * Write last part of string. - */ -NODE * -strend(char *str) -{ -// extern int maystr; - struct symtab *s; + struct symtab *sp; NODE *p; - int i; - char *c; /* If an identical string is already emitted, just forget this one */ - str = addstring(str); /* enter string in string table */ - s = lookup(str, SSTRING); /* check for existance */ - - if (s->soffset == 0 /* && maystr == 0 */) { /* No string */ - struct strsched *sc; - s->sclass = ILABEL; - - /* - * Delay printout of this string until after the current - * function, or the end of the statement. - */ - sc = tmpalloc(sizeof(struct strsched)); - sc->locctr = STRNG; - sc->sym = s; - sc->next = strpole; - strpole = sc; - s->soffset = getlab(); + if (wide) { + /* Do not save wide strings, at least not now */ + sp = getsymtab(str, SSTRING|STEMP); + } else { + str = addstring(str); /* enter string in string table */ + sp = lookup(str, SSTRING); /* check for existance */ } - p = block(NAME, NIL, NIL, CHAR+ARY, - tmpalloc(sizeof(union dimfun)), MKSUE(CHAR)); -#ifdef CHAR_UNSIGNED - p->n_type = UCHAR+ARY; -#endif - /* length calculation, used only for sizeof */ - for (i = 0, c = str; *c; ) { - if (*c++ == '\\') - (void)esccon(&c); - i++; - } - p->n_df->ddim = i+1; - p->n_sp = s; - return(p); -} + if (sp->soffset == 0) { /* No string */ + char *wr; + int i; -/* - * Print out new strings, before temp memory is cleared. - */ -void -strprint() -{ - char *wr; - int i, val, isw; - NODE *p = bcon(0); - - while (strpole != NULL) { - setloc1(STRNG); - deflab1(strpole->sym->soffset); - isw = strpole->sym->stype == WCHAR_TYPE+ARY; - - i = 0; - wr = strpole->sym->sname; - while (*wr != 0) { - if (*wr++ == '\\') - val = esccon(&wr); - else - val = (unsigned char)wr[-1]; - if (isw) { - p->n_lval = val; - p->n_type = WCHAR_TYPE; - ninval(i*(WCHAR_TYPE/SZCHAR), - (MKSUE(WCHAR_TYPE))->suesize, p); - } else - bycode(val, i); - i++; - } - if (isw) { - p->n_lval = 0; - ninval(i*(WCHAR_TYPE/SZCHAR), - (MKSUE(WCHAR_TYPE))->suesize, p); + sp->sclass = STATIC; + sp->slevel = 1; + sp->soffset = getlab(); + sp->squal = (CON >> TSHIFT); + sp->sdf = permalloc(sizeof(union dimfun)); + if (wide) { + sp->stype = WCHAR_TYPE+ARY; + sp->ssue = MKSUE(WCHAR_TYPE); } else { - bycode(0, i++); - bycode(-1, i); + if (funsigned_char) { + sp->stype = UCHAR+ARY; + sp->ssue = MKSUE(UCHAR); + } else { + sp->stype = CHAR+ARY; + sp->ssue = MKSUE(CHAR); + } } - strpole = strpole->next; + for (wr = sp->sname, i = 1; *wr; i++) + if (*wr++ == '\\') + (void)esccon(&wr); + + sp->sdf->ddim = i; + if (wide) + inwstring(sp); + else + instring(sp); } - nfree(p); -} -#if 0 -/* - * simulate byte v appearing in a list of integer values - */ -void -putbyte(int v) -{ - NODE *p; - p = bcon(v); - incode( p, SZCHAR ); - tfree( p ); -// gotscal(); + p = block(NAME, NIL, NIL, sp->stype, sp->sdf, sp->ssue); + p->n_sp = sp; + return(clocal(p)); } -#endif /* * update the offset pointed to by poff; return the @@ -1253,14 +1203,13 @@ /* * Only generate tempnodes if we are optimizing, * and only for integers, floats or pointers, - * and not if the basic type is volatile. + * and not if the type on this level is volatile. */ -/* XXX OLDSTYLE */ if (xtemps && ((p->sclass == AUTO) || (p->sclass == REGISTER)) && (p->stype < STRTY || ISPTR(p->stype)) && - !ISVOL((p->squal << TSHIFT)) && cisreg(p->stype)) { + !(cqual(p->stype, p->squal) & VOL) && cisreg(p->stype)) { NODE *tn = tempnode(0, p->stype, p->sdf, p->ssue); - p->soffset = tn->n_lval; + p->soffset = regno(tn); p->sflags |= STNODE; nfree(tn); return 0; @@ -1279,7 +1228,7 @@ } else #endif if (p->sclass == PARAM && (p->stype == CHAR || p->stype == UCHAR || - p->stype == SHORT || p->stype == USHORT)) { + p->stype == SHORT || p->stype == USHORT || p->stype == BOOL)) { off = upoff(SZINT, ALINT, &noff); #ifndef RTOLBYTES off = noff - tsz; @@ -1301,7 +1250,24 @@ } /* - * Allocate space on the stack for dynamic arrays. + * Delay emission of code generated in argument headers. + */ +static void +edelay(NODE *p) +{ + if (blevel == 1) { + /* Delay until after declarations */ + if (parlink == NULL) + parlink = p; + else + parlink = block(COMOP, parlink, p, 0, 0, 0); + } else + ecomp(p); +} + +/* + * Allocate space on the stack for dynamic arrays (or at least keep track + * of the index). * Strategy is as follows: * - first entry is a pointer to the dynamic datatype. * - if it's a one-dimensional array this will be the only entry used. @@ -1316,41 +1282,68 @@ union dimfun *df; NODE *n, *nn, *tn, *pol; TWORD t; - int i, no; + int astkp, no; /* - * The pointer to the array is stored in a TEMP node, which number - * is in the soffset field; + * The pointer to the array is not necessarily stored in a + * TEMP node, but if it is, its number is in the soffset field; */ t = p->stype; - p->sflags |= (STNODE|SDYNARRAY); - p->stype = INCREF(p->stype); /* Make this an indirect pointer */ - tn = tempnode(0, p->stype, p->sdf, p->ssue); - p->soffset = tn->n_lval; + astkp = 0; + if (ISARY(t) && blevel == 1) { + /* must take care of side effects of dynamic arg arrays */ + if (p->sdf->ddim < 0 && p->sdf->ddim != NOOFFSET) { + /* first-level array will be indexed correct */ + edelay(arrstk[astkp++]); + } + p->sdf++; + p->stype += (PTR-ARY); + t = p->stype; + } + if (ISARY(t)) { + p->sflags |= (STNODE|SDYNARRAY); + p->stype = INCREF(p->stype); /* Make this an indirect pointer */ + tn = tempnode(0, p->stype, p->sdf, p->ssue); + p->soffset = regno(tn); + } else { + oalloc(p, poff); + tn = NIL; + } df = p->sdf; pol = NIL; - for (i = 0; ISARY(t); t = DECREF(t), df++) { - if (df->ddim >= 0) + for (; t > BTMASK; t = DECREF(t)) { + if (!ISARY(t)) continue; - n = arrstk[i++]; - nn = tempnode(0, INT, 0, MKSUE(INT)); - no = nn->n_lval; - ecomp(buildtree(ASSIGN, nn, n)); /* Save size */ + if (df->ddim < 0) { + n = arrstk[astkp++]; + do { + nn = tempnode(0, INT, 0, MKSUE(INT)); + no = regno(nn); + } while (no == -NOOFFSET); + edelay(buildtree(ASSIGN, nn, n)); - df->ddim = -no; - n = tempnode(no, INT, 0, MKSUE(INT)); - if (pol == NIL) - pol = n; - else - pol = buildtree(MUL, pol, n); + df->ddim = -no; + n = tempnode(no, INT, 0, MKSUE(INT)); + } else + n = bcon(df->ddim); + + pol = (pol == NIL ? n : buildtree(MUL, pol, n)); + df++; } /* Create stack gap */ - if (pol == NIL) - uerror("aggregate dynamic array not allowed"); - else - spalloc(tn, pol, tsize(t, 0, p->ssue)); + if (blevel == 1) { + if (tn) + tfree(tn); + if (pol) + tfree(pol); + } else { + if (pol == NIL) + uerror("aggregate dynamic array not allowed"); + if (tn) + spalloc(tn, pol, tsize(t, 0, p->ssue)); + } arrstkp = 0; } @@ -1368,14 +1361,6 @@ /* this must be fixed to use the current type in alignments */ switch( new<0?pty->n_type:p->stype ){ - case ENUMTY: { - struct suedef *sue; - sue = new < 0 ? pty->n_sue : p->ssue; - al = sue->suealign; - sz = sue->suesize; - break; - } - case CHAR: case UCHAR: al = ALCHAR; @@ -1409,24 +1394,24 @@ } if( w == 0 ){ /* align only */ - SETOFF( strucoff, al ); + SETOFF( rpole->rstr, al ); if( new >= 0 ) uerror( "zero size field"); return(0); } - if( strucoff%al + w > sz ) SETOFF( strucoff, al ); + if( rpole->rstr%al + w > sz ) SETOFF( rpole->rstr, al ); if( new < 0 ) { - strucoff += w; /* we know it will fit */ + rpole->rstr += w; /* we know it will fit */ return(0); } /* establish the field */ if( new == 1 ) { /* previous definition */ - if( p->soffset != strucoff || p->sclass != (FIELD|w) ) return(1); + if( p->soffset != rpole->rstr || p->sclass != (FIELD|w) ) return(1); } - p->soffset = strucoff; - strucoff += w; + p->soffset = rpole->rstr; + rpole->rstr += w; p->stype = type; fldty( p ); return(0); @@ -1448,7 +1433,7 @@ if (class == SNULL) { if (blevel > 1) class = AUTO; - else if (blevel != 0 || instruct) + else if (blevel != 0 || rpole) cerror( "nidcl error" ); else /* blevel = 0 */ commflag = 1, class = EXTERN; @@ -1458,7 +1443,7 @@ sp = p->n_sp; /* check if forward decl */ - if (ISARY(sp->stype) && sp->sdf->ddim == 0) + if (ISARY(sp->stype) && sp->sdf->ddim == NOOFFSET) return; if (sp->sflags & SASG) @@ -1479,7 +1464,7 @@ if (blevel == 0) lcommadd(p->n_sp); else - lcommdec(p->n_sp); + defzero(p->n_sp); break; } } @@ -1539,173 +1524,161 @@ struct lcd *lc; SLIST_FOREACH(lc, &lhead, next) { - if (lc->sp != NULL) { - if (lc->sp->sclass == STATIC) - lcommdec(lc->sp); - else - commdec(lc->sp); - } + if (lc->sp != NULL) + defzero(lc->sp); } } /* - * Merges a type tree into one type. Returns one type node with merged types - * and class stored in the su field. Frees all other nodes. - * XXX - classes in typedefs? + * Merge given types to a single node. + * Any type can end up here. + * p is the old node, q is the old (if any). + * CLASS is AUTO, EXTERN, REGISTER, STATIC or TYPEDEF. + * QUALIFIER is VOL or CON + * TYPE is CHAR, SHORT, INT, LONG, SIGNED, UNSIGNED, VOID, BOOL, FLOAT, + * DOUBLE, STRTY, UNIONTY. */ NODE * typenode(NODE *p) { - NODE *l, *sp = NULL; - int class = 0, adj, noun, sign; - TWORD qual = 0; - - adj = INT; /* INT, LONG or SHORT */ - noun = UNDEF; /* INT, CHAR or FLOAT */ - sign = 0; /* 0, SIGNED or UNSIGNED */ - - /* Remove initial QUALIFIERs */ - if (p && p->n_op == QUALIFIER) { - qual = p->n_type; - l = p->n_left; - nfree(p); - p = l; - } - - /* Handle initial classes special */ - if (p && p->n_op == CLASS) { - class = p->n_type; - l = p->n_left; - nfree(p); - p = l; - } - - /* Remove more QUALIFIERs */ - if (p && p->n_op == QUALIFIER) { - qual |= p->n_type; - l = p->n_left; - nfree(p); - p = l; - } - -ag: if (p && p->n_op == TYPE) { - if (p->n_left == NIL) { -#ifdef CHAR_UNSIGNED - if (p->n_type == CHAR) - p->n_type = UCHAR; -#endif - if (p->n_type == SIGNED) - p->n_type = INT; -uni: p->n_lval = class; - p->n_qual = qual >> TSHIFT; - return p; - } else if (p->n_left->n_op == QUALIFIER) { - qual |= p->n_left->n_type; - l = p->n_left; - p->n_left = l->n_left; - nfree(l); - goto ag; - } else if (ISSTR(p->n_type)) { - /* Save node; needed for return */ - sp = p; - p = p->n_left; - } - } - - while (p != NIL) { - if (p->n_op == QUALIFIER) { - qual |= p->n_type; - goto next; - } - if (p->n_op == CLASS) { - if (class != 0) - uerror("too many storage classes"); + NODE *q, *saved; + TWORD type; + int class, qual; + int sig, uns, cmplx; + + cmplx = type = class = qual = sig = uns = 0; + saved = NIL; + + for (q = p; p; p = p->n_left) { + switch (p->n_op) { + case CLASS: + if (class) + goto bad; /* max 1 class */ class = p->n_type; - goto next; - } - if (p->n_op != TYPE) - cerror("typenode got notype %d", p->n_op); - switch (p->n_type) { - case UCHAR: - case USHORT: /* may come from typedef */ - if (sign != 0 || adj != INT) - goto bad; - noun = p->n_type; break; - case SIGNED: - case UNSIGNED: - if (sign != 0) - goto bad; - sign = p->n_type; + + case QUALIFIER: + qual |= p->n_type >> TSHIFT; break; - case LONG: - if (adj == LONG) { - adj = LONGLONG; + + case TYPE: + if (p->n_sp != NULL || ISSOU(p->n_type)) { + /* typedef, enum or struct/union */ + if (saved || type) + goto bad; + saved = p; break; - } - /* FALLTHROUGH */ - case SHORT: - if (adj != INT) + } else if ((p->n_type == SIGNED && uns) || + (p->n_type == UNSIGNED && sig)) goto bad; - adj = p->n_type; - break; - case INT: - case CHAR: + + switch (p->n_type) { + case BOOL: + case CHAR: + case FLOAT: + case VOID: + if (type) + goto bad; + type = p->n_type; + break; + case DOUBLE: + if (type == 0) + type = DOUBLE; + else if (type == LONG) + type = LDOUBLE; + else + goto bad; + break; + case SHORT: + if (type == 0 || type == INT) + type = SHORT; + else + goto bad; + break; + case INT: + if (type == SHORT || type == LONG || + type == LONGLONG) + break; + else if (type == 0) + type = INT; + else + goto bad; + break; + case LONG: + if (type == 0) + type = LONG; + else if (type == INT) + break; + else if (type == LONG) + type = LONGLONG; + else if (type == DOUBLE) + type = LDOUBLE; + else + goto bad; + break; + case SIGNED: + if (sig || uns) + goto bad; + sig = 1; + break; + case UNSIGNED: + if (sig || uns) + goto bad; + uns = 1; + break; + case COMPLEX: + cmplx = 1; + break; + default: + cerror("typenode"); + } + } + } + if (cmplx) { + if (sig || uns) + goto bad; + switch (type) { case FLOAT: - case DOUBLE: - if (noun != UNDEF) - goto bad; - noun = p->n_type; + type = FCOMPLEX; break; - case VOID: - if (noun != UNDEF || adj != INT) - goto bad; - adj = noun = VOID; + case DOUBLE: + type = COMPLEX; break; - case STRTY: - case UNIONTY: + case LDOUBLE: + type = LCOMPLEX; break; default: goto bad; } - next: - l = p->n_left; - nfree(p); - p = l; } - if (sp) { - p = sp; - goto uni; + if (saved && type) + goto bad; + if (sig || uns) { + if (type == 0) + type = sig ? INT : UNSIGNED; + if (type > ULONGLONG) + goto bad; + if (uns) + type = ENUNSIGN(type); } -#ifdef CHAR_UNSIGNED - if (noun == CHAR && sign == 0) - sign = UNSIGNED; -#endif - if (noun == UNDEF) { - noun = INT; - } else if (noun == FLOAT) { - if (sign != 0 || adj == SHORT) - goto bad; - noun = (adj == LONG ? DOUBLE : FLOAT); - } else if (noun == DOUBLE) { - if (sign != 0 || adj == SHORT) - goto bad; - noun = (adj == LONG ? LDOUBLE : DOUBLE); - } else if (noun == CHAR && adj != INT) - goto bad; + if (funsigned_char && type == CHAR && sig == 0) + type = UCHAR; + + /* free the chain */ + while (q) { + p = q->n_left; + if (q != saved) + nfree(q); + q = p; + } - if (adj != INT && (noun != DOUBLE && noun != LDOUBLE)) - noun = adj; - if (sign == UNSIGNED) - noun += (UNSIGNED-INT); - - p = block(TYPE, NIL, NIL, noun, 0, 0); - p->n_qual = qual >> TSHIFT; - if (strunem != 0) - class = strunem; + p = (saved ? saved : block(TYPE, NIL, NIL, type, 0, 0)); + p->n_qual = qual; p->n_lval = class; + if (BTYPE(p->n_type) == UNDEF) + MODTYPE(p->n_type, INT); return p; bad: uerror("illegal type combination"); @@ -1729,13 +1702,18 @@ (*ntdim)++; } -/* merge type typ with identifier idp */ +/* + * merge type typ with identifier idp. + * idp is returned as a NAME node with correct types. + * typ is untouched. + */ NODE * tymerge(NODE *typ, NODE *idp) { NODE *p; union dimfun *j; struct tylnk *base, tylnk, *tylkp; + struct suedef *sue; unsigned int t; int ntdim, i; @@ -1750,8 +1728,10 @@ } #endif + sue = idp->n_sue; + idp->n_type = typ->n_type; - idp->n_qual = (typ->n_qual << TSHIFT) | idp->n_qual; /* XXX ??? */ + idp->n_qual |= typ->n_qual; tylkp = &tylnk; tylkp->next = NULL; @@ -1776,12 +1756,29 @@ /* now idp is a single node: fix up type */ idp->n_type = ctype(idp->n_type); - idp->n_qual = DECQAL(idp->n_qual); /* in case ctype has rewritten things */ if ((t = BTYPE(idp->n_type)) != STRTY && t != UNIONTY && t != ENUMTY) idp->n_sue = MKSUE(t); +#if 1 + if (sue) { + struct suedef *s = permalloc(sizeof(struct suedef)); + *s = *idp->n_sue; + idp->n_sue = s; + if (sue->suealigned > s->suealign) + s->suealign = sue->suealigned; + s->suepacked = sue->suepacked; + s->suesection = sue->suesection; + } +#else + if (sue) { + if (sue->suealigned > idp->n_sue->suealign) + idp->n_sue->suealign = sue->suealigned; + idp->n_sue->suepacked = sue->suepacked; + } +#endif + if (idp->n_op != NAME) { for (p = idp->n_left; p->n_op != NAME; p = p->n_left) nfree(p); @@ -1818,8 +1815,7 @@ if (w->n_right->n_op == ELLIPSIS) continue; ty = w->n_right->n_type; - if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY || - BTYPE(ty) == ENUMTY) + if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY) num++; while (ISFTN(ty) == 0 && ISARY(ty) == 0 && ty > BTMASK) ty = DECREF(ty); @@ -1828,8 +1824,7 @@ } cnt++; ty = w->n_type; - if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY || - BTYPE(ty) == ENUMTY) + if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY) num++; while (ISFTN(ty) == 0 && ISARY(ty) == 0 && ty > BTMASK) ty = DECREF(ty); @@ -1863,8 +1858,7 @@ ap[j]->n_type = INCREF(ap[j]->n_type); ty = ap[j]->n_type; al[k++].type = ty; - if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY || - BTYPE(ty) == ENUMTY) + if (BTYPE(ty) == STRTY || BTYPE(ty) == UNIONTY) al[k++].sue = ap[j]->n_sue; while (ISFTN(ty) == 0 && ISARY(ty) == 0 && ty > BTMASK) ty = DECREF(ty); @@ -1875,8 +1869,10 @@ if (k > num) cerror("arglist: k%d > num%d", k, num); tfree(n); +#ifdef PCC_DEBUG if (pdebug) alprint(al, 0); +#endif return al; } @@ -1894,8 +1890,10 @@ TWORD t, q; o = p->n_op; - if (o == NAME) + if (o == NAME) { + p->n_qual = DECQAL(p->n_qual); return; + } t = INCREF(p->n_type); q = p->n_qual; @@ -1918,7 +1916,7 @@ nfree(p->n_right); #ifdef notdef /* XXX - check dimensions at usage time */ - if (dim.ddim == 0 && p->n_left->n_op == LB) + if (dim.ddim == NOOFFSET && p->n_left->n_op == LB) uerror("null dimension"); #endif } @@ -1975,25 +1973,153 @@ if (xnobuiltins) return NULL; #endif - - if (f->n_op != NAME) - return NULL; /* not direct call */ sp = f->n_sp; - /* XXX - strcmp is bad, use pointer comparision, redo someday */ - if (strcmp(sp->sname, "__builtin_alloca")) /* use GCC name */ - return NULL; /* not alloca */ - if (a == NULL || a->n_op == CM) { uerror("wrong arg count for alloca"); - return NULL; + return bcon(0); } t = tempnode(0, VOID|PTR, 0, MKSUE(INT) /* XXX */); - u = tempnode(t->n_lval, VOID|PTR, 0, MKSUE(INT) /* XXX */); + u = tempnode(regno(t), VOID|PTR, 0, MKSUE(INT) /* XXX */); spalloc(t, a, SZCHAR); tfree(f); return u; } + +/* + * Determine if a value is known to be constant at compile-time and + * hence that PCC can perform constant-folding on expressions involving + * that value. + */ +static NODE * +builtin_constant_p(NODE *f, NODE *a) +{ + int isconst = (a != NULL && a->n_op == ICON); + + tfree(f); + tfree(a); + + return bcon(isconst); +} + +#ifndef TARGET_STDARGS +static NODE * +builtin_stdarg_start(NODE *f, NODE *a) +{ + NODE *p, *q; + int sz; + + /* check num args and type */ + if (a == NULL || a->n_op != CM || a->n_left->n_op == CM || + !ISPTR(a->n_left->n_type)) + goto bad; + + /* must first deal with argument size; use int size */ + p = a->n_right; + if (p->n_type < INT) { + sz = SZINT/tsize(p->n_type, p->n_df, p->n_sue); + } else + sz = 1; + + /* do the real job */ + p = buildtree(ADDROF, p, NIL); /* address of last arg */ +#ifdef BACKAUTO + p = optim(buildtree(PLUS, p, bcon(sz))); /* add one to it (next arg) */ +#else + p = optim(buildtree(MINUS, p, bcon(sz))); /* add one to it (next arg) */ +#endif + q = block(NAME, NIL, NIL, PTR+VOID, 0, 0); /* create cast node */ + q = buildtree(CAST, q, p); /* cast to void * (for assignment) */ + p = q->n_right; + nfree(q->n_left); + nfree(q); + p = buildtree(ASSIGN, a->n_left, p); /* assign to ap */ + tfree(f); + nfree(a); + return p; +bad: + uerror("bad argument to __builtin_stdarg_start"); + return bcon(0); +} + +static NODE * +builtin_va_arg(NODE *f, NODE *a) +{ + NODE *p, *q, *r, *rv; + int sz, nodnum; + + /* check num args and type */ + if (a == NULL || a->n_op != CM || a->n_left->n_op == CM || + !ISPTR(a->n_left->n_type) || a->n_right->n_op != TYPE) + goto bad; + + /* create a copy to a temp node of current ap */ + p = tcopy(a->n_left); + q = tempnode(0, p->n_type, p->n_df, p->n_sue); + nodnum = regno(q); + rv = buildtree(ASSIGN, q, p); + + r = a->n_right; + sz = tsize(r->n_type, r->n_df, r->n_sue)/SZCHAR; + /* add one to ap */ +#ifdef BACKAUTO + rv = buildtree(COMOP, rv , buildtree(PLUSEQ, a->n_left, bcon(sz))); +#else +#error fix wrong eval order in builtin_va_arg + ecomp(buildtree(MINUSEQ, a->n_left, bcon(sz))); +#endif + + nfree(a->n_right); + nfree(a); + nfree(f); + r = tempnode(nodnum, INCREF(r->n_type), r->n_df, r->n_sue); + return buildtree(COMOP, rv, buildtree(UMUL, r, NIL)); +bad: + uerror("bad argument to __builtin_va_arg"); + return bcon(0); + +} + +static NODE * +builtin_va_end(NODE *f, NODE *a) +{ + tfree(f); + tfree(a); + return bcon(0); /* nothing */ +} + +static NODE * +builtin_va_copy(NODE *f, NODE *a) +{ + if (a == NULL || a->n_op != CM || a->n_left->n_op == CM) + goto bad; + tfree(f); + f = buildtree(ASSIGN, a->n_left, a->n_right); + nfree(a); + return f; + +bad: + uerror("bad argument to __builtin_va_copy"); + return bcon(0); +} +#endif /* TARGET_STDARGS */ + +static struct bitable { + char *name; + NODE *(*fun)(NODE *f, NODE *a); +} bitable[] = { + { "__builtin_alloca", builtin_alloca }, + { "__builtin_constant_p", builtin_constant_p }, +#ifndef TARGET_STDARGS + { "__builtin_stdarg_start", builtin_stdarg_start }, + { "__builtin_va_arg", builtin_va_arg }, + { "__builtin_va_end", builtin_va_end }, + { "__builtin_va_copy", builtin_va_copy }, +#endif +#ifdef TARGET_BUILTINS + TARGET_BUILTINS +#endif +}; #endif #ifdef PCC_DEBUG @@ -2010,16 +2136,18 @@ printf(" "); printf("arg %d: ", i++); tprint(stdout, al->type, 0); - if (BTYPE(al->type) == STRTY || - BTYPE(al->type) == UNIONTY || BTYPE(al->type) == ENUMTY) { + if (ISARY(al->type)) { + printf(" dim %d\n", al->df->ddim); + } else if (BTYPE(al->type) == STRTY || + BTYPE(al->type) == UNIONTY) { al++; - printf("dim %d\n", al->df->ddim); - } - printf("\n"); - if (ISFTN(DECREF(al->type))) { + printf(" (size %d align %d)", al->sue->suesize, + al->sue->suealign); + } else if (ISFTN(DECREF(al->type))) { al++; alprint(al->df->dfun, in+1); } + printf("\n"); } if (in == 0) printf("end arglist\n"); @@ -2031,7 +2159,7 @@ * Returns a merged node (via buildtree() of function and arguments. */ NODE * -doacall(NODE *f, NODE *a) +doacall(struct symtab *sp, NODE *f, NODE *a) { NODE *w, *r; union arglist *al; @@ -2054,7 +2182,7 @@ /* First let MD code do something */ calldec(f, a); /* XXX XXX hack */ - if ((f->n_op == CALL || f->n_op == CALL) && + if ((f->n_op == CALL) && f->n_left->n_op == ADDROF && f->n_left->n_left->n_op == NAME && (f->n_left->n_left->n_type & 0x7e0) == 0x4c0) @@ -2062,30 +2190,54 @@ /* XXX XXX hack */ #ifndef NO_C_BUILTINS - /* check for alloca */ - if ((w = builtin_alloca(f, a))) - return w; + /* check for builtins. function pointers are not allowed */ + if (f->n_op == NAME && + f->n_sp->sname[0] == '_' && f->n_sp->sname[1] == '_') { + int i; + + for (i = 0; i < (int)(sizeof(bitable)/sizeof(bitable[0])); i++) { + if (strcmp(bitable[i].name, f->n_sp->sname) == 0) + return (*bitable[i].fun)(f, a); + } + } #endif + + /* Check for undefined or late defined enums */ + if (BTYPE(f->n_type) == ENUMTY) { + /* not-yet check if declared enum */ + if (f->n_sue->sylnk->stype != ENUMTY) + MODTYPE(f->n_type, f->n_sue->sylnk->stype); + if (BTYPE(f->n_type) == ENUMTY) + uerror("enum %s not declared", f->n_sue->sylnk->sname); + } + /* * Do some basic checks. */ if (f->n_df == NULL || (al = f->n_df[0].dfun) == NULL) { if (Wimplicit_function_declaration) { - if (f->n_sp != NULL) - werror("no prototype for function '%s()'", - f->n_sp->sname); - else + if (f->n_sp != NULL) { + if (strncmp(f->n_sp->sname, + "__builtin", 9) != 0) + werror("no prototype for function " + "'%s()'", f->n_sp->sname); + } else { werror("no prototype for function pointer"); + } } /* floats must be cast to double */ if (a == NULL) goto build; for (w = a; w->n_op == CM; w = w->n_left) { + if (w->n_right->n_op == TYPE) + uerror("type is not an argument"); if (w->n_right->n_type != FLOAT) continue; w->n_right = argcast(w->n_right, DOUBLE, NULL, MKSUE(DOUBLE)); } + if (a->n_op == TYPE) + uerror("type is not an argument"); if (a->n_type == FLOAT) { MKTY(a, DOUBLE, 0, 0); } @@ -2103,7 +2255,7 @@ } #ifdef PCC_DEBUG if (pdebug) { - printf("arglist for %p\n", + printf("arglist for %s\n", f->n_sp != NULL ? f->n_sp->sname : "function pointer"); alprint(al, 0); } @@ -2149,8 +2301,19 @@ if ((hasarray = ISARY(arrt))) arrt += (PTR-ARY); #endif - if (ISARY(type)) - type += (PTR-ARY); + /* Taking addresses of arrays are meaningless in expressions */ + /* but people tend to do that and also use in prototypes */ + /* this is mostly a problem with typedefs */ + if (ISARY(type)) { + if (ISPTR(arrt) && ISARY(DECREF(arrt))) + type = INCREF(type); + else + type += (PTR-ARY); + } else if (ISPTR(type) && !ISARY(DECREF(type)) && + ISPTR(arrt) && ISARY(DECREF(arrt))) { + type += (ARY-PTR); + type = INCREF(type); + } /* Check structs */ if (type <= BTMASK && arrt <= BTMASK) { @@ -2162,12 +2325,17 @@ MKTY(apole->node, arrt, 0, 0) } } else if (ISSOU(BTYPE(type))) { - if (apole->node->n_sue != al[1].sue) + if (apole->node->n_sue->sylnk != al[1].sue->sylnk) goto incomp; } goto out; } + /* XXX should (recusively) check return type and arg list of + func ptr arg XXX */ + if (ISFTN(DECREF(arrt)) && ISFTN(type)) + type = INCREF(type); + /* Hereafter its only pointers (or arrays) left */ /* Check for struct/union intermixing with other types */ if (((type <= BTMASK) && ISSOU(BTYPE(type))) || @@ -2177,14 +2345,11 @@ /* Check for struct/union compatibility */ if (type == arrt) { if (ISSOU(BTYPE(type))) { - if (apole->node->n_sue == al[1].sue) + if (apole->node->n_sue->sylnk == al[1].sue->sylnk) goto out; } else goto out; } - if (BTYPE(arrt) == ENUMTY && BTYPE(type) == INT && - (arrt & ~BTMASK) == (type & ~BTMASK)) - goto skip; /* XXX enumty destroyed in optim() */ if (BTYPE(arrt) == VOID && type > BTMASK) goto skip; /* void *f = some pointer */ if (arrt > BTMASK && BTYPE(type) == VOID) @@ -2193,9 +2358,9 @@ goto skip; /* Anything assigned a zero */ if ((type & ~BTMASK) == (arrt & ~BTMASK)) { - /* do not complain for intermixed char/uchar */ - if ((BTYPE(type) == CHAR || BTYPE(type) == UCHAR) && - (BTYPE(arrt) == CHAR || BTYPE(arrt) == UCHAR)) + /* do not complain for pointers with signedness */ + if (!Wpointer_sign && + DEUNSIGN(BTYPE(type)) == DEUNSIGN(BTYPE(arrt))) goto skip; } @@ -2231,7 +2396,9 @@ if (apole != NULL) uerror("too many arguments to function"); -build: return buildtree(a == NIL ? UCALL : CALL, f, a); +build: if (sp != NULL && (sp->sflags & SINLINE) && (w = inlinetree(sp, f, a))) + return w; + return buildtree(a == NIL ? UCALL : CALL, f, a); } static int @@ -2241,9 +2408,9 @@ switch (type & TMASK) { case ARY: /* may be declared without dimension */ - if (dsym->ddim == 0) + if (dsym->ddim == NOOFFSET) dsym->ddim = ddef->ddim; - if (ddef->ddim && dsym->ddim != ddef->ddim) + if (ddef->ddim != NOOFFSET && dsym->ddim != ddef->ddim) return 1; dsym++, ddef++; break; @@ -2303,7 +2470,7 @@ t2 = usym->type; if (ISSTR(ty)) { usym++, udef++; - if (usym->sue != udef->sue) + if (usym->sue->sylnk != udef->sue->sylnk) return 1; } @@ -2345,7 +2512,7 @@ } /* detect function arguments, watching out for structure declarations */ - if (instruct && ISFTN(type)) { + if (rpole && ISFTN(type)) { uerror("function illegal in structure or union"); type = INCREF(type); } @@ -2371,12 +2538,14 @@ int fixclass(int class, TWORD type) { + extern int fun_inline; + /* first, fix null class */ if (class == SNULL) { - if (instruct&INSTRUCT) - class = MOS; - else if (instruct&INUNION) - class = MOU; + if (fun_inline && ISFTN(type)) + return SNULL; + if (rpole) + class = rpole->rsou == STNAME ? MOS : MOU; else if (blevel == 0) class = EXTDEF; else @@ -2402,28 +2571,23 @@ } } - if( class&FIELD ){ - if( !(instruct&INSTRUCT) ) uerror( "illegal use of field" ); - return( class ); - } - - switch( class ){ + if (class & FIELD) { + if (rpole && rpole->rsou != STNAME && rpole->rsou != UNAME) + uerror("illegal use of field"); + return(class); + } - case MOU: - if( !(instruct&INUNION) ) uerror( "illegal MOU class" ); - return( class ); + switch (class) { case MOS: - if( !(instruct&INSTRUCT) ) uerror( "illegal MOS class" ); - return( class ); - - case MOE: - if( instruct & (INSTRUCT|INUNION) ) uerror( "illegal MOE class" ); - return( class ); + case MOU: + if (rpole == NULL) + uerror("illegal member class"); + return(class); case REGISTER: if (blevel == 0) - uerror( "illegal register declaration" ); + uerror("illegal register declaration"); if (blevel == 1) return(PARAM); else @@ -2445,14 +2609,12 @@ uerror( "fortran function has wrong type" ); } } - case STNAME: - case UNAME: - case ENAME: case EXTERN: case STATIC: case EXTDEF: case TYPEDEF: case USTATIC: + case PARAM: return( class ); default: @@ -2504,7 +2666,7 @@ s = permalloc(sizeof(struct symtab)); symtabcnt++; } - s->sname = name; + s->sname = s->soname = name; s->snext = NULL; s->stype = UNDEF; s->squal = 0; @@ -2512,9 +2674,23 @@ s->sflags = flags & SMASK; s->soffset = 0; s->slevel = blevel; + s->sdf = NULL; + s->ssue = NULL; return s; } +int +fldchk(int sz) +{ + if (rpole->rsou != STNAME && rpole->rsou != UNAME) + uerror("field outside of structure"); + if (sz < 0 || sz >= FIELD) { + uerror("illegal field size"); + return 1; + } + return 0; +} + #ifdef PCC_DEBUG static char * ccnames[] = { /* names of storage classes */ @@ -2551,3 +2727,108 @@ return( ccnames[c] ); } #endif + +void +sspinit() +{ + NODE *p; + + p = block(NAME, NIL, NIL, FTN+VOID, 0, MKSUE(VOID)); + p->n_sp = lookup("__stack_chk_fail", SNORMAL); + defid(p, EXTERN); + nfree(p); + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_guard", SNORMAL); + defid(p, EXTERN); + nfree(p); +} + +void +sspstart() +{ + NODE *p, *q; + + q = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + q->n_sp = lookup("__stack_chk_guard", SNORMAL); + q = clocal(q); + + p = block(REG, NIL, NIL, INT, 0, 0); + p->n_lval = 0; + p->n_rval = FPREG; + q = block(ER, p, q, INT, 0, MKSUE(INT)); + q = clocal(q); + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_canary", SNORMAL); + defid(p, AUTO); + p = clocal(p); + + ecomp(buildtree(ASSIGN, p, q)); +} + +void +sspend() +{ + NODE *p, *q; + TWORD t; + int tmpnr = 0; + int lab; + + if (retlab != NOLAB) { + plabel(retlab); + retlab = getlab(); + } + + t = DECREF(cftnsp->stype); + if (t == BOOL) + t = BOOL_TYPE; + + if (t != VOID && !ISSOU(t)) { + p = tempnode(0, t, cftnsp->sdf, cftnsp->ssue); + tmpnr = regno(p); + q = block(REG, NIL, NIL, t, cftnsp->sdf, cftnsp->ssue); + q->n_rval = RETREG(t); + ecomp(buildtree(ASSIGN, p, q)); + } + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_canary", SNORMAL); + p = clocal(p); + + q = block(REG, NIL, NIL, INT, 0, 0); + q->n_lval = 0; + q->n_rval = FPREG; + q = block(ER, p, q, INT, 0, MKSUE(INT)); + + p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + p->n_sp = lookup("__stack_chk_guard", SNORMAL); + p = clocal(p); + + lab = getlab(); + cbranch(buildtree(EQ, p, q), bcon(lab)); + + p = block(NAME, NIL, NIL, FTN+VOID, 0, MKSUE(VOID)); + p->n_sp = lookup("__stack_chk_fail", SNORMAL); + p = clocal(p); + + ecomp(buildtree(UCALL, p, NIL)); + + plabel(lab); + + if (t != VOID && !ISSOU(t)) { + p = tempnode(tmpnr, t, cftnsp->sdf, cftnsp->ssue); + q = block(REG, NIL, NIL, t, cftnsp->sdf, cftnsp->ssue); + q->n_rval = RETREG(t); + ecomp(buildtree(ASSIGN, q, p)); + } +} + +/* + * Allocate on the permanent heap for inlines, otherwise temporary heap. + */ +void * +inlalloc(int size) +{ + return isinlining ? permalloc(size) : tmpalloc(size); +} Index: init.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/init.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/init.c -L usr.bin/pcc/ccom/init.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/init.c +++ usr.bin/pcc/ccom/init.c @@ -1,4 +1,4 @@ -/* $Id: init.c,v 1.30 2007/09/24 20:34:03 ragge Exp $ */ +/* $Id: init.c,v 1.47 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2004, 2007 Anders Magnusson (ragge at ludd.ltu.se). @@ -65,13 +65,13 @@ #include /* - * Four machine-dependent routines may be called during initialization: + * The following machine-dependent routines may be called during + * initialization: * - * instring(char *str) - Print out a string. * zbits(OFFSZ, int) - sets int bits of zero at position OFFSZ. * infld(CONSZ off, int fsz, CONSZ val) * - sets the bitfield val starting at off and size fsz. - * inval(CONSZ off, int fsz, NODE *) + * ninval(CONSZ off, int fsz, NODE *) * - prints an integer constant which may have * a label associated with it, located at off and * size fsz. @@ -118,8 +118,8 @@ */ static struct instk { struct instk *in_prev; /* linked list */ - struct symtab **in_xp; /* member in structure initializations */ - struct symtab *in_sym; /* stab index */ + struct symtab *in_lnk; /* member in structure initializations */ + struct symtab *in_sym; /* symtab index */ union dimfun *in_df; /* dimenston of array */ TWORD in_t; /* type for this level */ int in_n; /* number of arrays seen so far */ @@ -148,11 +148,20 @@ SLIST_ENTRY(llist) next; CONSZ begsz; /* bit offset of this entry */ struct ilist *il; -} *curll; -static SLIST_HEAD(, llist) lpole; +}; +static SLIST_HEAD(llh, llist) lpole; static CONSZ basesz; static int numents; /* # of array entries allocated */ +static struct initctx { + struct initctx *prev; + struct instk *pstk; + struct symtab *psym; + struct llh lpole; + CONSZ basesz; + int numents; +} *inilnk; + static struct ilist * getil(struct ilist *next, CONSZ b, int sz, NODE *n) { @@ -185,16 +194,19 @@ /* * Return structure containing off bitnumber. * Allocate more entries, if needed. - * This is not bright implemented. */ static struct llist * setll(OFFSZ off) { - struct llist *ll; + struct llist *ll = NULL; /* Ensure that we have enough entries */ while (off >= basesz * numents) - (void)getll(); + ll = getll(); + + if (ll != NULL && ll->begsz <= off && ll->begsz + basesz > off) + return ll; + SLIST_FOREACH(ll, &lpole, next) if (ll->begsz <= off && ll->begsz + basesz > off) break; @@ -209,14 +221,30 @@ void beginit(struct symtab *sp) { + struct initctx *ict; struct instk *is = &pbase; - struct llist *ll; #ifdef PCC_DEBUG if (idebug) printf("beginit(), sclass %s\n", scnames(sp->sclass)); #endif + if (pstk) { +#ifdef PCC_DEBUG + if (idebug) + printf("beginit: saving ctx pstk %p\n", pstk); +#endif + /* save old context */ + ict = tmpalloc(sizeof(struct initctx)); + ict->prev = inilnk; + inilnk = ict; + ict->pstk = pstk; + ict->psym = csym; + ict->lpole = lpole; + ict->basesz = basesz; + ict->numents = numents; + is = tmpalloc(sizeof(struct instk)); + } csym = sp; numents = 0; /* no entries in array list */ @@ -225,10 +253,9 @@ else basesz = tsize(DECREF(sp->stype), sp->sdf, sp->ssue); SLIST_INIT(&lpole); - curll = ll = getll(); /* at least first entry in list */ /* first element */ - is->in_xp = ISSOU(sp->stype) ? sp->ssue->suelem : NULL; + is->in_lnk = ISSOU(sp->stype) ? sp->ssue->sylnk : NULL; is->in_n = 0; is->in_t = sp->stype; is->in_sym = sp; @@ -276,25 +303,26 @@ is->in_n = 0; if (pstk == NULL) { /* stack empty */ - is->in_xp = ISSOU(sp->stype) ? sp->ssue->suelem : NULL; + is->in_lnk = ISSOU(sp->stype) ? sp->ssue->sylnk : NULL; is->in_t = sp->stype; is->in_sym = sp; is->in_df = sp->sdf; } else if (ISSOU(t)) { - sq = *pstk->in_xp; + sq = pstk->in_lnk; if (sq == NULL) { uerror("excess of initializing elements"); } else { - is->in_xp = ISSOU(sq->stype) ? sq->ssue->suelem : 0; + is->in_lnk = ISSOU(sq->stype) ? sq->ssue->sylnk : 0; is->in_t = sq->stype; is->in_sym = sq; is->in_df = sq->sdf; } } else if (ISARY(t)) { - is->in_xp = ISSOU(DECREF(t)) ? pstk->in_sym->ssue->suelem : 0; + is->in_lnk = ISSOU(DECREF(t)) ? pstk->in_sym->ssue->sylnk : 0; is->in_t = DECREF(t); is->in_sym = sp; - if (pstk->in_df->ddim && pstk->in_n >= pstk->in_df->ddim) { + if (pstk->in_df->ddim != NOOFFSET && + pstk->in_n >= pstk->in_df->ddim) { werror("excess of initializing elements"); pstk->in_n--; } @@ -326,9 +354,9 @@ printf("stkpop\n"); #endif for (; pstk; pstk = pstk->in_prev) { - if (pstk->in_t == STRTY) { - pstk->in_xp++; - if (*pstk->in_xp != NULL) + if (pstk->in_t == STRTY && pstk->in_lnk != NULL) { + pstk->in_lnk = pstk->in_lnk->snext; + if (pstk->in_lnk != NULL) break; } if (ISSOU(pstk->in_t) && pstk->in_fl) @@ -337,7 +365,7 @@ pstk->in_n++; if (pstk->in_fl) break; - if (pstk->in_df->ddim == 0 || + if (pstk->in_df->ddim == NOOFFSET || pstk->in_n < pstk->in_df->ddim) break; /* ger more elements */ } @@ -398,10 +426,12 @@ } } } +#ifdef PCC_DEBUG if (idebug>1) { printf("findoff: off %lld\n", off); prtstk(pstk); } +#endif return off; } @@ -445,24 +475,6 @@ } /* - * Align data and set correct location. - */ -static void -setscl(struct symtab *sp) -{ - setloc1((sp->squal << TSHIFT) & CON ? RDATA : DATA); - defalign(talign(sp->stype, sp->ssue)); - if (sp->sclass == EXTDEF || - (sp->sclass == STATIC && sp->slevel == 0)) { - defnam(sp); - } else { - if (sp->soffset == NOOFFSET) - cerror("setscl"); - deflab1(sp->soffset); - } -} - -/* * take care of generating a value for the initializer p * inoff has the current offset (last bit written) * in the current word being generated @@ -487,9 +499,11 @@ p = optim(p); +#ifdef notdef /* leave to the target to decide if useable */ if (csym->sclass != AUTO && p->n_op != ICON && p->n_op != FCON && p->n_op != NAME) cerror("scalinit not leaf"); +#endif /* Out of elements? */ if (pstk == NULL) { @@ -552,17 +566,14 @@ else typ = INT; /* Fake a struct reference */ - spname = csym; - p = buildtree(ADDROF, - buildtree(NAME, NIL, NIL), NIL); - r = block(ICON, NIL, NIL, typ, 0, MKSUE(typ)); + p = buildtree(ADDROF, nametree(csym), NIL); sym.stype = typ; sym.squal = 0; sym.sdf = 0; sym.ssue = MKSUE(typ); sym.soffset = off; sym.sclass = typ == INT ? FIELD | fsz : MOU; - r->n_sp = &sym; + r = xbcon(0, &sym, typ); p = block(STREF, p, r, INT, 0, MKSUE(INT)); ecode(buildtree(ASSIGN, stref(p), bcon(val))); } @@ -609,10 +620,10 @@ #endif if (csym->sclass != AUTO) - setscl(csym); + defloc(csym); /* Calculate total block size */ - if (ISARY(csym->stype) && csym->sdf->ddim == 0) { + if (ISARY(csym->stype) && csym->sdf->ddim == NOOFFSET) { tbit = numents*basesz; /* open-ended arrays */ csym->sdf->ddim = numents; if (csym->sclass == AUTO) { /* Get stack space */ @@ -644,20 +655,17 @@ (ll->begsz + il->off) - lastoff); /* Fake a struct reference */ - spname = csym; - p = buildtree(ADDROF, - buildtree(NAME, NIL, NIL), NIL); + p = buildtree(ADDROF, nametree(csym), NIL); n = il->n; - r = block(ICON, NIL, NIL, INT, 0, MKSUE(INT)); sym.stype = n->n_type; sym.squal = n->n_qual; sym.sdf = n->n_df; sym.ssue = n->n_sue; sym.soffset = ll->begsz + il->off; sym.sclass = fsz < 0 ? FIELD | -fsz : 0; - r->n_sp = &sym; + r = xbcon(0, &sym, INT); p = block(STREF, p, r, INT, 0, MKSUE(INT)); - ecode(buildtree(ASSIGN, stref(p), il->n)); + ecomp(buildtree(ASSIGN, stref(p), il->n)); if (fsz < 0) fsz = -fsz; @@ -670,7 +678,7 @@ infld(il->off, fsz, il->n->n_lval); } else ninval(il->off, fsz, il->n); - nfree(il->n); + tfree(il->n); } lastoff = ll->begsz + il->off + fsz; } @@ -679,6 +687,19 @@ clearbf(lastoff, tbit-lastoff); } else zbits(lastoff, tbit-lastoff); + if (inilnk) { + struct initctx *ict = inilnk; + pstk = ict->pstk; + csym = ict->psym; + lpole = ict->lpole; + basesz = ict->basesz; + numents = ict->numents; + inilnk = inilnk->prev; +#ifdef PCC_DEBUG + if (idebug) + printf("endinit: restoring ctx pstk %p\n", pstk); +#endif + } } /* @@ -731,8 +752,9 @@ if (ISARY(pstk->in_t)) pstk->in_n = pstk->in_df->ddim; else if (pstk->in_t == STRTY) { - while (pstk->in_xp[1] != NULL) - pstk->in_xp++; + while (pstk->in_lnk != NULL && + pstk->in_lnk->snext != NULL) + pstk->in_lnk = pstk->in_lnk->snext; } stkpop(); return; @@ -766,11 +788,11 @@ break; case NAME: - if (pstk->in_xp) { - for (; pstk->in_xp[0]; pstk->in_xp++) - if (pstk->in_xp[0]->sname == (char *)p->n_sp) + if (pstk->in_lnk) { + for (; pstk->in_lnk; pstk->in_lnk = pstk->in_lnk->snext) + if (pstk->in_lnk->sname == (char *)p->n_sp) break; - if (pstk->in_xp[0] == NULL) + if (pstk->in_lnk == NULL) uerror("member missing"); } else { uerror("not a struct/union"); @@ -798,12 +820,12 @@ pstk = pstk->in_prev; /* Empty stack */ if (ISSOU(pstk->in_t)) - pstk->in_xp = pstk->in_sym->ssue->suelem; + pstk->in_lnk = pstk->in_sym->ssue->sylnk; mkstack(p); /* Setup for assignment */ /* pop one step if SOU, ilbrace will push */ - if (op == NAME) + if (op == NAME || op == LB) pstk = pstk->in_prev; #ifdef PCC_DEBUG @@ -830,7 +852,7 @@ i = (unsigned char)s[-1]; asginit(bcon(i)); } - nfree(p); + tfree(p); } /* @@ -904,8 +926,8 @@ if (in->in_fl) printf("{ "); printf("soff=%d ", in->in_sym->soffset); if (in->in_t == STRTY) { - if (in->in_xp && in->in_xp[0]) - printf("curel %s ", in->in_xp[0]->sname); + if (in->in_lnk) + printf("curel %s ", in->in_lnk->sname); else printf("END struct"); } @@ -931,7 +953,7 @@ /* Handle "aaa" as { 'a', 'a', 'a' } */ beginit(sp); strcvt(p); - if (csym->sdf->ddim == 0) + if (csym->sdf->ddim == NOOFFSET) scalinit(bcon(0)); /* Null-term arrays */ endinit(); return; @@ -940,9 +962,8 @@ switch (sp->sclass) { case STATIC: case EXTDEF: - spname = sp; - p = optim(buildtree(ASSIGN, buildtree(NAME, NIL, NIL), p)); - setscl(sp); + p = optim(buildtree(ASSIGN, nametree(sp), p)); + defloc(sp); ninval(0, p->n_right->n_sue->suesize, p->n_right); tfree(p); break; @@ -951,8 +972,7 @@ case REGISTER: if (ISARY(sp->stype)) cerror("no array init"); - spname = sp; - ecomp(buildtree(ASSIGN, buildtree(NAME, NIL, NIL), p)); + ecomp(buildtree(ASSIGN, nametree(sp), p)); break; default: Index: gcc_compat.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/gcc_compat.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/gcc_compat.c -L usr.bin/pcc/ccom/gcc_compat.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/gcc_compat.c +++ usr.bin/pcc/ccom/gcc_compat.c @@ -1,4 +1,4 @@ -/* $Id: gcc_compat.c,v 1.7 2006/05/13 06:35:36 ragge Exp $ */ +/* $Id: gcc_compat.c,v 1.22 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -36,15 +36,46 @@ #include +/* Remove heading and trailing __ */ +static char * +decap(char *s) +{ + if (s[0] == '_' && s[1] == '_') { + int len = strlen(s); + + if (s[len-1] == '_' && s[len-2] == '_') { + s = tmpstrdup(s); /* will trash */ + s[len-2] = 0; + } + s += 2; + } + return s; +} + static struct kw { char *name, *ptr; int rv; } kw[] = { - { "__asm", NULL, C_ASM }, - { "__signed", NULL, 0 }, - { "__inline", NULL, C_FUNSPEC }, - { "__const", NULL, 0 }, - { "__asm__", NULL, C_ASM }, +/* + * Do NOT change the order of these entries unless you know + * what you're doing! + */ +/* 0 */ { "__asm", NULL, C_ASM }, +/* 1 */ { "__signed", NULL, 0 }, +/* 2 */ { "__inline", NULL, C_FUNSPEC }, +/* 3 */ { "__const", NULL, 0 }, +/* 4 */ { "__asm__", NULL, C_ASM }, +/* 5 */ { "__inline__", NULL, C_FUNSPEC }, +/* 6 */ { "__thread", NULL, 0 }, +/* 7 */ { "__FUNCTION__", NULL, 0 }, +/* 8 */ { "__volatile", NULL, 0 }, +/* 9 */ { "__volatile__", NULL, 0 }, +/* 10 */{ "__restrict", NULL, -1 }, +/* 11 */{ "__typeof__", NULL, C_TYPEOF }, +/* 12 */{ "typeof", NULL, C_TYPEOF }, +/* 13 */{ "__extension__", NULL, -1 }, +/* 14 */{ "__signed__", NULL, 0 }, +/* 15 */{ "__attribute__", NULL, 0 }, { NULL, NULL, 0 }, }; @@ -58,12 +89,16 @@ } +#define TS "\n#pragma tls\n# %d\n" +#define TLLEN sizeof(TS)+10 /* * See if a string matches a gcc keyword. */ int gcc_keyword(char *str, NODE **n) { + extern int inattr, parlvl, parbal; + char tlbuf[TLLEN], *tw; struct kw *kwp; int i; @@ -75,52 +110,174 @@ if (kwp->rv) return kwp->rv; switch (i) { - case 1: /* __signed */ + case 1: /* __signed */ + case 14: /* __signed__ */ *n = mkty((TWORD)SIGNED, 0, MKSUE(SIGNED)); return C_TYPE; case 3: /* __const */ *n = block(QUALIFIER, NIL, NIL, CON, 0, 0); return C_QUALIFIER; + case 6: /* __thread */ + snprintf(tlbuf, TLLEN, TS, lineno); + tw = &tlbuf[strlen(tlbuf)]; + while (tw > tlbuf) + cunput(*--tw); + return -1; + case 7: /* __FUNCTION__ */ + if (cftnsp == NULL) { + uerror("__FUNCTION__ outside function"); + yylval.strp = ""; + } else + yylval.strp = cftnsp->sname; /* XXX - not C99 */ + return C_STRING; + case 8: /* __volatile */ + case 9: /* __volatile__ */ + *n = block(QUALIFIER, NIL, NIL, VOL, 0, 0); + return C_QUALIFIER; + case 15: /* __attribute__ */ + inattr = 1; + parlvl = parbal; + return C_ATTRIBUTE; } cerror("gcc_keyword"); return 0; } -static struct ren { - struct ren *next; - char *old, *new; -} *renp; +#ifndef TARGET_TYPE_ATTR +#define TARGET_TYPE_ATTR(p, sue) 1 +#endif +#ifndef TARGET_VAR_ATTR +#define TARGET_VAR_ATTR(p, sue) 1 +#endif +#ifndef ALMAX +#define ALMAX (ALLDOUBLE > ALLONGLONG ? ALLDOUBLE : ALLONGLONG) +#endif + /* - * Save a name for later renaming of a variable. + * Get type attributes from an argument list. */ -void -gcc_rename(struct symtab *sp, char *newname) +static void +gcc_ta(NODE *p, void *arg) { - struct ren *ren = permalloc(sizeof(struct ren)); + struct suedef *sue = arg; + char *n2, *name = NULL; - sp->sflags |= SRENAME; - ren->old = sp->sname; - ren->new = newstring(newname, strlen(newname)+1); - ren->next = renp; - renp = ren; + if (p->n_op == NAME) { + name = (char *)p->n_sp; + } else if (p->n_op == CALL || p->n_op == UCALL) { + name = (char *)p->n_left->n_sp; + } else + cerror("bad type attribute"); + + n2 = name; + name = decap(name); + if (strcmp(name, "aligned") == 0) { + /* Align the type to a given max alignment */ + if (p->n_op == CALL) { + sue->suealigned = icons(eve(p->n_right)) * SZCHAR; + p->n_op = UCALL; + } else + sue->suealigned = ALMAX; + } else if (strcmp(name, "packed") == 0) { + /* pack members of a struct */ + if (p->n_op != NAME) + uerror("packed takes no args"); + sue->suepacked = SZCHAR; /* specify pack size? */ + } else if (TARGET_TYPE_ATTR(p, sue) == 0) + werror("unsupported attribute %s", n2); } /* - * Get a renamed variable. + * Get variable attributes from an argument list. */ -char * -gcc_findname(struct symtab *sp) +static void +gcc_va(NODE *p, void *arg) { - struct ren *w; + struct suedef *sue = arg; + char *n2, *name = NULL; - if ((sp->sflags & SRENAME) == 0) - return exname(sp->sname); + if (p->n_op == NAME) { + name = (char *)p->n_sp; + } else if (p->n_op == CALL || p->n_op == UCALL) { + name = (char *)p->n_left->n_sp; + } else + cerror("bad variable attribute"); + + n2 = name; + name = decap(name); + if (strcmp(name, "aligned") == 0) { + /* Align the variable to a given max alignment */ + if (p->n_op == CALL) { + sue->suealigned = icons(eve(p->n_right)) * SZCHAR; + p->n_op = UCALL; + } else + sue->suealigned = ALMAX; + } else if (strcmp(name, "section") == 0) { + if (p->n_right->n_op != STRING) + uerror("bad section"); + sue->suesection = p->n_right->n_name; +#ifdef notyet + } else if (strcmp(name, "packed") == 0) { + /* pack members of a struct */ + if (p->n_op != NAME) + uerror("packed takes no args"); + sue->suepacked = SZCHAR; /* specify pack size? */ +#endif + } else if (TARGET_VAR_ATTR(p, sue) == 0) + werror("unsupported attribute %s", n2); +} - for (w = renp; w; w = w->next) { - if (w->old == sp->sname) - return exname(w->new); - } - cerror("gcc_findname %s", sp->sname); - return NULL; +/* + * Extract type attributes from a node tree and setup a suedef + * struct based on its contents. + */ +struct suedef * +gcc_type_attrib(NODE *p) +{ + struct suedef *sue = tmpcalloc(sizeof(struct suedef)); + + flist(p, gcc_ta, sue); + tfree(p); + return sue; +} + +struct suedef * +gcc_var_attrib(NODE *p) +{ + struct suedef *sue = permalloc(sizeof(struct suedef)); /* XXX ??? */ + + memset(sue, 0, sizeof(struct suedef)); + flist(p, gcc_va, sue); + tfree(p); + return sue; +} + + +#ifdef notyet +struct gcc_attrib { + int atype; + union { + int iarg; char *sarg; + } a1; + union { + int iarg; char *sarg; + } a2; + union { + int iarg; char *sarg; + } a3; +}; + +typedef struct gcc_attrib g_attr_t; + +/* + * Parse an attribute tree and create a attribute struct. + * If failed, return NULL> + */ +g_attr_t * +gcc_attrib_parse(NODE *p) +{ } + +#endif + #endif Index: pass1.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/pass1.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/pass1.h -L usr.bin/pcc/ccom/pass1.h -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/pass1.h +++ usr.bin/pcc/ccom/pass1.h @@ -1,4 +1,4 @@ -/* $Id: pass1.h,v 1.125 2007/09/09 10:01:01 ragge Exp $ */ +/* $Id: pass1.h,v 1.166 2008/12/14 21:15:24 ragge Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -33,9 +33,20 @@ * POSSIBILITY OF SUCH DAMAGE. */ +#include "config.h" + #include #include +#include +#ifdef HAVE_STDINT_H +#include +#endif +#ifndef MKEXT +#include "external.h" +#else +typedef unsigned int bittype; /* XXX - for basicblock */ +#endif #include "manifest.h" #include "protos.h" @@ -63,7 +74,6 @@ #define MOE 16 #define UFORTRAN 17 #define USTATIC 18 -#define ILABEL 19 /* field size is ORed in */ #define FIELD 0100 @@ -81,21 +91,17 @@ #define NSTYPES 05 #define SMASK 07 -#define SSET 00010 -#define SREF 00020 -#define SNOCREAT 00040 -#define STEMP 00100 -#define SDYNARRAY 00200 -#define SINLINE 00400 -#define STNODE 01000 -#ifdef GCC_COMPAT -#define SRENAME 02000 /* Node is renamed */ -#endif -#define SASG 04000 - -#ifndef FIXDEF -#define FIXDEF(p) -#endif +/* #define SSET 00010 */ +/* #define SREF 00020 */ +#define SNOCREAT 00040 /* don't create a symbol in lookup() */ +#define STEMP 00100 /* Allocate symtab from temp or perm mem */ +#define SDYNARRAY 00200 /* symbol is dynamic array on stack */ +#define SINLINE 00400 /* function is of type inline */ +#define STNODE 01000 /* symbol shall be a temporary node */ +#define SASG 04000 /* symbol is assigned to already */ +#define SLOCAL1 010000 +#define SLOCAL2 020000 +#define SLOCAL3 040000 /* alignment of initialized quantities */ #ifndef AL_INIT @@ -122,8 +128,11 @@ */ struct suedef { int suesize; /* Size of the struct */ - struct symtab **suelem;/* points to the list of elements */ + struct symtab *sylnk; /* the list of elements */ int suealign; /* Alignment of this struct */ + int suealigned; /* Larger alignment requested */ + int suepacked; /* Smaller alignment requested */ + char * suesection; /* Section requested for this var/fun */ }; /* @@ -134,38 +143,26 @@ union dimfun *df; struct suedef *sue; }; -#define TNULL INCREF(MOETY) /* pointer to MOETY -- impossible type */ -#define TELLIPSIS INCREF(INCREF(MOETY)) +#define TNULL INCREF(FARG) /* pointer to FARG -- impossible type */ +#define TELLIPSIS INCREF(INCREF(FARG)) /* * Symbol table definition. - * - * The symtab_hdr struct is used to save label info in NAME and ICON nodes. */ -struct symtab_hdr { - struct symtab *h_next; /* link to other symbols in the same scope */ - int h_offset; /* offset or value */ - char h_sclass; /* storage class */ - char h_slevel; /* scope level */ - short h_sflags; /* flags, see below */ -}; - struct symtab { - struct symtab_hdr hdr; - char *sname; + struct symtab *snext; /* link to other symbols in the same scope */ + int soffset; /* offset or value */ + char sclass; /* storage class */ + char slevel; /* scope level */ + short sflags; /* flags, see below */ + char *sname; /* Symbol name */ + char *soname; /* Written-out name */ TWORD stype; /* type word */ TWORD squal; /* qualifier word */ union dimfun *sdf; /* ptr to the dimension/prototype array */ struct suedef *ssue; /* ptr to the definition table */ - int suse; /* line number of last use of the variable */ }; -#define snext hdr.h_next -#define soffset hdr.h_offset -#define sclass hdr.h_sclass -#define slevel hdr.h_slevel -#define sflags hdr.h_sflags - #define MKSUE(type) &btdims[type] extern struct suedef btdims[]; @@ -177,7 +174,7 @@ CONSZ sval; /* case value */ int slab; /* associated label */ }; -void genswitch(int, struct swents **, int); +int mygenswitch(int, TWORD, struct swents **, int); extern int blevel; extern int instruct, got_type; @@ -189,16 +186,12 @@ extern struct symtab *cftnsp; extern int autooff, maxautooff, argoff, strucoff; extern int brkflag; -extern int lastloc; extern OFFSZ inoff; extern int reached; extern int isinlining; - -/* tunnel to buildtree for name id's */ - -extern struct symtab *spname; +extern int xinline; extern int sdebug, idebug, pdebug; @@ -208,11 +201,9 @@ extern int flostat; extern int retlab; -/* - * Flags used in structures/unions - */ -#define INSTRUCT 02 -#define INUNION 04 +/* pragma globals */ +extern int pragma_allpacked, pragma_packed, pragma_aligned; +extern char *pragma_renamed; /* * Flags used in the (elementary) flow analysis ... @@ -228,16 +219,16 @@ /* declarations of various functions */ extern NODE - *buildtree(int, NODE *l, NODE *r), + *buildtree(int, NODE *, NODE *r), *mkty(unsigned, union dimfun *, struct suedef *), *rstruct(char *, int), - *dclstruct(struct rstack *), - *strend(char *), - *wstrend(char *), - *tymerge(NODE *typ, NODE *idp), + *dclstruct(struct rstack *, struct suedef *), + *strend(int gtype, char *), + *tymerge(NODE *, NODE *), *stref(NODE *), *offcon(OFFSZ, TWORD, union dimfun *, struct suedef *), *bcon(int), + *xbcon(CONSZ, struct symtab *, TWORD), *bpsize(NODE *), *convert(NODE *, int), *pconvert(NODE *), @@ -245,99 +236,150 @@ *ptmatch(NODE *), *tymatch(NODE *), *makety(NODE *, TWORD, TWORD, union dimfun *, struct suedef *), - *block(int, NODE *, NODE *r, TWORD, union dimfun *, struct suedef *), + *block(int, NODE *, NODE *, TWORD, union dimfun *, struct suedef *), *doszof(NODE *), *talloc(void), *optim(NODE *), *clocal(NODE *), *ccopy(NODE *), - *btsize(TWORD, union dimfun *, struct suedef *), - *tempnode(int, TWORD type, union dimfun *df, struct suedef *sue), - *doacall(NODE *f, NODE *a); + *tempnode(int, TWORD, union dimfun *, struct suedef *), + *eve(NODE *), + *doacall(struct symtab *, NODE *, NODE *); +NODE *intprom(NODE *); OFFSZ tsize(TWORD, union dimfun *, struct suedef *), psize(NODE *); NODE * typenode(NODE *new); void spalloc(NODE *, NODE *, OFFSZ); char *exname(char *); +NODE *floatcon(char *); +NODE *fhexcon(char *); +extern struct rstack *rpole; -int oalloc(struct symtab *p, int *poff); +int oalloc(struct symtab *, int *); void deflabel(char *); -void deflab1(int); -void setloc1(int); void gotolabel(char *); -unsigned int esccon(char **sptr); -void inline_start(char *name); +unsigned int esccon(char **); +void inline_start(struct symtab *); void inline_end(void); void inline_addarg(struct interpass *); -void inline_ref(char *); +void inline_ref(struct symtab *); void inline_prtout(void); +void inline_args(struct symtab **, int); +NODE *inlinetree(struct symtab *, NODE *, NODE *); void ftnarg(NODE *); -struct rstack *bstruct(char *, int); +struct rstack *bstruct(char *, int, struct suedef *); void moedef(char *); void beginit(struct symtab *); void simpleinit(struct symtab *, NODE *); -struct symtab *lookup(char *name, int s); -struct symtab *getsymtab(char *name, int flags); +struct symtab *lookup(char *, int); +struct symtab *getsymtab(char *, int); char *addstring(char *); char *addname(char *); -char *newstring(char *, int len); -void symclear(int level); -void schedremove(struct symtab *p); -struct symtab *hide(struct symtab *p); +void symclear(int); +struct symtab *hide(struct symtab *); +void soumemb(NODE *, char *, int); int talign(unsigned int, struct suedef *); void bfcode(struct symtab **, int); int chkftn(union arglist *, union arglist *); void branch(int); -void cbranch(NODE *p, NODE *q); +void cbranch(NODE *, NODE *); void extdec(struct symtab *); -void commdec(struct symtab *); -void lcommdec(struct symtab *); -int falloc(struct symtab *p, int w, int new, NODE *pty); +void defzero(struct symtab *); +int falloc(struct symtab *, int, int, NODE *); TWORD ctype(TWORD); -void ninval(CONSZ off, int fsz, NODE *); -void infld(CONSZ off, int fsz, CONSZ); -void zbits(CONSZ off, int fsz); -void indata(CONSZ, int); -void instring(char *); -void defnam(struct symtab *); -void plabel(int lab); +void ninval(CONSZ, int, NODE *); +void infld(CONSZ, int, CONSZ); +void zbits(CONSZ, int); +void instring(struct symtab *); +void inwstring(struct symtab *); +void plabel(int); void bjobcode(void); void ejobcode(int); void calldec(NODE *, NODE *); int cisreg(TWORD); -char *tmpsprintf(char *fmt, ...); -char *tmpvsprintf(char *fmt, va_list ap); +char *tmpsprintf(char *, ...); +char *tmpvsprintf(char *, va_list); void asginit(NODE *); void desinit(NODE *); void endinit(void); +void sspinit(void); +void sspstart(void); +void sspend(void); void ilbrace(void); void irbrace(void); -void scalinit(NODE *p); -int ftoint(NODE *, CONSZ **); -void p1print(char *fmt, ...); +void scalinit(NODE *); +void p1print(char *, ...); char *copst(int); int cdope(int); void myp2tree(NODE *); void lcommprint(void); void lcommdel(struct symtab *); +NODE *funcode(NODE *); +struct symtab *enumhd(char *); +NODE *enumdcl(struct symtab *); +NODE *enumref(char *); +CONSZ icons(NODE *); +int mypragma(char **); +void fixdef(struct symtab *); +int cqual(TWORD, TWORD); +void defloc(struct symtab *); +int fldchk(int); +int nncon(NODE *); +void cunput(char); +NODE *nametree(struct symtab *sp); +void *inlalloc(int size); +void pass1_lastchance(struct interpass *); +void fldty(struct symtab *p); +int getlab(void); + +#ifdef SOFTFLOAT +typedef struct softfloat SF; +SF soft_neg(SF); +SF soft_cast(CONSZ v, TWORD); +SF soft_plus(SF, SF); +SF soft_minus(SF, SF); +SF soft_mul(SF, SF); +SF soft_div(SF, SF); +int soft_isz(SF); +CONSZ soft_val(SF); +#define FLOAT_NEG(sf) soft_neg(sf) +#define FLOAT_CAST(v,t) soft_cast(v, t) +#define FLOAT_PLUS(x1,x2) soft_plus(x1, x2) +#define FLOAT_MINUS(x1,x2) soft_minus(x1, x2) +#define FLOAT_MUL(x1,x2) soft_mul(x1, x2) +#define FLOAT_DIV(x1,x2) soft_div(x1, x2) +#define FLOAT_ISZERO(sf) soft_isz(sf) +#define FLOAT_VAL(sf) soft_val(sf) +#else +#define FLOAT_NEG(p) -(p) +#define FLOAT_CAST(p,v) (ISUNSIGNED(v) ? \ + (long double)(U_CONSZ)(p) : (long double)(CONSZ)(p)) +#define FLOAT_PLUS(x1,x2) (x1) + (x2) +#define FLOAT_MINUS(x1,x2) (x1) - (x2) +#define FLOAT_MUL(x1,x2) (x1) * (x2) +#define FLOAT_DIV(x1,x2) (x1) / (x2) +#define FLOAT_ISZERO(p) (p) == 0.0 +#define FLOAT_VAL(p) (CONSZ)(p) +#endif #ifdef GCC_COMPAT void gcc_init(void); int gcc_keyword(char *, NODE **); -void gcc_rename(struct symtab *sp, char *newname); -char *gcc_findname(struct symtab *sp); +struct suedef *gcc_type_attrib(NODE *); +struct suedef *gcc_var_attrib(NODE *); #endif #ifdef STABS void stabs_init(void); void stabs_file(char *); +void stabs_efile(char *); void stabs_line(int); void stabs_rbrac(int); void stabs_lbrac(int); void stabs_func(struct symtab *); void stabs_newsym(struct symtab *); void stabs_chgsym(struct symtab *); -void stabs_struct(struct symtab *p, struct suedef *sue); +void stabs_struct(struct symtab *, struct suedef *); #endif #ifndef CHARCAST @@ -363,7 +405,7 @@ #define OROR (MAXOP+12) #define NOT (MAXOP+13) #define CAST (MAXOP+14) -/* #define STRING (MAXOP+15) */ +#define STRING (MAXOP+15) /* The following must be in the same order as their NOASG counterparts */ #define PLUSEQ (MAXOP+16) @@ -381,12 +423,18 @@ #define INCR (MAXOP+26) #define DECR (MAXOP+27) +#define SZOF (MAXOP+28) + + /* * The following types are only used in pass1. */ #define SIGNED (MAXTYPES+1) #define BOOL (MAXTYPES+2) - +#define FCOMPLEX (MAXTYPES+3) +#define COMPLEX (MAXTYPES+4) +#define LCOMPLEX (MAXTYPES+5) +#define ENUMTY (MAXTYPES+6) #define coptype(o) (cdope(o)&TYFLG) #define clogop(o) (cdope(o)&LOGFLG) Index: main.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/main.c,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/ccom/main.c -L usr.bin/pcc/ccom/main.c -u -r1.2 -r1.3 --- usr.bin/pcc/ccom/main.c +++ usr.bin/pcc/ccom/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.72 2007/09/25 06:43:06 ragge Exp $ */ +/* $Id: main.c,v 1.95 2008/12/17 15:59:24 ragge Exp $ */ /* * Copyright (c) 2002 Anders Magnusson. All rights reserved. @@ -26,7 +26,11 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "config.h" + +#ifdef HAVE_UNISTD_H #include +#endif #include #include #include @@ -34,19 +38,44 @@ #include "pass1.h" #include "pass2.h" -int sflag, nflag, oflag, kflag; -int lflag, odebug, rdebug, radebug, vdebug, s2debug, udebug, x2debug; +int sflag, nflag, oflag, kflag, pflag; +int lflag, odebug, rdebug, s2debug, udebug, x2debug; #if !defined(MULTIPASS) || defined(PASST) int iTflag, oTflag; #endif -int xdebug, mdebug, sdebug, gflag, c2debug, pdebug; +int xdebug, sdebug, gflag, c2debug, pdebug; int Wstrict_prototypes, Wmissing_prototypes, Wimplicit_int, - Wimplicit_function_declaration; -int xssaflag, xtailcallflag, xtemps, xdeljumps; + Wimplicit_function_declaration, Wpointer_sign, Wshadow, + Wsign_compare, Wunknown_pragmas, Wunreachable_code; +#ifdef CHAR_UNSIGNED +int funsigned_char = 1; +#else +int funsigned_char = 0; +#endif +int sspflag; +int xssaflag, xtailcallflag, xtemps, xdeljumps, xdce, xinline; int e2debug, t2debug, f2debug, b2debug; -struct suedef btdims[24]; +struct suedef btdims[32] = { + [BOOL] = { .suesize = SZBOOL, .suealign = ALBOOL }, + [CHAR] = { .suesize = SZCHAR, .suealign = ALCHAR }, + [INT] = { .suesize = SZINT, .suealign = ALINT }, + [FLOAT] = { .suesize = SZFLOAT, .suealign = ALFLOAT }, + [DOUBLE] = { .suesize = SZDOUBLE, .suealign = ALDOUBLE }, + [LDOUBLE] = { .suesize = SZLDOUBLE, .suealign = ALLDOUBLE }, + [LONG] = { .suesize = SZLONG, .suealign = ALLONG }, + [LONGLONG] = { .suesize = SZLONGLONG, .suealign = ALLONGLONG }, + [SHORT] = { .suesize = SZSHORT, .suealign = ALSHORT }, + [UCHAR] = { .suesize = SZCHAR, .suealign = ALCHAR }, + [USHORT] = { .suesize = SZSHORT, .suealign = ALSHORT }, + [UNSIGNED] = { .suesize = SZINT, .suealign = ALINT }, + [ULONG] = { .suesize = SZLONG, .suealign = ALLONG }, + [ULONGLONG] = { .suesize = SZLONGLONG, .suealign = ALLONGLONG }, + [FCOMPLEX] = { .suesize = SZFLOAT * 2, .suealign = ALFLOAT }, + [COMPLEX] = { .suesize = SZDOUBLE * 2, .suealign = ALDOUBLE }, + [LCOMPLEX] = { .suesize = SZLDOUBLE * 2, .suealign = ALLDOUBLE }, +}; char *prgname; static void prtstats(void); @@ -58,6 +87,11 @@ { "missing-prototypes", &Wmissing_prototypes, }, { "implicit-int", &Wimplicit_int, }, { "implicit-function-declaration", &Wimplicit_function_declaration, }, + { "shadow", &Wshadow, }, + { "pointer-sign", &Wpointer_sign, }, + { "sign-compare", &Wsign_compare, }, + { "unknown-pragmas", &Wunknown_pragmas, }, + { "unreachable-code", &Wunreachable_code, }, { NULL, NULL, }, }; @@ -72,10 +106,12 @@ static void segvcatch(int a) { - fprintf(stderr, "%sinternal compiler error: %s, line %d\n", + char buf[1024]; + + snprintf(buf, sizeof buf, "%sinternal compiler error: %s, line %d\n", nerrors ? "" : "major ", ftitle, lineno); - fflush(stderr); - exit(1); + write(STDERR_FILENO, buf, strlen(buf)); + _exit(1); } /* @@ -84,22 +120,60 @@ static void Wflags(char *str) { - int i, found = 0, all; + int i, flagval = 1, found = 0, all; + + if (strncmp("no-", str, 3) == 0) { + str += 3; + flagval = 0; + } if (strcmp(str, "implicit") == 0) { - Wimplicit_int = Wimplicit_function_declaration = 1; + Wimplicit_int = Wimplicit_function_declaration = flagval; + return; + } + if (strcmp(str, "error") == 0) { + warniserr = flagval; return; } + all = strcmp(str, "W") == 0; - for (i = 0; flagstr[i].n; i++) + for (i = 0; flagstr[i].n; i++) { if (all || strcmp(flagstr[i].n, str) == 0) { - *flagstr[i].f = 1; + *flagstr[i].f = flagval; found++; } - if (found == 0) + } + if (found == 0) { + fprintf(stderr, "unrecognised option '%s'\n", str); usage(); + } } +static void +fflags(char *str) +{ + int flagval = 1; + + if (strncmp("no-", str, 3) == 0) { + str += 3; + flagval = 0; + } + + if (strcmp(str, "signed-char") == 0) + funsigned_char = !flagval; + else if (strcmp(str, "unsigned-char") == 0) + funsigned_char = flagval; + else if (strcmp(str, "stack-protector") == 0) + sspflag = flagval; + else if (strcmp(str, "stack-protector-all") == 0) + sspflag = flagval; + else if (strncmp(str, "pack-struct", 11) == 0) + pragma_allpacked = (strlen(str) > 12 ? atoi(str+12) : 1); + else { + fprintf(stderr, "unrecognised option '%s'\n", str); + usage(); + } +} /* control multiple files */ int @@ -108,9 +182,15 @@ int ch; +#ifdef TIMING + struct timeval t1, t2; + + (void)gettimeofday(&t1, NULL); +#endif + prgname = argv[0]; - while ((ch = getopt(argc, argv, "VlwX:Z:W:sOT:gx:kv")) != -1) + while ((ch = getopt(argc, argv, "OT:VW:X:Z:f:gklm:psvwx:")) != -1) switch (ch) { #if !defined(MULTIPASS) || defined(PASS1) case 'X': @@ -118,13 +198,13 @@ switch (*optarg++) { case 'd': ++ddebug; break; /* declarations */ case 'i': ++idebug; break; /* initializations */ - case 'b': ++bdebug; break; - case 't': ++tdebug; break; + case 'b': ++bdebug; break; /* buildtree */ + case 't': ++tdebug; break; /* type match */ case 'e': ++edebug; break; /* pass1 exit */ case 'x': ++xdebug; break; /* MD code */ - case 's': ++sdebug; break; - case 'n': ++nflag; break; - case 'o': ++oflag; break; + case 's': ++sdebug; break; /* inline */ + case 'n': ++nflag; break; /* node alloc */ + case 'o': ++oflag; break; /* optim */ case 'p': ++pdebug; break; /* prototype */ default: fprintf(stderr, "unknown X flag '%c'\n", @@ -161,15 +241,12 @@ case 'r': /* register alloc/graph coloring */ ++rdebug; break; - case 'a': ++radebug; break; case 'b': /* basic block and SSA building */ ++b2debug; break; case 'c': /* code printout */ ++c2debug; break; - case 'm': ++mdebug; break; - case 'v': ++vdebug; break; case 't': ++t2debug; break; case 's': /* shape matching */ ++s2debug; @@ -187,16 +264,28 @@ #endif break; + case 'f': /* Language */ + fflags(optarg); + break; + + case 'g': /* Debugging */ + gflag = 1; + break; + case 'k': /* PIC code */ ++kflag; break; - case 'l': /* linenos */ + case 'l': /* Linenos */ ++lflag; break; - case 'g': /* Debugging */ - gflag = 1; + case 'm': /* Target-specific */ + mflags(optarg); + break; + + case 'p': /* Profiling */ + pflag = 1; break; case 's': /* Statistics */ @@ -216,6 +305,10 @@ xtemps++; else if (strcmp(optarg, "deljumps") == 0) xdeljumps++; + else if (strcmp(optarg, "dce") == 0) + xdce++; + else if (strcmp(optarg, "inline") == 0) + xinline++; else usage(); break; @@ -230,20 +323,21 @@ argc -= optind; argv += optind; - if (argc != 0) { + if (argc > 0 && strcmp(argv[0], "-") != 0) { if (freopen(argv[0], "r", stdin) == NULL) { fprintf(stderr, "open input file '%s':", argv[0]); perror(NULL); exit(1); } - if (argc != 1) - if (freopen(argv[1], "w", stdout) == NULL) { - fprintf(stderr, "open output file '%s':", - argv[1]); - perror(NULL); - exit(1); - } + } + if (argc > 1 && strcmp(argv[1], "-") != 0) { + if (freopen(argv[1], "w", stdout) == NULL) { + fprintf(stderr, "open output file '%s':", + argv[1]); + perror(NULL); + exit(1); + } } mkdope(); @@ -254,27 +348,18 @@ gcc_init(); #endif - /* dimension table initialization */ - - btdims[VOID].suesize = 0; - btdims[BOOL].suesize = SZBOOL; - btdims[CHAR].suesize = SZCHAR; - btdims[INT].suesize = SZINT; - btdims[FLOAT].suesize = SZFLOAT; - btdims[DOUBLE].suesize = SZDOUBLE; - btdims[LDOUBLE].suesize = SZLDOUBLE; - btdims[LONG].suesize = SZLONG; - btdims[LONGLONG].suesize = SZLONGLONG; - btdims[SHORT].suesize = SZSHORT; - btdims[UCHAR].suesize = SZCHAR; - btdims[USHORT].suesize = SZSHORT; - btdims[UNSIGNED].suesize = SZINT; - btdims[ULONG].suesize = SZLONG; - btdims[ULONGLONG].suesize = SZLONGLONG; - /* starts past any of the above */ reached = 1; bjobcode(); +#ifndef TARGET_STDARGS + { + NODE *p = block(NAME, NIL, NIL, PTR|CHAR, NULL, MKSUE(CHAR)); + struct symtab *sp = lookup(addname("__builtin_va_list"), 0); + p->n_sp = sp; + defid(p, TYPEDEF); + nfree(p); + } +#endif #ifdef STABS if (gflag) { @@ -283,13 +368,34 @@ } #endif + if (sspflag) + sspinit(); + (void) yyparse(); yyaccpt(); - ejobcode( nerrors ? 1 : 0 ); if (!nerrors) lcommprint(); +#ifdef STABS + if (gflag) + stabs_efile(argc ? argv[0] : ""); +#endif + + ejobcode( nerrors ? 1 : 0 ); + +#ifdef TIMING + (void)gettimeofday(&t2, NULL); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + if (t2.tv_usec < 0) { + t2.tv_usec += 1000000; + t2.tv_sec -= 1; + } + fprintf(stderr, "pccom total time: %ld s %ld us\n", + t2.tv_sec, t2.tv_usec); +#endif + if (sflag) prtstats(); return(nerrors?1:0); Index: cgram.y =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/cgram.y,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/cgram.y -L usr.bin/pcc/ccom/cgram.y -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/cgram.y +++ usr.bin/pcc/ccom/cgram.y @@ -1,4 +1,4 @@ -/* $Id: cgram.y,v 1.170 2007/09/16 19:25:33 ragge Exp $ */ +/* $Id: cgram.y,v 1.241 2008/12/20 14:15:27 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). @@ -79,7 +79,6 @@ /* * Token used in C lex/yacc communications. */ -%token C_WSTRING /* a wide string constant */ %token C_STRING /* a string constant */ %token C_ICON /* an integer constant */ %token C_FCON /* a floating point constant */ @@ -116,6 +115,9 @@ %token C_QUALIFIER %token C_FUNSPEC %token C_ASM +%token NOMATCH +%token C_TYPEOF /* COMPAT_GCC */ +%token C_ATTRIBUTE /* COMPAT_GCC */ /* * Precedence @@ -142,14 +144,15 @@ # include # include -static int fun_inline; /* Reading an inline function */ +int fun_inline; /* Reading an inline function */ int oldstyle; /* Current function being defined */ -int noretype; static struct symtab *xnf; -#ifdef GCC_COMPAT -char *renname; /* for renaming of variables */ -#endif +extern int enummer, tvaloff; +extern struct rstack *rpole; +static int ctval, widestr; +NODE *cftnod; +#define NORETYP SNOCREAT /* no return type, save in unused field in symtab */ static NODE *bdty(int op, ...); static void fend(void); @@ -159,12 +162,29 @@ static void resetbc(int mask); static void swend(void); static void addcase(NODE *p); +#ifdef GCC_COMPAT +static void gcccase(NODE *p, NODE *); +#endif static void adddef(void); static void savebc(void); -static void swstart(int); -static NODE * structref(NODE *p, int f, char *name); +static void swstart(int, TWORD); +static void genswitch(int, TWORD, struct swents **, int); +static NODE *structref(NODE *p, int f, char *name); static char *mkpstr(char *str); static struct symtab *clbrace(NODE *); +static NODE *cmop(NODE *l, NODE *r); +static NODE *xcmop(NODE *out, NODE *in, NODE *str); +static void mkxasm(char *str, NODE *p); +static NODE *xasmop(char *str, NODE *p); +static int maxstlen(char *str); +static char *stradd(char *old, char *new); +static NODE *biop(int op, NODE *l, NODE *r); +static void flend(void); +static char * simname(char *s); +#ifdef GCC_COMPAT +static NODE *tyof(NODE *); /* COMPAT_GCC */ +static NODE *voidcon(void); /* COMPAT_GCC */ +#endif /* * State for saving current switch state (when nested switches). @@ -184,6 +204,7 @@ NODE *nodep; struct symtab *symp; struct rstack *rp; + struct suedef *suep; char *strp; } @@ -191,60 +212,49 @@ %start ext_def_list %type con_e ifelprefix ifprefix whprefix forprefix doprefix switchpart - type_qualifier_list -%type e .e term enum_dcl struct_dcl cast_type funct_idn declarator + type_qualifier_list xbegin +%type e .e term enum_dcl struct_dcl cast_type declarator direct_declarator elist type_specifier merge_attribs parameter_declaration abstract_declarator initializer parameter_type_list parameter_list addrlbl declaration_specifiers pointer direct_abstract_declarator specifier_qualifier_list merge_specifiers nocon_e - identifier_list arg_param_list arg_declaration arg_dcl_list - designator_list designator -%type string wstring C_STRING C_WSTRING -%type enum_head str_head -%type xnfdeclarator clbrace + identifier_list arg_param_list + designator_list designator xasm oplist oper cnstr funtype + typeof attribute attribute_specifier /* COMPAT_GCC */ + attribute_list attr_spec_list /* COMPAT_GCC */ +%type string C_STRING +%type str_head +%type xnfdeclarator clbrace enum_head %type C_CLASS C_STRUCT C_RELOP C_DIVOP C_SHIFTOP C_ANDAND C_OROR C_STROP C_INCOP C_UNOP C_ASOP C_EQUOP + %type C_TYPE C_QUALIFIER C_ICON C_FCON %type C_NAME C_TYPENAME - +%type attr_var %% ext_def_list: ext_def_list external_def | { ftnend(); } ; -external_def: function_definition { blevel = 0; } +external_def: funtype kr_args compoundstmt { fend(); } | declaration { blevel = 0; symclear(0); } | asmstatement ';' | ';' | error { blevel = 0; } ; -function_definition: - /* Ansi (or K&R header without parameter types) */ - declaration_specifiers declarator { - fundef($1, $2); - } compoundstmt { fend(); } - /* Same as above but without declaring function type */ - | declarator { - noretype = 1; - fundef(mkty(INT, 0, MKSUE(INT)), $1); - } compoundstmt { fend(); noretype = 0; } - /* K&R function without type declaration */ - | declarator { - noretype = 1; - if (oldstyle == 0) - uerror("bad declaration in ansi function"); - fundef(mkty(INT, 0, MKSUE(INT)), $1); - } arg_dcl_list compoundstmt { fend(); noretype = 0; } - /* K&R function with type declaration */ - | declaration_specifiers declarator { - if (oldstyle == 0) - uerror("bad declaration in ansi function"); - fundef($1, $2); - } arg_dcl_list compoundstmt { fend(); } +funtype: /* no type given */ declarator { + fundef(mkty(INT, 0, MKSUE(INT)), $1); + cftnsp->sflags |= NORETYP; + } + | declaration_specifiers declarator { fundef($1,$2); } + ; + +kr_args: /* empty */ + | arg_dcl_list ; /* @@ -264,14 +274,12 @@ | C_QUALIFIER merge_attribs { $1->n_left = $2; $$ = $1; } | function_specifiers { $$ = NIL; } | function_specifiers merge_attribs { $$ = $2; } + /*COMPAT_GCC*/ | typeof { $$ = $1; } + /*COMPAT_GCC*/ | typeof merge_attribs { $1->n_left = $2; $$ = $1; } ; function_specifiers: - C_FUNSPEC { - if (fun_inline) - uerror("too many inline"); - fun_inline = 1; - } + C_FUNSPEC { fun_inline = 1; } ; type_specifier: C_TYPE { $$ = $1; } @@ -282,16 +290,40 @@ } | struct_dcl { $$ = $1; } | enum_dcl { $$ = $1; } + | attribute_specifier { tfree($1); $$ = biop(FLD, 0, 0); } + ; + +typeof: C_TYPEOF '(' term ')' { $$ = tyof($3); } /* COMPAT_GCC */ + /*COMPAT_GCC*/ | C_TYPEOF '(' cast_type ')' { $$ = tyof($3); } + /*COMPAT_GCC*/ ; + +attribute_specifier : + C_ATTRIBUTE '(' '(' attribute_list ')' ')' { $$ = $4; } + /*COMPAT_GCC*/ ; + +attribute_list: attribute + | attribute ',' attribute_list { $$ = cmop($3, $1); } + ; + +attribute: { $$ = voidcon(); } + | C_NAME { $$ = bdty(NAME, $1); } + | C_NAME '(' elist ')' { + $$ = bdty($3 == NIL ? UCALL : CALL, bdty(NAME, $1), $3); + } ; /* * Adds a pointer list to front of the declarators. * Note the UMUL right node pointer usage. */ -declarator: pointer direct_declarator { - $$ = $1; $1->n_right->n_left = $2; +declarator: pointer direct_declarator attr_var { + $$ = $1; $1->n_right->n_left = $2; $$->n_sue = 0; } - | direct_declarator { $$ = $1; } + | pointer attr_spec_list direct_declarator attr_var { + $$ = $1; $1->n_right->n_left = $3; $$->n_sue = 0; + tfree($2); + } + | direct_declarator attr_var { $$ = $1; $$->n_sue = 0; } ; /* @@ -328,41 +360,58 @@ direct_declarator: C_NAME { $$ = bdty(NAME, $1); } | '(' declarator ')' { $$ = $2; } | direct_declarator '[' nocon_e ']' { - $$ = block(LB, $1, $3, INT, 0, MKSUE(INT)); + $3 = optim($3); + if ((blevel == 0 || rpole != NULL) && !nncon($3)) + uerror("array size not constant"); + /* + * Checks according to 6.7.5.2 clause 1: + * "...the expression shall have an integer type." + * "If the expression is a constant expression, + * it shall have a value greater than zero." + */ + if (!ISINTEGER($3->n_type)) + werror("array size is not an integer"); + else if ($3->n_op == ICON) { + if ($3->n_lval < 0) { + uerror("array size cannot be negative"); + $3->n_lval = 1; + } +#ifdef notyet + if ($3->n_lval == 0 && Wgcc) + werror("gcc extension; zero size"); +#endif + } + $$ = biop(LB, $1, $3); + } + | direct_declarator '[' ']' { + $$ = biop(LB, $1, bcon(NOOFFSET)); } - | direct_declarator '[' ']' { $$ = bdty(LB, $1, 0); } - | direct_declarator '(' notype parameter_type_list ')' { - $$ = bdty(CALL, $1, $4); + | direct_declarator '(' parameter_type_list ')' { + $$ = bdty(CALL, $1, $3); } - | direct_declarator '(' notype identifier_list ')' { - $$ = bdty(CALL, $1, $4); + | direct_declarator '(' identifier_list ')' { + $$ = bdty(CALL, $1, $3); if (blevel != 0) uerror("function declaration in bad context"); oldstyle = 1; } - | direct_declarator '(' ')' { $$ = bdty(UCALL, $1); } - ; - -notype: { /* extern int notype, doproto; notype = 0; doproto=1; printf("notype\n"); */ } + | direct_declarator '(' ')' { + ctval = tvaloff; + $$ = bdty(UCALL, $1); + } ; -identifier_list: C_NAME { $$ = bdty(NAME, $1); $$->n_type = FARG; } - | identifier_list ',' C_NAME { - $$ = bdty(NAME, $3); - $$->n_type = FARG; - $$ = block(CM, $1, $$, 0, 0, 0); - } +identifier_list: C_NAME { $$ = bdty(NAME, $1); } + | identifier_list ',' C_NAME { $$ = cmop($1, bdty(NAME, $3)); } ; /* * Returns as parameter_list, but can add an additional ELLIPSIS node. - * Calls revert() to get the parameter list in the forward order. */ parameter_type_list: parameter_list { $$ = $1; } | parameter_list ',' C_ELLIPSIS { - $$ = block(CM, $1, block(ELLIPSIS, NIL, NIL, 0, 0, 0), - 0, 0, 0); + $$ = cmop($1, biop(ELLIPSIS, NIL, NIL)); } ; @@ -373,7 +422,7 @@ */ parameter_list: parameter_declaration { $$ = $1; } | parameter_list ',' parameter_declaration { - $$ = block(CM, $1, $3, 0, 0, 0); + $$ = cmop($1, $3); } ; @@ -382,15 +431,22 @@ */ parameter_declaration: declaration_specifiers declarator { + if ($1->n_lval != SNULL && $1->n_lval != REGISTER) + uerror("illegal parameter class"); + $2->n_sue = NULL; /* no attributes */ $$ = tymerge($1, $2); nfree($1); + } | declaration_specifiers abstract_declarator { + $2->n_sue = NULL; /* no attributes */ $$ = tymerge($1, $2); nfree($1); } | declaration_specifiers { - $$ = tymerge($1, bdty(NAME, NULL)); + $$ = bdty(NAME, NULL); + $$->n_sue = NULL; /* no attributes */ + $$ = tymerge($1, $$); nfree($1); } ; @@ -398,28 +454,30 @@ abstract_declarator: pointer { $$ = $1; $1->n_right->n_left = bdty(NAME, NULL); } | direct_abstract_declarator { $$ = $1; } - | pointer direct_abstract_declarator { + | pointer direct_abstract_declarator attr_var { $$ = $1; $1->n_right->n_left = $2; } ; direct_abstract_declarator: '(' abstract_declarator ')' { $$ = $2; } - | '[' ']' { $$ = bdty(LB, bdty(NAME, NULL), 0); } + | '[' ']' { $$ = biop(LB, bdty(NAME, NULL), bcon(NOOFFSET)); } | '[' con_e ']' { $$ = bdty(LB, bdty(NAME, NULL), $2); } - | direct_abstract_declarator '[' ']' { $$ = bdty(LB, $1, 0); } + | direct_abstract_declarator '[' ']' { + $$ = biop(LB, $1, bcon(NOOFFSET)); + } | direct_abstract_declarator '[' con_e ']' { $$ = bdty(LB, $1, $3); } | '(' ')' { $$ = bdty(UCALL, bdty(NAME, NULL)); } - | '(' notype parameter_type_list ')' { - $$ = bdty(CALL, bdty(NAME, NULL), $3); + | '(' parameter_type_list ')' { + $$ = bdty(CALL, bdty(NAME, NULL), $2); } | direct_abstract_declarator '(' ')' { $$ = bdty(UCALL, $1); } - | direct_abstract_declarator '(' notype parameter_type_list ')' { - $$ = bdty(CALL, $1, $4); + | direct_abstract_declarator '(' parameter_type_list ')' { + $$ = bdty(CALL, $1, $3); } ; @@ -445,25 +503,24 @@ /* * Declarations in beginning of blocks. */ -declaration_list: declaration - | declaration_list declaration +block_item_list: block_item + | block_item_list block_item + ; + +block_item: declaration + | statement ; /* * Here starts the old YACC code. */ -stmt_list: stmt_list statement - | { bccode(); } - ; - /* * Variables are declared in init_declarator. */ -declaration: declaration_specifiers ';' { nfree($1); goto inl; } +declaration: declaration_specifiers ';' { nfree($1); fun_inline = 0; } | declaration_specifiers init_declarator_list ';' { nfree($1); - inl: fun_inline = 0; } ; @@ -474,41 +531,51 @@ */ init_declarator_list: init_declarator - | init_declarator_list ',' { $$ = $0; } init_declarator + | init_declarator_list ',' attr_var { $$ = $0; } init_declarator attr_var ; -enum_dcl: enum_head '{' moe_list optcomma '}' { $$ = dclstruct($1); } - | C_ENUM C_NAME { $$ = rstruct($2,0); } - | C_ENUM C_TYPENAME { $$ = rstruct($2,0); } +enum_dcl: enum_head '{' moe_list optcomma '}' { $$ = enumdcl($1); } + | C_ENUM C_NAME { $$ = enumref($2); } ; -enum_head: C_ENUM { $$ = bstruct(NULL,0); } - | C_ENUM C_NAME { $$ = bstruct($2,0); } - | C_ENUM C_TYPENAME { $$ = bstruct($2,0); } +enum_head: C_ENUM { $$ = enumhd(NULL); } + | C_ENUM C_NAME { $$ = enumhd($2); } ; moe_list: moe | moe_list ',' moe ; -moe: C_NAME { moedef( $1 ); } - | C_NAME '=' con_e { strucoff = $3; moedef( $1 ); } +moe: C_NAME { moedef($1); } + | C_TYPENAME { moedef($1); } + | C_NAME '=' con_e { enummer = $3; moedef($1); } + | C_TYPENAME '=' con_e { enummer = $3; moedef($1); } ; -struct_dcl: str_head '{' struct_dcl_list '}' { $$ = dclstruct($1); } - | C_STRUCT C_NAME { $$ = rstruct($2,$1); } - | C_STRUCT C_TYPENAME { $$ = rstruct($2,$1); } - | str_head '{' '}' { -#ifndef GCC_COMPAT - werror("gcc extension"); -#endif - $$ = dclstruct($1); +struct_dcl: str_head '{' struct_dcl_list '}' { + $$ = dclstruct($1, NULL); } + | C_STRUCT attr_var C_NAME { $$ = rstruct($3,$1); } + /*COMPAT_GCC*/ | str_head '{' '}' { $$ = dclstruct($1, NULL); } ; -str_head: C_STRUCT { $$ = bstruct(NULL, $1); } - | C_STRUCT C_NAME { $$ = bstruct($2,$1); } - | C_STRUCT C_TYPENAME { $$ = bstruct($2,$1); } +attr_var: { + if (pragma_aligned || pragma_packed) { + $$ = tmpcalloc(sizeof(struct suedef)); + $$->suealigned = pragma_aligned; + $$->suepacked = pragma_packed; + } else + $$ = NULL; + } + /*COMPAT_GCC*/ | attr_spec_list { $$ = gcc_type_attrib($1); } + ; + +attr_spec_list: attribute_specifier + | attr_spec_list attribute_specifier { tfree($2); /* XXX */ } + ; + +str_head: C_STRUCT attr_var { $$ = bstruct(NULL, $1, $2); } + | C_STRUCT attr_var C_NAME { $$ = bstruct($3,$1, $2); } ; struct_dcl_list: struct_declaration @@ -539,30 +606,33 @@ struct_declarator: declarator { tymerge($0, $1); - $1->n_sp = getsymtab((char *)$1->n_sp, SMOSNAME); /* XXX */ - defid($1, $0->n_lval); + soumemb($1, (char *)$1->n_sp, 0); nfree($1); } | ':' con_e { - if (!(instruct&INSTRUCT)) - uerror( "field outside of structure" ); + if (fldchk($2)) + $2 = 1; falloc(NULL, $2, -1, $0); } | declarator ':' con_e { - if (!(instruct&INSTRUCT)) - uerror( "field outside of structure" ); - if( $3<0 || $3 >= FIELD ){ - uerror( "illegal field size" ); + if (fldchk($3)) $3 = 1; - } if ($1->n_op == NAME) { tymerge($0, $1); - $1->n_sp = getsymtab((char *)$1->n_sp,SMOSNAME); - defid($1, FIELD|$3); + soumemb($1, (char *)$1->n_sp, FIELD | $3); nfree($1); } else uerror("illegal declarator"); } + | /* unnamed member */ { + NODE *p = $0; + char *c = permalloc(10); + + if (p->n_type != STRTY && p->n_type != UNIONTY) + uerror("bad unnamed member type"); + snprintf(c, 10, "*%dFAKE", getlab()); + soumemb(p, c, 0); + } ; /* always preceeded by attributes */ @@ -576,27 +646,29 @@ init_declarator: declarator { init_declarator($0, $1, 0); } | declarator C_ASM '(' string ')' { #ifdef GCC_COMPAT - renname = $4; + pragma_renamed = newstring($4, strlen($4)); init_declarator($0, $1, 0); #else werror("gcc extension"); init_declarator($0, $1, 0); #endif } - | xnfdeclarator '=' e { simpleinit($1, $3); xnf = NULL; } + | xnfdeclarator '=' e { simpleinit($1, eve($3)); xnf = NULL; } | xnfdeclarator '=' begbr init_list optcomma '}' { endinit(); xnf = NULL; } + /*COMPAT_GCC*/ | xnfdeclarator '=' begbr '}' { endinit(); xnf = NULL; } | xnfdeclarator '=' addrlbl { simpleinit($1, $3); xnf = NULL; } ; begbr: '{' { beginit($-1); } ; -initializer: e %prec ',' { $$ = $1; } +initializer: e %prec ',' { $$ = eve($1); } | addrlbl { $$ = $1; } | ibrace init_list optcomma '}' { $$ = NULL; } + | ibrace '}' { asginit(bcon(0)); $$ = NULL; } ; init_list: designation initializer { asginit($2); } @@ -611,8 +683,18 @@ | designator_list designator { $$ = $2; $$->n_left = $1; } ; -designator: '[' con_e ']' { $$ = bdty(LB, NULL, $2); } - | C_STROP C_NAME { $$ = bdty(NAME, $2); } +designator: '[' con_e ']' { + if ($2 < 0) { + uerror("designator must be non-negative"); + $2 = 0; + } + $$ = biop(LB, NIL, bcon($2)); + } + | C_STROP C_NAME { + if ($1 != DOT) + uerror("invalid designator"); + $$ = bdty(NAME, $2); + } ; optcomma : /* VOID */ @@ -624,34 +706,8 @@ /* STATEMENTS */ -compoundstmt: begin declaration_list stmt_list '}' { -#ifdef STABS - if (gflag && blevel > 2) - stabs_rbrac(blevel); -#endif - --blevel; - if( blevel == 1 ) - blevel = 0; - symclear(blevel); /* Clean ut the symbol table */ - if (autooff > maxautooff) - maxautooff = autooff; - autooff = savctx->contlab; - savctx = savctx->next; - } - | begin stmt_list '}' { -#ifdef STABS - if (gflag && blevel > 2) - stabs_rbrac(blevel); -#endif - --blevel; - if( blevel == 1 ) - blevel = 0; - symclear(blevel); /* Clean ut the symbol table */ - if (autooff > maxautooff) - maxautooff = autooff; - autooff = savctx->contlab; - savctx = savctx->next; - } +compoundstmt: begin block_item_list '}' { flend(); } + | begin '}' { flend(); } ; begin: '{' { @@ -672,10 +728,13 @@ bc->contlab = autooff; bc->next = savctx; savctx = bc; + bccode(); + if (sspflag && blevel == 2) + sspstart(); } ; -statement: e ';' { ecomp( $1 ); } +statement: e ';' { ecomp(eve($1)); symclear(blevel); } | compoundstmt | ifprefix statement { plabel($1); reached = 1; } | ifelprefix statement { @@ -698,9 +757,9 @@ if (flostat & FCONT) reached = 1; if (reached) - cbranch($5, bcon($1)); + cbranch(eve($5), bcon($1)); else - tfree($5); + tfree(eve($5)); plabel( brklab); reached = 1; resetbc(0); @@ -741,35 +800,37 @@ } | C_RETURN ';' { branch(retlab); - if (cftnsp->stype != VOID && noretype && + if (cftnsp->stype != VOID && + (cftnsp->sflags & NORETYP) == 0 && cftnsp->stype != VOID+FTN) uerror("return value required"); rch: - if (!reached) + if (!reached && Wunreachable_code) werror( "statement is not reached"); reached = 0; } | C_RETURN e ';' { - register NODE *temp; - - spname = cftnsp; - temp = buildtree( NAME, NIL, NIL ); - temp->n_type = DECREF(temp->n_type); - temp = buildtree(RETURN, temp, $2); + NODE *p; - if (temp->n_type == VOID) - ecomp(temp->n_right); - else - ecomp(buildtree(FORCE, temp->n_right, NIL)); - nfree(temp->n_left); - nfree(temp); + p = nametree(cftnsp); + p->n_type = DECREF(p->n_type); + p = buildtree(RETURN, p, eve($2)); + if (p->n_type == VOID) { + ecomp(p->n_right); + } else { + if (cftnod == NIL) + cftnod = tempnode(0, p->n_type, + p->n_df, p->n_sue); + ecomp(buildtree(ASSIGN, + tcopy(cftnod), p->n_right)); + } + tfree(p->n_left); + nfree(p); branch(retlab); reached = 0; } | C_GOTO C_NAME ';' { gotolabel($2); goto rch; } - | C_GOTO '*' e ';' { - ecomp(block(GOTO, $3, NIL, INT, 0, 0)); - } + | C_GOTO '*' e ';' { ecomp(biop(GOTO, eve($3), NIL)); } | asmstatement ';' | ';' | error ';' @@ -777,18 +838,44 @@ | label statement ; -asmstatement: C_ASM '(' string ')' { send_passt(IP_ASM, mkpstr($3)); } +asmstatement: C_ASM mvol '(' string ')' { send_passt(IP_ASM, mkpstr($4)); } + | C_ASM mvol '(' string xasm ')' { mkxasm($4, $5); } + ; + +mvol: /* empty */ + | C_QUALIFIER { nfree($1); } + ; + +xasm: ':' oplist { $$ = xcmop($2, NIL, NIL); } + | ':' oplist ':' oplist { $$ = xcmop($2, $4, NIL); } + | ':' oplist ':' oplist ':' cnstr { $$ = xcmop($2, $4, $6); } + ; + +oplist: /* nothing */ { $$ = NIL; } + | oper { $$ = $1; } ; +oper: string '(' e ')' { $$ = xasmop($1, eve($3)); } + | oper ',' string '(' e ')' { + $$ = cmop($1, xasmop($3, eve($5))); + } + ; + +cnstr: string { $$ = xasmop($1, bcon(0)); } + | cnstr ',' string { $$ = cmop($1, xasmop($3, bcon(0))); } + ; + label: C_NAME ':' { deflabel($1); reached = 1; } - | C_CASE e ':' { addcase($2); reached = 1; } + | C_TYPENAME ':' { deflabel($1); reached = 1; } + | C_CASE e ':' { addcase(eve($2)); reached = 1; } +/* COMPAT_GCC */| C_CASE e C_ELLIPSIS e ':' { + gcccase(eve($2), eve($4)); reached = 1; + } | C_DEFAULT ':' { reached = 1; adddef(); flostat |= FDEF; } ; doprefix: C_DO { savebc(); - if (!reached) - werror("loop not entered at top"); brklab = getlab(); contlab = getlab(); plabel( $$ = getlab()); @@ -796,7 +883,7 @@ } ; ifprefix: C_IF '(' e ')' { - cbranch(buildtree(NOT, $3, NIL), bcon($$ = getlab())); + cbranch(buildtree(NOT, eve($3), NIL), bcon($$ = getlab())); reached = 1; } ; @@ -812,8 +899,7 @@ whprefix: C_WHILE '(' e ')' { savebc(); - if (!reached) - werror("loop not entered at top"); + $3 = eve($3); if ($3->n_op == ICON && $3->n_lval != 0) flostat = FLOOP; plabel( contlab = getlab()); @@ -828,8 +914,18 @@ forprefix: C_FOR '(' .e ';' .e ';' { if ($3) ecomp($3); - else if (!reached) - werror("loop not entered at top"); + savebc(); + contlab = getlab(); + brklab = getlab(); + plabel( $$ = getlab()); + reached = 1; + if ($5) + cbranch(buildtree(NOT, $5, NIL), bcon(brklab)); + else + flostat |= FLOOP; + } + | C_FOR '(' incblev declaration .e ';' { + blevel--; savebc(); contlab = getlab(); brklab = getlab(); @@ -841,182 +937,152 @@ flostat |= FLOOP; } ; -switchpart: C_SWITCH '(' e ')' { + +incblev: { blevel++; } + ; + +switchpart: C_SWITCH '(' e ')' { NODE *p; int num; + TWORD t; savebc(); brklab = getlab(); - if ($3->n_type != INT) { - /* must cast to integer */ - p = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); - p = buildtree(CAST, p, $3); - $3 = p->n_right; - nfree(p->n_left); - nfree(p); + $3 = eve($3); + if (($3->n_type != BOOL && $3->n_type > ULONGLONG) || + $3->n_type < CHAR) { + uerror("switch expression must have integer " + "type"); + t = INT; + } else { + $3 = intprom($3); + t = $3->n_type; } -// ecomp( buildtree( FORCE, $3, NIL ) ); - p = tempnode(0, INT, 0, MKSUE(INT)); - num = p->n_lval; + p = tempnode(0, t, 0, MKSUE(t)); + num = regno(p); ecomp(buildtree(ASSIGN, p, $3)); branch( $$ = getlab()); - swstart(num); + swstart(num, t); reached = 0; } ; /* EXPRESSIONS */ -con_e: { $$=instruct; instruct=0; } e %prec ',' { - $$ = icons( $2 ); - instruct=$1; +con_e: { $$ = rpole; rpole = NULL; } e %prec ',' { + $$ = icons(eve($2)); + rpole = $1; } ; -nocon_e: { $$=instruct; instruct=0; } e %prec ',' { - instruct=$1; - $$ = $2; +nocon_e: { $$ = rpole; rpole = NULL; } e %prec ',' { + rpole = $1; + $$ = eve($2); } ; -.e: e +.e: e { $$ = eve($1); } | { $$=0; } ; -elist: e %prec ',' - | elist ',' e { $$ = buildtree(CM, $1, $3); } +elist: { $$ = NIL; } + | e %prec ',' + | elist ',' e { $$ = biop(CM, $1, $3); } + | elist ',' cast_type { /* hack for stdarg */ + $3->n_op = TYPE; + $$ = biop(CM, $1, $3); + } ; /* * Precedence order of operators. */ -e: e ',' e { $$ = buildtree(COMOP, $1, $3); } - | e '=' e { $$ = buildtree(ASSIGN, $1, $3); } - | e C_ASOP e { $$ = buildtree($2, $1, $3); } +e: e ',' e { $$ = biop(COMOP, $1, $3); } + | e '=' e { $$ = biop(ASSIGN, $1, $3); } + | e C_ASOP e { $$ = biop($2, $1, $3); } | e '?' e ':' e { - $$=buildtree(QUEST, $1, buildtree(COLON, $3, $5)); + $$=biop(QUEST, $1, biop(COLON, $3, $5)); } - | e C_OROR e { $$ = buildtree($2, $1, $3); } - | e C_ANDAND e { $$ = buildtree($2, $1, $3); } - | e '|' e { $$ = buildtree(OR, $1, $3); } - | e '^' e { $$ = buildtree(ER, $1, $3); } - | e '&' e { $$ = buildtree(AND, $1, $3); } - | e C_EQUOP e { $$ = buildtree($2, $1, $3); } - | e C_RELOP e { $$ = buildtree($2, $1, $3); } - | e C_SHIFTOP e { $$ = buildtree($2, $1, $3); } - | e '+' e { $$ = buildtree(PLUS, $1, $3); } - | e '-' e { $$ = buildtree(MINUS, $1, $3); } - | e C_DIVOP e { $$ = buildtree($2, $1, $3); } - | e '*' e { $$ = buildtree(MUL, $1, $3); } - | e '=' addrlbl { $$ = buildtree(ASSIGN, $1, $3); } + | e C_OROR e { $$ = biop($2, $1, $3); } + | e C_ANDAND e { $$ = biop($2, $1, $3); } + | e '|' e { $$ = biop(OR, $1, $3); } + | e '^' e { $$ = biop(ER, $1, $3); } + | e '&' e { $$ = biop(AND, $1, $3); } + | e C_EQUOP e { $$ = biop($2, $1, $3); } + | e C_RELOP e { $$ = biop($2, $1, $3); } + | e C_SHIFTOP e { $$ = biop($2, $1, $3); } + | e '+' e { $$ = biop(PLUS, $1, $3); } + | e '-' e { $$ = biop(MINUS, $1, $3); } + | e C_DIVOP e { $$ = biop($2, $1, $3); } + | e '*' e { $$ = biop(MUL, $1, $3); } + | e '=' addrlbl { $$ = biop(ASSIGN, $1, $3); } | term ; +xbegin: begin { + $$ = getlab(); getlab(); getlab(); + branch($$); plabel(($$)+1); } + ; + addrlbl: C_ANDAND C_NAME { #ifdef GCC_COMPAT struct symtab *s = lookup($2, SLBLNAME); if (s->soffset == 0) s->soffset = -getlab(); - spname = s; - $$ = buildtree(ADDROF, buildtree(NAME, NIL, NIL), NIL); + $$ = buildtree(ADDROF, nametree(s), NIL); #else uerror("gcc extension"); #endif } ; -term: term C_INCOP { $$ = buildtree( $2, $1, bcon(1) ); } - | '*' term { $$ = buildtree(UMUL, $2, NIL); } - | '&' term { - if( ISFTN($2->n_type) || ISARY($2->n_type) ){ -#ifdef notdef - werror( "& before array or function: ignored" ); -#endif - $$ = $2; - } else - $$ = buildtree(ADDROF, $2, NIL); - } - | '-' term { $$ = buildtree(UMINUS, $2, NIL ); } +term: term C_INCOP { $$ = biop($2, $1, bcon(1)); } + | '*' term { $$ = biop(UMUL, $2, NIL); } + | '&' term { $$ = biop(ADDROF, $2, NIL); } + | '-' term { $$ = biop(UMINUS, $2, NIL ); } | '+' term { $$ = $2; } - | C_UNOP term { $$ = buildtree( $1, $2, NIL ); } + | C_UNOP term { $$ = biop($1, $2, NIL); } | C_INCOP term { - $$ = buildtree($1 == INCR ? PLUSEQ : MINUSEQ, - $2, bcon(1)); + $$ = biop($1 == INCR ? PLUSEQ : MINUSEQ, $2, bcon(1)); } - | C_SIZEOF term { $$ = doszof($2); } + | C_SIZEOF term { $$ = biop(SZOF, $2, bcon(0)); } | '(' cast_type ')' term %prec C_INCOP { - $$ = buildtree(CAST, $2, $4); - nfree($$->n_left); - nfree($$); - $$ = $$->n_right; + $$ = biop(CAST, $2, $4); } | C_SIZEOF '(' cast_type ')' %prec C_SIZEOF { - $$ = doszof($3); + $$ = biop(SZOF, $3, bcon(1)); } - | '(' cast_type ')' clbrace init_list '}' { + | '(' cast_type ')' clbrace init_list optcomma '}' { + uerror("compound literals"); endinit(); - spname = $4; - $$ = buildtree(NAME, NIL, NIL); - } - | term '[' e ']' { - $$ = buildtree( UMUL, - buildtree( PLUS, $1, $3 ), NIL ); - } - | funct_idn ')' { $$ = doacall($1, NIL); } - | funct_idn elist ')' { $$ = doacall($1, $2); } - | term C_STROP C_NAME { $$ = structref($1, $2, $3); } - | term C_STROP C_TYPENAME { $$ = structref($1, $2, $3); } - | C_NAME { - spname = lookup($1, 0); - /* recognize identifiers in initializations */ - if (blevel==0 && spname->stype == UNDEF) { - register NODE *q; - werror("undeclared initializer name %s", - spname->sname); - q = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); - q->n_sp = spname; - defid(q, EXTERN); - nfree(q); - } - if (spname->sflags & SINLINE) - inline_ref($1); - $$ = buildtree(NAME, NIL, NIL); - spname->suse = -lineno; - if (spname->sflags & SDYNARRAY) - $$ = buildtree(UMUL, $$, NIL); + $$ = nametree($4); } + | term '[' e ']' { $$ = biop(LB, $1, $3); } + | C_NAME '(' elist ')' { + $$ = biop($3 ? CALL : UCALL, bdty(NAME, $1), $3); + } + | term '(' elist ')' { $$ = biop($3 ? CALL : UCALL, $1, $3); } + | term C_STROP C_NAME { $$ = biop($2, $1, bdty(NAME, $3)); } + | term C_STROP C_TYPENAME { $$ = biop($2, $1, bdty(NAME, $3));} + | C_NAME %prec C_SIZEOF /* below ( */{ $$ = bdty(NAME, $1); } | C_ICON { $$ = $1; } | C_FCON { $$ = $1; } - | string { $$ = strend($1); /* get string contents */ } - | wstring { $$ = wstrend($1); } + | string { $$ = bdty(STRING, $1, widestr); } | '(' e ')' { $$=$2; } + | '(' xbegin block_item_list e ';' '}' ')' { + branch(($2)+2); + plabel($2); + $$ = biop(COMOP, biop(GOTO, bcon(($2)+1), NIL), $4); + $$->n_type = $4->n_type; /* XXX type checking ? */ + $$->n_sue = $4->n_sue; /* XXX type checking ? */ + $$->n_df = $4->n_df; /* XXX type checking ? */ + flend(); + } ; clbrace: '{' { $$ = clbrace($-1); } ; -string: C_STRING { - int len = strlen($1) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - } - | string C_STRING { - int len = strlen($1) + strlen($2) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - strlcat($$, $2, len); - } - ; - -wstring: C_WSTRING { - int len = strlen($1) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - } - | string C_WSTRING { - int len = strlen($1) + strlen($2) + 1; - $$ = tmpalloc(len); - strlcpy($$, $1, len); - strlcat($$, $2, len); - } +string: C_STRING { widestr = $1[0] == 'L'; $$ = stradd("", $1); } + | string C_STRING { $$ = stradd($1, $2); } ; cast_type: specifier_qualifier_list { @@ -1027,25 +1093,9 @@ $$ = tymerge($1, $2); nfree($1); } + /*COMPAT_GCC*/ | typeof { $$ = $1; $$->n_op = NAME; } ; -funct_idn: C_NAME '(' { - struct symtab *s = lookup($1, 0); - if (s->stype == UNDEF) { - register NODE *q; - q = block(NAME, NIL, NIL, FTN|INT, 0, MKSUE(INT)); - q->n_sp = s; - defid(q, EXTERN); - nfree(q); - } - if (s->sflags & SINLINE) - inline_ref($1); - spname = s; - $$ = buildtree(NAME, NIL, NIL); - s->suse = -lineno; - } - | term '(' - ; %% NODE * @@ -1058,10 +1108,11 @@ bdty(int op, ...) { va_list ap; + int val; register NODE *q; va_start(ap, op); - q = block(op, NIL, NIL, INT, 0, MKSUE(INT)); + q = biop(op, NIL, NIL); switch (op) { case UMUL: @@ -1077,13 +1128,22 @@ case LB: q->n_left = va_arg(ap, NODE *); - q->n_right = bcon(va_arg(ap, int)); + if ((val = va_arg(ap, int)) <= 0) { + uerror("array size must be positive"); + val = 1; + } + q->n_right = bcon(val); break; case NAME: q->n_sp = va_arg(ap, struct symtab *); /* XXX survive tymerge */ break; + case STRING: + q->n_name = va_arg(ap, char *); + q->n_lval = va_arg(ap, int); + break; + default: cerror("bad bdty"); } @@ -1093,6 +1153,25 @@ } static void +flend(void) +{ + if (sspflag && blevel == 2) + sspend(); +#ifdef STABS + if (gflag && blevel > 2) + stabs_rbrac(blevel); +#endif + --blevel; + if( blevel == 1 ) + blevel = 0; + symclear(blevel); /* Clean ut the symbol table */ + if (autooff > maxautooff) + maxautooff = autooff; + autooff = savctx->contlab; + savctx = savctx->next; +} + +static void savebc(void) { struct savbc *bc = tmpalloc(sizeof(struct savbc)); @@ -1120,6 +1199,7 @@ struct swents *ents; /* Linked sorted list of case entries */ int nents; /* # of entries in list */ int num; /* Node value will end up in */ + TWORD type; /* Type of switch expression */ } *swpole; /* @@ -1128,7 +1208,8 @@ static void addcase(NODE *p) { - struct swents *w, *sw = tmpalloc(sizeof(struct swents)); + struct swents **put, *w, *sw = tmpalloc(sizeof(struct swents)); + CONSZ val; p = optim(p); /* change enum to ints */ if (p->n_op != ICON || p->n_sp != NULL) { @@ -1140,40 +1221,55 @@ return; } + if (DEUNSIGN(swpole->type) != DEUNSIGN(p->n_type)) { + val = p->n_lval; + p = makety(p, swpole->type, 0, 0, MKSUE(swpole->type)); + if (p->n_op != ICON) + cerror("could not cast case value to type of switch " + "expression"); + if (p->n_lval != val) + werror("case expression truncated"); + } sw->sval = p->n_lval; - plabel( sw->slab = getlab()); - w = swpole->ents; - if (swpole->ents == NULL) { - sw->next = NULL; - swpole->ents = sw; - } else if (swpole->ents->next == NULL) { - if (swpole->ents->sval == sw->sval) { - uerror("duplicate case in switch"); - } else if (swpole->ents->sval < sw->sval) { - sw->next = NULL; - swpole->ents->next = sw; - } else { - sw->next = swpole->ents; - swpole->ents = sw; - } + tfree(p); + put = &swpole->ents; + if (ISUNSIGNED(swpole->type)) { + for (w = swpole->ents; + w != NULL && (U_CONSZ)w->sval < (U_CONSZ)sw->sval; + w = w->next) + put = &w->next; } else { - while (w->next->next != NULL && w->next->sval < sw->sval) { - w = w->next; - } - if (w->next->sval == sw->sval) { - uerror("duplicate case in switch"); - } else if (w->next->sval > sw->sval) { - sw->next = w->next; - w->next = sw; - } else { - sw->next = NULL; - w->next->next = sw; - } + for (w = swpole->ents; w != NULL && w->sval < sw->sval; + w = w->next) + put = &w->next; } + if (w != NULL && w->sval == sw->sval) { + uerror("duplicate case in switch"); + return; + } + plabel(sw->slab = getlab()); + *put = sw; + sw->next = w; swpole->nents++; - tfree(p); } +#ifdef GCC_COMPAT +void +gcccase(NODE *ln, NODE *hn) +{ + CONSZ i, l, h; + + l = icons(optim(ln)); + h = icons(optim(hn)); + + if (h < l) + i = l, l = h, h = i; + + for (i = l; i <= h; i++) + addcase(xbcon(i, NULL, hn->n_type)); +} +#endif + /* * add default case to switch */ @@ -1189,7 +1285,7 @@ } static void -swstart(int num) +swstart(int num, TWORD type) { struct swdef *sw = tmpalloc(sizeof(struct swdef)); @@ -1197,6 +1293,7 @@ sw->ents = NULL; sw->next = swpole; sw->num = num; + sw->type = type; swpole = sw; } @@ -1219,12 +1316,44 @@ swp[i] = swpole->ents; swpole->ents = swpole->ents->next; } - genswitch(swpole->num, swp, swpole->nents); + genswitch(swpole->num, swpole->type, swp, swpole->nents); swpole = swpole->next; } /* + * num: tempnode the value of the switch expression is in + * type: type of the switch expression + * + * p points to an array of structures, each consisting + * of a constant value and a label. + * The first is >=0 if there is a default label; + * its value is the label number + * The entries p[1] to p[n] are the nontrivial cases + * n is the number of case statements (length of list) + */ +static void +genswitch(int num, TWORD type, struct swents **p, int n) +{ + NODE *r, *q; + int i; + + if (mygenswitch(num, type, p, n)) + return; + + /* simple switch code */ + for (i = 1; i <= n; ++i) { + /* already in 1 */ + r = tempnode(num, type, 0, MKSUE(type)); + q = xbcon(p[i]->sval, NULL, type); + r = buildtree(NE, r, clocal(q)); + cbranch(buildtree(NOT, r, NIL), bcon(p[i]->slab)); + } + if (p[0]->slab > 0) + branch(p[0]->slab); +} + +/* * Declare a variable or prototype. */ static struct symtab * @@ -1240,10 +1369,11 @@ typ->n_sp->sflags |= SINLINE; if (ISFTN(typ->n_type) == 0) { - setloc1(DATA); if (assign) { defid(typ, class); typ->n_sp->sflags |= SASG; + if (typ->n_sp->sflags & SDYNARRAY) + uerror("can't initialize dynamic arrays"); lcommdel(typ->n_sp); } else { nidcl(typ, class); @@ -1258,6 +1388,24 @@ } /* + * Declare function arguments. + */ +static void +funargs(NODE *p) +{ + if (p->n_op == ELLIPSIS) + return; + if (oldstyle) { + p->n_op = TYPE; + p->n_type = FARG; + } + p->n_sp = lookup((char *)p->n_sp, 0);/* XXX */ + if (ISFTN(p->n_type)) + p->n_type = INCREF(p->n_type); + defid(p, PARAM); +} + +/* * Declare a function. */ static void @@ -1265,14 +1413,29 @@ { extern int prolab; struct symtab *s; + NODE *q = p; int class = tp->n_lval, oclass; char *c; - setloc1(PROG); - /* Enter function args before they are clobbered in tymerge() */ - /* Typecheck against prototype will be done in defid(). */ - ftnarg(p); + for (q = p; coptype(q->n_op) != LTYPE && q->n_left->n_op != NAME; + q = q->n_left) + ; + if (q->n_op != CALL && q->n_op != UCALL) { + uerror("invalid function definition"); + p = bdty(UCALL, p); + } + + argoff = ARGINIT; + ctval = tvaloff; + blevel++; + + if (q->n_op == CALL && q->n_right->n_type != VOID) { + /* declare function arguments */ + listf(q->n_right, funargs); + ftnarg(q); + } + blevel--; tymerge(tp, p); s = p->n_sp = lookup((char *)p->n_sp, 0); /* XXX */ @@ -1280,26 +1443,22 @@ if (class == STATIC && oclass == EXTERN) werror("%s was first declared extern, then static", s->sname); - if ((oclass == SNULL || oclass == USTATIC) && - class == STATIC && fun_inline) { - /* Unreferenced, store it for (eventual) later use */ - /* Ignore it if it not declared static */ + if (fun_inline) { + /* special syntax for inline functions */ s->sflags |= SINLINE; - inline_start(s->sname); - } - if (class == EXTERN) + inline_start(s); + if (class == EXTERN) + class = EXTDEF; + } else if (class == EXTERN) class = SNULL; /* same result */ cftnsp = s; defid(p, class); prolab = getlab(); - c = cftnsp->sname; -#ifdef GCC_COMPAT - c = gcc_findname(cftnsp); -#endif - send_passt(IP_PROLOG, -1, -1, c, cftnsp->stype, - cftnsp->sclass == EXTDEF, prolab); - blevel = 1; + c = cftnsp->soname; + send_passt(IP_PROLOG, -1, c, cftnsp->stype, + cftnsp->sclass == EXTDEF, prolab, ctval); + blevel++; #ifdef STABS if (gflag) stabs_func(s); @@ -1326,9 +1485,10 @@ if (f == DOT) p = buildtree(ADDROF, p, NIL); - r = block(NAME, NIL, NIL, INT, 0, MKSUE(INT)); + r = biop(NAME, NIL, NIL); r->n_name = name; - return buildtree(STREF, p, r); + r = buildtree(STREF, p, r); + return r; } static void @@ -1351,7 +1511,7 @@ branch(int lbl) { int r = reached++; - ecomp(block(GOTO, bcon(lbl), NIL, INT, 0, 0)); + ecomp(biop(GOTO, bcon(lbl), NIL)); reached = r; } @@ -1362,9 +1522,10 @@ mkpstr(char *str) { char *s, *os; - int v, l = strlen(str)+1; + int v, l = strlen(str)+3; /* \t + \n + \0 */ - os = s = isinlining ? permalloc(l) : tmpalloc(l); + os = s = inlalloc(l); + *s++ = '\t'; for (; *str; ) { if (*str++ == '\\') v = esccon(&str); @@ -1372,29 +1533,365 @@ v = str[-1]; *s++ = v; } + *s++ = '\n'; *s = 0; return os; } +/* + * Estimate the max length a string will have in its internal + * representation based on number of \ characters. + */ +static int +maxstlen(char *str) +{ + int i; + + for (i = 0; *str; str++, i++) + if (*str == '\\' || *str < 32 || *str > 0176) + i += 3; + return i; +} + +static char * +voct(char *d, unsigned int v) +{ + v &= (1 << SZCHAR) - 1; + *d++ = '\\'; + *d++ = v/64 + '0'; v &= 077; + *d++ = v/8 + '0'; v &= 7; + *d++ = v + '0'; + return d; +} + + +/* + * Convert a string to internal format. The resulting string may be no + * more than len characters long. + */ +static void +fixstr(char *d, char *s, int len) +{ + unsigned int v; + + while (*s) { + if (len <= 0) + cerror("fixstr"); + if (*s == '\\') { + s++; + v = esccon(&s); + d = voct(d, v); + len -= 4; + } else if (*s < ' ' || *s > 0176) { + d = voct(d, *s++); + len -= 4; + } else + *d++ = *s++, len--; + } + *d = 0; +} + +/* + * Add "raw" string new to cleaned string old. + */ +static char * +stradd(char *old, char *new) +{ + char *rv; + int len; + + if (*new == 'L' && new[1] == '\"') + widestr = 1, new++; + if (*new == '\"') { + new++; /* remove first " */ + new[strlen(new) - 1] = 0;/* remove last " */ + } + len = strlen(old) + maxstlen(new) + 1; + rv = tmpalloc(len); + strlcpy(rv, old, len); + fixstr(rv + strlen(old), new, maxstlen(new) + 1); + return rv; +} + static struct symtab * clbrace(NODE *p) { struct symtab *sp; - if (blevel == 0 && xnf != NULL) - cerror("no level0 compound literals"); - - sp = getsymtab("cl", STEMP); + sp = getsymtab(simname("cl"), STEMP); + if (blevel == 0 && xnf != NULL) { + sp->sclass = STATIC; + sp->slevel = 2; + sp->soffset = getlab(); + } else { + sp->sclass = blevel ? AUTO : STATIC; + if (!ISARY(sp->stype) || sp->sdf->ddim != NOOFFSET) { + sp->soffset = NOOFFSET; + oalloc(sp, &autooff); + } + } sp->stype = p->n_type; sp->squal = p->n_qual; sp->sdf = p->n_df; sp->ssue = p->n_sue; - sp->sclass = blevel ? AUTO : STATIC; - if (!ISARY(sp->stype) || sp->sdf->ddim != 0) { - sp->soffset = NOOFFSET; - oalloc(sp, &autooff); - } tfree(p); beginit(sp); return sp; } + +char * +simname(char *s) +{ + int len = strlen(s) + 10 + 1; + char *w = tmpalloc(len); + + snprintf(w, len, "%s%d", s, getlab()); + return w; +} + +NODE * +biop(int op, NODE *l, NODE *r) +{ + return block(op, l, r, INT, 0, MKSUE(INT)); +} + +static NODE * +cmop(NODE *l, NODE *r) +{ + return biop(CM, l, r); +} + +static NODE * +voidcon(void) +{ + return block(ICON, NIL, NIL, STRTY, 0, MKSUE(VOID)); +} + +/* Support for extended assembler a' la' gcc style follows below */ + +static NODE * +xmrg(NODE *out, NODE *in) +{ + NODE *p = in; + + if (p->n_op == XARG) { + in = cmop(out, p); + } else { + while (p->n_left->n_op == CM) + p = p->n_left; + p->n_left = cmop(out, p->n_left); + } + return in; +} + +/* + * Put together in and out node lists in one list, and balance it with + * the constraints on the right side of a CM node. + */ +static NODE * +xcmop(NODE *out, NODE *in, NODE *str) +{ + NODE *p, *q; + + if (out) { + /* D out-list sanity check */ + for (p = out; p->n_op == CM; p = p->n_left) { + q = p->n_right; + if (q->n_name[0] != '=' && q->n_name[0] != '+') + uerror("output missing ="); + } + if (p->n_name[0] != '=' && p->n_name[0] != '+') + uerror("output missing ="); + if (in == NIL) + p = out; + else + p = xmrg(out, in); + } else if (in) { + p = in; + } else + p = voidcon(); + + if (str == NIL) + str = voidcon(); + return cmop(p, str); +} + +/* + * Generate a XARG node based on a string and an expression. + */ +static NODE * +xasmop(char *str, NODE *p) +{ + + p = biop(XARG, p, NIL); + p->n_name = isinlining ? newstring(str, strlen(str)+1) : str; + return p; +} + +/* + * Generate a XASM node based on a string and an expression. + */ +static void +mkxasm(char *str, NODE *p) +{ + NODE *q; + + q = biop(XASM, p->n_left, p->n_right); + q->n_name = isinlining ? newstring(str, strlen(str)+1) : str; + nfree(p); + ecomp(q); +} + +#ifdef GCC_COMPAT +static NODE * +tyof(NODE *p) +{ + static struct symtab spp; + NODE *q = block(TYPE, NIL, NIL, p->n_type, 0, 0); + q->n_qual = p->n_qual; + q->n_sp = &spp; /* for typenode */ + tfree(p); + return q; +} +#endif + +/* + * Traverse an unhandled expression tree bottom-up and call buildtree() + * or equivalent as needed. + */ +NODE * +eve(NODE *p) +{ + struct symtab *sp; + NODE *r, *p1, *p2; + r = NULL; + + p1 = p->n_left; + p2 = p->n_right; + switch (p->n_op) { + case NAME: + sp = lookup((char *)p->n_sp, 0); + if (sp->sflags & SINLINE) + inline_ref(sp); + r = nametree(sp); + if (sp->sflags & SDYNARRAY) + r = buildtree(UMUL, r, NIL); + break; + + case DOT: + case STREF: + r = structref(eve(p1), p->n_op, (char *)p2->n_sp); + nfree(p2); + break; + + case CAST: + p1 = buildtree(CAST, p1, eve(p2)); + nfree(p1->n_left); + r = p1->n_right; + nfree(p1); + break; + + + case SZOF: + if (p2->n_lval == 0) + p1 = eve(p1); + nfree(p2); + r = doszof(p1); + break; + + case LB: + p1 = eve(p->n_left); + r = buildtree(UMUL, buildtree(PLUS, p1, eve(p2)), NIL); + break; + + case COMPL: + case UMINUS: + case NOT: + case UMUL: + r = buildtree(p->n_op, eve(p->n_left), NIL); + break; + + case ADDROF: + r = eve(p1); + if (ISFTN(p->n_type)/* || ISARY(p->n_type) */){ +#ifdef notdef + werror( "& before array or function: ignored" ); +#endif + } else + r = buildtree(ADDROF, r, NIL); + break; + + case CALL: + p2 = eve(p2); + /* FALLTHROUGH */ + case UCALL: + if (p1->n_op == NAME) { + sp = lookup((char *)p1->n_sp, 0); + if (sp->stype == UNDEF) { + p1->n_type = FTN|INT; + p1->n_sp = sp; + defid(p1, EXTERN); + } + nfree(p1); + r = doacall(sp, nametree(sp), p2); + } else + r = doacall(NULL, eve(p1), p2); + break; + + case INCR: + case DECR: + case CM: + case GT: + case GE: + case LT: + case LE: + case EQ: + case NE: + case RS: + case LS: + case RSEQ: + case LSEQ: + case AND: + case OR: + case ER: + case MUL: + case DIV: + case MOD: + case PLUS: + case MINUS: + case OROR: + case ANDAND: + case EREQ: + case OREQ: + case ANDEQ: + case MINUSEQ: + case PLUSEQ: + case MULEQ: + case DIVEQ: + case MODEQ: + case COMOP: + case QUEST: + case COLON: + case ASSIGN: + p1 = eve(p1); + r = buildtree(p->n_op, p1, eve(p2)); + break; + + case STRING: + r = strend(p->n_lval, p->n_name); + break; + + case TYPE: + case ICON: + case FCON: + return p; + + default: +#ifdef PCC_DEBUG + fwalk(p, eprint, 0); +#endif + cerror("eve"); + } + nfree(p); + return r; +} Index: ccom.1 =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/ccom.1,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/ccom.1 -L usr.bin/pcc/ccom/ccom.1 -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/ccom.1 +++ usr.bin/pcc/ccom/ccom.1 @@ -1,39 +1,43 @@ -.\" $Id: ccom.1,v 1.2 2007/09/26 14:48:49 ragge Exp $ .\" $NetBSD$ -.\" $OpenBSD$ +.\" $Id: ccom.1,v 1.8 2008/02/20 01:31:26 gmcgarry Exp $ ."\ .\" Copyright (c) 2007 Jeremy C. Reed -.\" Permission to use, copy, modify, and/or distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above +.\" Permission to use, copy, modify, and/or distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above .\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM -.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND -.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL -.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR -.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS -.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM +.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND +.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS +.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF .\" THIS SOFTWARE. .Dd September 14, 2007 -.Dt ccom 1 +.Dt CCOM 1 .Os .Sh NAME .Nm ccom .Nd C compiler .Sh SYNOPSIS .Nm +.Op Fl gs +.Op Fl W Ar flags .Op Fl X Ar flags +.Op Fl x Ar optimizations +.Op Fl Z Ar flags .Op infile .Op outfile -.Pp .Sh DESCRIPTION The .Nm utility provides a C compiler. The frontend is usually .Xr pcc 1 . -It is \fBnot\fR intended to be run directly. +It is +.Em not +intended to be run directly. .Pp .Nm reads the C source from @@ -48,6 +52,8 @@ .It Fl g Enable debugging. .\" built into binary, explain stabs? +.It Fl k +Generate PIC code. .It Fl s Print statistics to standard error when complete. This includes: @@ -56,81 +62,112 @@ dimension/function unions, struct/union/enum blocks, inline node count, inline control blocks, and permanent symtab entries. .\" TODO: explain units for above? +.It Fl v +Display version. .It Fl W Ar flags Report warnings. (Do some basic checks.) -NOTE! These are subject to change RSN! -.Ar Flags +.Em NOTE! +.Em These are subject to change RSN! +.Ar flags is one or more of the following: .Bl -tag -width Ds +.It Sy error +Report all warnings as errors. .It Sy implicit Implies -.Sy implicit-int +.Sy implicit-function-declaration and -.Sy implicit-function-declaration . +.Sy implicit-int . +.It Sy implicit-function-declaration +Report if no prototype was declared for a function. .It Sy implicit-int TODO -.It Sy implicit-function-declaration -Report if no prototype for function. .It Sy missing-prototypes TODO .It Sy strict-prototypes TODO +.It Sy W +Enable all warnings. +.El +.\" +.It Fl X Ar flags +C specific debugging where +.Ar flags +is one or more of the following: +.Bl -tag -width Ds +.It Sy b +Building of parse trees +.It Sy d +Declarations (using multiple +.Sy d +flags gives more output) +.It Sy e +Pass1 trees at exit +.It Sy i +Initializations +.It Sy n +Memory allocations +.It Sy o +Turn off optimisations +.It Sy p +Prototypes +.It Sy s +Inlining +.It Sy t +Type conversions +.It Sy x +Target-specific flag, used in machine-dependent code .El .\" .It Fl x Ar optimizations .Ar optimizations -is one or more of the following: +is one of the following: +.\" TODO: reword this, since multiple terms don't go with one -x switch?? .Bl -tag -width deljumps .It Sy deljumps Delete redundant jumps and dead code. .It Sy ssa -Convert statements into SSA form for optimization. Not yet finished. +Convert statements into SSA form for optimization. +Not yet finished. .It Sy tailcall Currently not implemented. .It Sy temps -Setting this flag allow variables to be put into registers, for further +Setting this flag allows variables to be put into registers, for further optimization by the register allocator. .El +The +.Fl x +flag can be passed multiple times to set different options. .\" -.It Fl X Ar C specific debugging flags -.Ar Flags +.It Fl Z Ar flags +Code generator (pass2) specific debugging where +.Ar flags is one or more of the following: .Bl -tag -width Ds .It Sy b -Building of parse trees -.It Sy d -Declarations, more d gives more output -.It Sy t -Type conversions -.It Sy i -Initializations -.It Sy e -Pass1 trees at exit -.It Sy x -Target-specific flag, used in machine-dependent code -.El -.\" -.It Fl Z Ar Code generator (pass2) specific debugging flags -.Ar Flags -is one or more of the following: -.Bl -tag -width Ds +Basic block and SSA building +.It Sy c +Code printout .It Sy e Trees when entering pass2 -.It Sy o -Instruction generator .It Sy f Instruction matcher, may provide much output +.It Sy n +Memory allocation +.It Sy o +Instruction generator .It Sy r Register allocator -.It Sy t -Type matching in instruction generator .It Sy s Shape matching in instruction generator +.It Sy t +Type matching in instruction generator .It Sy u Sethi-Ullman computations .It Sy x -Target-specific flag, used in machine-dependent code +Target-specific flag, used in machine-dependent code +.El .El .Sh SEE ALSO .Xr as 1 , @@ -139,8 +176,8 @@ .Sh HISTORY The .Nm -compiler is based on the original Portable C Compiler by S. C. -Johnson, written in the late 70's. +compiler is based on the original Portable C Compiler by S. C. Johnson, +written in the late 70's. Even though much of the compiler has been rewritten, some of the basics still remain. About 50% of the frontend code and 80% of the backend code has been @@ -148,5 +185,8 @@ Most is written by Anders Magnusson, with the exception of the data-flow analysis part and the SSA conversion code which is written by Peter A Jonsson, and the Mips port that were written as -part of a project by undergraduate students at Lulea University of +part of a project by undergraduate students at Lulea University of Technology. +.Pp +This product includes software developed or owned by Caldera +International, Inc. Index: trees.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/trees.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/trees.c -L usr.bin/pcc/ccom/trees.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/trees.c +++ usr.bin/pcc/ccom/trees.c @@ -1,4 +1,4 @@ -/* $Id: trees.c,v 1.163 2007/09/16 08:26:39 ragge Exp $ */ +/* $Id: trees.c,v 1.223 2008/12/14 21:15:24 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -70,14 +70,16 @@ # include "pass2.h" # include +# include static void chkpun(NODE *p); static int opact(NODE *p); static int moditype(TWORD); static NODE *strargs(NODE *); static void rmcops(NODE *p); - -int lastloc = -1; +static void putjops(NODE *, void *); +static struct symtab *findmember(struct symtab *, char *); +int inftn; /* currently between epilog/prolog */ /* some special actions, used in finding the type of nodes */ # define NCVT 01 @@ -107,6 +109,8 @@ */ int bdebug = 0; +extern int negrel[]; + NODE * buildtree(int o, NODE *l, NODE *r) @@ -116,8 +120,6 @@ int opty; struct symtab *sp = NULL; /* XXX gcc */ NODE *lr, *ll; - char *name; - struct symtab **elem; #ifdef PCC_DEBUG if (bdebug) { @@ -143,23 +145,23 @@ } else if (o == NOT && l->n_op == FCON) { l = clocal(block(SCONV, l, NIL, INT, 0, MKSUE(INT))); } else if( o == UMINUS && l->n_op == FCON ){ - l->n_dcon = -l->n_dcon; + l->n_dcon = FLOAT_NEG(l->n_dcon); return(l); } else if( o==QUEST && l->n_op==ICON ) { CONSZ c = l->n_lval; nfree(l); if (c) { + walkf(r->n_right, putjops, 0); tfree(r->n_right); l = r->n_left; - nfree(r); - return(l); } else { + walkf(r->n_left, putjops, 0); tfree(r->n_left); l = r->n_right; - nfree(r); - return(l); } + nfree(r); + return(l); } else if( opty == BITYPE && l->n_op == ICON && r->n_op == ICON ){ switch( o ){ @@ -199,9 +201,11 @@ case ER: case LS: case RS: - if( conval( l, o, r ) ) { - nfree(r); - return(l); + if (!ISPTR(l->n_type) && !ISPTR(r->n_type)) { + if( conval( l, o, r ) ) { + nfree(r); + return(l); + } } break; } @@ -214,21 +218,24 @@ case MUL: case DIV: if (l->n_op == ICON) - l->n_dcon = l->n_lval; + l->n_dcon = FLOAT_CAST(l->n_lval, l->n_type); if (r->n_op == ICON) - r->n_dcon = r->n_lval; + r->n_dcon = FLOAT_CAST(r->n_lval, r->n_type); switch (o) { case PLUS: - l->n_dcon += r->n_dcon; break; + l->n_dcon = FLOAT_PLUS(l->n_dcon, r->n_dcon); + break; case MINUS: - l->n_dcon -= r->n_dcon; break; + l->n_dcon = FLOAT_MINUS(l->n_dcon, r->n_dcon); + break; case MUL: - l->n_dcon *= r->n_dcon; break; + l->n_dcon = FLOAT_MUL(l->n_dcon, r->n_dcon); + break; case DIV: - if (r->n_dcon == 0) - uerror("division by 0."); - else - l->n_dcon /= r->n_dcon; + if (FLOAT_ISZERO(r->n_dcon)) + goto runtime; + l->n_dcon = FLOAT_DIV(l->n_dcon, r->n_dcon); + break; } l->n_op = FCON; l->n_type = DOUBLE; @@ -237,7 +244,7 @@ return(l); } } - +runtime: /* its real; we must make a new node */ p = block(o, l, r, INT, 0, MKSUE(INT)); @@ -247,6 +254,8 @@ if (actions & LVAL) { /* check left descendent */ if (notlval(p->n_left)) { uerror("lvalue required"); + nfree(p); + return l; #ifdef notyet } else { if ((l->n_type > BTMASK && ISCON(l->n_qual)) || @@ -296,53 +305,7 @@ switch(o){ case NAME: - sp = spname; - if (sp->sflags & STNODE) { - /* Generated for optimizer */ - p->n_op = TEMP; - p->n_type = sp->stype; - p->n_sue = sp->ssue; - p->n_df = sp->sdf; - p->n_lval = sp->soffset; - break; - } - -#ifdef GCC_COMPAT - /* Get a label name */ - if (sp->sflags == SLBLNAME) { - p->n_type = VOID; - p->n_sue = MKSUE(VOID); - p->n_lval = 0; - p->n_sp = sp; - break; - } else -#endif - if (sp->stype == UNDEF) { - uerror("%s undefined", sp->sname); - /* make p look reasonable */ - p->n_type = INT; - p->n_sue = MKSUE(INT); - p->n_df = NULL; - p->n_sp = sp; - p->n_lval = 0; - defid(p, SNULL); - break; - } - p->n_type = sp->stype; - p->n_qual = sp->squal; - p->n_df = sp->sdf; - p->n_sue = sp->ssue; - p->n_lval = 0; - p->n_sp = sp; - /* special case: MOETY is really an ICON... */ - if (p->n_type == MOETY) { - p->n_sp = NULL; - p->n_lval = sp->soffset; - p->n_df = NULL; - p->n_type = ENUMTY; - p->n_op = ICON; - } - break; + cerror("buildtree NAME"); case STREF: /* p->x turned into *(p+offset) */ @@ -354,17 +317,23 @@ break; } - if ((elem = l->n_sue->suelem) == NULL) + if ((sp = l->n_sue->sylnk) == NULL) { uerror("undefined struct or union"); + break; + } + sp = findmember(sp, r->n_name); +#ifdef notdef name = r->n_name; - for (; *elem != NULL; elem++) { - sp = *elem; + for (; sp != NULL; sp = sp->snext) { if (sp->sname == name) break; } - if (*elem == NULL) - uerror("member '%s' not declared", name); +#endif + if (sp == NULL) { + uerror("member '%s' not declared", r->n_name); + break; + } r->n_sp = sp; p = stref(p); @@ -453,7 +422,7 @@ TWORD t; union dimfun *d; - if (l->n_sue != r->n_sue) + if (l->n_sue->sylnk != r->n_sue->sylnk) uerror("assignment of different structures"); r = buildtree(ADDROF, r, NIL); @@ -462,6 +431,7 @@ sue = r->n_sue; l = block(STASG, l, r, t, d, sue); + l = clocal(l); if( o == RETURN ){ nfree(p); @@ -483,6 +453,8 @@ case CALL: p->n_right = r = strargs(p->n_right); + p = funcode(p); + /* FALLTHROUGH */ case UCALL: if (!ISPTR(l->n_type)) uerror("illegal function"); @@ -540,6 +512,88 @@ } +/* Find a member in a struct or union. May be an unnamed member */ +static struct symtab * +findmember(struct symtab *sp, char *s) +{ + struct symtab *sp2, *sp3; + + for (; sp != NULL; sp = sp->snext) { + if (sp->sname[0] == '*') { + /* unnamed member, recurse down */ + if ((sp2 = findmember(sp->ssue->sylnk, s))) { + sp3 = tmpalloc(sizeof (struct symtab)); + *sp3 = *sp2; + sp3->soffset += sp->soffset; + return sp3; + } + } else if (sp->sname == s) + return sp; + } + return NULL; +} + + +/* + * Check if there will be a lost label destination inside of a ?: + * It cannot be reached so just print it out. + */ +static void +putjops(NODE *p, void *arg) +{ + if (p->n_op == COMOP && p->n_left->n_op == GOTO) + plabel(p->n_left->n_left->n_lval+1); +} + +/* + * Build a name node based on a symtab entry. + * broken out from buildtree(). + */ +NODE * +nametree(struct symtab *sp) +{ + NODE *p; + + p = block(NAME, NIL, NIL, sp->stype, sp->sdf, sp->ssue); + p->n_qual = sp->squal; + p->n_sp = sp; + +#ifndef NO_C_BUILTINS + if (sp->sname[0] == '_' && strncmp(sp->sname, "__builtin_", 10) == 0) + return p; /* do not touch builtins here */ + +#endif + + if (sp->sflags & STNODE) { + /* Generated for optimizer */ + p->n_op = TEMP; + p->n_rval = sp->soffset; + } + +#ifdef GCC_COMPAT + /* Get a label name */ + if (sp->sflags == SLBLNAME) { + p->n_type = VOID; + p->n_sue = MKSUE(VOID); + } +#endif + if (sp->stype == UNDEF) { + uerror("%s undefined", sp->sname); + /* make p look reasonable */ + p->n_type = INT; + p->n_sue = MKSUE(INT); + p->n_df = NULL; + defid(p, SNULL); + } + if (sp->sclass == MOE) { + p->n_op = ICON; + p->n_lval = sp->soffset; + p->n_df = NULL; + p->n_sp = NULL; + } + return clocal(p); +} + /* * Do a conditional branch. */ @@ -548,8 +602,10 @@ { p = buildtree(CBRANCH, p, q); if (p->n_left->n_op == ICON) { - if (p->n_left->n_lval != 0) + if (p->n_left->n_lval != 0) { branch(q->n_lval); /* branch always */ + reached = 0; + } tfree(p); tfree(q); return; @@ -714,6 +770,7 @@ * we check that this integer is in fact a constant zero... * in the case of ASSIGN, any assignment of pointer to integer is illegal * this falls out, because the LHS is never 0. + * XXX - check for COMOPs in assignment RHS? */ void chkpun(NODE *p) @@ -743,8 +800,10 @@ return; break; default: - if ((t1 == VOID && t2 != VOID) || (t1 != VOID && t2 == VOID)) - return uerror("value of void expression used"); + if ((t1 == VOID && t2 != VOID) || (t1 != VOID && t2 == VOID)) { + uerror("value of void expression used"); + return; + } break; } @@ -754,26 +813,6 @@ if (BTYPE(t2) == VOID && (t1 & TMASK)) return; -#ifdef notdef - /* C99 says that enums always should be handled as ints */ - /* check for enumerations */ - if (t1==ENUMTY || t2==ENUMTY) { - if( clogop( p->n_op ) && p->n_op != EQ && p->n_op != NE ) { - werror( "comparison of enums" ); - return; - } - if (t1==ENUMTY && t2==ENUMTY) { - if (p->n_left->n_sue!=p->n_right->n_sue) - werror("enumeration type clash, " - "operator %s", copst(p->n_op)); - return; - } - if ((t1 == ENUMTY && t2 <= BTMASK) || - (t2 == ENUMTY && t1 <= BTMASK)) - return; - } -#endif - if (ISPTR(t1) || ISARY(t1)) q = p->n_right; else @@ -786,7 +825,7 @@ d1 = p->n_left->n_df; d2 = p->n_right->n_df; if (t1 == t2) { - if (p->n_left->n_sue != p->n_right->n_sue) + if (p->n_left->n_sue->sylnk != p->n_right->n_sue->sylnk) werror("illegal structure pointer combination"); return; } @@ -815,7 +854,8 @@ t1 = DECREF(t1); t2 = DECREF(t2); } - werror("illegal pointer combination"); + if (Wpointer_sign) + werror("illegal pointer combination"); } } @@ -856,6 +896,21 @@ off = s->soffset; dsc = s->sclass; +#ifndef CAN_UNALIGN + /* + * If its a packed struct, and the target cannot do unaligned + * accesses, then split it up in two bitfield operations. + * LHS and RHS accesses are different, so must delay + * it until we know. Do the bitfield construct here though. + */ + if ((dsc & FIELD) == 0 && (off % talign(s->stype, s->ssue))) { +// int sz = tsize(s->stype, s->sdf, s->ssue); +// int al = talign(s->stype, s->ssue); +// int sz1 = al - (off % al); + + } +#endif + if (dsc & FIELD) { /* make fields look like ints */ off = (off/ALINT)*ALINT; sue = MKSUE(INT); @@ -911,12 +966,18 @@ NODE * bcon(int i) { - register NODE *p; + return xbcon(i, NULL, INT); +} - p = block(ICON, NIL, NIL, INT, 0, MKSUE(INT)); - p->n_lval = i; - p->n_sp = NULL; - return(clocal(p)); +NODE * +xbcon(CONSZ val, struct symtab *sp, TWORD type) +{ + NODE *p; + + p = block(ICON, NIL, NIL, type, 0, MKSUE(type)); + p->n_lval = val; + p->n_sp = sp; + return clocal(p); } NODE * @@ -995,34 +1056,6 @@ return(p); } -/* - * change enums to ints, or appropriate types - */ -void -econvert( p ) register NODE *p; { - - - register TWORD ty; - - if( (ty=BTYPE(p->n_type)) == ENUMTY || ty == MOETY ) { - if (p->n_sue->suesize == SZCHAR) - ty = INT; - else if (p->n_sue->suesize == SZINT) - ty = INT; - else if (p->n_sue->suesize == SZSHORT) - ty = INT; - else if (p->n_sue->suesize == SZLONGLONG) - ty = LONGLONG; - else - ty = LONG; - ty = ctype(ty); - p->n_sue = MKSUE(ty); - MODTYPE(p->n_type,ty); - if (p->n_op == ICON && ty != LONG && ty != LONGLONG) - p->n_type = INT, p->n_sue = MKSUE(INT); - } -} - NODE * pconvert( p ) register NODE *p; { @@ -1049,7 +1082,12 @@ case LT: case GE: case GT: - if( ISUNSIGNED(p->n_left->n_type) || ISUNSIGNED(p->n_right->n_type) ) p->n_op += (ULE-LE); + if(ISUNSIGNED(p->n_left->n_type) || + ISUNSIGNED(p->n_right->n_type) || + ISPTR(p->n_left->n_type) || + ISPTR(p->n_right->n_type)) + p->n_op += (ULE-LE); + /* FALLTHROUGH */ case EQ: case NE: return( p ); @@ -1184,10 +1222,10 @@ t2 = DEUNSIGN(t2); } - if (t1 == ENUMTY || t1 == MOETY) - t1 = INT; /* XXX */ - if (t2 == ENUMTY || t2 == MOETY) - t2 = INT; /* XXX */ + if (Wsign_compare && clogop(o) && t1 == t2 && lu != ru && + p->n_left->n_op != ICON && p->n_right->n_op != ICON) + werror("comparison between signed and unsigned"); + #if 0 if ((t1 == CHAR || t1 == SHORT) && o!= RETURN) t1 = INT; @@ -1266,8 +1304,6 @@ makety(NODE *p, TWORD t, TWORD q, union dimfun *d, struct suedef *sue) { - if (p->n_type == ENUMTY && p->n_op == ICON) - econvert(p); if (t == p->n_type) { p->n_df = d; p->n_sue = sue; @@ -1294,10 +1330,7 @@ if (p->n_op == ICON) { if (t == DOUBLE || t == FLOAT) { p->n_op = FCON; - if (ISUNSIGNED(p->n_type)) - p->n_dcon = (U_CONSZ) p->n_lval; - else - p->n_dcon = p->n_lval; + p->n_dcon = FLOAT_CAST(p->n_lval, p->n_type); p->n_type = t; p->n_qual = q; p->n_sue = MKSUE(t); @@ -1332,20 +1365,21 @@ return(p); } -int -icons(p) register NODE *p; { +/* + * Return the constant value from an ICON. + */ +CONSZ +icons(NODE *p) +{ /* if p is an integer constant, return its value */ - int val; + CONSZ val; - if( p->n_op != ICON ){ + if (p->n_op != ICON || p->n_sp != NULL) { uerror( "constant expected"); val = 1; - } - else { + } else val = p->n_lval; - if( val != p->n_lval ) uerror( "constant too big for cross-compiler" ); - } - tfree( p ); + tfree(p); return(val); } @@ -1382,7 +1416,6 @@ # define MSTR 04 /* structure */ # define MPTR 010 /* pointer */ # define MPTI 020 /* pointer or integer */ -# define MENU 040 /* enumeration variable or member */ int opact(NODE *p) @@ -1428,8 +1461,6 @@ case MUL: case DIV: - if ((mt1&MDBI) && (mt2&MENU)) return( TYMATCH ); - if ((mt2&MDBI) && (mt1&MENU)) return( TYMATCH ); if( mt12 & MDBI ) return( TYMATCH ); break; @@ -1452,13 +1483,12 @@ case GT: case GE: if( mt12 & MDBI ) return( TYMATCH+CVTO ); - else if( mt12 & MPTR ) return( PTMATCH+PUN ); + else if( mt12 & MPTR ) return( PTMATCH+PUN+CVTO ); else if( mt12 & MPTI ) return( PTMATCH+PUN ); else break; case QUEST: case COMOP: - if( mt2&MENU ) return( TYPR+NCVTR ); return( TYPR ); case STREF: @@ -1480,12 +1510,6 @@ if( mt12 & MSTR ) return( LVAL+NCVT+TYPL+OTHER ); case CAST: if( mt12 & MDBI ) return( TYPL+LVAL+TYMATCH ); -#if 0 - else if(mt1&MENU && mt2&MDBI) return( TYPL+LVAL+TYMATCH ); - else if(mt2&MENU && mt1&MDBI) return( TYPL+LVAL+TYMATCH ); - else if( (mt1&MENU)||(mt2&MENU) ) - return( LVAL+NCVT+TYPL+PTMATCH+PUN ); -#endif else if( mt1 & MPTR) return( LVAL+PTMATCH+PUN ); else if( mt12 & MPTI ) return( TYPL+LVAL+TYMATCH+PUN ); break; @@ -1542,10 +1566,6 @@ { switch (ty) { - case ENUMTY: - case MOETY: - return( MENU|MINT|MDBI|MPTI ); - case STRTY: case UNIONTY: return( MSTR ); @@ -1572,7 +1592,7 @@ } } -int tvaloff = 100; +int tvaloff = MAXREGS+NPERMREG > 100 ? MAXREGS+NPERMREG + 100 : 100; /* * Returns a TEMP node with temp number nr. @@ -1584,7 +1604,7 @@ NODE *r; r = block(TEMP, NIL, NIL, type, df, sue); - r->n_lval = nr ? nr : tvaloff; + regno(r) = nr ? nr : tvaloff; tvaloff += szty(type); return r; } @@ -1599,6 +1619,9 @@ TWORD ty; NODE *rv; + if (p->n_op == FLD) + uerror("can't apply sizeof to bit-field"); + /* * Arrays may be dynamic, may need to make computations. */ @@ -1607,6 +1630,8 @@ df = p->n_df; ty = p->n_type; while (ISARY(ty)) { + if (df->ddim == NOOFFSET) + uerror("sizeof of incomplete type"); rv = buildtree(MUL, rv, df->ddim >= 0 ? bcon(df->ddim) : tempnode(-df->ddim, INT, 0, MKSUE(INT))); df++; @@ -1633,40 +1658,51 @@ ty = coptype( p->n_op ); printf("%p) %s, ", p, copst(p->n_op)); + if (p->n_op == XARG || p->n_op == XASM) + printf("id '%s', ", p->n_name); if (ty == LTYPE) { printf(CONFMT, p->n_lval); - printf(", %d, ", p->n_rval); + printf(", %d, ", (p->n_op != NAME && p->n_op != ICON) ? + p->n_rval : 0); } tprint(stdout, p->n_type, p->n_qual); printf( ", %p, %p\n", p->n_df, p->n_sue ); } # endif -void -prtdcon(NODE *p) +/* + * Emit everything that should be emitted on the left side + * of a comma operator, and remove the operator. + * Do not traverse through QUEST, ANDAND and OROR. + * Enable this for all targets when stable enough. + */ +static void +comops(NODE *p) { - int o = p->n_op, i; - - if (o != FCON) - return; - - /* Write float constants to memory */ - /* Should be volontary per architecture */ + int o; + NODE *q; - setloc1(RDATA); - defalign(p->n_type == FLOAT ? ALFLOAT : p->n_type == DOUBLE ? - ALDOUBLE : ALLDOUBLE ); - deflab1(i = getlab()); - ninval(0, btdims[p->n_type].suesize, p); - p->n_op = NAME; - p->n_lval = 0; - p->n_sp = tmpalloc(sizeof(struct symtab_hdr)); - p->n_sp->sclass = ILABEL; - p->n_sp->soffset = i; + while (p->n_op == COMOP) { + /* XXX hack for GCC ({ }) ops */ + if (p->n_left->n_op == GOTO) { + int v = p->n_left->n_left->n_lval; + ecomp(p->n_left); + plabel(v+1); + } else + ecomp(p->n_left); /* will recurse if more COMOPs */ + q = p->n_right; + *p = *q; + nfree(q); + } + o = coptype(p->n_op); + if (p->n_op == QUEST || p->n_op == ANDAND || p->n_op == OROR) + o = UTYPE; + if (o != LTYPE) + comops(p->n_left); + if (o == BITYPE) + comops(p->n_right); } -extern int negrel[]; - /* * Walk up through the tree from the leaves, * removing constant operators. @@ -1815,6 +1851,7 @@ case ANDAND: lab = false<0 ? getlab() : false ; andorbr(p->n_left, -1, lab); + comops(p->n_right); andorbr(p->n_right, true, false); if (false < 0) plabel( lab); @@ -1824,6 +1861,7 @@ case OROR: lab = true<0 ? getlab() : true; andorbr(p->n_left, lab, -1); + comops(p->n_right); andorbr(p->n_right, true, false); if (true < 0) plabel( lab); @@ -1862,9 +1900,18 @@ NODE *q, *r; int o, ty, lbl, lbl2, tval = 0; -again: o = p->n_op; ty = coptype(o); + if (BTYPE(p->n_type) == ENUMTY) { /* fixup enum */ + MODTYPE(p->n_type, p->n_sue->sylnk->stype); + /* + * XXX may fail if these are true: + * - variable-sized enums + * - non-byte-addressed targets. + */ + if (BTYPE(p->n_type) == ENUMTY && ISPTR(p->n_type)) + MODTYPE(p->n_type, INT); /* INT ok? */ + } switch (o) { case QUEST: @@ -1878,9 +1925,10 @@ /* Make ASSIGN node */ /* Only if type is not void */ q = p->n_right->n_left; + comops(q); if (type != VOID) { r = tempnode(0, q->n_type, q->n_df, q->n_sue); - tval = r->n_lval; + tval = regno(r); q = buildtree(ASSIGN, r, q); } rmcops(q); @@ -1889,6 +1937,7 @@ plabel( lbl); q = p->n_right->n_right; + comops(q); if (type != VOID) { r = tempnode(tval, q->n_type, q->n_df, q->n_sue); q = buildtree(ASSIGN, r, q); @@ -1927,7 +1976,7 @@ *r = *p; andorbr(r, -1, lbl = getlab()); q = tempnode(0, p->n_type, p->n_df, p->n_sue); - tval = q->n_lval; + tval = regno(q); r = tempnode(tval, p->n_type, p->n_df, p->n_sue); ecode(buildtree(ASSIGN, q, bcon(1))); branch(lbl2 = getlab()); @@ -1945,13 +1994,7 @@ p->n_op = ICON; p->n_type = VOID; break; case COMOP: - rmcops(p->n_left); - ecode(p->n_left); - /* Now when left tree is dealt with, rm COMOP */ - q = p->n_right; - *p = *p->n_right; - nfree(q); - goto again; + cerror("COMOP error"); default: if (ty == LTYPE) @@ -1994,7 +2037,7 @@ if (p->n_op == INCR || p->n_op == DECR) { /* * Rewrite x++ to (x += 1) -1; and deal with it further down. - * Pass2 will remove -1 if unneccessary. + * Pass2 will remove -1 if unnecessary. */ q = ccopy(p); tfree(p->n_left); @@ -2009,7 +2052,7 @@ if (has_se(l)) { q = tempnode(0, ll->n_type, ll->n_df, ll->n_sue); - tval = q->n_lval; + tval = regno(q); r = tempnode(tval, ll->n_type, ll->n_df,ll->n_sue); l->n_left = q; /* Now the left side of node p has no side effects. */ @@ -2052,19 +2095,21 @@ fwalk(p, eprint, 0); #endif if (!reached) { - werror("statement not reached"); + if (Wunreachable_code) + werror("statement not reached"); reached = 1; } p = optim(p); + comops(p); rmcops(p); p = delasgop(p); - setloc1(PROG); if (p->n_op == ICON && p->n_type == VOID) tfree(p); else ecode(p); } + #if defined(MULTIPASS) void p2tree(NODE *p) @@ -2072,9 +2117,7 @@ struct symtab *q; int ty; -# ifdef MYP2TREE - MYP2TREE(p); /* local action can be taken here; then return... */ -# endif + myp2tree(p); /* local action can be taken here */ ty = coptype(p->n_op); @@ -2101,11 +2144,10 @@ case ICON: /* print external name */ if ((q = p->n_sp) != NULL) { - if ((q->sclass == STATIC && q->slevel > 0) || - q->sclass == ILABEL) { + if ((q->sclass == STATIC && q->slevel > 0)) { printf(LABFMT, q->soffset); } else - printf("%s\n", exname(q->sname)); + printf("%s\n", exname(q->soname)); } else printf("\n"); break; @@ -2125,6 +2167,10 @@ printf("\t%d\t\n", talign(STRTY, p->n_left->n_sue)); break; + case XARG: + case XASM: + break; + default: printf( "\n" ); } @@ -2135,15 +2181,24 @@ p2tree(p->n_right); } #else +static char * +sptostr(struct symtab *sp) +{ + char *cp = inlalloc(32); + int n = sp->soffset; + if (n < 0) + n = -n; + snprintf(cp, 32, LABFMT, n); + return cp; +} + void p2tree(NODE *p) { struct symtab *q; int ty; -# ifdef MYP2TREE - MYP2TREE(p); /* local action can be taken here; then return... */ -# endif + myp2tree(p); /* local action can be taken here */ ty = coptype(p->n_op); @@ -2154,23 +2209,19 @@ if ((q = p->n_sp) != NULL) { if ((q->sclass == STATIC && q->slevel > 0) || #ifdef GCC_COMPAT - q->sflags == SLBLNAME || + q->sflags == SLBLNAME #endif - q->sclass == ILABEL) { - char *cp = (isinlining ? - permalloc(32) : tmpalloc(32)); - int n = q->soffset; - if (n < 0) - n = -n; - snprintf(cp, 32, LABFMT, n); + ) { + p->n_name = sptostr(q); + } else if (!kflag) { + char *name = exname(q->soname); + int n = strlen(name) + 1; + char *cp = inlalloc(n); + + strlcpy(cp, name, n); p->n_name = cp; - } else { -#ifdef GCC_COMPAT - p->n_name = gcc_findname(q); -#else - p->n_name = exname(q->sname); -#endif - } + } else + p->n_name = q->soname; } else p->n_name = ""; break; @@ -2198,6 +2249,10 @@ p->n_stalign = talign(STRTY,p->n_left->n_sue)/SZCHAR; break; + case XARG: + case XASM: + break; + default: p->n_name = ""; } @@ -2212,7 +2267,7 @@ * Change void data types into char. */ static void -delvoid(NODE *p) +delvoid(NODE *p, void *arg) { /* Convert "PTR undef" (void *) to "PTR uchar" */ if (BTYPE(p->n_type) == VOID) @@ -2227,7 +2282,7 @@ *q = *p; q->n_type = BOOL_TYPE; r = tempnode(0, BOOL_TYPE, NULL, MKSUE(BOOL_TYPE)); - val = r->n_lval; + val = regno(r); s = tempnode(val, BOOL_TYPE, NULL, MKSUE(BOOL_TYPE)); *p = *s; q = buildtree(ASSIGN, r, q); @@ -2250,8 +2305,7 @@ p = optim(p); p = delasgop(p); - walkf(p, prtdcon); - walkf(p, delvoid); + walkf(p, delvoid, 0); #ifdef PCC_DEBUG if (xdebug) { printf("Fulltree:\n"); @@ -2282,26 +2336,28 @@ else sz = sizeof(struct interpass); - ip = isinlining ? permalloc(sz) : tmpalloc(sz); + ip = inlalloc(sz); ip->type = type; ip->lineno = lineno; switch (type) { case IP_NODE: - if (lastloc != PROG) - setloc1(PROG); ip->ip_node = va_arg(ap, NODE *); break; case IP_EPILOG: + if (!isinlining) + defloc(cftnsp); + /* FALLTHROUGH */ case IP_PROLOG: - setloc1(PROG); + inftn = type == IP_PROLOG ? 1 : 0; ipp = (struct interpass_prolog *)ip; - ipp->ipp_regs = va_arg(ap, int); + memset(ipp->ipp_regs, (type == IP_PROLOG)? -1 : 0, + sizeof(ipp->ipp_regs)); ipp->ipp_autos = va_arg(ap, int); ipp->ipp_name = va_arg(ap, char *); ipp->ipp_type = va_arg(ap, TWORD); ipp->ipp_vis = va_arg(ap, int); ip->ip_lbl = va_arg(ap, int); - ipp->ip_tmpnum = tvaloff; + ipp->ip_tmpnum = va_arg(ap, int); ipp->ip_lblnum = crslab; if (type == IP_PROLOG) ipp->ip_lblnum--; @@ -2311,9 +2367,11 @@ break; case IP_ASM: if (blevel == 0) { /* outside function */ - printf("\t%s\n", va_arg(ap, char *)); + printf("\t"); + printf("%s", va_arg(ap, char *)); + printf("\n"); va_end(ap); - lastloc = -1; + defloc(NULL); return; } ip->ip_asm = va_arg(ap, char *); @@ -2322,12 +2380,11 @@ cerror("bad send_passt type %d", type); } va_end(ap); + pass1_lastchance(ip); /* target-specific info */ if (isinlining) inline_addarg(ip); else pass2_compile(ip); - if (type == IP_EPILOG) - lastloc = PROG; } char * @@ -2363,6 +2420,8 @@ SNAM(RSEQ,>>=) SNAM(INCR,++) SNAM(DECR,--) + SNAM(STRING,STRING) + SNAM(SZOF,SIZEOF) default: cerror("bad copst %d", op); } @@ -2375,6 +2434,7 @@ if (op <= MAXOP) return dope[op]; switch (op) { + case STRING: case QUALIFIER: case CLASS: case RB: @@ -2415,6 +2475,7 @@ case DECR: return BITYPE|ASGFLG; } + cerror("cdope missing op %d", op); return 0; /* XXX gcc */ } @@ -2445,7 +2506,45 @@ void plabel(int label) { - setloc1(PROG); reached = 1; /* Will this always be correct? */ send_passt(IP_DEFLAB, label); } + +/* + * Perform integer promotion on node n. + */ +NODE * +intprom(NODE *n) +{ + if ((n->n_type >= CHAR && n->n_type < INT) || n->n_type == BOOL) { + if ((n->n_type == UCHAR && MAX_UCHAR > MAX_INT) || + (n->n_type == USHORT && MAX_USHORT > MAX_INT)) + return makety(n, UNSIGNED, 0, 0, MKSUE(UNSIGNED)); + return makety(n, INT, 0, 0, MKSUE(INT)); + } + return n; +} + +/* + * Return CON/VOL/0, whichever are active for the current type. + */ +int +cqual(TWORD t, TWORD q) +{ + while (ISARY(t)) + t = DECREF(t), q = DECQAL(q); + if (t <= BTMASK) + q <<= TSHIFT; + return q & (CON|VOL); +} + +int crslab = 10; +/* + * Return a number for internal labels. + */ +int +getlab(void) +{ + return crslab++; +} + Index: stabs.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/stabs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/stabs.c -L usr.bin/pcc/ccom/stabs.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/stabs.c +++ usr.bin/pcc/ccom/stabs.c @@ -1,4 +1,4 @@ -/* $Id: stabs.c,v 1.15 2007/09/15 07:37:44 ragge Exp $ */ +/* $Id: stabs.c,v 1.27 2008/12/08 21:39:50 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -39,18 +39,31 @@ #ifdef STABS #include -#include #include #include #define STABHASH 256 #define INTNUM 1 /* internal number of type "int" */ +#undef BIT2BYTE /* from external.h */ #define BIT2BYTE(x) ((x)/SZCHAR) #ifndef STABLBL #error macdefs.h must define STABLBL #endif +/* defines taken from BSD */ +#define N_GSYM 0x20 /* global symbol */ +#define N_FUN 0x24 /* procedure name */ +#define N_LCSYM 0x28 /* bss segment variable */ +#define N_RSYM 0x40 /* register variable */ +#define N_SLINE 0x44 /* text segment line number */ +#define N_SO 0x64 /* main source file name */ +#define N_LSYM 0x80 /* stack variable */ +#define N_SOL 0x84 /* included source file name */ +#define N_PSYM 0xa0 /* parameter variable */ +#define N_LBRAC 0xc0 /* left bracket */ +#define N_RBRAC 0xe0 /* right bracket */ + /* * Local type mapping * Types are defined as a typeword, a dimension pointer (in the case @@ -67,6 +80,7 @@ static int ntypes; static char *curfun; static int stablbl = 10; +extern int inftn; void ptype(char *name, int num, int inhnum, long long min, long long max); struct stabtype *addtype(TWORD, union dimfun *, struct suedef *); @@ -77,7 +91,6 @@ #define MAXPSTR 100 extern int isinlining; -#define savestabs isinlining /* * Output type definitions for the stab debugging format. @@ -109,7 +122,7 @@ ptype("double", ADDTYPE(DOUBLE)->num, INTNUM, 8, 0); ptype("long double", ADDTYPE(LDOUBLE)->num, INTNUM, 12, 0); st = ADDTYPE(VOID); - cprint(savestabs, ".stabs \"void:t%d=r%d\",%d,0,0,0\n", + cprint(0, "\t.stabs \"void:t%d=r%d\",%d,0,0,0\n", st->num, st->num, N_LSYM); } @@ -120,7 +133,7 @@ void ptype(char *name, int num, int inhnum, long long min, long long max) { - cprint(savestabs, ".stabs \"%s:t%d=r%d;%lld;%lld;\",%d,0,0,0", + cprint(0, "\t.stabs \"%s:t%d=r%d;%lld;%lld;\",%d,0,0,0\n", name, num, inhnum, min, max, N_LSYM); } @@ -183,8 +196,16 @@ void stabs_line(int line) { - cprint(savestabs, ".stabn %d,0,%d," STABLBL "-%s", N_SLINE, line, stablbl, curfun); - cprint(1, STABLBL ":", stablbl++); + if (inftn == 0) + return; /* ignore */ +#ifdef STAB_LINE_ABSOLUTE + cprint(1, "\t.stabn %d,0,%d," STABLBL "\n" STABLBL ":\n", + N_SLINE, line, stablbl, stablbl); +#else + cprint(1, "\t.stabn %d,0,%d," STABLBL "-%s\n" STABLBL ":\n", + N_SLINE, line, stablbl, exname(curfun), stablbl); +#endif + stablbl++; } /* @@ -193,9 +214,14 @@ void stabs_lbrac(int blklvl) { - cprint(savestabs, ".stabn %d,0,%d," STABLBL "-%s", - N_LBRAC, blklvl, stablbl, curfun); - cprint(1, STABLBL ":", stablbl++); +#ifdef STAB_LINE_ABSOLUTE + cprint(1, "\t.stabn %d,0,%d," STABLBL "\n" STABLBL ":\n", + N_LBRAC, blklvl, stablbl, stablbl); +#else + cprint(1, "\t.stabn %d,0,%d," STABLBL "-%s\n" STABLBL ":\n", + N_LBRAC, blklvl, stablbl, exname(curfun), stablbl); +#endif + stablbl++; } /* @@ -204,24 +230,40 @@ void stabs_rbrac(int blklvl) { - cprint(savestabs, ".stabn %d,0,%d," STABLBL "-%s\n", - N_RBRAC, blklvl, stablbl, curfun); - cprint(1, STABLBL ":", stablbl++); +#ifdef STAB_LINE_ABSOLUTE + cprint(1, "\t.stabn %d,0,%d," STABLBL "\n" STABLBL ":\n", + N_RBRAC, blklvl, stablbl, stablbl); +#else + cprint(1, "\t.stabn %d,0,%d," STABLBL "-%s\n" STABLBL ":\n", + N_RBRAC, blklvl, stablbl, exname(curfun), stablbl); +#endif + stablbl++; } +static char *mainfile; + /* * Print current file and set mark. */ void stabs_file(char *fname) { - static char *mainfile; - if (mainfile == NULL) mainfile = fname; /* first call */ - cprint(savestabs, ".stabs \"%s\",%d,0,0," STABLBL, - fname, fname == mainfile ? N_SO : N_SOL, stablbl); - cprint(savestabs, STABLBL ":", stablbl++); + cprint(inftn, "\t.stabs \"%s\",%d,0,0," STABLBL "\n" STABLBL ":\n", + fname, fname == mainfile ? N_SO : N_SOL, stablbl, stablbl); + stablbl++; +} + +/* + * Print end mark + */ +void +stabs_efile(char *fname) +{ + cprint(inftn, "\t.stabs \"\",%d,0,0," STABLBL "\n" STABLBL ":\n", + fname == mainfile ? N_SO : N_SOL, stablbl, stablbl); + stablbl++; } /* @@ -232,12 +274,9 @@ { char str[MAXPSTR]; - curfun = s->sname; -#ifdef GCC_COMPAT - curfun = gcc_findname(cftnsp); -#endif + curfun = s->soname; printtype(s, str, sizeof(str)); - cprint(savestabs, ".stabs \"%s:%c%s\",%d,0,%d,%s", + cprint(1, "\t.stabs \"%s:%c%s\",%d,0,%d,%s\n", curfun, s->sclass == STATIC ? 'f' : 'F', str, N_FUN, BIT2BYTE(s->ssue->suesize), exname(curfun)); } @@ -286,8 +325,10 @@ void stabs_newsym(struct symtab *s) { + extern int fun_inline; char *sname; char ostr[MAXPSTR]; + int suesize; if (ISFTN(s->stype)) return; /* functions are handled separate */ @@ -297,43 +338,48 @@ s->sclass == TYPEDEF || (s->sclass & FIELD)) return; /* XXX - fix structs */ - sname = s->sname; -#ifdef GCC_COMPAT - sname = gcc_findname(s); -#endif + sname = s->soname; + suesize = BIT2BYTE(s->ssue->suesize); + if (suesize > 32767) + suesize = 32767; + else if (suesize < -32768) + suesize = -32768; printtype(s, ostr, sizeof(ostr)); switch (s->sclass) { case PARAM: - cprint(savestabs, ".stabs \"%s:p%s\",%d,0,%d,%d", sname, ostr, - N_PSYM, BIT2BYTE(s->ssue->suesize), BIT2BYTE(s->soffset)); + cprint(0, "\t.stabs \"%s:p%s\",%d,0,%d,%d\n", sname, ostr, + N_PSYM, suesize, BIT2BYTE(s->soffset)); break; case AUTO: - cprint(savestabs, ".stabs \"%s:%s\",%d,0,%d,%d", sname, ostr, - N_LSYM, BIT2BYTE(s->ssue->suesize), BIT2BYTE(s->soffset)); + cprint(0, "\t.stabs \"%s:%s\",%d,0,%d,%d\n", sname, ostr, + N_LSYM, suesize, BIT2BYTE(s->soffset)); break; case STATIC: if (blevel) - cprint(savestabs, ".stabs \"%s:V%s\",%d,0,%d," LABFMT, sname, ostr, - N_LCSYM, BIT2BYTE(s->ssue->suesize), s->soffset); + cprint(0, "\t.stabs \"%s:V%s\",%d,0,%d," LABFMT "\n", sname, ostr, + N_LCSYM, suesize, s->soffset); else - cprint(savestabs, ".stabs \"%s:S%s\",%d,0,%d,%s", sname, ostr, - N_LCSYM, BIT2BYTE(s->ssue->suesize), exname(sname)); + cprint(0, "\t.stabs \"%s:S%s\",%d,0,%d,%s\n", sname, ostr, + N_LCSYM, suesize, exname(sname)); break; case EXTERN: case EXTDEF: - cprint(savestabs, ".stabs \"%s:G%s\",%d,0,%d,0", sname, ostr, - N_GSYM, BIT2BYTE(s->ssue->suesize)); + cprint(0, "\t.stabs \"%s:G%s\",%d,0,%d,0\n", sname, ostr, + N_GSYM, suesize); break; case REGISTER: - cprint(savestabs, ".stabs \"%s:r%s\",%d,0,%d,%d", sname, ostr, + cprint(0, "\t.stabs \"%s:r%s\",%d,0,%d,%d\n", sname, ostr, N_RSYM, 1, s->soffset); break; - + case SNULL: + if (fun_inline) + break; + /* FALLTHROUGH */ default: cerror("fix stab_newsym; class %d", s->sclass); } @@ -352,22 +398,54 @@ { } -void +struct stabsv { + SLIST_ENTRY(stabsv) next; + char *str; +} ; +static SLIST_HEAD(, stabsv) stpole = { NULL, &stpole.q_forw }; + +/* + * Global variable debug info is printed out directly. + * For functions and their declarations, both the labels and + * the debug info is put into ASM nodes and follows their statements + * into pass2. + * Due to the possible unsync between pass1 and 2 and where the + * stabs info for text is sent over the following syncing is used: + * curfun == 0 + * print out everything; only data will be. + * curfun != 0 && inftn == 0 + * save in linked list + * curfun != 0 && inftn != 0 + * print linked list first, empty it, then arg. + */ +void cprint(int p2, char *fmt, ...) { - va_list ap; + struct stabsv *w; + va_list ap; char *str; + if (isinlining) + return; /* XXX do not save any inline functions currently */ + va_start(ap, fmt); if (p2) { str = tmpvsprintf(fmt, ap); - str = newstring(str, strlen(str)); /* XXX - for inlines */ - send_passt(IP_ASM, str); - } else { - putchar('\t'); + if (inftn == 0) { + w = tmpalloc(sizeof(struct stabsv)); + w->str = str; + SLIST_INSERT_LAST(&stpole, w, next); + } else { + if (stpole.q_last != &stpole.q_forw) { + SLIST_FOREACH(w, &stpole, next) { + send_passt(IP_ASM, w->str); + } + SLIST_INIT(&stpole); + } + send_passt(IP_ASM, str); + } + } else vprintf(fmt, ap); - putchar('\n'); - } va_end(ap); } Index: symtabs.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/symtabs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/symtabs.c -L usr.bin/pcc/ccom/symtabs.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/symtabs.c +++ usr.bin/pcc/ccom/symtabs.c @@ -1,4 +1,4 @@ -/* $Id: symtabs.c,v 1.14 2006/06/16 09:30:32 ragge Exp $ */ +/* $Id: symtabs.c,v 1.18 2008/06/19 08:05:00 gmcgarry Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -175,15 +175,15 @@ * Returns a struct symtab. */ struct symtab * -lookup(char *key, int ttype) +lookup(char *key, int stype) { struct symtab *sym; struct tree *w, *new, *last; - int cix, bit, fbit, svbit, ix, bitno, match; + int cix, bit, fbit, svbit, bitno; int type, uselvl; + intptr_t ix, match, code = (intptr_t)key; - long code = (long)key; - type = ttype & SMASK; + type = stype & SMASK; uselvl = (blevel > 0 && type != SSTRING); /* @@ -197,15 +197,15 @@ switch (numsyms[type]) { case 0: - if (ttype & SNOCREAT) + if (stype & SNOCREAT) return NULL; if (uselvl) { - sym = getsymtab(key, ttype|STEMP); + sym = getsymtab(key, stype|STEMP); sym->snext = tmpsyms[type]; tmpsyms[type] = sym; return sym; } - sympole[type] = (struct tree *)getsymtab(key, ttype); + sympole[type] = (struct tree *)getsymtab(key, stype); numsyms[type]++; return (struct symtab *)sympole[type]; @@ -228,12 +228,12 @@ } sym = (struct symtab *)w; - match = (long)sym->sname; + match = (intptr_t)sym->sname; ix = code ^ match; if (ix == 0) return sym; - else if (ttype & SNOCREAT) + else if (stype & SNOCREAT) return NULL; #ifdef PCC_DEBUG @@ -246,7 +246,7 @@ * Insert into the linked list, if feasible. */ if (uselvl) { - sym = getsymtab(key, ttype|STEMP); + sym = getsymtab(key, stype|STEMP); sym->snext = tmpsyms[type]; tmpsyms[type] = sym; return sym; @@ -258,17 +258,17 @@ * This could be optimized by adding a remove routine, but it * may be more trouble than it is worth. */ - if (ttype == (STEMP|SNORMAL)) - ttype = SNORMAL; + if (stype == (STEMP|SNORMAL)) + stype = SNORMAL; for (cix = 0; (ix & 1) == 0; ix >>= 1, cix++) ; - new = ttype & STEMP ? tmpalloc(sizeof(struct tree)) : + new = stype & STEMP ? tmpalloc(sizeof(struct tree)) : permalloc(sizeof(struct tree)); bit = (code >> cix) & 1; new->bitno = cix | (bit ? RIGHT_IS_LEAF : LEFT_IS_LEAF); - new->lr[bit] = (struct tree *)getsymtab(key, ttype); + new->lr[bit] = (struct tree *)getsymtab(key, stype); if (numsyms[type]++ == 1) { new->lr[!bit] = sympole[type]; new->bitno |= (bit ? LEFT_IS_LEAF : RIGHT_IS_LEAF); @@ -343,10 +343,15 @@ hide(struct symtab *sym) { struct symtab *new; + int typ = sym->sflags & SMASK; + + new = getsymtab(sym->sname, typ|STEMP); + new->snext = tmpsyms[typ]; + tmpsyms[typ] = new; + + if (Wshadow) + werror("declaration of '%s' shadows previous", sym->sname); - new = getsymtab(sym->sname, SNORMAL|STEMP); - new->snext = tmpsyms[SNORMAL]; - tmpsyms[SNORMAL] = new; #ifdef PCC_DEBUG if (ddebug) printf("\t%s hidden at level %d (%p -> %p)\n", Index: optim.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/optim.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccom/optim.c -L usr.bin/pcc/ccom/optim.c -u -r1.1 -r1.2 --- usr.bin/pcc/ccom/optim.c +++ usr.bin/pcc/ccom/optim.c @@ -1,4 +1,4 @@ -/* $Id: optim.c,v 1.28 2006/07/11 07:54:29 ragge Exp $ */ +/* $Id: optim.c,v 1.32 2008/10/27 21:13:20 ragge Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -43,8 +43,6 @@ # define LO(p) p->n_left->n_op # define LV(p) p->n_left->n_lval -static int nncon(NODE *); - int oflag = 0; /* remove left node */ @@ -92,7 +90,7 @@ int i; TWORD t; - if( (t=BTYPE(p->n_type))==ENUMTY || t==MOETY ) econvert(p); + t = BTYPE(p->n_type); if( oflag ) return(p); ty = coptype(p->n_op); @@ -137,7 +135,8 @@ goto setuleft; case RS: - if (LO(p) == RS && RCON(p->n_left) && RCON(p)) { + if (LO(p) == RS && RCON(p->n_left) && RCON(p) && + (RV(p) + RV(p->n_left)) < p->n_sue->suesize) { /* two right-shift by constants */ RV(p) += RV(p->n_left); p->n_left = zapleft(p->n_left); @@ -334,7 +333,21 @@ p->n_op = revrel[p->n_op - EQ ]; break; +#ifdef notyet + case ASSIGN: + /* Simple test to avoid two branches */ + if (RO(p) != NE) + break; + q = p->n_right; + if (RCON(q) && RV(q) == 0 && LO(q) == AND && + RCON(q->n_left) && (i = ispow2(RV(q->n_left))) && + q->n_left->n_type == INT) { + q->n_op = RS; + RV(q) = i; } + break; +#endif + } return(p); } Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccom/Makefile,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/ccom/Makefile -L usr.bin/pcc/ccom/Makefile -u -r1.2 -r1.3 --- usr.bin/pcc/ccom/Makefile +++ usr.bin/pcc/ccom/Makefile @@ -14,8 +14,8 @@ CFLAGS+= -Dmach_${TARGMACH} CFLAGS+= -DPCC_DEBUG -DGCC_COMPAT CFLAGS+= -Wall -Wmissing-prototypes -Wstrict-prototypes -Werror -CFLAGS+= -I. -I${.CURDIR}/.. -I${.CURDIR} -I${.CURDIR}/../mip -CFLAGS+= -I${.CURDIR}/../${TARGMACH} +CFLAGS+= -I. -I${.CURDIR}/.. -I${.CURDIR} +CFLAGS+= -I${.CURDIR}/../${TARGMACH} -I${.CURDIR}/../mip .PATH: ${.CURDIR}/../${TARGMACH} .PATH: ${.CURDIR}/../mip Index: scanner.l =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/scanner.l,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/cpp/scanner.l -L usr.bin/pcc/cpp/scanner.l -u -r1.1 -r1.2 --- usr.bin/pcc/cpp/scanner.l +++ usr.bin/pcc/cpp/scanner.l @@ -1,5 +1,5 @@ %{ -/* $Id: scanner.l,v 1.20 2007/09/25 20:41:07 ragge Exp $ */ +/* $Id: scanner.l,v 1.48 2008/08/21 16:32:40 ragge Exp $ */ /* * Copyright (c) 2004 Anders Magnusson. All rights reserved. @@ -27,19 +27,25 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#include "config.h" + #include #include #include +#ifdef HAVE_UNISTD_H #include +#endif #include +#include +#include "compat.h" #include "cpp.h" #include "y.tab.h" %} %{ -static long long cvtdig(int rad); -static int charcon(void); +static void cvtdig(int rad); +static int charcon(usch *); static void elsestmt(void); static void ifdefstmt(void); static void ifndefstmt(void); @@ -50,8 +56,8 @@ static void undefstmt(void); static void cpperror(void); static void elifstmt(void); -//static void linestmt(void); static void storepb(void); +static void badop(const char *); void include(void); void define(void); @@ -82,15 +88,17 @@ } #undef YY_INPUT #undef YY_BUF_SIZE -#define YY_BUF_SIZE 32768 +#define YY_BUF_SIZE (8*65536) #define YY_INPUT(b,r,m) (r = yyinput(b, m)) +#ifdef HAVE_CPP_VARARG_MACRO_GCC #define fprintf(x, ...) error(__VA_ARGS__) +#endif #define ECHO putstr((usch *)yytext) #undef fileno #define fileno(x) 0 #if YY_FLEX_SUBMINOR_VERSION >= 31 -/* Hack to avoid unneccessary warnings */ +/* Hack to avoid unnecessary warnings */ FILE *yyget_in (void); FILE *yyget_out (void); int yyget_leng (void); @@ -108,6 +116,9 @@ #define unput(ch) unch(ch) #endif #define PRTOUT(x) if (YYSTATE || slow) return x; if (!flslvl) putstr((usch *)yytext); +/* protection against recursion in #include */ +#define MAX_INCLEVEL 100 +static int inclevel; %} D [0-9] @@ -118,7 +129,7 @@ IS (u|U|l|L)* WS [\t ] -%s IFR CONTR DEF +%s IFR CONTR DEF COMMENT %% @@ -139,6 +150,8 @@ "\r" { ; /* Ignore CR's */ } +"++" { badop("++"); } +"--" { badop("--"); } "==" { return EQ; } "!=" { return NE; } "<=" { return LE; } @@ -160,28 +173,41 @@ {WS}+ { ; } {L}({L}|{D})* { + yylval.node.op = NUMBER; if (gotdef) { - yylval.val = - lookup((usch *)yytext, FIND) != 0; + yylval.node.nd_val + = lookup((usch *)yytext, FIND) != 0; gotdef = 0; return IDENT; } - yylval.val = 0; + yylval.node.nd_val = 0; return NUMBER; } -[1-9][0-9]* { if (slow && !YYSTATE) return IDENT; scale = 10; goto num; } +[0-9][0-9]* { + if (slow && !YYSTATE) + return IDENT; + scale = yytext[0] == '0' ? 8 : 10; + goto num; + } 0[xX]{H}+{IS}? { scale = 16; - num: if (YYSTATE) - yylval.val = cvtdig(scale); + num: if (YYSTATE == IFR) + cvtdig(scale); PRTOUT(NUMBER); } 0{D}+{IS}? { scale = 8; goto num; } {D}+{IS}? { scale = 10; goto num; } -L?'(\\.|[^\\'])+' { if (YYSTATE) - yylval.val = charcon(); - PRTOUT(NUMBER); +'(\\.|[^\\'])+' { + if (YYSTATE || slow) { + yylval.node.op = NUMBER; + yylval.node.nd_val = charcon((usch *)yytext); + return (NUMBER); + } + if (tflag) + yyless(1); + if (!flslvl) + putstr((usch *)yytext); } . { return yytext[0]; } @@ -190,7 +216,14 @@ {D}*"."{D}+({E})?{FS}? { PRTOUT(FPOINT); } {D}+"."{D}*({E})?{FS}? { PRTOUT(FPOINT); } -^{WS}*#{WS}* { contr = 1; BEGIN CONTR; } +^{WS}*#{WS}* { extern int inmac; + + if (inmac) + error("preprocessor directive found " + "while expanding macro"); + contr = 1; + BEGIN CONTR; + } {WS}+ { PRTOUT(WSPACE); } "ifndef" { contr = 0; ifndefstmt(); } @@ -203,19 +236,25 @@ "define" { contr = 0; BEGIN DEF; define(); BEGIN 0; } "undef" { contr = 0; if (slow) return IDENT; undefstmt(); } "line" { contr = 0; storepb(); BEGIN 0; line(); } -"pragma" { contr = 0; pragmastmt(); } +"pragma" { contr = 0; pragmastmt(); BEGIN 0; } "elif" { contr = 0; storepb(); BEGIN IFR; elifstmt(); BEGIN 0; } "//".*$ { /* if (tflag) yyless(..) */ - if (Cflag) + if (Cflag && !flslvl && !slow) putstr((usch *)yytext); else if (!flslvl) putch(' '); } "/*" { int c, wrn; - if (Cflag) + int prtcm = Cflag && !flslvl && !slow; + extern int readmac; + + if (Cflag && !flslvl && readmac) + return CMNT; + + if (prtcm) putstr((usch *)yytext); wrn = 0; more: while ((c = input()) && c != '*') { @@ -223,20 +262,18 @@ putch(c), ifiles->lineno++; else if (c == 1) /* WARN */ wrn = 1; - else if (Cflag) + else if (prtcm) putch(c); } if (c == 0) return 0; - if (Cflag) + if (prtcm) putch(c); if ((c = input()) && c != '/') { - if (Cflag) - putch('*'); unput(c); goto more; } - if (Cflag) + if (prtcm) putch(c); if (c == 0) return 0; @@ -280,7 +317,31 @@ xx: ; } -. { PRTOUT(yytext[0]); } +. { + if (contr) { + while (input() != '\n') + ; + unput('\n'); + BEGIN 0; + contr = 0; + goto yy; + } + if (YYSTATE || slow) + return yytext[0]; + if (yytext[0] == 6) { /* PRAGS */ + usch *obp = stringbuf; + extern usch *prtprag(usch *); + *stringbuf++ = yytext[0]; + do { + *stringbuf = input(); + } while (*stringbuf++ != 14); + prtprag(obp); + stringbuf = obp; + } else { + PRTOUT(yytext[0]); + } + yy:; + } %% @@ -393,25 +454,26 @@ /* * A new file included. * If ifiles == NULL, this is the first file and already opened (stdin). - * Return 0 on success, -1 on failure to open file. + * Return 0 on success, -1 if file to be included is not found. */ int pushfile(usch *file) { extern struct initar *initar; struct includ ibuf; - struct includ *old; struct includ *ic; int c, otrulvl; ic = &ibuf; - old = ifiles; + ic->next = ifiles; slow = 0; if (file != NULL) { if ((ic->infil = open((char *)file, O_RDONLY)) < 0) return -1; ic->orgfn = ic->fname = file; + if (++inclevel > MAX_INCLEVEL) + error("Limit for nested includes exceeded"); } else { ic->infil = 0; ic->orgfn = ic->fname = (usch *)""; @@ -438,8 +500,9 @@ if (otrulvl != trulvl || flslvl) error("unterminated conditional"); - ifiles = old; + ifiles = ic->next; close(ic->infil); + inclevel--; return 0; } @@ -458,7 +521,7 @@ s = sheap("%s: %s\n", Mfile, ifiles->fname); write(ofd, s, strlen((char *)s)); } - } else + } else if (!Pflag) putstr(sheap("# %d \"%s\"\n", ifiles->lineno, ifiles->fname)); stringbuf = os; } @@ -468,7 +531,7 @@ { #ifdef CPP_DEBUG extern int dflag; - if (dflag)printf(": '%c'(%d)", c, c); + if (dflag)printf(": '%c'(%d)", c > 31 ? c : ' ', c); #endif unput(c); } @@ -488,13 +551,13 @@ } /* - * Convert some string numbers to long long. - * Do not care about UL trailers, should we? + * Convert string numbers to unsigned long long and check overflow. */ -static long long +static void cvtdig(int rad) { - long long rv = 0; + unsigned long long rv = 0; + unsigned long long rv2 = 0; char *y = yytext; int c; @@ -503,20 +566,30 @@ y++; while (isxdigit(c)) { rv = rv * rad + dig2num(c); + /* check overflow */ + if (rv / rad < rv2) + error("Constant \"%s\" is out of range", yytext); + rv2 = rv; c = *y++; } - return rv; + y--; + while (*y == 'l' || *y == 'L') + y++; + yylval.node.op = *y == 'u' || *y == 'U' ? UNUMBER : NUMBER; + yylval.node.nd_uval = rv; + if ((rad == 8 || rad == 16) && yylval.node.nd_val < 0) + yylval.node.op = UNUMBER; + if (yylval.node.op == NUMBER && yylval.node.nd_val < 0) + /* too large for signed */ + error("Constant \"%s\" is out of range", yytext); } static int -charcon(void) +charcon(usch *p) { - usch *p = (usch *)yytext; int val, c; - if (*p == 'L') - p++; - p++; /* first ' */ + p++; /* skip first ' */ val = 0; if (*p++ == '\\') { switch (*p++) { @@ -553,14 +626,24 @@ } static void -chknl(void) +chknl(int ignore) { int t; + slow = 1; while ((t = yylex()) == WSPACE) ; - if (t != '\n') - error("newline expected, got %d", t); + if (t != '\n') { + if (ignore) { + warning("newline expected, got \"%s\"", yytext); + /* ignore rest of line */ + while ((t = yylex()) && t != '\n') + ; + } + else + error("newline expected, got \"%s\"", yytext); + } + slow = 0; } static void @@ -583,12 +666,14 @@ if (elslvl==trulvl+flslvl) error("Too many else"); elslvl=trulvl+flslvl; - chknl(); + chknl(1); } static void ifdefstmt(void) { + int t; + if (flslvl) { /* just ignore the rest of the line */ while (input() != '\n') @@ -599,28 +684,36 @@ return; } slow = 1; - if (yylex() != WSPACE || yylex() != IDENT) + do + t = yylex(); + while (t == WSPACE); + if (t != IDENT) error("bad ifdef"); slow = 0; if (flslvl == 0 && lookup((usch *)yytext, FIND) != 0) trulvl++; else flslvl++; - chknl(); + chknl(0); } static void ifndefstmt(void) { + int t; + slow = 1; - if (yylex() != WSPACE || yylex() != IDENT) + do + t = yylex(); + while (t == WSPACE); + if (t != IDENT) error("bad ifndef"); slow = 0; if (flslvl == 0 && lookup((usch *)yytext, FIND) == 0) trulvl++; else flslvl++; - chknl(); + chknl(0); } static void @@ -637,7 +730,7 @@ if (flslvl == 0) elflvl = 0; elslvl = 0; - chknl(); + chknl(1); } /* @@ -694,8 +787,24 @@ usch *opb = stringbuf; int c; - while ((c = input()) != '\n') + while ((c = input()) != '\n') { + if (c == '/') { + if ((c = input()) == '*') { + /* ignore comments here whatsoever */ + usch *g = stringbuf; + getcmnt(); + stringbuf = g; + continue; + } else if (c == '/') { + while ((c = input()) && c != '\n') + ; + break; + } + unput(c); + c = '/'; + } savch(c); + } cunput('\n'); savch(0); fixdefined(opb); /* XXX can fail if #line? */ @@ -779,7 +888,7 @@ if (flslvl) stringbuf = cp; else - error("error: %s", cp); + error("%s", cp); } static void @@ -793,7 +902,7 @@ if (flslvl == 0 && (np = lookup((usch *)yytext, FIND))) np->value = 0; slow = 0; - chknl(); + chknl(0); } static void @@ -804,11 +913,26 @@ slow = 1; if (yylex() != WSPACE) error("bad pragma"); - putstr((usch *)"#pragma "); + if (!flslvl) + putstr((usch *)"#pragma "); do { - putch(c = input()); /* Do arg expansion instead? */ + c = input(); + if (!flslvl) + putch(c); /* Do arg expansion instead? */ } while (c && c != '\n'); ifiles->lineno++; prtline(); slow = 0; } + +static void +badop(const char *op) +{ + error("invalid operator in preprocessor expression: %s", op); +} + +int +cinput() +{ + return input(); +} Index: token.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/token.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/cpp/token.c -L usr.bin/pcc/cpp/token.c -u -r1.1 -r1.2 --- usr.bin/pcc/cpp/token.c +++ usr.bin/pcc/cpp/token.c @@ -1,4 +1,4 @@ -/* $Id: token.c,v 1.11 2006/09/28 11:10:08 ragge Exp $ */ +/* $Id: token.c,v 1.12 2008/04/15 09:54:23 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson. All rights reserved. @@ -35,17 +35,7 @@ #include "cpp.h" /* definition for include file info */ -struct includ { - struct includ *next; - char *fname; - int lineno; - int infil; - usch *curptr; - usch *maxread; - usch *ostr; - usch *buffer; - usch bbuf[NAMEMAX+CPPBUF+1]; -} *ifiles; +struct includ *ifiles; usch *yyp, *yystr, yybuf[CPPBUF]; Index: cpp.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/cpp.c,v retrieving revision 1.3 retrieving revision 1.4 diff -L usr.bin/pcc/cpp/cpp.c -L usr.bin/pcc/cpp/cpp.c -u -r1.3 -r1.4 --- usr.bin/pcc/cpp/cpp.c +++ usr.bin/pcc/cpp/cpp.c @@ -1,4 +1,4 @@ -/* $Id: cpp.c,v 1.65 2007/09/25 20:41:08 ragge Exp $ */ +/* $Id: cpp.c,v 1.95 2008/12/07 20:12:05 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -66,24 +66,24 @@ * from V7 cpp, and at last ansi/c99 support. */ -#include "../config.h" +#include "config.h" +#ifdef HAVE_SYS_WAIT_H #include +#endif #include +#ifdef HAVE_UNISTD_H #include +#endif #include #include #include #include #include -#include #include -#ifdef HAVE_ALLOCA_H -#include -#endif - +#include "compat.h" #include "cpp.h" #include "y.tab.h" @@ -103,12 +103,15 @@ #define DDPRINT(x) #endif +#define GCC_VARI + int ofd; usch outbuf[CPPBUF]; -int obufp, istty; -int Cflag, Mflag, dMflag; +int obufp, istty, inmac; +int Cflag, Mflag, dMflag, Pflag; usch *Mfile; struct initar *initar; +int readmac; /* avoid recursion */ struct recur { @@ -149,6 +152,7 @@ * 1-> - number of args. */ +#define GCCARG 0xfd /* has gcc varargs that may be replaced with 0 */ #define VARG 0xfe /* has varargs */ #define OBJCT 0xff #define WARN 1 /* SOH, not legal char */ @@ -156,6 +160,8 @@ #define SNUFF 3 /* ETX, not legal char */ #define NOEXP 4 /* EOT, not legal char */ #define EXPAND 5 /* ENQ, not legal char */ +#define PRAGS 6 /* start of converted pragma */ +#define PRAGE 14 /* end of converted pragma */ /* args for lookup() */ #define FIND 0 @@ -168,6 +174,9 @@ void line(void); void flbuf(void); void usage(void); +usch *xstrdup(char *str); +usch *prtprag(usch *opb); + int main(int argc, char **argv) @@ -177,7 +186,13 @@ struct symtab *nl; register int ch; - while ((ch = getopt(argc, argv, "CD:I:MS:U:d:i:tvV?")) != -1) +#ifdef TIMING + struct timeval t1, t2; + + (void)gettimeofday(&t1, NULL); +#endif + + while ((ch = getopt(argc, argv, "CD:I:MPS:U:d:i:tvV?")) != -1) switch (ch) { case 'C': /* Do not discard comments */ Cflag++; @@ -199,6 +214,10 @@ Mflag++; break; + case 'P': /* Inhibit generation of line numbers */ + Pflag++; + break; + case 'S': case 'I': if ((w = calloc(sizeof(struct incs), 1)) == NULL) @@ -219,7 +238,7 @@ break; #endif case 'v': - printf("pcpp: %s\n", VERSSTR); + printf("cpp: %s\n", VERSSTR); break; case 'd': if (optarg[0] == 'M') { @@ -267,6 +286,10 @@ nl = lookup((usch *)"__STDC__", ENTER); savch(0); savch('1'); savch(OBJCT); nl->value = stringbuf-1; + + nl = lookup((usch *)"__STDC_VERSION__", ENTER); + savch(0); savstr((usch *)"199901L"); savch(OBJCT); + nl->value = stringbuf-1; } if (Mflag && !dMflag) { @@ -298,6 +321,17 @@ flbuf(); close(ofd); +#ifdef TIMING + (void)gettimeofday(&t2, NULL); + t2.tv_sec -= t1.tv_sec; + t2.tv_usec -= t1.tv_usec; + if (t2.tv_usec < 0) { + t2.tv_usec += 1000000; + t2.tv_sec -= 1; + } + fprintf(stderr, "cpp total time: %ld s %ld us\n", + t2.tv_sec, t2.tv_usec); +#endif return 0; } @@ -315,6 +349,7 @@ thisnl = NULL; slow = 1; + readmac++; base = osp = stringbuf; goto found; @@ -377,6 +412,10 @@ thisnl = NULL; break; + case CMNT: + getcmnt(); + break; + case STRING: case '\n': case NUMBER: @@ -394,11 +433,12 @@ } if (thisnl == NULL) { slow = 0; + readmac--; savch(0); return base; } } - error("preamture EOF"); + error("premature EOF"); /* NOTREACHED */ return NULL; /* XXX gcc */ } @@ -423,7 +463,7 @@ slow = 0; return; } - if (yylex() != STRING) + if (yylex() != STRING || yytext[0] == 'L') goto bad; c = strlen((char *)yytext); if (llen < c) { @@ -550,6 +590,55 @@ } void +getcmnt(void) +{ + int c; + + savstr((usch *)yytext); + for (;;) { + c = cinput(); + if (c == '*') { + c = cinput(); + if (c == '/') { + savstr((usch *)"*/"); + return; + } + cunput(c); + c = '*'; + } + savch(c); + } +} + +/* + * Compare two replacement lists, taking in account comments etc. + */ +static int +cmprepl(usch *o, usch *n) +{ + for (; *o; o--, n--) { + /* comment skip */ + if (*o == '/' && o[-1] == '*') { + while (*o != '*' || o[-1] != '/') + o--; + o -= 2; + } + if (*n == '/' && n[-1] == '*') { + while (*n != '*' || n[-1] != '/') + n--; + n -= 2; + } + while (*o == ' ' || *o == '\t') + o--; + while (*n == ' ' || *n == '\t') + n--; + if (*o != *n) + return 1; + } + return 0; +} + +void define() { struct symtab *np; @@ -557,7 +646,10 @@ int c, i, redef; int mkstr = 0, narg = -1; int ellips = 0; - int len; +#ifdef GCC_VARI + usch *gccvari = NULL; + int wascon; +#endif if (flslvl) return; @@ -571,12 +663,13 @@ np = lookup((usch *)yytext, ENTER); redef = np->value != NULL; + readmac = 1; sbeg = stringbuf; if ((c = yylex()) == '(') { narg = 0; /* function-like macros, deal with identifiers */ + c = definp(); for (;;) { - c = definp(); if (c == ')') break; if (c == ELLIPS) { @@ -586,15 +679,27 @@ break; } if (c == IDENT) { - len = strlen(yytext); - args[narg] = alloca(len+1); - strlcpy((char *)args[narg], yytext, len+1); - narg++; - if ((c = definp()) == ',') + /* make sure there is no arg of same name */ + for (i = 0; i < narg; i++) + if (!strcmp((char *) args[i], yytext)) + error("Duplicate macro " + "parameter \"%s\"", yytext); + args[narg++] = xstrdup(yytext); + if ((c = definp()) == ',') { + if ((c = definp()) == ')') + goto bad; continue; + } +#ifdef GCC_VARI + if (c == ELLIPS) { + if (definp() != ')') + goto bad; + gccvari = args[--narg]; + break; + } +#endif if (c == ')') break; - goto bad; } goto bad; } @@ -608,9 +713,17 @@ while (c == WSPACE) c = yylex(); + /* replacement list cannot start with ## operator */ + if (c == CONCAT) + goto bad; + /* parse replacement-list, substituting arguments */ savch('\0'); while (c != '\n') { +#ifdef GCC_VARI + wascon = 0; +loop: +#endif switch (c) { case WSPACE: /* remove spaces if it surrounds a ## directive */ @@ -622,6 +735,12 @@ savch(CONC); if ((c = yylex()) == WSPACE) c = yylex(); +#ifdef GCC_VARI + if (c == '\n') + break; + wascon = 1; + goto loop; +#endif } continue; @@ -630,7 +749,14 @@ savch(CONC); if ((c = yylex()) == WSPACE) c = yylex(); +#ifdef GCC_VARI + if (c == '\n') + break; + wascon = 1; + goto loop; +#else continue; +#endif case MKSTR: if (narg < 0) { @@ -655,6 +781,16 @@ if (strcmp(yytext, (char *)args[i]) == 0) break; if (i == narg) { +#ifdef GCC_VARI + if (gccvari && + strcmp(yytext, (char *)gccvari) == 0) { + savch(wascon ? GCCARG : VARG); + savch(WARN); + if (mkstr) + savch(SNUFF), mkstr = 0; + break; + } +#endif if (mkstr) error("not argument"); goto id; @@ -674,31 +810,40 @@ savch(SNUFF), mkstr = 0; break; + case CMNT: /* save comments */ + getcmnt(); + break; + default: id: savstr((usch *)yytext); break; } c = yylex(); } + readmac = 0; /* remove trailing whitespace */ while (stringbuf > sbeg) { if (stringbuf[-1] == ' ' || stringbuf[-1] == '\t') stringbuf--; + /* replacement list cannot end with ## operator */ + else if (stringbuf[-1] == CONC) + goto bad; else break; } +#ifdef GCC_VARI + if (gccvari) { + savch(narg); + savch(VARG); + } else +#endif if (ellips) { savch(narg); savch(VARG); } else savch(narg < 0 ? OBJCT : narg); if (redef) { - usch *o = np->value, *n = stringbuf-1; - - /* Redefinition to identical replacement-list is allowed */ - while (*o && *o == *n) - o--, n--; - if (*o || *o != *n) + if (cmprepl(np->value, stringbuf-1)) error("%s redefined\nprevious define: %s:%d", np->namep, np->file, np->line); stringbuf = sbeg; /* forget this space */ @@ -726,12 +871,31 @@ } #endif slow = 0; + for (i = 0; i < narg; i++) + free(args[i]); return; bad: error("bad define"); } void +xwarning(usch *s) +{ + usch *t; + usch *sb = stringbuf; + + flbuf(); + savch(0); + if (ifiles != NULL) { + t = sheap("%s:%d: warning: ", ifiles->fname, ifiles->lineno); + write (2, t, strlen((char *)t)); + } + write (2, s, strlen((char *)s)); + write (2, "\n", 1); + stringbuf = sb; +} + +void xerror(usch *s) { usch *t; @@ -739,7 +903,7 @@ flbuf(); savch(0); if (ifiles != NULL) { - t = sheap("%s:%d: ", ifiles->fname, ifiles->lineno); + t = sheap("%s:%d: error: ", ifiles->fname, ifiles->lineno); write (2, t, strlen((char *)t)); } write (2, s, strlen((char *)s)); @@ -751,7 +915,7 @@ * store a character into the "define" buffer. */ void -savch(c) +savch(int c) { if (stringbuf-sbf < SBSIZE) { *stringbuf++ = c; @@ -768,10 +932,9 @@ pragoper(void) { usch *opb; - int t; + int t, plev; - slow = 1; - putstr((usch *)"\n#pragma "); + slow++; if ((t = yylex()) == WSPACE) t = yylex(); if (t != '(') @@ -779,29 +942,37 @@ if ((t = yylex()) == WSPACE) t = yylex(); opb = stringbuf; - while (t != ')') { + for (plev = 0; ; t = yylex()) { + if (t == '(') + plev++; + if (t == ')') + plev--; + if (plev < 0) + break; savstr((usch *)yytext); - t = yylex(); } + savch(0); cunput(WARN); unpstr(opb); stringbuf = opb; expmac(NULL); + cunput('\n'); while (stringbuf > opb) cunput(*--stringbuf); - if ((t = yylex()) != STRING) - goto bad; - opb = (usch *)yytext; - if (*opb++ == 'L') - opb++; - while ((t = *opb++) != '\"') { - if (t == '\\' && (*opb == '\"' || *opb == '\\')) - t = *opb++; - putch(t); + savch(PRAGS); + while ((t = yylex()) != '\n') { + if (t == WSPACE) + continue; + if (t != STRING) + goto bad; + savstr((usch *)yytext); } - putch('\n'); - prtline(); + + savch(PRAGE); + while (stringbuf > opb) + cunput(*--stringbuf); + slow--; return; bad: error("bad pragma operator"); } @@ -815,8 +986,8 @@ struct recur *rp; { struct recur rp2; - register usch *vp, *cp; - int c, rv = 0, ws; + register usch *vp, *cp, *obp; + int c, nl; DPRINT(("subst: %s\n", sp->namep)); /* @@ -842,40 +1013,36 @@ /* should we be here at all? */ /* check if identifier is followed by parentheses */ - rv = 1; - ws = 0; + + obp = stringbuf; + nl = 0; do { - c = yylex(); + c = cinput(); + *stringbuf++ = c; if (c == WARN) { gotwarn++; if (rp == NULL) - goto noid; - } else if (c == WSPACE || c == '\n') - ws = 1; - } while (c == WSPACE || c == '\n' || c == WARN); - - cp = (usch *)yytext; - while (*cp) - cp++; - while (cp > (usch *)yytext) - cunput(*--cp); + break; + } + if (c == '\n') + nl++; + } while (c == ' ' || c == '\t' || c == '\n' || + c == '\r' || c == WARN); + DPRINT(("c %d\n", c)); if (c == '(' ) { + cunput(c); + stringbuf = obp; + ifiles->lineno += nl; expdef(vp, &rp2, gotwarn); - return rv; + return 1; } else { - /* restore identifier */ -noid: while (gotwarn--) - cunput(WARN); - if (ws) - cunput(' '); - cp = sp->namep; - while (*cp) - cp++; - while (cp > sp->namep) - cunput(*--cp); + *stringbuf = 0; + unpstr(obp); + unpstr(sp->namep); if ((c = yylex()) != IDENT) error("internal sync error"); + stringbuf = obp; return 0; } } else { @@ -903,18 +1070,18 @@ struct symtab *nl; int c, noexp = 0, orgexp; usch *och, *stksv; - extern int yyleng; #ifdef CPP_DEBUG if (dflag) { struct recur *rp2 = rp; printf("\nexpmac\n"); while (rp2) { - printf("do not expand %s\n", rp->sp->namep); + printf("do not expand %s\n", rp2->sp->namep); rp2 = rp2->next; } } #endif + readmac++; while ((c = yylex()) != WARN) { switch (c) { case NOEXP: noexp++; break; @@ -940,7 +1107,8 @@ else orgexp++; - DDPRINT(("id1: noexp %d orgexp %d\n", noexp, orgexp)); + DDPRINT(("id1: typ %d noexp %d orgexp %d\n", + c, noexp, orgexp)); if (c == IDENT) { /* XXX numbers? */ DDPRINT(("id2: str %s\n", yytext)); /* OK to always expand here? */ @@ -974,6 +1142,8 @@ unpstr((usch *)yytext); if (orgexp == -1) cunput(EXPAND); + else if (orgexp == -2) + cunput(EXPAND), cunput(EXPAND); else if (orgexp == 1) cunput(NOEXP); unpstr(och); @@ -1004,8 +1174,7 @@ error("bad noexp %d", noexp); stksv = NULL; if ((c = yylex()) == WSPACE) { - stksv = alloca(yyleng+1); - strlcpy((char *)stksv, yytext, yyleng+1); + stksv = xstrdup(yytext); c = yylex(); } /* only valid for expansion if fun macro */ @@ -1022,6 +1191,12 @@ unpstr(stksv); savstr(nl->namep); } + if (stksv) + free(stksv); + break; + + case CMNT: + getcmnt(); break; case STRING: @@ -1043,6 +1218,7 @@ } if (noexp) error("expmac noexp=%d", noexp); + readmac--; DPRINT(("return from expmac\n")); } @@ -1053,34 +1229,40 @@ * result is written on top of heap */ void -expdef(vp, rp, gotwarn) - usch *vp; - struct recur *rp; +expdef(usch *vp, struct recur *rp, int gotwarn) { usch **args, *sptr, *ap, *bp, *sp; int narg, c, i, plev, snuff, instr; int ellips = 0; - DPRINT(("expdef %s rp %s\n", vp, (rp ? (char *)rp->sp->namep : ""))); + DPRINT(("expdef rp %s\n", (rp ? (char *)rp->sp->namep : ""))); if ((c = yylex()) != '(') - error("got %c, expected )", c); + error("got %c, expected (", c); if (vp[1] == VARG) { narg = *vp--; ellips = 1; } else narg = vp[1]; - args = alloca(sizeof(usch *) * (narg+ellips)); + if ((args = malloc(sizeof(usch *) * (narg+ellips))) == NULL) + error("expdef: out of mem"); /* * read arguments and store them on heap. * will be removed just before return from this function. */ + inmac = 1; sptr = stringbuf; + instr = 0; for (i = 0; i < narg && c != ')'; i++) { args[i] = stringbuf; plev = 0; while ((c = yylex()) == WSPACE || c == '\n') ; + DDPRINT((":AAA (%d)", c)); + if (instr == -1) + savch(NOEXP), instr = 1; + if (c == NOEXP) + instr = 1; for (;;) { if (plev == 0 && (c == ')' || c == ',')) break; @@ -1091,10 +1273,20 @@ savstr((usch *)yytext); while ((c = yylex()) == '\n') savch('\n'); + while (c == CMNT) { + getcmnt(); + c = yylex(); + } + if (c == EXPAND) + instr = 0; + if (c == 0) + error("eof in macro"); } while (args[i] < stringbuf && (stringbuf[-1] == ' ' || stringbuf[-1] == '\t')) stringbuf--; + if (instr == 1) + savch(EXPAND), instr = -1; savch('\0'); } if (ellips) @@ -1102,8 +1294,12 @@ if (ellips && c != ')') { args[i] = stringbuf; plev = 0; + instr = 0; while ((c = yylex()) == WSPACE) ; + if (c == NOEXP) + instr++; + DDPRINT((":AAY (%d)", c)); for (;;) { if (plev == 0 && c == ')') break; @@ -1111,9 +1307,16 @@ plev++; if (c == ')') plev--; - savstr((usch *)yytext); + if (plev == 0 && c == ',' && instr) { + savch(EXPAND); + savch(','); + savch(NOEXP); + } else + savstr((usch *)yytext); while ((c = yylex()) == '\n') savch('\n'); + if (c == EXPAND) + instr--; } while (args[i] < stringbuf && (stringbuf[-1] == ' ' || stringbuf[-1] == '\t')) @@ -1122,10 +1325,13 @@ } if (narg == 0 && ellips == 0) - c = yylex(); + while ((c = yylex()) == WSPACE || c == '\n') + ; + if (c != ')' || (i != narg && ellips == 0) || (i < narg && ellips == 1)) error("wrong arg count"); + inmac = 0; while (gotwarn--) cunput(WARN); @@ -1147,6 +1353,14 @@ if (sp[-1] == VARG) { bp = ap = args[narg]; sp--; +#ifdef GCC_VARI + } else if (sp[-1] == GCCARG) { + ap = args[narg]; + if (ap[0] == 0) + ap = (usch *)"0"; + bp = ap; + sp--; +#endif } else bp = ap = args[(int)*--sp]; if (sp[2] != CONC && !snuff && sp[-1] != CONC) { @@ -1192,6 +1406,7 @@ /* scan the input buffer (until WARN) and save result on heap */ expmac(rp); + free(args); } usch * @@ -1255,6 +1470,10 @@ putstr(usch *s) { for (; *s; s++) { + if (*s == PRAGS) { + s = prtprag(s); + continue; + } outbuf[obufp++] = *s; if (obufp == CPPBUF || (istty && *s == '\n')) flbuf(); @@ -1480,3 +1699,41 @@ return (struct symtab *)new->lr[bit]; } +usch * +xstrdup(char *str) +{ + size_t len = strlen(str)+1; + usch *rv; + + if ((rv = malloc(len)) == NULL) + error("xstrdup: out of mem"); + strlcpy((char *)rv, str, len); + return rv; +} + +usch * +prtprag(usch *s) +{ + int ch; + + s++; + putstr((usch *)"\n#pragma "); + while (*s != PRAGE) { + if (*s == 'L') + s++; + if (*s == '\"') { + s++; + while ((ch = *s++) != '\"') { + if (ch == '\\' && (*s == '\"' || *s == '\\')) + ch = *s++; + putch(ch); + } + } else { + s++; + putch(*s); + } + } + putstr((usch *)"\n"); + prtline(); + return ++s; +} Index: cpy.y =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/cpy.y,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/cpp/cpy.y -L usr.bin/pcc/cpp/cpy.y -u -r1.1 -r1.2 --- usr.bin/pcc/cpp/cpy.y +++ usr.bin/pcc/cpp/cpy.y @@ -1,4 +1,4 @@ -/* $Id: cpy.y,v 1.12 2006/10/08 13:41:39 ragge Exp $ */ +/* $Id: cpy.y,v 1.16 2008/04/12 17:14:27 ragge Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -62,23 +62,34 @@ */ %{ -#include -#include -#include + +#include "cpp.h" + void yyerror(char *); int yylex(void); +int setd(int l, int r); + +#define EVALUNARY(tok, l, r) l.nd_val = tok r.nd_val; l.op = r.op +#define EVALBIN(tok, d, l, r) \ + d.op = setd(l.op, r.op); d.nd_val = l.nd_val tok r.nd_val +#define EVALUBIN(tok, d, l, r, t) \ + d.op = setd(l.op, r.op); \ + if (d.op == NUMBER) d.nd_val = l.nd_val tok r.nd_val; \ + else d.nd_uval = l.nd_uval tok r.nd_uval; \ + if (t && d.op) d.op = NUMBER +#define XEVALUBIN(tok, d, l, r) \ + if (r.nd_val) { EVALUBIN(tok, d, l, r, 0); } else d.op = 0 %} %term stop %term EQ NE LE GE LS RS -%term ANDAND OROR IDENT NUMBER +%term ANDAND OROR IDENT NUMBER UNUMBER /* * The following terminals are not used in the yacc code. */ -%term STRING FPOINT WSPACE VA_ARGS CONCAT MKSTR ELLIPS +%term STRING FPOINT WSPACE VA_ARGS CONCAT MKSTR ELLIPS CMNT %left ',' -%right '=' %right '?' ':' %left OROR %left ANDAND @@ -90,77 +101,117 @@ %left '+' '-' %left '*' '/' '%' %right '!' '~' UMINUS -%left '(' '.' +%left '(' %union { - long long val; + struct nd node; } -%type term NUMBER e +%type term e NUMBER UNUMBER %% -S: e '\n' { return($1 != 0);} - +S: e '\n' { + if ($1.op == 0) + error("division by zero"); + return $1.nd_val; + } e: e '*' e - {$$ = $1 * $3;} + { EVALUBIN(*, $$, $1, $3, 0); } | e '/' e - {$$ = $1 / $3;} + { XEVALUBIN(/, $$, $1, $3); } | e '%' e - {$$ = $1 % $3;} + { XEVALUBIN(%, $$, $1, $3); } | e '+' e - {$$ = $1 + $3;} + { EVALBIN(+, $$, $1, $3); } | e '-' e - {$$ = $1 - $3;} + { EVALBIN(-, $$, $1, $3); } | e LS e - {$$ = $1 << $3;} + { EVALBIN(<<, $$, $1, $3); } | e RS e - {$$ = $1 >> $3;} + { EVALUBIN(>>, $$, $1, $3, 0); } | e '<' e - {$$ = $1 < $3;} + { EVALUBIN(<, $$, $1, $3, 1); } | e '>' e - {$$ = $1 > $3;} + { EVALUBIN(>, $$, $1, $3, 1); } | e LE e - {$$ = $1 <= $3;} + { EVALUBIN(<=, $$, $1, $3, 1); } | e GE e - {$$ = $1 >= $3;} + { EVALUBIN(>=, $$, $1, $3, 1); } | e EQ e - {$$ = $1 == $3;} + { EVALUBIN(==, $$, $1, $3, 1); } | e NE e - {$$ = $1 != $3;} + { EVALUBIN(!=, $$, $1, $3, 1); } | e '&' e - {$$ = $1 & $3;} + { EVALBIN(&, $$, $1, $3); } | e '^' e - {$$ = $1 ^ $3;} + { EVALBIN(^, $$, $1, $3); } | e '|' e - {$$ = $1 | $3;} - | e ANDAND e - {$$ = $1 && $3;} - | e OROR e - {$$ = $1 || $3;} - | e '?' e ':' e - {$$ = $1 ? $3 : $5;} - | e ',' e - {$$ = $3;} + { EVALBIN(|, $$, $1, $3); } + | e ANDAND e { + $$ = $1; + if ($1.nd_val) { + $$.op = setd($1.op, $3.op); + $$.nd_val = ($3.nd_val != 0); + } + if ($$.op == UNUMBER) $$.op = NUMBER; + } + | e OROR e { + if ($1.nd_val != 0) { + $$.nd_val = ($1.nd_val != 0); + $$.op = $1.op; + } else { + $$.nd_val = ($3.nd_val != 0); + $$.op = setd($1.op, $3.op); + } + if ($$.op == UNUMBER) $$.op = NUMBER; + } + | e '?' e ':' e { + if ($1.op == 0) + $$ = $1; + else if ($1.nd_val) + $$ = $3; + else + $$ = $5; + } + | e ',' e { + $$.op = setd($1.op, $3.op); + $$.nd_val = $3.nd_val; + if ($$.op) $$.op = $3.op; + } | term {$$ = $1;} term: '-' term %prec UMINUS - {$$ = -$2;} + { EVALUNARY(-, $$, $2); } + | '+' term %prec UMINUS + {$$ = $2;} | '!' term - {$$ = !$2;} + { $$.nd_val = ! $2.nd_val; $$.op = $2.op ? NUMBER : 0; } | '~' term - {$$ = ~$2;} + { EVALUNARY(~, $$, $2); } | '(' e ')' {$$ = $2;} | NUMBER - {$$= $1;} + {$$ = $1;} %% -#include "cpp.h" - void yyerror(char *err) { error(err); } + +/* + * Set return type of an expression. + */ +int +setd(int l, int r) +{ + if (!l || !r) + return 0; /* div by zero involved */ + if (l == UNUMBER || r == UNUMBER) + return UNUMBER; + return NUMBER; +} + Index: cpp.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/cpp.h,v retrieving revision 1.2 retrieving revision 1.3 diff -L usr.bin/pcc/cpp/cpp.h -L usr.bin/pcc/cpp/cpp.h -u -r1.2 -r1.3 --- usr.bin/pcc/cpp/cpp.h +++ usr.bin/pcc/cpp/cpp.h @@ -1,4 +1,4 @@ -/* $Id: cpp.h,v 1.27 2007/09/17 18:16:14 ragge Exp $ */ +/* $Id: cpp.h,v 1.37 2008/07/02 01:12:41 gmcgarry Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). @@ -28,8 +28,9 @@ */ #include /* for obuf */ +#include -#include "../config.h" +#include "config.h" typedef unsigned char usch; #ifdef YYTEXT_POINTER @@ -43,7 +44,7 @@ extern int flslvl; extern int elflvl; extern int elslvl; -extern int tflag, Cflag; +extern int tflag, Cflag, Pflag; extern int Mflag, dMflag; extern usch *Mfile; extern int ofd; @@ -72,6 +73,7 @@ int infil; usch *curptr; usch *maxread; + usch *ostr; usch *buffer; usch bbuf[NAMEMAX+CPPBUF+1]; } *ifiles; @@ -90,6 +92,23 @@ char *str; }; +/* + * Struct used in parse tree evaluation. + * op is one of: + * - number type (NUMBER, UNUMBER) + * - zero (0) if divided by zero. + */ +struct nd { + int op; + union { + long long val; + unsigned long long uval; + } n; +}; + +#define nd_val n.val +#define nd_uval n.uval + struct recur; /* not used outside cpp.c */ int subst(struct symtab *, struct recur *); struct symtab *lookup(usch *namep, int enterf); @@ -115,6 +134,15 @@ void putstr(usch *s); void line(void); usch *sheap(char *fmt, ...); +void xwarning(usch *); void xerror(usch *); +#ifdef HAVE_CPP_VARARG_MACRO_GCC +#define warning(...) xwarning(sheap(__VA_ARGS__)) #define error(...) xerror(sheap(__VA_ARGS__)) +#else +#define warning printf +#define error printf +#endif void expmac(struct recur *); +int cinput(void); +void getcmnt(void); --- /dev/null +++ usr.bin/pcc/cpp/pcpp.1 @@ -0,0 +1,210 @@ +.\" $Id: cpp.1,v 1.10 2008/07/02 01:12:41 gmcgarry Exp $ +.\" $NetBSD$ +.\" $OpenBSD$ +."\ +.\" Copyright (c) 2007 Jeremy C. Reed +.\" +.\" Permission to use, copy, modify, and/or distribute this software for any +.\" purpose with or without fee is hereby granted, provided that the above +.\" copyright notice and this permission notice appear in all copies. +.\" +.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM +.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED +.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND +.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL +.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR +.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS +.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF +.\" THIS SOFTWARE. +.\" +.Dd September 17, 2007 +.Dt CPP 1 +.Os +.Sh NAME +.Nm cpp +.Nd C preprocessor +.Sh SYNOPSIS +.Nm +.\" TODO also document -Dvar and below without spaces? +.Op Fl CdMtVv +.Op Fl D Ar macro[=value] +.Op Fl I Ar path +.Op Fl i Ar file +.Op Fl S Ar path +.Op Fl U Ar macro +.Op Ar infile | - +.Op Ar outfile +.Sh DESCRIPTION +The +.Nm +utility is a macro preprocessor used by the +.Xr pcc 1 +compiler. +It is used to include header files, +expand macro definitions, +and perform conditional compilation. +.Pp +The +.Ar infile +input file is optional. +If not provided or the file name is +.Qq - +(dash), +.Nm +reads its initial file from standard input. +The +.Ar outfile +output file is also optional. +It writes by default to standard output. +.Pp +.\" TODO: document MAXARG 250 args to a macro, limited by char value +.\" TODO: Include order: +.\" For "..." files, first search "current" dir, then as <...> files. +.\" For <...> files, first search -I directories, then system directories. +.\" +The options are as follows: +.Bl -tag -width Ds +.It Fl ? +Show command line usage for +.Nm . +.It Fl C +Do not discard comments. +.It Fl D Ar macro[=value] +Fake a definition at the beginning by using +.Do #define +.Ar macro=value Dc . +If +.Ar value +is not set on command-line, then define it as 1. +.\" TODO: show example +.It Fl dM +Print list of +.Dq #define +statements to standard output for all defined macros other than +builtin macros (see below). +The normal results of preprocessing are not output. +.\" TODO this doesn't show predefined macros +.\" other -d options are ignored +.It Fl I Ar path +Add +.Ar path +to the list of directories containing needed header files. +This may be used to override system include directories +(see +.Fl S +option). +.Fl I +may be specified multiple times. +.It Fl i Ar file +Include a file at the beginning by using +.Do #include +.Ar file Dc . +.\" Note: I did not use the .In macro above +.It Fl M +Generate dependencies for +.Xr make 1 . +.\" TODO: explain and show example? +.It Fl P +Inhibit generation of line markers. This is sometimes useful when +running the preprocessor on something other than C code. +.It Fl S Ar path +Add +.Ar path +to the list of system directories containing needed header files. +The +.Fl S +option may be specified multiple times. +Note: +.Nm +does not have a default include directory defined. +.\" TODO: explain difference between -I and -S +.\" The directories listed by -I are searched first? +.It Fl t +Traditional cpp syntax. +Do not define the +.Dv __TIME__ , +.Dv __DATE__ , +.Dv __STDC__ , +and +.Dv __STDC_VERSION__ +macros. +.\" +.It Fl U Ar macro +Undefine a macro at the beginning by using +.Do #undef +.Ar macro Dc . +.It Fl V +Verbose debugging output. +.Fl V +can be repeated for further details. +.\" -V only available if cpp source built with CPP_DEBUG, which is the default. +.It Fl v +Display version. +.El +.Ss Builtin Macros +A few macros are interpreted inside the +.Nm cpp +program: +.Bl -diag +.It __DATE__ +Expands to the date in abbreviated month, day, and year format from +.Xr ctime 3 +in quotes. +.\" TODO: is that ctime(3) format output change according to locale? +.It __FILE__ +Expands to the name of the current input file in quotes. +When read from standard input, it expands to +.Qq Aq stdin . +.It __LINE__ +Expands to the line number of the current line containing the macro. +.It __STDC__ +Expands to the constant 1. +This means the compiler conforms to +.St -isoC +.Po also known as +.Do C90 Dc Pc . +.It __STDC_VERSION__ +Expands to +.Dq 199901L +which indicates that +.Nm +supports +.St -isoC-99 +.Po commonly referred to as +.Do C99 Dc Pc . +.It __TIME__ +Expands to the time in hour, minutes, and seconds from +.Xr ctime 3 +in quotes. +.El +.Pp +Also see the +.Fl t +option. +.Sh EXIT STATUS +The +.Nm +utility exits with one of the following values: +.Bl -tag -width Ds +.It 0 +Successfully finished. +.It 1 +An error occurred. +.El +.Sh SEE ALSO +.Xr as 1 , +.Xr ccom 1 , +.Xr pcc 1 +.\" +.Sh HISTORY +The +.Nm +command comes from the original Portable C Compiler by S. C. Johnson, +written in the late 70's. +The code originates from the V6 preprocessor with some additions +from V7 cpp and ansi/c99 support. +.Pp +A lot of the PCC code was rewritten by Anders Magnusson. +.Pp +This product includes software developed or owned by Caldera +International, Inc. Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/cpp/Makefile,v retrieving revision 1.6 retrieving revision 1.7 diff -L usr.bin/pcc/cpp/Makefile -L usr.bin/pcc/cpp/Makefile -u -r1.6 -r1.7 --- usr.bin/pcc/cpp/Makefile +++ usr.bin/pcc/cpp/Makefile @@ -5,13 +5,11 @@ PROG= pcpp TARGOS= midnightbsd BINDIR= ${libexecdir} -NO_MAN= -#MAN= cpp.1 -#MANDIR= /usr/local/man/man +MAN= pcpp.1 CFLAGS+= -DCPP_DEBUG -Wall -Wmissing-prototypes -Wstrict-prototypes -Werror CFLAGS+= -DLIBEXECDIR=\"${libexecdir}\" -CFLAGS+= -I. -I${.CURDIR} +CFLAGS+= -I. -I${.CURDIR} -I${.CURDIR}/.. -I${.CURDIR}/../mip/ SRCS= cpy.y scanner.l cpp.c CLEANFILES+= y.tab.c y.tab.h --- usr.bin/pcc/cpp/cpp.1 +++ /dev/null @@ -1,191 +0,0 @@ -.\" $Id: cpp.1,v 1.4 2007/09/26 14:48:51 ragge Exp $ -.\" $NetBSD$ -.\" $OpenBSD$ -."\ -.\" Copyright (c) 2007 Jeremy C. Reed -.\" -.\" Permission to use, copy, modify, and/or distribute this software for any -.\" purpose with or without fee is hereby granted, provided that the above -.\" copyright notice and this permission notice appear in all copies. -.\" -.\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR AND CONTRIBUTORS DISCLAIM -.\" ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED -.\" WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL AUTHOR AND -.\" CONTRIBUTORS BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL -.\" DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR -.\" PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS -.\" ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF -.\" THIS SOFTWARE. -.\" -.Dd September 17, 2007 -.Dt cpp 1 -.Os -.Sh NAME -.Nm cpp -.Nd C preprocessor -.Sh SYNOPSIS -.Nm -.\" TODO also document -Dvar and below without spaces? -.Op Fl Cdt -.Op Fl D Ar var=val -.Op Fl U Ar var -.Op Fl I Ar path -.Op Fl S Ar path -.Op Ar infile | - -.Op Ar outfile -.Pp -.Sh DESCRIPTION -The -.Nm -utility is a macro preprocessor used by the -.Xr pcc 1 -compiler. -It is used to include header files, -expand macro definitions, -and perform conditional compilation. -.Pp -The -.Ar infile -input file is optional. -If not provided or the file name is -.Qq - -(dash), -.Nm -reads its initial file from standard input. -The -.Ar outfile -output file is also optional. -It writes by default to standard output. -.Pp -.\" TODO: document MAXARG 250 args to a macro, limited by char value -.\" TODO: Include order: -.\" For "..." files, first search "current" dir, then as <...> files. -.\" For <...> files, first search -I directories, then system directories. -.\" -The options are as follows: -.Bl -tag -width Ds -.It Fl C -Do not discard comments. -.It Fl dM -Print list of -.Dq #define -statements to standard output for all defined macros other than -builtin macros (see below). -The normal results of preprocessing are not outputted. -.\" TODO this doesn't show predefined macros -.\" other -d options are ignored -.It Fl D Ar macro[=value] -Fake a definition at the beginning by using -.Do #define -.Ar macro=value Dc . -If -.Ar value -is not set on command-line, then defines as 1. -.\" TODO: show example -.It Fl i Ar file -Include a file at the beginning by using -.Do #include -.Ar file Dc . -.\" Note: I did not use the .In macro above -.It Fl I Ar directory -Add -.Ar directory -to the list of system directories containing needed header files. -This may be used to override system include directories -(see -.Fl S -option). -.Fl I -may be specified multiple times. -.It Fl M -Generate dependencies for -.Xr make 1 . -.\" TODO: explain and show example? -.It Fl S Ar directory -Add -.Ar directory -to the list of system directories containing needed header files. -.Fl S -may be specified multiple times. -Note: -.Nm -does not have a default include directory defined. -.\" TODO: explain difference between -I and -S -.\" The directories listed by -I are searched first? -.It Fl t -Traditional cpp syntax. -Do not define the -.Dv __TIME__ , -.Dv __DATE__ , -and -.Dv __STDC__ -macros. -.\" -.It Fl U Ar macro -Undefine a macro at the beginning by using -.Do #undef -.Ar macro Dc . -.It Fl v -Verbose debugging output. -.Fl v -can be repeated for further details. -.\" -v only available if cpp source built with CPP_DEBUG, which is the default. -.It Fl ? -Show command line usage for -.Nm . -.El -.Sh Builtin Macros -A few macros are interpreted inside the -.Nm cpp -program: -.Bl -diag -.It __DATE__ -Expands to the date in abbreviated month, day, and year format from -.Xr ctime 3 -in quotes. -.\" TODO: is that ctime(3) format output change according to locale? -.It __FILE__ -Expands to the name of the current input file in quotes. -When read from standard input, it expands to -.Qq Ao stdin Ac . -.It __LINE__ -Expands to the line number of the current line containing the macro. -.It __STDC__ -Expands to the constant 1. -This means the compiler conforms to ISO Standard C. -.It __TIME__ -Expands to the time in hour, minutes, and seconds from -.Xr ctime 3 -in quotes. -.El -.Pp -Also see the -.Fl t -option. -.Sh EXIT STATUS -The -.Nm -utility exits with one of the following values: -.Bl -tag -width Ds -.It 0 -Successfully finished. -.It 1 -An error occurred. -.El -.Sh SEE ALSO -.Xr as 1 , -.Xr ccom 1 , -.Xr pcc 1 -.\" -.Sh HISTORY -The -.Nm -command comes from the original Portable C Compiler by S. C. -Johnson, written in the late 70's. -The code originates from the V6 preprocessor with some additions -from V7 cpp and ansi/c99 support. -.Pp -A lot of the PCC code was rewritten by Anders Magnusson. -.Pp -This product includes software developed or owned by Caldera -International, Inc. Index: order.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/order.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/order.c -L usr.bin/pcc/i386/order.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/order.c +++ usr.bin/pcc/i386/order.c @@ -1,4 +1,4 @@ -/* $Id: order.c,v 1.49 2007/08/01 04:53:58 ragge Exp $ */ +/* $Id: order.c,v 1.54 2008/09/27 07:35:22 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -103,26 +103,16 @@ * Shape matches for UMUL. Cooperates with offstar(). */ int -shumul(NODE *p) +shumul(NODE *p, int shape) { if (x2debug) printf("shumul(%p)\n", p); /* Turns currently anything into OREG on x86 */ - return SOREG; -} - -/* - * Rewrite increment/decrement operation. - */ -int -setincr(NODE *p) -{ - if (x2debug) - printf("setincr(%p)\n", p); - - return(0); + if (shape & SOREG) + return SROREG; + return SRNOPE; } /* @@ -183,8 +173,8 @@ static struct rspecial s[] = { { NOLEFT, ESI }, { NOLEFT, EDI }, { 0 } }; return s; - } else if ((q->ltype & (TINT|TUNSIGNED)) && - q->rtype == TLONGLONG) { + } else if ((q->ltype & TINT) && + q->rtype == (TLONGLONG|TULONGLONG)) { static struct rspecial s[] = { { NLEFT, EAX }, { NRES, EAXEDX }, { NEVER, EAX }, { NEVER, EDX }, { 0 } }; @@ -285,3 +275,30 @@ { return 0; /* nothing differs on x86 */ } + +/* + * set registers in calling conventions live. + */ +int * +livecall(NODE *p) +{ + static int r[] = { EAX, EBX, -1 }; + int off = 1; + +#ifdef TLS + if (p->n_left->n_op == ICON && + strcmp(p->n_left->n_name, "___tls_get_addr at PLT") == 0) + off--; +#endif + + return kflag ? &r[off] : &r[2]; +} + +/* + * Signal whether the instruction is acceptable for this target. + */ +int +acceptable(struct optab *op) +{ + return 1; +} Index: macdefs.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/macdefs.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/macdefs.h -L usr.bin/pcc/i386/macdefs.h -u -r1.1 -r1.2 --- usr.bin/pcc/i386/macdefs.h +++ usr.bin/pcc/i386/macdefs.h @@ -1,4 +1,4 @@ -/* $Id: macdefs.h,v 1.46 2007/08/19 19:25:22 ragge Exp $ */ +/* $Id: macdefs.h,v 1.67 2008/12/14 18:26:43 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -65,8 +65,9 @@ #define ALLONGLONG 32 #define ALSHORT 16 #define ALPOINT 32 -#define ALSTRUCT 32 +#undef ALSTRUCT /* Not defined if ELF ABI */ #define ALSTACK 32 +#define ALMAX 128 /* not yet supported type */ /* * Min/max values. @@ -77,7 +78,7 @@ #define MIN_SHORT -32768 #define MAX_SHORT 32767 #define MAX_USHORT 65535 -#define MIN_INT -1 +#define MIN_INT (-0x7fffffff-1) #define MAX_INT 0x7fffffff #define MAX_UNSIGNED 0xffffffff #define MIN_LONG MIN_INT @@ -90,7 +91,11 @@ /* Default char is signed */ #undef CHAR_UNSIGNED #define BOOL_TYPE CHAR /* what used to store _Bool */ +#if defined(os_mirbsd) || defined(os_win32) +#define WCHAR_TYPE USHORT /* ISO 10646 16-bit Unicode */ +#else #define WCHAR_TYPE INT /* what used to store wchar_t */ +#endif /* * Use large-enough types. @@ -100,36 +105,37 @@ typedef long long OFFSZ; #define CONFMT "%lld" /* format for printing constants */ +#if defined(ELFABI) #define LABFMT ".L%d" /* format for printing labels */ #define STABLBL ".LL%d" /* format for stab (debugging) labels */ -#ifdef FORTRAN -#define XL 8 -#define FLABELFMT "%s:\n" -#define USETEXT ".text" -#define USECONST ".data\t0" /* XXX - fix */ -#define USEBSS ".data\t1" /* XXX - fix */ -#define USEINIT ".data\t2" /* XXX - fix */ -#define MAXREGVAR 3 /* XXX - fix */ +#else +#define LABFMT "L%d" /* format for printing labels */ +#define STABLBL "LL%d" /* format for stab (debugging) labels */ +#endif +#ifdef LANG_F77 #define BLANKCOMMON "_BLNK_" #define MSKIREG (M(TYSHORT)|M(TYLONG)) #define TYIREG TYLONG #define FSZLENG FSZLONG -#define FUDGEOFFSET 1 #define AUTOREG EBP #define ARGREG EBP -#define ARGOFFSET 4 +#define ARGOFFSET 8 +#endif + +#ifdef MACHOABI +#define STAB_LINE_ABSOLUTE /* S_LINE fields use absolute addresses */ #endif #define BACKAUTO /* stack grows negatively for automatics */ #define BACKTEMP /* stack grows negatively for temporaries */ -#define MYP2TREE(p) myp2tree(p); - #undef FIELDOPS /* no bit-field instructions */ #define RTOLBYTES /* bytes are numbered right to left */ #define ENUMSIZE(high,low) INT /* enums are always stored in full int */ +#define FINDMOPS /* i386 has instructions that modifies memory */ + /* Definitions mostly used in pass2 */ #define BYTEOFF(x) ((x)&03) @@ -292,10 +298,69 @@ #define FPREG EBP /* frame pointer */ #define STKREG ESP /* stack pointer */ -#define MYREADER(p) myreader(p) -#define MYCANON(p) mycanon(p) -#define MYOPTIM - #define SHSTR (MAXSPECIAL+1) /* short struct */ #define SFUNCALL (MAXSPECIAL+2) /* struct assign after function call */ #define SPCON (MAXSPECIAL+3) /* positive nonnamed constant */ + +/* + * Specials that indicate the applicability of machine idioms. + */ +#define SMIXOR (MAXSPECIAL+4) +#define SMILWXOR (MAXSPECIAL+5) +#define SMIHWXOR (MAXSPECIAL+6) + +/* + * i386-specific symbol table flags. + */ +#define SSECTION SLOCAL1 +#define STLS SLOCAL2 +#define SNOUNDERSCORE SLOCAL3 +#define SSTDCALL SLOCAL2 +#define SDLLINDIRECT SLOCAL3 + +/* + * i386-specific node flags. + */ +#define FSTDCALL 0x01 + +/* + * i386-specific interpass stuff. + */ + +#define TARGET_IPP_MEMBERS \ + int ipp_argstacksize; + +/* + * Extended assembler macros. + */ +void targarg(char *w, void *arg); +#define XASM_TARGARG(w, ary) \ + (w[1] == 'b' || w[1] == 'h' || w[1] == 'w' || w[1] == 'k' ? \ + w++, targarg(w, ary), 1 : 0) +int numconv(void *ip, void *p, void *q); +#define XASM_NUMCONV(ip, p, q) numconv(ip, p, q) +int xasmconstregs(char *); +#define XASMCONSTREGS(x) xasmconstregs(x) + +/* + * builtins. + */ +#define TARGET_BUILTINS \ + { "__builtin_frame_address", i386_builtin_frame_address }, \ + { "__builtin_return_address", i386_builtin_return_address }, + +#define NODE struct node +struct node; +NODE *i386_builtin_frame_address(NODE *f, NODE *a); +NODE *i386_builtin_return_address(NODE *f, NODE *a); +#undef NODE + +#if defined(MACHOABI) +struct stub { + struct { struct stub *q_forw, *q_back; } link; + char *name; +}; +extern struct stub stublist; +extern struct stub nlplist; +void addstub(struct stub *list, char *name); +#endif Index: table.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/table.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/table.c -L usr.bin/pcc/i386/table.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/table.c +++ usr.bin/pcc/i386/table.c @@ -1,4 +1,4 @@ -/* $Id: table.c,v 1.96 2007/09/20 14:52:13 ragge Exp $ */ +/* $Id: table.c,v 1.110 2008/11/24 14:52:02 mickey Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -133,7 +133,7 @@ { SCONV, INLL, SHCH|SOREG|SNAME, TCHAR, SANY, TLL, - NSPECIAL|NAREG|NASL, RESC1, + NSPECIAL|NCREG|NCSL, RESC1, " movsbl AL,%eax\n cltd\n", }, /* convert unsigned char to (u)long long */ @@ -229,7 +229,7 @@ /* convert int to char. This is done when register is loaded */ { SCONV, INCH, - SAREG, TWORD, + SAREG, TWORD|TPOINT, SANY, TCHAR|TUCHAR, NSPECIAL|NBREG|NBSL, RESC1, "ZM", }, @@ -241,17 +241,17 @@ 0, RLEFT, "", }, -/* convert int to long long */ +/* convert signed int to (u)long long */ { SCONV, INLL, - SAREG, TWORD|TPOINT, - SCREG, TLONGLONG, + SHINT, TSWORD, + SHLL, TLL, NSPECIAL|NCREG|NCSL, RESC1, " cltd\n", }, -/* convert int to unsigned long long */ +/* convert unsigned int to (u)long long */ { SCONV, INLL, - SAREG|SOREG|SNAME, TWORD|TPOINT, - SHLL, TULONGLONG, + SHINT|SOREG|SNAME, TUWORD|TPOINT, + SHLL, TLL, NCSL|NCREG, RESC1, " movl AL,A1\n xorl U1,U1\n", }, @@ -275,14 +275,14 @@ { SCONV, INCH, SOREG|SNAME, TLL, SANY, TCHAR|TUCHAR, - NAREG|NASL, RESC1, + NBREG|NBSL, RESC1, " movb AL,A1\n", }, /* convert (u)long long to (u)char (reg->reg, hopefully nothing) */ { SCONV, INCH, SHLL, TLL, SANY, TCHAR|TUCHAR, - NAREG|NASL, RESC1, + NBREG|NBSL, RESC1, "ZS", }, /* convert (u)long long to (u)short (mem->reg) */ @@ -358,7 +358,19 @@ SHFL, TLDOUBLE|TDOUBLE|TFLOAT, SAREG, TWORD, NAREG, RESC1, +#ifdef notdef /* Must round down and nothing else */ " subl $4,%esp\n fistpl (%esp)\n popl A1\n", }, +#else + " subl $12,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpl 8(%esp)\n" + " movl 8(%esp),A1\n" + " fldcw 4(%esp)\n" + " addl $12,%esp\n", }, +#endif /* convert float/double (in register) to (unsigned) long long */ /* XXX - unsigned is not handled correct */ @@ -366,8 +378,21 @@ SHFL, TLDOUBLE|TDOUBLE|TFLOAT, SHLL, TLONGLONG|TULONGLONG, NCREG, RESC1, +#ifdef notdef /* Must round down and nothing else */ " subl $8,%esp\n fistpq (%esp)\n" " popl A1\n popl U1\n", }, +#else + " subl $16,%esp\n" + " fnstcw (%esp)\n" + " fnstcw 4(%esp)\n" + " movb $12,1(%esp)\n" + " fldcw (%esp)\n" + " fistpq 8(%esp)\n" + " movl 8(%esp),A1\n" + " movl 12(%esp),U1\n" + " fldcw 4(%esp)\n" + " addl $16,%esp\n", }, +#endif /* slut sconv */ @@ -389,13 +414,13 @@ { CALL, INAREG, SCON, TANY, - SAREG, TWORD|TPOINT, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, NAREG|NASL, RESC1, /* should be 0 */ " call CL\nZC", }, { UCALL, INAREG, SCON, TANY, - SAREG, TWORD|TPOINT, + SAREG, TSHORT|TUSHORT|TWORD|TPOINT, NAREG|NASL, RESC1, /* should be 0 */ " call CL\n", }, @@ -573,6 +598,12 @@ NAREG|NASL, RESC1, " leal CR(AL),A1\n", }, +{ PLUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " incw AL\n", }, + { PLUS, INCH|FOREFF, SHCH|SNAME|SOREG, TCHAR|TUCHAR, SONE, TANY, @@ -591,6 +622,12 @@ 0, RLEFT, " decl AL\n", }, +{ MINUS, INAREG|FOREFF, + SAREG|SNAME|SOREG, TSHORT|TUSHORT, + SONE, TANY, + 0, RLEFT, + " decw AL\n", }, + { MINUS, INCH|FOREFF, SHCH|SNAME|SOREG, TCHAR|TUCHAR, SONE, TANY, @@ -623,48 +660,81 @@ " fsubZAp\n", }, /* Simple r/m->reg ops */ -{ OPSIMP, INAREG|FOREFF, +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD|TPOINT, + SAREG, TWORD|TPOINT, + 0, RLEFT|RESCC, + " Ol AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, SAREG, TWORD|TPOINT, SAREG|SNAME|SOREG, TWORD|TPOINT, - 0, RLEFT, + 0, RLEFT|RESCC, " Ol AR,AL\n", }, -{ OPSIMP, INAREG|FOREFF, +/* m/r |= r */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SHINT|SNAME|SOREG, TSHORT|TUSHORT, + SHINT, TSHORT|TUSHORT, + 0, RLEFT|RESCC, + " Ow AR,AL\n", }, + +/* r |= r/m */ +{ OPSIMP, INAREG|FOREFF|FORCC, SHINT, TSHORT|TUSHORT, SHINT|SNAME|SOREG, TSHORT|TUSHORT, - 0, RLEFT, + 0, RLEFT|RESCC, " Ow AR,AL\n", }, -{ OPSIMP, INCH|FOREFF, +/* m/r |= r */ +{ OPSIMP, INCH|FOREFF|FORCC, SHCH, TCHAR|TUCHAR, SHCH|SNAME|SOREG, TCHAR|TUCHAR, - 0, RLEFT, + 0, RLEFT|RESCC, " Ob AR,AL\n", }, -{ OPSIMP, INAREG|FOREFF, - SAREG, TWORD|TPOINT, +/* r |= r/m */ +{ OPSIMP, INCH|FOREFF|FORCC, + SHCH, TCHAR|TUCHAR, + SHCH|SNAME|SOREG, TCHAR|TUCHAR, + 0, RLEFT|RESCC, + " Ob AR,AL\n", }, + +/* m/r |= const */ +{ OPSIMP, INAREG|FOREFF|FORCC, + SAREG|SNAME|SOREG, TWORD|TPOINT, SCON, TWORD|TPOINT, - 0, RLEFT, + 0, RLEFT|RESCC, " Ol AR,AL\n", }, -{ OPSIMP, INAREG|FOREFF, +{ OPSIMP, INAREG|FOREFF|FORCC, SHINT|SNAME|SOREG, TSHORT|TUSHORT, SCON, TANY, - 0, RLEFT, + 0, RLEFT|RESCC, " Ow AR,AL\n", }, -{ OPSIMP, INCH|FOREFF, +{ OPSIMP, INCH|FOREFF|FORCC, SHCH|SNAME|SOREG, TCHAR|TUCHAR, SCON, TANY, - 0, RLEFT, + 0, RLEFT|RESCC, " Ob AR,AL\n", }, +/* r |= r/m */ { OPSIMP, INLL|FOREFF, SHLL, TLL, SHLL|SNAME|SOREG, TLL, 0, RLEFT, " Ol AR,AL\n Ol UR,UL\n", }, +/* m/r |= r/const */ +{ OPSIMP, INLL|FOREFF, + SHLL|SNAME|SOREG, TLL, + SHLL|SCON, TLL, + 0, RLEFT, + " Ol AR,AL\n Ol UR,UL\n", }, + /* * The next rules handle all shift operators. @@ -676,24 +746,28 @@ NSPECIAL|NCREG|NCSL|NCSR, RESC1, "ZO", }, +/* r/m <<= r */ { LS, INAREG|FOREFF, SAREG|SNAME|SOREG, TWORD, SHCH, TCHAR|TUCHAR, NSPECIAL, RLEFT, " sall AR,AL\n", }, +/* r/m <<= const */ { LS, INAREG|FOREFF, - SAREG, TWORD, + SAREG|SNAME|SOREG, TWORD, SCON, TANY, 0, RLEFT, " sall AR,AL\n", }, +/* r/m <<= r */ { LS, INAREG|FOREFF, SAREG|SNAME|SOREG, TSHORT|TUSHORT, SHCH, TCHAR|TUCHAR, NSPECIAL, RLEFT, " shlw AR,AL\n", }, +/* r/m <<= const */ { LS, INAREG|FOREFF, SAREG|SNAME|SOREG, TSHORT|TUSHORT, SCON, TANY, @@ -727,7 +801,7 @@ { RS, INAREG|FOREFF, SAREG|SNAME|SOREG, TSWORD, - SCON, TWORD|TCHAR|TUCHAR|TSHORT|TUSHORT, + SCON, TANY, 0, RLEFT, " sarl AR,AL\n", }, @@ -739,7 +813,7 @@ { RS, INAREG|FOREFF, SAREG|SNAME|SOREG, TUWORD, - SCON, TWORD|TCHAR|TUCHAR|TSHORT|TUSHORT, + SCON, TANY, 0, RLEFT, " shrl AR,AL\n", }, @@ -794,17 +868,41 @@ /* * The next rules takes care of assignments. "=". */ +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL, + SMIXOR, TANY, + 0, RDEST, + " xorl AL,AL\n xorl UL,UL\n", }, + +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL, + SMILWXOR, TANY, + 0, RDEST, + " xorl AL,AL\n movl UR,UL\n", }, + +{ ASSIGN, FORCC|FOREFF|INLL, + SHLL, TLL, + SMIHWXOR, TANY, + 0, RDEST, + " movl AR,AL\n xorl UL,UL\n", }, + +{ ASSIGN, FOREFF|INLL, + SHLL, TLL, + SCON, TANY, + 0, RDEST, + " movl AR,AL\n movl UR,UL\n", }, + { ASSIGN, FOREFF, SHLL|SNAME|SOREG, TLL, SCON, TANY, 0, 0, " movl AR,AL\n movl UR,UL\n", }, -{ ASSIGN, FOREFF|INLL, - SHLL, TLL, - SCON, TANY, +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TWORD|TPOINT, + SMIXOR, TANY, 0, RDEST, - " movl AR,AL\n movl UR,UL\n", }, + " xorl AL,AL\n", }, { ASSIGN, FOREFF, SAREG|SNAME|SOREG, TWORD|TPOINT, @@ -818,6 +916,12 @@ 0, RDEST, " movl AR,AL\n", }, +{ ASSIGN, FORCC|FOREFF|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + 0, RDEST, + " xorw AL,AL\n", }, + { ASSIGN, FOREFF, SAREG|SNAME|SOREG, TSHORT|TUSHORT, SCON, TANY, @@ -875,20 +979,40 @@ { ASSIGN, FOREFF|INBREG, SFLD, TCHAR|TUCHAR, SBREG|SCON, TCHAR|TUCHAR, - NBREG, RDEST, - "ZE", }, + NAREG|NBREG, RDEST, + " movb AR,A2\n" + " movzbl A2,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movb AR,AD\n" + "FZE", }, { ASSIGN, FOREFF|INAREG, - SFLD, TANY, - SAREG, TANY, + SFLD, TSHORT|TUSHORT, + SAREG|SCON, TSHORT|TUSHORT, NAREG, RDEST, - "ZE", }, + " movw AR,A1\n" + " movzwl A1,ZN\n" + " andl $N,AL\n" + " sall $H,ZN\n" + " andl $M,ZN\n" + " orl ZN,AL\n" + "F movw AR,AD\n" + "FZE", }, -{ ASSIGN, FOREFF, - SFLD, TANY, - SAREG|SNAME|SOREG|SCON, TANY, - NAREG, 0, - "ZE", }, +{ ASSIGN, FOREFF|INAREG, + SFLD, TWORD, + SAREG|SNAME|SOREG|SCON, TWORD, + NAREG, RDEST, + " movl AR,A1\n" + " andl $N,AL\n" + " sall $H,A1\n" + " andl $M,A1\n" + " orl A1,AL\n" + "F movl AR,AD\n" + "FZE", }, { ASSIGN, INDREG|FOREFF, SHFL, TFLOAT|TDOUBLE|TLDOUBLE, @@ -901,7 +1025,7 @@ SNAME|SOREG, TLDOUBLE, SHFL, TFLOAT|TDOUBLE|TLDOUBLE, 0, RDEST, - " fstt AL\n", }, + " fst AL\n", }, { ASSIGN, FOREFF, SNAME|SOREG, TLDOUBLE, @@ -1087,7 +1211,7 @@ { UMUL, INLL, SANY, TANY, SOREG, TLL, - NCREG|NCSL, RESC1, + NCREG, RESC1, " movl UL,U1\n movl AL,A1\n", }, { UMUL, INAREG, @@ -1241,7 +1365,7 @@ 0, RNOP, " jmp LL\n", }, -#ifdef GCC_COMPAT +#if defined(GCC_COMPAT) || defined(LANG_F77) { GOTO, FOREFF, SAREG, TANY, SANY, TANY, @@ -1252,12 +1376,36 @@ /* * Convert LTYPE to reg. */ +{ OPLTYPE, FORCC|INLL, + SCREG, TLL, + SMIXOR, TANY, + NCREG, RESC1, + " xorl U1,U1\n xorl A1,A1\n", }, + +{ OPLTYPE, FORCC|INLL, + SCREG, TLL, + SMILWXOR, TANY, + NCREG, RESC1, + " movl UL,U1\n xorl A1,A1\n", }, + +{ OPLTYPE, FORCC|INLL, + SCREG, TLL, + SMIHWXOR, TANY, + NCREG, RESC1, + " xorl U1,U1\n movl AL,A1\n", }, + { OPLTYPE, INLL, SANY, TANY, SCREG|SCON|SOREG|SNAME, TLL, NCREG, RESC1, " movl UL,U1\n movl AL,A1\n", }, +{ OPLTYPE, FORCC|INAREG, + SAREG, TWORD|TPOINT, + SMIXOR, TANY, + NAREG|NASL, RESC1, + " xorl A1,A1\n", }, + { OPLTYPE, INAREG, SANY, TANY, SAREG|SCON|SOREG|SNAME, TWORD|TPOINT, @@ -1270,6 +1418,12 @@ NBREG, RESC1, " movb AL,A1\n", }, +{ OPLTYPE, FORCC|INAREG, + SAREG, TSHORT|TUSHORT, + SMIXOR, TANY, + NAREG, RESC1, + " xorw A1,A1\n", }, + { OPLTYPE, INAREG, SANY, TANY, SAREG|SOREG|SNAME|SCON, TSHORT|TUSHORT, Index: local2.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/local2.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/local2.c -L usr.bin/pcc/i386/local2.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/local2.c +++ usr.bin/pcc/i386/local2.c @@ -1,4 +1,4 @@ -/* $Id: local2.c,v 1.89 2007/09/16 19:08:16 ragge Exp $ */ +/* $Id: local2.c,v 1.120 2008/12/14 18:26:43 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -26,22 +26,18 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ - # include "pass2.h" # include # include -void acon(NODE *p); -int argsize(NODE *p); +#if defined(PECOFFABI) || defined(MACHOABI) +#define EXPREFIX "_" +#else +#define EXPREFIX "" +#endif -static int stkpos; -void -lineid(int l, char *fn) -{ - /* identify line l and file fn */ - printf("# line %d, file %s\n", l, fn); -} +static int stkpos; void deflab(int label) @@ -59,16 +55,19 @@ static void prtprolog(struct interpass_prolog *ipp, int addto) { - int i, j; + int i; printf(" pushl %%ebp\n"); printf(" movl %%esp,%%ebp\n"); +#if defined(MACHOABI) + printf(" subl $8,%%esp\n"); /* 16-byte stack alignment */ +#endif if (addto) printf(" subl $%d,%%esp\n", addto); - for (i = ipp->ipp_regs, j = 0; i; i >>= 1, j++) - if (i & 1) + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) fprintf(stdout, " movl %s,-%d(%s)\n", - rnames[j], regoff[j], rnames[FPREG]); + rnames[i], regoff[i], rnames[FPREG]); } /* @@ -77,17 +76,16 @@ static int offcalc(struct interpass_prolog *ipp) { - int i, j, addto; + int i, addto; addto = p2maxautooff; if (addto >= AUTOINIT/SZCHAR) addto -= AUTOINIT/SZCHAR; - for (i = ipp->ipp_regs, j = 0; i ; i >>= 1, j++) { - if (i & 1) { + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) { addto += SZINT/SZCHAR; - regoff[j] = addto; + regoff[i] = addto; } - } return addto; } @@ -97,43 +95,61 @@ int addto; ftype = ipp->ipp_type; + +#ifdef LANG_F77 if (ipp->ipp_vis) printf(" .globl %s\n", ipp->ipp_name); printf(" .align 4\n"); printf("%s:\n", ipp->ipp_name); +#endif /* * We here know what register to save and how much to * add to the stack. */ addto = offcalc(ipp); +#if defined(MACHOABI) + addto = (addto + 15) & ~15; /* stack alignment */ +#endif prtprolog(ipp, addto); } void eoftn(struct interpass_prolog *ipp) { - int i, j; + int i; if (ipp->ipp_ip.ip_lbl == 0) return; /* no code needs to be generated */ /* return from function code */ - for (i = ipp->ipp_regs, j = 0; i ; i >>= 1, j++) { - if (i & 1) + for (i = 0; i < MAXREGS; i++) + if (TESTBIT(ipp->ipp_regs, i)) fprintf(stdout, " movl -%d(%s),%s\n", - regoff[j], rnames[FPREG], rnames[j]); - - } + regoff[i], rnames[FPREG], rnames[i]); /* struct return needs special treatment */ if (ftype == STRTY || ftype == UNIONTY) { printf(" movl 8(%%ebp),%%eax\n"); printf(" leave\n"); - printf(" ret $4\n"); +#ifdef os_win32 + printf(" ret $%d\n", 4 + ipp->ipp_argstacksize); +#else + printf(" ret $%d\n", 4); +#endif } else { printf(" leave\n"); - printf(" ret\n"); +#ifdef os_win32 + if (ipp->ipp_argstacksize) + printf(" ret $%d\n", ipp->ipp_argstacksize); + else +#endif + printf(" ret\n"); } + +#if defined(ELFABI) + printf("\t.size " EXPREFIX "%s,.-" EXPREFIX "%s\n", ipp->ipp_name, + ipp->ipp_name); +#endif } /* @@ -211,7 +227,7 @@ twollcomp(NODE *p) { int o = p->n_op; - int s = getlab(); + int s = getlab2(); int e = p->n_label; int cb1, cb2; @@ -250,58 +266,64 @@ deflab(s); } -/* - * Assign to a bitfield. - * Clumsy at least, but what to do? - */ +int +fldexpand(NODE *p, int cookie, char **cp) +{ + CONSZ val; + + if (p->n_op == ASSIGN) + p = p->n_left; + switch (**cp) { + case 'S': + printf("%d", UPKFSZ(p->n_rval)); + break; + case 'H': + printf("%d", UPKFOFF(p->n_rval)); + break; + case 'M': + case 'N': + val = (CONSZ)1 << UPKFSZ(p->n_rval); + --val; + val <<= UPKFOFF(p->n_rval); + printf("0x%llx", (**cp == 'M' ? val : ~val) & 0xffffffff); + break; + default: + comperr("fldexpand"); + } + return 1; +} + static void -bfasg(NODE *p) +bfext(NODE *p) { - NODE *fn = p->n_left; - int shift = UPKFOFF(fn->n_rval); - int fsz = UPKFSZ(fn->n_rval); - int andval, tch = 0; - - /* get instruction size */ - switch (p->n_type) { - case CHAR: case UCHAR: tch = 'b'; break; - case SHORT: case USHORT: tch = 'w'; break; - case INT: case UNSIGNED: tch = 'l'; break; - default: comperr("bfasg"); - } - - /* put src into a temporary reg */ - fprintf(stdout, " mov%c ", tch); - adrput(stdout, getlr(p, 'R')); - fprintf(stdout, ","); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, "\n"); - - /* AND away the bits from dest */ - andval = ~(((1 << fsz) - 1) << shift); - fprintf(stdout, " and%c $%d,", tch, andval); - adrput(stdout, fn->n_left); - fprintf(stdout, "\n"); - - /* AND away unwanted bits from src */ - andval = ((1 << fsz) - 1); - fprintf(stdout, " and%c $%d,", tch, andval); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, "\n"); - - /* SHIFT left src number of bits */ - if (shift) { - fprintf(stdout, " sal%c $%d,", tch, shift); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, "\n"); + int ch = 0, sz = 0; + + if (ISUNSIGNED(p->n_right->n_type)) + return; + switch (p->n_right->n_type) { + case CHAR: + ch = 'b'; + sz = 8; + break; + case SHORT: + ch = 'w'; + sz = 16; + break; + case INT: + case LONG: + ch = 'l'; + sz = 32; + break; + default: + comperr("bfext"); } - /* OR in src to dest */ - fprintf(stdout, " or%c ", tch); - adrput(stdout, getlr(p, '1')); - fprintf(stdout, ","); - adrput(stdout, fn->n_left); - fprintf(stdout, "\n"); + sz -= UPKFSZ(p->n_left->n_rval); + printf("\tshl%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n\tsar%c $%d,", ch, sz); + adrput(stdout, getlr(p, 'D')); + printf("\n"); } /* @@ -318,7 +340,12 @@ expand(p, 0, " pushl AL\n"); expand(p, 0, " leal 8(%esp),A1\n"); expand(p, 0, " pushl A1\n"); - fprintf(fp, " call memcpy\n"); +#if defined(MACHOABI) + fprintf(fp, " call L%s$stub\n", EXPREFIX "memcpy"); + addstub(&stublist, "memcpy"); +#else + fprintf(fp, " call %s\n", EXPREFIX "memcpy"); +#endif fprintf(fp, " addl $12,%%esp\n"); } @@ -375,12 +402,12 @@ int jmplab; if (loadlab == 0) { - loadlab = getlab(); + loadlab = getlab2(); expand(p, 0, " .data\n"); printf(LABFMT ": .long 0,0x80000000,0x403f\n", loadlab); expand(p, 0, " .text\n"); } - jmplab = getlab(); + jmplab = getlab2(); expand(p, 0, " pushl UL\n pushl AL\n"); expand(p, 0, " fildq (%esp)\n"); expand(p, 0, " addl $8,%esp\n"); @@ -426,6 +453,8 @@ break; case 'C': /* remove from stack after subroutine call */ + if (p->n_left->n_flags & FSTDCALL) + break; pr = p->n_qual; if (p->n_op == STCALL || p->n_op == USTCALL) pr += 4; @@ -439,8 +468,8 @@ twollcomp(p); break; - case 'E': /* Assign to bitfield */ - bfasg(p); + case 'E': /* Perform bitfield sign-extension */ + bfext(p); break; case 'F': /* Structure argument */ @@ -491,7 +520,8 @@ else if (p->n_op == RS) ch = "ashr"; else if (p->n_op == LS) ch = "ashl"; else ch = 0, comperr("ZO"); - printf("\tcall __%sdi3\n\taddl $%d,%s\n", ch, pr, rnames[ESP]); + printf("\tcall " EXPREFIX "__%sdi3\n\taddl $%d,%s\n", + ch, pr, rnames[ESP]); break; case 'P': /* push hidden argument on stack */ @@ -508,7 +538,12 @@ printf("\tpushl $%d\n", p->n_stsize); expand(p, INAREG, "\tpushl AR\n"); expand(p, INAREG, "\tleal AL,%eax\n\tpushl %eax\n"); - printf("\tcall memcpy\n"); +#if defined(MACHOABI) + printf("\tcall L%s$stub\n", EXPREFIX "memcpy"); + addstub(&stublist, "memcpy"); +#else + printf("\tcall %s\n", EXPREFIX "memcpy"); +#endif printf("\taddl $12,%%esp\n"); break; @@ -578,7 +613,7 @@ int o = p->n_op; if (o==NAME || o==REG || o==ICON || o==OREG || - (o==UMUL && shumul(p->n_left))) + (o==UMUL && shumul(p->n_left, SOREG))) return(1); return(0); } @@ -593,7 +628,7 @@ if (o == OREG || o == REG || o == NAME) return SRDIR; /* Direct match */ - if (o == UMUL && shumul(p->n_left)) + if (o == UMUL && shumul(p->n_left, SOREG)) return SROREG; /* Convert into oreg */ return SRREG; /* put it into a register */ } @@ -717,6 +752,8 @@ case OREG: r = p->n_rval; + if (p->n_name[0]) + printf("%s%s", p->n_name, p->n_lval ? "+" : ""); if (p->n_lval) fprintf(io, "%d", (int)p->n_lval); if (R2TEST(r)) { @@ -726,12 +763,23 @@ fprintf(io, "(%s)", rnames[p->n_rval]); return; case ICON: +#ifdef PCC_DEBUG + /* Sanitycheck for PIC, to catch adressable constants */ + if (kflag && p->n_name[0] && 0) { + static int foo; + + if (foo++ == 0) { + printf("\nfailing...\n"); + fwalk(p, e2print, 0); + comperr("pass2 conput"); + } + } +#endif /* addressable value of the constant */ fputc('$', io); conput(io, p); return; - case MOVE: case REG: switch (p->n_type) { case LONGLONG: @@ -780,7 +828,7 @@ } static void -fixcalls(NODE *p) +fixcalls(NODE *p, void *arg) { /* Prepare for struct return by allocating bounce space on stack */ switch (p->n_op) { @@ -844,7 +892,7 @@ DLIST_FOREACH(ip, ipole, qelem) { if (ip->type != IP_NODE) continue; - walkf(ip->ip_node, fixcalls); + walkf(ip->ip_node, fixcalls, 0); storefloat(ip, ip->ip_node); } if (stkpos > p2autooff) @@ -859,7 +907,7 @@ * Remove some PCONVs after OREGs are created. */ static void -pconv2(NODE *p) +pconv2(NODE *p, void *arg) { NODE *q; @@ -884,7 +932,7 @@ void mycanon(NODE *p) { - walkf(p, pconv2); + walkf(p, pconv2, 0); } void @@ -1026,6 +1074,22 @@ for (p = p->n_right; p->n_op == CM; p = p->n_left) size += argsiz(p->n_right); size += argsiz(p); +#if defined(ELFABI) + if (kflag) + size -= 4; +#endif + + +#if defined(MACHOABI) + int newsize = (size + 15) & ~15; /* stack alignment */ + int align = newsize-size; + + if (align != 0) + printf(" subl $%d,%%esp\n", align); + + size=newsize; +#endif + op->n_qual = size; /* XXX */ } @@ -1047,6 +1111,177 @@ p->n_lval < 0 || p->n_lval > 0x7fffffff) break; return SRDIR; + case SMIXOR: + return tshape(p, SZERO); + case SMILWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || p->n_lval & 0xffffffff) + break; + return SRDIR; + case SMIHWXOR: + if (o != ICON || p->n_name[0] || + p->n_lval == 0 || (p->n_lval >> 32) != 0) + break; + return SRDIR; } return SRNOPE; } + +/* + * Target-dependent command-line options. + */ +void +mflags(char *str) +{ +} + +/* + * Do something target-dependent for xasm arguments. + */ +int +myxasm(struct interpass *ip, NODE *p) +{ + struct interpass *ip2; + NODE *in = 0, *ut = 0; + TWORD t; + char *w; + int reg; + int cw; + + cw = xasmcode(p->n_name); + if (cw & (XASMASG|XASMINOUT)) + ut = p->n_left; + if ((cw & XASMASG) == 0) + in = p->n_left; + + switch (XASMVAL(cw)) { + case 'D': reg = EDI; break; + case 'S': reg = ESI; break; + case 'a': reg = EAX; break; + case 'b': reg = EBX; break; + case 'c': reg = ECX; break; + case 'd': reg = EDX; break; + case 't': reg = 0; break; + case 'u': reg = 1; break; + case 'A': reg = EAXEDX; break; + case 'q': /* XXX let it be CLASSA as for now */ + p->n_name = tmpstrdup(p->n_name); + w = strchr(p->n_name, 'q'); + *w = 'r'; + return 0; + default: + return 0; + } + p->n_name = tmpstrdup(p->n_name); + for (w = p->n_name; *w; w++) + ; + w[-1] = 'r'; /* now reg */ + t = p->n_left->n_type; + if (reg == EAXEDX) { + p->n_label = CLASSC; + } else { + p->n_label = CLASSA; + if (t == CHAR || t == UCHAR) { + p->n_label = CLASSB; + reg = reg * 2 + 8; + } + } + if (t == FLOAT || t == DOUBLE || t == LDOUBLE) { + p->n_label = CLASSD; + reg += 037; + } + + if (in && ut) + in = tcopy(in); + p->n_left = mklnode(REG, 0, reg, t); + if (ut) { + ip2 = ipnode(mkbinode(ASSIGN, ut, tcopy(p->n_left), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + } + if (in) { + ip2 = ipnode(mkbinode(ASSIGN, tcopy(p->n_left), in, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + return 1; +} + +void +targarg(char *w, void *arg) +{ + NODE **ary = arg; + NODE *p, *q; + + p = ary[(int)w[1]-'0']->n_left; + if (optype(p->n_op) != LTYPE) + comperr("bad xarg op %d", p->n_op); + q = tcopy(p); + if (q->n_op == REG) { + if (*w == 'k') { + q->n_type = INT; + } else if (*w != 'w') { + if (q->n_type > UCHAR) { + regno(q) = regno(q)*2+8; + if (*w == 'h') + regno(q)++; + } + q->n_type = INT; + } else + q->n_type = SHORT; + } + adrput(stdout, q); + tfree(q); +} + +/* + * target-specific conversion of numeric arguments. + */ +int +numconv(void *ip, void *p1, void *q1) +{ + NODE *p = p1, *q = q1; + int cw = xasmcode(q->n_name); + + switch (XASMVAL(cw)) { + case 'a': + case 'b': + case 'c': + case 'd': + p->n_name = tmpcalloc(2); + p->n_name[0] = XASMVAL(cw); + return 1; + default: + return 0; + } +} + +static struct { + char *name; int num; +} xcr[] = { + { "eax", EAX }, + { "ebx", EBX }, + { "ecx", ECX }, + { "edx", EDX }, + { "ax", EAX }, + { "bx", EBX }, + { "cx", ECX }, + { "dx", EDX }, + { NULL, 0 }, +}; + +/* + * Check for other names of the xasm constraints registers. + */ + +/* + * Check for other names of the xasm constraints registers. + */ +int xasmconstregs(char *s) +{ + int i; + + for (i = 0; xcr[i].name; i++) + if (strcmp(xcr[i].name, s) == 0) + return xcr[i].num; + return -1; +} + Index: code.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/code.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/code.c -L usr.bin/pcc/i386/code.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/code.c +++ usr.bin/pcc/i386/code.c @@ -1,4 +1,4 @@ -/* $Id: code.c,v 1.15 2007/07/06 17:02:27 ragge Exp $ */ +/* $Id: code.c,v 1.38 2008/12/14 17:20:58 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -29,37 +29,62 @@ # include "pass1.h" -/* - * cause the alignment to become a multiple of n - * never called for text segment. - */ -void -defalign(int n) -{ - n /= SZCHAR; - if (n == 1) - return; - printf(" .align %d\n", n); -} +int lastloc = -1; /* - * define the current location as the name p->sname - * never called for text segment. + * Define everything needed to print out some data (or text). + * This means segment, alignment, visibility, etc. */ void -defnam(struct symtab *p) +defloc(struct symtab *sp) { - char *c = p->sname; + extern char *nextsect; +#if defined(ELFABI) || defined(PECOFFABI) + static char *loctbl[] = { "text", "data", "section .rodata" }; +#elif defined(MACHOABI) + static char *loctbl[] = { "text", "data", "const_data" }; +#endif + TWORD t; + int s; -#ifdef GCC_COMPAT - c = gcc_findname(p); + if (sp == NULL) { + lastloc = -1; + return; + } + t = sp->stype; + s = ISFTN(t) ? PROG : ISCON(cqual(t, sp->squal)) ? RDATA : DATA; +#ifdef TLS + if (sp->sflags & STLS) { + if (s != DATA) + cerror("non-data symbol in tls section"); + nextsect = ".tdata"; + } +#endif + if (sp->ssue->suesection) + nextsect = sp->ssue->suesection; + if (nextsect) { + printf(" .section %s\n", nextsect); + nextsect = NULL; + s = -1; + } else if (s != lastloc) + printf(" .%s\n", loctbl[s]); + lastloc = s; + while (ISARY(t)) + t = DECREF(t); + if (sp->ssue->suealign > ALCHAR) + printf(" .align %d\n", sp->ssue->suealign/ALCHAR); + if (sp->sclass == EXTDEF) + printf(" .globl %s\n", exname(sp->soname)); +#if defined(ELFABI) + if (ISFTN(t)) + printf("\t.type %s, at function\n", exname(sp->soname)); #endif - if (p->sclass == EXTDEF) - printf(" .globl %s\n", c); - printf("%s:\n", c); + if (sp->slevel == 0) + printf("%s:\n", exname(sp->soname)); + else + printf(LABFMT ":\n", sp->soffset); } - /* * code for the end of a function * deals with struct return here @@ -67,27 +92,21 @@ void efcode() { + extern int gotnr; NODE *p, *q; - int sz; + gotnr = 0; /* new number for next fun */ if (cftnsp->stype != STRTY+FTN && cftnsp->stype != UNIONTY+FTN) return; - /* address of return struct is in eax */ - /* create a call to memcpy() */ - /* will get the result in eax */ - p = block(REG, NIL, NIL, CHAR+PTR, 0, MKSUE(CHAR+PTR)); - p->n_rval = EAX; - q = block(OREG, NIL, NIL, CHAR+PTR, 0, MKSUE(CHAR+PTR)); + /* Create struct assignment */ + q = block(OREG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); q->n_rval = EBP; q->n_lval = 8; /* return buffer offset */ - p = block(CM, q, p, INT, 0, MKSUE(INT)); - sz = (tsize(STRTY, cftnsp->sdf, cftnsp->ssue)+SZCHAR-1)/SZCHAR; - p = block(CM, p, bcon(sz), INT, 0, MKSUE(INT)); - p->n_right->n_name = ""; - p = block(CALL, bcon(0), p, CHAR+PTR, 0, MKSUE(CHAR+PTR)); - p->n_left->n_name = "memcpy"; - p = clocal(p); - send_passt(IP_NODE, p); + q = buildtree(UMUL, q, NIL); + p = block(REG, NIL, NIL, PTR+STRTY, 0, cftnsp->ssue); + p = buildtree(UMUL, p, NIL); + p = buildtree(ASSIGN, q, p); + ecomp(p); } /* @@ -95,15 +114,86 @@ * indices in symtab for the arguments; n is the number */ void -bfcode(struct symtab **a, int n) +bfcode(struct symtab **sp, int cnt) { +#ifdef os_win32 + extern int argstacksize; +#endif + struct symtab *sp2; + extern int gotnr; + NODE *n, *p; int i; - if (cftnsp->stype != STRTY+FTN && cftnsp->stype != UNIONTY+FTN) + if (cftnsp->stype == STRTY+FTN || cftnsp->stype == UNIONTY+FTN) { + /* Function returns struct, adjust arg offset */ + for (i = 0; i < cnt; i++) + sp[i]->soffset += SZPOINT(INT); + } + +#ifdef os_win32 + /* + * Count the arguments and mangle name in symbol table as a callee. + */ + argstacksize = 0; + if (cftnsp->sflags & SSTDCALL) { + char buf[64]; + for (i = 0; i < cnt; i++) { + TWORD t = sp[i]->stype; + if (t == STRTY || t == UNIONTY) + argstacksize += sp[i]->ssue->suesize; + else + argstacksize += szty(t) * SZINT / SZCHAR; + } + snprintf(buf, 64, "%s@%d", cftnsp->soname, argstacksize); + cftnsp->soname = newstring(buf, strlen(buf)); + } +#endif + + if (kflag) { +#define STL 100 + char *str = inlalloc(STL); +#if !defined(MACHOABI) + int l = getlab(); +#endif + + /* Generate extended assembler for PIC prolog */ + p = tempnode(0, INT, 0, MKSUE(INT)); + gotnr = regno(p); + p = block(XARG, p, NIL, INT, 0, MKSUE(INT)); + p->n_name = "=g"; + p = block(XASM, p, bcon(0), INT, 0, MKSUE(INT)); +#if defined(MACHOABI) + if (snprintf(str, STL, "call L%s$pb\nL%s$pb:\n\tpopl %%0\n", + cftnsp->sname, cftnsp->sname) >= STL) + cerror("bfcode"); +#else + if (snprintf(str, STL, + "call " LABFMT "\n" LABFMT ":\n popl %%0\n" + " addl $_GLOBAL_OFFSET_TABLE_+[.-" LABFMT "], %%0\n", + l, l, l) >= STL) + cerror("bfcode"); +#endif + p->n_name = str; + p->n_right->n_type = STRTY; + ecomp(p); + } + if (xtemps == 0) return; - /* Function returns struct, adjust arg offset */ - for (i = 0; i < n; i++) - a[i]->soffset += SZPOINT(INT); + + /* put arguments in temporaries */ + for (i = 0; i < cnt; i++) { + if (sp[i]->stype == STRTY || sp[i]->stype == UNIONTY || + cisreg(sp[i]->stype) == 0) + continue; + if (cqual(sp[i]->stype, sp[i]->squal) & VOL) + continue; + sp2 = sp[i]; + n = tempnode(0, sp[i]->stype, sp[i]->sdf, sp[i]->ssue); + n = buildtree(ASSIGN, n, nametree(sp2)); + sp[i]->soffset = regno(n->n_left); + sp[i]->sflags |= STNODE; + ecomp(n); + } } @@ -116,60 +206,97 @@ SETOFF(autooff, SZINT); } +#if defined(MACHOABI) +struct stub stublist; +struct stub nlplist; +#endif + /* called just before final exit */ /* flag is 1 if errors, 0 if none */ void ejobcode(int flag ) { +#if defined(MACHOABI) + /* + * iterate over the stublist and output the PIC stubs +` */ + if (kflag) { + struct stub *p; + + DLIST_FOREACH(p, &stublist, link) { + printf("\t.section __IMPORT,__jump_table,symbol_stubs,self_modifying_code+pure_instructions,5\n"); + printf("L%s$stub:\n", p->name); + printf("\t.indirect_symbol %s\n", exname(p->name)); + printf("\thlt ; hlt ; hlt ; hlt ; hlt\n"); + printf("\t.subsections_via_symbols\n"); + } + + printf("\t.section __IMPORT,__pointers,non_lazy_symbol_pointers\n"); + DLIST_FOREACH(p, &nlplist, link) { + printf("L%s$non_lazy_ptr:\n", p->name); + printf("\t.indirect_symbol %s\n", exname(p->name)); + printf("\t.long 0\n"); + } + + } +#endif + +#define _MKSTR(x) #x +#define MKSTR(x) _MKSTR(x) +#define OS MKSTR(TARGOS) + printf("\t.ident \"PCC: %s (%s)\"\n", PACKAGE_STRING, OS); } void bjobcode() { +#if defined(MACHOABI) + DLIST_INIT(&stublist, link); + DLIST_INIT(&nlplist, link); +#endif } /* - * Print character t at position i in one string, until t == -1. - * Locctr & label is already defined. + * Called with a function call with arguments as argument. + * This is done early in buildtree() and only done once. + * Returns p. */ -void -bycode(int t, int i) +NODE * +funcode(NODE *p) { - static int lastoctal = 0; - - /* put byte i+1 in a string */ + extern int gotnr; + NODE *r, *l; - if (t < 0) { - if (i != 0) - puts("\""); + /* Fix function call arguments. On x86, just add funarg */ + for (r = p->n_right; r->n_op == CM; r = r->n_left) { + if (r->n_right->n_op != STARG) + r->n_right = block(FUNARG, r->n_right, NIL, + r->n_right->n_type, r->n_right->n_df, + r->n_right->n_sue); + } + if (r->n_op != STARG) { + l = talloc(); + *l = *r; + r->n_op = FUNARG; + r->n_left = l; + r->n_type = l->n_type; + } + if (kflag == 0) + return p; +#if defined(ELFABI) + /* Create an ASSIGN node for ebx */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + l = buildtree(ASSIGN, l, tempnode(gotnr, INT, 0, MKSUE(INT))); + if (p->n_right->n_op != CM) { + p->n_right = block(CM, l, p->n_right, INT, 0, MKSUE(INT)); } else { - if (i == 0) - printf("\t.ascii \""); - if (t == '\\' || t == '"') { - lastoctal = 0; - putchar('\\'); - putchar(t); - } else if (t < 040 || t >= 0177) { - lastoctal++; - printf("\\%o",t); - } else if (lastoctal && '0' <= t && t <= '9') { - lastoctal = 0; - printf("\"\n\t.ascii \"%c", t); - } else { - lastoctal = 0; - putchar(t); - } + for (r = p->n_right; r->n_left->n_op == CM; r = r->n_left) + ; + r->n_left = block(CM, l, r->n_left, INT, 0, MKSUE(INT)); } -} - -/* - * n integer words of zeros - */ -void -zecode(int n) -{ - printf(" .zero %d\n", n * (SZINT/SZCHAR)); -// inoff += n * SZINT; +#endif + return p; } /* @@ -188,26 +315,11 @@ { } -/* p points to an array of structures, each consisting - * of a constant value and a label. - * The first is >=0 if there is a default label; - * its value is the label number - * The entries p[1] to p[n] are the nontrivial cases +/* * XXX - fix genswitch. */ -void -genswitch(int num, struct swents **p, int n) +int +mygenswitch(int num, TWORD type, struct swents **p, int n) { - NODE *r; - int i; - - /* simple switch code */ - for (i = 1; i <= n; ++i) { - /* already in 1 */ - r = tempnode(num, INT, 0, MKSUE(INT)); - r = buildtree(NE, r, bcon(p[i]->sval)); - cbranch(buildtree(NOT, r, NIL), bcon(p[i]->slab)); - } - if (p[0]->slab > 0) - branch(p[0]->slab); + return 0; } Index: local.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/i386/local.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/i386/local.c -L usr.bin/pcc/i386/local.c -u -r1.1 -r1.2 --- usr.bin/pcc/i386/local.c +++ usr.bin/pcc/i386/local.c @@ -1,4 +1,4 @@ -/* $Id: local.c,v 1.56 2007/09/24 16:23:36 ragge Exp $ */ +/* $Id: local.c,v 1.95 2008/12/23 06:51:21 gmcgarry Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -31,6 +31,277 @@ /* this file contains code which is dependent on the target machine */ +/* + * Check if a constant is too large for a type. + */ +static int +toolarge(TWORD t, CONSZ con) +{ + U_CONSZ ucon = con; + + switch (t) { + case ULONGLONG: + case LONGLONG: + break; /* cannot be too large */ +#define SCHK(i) case i: if (con > MAX_##i || con < MIN_##i) return 1; break +#define UCHK(i) case i: if (ucon > MAX_##i) return 1; break + SCHK(INT); + SCHK(SHORT); + case BOOL: + SCHK(CHAR); + UCHK(UNSIGNED); + UCHK(USHORT); + UCHK(UCHAR); + default: + cerror("toolarge"); + } + return 0; +} + +#if defined(MACHOABI) + +/* + * Keep track of PIC stubs. + */ + +void +addstub(struct stub *list, char *name) +{ + struct stub *s; + + DLIST_FOREACH(s, list, link) { + if (strcmp(s->name, name) == 0) + return; + } + + s = permalloc(sizeof(struct stub)); + s->name = permalloc(strlen(name) + 1); + strcpy(s->name, name); + DLIST_INSERT_BEFORE(list, s, link); +} + +#endif + +#define IALLOC(sz) (isinlining ? permalloc(sz) : tmpalloc(sz)) + +#ifndef os_win32 +/* + * Make a symtab entry for PIC use. + */ +static struct symtab * +picsymtab(char *p, char *s, char *s2) +{ + struct symtab *sp = IALLOC(sizeof(struct symtab)); + size_t len = strlen(p) + strlen(s) + strlen(s2) + 1; + + sp->sname = sp->soname = IALLOC(len); + strlcpy(sp->soname, p, len); + strlcat(sp->soname, s, len); + strlcat(sp->soname, s2, len); + sp->sclass = EXTERN; + sp->sflags = sp->slevel = 0; + return sp; +} +#endif + +int gotnr; /* tempnum for GOT register */ +int argstacksize; + +/* + * Create a reference for an extern variable. + */ +static NODE * +picext(NODE *p) +{ + +#if defined(ELFABI) + + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@GOT"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, PTR|VOID, 0, MKSUE(VOID)); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; + +#elif defined(MACHOABI) + + NODE *q, *r; + struct symtab *sp; + char buf2[64]; + + if (p->n_sp->sclass == EXTDEF) { + snprintf(buf2, 64, "-L%s$pb", cftnsp->soname); + sp = picsymtab("", exname(p->n_sp->soname), buf2); + } else { + snprintf(buf2, 64, "$non_lazy_ptr-L%s$pb", cftnsp->soname); + sp = picsymtab("L", p->n_sp->soname, buf2); + addstub(&nlplist, p->n_sp->soname); + } + q = tempnode(gotnr, PTR+VOID, 0, MKSUE(VOID)); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + + if (p->n_sp->sclass != EXTDEF) + q = block(UMUL, q, 0, PTR+VOID, 0, MKSUE(VOID)); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; + +#elif defined(PECOFFABI) + + return p; + +#endif + +} + +/* + * Create a reference for a static variable. + */ +static NODE * +picstatic(NODE *p) +{ + +#if defined(ELFABI) + + NODE *q, *r; + struct symtab *sp; + + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + if (p->n_sp->slevel > 0) { + char buf[32]; + snprintf(buf, 32, LABFMT, (int)p->n_sp->soffset); + sp = picsymtab("", buf, "@GOTOFF"); + } else + sp = picsymtab("", p->n_sp->soname, "@GOTOFF"); + sp->sclass = STATIC; + sp->stype = p->n_sp->stype; + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + nfree(p); + return q; + +#elif defined(MACHOABI) + + NODE *q, *r; + struct symtab *sp; + char buf2[64]; + + snprintf(buf2, 64, "-L%s$pb", cftnsp->soname); + + if (p->n_sp->slevel > 0) { + char buf1[64]; + snprintf(buf1, 64, LABFMT, (int)p->n_sp->soffset); + sp = picsymtab("", buf1, buf2); + sp->sflags |= SNOUNDERSCORE; + } else { + sp = picsymtab("", exname(p->n_sp->soname), buf2); + } + sp->sclass = STATIC; + sp->stype = p->n_sp->stype; + q = tempnode(gotnr, PTR+VOID, 0, MKSUE(VOID)); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; + nfree(p); + return q; + +#elif defined(PECOFFABI) + + return p; + +#endif + +} + +#ifdef TLS +/* + * Create a reference for a TLS variable. + */ +static NODE * +tlspic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + + /* + * creates: + * leal var at TLSGD(%ebx),%eax + * call ___tls_get_addr at PLT + */ + + /* calc address of var at TLSGD */ + q = tempnode(gotnr, PTR|VOID, 0, MKSUE(VOID)); + sp = picsymtab("", p->n_sp->soname, "@TLSGD"); + r = xbcon(0, sp, INT); + q = buildtree(PLUS, q, r); + + /* assign to %eax */ + r = block(REG, NIL, NIL, PTR|VOID, 0, MKSUE(VOID)); + r->n_rval = EAX; + q = buildtree(ASSIGN, r, q); + + /* call ___tls_get_addr */ + sp2 = lookup("___tls_get_addr at PLT", 0); + sp2->stype = EXTERN|INT|FTN; + r = nametree(sp2); + r = buildtree(ADDROF, r, NIL); + r = block(UCALL, r, NIL, INT, 0, MKSUE(INT)); + + /* fusion both parts together */ + q = buildtree(COMOP, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsnonpic(NODE *p) +{ + NODE *q, *r; + struct symtab *sp, *sp2; + int ext = p->n_sp->sclass; + + sp = picsymtab("", p->n_sp->soname, + ext == EXTERN ? "@INDNTPOFF" : "@NTPOFF"); + q = xbcon(0, sp, INT); + if (ext == EXTERN) + q = block(UMUL, q, NIL, PTR|VOID, 0, MKSUE(VOID)); + + sp2 = lookup("%gs:0", 0); + sp2->stype = EXTERN|INT; + r = nametree(sp2); + + q = buildtree(PLUS, q, r); + q = block(UMUL, q, 0, p->n_type, p->n_df, p->n_sue); + q->n_sp = p->n_sp; /* for init */ + + nfree(p); + return q; +} + +static NODE * +tlsref(NODE *p) +{ + if (kflag) + return (tlspic(p)); + else + return (tlsnonpic(p)); +} +#endif + /* clocal() is called to do local transformations on * an expression tree preparitory to its being * written out in intermediate code. @@ -75,11 +346,23 @@ p = stref(block(STREF, r, p, 0, 0, 0)); break; + case USTATIC: + if (kflag == 0) + break; + /* FALLTHROUGH */ case STATIC: - if (q->slevel == 0) +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); break; - p->n_lval = 0; - p->n_sp = q; + } +#endif + if (kflag == 0) { + if (q->slevel == 0) + break; + p->n_lval = 0; + } else if (blevel > 0) + p = picstatic(p); break; case REGISTER: @@ -88,31 +371,72 @@ p->n_rval = q->soffset; break; + case EXTERN: + case EXTDEF: +#ifdef TLS + if (q->sflags & STLS) { + p = tlsref(p); + break; } +#endif + if (kflag == 0) + break; + if (blevel > 0) + p = picext(p); + break; + } break; - case STCALL: + case ADDROF: + if (kflag == 0 || blevel == 0) + break; + /* char arrays may end up here */ + l = p->n_left; + if (l->n_op != NAME || + (l->n_type != ARY+CHAR && l->n_type != ARY+WCHAR_TYPE)) + break; + l = p; + p = picstatic(p->n_left); + nfree(l); + if (p->n_op != UMUL) + cerror("ADDROF error"); + l = p; + p = p->n_left; + nfree(l); + break; + + case UCALL: + case USTCALL: + if (kflag == 0) + break; +#if defined(ELFABI) + /* Change to CALL node with ebx as argument */ + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_rval = EBX; + p->n_right = buildtree(ASSIGN, l, + tempnode(gotnr, INT, 0, MKSUE(INT))); + p->n_op -= (UCALL-CALL); +#endif + + /* FALLTHROUGH */ +#if defined(MACHOABI) case CALL: - /* Fix function call arguments. On x86, just add funarg */ - for (r = p->n_right; r->n_op == CM; r = r->n_left) { - if (r->n_right->n_op != STARG && - r->n_right->n_op != FUNARG) - r->n_right = block(FUNARG, r->n_right, NIL, - r->n_right->n_type, r->n_right->n_df, - r->n_right->n_sue); - } - if (r->n_op != STARG && r->n_op != FUNARG) { - l = talloc(); - *l = *r; - r->n_op = FUNARG; r->n_left = l; r->n_type = l->n_type; - } + case STCALL: + if (p->n_type == VOID) + break; + + r = tempnode(0, p->n_type, p->n_df, p->n_sue); + l = tcopy(r); + p = buildtree(COMOP, buildtree(ASSIGN, r, p), l); +#endif + break; - + case CBRANCH: l = p->n_left; /* - * Remove unneccessary conversion ops. + * Remove unnecessary conversion ops. */ if (clogop(l->n_op) && l->n_left->n_op == SCONV) { if (coptype(l->n_op) != BITYPE) @@ -121,6 +445,10 @@ r = l->n_left->n_left; if (r->n_type >= FLOAT && r->n_type <= LDOUBLE) break; + if (ISPTR(r->n_type)) + break; /* no opt for pointers */ + if (toolarge(r->n_type, l->n_right->n_lval)) + break; /* Type must be correct */ t = r->n_type; nfree(l->n_left); @@ -222,8 +550,6 @@ case UNSIGNED: l->n_lval = val & 0xffffffff; break; - case ENUMTY: - case MOETY: case LONG: case INT: l->n_lval = (int)val; @@ -249,6 +575,14 @@ l->n_sue = MKSUE(m); nfree(p); return l; + } else if (l->n_op == FCON) { + l->n_lval = l->n_dcon; + l->n_sp = NULL; + l->n_op = ICON; + l->n_type = m; + l->n_sue = MKSUE(m); + nfree(p); + return clocal(l); } if (DEUNSIGN(p->n_type) == SHORT && DEUNSIGN(l->n_type) == SHORT) { @@ -280,9 +614,10 @@ case PMCONV: case PVCONV: - if( p->n_right->n_op != ICON ) cerror( "bad conversion", 0); - nfree(p); - return(buildtree(o==PMCONV?MUL:DIV, p->n_left, p->n_right)); + r = p; + p = buildtree(o == PMCONV ? MUL : DIV, p->n_left, p->n_right); + nfree(r); + break; case FORCE: /* put return value in return reg */ @@ -297,8 +632,6 @@ case RS: /* shift count must be in a char * unless longlong, where it must be int */ - if (p->n_right->n_op == ICON) - break; /* do not do anything */ if (p->n_type == LONGLONG || p->n_type == ULONGLONG) { if (p->n_right->n_type != INT) p->n_right = block(SCONV, p->n_right, NIL, @@ -320,16 +653,115 @@ return(p); } +/* + * Change CALL references to either direct (static) or PLT. + */ +static void +fixnames(NODE *p, void *arg) +{ +#if !defined(PECOFFABI) + + struct symtab *sp; + struct suedef *sue; + NODE *q; + char *c; + int isu; + + if ((cdope(p->n_op) & CALLFLG) == 0) + return; + isu = 0; + q = p->n_left; + sue = q->n_sue; + if (q->n_op == UMUL) + q = q->n_left, isu = 1; + + if (q->n_op == PLUS && q->n_left->n_op == TEMP && + q->n_right->n_op == ICON) { + sp = q->n_right->n_sp; + + if (sp == NULL) + return; /* nothing to do */ + if (sp->sclass == STATIC && !ISFTN(sp->stype)) + return; /* function pointer */ + + if (sp->sclass != STATIC && sp->sclass != EXTERN && + sp->sclass != EXTDEF) + cerror("fixnames"); + +#if defined(ELFABI) + + if ((c = strstr(sp->soname, "@GOT")) == NULL) + cerror("fixnames2"); + if (isu) { + memcpy(c, "@PLT", sizeof("@PLT")); + } else + *c = 0; + +#elif defined(MACHOABI) + + if ((c = strstr(sp->soname, "$non_lazy_ptr")) == NULL && + (c = strstr(sp->soname, "-L")) == NULL) + cerror("fixnames2"); + if (isu) { + *c = 0; + addstub(&stublist, sp->soname+1); + strcpy(c, "$stub"); + } else + *c = 0; + +#endif + + nfree(q->n_left); + q = q->n_right; + if (isu) + nfree(p->n_left->n_left); + nfree(p->n_left); + p->n_left = q; + q->n_sue = sue; + } +#endif +} + void myp2tree(NODE *p) { + struct symtab *sp; + + if (kflag) + walkf(p, fixnames, 0); /* XXX walkf not needed */ + if (p->n_op != FCON) + return; + +#if 0 + /* put floating constants in memory */ + setloc1(RDATA); + defalign(ALLDOUBLE); + deflab1(i = getlab()); + ninval(0, btdims[p->n_type].suesize, p); +#endif + + sp = IALLOC(sizeof(struct symtab)); + sp->sclass = STATIC; + sp->ssue = MKSUE(p->n_type); + sp->slevel = 1; /* fake numeric label */ + sp->soffset = getlab(); + sp->sflags = 0; + sp->stype = p->n_type; + sp->squal = (CON >> TSHIFT); + + defloc(sp); + ninval(0, sp->ssue->suesize, p); + + p->n_op = NAME; + p->n_lval = 0; + p->n_sp = sp; } /*ARGSUSED*/ int andable(NODE *p) { - return(1); /* all names can have & taken on them */ + return(1); /* all names can have & taken on them */ } /* @@ -403,47 +835,38 @@ } -#if 0 -/* - * Print out an integer constant of size size. - * can only be sizes <= SZINT. - */ -void -indata(CONSZ val, int size) -{ - switch (size) { - case SZCHAR: - printf("\t.byte %d\n", (int)val & 0xff); - break; - case SZSHORT: - printf("\t.word %d\n", (int)val & 0xffff); - break; - case SZINT: - printf("\t.long %d\n", (int)val & 0xffffffff); - break; - default: - cerror("indata"); - } -} -#endif - /* * Print out a string of characters. * Assume that the assembler understands C-style escape - * sequences. Location is already set. + * sequences. */ void -instring(char *str) +instring(struct symtab *sp) { - char *s; + char *s, *str = sp->sname; + +#if defined(ELFABI) || defined(PECOFFABI) + + defloc(sp); + +#elif defined(MACHOABI) + + extern int lastloc; + if (lastloc != STRNG) + printf(" .cstring\n"); + lastloc = STRNG; + printf("\t.p2align 2\n"); + printf(LABFMT ":\n", sp->soffset); - /* be kind to assemblers and avoid?long strings */ +#endif + + /* be kind to assemblers and avoid long strings */ printf("\t.ascii \""); for (s = str; *s != 0; ) { if (*s++ == '\\') { (void)esccon(&s); } - if (s - str > 64) { + if (s - str > 60) { fwrite(str, 1, s - str, stdout); printf("\"\n\t.ascii \""); str = s; @@ -453,6 +876,28 @@ printf("\\0\"\n"); } +/* + * Print out a wide string by calling ninval(). + */ +void +inwstring(struct symtab *sp) +{ + char *s = sp->sname; + NODE *p; + + defloc(sp); + p = xbcon(0, NULL, WCHAR_TYPE); + do { + if (*s++ == '\\') + p->n_lval = esccon(&s); + else + p->n_lval = (unsigned char)s[-1]; + ninval(0, (MKSUE(WCHAR_TYPE))->suesize, p); + } while (s[-1] != 0); + nfree(p); +} + + static int inbits, inval; /* @@ -520,6 +965,9 @@ { union { float f; double d; long double l; int i[3]; } u; struct symtab *q; +#if defined(ELFABI) || defined(MACHOABI) + char *c; +#endif TWORD t; int i; @@ -527,6 +975,34 @@ if (t > BTMASK) t = INT; /* pointer */ + while (p->n_op == SCONV || p->n_op == PCONV) { + NODE *l = p->n_left; + l->n_type = p->n_type; + p = l; + } + + if (kflag && (p->n_op == PLUS || p->n_op == UMUL)) { + if (p->n_op == UMUL) + p = p->n_left; + p = p->n_right; + q = p->n_sp; + +#if defined(ELFABI) + + if ((c = strstr(q->soname, "@GOT")) != NULL) + *c = 0; /* ignore GOT ref here */ + +#elif defined(MACHOABI) + + if ((c = strstr(q->soname, "$non_lazy_ptr")) != NULL) { + q->soname++; /* skip "L" */ + *c = 0; /* ignore GOT ref here */ + } + else if ((c = strstr(q->soname, "-L")) != NULL) + *c = 0; /* ignore GOT ref here */ + +#endif + } if (p->n_op != ICON && p->n_op != FCON) cerror("ninval: init node not constant"); @@ -547,17 +1023,26 @@ case UNSIGNED: printf("\t.long 0x%x", (int)p->n_lval); if ((q = p->n_sp) != NULL) { - if ((q->sclass == STATIC && q->slevel > 0) || - q->sclass == ILABEL) { + if ((q->sclass == STATIC && q->slevel > 0)) { printf("+" LABFMT, q->soffset); - } else - printf("+%s", exname(q->sname)); + } else { +#if defined(MACHOABI) + if ((q->sflags & SNOUNDERSCORE) != 0) + printf("+%s", q->soname); + else +#endif + printf("+%s", exname(q->soname)); + } } printf("\n"); break; case SHORT: case USHORT: +#ifdef os_sunos + printf("\t.2byte 0x%x\n", (int)p->n_lval & 0xffff); +#else printf("\t.short 0x%x\n", (int)p->n_lval & 0xffff); +#endif break; case BOOL: if (p->n_lval > 1) @@ -570,11 +1055,20 @@ case LDOUBLE: u.i[2] = 0; u.l = (long double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + /* XXX probably broken on most hosts */ + printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[2], u.i[1], u.i[0]); +#else printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[0], u.i[1], u.i[2]); +#endif break; case DOUBLE: u.d = (double)p->n_dcon; +#if defined(HOST_BIG_ENDIAN) + printf("\t.long\t0x%x,0x%x\n", u.i[1], u.i[0]); +#else printf("\t.long\t0x%x,0x%x\n", u.i[0], u.i[1]); +#endif break; case FLOAT: u.f = (float)p->n_dcon; @@ -585,49 +1079,33 @@ } } -#if 0 -/* - * print out an integer. - */ -void -inval(CONSZ word) -{ - word &= 0xffffffff; - printf(" .long 0x%llx\n", word); -} - -/* output code to initialize a floating point value */ -/* the proper alignment has been obtained */ -void -finval(NODE *p) -{ - union { float f; double d; long double l; int i[3]; } u; - - switch (p->n_type) { - case LDOUBLE: - u.i[2] = 0; - u.l = (long double)p->n_dcon; - printf("\t.long\t0x%x,0x%x,0x%x\n", u.i[0], u.i[1], u.i[2]); - break; - case DOUBLE: - u.d = (double)p->n_dcon; - printf("\t.long\t0x%x,0x%x\n", u.i[0], u.i[1]); - break; - case FLOAT: - u.f = (float)p->n_dcon; - printf("\t.long\t0x%x\n", u.i[0]); - break; - } -} -#endif - /* make a name look like an external name in the local machine */ char * exname(char *p) { +#if defined(PECOFFABI) || defined(MACHOABI) + +#define NCHNAM 256 + static char text[NCHNAM+1]; + int i; + if (p == NULL) return ""; - return p; + + text[0] = '_'; + for (i=1; *p && istype, q->sdf, q->ssue); - off = (off+(SZCHAR-1))/SZCHAR; -#ifdef GCC_COMPAT - printf(" .comm %s,0%o\n", gcc_findname(q), off); -#else - printf(" .comm %s,0%o\n", exname(q->sname), off); +#ifdef TLS + if (sp->sflags & STLS) { + if (sp->sclass == EXTERN) + sp->sclass = EXTDEF; + simpleinit(sp, bcon(0)); + return; + } #endif + + al = talign(sp->stype, sp->ssue)/SZCHAR; + off = tsize(sp->stype, sp->sdf, sp->ssue); + off = (off+(SZCHAR-1))/SZCHAR; + printf(" .%scomm ", sp->sclass == STATIC ? "l" : ""); + if (sp->slevel == 0) + printf("%s,0%o", exname(sp->soname), off); + else + printf(LABFMT ",0%o", sp->soffset, off); + if (sp->sclass != STATIC) + printf(",%d", al); + printf("\n"); } -/* make a local common declaration for id, if reasonable */ -void -lcommdec(struct symtab *q) +static char * +section2string(char *name, int len) { - int off; +#if defined(ELFABI) + char *s; + int n; - off = tsize(q->stype, q->sdf, q->ssue); - off = (off+(SZCHAR-1))/SZCHAR; - if (q->slevel == 0) -#ifdef GCC_COMPAT - printf(" .lcomm %s,0%o\n", gcc_findname(q), off); -#else - printf(" .lcomm %s,0%o\n", exname(q->sname), off); + if (strncmp(name, "link_set", 8) == 0) { + const char *postfix = ",\"aw\", at progbits"; + n = len + strlen(postfix) + 1; + s = IALLOC(n); + strlcpy(s, name, n); + strlcat(s, postfix, n); + return s; + } #endif - else - printf(" .lcomm " LABFMT ",0%o\n", q->soffset, off); + + return newstring(name, len); } +char *nextsect; +#ifdef TLS +static int gottls; +#endif +#ifdef os_win32 +static int stdcall; +static int dllindirect; +#endif +static char *alias; +static int constructor; +static int destructor; + /* - * print a (non-prog) label. + * Give target the opportunity of handling pragmas. + */ +int +mypragma(char **ary) +{ +#ifdef TLS + if (strcmp(ary[1], "tls") == 0 && ary[2] == NULL) { + gottls = 1; + return 1; + } +#endif +#ifdef os_win32 + if (strcmp(ary[1], "stdcall") == 0) { + stdcall = 1; + return 1; + } + if (strcmp(ary[1], "cdecl") == 0) { + stdcall = 0; + return 1; + } + if (strcmp(ary[1], "fastcall") == 0) { + stdcall = 2; + return 1; + } + if (strcmp(ary[1], "dllimport") == 0) { + dllindirect = 1; + return 1; + } + if (strcmp(ary[1], "dllexport") == 0) { + dllindirect = 1; + return 1; + } +#endif + if (strcmp(ary[1], "constructor") == 0 || strcmp(ary[1], "init") == 0) { + constructor = 1; + return 1; + } + if (strcmp(ary[1], "destructor") == 0 || strcmp(ary[1], "fini") == 0) { + destructor = 1; + return 1; + } + if (strcmp(ary[1], "section") == 0 && ary[2] != NULL) { + nextsect = section2string(ary[2], strlen(ary[2])); + return 1; + } + if (strcmp(ary[1], "alias") == 0 && ary[2] != NULL) { + alias = tmpstrdup(ary[2]); + return 1; + } + if (strcmp(ary[1], "ident") == 0) + return 1; /* Just ignore */ + + return 0; +} + +/* + * Called when a identifier has been declared. */ void -deflab1(int label) +fixdef(struct symtab *sp) { - printf(LABFMT ":\n", label); +#ifdef TLS + /* may have sanity checks here */ + if (gottls) + sp->sflags |= STLS; + gottls = 0; +#endif + if (alias != NULL && (sp->sclass != PARAM)) { + printf("\t.globl %s\n", exname(sp->soname)); + printf("%s = ", exname(sp->soname)); + printf("%s\n", exname(alias)); + alias = NULL; + } + if ((constructor || destructor) && (sp->sclass != PARAM)) { +#if defined(ELFABI) + printf("\t.section .%ctors,\"aw\", at progbits\n", + constructor ? 'c' : 'd'); +#elif defined(PECOFFABI) + printf("\t.section .%ctors,\"w\"\n", + constructor ? 'c' : 'd'); +#elif defined(MACHOABI) + if (kflag) { + if (constructor) + printf("\t.mod_init_func\n"); + else + printf("\t.mod_term_func\n"); + } else { + if (constructor) + printf("\t.constructor\n"); + else + printf("\t.destructor\n"); + } +#endif + printf("\t.p2align 2\n"); + printf("\t.long %s\n", exname(sp->sname)); + constructor = destructor = 0; + } +#ifdef os_win32 + if (stdcall && (sp->sclass != PARAM)) { + sp->sflags |= SSTDCALL; + stdcall = 0; + } + if (dllindirect && (sp->sclass != PARAM)) { + sp->sflags |= SDLLINDIRECT; + dllindirect = 0; + } +#endif } -static char *loctbl[] = { "text", "data", "section .rodata", "section .rodata" }; +NODE * +i386_builtin_return_address(NODE *f, NODE *a) +{ + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; -void -setloc1(int locc) + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + f = block(PLUS, f, bcon(4), INCREF(PTR+VOID), 0, MKSUE(VOID)); + f = buildtree(UMUL, f, NIL); + + return f; +bad: + uerror("bad argument to __builtin_return_address"); + return bcon(0); +} + +NODE * +i386_builtin_frame_address(NODE *f, NODE *a) { - if (locc == lastloc) - return; - lastloc = locc; - printf(" .%s\n", loctbl[locc]); + int nframes; + + if (a == NULL || a->n_op != ICON) + goto bad; + + nframes = a->n_lval; + + tfree(f); + tfree(a); + + f = block(REG, NIL, NIL, PTR+VOID, 0, MKSUE(VOID)); + regno(f) = FPREG; + + while (nframes--) + f = block(UMUL, f, NIL, PTR+VOID, 0, MKSUE(VOID)); + + return f; +bad: + uerror("bad argument to __builtin_frame_address"); + return bcon(0); } -#if 0 -int -ftoint(NODE *p, CONSZ **c) +#ifdef os_win32 +/* + * Postfix external functions with the arguments size. + */ +static void +mangle(NODE *p, void *arg) { - static CONSZ cc[3]; - union { float f; double d; long double l; int i[3]; } u; - int n; + NODE *l, *r; + TWORD t; + int size = 0; + char buf[64]; - switch (p->n_type) { - case LDOUBLE: - u.i[2] = 0; - u.l = (long double)p->n_dcon; - n = SZLDOUBLE; - break; - case DOUBLE: - u.d = (double)p->n_dcon; - n = SZDOUBLE; - break; - case FLOAT: - u.f = (float)p->n_dcon; - n = SZFLOAT; - break; + if ((p->n_op == NAME || p->n_op == ICON) && + p->n_sp && (p->n_sp->sflags & SDLLINDIRECT) && p->n_name) { + snprintf(buf, 64, "__imp_%s", p->n_name); + p->n_name = IALLOC(strlen(buf) + 1); + strcpy(p->n_name, buf); + return; + } + + if (p->n_op != CALL && p->n_op != STCALL && + p->n_op != UCALL && p->n_op != USTCALL) + return; + + l = p->n_left; + if (l->n_op == ADDROF) + l = l->n_left; + if (l->n_sp == NULL) + return; + if (l->n_sp->sflags & SSTDCALL) { + if (strchr(l->n_name, '@') == NULL) { + if (p->n_op == CALL || p->n_op == STCALL) { + for (r = p->n_right; + r->n_op == CM; r = r->n_left) { + t = r->n_type; + if (t == STRTY || t == UNIONTY) + size += r->n_sue->suesize; + else + size += szty(t) * SZINT / SZCHAR; + } + t = r->n_type; + if (t == STRTY || t == UNIONTY) + size += r->n_sue->suesize; + else + size += szty(t) * SZINT / SZCHAR; + } + snprintf(buf, 64, "%s@%d", l->n_name, size); + l->n_name = IALLOC(strlen(buf) + 1); + strcpy(l->n_name, buf); + } + + l->n_flags = FSTDCALL; } - cc[0] = u.i[0]; - cc[1] = u.i[1]; - cc[2] = u.i[2]; - *c = cc; - return n; } #endif + +void +pass1_lastchance(struct interpass *ip) +{ +#ifdef os_win32 + if (ip->type == IP_EPILOG) { + struct interpass_prolog *ipp = (struct interpass_prolog *)ip; + ipp->ipp_argstacksize = argstacksize; + } + + if (ip->type == IP_NODE) + walkf(ip->ip_node, mangle, 0); +#endif +} Index: reader.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/reader.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/reader.c -L usr.bin/pcc/mip/reader.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/reader.c +++ usr.bin/pcc/mip/reader.c @@ -1,4 +1,4 @@ -/* $Id: reader.c,v 1.203 2007/09/24 17:49:54 ragge Exp $ */ +/* $Id: reader.c,v 1.248 2008/12/03 07:08:40 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -61,12 +61,8 @@ */ /* - * Everything is entered via pass2_compile(). Three functions are - * allowed to recurse into pass2_compile(), so be careful: - * - deluseless() - * - myreader() - * Especially in myreader note that trees may be rewritten twice if - * things are not carefully handled. + * Everything is entered via pass2_compile(). No functions are + * allowed to recurse back into pass2_compile(). */ # include "pass2.h" @@ -86,59 +82,185 @@ NODE *nodepole; FILE *prfil; -static struct interpass prepole; +struct interpass prepole; void saveip(struct interpass *ip); -void deljumps(void); -void deltemp(NODE *p); -void mkhardops(NODE *p); -void optdump(struct interpass *ip); -void cvtemps(struct interpass *epil); +void deltemp(NODE *p, void *); +static void cvtemps(struct interpass *ipole, int op, int off); NODE *store(NODE *); -void rcount(void); -void compile2(struct interpass *ip); -void compile3(struct interpass *ip); -void compile4(struct interpass *ip); +static void fixxasm(struct p2env *); static void gencode(NODE *p, int cookie); +static void genxasm(NODE *p); -char *ltyp[] = { "", "LREG", "LOREG", "LTEMP" }; -char *rtyp[] = { "", "RREG", "ROREG", "RTEMP" }; +struct p2env p2env; -/* used when removing nodes */ -struct tmpsave { - struct tmpsave *next; - CONSZ tempaddr; - int tempno; -} *tmpsave; +int +getlab2(void) +{ + extern int getlab(void); + int rv = getlab(); +#ifdef PCC_DEBUG + if (p2env.epp->ip_lblnum != rv) + comperr("getlab2 error: %d != %d", p2env.epp->ip_lblnum, rv); +#endif + p2env.epp->ip_lblnum++; + return rv; +} #ifdef PCC_DEBUG +static int *lbldef, *lbluse; static void -cktree(NODE *p) +cktree(NODE *p, void *arg) { + int i; + if (p->n_op > MAXOP) - cerror("op %d slipped through", p->n_op); + cerror("%p) op %d slipped through", p, p->n_op); if (BTYPE(p->n_type) > MAXTYPES) - cerror("type %x slipped through", p->n_type); - if (p->n_op == CBRANCH && !logop(p->n_left->n_op)) - cerror("not logop branch"); + cerror("%p) type %x slipped through", p, p->n_type); + if (p->n_op == CBRANCH) { + if (!logop(p->n_left->n_op)) + cerror("%p) not logop branch", p); + i = p->n_right->n_lval; + if (i < p2env.ipp->ip_lblnum || i >= p2env.epp->ip_lblnum) + cerror("%p) label %d outside boundaries %d-%d", + p, i, p2env.ipp->ip_lblnum, p2env.epp->ip_lblnum); + lbluse[i-p2env.ipp->ip_lblnum] = 1; + } if ((dope[p->n_op] & ASGOPFLG) && p->n_op != RETURN) - cerror("asgop %d slipped through", p->n_op); + cerror("%p) asgop %d slipped through", p, p->n_op); + if (p->n_op == TEMP && + (regno(p) < p2env.ipp->ip_tmpnum || regno(p) >= p2env.epp->ip_tmpnum)) + cerror("%p) temporary %d outside boundaries %d-%d", + p, regno(p), p2env.ipp->ip_tmpnum, p2env.epp->ip_tmpnum); + if (p->n_op == GOTO) { + i = p->n_left->n_lval; + if (i < p2env.ipp->ip_lblnum || i >= p2env.epp->ip_lblnum) + cerror("%p) label %d outside boundaries %d-%d", + p, i, p2env.ipp->ip_lblnum, p2env.epp->ip_lblnum); + lbluse[i-p2env.ipp->ip_lblnum] = 1; + } +} + +/* + * Check that the trees are in a suitable state for pass2. + */ +static void +sanitychecks(struct p2env *p2e) +{ + struct interpass *ip; + int i; +#ifdef notyet + TMPMARK(); +#endif + lbldef = tmpcalloc(sizeof(int) * (p2e->epp->ip_lblnum - p2e->ipp->ip_lblnum)); + lbluse = tmpcalloc(sizeof(int) * (p2e->epp->ip_lblnum - p2e->ipp->ip_lblnum)); + + DLIST_FOREACH(ip, &p2env.ipole, qelem) { + if (ip->type == IP_DEFLAB) { + i = ip->ip_lbl; + if (i < p2e->ipp->ip_lblnum || i >= p2e->epp->ip_lblnum) + cerror("label %d outside boundaries %d-%d", + i, p2e->ipp->ip_lblnum, p2e->epp->ip_lblnum); + lbldef[i-p2e->ipp->ip_lblnum] = 1; + } + if (ip->type == IP_NODE) + walkf(ip->ip_node, cktree, 0); + } + for (i = 0; i < (p2e->epp->ip_lblnum - p2e->ipp->ip_lblnum); i++) + if (lbluse[i] != 0 && lbldef[i] == 0) + cerror("internal label %d not defined", + i + p2e->ipp->ip_lblnum); + +#ifdef notyet + TMPFREE(); +#endif } #endif /* + * Look if a temporary comes from a on-stack argument, in that case + * use the already existing stack position instead of moving it to + * a new place, and remove the move-to-temp statement. + */ +static int +stkarg(int tnr, int *soff) +{ + struct p2env *p2e = &p2env; + struct interpass *ip; + NODE *p; + + ip = DLIST_NEXT((struct interpass *)p2e->ipp, qelem); + while (ip->type != IP_DEFLAB) /* search for first DEFLAB */ + ip = DLIST_NEXT(ip, qelem); + + ip = DLIST_NEXT(ip, qelem); /* first NODE */ + + for (; ip->type != IP_DEFLAB; ip = DLIST_NEXT(ip, qelem)) { + if (ip->type != IP_NODE) + continue; + + p = ip->ip_node; + if (p->n_op == XASM) + continue; /* XXX - hack for x86 PIC */ +#ifdef PCC_DEBUG + if (p->n_op != ASSIGN || p->n_left->n_op != TEMP) + comperr("temparg"); +#endif + if (p->n_right->n_op != OREG && p->n_right->n_op != UMUL) + continue; /* arg in register */ + if (tnr != regno(p->n_left)) + continue; /* wrong assign */ + p = p->n_right; + if (p->n_op == UMUL && + p->n_left->n_op == PLUS && + p->n_left->n_left->n_op == REG && + p->n_left->n_right->n_op == ICON) + *soff = p->n_left->n_right->n_lval; + else if (p->n_op == OREG) + *soff = p->n_lval; + else + comperr("stkarg: bad arg"); + tfree(ip->ip_node); + DLIST_REMOVE(ip, qelem); + return 1; + } + return 0; +} + +/* + * See if an ADDROF is somewhere inside the expression tree. + * If so, fill in the offset table. + */ +static void +findaof(NODE *p, void *arg) +{ + int *aof = arg; + int tnr; + + if (p->n_op != ADDROF) + return; + tnr = regno(p->n_left); + if (aof[tnr]) + return; /* already gotten stack address */ + if (stkarg(tnr, &aof[tnr])) + return; /* argument was on stack */ + aof[tnr] = BITOOR(freetemp(szty(p->n_left->n_type))); +} + +/* * Check if a node has side effects. */ static int isuseless(NODE *n) { switch (n->n_op) { + case XASM: case FUNARG: case UCALL: case UFORTCALL: case FORCE: -/* case INIT: */ case ASSIGN: case CALL: case FORTCALL: @@ -158,7 +280,7 @@ /* * Delete statements with no meaning (like a+b; or 513.4;) */ -static NODE * +NODE * deluseless(NODE *p) { struct interpass *ip; @@ -192,70 +314,111 @@ return NULL; } -static struct interpass ipole; -struct interpass_prolog *ipp, *epp; - /* * Receives interpass structs from pass1. */ void pass2_compile(struct interpass *ip) { + struct p2env *p2e = &p2env; + int *addrp; + MARK mark; + if (ip->type == IP_PROLOG) { - tmpsave = NULL; - ipp = (struct interpass_prolog *)ip; - DLIST_INIT(&ipole, qelem); + memset(p2e, 0, sizeof(struct p2env)); + p2e->ipp = (struct interpass_prolog *)ip; + DLIST_INIT(&p2e->ipole, qelem); } - DLIST_INSERT_BEFORE(&ipole, ip, qelem); + DLIST_INSERT_BEFORE(&p2e->ipole, ip, qelem); if (ip->type != IP_EPILOG) return; #ifdef PCC_DEBUG if (e2debug) { printf("Entering pass2\n"); - printip(&ipole); + printip(&p2e->ipole); } #endif - epp = (struct interpass_prolog *)DLIST_PREV(&ipole, qelem); - p2maxautooff = p2autooff = epp->ipp_autos; + p2e->epp = (struct interpass_prolog *)DLIST_PREV(&p2e->ipole, qelem); + p2maxautooff = p2autooff = p2e->epp->ipp_autos; - myreader(&ipole); /* local massage of input */ +#ifdef PCC_DEBUG + sanitychecks(p2e); +#endif + myreader(&p2e->ipole); /* local massage of input */ + + /* + * Do initial modification of the trees. Two loops; + * - first, search for ADDROF of TEMPs, these must be + * converterd to OREGs on stack. + * - second, do the actual conversions, in case of not xtemps + * convert all temporaries to stack references. + */ + markset(&mark); + if (p2e->epp->ip_tmpnum != p2e->ipp->ip_tmpnum) { + addrp = tmpcalloc(sizeof(int) * + (p2e->epp->ip_tmpnum - p2e->ipp->ip_tmpnum)); + addrp -= p2e->ipp->ip_tmpnum; + } else + addrp = NULL; + if (xtemps) { + DLIST_FOREACH(ip, &p2e->ipole, qelem) { + if (ip->type == IP_NODE) + walkf(ip->ip_node, findaof, addrp); + } + } + DLIST_FOREACH(ip, &p2e->ipole, qelem) + if (ip->type == IP_NODE) + walkf(ip->ip_node, deltemp, addrp); + markfree(&mark); + +#ifdef PCC_DEBUG + if (e2debug) { + printf("Efter ADDROF/TEMP\n"); + printip(&p2e->ipole); + } +#endif - DLIST_FOREACH(ip, &ipole, qelem) { +#if 0 + DLIST_FOREACH(ip, &p2e->ipole, qelem) { if (ip->type != IP_NODE) continue; if (xtemps == 0) - walkf(ip->ip_node, deltemp); + walkf(ip->ip_node, deltemp, 0); } +#endif + DLIST_INIT(&prepole, qelem); - DLIST_FOREACH(ip, &ipole, qelem) { + DLIST_FOREACH(ip, &p2e->ipole, qelem) { if (ip->type != IP_NODE) continue; canon(ip->ip_node); - walkf(ip->ip_node, cktree); if ((ip->ip_node = deluseless(ip->ip_node)) == NULL) { DLIST_REMOVE(ip, qelem); } else while (!DLIST_ISEMPTY(&prepole, qelem)) { - struct interpass *ipp; + struct interpass *tipp; - ipp = DLIST_NEXT(&prepole, qelem); - DLIST_REMOVE(ipp, qelem); - DLIST_INSERT_BEFORE(ip, ipp, qelem); + tipp = DLIST_NEXT(&prepole, qelem); + DLIST_REMOVE(tipp, qelem); + DLIST_INSERT_BEFORE(ip, tipp, qelem); } } - optimize(&ipole); - ngenregs(&ipole); + fixxasm(p2e); /* setup for extended asm */ - DLIST_FOREACH(ip, &ipole, qelem) + optimize(p2e); + ngenregs(p2e); + + DLIST_FOREACH(ip, &p2e->ipole, qelem) emit(ip); } void emit(struct interpass *ip) { - NODE *p; + NODE *p, *r; + struct optab *op; int o; switch (ip->type) { @@ -263,23 +426,36 @@ p = ip->ip_node; nodepole = p; -//printf("bu:\n"); -//fwalk(p, e2print, 0); canon(p); /* may convert stuff after genregs */ -//fwalk(p, e2print, 0); + if (c2debug > 1) { + printf("emit IP_NODE:\n"); + fwalk(p, e2print, 0); + } switch (p->n_op) { case CBRANCH: /* Only emit branch insn if RESCC */ - if (table[TBLIDX(p->n_left->n_su)].rewrite & RESCC) { + /* careful when an OPLOG has been elided */ + if (p->n_left->n_su == 0 && p->n_left->n_left != NULL) { + op = &table[TBLIDX(p->n_left->n_left->n_su)]; + r = p->n_left; + } else { + op = &table[TBLIDX(p->n_left->n_su)]; + r = p; + } + if (op->rewrite & RESCC) { o = p->n_left->n_op; - gencode(p, FORCC); + gencode(r, FORCC); cbgen(o, p->n_right->n_lval); - } else - gencode(p, FORCC); + } else { + gencode(r, FORCC); + } break; case FORCE: gencode(p->n_left, INREGS); break; + case XASM: + genxasm(p); + break; default: if (p->n_op != REG || p->n_type != VOID) /* XXX */ gencode(p, FOREFF); /* Emit instructions */ @@ -292,17 +468,16 @@ break; case IP_EPILOG: eoftn((struct interpass_prolog *)ip); - tmpsave = NULL; /* Always forget old nodes */ p2maxautooff = p2autooff = AUTOINIT/SZCHAR; break; case IP_DEFLAB: deflab(ip->ip_lbl); break; case IP_ASM: - printf("\t%s\n", ip->ip_asm); + printf("%s", ip->ip_asm); break; default: - cerror("compile4 %d", ip->type); + cerror("emit %d", ip->type); } } @@ -370,7 +545,7 @@ geninsn(NODE *p, int cookie) { NODE *p1, *p2; - int o, rv = 0; + int q, o, rv = 0; #ifdef PCC_DEBUG if (odebug) { @@ -379,6 +554,9 @@ } #endif + q = cookie & QUIET; + cookie &= ~QUIET; /* XXX - should not be necessary */ + again: switch (o = p->n_op) { case EQ: case NE: @@ -390,6 +568,18 @@ case ULT: case UGE: case UGT: + p1 = p->n_left; + p2 = p->n_right; + if (p2->n_op == ICON && p2->n_lval == 0 && + optype(p1->n_op) == BITYPE) { +#ifdef mach_pdp11 /* XXX all targets? */ + if ((rv = geninsn(p1, FORCC|QUIET)) != FFAIL) + break; +#else + if (findops(p1, FORCC) > 0) + break; +#endif + } rv = relops(p); break; @@ -407,6 +597,11 @@ break; case ASSIGN: +#ifdef FINDMOPS + if ((rv = findmops(p, cookie)) != FFAIL) + break; + /* FALLTHROUGH */ +#endif case STASG: rv = findasg(p, cookie); break; @@ -419,6 +614,7 @@ case TEMP: case NAME: case ICON: + case FCON: case OREG: rv = findleaf(p, cookie); break; @@ -427,9 +623,10 @@ case CALL: /* CALL arguments are handled special */ for (p1 = p->n_right; p1->n_op == CM; p1 = p1->n_left) - geninsn(p1->n_right, FOREFF); - geninsn(p1, FOREFF); + (void)geninsn(p1->n_right, FOREFF); + (void)geninsn(p1, FOREFF); /* FALLTHROUGH */ + case FLD: case COMPL: case UMINUS: case PCONV: @@ -440,6 +637,7 @@ case STARG: case UCALL: case USTCALL: + case ADDROF: rv = finduni(p, cookie); break; @@ -447,23 +645,39 @@ p1 = p->n_left; p2 = p->n_right; p1->n_label = p2->n_lval; - o = p1->n_op; - geninsn(p1, FORCC); + (void)geninsn(p1, FORCC); p->n_su = 0; break; case FORCE: /* XXX needed? */ - geninsn(p->n_left, INREGS); + (void)geninsn(p->n_left, INREGS); p->n_su = 0; /* su calculations traverse left */ break; + case XASM: + for (p1 = p->n_left; p1->n_op == CM; p1 = p1->n_left) + (void)geninsn(p1->n_right, FOREFF); + (void)geninsn(p1, FOREFF); + break; /* all stuff already done? */ + + case XARG: + /* generate code for correct class here */ +// geninsn(p->n_left, 1 << p->n_label); + break; + default: comperr("geninsn: bad op %s, node %p", opst[o], p); } - if (rv == FFAIL) + if (rv == FFAIL && !q) comperr("Cannot generate code, node %p op %s", p,opst[p->n_op]); if (rv == FRETRY) goto again; +#ifdef PCC_DEBUG + if (odebug) { + printf("geninsn(%p, %s) rv %d\n", p, prcook(cookie), rv); + fwalk(p, e2print, 0); + } +#endif return rv; } @@ -514,7 +728,7 @@ * Rewrite node to register after instruction emit. */ static void -rewrite(NODE *p, int rewrite, int cookie) +rewrite(NODE *p, int dorewrite, int cookie) { NODE *l, *r; int o; @@ -550,18 +764,75 @@ tfree(l); if (optype(o) == BITYPE) tfree(r); - if (rewrite == 0) + if (dorewrite == 0) return; - CDEBUG(("rewrite: %p, reg %s\n", p, rnames[DECRA(p->n_reg, 0)])); + CDEBUG(("rewrite: %p, reg %s\n", p, + p->n_reg == -1? "" : rnames[DECRA(p->n_reg, 0)])); p->n_rval = DECRA(p->n_reg, 0); } +#ifndef XASM_TARGARG +#define XASM_TARGARG(x,y) 0 +#endif + +/* + * printout extended assembler. + */ +void +genxasm(NODE *p) +{ + NODE *q, **nary; + int n = 1, o = 0; + char *w; + + if (p->n_left->n_op != ICON || p->n_left->n_type != STRTY) { + for (q = p->n_left; q->n_op == CM; q = q->n_left) + n++; + nary = tmpalloc(sizeof(NODE *)*n); + o = n; + for (q = p->n_left; q->n_op == CM; q = q->n_left) { + gencode(q->n_right->n_left, INREGS); + nary[--o] = q->n_right; + } + gencode(q->n_left, INREGS); + nary[--o] = q; + } else + nary = 0; + + w = p->n_name; + putchar('\t'); + while (*w != 0) { + if (*w == '%') { + if (w[1] == '%') + putchar('%'); + else if (XASM_TARGARG(w, nary)) + ; /* handled by target */ + else if (w[1] < '0' || w[1] > (n + '0')) + uerror("bad xasm arg number %c", w[1]); + else + adrput(stdout, nary[(int)w[1]-'0']->n_left); + w++; + } else if (*w == '\\') { /* Always 3-digit octal */ + int num = *++w - '0'; + num = (num << 3) + *++w - '0'; + num = (num << 3) + *++w - '0'; + putchar(num); + } else + putchar(*w); + w++; + } + putchar('\n'); +} + void gencode(NODE *p, int cookie) { struct optab *q = &table[TBLIDX(p->n_su)]; NODE *p1, *l, *r; int o = optype(p->n_op); +#ifdef FINDMOPS + int ismops = (p->n_op == ASSIGN && (p->n_flags & 1)); +#endif l = p->n_left; r = p->n_right; @@ -598,7 +869,12 @@ } if (o != LTYPE) { gencode(l, INREGS); - if (q->rewrite & RLEFT) +#ifdef FINDMOPS + if (ismops) + ; + else +#endif + if (q->rewrite & RLEFT) ckmove(p, l); } if (o == BITYPE && !(p->n_su & DORIGHT)) { @@ -607,6 +883,18 @@ ckmove(p, r); } +#ifdef FINDMOPS + if (ismops) { + /* reduce right tree to make expand() work */ + if (optype(r->n_op) != LTYPE) { + p->n_op = r->n_op; + r = tcopy(r->n_right); + tfree(p->n_right); + p->n_right = r; + } + } +#endif + canon(p); if (q->needs & NSPECIAL) { @@ -614,6 +902,10 @@ int lr = rspecial(q, NLEFT); if (rr >= 0) { +#ifdef PCC_DEBUG + if (optype(p->n_op) != BITYPE) + comperr("gencode: rspecial borked"); +#endif if (r->n_op != REG) comperr("gencode: rop != REG"); if (rr != r->n_rval) @@ -633,7 +925,8 @@ if (p->n_op == ASSIGN && p->n_left->n_op == REG && p->n_right->n_op == REG && - p->n_left->n_rval == p->n_right->n_rval){ + p->n_left->n_rval == p->n_right->n_rval && + (p->n_su & RVCC) == 0) { /* XXX should check if necessary */ /* do not emit anything */ CDEBUG(("gencode(%p) assign nothing\n", p)); rewrite(p, q->rewrite, cookie); @@ -645,6 +938,12 @@ return; expand(p, cookie, q->cstring); +#ifdef FINDMOPS + if (ismops && DECRA(p->n_reg, 0) != regno(l) && cookie != FOREFF) { + CDEBUG(("gencode(%p) rmove\n", p)); + rmove(regno(l), DECRA(p->n_reg, 0), p->n_type); + } else +#endif if (callop(p->n_op) && cookie != FOREFF && DECRA(p->n_reg, 0) != RETREG(p->n_type)) { CDEBUG(("gencode(%p) retreg\n", p)); @@ -681,6 +980,7 @@ } int negrel[] = { NE, EQ, GT, GE, LT, LE, UGT, UGE, ULT, ULE } ; /* negatives of relationals */ +size_t negrelsize = sizeof negrel / sizeof negrel[0]; #ifdef PCC_DEBUG #undef PRTABLE @@ -708,7 +1008,12 @@ break; case TEMP: - fprintf(prfil, " " CONFMT, p->n_lval); + fprintf(prfil, " %d", regno(p)); + break; + + case XASM: + case XARG: + fprintf(prfil, " '%s'", p->n_name); break; case ICON: @@ -730,16 +1035,9 @@ fprintf(prfil, ", " ); tprint(prfil, p->n_type, p->n_qual); fprintf(prfil, ", " ); - { - int gregn(struct regw *); - if (p->n_reg == -1) - fprintf(prfil, "REG "); - else if (p->n_reg < 100000) /* XXX */ - fprintf(prfil, "REG %s", rnames[DECRA(p->n_reg, 0)]); - else - fprintf(prfil, "TEMP %d", gregn(p->n_regw)); - } - fprintf(prfil, ", SU= %d(%cREG,%s,%s,%s,%s)\n", + + prtreg(prfil, p); + fprintf(prfil, ", SU= %d(%cREG,%s,%s,%s,%s,%s,%s)\n", TBLIDX(p->n_su), TCLASS(p->n_su)+'@', #ifdef PRTABLE @@ -748,8 +1046,9 @@ #else "", #endif - ltyp[LMASK&p->n_su], - rtyp[(p->n_su&RMASK) >> 2], p->n_su & DORIGHT ? "DORIGHT" : ""); + p->n_su & LREG ? "LREG" : "", p->n_su & RREG ? "RREG" : "", + p->n_su & RVEFF ? "RVEFF" : "", p->n_su & RVCC ? "RVCC" : "", + p->n_su & DORIGHT ? "DORIGHT" : ""); } #endif @@ -815,35 +1114,32 @@ * change left TEMPs into OREGs */ void -deltemp(NODE *p) +deltemp(NODE *p, void *arg) { - struct tmpsave *w; - NODE *l; + int *aor = arg; + NODE *l, *r; if (p->n_op == TEMP) { - /* Check if already existing */ - for (w = tmpsave; w; w = w->next) - if (w->tempno == p->n_lval) - break; - if (w == NULL) { - /* new on stack */ - w = tmpalloc(sizeof(struct tmpsave)); - w->tempno = p->n_lval; - w->tempaddr = BITOOR(freetemp(szty(p->n_type))); - w->next = tmpsave; - tmpsave = w; - } - p->n_op = OREG; - p->n_rval = FPREG; - p->n_lval = w->tempaddr; - } else if (p->n_op == ADDROF) { - /* TEMPs are already converted to OREGs */ - if ((l = p->n_left)->n_op != OREG) - comperr("bad U&"); + if (aor[regno(p)] == 0) { + if (xtemps) + return; + aor[regno(p)] = BITOOR(freetemp(szty(p->n_type))); + } + l = mklnode(REG, 0, FPREG, INCREF(p->n_type)); + r = mklnode(ICON, aor[regno(p)], 0, INT); + p->n_left = mkbinode(PLUS, l, r, INCREF(p->n_type)); + p->n_op = UMUL; + } else if (p->n_op == ADDROF && p->n_left->n_op == OREG) { p->n_op = PLUS; + l = p->n_left; l->n_op = REG; l->n_type = INCREF(l->n_type); p->n_right = mklnode(ICON, l->n_lval, 0, INT); + } else if (p->n_op == ADDROF && p->n_left->n_op == UMUL) { + l = p->n_left; + *p = *p->n_left->n_left; + nfree(l->n_left); + nfree(l); } } @@ -851,7 +1147,7 @@ * for pointer/integer arithmetic, set pointer at left node */ static void -setleft(NODE *p) +setleft(NODE *p, void *arg) { NODE *q; @@ -909,10 +1205,10 @@ int i; if( (r=base(ql))>=0 && (i=offset(qr, tlen(p)))>=0) { makeor2(p, ql, r, i); - return; + return 1; } else if((r=base(qr))>=0 && (i=offset(ql, tlen(p)))>=0) { makeor2(p, qr, r, i); - return; + return 1; } } @@ -966,7 +1262,7 @@ * look for situations where we can turn * into OREG */ void -oreg2(NODE *p) +oreg2(NODE *p, void *arg) { if (p->n_op != UMUL) return; @@ -980,14 +1276,12 @@ canon(p) NODE *p; { /* put p in canonical form */ - walkf(p, setleft); /* ptrs at left node for arithmetic */ - walkf(p, oreg2); /* look for and create OREG nodes */ + walkf(p, setleft, 0); /* ptrs at left node for arithmetic */ + walkf(p, oreg2, 0); /* look for and create OREG nodes */ #ifndef FIELDOPS fwalk(p, ffld, 0); /* look for field operators */ # endif -#ifdef MYCANON - MYCANON(p); /* your own canonicalization routine(s) */ -#endif + mycanon(p); /* your own canonicalization routine(s) */ } @@ -997,6 +1291,12 @@ extern char *ftitle; va_list ap; + if (nerrors) { + fprintf(stderr, + "cannot recover from earlier errors: goodbye!\n"); + exit(1); + } + va_start(ap, str); fprintf(stderr, "%s, line %d: compiler error: ", ftitle, thisline); vfprintf(stderr, str, ap); @@ -1004,8 +1304,10 @@ va_end(ap); prfil = stderr; +#ifdef PCC_DEBUG if (nodepole && nodepole->n_op != FREE) fwalk(nodepole, e2print, 0); +#endif exit(1); } @@ -1050,6 +1352,7 @@ p->n_name = ""; p->n_qual = 0; p->n_op = op; + p->n_label = 0; p->n_lval = lval; p->n_rval = rval; p->n_type = type; @@ -1066,10 +1369,12 @@ p->n_name = ""; p->n_qual = 0; p->n_op = op; + p->n_label = 0; p->n_left = left; p->n_right = right; p->n_type = type; p->n_regw = NULL; + p->n_su = 0; return p; } @@ -1081,10 +1386,12 @@ p->n_name = ""; p->n_qual = 0; p->n_op = op; + p->n_label = 0; p->n_left = left; p->n_rval = rval; p->n_type = type; p->n_regw = NULL; + p->n_su = 0; return p; } @@ -1110,3 +1417,222 @@ } return -1; } + +#ifndef XASM_NUMCONV +#define XASM_NUMCONV(x,y,z) 0 +#endif + +/* + * change numeric argument redirections to the correct node type after + * cleaning up the other nodes. + * be careful about input operands that may have different value than output. + */ +static void +delnums(NODE *p, void *arg) +{ + struct interpass *ip = arg, *ip2; + NODE *r = ip->ip_node->n_left; + NODE *q; + TWORD t; + int cnt; + + if (p->n_name[0] < '0' || p->n_name[0] > '9') + return; /* not numeric */ + if ((q = listarg(r, p->n_name[0] - '0', &cnt)) == NIL) + comperr("bad delnums"); + + /* target may have opinions whether to do this conversion */ + if (XASM_NUMCONV(ip, p, q)) + return; + + /* Delete number by adding move-to/from-temp. Later on */ + /* the temps may be rewritten to other LTYPEs */ + t = p->n_left->n_type; + r = mklnode(TEMP, 0, p2env.epp->ip_tmpnum++, t); + + /* pre node */ + ip2 = ipnode(mkbinode(ASSIGN, tcopy(r), p->n_left, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + + /* post node */ + ip2 = ipnode(mkbinode(ASSIGN, q->n_left, tcopy(r), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + + p->n_left = tcopy(r); + q->n_left = r; + + p->n_name = tmpstrdup(q->n_name); + if (*p->n_name == '=') + p->n_name++; +} + +/* + * Ensure that a node is correct for the destination. + */ +static void +ltypify(NODE *p, void *arg) +{ + struct interpass *ip = arg; + struct interpass *ip2; + TWORD t = p->n_left->n_type; + NODE *q, *r; + int cw, ooff; + char *c; + +again: + if (myxasm(ip, p)) + return; /* handled by target-specific code */ + + cw = xasmcode(p->n_name); + switch (XASMVAL(cw)) { + case 'p': + /* pointer */ + /* just make register of it */ + p->n_name = tmpstrdup(p->n_name); + c = strchr(p->n_name, XASMVAL(cw)); /* cannot fail */ + *c = 'r'; + /* FALLTHROUGH */ + case 'g': /* general; any operand */ + case 'r': /* general reg */ + /* set register class */ + p->n_label = gclass(p->n_left->n_type); + if (p->n_left->n_op == REG || p->n_left->n_op == TEMP) + break; + q = p->n_left; + r = (cw & XASMINOUT ? tcopy(q) : q); + p->n_left = mklnode(TEMP, 0, p2env.epp->ip_tmpnum++, t); + if ((cw & XASMASG) == 0) { + ip2 = ipnode(mkbinode(ASSIGN, tcopy(p->n_left), r, t)); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + if (cw & (XASMASG|XASMINOUT)) { + /* output parameter */ + ip2 = ipnode(mkbinode(ASSIGN, q, tcopy(p->n_left), t)); + DLIST_INSERT_AFTER(ip, ip2, qelem); + } + break; + + case '0': case '1': case '2': case '3': case '4': + case '5': case '6': case '7': case '8': case '9': + break; + + case 'm': /* memory operand */ + /* store and reload value */ + q = p->n_left; + if (optype(q->n_op) == LTYPE) { + if (q->n_op == TEMP) { + ooff = BITOOR(freetemp(szty(t))); + cvtemps(ip, q->n_rval, ooff); + } else if (q->n_op == REG) + comperr("xasm m and reg"); + } else if (q->n_op == UMUL && + (q->n_left->n_op != TEMP && q->n_left->n_op != REG)) { + t = q->n_left->n_type; + ooff = p2env.epp->ip_tmpnum++; + ip2 = ipnode(mkbinode(ASSIGN, + mklnode(TEMP, 0, ooff, t), q->n_left, t)); + q->n_left = mklnode(TEMP, 0, ooff, t); + DLIST_INSERT_BEFORE(ip, ip2, qelem); + } + break; + + case 'i': /* immediate constant */ + case 'n': /* numeric constant */ + if (p->n_left->n_op == ICON) + break; + p->n_name = tmpstrdup(p->n_name); + c = strchr(p->n_name, XASMVAL(cw)); /* cannot fail */ + if (c[1]) { + c[0] = c[1], c[1] = 0; + goto again; + } else + uerror("constant required"); + break; + + default: + uerror("unsupported xasm option string '%s'", p->n_name); + } +} + +/* Extended assembler hacks */ +static void +fixxasm(struct p2env *p2e) +{ + struct interpass *pole = &p2e->ipole; + struct interpass *ip; + NODE *p; + + DLIST_FOREACH(ip, pole, qelem) { + if (ip->type != IP_NODE || ip->ip_node->n_op != XASM) + continue; + thisline = ip->lineno; + p = ip->ip_node->n_left; + + if (p->n_op == ICON && p->n_type == STRTY) + continue; + + /* replace numeric redirections with its underlying type */ + flist(p, delnums, ip); + + /* + * Ensure that the arg nodes can be directly addressable + * We decide that everything shall be LTYPE here. + */ + flist(p, ltypify, ip); + } +} + +/* + * Extract codeword from xasm string */ +int +xasmcode(char *s) +{ + int cw = 0; + + while (*s) { + switch ((int)*s) { + case '=': cw |= XASMASG; break; + case '&': cw |= XASMCONSTR; break; + case '+': cw |= XASMINOUT; break; + default: + if ((*s >= 'a' && *s <= 'z') || + (*s >= 'A' && *s <= 'Z') || + (*s >= '0' && *s <= '9')) { + cw |= *s; + return cw; + } + uerror("bad xasm constraint %c", *s); + } + s++; + } + return cw; +} + +static int xasnum, xoffnum; + +static void +xconv(NODE *p, void *arg) +{ + if (p->n_op != TEMP || p->n_rval != xasnum) + return; + p->n_op = OREG; + p->n_rval = FPREG; + p->n_lval = xoffnum; +} + +/* + * Convert nodes of type TEMP to op with lval off. + */ +static void +cvtemps(struct interpass *ipl, int tnum, int off) +{ + struct interpass *ip; + + xasnum = tnum; + xoffnum = off; + + DLIST_FOREACH(ip, ipl, qelem) + if (ip->type == IP_NODE) + walkf(ip->ip_node, xconv, 0); + walkf(ipl->ip_node, xconv, 0); +} Index: node.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/node.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/node.h -L usr.bin/pcc/mip/node.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/node.h +++ usr.bin/pcc/mip/node.h @@ -1,4 +1,4 @@ -/* $Id: node.h,v 1.31 2007/07/22 12:50:56 ragge Exp $ */ +/* $Id: node.h,v 1.35 2008/09/04 08:00:11 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -26,6 +26,9 @@ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ +#ifndef NODE_H +#define NODE_H + /* * The node structure is the basic element in the compiler. * Depending on the operator, it may be one of several types. @@ -60,6 +63,7 @@ union { int _label; int _stalign; + int _flags; struct suedef *_sue; } n_6; union { @@ -77,7 +81,18 @@ struct symtab *_sp; } n_r; } n_u; +#ifdef SOFTFLOAT +#ifdef FDFLOAT + /* To store F- or D-floats */ + struct softfloat { + unsigned short fd1, fd2, fd3, fd4; + } _dcon; +#else +#error missing softfloat structure definition +#endif +#else long double _dcon; +#endif } n_f; } NODE; @@ -87,6 +102,7 @@ #define n_label n_6._label #define n_stalign n_6._stalign +#define n_flags n_6._flags #define n_sue n_6._sue #define n_left n_f.n_u.n_l._left @@ -97,6 +113,9 @@ #define n_sp n_f.n_u.n_r._sp #define n_dcon n_f._dcon +#define NLOCAL1 010000 +#define NLOCAL2 020000 +#define NLOCAL3 040000 /* * Node types. * @@ -113,7 +132,7 @@ #define REG 6 #define OREG 7 #define TEMP 8 -#define MOVE 9 /* Special reg-reg move node */ +#define XARG 9 /* * Arithmetic nodes. @@ -184,7 +203,7 @@ #define STASG 50 #define STARG 51 #define FORCE 52 -/* #define INIT 53 */ +#define XASM 53 #define GOTO 54 #define RETURN 55 #define STREF 56 @@ -192,3 +211,5 @@ #define ADDROF 58 #define MAXOP 58 + +#endif Index: match.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/match.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/match.c -L usr.bin/pcc/mip/match.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/match.c +++ usr.bin/pcc/mip/match.c @@ -1,4 +1,4 @@ -/* $Id: match.c,v 1.72 2006/07/30 09:32:15 ragge Exp $ */ +/* $Id: match.c,v 1.89 2008/11/26 17:31:40 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -60,16 +60,15 @@ * POSSIBILITY OF SUCH DAMAGE. */ -# include "pass2.h" +#include "pass2.h" +#ifdef HAVE_STRINGS_H #include +#endif -void prttype(int t); void setclass(int tmp, int class); int getclass(int tmp); -int fldsz, fldshf; - int s2debug = 0; extern char *ltyp[], *rtyp[]; @@ -149,27 +148,14 @@ break; case ICON: + case FCON: if (shape & SCON) return SRDIR; break; case FLD: - if (shape & SFLD) { - int sh; - - if ((sh = flshape(p->n_left)) == SRNOPE) - return sh; - /* it is a FIELD shape; make side-effects */ - /* XXX - this will not work for multi-matches */ - o = p->n_rval; - fldsz = UPKFSZ(o); -# ifdef RTOLBYTES - fldshf = UPKFOFF(o); -# else - fldshf = SZINT - fldsz - UPKFOFF(o); -# endif - return sh; - } + if (shape & SFLD) + return flshape(p->n_left); break; case CCODES: @@ -190,9 +176,13 @@ break; case UMUL: +#if 0 if (shumul(p->n_left) & shape) return SROREG; /* Calls offstar to traverse down */ break; +#else + return shumul(p->n_left, shape); +#endif } return SRNOPE; @@ -264,6 +254,13 @@ return(0); } +#define FLDSZ(x) UPKFSZ(x) +#ifdef RTOLBYTES +#define FLDSHF(x) UPKFOFF(x) +#else +#define FLDSHF(x) (SZINT - FLDSZ(x) - UPKFOFF(x)) +#endif + /* * generate code by interpreting table entry */ @@ -272,6 +269,9 @@ { CONSZ val; +//printf("expand\n"); +//fwalk(p, e2print, 0); + for( ; *cp; ++cp ){ switch( *cp ){ @@ -284,23 +284,34 @@ continue; case 'F': /* this line deleted if FOREFF is active */ - if( cookie & FOREFF ) while( *++cp != '\n' ) ; /* VOID */ + if (cookie & FOREFF) { + while (*cp && *cp != '\n') + cp++; + if (*cp == 0) + return; + } continue; case 'S': /* field size */ - printf( "%d", fldsz ); + if (fldexpand(p, cookie, &cp)) + continue; + printf("%d", FLDSZ(p->n_rval)); continue; case 'H': /* field shift */ - printf( "%d", fldshf ); + if (fldexpand(p, cookie, &cp)) + continue; + printf("%d", FLDSHF(p->n_rval)); continue; case 'M': /* field mask */ case 'N': /* complement of field mask */ + if (fldexpand(p, cookie, &cp)) + continue; val = 1; - val <<= fldsz; + val <<= FLDSZ(p->n_rval); --val; - val <<= fldshf; + val <<= FLDSHF(p->n_rval); adrcon( *cp=='M' ? val : ~val ); continue; @@ -312,6 +323,11 @@ continue; case 'O': /* opcode string */ +#ifdef FINDMOPS + if (p->n_op == ASSIGN) + hopcode(*++cp, p->n_right->n_op); + else +#endif hopcode( *++cp, p->n_op ); continue; @@ -382,26 +398,6 @@ return NULL; } -static char *tarr[] = { - "CHAR", "SHORT", "INT", "LONG", "FLOAT", "DOUBLE", "POINT", "UCHAR", - "USHORT", "UINT", "ULONG", "PTRTO", "ANY", "STRUCT", "LONGLONG", - "ULONGLONG", -}; - -void -prttype(int t) -{ - int i, gone = 0; - - for (i = 0; i < 16; i++) - if ((t >> i) & 1) { - if (gone) putchar('|'); - gone++; - printf("%s", tarr[i]); - } -} - - #ifdef PCC_DEBUG #define F2DEBUG(x) if (f2debug) printf x #define F2WALK(x) if (f2debug) fwalk(x, e2print, 0) @@ -415,8 +411,8 @@ * Shape is register class where we want the result. * Returns register class if register nodes. * If w is: (should be shapes) - * - LREG - result in register, call geninsn(). - * - LOREG - create OREG; call offstar(). + * - SRREG - result in register, call geninsn(). + * - SROREG - create OREG; call offstar(). * - 0 - clear su, walk down. */ static int @@ -424,12 +420,14 @@ { int rv = 0; + F2DEBUG(("swmatch: p=%p, shape=%s, w=%s\n", p, prcook(shape), srtyp[w])); + switch (w) { - case LREG: + case SRREG: rv = geninsn(p, shape); break; - case LOREG: + case SROREG: /* should be here only if op == UMUL */ if (p->n_op != UMUL && p->n_op != FLD) comperr("swmatch %p", p); @@ -493,7 +491,8 @@ * p - node (for this leg) * shape - given shape for this leg * cookie - cookie given for parent node - * rv - switch key for traversing down + * rew - + * go - switch key for traversing down * returns register class. */ static int @@ -501,20 +500,23 @@ { int lsh; + F2DEBUG(("shswitch: p=%p, shape=%s, ", p, prcook(shape))); + F2DEBUG(("cookie=%s, rew=0x%x, go=%s\n", prcook(cookie), rew, srtyp[go])); + switch (go) { case SRDIR: /* direct match, just clear su */ (void)swmatch(p, 0, 0); break; case SROREG: /* call offstar to prepare for OREG conversion */ - (void)swmatch(p, shape, LOREG); + (void)swmatch(p, shape, SROREG); break; case SRREG: /* call geninsn() to get value into register */ - lsh = shape & INREGS; + lsh = shape & (FORCC | INREGS); if (rew && cookie != FOREFF) - lsh &= (cookie & INREGS); - lsh = swmatch(p, lsh, LREG); + lsh &= (cookie & (FORCC | INREGS)); + lsh = swmatch(p, lsh, SRREG); if (rew) sh = lsh; break; @@ -549,7 +551,10 @@ for (i = 0; ixp[i] >= 0; i++) { q = &table[ixp[i]]; - F2DEBUG(("findop: ixp %d\n", ixp[i])); + F2DEBUG(("findop: ixp %d str %s\n", ixp[i], q->cstring)); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0 || ttype(r->n_type, q->rtype) == 0) continue; /* Types must be correct */ @@ -565,7 +570,8 @@ F2DEBUG(("findop lshape %d\n", shl)); F2WALK(l); - if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT))== SRNOPE) continue; + if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT)) == SRNOPE) + continue; F2DEBUG(("findop rshape %d\n", shr)); F2WALK(r); @@ -592,18 +598,26 @@ sh = -1; +#ifdef mach_pdp11 + if (cookie == FORCC && p->n_op != AND) /* XXX - fix */ + cookie = INREGS; +#else + if (cookie == FORCC) + cookie = INREGS; +#endif + sh = shswitch(sh, p->n_left, qq->lshape, cookie, qq->rewrite & RLEFT, gol); sh = shswitch(sh, p->n_right, qq->rshape, cookie, qq->rewrite & RRIGHT, gor); if (sh == -1) { - if (cookie == FOREFF) + if (cookie == FOREFF || cookie == FORCC) sh = 0; else sh = ffs(cookie & qq->visit & INREGS)-1; } - F2DEBUG(("findops: node %p (%s)\n", p, prcook(1 << sh))); + F2DEBUG(("findops: node %p sh %d (%s)\n", p, sh, prcook(1 << sh))); p->n_su = MKIDX(idx, 0); SCLASS(p->n_su, sh); return sh; @@ -647,6 +661,9 @@ q = &table[ixp[i]]; F2DEBUG(("relops: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0 || ttype(r->n_type, q->rtype) == 0) continue; /* Types must be correct */ @@ -686,7 +703,7 @@ (void)shswitch(-1, p->n_right, q->rshape, FORCC, q->rewrite & RRIGHT, gor); - F2DEBUG(("findops: node %p\n", p)); + F2DEBUG(("relops: node %p\n", p)); p->n_su = MKIDX(idx, 0); SCLASS(p->n_su, CLASSA); /* XXX */ return 0; @@ -727,7 +744,10 @@ for (i = 0; ixp[i] >= 0; i++) { q = &table[ixp[i]]; - F2DEBUG(("asgop: ixp %d\n", ixp[i])); + F2DEBUG(("findasg: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0 || ttype(r->n_type, q->rtype) == 0) continue; /* Types must be correct */ @@ -735,20 +755,30 @@ if ((cookie & q->visit) == 0) continue; /* must get a result */ - F2DEBUG(("asgop got types\n")); - if ((shl = tshape(l, q->lshape)) == SRNOPE) - continue; - - if (shl == SRREG) - continue; + F2DEBUG(("findasg got types\n")); +#ifdef mach_pdp11 /* XXX - check for other targets too */ + if (p->n_op == STASG && ISPTR(l->n_type)) { + /* Accept lvalue to be in register */ + /* if struct assignment is given a pointer */ + if ((shl = chcheck(l, q->lshape, + q->rewrite & RLEFT)) == SRNOPE) + continue; + } else +#endif + { + if ((shl = tshape(l, q->lshape)) == SRNOPE) + continue; + if (shl == SRREG) + continue; + } - F2DEBUG(("asgop lshape %d\n", shl)); + F2DEBUG(("findasg lshape %d\n", shl)); F2WALK(l); - if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT))== SRNOPE) + if ((shr = chcheck(r, q->rshape, q->rewrite & RRIGHT)) == SRNOPE) continue; - F2DEBUG(("asgop rshape %d\n", shr)); + F2DEBUG(("findasg rshape %d\n", shr)); F2WALK(r); if (q->needs & REWRITE) break; /* Done here */ @@ -778,6 +808,23 @@ sh = shswitch(sh, p->n_right, qq->rshape, cookie, qq->rewrite & RRIGHT, gor); +#ifdef mach_pdp11 /* XXX all targets? */ + lvl = 0; + if (cookie == FOREFF) + lvl = RVEFF, sh = 0; + else if (cookie == FORCC) + lvl = RVCC, sh = 0; + else if (sh == -1) { + sh = ffs(cookie & qq->visit & INREGS)-1; +#ifdef PCC_DEBUG + if (sh == -1) + comperr("findasg bad shape"); +#endif + SCLASS(lvl,sh); + } else + SCLASS(lvl,sh); + p->n_su = MKIDX(idx, lvl); +#else if (sh == -1) { if (cookie == FOREFF) sh = 0; @@ -788,7 +835,10 @@ p->n_su = MKIDX(idx, 0); SCLASS(p->n_su, sh); - +#endif /* mach_pdp11 */ +#ifdef FINDMOPS + p->n_flags &= ~1; +#endif return sh; } @@ -812,6 +862,9 @@ q = &table[ixp[i]]; F2DEBUG(("findumul: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if ((q->visit & cookie) == 0) continue; /* wrong registers */ @@ -874,6 +927,8 @@ q = &table[ixp[i]]; F2DEBUG(("findleaf: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; if ((q->visit & cookie) == 0) continue; /* wrong registers */ @@ -935,6 +990,9 @@ q = &table[ixp[i]]; F2DEBUG(("finduni: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + if (ttype(l->n_type, q->ltype) == 0) continue; /* Type must be correct */ @@ -993,3 +1051,192 @@ SCLASS(p->n_su, sh); return sh; } + +#ifdef FINDMOPS +/* + * Try to find constructs like "a = a + 1;" and match them together + * with instructions like "incl a" or "addl $1,a". + * + * Level assignment for priority: + * left right prio + * - - - + * direct direct 1 + * direct REG 2 + * direct OREG 3 + * OREG direct 4 + * OREG REG 5 + * OREG OREG 6 + */ +int +findmops(NODE *p, int cookie) +{ + extern int *qtable[]; + struct optab *q; + int i, sh, shl, shr, lvl = 10; + NODE *l, *r; + int *ixp; + struct optab *qq = NULL; /* XXX gcc */ + int idx = 0, gol = 0, gor = 0; + + shl = shr = 0; + + F2DEBUG(("findmops tree: %s\n", prcook(cookie))); + F2WALK(p); + + l = getlr(p, 'L'); + r = getlr(p, 'R'); + /* See if this is a usable tree to work with */ + /* Currently only check for leaves */ + if (optype(r->n_op) != BITYPE || treecmp(l, r->n_left) == 0) + return FFAIL; + + F2DEBUG(("findmops is useable\n")); + + /* We can try to find a match. Use right op */ + ixp = qtable[r->n_op]; + l = getlr(r, 'L'); + r = getlr(r, 'R'); + + for (i = 0; ixp[i] >= 0; i++) { + q = &table[ixp[i]]; + + F2DEBUG(("findmops: ixp %d\n", ixp[i])); + if (!acceptable(q)) /* target-dependent filter */ + continue; + + if (ttype(l->n_type, q->ltype) == 0 || + ttype(r->n_type, q->rtype) == 0) + continue; /* Types must be correct */ + + F2DEBUG(("findmops got types\n")); + + switch (cookie) { + case FOREFF: + if ((q->visit & FOREFF) == 0) + continue; /* Not only for side effects */ + break; + case FORCC: + if ((q->visit & FORCC) == 0) + continue; /* Not only for side effects */ + break; + default: + if ((cookie & q->visit) == 0) + continue; /* Won't match requested shape */ + if (((cookie & INREGS & q->lshape) == 0) || !isreg(l)) + continue; /* Bad return register */ + break; + } + F2DEBUG(("findmops cookie\n")); + + /* + * left shape must match left node. + */ + if ((shl = tshape(l, q->lshape)) != SRDIR && (shl != SROREG)) + continue; + + F2DEBUG(("findmops lshape %d\n", shl)); + F2WALK(l); + + if ((shr = chcheck(r, q->rshape, 0)) == SRNOPE) + continue; + + F2DEBUG(("findmops rshape %d\n", shr)); + + /* + * Only allow RLEFT. XXX + */ + if ((q->rewrite & (RLEFT|RRIGHT)) != RLEFT) + continue; + + F2DEBUG(("rewrite OK\n")); + + F2WALK(r); + if (q->needs & REWRITE) + break; /* Done here */ + + if (lvl <= (shl + shr)) + continue; + + lvl = shl + shr; + qq = q; + idx = ixp[i]; + gol = shl; + gor = shr; + } + + if (lvl == 10) + return FFAIL; + F2DEBUG(("findmops entry %d(%s,%s)\n", idx, srtyp[gol], srtyp[gor])); + + /* + * Now we're here and have a match. left is semi-direct and + * right may be anything. + */ + + sh = -1; + sh = shswitch(sh, p->n_left, qq->lshape, cookie, + qq->rewrite & RLEFT, gol); + sh = shswitch(sh, r, qq->rshape, cookie, 0, gor); + + if (sh == -1) { + if (cookie & (FOREFF|FORCC)) + sh = 0; + else + sh = ffs(cookie & qq->visit & INREGS)-1; + } + F2DEBUG(("findmops done: node %p class %d\n", p, sh)); + + /* Trickery: Set table index on assign to op instead */ + /* gencode() will remove useless nodes */ + p->n_su = MKIDX(idx, 0); + p->n_flags |= 1; /* XXX tell gencode to reduce the right tree */ + SCLASS(p->n_su, sh); + + return sh; +} + +/* + * Compare two trees; return 1 if equal and 0 if not. + */ +int +treecmp(NODE *p1, NODE *p2) +{ + if (p1->n_op != p2->n_op) + return 0; + + switch (p1->n_op) { + case UMUL: + return treecmp(p1->n_left, p2->n_left); + + case OREG: + if (p1->n_lval != p2->n_lval || p1->n_rval != p2->n_rval) + return 0; + break; + + case NAME: + case ICON: + if (strcmp(p1->n_name, p2->n_name)) + return 0; + /* FALLTHROUGH */ + if (p1->n_lval != p2->n_lval) + return 0; + break; + + case REG: + case TEMP: + if (p1->n_rval != p2->n_rval) + return 0; + break; + case PLUS: + case MINUS: + if (treecmp(p1->n_left, p2->n_left) == 0 || + treecmp(p1->n_right, p2->n_right) == 0) + return 0; + break; + + default: + return 0; + } + return 1; +} +#endif Index: pass2.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/pass2.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/pass2.h -L usr.bin/pcc/mip/pass2.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/pass2.h +++ usr.bin/pcc/mip/pass2.h @@ -1,4 +1,4 @@ -/* $Id: pass2.h,v 1.98 2006/12/22 06:23:09 ragge Exp $ */ +/* $Id: pass2.h,v 1.119 2008/11/22 20:13:50 pantzer Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -34,13 +34,14 @@ */ #include -#include "manifest.h" -#include "protos.h" #ifndef MKEXT #include "external.h" #else -typedef int bittype; /* XXX - for basicblock */ +typedef unsigned int bittype; /* XXX - for basicblock */ +#define BIT2BYTE(a) (((a) + 31) / 32) #endif +#include "manifest.h" +#include "protos.h" /* cookies, used as arguments to codgen */ #define FOREFF 01 /* compute for effects only */ @@ -50,8 +51,12 @@ #define INDREG 020 /* compute into a register */ #define INREGS (INAREG|INBREG|INCREG|INDREG) #define FORCC 040 /* compute for condition codes only */ +#define QUIET 0100 /* tell geninsn() to not complain if fail */ #define INTEMP 010000 /* compute into a temporary location */ #define FORREW 040000 /* search the table for a rewrite rule */ +#define INEREG 0x10000 /* compute into a register, > 16 bits */ +#define INFREG 0x20000 /* compute into a register, > 16 bits */ +#define INGREG 0x40000 /* compute into a register, > 16 bits */ /* * OP descriptors, @@ -91,10 +96,13 @@ #define SSCON (SPECIAL|4) /* -32768 <= constant < 32768 */ #define SSOREG (SPECIAL|5) /* non-indexed OREG */ #define MAXSPECIAL (SPECIAL|5) +#define SEREG 0x10000 /* same as INEREG */ +#define SFREG 0x20000 /* same as INFREG */ +#define SGREG 0x40000 /* same as INGREG */ /* These are used in rstatus[] in conjunction with SxREG */ -#define TEMPREG 0100 -#define PERMREG 0200 +#define TEMPREG 01000 +#define PERMREG 02000 /* tshape() return values */ #define SRNOPE 0 /* Cannot match any shape */ @@ -140,28 +148,38 @@ #define RNOP 010000 /* DANGER: can cause loops.. */ /* needs */ -#define NAREG 0000001 -#define NACOUNT 0000003 -#define NAMASK 0000017 -#define NASL 0000004 /* may share left register */ -#define NASR 0000010 /* may share right register */ -#define NBREG 0000020 -#define NBCOUNT 0000060 -#define NBMASK 0000360 -#define NBSL 0000100 -#define NBSR 0000200 -#define NTEMP 0000400 -#define NTMASK 0001400 -#define NSPECIAL 0040000 /* need special register treatment */ -#define REWRITE 0100000 -#define NCSL 0x10000 /* Above 16 bit */ -#define NCSR 0x20000 /* Above 16 bit */ -#define NCREG 0x40000 /* Above 16 bit */ -#define NCCOUNT 0xc0000 -#define NDSL 0x100000 /* Above 16 bit */ -#define NDSR 0x200000 /* Above 16 bit */ -#define NDREG 0x400000 /* Above 16 bit */ -#define NDCOUNT 0xc00000 +#define NASL 0x0001 /* may share left register */ +#define NASR 0x0002 /* may share right register */ +#define NAREG 0x0004 +#define NACOUNT 0x000c +#define NBSL 0x0010 +#define NBSR 0x0020 +#define NBREG 0x0040 +#define NBCOUNT 0x00c0 +#define NCSL 0x0100 +#define NCSR 0x0200 +#define NCREG 0x0400 +#define NCCOUNT 0x0c00 +#define NTEMP 0x1000 +#define NTMASK 0x3000 +#define NSPECIAL 0x4000 /* need special register treatment */ +#define REWRITE 0x8000 +#define NDSL 0x00010000 /* Above 16 bit */ +#define NDSR 0x00020000 /* Above 16 bit */ +#define NDREG 0x00040000 /* Above 16 bit */ +#define NDCOUNT 0x000c0000 +#define NESL 0x00100000 /* Above 16 bit */ +#define NESR 0x00200000 /* Above 16 bit */ +#define NEREG 0x00400000 /* Above 16 bit */ +#define NECOUNT 0x00c00000 +#define NFSL 0x01000000 /* Above 16 bit */ +#define NFSR 0x02000000 /* Above 16 bit */ +#define NFREG 0x04000000 /* Above 16 bit */ +#define NFCOUNT 0x0c000000 +#define NGSL 0x10000000 /* Above 16 bit */ +#define NGSR 0x20000000 /* Above 16 bit */ +#define NGREG 0x40000000 /* Above 16 bit */ +#define NGCOUNT 0xc0000000 /* special treatment */ #define NLEFT (0001) /* left leg register (moveadd) */ @@ -178,14 +196,6 @@ #define isreg(p) (p->n_op == REG || p->n_op == TEMP) -#define TBUSY 01000 - -#define SETSTO(x,y) (stotree = (x), stocook = (y)) -extern int stocook; - -extern NODE *stotree; -extern int callflag; - extern int fregs; /* code tables */ @@ -215,14 +225,13 @@ #endif }; +struct p2env; extern NODE resc[]; - extern int p2autooff, p2maxautooff; extern NODE *talloc(void), *eread(void), - *tcopy(NODE *), *mklnode(int, CONSZ, int, TWORD), *mkbinode(int, NODE *, NODE *, TWORD), *mkunode(int, NODE *, int, TWORD), @@ -230,17 +239,12 @@ void eoftn(struct interpass_prolog *); void prologue(struct interpass_prolog *); -void setlocc(int locctr); void e2print(NODE *p, int down, int *a, int *b); void myoptim(struct interpass *); void cbgen(int op, int label); -struct optab *nxtmatch(struct optab *); -int chkmatch(NODE *, int, int, int); int match(NODE *p, int cookie); -int nmatch(NODE *p, int what); -#ifndef special +int acceptable(struct optab *); int special(NODE *, int); -#endif int setasg(NODE *, int); int setuni(NODE *, int); int sucomp(NODE *); @@ -250,9 +254,8 @@ void adrput(FILE *, NODE *); void comperr(char *str, ...); void genregs(NODE *p); -void ngenregs(struct interpass *); +void ngenregs(struct p2env *); NODE *store(NODE *); -void gencall(NODE *, NODE *prev); struct interpass *ipnode(NODE *); void deflab(int); void rmove(int, int, TWORD); @@ -265,14 +268,29 @@ int findumul(NODE *p, int); int findleaf(NODE *p, int); int relops(NODE *p); +#ifdef FINDMOPS +int findmops(NODE *p, int); +int treecmp(NODE *p1, NODE *p2); +#endif void offstar(NODE *p, int shape); int gclass(TWORD); void lastcall(NODE *); void myreader(struct interpass *pole); int oregok(NODE *p, int sharp); void myormake(NODE *); - +int *livecall(NODE *); +void prtreg(FILE *, NODE *); char *prcook(int); +int myxasm(struct interpass *ip, NODE *p); +int xasmcode(char *s); +int freetemp(int k); +int rewfld(NODE *p); +void canon(NODE *); +void mycanon(NODE *); +void oreg2(NODE *p, void *); +int shumul(NODE *p, int); +NODE *deluseless(NODE *p); +int getlab2(void); void conput(FILE *, NODE *); @@ -289,6 +307,17 @@ #define CLASSC 3 #define CLASSD 4 #define CLASSE 5 +#define CLASSF 6 +#define CLASSG 7 + +/* used when parsing xasm codes */ +#define XASMVAL(x) ((x) & 0377) /* get val from codeword */ +#define XASMASG 0x100 /* = */ +#define XASMCONSTR 0x200 /* & */ +#define XASMINOUT 0x400 /* + */ +#define XASMALL (XASMASG|XASMCONSTR|XASMINOUT) +#define XASMISINP(cw) (((cw) & XASMASG) == 0) /* input operand */ +#define XASMISOUT(cw) ((cw) & (XASMASG|XASMINOUT)) /* output operand */ /* routines to handle double indirection */ #ifdef R2REGS @@ -299,8 +328,8 @@ extern int lineno; extern int fldshf, fldsz; -extern int lflag, x2debug, udebug, e2debug, odebug, mdebug; -extern int rdebug, radebug, t2debug, s2debug, b2debug, c2debug; +extern int lflag, x2debug, udebug, e2debug, odebug; +extern int rdebug, t2debug, s2debug, b2debug, c2debug; extern int kflag; #ifdef FORT extern int Oflag; @@ -330,24 +359,17 @@ /* * Layout of findops() return value: - * bit 0-1 where to store left node. - * bit 2-3 where to store right node. - * bit 4 set if right leg should be evaluated first - * bit 5- table index + * bit 0 whether left shall go into a register. + * bit 1 whether right shall go into a register. + * bit 2 entry is only used for side effects. + * bit 3 if condition codes are used. * - * LOREG means: walk down left node, after code emission call canon() to - * convert the tree to an OREG. + * These values should be synced with FOREFF/FORCC. */ #define LREG 001 -#define LOREG 002 -#define LTEMP 003 -#define LDIR 003 -#define LMASK 003 -#define RREG 004 -#define ROREG 010 -#define RTEMP 014 -#define RDIR 014 -#define RMASK 014 +#define RREG 002 +#define RVEFF 004 +#define RVCC 010 #define DORIGHT 020 #define SCLASS(v,x) ((v) |= ((x) << 5)) #define TCLASS(x) (((x) >> 5) & 7) @@ -360,9 +382,12 @@ #define TBREGS 0 #endif #define REGBIT(x) (1 << (x)) +#ifndef PERMTYPE +#define PERMTYPE(a) (INT) +#endif void emit(struct interpass *); -void optimize(struct interpass *); +void optimize(struct p2env *); struct basicblock { DLIST_ENTRY(basicblock) bbelem; @@ -380,23 +405,25 @@ bittype *dfchildren; bittype *Aorig; bittype *Aphi; + SLIST_HEAD(, phiinfo) phi; struct interpass *first; /* first element of basic block */ struct interpass *last; /* last element of basic block */ }; struct labelinfo { struct basicblock **arr; - unsigned int size; + int size; unsigned int low; }; struct bblockinfo { - unsigned int size; + int size; struct basicblock **arr; }; struct varinfo { struct pvarinfo **arr; + SLIST_HEAD(, varstack) *stack; int size; int low; }; @@ -404,14 +431,44 @@ struct pvarinfo { struct pvarinfo *next; struct basicblock *bb; - NODE *top, *n; + TWORD n_type; +}; + +struct varstack { + SLIST_ENTRY(varstack) varstackelem; + int tmpregno; }; + struct cfgnode { SLIST_ENTRY(cfgnode) cfgelem; struct basicblock *bblock; }; +struct phiinfo { + SLIST_ENTRY(phiinfo) phielem; + int tmpregno; + int newtmpregno; + TWORD n_type; + int size; + int *intmpregno; +}; + +/* + * Description of the pass2 environment. + * There will be only one of these structs. It is used to keep + * all state descriptions during the compilation of a function + * in one place. + */ +struct p2env { + struct interpass ipole; /* all statements */ + struct interpass_prolog *ipp, *epp; /* quick references */ + struct basicblock bblocks; + int nbblocks; +}; + +extern struct p2env p2env; + /* * C compiler second pass extra defines. */ Index: regs.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/regs.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/regs.c -L usr.bin/pcc/mip/regs.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/regs.c +++ usr.bin/pcc/mip/regs.c @@ -1,4 +1,4 @@ -/* $Id: regs.c,v 1.155 2007/09/22 17:15:00 ragge Exp $ */ +/* $Id: regs.c,v 1.198 2008/12/14 18:26:02 ragge Exp $ */ /* * Copyright (c) 2005 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -28,11 +28,22 @@ #include "pass2.h" #include +#ifdef HAVE_STRINGS_H +#include +#endif +#ifdef HAVE_STDINT_H +#include +#endif #include +#ifdef HAVE_ALLOCA_H +#include +#endif #define MAXLOOP 20 /* Max number of allocation loops XXX 3 should be enough */ +#ifndef MAX #define MAX(a,b) (((a) > (b)) ? (a) : (b)) +#endif /* * New-style register allocator using graph coloring. @@ -40,9 +51,8 @@ * "Iterated Register Coalescing", ACM Transactions, No 3, May 1996. */ -#define BIT2BYTE(bits) ((((bits)+NUMBITS-1)/NUMBITS)*(NUMBITS/8)) #define BITALLOC(ptr,all,sz) { \ - int __s = BIT2BYTE(sz); ptr = all(__s); memset(ptr, 0, __s); } + int sz__s = BIT2BYTE(sz); ptr = all(sz__s); memset(ptr, 0, sz__s); } #undef COMPERR_PERM_MOVE #define RDEBUG(x) if (rdebug) printf x @@ -50,6 +60,9 @@ #define RPRINTIP(x) if (rdebug) printip(x) #define RDX(x) x #define UDEBUG(x) if (udebug) printf x +#define BDEBUG(x) if (b2debug) printf x + +#define VALIDREG(p) (p->n_op == REG && TESTBIT(validregs, regno(p))) /* * Data structure overview for this implementation of graph coloring: @@ -124,6 +137,7 @@ static REGW initial, *nblock; static void insnwalk(NODE *p); #ifdef PCC_DEBUG +int use_regw; int nodnum = 100; #define SETNUM(x) (x)->nodnum = nodnum++ #define ASGNUM(x) (x)->nodnum @@ -132,7 +146,7 @@ #define ASGNUM(x) #endif -#define ALLNEEDS (NACOUNT|NBCOUNT|NCCOUNT|NDCOUNT) +#define ALLNEEDS (NACOUNT|NBCOUNT|NCCOUNT|NDCOUNT|NECOUNT|NFCOUNT|NGCOUNT) /* XXX */ REGW *ablock; @@ -157,17 +171,21 @@ static REGW * newblock(NODE *p) { - REGW *nb = &nblock[(int)p->n_lval]; + REGW *nb = &nblock[regno(p)]; if (nb->link.q_forw == 0) { DLIST_INSERT_AFTER(&initial, nb, link); - ASGNUM(nb) = p->n_lval; +#ifdef PCC_DEBUG + ASGNUM(nb) = regno(p); RDEBUG(("Adding longtime %d for tmp %d\n", - nb->nodnum, (int)p->n_lval)); + nb->nodnum, regno(p))); +#endif } if (nb->r_class == 0) nb->r_class = gclass(p->n_type); +#ifdef PCC_DEBUG RDEBUG(("newblock: p %p, node %d class %d\n", p, nb->nodnum, nb->r_class)); +#endif return nb; } @@ -191,7 +209,7 @@ struct optab *q; int left, right; int nreg, need, i, nxreg, o; - int nareg, nbreg, ncreg, ndreg; + int nareg, nbreg, ncreg, ndreg, nereg, nfreg, ngreg; REGW *w; o = optype(p->n_op); @@ -205,6 +223,8 @@ if (o == LTYPE ) { if (p->n_op == TEMP) p->n_regw = newblock(p); + else if (p->n_op == REG) + p->n_regw = &ablock[regno(p)]; } else a = nsucomp(p->n_left); if (o == BITYPE) { @@ -217,16 +237,23 @@ } q = &table[TBLIDX(p->n_su)]; - nareg = (q->needs & NACOUNT); + for (i = (q->needs & NACOUNT), nareg = 0; i; i -= NAREG) + nareg++; for (i = (q->needs & NBCOUNT), nbreg = 0; i; i -= NBREG) nbreg++; for (i = (q->needs & NCCOUNT), ncreg = 0; i; i -= NCREG) ncreg++; for (i = (q->needs & NDCOUNT), ndreg = 0; i; i -= NDREG) ndreg++; + for (i = (q->needs & NECOUNT), nereg = 0; i; i -= NEREG) + nereg++; + for (i = (q->needs & NFCOUNT), nfreg = 0; i; i -= NFREG) + nfreg++; + for (i = (q->needs & NGCOUNT), ngreg = 0; i; i -= NGREG) + ngreg++; - nxreg = nareg + nbreg + ncreg + ndreg; + nxreg = nareg + nbreg + ncreg + ndreg + nereg + nfreg + ngreg; nreg = nxreg; if (callop(p->n_op)) nreg = MAX(fregs, nreg); @@ -276,11 +303,18 @@ return need; } +#ifdef PCC_DEBUG #define ADCL(n, cl) \ for (i = 0; i < n; i++, w++) { w->r_class = cl; \ DLIST_INSERT_BEFORE(&initial, w, link); SETNUM(w); \ UDEBUG(("Adding " #n " %d\n", w->nodnum)); \ } +#else +#define ADCL(n, cl) \ + for (i = 0; i < n; i++, w++) { w->r_class = cl; \ + DLIST_INSERT_BEFORE(&initial, w, link); SETNUM(w); \ + } +#endif UDEBUG(("node %p numregs %d\n", p, nxreg+1)); w = p->n_regw = tmpalloc(sizeof(REGW) * (nxreg+1)); @@ -293,12 +327,17 @@ SETNUM(w); if (w->r_class) DLIST_INSERT_BEFORE(&initial, w, link); - UDEBUG(("Adding short %d calss %d\n", w->nodnum, w->r_class)); +#ifdef PCC_DEBUG + UDEBUG(("Adding short %d class %d\n", w->nodnum, w->r_class)); +#endif w++; ADCL(nareg, CLASSA); ADCL(nbreg, CLASSB); ADCL(ncreg, CLASSC); ADCL(ndreg, CLASSD); + ADCL(nereg, CLASSE); + ADCL(nfreg, CLASSF); + ADCL(ngreg, CLASSG); if (q->rewrite & RESC1) { w = p->n_regw + 1; @@ -361,9 +400,13 @@ #endif i = COLORMAP(c, r); -if (i < 0 || i > 1) - comperr("trivially_colorable_p"); -//printf("trivially_colorable_p: n[1] %d n[2] %d n[3] %d n[4] %d class %d, triv %d\n", n[1], n[2], n[3], n[4], c, i); + if (i < 0 || i > 1) + comperr("trivially_colorable_p"); +#ifdef PCC_DEBUG + if (rdebug > 1) + printf("trivially_colorable_p: n[1] %d n[2] %d n[3] %d n[4] " + "%d for class %d, triv %d\n", n[1], n[2], n[3], n[4], c, i); +#endif return i; } @@ -380,10 +423,16 @@ needs -= NCREG, i++; while (needs & NDCOUNT) needs -= NDREG, i++; + while (needs & NECOUNT) + needs -= NEREG, i++; + while (needs & NFCOUNT) + needs -= NFREG, i++; + while (needs & NGCOUNT) + needs -= NGREG, i++; return i; } -static inline REGW * +static REGW * popwlist(REGW *l) { REGW *w = DLIST_NEXT(l, link); @@ -400,7 +449,7 @@ worklistMoves, activeMoves; enum { COAL, CONSTR, FROZEN, WLIST, ACTIVE }; -static inline REGM * +static REGM * popmlist(REGM *l) { REGM *w = DLIST_NEXT(l, link); @@ -418,7 +467,7 @@ * * Bitfields are used for liveness. Bit arrays are allocated on the * heap for the "live" variable and on the stack for the in, out, gen - * and kill variables. Therefore, for a temp number, the bit number must + * and killed variables. Therefore, for a temp number, the bit number must * be biased with tempmin. * * There may be an idea to use a different data structure to store @@ -430,21 +479,31 @@ LIVEADD(int x) { RDEBUG(("Liveadd: %d\n", x)); - if (x < tempmin || x >= tempmax) + if (x >= MAXREGS && (x < tempmin || x >= tempmax)) comperr("LIVEADD: out of range"); - BITSET(live, (x-tempmin)); + if (x < MAXREGS) { + BITSET(live, x); + } else + BITSET(live, (x-tempmin+MAXREGS)); } + static void LIVEDEL(int x) { RDEBUG(("Livedel: %d\n", x)); - if (x < tempmin || x >= tempmax) + + if (x >= MAXREGS && (x < tempmin || x >= tempmax)) comperr("LIVEDEL: out of range"); - BITCLEAR(live, (x-tempmin)); + if (x < MAXREGS) { + BITCLEAR(live, x); + } else + BITCLEAR(live, (x-tempmin+MAXREGS)); } #else -#define LIVEADD(x) BITSET(live, (x-tempmin)) -#define LIVEDEL(x) BITCLEAR(live, (x-tempmin)) +#define LIVEADD(x) \ + (x >= MAXREGS ? BITSET(live, (x-tempmin+MAXREGS)) : BITSET(live, x)) +#define LIVEDEL(x) \ + (x >= MAXREGS ? BITCLEAR(live, (x-tempmin+MAXREGS)) : BITCLEAR(live, x)) #endif static struct lives { @@ -479,7 +538,9 @@ { struct lives *l; +#ifdef PCC_DEBUG RDEBUG(("LIVEDELR: %d\n", x->nodnum)); +#endif DLIST_FOREACH(l, &lused, link) { if (l->var != x) continue; @@ -515,10 +576,11 @@ return w; } +#define HASHSZ 16384 struct AdjSet { struct AdjSet *next; REGW *u, *v; -} *edgehash[256]; +} *edgehash[HASHSZ]; /* Check if a node pair is adjacent */ static int @@ -543,7 +605,7 @@ } if (u > v) t = v, v = u, u = t; - w = edgehash[((long)u+(long)v) & 255]; + w = edgehash[((intptr_t)u+(intptr_t)v) & (HASHSZ-1)]; for (; w; w = w->next) { if (u == w->u && v == w->v) return 1; @@ -561,7 +623,7 @@ if (u > v) t = v, v = u, u = t; - x = ((long)u+(long)v) & 255; + x = ((intptr_t)u+(intptr_t)v) & (HASHSZ-1); w = tmpalloc(sizeof(struct AdjSet)); w->u = u, w->v = v; w->next = edgehash[x]; @@ -576,9 +638,9 @@ { ADJL *x; +#ifdef PCC_DEBUG RRDEBUG(("AddEdge: u %d v %d\n", ASGNUM(u), ASGNUM(v))); -#ifdef PCC_DEBUG #if 0 if (ASGNUM(u) == 0) comperr("AddEdge 0"); @@ -678,10 +740,11 @@ addalledges(REGW *e) { int i, j, k; - int nbits = xbits; struct lives *l; +#ifdef PCC_DEBUG RDEBUG(("addalledges for %d\n", e->nodnum)); +#endif if (e->r_class == -1) return; /* unused */ @@ -691,14 +754,17 @@ AddEdge(e, &ablock[ndontregs[i]]); } - /* First add to long-lived temps */ + /* First add to long-lived temps and hard regs */ RDEBUG(("addalledges longlived ")); - for (i = 0; i < nbits; i += NUMBITS) { + for (i = 0; i < xbits; i += NUMBITS) { if ((k = live[i/NUMBITS]) == 0) continue; while (k) { j = ffs(k)-1; - AddEdge(&nblock[i+j+tempmin], e); + if (i+j < MAXREGS) + AddEdge(&ablock[i+j], e); + else + AddEdge(&nblock[i+j+tempmin-MAXREGS], e); RRDEBUG(("%d ", i+j+tempmin)); k &= ~(1 << j); } @@ -707,7 +773,9 @@ /* short-lived temps */ RDEBUG(("addalledges shortlived ")); DLIST_FOREACH(l, &lused, link) { +#ifdef PCC_DEBUG RRDEBUG(("%d ", ASGNUM(l->var))); +#endif AddEdge(l->var, e); } RDEBUG(("done\n")); @@ -723,7 +791,9 @@ if (def == use) return; /* no move to itself XXX - ``shouldn't happen'' */ +#ifdef PCC_DEBUG RDEBUG(("moveadd: def %d use %d\n", ASGNUM(def), ASGNUM(use))); +#endif r = WORKLISTMOVEADD(use, def); MOVELISTADD(def, r); @@ -754,23 +824,25 @@ setlive(NODE *p, int set, REGW *rv) { if (rv != NULL) { + if (rv->nodnum < MAXREGS && + TESTBIT(validregs, rv->nodnum) == 0) + return; set ? LIVEADDR(rv) : LIVEDELR(rv); return; } if (p->n_regw != NULL) { + if (p->n_regw->nodnum < MAXREGS && + TESTBIT(validregs, p->n_regw->nodnum) == 0) + return; set ? LIVEADDR(p->n_regw) : LIVEDELR(p->n_regw); return; } switch (optype(p->n_op)) { case LTYPE: - if (p->n_op == TEMP) - set ? LIVEADD((int)p->n_lval) : LIVEDEL((int)p->n_lval); -#ifdef notyet - else if (p->n_op == REG) - ... -#endif + if (p->n_op == TEMP || VALIDREG(p)) + set ? LIVEADD(regno(p)) : LIVEDEL(regno(p)); break; case BITYPE: setlive(p->n_right, set, rv); @@ -788,7 +860,12 @@ static void addedge_r(NODE *p, REGW *w) { + RRDEBUG(("addedge_r: node %p regw %p\n", p, w)); + if (p->n_regw != NULL) { + if (p->n_regw->nodnum < MAXREGS && + TESTBIT(validregs, p->n_regw->nodnum) == 0) + return; AddEdge(p->n_regw, w); return; } @@ -800,6 +877,50 @@ } /* + * add/del parameter from live set. + */ +static void +setxarg(NODE *p) +{ + int i, ut = 0, in = 0; + int cw; + + if (p->n_op == ICON && p->n_type == STRTY) + return; + + RDEBUG(("setxarg %p %s\n", p, p->n_name)); + cw = xasmcode(p->n_name); + if (XASMISINP(cw)) + in = 1; + if (XASMISOUT(cw)) + ut = 1; + + switch (XASMVAL(cw)) { + case 'g': + if (p->n_left->n_op != REG && p->n_left->n_op != TEMP) + break; + /* FALLTHROUGH */ + case 'r': + i = regno(p->n_left); + if (ut) { + REGW *rw = p->n_left->n_op == REG ? ablock : nblock; + LIVEDEL(i); + addalledges(&rw[i]); + } + if (in) { + LIVEADD(i); + } + break; + case 'i': + case 'm': + case 'n': + break; + default: + comperr("bad ixarg %s", p->n_name); + } +} + +/* * Do the in-tree part of liveness analysis. (the difficult part) * * Walk down the tree in reversed-evaluation order (backwards). @@ -825,14 +946,13 @@ * Moves to special regs are scheduled after the evaluation of both legs. */ -#define ASGLEFT(p) (p->n_op == ASSIGN && p->n_left->n_op == TEMP) - static void insnwalk(NODE *p) { int o = p->n_op; struct optab *q = &table[TBLIDX(p->n_su)]; REGW *lr, *rr, *rv, *r, *rrv, *lrv; + NODE *lp, *rp; int i, n; RDEBUG(("insnwalk %p\n", p)); @@ -840,14 +960,16 @@ rv = p->n_regw; rrv = lrv = NULL; - if (ASGLEFT(p)) { - int v = p->n_left->n_lval; - LIVEDEL(v); /* remove assigned temp from live set */ - addalledges(&nblock[v]); + if (p->n_op == ASSIGN && + (p->n_left->n_op == TEMP || VALIDREG(p->n_left))) { + lr = p->n_left->n_op == TEMP ? nblock : ablock; + i = regno(p->n_left); + LIVEDEL(i); /* remove assigned temp from live set */ + addalledges(&lr[i]); } /* Add edges for the result of this node */ - if (rv && (q->visit & INREGS || o == TEMP)) + if (rv && (q->visit & INREGS || o == TEMP || VALIDREG(p))) addalledges(rv); /* special handling of CALL operators */ @@ -866,24 +988,36 @@ /* Check leaves for results in registers */ lr = optype(o) != LTYPE ? p->n_left->n_regw : NULL; + lp = optype(o) != LTYPE ? p->n_left : NULL; rr = optype(o) == BITYPE ? p->n_right->n_regw : NULL; + rp = optype(o) == BITYPE ? p->n_right : NULL; /* simple needs */ n = ncnt(q->needs); for (i = 0; i < n; i++) { #if 1 - static int ncl[] = { 0, NASL, NBSL, NCSL, NDSL }; - static int ncr[] = { 0, NASR, NBSR, NCSR, NDSR }; - + static int ncl[] = + { 0, NASL, NBSL, NCSL, NDSL, NESL, NFSL, NGSL }; + static int ncr[] = + { 0, NASR, NBSR, NCSR, NDSR, NESR, NFSR, NGSR }; + int j; + /* edges are already added */ - if ((r = &p->n_regw[1+i])->r_class == -1) + if ((r = &p->n_regw[1+i])->r_class == -1) { r = p->n_regw; - else + } else { + AddEdge(r, p->n_regw); addalledges(r); + } if (optype(o) != LTYPE && (q->needs & ncl[CLASS(r)]) == 0) addedge_r(p->n_left, r); if (optype(o) == BITYPE && (q->needs & ncr[CLASS(r)]) == 0) addedge_r(p->n_right, r); + for (j = i + 1; j < n; j++) { + if (p->n_regw[j+1].r_class == -1) + continue; + AddEdge(r, &p->n_regw[j+1]); + } #else if ((r = &p->n_regw[1+i])->r_class == -1) continue; @@ -924,6 +1058,13 @@ } if (o == ASSIGN) { + /* avoid use of unhandled registers */ + if (p->n_left->n_op == REG && + !TESTBIT(validregs, regno(p->n_left))) + lr = NULL; + if (p->n_right->n_op == REG && + !TESTBIT(validregs, regno(p->n_right))) + rr = NULL; /* needs special treatment */ if (lr && rr) moveadd(lr, rr); @@ -932,33 +1073,31 @@ if (rr && rv) moveadd(rr, rv); } else if (callop(o)) { -#ifdef notdef - /* calls needs special treatment */ - for (i = 0; tempregs[i] >= 0; i++) - addalledges(&ablock[i]); - if (rv) - moveadd(rv, &ablock[RETREG(p->n_type)]); -#endif - /* XXX - here must all live arg registers be added - * for archs with arguments in registers */ + int *c; + + for (c = livecall(p); *c != -1; c++) { + addalledges(ablock + *c); + LIVEADD(*c); + } } else if (q->rewrite & (RESC1|RESC2|RESC3)) { if (lr && rr) AddEdge(lr, rr); } else if (q->rewrite & RLEFT) { if (lr && rv) moveadd(rv, lr), lrv = rv; - if (rr && rv) - AddEdge(rr, rv); + if (rv && rp) + addedge_r(rp, rv); } else if (q->rewrite & RRIGHT) { if (rr && rv) moveadd(rv, rr), rrv = rv; - if (lr && rv) - AddEdge(lr, rv); + if (rv && lp) + addedge_r(lp, rv); } switch (optype(o)) { case BITYPE: - if (ASGLEFT(p)) { + if (p->n_op == ASSIGN && + (p->n_left->n_op == TEMP || p->n_left->n_op == REG)) { /* only go down right node */ insnwalk(p->n_right); } else if (callop(o)) { @@ -984,18 +1123,23 @@ case LTYPE: switch (o) { + case REG: + if (!TESTBIT(validregs, regno(p))) + break; /* never add moves */ + /* FALLTHROUGH */ case TEMP: - rr = &nblock[(int)p->n_lval]; + i = regno(p); + rr = (o == TEMP ? &nblock[i] : &ablock[i]); if (rv != rr) { addalledges(rr); moveadd(rv, rr); } - LIVEADD((int)p->n_lval); - break; - case REG: - case OREG: - /* Liveness for regs??? */ + LIVEADD(i); break; + + case OREG: /* XXX - not yet */ + break; + default: break; } @@ -1003,8 +1147,218 @@ } } -static bittype **gen, **kill, **in, **out; +static bittype **gen, **killed, **in, **out; + +#define MAXNSPILL 100 +static int notspill[MAXNSPILL], nspill; + +static int +innotspill(int n) +{ + int i; + for (i = 0; i < nspill; i++) + if (notspill[i] == n) + return 1; + return 0; +} + +/* + * Found an extended assembler node, so growel out gen/killed nodes. + */ +static void +xasmionize(NODE *p, void *arg) +{ + int bb = *(int *)arg; + int cw, b; + + if (p->n_op == ICON && p->n_type == STRTY) + return; /* dummy end marker */ + + cw = xasmcode(p->n_name); + if (XASMVAL(cw) == 'n' || XASMVAL(cw) == 'm') + return; /* no flow analysis */ + p = p->n_left; + + if (XASMVAL(cw) == 'g' && p->n_op != TEMP && p->n_op != REG) + return; /* no flow analysis */ + + b = regno(p); + if (XASMVAL(cw) == 'r' && p->n_op == TEMP) { + if (!innotspill(b)) { + if (nspill < MAXNSPILL) + notspill[nspill++] = b; + else + werror("MAXNSPILL overbooked"); + } + } + if (XASMISOUT(cw)) { + if (p->n_op == TEMP) { + b -= tempmin+MAXREGS; + BITCLEAR(gen[bb], b); + BITSET(killed[bb], b); + } else if (p->n_op == REG) { + BITCLEAR(gen[bb], b); + BITSET(killed[bb], b); + } else + uerror("bad xasm node type"); + } + if (XASMISINP(cw)) { + if (p->n_op == TEMP) { + BITSET(gen[bb], (b - tempmin+MAXREGS)); + } else if (p->n_op == REG) { + BITSET(gen[bb], b); + } else if (optype(p->n_op) != LTYPE) { + if (XASMVAL(cw) == 'r') + uerror("couldn't find available register"); + else + uerror("bad xasm node type2"); + } + } +} + +#ifndef XASMCONSTREGS +#define XASMCONSTREGS(x) (-1) +#endif + +/* + * Check that given constraints are valid. + */ +static void +xasmconstr(NODE *p, void *arg) +{ + int i; + + if (p->n_op == ICON && p->n_type == STRTY) + return; /* no constraints */ + + if (strcmp(p->n_name, "cc") == 0 || strcmp(p->n_name, "memory") == 0) + return; + + for (i = 0; i < MAXREGS; i++) + if (strcmp(rnames[i], p->n_name) == 0) { + addalledges(&ablock[i]); + return; + } + if ((i = XASMCONSTREGS(p->n_name)) < 0) + comperr("unsupported xasm constraint %s", p->n_name); + addalledges(&ablock[i]); +} + +#define RUP(x) (((x)+NUMBITS-1)/NUMBITS) +#define SETCOPY(t,f,i,n) for (i = 0; i < RUP(n); i++) t[i] = f[i] +#define SETSET(t,f,i,n) for (i = 0; i < RUP(n); i++) t[i] |= f[i] +#define SETCLEAR(t,f,i,n) for (i = 0; i < RUP(n); i++) t[i] &= ~f[i] +#define SETCMP(v,t,f,i,n) for (i = 0; i < RUP(n); i++) \ + if (t[i] != f[i]) v = 1 +#define SETEMPTY(t,sz) memset(t, 0, BIT2BYTE(sz)) + +static int +deldead(NODE *p, bittype *lvar) +{ + NODE *q; + int ty, rv = 0; + +#define BNO(p) (regno(p) - tempmin+MAXREGS) + if (p->n_op == TEMP) + BITSET(lvar, BNO(p)); + if (asgop(p->n_op) && p->n_left->n_op == TEMP && + TESTBIT(lvar, BNO(p->n_left)) == 0) { + /* + * Not live, must delete the right tree at least + * down to next statement with side effects. + */ + BDEBUG(("DCE deleting temp %d\n", regno(p->n_left))); + nfree(p->n_left); + q = p->n_right; + *p = *q; + nfree(q); + rv = 1; + } + ty = optype(p->n_op); + if (ty != LTYPE) + rv |= deldead(p->n_left, lvar); + if (ty == BITYPE) + rv |= deldead(p->n_right, lvar); + return rv; +} + +/* + * Do dead code elimination. + */ +static int +dce(struct p2env *p2e) +{ + extern struct interpass prepole; + struct basicblock *bb; + struct interpass *ip; + NODE *p; + bittype *lvar; + int i, bbnum, fix = 0; + + BDEBUG(("Entering DCE\n")); + /* + * Traverse over the basic blocks. + * if an assignment is found that writes to a temporary + * that is not live out, remove that assignment and its legs. + */ + DLIST_INIT(&prepole, qelem); + BITALLOC(lvar, alloca, xbits); + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { + bbnum = bb->bbnum; + BDEBUG(("DCE bblock %d, start %p last %p\n", + bbnum, bb->first, bb->last)); + SETCOPY(lvar, out[bbnum], i, xbits); + for (ip = bb->last; ; ip = DLIST_PREV(ip, qelem)) { + if (ip->type == IP_NODE && deldead(ip->ip_node, lvar)) { + if ((p = deluseless(ip->ip_node)) == NULL) { +#ifdef notyet + if (ip == bb->last) { + bb->last = + DLIST_PREV(ip, qelem); + } else if (ip == bb->first) { + bb->first = + DLIST_NEXT(ip, qelem); + } + DLIST_REMOVE(ip, qelem); +#else + ip->type = IP_ASM; + ip->ip_asm = ""; +#endif + fix++; + BDEBUG(("DCE ip %p deleted\n", ip)); + } else while (!DLIST_ISEMPTY(&prepole, qelem)) { + BDEBUG(("DCE doing ip prepend\n")); +#ifdef notyet + struct interpass *tipp; + tipp = DLIST_NEXT(&prepole, qelem); + DLIST_REMOVE(tipp, qelem); + DLIST_INSERT_BEFORE(ip, tipp, qelem); + if (ip == bb->first) + bb->first = tipp; + fix++; +#else + comperr("dce needs bb fixup"); +#endif + BDEBUG(("DCE ip prepended\n")); + } + if (ip->type == IP_NODE) { + geninsn(p, FOREFF); + nsucomp(p); + ip->ip_node = p; + } + } + if (ip == bb->first) + break; + } + } + BDEBUG(("DCE fix %d\n", fix)); + return fix; +} + +/* + * Set/clear long term liveness for regs and temps. + */ static void unionize(NODE *p, int bb) { @@ -1013,27 +1367,37 @@ if ((o = p->n_op) == TEMP) { #ifdef notyet for (i = 0; i < szty(p->n_type); i++) { - BITSET(gen[bb], ((int)p->n_lval - tempmin+i)); + BITSET(gen[bb], (regno(p) - tempmin+i+MAXREGS)); } #else i = 0; - BITSET(gen[bb], ((int)p->n_lval - tempmin+i)); + BITSET(gen[bb], (regno(p) - tempmin+i+MAXREGS)); #endif + } else if (VALIDREG(p)) { + BITSET(gen[bb], regno(p)); } - if (asgop(o) && p->n_left->n_op == TEMP) { - int b = p->n_left->n_lval - tempmin; + if (asgop(o)) { + if (p->n_left->n_op == TEMP) { + int b = regno(p->n_left) - tempmin+MAXREGS; #ifdef notyet - for (i = 0; i < szty(p->n_type); i++) { - BITCLEAR(gen[bb], (b+i)); - BITSET(kill[bb], (b+i)); - } + for (i = 0; i < szty(p->n_type); i++) { + BITCLEAR(gen[bb], (b+i)); + BITSET(killed[bb], (b+i)); + } #else - i = 0; - BITCLEAR(gen[bb], (b+i)); - BITSET(kill[bb], (b+i)); + i = 0; + BITCLEAR(gen[bb], (b+i)); + BITSET(killed[bb], (b+i)); #endif - unionize(p->n_right, bb); - return; + unionize(p->n_right, bb); + return; + } else if (VALIDREG(p->n_left)) { + int b = regno(p->n_left); + BITCLEAR(gen[bb], b); + BITSET(killed[bb], b); + unionize(p->n_right, bb); + return; + } } ty = optype(o); if (ty != LTYPE) @@ -1049,62 +1413,60 @@ * when doing short-range liveness analysis in Build(). */ static void -LivenessAnalysis(void) +LivenessAnalysis(struct p2env *p2e) { - extern struct basicblock bblocks; struct basicblock *bb; struct interpass *ip; int i, bbnum; /* - * generate the gen-kill sets for all basic blocks. + * generate the gen-killed sets for all basic blocks. */ - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { bbnum = bb->bbnum; for (ip = bb->last; ; ip = DLIST_PREV(ip, qelem)) { - /* gen/kill is 'p', this node is 'n' */ - if (ip->type == IP_NODE) - unionize(ip->ip_node, bbnum); + /* gen/killed is 'p', this node is 'n' */ + if (ip->type == IP_NODE) { + if (ip->ip_node->n_op == XASM) + flist(ip->ip_node->n_left, + xasmionize, &bbnum); + else + unionize(ip->ip_node, bbnum); + } if (ip == bb->first) break; } - memcpy(in[bbnum], gen[bbnum], BIT2BYTE(tempmax-tempmin)); + memcpy(in[bbnum], gen[bbnum], BIT2BYTE(xbits)); #ifdef PCC_DEBUG +#define PRTRG(x) printf("%d ", i < MAXREGS ? i : i + tempmin-MAXREGS) if (rdebug) { printf("basic block %d\ngen: ", bbnum); - for (i = 0; i < tempmax-tempmin; i++) + for (i = 0; i < xbits; i++) if (TESTBIT(gen[bbnum], i)) - printf("%d ", i+tempmin); - printf("\nkill: "); - for (i = 0; i < tempmax-tempmin; i++) - if (TESTBIT(kill[bbnum], i)) - printf("%d ", i+tempmin); + PRTRG(i); + printf("\nkilled: "); + for (i = 0; i < xbits; i++) + if (TESTBIT(killed[bbnum], i)) + PRTRG(i); printf("\n"); } #endif } } -#define SETCOPY(t,f,i,n) for (i = 0; i < n/NUMBITS; i++) t[i] = f[i] -#define SETSET(t,f,i,n) for (i = 0; i < n/NUMBITS; i++) t[i] |= f[i] -#define SETCLEAR(t,f,i,n) for (i = 0; i < n/NUMBITS; i++) t[i] &= ~f[i] -#define SETCMP(v,t,f,i,n) for (i = 0; i < n/NUMBITS; i++) \ - if (t[i] != f[i]) v = 1 - /* * Build the set of interference edges and adjacency list. */ static void -Build(struct interpass *ipole) +Build(struct p2env *p2e) { - extern struct basicblock bblocks; + struct interpass *ipole = &p2e->ipole; struct basicblock bbfake; struct interpass *ip; struct basicblock *bb; struct cfgnode *cn; - extern int nbblocks; bittype *saved; - int i, j, again, nbits; + int i, j, again; if (xtemps == 0) { /* @@ -1112,35 +1474,37 @@ * so fake one basic block to keep the liveness analysis * happy. */ - nbblocks = 1; + p2e->nbblocks = 1; bbfake.bbnum = 0; bbfake.last = DLIST_PREV(ipole, qelem); bbfake.first = DLIST_NEXT(ipole, qelem); - DLIST_INIT(&bblocks, bbelem); - DLIST_INSERT_AFTER(&bblocks, &bbfake, bbelem); + DLIST_INIT(&p2e->bblocks, bbelem); + DLIST_INSERT_AFTER(&p2e->bblocks, &bbfake, bbelem); SLIST_INIT(&bbfake.children); } /* Just fetch space for the temporaries from stack */ - nbits = xbits+(NUMBITS-1); - gen = alloca(nbblocks*sizeof(bittype*)); - kill = alloca(nbblocks*sizeof(bittype*)); - in = alloca(nbblocks*sizeof(bittype*)); - out = alloca(nbblocks*sizeof(bittype*)); - for (i = 0; i < nbblocks; i++) { - BITALLOC(gen[i],alloca,nbits); - BITALLOC(kill[i],alloca,nbits); - BITALLOC(in[i],alloca,nbits); - BITALLOC(out[i],alloca,nbits); - } - BITALLOC(saved,alloca,nbits); - LivenessAnalysis(); + gen = alloca(p2e->nbblocks*sizeof(bittype*)); + killed = alloca(p2e->nbblocks*sizeof(bittype*)); + in = alloca(p2e->nbblocks*sizeof(bittype*)); + out = alloca(p2e->nbblocks*sizeof(bittype*)); + for (i = 0; i < p2e->nbblocks; i++) { + BITALLOC(gen[i],alloca,xbits); + BITALLOC(killed[i],alloca,xbits); + BITALLOC(in[i],alloca,xbits); + BITALLOC(out[i],alloca,xbits); + } + BITALLOC(saved,alloca,xbits); + + nspill = 0; +livagain: + LivenessAnalysis(p2e); /* register variable temporaries are live */ for (i = 0; i < NPERMREG-1; i++) { if (nsavregs[i]) continue; - BITSET(out[nbblocks-1], i); + BITSET(out[p2e->nbblocks-1], (i+MAXREGS)); for (j = i+1; j < NPERMREG-1; j++) { if (nsavregs[j]) continue; @@ -1152,47 +1516,73 @@ do { again = 0; /* XXX - loop should be in reversed execution-order */ - DLIST_FOREACH_REVERSE(bb, &bblocks, bbelem) { - int i = bb->bbnum; - SETCOPY(saved, out[i], j, nbits); + DLIST_FOREACH_REVERSE(bb, &p2e->bblocks, bbelem) { + i = bb->bbnum; + SETCOPY(saved, out[i], j, xbits); SLIST_FOREACH(cn, &bb->children, cfgelem) { - SETSET(out[i], in[cn->bblock->bbnum], - j, nbits); + SETSET(out[i], in[cn->bblock->bbnum], j, xbits); } - SETCMP(again, saved, out[i], j, nbits); - SETCOPY(saved, in[i], j, nbits); - SETCOPY(in[i], out[i], j, nbits); - SETCLEAR(in[i], kill[i], j, nbits); - SETSET(in[i], gen[i], j, nbits); - SETCMP(again, saved, in[i], j, nbits); + SETCMP(again, saved, out[i], j, xbits); + SETCOPY(saved, in[i], j, xbits); + SETCOPY(in[i], out[i], j, xbits); + SETCLEAR(in[i], killed[i], j, xbits); + SETSET(in[i], gen[i], j, xbits); + SETCMP(again, saved, in[i], j, xbits); } } while (again); #ifdef PCC_DEBUG if (rdebug) { - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { printf("basic block %d\nin: ", bb->bbnum); - for (i = 0; i < tempmax-tempmin; i++) + for (i = 0; i < xbits; i++) if (TESTBIT(in[bb->bbnum], i)) - printf("%d ", i+tempmin); + PRTRG(i); printf("\nout: "); - for (i = 0; i < tempmax-tempmin; i++) + for (i = 0; i < xbits; i++) if (TESTBIT(out[bb->bbnum], i)) - printf("%d ", i+tempmin); + PRTRG(i); printf("\n"); } } #endif + if (xtemps && xdce) { + /* + * Do dead code elimination by using live out. + * Ignores if any variable read from is marked volatile, + * but what it should do is unspecified anyway. + * Liveness Analysis should be done in optim2 instead. + * + * This should recalculate the basic block structure. + */ + if (dce(p2e)) { + /* Clear bitfields */ + for (i = 0; i < p2e->nbblocks; i++) { + SETEMPTY(gen[i],xbits); + SETEMPTY(killed[i],xbits); + SETEMPTY(in[i],xbits); + SETEMPTY(out[i],xbits); + } + SETEMPTY(saved,xbits); + goto livagain; + } + } - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { RDEBUG(("liveadd bb %d\n", bb->bbnum)); i = bb->bbnum; - for (j = 0; j < (tempmax-tempmin); j += NUMBITS) + for (j = 0; j < xbits; j += NUMBITS) live[j/NUMBITS] = 0; - SETCOPY(live, out[i], j, nbits); + SETCOPY(live, out[i], j, xbits); for (ip = bb->last; ; ip = DLIST_PREV(ip, qelem)) { - if (ip->type == IP_NODE) - insnwalk(ip->ip_node); + if (ip->type == IP_NODE) { + if (ip->ip_node->n_op == XASM) { + flist(ip->ip_node->n_right, + xasmconstr, 0); + listf(ip->ip_node->n_left, setxarg); + } else + insnwalk(ip->ip_node); + } if (ip == bb->first) break; } @@ -1200,14 +1590,13 @@ #ifdef PCC_DEBUG if (rdebug) { - int i; struct AdjSet *w; ADJL *x; REGW *y; MOVL *m; printf("Interference edges\n"); - for (i = 0; i < 256; i++) { + for (i = 0; i < HASHSZ; i++) { if ((w = edgehash[i]) == NULL) continue; for (; w; w = w->next) @@ -1217,14 +1606,16 @@ DLIST_FOREACH(y, &initial, link) { printf("%d (%c): trivial [%d] ", ASGNUM(y), CLASS(y)+'@', trivially_colorable(y)); + i = 0; for (x = ADJLIST(y); x; x = x->r_next) { if (ONLIST(x->a_temp) != &selectStack && ONLIST(x->a_temp) != &coalescedNodes) printf("%d ", ASGNUM(x->a_temp)); else printf("(%d) ", ASGNUM(x->a_temp)); + i++; } - printf("\n"); + printf(": n=%d\n", i); } printf("Move nodes\n"); DLIST_FOREACH(y, &initial, link) { @@ -1281,7 +1672,9 @@ { int wast; +#ifdef PCC_DEBUG RRDEBUG(("DecrementDegree: w %d, c %d\n", ASGNUM(w), c)); +#endif wast = trivially_colorable(w); NCLASS(w, c)--; @@ -1306,7 +1699,9 @@ w = POPWLIST(simplifyWorklist); PUSHWLIST(w, selectStack); +#ifdef PCC_DEBUG RDEBUG(("Simplify: node %d class %d\n", ASGNUM(w), w->r_class)); +#endif l = w->r_adjList; for (; l; l = l->r_next) { @@ -1328,10 +1723,10 @@ static int OK(REGW *t, REGW *r) { +#ifdef PCC_DEBUG RDEBUG(("OK: t %d CLASS(t) %d adjSet(%d,%d)=%d\n", ASGNUM(t), CLASS(t), ASGNUM(t), ASGNUM(r), adjSet(t, r))); -#ifdef PCC_DEBUG if (rdebug > 1) { ADJL *w; int ndeg = 0; @@ -1376,7 +1771,6 @@ return 1; } -#define oldcons /* check some more */ /* * Do a conservative estimation of whether two temporaries can * be coalesced. This is "Briggs-style" check. @@ -1387,41 +1781,8 @@ { ADJL *w, *ww; REGW *n; -#ifdef oldcons - int i, ncl[NUMCLASS+1]; - - if (CLASS(u) != CLASS(v)) - comperr("Conservative: u(%d = %d), v(%d = %d)", - ASGNUM(u), CLASS(u), ASGNUM(v), CLASS(v)); - - for (i = 0; i < NUMCLASS+1; i++) - ncl[i] = 0; - - RDEBUG(("Conservative (%d,%d)\n", ASGNUM(u), ASGNUM(v))); - - for (w = ADJLIST(u); w; w = w->r_next) { - n = w->a_temp; - if (ONLIST(n) == &selectStack || ONLIST(n) == &coalescedNodes) - continue; - for (ww = ADJLIST(v); ww; ww = ww->r_next) - if (ww->a_temp == n) - break; - if (ww) - continue; - if (!trivially_colorable(n)) - ncl[CLASS(n)]++; - } - for (w = ADJLIST(v); w; w = w->r_next) { - n = w->a_temp; - if (ONLIST(n) == &selectStack || ONLIST(n) == &coalescedNodes) - continue; - if (!trivially_colorable(n)) - ncl[CLASS(n)]++; - } - i = trivially_colorable_p(CLASS(u), ncl); -#endif -{ int xncl[NUMCLASS+1], mcl = 0, j; + for (j = 0; j < NUMCLASS+1; j++) xncl[j] = 0; /* @@ -1461,17 +1822,7 @@ break; } out: j = trivially_colorable_p(CLASS(u), xncl); -#ifdef oldcons - if (j != i) - comperr("Conservative: j %d i %d", j, i); -#else return j; -#endif -} -#ifdef oldcons - RDEBUG(("Conservative i=%d\n", i)); - return i; -#endif } static void @@ -1492,7 +1843,9 @@ ADJL *l; REGW *t; +#ifdef PCC_DEBUG RDEBUG(("Combine (%d,%d)\n", ASGNUM(u), ASGNUM(v))); +#endif if (ONLIST(v) == &freezeWorklist) { DELWLIST(v); @@ -1501,12 +1854,14 @@ } PUSHWLIST(v, coalescedNodes); ALIAS(v) = u; +#ifdef PCC_DEBUG if (rdebug) { printf("adjlist(%d): ", ASGNUM(v)); for (l = ADJLIST(v); l; l = l->r_next) printf("%d ", l->a_temp->nodnum); printf("\n"); } +#endif #if 1 { MOVL *m0 = MOVELIST(v); @@ -1544,6 +1899,7 @@ DELWLIST(u); PUSHWLIST(u, spillWorklist); } +#ifdef PCC_DEBUG if (rdebug) { ADJL *w; printf("Combine %d class (%d): ", ASGNUM(u), CLASS(u)); @@ -1556,6 +1912,7 @@ } printf("\n"); } +#endif } static void @@ -1573,9 +1930,11 @@ else u = x, v = y; +#ifdef PCC_DEBUG RDEBUG(("Coalesce: src %d dst %d u %d v %d x %d y %d\n", ASGNUM(m->src), ASGNUM(m->dst), ASGNUM(u), ASGNUM(v), ASGNUM(x), ASGNUM(y))); +#endif if (CLASS(m->src) != CLASS(m->dst)) comperr("Coalesce: src class %d, dst class %d", @@ -1620,8 +1979,10 @@ v = GetAlias(x); else v = GetAlias(y); +#ifdef PCC_DEBUG RDEBUG(("FreezeMoves: u %d (%d,%d) v %d\n", ASGNUM(u),ASGNUM(x),ASGNUM(y),ASGNUM(v))); +#endif DLIST_REMOVE(m, link); PUSHMLIST(m, frozenMoves, FROZEN); if (ONLIST(v) != &freezeWorklist) @@ -1649,7 +2010,9 @@ */ u = POPWLIST(freezeWorklist); PUSHWLIST(u, simplifyWorklist); +#ifdef PCC_DEBUG RDEBUG(("Freeze %d\n", ASGNUM(u))); +#endif FreezeMoves(u); } @@ -1659,9 +2022,11 @@ REGW *w; RDEBUG(("SelectSpill\n")); +#ifdef PCC_DEBUG if (rdebug) DLIST_FOREACH(w, &spillWorklist, link) printf("SelectSpill: %d\n", ASGNUM(w)); +#endif /* First check if we can spill register variables */ DLIST_FOREACH(w, &spillWorklist, link) { @@ -1672,6 +2037,8 @@ if (w == &spillWorklist) { /* try to find another long-range variable */ DLIST_FOREACH(w, &spillWorklist, link) { + if (innotspill(w - nblock)) + continue; if (w >= &nblock[tempmin] && w < &nblock[tempmax]) break; } @@ -1695,41 +2062,42 @@ DLIST_REMOVE(w, link); PUSHWLIST(w, simplifyWorklist); +#ifdef PCC_DEBUG RDEBUG(("Freezing node %d\n", ASGNUM(w))); +#endif FreezeMoves(w); } -int gregn(REGW *); - -int -gregn(REGW *w) -{ - return w->nodnum; -} - /* * Set class on long-lived temporaries based on its type. */ static void -traclass(NODE *p) +traclass(NODE *p, void *arg) { REGW *nb; if (p->n_op != TEMP) return; - nb = &nblock[(int)p->n_lval]; + nb = &nblock[regno(p)]; if (CLASS(nb) == 0) CLASS(nb) = gclass(p->n_type); } static void -paint(NODE *p) +paint(NODE *p, void *arg) { struct optab *q; REGW *w, *ww; int i; +#ifdef notyet + /* XXX - trashes rewrite of trees (short) */ + if (!DLIST_ISEMPTY(&spilledNodes, link)) { + p->n_reg = 0; + return; + } +#endif if (p->n_regw != NULL) { /* Must color all allocated regs also */ ww = w = p->n_regw; @@ -1747,8 +2115,8 @@ } else p->n_reg = -1; if (p->n_op == TEMP) { - REGW *nb = &nblock[(int)p->n_lval]; - p->n_rval = COLOR(nb); + REGW *nb = &nblock[regno(p)]; + regno(p) = COLOR(nb); if (TCLASS(p->n_su) == 0) SCLASS(p->n_su, CLASS(nb)); p->n_op = REG; @@ -1759,6 +2127,7 @@ static void AssignColors(struct interpass *ip) { + struct interpass *ip2; int okColors, c; REGW *o, *w; ADJL *x; @@ -1767,13 +2136,17 @@ while (!WLISTEMPTY(selectStack)) { w = POPWLIST(selectStack); okColors = classmask(CLASS(w)); +#ifdef PCC_DEBUG RDEBUG(("classmask av %d, class %d: %x\n", w->nodnum, CLASS(w), okColors)); +#endif for (x = ADJLIST(w); x; x = x->r_next) { o = GetAlias(x->a_temp); +#ifdef PCC_DEBUG RRDEBUG(("Adj(%d): %d (%d)\n", ASGNUM(w), ASGNUM(o), ASGNUM(x->a_temp))); +#endif if (ONLIST(o) == &coloredNodes || ONLIST(o) == &precolored) { @@ -1787,37 +2160,47 @@ } if (okColors == 0) { PUSHWLIST(w, spilledNodes); +#ifdef PCC_DEBUG RDEBUG(("Spilling node %d\n", ASGNUM(w))); +#endif } else { PUSHWLIST(w, coloredNodes); c = ffs(okColors)-1; COLOR(w) = color2reg(c, CLASS(w)); +#ifdef PCC_DEBUG RDEBUG(("Coloring %d with %s, free %x\n", ASGNUM(w), rnames[COLOR(w)], okColors)); +#endif } } DLIST_FOREACH(w, &coalescedNodes, link) { REGW *ww = GetAlias(w); COLOR(w) = COLOR(ww); if (ONLIST(ww) == &spilledNodes) { +#ifdef PCC_DEBUG RDEBUG(("coalesced node %d spilled\n", w->nodnum)); +#endif ww = DLIST_PREV(w, link); DLIST_REMOVE(w, link); PUSHWLIST(w, spilledNodes); w = ww; - } else + } else { +#ifdef PCC_DEBUG RDEBUG(("Giving coalesced node %d color %s\n", w->nodnum, rnames[COLOR(w)])); +#endif + } } +#ifdef PCC_DEBUG if (rdebug) DLIST_FOREACH(w, &coloredNodes, link) printf("%d: color %s\n", ASGNUM(w), rnames[COLOR(w)]); +#endif if (DLIST_ISEMPTY(&spilledNodes, link)) { - struct interpass *ip2; DLIST_FOREACH(ip2, ip, qelem) if (ip2->type == IP_NODE) - walkf(ip2->ip_node, paint); + walkf(ip2->ip_node, paint, 0); } } @@ -1827,23 +2210,25 @@ * Will never end up here if not optimizing. */ static void -longtemp(NODE *p) +longtemp(NODE *p, void *arg) { + NODE *l, *r; REGW *w; if (p->n_op != TEMP) return; /* XXX - should have a bitmask to find temps to convert */ DLIST_FOREACH(w, spole, link) { - if (w != &nblock[(int)p->n_lval]) + if (w != &nblock[regno(p)]) continue; if (w->r_class == 0) { w->r_color = BITOOR(freetemp(szty(p->n_type))); w->r_class = 1; } - p->n_op = OREG; - p->n_lval = w->r_color; - p->n_rval = FPREG; + l = mklnode(REG, 0, FPREG, INCREF(p->n_type)); + r = mklnode(ICON, w->r_color, 0, INT); + p->n_left = mkbinode(PLUS, l, r, INCREF(p->n_type)); + p->n_op = UMUL; p->n_regw = NULL; break; } @@ -1855,7 +2240,7 @@ * XXX - must check if basic block structure is destroyed! */ static void -shorttemp(NODE *p) +shorttemp(NODE *p, void *arg) { struct interpass *nip; struct optab *q; @@ -1870,10 +2255,14 @@ /* XXX - use canaddr() */ if (p->n_op == OREG || p->n_op == NAME) { DLIST_REMOVE(w, link); +#ifdef PCC_DEBUG RDEBUG(("Node %d already in memory\n", ASGNUM(w))); +#endif break; } +#ifdef PCC_DEBUG RDEBUG(("rewriting node %d\n", ASGNUM(w))); +#endif off = BITOOR(freetemp(szty(p->n_type))); l = mklnode(OREG, off, FPREG, p->n_type); @@ -1923,7 +2312,7 @@ if (ip->type != IP_NODE) continue; cip = ip; - walkf(ip->ip_node, shorttemp); /* convert temps to oregs */ + walkf(ip->ip_node, shorttemp, 0); /* convert temps to oregs */ } if (!DLIST_ISEMPTY(spole, link)) comperr("treerewrite not empty"); @@ -1945,7 +2334,7 @@ continue; nodepole = ip->ip_node; thisline = ip->lineno; - walkf(ip->ip_node, longtemp); /* convert temps to oregs */ + walkf(ip->ip_node, longtemp, 0); /* convert temps to oregs */ } nodepole = NIL; } @@ -1960,19 +2349,21 @@ NODE *p; ip = DLIST_NEXT(ipole, qelem); /* PROLOG */ - ip = DLIST_NEXT(ip, qelem); /* first DEFLAB */ + while (ip->type != IP_DEFLAB) + ip = DLIST_NEXT(ip, qelem); ip = DLIST_NEXT(ip, qelem); /* first NODE */ for (; ip->type != IP_DEFLAB; ip = DLIST_NEXT(ip, qelem)) { if (ip->type == IP_ASM) continue; p = ip->ip_node; -#ifdef PCC_DEBUG +#ifdef notdef + /* register args may already have been put on stack */ if (p->n_op != ASSIGN || p->n_left->n_op != TEMP) comperr("temparg"); #endif if (p->n_right->n_op != OREG) continue; /* arg in register */ - if (w != &nblock[(int)p->n_left->n_lval]) + if (w != &nblock[regno(p->n_left)]) continue; w->r_color = p->n_right->n_lval; tfree(p); @@ -2068,6 +2459,33 @@ return rwtyp; } +#ifdef PCC_DEBUG +/* + * Print TEMP/REG contents in a node. + */ +void +prtreg(FILE *fp, NODE *p) +{ + int i, n = p->n_su == -1 ? 0 : ncnt(table[TBLIDX(p->n_su)].needs); +if (p->n_reg == -1) goto foo; + if (use_regw || p->n_reg > 0x40000000 || p->n_reg < 0) { + fprintf(fp, "TEMP "); + if (p->n_regw != NULL) { + for (i = 0; i < n+1; i++) + fprintf(fp, "%d ", p->n_regw[i].nodnum); + } else + fprintf(fp, ""); + } else { +foo: fprintf(fp, "REG "); + if (p->n_reg != -1) { + for (i = 0; i < n+1; i++) + fprintf(fp, "%s ", rnames[DECRA(p->n_reg, i)]); + } else + fprintf(fp, ""); + } +} +#endif + #ifdef notyet /* * Assign instructions, calculate evaluation order and @@ -2087,15 +2505,16 @@ * Do register allocation for trees by graph-coloring. */ void -ngenregs(struct interpass *ipole) +ngenregs(struct p2env *p2e) { + struct interpass *ipole = &p2e->ipole; extern NODE *nodepole; - struct interpass_prolog *ipp, *epp; struct interpass *ip; - int i, j, nbits = 0; + int i, j, tbits; int uu[NPERMREG] = { -1 }; int xnsavregs[NPERMREG]; int beenhere = 0; + TWORD type; DLIST_INIT(&lunused, link); DLIST_INIT(&lused, link); @@ -2103,11 +2522,8 @@ /* * Do some setup before doing the real thing. */ - ipp = (struct interpass_prolog *)DLIST_NEXT(ipole, qelem); - epp = (struct interpass_prolog *)DLIST_PREV(ipole, qelem); - - tempmin = ipp->ip_tmpnum; - tempmax = epp->ip_tmpnum; + tempmin = p2e->ipp->ip_tmpnum; + tempmax = p2e->epp->ip_tmpnum; /* * Allocate space for the permanent registers in the @@ -2130,16 +2546,16 @@ #ifdef PCC_DEBUG nodnum = tempmax; #endif - nbits = xbits = tempmax - tempmin; - if (nbits) { - nblock = tmpalloc(nbits * sizeof(REGW)); + tbits = tempmax - tempmin; /* # of temporaries */ + xbits = tbits + MAXREGS; /* total size of live array */ + if (tbits) { + nblock = tmpalloc(tbits * sizeof(REGW)); nblock -= tempmin; - live = tmpalloc(BIT2BYTE(nbits)); - RDEBUG(("nblock %p num %d size %zd\n", - nblock, nbits, (int)(nbits * sizeof(REGW)))); + RDEBUG(("nblock %p num %d size %zu\n", + nblock, tbits, (size_t)(tbits * sizeof(REGW)))); } - + live = tmpalloc(BIT2BYTE(xbits)); /* Block for precolored nodes */ ablock = tmpalloc(sizeof(REGW)*MAXREGS); @@ -2159,16 +2575,16 @@ recalc: onlyperm: /* XXX - should not have to redo all */ + memset(edgehash, 0, sizeof(edgehash)); - if (nbits) { - memset(nblock+tempmin, 0, nbits * sizeof(REGW)); - memset(live, 0, BIT2BYTE(nbits)); - memset(edgehash, 0, sizeof(edgehash)); + if (tbits) { + memset(nblock+tempmin, 0, tbits * sizeof(REGW)); #ifdef PCC_DEBUG for (i = tempmin; i < tempmax; i++) nblock[i].nodnum = i; #endif } + memset(live, 0, BIT2BYTE(xbits)); RPRINTIP(ipole); DLIST_INIT(&initial, link); DLIST_FOREACH(ip, ipole, qelem) { @@ -2177,15 +2593,20 @@ continue; nodepole = ip->ip_node; thisline = ip->lineno; - geninsn(ip->ip_node, FOREFF); + if (ip->ip_node->n_op != XASM) + geninsn(ip->ip_node, FOREFF); nsucomp(ip->ip_node); - walkf(ip->ip_node, traclass); + walkf(ip->ip_node, traclass, 0); } nodepole = NIL; RDEBUG(("nsucomp allocated %d temps (%d,%d)\n", tempmax-tempmin, tempmin, tempmax)); +#ifdef PCC_DEBUG + use_regw = 1; RPRINTIP(ipole); + use_regw = 0; +#endif RDEBUG(("ngenregs: numtemps %d (%d, %d)\n", tempmax-tempmin, tempmin, tempmax)); @@ -2205,7 +2626,7 @@ addalledges(&nblock[i+tempmin]); } - Build(ipole); + Build(p2e); RDEBUG(("Build done\n")); MkWorklist(); RDEBUG(("MkWorklist done\n")); @@ -2230,20 +2651,20 @@ case ONLYPERM: goto onlyperm; case SMALL: - optimize(ipole); + optimize(p2e); if (beenhere++ == MAXLOOP) - comperr("beenhere"); + comperr("cannot color graph - COLORMAP() bug?"); goto recalc; } } - /* fill in regs to save */ - ipp->ipp_regs = 0; + /* fill in regs to save */ + memset(p2e->ipp->ipp_regs, 0, sizeof(p2e->ipp->ipp_regs)); for (i = 0; i < NPERMREG-1; i++) { NODE *p; if (nsavregs[i]) { - ipp->ipp_regs |= (1 << permregs[i]); + BITSET(p2e->ipp->ipp_regs, permregs[i]); continue; /* Spilled */ } if (nblock[i+tempmin].r_color == permregs[i]) @@ -2251,7 +2672,7 @@ /* * If the original color of this permreg is used for * coloring another register, swap them to avoid - * unneccessary moves. + * unnecessary moves. */ for (j = i+1; j < NPERMREG-1; j++) { if (nblock[j+tempmin].r_color != permregs[i]) @@ -2263,23 +2684,27 @@ continue; /* Generate reg-reg move nodes for save */ + type = PERMTYPE(permregs[i]); +#ifdef PCC_DEBUG + if (PERMTYPE(nblock[i+tempmin].r_color) != type) + comperr("permreg botch"); +#endif p = mkbinode(ASSIGN, - mklnode(REG, 0, nblock[i+tempmin].r_color, INT), - mklnode(REG, 0, permregs[i], INT), INT); + mklnode(REG, 0, nblock[i+tempmin].r_color, type), + mklnode(REG, 0, permregs[i], type), type); p->n_reg = p->n_left->n_reg = p->n_right->n_reg = -1; p->n_left->n_su = p->n_right->n_su = 0; geninsn(p, FOREFF); ip = ipnode(p); DLIST_INSERT_AFTER(ipole->qelem.q_forw, ip, qelem); - /* XXX not int */ - p = mkbinode(ASSIGN, mklnode(REG, 0, permregs[i], INT), - mklnode(REG, 0, nblock[i+tempmin].r_color, INT), INT); + p = mkbinode(ASSIGN, mklnode(REG, 0, permregs[i], type), + mklnode(REG, 0, nblock[i+tempmin].r_color, type), type); p->n_reg = p->n_left->n_reg = p->n_right->n_reg = -1; p->n_left->n_su = p->n_right->n_su = 0; geninsn(p, FOREFF); ip = ipnode(p); DLIST_INSERT_BEFORE(ipole->qelem.q_back, ip, qelem); } - epp->ipp_regs = ipp->ipp_regs; - /* Done! */ + memcpy(p2e->epp->ipp_regs, p2e->ipp->ipp_regs, sizeof(p2e->epp->ipp_regs)); + /* Done! */ } Index: common.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/common.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/common.c -L usr.bin/pcc/mip/common.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/common.c +++ usr.bin/pcc/mip/common.c @@ -1,4 +1,4 @@ -/* $Id: common.c,v 1.73 2007/09/22 17:15:00 ragge Exp $ */ +/* $Id: common.c,v 1.87 2008/12/03 07:10:04 ragge Exp $ */ /* * Copyright (c) 2003 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -11,8 +11,6 @@ * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. - * 3. The name of the author may not be used to endorse or promote products - * derived from this software without specific prior written permission * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES @@ -75,10 +73,19 @@ char *ftitle; int lineno; +int warniserr = 0; + #ifndef WHERE #define WHERE(ch) fprintf(stderr, "%s, line %d: ", ftitle, lineno); #endif +static void +incerr(void) +{ + if (++nerrors > 30) + cerror("too many errors"); +} + /* * nonfatal error message * the routine where is different for pass 1 and pass 2; @@ -90,13 +97,11 @@ va_list ap; va_start(ap, s); - ++nerrors; WHERE('u'); vfprintf(stderr, s, ap); fprintf(stderr, "\n"); - if (nerrors > 30) - cerror("too many errors"); va_end(ap); + incerr(); } /* @@ -137,22 +142,22 @@ vfprintf(stderr, s, ap); fprintf(stderr, "\n"); va_end(ap); + if (warniserr) + incerr(); } #ifndef MKEXT static NODE *freelink; static int usednodes; +#ifndef LANG_F77 NODE * talloc() { - extern int inlnodecnt, recovernodes; register NODE *p; usednodes++; - if (recovernodes) - inlnodecnt++; if (freelink != NULL) { p = freelink; freelink = p->next; @@ -169,6 +174,7 @@ printf("alloc node %p from memory\n", p); return p; } +#endif /* * make a fresh copy of p @@ -191,7 +197,7 @@ return(q); } - +#ifndef LANG_F77 /* * ensure that all nodes have been freed */ @@ -206,6 +212,7 @@ if ((usednodes - inlnodecnt) != 0) cerror("usednodes == %d, inlnodecnt %d", usednodes, inlnodecnt); } +#endif /* * free the tree p @@ -214,7 +221,7 @@ tfree(NODE *p) { if (p->n_op != FREE) - walkf(p, (void (*)(NODE *))nfree); + walkf(p, (void (*)(NODE *, void *))nfree, 0); } /* @@ -224,7 +231,6 @@ NODE * nfree(NODE *p) { - extern int inlnodecnt, recovernodes; NODE *l; #ifdef PCC_DEBUG_NODES NODE *q; @@ -251,12 +257,16 @@ p->next = freelink; freelink = p; usednodes--; - if (recovernodes) - inlnodecnt--; return l; } #endif +#ifdef LANG_F77 +#define OPTYPE(x) optype(x) +#else +#define OPTYPE(x) coptype(x) +#endif + #ifdef MKEXT #define coptype(o) (dope[o]&TYFLG) #else @@ -275,7 +285,7 @@ (*f)(t, down, &down1, &down2); - switch (coptype( t->n_op )) { + switch (OPTYPE( t->n_op )) { case BITYPE: fwalk( t->n_left, f, down1 ); @@ -292,17 +302,18 @@ } void -walkf(NODE *t, void (*f)(NODE *)) +walkf(NODE *t, void (*f)(NODE *, void *), void *arg) { int opty; - opty = coptype(t->n_op); + + opty = OPTYPE(t->n_op); if (opty != LTYPE) - walkf( t->n_left, f ); + walkf( t->n_left, f, arg ); if (opty == BITYPE) - walkf( t->n_right, f ); - (*f)(t); + walkf( t->n_right, f, arg ); + (*f)(t, arg); } int dope[DSIZE]; @@ -317,7 +328,6 @@ { REG, "REG", LTYPE, }, { OREG, "OREG", LTYPE, }, { TEMP, "TEMP", LTYPE, }, - { MOVE, "MOVE", UTYPE, }, { ICON, "ICON", LTYPE, }, { FCON, "FCON", LTYPE, }, { CCODES, "CCODES", LTYPE, }, @@ -328,7 +338,8 @@ { UFORTCALL, "UFCALL", UTYPE|CALLFLG, }, { COMPL, "~", UTYPE, }, { FORCE, "FORCE", UTYPE, }, -/* { INIT, "INIT", UTYPE, }, */ + { XARG, "XARG", UTYPE, }, + { XASM, "XASM", BITYPE, }, { SCONV, "SCONV", UTYPE, }, { PCONV, "PCONV", UTYPE, }, { PLUS, "+", BITYPE|FLOFLG|SIMPFLG|COMMFLG, }, @@ -411,6 +422,9 @@ "void", "signed", /* pass1 */ "bool", /* pass1 */ + "fcomplex", /* pass1 */ + "dcomplex", /* pass1 */ + "lcomplex", /* pass1 */ "?", "?" }; @@ -434,16 +448,6 @@ } } -int crslab = 10; -/* - * Return a number for internal labels. - */ -int -getlab() -{ - return crslab++; -} - /* * Memory allocation routines. * Memory are allocated from the system in MEMCHUNKSZ blocks. @@ -453,7 +457,7 @@ */ #define MEMCHUNKSZ 8192 /* 8k per allocation */ -struct b { +struct balloc { char a1; union { long long l; @@ -461,13 +465,11 @@ } a2; }; -#define ALIGNMENT ((long)&((struct b *)0)->a2) +#define ALIGNMENT ((long)&((struct balloc *)0)->a2) #define ROUNDUP(x) (((x) + ((ALIGNMENT)-1)) & ~((ALIGNMENT)-1)) static char *allocpole; static int allocleft; -static char *tmppole; -static int tmpleft; int permallocsize, tmpallocsize, lostmem; void * @@ -475,29 +477,27 @@ { void *rv; -//printf("permalloc: allocpole %p allocleft %d size %d ", allocpole, allocleft, size); - if (size > MEMCHUNKSZ) - cerror("permalloc"); + if (size > MEMCHUNKSZ) { + if ((rv = malloc(size)) == NULL) + cerror("permalloc: missing %d bytes", size); + return rv; + } if (size <= 0) cerror("permalloc2"); if (allocleft < size) { /* looses unused bytes */ lostmem += allocleft; -//fprintf(stderr, "allocating perm\n"); if ((allocpole = malloc(MEMCHUNKSZ)) == NULL) cerror("permalloc: out of memory"); allocleft = MEMCHUNKSZ; } size = ROUNDUP(size); rv = &allocpole[MEMCHUNKSZ-allocleft]; -//printf("rv %p\n", rv); allocleft -= size; permallocsize += size; return rv; } -static char *tmplink; - void * tmpcalloc(int size) { @@ -508,66 +508,96 @@ return rv; } -#define TMPOLE &tmppole[MEMCHUNKSZ-tmpleft] +/* + * Duplicate a string onto the temporary heap. + */ +char * +tmpstrdup(char *str) +{ + int len; + + len = strlen(str) + 1; + return memcpy(tmpalloc(len), str, len); +} + +/* + * Allocation routines for temporary memory. + */ +#if 0 +#define ALLDEBUG(x) printf x +#else +#define ALLDEBUG(x) +#endif + +#define NELEM ((MEMCHUNKSZ-ROUNDUP(sizeof(struct xalloc *)))/ALIGNMENT) +#define ELEMSZ (ALIGNMENT) +#define MAXSZ (NELEM*ELEMSZ) +struct xalloc { + struct xalloc *next; + union { + struct balloc b; /* for initial alignment */ + char elm[MAXSZ]; + } u; +} *tapole, *tmpole; +int uselem = NELEM; /* next unused element */ + void * tmpalloc(int size) { + struct xalloc *xp; void *rv; + size_t nelem; - if (size > MEMCHUNKSZ/2) { - size += ROUNDUP(sizeof(char *)); - if ((rv = malloc(size)) == NULL) - cerror("tmpalloc: out of memory"); - /* link in before current chunk XXX */ - *(char **)rv = *(char **)tmppole; - *(char **)tmppole = rv; - tmpallocsize += size; - return (char *)rv + ROUNDUP(sizeof(char *)); - } - if (size <= 0) - cerror("tmpalloc2"); -//printf("tmpalloc: tmppole %p tmpleft %d size %d ", tmppole, tmpleft, size); - size = ROUNDUP(size); - if (tmpleft < size) { - if ((tmppole = malloc(MEMCHUNKSZ)) == NULL) - cerror("tmpalloc: out of memory"); -//fprintf(stderr, "allocating tmp\n"); - tmpleft = MEMCHUNKSZ - ROUNDUP(sizeof(char *)); - *(char **)tmppole = tmplink; - tmplink = tmppole; - } - rv = TMPOLE; -//printf("rv %p\n", rv); - tmpleft -= size; - tmpallocsize += size; + nelem = ROUNDUP(size)/ELEMSZ; + ALLDEBUG(("tmpalloc(%ld,%ld) %d (%zd) ", ELEMSZ, NELEM, size, nelem)); + if (nelem > NELEM/2) { + xp = malloc(size + ROUNDUP(sizeof(struct xalloc *))); + if (xp == NULL) + cerror("out of memory"); + ALLDEBUG(("XMEM! (%ld,%p) ", + size + ROUNDUP(sizeof(struct xalloc *)), xp)); + xp->next = tmpole; + tmpole = xp; + ALLDEBUG(("rv %p\n", &xp->u.elm[0])); + return &xp->u.elm[0]; + } + if (nelem + uselem >= NELEM) { + ALLDEBUG(("MOREMEM! ")); + /* alloc more */ + if ((xp = malloc(sizeof(struct xalloc))) == NULL) + cerror("out of memory"); + xp->next = tapole; + tapole = xp; + uselem = 0; + } else + xp = tapole; + rv = &xp->u.elm[uselem * ELEMSZ]; + ALLDEBUG(("elemno %d ", uselem)); + uselem += nelem; + ALLDEBUG(("new %d rv %p\n", uselem, rv)); return rv; } -#if 0 -/* - * Print and pack strings on heap. - */ -char *tmpsprintf(char *fmt, ...); -char * -tmpsprintf(char *fmt, ...) +void +tmpfree() { - va_list ap; - int len; - char *tmp; + struct xalloc *x1; - tmp = TMPOLE; - va_start(ap, fmt); - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) { - (void)tmpalloc(tmpleft); /* ugly */ - tmp = TMPOLE; - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) - cerror("bad tmpsprintf len"); + while (tmpole) { + x1 = tmpole; + tmpole = tmpole->next; + ALLDEBUG(("XMEM! free %p\n", x1)); + free(x1); + } + while (tapole && tapole->next) { + x1 = tapole; + tapole = tapole->next; + ALLDEBUG(("MOREMEM! free %p\n", x1)); + free(x1); } - va_end(ap); - tmpleft += len; - return tmp; + if (tapole) + uselem = 0; } -#endif /* * Print and pack vararg string on heap. @@ -576,43 +606,58 @@ char * tmpvsprintf(char *fmt, va_list ap) { - int len; + int len, asz; char *tmp; - if (tmpleft == 0) + if (uselem == NELEM) (void)tmpalloc(1); /* XXX ugly */ - tmp = TMPOLE; - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) { - (void)tmpalloc(tmpleft+1); /* ugly */ - tmp = TMPOLE; - if ((len = vsnprintf(tmp, tmpleft, fmt, ap)) >= tmpleft) + tmp = &tapole->u.elm[uselem * ELEMSZ]; + asz = (NELEM-uselem) * ELEMSZ; +//printf("tmpvsprintf: uselem %d asz %d ", uselem, asz); + if ((len = vsnprintf(tmp, asz, fmt, ap)) >= asz) { + (void)tmpalloc(asz+1); /* ugly */ + tmp = &tapole->u.elm[uselem * ELEMSZ]; + asz = (NELEM-uselem) * ELEMSZ; +//printf("len %d uselem %d \n", len, uselem); + if ((len = vsnprintf(tmp, asz, fmt, ap)) >= asz) cerror("bad tmpsprintf len"); } - tmpleft -= len+1; +//else printf("\n"); + uselem += (ROUNDUP(len+1)/ELEMSZ); +//printf("len %d asz %d strlen(tmp) %ld\n", len, asz, strlen(tmp)); return tmp; } +/* + * Set a mark for later removal from the temp heap. + */ void -tmpfree() +markset(struct mark *m) { - char *f, *of; + m->tmsav = tmpole; + m->tasav = tapole; + m->elem = uselem; +} - f = tmplink; - if (f == NULL) - return; - if (*(char **)f == NULL) { - tmpleft = MEMCHUNKSZ - ROUNDUP(sizeof(char *)); - return; +/* + * Remove everything on tmp heap from a mark. + */ +void +markfree(struct mark *m) +{ + struct xalloc *x1; + + while (tmpole != m->tmsav) { + x1 = tmpole; + tmpole = tmpole->next; + free(x1); } - while (f != NULL) { - of = f; - f = *(char **)f; - free(of); - } - tmplink = tmppole = NULL; - tmpleft = 0; -//fprintf(stderr, "freeing tmp\n"); - /* XXX - nothing right now */ + while (tapole != m->tasav) { + x1 = tapole; + tapole = tapole->next; + free(x1); + } + uselem = m->elem; } /* @@ -636,3 +681,48 @@ *c++ = *s++; return u; } + +/* + * Do a preorder walk of the CM list p and apply function f on each element. + */ +void +flist(NODE *p, void (*f)(NODE *, void *), void *arg) +{ + if (p->n_op == CM) { + (*f)(p->n_right, arg); + flist(p->n_left, f, arg); + } else + (*f)(p, arg); +} + +/* + * The same as flist but postorder. + */ +void +listf(NODE *p, void (*f)(NODE *)) +{ + if (p->n_op == CM) { + listf(p->n_left, f); + (*f)(p->n_right); + } else + (*f)(p); +} + +/* + * Get list argument number n from list, or NIL if out of list. + */ +NODE * +listarg(NODE *p, int n, int *cnt) +{ + NODE *r; + + if (p->n_op == CM) { + r = listarg(p->n_left, n, cnt); + if (n == ++(*cnt)) + r = p->n_right; + } else { + *cnt = 0; + r = n == 0 ? p : NIL; + } + return r; +} Index: compat.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/compat.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/compat.c -L usr.bin/pcc/mip/compat.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/compat.c +++ usr.bin/pcc/mip/compat.c @@ -24,12 +24,83 @@ * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. * - * $Id: compat.c,v 1.1 2007/09/20 12:52:15 ragge Exp $ + * $Id: compat.c,v 1.8 2008/11/01 08:29:38 mickey Exp $ + */ + +/*- + * Copyright (c) 1997, 2002 The NetBSD Foundation, Inc. + * All rights reserved. + * + * This code is derived from software contributed to The NetBSD Foundation + * by Klaus Klein and Jason R. Thorpe. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. All advertising materials mentioning features or use of this software + * must display the following acknowledgement: + * This product includes software developed by the NetBSD + * Foundation, Inc. and its contributors. + * 4. Neither the name of The NetBSD Foundation nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS + * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED + * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR + * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS + * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF + * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS + * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN + * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) + * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + * $NetBSD: basename.c,v 1.5 2002/10/17 02:06:04 thorpej Exp $ + */ + +/* + * Copyright (c) 1987, 1993 + * The Regents of the University of California. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * 1. Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * 2. Redistributions in binary form must reproduce the above copyright + * notice, this list of conditions and the following disclaimer in the + * documentation and/or other materials provided with the distribution. + * 3. Neither the name of the University nor the names of its contributors + * may be used to endorse or promote products derived from this software + * without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + * $NetBSD: gettemp.c,v 1.13 2003/12/05 00:57:36 uebayasi Exp $ */ #include +#include -#include "../config.h" +#include "config.h" +#define MKEXT /* XXX */ #include "manifest.h" #ifndef HAVE_STRLCAT @@ -102,3 +173,754 @@ return(s - src - 1); /* count does not include NUL */ } #endif + +#ifndef HAVE_GETOPT +char *optarg; +int optind = 1; +int +getopt(int argc, char **argv, char *args) +{ + int n; + int nlen = strlen(args); + char cmd; + char rv; + + if (argv[optind] && *argv[optind] == '-') { + cmd = *(argv[optind] + 1); + + for (n = 0; n < nlen; n++) { + if (args[n] == ':') + continue; + if (args[n] == cmd) { + rv = *(argv[optind] + 1); + if (args[n+1] == ':') { + if (*(argv[optind] + 2) != '\0') { + optarg = argv[optind] + 2; + optind += 1; + } else { + optarg = argv[optind + 1]; + optind += 2; + } + if (!optarg) + optarg=""; + return rv; + } else { + optarg = NULL; + optind += 1; + return rv; + } + } + } + } + + return -1; +} +#endif + +#ifdef WIN32 +#define ISPATHSEPARATOR(x) ((x == '/') || (x == '\\')) +#else +#define ISPATHSEPARATOR(x) (x == '/') +#endif + +#ifndef HAVE_BASENAME +#ifndef PATH_MAX +#define PATH_MAX 5000 +#endif + +char * +basename(char *path) +{ + static char singledot[] = "."; + static char result[PATH_MAX]; + char *p, *lastp; + size_t len; + + /* + * If `path' is a null pointer or points to an empty string, + * return a pointer to the string ".". + */ + if ((path == NULL) || (*path == '\0')) + return (singledot); + + /* Strip trailing slashes, if any. */ + lastp = path + strlen(path) - 1; + while (lastp != path && ISPATHSEPARATOR(*lastp)) + lastp--; + + /* Now find the beginning of this (final) component. */ + p = lastp; + while (p != path && !ISPATHSEPARATOR(*(p - 1))) + p--; + + /* ...and copy the result into the result buffer. */ + len = (lastp - p) + 1 /* last char */; + if (len > (PATH_MAX - 1)) + len = PATH_MAX - 1; + + memcpy(result, p, len); + result[len] = '\0'; + + return (result); +} +#endif + +#if !defined(HAVE_MKSTEMP) && !defined(WIN32) +int +mkstemp(char *path) +{ + char *start, *trv; + unsigned int pid; + + /* To guarantee multiple calls generate unique names even if + the file is not created. 676 different possibilities with 7 + or more X's, 26 with 6 or less. */ + static char xtra[2] = "aa"; + int xcnt = 0; + + pid = getpid(); + + /* Move to end of path and count trailing X's. */ + for (trv = path; *trv; ++trv) + if (*trv == 'X') + xcnt++; + else + xcnt = 0; + + /* Use at least one from xtra. Use 2 if more than 6 X's. */ + if (*(trv - 1) == 'X') + *--trv = xtra[0]; + if (xcnt > 6 && *(trv - 1) == 'X') + *--trv = xtra[1]; + + /* Set remaining X's to pid digits with 0's to the left. */ + while (*--trv == 'X') { + *trv = (pid % 10) + '0'; + pid /= 10; + } + + /* update xtra for next call. */ + if (xtra[0] != 'z') + xtra[0]++; + else { + xtra[0] = 'a'; + if (xtra[1] != 'z') + xtra[1]++; + else + xtra[1] = 'a'; + } + + return open(path, O_CREAT | O_EXCL | O_RDWR, 0600); +} +#endif + +#ifndef HAVE_FFS +int +ffs(int x) +{ + int r = 1; + if (!x) return 0; + if (!(x & 0xffff)) { x >>= 16; r += 16; } + if (!(x & 0xff)) { x >>= 8; r += 8; } + if (!(x & 0xf)) { x >>= 4; r += 4; } + if (!(x & 3)) { x >>= 2; r += 2; } + if (!(x & 1)) { x >>= 1; r += 1; } + + return r; +} +#endif + +/* + * Copyright Patrick Powell 1995 + * This code is based on code written by Patrick Powell (papowell at astart.com) + * It may be used for any purpose as long as this notice remains intact + * on all source code distributions + */ + +#if !defined(HAVE_SNPRINTF) || !defined(HAVE_VSNPRINTF) + +static void +dopr(char *buffer, size_t maxlen, const char *format, va_list args); + +static void +fmtstr(char *buffer, size_t *currlen, size_t maxlen, char *value, int flags, + int min, int max); + +static void +fmtint(char *buffer, size_t *currlen, size_t maxlen, long value, int base, + int min, int max, int flags); + +static void +fmtfp(char *buffer, size_t *currlen, size_t maxlen, long double fvalue, + int min, int max, int flags); + +static void +dopr_outch(char *buffer, size_t *currlen, size_t maxlen, char c); + +/* + * dopr(): poor man's version of doprintf + */ + +/* format read states */ +#define DP_S_DEFAULT 0 +#define DP_S_FLAGS 1 +#define DP_S_MIN 2 +#define DP_S_DOT 3 +#define DP_S_MAX 4 +#define DP_S_MOD 5 +#define DP_S_CONV 6 +#define DP_S_DONE 7 + +/* format flags - Bits */ +#define DP_F_MINUS (1 << 0) +#define DP_F_PLUS (1 << 1) +#define DP_F_SPACE (1 << 2) +#define DP_F_NUM (1 << 3) +#define DP_F_ZERO (1 << 4) +#define DP_F_UP (1 << 5) +#define DP_F_UNSIGNED (1 << 6) + +/* Conversion Flags */ +#define DP_C_SHORT 1 +#define DP_C_LONG 2 +#define DP_C_LDOUBLE 3 +#define DP_C_LONG_LONG 4 + +#define char_to_int(p) (p - '0') +#define abs_val(p) (p < 0 ? -p : p) + + +static void +dopr(char *buffer, size_t maxlen, const char *format, va_list args) +{ + char *strvalue, ch; + long value; + long double fvalue; + int min = 0, max = -1, state = DP_S_DEFAULT, flags = 0, cflags = 0; + size_t currlen = 0; + + ch = *format++; + + while (state != DP_S_DONE) { + if ((ch == '\0') || (currlen >= maxlen)) + state = DP_S_DONE; + + switch(state) { + case DP_S_DEFAULT: + if (ch == '%') + state = DP_S_FLAGS; + else + dopr_outch(buffer, &currlen, maxlen, ch); + ch = *format++; + break; + case DP_S_FLAGS: + switch (ch) { + case '-': + flags |= DP_F_MINUS; + ch = *format++; + break; + case '+': + flags |= DP_F_PLUS; + ch = *format++; + break; + case ' ': + flags |= DP_F_SPACE; + ch = *format++; + break; + case '#': + flags |= DP_F_NUM; + ch = *format++; + break; + case '0': + flags |= DP_F_ZERO; + ch = *format++; + break; + default: + state = DP_S_MIN; + break; + } + break; + case DP_S_MIN: + if (isdigit((unsigned char)ch)) { + min = 10 * min + char_to_int (ch); + ch = *format++; + } else if (ch == '*') { + min = va_arg (args, int); + ch = *format++; + state = DP_S_DOT; + } else + state = DP_S_DOT; + break; + case DP_S_DOT: + if (ch == '.') { + state = DP_S_MAX; + ch = *format++; + } else + state = DP_S_MOD; + break; + case DP_S_MAX: + if (isdigit((unsigned char)ch)) { + if (max < 0) + max = 0; + max = 10 * max + char_to_int(ch); + ch = *format++; + } else if (ch == '*') { + max = va_arg (args, int); + ch = *format++; + state = DP_S_MOD; + } else + state = DP_S_MOD; + break; + case DP_S_MOD: + switch (ch) { + case 'h': + cflags = DP_C_SHORT; + ch = *format++; + break; + case 'l': + cflags = DP_C_LONG; + ch = *format++; + if (ch == 'l') { + cflags = DP_C_LONG_LONG; + ch = *format++; + } + break; + case 'q': + cflags = DP_C_LONG_LONG; + ch = *format++; + break; + case 'L': + cflags = DP_C_LDOUBLE; + ch = *format++; + break; + default: + break; + } + state = DP_S_CONV; + break; + case DP_S_CONV: + switch (ch) { + case 'd': + case 'i': + if (cflags == DP_C_SHORT) + value = va_arg(args, int); + else if (cflags == DP_C_LONG) + value = va_arg(args, long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg (args, long long); + else + value = va_arg (args, int); + fmtint(buffer, &currlen, maxlen, value, 10, min, max, flags); + break; + case 'o': + flags |= DP_F_UNSIGNED; + if (cflags == DP_C_SHORT) + value = va_arg(args, unsigned int); + else if (cflags == DP_C_LONG) + value = va_arg(args, unsigned long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg(args, unsigned long long); + else + value = va_arg(args, unsigned int); + fmtint(buffer, &currlen, maxlen, value, 8, min, max, flags); + break; + case 'u': + flags |= DP_F_UNSIGNED; + if (cflags == DP_C_SHORT) + value = va_arg(args, unsigned int); + else if (cflags == DP_C_LONG) + value = va_arg(args, unsigned long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg(args, unsigned long long); + else + value = va_arg(args, unsigned int); + fmtint (buffer, &currlen, maxlen, value, 10, min, max, flags); + break; + case 'X': + flags |= DP_F_UP; + case 'x': + flags |= DP_F_UNSIGNED; + if (cflags == DP_C_SHORT) + value = va_arg(args, unsigned int); + else if (cflags == DP_C_LONG) + value = va_arg(args, unsigned long int); + else if (cflags == DP_C_LONG_LONG) + value = va_arg(args, unsigned long long); + else + value = va_arg(args, unsigned int); + fmtint(buffer, &currlen, maxlen, value, 16, min, max, flags); + break; + case 'f': + if (cflags == DP_C_LDOUBLE) + fvalue = va_arg(args, long double); + else + fvalue = va_arg(args, double); + /* um, floating point? */ + fmtfp(buffer, &currlen, maxlen, fvalue, min, max, flags); + break; + case 'E': + flags |= DP_F_UP; + case 'e': + if (cflags == DP_C_LDOUBLE) + fvalue = va_arg(args, long double); + else + fvalue = va_arg(args, double); + break; + case 'G': + flags |= DP_F_UP; + case 'g': + if (cflags == DP_C_LDOUBLE) + fvalue = va_arg(args, long double); + else + fvalue = va_arg(args, double); + break; + case 'c': + dopr_outch(buffer, &currlen, maxlen, va_arg(args, int)); + break; + case 's': + strvalue = va_arg(args, char *); + if (max < 0) + max = maxlen; /* ie, no max */ + fmtstr(buffer, &currlen, maxlen, strvalue, flags, min, max); + break; + case 'p': + strvalue = va_arg(args, void *); + fmtint(buffer, &currlen, maxlen, (long) strvalue, 16, min, max, flags); + break; + case 'n': + if (cflags == DP_C_SHORT) { + short int *num; + num = va_arg(args, short int *); + *num = currlen; + } else if (cflags == DP_C_LONG) { + long int *num; + num = va_arg(args, long int *); + *num = currlen; + } else if (cflags == DP_C_LONG_LONG) { + long long *num; + num = va_arg(args, long long *); + *num = currlen; + } else { + int *num; + num = va_arg(args, int *); + *num = currlen; + } + break; + case '%': + dopr_outch(buffer, &currlen, maxlen, ch); + break; + case 'w': /* not supported yet, treat as next char */ + ch = *format++; + break; + default: /* Unknown, skip */ + break; + } + ch = *format++; + state = DP_S_DEFAULT; + flags = cflags = min = 0; + max = -1; + break; + case DP_S_DONE: + break; + default: /* hmm? */ + break; /* some picky compilers need this */ + } + } + if (currlen < maxlen - 1) + buffer[currlen] = '\0'; + else + buffer[maxlen - 1] = '\0'; +} + +static void +fmtstr(char *buffer, size_t *currlen, size_t maxlen, + char *value, int flags, int min, int max) +{ + int cnt = 0, padlen, strln; /* amount to pad */ + + if (value == 0) + value = ""; + + for (strln = 0; value[strln]; ++strln); /* strlen */ + padlen = min - strln; + if (padlen < 0) + padlen = 0; + if (flags & DP_F_MINUS) + padlen = -padlen; /* Left Justify */ + + while ((padlen > 0) && (cnt < max)) { + dopr_outch(buffer, currlen, maxlen, ' '); + --padlen; + ++cnt; + } + while (*value && (cnt < max)) { + dopr_outch(buffer, currlen, maxlen, *value++); + ++cnt; + } + while ((padlen < 0) && (cnt < max)) { + dopr_outch(buffer, currlen, maxlen, ' '); + ++padlen; + ++cnt; + } +} + +/* Have to handle DP_F_NUM (ie 0x and 0 alternates) */ + +static void +fmtint(char *buffer, size_t *currlen, size_t maxlen, + long value, int base, int min, int max, int flags) +{ + unsigned long uvalue; + char convert[20]; + int signvalue = 0, place = 0, caps = 0; + int spadlen = 0; /* amount to space pad */ + int zpadlen = 0; /* amount to zero pad */ + +#define PADMAX(x,y) ((x) > (y) ? (x) : (y)) + + if (max < 0) + max = 0; + + uvalue = value; + + if (!(flags & DP_F_UNSIGNED)) { + if (value < 0) { + signvalue = '-'; + uvalue = -value; + } else if (flags & DP_F_PLUS) /* Do a sign (+/i) */ + signvalue = '+'; + else if (flags & DP_F_SPACE) + signvalue = ' '; + } + + if (flags & DP_F_UP) + caps = 1; /* Should characters be upper case? */ + do { + convert[place++] = + (caps ? "0123456789ABCDEF" : "0123456789abcdef") + [uvalue % (unsigned)base]; + uvalue = (uvalue / (unsigned)base ); + } while (uvalue && (place < 20)); + if (place == 20) + place--; + convert[place] = 0; + + zpadlen = max - place; + spadlen = min - PADMAX(max, place) - (signvalue ? 1 : 0); + if (zpadlen < 0) + zpadlen = 0; + if (spadlen < 0) + spadlen = 0; + if (flags & DP_F_ZERO) { + zpadlen = PADMAX(zpadlen, spadlen); + spadlen = 0; + } + if (flags & DP_F_MINUS) + spadlen = -spadlen; /* Left Justifty */ + + /* Spaces */ + while (spadlen > 0) { + dopr_outch(buffer, currlen, maxlen, ' '); + --spadlen; + } + + /* Sign */ + if (signvalue) + dopr_outch(buffer, currlen, maxlen, signvalue); + + /* Zeros */ + if (zpadlen > 0) { + while (zpadlen > 0) { + dopr_outch(buffer, currlen, maxlen, '0'); + --zpadlen; + } + } + + /* Digits */ + while (place > 0) + dopr_outch(buffer, currlen, maxlen, convert[--place]); + + /* Left Justified spaces */ + while (spadlen < 0) { + dopr_outch (buffer, currlen, maxlen, ' '); + ++spadlen; + } +} + +static long double +pow10(int exp) +{ + long double result = 1; + + while (exp) { + result *= 10; + exp--; + } + + return result; +} + +static long +round(long double value) +{ + long intpart = value; + + value -= intpart; + if (value >= 0.5) + intpart++; + + return intpart; +} + +static void +fmtfp(char *buffer, size_t *currlen, size_t maxlen, long double fvalue, + int min, int max, int flags) +{ + char iconvert[20], fconvert[20]; + int signvalue = 0, iplace = 0, fplace = 0; + int padlen = 0; /* amount to pad */ + int zpadlen = 0, caps = 0; + long intpart, fracpart; + long double ufvalue; + + /* + * AIX manpage says the default is 0, but Solaris says the default + * is 6, and sprintf on AIX defaults to 6 + */ + if (max < 0) + max = 6; + + ufvalue = abs_val(fvalue); + + if (fvalue < 0) + signvalue = '-'; + else if (flags & DP_F_PLUS) /* Do a sign (+/i) */ + signvalue = '+'; + else if (flags & DP_F_SPACE) + signvalue = ' '; + + intpart = ufvalue; + + /* + * Sorry, we only support 9 digits past the decimal because of our + * conversion method + */ + if (max > 9) + max = 9; + + /* We "cheat" by converting the fractional part to integer by + * multiplying by a factor of 10 + */ + fracpart = round((pow10 (max)) * (ufvalue - intpart)); + + if (fracpart >= pow10 (max)) { + intpart++; + fracpart -= pow10 (max); + } + + /* Convert integer part */ + do { + iconvert[iplace++] = + (caps ? "0123456789ABCDEF" : "0123456789abcdef") + [intpart % 10]; + intpart = (intpart / 10); + } while(intpart && (iplace < 20)); + if (iplace == 20) + iplace--; + iconvert[iplace] = 0; + + /* Convert fractional part */ + do { + fconvert[fplace++] = + (caps ? "0123456789ABCDEF" : "0123456789abcdef") + [fracpart % 10]; + fracpart = (fracpart / 10); + } while(fracpart && (fplace < 20)); + if (fplace == 20) + fplace--; + fconvert[fplace] = 0; + + /* -1 for decimal point, another -1 if we are printing a sign */ + padlen = min - iplace - max - 1 - ((signvalue) ? 1 : 0); + zpadlen = max - fplace; + if (zpadlen < 0) + zpadlen = 0; + if (padlen < 0) + padlen = 0; + if (flags & DP_F_MINUS) + padlen = -padlen; /* Left Justifty */ + + if ((flags & DP_F_ZERO) && (padlen > 0)) { + if (signvalue) { + dopr_outch(buffer, currlen, maxlen, signvalue); + --padlen; + signvalue = 0; + } + while (padlen > 0) { + dopr_outch(buffer, currlen, maxlen, '0'); + --padlen; + } + } + while (padlen > 0) { + dopr_outch(buffer, currlen, maxlen, ' '); + --padlen; + } + if (signvalue) + dopr_outch(buffer, currlen, maxlen, signvalue); + + while (iplace > 0) + dopr_outch(buffer, currlen, maxlen, iconvert[--iplace]); + + /* + * Decimal point. This should probably use locale to find the + * correct char to print out. + */ + dopr_outch(buffer, currlen, maxlen, '.'); + + while (fplace > 0) + dopr_outch(buffer, currlen, maxlen, fconvert[--fplace]); + + while (zpadlen > 0) { + dopr_outch(buffer, currlen, maxlen, '0'); + --zpadlen; + } + + while (padlen < 0) { + dopr_outch(buffer, currlen, maxlen, ' '); + ++padlen; + } +} + +static void +dopr_outch(char *buffer, size_t *currlen, size_t maxlen, char c) +{ + if (*currlen < maxlen) + buffer[(*currlen)++] = c; +} +#endif /* !defined(HAVE_SNPRINTF) || !defined(HAVE_VSNPRINTF) */ + +#ifndef HAVE_VSNPRINTF +int +vsnprintf(char *str, size_t count, const char *fmt, va_list args) +{ + str[0] = 0; + dopr(str, count, fmt, args); + + return(strlen(str)); +} +#endif /* !HAVE_VSNPRINTF */ + +#ifndef HAVE_SNPRINTF +int +snprintf(char *str,size_t count,const char *fmt,...) +{ + va_list ap; + + va_start(ap, fmt); + (void) vsnprintf(str, count, fmt, ap); + va_end(ap); + + return(strlen(str)); +} + +#endif /* !HAVE_SNPRINTF */ Index: manifest.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/manifest.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/manifest.h -L usr.bin/pcc/mip/manifest.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/manifest.h +++ usr.bin/pcc/mip/manifest.h @@ -1,4 +1,4 @@ -/* $Id: manifest.h,v 1.59 2007/09/20 12:02:54 ragge Exp $ */ +/* $Id: manifest.h,v 1.87 2008/12/04 07:28:55 ragge Exp $ */ /* * Copyright(C) Caldera International Inc. 2001-2002. All rights reserved. * @@ -37,9 +37,11 @@ #define MANIFEST #include -#include "../config.h" +#include +#include "config.h" #include "macdefs.h" #include "node.h" +#include "compat.h" /* * Node types @@ -75,8 +77,8 @@ #define LDOUBLE 14 #define STRTY 15 #define UNIONTY 16 -#define ENUMTY 17 -#define MOETY 18 /* member of enum */ +/* #define ENUMTY 17 */ +/* #define MOETY 18 */ /* member of enum */ #define VOID 19 #define MAXTYPES 19 /* highest type+1 to be used by lang code */ @@ -114,6 +116,7 @@ #define UNSIGNABLE(x) (((x)<=ULONGLONG&&(x)>=CHAR) && !ISUNSIGNED(x)) #define ENUNSIGN(x) ((x)|1) #define DEUNSIGN(x) ((x)&~1) +#define ISINTEGER(x) (((x) >= CHAR && (x) <= ULONGLONG) || (x) == BOOL) #define ISPTR(x) (((x)&TMASK)==PTR) #define ISFTN(x) (((x)&TMASK)==FTN) /* is x a function type? */ #define ISARY(x) (((x)&TMASK)==ARY) /* is x an array type? */ @@ -165,18 +168,24 @@ #define DATA 1 /* (rw) data segment */ #define RDATA 2 /* (ro) data segment */ #define STRNG 3 /* (ro) string segment */ +#define UDATA 4 /* (rw) uninitialized data */ +#define regno(p) ((p)->n_rval) /* register number */ + /* * */ extern int bdebug, tdebug, edebug; extern int ddebug, xdebug, f2debug; -extern int iTflag, oTflag; -extern int vdebug, sflag, nflag, gflag; +extern int iTflag, oTflag, kflag; +extern int sflag, nflag, gflag, pflag; extern int Wstrict_prototypes, Wmissing_prototypes, Wimplicit_int, - Wimplicit_function_declaration; -extern int xssaflag, xtailcallflag, xtemps, xdeljumps; + Wimplicit_function_declaration, Wpointer_sign, Wshadow, + Wsign_compare, Wunknown_pragmas, Wunreachable_code; +extern int funsigned_char; +extern int sspflag; +extern int xssaflag, xtailcallflag, xtemps, xdeljumps, xdce; int yyparse(void); void yyaccpt(void); @@ -191,6 +200,7 @@ #define DLIST_NEXT(h,f) (h)->f.q_forw #define DLIST_PREV(h,f) (h)->f.q_back #define DLIST_ISEMPTY(h,f) ((h)->f.q_forw == (h)) +#define DLIST_ENDMARK(h) (h) #define DLIST_FOREACH(v,h,f) \ for ((v) = (h)->f.q_forw; (v) != (h); (v) = (v)->f.q_forw) #define DLIST_FOREACH_REVERSE(v,h,f) \ @@ -215,17 +225,26 @@ /* Single-linked list */ #define SLIST_INIT(h) \ { (h)->q_forw = NULL; (h)->q_last = &(h)->q_forw; } +#define SLIST_SETUP(h) { NULL, &(h)->q_forw } #define SLIST_ENTRY(t) struct { struct t *q_forw; } #define SLIST_HEAD(n,t) struct n { struct t *q_forw, **q_last; } +#define SLIST_ISEMPTY(h) ((h)->q_last == &(h)->q_forw) #define SLIST_FIRST(h) ((h)->q_forw) #define SLIST_FOREACH(v,h,f) \ for ((v) = (h)->q_forw; (v) != NULL; (v) = (v)->f.q_forw) +#define SLIST_INSERT_FIRST(h,e,f) { \ + if ((h)->q_last == &(h)->q_forw) \ + (h)->q_last = &(e)->f.q_forw; \ + (e)->f.q_forw = (h)->q_forw; \ + (h)->q_forw = (e); \ +} #define SLIST_INSERT_LAST(h,e,f) { \ (e)->f.q_forw = NULL; \ *(h)->q_last = (e); \ (h)->q_last = &(e)->f.q_forw; \ } +#ifndef MKEXT /* * Functions for inter-pass communication. * @@ -253,11 +272,20 @@ char *ipp_name; /* Function name */ int ipp_vis; /* Function visibility */ TWORD ipp_type; /* Function type */ - int ipp_regs; /* Bitmask of registers to save */ +#define NIPPREGS BIT2BYTE(MAXREGS)/sizeof(bittype) + bittype ipp_regs[NIPPREGS]; + /* Bitmask of registers to save */ int ipp_autos; /* Size on stack needed */ int ip_tmpnum; /* # allocated temp nodes so far */ int ip_lblnum; /* # used labels so far */ +#ifdef TARGET_IPP_MEMBERS + TARGET_IPP_MEMBERS +#endif }; +#else +struct interpass { int dummy; }; +struct interpass_prolog; +#endif /* !MKEXT */ /* * Epilog/prolog takes following arguments (in order): @@ -289,17 +317,13 @@ /* * External declarations, typedefs and the like */ -char *hash(char *s); -char *savestr(char *cp); -char *tstr(char *cp); - -#ifndef HAVE_STRLCPY -size_t strlcpy(char *dst, const char *src, size_t siz); -#endif -#ifndef HAVE_STRLCAT -size_t strlcat(char *dst, const char *src, size_t siz); -#endif +/* used for memory allocation */ +typedef struct mark { + void *tmsav; + void *tasav; + int elem; +} MARK; /* memory management stuff */ void *permalloc(int size); @@ -307,6 +331,12 @@ void *tmpalloc(int size); void tmpfree(void); char *newstring(char *, int len); +char *tmpstrdup(char *str); +void markset(struct mark *m); +void markfree(struct mark *m); + +/* command-line processing */ +void mflags(char *); void tprint(FILE *, TWORD, TWORD); @@ -318,7 +348,18 @@ /* node routines */ NODE *nfree(NODE *); +void tfree(NODE *); +NODE *tcopy(NODE *); +void walkf(NODE *, void (*f)(NODE *, void *), void *); void fwalk(NODE *t, void (*f)(NODE *, int, int *, int *), int down); +void flist(NODE *p, void (*f)(NODE *, void *), void *); +void listf(NODE *p, void (*f)(NODE *)); +NODE *listarg(NODE *p, int n, int *cnt); +void cerror(char *s, ...); +void werror(char *s, ...); +void uerror(char *s, ...); + extern int nerrors; /* number of errors seen so far */ +extern int warniserr; /* treat warnings as errors */ #endif Index: mkext.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/mkext.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/mkext.c -L usr.bin/pcc/mip/mkext.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/mkext.c +++ usr.bin/pcc/mip/mkext.c @@ -3,8 +3,21 @@ * Generate defines for the needed hardops. */ #include "pass2.h" +#include +#ifdef HAVE_STRING_H #include +#endif + +#ifdef HAVE_C99_FORMAT +#define FMTdPTR "%td" +#else +#if defined(_WIN64) || defined(LP64) +#define FMTdPTR "%ld" +#else +#define FMTdPTR "%d" +#endif +#endif int chkop[DSIZE]; @@ -62,12 +75,53 @@ int rstatus[] = { RSTATUS }; int roverlay[MAXREGS][MAXREGS] = { ROVERLAP }; -int regclassmap[NUMCLASS][MAXREGS]; +int regclassmap[CLASSG][MAXREGS]; /* CLASSG is highest class */ static void compl(struct optab *q, char *str) { - printf("table entry %td, op %s: %s\n", q - table, opst[q->op], str); + int op = q->op; + char *s; + + if (op < OPSIMP) { + s = opst[op]; + } else + switch (op) { + default: s = "Special op"; break; + case OPSIMP: s = "OPLSIMP"; break; + case OPCOMM: s = "OPCOMM"; break; + case OPMUL: s = "OPMUL"; break; + case OPDIV: s = "OPDIV"; break; + case OPUNARY: s = "OPUNARY"; break; + case OPLEAF: s = "OPLEAF"; break; + case OPANY: s = "OPANY"; break; + case OPLOG: s = "OPLOG"; break; + case OPFLOAT: s = "OPFLOAT"; break; + case OPSHFT: s = "OPSHFT"; break; + case OPLTYPE: s = "OPLTYPE"; break; + } + + printf("table entry " FMTdPTR ", op %s: %s\n", q - table, s, str); +} + +static int +getrcl(struct optab *q) +{ + int v = q->needs & + (NACOUNT|NBCOUNT|NCCOUNT|NDCOUNT|NECOUNT|NFCOUNT|NGCOUNT); + int r = q->rewrite & RESC1 ? 1 : q->rewrite & RESC2 ? 2 : 3; + int i = 0; + +#define INCK(c) while (v & c##COUNT) { \ + v -= c##REG, i++; if (i == r) return I##c##REG; } + INCK(NA) + INCK(NB) + INCK(NC) + INCK(ND) + INCK(NE) + INCK(NF) + INCK(NG) + return 0; } int @@ -75,10 +129,16 @@ { struct optab *q; struct checks *ch; - int i, j, areg, breg, creg, dreg, mx; + int i, j, areg, breg, creg, dreg, mx, ereg, freg, greg; char *bitary; int bitsz, rval, nelem; + if (argc == 2) { + i = atoi(argv[1]); + printf("Entry %d:\n%s\n", i, table[i].cstring); + return 0; + } + mkdope(); for (q = table; q->op != FREE; q++) { @@ -99,6 +159,8 @@ perror("open hfile"); return(1); } + fprintf(fh, "#ifndef _EXTERNAL_H_\n#define _EXTERNAL_H_\n"); + for (ch = checks; ch->op != 0; ch++) { if ((chkop[ch->op] & ch->type) == 0) fprintf(fh, "#define NEED_%s\n", ch->name); @@ -117,12 +179,17 @@ bitsz = sizeof(int) == 4 ? 32 : 16; } fprintf(fh, "#define NUMBITS %d\n", bitsz); + fprintf(fh, "#define BIT2BYTE(bits) " + "((((bits)+NUMBITS-1)/NUMBITS)*(NUMBITS/8))\n"); fprintf(fh, "#define BITSET(arr, bit) " - "(arr[bit/NUMBITS] |= (1 << (bit & (NUMBITS-1))))\n"); + "(arr[bit/NUMBITS] |= ((%s)1 << (bit & (NUMBITS-1))))\n", + bitary); fprintf(fh, "#define BITCLEAR(arr, bit) " - "(arr[bit/NUMBITS] &= ~(1 << (bit & (NUMBITS-1))))\n"); + "(arr[bit/NUMBITS] &= ~((%s)1 << (bit & (NUMBITS-1))))\n", + bitary); fprintf(fh, "#define TESTBIT(arr, bit) " - "(arr[bit/NUMBITS] & (1 << (bit & (NUMBITS-1))))\n"); + "(arr[bit/NUMBITS] & ((%s)1 << (bit & (NUMBITS-1))))\n", + bitary); fprintf(fh, "typedef %s bittype;\n", bitary); /* register class definitions, used by graph-coloring */ @@ -134,16 +201,25 @@ if (q->op == ASSIGN) { #define F(x) (q->visit & x && q->rewrite & (RLEFT|RRIGHT) && \ q->lshape & ~x && q->rshape & ~x) - if (F(INAREG) || F(INBREG) || F(INCREG) || F(INDREG)) { + if (F(INAREG) || F(INBREG) || F(INCREG) || F(INDREG) || + F(INEREG) || F(INFREG) || F(INGREG)) { compl(q, "may match without result register"); rval++; } #undef F - if ((q->visit & INREGS) && q->rewrite != RDEST) { + if ((q->visit & INREGS) && !(q->rewrite & RDEST)) { compl(q, "ASSIGN reclaim must be RDEST"); rval++; } } + /* check that reclaim is not the wrong class */ + if ((q->rewrite & (RESC1|RESC2|RESC3)) && + !(q->needs & REWRITE)) { + if ((q->visit & getrcl(q)) == 0) { + compl(q, "wrong RESCx class"); + rval++; + } + } if (q->rewrite & (RESC1|RESC2|RESC3) && q->visit & FOREFF) compl(q, "FOREFF may cause reclaim of wrong class"); } @@ -163,23 +239,42 @@ fprintf(fc, "%d, ", i), j++; fprintf(fc, "-1 };\n"); fprintf(fh, "#define NPERMREG %d\n", j+1); + fprintf(fc, "bittype validregs[] = {\n"); + for (j = 0; j < MAXREGS; j += bitsz) { + int cbit = 0; + for (i = 0; i < bitsz; i++) { + if (i+j == MAXREGS) + break; + if (rstatus[i+j] & INREGS) + cbit |= (1 << i); + } + fprintf(fc, "\t0x%08x,\n", cbit); + } + fprintf(fc, "};\n"); + fprintf(fh, "extern bittype validregs[];\n"); /* * The register allocator uses bitmasks of registers for each class. */ - areg = breg = creg = dreg = 0; + areg = breg = creg = dreg = ereg = freg = greg = 0; for (i = 0; i < MAXREGS; i++) { - regclassmap[0][i] = regclassmap[1][i] = regclassmap[2][i] = - regclassmap[3][i] = -1; + for (j = 0; j < NUMCLASS; j++) + regclassmap[j][i] = -1; if (rstatus[i] & SAREG) regclassmap[0][i] = areg++; if (rstatus[i] & SBREG) regclassmap[1][i] = breg++; if (rstatus[i] & SCREG) regclassmap[2][i] = creg++; if (rstatus[i] & SDREG) regclassmap[3][i] = dreg++; + if (rstatus[i] & SEREG) regclassmap[4][i] = ereg++; + if (rstatus[i] & SFREG) regclassmap[5][i] = freg++; + if (rstatus[i] & SGREG) regclassmap[6][i] = greg++; } fprintf(fh, "#define AREGCNT %d\n", areg); fprintf(fh, "#define BREGCNT %d\n", breg); fprintf(fh, "#define CREGCNT %d\n", creg); fprintf(fh, "#define DREGCNT %d\n", dreg); + fprintf(fh, "#define EREGCNT %d\n", ereg); + fprintf(fh, "#define FREGCNT %d\n", freg); + fprintf(fh, "#define GREGCNT %d\n", greg); if (areg > bitsz) printf("%d regs in class A (max %d)\n", areg, bitsz), rval++; if (breg > bitsz) @@ -188,15 +283,24 @@ printf("%d regs in class C (max %d)\n", creg, bitsz), rval++; if (dreg > bitsz) printf("%d regs in class D (max %d)\n", dreg, bitsz), rval++; + if (ereg > bitsz) + printf("%d regs in class E (max %d)\n", ereg, bitsz), rval++; + if (freg > bitsz) + printf("%d regs in class F (max %d)\n", freg, bitsz), rval++; + if (greg > bitsz) + printf("%d regs in class G (max %d)\n", greg, bitsz), rval++; fprintf(fc, "static int amap[MAXREGS][NUMCLASS] = {\n"); for (i = 0; i < MAXREGS; i++) { - int ba, bb, bc, bd, r; - ba = bb = bc = bd = 0; + int ba, bb, bc, bd, r, be, bf, bg; + ba = bb = bc = bd = be = bf = bg = 0; if (rstatus[i] & SAREG) ba = (1 << regclassmap[0][i]); if (rstatus[i] & SBREG) bb = (1 << regclassmap[1][i]); if (rstatus[i] & SCREG) bc = (1 << regclassmap[2][i]); if (rstatus[i] & SDREG) bd = (1 << regclassmap[3][i]); + if (rstatus[i] & SEREG) be = (1 << regclassmap[4][i]); + if (rstatus[i] & SFREG) bf = (1 << regclassmap[5][i]); + if (rstatus[i] & SGREG) bg = (1 << regclassmap[6][i]); for (j = 0; roverlay[i][j] >= 0; j++) { r = roverlay[i][j]; if (rstatus[r] & SAREG) @@ -207,8 +311,21 @@ bc |= (1 << regclassmap[2][r]); if (rstatus[r] & SDREG) bd |= (1 << regclassmap[3][r]); + if (rstatus[r] & SEREG) + be |= (1 << regclassmap[4][r]); + if (rstatus[r] & SFREG) + bf |= (1 << regclassmap[5][r]); + if (rstatus[r] & SGREG) + bg |= (1 << regclassmap[6][r]); } - fprintf(fc, "\t{ 0x%x,0x%x,0x%x,0x%x },\n", ba, bb, bc, bd); + fprintf(fc, "\t/* %d */{ 0x%x", i, ba); + if (NUMCLASS > 1) fprintf(fc, ",0x%x", bb); + if (NUMCLASS > 2) fprintf(fc, ",0x%x", bc); + if (NUMCLASS > 3) fprintf(fc, ",0x%x", bd); + if (NUMCLASS > 4) fprintf(fc, ",0x%x", be); + if (NUMCLASS > 5) fprintf(fc, ",0x%x", bf); + if (NUMCLASS > 6) fprintf(fc, ",0x%x", bg); + fprintf(fc, " },\n"); } fprintf(fc, "};\n"); @@ -221,9 +338,12 @@ if (breg > mx) mx = breg; if (creg > mx) mx = creg; if (dreg > mx) mx = dreg; - if (mx > (sizeof(int)*8)-1) { - printf("too many regs in a calss, use two classes instead\n"); - printf("%d > %d\n", mx, (sizeof(int)*8)-1); + if (ereg > mx) mx = ereg; + if (freg > mx) mx = freg; + if (greg > mx) mx = greg; + if (mx > (int)(sizeof(int)*8)-1) { + printf("too many regs in a class, use two classes instead\n"); + printf("%d > %zu\n", mx, (sizeof(int)*8)-1); rval++; } fprintf(fc, "static int rmap[NUMCLASS][%d] = {\n", mx); @@ -241,13 +361,16 @@ fprintf(fc, " return rmap[class-1][color];\n}\n"); /* used by register allocator */ - fprintf(fc, "int regK[] = { 0, %d, %d, %d, %d };\n", - areg, breg, creg, dreg); + fprintf(fc, "int regK[] = { 0, %d, %d, %d, %d, %d, %d, %d };\n", + areg, breg, creg, dreg, ereg, freg, greg); fprintf(fc, "int\nclassmask(int class)\n{\n"); fprintf(fc, "\tif(class == CLASSA) return 0x%x;\n", (1 << areg)-1); fprintf(fc, "\tif(class == CLASSB) return 0x%x;\n", (1 << breg)-1); fprintf(fc, "\tif(class == CLASSC) return 0x%x;\n", (1 << creg)-1); - fprintf(fc, "\treturn 0x%x;\n}\n", (1 << dreg)-1); + fprintf(fc, "\tif(class == CLASSD) return 0x%x;\n", (1 << dreg)-1); + fprintf(fc, "\tif(class == CLASSE) return 0x%x;\n", (1 << ereg)-1); + fprintf(fc, "\tif(class == CLASSF) return 0x%x;\n", (1 << freg)-1); + fprintf(fc, "\treturn 0x%x;\n}\n", (1 << greg)-1); fprintf(fh, "int interferes(int reg1, int reg2);\n"); nelem = (MAXREGS+bitsz-1)/bitsz; @@ -270,6 +393,7 @@ fprintf(fc, "int\ninterferes(int reg1, int reg2)\n{\n"); fprintf(fc, "return TESTBIT(ovlarr[reg1], reg2);\n}\n"); fclose(fc); + fprintf(fh, "#endif /* _EXTERNAL_H_ */\n"); fclose(fh); return rval; } @@ -291,19 +415,20 @@ for (op = table; op->op != FREE; op++) { if (op->op < OPSIMP) { if (op->op == i) { - P((fc, "%td, ", op - table)); + P((fc, FMTdPTR ", ", op - table)); curalen++; } } else { int opmtemp; if ((opmtemp=mamask[op->op - OPSIMP])&SPFLG) { if (i==NAME || i==ICON || i==TEMP || - i==OREG || i == REG) { - P((fc, "%td, ", op - table)); + i==OREG || i == REG || i == FCON) { + P((fc, FMTdPTR ", ", + op - table)); curalen++; } } else if ((dope[i]&(opmtemp|ASGFLG))==opmtemp){ - P((fc, "%td, ", op - table)); + P((fc, FMTdPTR ", ", op - table)); curalen++; } } Index: optim2.c =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/optim2.c,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/optim2.c -L usr.bin/pcc/mip/optim2.c -u -r1.1 -r1.2 --- usr.bin/pcc/mip/optim2.c +++ usr.bin/pcc/mip/optim2.c @@ -1,4 +1,4 @@ -/* $Id: optim2.c,v 1.44 2006/06/20 06:02:44 ragge Exp $ */ +/* $Id: optim2.c,v 1.62 2008/12/11 21:23:28 pantzer Exp $ */ /* * Copyright (c) 2004 Anders Magnusson (ragge at ludd.luth.se). * All rights reserved. @@ -41,169 +41,48 @@ #define BDEBUG(x) if (b2debug) printf x +#define mktemp(n, t) mklnode(TEMP, 0, n, t) + static int dfsnum; void saveip(struct interpass *ip); -void deljumps(struct interpass *); +void deljumps(struct p2env *); void optdump(struct interpass *ip); void printip(struct interpass *pole); static struct varinfo defsites; struct interpass *storesave; -static struct interpass_prolog *ipp, *epp; /* prolog/epilog */ -void bblocks_build(struct interpass *, struct labelinfo *, struct bblockinfo *); -void cfg_build(struct labelinfo *labinfo); +void bblocks_build(struct p2env *, struct labelinfo *, struct bblockinfo *); +void cfg_build(struct p2env *, struct labelinfo *labinfo); void cfg_dfs(struct basicblock *bb, unsigned int parent, struct bblockinfo *bbinfo); -void dominators(struct bblockinfo *bbinfo); +void dominators(struct p2env *, struct bblockinfo *bbinfo); struct basicblock * ancestorwithlowestsemi(struct basicblock *bblock, struct bblockinfo *bbinfo); void link(struct basicblock *parent, struct basicblock *child); void computeDF(struct basicblock *bblock, struct bblockinfo *bbinfo); +void printDF(struct p2env *p2e, struct bblockinfo *bbinfo); void findTemps(struct interpass *ip); -void placePhiFunctions(struct bblockinfo *bbinfo); -void remunreach(void); - -struct basicblock bblocks; -int nbblocks; -static struct interpass *cvpole; - -struct addrof { - struct addrof *next; - int tempnum; - int oregoff; -} *otlink; - -static int -getoff(int num) -{ - struct addrof *w; - - for (w = otlink; w; w = w->next) - if (w->tempnum == num) - return w->oregoff; - return 0; -} - -/* - * Use stack argument addresses instead of copying if & is used on a var. - */ -static int -setargs(int tval, struct addrof *w) -{ - struct interpass *ip; - NODE *p; - - ip = DLIST_NEXT(cvpole, qelem); /* PROLOG */ - ip = DLIST_NEXT(ip, qelem); /* first DEFLAB */ - ip = DLIST_NEXT(ip, qelem); /* first NODE */ - for (; ip->type != IP_DEFLAB; ip = DLIST_NEXT(ip, qelem)) { - p = ip->ip_node; -#ifdef PCC_DEBUG - if (p->n_op != ASSIGN || p->n_left->n_op != TEMP) - comperr("temparg"); -#endif - if (p->n_right->n_op != OREG) - continue; /* arg in register */ - if (tval != p->n_left->n_lval) - continue; /* wrong assign */ - w->oregoff = p->n_right->n_lval; - tfree(p); - DLIST_REMOVE(ip, qelem); - return 1; - } - return 0; -} - -/* - * Search for ADDROF elements and, if found, record them. - */ -static void -findaddrof(NODE *p) -{ - struct addrof *w; - - if (p->n_op != ADDROF) - return; - if (getoff(p->n_left->n_lval)) - return; - w = tmpalloc(sizeof(struct addrof)); - w->tempnum = p->n_left->n_lval; - if (setargs(p->n_left->n_lval, w) == 0) - w->oregoff = BITOOR(freetemp(szty(p->n_left->n_type))); - w->next = otlink; - otlink = w; -} - - -/* - * Convert address-taken temps to OREGs. - */ -static void -cvtaddrof(NODE *p) -{ - NODE *l; - int n; - - if (p->n_op != ADDROF && p->n_op != TEMP) - return; - if (p->n_op == TEMP) { - n = getoff(p->n_lval); - if (n == 0) - return; - p->n_op = OREG; - p->n_lval = n; - p->n_rval = FPREG; - } else { - l = p->n_left; - l->n_type = p->n_type; - p->n_right = mklnode(ICON, l->n_lval, 0, l->n_type); - p->n_op = PLUS; - l->n_op = REG; - l->n_lval = 0; - l->n_rval = FPREG; - - } -} +void placePhiFunctions(struct p2env *, struct bblockinfo *bbinfo); +void renamevar(struct p2env *p2e,struct basicblock *bblock, struct bblockinfo *bbinfo); +void removephi(struct p2env *p2e, struct labelinfo *,struct bblockinfo *bbinfo); +void remunreach(struct p2env *); void -optimize(struct interpass *ipole) +optimize(struct p2env *p2e) { - struct interpass *ip; + struct interpass *ipole = &p2e->ipole; struct labelinfo labinfo; struct bblockinfo bbinfo; - ipp = (struct interpass_prolog *)DLIST_NEXT(ipole, qelem); - epp = (struct interpass_prolog *)DLIST_PREV(ipole, qelem); - if (b2debug) { printf("initial links\n"); printip(ipole); } - /* - * Convert ADDROF TEMP to OREGs. - */ - if (xtemps) { - otlink = NULL; - cvpole = ipole; - DLIST_FOREACH(ip, ipole, qelem) { - if (ip->type != IP_NODE) - continue; - walkf(ip->ip_node, findaddrof); - } - if (otlink) { - DLIST_FOREACH(ip, ipole, qelem) { - if (ip->type != IP_NODE) - continue; - walkf(ip->ip_node, cvtaddrof); - } - } - } - if (xdeljumps) - deljumps(ipole); /* Delete redundant jumps and dead code */ + deljumps(p2e); /* Delete redundant jumps and dead code */ #ifdef PCC_DEBUG if (b2debug) { @@ -212,32 +91,64 @@ } #endif if (xssaflag || xtemps) { - DLIST_INIT(&bblocks, bbelem); - bblocks_build(ipole, &labinfo, &bbinfo); + DLIST_INIT(&p2e->bblocks, bbelem); + bblocks_build(p2e, &labinfo, &bbinfo); BDEBUG(("Calling cfg_build\n")); - cfg_build(&labinfo); + cfg_build(p2e, &labinfo); } if (xssaflag) { BDEBUG(("Calling dominators\n")); - dominators(&bbinfo); + dominators(p2e, &bbinfo); BDEBUG(("Calling computeDF\n")); - computeDF(DLIST_NEXT(&bblocks, bbelem), &bbinfo); + computeDF(DLIST_NEXT(&p2e->bblocks, bbelem), &bbinfo); + + if (b2debug) { + printDF(p2e,&bbinfo); + } + + BDEBUG(("Calling placePhiFunctions\n")); + + placePhiFunctions(p2e, &bbinfo); + + BDEBUG(("Calling renamevar\n")); + + renamevar(p2e,DLIST_NEXT(&p2e->bblocks, bbelem), &bbinfo); + + BDEBUG(("Calling removephi\n")); + + removephi(p2e,&labinfo,&bbinfo); + BDEBUG(("Calling remunreach\n")); - remunreach(); -#if 0 - dfg = dfg_build(cfg); - ssa = ssa_build(cfg, dfg); + remunreach(p2e); + + /* + Recalculate basic blocks and cfg that was destroyed + by removephi + */ + + DLIST_INIT(&p2e->bblocks, bbelem); + bblocks_build(p2e, &labinfo, &bbinfo); + BDEBUG(("Calling cfg_build\n")); + cfg_build(p2e, &labinfo); + +#ifdef PCC_DEBUG + if (b2debug) { + printf("new tree\n"); + printip(ipole); + } #endif } #ifdef PCC_DEBUG - if (epp->ipp_regs != 0) - comperr("register error"); + { + int i; + for (i = NIPPREGS; i--; ) + if (p2e->epp->ipp_regs[i] != 0) + comperr("register error"); + } #endif -#ifdef MYOPTIM - myoptim((struct interpass *)ipp); -#endif + myoptim(ipole); } /* @@ -245,14 +156,18 @@ * This routine can be made much more efficient. */ void -deljumps(struct interpass *ipole) +deljumps(struct p2env *p2e) { - struct interpass *ip, *n, *ip2; + struct interpass *ipole = &p2e->ipole; + struct interpass *ip, *n, *ip2, *start; int gotone,low, high; - int *lblary, sz, o, i; + int *lblary, *jmpary, sz, o, i, j, lab1, lab2; + int del; + extern int negrel[]; + extern size_t negrelsize; - low = ipp->ip_lblnum; - high = epp->ip_lblnum; + low = p2e->ipp->ip_lblnum; + high = p2e->epp->ip_lblnum; #ifdef notyet mark = tmpmark(); /* temporary used memory */ @@ -260,18 +175,64 @@ sz = (high-low) * sizeof(int); lblary = tmpalloc(sz); + jmpary = tmpalloc(sz); + + /* + * XXX: Find the first two labels. They may not be deleted, + * because the register allocator expects them to be there. + * These will not be coalesced with any other label. + */ + lab1 = lab2 = -1; + start = NULL; + DLIST_FOREACH(ip, ipole, qelem) { + if (ip->type != IP_DEFLAB) + continue; + if (lab1 < 0) + lab1 = ip->ip_lbl; + else if (lab2 < 0) { + lab2 = ip->ip_lbl; + start = ip; + } else /* lab1 >= 0 && lab2 >= 0, we're done. */ + break; + } + if (lab1 < 0 || lab2 < 0) + comperr("deljumps"); again: gotone = 0; memset(lblary, 0, sz); + lblary[lab1 - low] = lblary[lab2 - low] = 1; + memset(jmpary, 0, sz); /* refcount and coalesce all labels */ DLIST_FOREACH(ip, ipole, qelem) { - if (ip->type == IP_DEFLAB) { + if (ip->type == IP_DEFLAB && ip->ip_lbl != lab1 && + ip->ip_lbl != lab2) { n = DLIST_NEXT(ip, qelem); + + /* + * Find unconditional jumps directly following a + * label. Jumps jumping to themselves are not + * taken into account. + */ + if (n->type == IP_NODE && n->ip_node->n_op == GOTO) { + i = n->ip_node->n_left->n_lval; + if (i != ip->ip_lbl) + jmpary[ip->ip_lbl - low] = i; + } + while (n->type == IP_DEFLAB) { - if (n->type == IP_DEFLAB && - lblary[n->ip_lbl-low] >= 0) - lblary[n->ip_lbl-low] = -ip->ip_lbl; + if (n->ip_lbl != lab1 && n->ip_lbl != lab2 && + lblary[n->ip_lbl-low] >= 0) { + /* + * If the label is used, mark the + * label to be coalesced with as + * used, too. + */ + if (lblary[n->ip_lbl - low] > 0 && + lblary[ip->ip_lbl - low] == 0) + lblary[ip->ip_lbl - low] = 1; + lblary[n->ip_lbl - low] = -ip->ip_lbl; + } n = DLIST_NEXT(n, qelem); } } @@ -284,7 +245,15 @@ i = ip->ip_node->n_right->n_lval; else continue; - lblary[i-low] |= 1; + + /* + * Mark destination label i as used, if it is not already. + * If i is to be merged with label j, mark j as used, too. + */ + if (lblary[i - low] == 0) + lblary[i-low] = 1; + else if ((j = lblary[i - low]) < 0 && lblary[-j - low] == 0) + lblary[-j - low] = 1; } /* delete coalesced/unused labels and rename gotos */ @@ -295,22 +264,33 @@ DLIST_REMOVE(n, qelem); gotone = 1; } - continue; } - if (n->type != IP_NODE) + if (ip->type != IP_NODE) continue; - o = n->ip_node->n_op; + o = ip->ip_node->n_op; if (o == GOTO) - i = n->ip_node->n_left->n_lval; + i = ip->ip_node->n_left->n_lval; else if (o == CBRANCH) - i = n->ip_node->n_right->n_lval; + i = ip->ip_node->n_right->n_lval; else continue; + + /* Simplify (un-)conditional jumps to unconditional jumps. */ + if (jmpary[i - low] > 0) { + gotone = 1; + i = jmpary[i - low]; + if (o == GOTO) + ip->ip_node->n_left->n_lval = i; + else + ip->ip_node->n_right->n_lval = i; + } + + /* Fixup for coalesced labels. */ if (lblary[i-low] < 0) { if (o == GOTO) - n->ip_node->n_left->n_lval = -lblary[i-low]; + ip->ip_node->n_left->n_lval = -lblary[i-low]; else - n->ip_node->n_right->n_lval = -lblary[i-low]; + ip->ip_node->n_right->n_lval = -lblary[i-low]; } } @@ -332,13 +312,61 @@ if (ip2->type != IP_DEFLAB) continue; - if (ip2->ip_lbl == i) { + if (ip2->ip_lbl == i && i != lab1 && i != lab2) { tfree(n->ip_node); DLIST_REMOVE(n, qelem); gotone = 1; } } + /* + * Transform cbranch cond, 1; goto 2; 1: ... into + * cbranch !cond, 2; 1: ... + */ + DLIST_FOREACH(ip, ipole, qelem) { + n = DLIST_NEXT(ip, qelem); + ip2 = DLIST_NEXT(n, qelem); + if (ip->type != IP_NODE || ip->ip_node->n_op != CBRANCH) + continue; + if (n->type != IP_NODE || n->ip_node->n_op != GOTO) + continue; + if (ip2->type != IP_DEFLAB) + continue; + i = ip->ip_node->n_right->n_lval; + j = n->ip_node->n_left->n_lval; + if (j == lab1 || j == lab2) + continue; + if (i != ip2->ip_lbl || i == lab1 || i == lab2) + continue; + ip->ip_node->n_right->n_lval = j; + i = ip->ip_node->n_left->n_op; + if (i < EQ || i - EQ >= (int)negrelsize) + comperr("deljumps: unexpected op"); + ip->ip_node->n_left->n_op = negrel[i - EQ]; + tfree(n->ip_node); + DLIST_REMOVE(n, qelem); + gotone = 1; + } + + /* Delete everything after a goto up to the next label. */ + for (ip = start, del = 0; ip != DLIST_ENDMARK(ipole); + ip = DLIST_NEXT(ip, qelem)) { +loop: + if ((n = DLIST_NEXT(ip, qelem)) == DLIST_ENDMARK(ipole)) + break; + if (n->type != IP_NODE) { + del = 0; + continue; + } + if (del) { + tfree(n->ip_node); + DLIST_REMOVE(n, qelem); + gotone = 1; + goto loop; + } else if (n->ip_node->n_op == GOTO) + del = 1; + } + if (gotone) goto again; @@ -355,7 +383,9 @@ printf("type %s\n", nm[ip->type-1]); switch (ip->type) { case IP_NODE: +#ifdef PCC_DEBUG fwalk(ip->ip_node, e2print, 0); +#endif break; case IP_DEFLAB: printf("label " LABFMT "\n", ip->ip_lbl); @@ -374,9 +404,10 @@ */ void -bblocks_build(struct interpass *ipole, struct labelinfo *labinfo, +bblocks_build(struct p2env *p2e, struct labelinfo *labinfo, struct bblockinfo *bbinfo) { + struct interpass *ipole = &p2e->ipole; struct interpass *ip; struct basicblock *bb = NULL; int low, high; @@ -384,8 +415,8 @@ int i; BDEBUG(("bblocks_build (%p, %p)\n", labinfo, bbinfo)); - low = ipp->ip_lblnum; - high = epp->ip_lblnum; + low = p2e->ipp->ip_lblnum; + high = p2e->epp->ip_lblnum; /* * First statement is a leader. @@ -410,8 +441,9 @@ bb->dfchildren = NULL; bb->Aorig = NULL; bb->Aphi = NULL; + SLIST_INIT(&bb->phi); bb->bbnum = count; - DLIST_INSERT_BEFORE(&bblocks, bb, bbelem); + DLIST_INSERT_BEFORE(&p2e->bblocks, bb, bbelem); count++; } bb->last = ip; @@ -421,12 +453,12 @@ if (ip->type == IP_PROLOG) bb = NULL; } - nbblocks = count; + p2e->nbblocks = count; if (b2debug) { printf("Basic blocks in func: %d, low %d, high %d\n", count, low, high); - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { printf("bb %p: first %p last %p\n", bb, bb->first, bb->last); } @@ -446,7 +478,7 @@ } /* Build the label table */ - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { if (bb->first->type == IP_DEFLAB) labinfo->arr[bb->first->ip_lbl - low] = bb; } @@ -465,14 +497,14 @@ */ void -cfg_build(struct labelinfo *labinfo) +cfg_build(struct p2env *p2e, struct labelinfo *labinfo) { /* Child and parent nodes */ struct cfgnode *cnode; struct cfgnode *pnode; struct basicblock *bb; - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { if (bb->first->type == IP_EPILOG) { break; @@ -483,7 +515,8 @@ pnode->bblock = bb; if ((bb->last->type == IP_NODE) && - (bb->last->ip_node->n_op == GOTO)) { + (bb->last->ip_node->n_op == GOTO) && + (bb->last->ip_node->n_left->n_op == ICON)) { if (bb->last->ip_node->n_left->n_lval - labinfo->low > labinfo->size) { comperr("Label out of range: %d, base %d", @@ -550,27 +583,27 @@ */ void -dominators(struct bblockinfo *bbinfo) +dominators(struct p2env *p2e, struct bblockinfo *bbinfo) { struct cfgnode *cnode; struct basicblock *bb, *y, *v; struct basicblock *s, *sprime, *p; int h, i; - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { bb->bucket = setalloc(bbinfo->size); bb->df = setalloc(bbinfo->size); bb->dfchildren = setalloc(bbinfo->size); } dfsnum = 0; - cfg_dfs(DLIST_NEXT(&bblocks, bbelem), 0, bbinfo); + cfg_dfs(DLIST_NEXT(&p2e->bblocks, bbelem), 0, bbinfo); if (b2debug) { struct basicblock *bbb; struct cfgnode *ccnode; - DLIST_FOREACH(bbb, &bblocks, bbelem) { + DLIST_FOREACH(bbb, &p2e->bblocks, bbelem) { printf("Basic block %d, parents: ", bbb->dfnum); SLIST_FOREACH(ccnode, &bbb->parents, cfgelem) { printf("%d, ", ccnode->bblock->dfnum); @@ -587,6 +620,9 @@ bb = bbinfo->arr[h]; p = s = bbinfo->arr[bb->dfparent]; SLIST_FOREACH(cnode, &bb->parents, cfgelem) { + if (cnode->bblock->dfnum ==0) + continue; /* Ignore unreachable code */ + if (cnode->bblock->dfnum <= bb->dfnum) sprime = cnode->bblock; else @@ -613,7 +649,7 @@ if (b2debug) { printf("Num\tSemi\tAncest\tidom\n"); - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { printf("%d\t%d\t%d\t%d\n", bb->dfnum, bb->semi, bb->ancestor, bb->idom); } @@ -625,7 +661,7 @@ bb->idom = bbinfo->arr[bb->samedom]->idom; } } - DLIST_FOREACH(bb, &bblocks, bbelem) { + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { if (bb->idom != 0 && bb->idom != bb->dfnum) { BDEBUG(("Setting child %d of %d\n", bb->dfnum, bbinfo->arr[bb->idom]->dfnum)); @@ -672,36 +708,70 @@ computeDF(bbinfo->arr[h], bbinfo); for (i = 1; i < bbinfo->size; i++) { if (TESTBIT(bbinfo->arr[h]->df, i) && - (bbinfo->arr[h] == bblock || - (bblock->idom != bbinfo->arr[h]->dfnum))) + (bbinfo->arr[i] == bblock || + (bblock->dfnum != bbinfo->arr[i]->idom))) BITSET(bblock->df, i); } } } +void printDF(struct p2env *p2e, struct bblockinfo *bbinfo) +{ + struct basicblock *bb; + int i; + + printf("Dominance frontiers:\n"); + + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { + printf("bb %d : ", bb->dfnum); + + for (i=1; i < bbinfo->size;i++) { + if (TESTBIT(bb->df,i)) { + printf("%d ",i); + } + } + + printf("\n"); + } + +} + + + static struct basicblock *currbb; static struct interpass *currip; /* Helper function for findTemps, Find assignment nodes. */ static void -searchasg(NODE *p) +searchasg(NODE *p, void *arg) { struct pvarinfo *pv; - + int tempnr; + struct varstack *stacke; + if (p->n_op != ASSIGN) return; if (p->n_left->n_op != TEMP) return; + tempnr=regno(p->n_left)-defsites.low; + + BITSET(currbb->Aorig, tempnr); + pv = tmpcalloc(sizeof(struct pvarinfo)); - pv->next = defsites.arr[p->n_left->n_lval]; + pv->next = defsites.arr[tempnr]; pv->bb = currbb; - pv->top = currip->ip_node; - pv->n = p->n_left; - BITSET(currbb->Aorig, p->n_left->n_lval); - - defsites.arr[p->n_left->n_lval] = pv; + pv->n_type = p->n_left->n_type; + + defsites.arr[tempnr] = pv; + + + if (SLIST_FIRST(&defsites.stack[tempnr])==NULL) { + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=0; + SLIST_INSERT_FIRST(&defsites.stack[tempnr],stacke,varstackelem); + } } /* Walk the interpass looking for assignment nodes. */ @@ -712,7 +782,7 @@ currip = ip; - walkf(ip->ip_node, searchasg); + walkf(ip->ip_node, searchasg, 0); } /* @@ -720,32 +790,37 @@ */ void -placePhiFunctions(struct bblockinfo *bbinfo) +placePhiFunctions(struct p2env *p2e, struct bblockinfo *bbinfo) { struct basicblock *bb; + struct basicblock *y; struct interpass *ip; - int maxtmp, i, j, k, l; + int maxtmp, i, j, k; struct pvarinfo *n; struct cfgnode *cnode; TWORD ntype; - NODE *p; struct pvarinfo *pv; + struct phiinfo *phi; + int phifound; - bb = DLIST_NEXT(&bblocks, bbelem); + bb = DLIST_NEXT(&p2e->bblocks, bbelem); defsites.low = ((struct interpass_prolog *)bb->first)->ip_tmpnum; - bb = DLIST_PREV(&bblocks, bbelem); + bb = DLIST_PREV(&p2e->bblocks, bbelem); maxtmp = ((struct interpass_prolog *)bb->first)->ip_tmpnum; defsites.size = maxtmp - defsites.low + 1; defsites.arr = tmpcalloc(defsites.size*sizeof(struct pvarinfo *)); - + defsites.stack = tmpcalloc(defsites.size*sizeof(SLIST_HEAD(, varstack))); + + for (i=0;ibblocks, bbelem) { currbb = bb; ip = bb->first; bb->Aorig = setalloc(defsites.size); bb->Aphi = setalloc(defsites.size); - while (ip != bb->last) { findTemps(ip); ip = DLIST_NEXT(ip, qelem); @@ -753,8 +828,9 @@ /* Make sure we get the last statement in the bblock */ findTemps(ip); } + /* For each variable */ - for (i = defsites.low; i < defsites.size; i++) { + for (i = 0; i < defsites.size; i++) { /* While W not empty */ while (defsites.arr[i] != NULL) { /* Remove some node n from W */ @@ -768,27 +844,45 @@ if (TESTBIT(bbinfo->arr[j]->Aphi, i)) continue; - ntype = n->n->n_type; + y=bbinfo->arr[j]; + ntype = n->n_type; k = 0; /* Amount of predecessors for y */ - SLIST_FOREACH(cnode, &n->bb->parents, cfgelem) + SLIST_FOREACH(cnode, &y->parents, cfgelem) k++; - /* Construct phi(...) */ - p = mklnode(TEMP, i, 0, ntype); - for (l = 0; l < k-1; l++) - p = mkbinode(PHI, p, - mklnode(TEMP, i, 0, ntype), ntype); - ip = ipnode(mkbinode(ASSIGN, - mklnode(TEMP, i, 0, ntype), p, ntype)); - /* Insert phi at top of basic block */ - DLIST_INSERT_BEFORE(((struct interpass*)&n->bb->first), ip, qelem); - n->bb->first = ip; + /* Construct phi(...) + */ + + phifound=0; + + SLIST_FOREACH(phi, &y->phi, phielem) { + if (phi->tmpregno==i+defsites.low) + phifound++; + } + + if (phifound==0) { + if (b2debug) + printf("Phi in %d (%p) for %d\n",y->dfnum,y,i+defsites.low); + + phi = tmpcalloc(sizeof(struct phiinfo)); + + phi->tmpregno=i+defsites.low; + phi->size=k; + phi->n_type=ntype; + phi->intmpregno=tmpcalloc(k*sizeof(int)); + + SLIST_INSERT_LAST(&y->phi,phi,phielem); + } else { + if (b2debug) + printf("Phi already in %d for %d\n",y->dfnum,i+defsites.low); + } + BITSET(bbinfo->arr[j]->Aphi, i); if (!TESTBIT(bbinfo->arr[j]->Aorig, i)) { pv = tmpalloc(sizeof(struct pvarinfo)); - // XXXpj Ej fullst?ndig information. - pv->bb = bbinfo->arr[j]; - pv->next = defsites.arr[i]->next; + pv->bb = y; + pv->n_type=ntype; + pv->next = defsites.arr[i]; defsites.arr[i] = pv; } @@ -798,18 +892,232 @@ } } +/* Helper function for renamevar. */ +static void +renamevarhelper(struct p2env *p2e,NODE *t,void *poplistarg) +{ + SLIST_HEAD(, varstack) *poplist=poplistarg; + int opty; + int tempnr; + int newtempnr; + int x; + struct varstack *stacke; + + if (t->n_op == ASSIGN && t->n_left->n_op == TEMP) { + renamevarhelper(p2e,t->n_right,poplist); + + tempnr=regno(t->n_left)-defsites.low; + + newtempnr=p2e->epp->ip_tmpnum++; + regno(t->n_left)=newtempnr; + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=newtempnr; + SLIST_INSERT_FIRST(&defsites.stack[tempnr],stacke,varstackelem); + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=tempnr; + SLIST_INSERT_FIRST(poplist,stacke,varstackelem); + } else { + if (t->n_op == TEMP) { + tempnr=regno(t)-defsites.low; + + x=SLIST_FIRST(&defsites.stack[tempnr])->tmpregno; + regno(t)=x; + } + + opty = optype(t->n_op); + + if (opty != LTYPE) + renamevarhelper(p2e, t->n_left,poplist); + if (opty == BITYPE) + renamevarhelper(p2e, t->n_right,poplist); + } +} + + +void +renamevar(struct p2env *p2e,struct basicblock *bb, struct bblockinfo *bbinfo) +{ + struct interpass *ip; + int h,j; + SLIST_HEAD(, varstack) poplist; + struct varstack *stacke; + struct cfgnode *cfgn; + struct cfgnode *cfgn2; + int tmpregno,newtmpregno; + struct phiinfo *phi; + + SLIST_INIT(&poplist); + + SLIST_FOREACH(phi,&bb->phi,phielem) { + tmpregno=phi->tmpregno-defsites.low; + + newtmpregno=p2e->epp->ip_tmpnum++; + phi->newtmpregno=newtmpregno; + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=newtmpregno; + SLIST_INSERT_FIRST(&defsites.stack[tmpregno],stacke,varstackelem); + + stacke=tmpcalloc(sizeof (struct varstack)); + stacke->tmpregno=tmpregno; + SLIST_INSERT_FIRST(&poplist,stacke,varstackelem); + } + + + ip=bb->first; + + while (1) { + if ( ip->type == IP_NODE) { + renamevarhelper(p2e,ip->ip_node,&poplist); + } + + if (ip==bb->last) + break; + + ip = DLIST_NEXT(ip, qelem); + } + + SLIST_FOREACH(cfgn,&bb->children,cfgelem) { + j=0; + + SLIST_FOREACH(cfgn2, &cfgn->bblock->parents, cfgelem) { + if (cfgn2->bblock->dfnum==bb->dfnum) + break; + + j++; + } + + SLIST_FOREACH(phi,&cfgn->bblock->phi,phielem) { + phi->intmpregno[j]=SLIST_FIRST(&defsites.stack[phi->tmpregno-defsites.low])->tmpregno; + } + + } + + for (h = 1; h < bbinfo->size; h++) { + if (!TESTBIT(bb->dfchildren, h)) + continue; + + renamevar(p2e,bbinfo->arr[h], bbinfo); + } + + SLIST_FOREACH(stacke,&poplist,varstackelem) { + tmpregno=stacke->tmpregno; + + defsites.stack[tmpregno].q_forw=defsites.stack[tmpregno].q_forw->varstackelem.q_forw; + } +} + +void +removephi(struct p2env *p2e, struct labelinfo *labinfo,struct bblockinfo *bbinfo) +{ + struct basicblock *bb,*bbparent; + struct cfgnode *cfgn; + struct phiinfo *phi; + int i; + struct interpass *ip; + struct interpass *pip; + TWORD n_type; + int complex; + int label=0; + int newlabel; + + DLIST_FOREACH(bb, &p2e->bblocks, bbelem) { + SLIST_FOREACH(phi,&bb->phi,phielem) { // Look at only one, notice break at end + i=0; + + SLIST_FOREACH(cfgn, &bb->parents, cfgelem) { + bbparent=cfgn->bblock; + + pip=bbparent->last; + + complex = 0; + + BDEBUG(("removephi: %p in %d",pip,bb->dfnum)); + if (pip->type == IP_NODE && pip->ip_node->n_op == GOTO) { + BDEBUG((" GOTO ")); + label=pip->ip_node->n_left->n_lval; + complex=1; + } else if (pip->type == IP_NODE && pip->ip_node->n_op == CBRANCH) { + BDEBUG((" CBRANCH ")); + label=pip->ip_node->n_right->n_lval; + + if (bb==labinfo->arr[label - p2e->ipp->ip_lblnum]) + complex=2; + } + + BDEBUG((" Complex: %d\n",complex)); + + if (complex > 0) { + /* + This destroys basic block calculations. + Maybe it shoud not + */ + ip = ipnode(mkunode(GOTO, mklnode(ICON, label, 0, INT), 0, INT)); + DLIST_INSERT_BEFORE((bb->first), ip, qelem); + + newlabel=getlab2(); + + ip = tmpalloc(sizeof(struct interpass)); + ip->type = IP_DEFLAB; + // Line number?? ip->lineno; + ip->ip_lbl = newlabel; + DLIST_INSERT_BEFORE((bb->first), ip, qelem); + + SLIST_FOREACH(phi,&bb->phi,phielem) { + if (phi->intmpregno[i]>0) { + n_type=phi->n_type; + ip = ipnode(mkbinode(ASSIGN, + mktemp(phi->newtmpregno, n_type), + mktemp(phi->intmpregno[i],n_type), + n_type)); + + DLIST_INSERT_BEFORE((bb->first), ip, qelem); + } + } + + if (complex==1) + pip->ip_node->n_left->n_lval=newlabel; + + if (complex==2) + pip->ip_node->n_right->n_lval=newlabel; + + } else { + /* Construct move */ + SLIST_FOREACH(phi,&bb->phi,phielem) { + if (phi->intmpregno[i]>0) { + n_type=phi->n_type; + ip = ipnode(mkbinode(ASSIGN, + mktemp(phi->newtmpregno, n_type), + mktemp(phi->intmpregno[i],n_type), + n_type)); + + /* Insert move at bottom of parent basic block */ + DLIST_INSERT_AFTER((bbparent->last), ip, qelem); + } + } + } + i++; + } + break; + } + } +} + + /* * Remove unreachable nodes in the CFG. */ void -remunreach(void) +remunreach(struct p2env *p2e) { struct basicblock *bb, *nbb; struct interpass *next, *ctree; - bb = DLIST_NEXT(&bblocks, bbelem); - while (bb != &bblocks) { + bb = DLIST_NEXT(&p2e->bblocks, bbelem); + while (bb != &p2e->bblocks) { nbb = DLIST_NEXT(bb, bbelem); /* Code with dfnum 0 is unreachable */ @@ -848,7 +1156,8 @@ static char *foo[] = { 0, "NODE", "PROLOG", "STKOFF", "EPILOG", "DEFLAB", "DEFNAM", "ASM" }; struct interpass *ip; - struct interpass_prolog *ipp, *epp; + struct interpass_prolog *ipplg, *epplg; + unsigned i; DLIST_FOREACH(ip, pole, qelem) { if (ip->type > MAXIP) @@ -857,20 +1166,28 @@ printf("%s (%p): ", foo[ip->type], ip); switch (ip->type) { case IP_NODE: printf("\n"); +#ifdef PCC_DEBUG fwalk(ip->ip_node, e2print, 0); break; +#endif case IP_PROLOG: - ipp = (struct interpass_prolog *)ip; - printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", - ipp->ipp_name, ipp->ipp_vis ? "(local)" : "", - ipp->ipp_regs, ipp->ipp_autos, ipp->ip_tmpnum, - ipp->ip_lblnum); + ipplg = (struct interpass_prolog *)ip; + printf("%s %s regs", + ipplg->ipp_name, ipplg->ipp_vis ? "(local)" : ""); + for (i = 0; i < NIPPREGS; i++) + printf("%s0x%x", i? ":" : " ", + ipplg->ipp_regs[i]); + printf(" autos %d mintemp %d minlbl %d\n", + ipplg->ipp_autos, ipplg->ip_tmpnum, ipplg->ip_lblnum); break; case IP_EPILOG: - epp = (struct interpass_prolog *)ip; - printf("%s %s regs %x autos %d mintemp %d minlbl %d\n", - epp->ipp_name, epp->ipp_vis ? "(local)" : "", - epp->ipp_regs, epp->ipp_autos, epp->ip_tmpnum, - epp->ip_lblnum); + epplg = (struct interpass_prolog *)ip; + printf("%s %s regs", + epplg->ipp_name, epplg->ipp_vis ? "(local)" : ""); + for (i = 0; i < NIPPREGS; i++) + printf("%s0x%x", i? ":" : " ", + epplg->ipp_regs[i]); + printf(" autos %d mintemp %d minlbl %d\n", + epplg->ipp_autos, epplg->ip_tmpnum, epplg->ip_lblnum); break; case IP_DEFLAB: printf(LABFMT "\n", ip->ip_lbl); break; case IP_DEFNAM: printf("\n"); break; Index: protos.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/mip/protos.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/mip/protos.h -L usr.bin/pcc/mip/protos.h -u -r1.1 -r1.2 --- usr.bin/pcc/mip/protos.h +++ usr.bin/pcc/mip/protos.h @@ -1,24 +1,9 @@ -struct optab; -struct symtab; -struct sw; - -void cerror(char *s, ...); -void werror(char *s, ...); -void uerror(char *s, ...); -void reclaim(NODE *p, int, int); -void walkf(NODE *, void (*f)(NODE *)); -void allchk(void); -void tfree(NODE *); int tshape(NODE *, int); -void prtdcon(NODE *p); -void tinit(void); void tcheck(void); void mkdope(void); -int tshape(NODE *p, int shape); int shtemp(NODE *p); int flshape(NODE *p); -int shumul(NODE *p); int ttype(TWORD t, int tword); void expand(NODE *, int, char *); void hopcode(int, int); @@ -26,58 +11,29 @@ void zzzcode(NODE *, int); void insput(NODE *); void upput(NODE *, int); -void econvert(NODE *); int andable(NODE *); int conval(NODE *, int, NODE *); int ispow2(CONSZ); void defid(NODE *q, int class); -int getlab(void); void ftnend(void); void efcode(void); void dclargs(void); -void fixarg(struct symtab *); void cendarg(void); -void defalign(int); int fldal(unsigned int); -void vfdzero(int); -void zecode(int); -void putbyte(int v); +int fldexpand(NODE *, int, char **); void ecomp(NODE *p); -void cinit(NODE *, int); void bccode(void); int upoff(int size, int alignment, int *poff); -void fldty(struct symtab *p); void nidcl(NODE *p, int class); int noinit(void); void eprint(NODE *, int, int *, int *); int uclass(int class); -int fixclass(int, TWORD type); -void lineid(int, char *); -void mycanon(NODE *); -void delay(NODE *); -int delay1(NODE *); -void delay2(NODE *); void setregs(void); -int autoincr(NODE *); -int deltest(NODE *); -void canon(NODE *); -void order(NODE *, int); int tlen(NODE *p); -int setincr(NODE *); int setbin(NODE *); -void stoarg(NODE *p, int); -void constore(NODE *); -void markcall(NODE *); -void oreg2(NODE *p); int notoff(TWORD, int, CONSZ, char *); -void bycode(int, int); -void pstab(char *, int); -void psline(void); int notlval(NODE *); -int icons(NODE *); void ecode(NODE *p); int yylex(void); void yyerror(char *s); void p2tree(NODE *p); -int rewfld(NODE *p); -int freetemp(int k); Index: ccconfig.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/ccconfig.h,v retrieving revision 1.1 retrieving revision 1.2 diff -L usr.bin/pcc/ccconfig.h -L usr.bin/pcc/ccconfig.h -u -r1.1 -r1.2 --- usr.bin/pcc/ccconfig.h +++ usr.bin/pcc/ccconfig.h @@ -1,43 +1,129 @@ +/* $Id: ccconfig.h,v 1.4 2008/07/18 06:53:48 gmcgarry Exp $ */ /*- - * Copyright (c) 2007 Lucas Holt - * Copyright (c) 2007 David O'Brien - * Copyright (c) 2007 Ed Schouten - * All rights reserved. + * Copyright (c) 2007, 2008 + * Thorsten Glaser * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. + * Provided that these terms and disclaimer and all copyright notices + * are retained or reproduced in an accompanying document, permission + * is granted to deal in this work without restriction, including un- + * limited rights to use, publicly perform, distribute, sell, modify, + * merge, give away, or sublicence. * - * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. + * This work is provided "AS IS" and WITHOUT WARRANTY of any kind, to + * the utmost extent permitted by applicable law, neither express nor + * implied; without malicious intent or gross negligence. In no event + * may a licensor, author or contributor be held liable for indirect, + * direct, other damage, loss, or other issues arising in any way out + * of dealing in the work, even if advised of the possibility of such + * damage or existence of a defect, except proven that it results out + * of said person's immediate fault when using the work as intended. */ -#define CPPADD { "-D__MidnightBSD__", "-D__ELF__", "-D__unix__=1", "-D__unix=1", "-D__STDC__=1", NULL, } -#define DYNLINKER { "-dynamic-linker", "/libexec/ld-elf.so.1", NULL } -#define CRT0FILE "/usr/lib/crt1.o" -#define STARTFILES { "/usr/lib/crti.o", "/usr/lib/crtbegin.o", NULL } -#define ENDFILES { "/usr/lib/crtend.o", "/usr/lib/crtn.o", NULL } -#define STARTLABEL "_start" +/** + * Configuration for pcc on a MidnightBSD (amd64, i386 or sparc64) target + */ -#if defined(mach_i386) || defined(mach_x86) -#define CPPMDADD { "-D__i386__", "-D__i386", NULL, } -#else -#error defines for arch missing +/* === mi part === */ + +#ifndef LIBDIR +#define LIBDIR "/usr/lib/" #endif +/* cpp MI defines */ +#define CPPADD { \ + "-D__MidnightBSD__", \ + "-D__FreeBSD__", \ + "-D__unix__", \ + "-D__unix", \ + "-Dunix", \ + "-D__ELF__", \ + "-D_LONGLONG", \ + NULL \ +} + +/* for dynamically linked binaries */ +#define DYNLINKER { \ + "-dynamic-linker", \ + "/libexec/ld-elf.so.1", \ + NULL \ +} +#define STARTFILES { \ + LIBDIR "crti.o", \ + LIBDIR "crtbegin.o", \ + NULL \ +} +#define ENDFILES { \ + LIBDIR "crtend.o", \ + LIBDIR "crtn.o", \ + NULL \ +} + +/* for shared libraries */ +#define STARTFILES_S { \ + LIBDIR "crti.o", \ + LIBDIR "crtbeginS.o", \ + NULL \ +} +#define ENDFILES_S { \ + LIBDIR "crtendS.o", \ + LIBDIR "crtn.o", \ + NULL \ +} + +/* for statically linked binaries */ +#define STARTFILES_T { \ + LIBDIR "crti.o", \ + LIBDIR "crtbeginT.o", \ + NULL \ +} +#define ENDFILES_T { \ + LIBDIR "crtend.o", \ + LIBDIR "crtn.o", \ + NULL \ +} + +#define LIBCLIBS { \ + "-lc", \ + NULL \ +} +#define LIBCLIBS_PROFILE { \ + "-lc_p", \ + NULL \ +} + + +/* C run-time startup */ +#define CRT0FILE LIBDIR "crt1.o" +#define CRT0FILE_PROFILE LIBDIR "gcrt1.o" +#define STARTLABEL "_start" + +/* debugging info */ #define STABS +/* === md part === */ + +#if defined(mach_i386) +#define CPPMDADD { \ + "-D__i386__", \ + "-D__i386", \ + "-Di386", \ + NULL, \ +} +#elif defined(mach_sparc64) +#define CPPMDADD { \ + "-D__sparc64__", \ + "-D__sparc_v9__", \ + "-D__sparcv9", \ + "-D__sparc__", \ + "-D__sparc", \ + "-Dsparc", \ + "-D__arch64__", \ + "-D__LP64__", \ + "-D_LP64", \ + NULL, \ +} +#elif defined(mach_amd64) +#error pcc does not support amd64 yet +#else +#error this architecture is not supported by MidnightBSD +#endif Index: config.h =================================================================== RCS file: /home/cvs/src/usr.bin/pcc/config.h,v retrieving revision 1.3 retrieving revision 1.4 diff -L usr.bin/pcc/config.h -L usr.bin/pcc/config.h -u -r1.3 -r1.4 --- usr.bin/pcc/config.h +++ usr.bin/pcc/config.h @@ -1,6 +1,21 @@ /* config.h. Generated from config.h.in by configure. */ /* config.h.in. Generated from configure.ac by autoheader. */ +/* Using a.out ABI */ +/* #undef AOUTABI */ + +/* Define path to alternate assembler */ +/* #undef ASSEMBLER */ + +/* Using Classic 68k ABI */ +/* #undef CLASSIC68K */ + +/* Using COFF ABI */ +/* #undef COFFABI */ + +/* Define path to alternate preprocessor */ +/* #undef COMPILER */ + /* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP systems. This function is required for `alloca.c' support on those systems. */ @@ -9,6 +24,12 @@ /* Define to 1 if using `alloca.c'. */ /* #undef C_ALLOCA */ +/* Using ECOFF ABI */ +/* #undef ECOFFABI */ + +/* Using ELF ABI */ +#define ELFABI + /* Define to 1 if you have `alloca', as a function or macro. */ #define HAVE_ALLOCA 1 @@ -16,30 +37,38 @@ */ /* #undef HAVE_ALLOCA_H */ -/* Define to 1 if you don't have `vprintf' but do have `_doprnt.' */ -/* #undef HAVE_DOPRNT */ +/* Define to 1 if you have the `basename' function. */ +#define HAVE_BASENAME 1 + +/* Define to 1 if printf supports C99 size specifiers */ +#define HAVE_C99_FORMAT 1 + +/* Define to 1 if your compiler supports C99 variadic macros */ +#define HAVE_CPP_VARARG_MACRO_GCC 1 -/* Define to 1 if you have the header file. */ -/* #undef HAVE_FCNTL_H */ +/* Define to 1 if you have the `ffs' function. */ +#define HAVE_FFS 1 -/* Define to 1 if you have the `fork' function. */ -/* #undef HAVE_FORK */ +/* Define to 1 if you have the `getopt' function. */ +#define HAVE_GETOPT 1 /* Define to 1 if you have the header file. */ #define HAVE_INTTYPES_H 1 -/* Define to 1 if your system has a GNU libc compatible `malloc' function, and - to 0 otherwise. */ -/* #undef HAVE_MALLOC */ +/* Define to 1 if you have the header file. */ +#define HAVE_LIBGEN_H 1 + +/* Define to 1 if you have the header file. */ +/* #undef HAVE_MALLOC_H */ /* Define to 1 if you have the header file. */ #define HAVE_MEMORY_H 1 -/* Define to 1 if you have the `memset' function. */ -/* #undef HAVE_MEMSET */ +/* Define to 1 if you have the `mkstemp' function. */ +#define HAVE_MKSTEMP 1 -/* Define to 1 if stdbool.h conforms to C99. */ -/* #undef HAVE_STDBOOL_H */ +/* Define to 1 if you have the `snprintf' function. */ +#define HAVE_SNPRINTF 1 /* Define to 1 if you have the header file. */ #define HAVE_STDINT_H 1 @@ -47,27 +76,17 @@ /* Define to 1 if you have the header file. */ #define HAVE_STDLIB_H 1 -/* Define to 1 if you have the `strchr' function. */ -/* #undef HAVE_STRCHR */ -#define HAVE_STRCHR 1 - -/* Define to 1 if you have the `strdup' function. */ -/* #undef HAVE_STRDUP */ -#define HAVE_STRDUP 1 - /* Define to 1 if you have the header file. */ #define HAVE_STRINGS_H 1 /* Define to 1 if you have the header file. */ #define HAVE_STRING_H 1 -/* Define to 1 if you have the `strrchr' function. */ -/* #undef HAVE_STRRCHR */ -#define HAVE_STRRCHR 1 - -/* Define to 1 if you have the `strtol' function. */ -/* #undef HAVE_STRTOL */ -#define HAVE_STRTOL 1 +/* Define to 1 if you have the `strlcat' function. */ +#define HAVE_STRLCAT 1 + +/* Define to 1 if you have the `strlcpy' function. */ +#define HAVE_STRLCPY 1 /* Define to 1 if you have the header file. */ #define HAVE_SYS_STAT_H 1 @@ -76,51 +95,61 @@ #define HAVE_SYS_TYPES_H 1 /* Define to 1 if you have that is POSIX.1 compatible. */ -/* #undef HAVE_SYS_WAIT_H */ +#define HAVE_SYS_WAIT_H 1 /* Define to 1 if you have the header file. */ #define HAVE_UNISTD_H 1 -/* Define to 1 if you have the `vfork' function. */ -/* #undef HAVE_VFORK */ -#define HAVE_VFORK 1 +/* Define to 1 if you have the `vsnprintf' function. */ +#define HAVE_VSNPRINTF 1 -/* Define to 1 if you have the header file. */ -/* #undef HAVE_VFORK_H */ +/* Define if host is BIG endian */ +/* #undef HOST_BIG_ENDIAN */ -/* Define to 1 if you have the `vprintf' function. */ -/* #undef HAVE_VPRINTF */ -#define HAVE_VPRINTF 1 +/* Define if host is LITTLE endian */ +#define HOST_LITTLE_ENDIAN -/* Define to 1 if `fork' works. */ -/* #undef HAVE_WORKING_FORK */ +/* lex is flex */ +#define ISFLEX 1 -/* Define to 1 if `vfork' works. */ -/* #undef HAVE_WORKING_VFORK */ +/* Define alternate standard lib directory */ +/* #undef LIBDIR */ -/* Define to 1 if the system has the type `_Bool'. */ -/* #undef HAVE__BOOL */ +/* Define path to alternate linker */ +/* #undef LINKER */ -/* Name of package */ -/* #undef PACKAGE */ +/* Using Mach-O ABI */ +/* #undef MACHOABI */ /* Define to the address where bug reports for this package should be sent. */ -#define PACKAGE_BUGREPORT "BUG-REPORT-ADDRESS" +#define PACKAGE_BUGREPORT "" /* Define to the full name of this package. */ #define PACKAGE_NAME "pcc" /* Define to the full name and version of this package. */ -#define PACKAGE_STRING "pcc 0.9.8" +#define PACKAGE_STRING "pcc 0.9.9" /* Define to the one symbol short name of this package. */ #define PACKAGE_TARNAME "pcc" /* Define to the version of this package. */ -#define PACKAGE_VERSION "0.9.8" +#define PACKAGE_VERSION "0.9.9" + +/* Major version no */ +#define PCC_MAJOR 0 -/* Define as the return type of signal handlers (`int' or `void'). */ -/* #undef RETSIGTYPE */ +/* Minor version no */ +#define PCC_MINOR 9 + +/* Minor minor version no */ +#define PCC_MINORMINOR 9 + +/* Using PE/COFF ABI */ +/* #undef PECOFFABI */ + +/* Define path to alternate preprocessor */ +/* #undef PREPROCESSOR */ /* If using the C implementation of alloca, define if you know the direction of stack growth for your system; otherwise it will be @@ -133,30 +162,24 @@ /* Define to 1 if you have the ANSI C header files. */ #define STDC_HEADERS 1 -/* Version number of package */ -#define PCC_MAJOR 0 -#define PCC_MINOR 9 -#define PCC_MINORMINOR 8 -#define VERSSTR "pcc 0.9.8 for i386-unknown-midnightbsd0.2, laffer1 at m5.midnightbsd.org Wed Sep 26 15:13:33 EDT 2007" - -/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a - `char[]'. */ -#define YYTEXT_POINTER 1 - -/* Define to rpl_malloc if the replacement function should be used. */ -/* #undef malloc */ +/* Define alternate standard include directory */ +/* #undef STDINC */ -/* Define to `int' if does not define. */ -/* #undef pid_t */ +/* Define if target defaults to BIG endian */ +/* #undef TARGET_BIG_ENDIAN */ -/* Define as `fork' if `vfork' does not work. */ -/* #undef vfork */ +/* Define if target defaults to LITTLE endian */ +#define TARGET_LITTLE_ENDIAN 1 -/* target operating system */ +/* Target OS */ #define TARGOS midnightbsd -/* mkstemp() */ -#define HAVE_MKSTEMP 1 +/* Enable thread-local storage (TLS). */ +/* #undef TLS */ -/* which lex is used */ -#define ISFLEX 1 +/* Version string */ +#define VERSSTR "pcc 0.9.9 for i386-unknown-midnightbsd0.3, root at defiant.midnightbsd.org Tue Jan 20 15:33:42 EST 2009" + +/* Define to 1 if `lex' declares `yytext' as a `char *' by default, not a + `char[]'. */ +#define YYTEXT_POINTER 1 --- /dev/null +++ usr.bin/pcc/sparc64/order.c @@ -0,0 +1,112 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass2.h" + +int +notoff(TWORD t, int r, CONSZ off, char *cp) +{ + return 0; +} + +/* + * Turn a UMUL-referenced node into OREG. + */ +void +offstar(NODE *p, int shape) +{ + if (x2debug) + printf("offstar(%p)\n", p); + + if (p->n_op == PLUS || p->n_op == MINUS) { + if (p->n_right->n_op == ICON) { + if (isreg(p->n_left) == 0) + (void)geninsn(p->n_left, INAREG); + /* Converted in ormake() */ + return; + } + } + (void)geninsn(p, INAREG); +} + +void +myormake(NODE *q) +{ +} + +int +shumul(NODE *p, int shape) +{ + if (shape & SOREG) + return SROREG; + return SRNOPE; +} + +int +setbin(NODE *p) +{ + return 0; +} + +int +setasg(NODE *p, int cookie) +{ + return 0; +} + +int +setuni(NODE *p, int cookie) +{ + return 0; +} + +struct rspecial * +nspecial(struct optab *q) +{ + switch (q->op) { + case STASG: { + static struct rspecial s[] = { + { NEVER, O0 }, + { NRIGHT, O1 }, + { NEVER, O2 }, + { 0 } + }; + return s; + } + } + + comperr("unknown nspecial %d: %s", q - table, q->cstring); + return 0; /* XXX */ +} + +int +setorder(NODE *p) +{ + return 0; +} + +int * +livecall(NODE *p) +{ + static int ret[] = { O0, O1, O2, O3, O4, O5, O6, O7, -1 }; + return ret; +} + +int +acceptable(struct optab *op) +{ + return 1; +} --- /dev/null +++ usr.bin/pcc/sparc64/macdefs.h @@ -0,0 +1,267 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + + +/* + * Many arithmetic instructions take 'reg_or_imm' in SPARCv9, where imm + * means we can use a signed 13-bit constant (simm13). This gives us a + * shortcut for small constants, instead of loading them into a register. + * Special handling is required because 13 bits lies between SSCON and SCON. + */ +#define SIMM13(val) (val < 4096 && val > -4097) + +/* + * The SPARCv9 ABI specifies a stack bias of 2047 bits. This means that the + * end of our call space is %fp+V9BIAS, working back towards %sp+V9BIAS+176. + */ +#define V9BIAS 2047 + +/* + * The ABI requires that every frame reserve 176 bits for saving registers + * in the case of a spill. The stack size must be 16-bit aligned. + */ +#define V9RESERVE 176 +#define V9STEP(x) ALIGN(x, 0xf) +#define ALIGN(x, y) ((x & y) ? (x + y) & ~y : x) + + +#define makecc(val,i) lastcon = (lastcon<<8)|((val<<24)>>24); + +#define ARGINIT (7*8) /* XXX */ +#define AUTOINIT (0) + +/* Type sizes */ +#define SZCHAR 8 +#define SZBOOL 32 +#define SZINT 32 +#define SZFLOAT 32 +#define SZDOUBLE 64 +#define SZLDOUBLE 64 +#define SZLONG 64 +#define SZSHORT 16 +#define SZLONGLONG 64 +#define SZPOINT(t) 64 + +/* Type alignments */ +#define ALCHAR 8 +#define ALBOOL 32 +#define ALINT 32 +#define ALFLOAT 32 +#define ALDOUBLE 64 +#define ALLDOUBLE 64 +#define ALLONG 64 +#define ALLONGLONG 64 +#define ALSHORT 16 +#define ALPOINT 64 +#define ALSTRUCT 32 +#define ALSTACK 64 + +/* Min/max values. */ +#define MIN_CHAR -128 +#define MAX_CHAR 127 +#define MAX_UCHAR 255 +#define MIN_SHORT -32768 +#define MAX_SHORT 32767 +#define MAX_USHORT 65535 +#define MIN_INT -1 +#define MAX_INT 0x7fffffff +#define MAX_UNSIGNED 0xffffffff +#define MIN_LONGLONG 0x8000000000000000LL +#define MAX_LONGLONG 0x7fffffffffffffffLL +#define MAX_ULONGLONG 0xffffffffffffffffULL +#define MIN_LONG MIN_LONGLONG +#define MAX_LONG MAX_LONGLONG +#define MAX_ULONG MAX_ULONGLONG + +#define BOOL_TYPE INT +#define WCHAR_TYPE INT + +typedef long long CONSZ; +typedef unsigned long long U_CONSZ; +typedef long long OFFSZ; + +#define CONFMT "%lld" +#define LABFMT "L%d" +#define STABLBL "LL%d" + +#define BACKAUTO /* Stack grows negatively for automatics. */ +#define BACKTEMP /* Stack grows negatively for temporaries. */ + +#undef FIELDOPS +#define RTOLBYTES + +#define ENUMSIZE(high,low) INT +#define BYTEOFF(x) ((x)&03) +#define BITOOR(x) (x) + +#define szty(t) ((ISPTR(t) || (t) == DOUBLE || \ + (t) == LONG || (t) == ULONG || \ + (t) == LONGLONG || (t) == ULONGLONG) ? 2 : 1) + + +/* Register names. */ + +#define MAXREGS (31 + 31 + 16 + 2) +#define NUMCLASS 4 + +//define G0 -1 +#define G1 0 +#define G2 1 +#define G3 2 +#define G4 3 +#define G5 4 +#define G6 5 +#define G7 6 +#define O0 7 +#define O1 8 +#define O2 9 +#define O3 10 +#define O4 11 +#define O5 12 +#define O6 13 +#define O7 14 +#define L0 15 +#define L1 16 +#define L2 17 +#define L3 18 +#define L4 19 +#define L5 20 +#define L6 21 +#define L7 22 +#define I0 23 +#define I1 24 +#define I2 25 +#define I3 26 +#define I4 27 +#define I5 28 +#define I6 29 +#define I7 30 + +#define F0 31 +#define F1 32 +#define F2 33 +#define F3 34 +#define F4 35 +#define F5 36 +#define F6 37 +#define F7 38 +#define F8 39 +#define F9 40 +#define F10 41 +#define F11 42 +#define F12 43 +#define F13 44 +#define F14 45 +#define F15 46 +#define F16 47 +#define F17 48 +#define F18 49 +#define F19 50 +#define F20 51 +#define F21 52 +#define F22 53 +#define F23 54 +#define F24 55 +#define F25 56 +#define F26 57 +#define F27 58 +#define F28 59 +#define F29 60 +#define F30 61 +//define F31 XXX +#define D0 62 +#define D1 63 +#define D2 64 +#define D3 65 +#define D4 66 +#define D5 67 +#define D6 68 +#define D7 69 +#define D8 70 +#define D9 71 +#define D10 72 +#define D11 73 +#define D12 74 +#define D13 75 +#define D14 76 +#define D15 77 + +#define SP 78 +#define FP 79 + +#define FPREG FP + +#define RETREG(x) ((x)==DOUBLE ? D0 : (x)==FLOAT ? F1 : O0) +#define RETREG_PRE(x) ((x)==DOUBLE ? D0 : (x)==FLOAT ? F1 : I0) + +#define RSTATUS \ + /* global */ \ + SAREG|PERMREG, SAREG|PERMREG, SAREG|PERMREG, \ + SAREG|PERMREG, SAREG|PERMREG, SAREG|PERMREG, SAREG|PERMREG, \ + /* out */ \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + /* local */ \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + /* in */ \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, SAREG|TEMPREG, \ + /* 32-bit floating point */ \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, \ + SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, SBREG, /*, SBREG */ \ + /* 64-bit floating point */ \ + SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, \ + SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, SCREG, \ + /* sp */ SDREG, \ + /* fp */ SDREG + +#define ROVERLAP \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ + { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, { -1 }, \ +/* 32-bit floating point */ \ + { D0, -1 }, { D0, -1 }, { D1, -1 }, { D1, -1 }, \ + { D2, -1 }, { D2, -1 }, { D3, -1 }, { D3, -1 }, \ + { D4, -1 }, { D4, -1 }, { D5, -1 }, { D5, -1 }, \ + { D6, -1 }, { D6, -1 }, { D7, -1 }, { D7, -1 }, \ + { D8, -1 }, { D8, -1 }, { D9, -1 }, { D9, -1 }, \ + { D10, -1 }, { D10, -1 }, { D11, -1 }, { D11, -1 }, \ + { D12, -1 }, { D12, -1 }, { D13, -1 }, { D13, -1 }, \ + { D14, -1 }, { D14, -1 }, { D15, -1 }, /* { D15, -1 }, */ \ +/* 64-bit floating point */ \ + { F0, F1, -1 }, { F2, F3, -1 }, { F4, F5, -1 }, \ + { F6, F7, -1 }, { F8, F9, -1 }, { F10, F11, -1 }, \ + { F12, F13, -1 }, { F14, F15, -1 }, { F16, F17, -1 }, \ + { F18, F19, -1 }, { F20, F21, -1 }, { F22, F23, -1 }, \ + { F24, F25, -1 }, { F26, F27, -1 }, { F28, F29, -1 }, \ + { F30, /* F31, */ -1 }, \ + { -1 }, \ + { -1 } + +#define GCLASS(x) (x <= I7 ? CLASSA : \ + (x <= F30 ? CLASSB : \ + (x <= D15 ? CLASSC : \ + (x == SP || x == FP ? CLASSD : 0)))) +#define PCLASS(p) (1 << gclass((p)->n_type)) +#define DECRA(x,y) (((x) >> (y*7)) & 127) +#define ENCRA(x,y) ((x) << (7+y*7)) +#define ENCRD(x) (x) + +int COLORMAP(int c, int *r); --- /dev/null +++ usr.bin/pcc/sparc64/table.c @@ -0,0 +1,963 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass2.h" + +#define TS64 TLONG|TLONGLONG +#define TU64 TULONG|TULONGLONG|TPOINT +#define T64 TS64|TU64 + +struct optab table[] = { + +{ -1, FOREFF, SANY, TANY, SANY, TANY, 0, 0, "", }, /* empty */ + +{ PCONV, INAREG, + SAREG, T64|TINT, + SAREG, T64, + 0, RLEFT, + " ! convert between word and pointer\n", }, + +/* Conversions. */ + +{ SCONV, INAREG, + SAREG, T64|TUNSIGNED, + SAREG, TINT, + NAREG|NASL, RESC1, + " sra AL,0,A1 \t\t! (u)int64/32 -> (u)int32\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED, + SAREG, TSHORT, + NAREG|NASL, RESC1, + " sll AL,16,A1 \t\t! (u)int64/32 -> int16\n" + " sra AL,16,A1\n" + " sra AL, 0,A1\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED, + SAREG, TUSHORT, + NAREG|NASL, RESC1, + " sll AL,16,A1 \t\t! (u)int64/32 -> uint16\n" + " srl AL,16,A1\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED|TSHORT|TUSHORT, + SAREG, TCHAR, + NAREG|NASL, RESC1, + " sll AL,24,A1 \t\t! (u)int64/32/16 -> int8\n" + " sra AL,24,A1\n" + " sra AL, 0,A1\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED|TSHORT|TUSHORT, + SAREG, TUCHAR, + NAREG|NASL, RESC1, + " and AL,0xff,A1 \t\t! (u)int64/32/16 -> uint8\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TUNSIGNED|TSHORT|TUSHORT, + SAREG, T64, + 0, RLEFT, + " \t\t! (u)int64...8 -> (u)int64\n", }, + +{ SCONV, INAREG, + SAREG, TSHORT|TUSHORT|TCHAR|TUCHAR, + SAREG, TINT, + 0, RLEFT, + " \t\t! (u)int16/8 -> int32\n", }, + +{ SCONV, INAREG, + SAREG, T64|TINT|TSHORT|TCHAR, + SAREG, TUNSIGNED, + 0, RLEFT, + " srl AL, 0,A1 \t\t! int32/16/8 -> uint32\n", }, + +{ SCONV, INAREG, + SAREG, TUSHORT|TUCHAR, + SAREG, TUNSIGNED, + 0, RLEFT, + " \t\t! uint16/8 -> uint32\n", }, + +{ SCONV, INBREG, + SBREG, TINT|TUNSIGNED, + SBREG, TFLOAT, + NBREG|NASL, RESC1, + " fitos AL,A1 \t\t! (u)int32 -> float\n", }, + +{ SCONV, INBREG, + SBREG, T64, + SBREG, TFLOAT, + NBREG|NASL, RESC1, + " fxtos AL,A1 \t\t! (u)int64 -> float\n", }, + +{ SCONV, INCREG, + SCREG, TINT|TUNSIGNED, + SCREG, TDOUBLE, + NCREG|NASL, RESC1, + " fitod AL,A1 \t\t! (u)int32 -> double\n", }, + +{ SCONV, INCREG, + SCREG, T64, + SCREG, TDOUBLE, + NCREG|NASL, RESC1, + " fxtod AL,A1 \t\t! (u)int64 -> double\n", }, + + +/* Floating-point conversions must be stored and loaded. */ + +{ SCONV, INAREG, + SOREG, TFLOAT, + SAREG, TINT, + NAREG|(2*NBREG), RESC1, + " ld [AL],A2 \t\t! float -> int32\n" + " nop\n" + " fmovs A2,A3\n" + " fstoi A2,A2\n" + " st A2,[AL]\n" + " nop\n" + " ld [AL],A1\n" + " nop\n" + " st A3,[AL]\n" + " nop\n", }, + +{ SCONV, INAREG, + SOREG, TDOUBLE, + SAREG, TINT, + NAREG|(2*NCREG), RESC1, + " ld [AL],A2 \t\t! double -> int32\n" + " nop\n" + " fmovd A2,A3\n" + " fdtoi A2,A2\n" + " std A2,[AL]\n" + " nop\n" + " ldd [AL],A1\n" + " nop\n" + " std A3,[AL]\n" + " nop\n", }, + +{ SCONV, INBREG, + SOREG, T64|TUNSIGNED, + SBREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 \t\t! int64 -> float\n" + " fxtos A1,A1\n", }, + +{ SCONV, INBREG, + SOREG, TINT|TSHORT|TCHAR, + SBREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 \t\t! int32/16/8 -> float\n" + " fitos A1,A1\n", }, // XXX need 'lds', 'ldh', etc + +{ SCONV, INCREG, + SOREG, T64|TUNSIGNED, + SCREG, TDOUBLE, + NCREG, RESC1, + " ldd [AL],A1 \t\t! (u)int64 -> double\n" + " fxtod A1,A1\n", }, + +{ SCONV, INCREG, + SOREG, TINT|TSHORT|TCHAR, + SCREG, TDOUBLE, + NCREG, RESC1, + " ld [AL],A1 \t\t! int32/16/8 -> double\n" + " fitod A1,A1\n", }, // XXX need 'lds' 'ldh' 'ld', etc. + +{ SCONV, INBREG, + SCREG, TDOUBLE, + SBREG, TFLOAT, + NBREG, RESC1, + " fdtos AL,A1 \t\t! double -> float\n",}, + +{ SCONV, INCREG, + SBREG, TFLOAT, + SCREG, TDOUBLE, + NCREG, RESC1, + " fstod AL,A1 \t\t! float -> double\n",}, + +{ SCONV, INAREG, + SBREG, TFLOAT, + SAREG, TINT, + NAREG|NBREG, RESC1, + " fstoi AL,A2 \t\t! float -> int\n" + " st A2,[%fp+2047]\n" + " nop\n" + " ld [%fp+2047],A1\n" + " nop\n",}, + +{ SCONV, INAREG, + SCREG, TDOUBLE, + SAREG, TINT, + NAREG|NCREG, RESC1, + " fdtoi AL,A2 \t\t! double -> int\n" + " st A2,[%fp+2047]\n" + " nop\n" + " ld [%fp+2047],A1\n" + " nop\n",}, + + +/* Multiplication and division */ + +{ MUL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASR|NASL, RESC1, + " mulx AL,AR,A1 ! multiply\n", }, + +{ MUL, INBREG, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG|NBSR|NBSL, RESC1, + " fmuls AL,AR,A1 ! multiply float\n", }, + +{ MUL, INCREG, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG|NCSR|NCSL, RESC1, + " fmuld AL,AR,A1 ! multiply double\n", }, + +{ DIV, INAREG, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + NAREG|NASR|NASL, RESC1, + " udivx AL,AR,A1 ! unsigned division\n", }, + +{ DIV, INAREG, + SAREG, TINT|TSHORT|TCHAR|TS64, + SAREG, TINT|TSHORT|TCHAR|TS64, + NAREG|NASR|NASL, RESC1, + " sdivx AL,AR,A1 ! signed division\n", }, + +{ DIV, INBREG, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG|NBSR|NBSL, RESC1, + " fdivs AL,AR,A1 ! divide float\n", }, + +{ DIV, INCREG, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG|NCSR|NCSL, RESC1, + " fdivd AL,AR,A1 ! divide double\n", }, + +{ MOD, INAREG, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + SAREG, TUNSIGNED|TUSHORT|TUCHAR|TU64, + NAREG, RESC1, + " udivx AL,AR,A1 ! unsigned modulo\n" + " mulx A1,AR,A1\n" + " sub AL,A1,A1\n", }, + +{ MOD, INAREG, + SAREG, TINT|TSHORT|TCHAR|TS64, + SAREG, TINT|TSHORT|TCHAR|TS64, + NAREG, RESC1, + " sdivx AL,AR,A1 ! signed modulo\n" + " mulx A1,AR,A1\n" + " sub AL,A1,A1\n", }, + +{ PLUS, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASL, RESC1, + " add AL,AR,A1\n", }, + +{ PLUS, INBREG, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG|NBSL, RESC1, + " fadds AL,AR,A1\n", }, + +{ PLUS, INCREG, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG|NCSL, RESC1, + " faddd AL,AR,A1\n", }, + +{ PLUS, INAREG, + SAREG, TANY, + SCON, TANY, + (3*NAREG)|NASL, RESC1, + "ZA", }, + +{ MINUS, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASL, RESC1, + " sub AL,AR,A1\n", }, + +{ MINUS, INBREG, + SBREG, TANY, + SBREG, TANY, + NBREG|NBSL|NBSR, RESC1, + " fsubs AL,AR,A1\n", }, + +{ MINUS, INCREG, + SCREG, TANY, + SCREG, TANY, + NCREG|NCSL|NBSR, RESC1, + " fsubd AL,AR,A1\n", }, + +{ MINUS, INAREG, + SAREG, TANY, + SCON, TANY, + (3*NAREG)|NASL, RESC1, + "ZB", }, + +{ UMINUS, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, + " sub %g0,AL,A1\n", }, + +{ UMINUS, INBREG, + SBREG, TANY, + SANY, TANY, + NBREG|NBSL, RESC1, + " fsubs %g0,AL,A1\n", }, + +{ UMINUS, INCREG, + SCREG, TANY, + SANY, TANY, + NCREG|NCSL, RESC1, + " fsubd %g0,AL,A1\n", }, + +/* Shifts */ + +{ RS, INAREG, + SAREG, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + SAREG|SCON, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " sra AL,AR,A1 ! shift right\n", }, + +{ RS, INAREG, + SAREG, T64, + SAREG|SCON, T64|TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " srax AL,AR,A1 ! shift right\n", }, + +{ LS, INAREG, + SAREG, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + SAREG|SCON, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " sll AL,AR,A1 ! shift left\n", }, + +{ LS, INAREG, + SAREG, T64, + SAREG|SCON, TINT|TUNSIGNED|TSHORT|TUSHORT|TCHAR|TUCHAR, + NAREG|NASL, RESC1, + " sllx AL,AR,A1 ! shift left\n", }, + +{ COMPL, INAREG, + SAREG, TANY, + SANY, TANY, + NAREG|NASL, RESC1, + " orn AL,%g0,A1 ! complement\n", }, + +/* Assignments */ + +{ ASSIGN, FOREFF|INAREG, + SOREG, TINT|TUNSIGNED, + SAREG, TINT|TUNSIGNED, + 0, RDEST, + " stw AR,[AL] ! store (u)int32\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SOREG, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + 0, RDEST, + " sth AR,[AL] ! store (u)int16\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SOREG, TCHAR|TUCHAR, + SAREG, TCHAR|TUCHAR, + 0, RDEST, + " stb AR,[AL] ! store (u)int8\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SOREG, T64, + SAREG, T64, + 0, RDEST, + " stx AR,[AL] ! store (u)int64\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INBREG, + SOREG, TFLOAT, + SBREG, TFLOAT, + 0, RDEST, + " st AR,[AL] ! store float\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INBREG, + SOREG, TINT, + SBREG, TINT, + 0, RDEST, + " st AR,[AL] ! store int from fp address\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SOREG, TDOUBLE, + SCREG, TDOUBLE, + 0, RDEST, + " std AR,[AL] ! store double\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SOREG, TINT, + SCREG, TINT, + 0, RDEST, + " st AR,[AL] ! store int from fp address\n" + " nop\n", }, + + +{ ASSIGN, FOREFF|INAREG, + SNAME, TINT|TUNSIGNED, + SAREG, TINT|TUNSIGNED, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int32 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " stw AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SNAME, TSHORT|TUSHORT, + SAREG, TSHORT|TUSHORT, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int16 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " sth AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SNAME, TCHAR|TUCHAR, + SAREG, TCHAR|TUCHAR, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int8 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " stb AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SNAME, T64, + SAREG, T64, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store (u)int64 into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " stx AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INBREG, + SNAME, TFLOAT|TINT, + SBREG, TFLOAT|TINT, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store float into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " st AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SNAME, TDOUBLE, + SCREG, TDOUBLE, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store double into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " std AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INCREG, + SNAME, TINT, + SCREG, TINT, + NAREG, RDEST, + " sethi %h44(AL),A1 \t! store int into sname\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " st AR,[A1+%l44(AL)]\n" + " nop\n", }, + +{ ASSIGN, FOREFF|INAREG, + SAREG, TANY, + SAREG, TANY, + 0, RDEST, + " mov AR,AL ! register move\n", }, + +{ ASSIGN, FOREFF|INBREG, + SBREG, TANY, + SBREG, TANY, + 0, RDEST, + " fmovs AR,AL ! move float\n", }, + +{ ASSIGN, FOREFF|INCREG, + SCREG, TANY, + SCREG, TANY, + 0, RDEST, + " fmovd AR,AL ! move double\n", }, + +/* Structure assignment. */ + +{ STASG, INAREG|FOREFF, + SOREG|SNAME, TANY, + SAREG, TPTRTO|TANY, + NSPECIAL, RRIGHT, + "ZQ", }, + +/* Comparisons. */ + +{ EQ, FORCC, + SAREG, TANY, + SAREG, TANY, + 0, RESCC, + " cmp AL,AR\n" + " be LC\n" + " nop\n", }, + +{ NE, FORCC, + SAREG, TANY, + SAREG, TANY, + 0, RESCC, + " cmp AL,AR\n" + " bne LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SAREG, TANY, + SZERO, TANY, + 0, RESCC, + " O AL,LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SAREG, TANY, + SAREG, TANY, + NAREG|NASL, RESCC, + " sub AL,AR,A1 ! oplog\n" + " O A1,LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SAREG, TANY, + SCCON, TANY, + NAREG|NASL, RESCC, + " sub AL,AR,A1 ! oplog sccon\n" + " O A1,LC\n" + " nop\n", }, + +{ OPLOG, FORCC, + SBREG, TFLOAT, + SBREG, TFLOAT, + NBREG, RESCC, + " fcmps AL,AR ! oplog float\n" + " ZF LC\n", }, + +{ OPLOG, FORCC, + SOREG, TFLOAT, + SBREG, TFLOAT, + NBREG, RESCC, + " ld [AL], A1 ! oplog float oreg\n" + " nop\n" + " fcmps A1,AR\n" + " ZF LC\n", }, + +{ OPLOG, FORCC, + SCREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG, RESCC, + " fcmpd AL,AR ! oplog double\n" + " ZF LC\n", }, + +{ OPLOG, FORCC, + SOREG, TDOUBLE, + SCREG, TDOUBLE, + NCREG, RESCC, + " ldd [AL], A1 ! oplog double oreg\n" + " nop\n" + " fcmpd A1,AR\n" + " ZF LC\n", }, + + +/* Load constants to register. */ + +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, T64, + NAREG, RESC1, + " sethi %h44(AL),A1\t ! load const (u)int64 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldx [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TINT, + NAREG, RESC1, + " sethi %h44(AL),A1\t ! load const int32 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldsw [A1+%l44(AL)],A1\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TUNSIGNED, + NAREG, RESC1, + " sethi %h44(AL),A1\t! load const uint32 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " lduw [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TSHORT, + NAREG, RESC1, + " sethi %h44(AL),A1\t! load const int16 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldsh [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TUSHORT, + NAREG, RESC1, + " sethi %h44(AL),A1\t ! load const uint16 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " lduh [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TCHAR, + NAREG, RESC1, + " sethi %h44(AL),A1\t\t! load const int8 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldsb [A1+%l44(AL)],A1\n" + " nop\n", }, +{ OPLTYPE, INAREG, + SCON, TANY, + SNAME, TUCHAR, + NAREG, RESC1, + " sethi %h44(AL),A1\t! load const uint8 to reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldub [A1+%l44(AL)],A1\n" + " nop\n", }, + +{ OPLTYPE, INBREG, + SBREG, TANY, + SNAME, TANY, + NAREG|NBREG, RESC2, + " sethi %h44(AL),A1\t\t! load const to fp reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ld [A1+%l44(AL)],A2\n" + " nop\n", }, + +{ OPLTYPE, INCREG, + SCREG, TANY, + SNAME, TANY, + NAREG|NCREG, RESC2, + " sethi %h44(AL),A1\t\t! load const to fp reg\n" + " or A1,%m44(AL),A1\n" + " sllx A1,12,A1\n" + " ldd [A1+%l44(AL)],A2\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SCON, TANY, + (2*NAREG), RESC1, + "ZC" }, + +/* Convert LTYPE to reg. */ + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TCHAR, + NAREG, RESC1, + " ldsb [AL],A1 ! load int8 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TUCHAR, + NAREG, RESC1, + " ldub [AL],A1 ! load uint8 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TSHORT, + NAREG, RESC1, + " ldsh [AL],A1 ! load int16 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TUSHORT, + NAREG, RESC1, + " lduh [AL],A1 ! load uint16 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TINT, + NAREG, RESC1, + " ldsw [AL],A1 ! load int32 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, TUNSIGNED, + NAREG, RESC1, + " lduw [AL],A1 ! load uint32 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SAREG, TANY, + SOREG, T64, + NAREG, RESC1, + " ldx [AL],A1 ! load (u)int64 to reg\n" + " nop\n", }, + +{ OPLTYPE, INAREG, + SANY, TANY, + SZERO, TANY, + NAREG, RESC1, + " mov \%g0,A1\t ! load 0 to reg\n", }, + +{ OPLTYPE, INBREG, + SBREG, TFLOAT, + SOREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 ! load float to reg\n" + " nop\n", }, + +{ OPLTYPE, INCREG, + SCREG, TDOUBLE, + SOREG, TDOUBLE, + NCREG, RESC1, + " ldd [AL],A1 ! load double to reg\n" + " nop\n", }, + +/* Jumps. */ + +{ GOTO, FOREFF, + SCON, TANY, + SANY, TANY, + 0, RNOP, + " call LL ! goto LL\n" + " nop\n", }, + +{ UCALL, FOREFF, + SCON, TANY, + SANY, TANY, + 0, 0, + " call CL ! void CL()\n" + " nop\n", }, + +{ UCALL, INAREG, + SCON, TANY, + SAREG, TANY, + NAREG, RESC1, + " call CL ! = CL()\n" + " nop\n", }, + +{ CALL, FOREFF, + SCON, TANY, + SANY, TANY, + 0, 0, + " call CL ! void CL(constant)\n" + " nop\n", }, + +{ CALL, INAREG, + SCON, TANY, + SAREG, TANY, + NAREG, RESC1, + " call CL ! = CL(constant)\n" + " nop\n", }, + +{ CALL, INBREG, + SCON, TANY, + SBREG, TFLOAT, + NBREG, RESC1, + " call CL ! = CL(constant)\n" + " nop\n", }, + +{ CALL, INCREG, + SCON, TANY, + SCREG, TDOUBLE, + NCREG, RESC1, + " call CL ! = CL(constant)\n" + " nop\n", }, + +{ CALL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG, RESC1, + " call AL ! = AL(args)\n" + " nop\n", }, + +{ CALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call AL ! void AL(args)\n" + " nop\n", }, + +{ UCALL, FOREFF, + SAREG, TANY, + SANY, TANY, + 0, 0, + " call AL ! (*AL)()\n" + " nop\n", }, + +{ UCALL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG, RESC1, + " call AL ! = (*AL)()\n" + " nop\n", }, + +{ CALL, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG, RESC1, + " call AL ! = (*AL)(args)\n" + " nop\n", }, + +/* Function arguments. */ + +{ FUNARG, FOREFF, + SAREG, T64, + SANY, TANY, + 0, 0, + " stx AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SAREG, TINT|TUNSIGNED, + SANY, TANY, + 0, 0, + " stw AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SAREG, TSHORT|TUSHORT, + SANY, TANY, + 0, 0, + " sth AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SAREG, TCHAR|TUCHAR, + SANY, TANY, + 0, 0, + " stb AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SBREG, TFLOAT, + SANY, TANY, + 0, 0, + " st AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + +{ FUNARG, FOREFF, + SCREG, TDOUBLE, + SANY, TANY, + 0, 0, + " std AL,[%sp+AR] \t! save func arg to stack\n" + " nop\n", }, + + +/* Indirection. */ + +{ OPSIMP, INAREG, + SAREG, TANY, + SAREG, TANY, + NAREG|NASR|NASL, RESC1, + " O AL,AR,A1\n", }, + +{ UMUL, INAREG, + SANY, T64, + SOREG, T64, + NAREG, RESC1, + " ldx [AL],A1 ! (u)int64 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TINT, + SOREG, TINT, + NAREG, RESC1, + " ldsw [AL],A1 ! int32 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TUNSIGNED, + SOREG, TUNSIGNED, + NAREG, RESC1, + " lduw [AL],A1 ! uint32 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TCHAR, + SOREG, TCHAR, + NAREG, RESC1, + " ldsb [AL],A1 ! int8 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TUCHAR, + SOREG, TUCHAR, + NAREG, RESC1, + " ldub [AL],A1 ! uint8 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TSHORT, + SOREG, TSHORT, + NAREG, RESC1, + " ldsh [AL],A1 ! int16 load\n" + " nop\n", }, +{ UMUL, INAREG, + SANY, TUSHORT, + SOREG, TUSHORT, + NAREG, RESC1, + " lduh [AL],A1 ! uint16 load\n" + " nop\n", }, + +{ UMUL, INBREG, + SANY, TFLOAT, + SOREG, TFLOAT, + NBREG, RESC1, + " ld [AL],A1 ! load float\n" + " nop\n", }, + +{ UMUL, INCREG, + SANY, TDOUBLE, + SOREG, TDOUBLE, + NCREG, RESC1, + " ldd [AL],A1 ! load double\n" + " nop\n", }, + +{ FREE,FREE,FREE,FREE,FREE,FREE,FREE,FREE, "ERR: printing free op\n" }, + +}; + +int tablesize = sizeof(table)/sizeof(table[0]); --- /dev/null +++ usr.bin/pcc/sparc64/local2.c @@ -0,0 +1,424 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass1.h" +#include "pass2.h" + + +char * +rnames[] = { + /* "\%g0", always zero, removed due to 31-element class limit */ + "\%g1", "\%g2", "\%g3", "\%g4", "\%g5", "\%g6", "\%g7", + "\%o0", "\%o1", "\%o2", "\%o3", "\%o4", "\%o5", "\%o6", "\%o7", + "\%l0", "\%l1", "\%l2", "\%l3", "\%l4", "\%l5", "\%l6", "\%l7", + "\%i0", "\%i1", "\%i2", "\%i3", "\%i4", "\%i5", "\%i6", "\%i7", + + "\%f0", "\%f1", "\%f2", "\%f3", "\%f4", "\%f5", "\%f6", "\%f7", + "\%f8", "\%f9", "\%f10", "\%f11", "\%f12", "\%f13", "\%f14", "\%f15", + "\%f16", "\%f17", "\%f18", "\%f19", "\%f20", "\%f21", "\%f22", "\%f23", + "\%f24", "\%f25", "\%f26", "\%f27", "\%f28", "\%f29", "\%f30", + /*, "\%f31" XXX removed due to 31-element class limit */ + + "\%f0", "\%f2", "\%f4", "\%f6", "\%f8", "\%f10", "\%f12", "\%f14", + "\%f16", "\%f18", "\%f20", "\%f22", "\%f24", "\%f26", "\%f28", "\%f30", + + "\%sp", "\%fp", +}; + +void +deflab(int label) +{ + printf(LABFMT ":\n", label); +} + +void +prologue(struct interpass_prolog *ipp) +{ + int i, stack; + + stack = V9RESERVE + V9STEP(p2maxautooff); + + for (i = ipp->ipp_regs[0]; i; i >>= 1) + if (i & 1) + stack += 16; + + /* TODO printf("\t.proc %d\n"); */ + printf("\t.global %s\n", ipp->ipp_name); + printf("\t.align 4\n"); + printf("%s:\n", ipp->ipp_name); + if (SIMM13(stack)) + printf("\tsave %%sp,-%d,%%sp\n", stack); + else { + printf("\tsetx -%d,%%g4,%%g1\n", stack); + printf("\tsave %%sp,%%g1,%%sp\n"); + } +} + +void +eoftn(struct interpass_prolog *ipp) +{ + printf("\tret\n"); + printf("\trestore\n"); + printf("\t.type %s,#function\n", ipp->ipp_name); + printf("\t.size %s,(.-%s)\n", ipp->ipp_name, ipp->ipp_name); +} + +void +hopcode(int f, int o) +{ + char *str; + + switch (o) { + case EQ: str = "brz"; break; + case NE: str = "brnz"; break; + case ULE: + case LE: str = "brlez"; break; + case ULT: + case LT: str = "brlz"; break; + case UGE: + case GE: str = "brgez"; break; + case UGT: + case GT: str = "brgz"; break; + case PLUS: str = "add"; break; + case MINUS: str = "sub"; break; + case AND: str = "and"; break; + case OR: str = "or"; break; + case ER: str = "xor"; break; + default: + comperr("unknown hopcode: %d (with %c)", o, f); + return; + } + + printf("%s%c", str, f); +} + +int +tlen(NODE *p) +{ + switch (p->n_type) { + case CHAR: + case UCHAR: + return 1; + case SHORT: + case USHORT: + return (SZSHORT / SZCHAR); + case FLOAT: + return (SZFLOAT / SZCHAR); + case DOUBLE: + return (SZDOUBLE / SZCHAR); + case INT: + case UNSIGNED: + return (SZINT / SZCHAR); + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + return SZLONGLONG / SZCHAR; + default: + if (!ISPTR(p->n_type)) + comperr("tlen type unknown: %d"); + return SZPOINT(p->n_type) / SZCHAR; + } +} + +void +zzzcode(NODE * p, int c) +{ + char *str; + NODE *l, *r; + l = p->n_left; + r = p->n_right; + + switch (c) { + + case 'A': /* Add const. */ + if (ISPTR(l->n_type) && l->n_rval == FP) + r->n_lval += V9BIAS; + + if (SIMM13(r->n_lval)) + expand(p, 0, "\tadd AL,AR,A1\t\t! add const\n"); + else + expand(p, 0, "\tsetx AR,A3,A2\t\t! add const\n" + "\tadd AL,A2,A1\n"); + break; + case 'B': /* Subtract const. */ + if (ISPTR(l->n_type) && l->n_rval == FP) + r->n_lval -= V9BIAS; + + if (SIMM13(r->n_lval)) + expand(p, 0, "\tsub AL,AR,A1\t\t! subtract const\n"); + else + expand(p, 0, "\tsetx AR,A3,A2\t\t! subtract const\n" + "\tsub AL,A2,A1\n"); + break; + case 'C': /* Load constant to register. */ + if (ISPTR(p->n_type)) + expand(p, 0, + "\tsethi %h44(AL),A1\t\t! load label\n" + "\tor A1,%m44(AL),A1\n" + "\tsllx A1,12,A1\n" + "\tor A1,%l44(AL),A1\n"); + else if (SIMM13(p->n_lval)) + expand(p, 0, "\tor %g0,AL,A1\t\t\t! load const\n"); + else + expand(p, 0, "\tsetx AL,A2,A1\t\t! load const\n"); + break; + case 'F': /* Floating-point comparison, cf. hopcode(). */ + switch (p->n_op) { + case EQ: str = "fbe"; break; + case NE: str = "fbne"; break; + case ULE: + case LE: str = "fbule"; break; + case ULT: + case LT: str = "fbul"; break; + case UGE: + case GE: str = "fbuge"; break; + case UGT: + case GT: str = "fbug"; break; + /* XXX + case PLUS: str = "add"; break; + case MINUS: str = "sub"; break; + case AND: str = "and"; break; + case OR: str = "or"; break; + case ER: str = "xor"; break;*/ + default: + comperr("unknown float code: %d", p->n_op); + return; + } + printf(str); + break; + + case 'Q': /* Structure assignment. */ + /* TODO Check if p->n_stsize is small and use a few ldx's + to move the struct instead of memcpy. The equiv. + could be done on all the architectures. */ + if (l->n_rval != O0) + printf("\tmov %s,%s\n", rnames[l->n_rval], rnames[O0]); + if (SIMM13(p->n_stsize)) + printf("\tor %%g0,%d,%%o2\n", p->n_stsize); + else + printf("\tsetx %d,%%g1,%%o2\n", p->n_stsize); + printf("\tcall memcpy\t\t\t! struct assign (dest, src, len)\n"); + printf("\tnop\n"); + break; + default: + cerror("unknown zzzcode call: %c", c); + } +} + +int +rewfld(NODE * p) +{ + return (1); +} + +int +fldexpand(NODE *p, int cookie, char **cp) +{ + printf("XXX fldexpand called\n"); /* XXX */ + return 1; +} + +int +flshape(NODE * p) +{ + return SRREG; +} + +int +shtemp(NODE * p) +{ + return 0; +} + + +void +adrcon(CONSZ val) +{ +} + +void +conput(FILE * fp, NODE * p) +{ + if (p->n_op != ICON) { + comperr("conput got bad op: %s", copst(p->n_op)); + return; + } + + if (p->n_name[0] != '\0') { + fprintf(fp, "%s", p->n_name); + if (p->n_lval > 0) + fprintf(fp, "+"); + if (p->n_lval) + fprintf(fp, "%lld", p->n_lval); + } else + fprintf(fp, CONFMT, p->n_lval); +} + +void +insput(NODE * p) +{ + comperr("insput"); +} + +void +upput(NODE *p, int size) +{ + comperr("upput"); +} + +void +adrput(FILE * io, NODE * p) +{ + int64_t off; + + if (p->n_op == FLD) { + printf("adrput a FLD\n"); + p = p->n_left; + } + + if (p->n_op == UMUL && p->n_right == 0) + p = p->n_left; + + off = p->n_lval; + + switch (p->n_op) { + case NAME: + if (p->n_name[0] != '\0') + fputs(p->n_name, io); + if (off > 0) + fprintf(io, "+"); + if (off != 0) + fprintf(io, CONFMT, off); + return; + case OREG: + fprintf(io, "%s", rnames[p->n_rval]); + if (p->n_rval == FP) + off += V9BIAS; + if (p->n_rval == SP) + off += V9BIAS + V9RESERVE; + if (off > 0) + fprintf(io, "+"); + if (off) + fprintf(io, "%lld", off); + return; + case ICON: + /* addressable value of the constant */ + conput(io, p); + return; + case REG: + fputs(rnames[p->n_rval], io); + return; + case FUNARG: + /* We do something odd and store the stack offset in n_rval. */ + fprintf(io, "%d", V9BIAS + V9RESERVE + p->n_rval); + return; + default: + comperr("bad address, %s, node %p", copst(p->n_op), p); + return; + } +} + +void +cbgen(int o, int lab) +{ +} + +void +myreader(struct interpass * ipole) +{ +} + +void +mycanon(NODE * p) +{ +} + +void +myoptim(struct interpass * ipole) +{ +} + +void +rmove(int s, int d, TWORD t) +{ + printf("\t"); + + if (t == FLOAT) printf("fmovs"); + else if (t == DOUBLE) printf("fmovd"); + else printf("mov"); + + printf(" %s,%s\t\t\t! rmove()\n", rnames[s], rnames[d]); +} + +int +gclass(TWORD t) +{ + if (t == FLOAT) + return CLASSB; + if (t == DOUBLE) + return CLASSC; + return CLASSA; +} + +void +lastcall(NODE *p) +{ +} + +int +special(NODE *p, int shape) +{ + return SRNOPE; +} + +void mflags(char *str) +{ +} + +int +COLORMAP(int c, int *r) +{ + int num=0; + + switch (c) { + case CLASSA: + num += r[CLASSA]; + return num < 32; + case CLASSB: + num += r[CLASSB]; + num += 2*r[CLASSC]; + return num < 32;; + case CLASSC: + num += r[CLASSC]; + num += 2*r[CLASSB]; + return num < 17; + case CLASSD: + return 0; + default: + comperr("COLORMAP: unknown class: %d", c); + return 0; + } +} +/* + * Do something target-dependent for xasm arguments. + * Supposed to find target-specific constraints and rewrite them. + */ +int +myxasm(struct interpass *ip, NODE *p) +{ + return 0; +} --- /dev/null +++ usr.bin/pcc/sparc64/code.c @@ -0,0 +1,237 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass1.h" + +void +defloc(struct symtab *sp) +{ + static char *loctbl[] = { "text", "data", "rodata" }; + static int lastloc = -1; + TWORD t; + int s; + + t = sp->stype; + s = ISFTN(t) ? PROG : ISCON(cqual(t, sp->squal)) ? RDATA : DATA; + if (s != lastloc) + printf("\n\t.section \".%s\"\n", loctbl[s]); + lastloc = s; + if (s == PROG) + return; + + switch (DEUNSIGN(sp->stype)) { + case CHAR: s = 1; + case SHORT: s = 2; + case INT: + case UNSIGNED: s = 4; + default: s = 8; + } + printf("\t.align %d\n", s); + + if (sp->sclass == EXTDEF) + printf("\t.global %s\n", sp->soname); + if (sp->slevel == 0) { + printf("\t.type %s,#object\n", sp->soname); + printf("\t.size %s," CONFMT "\n", sp->soname, + tsize(sp->stype, sp->sdf, sp->ssue) / SZCHAR); + printf("%s:\n", sp->soname); + } else + printf(LABFMT ":\n", sp->soffset); +} + +void +efcode() +{ + /* XXX */ +} + +void +bfcode(struct symtab **sp, int cnt) +{ + int i, off; + NODE *p, *q; + struct symtab *sym; + + /* Process the first six arguments. */ + for (i=0; i < cnt && i < 6; i++) { + sym = sp[i]; + q = block(REG, NIL, NIL, sym->stype, sym->sdf, sym->ssue); + q->n_rval = RETREG_PRE(sym->stype) + i; + p = tempnode(0, sym->stype, sym->sdf, sym->ssue); + sym->soffset = regno(p); + sym->sflags |= STNODE; + p = buildtree(ASSIGN, p, q); + ecomp(p); + } + + /* Process the remaining arguments. */ + for (off = V9RESERVE; i < cnt; i++) { + sym = sp[i]; + p = tempnode(0, sym->stype, sym->sdf, sym->ssue); + off = ALIGN(off, (tlen(p) - 1)); + sym->soffset = off * SZCHAR; + off += tlen(p); + p = buildtree(ASSIGN, p, nametree(sym)); + sym->soffset = regno(p->n_left); + sym->sflags |= STNODE; + ecomp(p); + } +} + +void +bccode() +{ + SETOFF(autooff, SZINT); +} + +void +ejobcode(int flag) +{ +} + +void +bjobcode() +{ +} + +/* + * The first six 64-bit arguments are saved in the registers O0 to O5, + * which become I0 to I5 after the "save" instruction moves the register + * window. Arguments 7 and up must be saved on the stack to %sp+BIAS+176. + * + * For a pretty picture, see Figure 3-16 in the SPARC Compliance Def 2.4. + */ +static NODE * +moveargs(NODE *p, int *regp, int *stacksize) +{ + NODE *r, *q; + + if (p->n_op == CM) { + p->n_left = moveargs(p->n_left, regp, stacksize); + r = p->n_right; + } else { + r = p; + } + + /* XXX more than six FP args can and should be passed in registers. */ + if (*regp > 5 && r->n_op != STARG) { + /* We are storing the stack offset in n_rval. */ + r = block(FUNARG, r, NIL, r->n_type, r->n_df, r->n_sue); + /* Make sure we are appropriately aligned. */ + *stacksize = ALIGN(*stacksize, (tlen(r) - 1)); + r->n_rval = *stacksize; + *stacksize += tlen(r); + } else if (r->n_op == STARG) + cerror("op STARG in moveargs"); + else { + q = block(REG, NIL, NIL, r->n_type, r->n_df, r->n_sue); + + /* + * The first six non-FP arguments go in the registers O0 - O5. + * Float arguments are stored in %fp1, %fp3, ..., %fp29, %fp31. + * Double arguments are stored in %fp0, %fp2, ..., %fp28, %fp30. + * A non-fp argument still increments register, eg. + * test(int a, int b, float b) + * takes %o0, %o1, %fp5. + */ + if (q->n_type == FLOAT) + q->n_rval = F0 + (*regp++ * 2) + 1; + else if (q->n_type == DOUBLE) + q->n_rval = D0 + *regp++; + else if (q->n_type == LDOUBLE) + cerror("long double support incomplete"); + else + q->n_rval = O0 + (*regp)++; + + r = buildtree(ASSIGN, q, r); + } + + if (p->n_op == CM) { + p->n_right = r; + return p; + } + + return r; +} + +NODE * +funcode(NODE *p) +{ + NODE *r, *l; + int reg = 0, stacksize = 0; + + r = l = 0; + + p->n_right = moveargs(p->n_right, ®, &stacksize); + + /* + * This is a particularly gross and inefficient way to handle + * argument overflows. First, we calculate how much stack space + * we need in moveargs(). Then we assign it by moving %sp, make + * the function call, and then move %sp back. + * + * What we should be doing is getting the maximum of all the needed + * stacksize values to the prologue and doing it all in the "save" + * instruction. + */ + if (stacksize != 0) { + stacksize = V9STEP(stacksize); /* 16-bit alignment. */ + + r = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + r->n_lval = 0; + r->n_rval = SP; + r = block(MINUS, r, bcon(stacksize), INT, 0, MKSUE(INT)); + + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_lval = 0; + l->n_rval = SP; + r = buildtree(ASSIGN, l, r); + + p = buildtree(COMOP, r, p); + + r = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + r->n_lval = 0; + r->n_rval = SP; + r = block(PLUS, r, bcon(stacksize), INT, 0, MKSUE(INT)); + + l = block(REG, NIL, NIL, INT, 0, MKSUE(INT)); + l->n_lval = 0; + l->n_rval = SP; + r = buildtree(ASSIGN, l, r); + + p = buildtree(COMOP, p, r); + + } + return p; +} + +int +fldal(unsigned int t) +{ + uerror("illegal field type"); + return ALINT; +} + +void +fldty(struct symtab *p) +{ +} + +int +mygenswitch(int num, TWORD type, struct swents **p, int n) +{ + return 0; +} --- /dev/null +++ usr.bin/pcc/sparc64/local.c @@ -0,0 +1,354 @@ +/* + * Copyright (c) 2008 David Crawshaw + * + * Permission to use, copy, modify, and/or distribute this software for any + * purpose with or without fee is hereby granted, provided that the above + * copyright notice and this permission notice appear in all copies. + * + * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES + * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF + * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR + * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES + * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN + * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF + * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. + */ + +#include "pass1.h" + +NODE * +clocal(NODE *p) +{ + struct symtab *sp; + int op; + NODE *r, *l; + + op = p->n_op; + sp = p->n_sp; + l = p->n_left; + r = p->n_right; + +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal in: %p, %s\n", p, copst(op)); + fwalk(p, eprint, 0); + } +#endif + + switch (op) { + + case NAME: + if (sp->sclass == PARAM || sp->sclass == AUTO) { + /* + * Use a fake structure reference to + * write out frame pointer offsets. + */ + l = block(REG, NIL, NIL, PTR+STRTY, 0, 0); + l->n_lval = 0; + l->n_rval = FP; + r = p; + p = stref(block(STREF, l, r, 0, 0, 0)); + } + break; + case PCONV: /* Remove what PCONVs we can. */ + if (l->n_op == SCONV) + break; + + if (l->n_op == ICON || (ISPTR(p->n_type) && ISPTR(l->n_type))) { + l->n_type = p->n_type; + l->n_qual = p->n_qual; + l->n_df = p->n_df; + l->n_sue = p->n_sue; + nfree(p); + p = l; + } + break; + + case SCONV: + /* Remove redundant conversions. */ + if ((p->n_type & TMASK) == 0 && (l->n_type & TMASK) == 0 && + btdims[p->n_type].suesize == btdims[l->n_type].suesize && + p->n_type != FLOAT && p->n_type != DOUBLE && + l->n_type != FLOAT && l->n_type != DOUBLE && + l->n_type != DOUBLE && p->n_type != LDOUBLE) { + if (l->n_op == NAME || l->n_op == UMUL || + l->n_op == TEMP) { + l->n_type = p->n_type; + nfree(p); + p = l; + break; + } + } + + /* Convert floating point to int before to char or short. */ + if ((l->n_type == FLOAT || l->n_type == DOUBLE || l->n_type == LDOUBLE) + && (DEUNSIGN(p->n_type) == CHAR || DEUNSIGN(p->n_type) == SHORT)) { + p = block(SCONV, p, NIL, p->n_type, p->n_df, p->n_sue); + p->n_left->n_type = INT; + break; + } + + /* Transform constants now. */ + if (l->n_op != ICON) + break; + + if (ISPTR(p->n_type)) { + l->n_type = p->n_type; + nfree(p); + p = l; + break; + } + + switch (p->n_type) { + case BOOL: l->n_lval = (l->n_lval != 0); break; + case CHAR: l->n_lval = (char)l->n_lval; break; + case UCHAR: l->n_lval = l->n_lval & 0377; break; + case SHORT: l->n_lval = (short)l->n_lval; break; + case USHORT: l->n_lval = l->n_lval & 0177777; break; + case UNSIGNED: l->n_lval = l->n_lval & 0xffffffff; break; + case INT: l->n_lval = (int)l->n_lval; break; + case ULONG: + case ULONGLONG: l->n_lval = l->n_lval; break; + case LONG: + case LONGLONG: l->n_lval = (long long)l->n_lval; break; + case FLOAT: + case DOUBLE: + case LDOUBLE: + l->n_op = FCON; + l->n_dcon = l->n_lval; + break; + case VOID: + break; + default: + cerror("sconv type unknown %d", p->n_type); + } + + l->n_type = p->n_type; + nfree(p); + p = l; + break; + + case PMCONV: + case PVCONV: + if (r->n_op != ICON) + cerror("converting bad type"); + nfree(p); + p = buildtree(op == PMCONV ? MUL : DIV, l, r); + break; + + case FORCE: + /* Put attached value into the return register. */ + p->n_op = ASSIGN; + p->n_right = p->n_left; + p->n_left = block(REG, NIL, NIL, p->n_type, 0, MKSUE(INT)); + p->n_left->n_rval = RETREG_PRE(p->n_type); + break; + } + +#ifdef PCC_DEBUG + if (xdebug) { + printf("clocal out: %p, %s\n", p, copst(op)); + fwalk(p, eprint, 0); + } +#endif + + return p; +} + +void +myp2tree(NODE *p) +{ + struct symtab *sp; + + if (p->n_op != FCON) + return; + + sp = tmpalloc(sizeof(struct symtab)); + sp->sclass = STATIC; + sp->slevel = 1; + sp->soffset = getlab(); + sp->sflags = 0; + sp->stype = p->n_type; + sp->squal = (CON >> TSHIFT); + + defloc(sp); + ninval(0, btdims[p->n_type].suesize, p); + + p->n_op = NAME; + p->n_lval = 0; + p->n_sp = sp; +} + +int +andable(NODE *p) +{ + return 1; +} + +void +cendarg() +{ + autooff = AUTOINIT; +} + +int +cisreg(TWORD t) +{ + /* SPARCv9 registers are all 64-bits wide. */ + return 1; +} + +NODE * +offcon(OFFSZ off, TWORD t, union dimfun *d, struct suedef *sue) +{ + return bcon(off / SZCHAR); +} + +void +spalloc(NODE *t, NODE *p, OFFSZ off) +{ +} + +void +inwstring(struct symtab *sp) +{ +} + +void +instring(struct symtab *sp) +{ + char *s, *str; + + defloc(sp); + str = sp->sname; + + printf("\t.ascii \""); + for (s = str; *s != 0; *s++) { + if (*s++ == '\\') + esccon(&s); + if (s - str > 60) { + fwrite(str, 1, s - str, stdout); + printf("\"\n\t.ascii \""); + str = s; + } + } + fwrite(str, 1, s - str, stdout); + printf("\\0\"\n"); +} + +void +zbits(OFFSZ off, int fsz) +{ +} + +void +infld(CONSZ off, int fsz, CONSZ val) +{ +} + +void +ninval(CONSZ off, int fsz, NODE *p) +{ + TWORD t; + struct symtab *sp; + union { float f; double d; int i; long long l; } u; + + t = p->n_type; + sp = p->n_sp; + + if (ISPTR(t)) + t = LONGLONG; + + if (p->n_op != ICON && p->n_op != FCON) + cerror("ninval: not a constant"); + if (p->n_op == ICON && sp != NULL && DEUNSIGN(t) != LONGLONG) + cerror("ninval: not constant"); + + switch (t) { + case CHAR: + case UCHAR: + printf("\t.byte %d\n", (int)p->n_lval & 0xff); + break; + case SHORT: + case USHORT: + printf("\t.half %d\n", (int)p->n_lval &0xffff); + break; + case BOOL: + p->n_lval = (p->n_lval != 0); /* FALLTHROUGH */ + case INT: + case UNSIGNED: + printf("\t.long " CONFMT "\n", p->n_lval); + break; + case LONG: + case ULONG: + case LONGLONG: + case ULONGLONG: + printf("\t.xword %lld", p->n_lval); + if (sp != 0) { + if (sp->sclass == STATIC && sp->slevel > 0) + printf("+" LABFMT, sp->soffset); + else + printf("+%s", exname(sp->soname)); + } + printf("\n"); + break; + case FLOAT: + u.f = (float)p->n_dcon; + printf("\t.long %d\n", u.i); + break; + case DOUBLE: + u.d = (double)p->n_dcon; + printf("\t.xword %lld\n", u.l); + break; + } +} + +char * +exname(char *p) +{ + return p ? p : ""; +} + +TWORD +ctype(TWORD type) +{ + return type; +} + +void +calldec(NODE *p, NODE *q) +{ +} + +void +extdec(struct symtab *q) +{ +} + +void +defzero(struct symtab *sp) +{ + int off = (tsize(sp->stype, sp->sdf, sp->ssue) + SZCHAR - 1) / SZCHAR; + printf("\t.comm "); + if (sp->slevel == 0) + printf("%s,%d\n", exname(sp->soname), off); + else + printf(LABFMT ",%d\n", sp->soffset, off); +} + +int +mypragma(char **ary) +{ + return 0; +} + +void +fixdef(struct symtab *sp) +{ +} + +void +pass1_lastchance(struct interpass *ip) +{ +} + From laffer1 at midnightbsd.org Tue Jan 20 16:30:17 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:30:17 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: move the pcc line to a more logical place Message-ID: <200901202130.n0KLUHkH081073@stargazer.midnightbsd.org> Log Message: ----------- move the pcc line to a more logical place Modified Files: -------------- src/usr.bin: Makefile (r1.19 -> r1.20) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/usr.bin/Makefile,v retrieving revision 1.19 retrieving revision 1.20 diff -L usr.bin/Makefile -L usr.bin/Makefile -u -r1.19 -r1.20 --- usr.bin/Makefile +++ usr.bin/Makefile @@ -316,8 +316,8 @@ .if ${MK_NCP} != "no" _ncplist= ncplist _ncplogin= ncplogin -#_pcc= pcc .endif +#_pcc= pcc _smbutil= smbutil .endif From laffer1 at midnightbsd.org Tue Jan 20 16:32:31 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 16:32:31 -0500 (EST) Subject: [Midnightbsd-cvs] src: src/etc: Message-ID: <200901202132.n0KLWVhC081261@stargazer.midnightbsd.org> Log Message: ----------- Modified Files: -------------- src/etc: rc.bsdextended (r1.2 -> r1.3) rc.initdiskless (r1.2 -> r1.3) -------------- next part -------------- Index: rc.initdiskless =================================================================== RCS file: /home/cvs/src/etc/rc.initdiskless,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.initdiskless -L etc/rc.initdiskless -u -r1.2 -r1.3 --- etc/rc.initdiskless +++ etc/rc.initdiskless @@ -24,9 +24,9 @@ # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # -# $FreeBSD: src/etc/rc.initdiskless,v 1.42.2.4 2006/01/24 05:49:58 brooks Exp $ # $MidnightBSD$ -# +# $FreeBSD: src/etc/rc.initdiskless,v 1.52 2006/12/03 23:50:29 luigi Exp $ + # On entry to this script the entire system consists of a read-only root # mounted via NFS. The kernel has run BOOTP and configured an interface # (otherwise it would not have been able to mount the NFS root!) @@ -71,12 +71,16 @@ # then /dev/ad0s3 will be be mounted on /conf/1.2.3.4/foo/ # # /conf/T/M/diskless_remount -# The contents of the file points to an NFS filesystem. E.g. if -# /conf/base/etc/diskless_remount contains "foo.com:/etc", -# then foo.com:/etc will be be mounted on /conf/base/etc/ -# If the file contains a pathname starting with "/", then -# the root path is prepended to it; this allows relocation of -# the root filesystem without changing configuration files. +# The contents of the file points to an NFS filesystem, +# possibly followed by mount_nfs options. If the server name +# is omitted, the script will prepend the root path used when +# booting. E.g. if you booted from foo.com:/path/to/root, +# an entry for /conf/base/etc/diskless_remount could be any of +# foo.com:/path/to/root/etc +# /etc -o ro +# Because mount_nfs understands ".." in paths, it is +# possible to mount from locations above the NFS root with +# paths such as "/../../etc". # # /conf/T/M/md_size # The contents of the file specifies the size of the memory @@ -98,21 +102,27 @@ # The list of paths contained in the file are rm -rf'd # relative to /SUBDIR. # +# /conf/diskless_remount +# Similar to /conf/T/M/diskless_remount above, but allows +# all of /conf to be remounted. This can be used to allow +# multiple roots to share the same /conf. +# +# # You will almost universally want to create the following files under /conf # -# File Content -# ---------------------------- ------------------------------------------ -# /conf/base/etc/md_size size of /etc filesystem -# /conf/base/diskless_remount "/etc" -# /conf/default/etc/rc.conf generic diskless config parameters -# /conf/default/etc/fstab generic diskless fstab e.g. like this -# -# foo:/root_part / nfs ro 0 0 -# foo:/usr_part /usr nfs ro 0 0 -# foo:/home_part /home nfs rw 0 0 -# md /tmp mfs -s=30m,rw 0 0 -# md /var mfs -s=30m,rw 0 0 -# proc /proc procfs rw 0 0 +# File Content +# ---------------------------- ---------------------------------- +# /conf/base/etc/md_size size of /etc filesystem +# /conf/base/etc/diskless_remount "/etc" +# /conf/default/etc/rc.conf generic diskless config parameters +# /conf/default/etc/fstab generic diskless fstab e.g. like this +# +# foo:/root_part / nfs ro 0 0 +# foo:/usr_part /usr nfs ro 0 0 +# foo:/home_part /home nfs rw 0 0 +# md /tmp mfs -s=30m,rw 0 0 +# md /var mfs -s=30m,rw 0 0 +# proc /proc procfs rw 0 0 # # plus, possibly, overrides for password files etc. # @@ -124,6 +134,14 @@ dlv=`/sbin/sysctl -n vfs.nfs.diskless_valid 2> /dev/null` +# DEBUGGING +# log something on stdout if verbose. +o_verbose=0 # set to 1 or 2 if you want more debugging +log() { + [ ${o_verbose} -gt 0 ] && echo "*** $* ***" + [ ${o_verbose} -gt 1 ] && read -p "=== Press enter to continue" foo +} + # chkerr: # # Routine to check for error @@ -143,6 +161,23 @@ esac } +# The list of filesystems to umount after the copy +to_umount="" + +handle_remount() { # $1 = mount point + local nfspt mountopts b + b=$1 + log handle_remount $1 + [ -d $b -a -f $b/diskless_remount ] || return + read nfspt mountopts < $b/diskless_remount + log "nfspt ${nfspt} mountopts ${mountopts}" + # prepend the nfs root if not present + [ `expr "$nfspt" : '\(.\)'` = "/" ] && nfspt="${nfsroot}${nfspt}" + mount_nfs $mountopts $nfspt $b + chkerr $? "mount_nfs $nfspt $b" + to_umount="$b ${to_umount}" +} + # Create a generic memory disk # mount_md() { @@ -152,16 +187,16 @@ # Create the memory filesystem if it has not already been created # create_md() { - if [ "x`eval echo \\$md_created_$1`" = "x" ]; then + [ "x`eval echo \\$md_created_$1`" = "x" ] || return # only once if [ "x`eval echo \\$md_size_$1`" = "x" ]; then md_size=10240 else md_size=`eval echo \\$md_size_$1` fi + log create_md $1 with size $md_size mount_md $md_size /$1 /bin/chmod 755 /$1 eval md_created_$1=created - fi } # DEBUGGING @@ -197,7 +232,7 @@ echo "Interface ${bootp_ifc} IP-Address ${bootp_ipa} Broadcast ${bootp_ipbca} ${class}" fi -# Figure out our NFS root path +log Figure out our NFS root path # set -- `mount -t nfs` while [ $# -ge 1 ] ; do @@ -220,20 +255,8 @@ templates="${templates} ${bootp_ipa} ip/${bootp_ipa}" fi -# The list of filesystems to umount after the copy -to_umount="" - -# If /conf/diskless_remount exists, remount all of /conf. This allows -# multiple roots to share the same conf files. -if [ -d /conf -a -f /conf/diskless_remount ]; then - nfspt=`/bin/cat /conf/diskless_remount` - if [ `expr "$nfspt" : '\(.\)'` = "/" ]; then - nfspt="${nfsroot}${nfspt}" - fi - mount_nfs $nfspt /conf - chkerr $? "mount_nfs $nfspt /conf" - to_umount="/conf" -fi +# If /conf/diskless_remount exists, remount all of /conf. +handle_remount /conf # Resolve templates in /conf/base, /conf/default, /conf/${bootp_ipbca}, # and /conf/${bootp_ipa}. For each subdirectory found within these @@ -255,18 +278,17 @@ # it before attemping to the remount. This allows the root to be # relocated without needing to change the remount files. # +log "templates are ${templates}" for i in ${templates} ; do for j in /conf/$i/* ; do + [ -d $j ] || continue + # memory filesystem size specification - # subdir=${j##*/} - if [ -d $j -a -f $j/md_size ]; then - eval md_size_$subdir=`cat $j/md_size` - fi + [ -f $j/md_size ] && eval md_size_$subdir=`cat $j/md_size` - # remount - # - if [ -d $j -a -f $j/remount ]; then + # remount. Beware, the command is in the file itself! + if [ -f $j/remount ]; then nfspt=`/bin/cat $j/remount` $nfspt $j chkerr $? "$nfspt $j" @@ -274,16 +296,7 @@ fi # NFS remount - # - if [ -d $j -a -f $j/diskless_remount ]; then - nfspt=`/bin/cat $j/diskless_remount` - if [ `expr "$nfspt" : '\(.\)'` = "/" ]; then - nfspt="${nfsroot}${nfspt}" - fi - mount_nfs $nfspt $j - chkerr $? "mount_nfs $nfspt $j" - to_umount="$j ${to_umount}" - fi + handle_remount $j done done @@ -301,7 +314,7 @@ subdir=${j##*/} if [ -d $j -a ! -f $j.cpio.gz ]; then create_md $subdir - cp -Rp $j/* /$subdir + cp -Rp $j/ /$subdir fi done for j in /conf/$i/*.cpio.gz ; do Index: rc.bsdextended =================================================================== RCS file: /home/cvs/src/etc/rc.bsdextended,v retrieving revision 1.2 retrieving revision 1.3 diff -L etc/rc.bsdextended -L etc/rc.bsdextended -u -r1.2 -r1.3 --- etc/rc.bsdextended +++ etc/rc.bsdextended @@ -23,10 +23,9 @@ # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. -# -# $MidnightBSD$ -# $FreeBSD: src/etc/rc.bsdextended,v 1.1 2004/09/29 00:12:28 trhodes Exp $ # +# $FreeBSD: src/etc/rc.bsdextended,v 1.2 2006/04/22 11:02:44 trhodes Exp $ +# $MidnightBSD$ #### # Sample startup policy for the mac_bsdextended(4) security module. @@ -49,34 +48,25 @@ #### # WARNING: recommended reading is the handbook's MAC -# chapter and the ugidfw(8) -# manual page. You can lock yourself out of the system -# very quickly by setting incorrect values here. -#### - -#### -# Set the value of 'x' to system users. This would be nice but it -# does not get the \n proper. Work around is used below. -#x=`awk -F: '($3 >= 1001) && ($3 != 65534) { print $1 }' /etc/passwd`; -#l=`awk -F: '($3 >= 1001) && ($3 != 65534) { print $3 }' /etc/passwd`; +# chapter and the ugidfw(8) manual page. You can +# lock yourself out of the system very quickly by setting +# incorrect values here. These are only examples. #### #### # Build a generic list of rules here, these should be # modified before using this script. -# ugidfw add 1 subject uid USER1 object uid USER2 mode n -# ugidfw add 2 subject gid USER1 object gid USER2 mode n # # For apache to read user files, the ruleadd must give # it permissions by default. #### -${CMD} add subject uid 80 object not uid 80 mode rxws; -${CMD} add subject gid 80 object not gid 80 mode rxws; +#${CMD} add subject uid 80 object not uid 80 mode rxws; +#${CMD} add subject gid 80 object not gid 80 mode rxws; #### # majordomo compat: #${CMD} add subject uid 54 object not uid 54 mode rxws; -${CMD} add subject gid 26 object gid 54 mode rxws; +#${CMD} add subject gid 26 object gid 54 mode rxws; #### # This is for root: @@ -84,14 +74,9 @@ ${CMD} add subject gid 0 object not gid 0 mode arxws; #### -# And for mailnull: -${CMD} add subject uid 26 object not uid 26 mode rxws; -${CMD} add subject gid 26 object not gid 26 mode rxws; - -#### # And for majordomo: -${CMD} add subject uid 54 object not uid 54 mode rxws; -${CMD} add subject gid 54 object not gid 54 mode rxws; +#${CMD} add subject uid 54 object not uid 54 mode rxws; +#${CMD} add subject gid 54 object not gid 54 mode rxws; #### # And for bin: @@ -100,8 +85,8 @@ #### # And for mail/pop: -${CMD} add subject uid 68 object not uid 68 mode rxws; -${CMD} add subject gid 6 object not gid 6 mode arxws; +#${CMD} add subject uid 68 object not uid 68 mode rxws; +#${CMD} add subject gid 6 object not gid 6 mode arxws; #### # And for smmsp: @@ -115,13 +100,13 @@ #### # For cyrus: -${CMD} add subject uid 60 object not uid 60 mode rxws; -${CMD} add subject gid 60 object not gid 60 mode rxws; +#${CMD} add subject uid 60 object not uid 60 mode rxws; +#${CMD} add subject gid 60 object not gid 60 mode rxws; #### # For stunnel: -${CMD} add subject uid 1018 object not uid 1018 mode rxws; -${CMD} add subject gid 1018 object not gid 1018 mode rxws; +#${CMD} add subject uid 1018 object not uid 1018 mode rxws; +#${CMD} add subject gid 1018 object not gid 1018 mode rxws; #### # For the nobody account: @@ -137,12 +122,6 @@ done; #### -# Work around majordomo problem where gid is `4'. -for x in `awk -F: '($3 >= 1001) && ($3 != 65534) { print $1 }' /etc/passwd`; - do ${CMD} add subject uid $x object gid 4 mode arwxs; -done; - -#### # Use some script to get a list of users and # add all users to mode n for all other users. This # will isolate all users from other user home directories while From laffer1 at midnightbsd.org Tue Jan 20 22:34:06 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 22:34:06 -0500 (EST) Subject: [Midnightbsd-cvs] src: Makefile: We don't have usbd.conf anymore Message-ID: <200901210334.n0L3Y6na014161@stargazer.midnightbsd.org> Log Message: ----------- We don't have usbd.conf anymore Modified Files: -------------- src/release: Makefile (r1.19 -> r1.20) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/src/release/Makefile,v retrieving revision 1.19 retrieving revision 1.20 diff -L release/Makefile -L release/Makefile -u -r1.19 -r1.20 --- release/Makefile +++ release/Makefile @@ -28,7 +28,7 @@ # #CHROOTDIR=/junk/release # If this is a -stable snapshot, then set -#RELEASETAG=RELENG_0_2 +#RELEASETAG=RELENG_0_3 # # To test a release with a source tree containing patches and # other work. This tree will get copied instead of getting the @@ -699,7 +699,6 @@ done ) cp ${RD}/trees/base/sbin/dhclient-script ${RD}/mfsfd/stand # cp ${RD}/trees/base/usr/bin/tar ${RD}/mfsfd/stand - cp ${.CURDIR}/../etc/usbd.conf ${RD}/mfsfd/etc/usbd.conf cp ${.CURDIR}/../etc/master.passwd ${RD}/mfsfd/etc/master.passwd cp ${RD}/trees/base/etc/*pwd.db ${RD}/mfsfd/etc/ ( for F in defaults/rc.conf netconfig protocols ; do \ From laffer1 at midnightbsd.org Tue Jan 20 23:34:56 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Tue, 20 Jan 2009 23:34:56 -0500 (EST) Subject: [Midnightbsd-cvs] mports: clamav-clamd.in: Fix file checking. Message-ID: <200901210434.n0L4Yuks019209@stargazer.midnightbsd.org> Log Message: ----------- Fix file checking. Modified Files: -------------- mports/security/clamav/files: clamav-clamd.in (r1.3 -> r1.4) -------------- next part -------------- Index: clamav-clamd.in =================================================================== RCS file: /home/cvs/mports/security/clamav/files/clamav-clamd.in,v retrieving revision 1.3 retrieving revision 1.4 diff -L security/clamav/files/clamav-clamd.in -L security/clamav/files/clamav-clamd.in -u -r1.3 -r1.4 --- security/clamav/files/clamav-clamd.in +++ security/clamav/files/clamav-clamd.in @@ -36,8 +36,8 @@ #clamav .93 won't start without a valid main.cvd file clamav_clamd_precmd() { - if [ ! -f %%DBDIR%%/main.cvd ];then - echo "Missing %%DBDIR%%/clamav/*.cvd files. You must run freshclam first" + if [ ! -f %%DBDIR%%/main.cvd -a ! -f %%DBDIR%%/main.cld ];then + echo "Missing %%DBDIR%%/*.cvd or *.cld files. You must run freshclam first" exit 1 fi } From laffer1 at midnightbsd.org Wed Jan 21 00:00:58 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Wed, 21 Jan 2009 00:00:58 -0500 (EST) Subject: [Midnightbsd-cvs] mports: security/clamav: update to 0.94.2. Message-ID: <200901210500.n0L50wFf040508@stargazer.midnightbsd.org> Log Message: ----------- update to 0.94.2. stop using libtool as it's got a built in version now. Modified Files: -------------- mports/security/clamav: Makefile (r1.15 -> r1.16) distinfo (r1.13 -> r1.14) mports/security/clamav/files: patch-configure (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/security/clamav/Makefile,v retrieving revision 1.15 retrieving revision 1.16 diff -L security/clamav/Makefile -L security/clamav/Makefile -u -r1.15 -r1.16 --- security/clamav/Makefile +++ security/clamav/Makefile @@ -7,7 +7,7 @@ # PORTNAME= clamav -PORTVERSION= 0.94 +PORTVERSION= 0.94.2 CATEGORIES= security MASTER_SITES= SF @@ -28,7 +28,7 @@ STDERR "Print logs to stderr instead of stdout" Off \ EXPERIMENTAL "Build experimental code" Off -USE_AUTOTOOLS= libtool:15 +GNU_CONFIGURE= yes CONFIGURE_TARGET= --build=${MACHINE_ARCH}-portbld-freebsd6.0 USE_LDCONFIG= yes USE_RC_SUBR= clamav-clamd clamav-freshclam @@ -43,9 +43,9 @@ CONFIGURE_ENV+= CPPFLAGS="${CPPFLAGS}" \ LDFLAGS="${LDFLAGS}" CONFIGURE_ARGS= --with-dbdir=${DBDIR} \ + --libdir=${PREFIX}/lib \ --with-zlib=/usr \ --mandir=${MANPREFIX}/man \ - --disable-zlib-vcheck \ --disable-clamuko \ --disable-clamav \ --enable-bigstack \ Index: distinfo =================================================================== RCS file: /home/cvs/mports/security/clamav/distinfo,v retrieving revision 1.13 retrieving revision 1.14 diff -L security/clamav/distinfo -L security/clamav/distinfo -u -r1.13 -r1.14 --- security/clamav/distinfo +++ security/clamav/distinfo @@ -1,3 +1,3 @@ -MD5 (clamav-0.94.tar.gz) = d3f6d5fff2db81950491749166ab0ffa -SHA256 (clamav-0.94.tar.gz) = ae188c18936ea9154eb6a85ea553c29f4349ee3e95457055fae5fe1b981af602 -SIZE (clamav-0.94.tar.gz) = 20509228 +MD5 (clamav-0.94.2.tar.gz) = 1181e6d62341b84708f126cc353f7ebf +SHA256 (clamav-0.94.2.tar.gz) = 1aec7fecff375958d067aceeb9782d3ff0be7c13bed0eecf6240fb089f8d268c +SIZE (clamav-0.94.2.tar.gz) = 22107637 Index: patch-configure =================================================================== RCS file: /home/cvs/mports/security/clamav/files/patch-configure,v retrieving revision 1.3 retrieving revision 1.4 diff -L security/clamav/files/patch-configure -L security/clamav/files/patch-configure -u -r1.3 -r1.4 --- security/clamav/files/patch-configure +++ security/clamav/files/patch-configure @@ -1,6 +1,6 @@ ---- configure.orig 2008-09-01 15:41:18.000000000 -0300 -+++ configure 2008-09-05 08:57:53.000000000 -0300 -@@ -16571,7 +16571,7 @@ +--- configure.orig 2008-10-15 07:41:31.000000000 -0300 ++++ configure 2008-10-15 08:55:58.000000000 -0300 +@@ -17909,7 +17909,7 @@ ;; freebsd*) if test "$have_pthreads" = "yes"; then @@ -9,16 +9,16 @@ TH_SAFE="-thread-safe" cat >>confdefs.h <<\_ACEOF -@@ -16931,7 +16931,7 @@ +@@ -18269,7 +18269,7 @@ if test "$have_milter" = "yes"; then - save_LDFLAGS="$LDFLAGS" -- CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" -+ CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS $THREAD_LIBS" + save_LIBS="$LIBS" +- CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -lpthread" ++ CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS $THREAD_LIBS" if test -d /usr/lib/libmilter ; then CLAMAV_MILTER_LIBS="$CLAMAV_MILTER_LIBS -L/usr/lib/libmilter" fi -@@ -17468,19 +17468,25 @@ +@@ -18806,19 +18806,25 @@ sendmailver_c=`echo $sendmailver | awk -F. '{printf $3}'` From ctriv at midnightbsd.org Wed Jan 21 11:47:03 2009 From: ctriv at midnightbsd.org (ctriv at midnightbsd.org) Date: Wed, 21 Jan 2009 11:47:03 -0500 (EST) Subject: [Midnightbsd-cvs] mports: apache.mk: provide some sensible defaults if apxs isn't Message-ID: <200901211647.n0LGl3mm012849@stargazer.midnightbsd.org> Log Message: ----------- provide some sensible defaults if apxs isn't installed. Modified Files: -------------- mports/Mk/extensions: apache.mk (r1.2 -> r1.3) -------------- next part -------------- Index: apache.mk =================================================================== RCS file: /home/cvs/mports/Mk/extensions/apache.mk,v retrieving revision 1.2 retrieving revision 1.3 diff -L Mk/extensions/apache.mk -L Mk/extensions/apache.mk -u -r1.2 -r1.3 --- Mk/extensions/apache.mk +++ Mk/extensions/apache.mk @@ -350,8 +350,13 @@ .elif defined(AP_PORT_IS_MODULE) +.if exists(${APXS}) APR_CONFIG!= ${APXS} -q APR_CONFIG AP_LIBTOOL!= ${APR_CONFIG} --apr-libtool +.else +APR_CONFIG= ${LOCALBASE}/bin/apr-1-config +AP_LIBTOOL= ${LOCALBASE}/build-1/libtool +.endif .if defined(AP_FAST_BUILD) .if !target(ap-gen-plist) From laffer1 at midnightbsd.org Wed Jan 21 13:56:03 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Wed, 21 Jan 2009 13:56:03 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: switch to releases directory Message-ID: <200901211856.n0LIu3IX056367@stargazer.midnightbsd.org> Log Message: ----------- switch to releases directory Modified Files: -------------- www/download: index.html (r1.41 -> r1.42) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.41 retrieving revision 1.42 diff -L download/index.html -L download/index.html -u -r1.41 -r1.42 --- download/index.html +++ download/index.html @@ -43,7 +43,7 @@
NetBSD.se - HTTP + FTP + HTTP + FTP Fast From crash at midnightbsd.org Sun Jan 25 14:37:14 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 14:37:14 -0500 (EST) Subject: [Midnightbsd-cvs] mports: archivers/unrar: update to 3.80 instead of 3.80.b2 Message-ID: <200901251937.n0PJbE4D075247@stargazer.midnightbsd.org> Log Message: ----------- update to 3.80 instead of 3.80.b2 Modified Files: -------------- mports/archivers/unrar: Makefile (r1.5 -> r1.6) distinfo (r1.3 -> r1.4) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/archivers/unrar/Makefile,v retrieving revision 1.5 retrieving revision 1.6 diff -L archivers/unrar/Makefile -L archivers/unrar/Makefile -u -r1.5 -r1.6 --- archivers/unrar/Makefile +++ archivers/unrar/Makefile @@ -7,11 +7,11 @@ # PORTNAME= unrar -PORTVERSION= 3.80.b2 +PORTVERSION= 3.80 PORTEPOCH= 5 CATEGORIES+= archivers MASTER_SITES= http://www.rarlab.com/rar/ -DISTNAME= unrarsrc-3.8.2 +DISTNAME= unrarsrc-3.8.4 MAINTAINER?= ports at MidnightBSD.org COMMENT= Extract, view & test RAR archives Index: distinfo =================================================================== RCS file: /home/cvs/mports/archivers/unrar/distinfo,v retrieving revision 1.3 retrieving revision 1.4 diff -L archivers/unrar/distinfo -L archivers/unrar/distinfo -u -r1.3 -r1.4 --- archivers/unrar/distinfo +++ archivers/unrar/distinfo @@ -1,3 +1,3 @@ -MD5 (unrarsrc-3.8.2.tar.gz) = 897e7d72c7576ff8c83a2b8f48017bb1 -SHA256 (unrarsrc-3.8.2.tar.gz) = d989b1393d350290fdab4162b4e7a6bcf061d2b3a4a1c4982fc0868d668cc731 -SIZE (unrarsrc-3.8.2.tar.gz) = 134853 +MD5 (unrarsrc-3.8.4.tar.gz) = b40b43e28dee42abd9840bfc9e2909ee +SHA256 (unrarsrc-3.8.4.tar.gz) = 5d501b853885c30f4b0ee8fd9a7c61607df99fd1aaf7db99a2c44c6243337886 +SIZE (unrarsrc-3.8.4.tar.gz) = 135665 From crash at midnightbsd.org Sun Jan 25 14:53:09 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 14:53:09 -0500 (EST) Subject: [Midnightbsd-cvs] mports: archivers/p7zip: update to 4.61 Message-ID: <200901251953.n0PJr9eb076478@stargazer.midnightbsd.org> Log Message: ----------- update to 4.61 Modified Files: -------------- mports/archivers/p7zip: Makefile (r1.6 -> r1.7) distinfo (r1.4 -> r1.5) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/archivers/p7zip/Makefile,v retrieving revision 1.6 retrieving revision 1.7 diff -L archivers/p7zip/Makefile -L archivers/p7zip/Makefile -u -r1.6 -r1.7 --- archivers/p7zip/Makefile +++ archivers/p7zip/Makefile @@ -7,7 +7,7 @@ # PORTNAME= p7zip -PORTVERSION= 4.58 +PORTVERSION= 4.61 PORTREVISION= 1 CATEGORIES= archivers MASTER_SITES= SF Index: distinfo =================================================================== RCS file: /home/cvs/mports/archivers/p7zip/distinfo,v retrieving revision 1.4 retrieving revision 1.5 diff -L archivers/p7zip/distinfo -L archivers/p7zip/distinfo -u -r1.4 -r1.5 --- archivers/p7zip/distinfo +++ archivers/p7zip/distinfo @@ -1,3 +1,3 @@ -MD5 (p7zip_4.58_src_all.tar.bz2) = 315b184102c17c4956f53218d973222d -SHA256 (p7zip_4.58_src_all.tar.bz2) = 52391559b7782d2bad45b783579ea9825f28670ba6f234fd0d9248af3e82bedd -SIZE (p7zip_4.58_src_all.tar.bz2) = 1948207 +MD5 (p7zip_4.61_src_all.tar.bz2) = a01408ac4ef496270ff936db21309b92 +SHA256 (p7zip_4.61_src_all.tar.bz2) = ccc309c6411b3e9badc73f2c3e1c0469d333d09a1ea30481c4a6be0782dbe061 +SIZE (p7zip_4.61_src_all.tar.bz2) = 2483533 From crash at midnightbsd.org Sun Jan 25 15:03:27 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 15:03:27 -0500 (EST) Subject: [Midnightbsd-cvs] mports: archivers/pbzip2: update to 1.0.5 Message-ID: <200901252003.n0PK3Rwj077352@stargazer.midnightbsd.org> Log Message: ----------- update to 1.0.5 Modified Files: -------------- mports/archivers/pbzip2: Makefile (r1.5 -> r1.6) distinfo (r1.2 -> r1.3) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/archivers/pbzip2/Makefile,v retrieving revision 1.5 retrieving revision 1.6 diff -L archivers/pbzip2/Makefile -L archivers/pbzip2/Makefile -u -r1.5 -r1.6 --- archivers/pbzip2/Makefile +++ archivers/pbzip2/Makefile @@ -1,10 +1,10 @@ # $MidnightBSD$ PORTNAME= pbzip2 -PORTVERSION= 1.0.2 +PORTVERSION= 1.0.5 CATEGORIES= archivers -MASTER_SITES= http://compression.ca/pbzip2/ CENKES - +MASTER_SITES= http://compression.ca/pbzip2/ +DIST_SUBDIR= ${PORTNAME}-${PORTVERSION} MAINTAINER= ports at MidnightBSD.org COMMENT= Parallel BZIP2 LICENSE= bzip2 @@ -14,16 +14,14 @@ MAN1= pbzip2.1 MLINKS= pbzip2.1 pbunzip2.1 +USE_GMAKE= YES post-patch: @${REINPLACE_CMD} \ - -e "s,-pthread -lpthread,${PTHREAD_LIBS},g" \ - -e "s,-O3,${CXXFLAGS}," \ - -e "s,^CC,#CC," \ - -e "s,CC,CXX," ${WRKSRC}/Makefile - @${REINPLACE_CMD} \ - -e "s,PRIu64 \"Lu\",PRIu64 Lu," \ - -e "s,\"PRIu64\",#PRIu64,g" ${WRKSRC}/pbzip2.cpp - + -e 's,-pthread -lpthread,${PTHREAD_LIBS},g; \ + s,-O2,${CXXFLAGS},; \ + s,^CC,#CC,; \ + s,CC,CXX,' ${WRKSRC}/Makefile + do-install: @${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin/ @${LN} -sf ${PORTNAME} ${PREFIX}/bin/pbunzip2 Index: distinfo =================================================================== RCS file: /home/cvs/mports/archivers/pbzip2/distinfo,v retrieving revision 1.2 retrieving revision 1.3 diff -L archivers/pbzip2/distinfo -L archivers/pbzip2/distinfo -u -r1.2 -r1.3 --- archivers/pbzip2/distinfo +++ archivers/pbzip2/distinfo @@ -1,3 +1,3 @@ -MD5 (pbzip2-1.0.2.tar.gz) = 7c959f0554695bc484865b938e791aaf -SHA256 (pbzip2-1.0.2.tar.gz) = 41c654b493bfd045f3a625ca9f3fb66e327ad0a4395e515c2bd6c3070b83c0e4 -SIZE (pbzip2-1.0.2.tar.gz) = 22777 +MD5 (pbzip2-1.0.5/pbzip2-1.0.5.tar.gz) = e2448d22ee29d1e6549ac58b98df11ab +SHA256 (pbzip2-1.0.5/pbzip2-1.0.5.tar.gz) = 415d8c8a69080b7e55a50784852971fca249cd9e5ec4ada8e617ca2696c9896d +SIZE (pbzip2-1.0.5/pbzip2-1.0.5.tar.gz) = 26997 From crash at midnightbsd.org Sun Jan 25 15:27:25 2009 From: crash at midnightbsd.org (crash at midnightbsd.org) Date: Sun, 25 Jan 2009 15:27:25 -0500 (EST) Subject: [Midnightbsd-cvs] mports: shells/bash: update 3.2 to patchlevel 48 Message-ID: <200901252027.n0PKRPX3079594@stargazer.midnightbsd.org> Log Message: ----------- update 3.2 to patchlevel 48 Modified Files: -------------- mports/shells/bash: Makefile (r1.8 -> r1.9) distinfo (r1.4 -> r1.5) -------------- next part -------------- Index: Makefile =================================================================== RCS file: /home/cvs/mports/shells/bash/Makefile,v retrieving revision 1.8 retrieving revision 1.9 diff -L shells/bash/Makefile -L shells/bash/Makefile -u -r1.8 -r1.9 --- shells/bash/Makefile +++ shells/bash/Makefile @@ -8,7 +8,7 @@ # PORTNAME= bash -PATCHLEVEL= 39 +PATCHLEVEL= 48 PORTVERSION= 3.2.${PATCHLEVEL:S/^0//g} CATEGORIES= shells MASTER_SITES= ${MASTER_SITE_GNU:S/$/:bash/} \ Index: distinfo =================================================================== RCS file: /home/cvs/mports/shells/bash/distinfo,v retrieving revision 1.4 retrieving revision 1.5 diff -L shells/bash/distinfo -L shells/bash/distinfo -u -r1.4 -r1.5 --- shells/bash/distinfo +++ shells/bash/distinfo @@ -118,5 +118,32 @@ MD5 (bash/bash32-039) = e240c34f979b64bcb83c5f6567110bb1 SHA256 (bash/bash32-039) = 46d427fd5b1509ec7dd980c07efd88634fde61cf07ab221dcbde9e1021bd2817 SIZE (bash/bash32-039) = 5034 +MD5 (bash/bash32-040) = 06e6df263398807fa032707fb7b77b5f +SHA256 (bash/bash32-040) = c9e0387eb4a2904126864d24de0699cdb6070789e1c02287a3b81ea96bf945aa +SIZE (bash/bash32-040) = 1403 +MD5 (bash/bash32-041) = 373ae081d658dc85bc1058c4759d6669 +SHA256 (bash/bash32-041) = cc551fa57d613efea30ab2404fe724793a3d10f012b030e611d2c6449e463bcd +SIZE (bash/bash32-041) = 4446 +MD5 (bash/bash32-042) = 9c9ebc6bfc33a0215277ee17a276eb5a +SHA256 (bash/bash32-042) = fd0df54d03034e104b6377f249624bda0271aa874190a46e9d41fc49ad3caaef +SIZE (bash/bash32-042) = 1209 +MD5 (bash/bash32-043) = b87fb9ea16a64ca41b6676e9a7eb7a33 +SHA256 (bash/bash32-043) = 43df7d2d7d61d3a8f0e14bc86d4f55b6d2e64829ba0829a78f5214d186087af7 +SIZE (bash/bash32-043) = 1658 +MD5 (bash/bash32-044) = 07e0229ce5879bfbd26a8146070fd366 +SHA256 (bash/bash32-044) = 204b5ecaaa5de334c3cfbce6dfd8a9d3770b09024ab4724d86080fbf501ded69 +SIZE (bash/bash32-044) = 5565 +MD5 (bash/bash32-045) = 1ad07965a8a93f3556ee1ab18b97cde2 +SHA256 (bash/bash32-045) = 3250e6c6d5d6884e31beaa2f521d2a1af9c2f701a4c0e67a7cd011b6ad8f082b +SIZE (bash/bash32-045) = 1338 +MD5 (bash/bash32-046) = f7b1e19fcad54c2286bc0ed614aad9bf +SHA256 (bash/bash32-046) = fc829e92fa951c34368d83272d746f5c0ed345a7ad037f93322347eed00a1e1f +SIZE (bash/bash32-046) = 1275 +MD5 (bash/bash32-047) = 550690766de770116c34dbdf74e59184 +SHA256 (bash/bash32-047) = 623d4a958d2b022a15929a4de7403766ff07b295a185987b4d1e6cf3b70ea106 +SIZE (bash/bash32-047) = 1981 +MD5 (bash/bash32-048) = 4cc593e7b789b23b37a5397e092d3954 +SHA256 (bash/bash32-048) = 74cb56764274f393676f68738eb22a3ed8fa388c0487feeadf0d78a45b549749 +SIZE (bash/bash32-048) = 1948 MD5 (bash/FAQ) = IGNORE SHA256 (bash/FAQ) = IGNORE From laffer1 at midnightbsd.org Sun Jan 25 16:55:17 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Sun, 25 Jan 2009 16:55:17 -0500 (EST) Subject: [Midnightbsd-cvs] mports: www/apache22: update to 2.2.11 Message-ID: <200901252155.n0PLtHHt087319@stargazer.midnightbsd.org> Log Message: ----------- update to 2.2.11 Modified Files: -------------- mports/www/apache22: Makefile (r1.10 -> r1.11) Makefile.doc (r1.2 -> r1.3) Makefile.modules (r1.2 -> r1.3) distinfo (r1.6 -> r1.7) -------------- next part -------------- Index: Makefile.doc =================================================================== RCS file: /home/cvs/mports/www/apache22/Makefile.doc,v retrieving revision 1.2 retrieving revision 1.3 diff -L www/apache22/Makefile.doc -L www/apache22/Makefile.doc -u -r1.2 -r1.3 --- www/apache22/Makefile.doc +++ www/apache22/Makefile.doc @@ -5,6 +5,7 @@ # - make options output # - apache22 man/docs routines # +# $MidnightBSD$ # $FreeBSD: ports/www/apache22/Makefile.doc,v 1.10 2006/11/05 10:49:17 clement Exp $ # Index: Makefile.modules =================================================================== RCS file: /home/cvs/mports/www/apache22/Makefile.modules,v retrieving revision 1.2 retrieving revision 1.3 diff -L www/apache22/Makefile.modules -L www/apache22/Makefile.modules -u -r1.2 -r1.3 --- www/apache22/Makefile.modules +++ www/apache22/Makefile.modules @@ -9,6 +9,7 @@ # gsed 's/^\(.*\)mod\(.*\)\.so/%%\MOD\U\2%%\L\1mod\2\.so/' pkg-plist > tmp # mv tmp pkg-plist # +# $MidnightBSD$ # $FreeBSD: ports/www/apache22/Makefile.modules,v 1.21 2007/01/13 13:18:35 clement Exp $ # Index: Makefile =================================================================== RCS file: /home/cvs/mports/www/apache22/Makefile,v retrieving revision 1.10 retrieving revision 1.11 diff -L www/apache22/Makefile -L www/apache22/Makefile -u -r1.10 -r1.11 --- www/apache22/Makefile +++ www/apache22/Makefile @@ -8,7 +8,7 @@ # PORTNAME= apache -PORTVERSION= 2.2.10 +PORTVERSION= 2.2.11 CATEGORIES= www MASTER_SITES= ${MASTER_SITE_APACHE_HTTPD} \ ${MASTER_SITE_LOCAL:S/%SUBDIR%\//clement\/:aprmysql/} Index: distinfo =================================================================== RCS file: /home/cvs/mports/www/apache22/distinfo,v retrieving revision 1.6 retrieving revision 1.7 diff -L www/apache22/distinfo -L www/apache22/distinfo -u -r1.6 -r1.7 --- www/apache22/distinfo +++ www/apache22/distinfo @@ -1,3 +1,3 @@ -MD5 (apache22/httpd-2.2.10.tar.bz2) = 6697772ba5f8d34988fe297417ccaacc -SHA256 (apache22/httpd-2.2.10.tar.bz2) = 681d5787288e4e527877f415acce198be96ce7de0dc6e354646b1df4aae21383 -SIZE (apache22/httpd-2.2.10.tar.bz2) = 5068069 +MD5 (apache22/httpd-2.2.11.tar.bz2) = 3e98bcb14a7122c274d62419566431bb +SHA256 (apache22/httpd-2.2.11.tar.bz2) = 5ce34825c5b84d1808605a22f8d16d44c6f91882a538bb98a3affed8f5dff6fe +SIZE (apache22/httpd-2.2.11.tar.bz2) = 5230130 From laffer1 at midnightbsd.org Mon Jan 26 14:14:09 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:14:09 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: Add new partial mirror Message-ID: <200901261914.n0QJE9UY017809@stargazer.midnightbsd.org> Log Message: ----------- Add new partial mirror Modified Files: -------------- www/download: index.html (r1.42 -> r1.43) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.42 retrieving revision 1.43 diff -L download/index.html -L download/index.html -u -r1.42 -r1.43 --- download/index.html +++ download/index.html @@ -62,6 +62,11 @@ Medium + "Kitty" (ISOs only) + HTTP + FTP + Medium + +
MidnightBSD.org HTTP + FTP Slow From laffer1 at midnightbsd.org Mon Jan 26 14:18:13 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:18:13 -0500 (EST) Subject: [Midnightbsd-cvs] www: www/download: change URLs for vm images so they are on the ftp Message-ID: <200901261918.n0QJIDqm018372@stargazer.midnightbsd.org> Log Message: ----------- change URLs for vm images so they are on the ftp server too. Modified Files: -------------- www/download: parallels.html (r1.2 -> r1.3) vmware.html (r1.3 -> r1.4) -------------- next part -------------- Index: vmware.html =================================================================== RCS file: /home/cvs/www/download/vmware.html,v retrieving revision 1.3 retrieving revision 1.4 diff -L download/vmware.html -L download/vmware.html -u -r1.3 -r1.4 --- download/vmware.html +++ download/vmware.html @@ -12,10 +12,10 @@ is no password. DHCP is enabled. X.org 6.9 and perl are installed.

-Download (Zip format) the MidnightBSD VMware virtual appliance. +Download (Zip format) the MidnightBSD VMware virtual appliance.

-

A second appliance (7zip format) is available with a subset of KDE 3.5.4 installed and kdm running at startup. It is approximately 291MB and requires a username and password of mnbsd.

+

A second appliance (7zip format) is available with a subset of KDE 3.5.4 installed and kdm running at startup. It is approximately 291MB and requires a username and password of mnbsd.

Index: parallels.html =================================================================== RCS file: /home/cvs/www/download/parallels.html,v retrieving revision 1.2 retrieving revision 1.3 diff -L download/parallels.html -L download/parallels.html -u -r1.2 -r1.3 --- download/parallels.html +++ download/parallels.html @@ -11,7 +11,7 @@

This MidnightBSD appliance is based on 0.1.1-RELEASE. It is 60MB compressedand under 200MB uncompressed. Only the root account is configured and there is no password. DHCP is enabled. No x.org. Made on Parallels 3 for Mac OS X.

-

MidnightBSD 0.1.1 for Parallels

+

MidnightBSD 0.1.1 for Parallels

From laffer1 at midnightbsd.org Mon Jan 26 14:19:47 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:19:47 -0500 (EST) Subject: [Midnightbsd-cvs] www: index.html: change url for VMs Message-ID: <200901261919.n0QJJlxs018488@stargazer.midnightbsd.org> Log Message: ----------- change url for VMs Modified Files: -------------- www/download: index.html (r1.43 -> r1.44) -------------- next part -------------- Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.43 retrieving revision 1.44 diff -L download/index.html -L download/index.html -u -r1.43 -r1.44 --- download/index.html +++ download/index.html @@ -80,15 +80,15 @@

- - + + - + - +
VMWare Image (222MB)Parallels Image (60MB)Parallels 3.x Image (60MB)
This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. A second appliance (7zip, 291MB) is available with a subset of KDE 3.5.4 and kdm running at startup. Username and password: mnbsd.This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. A second appliance (7zip, 291MB) is available with a subset of KDE 3.5.4 and kdm running at startup. Username and password: mnbsd. This MidnightBSD appliance is based on 0.1.1-RELEASE. It is 60MB compressed and 200MB uncompressed. Only the root account is configured and there is no password. DHCP is enabled. No X.org. Made on Parallels 3 for Mac OS X.

From laffer1 at midnightbsd.org Mon Jan 26 14:24:58 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Mon, 26 Jan 2009 14:24:58 -0500 (EST) Subject: [Midnightbsd-cvs] www: www/download: change vmware availability. Message-ID: <200901261924.n0QJOwRH019144@stargazer.midnightbsd.org> Log Message: ----------- change vmware availability. (i need to make new ones soon) Modified Files: -------------- www/download: index.html (r1.44 -> r1.45) vmware.html (r1.4 -> r1.5) -------------- next part -------------- Index: vmware.html =================================================================== RCS file: /home/cvs/www/download/vmware.html,v retrieving revision 1.4 retrieving revision 1.5 diff -L download/vmware.html -L download/vmware.html -u -r1.4 -r1.5 --- download/vmware.html +++ download/vmware.html @@ -15,8 +15,5 @@ Download (Zip format) the MidnightBSD VMware virtual appliance.

-

A second appliance (7zip format) is available with a subset of KDE 3.5.4 installed and kdm running at startup. It is approximately 291MB and requires a username and password of mnbsd.

- - Index: index.html =================================================================== RCS file: /home/cvs/www/download/index.html,v retrieving revision 1.44 retrieving revision 1.45 diff -L download/index.html -L download/index.html -u -r1.44 -r1.45 --- download/index.html +++ download/index.html @@ -80,7 +80,7 @@

- + @@ -88,7 +88,7 @@ - +
Parallels 3.x Image (60MB)
This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. A second appliance (7zip, 291MB) is available with a subset of KDE 3.5.4 and kdm running at startup. Username and password: mnbsd.This MidnightBSD VMWare appliance is based on 0.1.1-RELEASE. It is 222MB compressed and around 700MB uncompressed. Only the root account is configured (no password). DHCP, X.org 6.9 and perl are installed. This MidnightBSD appliance is based on 0.1.1-RELEASE. It is 60MB compressed and 200MB uncompressed. Only the root account is configured and there is no password. DHCP is enabled. No X.org. Made on Parallels 3 for Mac OS X.

From laffer1 at midnightbsd.org Thu Jan 29 12:52:58 2009 From: laffer1 at midnightbsd.org (laffer1 at midnightbsd.org) Date: Thu, 29 Jan 2009 12:52:58 -0500 (EST) Subject: [Midnightbsd-cvs] mports: www/dojo: Add dojo and zend framework ports. Message-ID: <200901291752.n0THqwS3004816@stargazer.midnightbsd.org> Log Message: ----------- Add dojo and zend framework ports. These are based on Greg Larkin's ports for FreeBSD. I need this for work. Added Files: ----------- mports/www/dojo: Makefile (r1.1) distinfo (r1.1) pkg-descr (r1.1) pkg-plist (r1.1) mports/www/dojo/files: dojo.conf.in (r1.1) pkg-message.in (r1.1) mports/www/zend-framework: Makefile (r1.1) distinfo (r1.1) pkg-descr (r1.1) pkg-plist (r1.1) mports/www/zend-framework/files: pkg-message.in (r1.1) -------------- next part -------------- --- /dev/null +++ www/dojo/pkg-descr @@ -0,0 +1,7 @@ +Dojo is an Open Source DHTML toolkit written in JavaScript. It +builds on several contributed code bases (nWidgets, Burstlib, f(m)), +which is why we refer to it sometimes as a "unified" toolkit. Dojo +aims to solve some long-standing historical problems with DHTML +which prevented mass adoption of dynamic web application development. + +WWW: http://dojotoolkit.org/ --- /dev/null +++ www/dojo/pkg-plist @@ -0,0 +1,2179 @@ +%%WWWDIR%%/dijit/ColorPalette.js +%%WWWDIR%%/dijit/Declaration.js +%%WWWDIR%%/dijit/Dialog.js +%%WWWDIR%%/dijit/Editor.js +%%WWWDIR%%/dijit/InlineEditBox.js +%%WWWDIR%%/dijit/LICENSE +%%WWWDIR%%/dijit/Menu.js +%%WWWDIR%%/dijit/ProgressBar.js +%%WWWDIR%%/dijit/TitlePane.js +%%WWWDIR%%/dijit/Toolbar.js +%%WWWDIR%%/dijit/Tooltip.js +%%WWWDIR%%/dijit/Tree.js +%%WWWDIR%%/dijit/_Calendar.js +%%WWWDIR%%/dijit/_Container.js +%%WWWDIR%%/dijit/_Templated.js +%%WWWDIR%%/dijit/_TimePicker.js +%%WWWDIR%%/dijit/_Widget.js +%%WWWDIR%%/dijit/_base.js +%%WWWDIR%%/dijit/_base/focus.js +%%WWWDIR%%/dijit/_base/manager.js +%%WWWDIR%%/dijit/_base/place.js +%%WWWDIR%%/dijit/_base/popup.js +%%WWWDIR%%/dijit/_base/scroll.js +%%WWWDIR%%/dijit/_base/sniff.js +%%WWWDIR%%/dijit/_base/typematic.js +%%WWWDIR%%/dijit/_base/wai.js +%%WWWDIR%%/dijit/_base/window.js +%%WWWDIR%%/dijit/_editor/RichText.js +%%WWWDIR%%/dijit/_editor/_Plugin.js +%%WWWDIR%%/dijit/_editor/html.js +%%WWWDIR%%/dijit/_editor/nls/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ar/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ar/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ar/commands.js +%%WWWDIR%%/dijit/_editor/nls/ca/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ca/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ca/commands.js +%%WWWDIR%%/dijit/_editor/nls/commands.js +%%WWWDIR%%/dijit/_editor/nls/cs/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/cs/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/cs/commands.js +%%WWWDIR%%/dijit/_editor/nls/da/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/da/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/da/commands.js +%%WWWDIR%%/dijit/_editor/nls/de/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/de/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/de/commands.js +%%WWWDIR%%/dijit/_editor/nls/el/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/el/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/el/commands.js +%%WWWDIR%%/dijit/_editor/nls/es/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/es/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/es/commands.js +%%WWWDIR%%/dijit/_editor/nls/fi/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/fi/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/fi/commands.js +%%WWWDIR%%/dijit/_editor/nls/fr/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/fr/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/fr/commands.js +%%WWWDIR%%/dijit/_editor/nls/he/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/he/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/he/commands.js +%%WWWDIR%%/dijit/_editor/nls/hu/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/hu/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/hu/commands.js +%%WWWDIR%%/dijit/_editor/nls/it/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/it/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/it/commands.js +%%WWWDIR%%/dijit/_editor/nls/ja/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ja/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ja/commands.js +%%WWWDIR%%/dijit/_editor/nls/ko/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ko/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ko/commands.js +%%WWWDIR%%/dijit/_editor/nls/nb/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/nb/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/nb/commands.js +%%WWWDIR%%/dijit/_editor/nls/nl/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/nl/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/nl/commands.js +%%WWWDIR%%/dijit/_editor/nls/pl/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/pl/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/pl/commands.js +%%WWWDIR%%/dijit/_editor/nls/pt-pt/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/pt-pt/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/pt-pt/commands.js +%%WWWDIR%%/dijit/_editor/nls/pt/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/pt/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/pt/commands.js +%%WWWDIR%%/dijit/_editor/nls/ru/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/ru/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/ru/commands.js +%%WWWDIR%%/dijit/_editor/nls/sk/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/sk/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/sk/commands.js +%%WWWDIR%%/dijit/_editor/nls/sl/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/sl/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/sl/commands.js +%%WWWDIR%%/dijit/_editor/nls/sv/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/sv/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/sv/commands.js +%%WWWDIR%%/dijit/_editor/nls/th/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/th/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/th/commands.js +%%WWWDIR%%/dijit/_editor/nls/tr/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/tr/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/tr/commands.js +%%WWWDIR%%/dijit/_editor/nls/zh-tw/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/zh-tw/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/zh-tw/commands.js +%%WWWDIR%%/dijit/_editor/nls/zh/FontChoice.js +%%WWWDIR%%/dijit/_editor/nls/zh/LinkDialog.js +%%WWWDIR%%/dijit/_editor/nls/zh/commands.js +%%WWWDIR%%/dijit/_editor/plugins/AlwaysShowToolbar.js +%%WWWDIR%%/dijit/_editor/plugins/EnterKeyHandling.js +%%WWWDIR%%/dijit/_editor/plugins/FontChoice.js +%%WWWDIR%%/dijit/_editor/plugins/LinkDialog.js +%%WWWDIR%%/dijit/_editor/plugins/TabIndent.js +%%WWWDIR%%/dijit/_editor/plugins/TextColor.js +%%WWWDIR%%/dijit/_editor/plugins/ToggleDir.js +%%WWWDIR%%/dijit/_editor/range.js +%%WWWDIR%%/dijit/_editor/selection.js +%%WWWDIR%%/dijit/_tree/Node.html +%%WWWDIR%%/dijit/_tree/Tree.html +%%WWWDIR%%/dijit/_tree/dndContainer.js +%%WWWDIR%%/dijit/_tree/dndSelector.js +%%WWWDIR%%/dijit/_tree/dndSource.js +%%WWWDIR%%/dijit/_tree/model.js +%%WWWDIR%%/dijit/dijit-all.js +%%WWWDIR%%/dijit/dijit.js +%%WWWDIR%%/dijit/form/Button.js +%%WWWDIR%%/dijit/form/CheckBox.js +%%WWWDIR%%/dijit/form/ComboBox.js +%%WWWDIR%%/dijit/form/CurrencyTextBox.js +%%WWWDIR%%/dijit/form/DateTextBox.js +%%WWWDIR%%/dijit/form/FilteringSelect.js +%%WWWDIR%%/dijit/form/Form.js +%%WWWDIR%%/dijit/form/MultiSelect.js +%%WWWDIR%%/dijit/form/NumberSpinner.js +%%WWWDIR%%/dijit/form/NumberTextBox.js +%%WWWDIR%%/dijit/form/SimpleTextarea.js +%%WWWDIR%%/dijit/form/Slider.js +%%WWWDIR%%/dijit/form/TextBox.js +%%WWWDIR%%/dijit/form/Textarea.js +%%WWWDIR%%/dijit/form/TimeTextBox.js +%%WWWDIR%%/dijit/form/ValidationTextBox.js +%%WWWDIR%%/dijit/form/_DateTimeTextBox.js +%%WWWDIR%%/dijit/form/_FormWidget.js +%%WWWDIR%%/dijit/form/_Spinner.js +%%WWWDIR%%/dijit/form/nls/ComboBox.js +%%WWWDIR%%/dijit/form/nls/Textarea.js +%%WWWDIR%%/dijit/form/nls/ar/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ar/Textarea.js +%%WWWDIR%%/dijit/form/nls/ar/validate.js +%%WWWDIR%%/dijit/form/nls/ca/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ca/Textarea.js +%%WWWDIR%%/dijit/form/nls/ca/validate.js +%%WWWDIR%%/dijit/form/nls/cs/ComboBox.js +%%WWWDIR%%/dijit/form/nls/cs/Textarea.js +%%WWWDIR%%/dijit/form/nls/cs/validate.js +%%WWWDIR%%/dijit/form/nls/da/ComboBox.js +%%WWWDIR%%/dijit/form/nls/da/Textarea.js +%%WWWDIR%%/dijit/form/nls/da/validate.js +%%WWWDIR%%/dijit/form/nls/de/ComboBox.js +%%WWWDIR%%/dijit/form/nls/de/Textarea.js +%%WWWDIR%%/dijit/form/nls/de/validate.js +%%WWWDIR%%/dijit/form/nls/el/ComboBox.js +%%WWWDIR%%/dijit/form/nls/el/Textarea.js +%%WWWDIR%%/dijit/form/nls/el/validate.js +%%WWWDIR%%/dijit/form/nls/es/ComboBox.js +%%WWWDIR%%/dijit/form/nls/es/Textarea.js +%%WWWDIR%%/dijit/form/nls/es/validate.js +%%WWWDIR%%/dijit/form/nls/fi/ComboBox.js +%%WWWDIR%%/dijit/form/nls/fi/Textarea.js +%%WWWDIR%%/dijit/form/nls/fi/validate.js +%%WWWDIR%%/dijit/form/nls/fr/ComboBox.js +%%WWWDIR%%/dijit/form/nls/fr/Textarea.js +%%WWWDIR%%/dijit/form/nls/fr/validate.js +%%WWWDIR%%/dijit/form/nls/he/ComboBox.js +%%WWWDIR%%/dijit/form/nls/he/Textarea.js +%%WWWDIR%%/dijit/form/nls/he/validate.js +%%WWWDIR%%/dijit/form/nls/hu/ComboBox.js +%%WWWDIR%%/dijit/form/nls/hu/Textarea.js +%%WWWDIR%%/dijit/form/nls/hu/validate.js +%%WWWDIR%%/dijit/form/nls/it/ComboBox.js +%%WWWDIR%%/dijit/form/nls/it/Textarea.js +%%WWWDIR%%/dijit/form/nls/it/validate.js +%%WWWDIR%%/dijit/form/nls/ja/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ja/Textarea.js +%%WWWDIR%%/dijit/form/nls/ja/validate.js +%%WWWDIR%%/dijit/form/nls/ko/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ko/Textarea.js +%%WWWDIR%%/dijit/form/nls/ko/validate.js +%%WWWDIR%%/dijit/form/nls/nb/ComboBox.js +%%WWWDIR%%/dijit/form/nls/nb/Textarea.js +%%WWWDIR%%/dijit/form/nls/nb/validate.js +%%WWWDIR%%/dijit/form/nls/nl/ComboBox.js +%%WWWDIR%%/dijit/form/nls/nl/Textarea.js +%%WWWDIR%%/dijit/form/nls/nl/validate.js +%%WWWDIR%%/dijit/form/nls/pl/ComboBox.js +%%WWWDIR%%/dijit/form/nls/pl/Textarea.js +%%WWWDIR%%/dijit/form/nls/pl/validate.js +%%WWWDIR%%/dijit/form/nls/pt-pt/ComboBox.js +%%WWWDIR%%/dijit/form/nls/pt-pt/Textarea.js +%%WWWDIR%%/dijit/form/nls/pt-pt/validate.js +%%WWWDIR%%/dijit/form/nls/pt/ComboBox.js +%%WWWDIR%%/dijit/form/nls/pt/Textarea.js +%%WWWDIR%%/dijit/form/nls/pt/validate.js +%%WWWDIR%%/dijit/form/nls/ru/ComboBox.js +%%WWWDIR%%/dijit/form/nls/ru/Textarea.js +%%WWWDIR%%/dijit/form/nls/ru/validate.js +%%WWWDIR%%/dijit/form/nls/sk/ComboBox.js +%%WWWDIR%%/dijit/form/nls/sk/Textarea.js +%%WWWDIR%%/dijit/form/nls/sk/validate.js +%%WWWDIR%%/dijit/form/nls/sl/ComboBox.js +%%WWWDIR%%/dijit/form/nls/sl/Textarea.js +%%WWWDIR%%/dijit/form/nls/sl/validate.js +%%WWWDIR%%/dijit/form/nls/sv/ComboBox.js +%%WWWDIR%%/dijit/form/nls/sv/Textarea.js +%%WWWDIR%%/dijit/form/nls/sv/validate.js +%%WWWDIR%%/dijit/form/nls/th/ComboBox.js +%%WWWDIR%%/dijit/form/nls/th/Textarea.js +%%WWWDIR%%/dijit/form/nls/th/validate.js +%%WWWDIR%%/dijit/form/nls/tr/ComboBox.js +%%WWWDIR%%/dijit/form/nls/tr/Textarea.js +%%WWWDIR%%/dijit/form/nls/tr/validate.js +%%WWWDIR%%/dijit/form/nls/validate.js +%%WWWDIR%%/dijit/form/nls/zh-tw/ComboBox.js +%%WWWDIR%%/dijit/form/nls/zh-tw/Textarea.js +%%WWWDIR%%/dijit/form/nls/zh-tw/validate.js +%%WWWDIR%%/dijit/form/nls/zh/ComboBox.js +%%WWWDIR%%/dijit/form/nls/zh/Textarea.js +%%WWWDIR%%/dijit/form/nls/zh/validate.js +%%WWWDIR%%/dijit/layout/AccordionContainer.js +%%WWWDIR%%/dijit/layout/BorderContainer.js +%%WWWDIR%%/dijit/layout/ContentPane.js +%%WWWDIR%%/dijit/layout/LayoutContainer.js +%%WWWDIR%%/dijit/layout/LinkPane.js +%%WWWDIR%%/dijit/layout/SplitContainer.js +%%WWWDIR%%/dijit/layout/StackContainer.js +%%WWWDIR%%/dijit/layout/TabContainer.js +%%WWWDIR%%/dijit/layout/_LayoutWidget.js +%%WWWDIR%%/dijit/nls/ar/common.js +%%WWWDIR%%/dijit/nls/ar/loading.js +%%WWWDIR%%/dijit/nls/ca/common.js +%%WWWDIR%%/dijit/nls/ca/loading.js +%%WWWDIR%%/dijit/nls/common.js +%%WWWDIR%%/dijit/nls/cs/common.js +%%WWWDIR%%/dijit/nls/cs/loading.js +%%WWWDIR%%/dijit/nls/da/common.js +%%WWWDIR%%/dijit/nls/da/loading.js +%%WWWDIR%%/dijit/nls/de/common.js +%%WWWDIR%%/dijit/nls/de/loading.js +%%WWWDIR%%/dijit/nls/dijit-all_ROOT.js +%%WWWDIR%%/dijit/nls/dijit-all_ar.js +%%WWWDIR%%/dijit/nls/dijit-all_ca.js +%%WWWDIR%%/dijit/nls/dijit-all_cs.js +%%WWWDIR%%/dijit/nls/dijit-all_da.js +%%WWWDIR%%/dijit/nls/dijit-all_de-de.js +%%WWWDIR%%/dijit/nls/dijit-all_de.js +%%WWWDIR%%/dijit/nls/dijit-all_el.js +%%WWWDIR%%/dijit/nls/dijit-all_en-gb.js +%%WWWDIR%%/dijit/nls/dijit-all_en-us.js +%%WWWDIR%%/dijit/nls/dijit-all_en.js +%%WWWDIR%%/dijit/nls/dijit-all_es-es.js +%%WWWDIR%%/dijit/nls/dijit-all_es.js +%%WWWDIR%%/dijit/nls/dijit-all_fi-fi.js +%%WWWDIR%%/dijit/nls/dijit-all_fi.js +%%WWWDIR%%/dijit/nls/dijit-all_fr-fr.js +%%WWWDIR%%/dijit/nls/dijit-all_fr.js +%%WWWDIR%%/dijit/nls/dijit-all_he-il.js +%%WWWDIR%%/dijit/nls/dijit-all_he.js +%%WWWDIR%%/dijit/nls/dijit-all_hu.js +%%WWWDIR%%/dijit/nls/dijit-all_it-it.js +%%WWWDIR%%/dijit/nls/dijit-all_it.js +%%WWWDIR%%/dijit/nls/dijit-all_ja-jp.js +%%WWWDIR%%/dijit/nls/dijit-all_ja.js +%%WWWDIR%%/dijit/nls/dijit-all_ko-kr.js +%%WWWDIR%%/dijit/nls/dijit-all_ko.js +%%WWWDIR%%/dijit/nls/dijit-all_nl-nl.js +%%WWWDIR%%/dijit/nls/dijit-all_nl.js +%%WWWDIR%%/dijit/nls/dijit-all_no.js +%%WWWDIR%%/dijit/nls/dijit-all_pl.js +%%WWWDIR%%/dijit/nls/dijit-all_pt-br.js +%%WWWDIR%%/dijit/nls/dijit-all_pt-pt.js +%%WWWDIR%%/dijit/nls/dijit-all_pt.js +%%WWWDIR%%/dijit/nls/dijit-all_ru.js +%%WWWDIR%%/dijit/nls/dijit-all_sk.js +%%WWWDIR%%/dijit/nls/dijit-all_sl.js +%%WWWDIR%%/dijit/nls/dijit-all_sv.js +%%WWWDIR%%/dijit/nls/dijit-all_th.js +%%WWWDIR%%/dijit/nls/dijit-all_tr.js +%%WWWDIR%%/dijit/nls/dijit-all_xx.js +%%WWWDIR%%/dijit/nls/dijit-all_zh-cn.js +%%WWWDIR%%/dijit/nls/dijit-all_zh-tw.js +%%WWWDIR%%/dijit/nls/dijit-all_zh.js +%%WWWDIR%%/dijit/nls/el/common.js +%%WWWDIR%%/dijit/nls/el/loading.js +%%WWWDIR%%/dijit/nls/es/common.js +%%WWWDIR%%/dijit/nls/es/loading.js +%%WWWDIR%%/dijit/nls/fi/common.js +%%WWWDIR%%/dijit/nls/fi/loading.js +%%WWWDIR%%/dijit/nls/fr/common.js +%%WWWDIR%%/dijit/nls/fr/loading.js +%%WWWDIR%%/dijit/nls/he/common.js +%%WWWDIR%%/dijit/nls/he/loading.js +%%WWWDIR%%/dijit/nls/hu/common.js +%%WWWDIR%%/dijit/nls/hu/loading.js +%%WWWDIR%%/dijit/nls/it/common.js +%%WWWDIR%%/dijit/nls/it/loading.js +%%WWWDIR%%/dijit/nls/ja/common.js +%%WWWDIR%%/dijit/nls/ja/loading.js +%%WWWDIR%%/dijit/nls/ko/common.js +%%WWWDIR%%/dijit/nls/ko/loading.js +%%WWWDIR%%/dijit/nls/loading.js +%%WWWDIR%%/dijit/nls/nb/common.js +%%WWWDIR%%/dijit/nls/nb/loading.js +%%WWWDIR%%/dijit/nls/nl/common.js +%%WWWDIR%%/dijit/nls/nl/loading.js +%%WWWDIR%%/dijit/nls/pl/common.js +%%WWWDIR%%/dijit/nls/pl/loading.js +%%WWWDIR%%/dijit/nls/pt-pt/common.js +%%WWWDIR%%/dijit/nls/pt-pt/loading.js +%%WWWDIR%%/dijit/nls/pt/common.js +%%WWWDIR%%/dijit/nls/pt/loading.js +%%WWWDIR%%/dijit/nls/ru/common.js +%%WWWDIR%%/dijit/nls/ru/loading.js +%%WWWDIR%%/dijit/nls/sk/common.js +%%WWWDIR%%/dijit/nls/sk/loading.js +%%WWWDIR%%/dijit/nls/sl/common.js +%%WWWDIR%%/dijit/nls/sl/loading.js +%%WWWDIR%%/dijit/nls/sv/common.js +%%WWWDIR%%/dijit/nls/sv/loading.js +%%WWWDIR%%/dijit/nls/th/common.js +%%WWWDIR%%/dijit/nls/th/loading.js +%%WWWDIR%%/dijit/nls/tr/common.js +%%WWWDIR%%/dijit/nls/tr/loading.js +%%WWWDIR%%/dijit/nls/zh-tw/common.js +%%WWWDIR%%/dijit/nls/zh-tw/loading.js +%%WWWDIR%%/dijit/nls/zh/common.js +%%WWWDIR%%/dijit/nls/zh/loading.js +%%WWWDIR%%/dijit/resources/_modules.js +%%WWWDIR%%/dijit/robot.js +%%WWWDIR%%/dijit/robotx.js +%%WWWDIR%%/dijit/themes/a11y/README.txt +%%WWWDIR%%/dijit/themes/a11y/colors3x4.png +%%WWWDIR%%/dijit/themes/a11y/colors7x10.png +%%WWWDIR%%/dijit/themes/a11y/indeterminate_progress.gif +%%WWWDIR%%/dijit/themes/dijit.css +%%WWWDIR%%/dijit/themes/dijit_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Calendar.css +%%WWWDIR%%/dijit/themes/nihilo/Calendar_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/ColorPalette.css +%%WWWDIR%%/dijit/themes/nihilo/Common.css +%%WWWDIR%%/dijit/themes/nihilo/Dialog.css +%%WWWDIR%%/dijit/themes/nihilo/Dialog_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Editor.css +%%WWWDIR%%/dijit/themes/nihilo/Editor_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Menu.css +%%WWWDIR%%/dijit/themes/nihilo/Menu_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/ProgressBar.css +%%WWWDIR%%/dijit/themes/nihilo/TimePicker.css +%%WWWDIR%%/dijit/themes/nihilo/TitlePane.css +%%WWWDIR%%/dijit/themes/nihilo/TitlePane_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/Toolbar.css +%%WWWDIR%%/dijit/themes/nihilo/Tree.css +%%WWWDIR%%/dijit/themes/nihilo/Tree_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/Button.css +%%WWWDIR%%/dijit/themes/nihilo/form/Button_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/Checkbox.css +%%WWWDIR%%/dijit/themes/nihilo/form/ComboBox.css +%%WWWDIR%%/dijit/themes/nihilo/form/Common.css +%%WWWDIR%%/dijit/themes/nihilo/form/Common_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/RadioButton.css +%%WWWDIR%%/dijit/themes/nihilo/form/Slider.css +%%WWWDIR%%/dijit/themes/nihilo/form/Slider_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/form/TimeTextBox.css +%%WWWDIR%%/dijit/themes/nihilo/images/accordionItemActive.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonActive.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonDisabled.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonEnabled.png +%%WWWDIR%%/dijit/themes/nihilo/images/buttonHover.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndCopy.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndMove.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndNoCopy.png +%%WWWDIR%%/dijit/themes/nihilo/images/dndNoMove.png +%%WWWDIR%%/dijit/themes/nihilo/images/editor.gif +%%WWWDIR%%/dijit/themes/nihilo/images/editorDisabled.gif +%%WWWDIR%%/dijit/themes/nihilo/images/editorDisabled_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/editor_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/no.gif +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumb.gif +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/nihilo/images/preciseSliderThumbFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/progressBarAnim.gif +%%WWWDIR%%/dijit/themes/nihilo/images/progressBarEmpty.png +%%WWWDIR%%/dijit/themes/nihilo/images/progressBarFull.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderEmpty.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderEmptyVertical.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFull.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFullFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFullVertical.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderFullVerticalFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumb.gif +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/nihilo/images/sliderThumbFocus.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerH-thumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerH.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerV-thumb.png +%%WWWDIR%%/dijit/themes/nihilo/images/splitContainerSizerV.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteArrows.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteArrows.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteCheckbox.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteCheckbox.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteDivIcons.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteDivIcons.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRadio.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRadio.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRoundedIconsSmall.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteRoundedIconsSmall.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree.png +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/spriteTree_rtl.png +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomActiveC.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomActiveSpriteLR.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomEnabledC.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomEnabledSpriteLR.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomHoverC.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabBottomHoverSpriteLR.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabContainerSprite.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabLeftChecked.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabRightChecked.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripe.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripeBottom.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripeLeft.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tabStripeRight.gif +%%WWWDIR%%/dijit/themes/nihilo/images/titleBar.png +%%WWWDIR%%/dijit/themes/nihilo/images/titleBarActive.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorDown.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorDown.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorLeft.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorLeft.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorRight.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorRight.png +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorUp.gif +%%WWWDIR%%/dijit/themes/nihilo/images/tooltipConnectorUp.png +%%WWWDIR%%/dijit/themes/nihilo/images/treeExpand_loading.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI_half.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI_half_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/treeI_rtl.gif +%%WWWDIR%%/dijit/themes/nihilo/images/validationInputBg.gif +%%WWWDIR%%/dijit/themes/nihilo/images/validationInputBg.png +%%WWWDIR%%/dijit/themes/nihilo/images/warning.png +%%WWWDIR%%/dijit/themes/nihilo/layout/AccordionContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/AccordionContainer_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/layout/BorderContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/ContentPane.css +%%WWWDIR%%/dijit/themes/nihilo/layout/SplitContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/TabContainer.css +%%WWWDIR%%/dijit/themes/nihilo/layout/TabContainer_rtl.css +%%WWWDIR%%/dijit/themes/nihilo/nihilo.css +%%WWWDIR%%/dijit/themes/nihilo/nihilo_rtl.css +%%WWWDIR%%/dijit/themes/soria/Calendar.css +%%WWWDIR%%/dijit/themes/soria/Calendar_rtl.css +%%WWWDIR%%/dijit/themes/soria/ColorPalette.css +%%WWWDIR%%/dijit/themes/soria/Common.css +%%WWWDIR%%/dijit/themes/soria/Dialog.css +%%WWWDIR%%/dijit/themes/soria/Dialog_rtl.css +%%WWWDIR%%/dijit/themes/soria/Editor.css +%%WWWDIR%%/dijit/themes/soria/Editor_rtl.css +%%WWWDIR%%/dijit/themes/soria/Menu.css +%%WWWDIR%%/dijit/themes/soria/Menu_rtl.css +%%WWWDIR%%/dijit/themes/soria/ProgressBar.css +%%WWWDIR%%/dijit/themes/soria/TimePicker.css +%%WWWDIR%%/dijit/themes/soria/TitlePane.css +%%WWWDIR%%/dijit/themes/soria/TitlePane_rtl.css +%%WWWDIR%%/dijit/themes/soria/Toolbar.css +%%WWWDIR%%/dijit/themes/soria/Tree.css +%%WWWDIR%%/dijit/themes/soria/Tree_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/Button.css +%%WWWDIR%%/dijit/themes/soria/form/Button_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/Checkbox.css +%%WWWDIR%%/dijit/themes/soria/form/ComboBox.css +%%WWWDIR%%/dijit/themes/soria/form/Common.css +%%WWWDIR%%/dijit/themes/soria/form/Common_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/RadioButton.css +%%WWWDIR%%/dijit/themes/soria/form/Slider.css +%%WWWDIR%%/dijit/themes/soria/form/Slider_rtl.css +%%WWWDIR%%/dijit/themes/soria/form/TimeTextBox.css +%%WWWDIR%%/dijit/themes/soria/images/accordionItemActive.gif +%%WWWDIR%%/dijit/themes/soria/images/accordionItemActive.png +%%WWWDIR%%/dijit/themes/soria/images/buttonActive.png +%%WWWDIR%%/dijit/themes/soria/images/buttonDisabled.png +%%WWWDIR%%/dijit/themes/soria/images/buttonEnabled.png +%%WWWDIR%%/dijit/themes/soria/images/buttonHover.png +%%WWWDIR%%/dijit/themes/soria/images/dndCopy.png +%%WWWDIR%%/dijit/themes/soria/images/dndMove.png +%%WWWDIR%%/dijit/themes/soria/images/dndNoCopy.png +%%WWWDIR%%/dijit/themes/soria/images/dndNoMove.png +%%WWWDIR%%/dijit/themes/soria/images/editor.gif +%%WWWDIR%%/dijit/themes/soria/images/editorDisabled.gif +%%WWWDIR%%/dijit/themes/soria/images/editorDisabled_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/editor_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumb.gif +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumb.png +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/soria/images/preciseSliderThumbFocus.png +%%WWWDIR%%/dijit/themes/soria/images/progressBarAnim.gif +%%WWWDIR%%/dijit/themes/soria/images/progressBarEmpty.png +%%WWWDIR%%/dijit/themes/soria/images/progressBarFull.png +%%WWWDIR%%/dijit/themes/soria/images/sliderEmpty.png +%%WWWDIR%%/dijit/themes/soria/images/sliderEmptyVertical.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFull.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFullFocus.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFullVertical.png +%%WWWDIR%%/dijit/themes/soria/images/sliderFullVerticalFocus.png +%%WWWDIR%%/dijit/themes/soria/images/sliderThumb.gif +%%WWWDIR%%/dijit/themes/soria/images/sliderThumb.png +%%WWWDIR%%/dijit/themes/soria/images/sliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/soria/images/sliderThumbFocus.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerH-thumb.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerH.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerV-thumb.png +%%WWWDIR%%/dijit/themes/soria/images/splitContainerSizerV.png +%%WWWDIR%%/dijit/themes/soria/images/spriteArrows.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteArrows.png +%%WWWDIR%%/dijit/themes/soria/images/spriteCheckbox.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteCheckbox.png +%%WWWDIR%%/dijit/themes/soria/images/spriteDivIcons.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteDivIcons.png +%%WWWDIR%%/dijit/themes/soria/images/spriteRadio.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteRadio.png +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmall.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmall.png +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmallBl.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteRoundedIconsSmallBl.png +%%WWWDIR%%/dijit/themes/soria/images/spriteTree.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteTree.png +%%WWWDIR%%/dijit/themes/soria/images/spriteTree_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/spriteTree_rtl.png +%%WWWDIR%%/dijit/themes/soria/images/tabBottomActiveC.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomActiveSpriteLR.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomEnabledC.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomEnabledSpriteLR.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomHoverC.gif +%%WWWDIR%%/dijit/themes/soria/images/tabBottomHoverSpriteLR.gif +%%WWWDIR%%/dijit/themes/soria/images/tabContainerSprite.gif +%%WWWDIR%%/dijit/themes/soria/images/tabLeftChecked.gif +%%WWWDIR%%/dijit/themes/soria/images/tabRightChecked.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripe.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripeBottom.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripeLeft.gif +%%WWWDIR%%/dijit/themes/soria/images/tabStripeRight.gif +%%WWWDIR%%/dijit/themes/soria/images/titleBar.png +%%WWWDIR%%/dijit/themes/soria/images/titleBarActive.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorDown.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorDown.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorLeft.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorLeft.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorRight.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorRight.png +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorUp.gif +%%WWWDIR%%/dijit/themes/soria/images/tooltipConnectorUp.png +%%WWWDIR%%/dijit/themes/soria/images/treeExpand_loading.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI_half.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI_half_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/treeI_rtl.gif +%%WWWDIR%%/dijit/themes/soria/images/validationInputBg.gif +%%WWWDIR%%/dijit/themes/soria/images/validationInputBg.png +%%WWWDIR%%/dijit/themes/soria/images/warning.png +%%WWWDIR%%/dijit/themes/soria/layout/AccordionContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/AccordionContainer_rtl.css +%%WWWDIR%%/dijit/themes/soria/layout/BorderContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/ContentPane.css +%%WWWDIR%%/dijit/themes/soria/layout/SplitContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/TabContainer.css +%%WWWDIR%%/dijit/themes/soria/layout/TabContainer_rtl.css +%%WWWDIR%%/dijit/themes/soria/soria.css +%%WWWDIR%%/dijit/themes/soria/soria_rtl.css +%%WWWDIR%%/dijit/themes/templateThemeTest.html +%%WWWDIR%%/dijit/themes/themeTester.html +%%WWWDIR%%/dijit/themes/themeTesterImages/blackButtonEnabled.gif +%%WWWDIR%%/dijit/themes/themeTesterImages/blackButtonHover.gif +%%WWWDIR%%/dijit/themes/themeTesterQuirk.html +%%WWWDIR%%/dijit/themes/tundra/Calendar.css +%%WWWDIR%%/dijit/themes/tundra/Calendar_rtl.css +%%WWWDIR%%/dijit/themes/tundra/ColorPalette.css +%%WWWDIR%%/dijit/themes/tundra/Common.css +%%WWWDIR%%/dijit/themes/tundra/Dialog.css +%%WWWDIR%%/dijit/themes/tundra/Dialog_rtl.css +%%WWWDIR%%/dijit/themes/tundra/Editor.css +%%WWWDIR%%/dijit/themes/tundra/Editor_rtl.css +%%WWWDIR%%/dijit/themes/tundra/Menu.css +%%WWWDIR%%/dijit/themes/tundra/Menu_rtl.css +%%WWWDIR%%/dijit/themes/tundra/ProgressBar.css +%%WWWDIR%%/dijit/themes/tundra/TimePicker.css +%%WWWDIR%%/dijit/themes/tundra/TitlePane.css +%%WWWDIR%%/dijit/themes/tundra/TitlePane_rtl.css +%%WWWDIR%%/dijit/themes/tundra/Toolbar.css +%%WWWDIR%%/dijit/themes/tundra/Tree.css +%%WWWDIR%%/dijit/themes/tundra/Tree_rtl.css +%%WWWDIR%%/dijit/themes/tundra/form/Button.css +%%WWWDIR%%/dijit/themes/tundra/form/Checkbox.css +%%WWWDIR%%/dijit/themes/tundra/form/Common.css +%%WWWDIR%%/dijit/themes/tundra/form/Common_rtl.css +%%WWWDIR%%/dijit/themes/tundra/form/RadioButton.css +%%WWWDIR%%/dijit/themes/tundra/form/Slider.css +%%WWWDIR%%/dijit/themes/tundra/form/Slider_rtl.css +%%WWWDIR%%/dijit/themes/tundra/images/accordionItemActive.gif +%%WWWDIR%%/dijit/themes/tundra/images/accordionItemHover.gif +%%WWWDIR%%/dijit/themes/tundra/images/buttonActive.png +%%WWWDIR%%/dijit/themes/tundra/images/buttonDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/buttonEnabled.png +%%WWWDIR%%/dijit/themes/tundra/images/buttonHover.png +%%WWWDIR%%/dijit/themes/tundra/images/calendarDayLabel.png +%%WWWDIR%%/dijit/themes/tundra/images/calendarMonthLabel.png +%%WWWDIR%%/dijit/themes/tundra/images/calendarYearLabel.png +%%WWWDIR%%/dijit/themes/tundra/images/checkmark.gif +%%WWWDIR%%/dijit/themes/tundra/images/checkmark.png +%%WWWDIR%%/dijit/themes/tundra/images/checkmarkNoBorder.gif +%%WWWDIR%%/dijit/themes/tundra/images/checkmarkNoBorder.png +%%WWWDIR%%/dijit/themes/tundra/images/circleIcon.gif +%%WWWDIR%%/dijit/themes/tundra/images/circleIcon.png +%%WWWDIR%%/dijit/themes/tundra/images/comboArrowDown.gif +%%WWWDIR%%/dijit/themes/tundra/images/dijitProgressBarAnim.gif +%%WWWDIR%%/dijit/themes/tundra/images/dijitProgressBarAnim.psd +%%WWWDIR%%/dijit/themes/tundra/images/dndCopy.png +%%WWWDIR%%/dijit/themes/tundra/images/dndMove.png +%%WWWDIR%%/dijit/themes/tundra/images/dndNoCopy.png +%%WWWDIR%%/dijit/themes/tundra/images/dndNoMove.png +%%WWWDIR%%/dijit/themes/tundra/images/dojoTundraGradientBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/dojoTundraGradientBg.png +%%WWWDIR%%/dijit/themes/tundra/images/doubleArrowDown.png +%%WWWDIR%%/dijit/themes/tundra/images/doubleArrowUp.png +%%WWWDIR%%/dijit/themes/tundra/images/editor.gif +%%WWWDIR%%/dijit/themes/tundra/images/editorDisabled.gif +%%WWWDIR%%/dijit/themes/tundra/images/editorDisabled_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/editor_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/folderClosed.gif +%%WWWDIR%%/dijit/themes/tundra/images/folderOpened.gif +%%WWWDIR%%/dijit/themes/tundra/images/i.gif +%%WWWDIR%%/dijit/themes/tundra/images/i_half.gif +%%WWWDIR%%/dijit/themes/tundra/images/i_half_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/i_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/leaf.gif +%%WWWDIR%%/dijit/themes/tundra/images/loading.gif +%%WWWDIR%%/dijit/themes/tundra/images/menu.png +%%WWWDIR%%/dijit/themes/tundra/images/minusButton.gif +%%WWWDIR%%/dijit/themes/tundra/images/no.gif +%%WWWDIR%%/dijit/themes/tundra/images/noX.gif +%%WWWDIR%%/dijit/themes/tundra/images/plusButton.gif +%%WWWDIR%%/dijit/themes/tundra/images/popupMenuBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumb.gif +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumb.png +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/tundra/images/preciseSliderThumbFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-1.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-2.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-3.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-4.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-5.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-6.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-7.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-8.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim-9.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim.gif +%%WWWDIR%%/dijit/themes/tundra/images/progressBarAnim.psd +%%WWWDIR%%/dijit/themes/tundra/images/progressBarEmpty.png +%%WWWDIR%%/dijit/themes/tundra/images/progressBarFull.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonActive.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonActiveDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonActiveHover.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonEnabled.png +%%WWWDIR%%/dijit/themes/tundra/images/radioButtonHover.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderEmpty.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderEmptyVertical.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFull.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFullFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFullVertical.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderFullVerticalFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderThumb.png +%%WWWDIR%%/dijit/themes/tundra/images/sliderThumbFocus.gif +%%WWWDIR%%/dijit/themes/tundra/images/sliderThumbFocus.png +%%WWWDIR%%/dijit/themes/tundra/images/smallArrowDown.png +%%WWWDIR%%/dijit/themes/tundra/images/smallArrowUp.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerH-thumb.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerH.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerV-thumb.png +%%WWWDIR%%/dijit/themes/tundra/images/splitContainerSizerV.png +%%WWWDIR%%/dijit/themes/tundra/images/spriteArrows.gif +%%WWWDIR%%/dijit/themes/tundra/images/spriteArrows.png +%%WWWDIR%%/dijit/themes/tundra/images/spriteRoundedIconsSmall.gif +%%WWWDIR%%/dijit/themes/tundra/images/spriteRoundedIconsSmall.png +%%WWWDIR%%/dijit/themes/tundra/images/tabActive.png +%%WWWDIR%%/dijit/themes/tundra/images/tabClose.gif +%%WWWDIR%%/dijit/themes/tundra/images/tabClose.png +%%WWWDIR%%/dijit/themes/tundra/images/tabCloseHover.gif +%%WWWDIR%%/dijit/themes/tundra/images/tabCloseHover.png +%%WWWDIR%%/dijit/themes/tundra/images/tabDisabled.png +%%WWWDIR%%/dijit/themes/tundra/images/tabEnabled.png +%%WWWDIR%%/dijit/themes/tundra/images/tabHover.gif +%%WWWDIR%%/dijit/themes/tundra/images/tabHover.png +%%WWWDIR%%/dijit/themes/tundra/images/titleBar.png +%%WWWDIR%%/dijit/themes/tundra/images/titleBarBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorDown.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorDown.png +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorLeft.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorLeft.png +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorRight.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorRight.png +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorUp.gif +%%WWWDIR%%/dijit/themes/tundra/images/tooltipConnectorUp.png +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_leaf.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_leaf_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_loading.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_minus.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_minus_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_mius.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_plus.gif +%%WWWDIR%%/dijit/themes/tundra/images/treeExpand_plus_rtl.gif +%%WWWDIR%%/dijit/themes/tundra/images/validationInputBg.gif +%%WWWDIR%%/dijit/themes/tundra/images/validationInputBg.png +%%WWWDIR%%/dijit/themes/tundra/images/warning.png +%%WWWDIR%%/dijit/themes/tundra/layout/AccordionContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/BorderContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/ContentPane.css +%%WWWDIR%%/dijit/themes/tundra/layout/SplitContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/TabContainer.css +%%WWWDIR%%/dijit/themes/tundra/layout/TabContainer_rtl.css +%%WWWDIR%%/dijit/themes/tundra/tundra.css +%%WWWDIR%%/dojo/AdapterRegistry.js +%%WWWDIR%%/dojo/DeferredList.js +%%WWWDIR%%/dojo/LICENSE +%%WWWDIR%%/dojo/NodeList-fx.js +%%WWWDIR%%/dojo/NodeList-html.js +%%WWWDIR%%/dojo/OpenAjax.js +%%WWWDIR%%/dojo/_base.js +%%WWWDIR%%/dojo/_base/Color.js +%%WWWDIR%%/dojo/_base/Deferred.js +%%WWWDIR%%/dojo/_base/NodeList.js +%%WWWDIR%%/dojo/_base/_loader/bootstrap.js +%%WWWDIR%%/dojo/_base/_loader/hostenv_browser.js +%%WWWDIR%%/dojo/_base/_loader/hostenv_rhino.js +%%WWWDIR%%/dojo/_base/_loader/hostenv_spidermonkey.js +%%WWWDIR%%/dojo/_base/_loader/loader.js +%%WWWDIR%%/dojo/_base/_loader/loader_debug.js +%%WWWDIR%%/dojo/_base/_loader/loader_xd.js +%%WWWDIR%%/dojo/_base/array.js +%%WWWDIR%%/dojo/_base/browser.js +%%WWWDIR%%/dojo/_base/connect.js +%%WWWDIR%%/dojo/_base/declare.js +%%WWWDIR%%/dojo/_base/event.js +%%WWWDIR%%/dojo/_base/fx.js +%%WWWDIR%%/dojo/_base/html.js +%%WWWDIR%%/dojo/_base/json.js +%%WWWDIR%%/dojo/_base/lang.js +%%WWWDIR%%/dojo/_base/query.js +%%WWWDIR%%/dojo/_base/window.js +%%WWWDIR%%/dojo/_base/xhr.js +%%WWWDIR%%/dojo/_firebug/LICENSE +%%WWWDIR%%/dojo/_firebug/errorIcon.png +%%WWWDIR%%/dojo/_firebug/firebug.css +%%WWWDIR%%/dojo/_firebug/firebug.js +%%WWWDIR%%/dojo/_firebug/infoIcon.png +%%WWWDIR%%/dojo/_firebug/tab_lft_norm.png +%%WWWDIR%%/dojo/_firebug/tab_lft_over.png +%%WWWDIR%%/dojo/_firebug/tab_rgt_norm.png +%%WWWDIR%%/dojo/_firebug/tab_rgt_over.png +%%WWWDIR%%/dojo/_firebug/warningIcon.png +%%WWWDIR%%/dojo/back.js +%%WWWDIR%%/dojo/behavior.js +%%WWWDIR%%/dojo/build.txt +%%WWWDIR%%/dojo/cldr/LICENSE +%%WWWDIR%%/dojo/cldr/README +%%WWWDIR%%/dojo/cldr/monetary.js +%%WWWDIR%%/dojo/cldr/nls/currency.js +%%WWWDIR%%/dojo/cldr/nls/de-de/number.js +%%WWWDIR%%/dojo/cldr/nls/de/currency.js +%%WWWDIR%%/dojo/cldr/nls/de/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/de/number.js +%%WWWDIR%%/dojo/cldr/nls/en-au/currency.js +%%WWWDIR%%/dojo/cldr/nls/en-au/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en-au/number.js +%%WWWDIR%%/dojo/cldr/nls/en-ca/currency.js +%%WWWDIR%%/dojo/cldr/nls/en-ca/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en-gb/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en-gb/number.js +%%WWWDIR%%/dojo/cldr/nls/en-us/currency.js +%%WWWDIR%%/dojo/cldr/nls/en-us/number.js +%%WWWDIR%%/dojo/cldr/nls/en/currency.js +%%WWWDIR%%/dojo/cldr/nls/en/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/en/number.js +%%WWWDIR%%/dojo/cldr/nls/es-es/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/es-es/number.js +%%WWWDIR%%/dojo/cldr/nls/es/currency.js +%%WWWDIR%%/dojo/cldr/nls/es/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/es/number.js +%%WWWDIR%%/dojo/cldr/nls/fr/currency.js +%%WWWDIR%%/dojo/cldr/nls/fr/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/fr/number.js +%%WWWDIR%%/dojo/cldr/nls/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/it-it/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/it/currency.js +%%WWWDIR%%/dojo/cldr/nls/it/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/it/number.js +%%WWWDIR%%/dojo/cldr/nls/ja-jp/number.js +%%WWWDIR%%/dojo/cldr/nls/ja/currency.js +%%WWWDIR%%/dojo/cldr/nls/ja/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/ja/number.js +%%WWWDIR%%/dojo/cldr/nls/ko-kr/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/ko-kr/number.js +%%WWWDIR%%/dojo/cldr/nls/ko/currency.js +%%WWWDIR%%/dojo/cldr/nls/ko/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/ko/number.js +%%WWWDIR%%/dojo/cldr/nls/number.js +%%WWWDIR%%/dojo/cldr/nls/pt-br/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/pt/currency.js +%%WWWDIR%%/dojo/cldr/nls/pt/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/pt/number.js +%%WWWDIR%%/dojo/cldr/nls/zh-cn/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/zh-cn/number.js +%%WWWDIR%%/dojo/cldr/nls/zh-tw/currency.js +%%WWWDIR%%/dojo/cldr/nls/zh-tw/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/zh-tw/number.js +%%WWWDIR%%/dojo/cldr/nls/zh/currency.js +%%WWWDIR%%/dojo/cldr/nls/zh/gregorian.js +%%WWWDIR%%/dojo/cldr/nls/zh/number.js +%%WWWDIR%%/dojo/cldr/supplemental.js +%%WWWDIR%%/dojo/colors.js +%%WWWDIR%%/dojo/cookie.js +%%WWWDIR%%/dojo/currency.js +%%WWWDIR%%/dojo/data/ItemFileReadStore.js +%%WWWDIR%%/dojo/data/ItemFileWriteStore.js +%%WWWDIR%%/dojo/data/api/Identity.js +%%WWWDIR%%/dojo/data/api/Notification.js +%%WWWDIR%%/dojo/data/api/Read.js +%%WWWDIR%%/dojo/data/api/Request.js +%%WWWDIR%%/dojo/data/api/Write.js +%%WWWDIR%%/dojo/data/util/filter.js +%%WWWDIR%%/dojo/data/util/simpleFetch.js +%%WWWDIR%%/dojo/data/util/sorter.js +%%WWWDIR%%/dojo/date.js +%%WWWDIR%%/dojo/date/locale.js +%%WWWDIR%%/dojo/date/stamp.js +%%WWWDIR%%/dojo/dnd/Avatar.js +%%WWWDIR%%/dojo/dnd/Container.js +%%WWWDIR%%/dojo/dnd/Manager.js +%%WWWDIR%%/dojo/dnd/Moveable.js +%%WWWDIR%%/dojo/dnd/Mover.js +%%WWWDIR%%/dojo/dnd/Selector.js +%%WWWDIR%%/dojo/dnd/Source.js +%%WWWDIR%%/dojo/dnd/TimedMoveable.js +%%WWWDIR%%/dojo/dnd/autoscroll.js +%%WWWDIR%%/dojo/dnd/common.js +%%WWWDIR%%/dojo/dnd/move.js +%%WWWDIR%%/dojo/dojo.js +%%WWWDIR%%/dojo/fx.js +%%WWWDIR%%/dojo/fx/easing.js +%%WWWDIR%%/dojo/gears.js +%%WWWDIR%%/dojo/html.js +%%WWWDIR%%/dojo/i18n.js +%%WWWDIR%%/dojo/io/iframe.js +%%WWWDIR%%/dojo/io/script.js +%%WWWDIR%%/dojo/jaxer.js +%%WWWDIR%%/dojo/nls/ar/colors.js +%%WWWDIR%%/dojo/nls/ca/colors.js +%%WWWDIR%%/dojo/nls/colors.js +%%WWWDIR%%/dojo/nls/cs/colors.js +%%WWWDIR%%/dojo/nls/da/colors.js +%%WWWDIR%%/dojo/nls/de/colors.js +%%WWWDIR%%/dojo/nls/el/colors.js +%%WWWDIR%%/dojo/nls/es/colors.js +%%WWWDIR%%/dojo/nls/fi/colors.js +%%WWWDIR%%/dojo/nls/fr/colors.js +%%WWWDIR%%/dojo/nls/he/colors.js +%%WWWDIR%%/dojo/nls/hu/colors.js +%%WWWDIR%%/dojo/nls/it/colors.js +%%WWWDIR%%/dojo/nls/ja/colors.js +%%WWWDIR%%/dojo/nls/ko/colors.js +%%WWWDIR%%/dojo/nls/nb/colors.js +%%WWWDIR%%/dojo/nls/nl/colors.js +%%WWWDIR%%/dojo/nls/pl/colors.js +%%WWWDIR%%/dojo/nls/pt-pt/colors.js +%%WWWDIR%%/dojo/nls/pt/colors.js +%%WWWDIR%%/dojo/nls/ru/colors.js +%%WWWDIR%%/dojo/nls/sk/colors.js +%%WWWDIR%%/dojo/nls/sl/colors.js +%%WWWDIR%%/dojo/nls/sv/colors.js +%%WWWDIR%%/dojo/nls/th/colors.js +%%WWWDIR%%/dojo/nls/tr/colors.js +%%WWWDIR%%/dojo/nls/zh-tw/colors.js +%%WWWDIR%%/dojo/nls/zh/colors.js +%%WWWDIR%%/dojo/number.js +%%WWWDIR%%/dojo/parser.js +%%WWWDIR%%/dojo/regexp.js +%%WWWDIR%%/dojo/resources/LICENSE +%%WWWDIR%%/dojo/resources/_modules.js +%%WWWDIR%%/dojo/resources/blank.gif +%%WWWDIR%%/dojo/resources/blank.html +%%WWWDIR%%/dojo/resources/dnd.css +%%WWWDIR%%/dojo/resources/dojo.css +%%WWWDIR%%/dojo/resources/iframe_history.html +%%WWWDIR%%/dojo/resources/images/dndCopy.png +%%WWWDIR%%/dojo/resources/images/dndMove.png +%%WWWDIR%%/dojo/resources/images/dndNoCopy.png +%%WWWDIR%%/dojo/resources/images/dndNoMove.png +%%WWWDIR%%/dojo/robot.js +%%WWWDIR%%/dojo/robotx.js +%%WWWDIR%%/dojo/rpc/JsonService.js +%%WWWDIR%%/dojo/rpc/JsonpService.js +%%WWWDIR%%/dojo/rpc/RpcService.js +%%WWWDIR%%/dojo/string.js +%%WWWDIR%%/dojox/LICENSE +%%WWWDIR%%/dojox/analytics.js +%%WWWDIR%%/dojox/analytics/README +%%WWWDIR%%/dojox/analytics/Urchin.js +%%WWWDIR%%/dojox/analytics/_base.js +%%WWWDIR%%/dojox/analytics/logger/JSON.php +%%WWWDIR%%/dojox/analytics/logger/dojoxAnalytics.php +%%WWWDIR%%/dojox/analytics/plugins/consoleMessages.js +%%WWWDIR%%/dojox/analytics/plugins/dojo.js +%%WWWDIR%%/dojox/analytics/plugins/idle.js +%%WWWDIR%%/dojox/analytics/plugins/mouseClick.js +%%WWWDIR%%/dojox/analytics/plugins/mouseOver.js +%%WWWDIR%%/dojox/analytics/plugins/window.js +%%WWWDIR%%/dojox/analytics/profiles/analytics.profile.js +%%WWWDIR%%/dojox/analytics/profiles/analyticsInBase.profile.js +%%WWWDIR%%/dojox/av/FLVideo.js +%%WWWDIR%%/dojox/av/README +%%WWWDIR%%/dojox/av/_Media.js +%%WWWDIR%%/dojox/av/resources/version.mov +%%WWWDIR%%/dojox/av/resources/video.swf +%%WWWDIR%%/dojox/av/widget/PlayButton.js +%%WWWDIR%%/dojox/av/widget/Player.js +%%WWWDIR%%/dojox/av/widget/ProgressSlider.js +%%WWWDIR%%/dojox/av/widget/Status.js +%%WWWDIR%%/dojox/av/widget/VolumeButton.js +%%WWWDIR%%/dojox/av/widget/resources/PlayButton.html +%%WWWDIR%%/dojox/av/widget/resources/Player.css +%%WWWDIR%%/dojox/av/widget/resources/Player.html +%%WWWDIR%%/dojox/av/widget/resources/ProgressSlider.html +%%WWWDIR%%/dojox/av/widget/resources/Status.html +%%WWWDIR%%/dojox/av/widget/resources/VolumeButton.html +%%WWWDIR%%/dojox/av/widget/resources/images/dojoPlayerIcons.png +%%WWWDIR%%/dojox/av/widget/resources/images/playerIcons +%%WWWDIR%%/dojox/av/widget/resources/images/player_sprite.png +%%WWWDIR%%/dojox/av/widget/resources/images/progressLoadedBk.png +%%WWWDIR%%/dojox/av/widget/resources/images/progressPositionBk.png +%%WWWDIR%%/dojox/av/widget/resources/images/sliderHandleNorm.png +%%WWWDIR%%/dojox/av/widget/resources/images/sliderHandleOver.png +%%WWWDIR%%/dojox/av/widget/resources/images/sliderHandleSprite.png +%%WWWDIR%%/dojox/charting/Chart2D.js +%%WWWDIR%%/dojox/charting/Chart3D.js +%%WWWDIR%%/dojox/charting/Element.js +%%WWWDIR%%/dojox/charting/README +%%WWWDIR%%/dojox/charting/Series.js +%%WWWDIR%%/dojox/charting/Theme.js +%%WWWDIR%%/dojox/charting/action2d/Base.js +%%WWWDIR%%/dojox/charting/action2d/Highlight.js +%%WWWDIR%%/dojox/charting/action2d/Magnify.js +%%WWWDIR%%/dojox/charting/action2d/MoveSlice.js +%%WWWDIR%%/dojox/charting/action2d/Shake.js +%%WWWDIR%%/dojox/charting/action2d/Tooltip.js +%%WWWDIR%%/dojox/charting/axis2d/Base.js +%%WWWDIR%%/dojox/charting/axis2d/Default.js +%%WWWDIR%%/dojox/charting/axis2d/common.js +%%WWWDIR%%/dojox/charting/plot2d/Areas.js +%%WWWDIR%%/dojox/charting/plot2d/Bars.js +%%WWWDIR%%/dojox/charting/plot2d/Base.js +%%WWWDIR%%/dojox/charting/plot2d/Bubble.js +%%WWWDIR%%/dojox/charting/plot2d/ClusteredBars.js +%%WWWDIR%%/dojox/charting/plot2d/ClusteredColumns.js +%%WWWDIR%%/dojox/charting/plot2d/Columns.js +%%WWWDIR%%/dojox/charting/plot2d/Default.js +%%WWWDIR%%/dojox/charting/plot2d/Grid.js +%%WWWDIR%%/dojox/charting/plot2d/Lines.js +%%WWWDIR%%/dojox/charting/plot2d/Markers.js +%%WWWDIR%%/dojox/charting/plot2d/MarkersOnly.js +%%WWWDIR%%/dojox/charting/plot2d/Pie.js +%%WWWDIR%%/dojox/charting/plot2d/Scatter.js +%%WWWDIR%%/dojox/charting/plot2d/Stacked.js +%%WWWDIR%%/dojox/charting/plot2d/StackedAreas.js +%%WWWDIR%%/dojox/charting/plot2d/StackedBars.js +%%WWWDIR%%/dojox/charting/plot2d/StackedColumns.js +%%WWWDIR%%/dojox/charting/plot2d/StackedLines.js +%%WWWDIR%%/dojox/charting/plot2d/common.js +%%WWWDIR%%/dojox/charting/plot3d/Bars.js +%%WWWDIR%%/dojox/charting/plot3d/Base.js +%%WWWDIR%%/dojox/charting/plot3d/Cylinders.js +%%WWWDIR%%/dojox/charting/scaler/common.js +%%WWWDIR%%/dojox/charting/scaler/linear.js +%%WWWDIR%%/dojox/charting/scaler/primitive.js +%%WWWDIR%%/dojox/charting/themes/Adobebricks.js +%%WWWDIR%%/dojox/charting/themes/Algae.js +%%WWWDIR%%/dojox/charting/themes/Bahamation.js +%%WWWDIR%%/dojox/charting/themes/BlueDusk.js +%%WWWDIR%%/dojox/charting/themes/CubanShirts.js +%%WWWDIR%%/dojox/charting/themes/Desert.js +%%WWWDIR%%/dojox/charting/themes/Dollar.js +%%WWWDIR%%/dojox/charting/themes/ET/greys.js +%%WWWDIR%%/dojox/charting/themes/Grasshopper.js +%%WWWDIR%%/dojox/charting/themes/Grasslands.js +%%WWWDIR%%/dojox/charting/themes/GreySkies.js +%%WWWDIR%%/dojox/charting/themes/IndigoNation.js +%%WWWDIR%%/dojox/charting/themes/Ireland.js +%%WWWDIR%%/dojox/charting/themes/MiamiNice.js +%%WWWDIR%%/dojox/charting/themes/Midwest.js +%%WWWDIR%%/dojox/charting/themes/Minty.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/README +%%WWWDIR%%/dojox/charting/themes/PlotKit/blue.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/cyan.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/green.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/orange.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/purple.js +%%WWWDIR%%/dojox/charting/themes/PlotKit/red.js +%%WWWDIR%%/dojox/charting/themes/PurpleRain.js +%%WWWDIR%%/dojox/charting/themes/README +%%WWWDIR%%/dojox/charting/themes/RoyalPurples.js +%%WWWDIR%%/dojox/charting/themes/SageToLime.js +%%WWWDIR%%/dojox/charting/themes/Shrooms.js +%%WWWDIR%%/dojox/charting/themes/Tufte.js +%%WWWDIR%%/dojox/charting/themes/WatersEdge.js +%%WWWDIR%%/dojox/charting/themes/Wetland.js +%%WWWDIR%%/dojox/charting/widget/Chart2D.js +%%WWWDIR%%/dojox/charting/widget/Legend.js +%%WWWDIR%%/dojox/charting/widget/Sparkline.js +%%WWWDIR%%/dojox/collections.js +%%WWWDIR%%/dojox/collections/ArrayList.js +%%WWWDIR%%/dojox/collections/BinaryTree.js +%%WWWDIR%%/dojox/collections/Dictionary.js +%%WWWDIR%%/dojox/collections/Queue.js +%%WWWDIR%%/dojox/collections/README +%%WWWDIR%%/dojox/collections/Set.js +%%WWWDIR%%/dojox/collections/SortedList.js +%%WWWDIR%%/dojox/collections/Stack.js +%%WWWDIR%%/dojox/collections/_base.js +%%WWWDIR%%/dojox/color.js +%%WWWDIR%%/dojox/color/Colorspace.js +%%WWWDIR%%/dojox/color/Generator.js +%%WWWDIR%%/dojox/color/Palette.js +%%WWWDIR%%/dojox/color/README +%%WWWDIR%%/dojox/color/_base.js +%%WWWDIR%%/dojox/cometd.js +%%WWWDIR%%/dojox/cometd/HttpChannels.js +%%WWWDIR%%/dojox/cometd/README +%%WWWDIR%%/dojox/cometd/RestChannels.js +%%WWWDIR%%/dojox/cometd/_base.js +%%WWWDIR%%/dojox/cometd/callbackPollTransport.js +%%WWWDIR%%/dojox/cometd/longPollTransport.js +%%WWWDIR%%/dojox/cometd/longPollTransportFormEncoded.js +%%WWWDIR%%/dojox/cometd/longPollTransportJsonEncoded.js +%%WWWDIR%%/dojox/cometd/timestamp.js +%%WWWDIR%%/dojox/cometd/timesync.js +%%WWWDIR%%/dojox/data/AndOrReadStore.js +%%WWWDIR%%/dojox/data/AndOrWriteStore.js +%%WWWDIR%%/dojox/data/AtomReadStore.js +%%WWWDIR%%/dojox/data/ClientFilter.js +%%WWWDIR%%/dojox/data/CouchDBRestStore.js +%%WWWDIR%%/dojox/data/CssClassStore.js +%%WWWDIR%%/dojox/data/CssRuleStore.js +%%WWWDIR%%/dojox/data/CsvStore.js +%%WWWDIR%%/dojox/data/FileStore.js +%%WWWDIR%%/dojox/data/FlickrRestStore.js +%%WWWDIR%%/dojox/data/FlickrStore.js +%%WWWDIR%%/dojox/data/GoogleFeedStore.js +%%WWWDIR%%/dojox/data/GoogleSearchStore.js +%%WWWDIR%%/dojox/data/HtmlStore.js +%%WWWDIR%%/dojox/data/HtmlTableStore.js +%%WWWDIR%%/dojox/data/JsonRestStore.js +%%WWWDIR%%/dojox/data/KeyValueStore.js +%%WWWDIR%%/dojox/data/OpmlStore.js +%%WWWDIR%%/dojox/data/PersevereStore.js +%%WWWDIR%%/dojox/data/PicasaStore.js +%%WWWDIR%%/dojox/data/QueryReadStore.js +%%WWWDIR%%/dojox/data/README +%%WWWDIR%%/dojox/data/S3Store.js +%%WWWDIR%%/dojox/data/ServiceStore.js +%%WWWDIR%%/dojox/data/SnapLogicStore.js +%%WWWDIR%%/dojox/data/WikipediaStore.js +%%WWWDIR%%/dojox/data/XmlStore.js +%%WWWDIR%%/dojox/data/css.js +%%WWWDIR%%/dojox/data/dom.js +%%WWWDIR%%/dojox/data/jsonPathStore.js +%%WWWDIR%%/dojox/data/restListener.js +%%WWWDIR%%/dojox/data/s3/README +%%WWWDIR%%/dojox/data/s3/proxy.example-php +%%WWWDIR%%/dojox/date/HebrewDate.js +%%WWWDIR%%/dojox/date/IslamicDate.js +%%WWWDIR%%/dojox/date/README +%%WWWDIR%%/dojox/date/php.js +%%WWWDIR%%/dojox/date/posix.js +%%WWWDIR%%/dojox/dtl.js +%%WWWDIR%%/dojox/dtl/Context.js +%%WWWDIR%%/dojox/dtl/README +%%WWWDIR%%/dojox/dtl/_HtmlTemplated.js +%%WWWDIR%%/dojox/dtl/_Templated.js +%%WWWDIR%%/dojox/dtl/_base.js +%%WWWDIR%%/dojox/dtl/contrib/data.js +%%WWWDIR%%/dojox/dtl/contrib/dijit.js +%%WWWDIR%%/dojox/dtl/contrib/html.js +%%WWWDIR%%/dojox/dtl/contrib/objects.js +%%WWWDIR%%/dojox/dtl/ext-dojo/NodeList.js +%%WWWDIR%%/dojox/dtl/filter/dates.js +%%WWWDIR%%/dojox/dtl/filter/htmlstrings.js +%%WWWDIR%%/dojox/dtl/filter/integers.js +%%WWWDIR%%/dojox/dtl/filter/lists.js +%%WWWDIR%%/dojox/dtl/filter/logic.js +%%WWWDIR%%/dojox/dtl/filter/misc.js +%%WWWDIR%%/dojox/dtl/filter/strings.js +%%WWWDIR%%/dojox/dtl/html.js +%%WWWDIR%%/dojox/dtl/render/html.js +%%WWWDIR%%/dojox/dtl/tag/date.js +%%WWWDIR%%/dojox/dtl/tag/loader.js +%%WWWDIR%%/dojox/dtl/tag/logic.js +%%WWWDIR%%/dojox/dtl/tag/loop.js +%%WWWDIR%%/dojox/dtl/tag/misc.js +%%WWWDIR%%/dojox/dtl/utils/date.js +%%WWWDIR%%/dojox/editor/README +%%WWWDIR%%/dojox/editor/plugins/TablePlugins.js +%%WWWDIR%%/dojox/editor/plugins/UploadImage.js +%%WWWDIR%%/dojox/editor/plugins/nls/TableDialog.js +%%WWWDIR%%/dojox/editor/plugins/resources/editorPlugins.css +%%WWWDIR%%/dojox/editor/plugins/resources/images/busy.gif +%%WWWDIR%%/dojox/editor/plugins/resources/images/cellpad.png +%%WWWDIR%%/dojox/editor/plugins/resources/images/cellspace.png +%%WWWDIR%%/dojox/editor/plugins/resources/images/tableIcons.png +%%WWWDIR%%/dojox/editor/plugins/resources/images/uploadImageIcon.gif +%%WWWDIR%%/dojox/editor/plugins/resources/insertTable.html +%%WWWDIR%%/dojox/editor/plugins/resources/modifyTable.html +%%WWWDIR%%/dojox/embed/Flash.js +%%WWWDIR%%/dojox/embed/IE/flash.js +%%WWWDIR%%/dojox/embed/Object.js +%%WWWDIR%%/dojox/embed/Quicktime.js +%%WWWDIR%%/dojox/embed/README +%%WWWDIR%%/dojox/embed/resources/version.mov +%%WWWDIR%%/dojox/encoding/LICENSE +%%WWWDIR%%/dojox/encoding/README +%%WWWDIR%%/dojox/encoding/_base.js +%%WWWDIR%%/dojox/encoding/ascii85.js +%%WWWDIR%%/dojox/encoding/base64.js +%%WWWDIR%%/dojox/encoding/bits.js +%%WWWDIR%%/dojox/encoding/compression/lzw.js +%%WWWDIR%%/dojox/encoding/compression/splay.js +%%WWWDIR%%/dojox/encoding/crypto/Blowfish.js +%%WWWDIR%%/dojox/encoding/crypto/_base.js +%%WWWDIR%%/dojox/encoding/digests/MD5.js +%%WWWDIR%%/dojox/encoding/digests/_base.js +%%WWWDIR%%/dojox/encoding/easy64.js +%%WWWDIR%%/dojox/flash.js +%%WWWDIR%%/dojox/flash/DojoExternalInterface.as +%%WWWDIR%%/dojox/flash/ExpressInstall.as +%%WWWDIR%%/dojox/flash/README +%%WWWDIR%%/dojox/flash/_base.js +%%WWWDIR%%/dojox/form/BusyButton.js +%%WWWDIR%%/dojox/form/CheckedMultiSelect.js +%%WWWDIR%%/dojox/form/DateTextBox.js +%%WWWDIR%%/dojox/form/DropDownSelect.js +%%WWWDIR%%/dojox/form/DropDownStack.js +%%WWWDIR%%/dojox/form/FileInput.js +%%WWWDIR%%/dojox/form/FileInputAuto.js +%%WWWDIR%%/dojox/form/FilePickerTextBox.js +%%WWWDIR%%/dojox/form/FileUploader.js +%%WWWDIR%%/dojox/form/MultiComboBox.js +%%WWWDIR%%/dojox/form/PasswordValidator.js +%%WWWDIR%%/dojox/form/README +%%WWWDIR%%/dojox/form/RadioStack.js +%%WWWDIR%%/dojox/form/RangeSlider.js +%%WWWDIR%%/dojox/form/Rating.js +%%WWWDIR%%/dojox/form/TimeSpinner.js +%%WWWDIR%%/dojox/form/_FormSelectWidget.js +%%WWWDIR%%/dojox/form/_HasDropDown.js +%%WWWDIR%%/dojox/form/_SelectStackMixin.js +%%WWWDIR%%/dojox/form/nls/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ar/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ca/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/cs/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/da/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/de/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/el/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/es/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/fi/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/fr/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/he/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/hu/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/it/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ja/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ko/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/nb/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/nl/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/pl/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/pt-pt/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/pt/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/ru/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/sk/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/sl/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/sv/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/th/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/tr/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/zh-tw/PasswordValidator.js +%%WWWDIR%%/dojox/form/nls/zh/PasswordValidator.js +%%WWWDIR%%/dojox/form/resources/BusyButton.css +%%WWWDIR%%/dojox/form/resources/CheckedMultiSelect.css +%%WWWDIR%%/dojox/form/resources/CheckedMultiSelect.html +%%WWWDIR%%/dojox/form/resources/DropDownSelect.css +%%WWWDIR%%/dojox/form/resources/DropDownSelect.html +%%WWWDIR%%/dojox/form/resources/FileInput.css +%%WWWDIR%%/dojox/form/resources/FileInput.html +%%WWWDIR%%/dojox/form/resources/FileInputAuto.html +%%WWWDIR%%/dojox/form/resources/FilePickerTextBox.css +%%WWWDIR%%/dojox/form/resources/FilePickerTextBox.html +%%WWWDIR%%/dojox/form/resources/HorizontalRangeSlider.html +%%WWWDIR%%/dojox/form/resources/PasswordValidator.html +%%WWWDIR%%/dojox/form/resources/RangeSlider.css +%%WWWDIR%%/dojox/form/resources/Rating.css +%%WWWDIR%%/dojox/form/resources/RecieveFile.php +%%WWWDIR%%/dojox/form/resources/UploadFile.php +%%WWWDIR%%/dojox/form/resources/VerticalRangeSlider.html +%%WWWDIR%%/dojox/form/resources/_CheckedMultiSelectItem.html +%%WWWDIR%%/dojox/form/resources/cLOG.php +%%WWWDIR%%/dojox/form/resources/images/loading_wheel.gif +%%WWWDIR%%/dojox/form/resources/images/nihiloFolderSprite.gif +%%WWWDIR%%/dojox/form/resources/images/rating_empty.gif +%%WWWDIR%%/dojox/form/resources/images/rating_full.gif +%%WWWDIR%%/dojox/form/resources/images/soriaFolderSprite.gif +%%WWWDIR%%/dojox/form/resources/images/tundraFolderSprite.gif +%%WWWDIR%%/dojox/form/resources/uploader.swf +%%WWWDIR%%/dojox/fx.js +%%WWWDIR%%/dojox/fx/README +%%WWWDIR%%/dojox/fx/Shadow.js +%%WWWDIR%%/dojox/fx/_arg.js +%%WWWDIR%%/dojox/fx/_base.js +%%WWWDIR%%/dojox/fx/_core.js +%%WWWDIR%%/dojox/fx/easing.js +%%WWWDIR%%/dojox/fx/ext-dojo/NodeList.js +%%WWWDIR%%/dojox/fx/flip.js +%%WWWDIR%%/dojox/fx/resources/shadowB.png +%%WWWDIR%%/dojox/fx/resources/shadowBL.png +%%WWWDIR%%/dojox/fx/resources/shadowBR.png +%%WWWDIR%%/dojox/fx/resources/shadowL.png +%%WWWDIR%%/dojox/fx/resources/shadowR.png +%%WWWDIR%%/dojox/fx/resources/shadowT.png +%%WWWDIR%%/dojox/fx/resources/shadowTL.png +%%WWWDIR%%/dojox/fx/resources/shadowTR.png +%%WWWDIR%%/dojox/fx/scroll.js +%%WWWDIR%%/dojox/fx/split.js +%%WWWDIR%%/dojox/fx/style.js +%%WWWDIR%%/dojox/fx/text.js +%%WWWDIR%%/dojox/gfx.js +%%WWWDIR%%/dojox/gfx/Moveable.js +%%WWWDIR%%/dojox/gfx/Mover.js +%%WWWDIR%%/dojox/gfx/README +%%WWWDIR%%/dojox/gfx/VectorText.js +%%WWWDIR%%/dojox/gfx/_base.js +%%WWWDIR%%/dojox/gfx/arc.js +%%WWWDIR%%/dojox/gfx/attach.js +%%WWWDIR%%/dojox/gfx/canvas.js +%%WWWDIR%%/dojox/gfx/canvas_attach.js +%%WWWDIR%%/dojox/gfx/decompose.js +%%WWWDIR%%/dojox/gfx/fx.js +%%WWWDIR%%/dojox/gfx/matrix.js +%%WWWDIR%%/dojox/gfx/move.js +%%WWWDIR%%/dojox/gfx/path.js +%%WWWDIR%%/dojox/gfx/resources/Gillius.svg +%%WWWDIR%%/dojox/gfx/resources/README +%%WWWDIR%%/dojox/gfx/shape.js +%%WWWDIR%%/dojox/gfx/silverlight.js +%%WWWDIR%%/dojox/gfx/silverlight_attach.js +%%WWWDIR%%/dojox/gfx/svg.js +%%WWWDIR%%/dojox/gfx/svg_attach.js +%%WWWDIR%%/dojox/gfx/utils.js +%%WWWDIR%%/dojox/gfx/vml.js +%%WWWDIR%%/dojox/gfx/vml_attach.js +%%WWWDIR%%/dojox/gfx3d.js +%%WWWDIR%%/dojox/gfx3d/README +%%WWWDIR%%/dojox/gfx3d/_base.js +%%WWWDIR%%/dojox/gfx3d/gradient.js +%%WWWDIR%%/dojox/gfx3d/lighting.js +%%WWWDIR%%/dojox/gfx3d/matrix.js +%%WWWDIR%%/dojox/gfx3d/object.js +%%WWWDIR%%/dojox/gfx3d/scheduler.js +%%WWWDIR%%/dojox/gfx3d/vector.js +%%WWWDIR%%/dojox/grid/DataGrid.js +%%WWWDIR%%/dojox/grid/DataSelection.js +%%WWWDIR%%/dojox/grid/Grid.js +%%WWWDIR%%/dojox/grid/README +%%WWWDIR%%/dojox/grid/Selection.js +%%WWWDIR%%/dojox/grid/VirtualGrid.js +%%WWWDIR%%/dojox/grid/_EditManager.js +%%WWWDIR%%/dojox/grid/_Events.js +%%WWWDIR%%/dojox/grid/_FocusManager.js +%%WWWDIR%%/dojox/grid/_Grid.js +%%WWWDIR%%/dojox/grid/_Layout.js +%%WWWDIR%%/dojox/grid/_RowManager.js +%%WWWDIR%%/dojox/grid/_RowSelector.js +%%WWWDIR%%/dojox/grid/_Scroller.js +%%WWWDIR%%/dojox/grid/_View.js +%%WWWDIR%%/dojox/grid/_ViewManager.js +%%WWWDIR%%/dojox/grid/_grid/Grid.css +%%WWWDIR%%/dojox/grid/_grid/Grid_rtl.css +%%WWWDIR%%/dojox/grid/_grid/nihiloGrid.css +%%WWWDIR%%/dojox/grid/_grid/soriaGrid.css +%%WWWDIR%%/dojox/grid/_grid/tundraGrid.css +%%WWWDIR%%/dojox/grid/cells.js +%%WWWDIR%%/dojox/grid/cells/_base.js +%%WWWDIR%%/dojox/grid/cells/dijit.js +%%WWWDIR%%/dojox/grid/compat/Grid.js +%%WWWDIR%%/dojox/grid/compat/README +%%WWWDIR%%/dojox/grid/compat/VirtualGrid.js +%%WWWDIR%%/dojox/grid/compat/_data/dijitEditors.js +%%WWWDIR%%/dojox/grid/compat/_data/editors.js +%%WWWDIR%%/dojox/grid/compat/_data/fields.js +%%WWWDIR%%/dojox/grid/compat/_data/model.js +%%WWWDIR%%/dojox/grid/compat/_grid/Grid.css +%%WWWDIR%%/dojox/grid/compat/_grid/Grid_rtl.css +%%WWWDIR%%/dojox/grid/compat/_grid/builder.js +%%WWWDIR%%/dojox/grid/compat/_grid/cell.js +%%WWWDIR%%/dojox/grid/compat/_grid/drag.js +%%WWWDIR%%/dojox/grid/compat/_grid/edit.js +%%WWWDIR%%/dojox/grid/compat/_grid/focus.js +%%WWWDIR%%/dojox/grid/compat/_grid/images/grid_dx_gradient.gif +%%WWWDIR%%/dojox/grid/compat/_grid/images/grid_sort_down.gif +%%WWWDIR%%/dojox/grid/compat/_grid/images/grid_sort_up.gif +%%WWWDIR%%/dojox/grid/compat/_grid/images/tabEnabled_rotated.png +%%WWWDIR%%/dojox/grid/compat/_grid/images/tabHover_rotated.png +%%WWWDIR%%/dojox/grid/compat/_grid/layout.js +%%WWWDIR%%/dojox/grid/compat/_grid/lib.js +%%WWWDIR%%/dojox/grid/compat/_grid/nihiloGrid.css +%%WWWDIR%%/dojox/grid/compat/_grid/publicEvents.js +%%WWWDIR%%/dojox/grid/compat/_grid/rowbar.js +%%WWWDIR%%/dojox/grid/compat/_grid/rows.js +%%WWWDIR%%/dojox/grid/compat/_grid/scroller.js +%%WWWDIR%%/dojox/grid/compat/_grid/selection.js +%%WWWDIR%%/dojox/grid/compat/_grid/soriaGrid.css +%%WWWDIR%%/dojox/grid/compat/_grid/tundraGrid.css +%%WWWDIR%%/dojox/grid/compat/_grid/view.js +%%WWWDIR%%/dojox/grid/compat/_grid/views.js +%%WWWDIR%%/dojox/grid/compat/resources/GridView.html +%%WWWDIR%%/dojox/grid/compat/resources/VirtualGrid.html +%%WWWDIR%%/dojox/grid/compat/tests/databaseModel.js +%%WWWDIR%%/dojox/grid/compat/tests/images/closed.gif +%%WWWDIR%%/dojox/grid/compat/tests/images/flatScreen.gif +%%WWWDIR%%/dojox/grid/compat/tests/images/open.gif +%%WWWDIR%%/dojox/grid/compat/tests/support/books.xml +%%WWWDIR%%/dojox/grid/compat/tests/support/data.php +%%WWWDIR%%/dojox/grid/compat/tests/support/geography.xml +%%WWWDIR%%/dojox/grid/compat/tests/support/json.php +%%WWWDIR%%/dojox/grid/compat/tests/support/movies.csv +%%WWWDIR%%/dojox/grid/compat/tests/support/test_data.js +%%WWWDIR%%/dojox/grid/compat/tests/support/test_data_objects.js +%%WWWDIR%%/dojox/grid/compat/tests/support/testtbl.sql +%%WWWDIR%%/dojox/grid/compat/tests/support/yahoo_search.js +%%WWWDIR%%/dojox/grid/compat/tests/test_change_structure.html +%%WWWDIR%%/dojox/grid/compat/tests/test_custom_sort.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_empty.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model_EmptyResultSet.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model_multiStores.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_model_processError.html +%%WWWDIR%%/dojox/grid/compat/tests/test_dojo_data_notification.html +%%WWWDIR%%/dojox/grid/compat/tests/test_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_edit_canEdit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_edit_dijit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_events.html +%%WWWDIR%%/dojox/grid/compat/tests/test_expand.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_dlg.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_headerHeight.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_layout.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_layout_LayoutContainer.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_layout_borderContainer.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_object_model_change.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_programmatic.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_programmatic_layout.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_rtl.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_themes.html +%%WWWDIR%%/dojox/grid/compat/tests/test_grid_tooltip_menu.html +%%WWWDIR%%/dojox/grid/compat/tests/test_keyboard.html +%%WWWDIR%%/dojox/grid/compat/tests/test_markup.html +%%WWWDIR%%/dojox/grid/compat/tests/test_mysql_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_sizing.html +%%WWWDIR%%/dojox/grid/compat/tests/test_sizing_100rows.html +%%WWWDIR%%/dojox/grid/compat/tests/test_sizing_ResizeHandle.html +%%WWWDIR%%/dojox/grid/compat/tests/test_styling.html +%%WWWDIR%%/dojox/grid/compat/tests/test_subgrid.html +%%WWWDIR%%/dojox/grid/compat/tests/test_tundra_edit.html +%%WWWDIR%%/dojox/grid/compat/tests/test_yahoo_images.html +%%WWWDIR%%/dojox/grid/compat/tests/test_yahoo_search.html +%%WWWDIR%%/dojox/grid/compat/tests/yahooSearch.js +%%WWWDIR%%/dojox/grid/resources/Grid.css +%%WWWDIR%%/dojox/grid/resources/Grid_rtl.css +%%WWWDIR%%/dojox/grid/resources/View.html +%%WWWDIR%%/dojox/grid/resources/_Grid.html +%%WWWDIR%%/dojox/grid/resources/images/grid_dx_gradient.gif +%%WWWDIR%%/dojox/grid/resources/images/grid_sort_down.gif +%%WWWDIR%%/dojox/grid/resources/images/grid_sort_up.gif +%%WWWDIR%%/dojox/grid/resources/images/tabEnabled_rotated.png +%%WWWDIR%%/dojox/grid/resources/images/tabHover_rotated.png +%%WWWDIR%%/dojox/grid/resources/nihiloGrid.css +%%WWWDIR%%/dojox/grid/resources/soriaGrid.css +%%WWWDIR%%/dojox/grid/resources/tundraGrid.css +%%WWWDIR%%/dojox/grid/util.js +%%WWWDIR%%/dojox/help/README +%%WWWDIR%%/dojox/help/_base.js +%%WWWDIR%%/dojox/help/console.js +%%WWWDIR%%/dojox/highlight.js +%%WWWDIR%%/dojox/highlight/README +%%WWWDIR%%/dojox/highlight/_base.js +%%WWWDIR%%/dojox/highlight/languages/_all.js +%%WWWDIR%%/dojox/highlight/languages/_dynamic.js +%%WWWDIR%%/dojox/highlight/languages/_static.js +%%WWWDIR%%/dojox/highlight/languages/_www.js +%%WWWDIR%%/dojox/highlight/languages/cpp.js +%%WWWDIR%%/dojox/highlight/languages/css.js +%%WWWDIR%%/dojox/highlight/languages/delphi.js +%%WWWDIR%%/dojox/highlight/languages/django.js +%%WWWDIR%%/dojox/highlight/languages/html.js +%%WWWDIR%%/dojox/highlight/languages/javascript.js +%%WWWDIR%%/dojox/highlight/languages/pygments/_html.js +%%WWWDIR%%/dojox/highlight/languages/pygments/_www.js +%%WWWDIR%%/dojox/highlight/languages/pygments/css.js +%%WWWDIR%%/dojox/highlight/languages/pygments/html.js +%%WWWDIR%%/dojox/highlight/languages/pygments/javascript.js +%%WWWDIR%%/dojox/highlight/languages/pygments/xml.js +%%WWWDIR%%/dojox/highlight/languages/python.js +%%WWWDIR%%/dojox/highlight/languages/sql.js +%%WWWDIR%%/dojox/highlight/languages/xml.js +%%WWWDIR%%/dojox/highlight/resources/highlight.css +%%WWWDIR%%/dojox/highlight/resources/pygments/autumn.css +%%WWWDIR%%/dojox/highlight/resources/pygments/borland.css +%%WWWDIR%%/dojox/highlight/resources/pygments/colorful.css +%%WWWDIR%%/dojox/highlight/resources/pygments/default.css +%%WWWDIR%%/dojox/highlight/resources/pygments/emacs.css +%%WWWDIR%%/dojox/highlight/resources/pygments/friendly.css +%%WWWDIR%%/dojox/highlight/resources/pygments/fruity.css +%%WWWDIR%%/dojox/highlight/resources/pygments/manni.css +%%WWWDIR%%/dojox/highlight/resources/pygments/murphy.css +%%WWWDIR%%/dojox/highlight/resources/pygments/native.css +%%WWWDIR%%/dojox/highlight/resources/pygments/pastie.css +%%WWWDIR%%/dojox/highlight/resources/pygments/perldoc.css +%%WWWDIR%%/dojox/highlight/resources/pygments/trac.css +%%WWWDIR%%/dojox/html.js +%%WWWDIR%%/dojox/html/README +%%WWWDIR%%/dojox/html/_base.js +%%WWWDIR%%/dojox/html/metrics.js +%%WWWDIR%%/dojox/html/styles.js +%%WWWDIR%%/dojox/image/Badge.js +%%WWWDIR%%/dojox/image/FlickrBadge.js +%%WWWDIR%%/dojox/image/Gallery.js +%%WWWDIR%%/dojox/image/Lightbox.js +%%WWWDIR%%/dojox/image/Magnifier.js +%%WWWDIR%%/dojox/image/MagnifierLite.js +%%WWWDIR%%/dojox/image/README +%%WWWDIR%%/dojox/image/SlideShow.js +%%WWWDIR%%/dojox/image/ThumbnailPicker.js +%%WWWDIR%%/dojox/image/resources/Badge.css +%%WWWDIR%%/dojox/image/resources/Gallery.css +%%WWWDIR%%/dojox/image/resources/Gallery.html +%%WWWDIR%%/dojox/image/resources/Lightbox.css +%%WWWDIR%%/dojox/image/resources/Lightbox.html +%%WWWDIR%%/dojox/image/resources/Magnifier.css +%%WWWDIR%%/dojox/image/resources/SlideShow.css +%%WWWDIR%%/dojox/image/resources/SlideShow.html +%%WWWDIR%%/dojox/image/resources/ThumbnailPicker.css +%%WWWDIR%%/dojox/image/resources/ThumbnailPicker.html +%%WWWDIR%%/dojox/image/resources/image.css +%%WWWDIR%%/dojox/image/resources/images/buttons.gif +%%WWWDIR%%/dojox/image/resources/images/buttons.png +%%WWWDIR%%/dojox/image/resources/images/close.gif +%%WWWDIR%%/dojox/image/resources/images/close.png +%%WWWDIR%%/dojox/image/resources/images/close_dark.png +%%WWWDIR%%/dojox/image/resources/images/left.gif +%%WWWDIR%%/dojox/image/resources/images/left.png +%%WWWDIR%%/dojox/image/resources/images/loading.gif +%%WWWDIR%%/dojox/image/resources/images/right.gif +%%WWWDIR%%/dojox/image/resources/images/right.png +%%WWWDIR%%/dojox/image/resources/images/warning.png +%%WWWDIR%%/dojox/io/README +%%WWWDIR%%/dojox/io/httpParse.js +%%WWWDIR%%/dojox/io/proxy/README +%%WWWDIR%%/dojox/io/proxy/tests/frag.xml +%%WWWDIR%%/dojox/io/proxy/tests/xip.html +%%WWWDIR%%/dojox/io/proxy/xip.js +%%WWWDIR%%/dojox/io/proxy/xip_client.html +%%WWWDIR%%/dojox/io/proxy/xip_server.html +%%WWWDIR%%/dojox/io/scriptFrame.js +%%WWWDIR%%/dojox/io/windowName.js +%%WWWDIR%%/dojox/io/xhrMultiPart.js +%%WWWDIR%%/dojox/io/xhrPlugins.js +%%WWWDIR%%/dojox/io/xhrWindowNamePlugin.js +%%WWWDIR%%/dojox/json/README +%%WWWDIR%%/dojox/json/query.js +%%WWWDIR%%/dojox/json/ref.js +%%WWWDIR%%/dojox/json/schema.js +%%WWWDIR%%/dojox/jsonPath.js +%%WWWDIR%%/dojox/jsonPath/README +%%WWWDIR%%/dojox/jsonPath/query.js +%%WWWDIR%%/dojox/lang/LICENSE +%%WWWDIR%%/dojox/lang/README +%%WWWDIR%%/dojox/lang/aspect.js +%%WWWDIR%%/dojox/lang/aspect/cflow.js +%%WWWDIR%%/dojox/lang/aspect/counter.js +%%WWWDIR%%/dojox/lang/aspect/memoizer.js +%%WWWDIR%%/dojox/lang/aspect/memoizerGuard.js +%%WWWDIR%%/dojox/lang/aspect/profiler.js +%%WWWDIR%%/dojox/lang/aspect/timer.js +%%WWWDIR%%/dojox/lang/aspect/tracer.js +%%WWWDIR%%/dojox/lang/functional.js +%%WWWDIR%%/dojox/lang/functional/array.js +%%WWWDIR%%/dojox/lang/functional/binrec.js +%%WWWDIR%%/dojox/lang/functional/curry.js +%%WWWDIR%%/dojox/lang/functional/fold.js +%%WWWDIR%%/dojox/lang/functional/lambda.js +%%WWWDIR%%/dojox/lang/functional/linrec.js +%%WWWDIR%%/dojox/lang/functional/listcomp.js +%%WWWDIR%%/dojox/lang/functional/multirec.js +%%WWWDIR%%/dojox/lang/functional/numrec.js +%%WWWDIR%%/dojox/lang/functional/object.js +%%WWWDIR%%/dojox/lang/functional/reversed.js +%%WWWDIR%%/dojox/lang/functional/scan.js +%%WWWDIR%%/dojox/lang/functional/sequence.js +%%WWWDIR%%/dojox/lang/functional/tailrec.js +%%WWWDIR%%/dojox/lang/functional/util.js +%%WWWDIR%%/dojox/lang/functional/zip.js +%%WWWDIR%%/dojox/lang/mix.js +%%WWWDIR%%/dojox/lang/observable.js +%%WWWDIR%%/dojox/lang/utils.js +%%WWWDIR%%/dojox/layout/BorderContainer.js +%%WWWDIR%%/dojox/layout/ContentPane.js +%%WWWDIR%%/dojox/layout/DragPane.js +%%WWWDIR%%/dojox/layout/ExpandoPane.js +%%WWWDIR%%/dojox/layout/FloatingPane.js +%%WWWDIR%%/dojox/layout/GridContainer.js +%%WWWDIR%%/dojox/layout/README +%%WWWDIR%%/dojox/layout/RadioGroup.js +%%WWWDIR%%/dojox/layout/ResizeHandle.js +%%WWWDIR%%/dojox/layout/RotatorContainer.js +%%WWWDIR%%/dojox/layout/ScrollPane.js +%%WWWDIR%%/dojox/layout/ToggleSplitter.js +%%WWWDIR%%/dojox/layout/dnd/Avatar.js +%%WWWDIR%%/dojox/layout/dnd/PlottedDnd.js +%%WWWDIR%%/dojox/layout/nls/GridContainer.js +%%WWWDIR%%/dojox/layout/nls/en/GridContainer.js +%%WWWDIR%%/dojox/layout/nls/fr/GridContainer.js +%%WWWDIR%%/dojox/layout/resources/DndGridContainer.css +%%WWWDIR%%/dojox/layout/resources/ExpandoPane.css +%%WWWDIR%%/dojox/layout/resources/ExpandoPane.html +%%WWWDIR%%/dojox/layout/resources/FloatingPane.css +%%WWWDIR%%/dojox/layout/resources/FloatingPane.html +%%WWWDIR%%/dojox/layout/resources/GridContainer.css +%%WWWDIR%%/dojox/layout/resources/GridContainer.html +%%WWWDIR%%/dojox/layout/resources/RadioGroup.css +%%WWWDIR%%/dojox/layout/resources/ResizeHandle.css +%%WWWDIR%%/dojox/layout/resources/RotatorContainer.css +%%WWWDIR%%/dojox/layout/resources/ScrollPane.css +%%WWWDIR%%/dojox/layout/resources/ScrollPane.html +%%WWWDIR%%/dojox/layout/resources/ToggleSplitter.css +%%WWWDIR%%/dojox/layout/resources/icons/grip_bg.gif +%%WWWDIR%%/dojox/layout/resources/icons/pixel.gif +%%WWWDIR%%/dojox/layout/resources/icons/resize.png +%%WWWDIR%%/dojox/layout/resources/icons/rotator.png +%%WWWDIR%%/dojox/math.js +%%WWWDIR%%/dojox/math/README +%%WWWDIR%%/dojox/math/_base.js +%%WWWDIR%%/dojox/math/curves.js +%%WWWDIR%%/dojox/math/matrix.js +%%WWWDIR%%/dojox/off.js +%%WWWDIR%%/dojox/off/README +%%WWWDIR%%/dojox/off/_common.js +%%WWWDIR%%/dojox/off/docs/bookmarklets.html +%%WWWDIR%%/dojox/off/files.js +%%WWWDIR%%/dojox/off/network_check.txt +%%WWWDIR%%/dojox/off/offline.js +%%WWWDIR%%/dojox/off/resources/checkmark.png +%%WWWDIR%%/dojox/off/resources/greenball.png +%%WWWDIR%%/dojox/off/resources/learnhow.html +%%WWWDIR%%/dojox/off/resources/learnhow.js +%%WWWDIR%%/dojox/off/resources/offline-widget.css +%%WWWDIR%%/dojox/off/resources/offline-widget.html +%%WWWDIR%%/dojox/off/resources/redball.png +%%WWWDIR%%/dojox/off/resources/roller.gif +%%WWWDIR%%/dojox/off/sync.js +%%WWWDIR%%/dojox/off/ui.js +%%WWWDIR%%/dojox/presentation.js +%%WWWDIR%%/dojox/presentation/README +%%WWWDIR%%/dojox/presentation/_base.js +%%WWWDIR%%/dojox/presentation/resources/Show.css +%%WWWDIR%%/dojox/presentation/resources/Show.html +%%WWWDIR%%/dojox/presentation/resources/Slide.html +%%WWWDIR%%/dojox/presentation/resources/icons/down.png +%%WWWDIR%%/dojox/presentation/resources/icons/next.png +%%WWWDIR%%/dojox/presentation/resources/icons/prev.png +%%WWWDIR%%/dojox/presentation/resources/icons/up.png +%%WWWDIR%%/dojox/resources/README.template +%%WWWDIR%%/dojox/resources/_modules.js +%%WWWDIR%%/dojox/resources/explore.php +%%WWWDIR%%/dojox/resources/manualTests.html +%%WWWDIR%%/dojox/resources/manualTests.js +%%WWWDIR%%/dojox/robot/README +%%WWWDIR%%/dojox/robot/recorder.js +%%WWWDIR%%/dojox/rpc/Client.js +%%WWWDIR%%/dojox/rpc/JsonRPC.js +%%WWWDIR%%/dojox/rpc/JsonRest.js +%%WWWDIR%%/dojox/rpc/OfflineRest.js +%%WWWDIR%%/dojox/rpc/ProxiedPath.js +%%WWWDIR%%/dojox/rpc/README +%%WWWDIR%%/dojox/rpc/Rest.js +%%WWWDIR%%/dojox/rpc/SMDLibrary/dojo-api.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/geonames.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/google.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/wikipedia.smd +%%WWWDIR%%/dojox/rpc/SMDLibrary/yahoo.smd +%%WWWDIR%%/dojox/rpc/Service.js +%%WWWDIR%%/dojox/rpc/test.txt +%%WWWDIR%%/dojox/secure/DOM.js +%%WWWDIR%%/dojox/secure/README +%%WWWDIR%%/dojox/secure/capability.js +%%WWWDIR%%/dojox/secure/sandbox.js +%%WWWDIR%%/dojox/sketch.js +%%WWWDIR%%/dojox/sketch/Anchor.js +%%WWWDIR%%/dojox/sketch/Annotation.js +%%WWWDIR%%/dojox/sketch/DoubleArrowAnnotation.js +%%WWWDIR%%/dojox/sketch/Figure.js +%%WWWDIR%%/dojox/sketch/LeadAnnotation.js +%%WWWDIR%%/dojox/sketch/PreexistingAnnotation.js +%%WWWDIR%%/dojox/sketch/README +%%WWWDIR%%/dojox/sketch/SingleArrowAnnotation.js +%%WWWDIR%%/dojox/sketch/Slider.js +%%WWWDIR%%/dojox/sketch/Toolbar.js +%%WWWDIR%%/dojox/sketch/UnderlineAnnotation.js +%%WWWDIR%%/dojox/sketch/UndoStack.js +%%WWWDIR%%/dojox/sketch/_Plugin.js +%%WWWDIR%%/dojox/sketch/resources/images/icons.gif +%%WWWDIR%%/dojox/sketch/resources/sketch.css +%%WWWDIR%%/dojox/sql.js +%%WWWDIR%%/dojox/sql/LICENSE +%%WWWDIR%%/dojox/sql/README +%%WWWDIR%%/dojox/sql/_base.js +%%WWWDIR%%/dojox/sql/_crypto.js +%%WWWDIR%%/dojox/storage.js +%%WWWDIR%%/dojox/storage/AirDBStorageProvider.js +%%WWWDIR%%/dojox/storage/AirEncryptedLocalStorageProvider.js +%%WWWDIR%%/dojox/storage/AirFileStorageProvider.js +%%WWWDIR%%/dojox/storage/FlashStorageProvider.js +%%WWWDIR%%/dojox/storage/GearsStorageProvider.js +%%WWWDIR%%/dojox/storage/Provider.js +%%WWWDIR%%/dojox/storage/README +%%WWWDIR%%/dojox/storage/Storage.as +%%WWWDIR%%/dojox/storage/Storage.swf +%%WWWDIR%%/dojox/storage/WhatWGStorageProvider.js +%%WWWDIR%%/dojox/storage/_common.js +%%WWWDIR%%/dojox/storage/buildFlashStorage.sh +%%WWWDIR%%/dojox/storage/manager.js +%%WWWDIR%%/dojox/storage/storage_dialog.fla +%%WWWDIR%%/dojox/storage/storage_dialog.swf +%%WWWDIR%%/dojox/string/BidiComplex.js +%%WWWDIR%%/dojox/string/Builder.js +%%WWWDIR%%/dojox/string/README +%%WWWDIR%%/dojox/string/sprintf.js +%%WWWDIR%%/dojox/string/tokenize.js +%%WWWDIR%%/dojox/testing/DocTest.js +%%WWWDIR%%/dojox/testing/README +%%WWWDIR%%/dojox/timing.js +%%WWWDIR%%/dojox/timing/README +%%WWWDIR%%/dojox/timing/Sequence.js +%%WWWDIR%%/dojox/timing/Streamer.js +%%WWWDIR%%/dojox/timing/ThreadPool.js +%%WWWDIR%%/dojox/timing/_base.js +%%WWWDIR%%/dojox/uuid.js +%%WWWDIR%%/dojox/uuid/README +%%WWWDIR%%/dojox/uuid/Uuid.js +%%WWWDIR%%/dojox/uuid/_base.js +%%WWWDIR%%/dojox/uuid/generateRandomUuid.js +%%WWWDIR%%/dojox/uuid/generateTimeBasedUuid.js +%%WWWDIR%%/dojox/validate.js +%%WWWDIR%%/dojox/validate/README +%%WWWDIR%%/dojox/validate/_base.js +%%WWWDIR%%/dojox/validate/ca.js +%%WWWDIR%%/dojox/validate/check.js +%%WWWDIR%%/dojox/validate/creditCard.js +%%WWWDIR%%/dojox/validate/isbn.js +%%WWWDIR%%/dojox/validate/regexp.js +%%WWWDIR%%/dojox/validate/us.js +%%WWWDIR%%/dojox/validate/web.js +%%WWWDIR%%/dojox/widget/Calendar.js +%%WWWDIR%%/dojox/widget/Calendar/Calendar.css +%%WWWDIR%%/dojox/widget/Calendar/Calendar.html +%%WWWDIR%%/dojox/widget/Calendar/CalendarDay.html +%%WWWDIR%%/dojox/widget/Calendar/CalendarMonth.html +%%WWWDIR%%/dojox/widget/Calendar/CalendarYear.html +%%WWWDIR%%/dojox/widget/CalendarFx.js +%%WWWDIR%%/dojox/widget/ColorPicker.js +%%WWWDIR%%/dojox/widget/ColorPicker/ColorPicker.css +%%WWWDIR%%/dojox/widget/ColorPicker/ColorPicker.html +%%WWWDIR%%/dojox/widget/ColorPicker/images/hue.png +%%WWWDIR%%/dojox/widget/ColorPicker/images/hueHandle.png +%%WWWDIR%%/dojox/widget/ColorPicker/images/pickerPointer.png +%%WWWDIR%%/dojox/widget/ColorPicker/images/underlay.png +%%WWWDIR%%/dojox/widget/Dialog.js +%%WWWDIR%%/dojox/widget/Dialog/Dialog.css +%%WWWDIR%%/dojox/widget/Dialog/Dialog.html +%%WWWDIR%%/dojox/widget/Dialog/images/dialogCloseButton.gif +%%WWWDIR%%/dojox/widget/Dialog/images/dialogCloseButton.png +%%WWWDIR%%/dojox/widget/DocTester.js +%%WWWDIR%%/dojox/widget/DocTester/DocTester.css +%%WWWDIR%%/dojox/widget/DocTester/DocTester.html +%%WWWDIR%%/dojox/widget/FilePicker.js +%%WWWDIR%%/dojox/widget/FilePicker/FilePicker.css +%%WWWDIR%%/dojox/widget/FilePicker/_FileInfoPane.html +%%WWWDIR%%/dojox/widget/FilePicker/images/nihiloFileIcons.gif +%%WWWDIR%%/dojox/widget/FilePicker/images/soriaFileIcons.gif +%%WWWDIR%%/dojox/widget/FilePicker/images/tundraFileIcons.gif +%%WWWDIR%%/dojox/widget/FisheyeList.js +%%WWWDIR%%/dojox/widget/FisheyeList/FisheyeList.css +%%WWWDIR%%/dojox/widget/FisheyeLite.js +%%WWWDIR%%/dojox/widget/Iterator.js +%%WWWDIR%%/dojox/widget/Loader.js +%%WWWDIR%%/dojox/widget/Loader/Loader.css +%%WWWDIR%%/dojox/widget/Loader/icons/loading.gif +%%WWWDIR%%/dojox/widget/Pager.js +%%WWWDIR%%/dojox/widget/Pager/Pager.css +%%WWWDIR%%/dojox/widget/Pager/Pager.html +%%WWWDIR%%/dojox/widget/Pager/images/hNext.png +%%WWWDIR%%/dojox/widget/Pager/images/hPrevious.png +%%WWWDIR%%/dojox/widget/Pager/images/pageActive.png +%%WWWDIR%%/dojox/widget/Pager/images/pageInactive.png +%%WWWDIR%%/dojox/widget/Pager/images/vNext.png +%%WWWDIR%%/dojox/widget/Pager/images/vPrevious.png +%%WWWDIR%%/dojox/widget/PlaceholderMenuItem.js +%%WWWDIR%%/dojox/widget/README +%%WWWDIR%%/dojox/widget/Roller.js +%%WWWDIR%%/dojox/widget/RollingList.js +%%WWWDIR%%/dojox/widget/RollingList/RollingList.css +%%WWWDIR%%/dojox/widget/SortList.js +%%WWWDIR%%/dojox/widget/SortList/SortList.css +%%WWWDIR%%/dojox/widget/SortList/SortList.html +%%WWWDIR%%/dojox/widget/Toaster.js +%%WWWDIR%%/dojox/widget/Toaster/Toaster.css +%%WWWDIR%%/dojox/widget/Wizard.js +%%WWWDIR%%/dojox/widget/Wizard/Wizard.css +%%WWWDIR%%/dojox/widget/Wizard/Wizard.html +%%WWWDIR%%/dojox/widget/nls/FilePicker.js +%%WWWDIR%%/dojox/widget/nls/RollingList.js +%%WWWDIR%%/dojox/widget/nls/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ar/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ca/Wizard.js +%%WWWDIR%%/dojox/widget/nls/cs/Wizard.js +%%WWWDIR%%/dojox/widget/nls/da/Wizard.js +%%WWWDIR%%/dojox/widget/nls/de/Wizard.js +%%WWWDIR%%/dojox/widget/nls/el/Wizard.js +%%WWWDIR%%/dojox/widget/nls/es/Wizard.js +%%WWWDIR%%/dojox/widget/nls/fi/Wizard.js +%%WWWDIR%%/dojox/widget/nls/fr/Wizard.js +%%WWWDIR%%/dojox/widget/nls/he/Wizard.js +%%WWWDIR%%/dojox/widget/nls/hu/Wizard.js +%%WWWDIR%%/dojox/widget/nls/it/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ja/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ko/Wizard.js +%%WWWDIR%%/dojox/widget/nls/nb/Wizard.js +%%WWWDIR%%/dojox/widget/nls/nl/Wizard.js +%%WWWDIR%%/dojox/widget/nls/pl/Wizard.js +%%WWWDIR%%/dojox/widget/nls/pt-pt/Wizard.js +%%WWWDIR%%/dojox/widget/nls/pt/Wizard.js +%%WWWDIR%%/dojox/widget/nls/ru/Wizard.js +%%WWWDIR%%/dojox/widget/nls/sk/Wizard.js +%%WWWDIR%%/dojox/widget/nls/sl/Wizard.js +%%WWWDIR%%/dojox/widget/nls/sv/Wizard.js +%%WWWDIR%%/dojox/widget/nls/th/Wizard.js +%%WWWDIR%%/dojox/widget/nls/tr/Wizard.js +%%WWWDIR%%/dojox/widget/nls/zh-tw/Wizard.js +%%WWWDIR%%/dojox/widget/nls/zh/Wizard.js +%%WWWDIR%%/dojox/wire.js +%%WWWDIR%%/dojox/wire/CompositeWire.js +%%WWWDIR%%/dojox/wire/DataWire.js +%%WWWDIR%%/dojox/wire/README +%%WWWDIR%%/dojox/wire/TableAdapter.js +%%WWWDIR%%/dojox/wire/TextAdapter.js +%%WWWDIR%%/dojox/wire/TreeAdapter.js +%%WWWDIR%%/dojox/wire/Wire.js +%%WWWDIR%%/dojox/wire/XmlWire.js +%%WWWDIR%%/dojox/wire/_base.js +%%WWWDIR%%/dojox/wire/ml/Action.js +%%WWWDIR%%/dojox/wire/ml/Data.js +%%WWWDIR%%/dojox/wire/ml/DataStore.js +%%WWWDIR%%/dojox/wire/ml/Invocation.js +%%WWWDIR%%/dojox/wire/ml/Service.js +%%WWWDIR%%/dojox/wire/ml/Transfer.js +%%WWWDIR%%/dojox/wire/ml/util.js +%%WWWDIR%%/dojox/xml/DomParser.js +%%WWWDIR%%/dojox/xml/README +%%WWWDIR%%/dojox/xml/Script.js +%%WWWDIR%%/dojox/xml/parser.js +%%WWWDIR%%/dojox/xml/widgetParser.js +%%WWWDIR%%/dojox/xmpp/ChatService.js +%%WWWDIR%%/dojox/xmpp/PresenceService.js +%%WWWDIR%%/dojox/xmpp/README +%%WWWDIR%%/dojox/xmpp/RosterService.js +%%WWWDIR%%/dojox/xmpp/TransportSession.js +%%WWWDIR%%/dojox/xmpp/UserService.js +%%WWWDIR%%/dojox/xmpp/sasl.js +%%WWWDIR%%/dojox/xmpp/util.js +%%WWWDIR%%/dojox/xmpp/widget/ChatSession.js +%%WWWDIR%%/dojox/xmpp/widget/templates/ChatSession.html +%%WWWDIR%%/dojox/xmpp/xmppSession.js + at dirrm %%WWWDIR%%/dojox/xmpp/widget/templates + at dirrm %%WWWDIR%%/dojox/xmpp/widget + at dirrm %%WWWDIR%%/dojox/xmpp + at dirrm %%WWWDIR%%/dojox/xml + at dirrm %%WWWDIR%%/dojox/wire/ml + at dirrm %%WWWDIR%%/dojox/wire + at dirrm %%WWWDIR%%/dojox/widget/nls/zh-tw + at dirrm %%WWWDIR%%/dojox/widget/nls/zh + at dirrm %%WWWDIR%%/dojox/widget/nls/tr + at dirrm %%WWWDIR%%/dojox/widget/nls/th + at dirrm %%WWWDIR%%/dojox/widget/nls/sv + at dirrm %%WWWDIR%%/dojox/widget/nls/sl + at dirrm %%WWWDIR%%/dojox/widget/nls/sk + at dirrm %%WWWDIR%%/dojox/widget/nls/ru + at dirrm %%WWWDIR%%/dojox/widget/nls/pt-pt + at dirrm %%WWWDIR%%/dojox/widget/nls/pt + at dirrm %%WWWDIR%%/dojox/widget/nls/pl + at dirrm %%WWWDIR%%/dojox/widget/nls/nl + at dirrm %%WWWDIR%%/dojox/widget/nls/nb + at dirrm %%WWWDIR%%/dojox/widget/nls/ko + at dirrm %%WWWDIR%%/dojox/widget/nls/ja + at dirrm %%WWWDIR%%/dojox/widget/nls/it + at dirrm %%WWWDIR%%/dojox/widget/nls/hu + at dirrm %%WWWDIR%%/dojox/widget/nls/he + at dirrm %%WWWDIR%%/dojox/widget/nls/fr + at dirrm %%WWWDIR%%/dojox/widget/nls/fi + at dirrm %%WWWDIR%%/dojox/widget/nls/es + at dirrm %%WWWDIR%%/dojox/widget/nls/el + at dirrm %%WWWDIR%%/dojox/widget/nls/de + at dirrm %%WWWDIR%%/dojox/widget/nls/da + at dirrm %%WWWDIR%%/dojox/widget/nls/cs + at dirrm %%WWWDIR%%/dojox/widget/nls/ca + at dirrm %%WWWDIR%%/dojox/widget/nls/ar + at dirrm %%WWWDIR%%/dojox/widget/nls + at dirrm %%WWWDIR%%/dojox/widget/Wizard + at dirrm %%WWWDIR%%/dojox/widget/Toaster + at dirrm %%WWWDIR%%/dojox/widget/SortList + at dirrm %%WWWDIR%%/dojox/widget/RollingList + at dirrm %%WWWDIR%%/dojox/widget/Pager/images + at dirrm %%WWWDIR%%/dojox/widget/Pager + at dirrm %%WWWDIR%%/dojox/widget/Loader/icons + at dirrm %%WWWDIR%%/dojox/widget/Loader + at dirrm %%WWWDIR%%/dojox/widget/FisheyeList + at dirrm %%WWWDIR%%/dojox/widget/FilePicker/images + at dirrm %%WWWDIR%%/dojox/widget/FilePicker + at dirrm %%WWWDIR%%/dojox/widget/DocTester + at dirrm %%WWWDIR%%/dojox/widget/Dialog/images + at dirrm %%WWWDIR%%/dojox/widget/Dialog + at dirrm %%WWWDIR%%/dojox/widget/ColorPicker/images + at dirrm %%WWWDIR%%/dojox/widget/ColorPicker + at dirrm %%WWWDIR%%/dojox/widget/Calendar + at dirrm %%WWWDIR%%/dojox/widget + at dirrm %%WWWDIR%%/dojox/validate + at dirrm %%WWWDIR%%/dojox/uuid + at dirrm %%WWWDIR%%/dojox/timing + at dirrm %%WWWDIR%%/dojox/testing + at dirrm %%WWWDIR%%/dojox/string + at dirrm %%WWWDIR%%/dojox/storage + at dirrm %%WWWDIR%%/dojox/sql + at dirrm %%WWWDIR%%/dojox/sketch/resources/images + at dirrm %%WWWDIR%%/dojox/sketch/resources + at dirrm %%WWWDIR%%/dojox/sketch + at dirrm %%WWWDIR%%/dojox/secure + at dirrm %%WWWDIR%%/dojox/rpc/SMDLibrary + at dirrm %%WWWDIR%%/dojox/rpc + at dirrm %%WWWDIR%%/dojox/robot + at dirrm %%WWWDIR%%/dojox/resources + at dirrm %%WWWDIR%%/dojox/presentation/resources/icons + at dirrm %%WWWDIR%%/dojox/presentation/resources + at dirrm %%WWWDIR%%/dojox/presentation + at dirrm %%WWWDIR%%/dojox/off/resources + at dirrm %%WWWDIR%%/dojox/off/docs + at dirrm %%WWWDIR%%/dojox/off + at dirrm %%WWWDIR%%/dojox/math + at dirrm %%WWWDIR%%/dojox/layout/resources/icons + at dirrm %%WWWDIR%%/dojox/layout/resources + at dirrm %%WWWDIR%%/dojox/layout/nls/fr + at dirrm %%WWWDIR%%/dojox/layout/nls/en + at dirrm %%WWWDIR%%/dojox/layout/nls + at dirrm %%WWWDIR%%/dojox/layout/dnd + at dirrm %%WWWDIR%%/dojox/layout + at dirrm %%WWWDIR%%/dojox/lang/functional + at dirrm %%WWWDIR%%/dojox/lang/aspect + at dirrm %%WWWDIR%%/dojox/lang + at dirrm %%WWWDIR%%/dojox/jsonPath + at dirrm %%WWWDIR%%/dojox/json + at dirrm %%WWWDIR%%/dojox/io/proxy/tests + at dirrm %%WWWDIR%%/dojox/io/proxy + at dirrm %%WWWDIR%%/dojox/io + at dirrm %%WWWDIR%%/dojox/image/resources/images + at dirrm %%WWWDIR%%/dojox/image/resources + at dirrm %%WWWDIR%%/dojox/image + at dirrm %%WWWDIR%%/dojox/html + at dirrm %%WWWDIR%%/dojox/highlight/resources/pygments + at dirrm %%WWWDIR%%/dojox/highlight/resources + at dirrm %%WWWDIR%%/dojox/highlight/languages/pygments + at dirrm %%WWWDIR%%/dojox/highlight/languages + at dirrm %%WWWDIR%%/dojox/highlight + at dirrm %%WWWDIR%%/dojox/help + at dirrm %%WWWDIR%%/dojox/grid/resources/images + at dirrm %%WWWDIR%%/dojox/grid/resources + at dirrm %%WWWDIR%%/dojox/grid/compat/tests/support + at dirrm %%WWWDIR%%/dojox/grid/compat/tests/images + at dirrm %%WWWDIR%%/dojox/grid/compat/tests + at dirrm %%WWWDIR%%/dojox/grid/compat/resources + at dirrm %%WWWDIR%%/dojox/grid/compat/_grid/images + at dirrm %%WWWDIR%%/dojox/grid/compat/_grid + at dirrm %%WWWDIR%%/dojox/grid/compat/_data + at dirrm %%WWWDIR%%/dojox/grid/compat + at dirrm %%WWWDIR%%/dojox/grid/cells + at dirrm %%WWWDIR%%/dojox/grid/_grid + at dirrm %%WWWDIR%%/dojox/grid + at dirrm %%WWWDIR%%/dojox/gfx3d + at dirrm %%WWWDIR%%/dojox/gfx/resources + at dirrm %%WWWDIR%%/dojox/gfx + at dirrm %%WWWDIR%%/dojox/fx/resources + at dirrm %%WWWDIR%%/dojox/fx/ext-dojo + at dirrm %%WWWDIR%%/dojox/fx + at dirrm %%WWWDIR%%/dojox/form/resources/images + at dirrm %%WWWDIR%%/dojox/form/resources + at dirrm %%WWWDIR%%/dojox/form/nls/zh-tw + at dirrm %%WWWDIR%%/dojox/form/nls/zh + at dirrm %%WWWDIR%%/dojox/form/nls/tr + at dirrm %%WWWDIR%%/dojox/form/nls/th + at dirrm %%WWWDIR%%/dojox/form/nls/sv + at dirrm %%WWWDIR%%/dojox/form/nls/sl + at dirrm %%WWWDIR%%/dojox/form/nls/sk + at dirrm %%WWWDIR%%/dojox/form/nls/ru + at dirrm %%WWWDIR%%/dojox/form/nls/pt-pt + at dirrm %%WWWDIR%%/dojox/form/nls/pt + at dirrm %%WWWDIR%%/dojox/form/nls/pl + at dirrm %%WWWDIR%%/dojox/form/nls/nl + at dirrm %%WWWDIR%%/dojox/form/nls/nb + at dirrm %%WWWDIR%%/dojox/form/nls/ko + at dirrm %%WWWDIR%%/dojox/form/nls/ja + at dirrm %%WWWDIR%%/dojox/form/nls/it + at dirrm %%WWWDIR%%/dojox/form/nls/hu + at dirrm %%WWWDIR%%/dojox/form/nls/he + at dirrm %%WWWDIR%%/dojox/form/nls/fr + at dirrm %%WWWDIR%%/dojox/form/nls/fi + at dirrm %%WWWDIR%%/dojox/form/nls/es + at dirrm %%WWWDIR%%/dojox/form/nls/el + at dirrm %%WWWDIR%%/dojox/form/nls/de + at dirrm %%WWWDIR%%/dojox/form/nls/da + at dirrm %%WWWDIR%%/dojox/form/nls/cs + at dirrm %%WWWDIR%%/dojox/form/nls/ca + at dirrm %%WWWDIR%%/dojox/form/nls/ar + at dirrm %%WWWDIR%%/dojox/form/nls + at dirrm %%WWWDIR%%/dojox/form + at dirrm %%WWWDIR%%/dojox/flash + at dirrm %%WWWDIR%%/dojox/encoding/digests + at dirrm %%WWWDIR%%/dojox/encoding/crypto + at dirrm %%WWWDIR%%/dojox/encoding/compression + at dirrm %%WWWDIR%%/dojox/encoding + at dirrm %%WWWDIR%%/dojox/embed/resources + at dirrm %%WWWDIR%%/dojox/embed/IE + at dirrm %%WWWDIR%%/dojox/embed + at dirrm %%WWWDIR%%/dojox/editor/plugins/resources/images + at dirrm %%WWWDIR%%/dojox/editor/plugins/resources + at dirrm %%WWWDIR%%/dojox/editor/plugins/nls + at dirrm %%WWWDIR%%/dojox/editor/plugins + at dirrm %%WWWDIR%%/dojox/editor + at dirrm %%WWWDIR%%/dojox/dtl/utils + at dirrm %%WWWDIR%%/dojox/dtl/tag + at dirrm %%WWWDIR%%/dojox/dtl/render + at dirrm %%WWWDIR%%/dojox/dtl/filter + at dirrm %%WWWDIR%%/dojox/dtl/ext-dojo + at dirrm %%WWWDIR%%/dojox/dtl/contrib + at dirrm %%WWWDIR%%/dojox/dtl + at dirrm %%WWWDIR%%/dojox/date + at dirrm %%WWWDIR%%/dojox/data/s3 + at dirrm %%WWWDIR%%/dojox/data + at dirrm %%WWWDIR%%/dojox/cometd + at dirrm %%WWWDIR%%/dojox/color + at dirrm %%WWWDIR%%/dojox/collections + at dirrm %%WWWDIR%%/dojox/charting/widget + at dirrm %%WWWDIR%%/dojox/charting/themes/PlotKit + at dirrm %%WWWDIR%%/dojox/charting/themes/ET + at dirrm %%WWWDIR%%/dojox/charting/themes + at dirrm %%WWWDIR%%/dojox/charting/scaler + at dirrm %%WWWDIR%%/dojox/charting/plot3d + at dirrm %%WWWDIR%%/dojox/charting/plot2d + at dirrm %%WWWDIR%%/dojox/charting/axis2d + at dirrm %%WWWDIR%%/dojox/charting/action2d + at dirrm %%WWWDIR%%/dojox/charting + at dirrm %%WWWDIR%%/dojox/av/widget/resources/images + at dirrm %%WWWDIR%%/dojox/av/widget/resources + at dirrm %%WWWDIR%%/dojox/av/widget + at dirrm %%WWWDIR%%/dojox/av/resources + at dirrm %%WWWDIR%%/dojox/av + at dirrm %%WWWDIR%%/dojox/analytics/profiles + at dirrm %%WWWDIR%%/dojox/analytics/plugins + at dirrm %%WWWDIR%%/dojox/analytics/logger + at dirrm %%WWWDIR%%/dojox/analytics + at dirrm %%WWWDIR%%/dojox + at dirrm %%WWWDIR%%/dojo/rpc + at dirrm %%WWWDIR%%/dojo/resources/images + at dirrm %%WWWDIR%%/dojo/resources + at dirrm %%WWWDIR%%/dojo/nls/zh-tw + at dirrm %%WWWDIR%%/dojo/nls/zh + at dirrm %%WWWDIR%%/dojo/nls/tr + at dirrm %%WWWDIR%%/dojo/nls/th + at dirrm %%WWWDIR%%/dojo/nls/sv + at dirrm %%WWWDIR%%/dojo/nls/sl + at dirrm %%WWWDIR%%/dojo/nls/sk + at dirrm %%WWWDIR%%/dojo/nls/ru + at dirrm %%WWWDIR%%/dojo/nls/pt-pt + at dirrm %%WWWDIR%%/dojo/nls/pt + at dirrm %%WWWDIR%%/dojo/nls/pl + at dirrm %%WWWDIR%%/dojo/nls/nl + at dirrm %%WWWDIR%%/dojo/nls/nb + at dirrm %%WWWDIR%%/dojo/nls/ko + at dirrm %%WWWDIR%%/dojo/nls/ja + at dirrm %%WWWDIR%%/dojo/nls/it + at dirrm %%WWWDIR%%/dojo/nls/hu + at dirrm %%WWWDIR%%/dojo/nls/he + at dirrm %%WWWDIR%%/dojo/nls/fr + at dirrm %%WWWDIR%%/dojo/nls/fi + at dirrm %%WWWDIR%%/dojo/nls/es + at dirrm %%WWWDIR%%/dojo/nls/el + at dirrm %%WWWDIR%%/dojo/nls/de + at dirrm %%WWWDIR%%/dojo/nls/da + at dirrm %%WWWDIR%%/dojo/nls/cs + at dirrm %%WWWDIR%%/dojo/nls/ca + at dirrm %%WWWDIR%%/dojo/nls/ar + at dirrm %%WWWDIR%%/dojo/nls + at dirrm %%WWWDIR%%/dojo/io + at dirrm %%WWWDIR%%/dojo/fx + at dirrm %%WWWDIR%%/dojo/dnd + at dirrm %%WWWDIR%%/dojo/date + at dirrm %%WWWDIR%%/dojo/data/util + at dirrm %%WWWDIR%%/dojo/data/api + at dirrm %%WWWDIR%%/dojo/data + at dirrm %%WWWDIR%%/dojo/cldr/nls/zh-tw + at dirrm %%WWWDIR%%/dojo/cldr/nls/zh-cn + at dirrm %%WWWDIR%%/dojo/cldr/nls/zh + at dirrm %%WWWDIR%%/dojo/cldr/nls/pt-br + at dirrm %%WWWDIR%%/dojo/cldr/nls/pt + at dirrm %%WWWDIR%%/dojo/cldr/nls/ko-kr + at dirrm %%WWWDIR%%/dojo/cldr/nls/ko + at dirrm %%WWWDIR%%/dojo/cldr/nls/ja-jp + at dirrm %%WWWDIR%%/dojo/cldr/nls/ja + at dirrm %%WWWDIR%%/dojo/cldr/nls/it-it + at dirrm %%WWWDIR%%/dojo/cldr/nls/it + at dirrm %%WWWDIR%%/dojo/cldr/nls/fr + at dirrm %%WWWDIR%%/dojo/cldr/nls/es-es + at dirrm %%WWWDIR%%/dojo/cldr/nls/es + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-us + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-gb + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-ca + at dirrm %%WWWDIR%%/dojo/cldr/nls/en-au + at dirrm %%WWWDIR%%/dojo/cldr/nls/en + at dirrm %%WWWDIR%%/dojo/cldr/nls/de-de + at dirrm %%WWWDIR%%/dojo/cldr/nls/de + at dirrm %%WWWDIR%%/dojo/cldr/nls + at dirrm %%WWWDIR%%/dojo/cldr + at dirrm %%WWWDIR%%/dojo/_firebug + at dirrm %%WWWDIR%%/dojo/_base/_loader + at dirrm %%WWWDIR%%/dojo/_base + at dirrm %%WWWDIR%%/dojo + at dirrm %%WWWDIR%%/dijit/themes/tundra/layout + at dirrm %%WWWDIR%%/dijit/themes/tundra/images + at dirrm %%WWWDIR%%/dijit/themes/tundra/form + at dirrm %%WWWDIR%%/dijit/themes/tundra + at dirrm %%WWWDIR%%/dijit/themes/themeTesterImages + at dirrm %%WWWDIR%%/dijit/themes/soria/layout + at dirrm %%WWWDIR%%/dijit/themes/soria/images + at dirrm %%WWWDIR%%/dijit/themes/soria/form + at dirrm %%WWWDIR%%/dijit/themes/soria + at dirrm %%WWWDIR%%/dijit/themes/nihilo/layout + at dirrm %%WWWDIR%%/dijit/themes/nihilo/images + at dirrm %%WWWDIR%%/dijit/themes/nihilo/form + at dirrm %%WWWDIR%%/dijit/themes/nihilo + at dirrm %%WWWDIR%%/dijit/themes/a11y + at dirrm %%WWWDIR%%/dijit/themes + at dirrm %%WWWDIR%%/dijit/resources + at dirrm %%WWWDIR%%/dijit/nls/zh-tw + at dirrm %%WWWDIR%%/dijit/nls/zh + at dirrm %%WWWDIR%%/dijit/nls/tr + at dirrm %%WWWDIR%%/dijit/nls/th + at dirrm %%WWWDIR%%/dijit/nls/sv + at dirrm %%WWWDIR%%/dijit/nls/sl + at dirrm %%WWWDIR%%/dijit/nls/sk + at dirrm %%WWWDIR%%/dijit/nls/ru + at dirrm %%WWWDIR%%/dijit/nls/pt-pt + at dirrm %%WWWDIR%%/dijit/nls/pt + at dirrm %%WWWDIR%%/dijit/nls/pl + at dirrm %%WWWDIR%%/dijit/nls/nl + at dirrm %%WWWDIR%%/dijit/nls/nb + at dirrm %%WWWDIR%%/dijit/nls/ko + at dirrm %%WWWDIR%%/dijit/nls/ja + at dirrm %%WWWDIR%%/dijit/nls/it + at dirrm %%WWWDIR%%/dijit/nls/hu + at dirrm %%WWWDIR%%/dijit/nls/he + at dirrm %%WWWDIR%%/dijit/nls/fr + at dirrm %%WWWDIR%%/dijit/nls/fi + at dirrm %%WWWDIR%%/dijit/nls/es + at dirrm %%WWWDIR%%/dijit/nls/el + at dirrm %%WWWDIR%%/dijit/nls/de + at dirrm %%WWWDIR%%/dijit/nls/da + at dirrm %%WWWDIR%%/dijit/nls/cs + at dirrm %%WWWDIR%%/dijit/nls/ca + at dirrm %%WWWDIR%%/dijit/nls/ar + at dirrm %%WWWDIR%%/dijit/nls + at dirrm %%WWWDIR%%/dijit/layout + at dirrm %%WWWDIR%%/dijit/form/nls/zh-tw + at dirrm %%WWWDIR%%/dijit/form/nls/zh + at dirrm %%WWWDIR%%/dijit/form/nls/tr + at dirrm %%WWWDIR%%/dijit/form/nls/th + at dirrm %%WWWDIR%%/dijit/form/nls/sv + at dirrm %%WWWDIR%%/dijit/form/nls/sl + at dirrm %%WWWDIR%%/dijit/form/nls/sk + at dirrm %%WWWDIR%%/dijit/form/nls/ru + at dirrm %%WWWDIR%%/dijit/form/nls/pt-pt + at dirrm %%WWWDIR%%/dijit/form/nls/pt + at dirrm %%WWWDIR%%/dijit/form/nls/pl + at dirrm %%WWWDIR%%/dijit/form/nls/nl + at dirrm %%WWWDIR%%/dijit/form/nls/nb + at dirrm %%WWWDIR%%/dijit/form/nls/ko + at dirrm %%WWWDIR%%/dijit/form/nls/ja + at dirrm %%WWWDIR%%/dijit/form/nls/it + at dirrm %%WWWDIR%%/dijit/form/nls/hu + at dirrm %%WWWDIR%%/dijit/form/nls/he + at dirrm %%WWWDIR%%/dijit/form/nls/fr + at dirrm %%WWWDIR%%/dijit/form/nls/fi + at dirrm %%WWWDIR%%/dijit/form/nls/es + at dirrm %%WWWDIR%%/dijit/form/nls/el + at dirrm %%WWWDIR%%/dijit/form/nls/de + at dirrm %%WWWDIR%%/dijit/form/nls/da + at dirrm %%WWWDIR%%/dijit/form/nls/cs + at dirrm %%WWWDIR%%/dijit/form/nls/ca + at dirrm %%WWWDIR%%/dijit/form/nls/ar + at dirrm %%WWWDIR%%/dijit/form/nls + at dirrm %%WWWDIR%%/dijit/form + at dirrm %%WWWDIR%%/dijit/_tree + at dirrm %%WWWDIR%%/dijit/_editor/plugins + at dirrm %%WWWDIR%%/dijit/_editor/nls/zh-tw + at dirrm %%WWWDIR%%/dijit/_editor/nls/zh + at dirrm %%WWWDIR%%/dijit/_editor/nls/tr + at dirrm %%WWWDIR%%/dijit/_editor/nls/th + at dirrm %%WWWDIR%%/dijit/_editor/nls/sv + at dirrm %%WWWDIR%%/dijit/_editor/nls/sl + at dirrm %%WWWDIR%%/dijit/_editor/nls/sk + at dirrm %%WWWDIR%%/dijit/_editor/nls/ru + at dirrm %%WWWDIR%%/dijit/_editor/nls/pt-pt + at dirrm %%WWWDIR%%/dijit/_editor/nls/pt + at dirrm %%WWWDIR%%/dijit/_editor/nls/pl + at dirrm %%WWWDIR%%/dijit/_editor/nls/nl + at dirrm %%WWWDIR%%/dijit/_editor/nls/nb + at dirrm %%WWWDIR%%/dijit/_editor/nls/ko + at dirrm %%WWWDIR%%/dijit/_editor/nls/ja + at dirrm %%WWWDIR%%/dijit/_editor/nls/it + at dirrm %%WWWDIR%%/dijit/_editor/nls/hu + at dirrm %%WWWDIR%%/dijit/_editor/nls/he + at dirrm %%WWWDIR%%/dijit/_editor/nls/fr + at dirrm %%WWWDIR%%/dijit/_editor/nls/fi + at dirrm %%WWWDIR%%/dijit/_editor/nls/es + at dirrm %%WWWDIR%%/dijit/_editor/nls/el + at dirrm %%WWWDIR%%/dijit/_editor/nls/de + at dirrm %%WWWDIR%%/dijit/_editor/nls/da + at dirrm %%WWWDIR%%/dijit/_editor/nls/cs + at dirrm %%WWWDIR%%/dijit/_editor/nls/ca + at dirrm %%WWWDIR%%/dijit/_editor/nls/ar + at dirrm %%WWWDIR%%/dijit/_editor/nls + at dirrm %%WWWDIR%%/dijit/_editor + at dirrm %%WWWDIR%%/dijit/_base + at dirrm %%WWWDIR%%/dijit + at dirrm %%WWWDIR%% --- /dev/null +++ www/dojo/Makefile @@ -0,0 +1,54 @@ +# $MidnightBSD: mports/www/dojo/Makefile,v 1.1 2009/01/29 17:52:54 laffer1 Exp $ + +PORTNAME= dojo +PORTVERSION= 1.2.3 +CATEGORIES= www +MASTER_SITES= http://download.dojotoolkit.org/release-${PORTVERSION}/ \ + LOCAL/glarkin +DISTNAME= dojo-release-${PORTVERSION} + +MAINTAINER= ports at MidnightBSD.org +COMMENT= An open-source DHTML toolkit written in JavaScript +LICENSE= bsd3 + +NO_BUILD= yes + +OPTIONS= APACHE "Configure for Apache-2.x" off + +.include + +PLIST_SUB+= WWWDIR=www/${PORTNAME} + +.if defined(WITH_APACHE) +USE_APACHE= 2.0+ +CONFDIR= ${PREFIX}/${CONFDIR_REL} +CONFDIR_REL= ${APACHEETCDIR}/Includes +PLIST_SUB+= NOAPACHE="" CONFDIR=${CONFDIR_REL} +CONF= dojo.conf +SUB_FILES+= pkg-message ${CONF} +.else +PLIST_SUB+= NOAPACHE="@comment " +.endif + +do-install: + @${MKDIR} ${PREFIX}/www/${PORTNAME} + (cd ${WRKSRC} && pax -rw . ${PREFIX}/www/${PORTNAME}) + @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${PREFIX}/www/${PORTNAME} + @${FIND} ${PREFIX}/www/${PORTNAME} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 + @${FIND} ${PREFIX}/www/${PORTNAME} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 + +.if defined(WITH_APACHE) +post-install: + @if [ -d "${CONFDIR}" ]; then \ + ${CP} ${WRKDIR}/${CONF} ${CONFDIR}/dojo.conf; \ + else \ + ${ECHO_MSG} "" ; \ + ${ECHO_MSG} "Please check your Apache 2.x installation -" ; \ + ${ECHO_MSG} "${CONFDIR} doesn't exist," ; \ + ${ECHO_MSG} "so I cannot install ${CONF} there!" ; \ + ${ECHO_MSG} "" ; \ + ${FALSE} ; \ + fi +.endif + +.include --- /dev/null +++ www/dojo/distinfo @@ -0,0 +1,3 @@ +MD5 (dojo-release-1.2.3.tar.gz) = ee6375dc812c75bbe3953b8c24f5cae5 +SHA256 (dojo-release-1.2.3.tar.gz) = 66afd514deff7f785dd3e95b31c72968677f0d9b3d6ba1da59743176b0d292fc +SIZE (dojo-release-1.2.3.tar.gz) = 1715583 --- /dev/null +++ www/dojo/files/pkg-message.in @@ -0,0 +1,11 @@ +You have just installed the Dojo DHTML toolkit. + +Note that you should restart your Apache web server to ensure that +the Dojo configuration file is loaded. + +Dojo toolkit demonstration pages can be found at: +http://localhost/dojo/dijit/demos/chat.html +http://localhost/dojo/dijit/demos/form.html +http://localhost/dojo/dijit/demos/i18n.html +http://localhost/dojo/dijit/demos/mail.html +http://localhost/dojo/dijit/demos/nihao.html --- /dev/null +++ www/dojo/files/dojo.conf.in @@ -0,0 +1,6 @@ +Alias /dojo %%WWWDIR%% + + + Order deny,allow + Allow from all + --- /dev/null +++ www/zend-framework/pkg-descr @@ -0,0 +1,6 @@ +This is a port of the Zend Framework. The Zend Framework aims to +provide an architecture for developing entire applications with no +other library dependencies. This code will always be actively developed, +tested, and supported by Zend and the PHP Collaboration Project. + +WWW: http://framework.zend.com/ --- /dev/null +++ www/zend-framework/pkg-plist @@ -0,0 +1,8135 @@ +%%DOJO%%%%DATADIR%%/externals/dojo/demos/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/13.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/1984.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/25.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/25_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/26.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/26_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/27.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/27_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/cinema.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/clicks.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/closterkeller.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/colony5.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/deinelakaien.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/genesis.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/godsbow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/made.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/main.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/nightspirit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/pati.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/redmprez.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/sieben.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/soon.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/images/thy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/castle/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/alarm.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/bg.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/board.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/bubble.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/correct.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/incorrect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/questions.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/remaining.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/slow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/teacher_body.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/teacher_eyes_closed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/teacher_mouth_angry.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/images/try_again.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/MathFlashCard.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/MathFlashCard.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/Teacher.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/Teacher.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/Teacher.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/flashCards/src/tests/test_Teacher.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/charts.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/comic.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/img/comicstrip.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/resources/bookplate.svg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/resources/digistrip.svg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/resources/eurostyle.svg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/charts.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/comic.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/news.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/fonts/src/pie.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/form/states.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/continents.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/flags.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/flags.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/languages.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/languages.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/model.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/normalizeJson.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/sprite.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/i18n/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/contacts.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/icons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/icons.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/mail.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mail/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/background.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/download.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/downloadnow.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/logo.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/logo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/shot3.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/images/shot3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/src/download.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/mojo/src/drop.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/en/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/fr/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/nihao/nls/zh/helloworld.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/accept.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/anchor.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_cascade.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_double.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_form_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_get.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_home.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_osx.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_osx_terminal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_boxes.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_contract.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_expand.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_list.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_side_tree.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_split.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_tile_horizontal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_tile_vertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_columns.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_detail.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_gallery.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_icons.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_list.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_view_tile.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_xp.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/application_xp_terminal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_branch.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_divide.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_down.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_inout.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_join.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_merge.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_redo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_refresh_small.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_rotate_anticlockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_rotate_clockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_switch.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_turn_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_turn_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_undo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/arrow_up.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/asterisk_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/asterisk_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/attach.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_bronze_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_bronze_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_bronze_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_gold_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_gold_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_gold_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_silver_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_silver_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/award_star_silver_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/basket_remove.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bell_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bin_closed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bin_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bomb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_addresses.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_next.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/book_previous.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/box.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/brick_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bricks.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/briefcase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bug_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/building_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_down.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_top.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_arrow_up.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_black.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_feed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_pink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_purple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_toggle_minus.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_toggle_plus.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_white.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/bullet_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cake.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calculator_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_view_day.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_view_month.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/calendar_view_week.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/camera_small.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cancel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/car.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/car_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/car_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cart_remove.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_burn.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_eject.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cd_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_bar_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_curve_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_line_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_organisation.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_organisation_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_organisation_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/chart_pie_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_pause.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_play.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/clock_stop.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cog_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/coins.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/coins_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/coins_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/color_swatch.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/color_wheel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comment_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comments.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comments_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/comments_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/compress.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/computer_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/connect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_decrease.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_high.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_increase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/contrast_low.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_eject.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_eject_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_end.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_end_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_equalizer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_equalizer_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_fastforward.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_fastforward_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_pause.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_pause_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_play.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_play_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_repeat.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_repeat_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_rewind.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_rewind_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_start.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_start_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_stop.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/control_stop_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/controller_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/creditcards.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cross.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/css_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cup_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cursor.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cut.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/cut_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_connect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/database_table.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_next.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/date_previous.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/disconnect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/disk_multiple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/door_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drink_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_burn.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_cd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_cd_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_network.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_rename.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/drive_web.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/dvd_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_attach.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/email_open_image.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_evilgrin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_grin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_happy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_smile.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_surprised.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_tongue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_unhappy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_waii.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/emoticon_wink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/error_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/exclamation.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/eye.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/feed_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/female.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/film_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_pink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_purple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/flag_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_bell.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_brick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_bug.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_camera.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_explore.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_feed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_heart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_image.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_lightbulb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_page.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_page_white.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_palette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_table.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/folder_wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/font_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/group_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/heart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/heart_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/heart_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/help.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/hourglass_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/house.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/house_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/house_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/html_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/image_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/images.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/information.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_cast.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_cast_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_cast_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ipod_sound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/joystick_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/key_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/keyboard_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layers.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_content.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_header.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/layout_sidebar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightbulb_off.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lightning_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_break.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/link_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_break.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lock_open.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_flatbed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/lorry_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/magifier_zoom_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/magnifier.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/magnifier_zoom_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/male.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/map_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_bronze_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_gold_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/medal_silver_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_dollar.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_euro.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_pound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/money_yen.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/monitor_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/mouse_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/music.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/new.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/newspaper_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/note_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/overlays.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/package_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_attach.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_code.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_copy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_excel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_paintbrush.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_paste.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_acrobat.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_actionscript.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_c.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_camera.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_cd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_code.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_code_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_coldfusion.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_compressed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_copy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_cplusplus.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_csharp.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_cup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_dvd.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_excel.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_find.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_flash.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_freehand.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_get.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_h.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_horizontal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_medal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_office.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_paint.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_paintbrush.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_paste.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_php.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_powerpoint.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_ruby.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_stack.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_swoosh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_text.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_text_width.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_tux.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_vector.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_visualstudio.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_width.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_world.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_white_zip.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/page_world.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paintbrush.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paintcan.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/palette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paste_plain.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/paste_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pencil_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/phone_sound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photo_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/photos.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/picture_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pictures.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pilcrow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/pill_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_disabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/plugin_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_empty.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/printer_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rainbow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_disk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_magnify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_picture.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/report_word.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_first.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_last.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_next.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/resultset_previous.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rosette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/rss_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_get.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/ruby_put.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_code.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_code_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_palette.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/script_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_chart.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_compressed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_connect.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_database.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/server_uncompressed.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shading.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_center.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_middle.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_align_top.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_flip_horizontal.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_flip_vertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_group.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_handles.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_back.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_backwards.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_forwards.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_move_front.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_rotate_anticlockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_rotate_clockwise.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_square_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shape_ungroup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/shield_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sitemap.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sitemap_color.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_low.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_mute.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sound_none.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/spellcheck.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_8ball.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_basketball.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_football.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_golf.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_raquet.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_shuttlecock.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_soccer.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sport_tennis.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/star.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_away.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_busy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_offline.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/status_online.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/stop.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/style_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/sum.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tab_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_gear.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_multiple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_refresh.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_relationship.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_row_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_row_insert.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_save.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/table_sort.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_blue_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_pink.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_purple.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tag_yellow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/telephone_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/television.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/television_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/television_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_center.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_justify.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_align_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_allcaps.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_bold.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_columns.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_dropcaps.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_1.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_2.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_3.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_4.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_5.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_heading_6.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_horizontalrule.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_indent.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_indent_remove.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_italic.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_kerning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_letter_omega.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_letterspacing.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_linespacing.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_list_bullets.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_list_numbers.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_lowercase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_left.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_right.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_padding_top.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_replace.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_signature.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_smallcaps.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_strikethrough.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_subscript.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_superscript.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_underline.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/text_uppercase.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_key.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/textfield_rename.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/thumb_down.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/thumb_up.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tick.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/time_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/timeline_marker.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_blue.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/transmit_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/tux.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_comment.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_female.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_gray.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_green.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_red.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/user_suit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vcard_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vector.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vector_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/vector_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/wand.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_clouds.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_cloudy.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_lightning.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_rain.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_snow.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/weather_sun.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/webcam_error.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_edit.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/world_link.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/wrench.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/wrench_orange.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_add.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_delete.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_go.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/xhtml_valid.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/zoom.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/zoom_in.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/icons/zoom_out.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/readme.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/silk/readme.txt +%%DOJO%%%%DATADIR%%/externals/dojo/demos/resources/users.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/buildDemo.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/imageReflect.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/bg01.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/info.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/logo.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/round.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/square.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/alex.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/becka11y.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/bforbes.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/blowery.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/blowery.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/bradn.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dante.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dante.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/davidb.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dmachi.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dmachi.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/dylanks.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/eugene.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/gregw.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/heng.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/itorrey.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/itorrey.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/jared_j.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/kris.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/mccain.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/nonken.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/ntoone.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/pottedmeat.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/rcoup.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/sfoster.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/ttrenka.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/images/users/wildbill.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/src/Image.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/skew/src/image-lib.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/UploadFile.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/buildDemo.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/cLOG.php +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/uploader/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/README +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/buildDemo.sh +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/demo.css +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/demo.html +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/demo.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/blkBk.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/playerIcons +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/volBack.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/volBackOver.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/images/volMask.png +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/items.json +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Clayman_01.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Clayman_02.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Clayman_03.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Grog.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Manager.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/OldMan.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/TapDance.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/Walkin.flv +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Clayman_01.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Clayman_02.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Clayman_03.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Grog.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Manager.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/OldMan.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/TapDance.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/media/thumbs/Walkin.jpg +%%DOJO%%%%DATADIR%%/externals/dojo/demos/video/src.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/ColorPalette.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Declaration.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Dialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Editor.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/InlineEditBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Menu.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/ProgressBar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/TitlePane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Toolbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Tooltip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/Tree.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Calendar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Container.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Templated.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_TimePicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_Widget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/focus.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/manager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/place.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/popup.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/scroll.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/sniff.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/typematic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/wai.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_base/window.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/RichText.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/_Plugin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ar/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ar/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ar/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ca/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ca/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ca/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/cs/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/cs/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/cs/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/da/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/da/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/da/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/de/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/de/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/de/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/el/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/el/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/el/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/es/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/es/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/es/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fi/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fi/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fi/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fr/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fr/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/fr/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/he/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/he/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/he/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/hu/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/hu/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/hu/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/it/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/it/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/it/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ja/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ja/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ja/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ko/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ko/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ko/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nb/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nb/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nb/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nl/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nl/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/nl/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pl/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pl/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pl/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/pt/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ru/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ru/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/ru/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sk/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sk/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sk/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sl/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sl/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sl/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sv/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sv/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/sv/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/th/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/th/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/th/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/tr/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/tr/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/tr/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/nls/zh/commands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/AlwaysShowToolbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/EnterKeyHandling.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/FontChoice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/LinkDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/TabIndent.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/TextColor.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/plugins/ToggleDir.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/range.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_editor/selection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/Node.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/Tree.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/dndContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/dndSelector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/dndSource.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/_tree/model.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/dijit-all.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/dijit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Button.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/CheckBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/CurrencyTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/DateTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/FilteringSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Form.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/MultiSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/NumberSpinner.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/NumberTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/SimpleTextarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Slider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/TextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/TimeTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/ValidationTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/_DateTimeTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/_FormWidget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/_Spinner.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ar/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ar/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ar/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ca/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ca/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ca/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/cs/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/cs/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/cs/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/da/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/da/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/da/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/de/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/de/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/de/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/el/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/el/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/el/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/es/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/es/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/es/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fi/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fi/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fi/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fr/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fr/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/fr/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/he/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/he/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/he/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/hu/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/hu/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/hu/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/it/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/it/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/it/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ja/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ja/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ja/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ko/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ko/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ko/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nb/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nb/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nb/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nl/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nl/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/nl/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pl/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pl/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pl/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/pt/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ru/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ru/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/ru/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sk/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sk/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sk/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sl/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sl/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sl/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sv/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sv/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/sv/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/th/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/th/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/th/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/tr/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/tr/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/tr/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh/ComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh/Textarea.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/nls/zh/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/Button.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/CheckBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/ComboBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/ComboButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/DropDownButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/HorizontalSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/Spinner.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/TextBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/ValidationTextBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/form/templates/VerticalSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/AccordionContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/BorderContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/ContentPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/LayoutContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/LinkPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/SplitContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/StackContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/TabContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/_LayoutWidget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/templates/AccordionPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/templates/TabContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/layout/templates/_TabButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ar/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ar/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ca/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ca/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/cs/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/cs/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/da/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/da/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/de/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/de/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/el/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/el/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/es/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/es/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fi/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fi/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fr/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/fr/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/he/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/he/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/hu/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/hu/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/it/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/it/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ja/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ja/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ko/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ko/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nb/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nb/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nl/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/nl/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pl/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pl/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt-pt/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt-pt/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/pt/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ru/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/ru/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sk/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sk/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sl/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sl/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sv/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/sv/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/th/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/th/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/tr/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/tr/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh-tw/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh-tw/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/nls/zh/loading.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/resources/_modules.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/robot.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/robotx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/Calendar.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/ColorPalette.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/Dialog.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/InlineEditBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/ProgressBar.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/TimePicker.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/TitlePane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/Tooltip.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/templates/TooltipDialog.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/tests/_data/countries.json +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/tests/_testCommon.js +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/README.txt +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/colors3x4.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/colors7x10.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/a11y/indeterminate_progress.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/dijit.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/dijit_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Calendar_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/ColorPalette.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Dialog_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Editor.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Editor_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Menu.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Menu_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/ProgressBar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/TimePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/TitlePane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/TitlePane_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Toolbar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Tree.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/Tree_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Button.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Button_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Checkbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/ComboBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Common_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/RadioButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Slider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/Slider_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/form/TimeTextBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/accordionItemActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/buttonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editor.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editorDisabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editorDisabled_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/no.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/preciseSliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/progressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/progressBarEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/progressBarFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderEmptyVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFullFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFullVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderFullVerticalFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/sliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerH-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerH.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerV-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/splitContainerSizerV.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteArrows.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteArrows.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteCheckbox.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteCheckbox.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteDivIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteDivIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRadio.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRadio.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRoundedIconsSmall.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteRoundedIconsSmall.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/spriteTree_rtl.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomActiveC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomActiveSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomEnabledC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomEnabledSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomHoverC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabBottomHoverSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabContainerSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabLeftChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabRightChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripe.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripeBottom.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripeLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tabStripeRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/titleBar.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/titleBarActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorLeft.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorRight.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorUp.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/tooltipConnectorUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeExpand_loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI_half.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI_half_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/treeI_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/validationInputBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/validationInputBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/AccordionContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/AccordionContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/BorderContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/ContentPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/SplitContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/TabContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout/TabContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/nihilo.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/nihilo/nihilo_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/buttonHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/close.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/closeActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/closeHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonArrowHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonBtnHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/comboButtonEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-center.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-center.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-right-06.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-center.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/ddButtonHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/images.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/selectHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerActive-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerActive-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerDisabled-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerEnabled-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerHover-bottom.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/spinnerHover-top.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabActive-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabActive-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabActive-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabDisabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabDisabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabDisabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabEnabled-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabEnabled-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabEnabled-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabHover-left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabHover-right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/tabHover-stretch.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/noir.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/noir.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/noir/noir.psd +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Calendar_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/ColorPalette.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Dialog_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Editor.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Editor_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Menu.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Menu_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/ProgressBar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/TimePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/TitlePane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/TitlePane_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Toolbar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Tree.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/Tree_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Button.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Button_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Checkbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/ComboBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Common_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/RadioButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Slider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/Slider_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/form/TimeTextBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/accordionItemActive.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/accordionItemActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/buttonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editor.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editorDisabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editorDisabled_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/preciseSliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/progressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/progressBarEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/progressBarFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderEmptyVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFullFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFullVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderFullVerticalFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/sliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerH-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerH.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerV-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/splitContainerSizerV.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteArrows.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteArrows.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteCheckbox.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteCheckbox.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteDivIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteDivIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRadio.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRadio.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmall.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmall.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmallBl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteRoundedIconsSmallBl.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/spriteTree_rtl.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomActiveC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomActiveSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomEnabledC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomEnabledSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomHoverC.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabBottomHoverSpriteLR.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabContainerSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabLeftChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabRightChecked.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripe.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripeBottom.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripeLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tabStripeRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/titleBar.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/titleBarActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorLeft.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorRight.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorUp.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/tooltipConnectorUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeExpand_loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI_half.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI_half_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/treeI_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/validationInputBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/validationInputBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/AccordionContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/AccordionContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/BorderContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/ContentPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/SplitContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/TabContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/layout/TabContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/soria.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/soria/soria_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/templateThemeTest.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTester.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTesterImages/blackButtonEnabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTesterImages/blackButtonHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/themeTesterQuirk.html +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Calendar_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/ColorPalette.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Dialog_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Editor.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Editor_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Menu.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Menu_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/ProgressBar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/TimePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/TitlePane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/TitlePane_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Toolbar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Tree.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/Tree_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Button.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Checkbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Common.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Common_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/RadioButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Slider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/form/Slider_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/accordionItemActive.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/accordionItemHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/buttonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/calendarDayLabel.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/calendarMonthLabel.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/calendarYearLabel.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmark.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmark.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmarkNoBorder.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/checkmarkNoBorder.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/circleIcon.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/circleIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/comboArrowDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dijitProgressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dijitProgressBarAnim.psd +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dojoTundraGradientBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/dojoTundraGradientBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/doubleArrowDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/doubleArrowUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editor.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editorDisabled.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editorDisabled_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/editor_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/folderClosed.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/folderOpened.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i_half.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i_half_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/i_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/leaf.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/menu.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/minusButton.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/no.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/noX.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/plusButton.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/popupMenuBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumb.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/preciseSliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-1.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-2.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-3.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-4.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-5.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-6.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-7.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-8.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim-9.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarAnim.psd +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/progressBarFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonActiveDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonActiveHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/radioButtonHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderEmpty.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderEmptyVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFull.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFullFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFullVertical.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderFullVerticalFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderThumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderThumbFocus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/sliderThumbFocus.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/smallArrowDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/smallArrowUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerH-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerH.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerV-thumb.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/splitContainerSizerV.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteArrows.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteArrows.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteRoundedIconsSmall.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/spriteRoundedIconsSmall.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabClose.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabClose.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabCloseHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabCloseHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabDisabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabEnabled.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabHover.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tabHover.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/titleBar.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/titleBarBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorDown.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorDown.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorLeft.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorLeft.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorRight.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorRight.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorUp.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/tooltipConnectorUp.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_leaf.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_leaf_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_minus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_minus_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_mius.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_plus.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/treeExpand_plus_rtl.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/validationInputBg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/validationInputBg.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/AccordionContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/BorderContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/ContentPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/SplitContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/TabContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/layout/TabContainer_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dijit/themes/tundra/tundra.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/AdapterRegistry.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/DeferredList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/NodeList-fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/NodeList-html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/OpenAjax.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/Color.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/Deferred.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/NodeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/bootstrap.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/hostenv_browser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/hostenv_rhino.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/hostenv_spidermonkey.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/loader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/loader_debug.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/_loader/loader_xd.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/array.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/browser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/connect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/declare.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/event.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/json.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/lang.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/query.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/window.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_base/xhr.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/errorIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/firebug.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/firebug.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/infoIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_lft_norm.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_lft_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_rgt_norm.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/tab_rgt_over.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/_firebug/warningIcon.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/back.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/behavior.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/monetary.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de-de/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/de/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-ca/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-ca/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-gb/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-gb/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-us/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en-us/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/en/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es-es/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es-es/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/es/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/fr/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/fr/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/fr/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it-it/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/it/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja-jp/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ja/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko-kr/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko-kr/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/ko/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt-br/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/pt/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-cn/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-cn/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh/gregorian.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/nls/zh/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cldr/supplemental.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/cookie.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/currency.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/ItemFileReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/ItemFileWriteStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Identity.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Notification.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Read.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Request.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/api/Write.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/util/filter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/util/simpleFetch.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/data/util/sorter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/date.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/date/locale.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/date/stamp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Avatar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Container.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Manager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Moveable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Mover.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Selector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/Source.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/TimedMoveable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/autoscroll.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dnd/move.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/dojo.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/fx/easing.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/gears.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/i18n.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/io/iframe.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/io/script.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/jaxer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ar/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ca/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/cs/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/da/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/de/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/el/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/es/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/fi/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/fr/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/he/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/hu/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/it/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ja/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ko/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/nb/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/nl/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/pl/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/pt-pt/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/pt/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/ru/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/sk/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/sl/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/sv/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/th/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/tr/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/zh-tw/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/nls/zh/colors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/number.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/parser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/regexp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/_modules.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/blank.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/blank.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/dnd.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/dojo.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/iframe_history.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndNoCopy.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/resources/images/dndNoMove.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/robot.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/robotx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/rpc/JsonService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/rpc/JsonpService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/rpc/RpcService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/string.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojo/tests.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/Urchin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/logger/JSON.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/logger/dojoxAnalytics.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/consoleMessages.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/dojo.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/idle.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/mouseClick.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/mouseOver.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/plugins/window.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/profiles/analytics.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/analytics/profiles/analyticsInBase.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/FLVideo.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/_Media.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/resources/version.mov +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/resources/video.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/PlayButton.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/Player.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/ProgressSlider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/Status.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/VolumeButton.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/PlayButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/Player.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/Player.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/ProgressSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/Status.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/VolumeButton.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/dojoPlayerIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/playerIcons +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/player_sprite.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/progressLoadedBk.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/progressPositionBk.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/sliderHandleNorm.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/sliderHandleOver.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/av/widget/resources/images/sliderHandleSprite.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Chart2D.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Chart3D.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Element.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Series.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/Theme.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Highlight.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Magnify.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/MoveSlice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Shake.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/action2d/Tooltip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/axis2d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/axis2d/Default.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/axis2d/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Areas.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Bars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Bubble.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/ClusteredBars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/ClusteredColumns.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Columns.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Default.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Lines.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Markers.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/MarkersOnly.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Pie.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Scatter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/Stacked.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedAreas.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedBars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedColumns.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/StackedLines.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot2d/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot3d/Bars.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot3d/Base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/plot3d/Cylinders.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/scaler/common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/scaler/linear.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/scaler/primitive.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Adobebricks.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Algae.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Bahamation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/BlueDusk.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/CubanShirts.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Desert.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Dollar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/ET/greys.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Grasshopper.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Grasslands.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/GreySkies.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/IndigoNation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Ireland.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/MiamiNice.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Midwest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Minty.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/blue.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/cyan.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/green.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/orange.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/purple.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit/red.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/PurpleRain.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/RoyalPurples.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/SageToLime.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Shrooms.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Tufte.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/WatersEdge.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/themes/Wetland.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/widget/Chart2D.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/widget/Legend.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/charting/widget/Sparkline.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/ArrayList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/BinaryTree.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Dictionary.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Queue.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Set.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/SortedList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/Stack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/collections/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/Colorspace.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/Generator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/Palette.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/color/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/HttpChannels.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/RestChannels.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/callbackPollTransport.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/longPollTransport.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/longPollTransportFormEncoded.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/longPollTransportJsonEncoded.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/timestamp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/cometd/timesync.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/AndOrReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/AndOrWriteStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/AtomReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/ClientFilter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CouchDBRestStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CssClassStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CssRuleStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/CsvStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/FileStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/FlickrRestStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/FlickrStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/GoogleFeedStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/GoogleSearchStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/HtmlStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/HtmlTableStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/JsonRestStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/KeyValueStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/OpmlStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/PersevereStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/PicasaStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/QueryReadStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/S3Store.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/ServiceStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/SnapLogicStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/WikipediaStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/XmlStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/css.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/dom.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/jsonPathStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/restListener.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/s3/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/data/s3/proxy.example-php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/HebrewDate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/IslamicDate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/php.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/date/posix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/Context.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/_HtmlTemplated.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/_Templated.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/data.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/dijit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/contrib/objects.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/ext-dojo/NodeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/dates.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/htmlstrings.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/integers.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/lists.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/logic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/misc.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/filter/strings.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/render/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/date.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/loader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/logic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/loop.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/tag/misc.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/dtl/utils/date.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/TablePlugins.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/UploadImage.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/nls/TableDialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/editorPlugins.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/busy.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/cellpad.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/cellspace.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/tableIcons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images/uploadImageIcon.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/insertTable.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/modifyTable.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/Flash.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/IE/flash.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/Object.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/Quicktime.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/embed/resources/version.mov +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/ascii85.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/base64.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/bits.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/compression/lzw.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/compression/splay.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/crypto/Blowfish.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/crypto/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/digests/MD5.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/digests/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/encoding/easy64.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/DojoExternalInterface.as +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/ExpressInstall.as +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/flash/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/BusyButton.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/CheckedMultiSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/DateTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/DropDownSelect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/DropDownStack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FileInput.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FileInputAuto.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FilePickerTextBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/FileUploader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/MultiComboBox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/RadioStack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/RangeSlider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/Rating.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/TimeSpinner.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/_FormSelectWidget.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/_HasDropDown.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/_SelectStackMixin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ar/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ca/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/cs/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/da/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/de/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/el/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/es/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/fi/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/fr/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/he/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/hu/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/it/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ja/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ko/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/nb/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/nl/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/pl/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/pt-pt/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/pt/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/ru/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/sk/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/sl/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/sv/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/th/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/tr/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/zh-tw/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/nls/zh/PasswordValidator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/BusyButton.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/CheckedMultiSelect.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/CheckedMultiSelect.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/DropDownSelect.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/DropDownSelect.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FileInput.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FileInput.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FileInputAuto.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FilePickerTextBox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/FilePickerTextBox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/HorizontalRangeSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/PasswordValidator.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/RangeSlider.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/Rating.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/RecieveFile.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/UploadFile.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/VerticalRangeSlider.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/_CheckedMultiSelectItem.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/cLOG.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/loading_wheel.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/nihiloFolderSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/rating_empty.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/rating_full.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/soriaFolderSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/images/tundraFolderSprite.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/form/resources/uploader.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/Shadow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/_arg.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/_core.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/easing.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/ext-dojo/NodeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/flip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowB.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowBL.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowBR.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowL.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowR.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowT.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowTL.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/resources/shadowTR.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/scroll.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/split.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/style.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/fx/text.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/Moveable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/Mover.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/VectorText.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/arc.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/canvas.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/canvas_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/decompose.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/fx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/matrix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/move.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/path.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/resources/Gillius.svg +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/resources/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/shape.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/silverlight.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/silverlight_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/svg.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/svg_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/utils.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/vml.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx/vml_attach.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/gradient.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/lighting.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/matrix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/object.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/scheduler.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/gfx3d/vector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/DataGrid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/DataSelection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/Selection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/VirtualGrid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_EditManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Events.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_FocusManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Layout.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_RowManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_RowSelector.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_Scroller.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_View.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_ViewManager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/Grid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/Grid_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/nihiloGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/soriaGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/_grid/tundraGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/cells.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/cells/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/cells/dijit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/Grid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/VirtualGrid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/dijitEditors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/editors.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/fields.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_data/model.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/Grid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/Grid_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/builder.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/cell.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/drag.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/edit.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/focus.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/grid_dx_gradient.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/grid_sort_down.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/grid_sort_up.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/tabEnabled_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images/tabHover_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/layout.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/lib.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/nihiloGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/publicEvents.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/rowbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/rows.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/scroller.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/selection.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/soriaGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/tundraGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/view.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/views.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/resources/GridView.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/resources/VirtualGrid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/databaseModel.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images/closed.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images/flatScreen.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images/open.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/books.xml +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/data.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/geography.xml +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/json.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/movies.csv +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/test_data.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/test_data_objects.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/testtbl.sql +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support/yahoo_search.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_change_structure.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_custom_sort.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_empty.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model_EmptyResultSet.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model_multiStores.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_model_processError.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_dojo_data_notification.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_edit_canEdit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_edit_dijit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_events.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_expand.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_dlg.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_headerHeight.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_layout.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_layout_LayoutContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_layout_borderContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_object_model_change.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_programmatic.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_programmatic_layout.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_rtl.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_themes.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_grid_tooltip_menu.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_keyboard.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_markup.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_mysql_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_sizing.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_sizing_100rows.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_sizing_ResizeHandle.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_styling.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_subgrid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_tundra_edit.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_yahoo_images.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/test_yahoo_search.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/compat/tests/yahooSearch.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/Grid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/Grid_rtl.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/View.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/_Grid.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/grid_dx_gradient.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/grid_sort_down.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/grid_sort_up.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/tabEnabled_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/images/tabHover_rotated.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/nihiloGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/soriaGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/resources/tundraGrid.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/grid/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/help/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/help/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/help/console.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_all.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_dynamic.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_static.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/_www.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/cpp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/css.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/delphi.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/django.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/javascript.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/_html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/_www.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/css.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/javascript.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments/xml.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/python.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/sql.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/languages/xml.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/highlight.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/autumn.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/borland.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/colorful.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/default.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/emacs.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/friendly.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/fruity.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/manni.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/murphy.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/native.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/pastie.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/perldoc.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments/trac.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/metrics.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/html/styles.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Badge.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/FlickrBadge.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Gallery.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Lightbox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/Magnifier.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/MagnifierLite.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/SlideShow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/ThumbnailPicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Badge.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Gallery.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Gallery.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Lightbox.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Lightbox.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/Magnifier.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/SlideShow.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/SlideShow.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/ThumbnailPicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/ThumbnailPicker.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/image.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/buttons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/buttons.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/close.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/close.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/close_dark.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/left.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/left.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/right.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/right.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/image/resources/images/warning.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/httpParse.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/tests/frag.xml +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/tests/xip.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/xip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/xip_client.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/proxy/xip_server.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/scriptFrame.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/windowName.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/xhrMultiPart.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/xhrPlugins.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/io/xhrWindowNamePlugin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/query.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/ref.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/json/schema.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/jsonPath.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/jsonPath/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/jsonPath/query.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/cflow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/counter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/memoizer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/memoizerGuard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/profiler.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/timer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/aspect/tracer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/array.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/binrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/curry.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/fold.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/lambda.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/linrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/listcomp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/multirec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/numrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/object.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/reversed.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/scan.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/sequence.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/tailrec.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/functional/zip.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/mix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/observable.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/lang/utils.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/BorderContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ContentPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/DragPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ExpandoPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/FloatingPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/RadioGroup.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ResizeHandle.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/RotatorContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ScrollPane.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/ToggleSplitter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/dnd/Avatar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/dnd/PlottedDnd.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/nls/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/nls/en/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/nls/fr/GridContainer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/DndGridContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ExpandoPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ExpandoPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/FloatingPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/FloatingPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/GridContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/GridContainer.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/RadioGroup.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ResizeHandle.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/RotatorContainer.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ScrollPane.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ScrollPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/ToggleSplitter.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/grip_bg.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/pixel.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/resize.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/layout/resources/icons/rotator.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/curves.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/math/matrix.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/_common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/docs/bookmarklets.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/files.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/network_check.txt +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/offline.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/checkmark.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/greenball.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/learnhow.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/learnhow.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/offline-widget.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/offline-widget.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/redball.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/resources/roller.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/sync.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/off/ui.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/Show.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/Show.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/Slide.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/down.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/next.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/prev.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/presentation/resources/icons/up.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/README.template +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/_modules.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/explore.php +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/manualTests.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/resources/manualTests.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/robot/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/robot/recorder.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/Client.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/JsonRPC.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/JsonRest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/OfflineRest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/ProxiedPath.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/Rest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/dojo-api.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/geonames.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/google.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/wikipedia.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary/yahoo.smd +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/Service.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/rpc/test.txt +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/DOM.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/capability.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/secure/sandbox.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Anchor.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Annotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/DoubleArrowAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Figure.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/LeadAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/PreexistingAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/SingleArrowAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Slider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/Toolbar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/UnderlineAnnotation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/UndoStack.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/_Plugin.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/resources/images/icons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sketch/resources/sketch.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/sql/_crypto.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/AirDBStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/AirEncryptedLocalStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/AirFileStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/FlashStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/GearsStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/Provider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/Storage.as +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/Storage.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/WhatWGStorageProvider.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/_common.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/buildFlashStorage.sh +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/manager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/storage_dialog.fla +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/storage/storage_dialog.swf +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/BidiComplex.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/Builder.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/sprintf.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/string/tokenize.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/testing/DocTest.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/testing/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/Sequence.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/Streamer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/ThreadPool.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/timing/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/Uuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/generateRandomUuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/uuid/generateTimeBasedUuid.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/ca.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/check.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/creditCard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/isbn.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/regexp.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/us.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/validate/web.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/Calendar.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/Calendar.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/CalendarDay.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/CalendarMonth.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Calendar/CalendarYear.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/CalendarFx.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/ColorPicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/ColorPicker.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/hue.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/hueHandle.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/pickerPointer.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images/underlay.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/Dialog.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/Dialog.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/images/dialogCloseButton.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Dialog/images/dialogCloseButton.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/DocTester.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/DocTester/DocTester.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/DocTester/DocTester.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/FilePicker.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/_FileInfoPane.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images/nihiloFileIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images/soriaFileIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images/tundraFileIcons.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FisheyeList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FisheyeList/FisheyeList.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/FisheyeLite.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Iterator.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Loader.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Loader/Loader.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Loader/icons/loading.gif +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/Pager.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/Pager.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/hNext.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/hPrevious.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/pageActive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/pageInactive.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/vNext.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Pager/images/vPrevious.png +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/PlaceholderMenuItem.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Roller.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/RollingList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/RollingList/RollingList.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/SortList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/SortList/SortList.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/SortList/SortList.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Toaster.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Toaster/Toaster.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Wizard/Wizard.css +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/Wizard/Wizard.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/FilePicker.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/RollingList.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ar/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ca/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/cs/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/da/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/de/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/el/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/es/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/fi/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/fr/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/he/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/hu/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/it/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ja/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ko/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/nb/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/nl/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/pl/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/pt-pt/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/pt/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/ru/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/sk/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/sl/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/sv/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/th/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/tr/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/zh-tw/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/widget/nls/zh/Wizard.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/CompositeWire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/DataWire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/TableAdapter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/TextAdapter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/TreeAdapter.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/Wire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/XmlWire.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/_base.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Action.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Data.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/DataStore.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Invocation.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Service.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/Transfer.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/wire/ml/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/DomParser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/Script.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/parser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xml/widgetParser.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/ChatService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/PresenceService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/README +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/RosterService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/TransportSession.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/UserService.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/sasl.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/util.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/widget/ChatSession.js +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/widget/templates/ChatSession.html +%%DOJO%%%%DATADIR%%/externals/dojo/dojox/xmpp/xmppSession.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build.bat +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build_mini.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build_notice.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/build_release.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cdnBuild.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/changeVersion.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/alias.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/arrayInherit.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/build.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/calendar.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/cldrUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/currency.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/CatalogManager.properties +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/catalog +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/core.zip +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml/ldml.dtd +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/APL-2.0.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/MPL-1.0.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/MPL-1.1.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/ant-apache-bsf.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/bsf.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/js.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/resolver.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib/saxon8.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/number.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/specialLocale.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/cldr/util.xsl +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/clean_release.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/copyright.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/buildUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/buildUtilXd.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/checkBuildSize.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/convertTestsToXDomain.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/dojoGuardEnd.jsfrag +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/dojoGuardStart.jsfrag +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/fileUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/i18nUtil.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/logger.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/Packer.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/Words.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer/base2.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/listProfileDeps.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/makeDojoJsWeb.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/mk_branch.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/base.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/cometd.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/demos-all.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/dtkapi.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/fx.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/layers.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/offline.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/rhino.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/sql.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/standard.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/standardCustomBase.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/profiles/storage.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/conditionalTest.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/conditionalTest.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/foo/page/view.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/profiles/customBase.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/tests/profiles/nestedNls.profile.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild.php +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/builder_ui.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/dojo.js.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps.properties +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Global/download.skin +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Global/global.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Root/main.hac +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/app.properties +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/index.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/makeWebBuildModuleList.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/topIndex.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/webbuild.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/buildscripts/webbuild/webbuild.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/README +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/Robot.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_browserRunner.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_rhinoRunner.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/doh.wav +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/dohaaa.wav +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/_sounds/woohoo.wav +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/DOHRobot.jar +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/DOHRobot.java +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/compilerobot.bat +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/robot/robot.css +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/runner.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/runner.js +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/runner.sh +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/small_logo.png +%%DOJO%%%%DATADIR%%/externals/dojo/util/doh/tests/robot.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/README.txt +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo-war/pom.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java/org/dojotoolkit/DojoFilter.java +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/webapp/WEB-INF/web.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo/pom.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/dojo/src/main/assembly/dojo.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/maven/pom.xml +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/BUILD +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/LICENSE +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/MPL-1.1.html +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/custom_rhino.diff +%%DOJO%%%%DATADIR%%/externals/dojo/util/shrinksafe/custom_rhino.jar +%%INCUBATOR%%%%DATADIR%%/incubator/bin/zf.bat +%%INCUBATOR%%%%DATADIR%%/incubator/bin/zf.php +%%INCUBATOR%%%%DATADIR%%/incubator/bin/zf.sh +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Console/Getopt.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Class.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag/Param.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag/Return.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Extension.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Function.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Method.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Parameter.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Reflection/Property.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Apache/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Body.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Class.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag/Param.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag/Return.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Member/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Member/Container.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Method.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Parameter.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Property.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli/ArgumentParser.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli/Manifest.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Dispatcher.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Request.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Response.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/Chain.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/IncludePathLoader.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/IncludePathLoader/RecursiveFilterIterator.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/ActionMetadata.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/Metadata.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/ProviderMetadata.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Action.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider/Signature.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Action/Create.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Action/Delete.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Manifest.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider/Phpinfo.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider/Providers.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider/Version.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem/Directory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem/File.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Registry.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/INotOverwritable.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ISystem.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ITopLevel.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ProjectDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ProjectProfileFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System/ProjectProvidersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ApisDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ApplicationDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/BootstrapFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/CacheDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ConfigsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ControllerFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ControllersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/DataDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/HtaccessFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LayoutsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LibraryDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LocalesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/LogsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ModelsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ModulesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicImagesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicIndexFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicScriptsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/PublicStylesheetsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/SearchIndexesDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/SessionsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/TemporaryDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/TestsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/UploadsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewControllerScriptsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewFiltersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewHelpersDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewScriptFile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewScriptsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ViewsDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf/ZfStandardLibraryDirectory.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Exception.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/FileParser/Interface.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/FileParser/Xml.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Iterator/EnabledResource.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource/Container.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource/SearchConstraints.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Abstract.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Action.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Controller.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Manifest.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Profile.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/Project.php +%%INCUBATOR%%%%DATADIR%%/incubator/library/Zend/Tool/Project/Provider/View.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/AllTests.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/TestConfiguration.php.dist +%%INCUBATOR%%%%DATADIR%%/incubator/tests/TestHelper.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/ClassTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/Tag/ParamTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/Tag/ReturnTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/TagTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/DocblockTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/ExtensionTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/FileTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/FunctionTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/MethodTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/ParameterTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/PropertyTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Reflection/_files/TestSampleClass.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/ClassTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/FileTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/MethodTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/PropertyTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/_files/TestSampleSingleClass.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/AllTests.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/Context/RegistryTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/ProfileTest.php +%%INCUBATOR%%%%DATADIR%%/incubator/tests/Zend/Tool/Project/_files/.zfproject.xml.orig +%%DATADIR%%/library/Zend/Acl.php +%%DATADIR%%/library/Zend/Acl/Assert/Interface.php +%%DATADIR%%/library/Zend/Acl/Exception.php +%%DATADIR%%/library/Zend/Acl/Resource.php +%%DATADIR%%/library/Zend/Acl/Resource/Interface.php +%%DATADIR%%/library/Zend/Acl/Role.php +%%DATADIR%%/library/Zend/Acl/Role/Interface.php +%%DATADIR%%/library/Zend/Acl/Role/Registry.php +%%DATADIR%%/library/Zend/Acl/Role/Registry/Exception.php +%%DATADIR%%/library/Zend/Amf/Constants.php +%%DATADIR%%/library/Zend/Amf/Exception.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf0/Deserializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf0/Serializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf3/Deserializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Amf3/Serializer.php +%%DATADIR%%/library/Zend/Amf/Parse/Deserializer.php +%%DATADIR%%/library/Zend/Amf/Parse/InputStream.php +%%DATADIR%%/library/Zend/Amf/Parse/OutputStream.php +%%DATADIR%%/library/Zend/Amf/Parse/Serializer.php +%%DATADIR%%/library/Zend/Amf/Parse/TypeLoader.php +%%DATADIR%%/library/Zend/Amf/Request.php +%%DATADIR%%/library/Zend/Amf/Request/Http.php +%%DATADIR%%/library/Zend/Amf/Response.php +%%DATADIR%%/library/Zend/Amf/Response/Http.php +%%DATADIR%%/library/Zend/Amf/Server.php +%%DATADIR%%/library/Zend/Amf/Server/Exception.php +%%DATADIR%%/library/Zend/Amf/Util/BinaryStream.php +%%DATADIR%%/library/Zend/Amf/Value/ByteArray.php +%%DATADIR%%/library/Zend/Amf/Value/MessageBody.php +%%DATADIR%%/library/Zend/Amf/Value/MessageHeader.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/AbstractMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/AcknowledgeMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/AsyncMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/CommandMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/ErrorMessage.php +%%DATADIR%%/library/Zend/Amf/Value/Messaging/RemotingMessage.php +%%DATADIR%%/library/Zend/Amf/Value/TraitsInfo.php +%%DATADIR%%/library/Zend/Auth.php +%%DATADIR%%/library/Zend/Auth/Adapter/DbTable.php +%%DATADIR%%/library/Zend/Auth/Adapter/Digest.php +%%DATADIR%%/library/Zend/Auth/Adapter/Exception.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver/Exception.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver/File.php +%%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver/Interface.php +%%DATADIR%%/library/Zend/Auth/Adapter/InfoCard.php +%%DATADIR%%/library/Zend/Auth/Adapter/Interface.php +%%DATADIR%%/library/Zend/Auth/Adapter/Ldap.php +%%DATADIR%%/library/Zend/Auth/Adapter/OpenId.php +%%DATADIR%%/library/Zend/Auth/Exception.php +%%DATADIR%%/library/Zend/Auth/Result.php +%%DATADIR%%/library/Zend/Auth/Storage/Exception.php +%%DATADIR%%/library/Zend/Auth/Storage/Interface.php +%%DATADIR%%/library/Zend/Auth/Storage/NonPersistent.php +%%DATADIR%%/library/Zend/Auth/Storage/Session.php +%%DATADIR%%/library/Zend/Cache.php +%%DATADIR%%/library/Zend/Cache/Backend.php +%%DATADIR%%/library/Zend/Cache/Backend/Apc.php +%%DATADIR%%/library/Zend/Cache/Backend/ExtendedInterface.php +%%DATADIR%%/library/Zend/Cache/Backend/File.php +%%DATADIR%%/library/Zend/Cache/Backend/Interface.php +%%DATADIR%%/library/Zend/Cache/Backend/Memcached.php +%%DATADIR%%/library/Zend/Cache/Backend/Sqlite.php +%%DATADIR%%/library/Zend/Cache/Backend/Test.php +%%DATADIR%%/library/Zend/Cache/Backend/TwoLevels.php +%%DATADIR%%/library/Zend/Cache/Backend/Xcache.php +%%DATADIR%%/library/Zend/Cache/Backend/ZendPlatform.php +%%DATADIR%%/library/Zend/Cache/Core.php +%%DATADIR%%/library/Zend/Cache/Exception.php +%%DATADIR%%/library/Zend/Cache/Frontend/Class.php +%%DATADIR%%/library/Zend/Cache/Frontend/File.php +%%DATADIR%%/library/Zend/Cache/Frontend/Function.php +%%DATADIR%%/library/Zend/Cache/Frontend/Output.php +%%DATADIR%%/library/Zend/Cache/Frontend/Page.php +%%DATADIR%%/library/Zend/Captcha/Adapter.php +%%DATADIR%%/library/Zend/Captcha/Base.php +%%DATADIR%%/library/Zend/Captcha/Dumb.php +%%DATADIR%%/library/Zend/Captcha/Exception.php +%%DATADIR%%/library/Zend/Captcha/Figlet.php +%%DATADIR%%/library/Zend/Captcha/Image.php +%%DATADIR%%/library/Zend/Captcha/ReCaptcha.php +%%DATADIR%%/library/Zend/Captcha/Word.php +%%DATADIR%%/library/Zend/Config.php +%%DATADIR%%/library/Zend/Config/Exception.php +%%DATADIR%%/library/Zend/Config/Ini.php +%%DATADIR%%/library/Zend/Config/Writer.php +%%DATADIR%%/library/Zend/Config/Writer/Array.php +%%DATADIR%%/library/Zend/Config/Writer/Ini.php +%%DATADIR%%/library/Zend/Config/Writer/Xml.php +%%DATADIR%%/library/Zend/Config/Xml.php +%%DATADIR%%/library/Zend/Console/Getopt.php +%%DATADIR%%/library/Zend/Console/Getopt/Exception.php +%%DATADIR%%/library/Zend/Controller/Action.php +%%DATADIR%%/library/Zend/Controller/Action/Exception.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Abstract.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/ActionStack.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AjaxContext.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AutoComplete/Abstract.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AutoCompleteDojo.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/AutoCompleteScriptaculous.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/ContextSwitch.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/FlashMessenger.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Json.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Redirector.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/Url.php +%%DATADIR%%/library/Zend/Controller/Action/Helper/ViewRenderer.php +%%DATADIR%%/library/Zend/Controller/Action/HelperBroker.php +%%DATADIR%%/library/Zend/Controller/Action/HelperBroker/PriorityStack.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Abstract.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Exception.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Interface.php +%%DATADIR%%/library/Zend/Controller/Dispatcher/Standard.php +%%DATADIR%%/library/Zend/Controller/Exception.php +%%DATADIR%%/library/Zend/Controller/Front.php +%%DATADIR%%/library/Zend/Controller/Plugin/Abstract.php +%%DATADIR%%/library/Zend/Controller/Plugin/ActionStack.php +%%DATADIR%%/library/Zend/Controller/Plugin/Broker.php +%%DATADIR%%/library/Zend/Controller/Plugin/ErrorHandler.php +%%DATADIR%%/library/Zend/Controller/Request/Abstract.php +%%DATADIR%%/library/Zend/Controller/Request/Apache404.php +%%DATADIR%%/library/Zend/Controller/Request/Exception.php +%%DATADIR%%/library/Zend/Controller/Request/Http.php +%%DATADIR%%/library/Zend/Controller/Request/HttpTestCase.php +%%DATADIR%%/library/Zend/Controller/Request/Simple.php +%%DATADIR%%/library/Zend/Controller/Response/Abstract.php +%%DATADIR%%/library/Zend/Controller/Response/Cli.php +%%DATADIR%%/library/Zend/Controller/Response/Exception.php +%%DATADIR%%/library/Zend/Controller/Response/Http.php +%%DATADIR%%/library/Zend/Controller/Response/HttpTestCase.php +%%DATADIR%%/library/Zend/Controller/Router/Abstract.php +%%DATADIR%%/library/Zend/Controller/Router/Exception.php +%%DATADIR%%/library/Zend/Controller/Router/Interface.php +%%DATADIR%%/library/Zend/Controller/Router/Rewrite.php +%%DATADIR%%/library/Zend/Controller/Router/Route.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Abstract.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Chain.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Hostname.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Interface.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Module.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Regex.php +%%DATADIR%%/library/Zend/Controller/Router/Route/Static.php +%%DATADIR%%/library/Zend/Currency.php +%%DATADIR%%/library/Zend/Currency/Exception.php +%%DATADIR%%/library/Zend/Date.php +%%DATADIR%%/library/Zend/Date/Cities.php +%%DATADIR%%/library/Zend/Date/DateObject.php +%%DATADIR%%/library/Zend/Date/Exception.php +%%DATADIR%%/library/Zend/Db.php +%%DATADIR%%/library/Zend/Db/Adapter/Abstract.php +%%DATADIR%%/library/Zend/Db/Adapter/Db2.php +%%DATADIR%%/library/Zend/Db/Adapter/Db2/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Mysqli.php +%%DATADIR%%/library/Zend/Db/Adapter/Mysqli/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Oracle.php +%%DATADIR%%/library/Zend/Db/Adapter/Oracle/Exception.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Abstract.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm/Db2.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm/Ids.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Mssql.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Mysql.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Oci.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Pgsql.php +%%DATADIR%%/library/Zend/Db/Adapter/Pdo/Sqlite.php +%%DATADIR%%/library/Zend/Db/Exception.php +%%DATADIR%%/library/Zend/Db/Expr.php +%%DATADIR%%/library/Zend/Db/Profiler.php +%%DATADIR%%/library/Zend/Db/Profiler/Exception.php +%%DATADIR%%/library/Zend/Db/Profiler/Firebug.php +%%DATADIR%%/library/Zend/Db/Profiler/Query.php +%%DATADIR%%/library/Zend/Db/Select.php +%%DATADIR%%/library/Zend/Db/Select/Exception.php +%%DATADIR%%/library/Zend/Db/Statement.php +%%DATADIR%%/library/Zend/Db/Statement/Db2.php +%%DATADIR%%/library/Zend/Db/Statement/Db2/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Interface.php +%%DATADIR%%/library/Zend/Db/Statement/Mysqli.php +%%DATADIR%%/library/Zend/Db/Statement/Mysqli/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Oracle.php +%%DATADIR%%/library/Zend/Db/Statement/Oracle/Exception.php +%%DATADIR%%/library/Zend/Db/Statement/Pdo.php +%%DATADIR%%/library/Zend/Db/Statement/Pdo/Ibm.php +%%DATADIR%%/library/Zend/Db/Table.php +%%DATADIR%%/library/Zend/Db/Table/Abstract.php +%%DATADIR%%/library/Zend/Db/Table/Exception.php +%%DATADIR%%/library/Zend/Db/Table/Row.php +%%DATADIR%%/library/Zend/Db/Table/Row/Abstract.php +%%DATADIR%%/library/Zend/Db/Table/Row/Exception.php +%%DATADIR%%/library/Zend/Db/Table/Rowset.php +%%DATADIR%%/library/Zend/Db/Table/Rowset/Abstract.php +%%DATADIR%%/library/Zend/Db/Table/Rowset/Exception.php +%%DATADIR%%/library/Zend/Db/Table/Select.php +%%DATADIR%%/library/Zend/Db/Table/Select/Exception.php +%%DATADIR%%/library/Zend/Debug.php +%%DATADIR%%/library/Zend/Dojo.php +%%DATADIR%%/library/Zend/Dojo/Data.php +%%DATADIR%%/library/Zend/Dojo/Exception.php +%%DATADIR%%/library/Zend/Dojo/Form.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/AccordionContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/AccordionPane.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/BorderContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/ContentPane.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/DijitContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/DijitElement.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/DijitForm.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/SplitContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/StackContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/Decorator/TabContainer.php +%%DATADIR%%/library/Zend/Dojo/Form/DisplayGroup.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Button.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/CheckBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/ComboBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/CurrencyTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/DateTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Dijit.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/DijitMulti.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Editor.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/FilteringSelect.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/HorizontalSlider.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/NumberSpinner.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/NumberTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/PasswordTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/RadioButton.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Slider.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/SubmitButton.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/TextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/Textarea.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/TimeTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/ValidationTextBox.php +%%DATADIR%%/library/Zend/Dojo/Form/Element/VerticalSlider.php +%%DATADIR%%/library/Zend/Dojo/Form/SubForm.php +%%DATADIR%%/library/Zend/Dojo/View/Exception.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/AccordionContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/AccordionPane.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/BorderContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Button.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/CheckBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/ComboBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/ContentPane.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/CurrencyTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/DateTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Dijit.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/DijitContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Dojo.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Dojo/Container.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Editor.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/FilteringSelect.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Form.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/HorizontalSlider.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/NumberSpinner.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/NumberTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/PasswordTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/RadioButton.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/SimpleTextarea.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Slider.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/SplitContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/StackContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/SubmitButton.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/TabContainer.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/TextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/Textarea.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/TimeTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/ValidationTextBox.php +%%DATADIR%%/library/Zend/Dojo/View/Helper/VerticalSlider.php +%%DATADIR%%/library/Zend/Dom/Exception.php +%%DATADIR%%/library/Zend/Dom/Query.php +%%DATADIR%%/library/Zend/Dom/Query/Css2Xpath.php +%%DATADIR%%/library/Zend/Dom/Query/Result.php +%%DATADIR%%/library/Zend/Exception.php +%%DATADIR%%/library/Zend/Feed.php +%%DATADIR%%/library/Zend/Feed/Abstract.php +%%DATADIR%%/library/Zend/Feed/Atom.php +%%DATADIR%%/library/Zend/Feed/Builder.php +%%DATADIR%%/library/Zend/Feed/Builder/Entry.php +%%DATADIR%%/library/Zend/Feed/Builder/Exception.php +%%DATADIR%%/library/Zend/Feed/Builder/Header.php +%%DATADIR%%/library/Zend/Feed/Builder/Header/Itunes.php +%%DATADIR%%/library/Zend/Feed/Builder/Interface.php +%%DATADIR%%/library/Zend/Feed/Element.php +%%DATADIR%%/library/Zend/Feed/Entry/Abstract.php +%%DATADIR%%/library/Zend/Feed/Entry/Atom.php +%%DATADIR%%/library/Zend/Feed/Entry/Rss.php +%%DATADIR%%/library/Zend/Feed/Exception.php +%%DATADIR%%/library/Zend/Feed/Rss.php +%%DATADIR%%/library/Zend/File/Transfer.php +%%DATADIR%%/library/Zend/File/Transfer/Adapter/Abstract.php +%%DATADIR%%/library/Zend/File/Transfer/Adapter/Http.php +%%DATADIR%%/library/Zend/File/Transfer/Exception.php +%%DATADIR%%/library/Zend/Filter.php +%%DATADIR%%/library/Zend/Filter/Alnum.php +%%DATADIR%%/library/Zend/Filter/Alpha.php +%%DATADIR%%/library/Zend/Filter/BaseName.php +%%DATADIR%%/library/Zend/Filter/Digits.php +%%DATADIR%%/library/Zend/Filter/Dir.php +%%DATADIR%%/library/Zend/Filter/Exception.php +%%DATADIR%%/library/Zend/Filter/File/LowerCase.php +%%DATADIR%%/library/Zend/Filter/File/Rename.php +%%DATADIR%%/library/Zend/Filter/File/UpperCase.php +%%DATADIR%%/library/Zend/Filter/HtmlEntities.php +%%DATADIR%%/library/Zend/Filter/Inflector.php +%%DATADIR%%/library/Zend/Filter/Input.php +%%DATADIR%%/library/Zend/Filter/Int.php +%%DATADIR%%/library/Zend/Filter/Interface.php +%%DATADIR%%/library/Zend/Filter/PregReplace.php +%%DATADIR%%/library/Zend/Filter/RealPath.php +%%DATADIR%%/library/Zend/Filter/StringToLower.php +%%DATADIR%%/library/Zend/Filter/StringToUpper.php +%%DATADIR%%/library/Zend/Filter/StringTrim.php +%%DATADIR%%/library/Zend/Filter/StripNewlines.php +%%DATADIR%%/library/Zend/Filter/StripTags.php +%%DATADIR%%/library/Zend/Filter/Word/CamelCaseToDash.php +%%DATADIR%%/library/Zend/Filter/Word/CamelCaseToSeparator.php +%%DATADIR%%/library/Zend/Filter/Word/CamelCaseToUnderscore.php +%%DATADIR%%/library/Zend/Filter/Word/DashToCamelCase.php +%%DATADIR%%/library/Zend/Filter/Word/DashToSeparator.php +%%DATADIR%%/library/Zend/Filter/Word/DashToUnderscore.php +%%DATADIR%%/library/Zend/Filter/Word/Separator/Abstract.php +%%DATADIR%%/library/Zend/Filter/Word/SeparatorToCamelCase.php +%%DATADIR%%/library/Zend/Filter/Word/SeparatorToDash.php +%%DATADIR%%/library/Zend/Filter/Word/SeparatorToSeparator.php +%%DATADIR%%/library/Zend/Filter/Word/UnderscoreToCamelCase.php +%%DATADIR%%/library/Zend/Filter/Word/UnderscoreToDash.php +%%DATADIR%%/library/Zend/Filter/Word/UnderscoreToSeparator.php +%%DATADIR%%/library/Zend/Form.php +%%DATADIR%%/library/Zend/Form/Decorator/Abstract.php +%%DATADIR%%/library/Zend/Form/Decorator/Callback.php +%%DATADIR%%/library/Zend/Form/Decorator/Captcha.php +%%DATADIR%%/library/Zend/Form/Decorator/Captcha/Word.php +%%DATADIR%%/library/Zend/Form/Decorator/Description.php +%%DATADIR%%/library/Zend/Form/Decorator/DtDdWrapper.php +%%DATADIR%%/library/Zend/Form/Decorator/Errors.php +%%DATADIR%%/library/Zend/Form/Decorator/Exception.php +%%DATADIR%%/library/Zend/Form/Decorator/Fieldset.php +%%DATADIR%%/library/Zend/Form/Decorator/File.php +%%DATADIR%%/library/Zend/Form/Decorator/Form.php +%%DATADIR%%/library/Zend/Form/Decorator/FormElements.php +%%DATADIR%%/library/Zend/Form/Decorator/FormErrors.php +%%DATADIR%%/library/Zend/Form/Decorator/HtmlTag.php +%%DATADIR%%/library/Zend/Form/Decorator/Image.php +%%DATADIR%%/library/Zend/Form/Decorator/Interface.php +%%DATADIR%%/library/Zend/Form/Decorator/Label.php +%%DATADIR%%/library/Zend/Form/Decorator/PrepareElements.php +%%DATADIR%%/library/Zend/Form/Decorator/ViewHelper.php +%%DATADIR%%/library/Zend/Form/Decorator/ViewScript.php +%%DATADIR%%/library/Zend/Form/DisplayGroup.php +%%DATADIR%%/library/Zend/Form/Element.php +%%DATADIR%%/library/Zend/Form/Element/Button.php +%%DATADIR%%/library/Zend/Form/Element/Captcha.php +%%DATADIR%%/library/Zend/Form/Element/Checkbox.php +%%DATADIR%%/library/Zend/Form/Element/Exception.php +%%DATADIR%%/library/Zend/Form/Element/File.php +%%DATADIR%%/library/Zend/Form/Element/Hash.php +%%DATADIR%%/library/Zend/Form/Element/Hidden.php +%%DATADIR%%/library/Zend/Form/Element/Image.php +%%DATADIR%%/library/Zend/Form/Element/Multi.php +%%DATADIR%%/library/Zend/Form/Element/MultiCheckbox.php +%%DATADIR%%/library/Zend/Form/Element/Multiselect.php +%%DATADIR%%/library/Zend/Form/Element/Password.php +%%DATADIR%%/library/Zend/Form/Element/Radio.php +%%DATADIR%%/library/Zend/Form/Element/Reset.php +%%DATADIR%%/library/Zend/Form/Element/Select.php +%%DATADIR%%/library/Zend/Form/Element/Submit.php +%%DATADIR%%/library/Zend/Form/Element/Text.php +%%DATADIR%%/library/Zend/Form/Element/Textarea.php +%%DATADIR%%/library/Zend/Form/Element/Xhtml.php +%%DATADIR%%/library/Zend/Form/Exception.php +%%DATADIR%%/library/Zend/Form/SubForm.php +%%DATADIR%%/library/Zend/Gdata.php +%%DATADIR%%/library/Zend/Gdata/App.php +%%DATADIR%%/library/Zend/Gdata/App/AuthException.php +%%DATADIR%%/library/Zend/Gdata/App/BadMethodCallException.php +%%DATADIR%%/library/Zend/Gdata/App/Base.php +%%DATADIR%%/library/Zend/Gdata/App/BaseMediaSource.php +%%DATADIR%%/library/Zend/Gdata/App/CaptchaRequiredException.php +%%DATADIR%%/library/Zend/Gdata/App/Entry.php +%%DATADIR%%/library/Zend/Gdata/App/Exception.php +%%DATADIR%%/library/Zend/Gdata/App/Extension.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Author.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Category.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Content.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Contributor.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Control.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Draft.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Element.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Email.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Generator.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Icon.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Id.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Link.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Logo.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Name.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Person.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Published.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Rights.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Source.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Subtitle.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Summary.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Text.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Title.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Updated.php +%%DATADIR%%/library/Zend/Gdata/App/Extension/Uri.php +%%DATADIR%%/library/Zend/Gdata/App/Feed.php +%%DATADIR%%/library/Zend/Gdata/App/FeedEntryParent.php +%%DATADIR%%/library/Zend/Gdata/App/FeedSourceParent.php +%%DATADIR%%/library/Zend/Gdata/App/HttpException.php +%%DATADIR%%/library/Zend/Gdata/App/IOException.php +%%DATADIR%%/library/Zend/Gdata/App/InvalidArgumentException.php +%%DATADIR%%/library/Zend/Gdata/App/LoggingHttpClientAdapterSocket.php +%%DATADIR%%/library/Zend/Gdata/App/MediaEntry.php +%%DATADIR%%/library/Zend/Gdata/App/MediaFileSource.php +%%DATADIR%%/library/Zend/Gdata/App/MediaSource.php +%%DATADIR%%/library/Zend/Gdata/App/Util.php +%%DATADIR%%/library/Zend/Gdata/App/VersionException.php +%%DATADIR%%/library/Zend/Gdata/AuthSub.php +%%DATADIR%%/library/Zend/Gdata/Books.php +%%DATADIR%%/library/Zend/Gdata/Books/CollectionEntry.php +%%DATADIR%%/library/Zend/Gdata/Books/CollectionFeed.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/AnnotationLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/BooksCategory.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/BooksLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/Embeddability.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/InfoLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/PreviewLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/Review.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/ThumbnailLink.php +%%DATADIR%%/library/Zend/Gdata/Books/Extension/Viewability.php +%%DATADIR%%/library/Zend/Gdata/Books/VolumeEntry.php +%%DATADIR%%/library/Zend/Gdata/Books/VolumeFeed.php +%%DATADIR%%/library/Zend/Gdata/Books/VolumeQuery.php +%%DATADIR%%/library/Zend/Gdata/Calendar.php +%%DATADIR%%/library/Zend/Gdata/Calendar/EventEntry.php +%%DATADIR%%/library/Zend/Gdata/Calendar/EventFeed.php +%%DATADIR%%/library/Zend/Gdata/Calendar/EventQuery.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/AccessLevel.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Color.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Hidden.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Link.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/QuickAdd.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Selected.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/SendEventNotifications.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/Timezone.php +%%DATADIR%%/library/Zend/Gdata/Calendar/Extension/WebContent.php +%%DATADIR%%/library/Zend/Gdata/Calendar/ListEntry.php +%%DATADIR%%/library/Zend/Gdata/Calendar/ListFeed.php +%%DATADIR%%/library/Zend/Gdata/ClientLogin.php +%%DATADIR%%/library/Zend/Gdata/Docs.php +%%DATADIR%%/library/Zend/Gdata/Docs/DocumentListEntry.php +%%DATADIR%%/library/Zend/Gdata/Docs/DocumentListFeed.php +%%DATADIR%%/library/Zend/Gdata/Docs/Query.php +%%DATADIR%%/library/Zend/Gdata/DublinCore.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Creator.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Date.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Description.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Format.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Identifier.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Language.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Publisher.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Rights.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Subject.php +%%DATADIR%%/library/Zend/Gdata/DublinCore/Extension/Title.php +%%DATADIR%%/library/Zend/Gdata/Entry.php +%%DATADIR%%/library/Zend/Gdata/Exif.php +%%DATADIR%%/library/Zend/Gdata/Exif/Entry.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Distance.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Exposure.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/FStop.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Flash.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/FocalLength.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/ImageUniqueId.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Iso.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Make.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Model.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Tags.php +%%DATADIR%%/library/Zend/Gdata/Exif/Extension/Time.php +%%DATADIR%%/library/Zend/Gdata/Exif/Feed.php +%%DATADIR%%/library/Zend/Gdata/Extension.php +%%DATADIR%%/library/Zend/Gdata/Extension/AttendeeStatus.php +%%DATADIR%%/library/Zend/Gdata/Extension/AttendeeType.php +%%DATADIR%%/library/Zend/Gdata/Extension/Comments.php +%%DATADIR%%/library/Zend/Gdata/Extension/EntryLink.php +%%DATADIR%%/library/Zend/Gdata/Extension/EventStatus.php +%%DATADIR%%/library/Zend/Gdata/Extension/ExtendedProperty.php +%%DATADIR%%/library/Zend/Gdata/Extension/FeedLink.php +%%DATADIR%%/library/Zend/Gdata/Extension/OpenSearchItemsPerPage.php +%%DATADIR%%/library/Zend/Gdata/Extension/OpenSearchStartIndex.php +%%DATADIR%%/library/Zend/Gdata/Extension/OpenSearchTotalResults.php +%%DATADIR%%/library/Zend/Gdata/Extension/OriginalEvent.php +%%DATADIR%%/library/Zend/Gdata/Extension/Rating.php +%%DATADIR%%/library/Zend/Gdata/Extension/Recurrence.php +%%DATADIR%%/library/Zend/Gdata/Extension/RecurrenceException.php +%%DATADIR%%/library/Zend/Gdata/Extension/Reminder.php +%%DATADIR%%/library/Zend/Gdata/Extension/Transparency.php +%%DATADIR%%/library/Zend/Gdata/Extension/Visibility.php +%%DATADIR%%/library/Zend/Gdata/Extension/When.php +%%DATADIR%%/library/Zend/Gdata/Extension/Where.php +%%DATADIR%%/library/Zend/Gdata/Extension/Who.php +%%DATADIR%%/library/Zend/Gdata/Feed.php +%%DATADIR%%/library/Zend/Gdata/Gapps.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListQuery.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListRecipientEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListRecipientFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/EmailListRecipientQuery.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Error.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/EmailList.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Login.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Name.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Nickname.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Extension/Quota.php +%%DATADIR%%/library/Zend/Gdata/Gapps/NicknameEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/NicknameFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/NicknameQuery.php +%%DATADIR%%/library/Zend/Gdata/Gapps/Query.php +%%DATADIR%%/library/Zend/Gdata/Gapps/ServiceException.php +%%DATADIR%%/library/Zend/Gdata/Gapps/UserEntry.php +%%DATADIR%%/library/Zend/Gdata/Gapps/UserFeed.php +%%DATADIR%%/library/Zend/Gdata/Gapps/UserQuery.php +%%DATADIR%%/library/Zend/Gdata/Gbase.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Entry.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Extension/BaseAttribute.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Feed.php +%%DATADIR%%/library/Zend/Gdata/Gbase/ItemEntry.php +%%DATADIR%%/library/Zend/Gdata/Gbase/ItemFeed.php +%%DATADIR%%/library/Zend/Gdata/Gbase/ItemQuery.php +%%DATADIR%%/library/Zend/Gdata/Gbase/Query.php +%%DATADIR%%/library/Zend/Gdata/Gbase/SnippetEntry.php +%%DATADIR%%/library/Zend/Gdata/Gbase/SnippetFeed.php +%%DATADIR%%/library/Zend/Gdata/Gbase/SnippetQuery.php +%%DATADIR%%/library/Zend/Gdata/Geo.php +%%DATADIR%%/library/Zend/Gdata/Geo/Entry.php +%%DATADIR%%/library/Zend/Gdata/Geo/Extension/GeoRssWhere.php +%%DATADIR%%/library/Zend/Gdata/Geo/Extension/GmlPoint.php +%%DATADIR%%/library/Zend/Gdata/Geo/Extension/GmlPos.php +%%DATADIR%%/library/Zend/Gdata/Geo/Feed.php +%%DATADIR%%/library/Zend/Gdata/Health.php +%%DATADIR%%/library/Zend/Gdata/Health/Extension/Ccr.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileEntry.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileFeed.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileListEntry.php +%%DATADIR%%/library/Zend/Gdata/Health/ProfileListFeed.php +%%DATADIR%%/library/Zend/Gdata/Health/Query.php +%%DATADIR%%/library/Zend/Gdata/HttpClient.php +%%DATADIR%%/library/Zend/Gdata/Kind/EventEntry.php +%%DATADIR%%/library/Zend/Gdata/Media.php +%%DATADIR%%/library/Zend/Gdata/Media/Entry.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaCategory.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaContent.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaCopyright.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaCredit.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaDescription.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaGroup.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaHash.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaKeywords.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaPlayer.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaRating.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaRestriction.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaText.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaThumbnail.php +%%DATADIR%%/library/Zend/Gdata/Media/Extension/MediaTitle.php +%%DATADIR%%/library/Zend/Gdata/Media/Feed.php +%%DATADIR%%/library/Zend/Gdata/Photos.php +%%DATADIR%%/library/Zend/Gdata/Photos/AlbumEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/AlbumFeed.php +%%DATADIR%%/library/Zend/Gdata/Photos/AlbumQuery.php +%%DATADIR%%/library/Zend/Gdata/Photos/CommentEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Access.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/AlbumId.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/BytesUsed.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Checksum.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Client.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/CommentCount.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/CommentingEnabled.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Height.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Id.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Location.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/MaxPhotosPerAlbum.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Name.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Nickname.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/NumPhotos.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/NumPhotosRemaining.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/PhotoId.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Position.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/QuotaCurrent.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/QuotaLimit.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Rotation.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Size.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Thumbnail.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Timestamp.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/User.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Version.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Weight.php +%%DATADIR%%/library/Zend/Gdata/Photos/Extension/Width.php +%%DATADIR%%/library/Zend/Gdata/Photos/PhotoEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/PhotoFeed.php +%%DATADIR%%/library/Zend/Gdata/Photos/PhotoQuery.php +%%DATADIR%%/library/Zend/Gdata/Photos/TagEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/UserEntry.php +%%DATADIR%%/library/Zend/Gdata/Photos/UserFeed.php +%%DATADIR%%/library/Zend/Gdata/Photos/UserQuery.php +%%DATADIR%%/library/Zend/Gdata/Query.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/CellEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/CellFeed.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/CellQuery.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/DocumentQuery.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/Cell.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/ColCount.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/Custom.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension/RowCount.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/ListEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/ListFeed.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/ListQuery.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/SpreadsheetEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/SpreadsheetFeed.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/WorksheetEntry.php +%%DATADIR%%/library/Zend/Gdata/Spreadsheets/WorksheetFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube.php +%%DATADIR%%/library/Zend/Gdata/YouTube/CommentEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/CommentFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/ContactEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/ContactFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/AboutMe.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Age.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Books.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Company.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Control.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/CountHint.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Description.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Duration.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/FirstName.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Gender.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Hobbies.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Hometown.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/LastName.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Link.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Location.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaContent.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaCredit.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaGroup.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/MediaRating.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Movies.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Music.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/NoEmbed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Occupation.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/PlaylistId.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/PlaylistTitle.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Position.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Private.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/QueryString.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Racy.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Recorded.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Relationship.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/ReleaseDate.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/School.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/State.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Statistics.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Status.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Token.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Uploaded.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/Username.php +%%DATADIR%%/library/Zend/Gdata/YouTube/Extension/VideoId.php +%%DATADIR%%/library/Zend/Gdata/YouTube/MediaEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistListEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistListFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistVideoEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/PlaylistVideoFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/SubscriptionEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/SubscriptionFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/UserProfileEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/VideoEntry.php +%%DATADIR%%/library/Zend/Gdata/YouTube/VideoFeed.php +%%DATADIR%%/library/Zend/Gdata/YouTube/VideoQuery.php +%%DATADIR%%/library/Zend/Http/Client.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Exception.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Interface.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Proxy.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Socket.php +%%DATADIR%%/library/Zend/Http/Client/Adapter/Test.php +%%DATADIR%%/library/Zend/Http/Client/Exception.php +%%DATADIR%%/library/Zend/Http/Cookie.php +%%DATADIR%%/library/Zend/Http/CookieJar.php +%%DATADIR%%/library/Zend/Http/Exception.php +%%DATADIR%%/library/Zend/Http/Response.php +%%DATADIR%%/library/Zend/InfoCard.php +%%DATADIR%%/library/Zend/InfoCard/Adapter/Default.php +%%DATADIR%%/library/Zend/InfoCard/Adapter/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Adapter/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Adapter/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Adapter/Rsa.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Rsa/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter/Aes128cbc.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter/Aes256cbc.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes128cbc/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes256cbc/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Claims.php +%%DATADIR%%/library/Zend/InfoCard/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Assertion.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Assertion/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Assertion/Saml.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Element.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Element/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData/XmlEnc.php +%%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedKey.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/Abstract.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/Default.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo/XmlDSig.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/EnvelopedSignature.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/Exception.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/Interface.php +%%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform/XmlExcC14N.php +%%DATADIR%%/library/Zend/InfoCard/Xml/SecurityTokenReference.php +%%DATADIR%%/library/Zend/Json.php +%%DATADIR%%/library/Zend/Json/Decoder.php +%%DATADIR%%/library/Zend/Json/Encoder.php +%%DATADIR%%/library/Zend/Json/Exception.php +%%DATADIR%%/library/Zend/Json/Server.php +%%DATADIR%%/library/Zend/Json/Server/Cache.php +%%DATADIR%%/library/Zend/Json/Server/Error.php +%%DATADIR%%/library/Zend/Json/Server/Exception.php +%%DATADIR%%/library/Zend/Json/Server/Request.php +%%DATADIR%%/library/Zend/Json/Server/Request/Http.php +%%DATADIR%%/library/Zend/Json/Server/Response.php +%%DATADIR%%/library/Zend/Json/Server/Response/Http.php +%%DATADIR%%/library/Zend/Json/Server/Smd.php +%%DATADIR%%/library/Zend/Json/Server/Smd/Service.php +%%DATADIR%%/library/Zend/Layout.php +%%DATADIR%%/library/Zend/Layout/Controller/Action/Helper/Layout.php +%%DATADIR%%/library/Zend/Layout/Controller/Plugin/Layout.php +%%DATADIR%%/library/Zend/Layout/Exception.php +%%DATADIR%%/library/Zend/Ldap.php +%%DATADIR%%/library/Zend/Ldap/Exception.php +%%DATADIR%%/library/Zend/Loader.php +%%DATADIR%%/library/Zend/Loader/Exception.php +%%DATADIR%%/library/Zend/Loader/PluginLoader.php +%%DATADIR%%/library/Zend/Loader/PluginLoader/Exception.php +%%DATADIR%%/library/Zend/Loader/PluginLoader/Interface.php +%%DATADIR%%/library/Zend/Locale.php +%%DATADIR%%/library/Zend/Locale/Data.php +%%DATADIR%%/library/Zend/Locale/Data/Translation.php +%%DATADIR%%/library/Zend/Locale/Data/aa.xml +%%DATADIR%%/library/Zend/Locale/Data/aa_DJ.xml +%%DATADIR%%/library/Zend/Locale/Data/aa_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/aa_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/af.xml +%%DATADIR%%/library/Zend/Locale/Data/af_NA.xml +%%DATADIR%%/library/Zend/Locale/Data/af_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/ak.xml +%%DATADIR%%/library/Zend/Locale/Data/ak_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/am.xml +%%DATADIR%%/library/Zend/Locale/Data/am_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/ar.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_AE.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_BH.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_DZ.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_EG.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_IQ.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_JO.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_KW.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_LB.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_LY.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_MA.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_OM.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_QA.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_SA.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_SD.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_SY.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_TN.xml +%%DATADIR%%/library/Zend/Locale/Data/ar_YE.xml +%%DATADIR%%/library/Zend/Locale/Data/as.xml +%%DATADIR%%/library/Zend/Locale/Data/as_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/az.xml +%%DATADIR%%/library/Zend/Locale/Data/az_AZ.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Cyrl_AZ.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/az_Latn_AZ.xml +%%DATADIR%%/library/Zend/Locale/Data/be.xml +%%DATADIR%%/library/Zend/Locale/Data/be_BY.xml +%%DATADIR%%/library/Zend/Locale/Data/bg.xml +%%DATADIR%%/library/Zend/Locale/Data/bg_BG.xml +%%DATADIR%%/library/Zend/Locale/Data/bn.xml +%%DATADIR%%/library/Zend/Locale/Data/bn_BD.xml +%%DATADIR%%/library/Zend/Locale/Data/bn_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/bs.xml +%%DATADIR%%/library/Zend/Locale/Data/bs_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/byn.xml +%%DATADIR%%/library/Zend/Locale/Data/byn_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/ca.xml +%%DATADIR%%/library/Zend/Locale/Data/ca_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/cch.xml +%%DATADIR%%/library/Zend/Locale/Data/cch_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/characters.xml +%%DATADIR%%/library/Zend/Locale/Data/cop.xml +%%DATADIR%%/library/Zend/Locale/Data/cs.xml +%%DATADIR%%/library/Zend/Locale/Data/cs_CZ.xml +%%DATADIR%%/library/Zend/Locale/Data/cy.xml +%%DATADIR%%/library/Zend/Locale/Data/cy_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/da.xml +%%DATADIR%%/library/Zend/Locale/Data/da_DK.xml +%%DATADIR%%/library/Zend/Locale/Data/de.xml +%%DATADIR%%/library/Zend/Locale/Data/de_AT.xml +%%DATADIR%%/library/Zend/Locale/Data/de_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/de_CH.xml +%%DATADIR%%/library/Zend/Locale/Data/de_DE.xml +%%DATADIR%%/library/Zend/Locale/Data/de_LI.xml +%%DATADIR%%/library/Zend/Locale/Data/de_LU.xml +%%DATADIR%%/library/Zend/Locale/Data/dv.xml +%%DATADIR%%/library/Zend/Locale/Data/dv_MV.xml +%%DATADIR%%/library/Zend/Locale/Data/dz.xml +%%DATADIR%%/library/Zend/Locale/Data/dz_BT.xml +%%DATADIR%%/library/Zend/Locale/Data/ee.xml +%%DATADIR%%/library/Zend/Locale/Data/ee_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/ee_TG.xml +%%DATADIR%%/library/Zend/Locale/Data/el.xml +%%DATADIR%%/library/Zend/Locale/Data/el_CY.xml +%%DATADIR%%/library/Zend/Locale/Data/el_GR.xml +%%DATADIR%%/library/Zend/Locale/Data/el_POLYTON.xml +%%DATADIR%%/library/Zend/Locale/Data/en.xml +%%DATADIR%%/library/Zend/Locale/Data/en_AS.xml +%%DATADIR%%/library/Zend/Locale/Data/en_AU.xml +%%DATADIR%%/library/Zend/Locale/Data/en_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/en_BW.xml +%%DATADIR%%/library/Zend/Locale/Data/en_BZ.xml +%%DATADIR%%/library/Zend/Locale/Data/en_CA.xml +%%DATADIR%%/library/Zend/Locale/Data/en_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/en_GU.xml +%%DATADIR%%/library/Zend/Locale/Data/en_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/en_IE.xml +%%DATADIR%%/library/Zend/Locale/Data/en_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/en_JM.xml +%%DATADIR%%/library/Zend/Locale/Data/en_MH.xml +%%DATADIR%%/library/Zend/Locale/Data/en_MP.xml +%%DATADIR%%/library/Zend/Locale/Data/en_MT.xml +%%DATADIR%%/library/Zend/Locale/Data/en_NA.xml +%%DATADIR%%/library/Zend/Locale/Data/en_NZ.xml +%%DATADIR%%/library/Zend/Locale/Data/en_PH.xml +%%DATADIR%%/library/Zend/Locale/Data/en_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/en_SG.xml +%%DATADIR%%/library/Zend/Locale/Data/en_Shaw.xml +%%DATADIR%%/library/Zend/Locale/Data/en_TT.xml +%%DATADIR%%/library/Zend/Locale/Data/en_UM.xml +%%DATADIR%%/library/Zend/Locale/Data/en_US.xml +%%DATADIR%%/library/Zend/Locale/Data/en_US_POSIX.xml +%%DATADIR%%/library/Zend/Locale/Data/en_VI.xml +%%DATADIR%%/library/Zend/Locale/Data/en_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/en_ZW.xml +%%DATADIR%%/library/Zend/Locale/Data/eo.xml +%%DATADIR%%/library/Zend/Locale/Data/es.xml +%%DATADIR%%/library/Zend/Locale/Data/es_AR.xml +%%DATADIR%%/library/Zend/Locale/Data/es_BO.xml +%%DATADIR%%/library/Zend/Locale/Data/es_CL.xml +%%DATADIR%%/library/Zend/Locale/Data/es_CO.xml +%%DATADIR%%/library/Zend/Locale/Data/es_CR.xml +%%DATADIR%%/library/Zend/Locale/Data/es_DO.xml +%%DATADIR%%/library/Zend/Locale/Data/es_EC.xml +%%DATADIR%%/library/Zend/Locale/Data/es_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/es_GT.xml +%%DATADIR%%/library/Zend/Locale/Data/es_HN.xml +%%DATADIR%%/library/Zend/Locale/Data/es_MX.xml +%%DATADIR%%/library/Zend/Locale/Data/es_NI.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PA.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PE.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PR.xml +%%DATADIR%%/library/Zend/Locale/Data/es_PY.xml +%%DATADIR%%/library/Zend/Locale/Data/es_SV.xml +%%DATADIR%%/library/Zend/Locale/Data/es_US.xml +%%DATADIR%%/library/Zend/Locale/Data/es_UY.xml +%%DATADIR%%/library/Zend/Locale/Data/es_VE.xml +%%DATADIR%%/library/Zend/Locale/Data/et.xml +%%DATADIR%%/library/Zend/Locale/Data/et_EE.xml +%%DATADIR%%/library/Zend/Locale/Data/eu.xml +%%DATADIR%%/library/Zend/Locale/Data/eu_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/fa.xml +%%DATADIR%%/library/Zend/Locale/Data/fa_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/fa_IR.xml +%%DATADIR%%/library/Zend/Locale/Data/fi.xml +%%DATADIR%%/library/Zend/Locale/Data/fi_FI.xml +%%DATADIR%%/library/Zend/Locale/Data/fil.xml +%%DATADIR%%/library/Zend/Locale/Data/fil_PH.xml +%%DATADIR%%/library/Zend/Locale/Data/fo.xml +%%DATADIR%%/library/Zend/Locale/Data/fo_FO.xml +%%DATADIR%%/library/Zend/Locale/Data/fr.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_CA.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_CH.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_FR.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_LU.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_MC.xml +%%DATADIR%%/library/Zend/Locale/Data/fr_SN.xml +%%DATADIR%%/library/Zend/Locale/Data/fur.xml +%%DATADIR%%/library/Zend/Locale/Data/fur_IT.xml +%%DATADIR%%/library/Zend/Locale/Data/ga.xml +%%DATADIR%%/library/Zend/Locale/Data/ga_IE.xml +%%DATADIR%%/library/Zend/Locale/Data/gaa.xml +%%DATADIR%%/library/Zend/Locale/Data/gaa_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/gez.xml +%%DATADIR%%/library/Zend/Locale/Data/gez_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/gez_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/gl.xml +%%DATADIR%%/library/Zend/Locale/Data/gl_ES.xml +%%DATADIR%%/library/Zend/Locale/Data/gu.xml +%%DATADIR%%/library/Zend/Locale/Data/gu_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/gv.xml +%%DATADIR%%/library/Zend/Locale/Data/gv_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/ha.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Arab_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Arab_SD.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn_GH.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn_NE.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_Latn_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_NE.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ha_SD.xml +%%DATADIR%%/library/Zend/Locale/Data/haw.xml +%%DATADIR%%/library/Zend/Locale/Data/haw_US.xml +%%DATADIR%%/library/Zend/Locale/Data/he.xml +%%DATADIR%%/library/Zend/Locale/Data/he_IL.xml +%%DATADIR%%/library/Zend/Locale/Data/hi.xml +%%DATADIR%%/library/Zend/Locale/Data/hi_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/hr.xml +%%DATADIR%%/library/Zend/Locale/Data/hr_HR.xml +%%DATADIR%%/library/Zend/Locale/Data/hu.xml +%%DATADIR%%/library/Zend/Locale/Data/hu_HU.xml +%%DATADIR%%/library/Zend/Locale/Data/hy.xml +%%DATADIR%%/library/Zend/Locale/Data/hy_AM.xml +%%DATADIR%%/library/Zend/Locale/Data/hy_AM_REVISED.xml +%%DATADIR%%/library/Zend/Locale/Data/ia.xml +%%DATADIR%%/library/Zend/Locale/Data/id.xml +%%DATADIR%%/library/Zend/Locale/Data/id_ID.xml +%%DATADIR%%/library/Zend/Locale/Data/ig.xml +%%DATADIR%%/library/Zend/Locale/Data/ig_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/ii.xml +%%DATADIR%%/library/Zend/Locale/Data/ii_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/in.xml +%%DATADIR%%/library/Zend/Locale/Data/is.xml +%%DATADIR%%/library/Zend/Locale/Data/is_IS.xml +%%DATADIR%%/library/Zend/Locale/Data/it.xml +%%DATADIR%%/library/Zend/Locale/Data/it_CH.xml +%%DATADIR%%/library/Zend/Locale/Data/it_IT.xml +%%DATADIR%%/library/Zend/Locale/Data/iu.xml +%%DATADIR%%/library/Zend/Locale/Data/iw.xml +%%DATADIR%%/library/Zend/Locale/Data/ja.xml +%%DATADIR%%/library/Zend/Locale/Data/ja_JP.xml +%%DATADIR%%/library/Zend/Locale/Data/ka.xml +%%DATADIR%%/library/Zend/Locale/Data/ka_GE.xml +%%DATADIR%%/library/Zend/Locale/Data/kaj.xml +%%DATADIR%%/library/Zend/Locale/Data/kaj_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/kam.xml +%%DATADIR%%/library/Zend/Locale/Data/kam_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/kcg.xml +%%DATADIR%%/library/Zend/Locale/Data/kcg_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/kfo.xml +%%DATADIR%%/library/Zend/Locale/Data/kfo_CI.xml +%%DATADIR%%/library/Zend/Locale/Data/kk.xml +%%DATADIR%%/library/Zend/Locale/Data/kk_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/kk_Cyrl_KZ.xml +%%DATADIR%%/library/Zend/Locale/Data/kk_KZ.xml +%%DATADIR%%/library/Zend/Locale/Data/kl.xml +%%DATADIR%%/library/Zend/Locale/Data/kl_GL.xml +%%DATADIR%%/library/Zend/Locale/Data/km.xml +%%DATADIR%%/library/Zend/Locale/Data/km_KH.xml +%%DATADIR%%/library/Zend/Locale/Data/kn.xml +%%DATADIR%%/library/Zend/Locale/Data/kn_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ko.xml +%%DATADIR%%/library/Zend/Locale/Data/ko_KR.xml +%%DATADIR%%/library/Zend/Locale/Data/kok.xml +%%DATADIR%%/library/Zend/Locale/Data/kok_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/kpe.xml +%%DATADIR%%/library/Zend/Locale/Data/kpe_GN.xml +%%DATADIR%%/library/Zend/Locale/Data/kpe_LR.xml +%%DATADIR%%/library/Zend/Locale/Data/ku.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_Latn_TR.xml +%%DATADIR%%/library/Zend/Locale/Data/ku_TR.xml +%%DATADIR%%/library/Zend/Locale/Data/kw.xml +%%DATADIR%%/library/Zend/Locale/Data/kw_GB.xml +%%DATADIR%%/library/Zend/Locale/Data/ky.xml +%%DATADIR%%/library/Zend/Locale/Data/ky_KG.xml +%%DATADIR%%/library/Zend/Locale/Data/ln.xml +%%DATADIR%%/library/Zend/Locale/Data/ln_CD.xml +%%DATADIR%%/library/Zend/Locale/Data/ln_CG.xml +%%DATADIR%%/library/Zend/Locale/Data/lo.xml +%%DATADIR%%/library/Zend/Locale/Data/lo_LA.xml +%%DATADIR%%/library/Zend/Locale/Data/lt.xml +%%DATADIR%%/library/Zend/Locale/Data/lt_LT.xml +%%DATADIR%%/library/Zend/Locale/Data/lv.xml +%%DATADIR%%/library/Zend/Locale/Data/lv_LV.xml +%%DATADIR%%/library/Zend/Locale/Data/mk.xml +%%DATADIR%%/library/Zend/Locale/Data/mk_MK.xml +%%DATADIR%%/library/Zend/Locale/Data/ml.xml +%%DATADIR%%/library/Zend/Locale/Data/ml_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Cyrl_MN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_MN.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Mong.xml +%%DATADIR%%/library/Zend/Locale/Data/mn_Mong_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/mo.xml +%%DATADIR%%/library/Zend/Locale/Data/mr.xml +%%DATADIR%%/library/Zend/Locale/Data/mr_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ms.xml +%%DATADIR%%/library/Zend/Locale/Data/ms_BN.xml +%%DATADIR%%/library/Zend/Locale/Data/ms_MY.xml +%%DATADIR%%/library/Zend/Locale/Data/mt.xml +%%DATADIR%%/library/Zend/Locale/Data/mt_MT.xml +%%DATADIR%%/library/Zend/Locale/Data/my.xml +%%DATADIR%%/library/Zend/Locale/Data/my_MM.xml +%%DATADIR%%/library/Zend/Locale/Data/nb.xml +%%DATADIR%%/library/Zend/Locale/Data/nb_NO.xml +%%DATADIR%%/library/Zend/Locale/Data/ne.xml +%%DATADIR%%/library/Zend/Locale/Data/ne_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ne_NP.xml +%%DATADIR%%/library/Zend/Locale/Data/nl.xml +%%DATADIR%%/library/Zend/Locale/Data/nl_BE.xml +%%DATADIR%%/library/Zend/Locale/Data/nl_NL.xml +%%DATADIR%%/library/Zend/Locale/Data/nn.xml +%%DATADIR%%/library/Zend/Locale/Data/nn_NO.xml +%%DATADIR%%/library/Zend/Locale/Data/no.xml +%%DATADIR%%/library/Zend/Locale/Data/nr.xml +%%DATADIR%%/library/Zend/Locale/Data/nr_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/nso.xml +%%DATADIR%%/library/Zend/Locale/Data/nso_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/ny.xml +%%DATADIR%%/library/Zend/Locale/Data/ny_MW.xml +%%DATADIR%%/library/Zend/Locale/Data/om.xml +%%DATADIR%%/library/Zend/Locale/Data/om_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/om_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/or.xml +%%DATADIR%%/library/Zend/Locale/Data/or_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/pa.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Arab_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Guru.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_Guru_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/pa_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/pl.xml +%%DATADIR%%/library/Zend/Locale/Data/pl_PL.xml +%%DATADIR%%/library/Zend/Locale/Data/plurals.xml +%%DATADIR%%/library/Zend/Locale/Data/ps.xml +%%DATADIR%%/library/Zend/Locale/Data/ps_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/pt.xml +%%DATADIR%%/library/Zend/Locale/Data/pt_BR.xml +%%DATADIR%%/library/Zend/Locale/Data/pt_PT.xml +%%DATADIR%%/library/Zend/Locale/Data/ro.xml +%%DATADIR%%/library/Zend/Locale/Data/ro_MD.xml +%%DATADIR%%/library/Zend/Locale/Data/ro_RO.xml +%%DATADIR%%/library/Zend/Locale/Data/root.xml +%%DATADIR%%/library/Zend/Locale/Data/ru.xml +%%DATADIR%%/library/Zend/Locale/Data/ru_RU.xml +%%DATADIR%%/library/Zend/Locale/Data/ru_UA.xml +%%DATADIR%%/library/Zend/Locale/Data/rw.xml +%%DATADIR%%/library/Zend/Locale/Data/rw_RW.xml +%%DATADIR%%/library/Zend/Locale/Data/sa.xml +%%DATADIR%%/library/Zend/Locale/Data/sa_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/se.xml +%%DATADIR%%/library/Zend/Locale/Data/se_FI.xml +%%DATADIR%%/library/Zend/Locale/Data/se_NO.xml +%%DATADIR%%/library/Zend/Locale/Data/sh.xml +%%DATADIR%%/library/Zend/Locale/Data/sh_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sh_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sh_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/si.xml +%%DATADIR%%/library/Zend/Locale/Data/si_LK.xml +%%DATADIR%%/library/Zend/Locale/Data/sid.xml +%%DATADIR%%/library/Zend/Locale/Data/sid_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/sk.xml +%%DATADIR%%/library/Zend/Locale/Data/sk_SK.xml +%%DATADIR%%/library/Zend/Locale/Data/sl.xml +%%DATADIR%%/library/Zend/Locale/Data/sl_SI.xml +%%DATADIR%%/library/Zend/Locale/Data/so.xml +%%DATADIR%%/library/Zend/Locale/Data/so_DJ.xml +%%DATADIR%%/library/Zend/Locale/Data/so_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/so_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/so_SO.xml +%%DATADIR%%/library/Zend/Locale/Data/sq.xml +%%DATADIR%%/library/Zend/Locale/Data/sq_AL.xml +%%DATADIR%%/library/Zend/Locale/Data/sr.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_ME.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_RS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Cyrl_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_BA.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_CS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_ME.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_RS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_Latn_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_ME.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_RS.xml +%%DATADIR%%/library/Zend/Locale/Data/sr_YU.xml +%%DATADIR%%/library/Zend/Locale/Data/ss.xml +%%DATADIR%%/library/Zend/Locale/Data/ss_SZ.xml +%%DATADIR%%/library/Zend/Locale/Data/ss_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/st.xml +%%DATADIR%%/library/Zend/Locale/Data/st_LS.xml +%%DATADIR%%/library/Zend/Locale/Data/st_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/supplementalData.xml +%%DATADIR%%/library/Zend/Locale/Data/sv.xml +%%DATADIR%%/library/Zend/Locale/Data/sv_FI.xml +%%DATADIR%%/library/Zend/Locale/Data/sv_SE.xml +%%DATADIR%%/library/Zend/Locale/Data/sw.xml +%%DATADIR%%/library/Zend/Locale/Data/sw_KE.xml +%%DATADIR%%/library/Zend/Locale/Data/sw_TZ.xml +%%DATADIR%%/library/Zend/Locale/Data/syr.xml +%%DATADIR%%/library/Zend/Locale/Data/syr_SY.xml +%%DATADIR%%/library/Zend/Locale/Data/ta.xml +%%DATADIR%%/library/Zend/Locale/Data/ta_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/te.xml +%%DATADIR%%/library/Zend/Locale/Data/te_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/telephoneCodeData.xml +%%DATADIR%%/library/Zend/Locale/Data/tg.xml +%%DATADIR%%/library/Zend/Locale/Data/tg_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/tg_Cyrl_TJ.xml +%%DATADIR%%/library/Zend/Locale/Data/tg_TJ.xml +%%DATADIR%%/library/Zend/Locale/Data/th.xml +%%DATADIR%%/library/Zend/Locale/Data/th_TH.xml +%%DATADIR%%/library/Zend/Locale/Data/ti.xml +%%DATADIR%%/library/Zend/Locale/Data/ti_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/ti_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/tig.xml +%%DATADIR%%/library/Zend/Locale/Data/tig_ER.xml +%%DATADIR%%/library/Zend/Locale/Data/tl.xml +%%DATADIR%%/library/Zend/Locale/Data/tn.xml +%%DATADIR%%/library/Zend/Locale/Data/tn_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/to.xml +%%DATADIR%%/library/Zend/Locale/Data/to_TO.xml +%%DATADIR%%/library/Zend/Locale/Data/tr.xml +%%DATADIR%%/library/Zend/Locale/Data/tr_TR.xml +%%DATADIR%%/library/Zend/Locale/Data/ts.xml +%%DATADIR%%/library/Zend/Locale/Data/ts_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/tt.xml +%%DATADIR%%/library/Zend/Locale/Data/tt_RU.xml +%%DATADIR%%/library/Zend/Locale/Data/ug.xml +%%DATADIR%%/library/Zend/Locale/Data/ug_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/ug_Arab_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/ug_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/uk.xml +%%DATADIR%%/library/Zend/Locale/Data/uk_UA.xml +%%DATADIR%%/library/Zend/Locale/Data/ur.xml +%%DATADIR%%/library/Zend/Locale/Data/ur_IN.xml +%%DATADIR%%/library/Zend/Locale/Data/ur_PK.xml +%%DATADIR%%/library/Zend/Locale/Data/uz.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Arab.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Arab_AF.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Cyrl.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Cyrl_UZ.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_Latn_UZ.xml +%%DATADIR%%/library/Zend/Locale/Data/uz_UZ.xml +%%DATADIR%%/library/Zend/Locale/Data/ve.xml +%%DATADIR%%/library/Zend/Locale/Data/ve_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/vi.xml +%%DATADIR%%/library/Zend/Locale/Data/vi_VN.xml +%%DATADIR%%/library/Zend/Locale/Data/wal.xml +%%DATADIR%%/library/Zend/Locale/Data/wal_ET.xml +%%DATADIR%%/library/Zend/Locale/Data/wo.xml +%%DATADIR%%/library/Zend/Locale/Data/wo_Latn.xml +%%DATADIR%%/library/Zend/Locale/Data/wo_Latn_SN.xml +%%DATADIR%%/library/Zend/Locale/Data/wo_SN.xml +%%DATADIR%%/library/Zend/Locale/Data/xh.xml +%%DATADIR%%/library/Zend/Locale/Data/xh_ZA.xml +%%DATADIR%%/library/Zend/Locale/Data/yo.xml +%%DATADIR%%/library/Zend/Locale/Data/yo_NG.xml +%%DATADIR%%/library/Zend/Locale/Data/zh.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_CN.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_MO.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hans_SG.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant_HK.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant_MO.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_Hant_TW.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_MO.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_SG.xml +%%DATADIR%%/library/Zend/Locale/Data/zh_TW.xml +%%DATADIR%%/library/Zend/Locale/Data/zu.xml +%%DATADIR%%/library/Zend/Locale/Data/zu_ZA.xml +%%DATADIR%%/library/Zend/Locale/Exception.php +%%DATADIR%%/library/Zend/Locale/Format.php +%%DATADIR%%/library/Zend/Locale/Math.php +%%DATADIR%%/library/Zend/Locale/Math/Exception.php +%%DATADIR%%/library/Zend/Locale/Math/PhpMath.php +%%DATADIR%%/library/Zend/Log.php +%%DATADIR%%/library/Zend/Log/Exception.php +%%DATADIR%%/library/Zend/Log/Filter/Interface.php +%%DATADIR%%/library/Zend/Log/Filter/Message.php +%%DATADIR%%/library/Zend/Log/Filter/Priority.php +%%DATADIR%%/library/Zend/Log/Filter/Suppress.php +%%DATADIR%%/library/Zend/Log/Formatter/Interface.php +%%DATADIR%%/library/Zend/Log/Formatter/Simple.php +%%DATADIR%%/library/Zend/Log/Formatter/Xml.php +%%DATADIR%%/library/Zend/Log/Writer/Abstract.php +%%DATADIR%%/library/Zend/Log/Writer/Db.php +%%DATADIR%%/library/Zend/Log/Writer/Firebug.php +%%DATADIR%%/library/Zend/Log/Writer/Mock.php +%%DATADIR%%/library/Zend/Log/Writer/Null.php +%%DATADIR%%/library/Zend/Log/Writer/Stream.php +%%DATADIR%%/library/Zend/Mail.php +%%DATADIR%%/library/Zend/Mail/Exception.php +%%DATADIR%%/library/Zend/Mail/Message.php +%%DATADIR%%/library/Zend/Mail/Message/File.php +%%DATADIR%%/library/Zend/Mail/Message/Interface.php +%%DATADIR%%/library/Zend/Mail/Part.php +%%DATADIR%%/library/Zend/Mail/Part/File.php +%%DATADIR%%/library/Zend/Mail/Part/Interface.php +%%DATADIR%%/library/Zend/Mail/Protocol/Abstract.php +%%DATADIR%%/library/Zend/Mail/Protocol/Exception.php +%%DATADIR%%/library/Zend/Mail/Protocol/Imap.php +%%DATADIR%%/library/Zend/Mail/Protocol/Pop3.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth/Crammd5.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth/Login.php +%%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth/Plain.php +%%DATADIR%%/library/Zend/Mail/Storage.php +%%DATADIR%%/library/Zend/Mail/Storage/Abstract.php +%%DATADIR%%/library/Zend/Mail/Storage/Exception.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder/Interface.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder/Maildir.php +%%DATADIR%%/library/Zend/Mail/Storage/Folder/Mbox.php +%%DATADIR%%/library/Zend/Mail/Storage/Imap.php +%%DATADIR%%/library/Zend/Mail/Storage/Maildir.php +%%DATADIR%%/library/Zend/Mail/Storage/Mbox.php +%%DATADIR%%/library/Zend/Mail/Storage/Pop3.php +%%DATADIR%%/library/Zend/Mail/Storage/Writable/Interface.php +%%DATADIR%%/library/Zend/Mail/Storage/Writable/Maildir.php +%%DATADIR%%/library/Zend/Mail/Transport/Abstract.php +%%DATADIR%%/library/Zend/Mail/Transport/Exception.php +%%DATADIR%%/library/Zend/Mail/Transport/Sendmail.php +%%DATADIR%%/library/Zend/Mail/Transport/Smtp.php +%%DATADIR%%/library/Zend/Measure/Abstract.php +%%DATADIR%%/library/Zend/Measure/Acceleration.php +%%DATADIR%%/library/Zend/Measure/Angle.php +%%DATADIR%%/library/Zend/Measure/Area.php +%%DATADIR%%/library/Zend/Measure/Binary.php +%%DATADIR%%/library/Zend/Measure/Capacitance.php +%%DATADIR%%/library/Zend/Measure/Cooking/Volume.php +%%DATADIR%%/library/Zend/Measure/Cooking/Weight.php +%%DATADIR%%/library/Zend/Measure/Current.php +%%DATADIR%%/library/Zend/Measure/Density.php +%%DATADIR%%/library/Zend/Measure/Energy.php +%%DATADIR%%/library/Zend/Measure/Exception.php +%%DATADIR%%/library/Zend/Measure/Flow/Mass.php +%%DATADIR%%/library/Zend/Measure/Flow/Mole.php +%%DATADIR%%/library/Zend/Measure/Flow/Volume.php +%%DATADIR%%/library/Zend/Measure/Force.php +%%DATADIR%%/library/Zend/Measure/Frequency.php +%%DATADIR%%/library/Zend/Measure/Illumination.php +%%DATADIR%%/library/Zend/Measure/Length.php +%%DATADIR%%/library/Zend/Measure/Lightness.php +%%DATADIR%%/library/Zend/Measure/Number.php +%%DATADIR%%/library/Zend/Measure/Power.php +%%DATADIR%%/library/Zend/Measure/Pressure.php +%%DATADIR%%/library/Zend/Measure/Speed.php +%%DATADIR%%/library/Zend/Measure/Temperature.php +%%DATADIR%%/library/Zend/Measure/Time.php +%%DATADIR%%/library/Zend/Measure/Torque.php +%%DATADIR%%/library/Zend/Measure/Viscosity/Dynamic.php +%%DATADIR%%/library/Zend/Measure/Viscosity/Kinematic.php +%%DATADIR%%/library/Zend/Measure/Volume.php +%%DATADIR%%/library/Zend/Measure/Weight.php +%%DATADIR%%/library/Zend/Memory.php +%%DATADIR%%/library/Zend/Memory/AccessController.php +%%DATADIR%%/library/Zend/Memory/Container.php +%%DATADIR%%/library/Zend/Memory/Container/Interface.php +%%DATADIR%%/library/Zend/Memory/Container/Locked.php +%%DATADIR%%/library/Zend/Memory/Container/Movable.php +%%DATADIR%%/library/Zend/Memory/Exception.php +%%DATADIR%%/library/Zend/Memory/Manager.php +%%DATADIR%%/library/Zend/Memory/Value.php +%%DATADIR%%/library/Zend/Mime.php +%%DATADIR%%/library/Zend/Mime/Decode.php +%%DATADIR%%/library/Zend/Mime/Exception.php +%%DATADIR%%/library/Zend/Mime/Message.php +%%DATADIR%%/library/Zend/Mime/Part.php +%%DATADIR%%/library/Zend/OpenId.php +%%DATADIR%%/library/Zend/OpenId/Consumer.php +%%DATADIR%%/library/Zend/OpenId/Consumer/Storage.php +%%DATADIR%%/library/Zend/OpenId/Consumer/Storage/File.php +%%DATADIR%%/library/Zend/OpenId/Exception.php +%%DATADIR%%/library/Zend/OpenId/Extension.php +%%DATADIR%%/library/Zend/OpenId/Extension/Sreg.php +%%DATADIR%%/library/Zend/OpenId/Provider.php +%%DATADIR%%/library/Zend/OpenId/Provider/Storage.php +%%DATADIR%%/library/Zend/OpenId/Provider/Storage/File.php +%%DATADIR%%/library/Zend/OpenId/Provider/User.php +%%DATADIR%%/library/Zend/OpenId/Provider/User/Session.php +%%DATADIR%%/library/Zend/Paginator.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Array.php +%%DATADIR%%/library/Zend/Paginator/Adapter/DbSelect.php +%%DATADIR%%/library/Zend/Paginator/Adapter/DbTableSelect.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Interface.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Iterator.php +%%DATADIR%%/library/Zend/Paginator/Adapter/Null.php +%%DATADIR%%/library/Zend/Paginator/Exception.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/All.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Elastic.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Interface.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Jumping.php +%%DATADIR%%/library/Zend/Paginator/ScrollingStyle/Sliding.php +%%DATADIR%%/library/Zend/Pdf.php +%%DATADIR%%/library/Zend/Pdf/Cmap.php +%%DATADIR%%/library/Zend/Pdf/Cmap/ByteEncoding.php +%%DATADIR%%/library/Zend/Pdf/Cmap/ByteEncoding/Static.php +%%DATADIR%%/library/Zend/Pdf/Cmap/SegmentToDelta.php +%%DATADIR%%/library/Zend/Pdf/Cmap/TrimmedTable.php +%%DATADIR%%/library/Zend/Pdf/Color.php +%%DATADIR%%/library/Zend/Pdf/Color/Cmyk.php +%%DATADIR%%/library/Zend/Pdf/Color/GrayScale.php +%%DATADIR%%/library/Zend/Pdf/Color/Html.php +%%DATADIR%%/library/Zend/Pdf/Color/Rgb.php +%%DATADIR%%/library/Zend/Pdf/Element.php +%%DATADIR%%/library/Zend/Pdf/Element/Array.php +%%DATADIR%%/library/Zend/Pdf/Element/Boolean.php +%%DATADIR%%/library/Zend/Pdf/Element/Dictionary.php +%%DATADIR%%/library/Zend/Pdf/Element/Name.php +%%DATADIR%%/library/Zend/Pdf/Element/Null.php +%%DATADIR%%/library/Zend/Pdf/Element/Numeric.php +%%DATADIR%%/library/Zend/Pdf/Element/Object.php +%%DATADIR%%/library/Zend/Pdf/Element/Object/Stream.php +%%DATADIR%%/library/Zend/Pdf/Element/Reference.php +%%DATADIR%%/library/Zend/Pdf/Element/Reference/Context.php +%%DATADIR%%/library/Zend/Pdf/Element/Reference/Table.php +%%DATADIR%%/library/Zend/Pdf/Element/Stream.php +%%DATADIR%%/library/Zend/Pdf/Element/String.php +%%DATADIR%%/library/Zend/Pdf/Element/String/Binary.php +%%DATADIR%%/library/Zend/Pdf/ElementFactory.php +%%DATADIR%%/library/Zend/Pdf/ElementFactory/Interface.php +%%DATADIR%%/library/Zend/Pdf/ElementFactory/Proxy.php +%%DATADIR%%/library/Zend/Pdf/Exception.php +%%DATADIR%%/library/Zend/Pdf/FileParser.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Font.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Font/OpenType.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Font/OpenType/TrueType.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Image.php +%%DATADIR%%/library/Zend/Pdf/FileParser/Image/Png.php +%%DATADIR%%/library/Zend/Pdf/FileParserDataSource.php +%%DATADIR%%/library/Zend/Pdf/FileParserDataSource/File.php +%%DATADIR%%/library/Zend/Pdf/FileParserDataSource/String.php +%%DATADIR%%/library/Zend/Pdf/Filter/Ascii85.php +%%DATADIR%%/library/Zend/Pdf/Filter/AsciiHex.php +%%DATADIR%%/library/Zend/Pdf/Filter/Compression.php +%%DATADIR%%/library/Zend/Pdf/Filter/Compression/Flate.php +%%DATADIR%%/library/Zend/Pdf/Filter/Compression/Lzw.php +%%DATADIR%%/library/Zend/Pdf/Filter/Interface.php +%%DATADIR%%/library/Zend/Pdf/Font.php +%%DATADIR%%/library/Zend/Pdf/Image.php +%%DATADIR%%/library/Zend/Pdf/Page.php +%%DATADIR%%/library/Zend/Pdf/Parser.php +%%DATADIR%%/library/Zend/Pdf/Parser/Stream.php +%%DATADIR%%/library/Zend/Pdf/PhpArray.php +%%DATADIR%%/library/Zend/Pdf/Resource.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/CidFont.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/CidFont/TrueType.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Extracted.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/FontDescriptor.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Parsed.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Parsed/TrueType.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/Courier.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/CourierBold.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/CourierBoldOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/CourierOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/Helvetica.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/HelveticaBold.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/HelveticaBoldOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/HelveticaOblique.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/Symbol.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesBold.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesBoldItalic.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesItalic.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/TimesRoman.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard/ZapfDingbats.php +%%DATADIR%%/library/Zend/Pdf/Resource/Font/Type0.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image/Jpeg.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image/Png.php +%%DATADIR%%/library/Zend/Pdf/Resource/Image/Tiff.php +%%DATADIR%%/library/Zend/Pdf/Resource/ImageFactory.php +%%DATADIR%%/library/Zend/Pdf/StringParser.php +%%DATADIR%%/library/Zend/Pdf/Style.php +%%DATADIR%%/library/Zend/Pdf/Trailer.php +%%DATADIR%%/library/Zend/Pdf/Trailer/Generator.php +%%DATADIR%%/library/Zend/Pdf/Trailer/Keeper.php +%%DATADIR%%/library/Zend/Pdf/UpdateInfoContainer.php +%%DATADIR%%/library/Zend/ProgressBar.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/Console.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/Exception.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/JsPull.php +%%DATADIR%%/library/Zend/ProgressBar/Adapter/JsPush.php +%%DATADIR%%/library/Zend/ProgressBar/Exception.php +%%DATADIR%%/library/Zend/Registry.php +%%DATADIR%%/library/Zend/Request/Interface.php +%%DATADIR%%/library/Zend/Rest/Client.php +%%DATADIR%%/library/Zend/Rest/Client/Exception.php +%%DATADIR%%/library/Zend/Rest/Client/Result.php +%%DATADIR%%/library/Zend/Rest/Client/Result/Exception.php +%%DATADIR%%/library/Zend/Rest/Exception.php +%%DATADIR%%/library/Zend/Rest/Server.php +%%DATADIR%%/library/Zend/Rest/Server/Exception.php +%%DATADIR%%/library/Zend/Search/Exception.php +%%DATADIR%%/library/Zend/Search/Lucene.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Text.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Text/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/TextNum.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/TextNum/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8Num.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8Num/CaseInsensitive.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/Token.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/LowerCase.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/LowerCaseUtf8.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/ShortWords.php +%%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter/StopWords.php +%%DATADIR%%/library/Zend/Search/Lucene/Document.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Docx.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Html.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/OpenXml.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Pptx.php +%%DATADIR%%/library/Zend/Search/Lucene/Document/Xlsx.php +%%DATADIR%%/library/Zend/Search/Lucene/Exception.php +%%DATADIR%%/library/Zend/Search/Lucene/FSM.php +%%DATADIR%%/library/Zend/Search/Lucene/FSMAction.php +%%DATADIR%%/library/Zend/Search/Lucene/Field.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/DictionaryLoader.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/DocsFilter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/FieldInfo.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentInfo.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentInfoPriorityQueue.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentMerger.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter/DocumentWriter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter/StreamWriter.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/TermInfo.php +%%DATADIR%%/library/Zend/Search/Lucene/Index/Writer.php +%%DATADIR%%/library/Zend/Search/Lucene/Interface.php +%%DATADIR%%/library/Zend/Search/Lucene/LockManager.php +%%DATADIR%%/library/Zend/Search/Lucene/PriorityQueue.php +%%DATADIR%%/library/Zend/Search/Lucene/Proxy.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/BooleanExpressionRecognizer.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Boolean.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Empty.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Fuzzy.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Insignificant.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/MultiTerm.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Phrase.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Range.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Query/Wildcard.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry/Phrase.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry/Subquery.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryHit.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryLexer.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryParser.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryParserContext.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryParserException.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/QueryToken.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Similarity.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Similarity/Default.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Boolean.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Empty.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/MultiTerm.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Phrase.php +%%DATADIR%%/library/Zend/Search/Lucene/Search/Weight/Term.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/Directory.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/Directory/Filesystem.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/File.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/File/Filesystem.php +%%DATADIR%%/library/Zend/Search/Lucene/Storage/File/Memory.php +%%DATADIR%%/library/Zend/Server/Abstract.php +%%DATADIR%%/library/Zend/Server/Cache.php +%%DATADIR%%/library/Zend/Server/Definition.php +%%DATADIR%%/library/Zend/Server/Exception.php +%%DATADIR%%/library/Zend/Server/Interface.php +%%DATADIR%%/library/Zend/Server/Method/Callback.php +%%DATADIR%%/library/Zend/Server/Method/Definition.php +%%DATADIR%%/library/Zend/Server/Method/Parameter.php +%%DATADIR%%/library/Zend/Server/Method/Prototype.php +%%DATADIR%%/library/Zend/Server/Reflection.php +%%DATADIR%%/library/Zend/Server/Reflection/Class.php +%%DATADIR%%/library/Zend/Server/Reflection/Exception.php +%%DATADIR%%/library/Zend/Server/Reflection/Function.php +%%DATADIR%%/library/Zend/Server/Reflection/Function/Abstract.php +%%DATADIR%%/library/Zend/Server/Reflection/Method.php +%%DATADIR%%/library/Zend/Server/Reflection/Node.php +%%DATADIR%%/library/Zend/Server/Reflection/Parameter.php +%%DATADIR%%/library/Zend/Server/Reflection/Prototype.php +%%DATADIR%%/library/Zend/Server/Reflection/ReturnValue.php +%%DATADIR%%/library/Zend/Service/Abstract.php +%%DATADIR%%/library/Zend/Service/Akismet.php +%%DATADIR%%/library/Zend/Service/Amazon.php +%%DATADIR%%/library/Zend/Service/Amazon/Accessories.php +%%DATADIR%%/library/Zend/Service/Amazon/CustomerReview.php +%%DATADIR%%/library/Zend/Service/Amazon/EditorialReview.php +%%DATADIR%%/library/Zend/Service/Amazon/Image.php +%%DATADIR%%/library/Zend/Service/Amazon/Item.php +%%DATADIR%%/library/Zend/Service/Amazon/ListmaniaList.php +%%DATADIR%%/library/Zend/Service/Amazon/Offer.php +%%DATADIR%%/library/Zend/Service/Amazon/OfferSet.php +%%DATADIR%%/library/Zend/Service/Amazon/Query.php +%%DATADIR%%/library/Zend/Service/Amazon/ResultSet.php +%%DATADIR%%/library/Zend/Service/Amazon/SimilarProduct.php +%%DATADIR%%/library/Zend/Service/Audioscrobbler.php +%%DATADIR%%/library/Zend/Service/Delicious.php +%%DATADIR%%/library/Zend/Service/Delicious/Exception.php +%%DATADIR%%/library/Zend/Service/Delicious/Post.php +%%DATADIR%%/library/Zend/Service/Delicious/PostList.php +%%DATADIR%%/library/Zend/Service/Delicious/SimplePost.php +%%DATADIR%%/library/Zend/Service/Exception.php +%%DATADIR%%/library/Zend/Service/Flickr.php +%%DATADIR%%/library/Zend/Service/Flickr/Image.php +%%DATADIR%%/library/Zend/Service/Flickr/Result.php +%%DATADIR%%/library/Zend/Service/Flickr/ResultSet.php +%%DATADIR%%/library/Zend/Service/Nirvanix.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Exception.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Namespace/Base.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Namespace/Imfs.php +%%DATADIR%%/library/Zend/Service/Nirvanix/Response.php +%%DATADIR%%/library/Zend/Service/ReCaptcha.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/Exception.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/MailHide.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/MailHide/Exception.php +%%DATADIR%%/library/Zend/Service/ReCaptcha/Response.php +%%DATADIR%%/library/Zend/Service/Simpy.php +%%DATADIR%%/library/Zend/Service/Simpy/Link.php +%%DATADIR%%/library/Zend/Service/Simpy/LinkQuery.php +%%DATADIR%%/library/Zend/Service/Simpy/LinkSet.php +%%DATADIR%%/library/Zend/Service/Simpy/Note.php +%%DATADIR%%/library/Zend/Service/Simpy/NoteSet.php +%%DATADIR%%/library/Zend/Service/Simpy/Tag.php +%%DATADIR%%/library/Zend/Service/Simpy/TagSet.php +%%DATADIR%%/library/Zend/Service/Simpy/Watchlist.php +%%DATADIR%%/library/Zend/Service/Simpy/WatchlistFilter.php +%%DATADIR%%/library/Zend/Service/Simpy/WatchlistFilterSet.php +%%DATADIR%%/library/Zend/Service/Simpy/WatchlistSet.php +%%DATADIR%%/library/Zend/Service/SlideShare.php +%%DATADIR%%/library/Zend/Service/SlideShare/Exception.php +%%DATADIR%%/library/Zend/Service/SlideShare/SlideShow.php +%%DATADIR%%/library/Zend/Service/StrikeIron.php +%%DATADIR%%/library/Zend/Service/StrikeIron/Base.php +%%DATADIR%%/library/Zend/Service/StrikeIron/Decorator.php +%%DATADIR%%/library/Zend/Service/StrikeIron/Exception.php +%%DATADIR%%/library/Zend/Service/StrikeIron/SalesUseTaxBasic.php +%%DATADIR%%/library/Zend/Service/StrikeIron/USAddressVerification.php +%%DATADIR%%/library/Zend/Service/StrikeIron/ZipCodeInfo.php +%%DATADIR%%/library/Zend/Service/Technorati.php +%%DATADIR%%/library/Zend/Service/Technorati/Author.php +%%DATADIR%%/library/Zend/Service/Technorati/BlogInfoResult.php +%%DATADIR%%/library/Zend/Service/Technorati/CosmosResult.php +%%DATADIR%%/library/Zend/Service/Technorati/CosmosResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/DailyCountsResult.php +%%DATADIR%%/library/Zend/Service/Technorati/DailyCountsResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/Exception.php +%%DATADIR%%/library/Zend/Service/Technorati/GetInfoResult.php +%%DATADIR%%/library/Zend/Service/Technorati/KeyInfoResult.php +%%DATADIR%%/library/Zend/Service/Technorati/Result.php +%%DATADIR%%/library/Zend/Service/Technorati/ResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/SearchResult.php +%%DATADIR%%/library/Zend/Service/Technorati/SearchResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/TagResult.php +%%DATADIR%%/library/Zend/Service/Technorati/TagResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/TagsResult.php +%%DATADIR%%/library/Zend/Service/Technorati/TagsResultSet.php +%%DATADIR%%/library/Zend/Service/Technorati/Utils.php +%%DATADIR%%/library/Zend/Service/Technorati/Weblog.php +%%DATADIR%%/library/Zend/Service/Twitter.php +%%DATADIR%%/library/Zend/Service/Twitter/Exception.php +%%DATADIR%%/library/Zend/Service/Twitter/Search.php +%%DATADIR%%/library/Zend/Service/Yahoo.php +%%DATADIR%%/library/Zend/Service/Yahoo/Image.php +%%DATADIR%%/library/Zend/Service/Yahoo/ImageResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/ImageResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/InlinkDataResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/InlinkDataResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/LocalResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/LocalResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/NewsResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/NewsResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/PageDataResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/PageDataResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/Result.php +%%DATADIR%%/library/Zend/Service/Yahoo/ResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/VideoResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/VideoResultSet.php +%%DATADIR%%/library/Zend/Service/Yahoo/WebResult.php +%%DATADIR%%/library/Zend/Service/Yahoo/WebResultSet.php +%%DATADIR%%/library/Zend/Session.php +%%DATADIR%%/library/Zend/Session/Abstract.php +%%DATADIR%%/library/Zend/Session/Exception.php +%%DATADIR%%/library/Zend/Session/Namespace.php +%%DATADIR%%/library/Zend/Session/SaveHandler/DbTable.php +%%DATADIR%%/library/Zend/Session/SaveHandler/Exception.php +%%DATADIR%%/library/Zend/Session/SaveHandler/Interface.php +%%DATADIR%%/library/Zend/Session/Validator/Abstract.php +%%DATADIR%%/library/Zend/Session/Validator/HttpUserAgent.php +%%DATADIR%%/library/Zend/Session/Validator/Interface.php +%%DATADIR%%/library/Zend/Soap/AutoDiscover.php +%%DATADIR%%/library/Zend/Soap/AutoDiscover/Exception.php +%%DATADIR%%/library/Zend/Soap/Client.php +%%DATADIR%%/library/Zend/Soap/Client/Common.php +%%DATADIR%%/library/Zend/Soap/Client/DotNet.php +%%DATADIR%%/library/Zend/Soap/Client/Exception.php +%%DATADIR%%/library/Zend/Soap/Client/Local.php +%%DATADIR%%/library/Zend/Soap/Server.php +%%DATADIR%%/library/Zend/Soap/Server/Exception.php +%%DATADIR%%/library/Zend/Soap/Wsdl.php +%%DATADIR%%/library/Zend/Soap/Wsdl/CodeGenerator.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Exception.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Parser.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Parser/Result.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/Abstract.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/AnyType.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/ArrayOfTypeComplex.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/ArrayOfTypeSequence.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/DefaultComplexType.php +%%DATADIR%%/library/Zend/Soap/Wsdl/Strategy/Interface.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/DomQuery.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/Exception.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/Redirect.php +%%DATADIR%%/library/Zend/Test/PHPUnit/Constraint/ResponseHeader.php +%%DATADIR%%/library/Zend/Test/PHPUnit/ControllerTestCase.php +%%DATADIR%%/library/Zend/Text/Exception.php +%%DATADIR%%/library/Zend/Text/Figlet.php +%%DATADIR%%/library/Zend/Text/Figlet/Exception.php +%%DATADIR%%/library/Zend/Text/Figlet/zend-framework.flf +%%DATADIR%%/library/Zend/Text/MultiByte.php +%%DATADIR%%/library/Zend/Text/Table.php +%%DATADIR%%/library/Zend/Text/Table/Column.php +%%DATADIR%%/library/Zend/Text/Table/Decorator/Ascii.php +%%DATADIR%%/library/Zend/Text/Table/Decorator/Interface.php +%%DATADIR%%/library/Zend/Text/Table/Decorator/Unicode.php +%%DATADIR%%/library/Zend/Text/Table/Exception.php +%%DATADIR%%/library/Zend/Text/Table/Row.php +%%DATADIR%%/library/Zend/TimeSync.php +%%DATADIR%%/library/Zend/TimeSync/Exception.php +%%DATADIR%%/library/Zend/TimeSync/Ntp.php +%%DATADIR%%/library/Zend/TimeSync/Protocol.php +%%DATADIR%%/library/Zend/TimeSync/Sntp.php +%%DATADIR%%/library/Zend/Translate.php +%%DATADIR%%/library/Zend/Translate/Adapter.php +%%DATADIR%%/library/Zend/Translate/Adapter/Array.php +%%DATADIR%%/library/Zend/Translate/Adapter/Csv.php +%%DATADIR%%/library/Zend/Translate/Adapter/Gettext.php +%%DATADIR%%/library/Zend/Translate/Adapter/Ini.php +%%DATADIR%%/library/Zend/Translate/Adapter/Qt.php +%%DATADIR%%/library/Zend/Translate/Adapter/Tbx.php +%%DATADIR%%/library/Zend/Translate/Adapter/Tmx.php +%%DATADIR%%/library/Zend/Translate/Adapter/Xliff.php +%%DATADIR%%/library/Zend/Translate/Adapter/XmlTm.php +%%DATADIR%%/library/Zend/Translate/Exception.php +%%DATADIR%%/library/Zend/Uri.php +%%DATADIR%%/library/Zend/Uri/Exception.php +%%DATADIR%%/library/Zend/Uri/Http.php +%%DATADIR%%/library/Zend/Validate.php +%%DATADIR%%/library/Zend/Validate/Abstract.php +%%DATADIR%%/library/Zend/Validate/Alnum.php +%%DATADIR%%/library/Zend/Validate/Alpha.php +%%DATADIR%%/library/Zend/Validate/Barcode.php +%%DATADIR%%/library/Zend/Validate/Barcode/Ean13.php +%%DATADIR%%/library/Zend/Validate/Barcode/UpcA.php +%%DATADIR%%/library/Zend/Validate/Between.php +%%DATADIR%%/library/Zend/Validate/Ccnum.php +%%DATADIR%%/library/Zend/Validate/Date.php +%%DATADIR%%/library/Zend/Validate/Digits.php +%%DATADIR%%/library/Zend/Validate/EmailAddress.php +%%DATADIR%%/library/Zend/Validate/Exception.php +%%DATADIR%%/library/Zend/Validate/File/Count.php +%%DATADIR%%/library/Zend/Validate/File/Crc32.php +%%DATADIR%%/library/Zend/Validate/File/ExcludeExtension.php +%%DATADIR%%/library/Zend/Validate/File/ExcludeMimeType.php +%%DATADIR%%/library/Zend/Validate/File/Exists.php +%%DATADIR%%/library/Zend/Validate/File/Extension.php +%%DATADIR%%/library/Zend/Validate/File/FilesSize.php +%%DATADIR%%/library/Zend/Validate/File/Hash.php +%%DATADIR%%/library/Zend/Validate/File/ImageSize.php +%%DATADIR%%/library/Zend/Validate/File/IsCompressed.php +%%DATADIR%%/library/Zend/Validate/File/IsImage.php +%%DATADIR%%/library/Zend/Validate/File/Md5.php +%%DATADIR%%/library/Zend/Validate/File/MimeType.php +%%DATADIR%%/library/Zend/Validate/File/NotExists.php +%%DATADIR%%/library/Zend/Validate/File/Sha1.php +%%DATADIR%%/library/Zend/Validate/File/Size.php +%%DATADIR%%/library/Zend/Validate/File/Upload.php +%%DATADIR%%/library/Zend/Validate/Float.php +%%DATADIR%%/library/Zend/Validate/GreaterThan.php +%%DATADIR%%/library/Zend/Validate/Hex.php +%%DATADIR%%/library/Zend/Validate/Hostname.php +%%DATADIR%%/library/Zend/Validate/Hostname/At.php +%%DATADIR%%/library/Zend/Validate/Hostname/Ch.php +%%DATADIR%%/library/Zend/Validate/Hostname/De.php +%%DATADIR%%/library/Zend/Validate/Hostname/Fi.php +%%DATADIR%%/library/Zend/Validate/Hostname/Hu.php +%%DATADIR%%/library/Zend/Validate/Hostname/Interface.php +%%DATADIR%%/library/Zend/Validate/Hostname/Li.php +%%DATADIR%%/library/Zend/Validate/Hostname/No.php +%%DATADIR%%/library/Zend/Validate/Hostname/Se.php +%%DATADIR%%/library/Zend/Validate/Identical.php +%%DATADIR%%/library/Zend/Validate/InArray.php +%%DATADIR%%/library/Zend/Validate/Int.php +%%DATADIR%%/library/Zend/Validate/Interface.php +%%DATADIR%%/library/Zend/Validate/Ip.php +%%DATADIR%%/library/Zend/Validate/LessThan.php +%%DATADIR%%/library/Zend/Validate/NotEmpty.php +%%DATADIR%%/library/Zend/Validate/Regex.php +%%DATADIR%%/library/Zend/Validate/StringLength.php +%%DATADIR%%/library/Zend/Version.php +%%DATADIR%%/library/Zend/View.php +%%DATADIR%%/library/Zend/View/Abstract.php +%%DATADIR%%/library/Zend/View/Exception.php +%%DATADIR%%/library/Zend/View/Helper/Abstract.php +%%DATADIR%%/library/Zend/View/Helper/Action.php +%%DATADIR%%/library/Zend/View/Helper/DeclareVars.php +%%DATADIR%%/library/Zend/View/Helper/Doctype.php +%%DATADIR%%/library/Zend/View/Helper/Fieldset.php +%%DATADIR%%/library/Zend/View/Helper/Form.php +%%DATADIR%%/library/Zend/View/Helper/FormButton.php +%%DATADIR%%/library/Zend/View/Helper/FormCheckbox.php +%%DATADIR%%/library/Zend/View/Helper/FormElement.php +%%DATADIR%%/library/Zend/View/Helper/FormErrors.php +%%DATADIR%%/library/Zend/View/Helper/FormFile.php +%%DATADIR%%/library/Zend/View/Helper/FormHidden.php +%%DATADIR%%/library/Zend/View/Helper/FormImage.php +%%DATADIR%%/library/Zend/View/Helper/FormLabel.php +%%DATADIR%%/library/Zend/View/Helper/FormMultiCheckbox.php +%%DATADIR%%/library/Zend/View/Helper/FormNote.php +%%DATADIR%%/library/Zend/View/Helper/FormPassword.php +%%DATADIR%%/library/Zend/View/Helper/FormRadio.php +%%DATADIR%%/library/Zend/View/Helper/FormReset.php +%%DATADIR%%/library/Zend/View/Helper/FormSelect.php +%%DATADIR%%/library/Zend/View/Helper/FormSubmit.php +%%DATADIR%%/library/Zend/View/Helper/FormText.php +%%DATADIR%%/library/Zend/View/Helper/FormTextarea.php +%%DATADIR%%/library/Zend/View/Helper/HeadLink.php +%%DATADIR%%/library/Zend/View/Helper/HeadMeta.php +%%DATADIR%%/library/Zend/View/Helper/HeadScript.php +%%DATADIR%%/library/Zend/View/Helper/HeadStyle.php +%%DATADIR%%/library/Zend/View/Helper/HeadTitle.php +%%DATADIR%%/library/Zend/View/Helper/HtmlElement.php +%%DATADIR%%/library/Zend/View/Helper/HtmlFlash.php +%%DATADIR%%/library/Zend/View/Helper/HtmlList.php +%%DATADIR%%/library/Zend/View/Helper/HtmlObject.php +%%DATADIR%%/library/Zend/View/Helper/HtmlPage.php +%%DATADIR%%/library/Zend/View/Helper/HtmlQuicktime.php +%%DATADIR%%/library/Zend/View/Helper/InlineScript.php +%%DATADIR%%/library/Zend/View/Helper/Interface.php +%%DATADIR%%/library/Zend/View/Helper/Json.php +%%DATADIR%%/library/Zend/View/Helper/Layout.php +%%DATADIR%%/library/Zend/View/Helper/PaginationControl.php +%%DATADIR%%/library/Zend/View/Helper/Partial.php +%%DATADIR%%/library/Zend/View/Helper/Partial/Exception.php +%%DATADIR%%/library/Zend/View/Helper/PartialLoop.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container/Abstract.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container/Exception.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Container/Standalone.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Registry.php +%%DATADIR%%/library/Zend/View/Helper/Placeholder/Registry/Exception.php +%%DATADIR%%/library/Zend/View/Helper/RenderToPlaceholder.php +%%DATADIR%%/library/Zend/View/Helper/Translate.php +%%DATADIR%%/library/Zend/View/Helper/Url.php +%%DATADIR%%/library/Zend/View/Interface.php +%%DATADIR%%/library/Zend/View/Stream.php +%%DATADIR%%/library/Zend/Wildfire/Channel/HttpHeaders.php +%%DATADIR%%/library/Zend/Wildfire/Channel/Interface.php +%%DATADIR%%/library/Zend/Wildfire/Exception.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp/Message.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp/TableMessage.php +%%DATADIR%%/library/Zend/Wildfire/Plugin/Interface.php +%%DATADIR%%/library/Zend/Wildfire/Protocol/JsonStream.php +%%DATADIR%%/library/Zend/XmlRpc/Client.php +%%DATADIR%%/library/Zend/XmlRpc/Client/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Client/FaultException.php +%%DATADIR%%/library/Zend/XmlRpc/Client/HttpException.php +%%DATADIR%%/library/Zend/XmlRpc/Client/IntrospectException.php +%%DATADIR%%/library/Zend/XmlRpc/Client/ServerIntrospection.php +%%DATADIR%%/library/Zend/XmlRpc/Client/ServerProxy.php +%%DATADIR%%/library/Zend/XmlRpc/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Fault.php +%%DATADIR%%/library/Zend/XmlRpc/Request.php +%%DATADIR%%/library/Zend/XmlRpc/Request/Http.php +%%DATADIR%%/library/Zend/XmlRpc/Request/Stdin.php +%%DATADIR%%/library/Zend/XmlRpc/Response.php +%%DATADIR%%/library/Zend/XmlRpc/Response/Http.php +%%DATADIR%%/library/Zend/XmlRpc/Server.php +%%DATADIR%%/library/Zend/XmlRpc/Server/Cache.php +%%DATADIR%%/library/Zend/XmlRpc/Server/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Server/Fault.php +%%DATADIR%%/library/Zend/XmlRpc/Server/System.php +%%DATADIR%%/library/Zend/XmlRpc/Value.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Array.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Base64.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Boolean.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Collection.php +%%DATADIR%%/library/Zend/XmlRpc/Value/DateTime.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Double.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Exception.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Integer.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Nil.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Scalar.php +%%DATADIR%%/library/Zend/XmlRpc/Value/String.php +%%DATADIR%%/library/Zend/XmlRpc/Value/Struct.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Feeds/consume-feed.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Blogger.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser/books_browser.css +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser/interface.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Calendar.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Docs.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Gapps.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Gbase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Health.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/InstallationChecker.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/MyLibrary/demo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Photos.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/Spreadsheet-ClientLogin.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/notfound.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/operations.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/session_details.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/video_app.css +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp/video_app.js +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/interface.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/video_browser.css +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser/video_browser.js +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Locale/AllLanguages.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/SimpleMailer.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/maildir/maildir.tar +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/mbox/INBOX +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Mail/mbox/subfolder/test +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/login-bg.gif +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/controllers/ErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/error/404.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/error/500.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/index/login.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/index/welcome.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html/.htaccess +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html/config.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/identity.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/identity2.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/login.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/profile.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/register.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/registration_complete.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/templates/trust.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/test_auth.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/test_consumer.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/OpenId/test_server.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Pdf/demo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Pdf/stamp.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Pdf/test.pdf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/ProgressBar/JsPush.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/ProgressBar/Upload.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/ProgressBar/animation.gif +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/feed-search/create-index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/feed-search/search-index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/CreateIndex.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/about-pear.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/authors.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.bugs.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.documentation.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.newpackage.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.patches.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/contributing.wishlist.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/copyright.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource/core.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Amazon/amazon-search.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Flickr/flickr-composite.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Flickr/flickr-search.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Protocols/xmlrpc-upc-lookup.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/WebServices/Yahoo/yahoo-multi-search.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Db-Profiler-Firebug/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Log-Writer-Firebug/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ZendDbProfilerFirebugController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ZendLogWriterFirebugController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/ZendWildfirePluginFirePhpController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/error/error.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/index/index.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-db-profiler-firebug/test-logging.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-db-profiler-firebug/test-multiple-databases.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug/test-error-controller.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug/test-large-message.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug/test-logging.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-wildfire-plugin-firephp/test-groups.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/.htaccess +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Db-Profiler-Firebug/TestDocExample.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Log-Writer-Firebug/TestDocExample.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/demos/Zend/Wildfire/public/index.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/TestConfiguration.php.dist +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/TestHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/AclTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Contact.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/bytearray.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/longstring.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/arrayAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/bogusTypedObjectAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolFalseAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolFalseAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolTrueAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/boolTrueAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/byteArrayAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/credentialsheaderAmf0.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/dateAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/dateAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/intAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/largeIntAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/mixedArrayAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/nullAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/numberAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/numberAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/objectAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/referenceAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/stringAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/stringAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/typedObjectAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/undefAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/undefinedAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/xmlAmf0Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock/xmlAmf3Request.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/RequestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/arrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/arrayAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolFalseAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolFalseAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolTrueAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/boolTrueAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/classMapAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/dateAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/dateAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/intAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/largeIntAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/mixedArrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/nestedArrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/nullAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/numberAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/numberAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/objectAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/stringAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/stringAmf3Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/stringArrayAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock/typedObjectAmf0Response.bin +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/TypeLoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Util/BinaryStreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Value/MessageBodyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Amf/Value/MessageHeaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/BasicSqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/BasicSqliteTest/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Digest/_files/.htdigest.1 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DigestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/AuthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/ObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/ProxyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/Resolver/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/Resolver/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/_files/htbasic.1 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/_files/htdigest.3 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/OpenIdTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/ResponseHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Auth/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/AuthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/ApcBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/ClassFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/CommonBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/CommonExtendedBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/CoreTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FactoryException.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FactoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FileBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FileFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/FunctionFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/MemcachedBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/OutputFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/PageFrontendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/SqliteBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/TwoLevelsBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/XcacheBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Cache/ZendPlatformBackendTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/DumbTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/FigletTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/ImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Captcha/ReCaptchaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/IniTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/IniTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/XmlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/files/allsections.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/Writer/files/allsections.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/XmlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/allsections.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/allsections.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/array.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/circular.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/circular.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/config.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/config.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/invalid.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/invalid.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/multipleinheritance.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/nosections.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/onetoplevelstring.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/separator.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/shortparamsone.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/shortparamstwo.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/toplevelstring.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Config/_files/zf2843.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ConfigTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Console/GetoptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/ActionStackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/AjaxContextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/AutoCompleteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/ContextSwitchTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/FlashMessengerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/JsonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/RedirectorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/UrlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper/ViewRendererTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/HelperBroker/PriorityStackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Action/HelperBrokerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/ActionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Dispatcher/StandardTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/FrontTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Plugin/ActionStackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Plugin/BrokerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Plugin/ErrorHandlerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/Apache404Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/HttpTestCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Request/SimpleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Response/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Response/HttpTestCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/RewriteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/ChainTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/HostnameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/ModuleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/RegexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/Router/RouteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin/BazController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin/FooBarController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/BazController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/EmptyController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/FooBarController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/HelperBrokerController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/HelperFlashMessengerController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Helpers/TestHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/Helpers/Url.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/ObController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/ViewController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/index/test.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/test.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/test/foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/controllers/Admin/HelperController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/helpers/SampleZfHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts/admin/helper/render.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers/Admin/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/helpers/FooUseHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts/admin/index/use-helper.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/routes-root.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/_files/routes.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/custom/renderScript.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/foo-bar/baz-bat.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/ob.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/site.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/view/index.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/view/name.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/CurrencyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Date/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Date/DateObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/DateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/Db2Statement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/MysqliStatement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/OracleStatement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test/PdoStatement.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Testnamespace/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/FirebugTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/ProfilerCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Profiler/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Select/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Statement/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestMockRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestMyRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/TestTableRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/TestMyRowset.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Db2Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/MysqliTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/OdbcTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/IbmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/MssqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/MysqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/OciTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/PgsqlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo/SqliteTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableAccounts.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableAccountsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugs.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugsProducts.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableBugsProductsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableProducts.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableProductsCustom.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TableSpecial.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TestCommon.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/Table/TestSetup.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestSetup.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Common.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Db2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Mysqli.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Oracle.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Common.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Ibm.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Mssql.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Mysql.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Oci.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Pgsql.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo/Sqlite.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Static.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/DebugTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/DataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/DojoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/AccordionContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/AccordionPaneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/BorderContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/DijitContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/DijitElementTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/DijitFormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/SplitContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/StackContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator/TabContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/ButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/CheckBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/ComboBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/CurrencyTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/DateTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/DijitTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/EditorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/FilteringSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/HorizontalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/NumberSpinnerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/NumberTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/PasswordTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/RadioButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/SubmitButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/TextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/TextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/TimeTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/ValidationTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/VerticalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/_files/locale/array.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/Form/SubFormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/AccordionContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/AccordionPaneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/BorderContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/CheckBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ComboBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ContentPaneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/CurrencyTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/DateTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/DojoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/EditorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/FilteringSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/HorizontalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/NumberSpinnerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/NumberTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/PasswordTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/RadioButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/SimpleTextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/SplitContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/StackContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/SubmitButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TabContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/TimeTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/ValidationTextBoxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper/VerticalSliderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/Query/Css2XpathTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/Query/ResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Dom/_files/sample.xhtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/ArrayAccessTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/AtomEntryOnlyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/AtomPublishingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/CountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/ElementTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/Entry/RssTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/ImportTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/IteratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-before-update.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-created-entry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-expected-update.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomPublishingTest-updated-entry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestGoogle.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestMozillazine.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestOReilly.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestPlanetPHP.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample3.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/AtomTestSample4.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest091Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest092Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest100Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest100Sample2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTest200Sample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestCNN.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestHarvardLaw.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestPlanetPHP.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/RssTestSlashdot.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestAtomFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestAtomFeedEntryOnly.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestAtomFeedNamespaced.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Feed/_files/TestFeedEntryRssContentEncoded.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/Transfer/Adapter/AbstractTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/Transfer/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/File/Transfer/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/AlnumTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/AlphaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/BaseNameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/DigitsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/DirTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/File/LowerCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/File/RenameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/File/UpperCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/HtmlEntitiesTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/InflectorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/InputTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/IntTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/PregReplaceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/RealPathTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StringToLowerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StringToUpperTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StringTrimTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StripNewlinesTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/StripTagsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/CamelCaseToDashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/CamelCaseToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/CamelCaseToUnderscoreTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/DashToCamelCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/DashToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/DashToUnderscoreTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/SeparatorToCamelCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/SeparatorToDashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/SeparatorToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToCamelCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToDashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToPathSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/Word/UnderscoreToSeparatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/TestNamespace/MyDigits.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/TestNamespace/StringEquals.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/_testDir2/.placeholder +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/file.1 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/testfile.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Filter/_files/testfile2.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/FilterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/AbstractTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/CallbackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/DescriptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ErrorsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FieldsetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FormErrorsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/HtmlTagTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/LabelTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/PrepareElementsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ViewHelperTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Decorator/ViewScriptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/DisplayGroupTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/ButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/CaptchaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/CheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/HashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/HiddenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/ImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/MultiCheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/MultiselectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/PasswordTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/RadioTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/ResetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/SelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/SubmitTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/TextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/TextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/TransferAdapter/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/filter/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/validator/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/ElementTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/SubFormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/multiOptions.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/multiOptions.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/zf3213.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/config/zf3250.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/decorators/Label.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/decorators/TableRow.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/locale/array.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/contentWrappingDecorator.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/decorator.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/decoratorCausesReplacement.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Form/_files/views/replacingDecorator.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/AuthorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/BaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/CaptchaRequiredExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/CategoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/ContentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/ControlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/EntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/FeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/GeneratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/HttpExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/MockBase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/UtilTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/AuthorElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/CategoryElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/ContentElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/ContentElementSample2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/ControlElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/EntrySample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/EntrySampleHttp1.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/FeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files/GeneratorElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AppTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AttendeeStatusTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AttendeeTypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/AuthSubTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/CollectionEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/CollectionFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/VolumeEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/VolumeFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/_files/VolumeEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Books/_files/VolumeFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/BooksOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/BooksTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/AccessLevelTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/ColorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/EventEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/EventQueryExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/EventQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/HiddenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/LinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/QuickAddTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/SelectedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/SendEventNotificationsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/TimezoneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/WebContentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/AccessLevelElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/ColorElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/EventEntrySample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/EventFeedCompositeSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/HiddenElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/LinkElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/ListFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/QuickAddElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/SelectedElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/SendEventNotificationsElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/TestDataEventFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/TimezoneElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files/WebContentElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarEventTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarFeedCompositeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CalendarTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/CommentsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/DocumentListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/DocumentListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/_files/TestDataDocumentListEntrySample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/_files/TestDataDocumentListFeedSample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/DocsOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/DocsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/EntryLinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/EntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/EventStatusTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/ExtendedPropertyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/FeedLinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/FeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListRecipientEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListRecipientFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListRecipientQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/EmailListTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/ErrorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/LoginTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/NicknameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/QuotaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/ServiceExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/UserEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/UserFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/UserQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/AppsForYourDomainElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListRecipientEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/EmailListRecipientFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/LoginElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NameElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NicknameElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NicknameEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/NicknameFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/QuotaElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/UserEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files/UserFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GappsOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GappsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/BaseAttributeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/ItemEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/ItemFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/ItemQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/SnippetFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/SnippetQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/_files/TestDataGbaseItemFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/_files/TestDataGbaseSnippetFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GbaseOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GdataOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/GdataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/ProfileEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/ProfileFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/ProfileListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_allergy0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_allergy1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_allergy_all.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_condition0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_condition1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_condition_all.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_just_ccr.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications3.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_medications_all.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileEntrySample_results0.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileFeedSample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/TestDataHealthProfileListEntrySample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files/ccr_notice_sample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/HealthOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OpenSearchItemsPerPageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OpenSearchStartIndexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OpenSearchTotalResultsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/OriginalEventTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosAlbumEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosAlbumFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosAlbumQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosCommentEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosPhotoEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosPhotoFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosPhotoQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosTagEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosUserEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosUserFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/PhotosUserQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestAlbumEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestAlbumFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestCommentEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestPhotoEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestPhotoFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestTagEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestUserEntry.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/TestUserFeed.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files/test.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/PhotosOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/QueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/RecurrenceExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/RecurrenceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/ReminderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CellTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ColCountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/CustomTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/DocumentQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/ListQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/RowCountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/SpreadsheetFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/WorksheetEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/WorksheetFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataCellFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataListFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataSpreadsheetFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files/TestDataWorksheetFeedSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/SpreadsheetsOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/SpreadsheetsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/TestUtility/MockHttpClient.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/TransparencyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/VisibilityTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/WhenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/WhereTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/WhoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/CommentEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/CommentFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/ContactEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/ContactFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistListEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistListFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistVideoEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/PlaylistVideoFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/SubscriptionEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/SubscriptionFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/UserProfileEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/VideoEntryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/VideoFeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/VideoQueryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/CommentEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/CommentFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/ContactEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/ContactFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/FormUploadTokenResponseSample.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListFeedDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistListVideoEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistVideoEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistVideoEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/PlaylistVideoFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_channelV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_favoritesV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_playlistV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionEntryDataSample_queryV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/SubscriptionFeedDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/UserProfileEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/UserProfileEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoEntryDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoEntryDataSamplePrivate.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoEntryDataSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files/VideoFeedDataSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTubeOnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/YouTubeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample1.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample2.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample3.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AppSample4.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AttendeeStatusElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/AttendeeTypeElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/CommentsElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/DocsTest.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/EntryLinkElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/EntrySample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/EventStatusElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/ExtendedPropertyElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/FeedLinkElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/FeedSampleV1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/FeedSampleV2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OpenSearchItemsPerPageElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OpenSearchStartIndexElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OpenSearchTotalResultsElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/OriginalEventElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RecurrenceElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RecurrenceExceptionElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/ReminderElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RsaCert.pem +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/RsaKey.pem +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/TransparencyElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/VisibilityElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/WhenElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/WhereElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/WhoElementSample1.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Gdata/_files/testImage.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/CurlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/ProxyAdapterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SocketKeepaliveTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SocketPersistentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/SocketTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/StaticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/TestAdapterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/ZF4238-zerolineresponse.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/staticFile.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testCookies.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testGetData.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testHeaders.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testHttpAuth.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testPostData.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testRawPostData.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testRedirections.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testRelativeRedirections.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testResetParameters.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testSimpleRequests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/Client/_files/testUploads.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/CookieJarTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/CookieTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/body +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_302 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_403_nomessage +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_404 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_500 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_chunked +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_crlf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_deflate +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_gzip +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_leadingws +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_lfonly +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_multiline_header +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_unknown +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_with_cookies +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Http/_files/response_with_single_cookie +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/AssertionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/CipherTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/ProcessTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/XmlParsingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey_bad_block.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey_missing_enc_algo.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedkey_missing_encryptionmethod.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedtoken.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/encryptedtoken_bad_type.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/security_token_bad_keyref.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/signedToken.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/signedToken_bad_type.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/ssl_private.cert +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/InfoCard/_files/ssl_pub.cert +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/JsonXMLTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/CacheTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/ErrorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/RequestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/Smd/ServiceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/Server/SmdTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Json/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/JsonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/FunctionalTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/HelperTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/LayoutTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/PluginTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/MinimalCustomView.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/controllers/ZendLayoutFunctionalTestErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/controllers/ZendLayoutFunctionalTestTestController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/layouts/layout.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-error/error.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-test/index.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/helpers/FooBar.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/scripts/layout.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/scripts/layout2.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/layout.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/plugin.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/test/layout.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/BindTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/CanonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/ConnectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Ldap/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/AutoloadDoesNotHideParseError.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/AutoloadableClass.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/MyLoader.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/MyOverloader.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/PluginLoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/_files/ParseError.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/_files/ZfTest/CacheTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Loader/_files/ZfTest/FormSubmit.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/LoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/DataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/FormatTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Locale/MathTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/LocaleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/ChainingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/PriorityTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Filter/SuppressTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Formatter/SimpleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Formatter/XmlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/LogTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/DbTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/FirebugTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/MockTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/NullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Log/Writer/StreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/ImapTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/InterfaceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirFolderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirMessageOldTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MaildirWritableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MboxFolderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MboxMessageOldTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/Pop3Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/SmtpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/mail.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.maildir/maildir.tar +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox/INBOX +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox/subfolder/test +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/MailTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AccelerationTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AngleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/AreaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/BinaryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/CapacitanceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Cooking/VolumeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Cooking/WeightTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/CurrentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/DensityTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/EnergyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Flow/MassTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Flow/MoleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Flow/VolumeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/ForceTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/FrequencyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/IlluminationTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/LengthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/LightnessTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/NumberTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/PowerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/PressureTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/SpeedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/TemperatureTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/TimeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/TorqueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Viscosity/DynamicTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/Viscosity/KinematicTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/VolumeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Measure/WeightTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/AccessControllerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/LockedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/MemoryManagerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/MemoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/MovableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Memory/ValueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mime/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mime/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Mime/PartTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/MimeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ConsumerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Extension/SregTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ExtensionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/User/SessionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ProviderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenId/ResponseHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/OpenIdTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbSelect/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbTableSelect/OracleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbTableSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/IteratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/NullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/AllTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/ElasticTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/JumpingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle/SlidingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/TestTable.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/Zf4207.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/config.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/scripts/partial.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/test.sqlite +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Paginator/_files/testempty.sqlite +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/PaginatorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/DrawingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/BooleanTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/DictionaryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/NameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/NullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/NumericTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/Object/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/Object/StreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/ObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/StreamTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/String/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/String/BinaryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/Element/StringTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/ProcessingTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/pdfarchiving.pdf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/stamp.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/stamp.png +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_files/stamp.tif +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/COPYRIGHT.TXT +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/README.TXT +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/RELEASENOTES.TXT +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/Vera.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraBI.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraBd.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraIt.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMoBI.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMoBd.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMoIt.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraMono.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraSe.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts/VeraSeBd.ttf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/ConsoleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/JsPullTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter/JsPushTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ProgressBar/ProgressBarTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/RegistryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/ClientTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/ResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnArray.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnFalse.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnInt.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnNestedArray.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnObject.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnString.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnTrue.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Rest/responses/returnVoid.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/AnalysisTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/DocumentTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/FSMTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/FieldTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/DictionaryLoaderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/FieldInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/SegmentInfoPriorityQueueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/SegmentInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/SegmentMergerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/TermInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/TermTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_files/mergedSegment.cfs.sample +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_0.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_1.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_1.sti +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_2.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_3.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_3.del +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/_4.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/deletable +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files/segments +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/LuceneTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/PriorityQueueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Search23Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/SearchTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/DirectoryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/FileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_files/sample_data +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_0.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_1.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_2.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_3.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_3_1.del +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/_4.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/segments.gen +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files/segments_8 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_0.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_1.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_2.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_3.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_3.del +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/_4.cfs +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/deletable +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files/segments +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.fdt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.fdx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.fnm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.frq +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.nrm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.prx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.tii +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/_6.tis +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/segments.gen +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles/segments_8 +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/about-pear.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/authors.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.bugs.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.documentation.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.newpackage.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.patches.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/contributing.wishlist.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/copyright.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files/core.html +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test.docx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test.pptx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test.xlsx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test2.docx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments/test3.docx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/DefinitionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/CallbackTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/DefinitionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/ParameterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Method/PrototypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/ClassTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/FunctionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/MethodTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/NodeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/ParameterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/PrototypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/Reflection/ReturnValueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Server/ReflectionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/AkismetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Amazon/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Amazon/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Amazon/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/AlbumDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/ArtistTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/AudioscrobblerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/GroupTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/ProfileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/TagDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/TrackDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/_files/errorNoUserExists +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/_files/errorResponseStatusError +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/PostTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/PrivateDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/PublicDataTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/SimplePostTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Delicious/SkipTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883923.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883924.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883929.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427883930.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884394.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884398.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884401.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427884403.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_427887192.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic-result_428222530.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosBasic.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testGroupPoolGetPhotosExceptionGroupIdInvalid.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883923.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883924.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883929.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427883930.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884394.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884398.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884401.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427884403.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_427887192.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic-result_428222530.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testTagSearchBasic.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testUserSearchExceptionEmailInvalid.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files/testUserSearchExceptionUsernameInvalid.response +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/ExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/FunctionalTestCase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/Namespace/BaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/Namespace/ImfsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/NirvanixTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/MailHideTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/ReCaptchaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/SimpyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/SlideShare/_files/demo.ppt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/SlideShareTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/BaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/DecoratorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/ExceptionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/NoSoapTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/SalesUseTaxBasicTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/StrikeIronTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/USAddressVerificationTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron/ZipCodeInfoTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/AuthorTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/BlogInfoResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/CosmosResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/CosmosResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/DailyCountsResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/DailyCountsResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/GetInfoResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/KeyInfoResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/ResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/ResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/SearchResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/SearchResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagsResultSetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TagsResultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TechnoratiTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/TestCase.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/UtilsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/WeblogTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/MISSING +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestAuthor.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestAuthorNullFields.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoErrorUrlNotWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoResult.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoResultUrlWithInvalidSchema.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogInfoSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogPostTagsError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogPostTagsErrorUrlNotWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestBlogPostTagsSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogLink.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogLinkClaim.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogWeblogClaim.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetBlogWeblogClaim2.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteLink.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteUrlWithInvalidSchema.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosResultSetSiteWeblogWithMissingInboundblogs.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestCosmosSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestDailyCountsError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestDailyCountsResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestDailyCountsSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestGetInfoError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestGetInfoResult.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestGetInfoSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestKeyInfoError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestKeyInfoResult.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestKeyInfoSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestSearchResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestSearchSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTagsResultSet.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTopTagsError.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestTopTagsSuccess.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestWeblog.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files/TestWeblogTwoAuthors.xml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/TwitterSearchTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/TwitterTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Yahoo/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Yahoo/OfflineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Service/Yahoo/OnlineTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/README.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SaveHandler/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SaveHandler/DbTableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SessionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Session/SessionTestHelper.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/AutoDiscoverTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/ClientTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/Wsdl/ArrayOfTypeComplexStrategyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/Wsdl/ArrayOfTypeSequenceStrategyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/WsdlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/_files/cert_file +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/_files/commontypes.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/_files/wsdl_example.wsdl +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Soap/schemas/wsdl.xsd +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/ControllerTestCaseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers/ErrorController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers/ZendTestPhpUnitFooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/error/error.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/zend-test-php-unit-foo/bar.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/zend-test-php-unit-foo/baz.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/bootstrap.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/CharWrapLeftToRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/CharWrapRightToLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/CorrectEncoding.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/GenerateDummies.sh +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/GzippedFont.gz +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/InvalidFont.flf +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/NoSmush.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/NoSmushRightToLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/OutputWidth50AlignRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/ParagraphOff.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/ParagraphOn.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/SmushDefault.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/SmushForced.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardAlignCenter.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardAlignLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardAlignRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardRightToLeftAlignCenter.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardRightToLeftAlignLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/StandardRightToLeftAlignRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/WordWrapLeftToRight.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/Figlet/WordWrapRightToLeft.figlet +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/FigletTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Text/TableTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/TimeSyncTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/ArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/CsvTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/GettextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/IniTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/QtTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/TbxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/TmxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/XliffTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/XmlTmTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed2.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed3.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/failed3.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/de_AT/LC_TEST/translation-de_DE.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/en_GB/LC_OTHER/translation-en_US.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/de_AT/LC_TEST/translation-de_DE.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/en_GB/LC_OTHER/translation-en_US.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/de_AT/LC_TEST/translation-de_DE.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/en_GB/LC_OTHER/translation-en_US.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/de_AT/LC_TEST/translation-de_DE.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/en_GB/LC_OTHER/translation-en_US.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/de_AT/LC_TEST/translation-de_DE.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/en_GB/LC_OTHER/translation-en_US.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/de_AT/LC_TEST/translation-de_DE.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/en_GB/LC_OTHER/translation-en_US.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/de_AT/LC_TEST/translation-de_DE.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/en_GB/LC_OTHER/translation-en_US.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/de_AT/LC_TEST/translation-de_DE.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/en_GB/LC_OTHER/translation-en_US.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/de_AT/LC_TEST/translation-de_DE.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/en_GB/LC_OTHER/translation-en_US.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_bigendian.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_empty.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.ini +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en2.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.ts +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.xliff +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_en3.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_otherdelimiter.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_otherencoding.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_otherencoding.po +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_specialchars.csv +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_withoutencoding.tbx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_withoutencoding.tmx +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/translation_withoutencoding.xmltm +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/TranslateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Uri/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Uri/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Uri/_files/testVeryLongUriZF3712.txt +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/UriTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AbstractTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AlnumTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/AlphaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/BarcodeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/BetweenTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/CcnumTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/DateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/DigitsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/EmailAddressTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/CountTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/Crc32Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExcludeExtensionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExcludeMimeTypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExistsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ExtensionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/FilesSizeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/HashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/ImageSizeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/IsCompressedTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/IsImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/Md5Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/MimeTypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/NotExistsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/Sha1Test.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/SizeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/UploadTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/badpicture.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/picture.jpg +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/test.zip +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize2.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize3.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/File/_files/testsize4.mo +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/FloatTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/GreaterThanTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/HexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/HostnameTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/IdenticalTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/InArrayTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/IntTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/IpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/LessThanTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/MessageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/NotEmptyTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/RegexTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Validate/StringLengthTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ValidateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/VersionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/ActionTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/DeclareVarsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/DoctypeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FieldsetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormButtonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormCheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormErrorsTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormFileTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormImageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormLabelTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormMultiCheckboxTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormPasswordTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormRadioTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormResetTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormSelectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormSubmitTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormTextTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/FormTextareaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadLinkTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadMetaTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadScriptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadStyleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HeadTitleTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlFlashTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlListTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlObjectTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlPageTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/HtmlQuicktimeTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/InlineScriptTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/JsonTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/LayoutTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PaginationControlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PartialLoopTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PartialTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder/ContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder/RegistryTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder/StandaloneContainerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/PlaceholderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/RenderToPlaceholderTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/TranslateTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/UrlTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/controllers/BarController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/controllers/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/bar/baz.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/foo/bar.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/foo/baz.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialActionCall.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialLoop.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialLoopCouter.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialLoopObject.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialObj.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialOne.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialThree.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/partialVars.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/controllers/BazController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/controllers/FooController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz/bar-one.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz/bar-three.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz/bar-two.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo/bar.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo/nest.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo/nested.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/partialLoop.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/partialTwo.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/scripts/rendertoplaceholderscript.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/scripts/testPagination.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/FilterDir1/Foo.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir1/Stub1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir1/StubEmpty.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2/Datetime.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2/Stub1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2/Stub2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/test.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testParent.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testStrictVars.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testSubTemplate.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/View/_templates/testZf995.phtml +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/ViewTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Wildfire/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Wildfire/WildfireTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/Wildfire/_files/IndexController.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/AllTests.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ClientTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/FaultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/Request/HttpTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/RequestTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ResponseTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/Server/CacheTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/Server/FaultTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ServerTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/XmlRpc/ValueTest.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class1/Subclass2.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class3.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class4.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/ClassNonexistent.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Interface1.php +%%PORTEXAMPLES%%%%EXAMPLESDIR%%/tests/Zend/_files/_testDir2/Class2.php +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files/_testDir2 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files/_testDir1/Class1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files/_testDir1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/XmlRpc/Server +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/XmlRpc/Request +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/XmlRpc +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Wildfire/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Wildfire +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_templates +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir2 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs/HelperDir1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs/FilterDir1 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/_stubs +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts/baz +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts/bar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules/default +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files/modules +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper/Placeholder +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View/Helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/View +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Validate/File/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Validate/File +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Validate +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Uri/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Uri +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxmltm +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testxliff +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtmx +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testtbx +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testmo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testini +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testcsv +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/en_GB/LC_OTHER +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/en_GB +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/de_AT/LC_TEST +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray/de_AT +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files/testarray +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Translate +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Text/Figlet +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Text +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/zend-test-php-unit-foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap/schemas +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap/Wsdl +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Soap +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Session/SaveHandler +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Session +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Yahoo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Technorati/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Technorati +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/StrikeIron +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/SlideShare/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/SlideShare +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/ReCaptcha +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix/Namespace +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Nirvanix +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Flickr/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Flickr +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Delicious +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Audioscrobbler +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service/Amazon +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Service +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Server/Reflection +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Server/Method +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Server +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_openXmlDocuments +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSource +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_nonCompoundIndexFiles +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_indexSample +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index23Sample +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_tempFiles/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_tempFiles +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_source +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search/Lucene +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Search +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Rest/responses +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Rest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/ProgressBar/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/ProgressBar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/_fonts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/Element/String +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/Element/Object +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf/Element +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Pdf +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/_files/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/ScrollingStyle +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbTableSelect +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter/DbSelect +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Paginator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/User +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Provider +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Extension +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/OpenId +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mime +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Memory/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Memory +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure/Viscosity +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure/Flow +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure/Cooking +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Measure +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox/subfolder +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.mbox +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files/test.maildir +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Mail +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log/Writer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log/Formatter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log/Filter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Log +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Loader/_files/ZfTest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Loader/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Loader +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Ldap +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts/test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/filters +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts/zend-layout-functional-test-error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/layouts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files/functional-test-app +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Layout +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Json/Server/Smd +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Json/Server +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Json +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/InfoCard/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/InfoCard +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http/Client/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http/Client +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Http +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/YouTube +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/TestUtility +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Spreadsheets +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Photos/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Photos +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Health/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Health +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gbase +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Gapps +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Docs/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Docs +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Calendar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Books/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/Books +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/App/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata/App +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Gdata +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/decorators +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files/config +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/validator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/filter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files/TransferAdapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Element +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form/Decorator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Form +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/_files/_testDir2 +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/_files/TestNamespace +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/Word +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter/File +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Filter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/File/Transfer/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/File/Transfer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/File +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Feed/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Feed/Entry +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Feed +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dom/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dom/Query +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dom +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/View/Helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/View +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/_files/locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Element +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form/Decorator +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo/Form +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Dojo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/TestUtil/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/TestUtil +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Select/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Select +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Rowset +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Row/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Row +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Relationships +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Table +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Statement/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Statement +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Select/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Select +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Profiler/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Profiler +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Testnamespace +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files/Test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter/Pdo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Db +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Date +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/view +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/foo-bar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts/custom +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views/filters +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts/admin/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts/admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers/Admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/foo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts/admin/helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts/admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/controllers/Admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/default +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/test +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/filters +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/Helpers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files/Admin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Router/Route +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Router +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Response +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Request +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Plugin +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Dispatcher +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Action/HelperBroker +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Action/Helper +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller/Action +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Controller +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Console +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/Writer/temp +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/Writer/files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config/Writer +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Config +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Captcha +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Cache +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Ldap +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http/Resolver +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Http +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Digest/_files +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/Digest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable/BasicSqliteTest +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/DbTable +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth/Adapter +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Auth +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Value +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Util +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Response/mock +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Response +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Request/mock +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf/Request +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend/Amf +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests/Zend +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/tests +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Log-Writer-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot/Zend-Db-Profiler-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public/Boot +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/public +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-wildfire-plugin-firephp +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-log-writer-firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/zend-db-profiler-firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts/error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Log-Writer-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot/Zend-Db-Profiler-Firebug +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers/Boot +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire/application +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Wildfire +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Yahoo +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Protocols +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Flickr +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices/Amazon +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/WebServices +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing/IndexSource +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene/indexing +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene/feed-search +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search/Lucene +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Search +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/ProgressBar +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Pdf +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/templates +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/html +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/index +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts/error +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views/scripts +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/views +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application/controllers +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth/application +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId/mvc_auth +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/OpenId +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail/mbox/subfolder +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail/mbox +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail/maildir +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Mail +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Locale +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoBrowser +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/YouTubeVideoApp +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/MyLibrary +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata/BooksBrowser +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Gdata +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend/Feeds +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos/Zend +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%%/demos +%%PORTEXAMPLES%%@dirrm %%EXAMPLESDIR%% + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Value + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Server + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Response + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Request + at dirrm %%DATADIR%%/library/Zend/XmlRpc/Client + at dirrm %%DATADIR%%/library/Zend/XmlRpc + at dirrm %%DATADIR%%/library/Zend/Wildfire/Protocol + at dirrm %%DATADIR%%/library/Zend/Wildfire/Plugin/FirePhp + at dirrm %%DATADIR%%/library/Zend/Wildfire/Plugin + at dirrm %%DATADIR%%/library/Zend/Wildfire/Channel + at dirrm %%DATADIR%%/library/Zend/Wildfire + at dirrm %%DATADIR%%/library/Zend/View/Helper/Placeholder/Registry + at dirrm %%DATADIR%%/library/Zend/View/Helper/Placeholder/Container + at dirrm %%DATADIR%%/library/Zend/View/Helper/Placeholder + at dirrm %%DATADIR%%/library/Zend/View/Helper/Partial + at dirrm %%DATADIR%%/library/Zend/View/Helper + at dirrm %%DATADIR%%/library/Zend/View + at dirrm %%DATADIR%%/library/Zend/Validate/Hostname + at dirrm %%DATADIR%%/library/Zend/Validate/File + at dirrm %%DATADIR%%/library/Zend/Validate/Barcode + at dirrm %%DATADIR%%/library/Zend/Validate + at dirrm %%DATADIR%%/library/Zend/Uri + at dirrm %%DATADIR%%/library/Zend/Translate/Adapter + at dirrm %%DATADIR%%/library/Zend/Translate + at dirrm %%DATADIR%%/library/Zend/TimeSync + at dirrm %%DATADIR%%/library/Zend/Text/Table/Decorator + at dirrm %%DATADIR%%/library/Zend/Text/Table + at dirrm %%DATADIR%%/library/Zend/Text/Figlet + at dirrm %%DATADIR%%/library/Zend/Text + at dirrm %%DATADIR%%/library/Zend/Test/PHPUnit/Constraint + at dirrm %%DATADIR%%/library/Zend/Test/PHPUnit + at dirrm %%DATADIR%%/library/Zend/Test + at dirrm %%DATADIR%%/library/Zend/Soap/Wsdl/Strategy + at dirrm %%DATADIR%%/library/Zend/Soap/Wsdl/Parser + at dirrm %%DATADIR%%/library/Zend/Soap/Wsdl + at dirrm %%DATADIR%%/library/Zend/Soap/Server + at dirrm %%DATADIR%%/library/Zend/Soap/Client + at dirrm %%DATADIR%%/library/Zend/Soap/AutoDiscover + at dirrm %%DATADIR%%/library/Zend/Soap + at dirrm %%DATADIR%%/library/Zend/Session/Validator + at dirrm %%DATADIR%%/library/Zend/Session/SaveHandler + at dirrm %%DATADIR%%/library/Zend/Session + at dirrm %%DATADIR%%/library/Zend/Service/Yahoo + at dirrm %%DATADIR%%/library/Zend/Service/Twitter + at dirrm %%DATADIR%%/library/Zend/Service/Technorati + at dirrm %%DATADIR%%/library/Zend/Service/StrikeIron + at dirrm %%DATADIR%%/library/Zend/Service/SlideShare + at dirrm %%DATADIR%%/library/Zend/Service/Simpy + at dirrm %%DATADIR%%/library/Zend/Service/ReCaptcha/MailHide + at dirrm %%DATADIR%%/library/Zend/Service/ReCaptcha + at dirrm %%DATADIR%%/library/Zend/Service/Nirvanix/Namespace + at dirrm %%DATADIR%%/library/Zend/Service/Nirvanix + at dirrm %%DATADIR%%/library/Zend/Service/Flickr + at dirrm %%DATADIR%%/library/Zend/Service/Delicious + at dirrm %%DATADIR%%/library/Zend/Service/Amazon + at dirrm %%DATADIR%%/library/Zend/Service + at dirrm %%DATADIR%%/library/Zend/Server/Reflection/Function + at dirrm %%DATADIR%%/library/Zend/Server/Reflection + at dirrm %%DATADIR%%/library/Zend/Server/Method + at dirrm %%DATADIR%%/library/Zend/Server + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Storage/File + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Storage/Directory + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Storage + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/Weight + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/Similarity + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/QueryEntry + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search/Query + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Search + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Index/SegmentWriter + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Index + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Document + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/TokenFilter + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8Num + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Utf8 + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/TextNum + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common/Text + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer/Common + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis/Analyzer + at dirrm %%DATADIR%%/library/Zend/Search/Lucene/Analysis + at dirrm %%DATADIR%%/library/Zend/Search/Lucene + at dirrm %%DATADIR%%/library/Zend/Search + at dirrm %%DATADIR%%/library/Zend/Rest/Server + at dirrm %%DATADIR%%/library/Zend/Rest/Client/Result + at dirrm %%DATADIR%%/library/Zend/Rest/Client + at dirrm %%DATADIR%%/library/Zend/Rest + at dirrm %%DATADIR%%/library/Zend/Request + at dirrm %%DATADIR%%/library/Zend/ProgressBar/Adapter + at dirrm %%DATADIR%%/library/Zend/ProgressBar + at dirrm %%DATADIR%%/library/Zend/Pdf/Trailer + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Image + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Standard + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple/Parsed + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/Simple + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font/CidFont + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource/Font + at dirrm %%DATADIR%%/library/Zend/Pdf/Resource + at dirrm %%DATADIR%%/library/Zend/Pdf/Parser + at dirrm %%DATADIR%%/library/Zend/Pdf/Filter/Compression + at dirrm %%DATADIR%%/library/Zend/Pdf/Filter + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParserDataSource + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser/Image + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser/Font/OpenType + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser/Font + at dirrm %%DATADIR%%/library/Zend/Pdf/FileParser + at dirrm %%DATADIR%%/library/Zend/Pdf/ElementFactory + at dirrm %%DATADIR%%/library/Zend/Pdf/Element/String + at dirrm %%DATADIR%%/library/Zend/Pdf/Element/Reference + at dirrm %%DATADIR%%/library/Zend/Pdf/Element/Object + at dirrm %%DATADIR%%/library/Zend/Pdf/Element + at dirrm %%DATADIR%%/library/Zend/Pdf/Color + at dirrm %%DATADIR%%/library/Zend/Pdf/Cmap/ByteEncoding + at dirrm %%DATADIR%%/library/Zend/Pdf/Cmap + at dirrm %%DATADIR%%/library/Zend/Pdf + at dirrm %%DATADIR%%/library/Zend/Paginator/ScrollingStyle + at dirrm %%DATADIR%%/library/Zend/Paginator/Adapter + at dirrm %%DATADIR%%/library/Zend/Paginator + at dirrm %%DATADIR%%/library/Zend/OpenId/Provider/User + at dirrm %%DATADIR%%/library/Zend/OpenId/Provider/Storage + at dirrm %%DATADIR%%/library/Zend/OpenId/Provider + at dirrm %%DATADIR%%/library/Zend/OpenId/Extension + at dirrm %%DATADIR%%/library/Zend/OpenId/Consumer/Storage + at dirrm %%DATADIR%%/library/Zend/OpenId/Consumer + at dirrm %%DATADIR%%/library/Zend/OpenId + at dirrm %%DATADIR%%/library/Zend/Mime + at dirrm %%DATADIR%%/library/Zend/Memory/Container + at dirrm %%DATADIR%%/library/Zend/Memory + at dirrm %%DATADIR%%/library/Zend/Measure/Viscosity + at dirrm %%DATADIR%%/library/Zend/Measure/Flow + at dirrm %%DATADIR%%/library/Zend/Measure/Cooking + at dirrm %%DATADIR%%/library/Zend/Measure + at dirrm %%DATADIR%%/library/Zend/Mail/Transport + at dirrm %%DATADIR%%/library/Zend/Mail/Storage/Writable + at dirrm %%DATADIR%%/library/Zend/Mail/Storage/Folder + at dirrm %%DATADIR%%/library/Zend/Mail/Storage + at dirrm %%DATADIR%%/library/Zend/Mail/Protocol/Smtp/Auth + at dirrm %%DATADIR%%/library/Zend/Mail/Protocol/Smtp + at dirrm %%DATADIR%%/library/Zend/Mail/Protocol + at dirrm %%DATADIR%%/library/Zend/Mail/Part + at dirrm %%DATADIR%%/library/Zend/Mail/Message + at dirrm %%DATADIR%%/library/Zend/Mail + at dirrm %%DATADIR%%/library/Zend/Log/Writer + at dirrm %%DATADIR%%/library/Zend/Log/Formatter + at dirrm %%DATADIR%%/library/Zend/Log/Filter + at dirrm %%DATADIR%%/library/Zend/Log + at dirrm %%DATADIR%%/library/Zend/Locale/Math + at dirrm %%DATADIR%%/library/Zend/Locale/Data + at dirrm %%DATADIR%%/library/Zend/Locale + at dirrm %%DATADIR%%/library/Zend/Loader/PluginLoader + at dirrm %%DATADIR%%/library/Zend/Loader + at dirrm %%DATADIR%%/library/Zend/Ldap + at dirrm %%DATADIR%%/library/Zend/Layout/Controller/Plugin + at dirrm %%DATADIR%%/library/Zend/Layout/Controller/Action/Helper + at dirrm %%DATADIR%%/library/Zend/Layout/Controller/Action + at dirrm %%DATADIR%%/library/Zend/Layout/Controller + at dirrm %%DATADIR%%/library/Zend/Layout + at dirrm %%DATADIR%%/library/Zend/Json/Server/Smd + at dirrm %%DATADIR%%/library/Zend/Json/Server/Response + at dirrm %%DATADIR%%/library/Zend/Json/Server/Request + at dirrm %%DATADIR%%/library/Zend/Json/Server + at dirrm %%DATADIR%%/library/Zend/Json + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Security/Transform + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Security + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/KeyInfo + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/EncryptedData + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Element + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml/Assertion + at dirrm %%DATADIR%%/library/Zend/InfoCard/Xml + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes256cbc + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Aes128cbc + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric/Adapter + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Symmetric + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Rsa + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Pki/Adapter + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher/Pki + at dirrm %%DATADIR%%/library/Zend/InfoCard/Cipher + at dirrm %%DATADIR%%/library/Zend/InfoCard/Adapter + at dirrm %%DATADIR%%/library/Zend/InfoCard + at dirrm %%DATADIR%%/library/Zend/Http/Client/Adapter + at dirrm %%DATADIR%%/library/Zend/Http/Client + at dirrm %%DATADIR%%/library/Zend/Http + at dirrm %%DATADIR%%/library/Zend/Gdata/YouTube/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/YouTube + at dirrm %%DATADIR%%/library/Zend/Gdata/Spreadsheets/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Spreadsheets + at dirrm %%DATADIR%%/library/Zend/Gdata/Photos/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Photos + at dirrm %%DATADIR%%/library/Zend/Gdata/Media/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Media + at dirrm %%DATADIR%%/library/Zend/Gdata/Kind + at dirrm %%DATADIR%%/library/Zend/Gdata/Health/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Health + at dirrm %%DATADIR%%/library/Zend/Gdata/Geo/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Geo + at dirrm %%DATADIR%%/library/Zend/Gdata/Gbase/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Gbase + at dirrm %%DATADIR%%/library/Zend/Gdata/Gapps/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Gapps + at dirrm %%DATADIR%%/library/Zend/Gdata/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Exif/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Exif + at dirrm %%DATADIR%%/library/Zend/Gdata/DublinCore/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/DublinCore + at dirrm %%DATADIR%%/library/Zend/Gdata/Docs + at dirrm %%DATADIR%%/library/Zend/Gdata/Calendar/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Calendar + at dirrm %%DATADIR%%/library/Zend/Gdata/Books/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/Books + at dirrm %%DATADIR%%/library/Zend/Gdata/App/Extension + at dirrm %%DATADIR%%/library/Zend/Gdata/App + at dirrm %%DATADIR%%/library/Zend/Gdata + at dirrm %%DATADIR%%/library/Zend/Form/Element + at dirrm %%DATADIR%%/library/Zend/Form/Decorator/Captcha + at dirrm %%DATADIR%%/library/Zend/Form/Decorator + at dirrm %%DATADIR%%/library/Zend/Form + at dirrm %%DATADIR%%/library/Zend/Filter/Word/Separator + at dirrm %%DATADIR%%/library/Zend/Filter/Word + at dirrm %%DATADIR%%/library/Zend/Filter/File + at dirrm %%DATADIR%%/library/Zend/Filter + at dirrm %%DATADIR%%/library/Zend/File/Transfer/Adapter + at dirrm %%DATADIR%%/library/Zend/File/Transfer + at dirrm %%DATADIR%%/library/Zend/File + at dirrm %%DATADIR%%/library/Zend/Feed/Entry + at dirrm %%DATADIR%%/library/Zend/Feed/Builder/Header + at dirrm %%DATADIR%%/library/Zend/Feed/Builder + at dirrm %%DATADIR%%/library/Zend/Feed + at dirrm %%DATADIR%%/library/Zend/Dom/Query + at dirrm %%DATADIR%%/library/Zend/Dom + at dirrm %%DATADIR%%/library/Zend/Dojo/View/Helper/Dojo + at dirrm %%DATADIR%%/library/Zend/Dojo/View/Helper + at dirrm %%DATADIR%%/library/Zend/Dojo/View + at dirrm %%DATADIR%%/library/Zend/Dojo/Form/Element + at dirrm %%DATADIR%%/library/Zend/Dojo/Form/Decorator + at dirrm %%DATADIR%%/library/Zend/Dojo/Form + at dirrm %%DATADIR%%/library/Zend/Dojo + at dirrm %%DATADIR%%/library/Zend/Db/Table/Select + at dirrm %%DATADIR%%/library/Zend/Db/Table/Rowset + at dirrm %%DATADIR%%/library/Zend/Db/Table/Row + at dirrm %%DATADIR%%/library/Zend/Db/Table + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Pdo + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Oracle + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Mysqli + at dirrm %%DATADIR%%/library/Zend/Db/Statement/Db2 + at dirrm %%DATADIR%%/library/Zend/Db/Statement + at dirrm %%DATADIR%%/library/Zend/Db/Select + at dirrm %%DATADIR%%/library/Zend/Db/Profiler + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Pdo/Ibm + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Pdo + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Oracle + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Mysqli + at dirrm %%DATADIR%%/library/Zend/Db/Adapter/Db2 + at dirrm %%DATADIR%%/library/Zend/Db/Adapter + at dirrm %%DATADIR%%/library/Zend/Db + at dirrm %%DATADIR%%/library/Zend/Date + at dirrm %%DATADIR%%/library/Zend/Currency + at dirrm %%DATADIR%%/library/Zend/Controller/Router/Route + at dirrm %%DATADIR%%/library/Zend/Controller/Router + at dirrm %%DATADIR%%/library/Zend/Controller/Response + at dirrm %%DATADIR%%/library/Zend/Controller/Request + at dirrm %%DATADIR%%/library/Zend/Controller/Plugin + at dirrm %%DATADIR%%/library/Zend/Controller/Dispatcher + at dirrm %%DATADIR%%/library/Zend/Controller/Action/HelperBroker + at dirrm %%DATADIR%%/library/Zend/Controller/Action/Helper/AutoComplete + at dirrm %%DATADIR%%/library/Zend/Controller/Action/Helper + at dirrm %%DATADIR%%/library/Zend/Controller/Action + at dirrm %%DATADIR%%/library/Zend/Controller + at dirrm %%DATADIR%%/library/Zend/Console/Getopt + at dirrm %%DATADIR%%/library/Zend/Console + at dirrm %%DATADIR%%/library/Zend/Config/Writer + at dirrm %%DATADIR%%/library/Zend/Config + at dirrm %%DATADIR%%/library/Zend/Captcha + at dirrm %%DATADIR%%/library/Zend/Cache/Frontend + at dirrm %%DATADIR%%/library/Zend/Cache/Backend + at dirrm %%DATADIR%%/library/Zend/Cache + at dirrm %%DATADIR%%/library/Zend/Auth/Storage + at dirrm %%DATADIR%%/library/Zend/Auth/Adapter/Http/Resolver + at dirrm %%DATADIR%%/library/Zend/Auth/Adapter/Http + at dirrm %%DATADIR%%/library/Zend/Auth/Adapter + at dirrm %%DATADIR%%/library/Zend/Auth + at dirrm %%DATADIR%%/library/Zend/Amf/Value/Messaging + at dirrm %%DATADIR%%/library/Zend/Amf/Value + at dirrm %%DATADIR%%/library/Zend/Amf/Util + at dirrm %%DATADIR%%/library/Zend/Amf/Server + at dirrm %%DATADIR%%/library/Zend/Amf/Response + at dirrm %%DATADIR%%/library/Zend/Amf/Request + at dirrm %%DATADIR%%/library/Zend/Amf/Parse/Amf3 + at dirrm %%DATADIR%%/library/Zend/Amf/Parse/Amf0 + at dirrm %%DATADIR%%/library/Zend/Amf/Parse + at dirrm %%DATADIR%%/library/Zend/Amf + at dirrm %%DATADIR%%/library/Zend/Acl/Role/Registry + at dirrm %%DATADIR%%/library/Zend/Acl/Role + at dirrm %%DATADIR%%/library/Zend/Acl/Resource + at dirrm %%DATADIR%%/library/Zend/Acl/Assert + at dirrm %%DATADIR%%/library/Zend/Acl + at dirrm %%DATADIR%%/library/Zend + at dirrm %%DATADIR%%/library +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project/_files/project1 +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project/_files +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project/Context +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Project +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/Framework +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/_files +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Tool +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection/_files +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection/Docblock/Tag +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend/Reflection +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests/Zend +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/tests +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Structure +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Provider +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Resource +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/Iterator +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile/FileParser +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Profile +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Zf +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context/System +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context/Filesystem +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project/Context +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Project +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Provider +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/System/Action +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/System +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Provider +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Manifest +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader/IncludePathLoader +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Loader +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Client/Cli +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework/Client +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/Framework +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Member +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock/Tag +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Php +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator/Apache +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool/CodeGenerator +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Tool +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Reflection/Docblock/Tag +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Reflection/Docblock +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Reflection +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend/Console +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library/Zend +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/library +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator/bin +%%INCUBATOR%%@dirrm %%DATADIR%%/incubator +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/shrinksafe +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo/src/main/assembly +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo/src/main +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/webapp/WEB-INF +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/webapp +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java/org/dojotoolkit +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java/org +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main/java +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src/main +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo-war +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven/dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/maven +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh/robot +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh/_sounds +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/doh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Root +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder/Global +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps/builder +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma/apps +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild/helma +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/webbuild +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests/profiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests/foo/page +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests/foo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/profiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/jslib/packer +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/jslib +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/cldr/lib +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/cldr/ldml +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts/cldr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util/buildscripts +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/util +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xmpp/widget/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xmpp/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xmpp +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/xml +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/wire/ml +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/wire +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Wizard +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Toaster +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/SortList +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/RollingList +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Pager/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Pager +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Loader/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Loader +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/FisheyeList +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/FilePicker/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/FilePicker +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/DocTester +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Dialog/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Dialog +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/ColorPicker/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/ColorPicker +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget/Calendar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/validate +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/uuid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/timing +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/testing +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/string +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/storage +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sql +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sketch/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sketch/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/sketch +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/secure +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/rpc/SMDLibrary +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/rpc +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/robot +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/presentation/resources/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/presentation/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/presentation +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/off/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/off/docs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/off +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/math +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/resources/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/nls/en +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout/dnd +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/lang/functional +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/lang/aspect +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/lang +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/jsonPath +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/json +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/io/proxy/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/io/proxy +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/io +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/image/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/image/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/image +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/html +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/resources/pygments +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/languages/pygments +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight/languages +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/highlight +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/help +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/tests/support +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/tests/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/_grid/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/_grid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat/_data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/compat +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/cells +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid/_grid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/grid +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/gfx3d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/gfx/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/gfx +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/fx/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/fx/ext-dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/fx +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/flash +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding/digests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding/crypto +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding/compression +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/encoding +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/embed/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/embed/IE +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/embed +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor/plugins +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/editor +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/utils +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/tag +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/render +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/filter +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/ext-dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl/contrib +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/dtl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/date +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/data/s3 +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/cometd +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/color +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/collections +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/themes/PlotKit +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/themes/ET +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/themes +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/scaler +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/plot3d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/plot2d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/axis2d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting/action2d +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/charting +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/widget/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/widget/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/widget +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/av +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/profiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/plugins +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/logger/logs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics/logger +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox/analytics +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojox +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/rpc +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/resources/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/io +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/fx +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/dnd +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/date +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/data/util +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/data/api +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/zh-cn +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/pt-br +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ko-kr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ja-jp +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/it-it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/es-es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-us +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-gb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en-au +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/en +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/de-de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/cldr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/_firebug +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/_base/_loader +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo/_base +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/tundra +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/themeTesterImages +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/soria +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/noir/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/noir +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/nihilo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes/a11y +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/themes +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/tests/_data +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/layout/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/layout +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/templates +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_tree +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/plugins +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/zh-tw +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/tr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/th +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/sv +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/sl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/sk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ru +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/pt-pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/pt +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/pl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/nl +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/nb +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ko +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ja +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/it +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/hu +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/he +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/fi +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/es +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/el +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/de +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/da +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/cs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ca +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls/ar +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_editor +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit/_base +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/dijit +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video/media/thumbs +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video/media +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/video +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/uploader/UploadedFiles +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/uploader +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/images/users +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew/cache +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/skew +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/resources/silk/icons +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/resources/silk +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls/zh +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls/fr +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls/en +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao/nls +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/nihao +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mojo/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mojo/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mojo +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/mail +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/i18n +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/form +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts/resources +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts/img +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/fonts +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards/src/tests +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards/src +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/flashCards +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/castle/images +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos/castle +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo/demos +%%DOJO%%@dirrm %%DATADIR%%/externals/dojo +%%DOJO%%@dirrm %%DATADIR%%/externals + at dirrm %%DATADIR%% +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Test/PHPUnit/_files/application/views/scripts/index +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_index/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Search/Lucene/Storage/_tempFiles/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/OpenId/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/OpenId/Provider/Storage/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/OpenId/Consumer/Storage/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Memory/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Layout/_files/layouts-basepath/filters +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Db/Table/_files +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/views/helpers +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/views/filters +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/helpers +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Controller/_files/modules/bar/views/filters +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Config/Writer/temp +%%PORTEXAMPLES%%@exec mkdir -p %D/%%EXAMPLESDIR%%/tests/Zend/Auth/Adapter/OpenId/_files +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/tests/Zend/Tool/Project/_files/project1 +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/tests/Zend/Tool/Framework +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/tests/Zend/Tool/CodeGenerator/Php/Docblock +%%INCUBATOR%%@exec mkdir -p %D/%%DATADIR%%/incubator/library/Zend/Tool/Project/Structure +%%DOJO%%@exec mkdir -p %D/%%DATADIR%%/externals/dojo/dojox/analytics/logger/logs +%%DOJO%%@exec mkdir -p %D/%%DATADIR%%/externals/dojo/demos/uploader/UploadedFiles +%%DOJO%%@exec mkdir -p %D/%%DATADIR%%/externals/dojo/demos/skew/cache --- /dev/null +++ www/zend-framework/Makefile @@ -0,0 +1,140 @@ +# $MidnightBSD: mports/www/zend-framework/Makefile,v 1.1 2009/01/29 17:52:55 laffer1 Exp $ + +PORTNAME= ZendFramework +PORTVERSION= 1.7.3 +CATEGORIES= www +MASTER_SITES= http://framework.zend.com/releases/${DISTNAME}/ GENTOO/distfiles + +MAINTAINER= ports at MidnightBSD.org +COMMENT= A framework for developing PHP web applications +LICENSE= unknown + +NO_BUILD= yes +USE_PHP= spl +WANT_PHP_WEB= yes +USE_GETTEXT= yes + +SUB_FILES= pkg-message + +OPTIONS= \ + EDOJO "Install embedded Dojo" On \ + PDOJO "Install Dojo from ports" Off \ + INCUBATOR "Install incubator classes" Off \ + MYSQL "Install MySQL PDO support" Off \ + MYSQLI "Install MySQLi support" Off \ + DBLIB "Install DBLIB PDO support" Off \ + PGSQL "Install PostgreSQL PDO support" Off \ + ODBC "Install ODBC PDO support" Off \ + SQLITE "Install SQLite v3 PDO support" Off \ + REQPHP "Install required PHP dependencies" On \ + OPTPHP "Install optional PHP dependencies" Off + +#OCI "Install Oracle OCI 8 PDO support" Off \ + +.if !defined(NOPORTDOCS) +PORTDOCS= INSTALL.txt README.txt +.endif + +.include + +# Check for mutually-exclusive options +.if defined(WITH_EDOJO) && defined(WITH_PDOJO) +IGNORE= please select only one type of Dojo installation +.endif + +INSTALL_DIRS= library + +.if defined(WITH_EDOJO) +DOJO= "" +INSTALL_DIRS+= externals +CONFLICTS+= dojo-1.* +.else +DOJO= "@comment " +.endif +PLIST_SUB+= DOJO=${DOJO} + +.if defined(WITH_INCUBATOR) +INCUBATOR= "" +INSTALL_DIRS+= incubator +.else +INCUBATOR= "@comment " +.endif +PLIST_SUB+= INCUBATOR=${INCUBATOR} + +.if defined(WITH_PDOJO) +RUN_DEPENDS+= dojo>=0:${PORTSDIR}/www/dojo +.endif + +# Add all of the required and/or optional PHP extension dependencies, +# if chosen by the user. +# +# See http://framework.zend.com/manual/en/requirements.extensions.html for +# a table of what PHP extensions are required for what ZF classes. + +.if defined(WITH_REQPHP) +USE_PHP+= apc ctype curl dom gd hash iconv mbstring \ + memcache pdo session simplexml soap xml zlib +.endif +.if defined(WITH_OPTPHP) +USE_PHP+= bcmath bitset json posix +.endif + +.if defined(WITH_MYSQL) +USE_PHP+= pdo_mysql +.endif + +.if defined(WITH_MYSQLI) +USE_PHP+= mysqli +.endif + +.if defined(WITH_DBLIB) +RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_dblib.so:${PORTSDIR}/databases/php5-pdo_dblib +.endif + +.if defined(WITH_PGSQL) +RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_pgsql.so:${PORTSDIR}/databases/php5-pdo_pgsql +.endif + +#.if defined(WITH_OCI) +#RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_oci.so:${PORTSDIR}/databases/php5-pdo_oci +#.endif + +.if defined(WITH_ODBC) +RUN_DEPENDS+= ${LOCALBASE}/lib/php/${PHP_EXT_DIR}/pdo_odbc.so:${PORTSDIR}/databases/php5-pdo_odbc +.endif + +.if defined(WITH_SQLITE) +USE_PHP+= pdo_sqlite +.endif + +do-install: + @cd ${WRKSRC} && ${COPYTREE_SHARE} "${INSTALL_DIRS}" ${DATADIR} + @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${DATADIR} + @${ECHO_CMD} '@exec ${CHOWN} -R ${WWWOWN}:${WWWGRP} \ + ${DATADIR:S|^${PREFIX}/|%D/|}' >> ${TMPPLIST} + @${FIND} ${DATADIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 + @${ECHO_CMD} '@exec ${FIND} ${DATADIR} -type f -print0 | \ + ${XARGS} -0 ${CHMOD} 644' >> ${TMPPLIST} + @${FIND} ${DATADIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 + @${ECHO_CMD} '@exec ${FIND} ${DATADIR} -type d -print0 | \ + ${XARGS} -0 ${CHMOD} 755' >> ${TMPPLIST} +.if !defined(NOPORTEXAMPLES) + @cd ${WRKSRC} && ${COPYTREE_SHARE} "demos tests" ${EXAMPLESDIR} + @${CHOWN} -R ${WWWOWN}:${WWWGRP} ${EXAMPLESDIR} + @${ECHO_CMD} '@exec ${CHOWN} -R ${WWWOWN}:${WWWGRP} \ + ${EXAMPLESDIR:S|^${PREFIX}/|%D/|}' >> ${TMPPLIST} + @${FIND} ${EXAMPLESDIR} -type f -print0 | ${XARGS} -0 ${CHMOD} 644 + @${ECHO_CMD} '@exec ${FIND} ${EXAMPLESDIR} -type f -print0 | \ + ${XARGS} -0 ${CHMOD} 644' >> ${TMPPLIST} + @${FIND} ${EXAMPLESDIR} -type d -print0 | ${XARGS} -0 ${CHMOD} 755 + @${ECHO_CMD} '@exec ${FIND} ${EXAMPLESDIR} -type d -print0 | \ + ${XARGS} -0 ${CHMOD} 755' >> ${TMPPLIST} +.endif + +post-install: +.if !defined(NOPORTDOCS) + @${INSTALL} -d ${DOCSDIR} + @cd ${WRKSRC} && ${COPYTREE_SHARE} "${PORTDOCS}" ${DOCSDIR} +.endif + +.include --- /dev/null +++ www/zend-framework/distinfo @@ -0,0 +1,3 @@ +MD5 (ZendFramework-1.7.3.tar.gz) = 2e85be48a81d41cad72b9ababe16a806 +SHA256 (ZendFramework-1.7.3.tar.gz) = 372a3a29eb4578e0dd4f2b1a8f614648dcf5f3fc290e4088679c5ac4ce883f47 +SIZE (ZendFramework-1.7.3.tar.gz) = 21197198 --- /dev/null +++ www/zend-framework/files/pkg-message.in @@ -0,0 +1,10 @@ +Now you need to adjust PHP's include_path to contain + `%%DATADIR%%/library' + +For example, insert: + include_path = ".:%%DATADIR%%/library" + +into `%%LOCALBASE%%/etc/php.ini'. + +For more information about the Zend Framework, please visit: +http://framework.zend.com/