From owner-svn-src-stable-6@FreeBSD.ORG Sun Aug 1 09:17:05 2010 Return-Path: Delivered-To: svn-src-stable-6@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7F6EB106564A; Sun, 1 Aug 2010 09:17:05 +0000 (UTC) (envelope-from edwin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6D19F8FC16; Sun, 1 Aug 2010 09:17:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o719H53P055878; Sun, 1 Aug 2010 09:17:05 GMT (envelope-from edwin@svn.freebsd.org) Received: (from edwin@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o719H56u055870; Sun, 1 Aug 2010 09:17:05 GMT (envelope-from edwin@svn.freebsd.org) Message-Id: <201008010917.o719H56u055870@svn.freebsd.org> From: Edwin Groothuis Date: Sun, 1 Aug 2010 09:17:05 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-6@freebsd.org X-SVN-Group: stable-6 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r210722 - stable/6/share/zoneinfo X-BeenThere: svn-src-stable-6@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 6-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 01 Aug 2010 09:17:05 -0000 Author: edwin Date: Sun Aug 1 09:17:05 2010 New Revision: 210722 URL: http://svn.freebsd.org/changeset/base/210722 Log: MFC of 210718, tzdata2010k: - Daylight Saving Time will not be used in Egypt during Ramadan. - Proper names for Pacific/Pohnpei and Pacific/Chuuk - Fix historical information for Finland for 1981 and 1982 - No leap-second for December 2010. - Fix historical information for Ontario (Canada) Modified: stable/6/share/zoneinfo/africa stable/6/share/zoneinfo/australasia stable/6/share/zoneinfo/backward stable/6/share/zoneinfo/europe stable/6/share/zoneinfo/leapseconds stable/6/share/zoneinfo/northamerica stable/6/share/zoneinfo/zone.tab Directory Properties: stable/6/share/zoneinfo/ (props changed) Modified: stable/6/share/zoneinfo/africa ============================================================================== --- stable/6/share/zoneinfo/africa Sun Aug 1 09:11:56 2010 (r210721) +++ stable/6/share/zoneinfo/africa Sun Aug 1 09:17:05 2010 (r210722) @@ -1,5 +1,5 @@ #
-# @(#)africa	8.26
+# @(#)africa	8.27
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 
@@ -294,8 +294,25 @@ Rule	Egypt	2007	only	-	Sep	Thu>=1	23:00s
 # and can be found by searching for "winter" in their search engine
 # (at least today).
 
+# From Alexander Krivenyshev (2010-07-20):
+# According to News from Egypt -  Al-Masry Al-Youm Egypt's cabinet has
+# decided that Daylight Saving Time will not be used in Egypt during
+# Ramadan.
+#
+# Arabic translation:
+# "Clocks to go back during Ramadan--and then forward again"
+# 
+# http://www.almasryalyoum.com/en/news/clocks-go-back-during-ramadan-and-then-forward-again
+# 
+# or
+# 
+# http://www.worldtimezone.com/dst_news/dst_news_egypt02.html
+# 
+
 Rule	Egypt	2008	only	-	Aug	lastThu	23:00s	0	-
 Rule	Egypt	2009	only	-	Aug	20	23:00s	0	-
+Rule	Egypt	2010	only	-	Aug	10	23:00s	0	-
+Rule	Egypt	2010	only	-	Sep	9	0:00s	1:00	S
 Rule	Egypt	2010	max	-	Sep	lastThu	23:00s	0	-
 
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]

Modified: stable/6/share/zoneinfo/australasia
==============================================================================
--- stable/6/share/zoneinfo/australasia	Sun Aug  1 09:11:56 2010	(r210721)
+++ stable/6/share/zoneinfo/australasia	Sun Aug  1 09:17:05 2010	(r210722)
@@ -1,5 +1,5 @@
 # 
-# @(#)australasia	8.17
+# @(#)australasia	8.18
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 
@@ -346,10 +346,10 @@ Zone Pacific/Kwajalein	11:09:20 -	LMT	19
 
 # Micronesia
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
-Zone Pacific/Truk	10:07:08 -	LMT	1901
-			10:00	-	TRUT			# Truk Time
-Zone Pacific/Ponape	10:32:52 -	LMT	1901		# Kolonia
-			11:00	-	PONT			# Ponape Time
+Zone Pacific/Chuuk	10:07:08 -	LMT	1901
+			10:00	-	CHUT			# Chuuk Time
+Zone Pacific/Pohnpei	10:32:52 -	LMT	1901		# Kolonia
+			11:00	-	PONT			# Pohnpei Time
 Zone Pacific/Kosrae	10:51:56 -	LMT	1901
 			11:00	-	KOST	1969 Oct	# Kosrae Time
 			12:00	-	KOST	1999

Modified: stable/6/share/zoneinfo/backward
==============================================================================
--- stable/6/share/zoneinfo/backward	Sun Aug  1 09:11:56 2010	(r210721)
+++ stable/6/share/zoneinfo/backward	Sun Aug  1 09:17:05 2010	(r210722)
@@ -1,5 +1,5 @@
 # 
-# @(#)backward	8.8
+# @(#)backward	8.9
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 
@@ -90,7 +90,9 @@ Link	Pacific/Chatham		NZ-CHAT
 Link	America/Denver		Navajo
 Link	Asia/Shanghai		PRC
 Link	Pacific/Pago_Pago	Pacific/Samoa
-Link	Pacific/Truk		Pacific/Yap
+Link	Pacific/Chuuk		Pacific/Yap
+Link	Pacific/Chuuk		Pacific/Truk
+Link	Pacific/Pohnpei		Pacific/Ponape
 Link	Europe/Warsaw		Poland
 Link	Europe/Lisbon		Portugal
 Link	Asia/Taipei		ROC

Modified: stable/6/share/zoneinfo/europe
==============================================================================
--- stable/6/share/zoneinfo/europe	Sun Aug  1 09:11:56 2010	(r210721)
+++ stable/6/share/zoneinfo/europe	Sun Aug  1 09:17:05 2010	(r210722)
@@ -1,5 +1,5 @@
 # 
-# @(#)europe	8.26
+# @(#)europe	8.27
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 
@@ -1013,22 +1013,47 @@ Zone	Europe/Tallinn	1:39:00	-	LMT	1880
 			2:00	EU	EE%sT
 
 # Finland
-#
+
 # From Hannu Strang (1994-09-25 06:03:37 UTC):
 # Well, here in Helsinki we're just changing from summer time to regular one,
 # and it's supposed to change at 4am...
+
+# From Janne Snabb (2010-0715):
 #
-# From Paul Eggert (2006-03-22):
-# Shanks & Pottenger say Finland has switched at 02:00 standard time
-# since 1981.  Go with Strang instead.
+# I noticed that the Finland data is not accurate for years 1981 and 1982.
+# During these two first trial years the DST adjustment was made one hour
+# earlier than in forthcoming years. Starting 1983 the adjustment was made
+# according to the central European standards.
+#
+# This is documented in Heikki Oja: Aikakirja 2007, published by The Almanac
+# Office of University of Helsinki, ISBN 952-10-3221-9, available online (in
+# Finnish) at
+#
+# 
+# http://almanakka.helsinki.fi/aikakirja/Aikakirja2007kokonaan.pdf
+# 
 #
+# Page 105 (56 in PDF version) has a handy table of all past daylight savings
+# transitions. It is easy enough to interpret without Finnish skills.
+#
+# This is also confirmed by Finnish Broadcasting Company's archive at:
+#
+# 
+# http://www.yle.fi/elavaarkisto/?s=s&g=1&ag=5&t=&a=3401
+# 
+#
+# The news clip from 1981 says that "the time between 2 and 3 o'clock does not
+# exist tonight."
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Finland	1942	only	-	Apr	3	0:00	1:00	S
 Rule	Finland	1942	only	-	Oct	3	0:00	0	-
+Rule	Finland	1981	1982	-	Mar	lastSun	2:00	1:00	S
+Rule	Finland	1981	1982	-	Sep	lastSun	3:00	0	-
 # Zone	NAME		GMTOFF	RULES	FORMAT	[UNTIL]
 Zone	Europe/Helsinki	1:39:52 -	LMT	1878 May 31
 			1:39:52	-	HMT	1921 May    # Helsinki Mean Time
-			2:00	Finland	EE%sT	1981 Mar 29 2:00
+			2:00	Finland	EE%sT	1983
 			2:00	EU	EE%sT
 
 # Aaland Is

Modified: stable/6/share/zoneinfo/leapseconds
==============================================================================
--- stable/6/share/zoneinfo/leapseconds	Sun Aug  1 09:11:56 2010	(r210721)
+++ stable/6/share/zoneinfo/leapseconds	Sun Aug  1 09:17:05 2010	(r210722)
@@ -1,5 +1,5 @@
 # 
-# @(#)leapseconds	8.9
+# @(#)leapseconds	8.10
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 
@@ -60,9 +60,9 @@ Leap	2008	Dec	31	23:59:60	+	S
 # FAX       : 33 (0) 1 40 51 22 91
 # Internet  : services.iers@obspm.fr
 #
-# Paris, 4 July 2009
+# Paris, 14 July 2010
 #
-# Bulletin C 38
+# Bulletin C 40
 #
 # To authorities responsible
 # for the measurement and
@@ -70,9 +70,9 @@ Leap	2008	Dec	31	23:59:60	+	S
 #
 # INFORMATION ON UTC - TAI
 #
-# NO positive leap second will be introduced at the end of December 2009.
+# NO positive leap second will be introduced at the end of December 2010.
 # The difference between Coordinated Universal Time UTC and the
-# International Atomic Time TAI is :		
+# International Atomic Time TAI is :
 #
 # from 2009 January 1, 0h UTC, until further notice : UTC-TAI = -34 s
 #
@@ -82,6 +82,6 @@ Leap	2008	Dec	31	23:59:60	+	S
 # will be no time step at the next possible date.
 #
 # Daniel GAMBIS
-# Director			
+# Director
 # Earth Orientation Center of IERS
 # Observatoire de Paris, France

Modified: stable/6/share/zoneinfo/northamerica
==============================================================================
--- stable/6/share/zoneinfo/northamerica	Sun Aug  1 09:11:56 2010	(r210721)
+++ stable/6/share/zoneinfo/northamerica	Sun Aug  1 09:17:05 2010	(r210722)
@@ -1,5 +1,5 @@
 # 
-# @(#)northamerica	8.31
+# @(#)northamerica	8.34
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 
@@ -1324,6 +1324,83 @@ Zone America/Montreal	-4:54:16 -	LMT	188
 # entry since our cutoff date of 1970, so we can move
 # America/Coral_Harbour to the 'backward' file.
 
+# From Mark Brader (2010-03-06):
+#
+# Currently the database has:
+#
+# # Ontario
+#
+# # From Paul Eggert (2006-07-09):
+# # Shanks & Pottenger write that since 1970 most of Ontario has been like
+# # Toronto.
+# # Thunder Bay skipped DST in 1973.
+# # Many smaller locales did not observe peacetime DST until 1974;
+# # Nipigon (EST) and Rainy River (CST) are the largest that we know of.
+#
+# In the (Toronto) Globe and Mail for Saturday, 1955-09-24, in the bottom
+# right corner of page 1, it says that Toronto will return to standard
+# time at 2 am Sunday morning (which agrees with the database), and that:
+#
+#     The one-hour setback will go into effect throughout most of Ontario,
+#     except in areas like Windsor which remains on standard time all year.
+#
+# Windsor is, of course, a lot larger than Nipigon.
+#
+# I only came across this incidentally.  I don't know if Windsor began
+# observing DST when Detroit did, or in 1974, or on some other date.
+#
+# By the way, the article continues by noting that:
+#
+#     Some cities in the United States have pushed the deadline back
+#     three weeks and will change over from daylight saving in October.
+
+# From Arthur David Olson (2010-07-17):
+#
+# "Standard Time and Time Zones in Canada" appeared in
+# The Journal of The Royal Astronomical Society of Canada,
+# volume 26, number 2 (February 1932) and, as of 2010-07-17,
+# was available at
+# 
+# http://adsabs.harvard.edu/full/1932JRASC..26...49S
+# 
+#
+# It includes the text below (starting on page 57):
+#
+#   A list of the places in Canada using daylight saving time would
+# require yearly revision. From information kindly furnished by
+# the provincial governments and by the postmasters in many cities
+# and towns, it is found that the following places used daylight sav-
+# ing in 1930. The information for the province of Quebec is definite,
+# for the other provinces only approximate:
+#
+# 	Province	Daylight saving time used
+# Prince Edward Island	Not used.
+# Nova Scotia		In Halifax only.
+# New Brunswick		In St. John only.
+# Quebec		In the following places:
+# 			Montreal	Lachine
+# 			Quebec		Mont-Royal
+# 			Levis		Iberville
+# 			St. Lambert	Cap de la Madeleine
+# 			Verdun		Loretteville
+# 			Westmount	Richmond
+# 			Outremont	St. Jerome
+# 			Longueuil	Greenfield Park
+# 			Arvida		Waterloo
+# 			Chambly-Canton	Beaulieu
+# 			Melbourne	La Tuque
+# 			St. Theophile	Buckingham
+# Ontario		Used generally in the cities and towns along
+# 			the southerly part of the province. Not
+# 			used in the northwesterlhy part.
+# Manitoba		Not used.
+# Saskatchewan		In Regina only.
+# Alberta		Not used.
+# British Columbia	Not used.
+#
+#   With some exceptions, the use of daylight saving may be said to be limited
+# to those cities and towns lying between Quebec city and Windsor, Ont.
+
 # Rule	NAME	FROM	TO	TYPE	IN	ON	AT	SAVE	LETTER/S
 Rule	Toronto	1919	only	-	Mar	30	23:30	1:00	D
 Rule	Toronto	1919	only	-	Oct	26	0:00	0	S
@@ -2147,7 +2224,7 @@ Zone America/Bahia_Banderas	-7:01:00 -	L
 			-6:00	-	CST	1942 Apr 24
 			-7:00	-	MST	1949 Jan 14
 			-8:00	-	PST	1970
-			-7:00	Mexico	M%sT	2010 Apr 4
+			-7:00	Mexico	M%sT	2010 Apr 4 2:00
 			-6:00	Mexico	C%sT
 
 # Baja California (near US border)

Modified: stable/6/share/zoneinfo/zone.tab
==============================================================================
--- stable/6/share/zoneinfo/zone.tab	Sun Aug  1 09:11:56 2010	(r210721)
+++ stable/6/share/zoneinfo/zone.tab	Sun Aug  1 09:17:05 2010	(r210722)
@@ -1,5 +1,5 @@
 # 
-# @(#)zone.tab	8.36
+# @(#)zone.tab	8.37
 # This file is in the public domain, so clarified as of
 # 2009-05-17 by Arthur David Olson.
 #
@@ -177,8 +177,8 @@ ET	+0902+03842	Africa/Addis_Ababa
 FI	+6010+02458	Europe/Helsinki
 FJ	-1808+17825	Pacific/Fiji
 FK	-5142-05751	Atlantic/Stanley
-FM	+0725+15147	Pacific/Truk	Truk (Chuuk) and Yap
-FM	+0658+15813	Pacific/Ponape	Ponape (Pohnpei)
+FM	+0725+15147	Pacific/Chuuk	Chuuk (Truk) and Yap
+FM	+0658+15813	Pacific/Pohnpei	Pohnpei (Ponape)
 FM	+0519+16259	Pacific/Kosrae	Kosrae
 FO	+6201-00646	Atlantic/Faroe
 FR	+4852+00220	Europe/Paris

From owner-svn-src-stable-6@FreeBSD.ORG  Wed Aug  4 13:20:34 2010
Return-Path: 
Delivered-To: svn-src-stable-6@freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id BF2F11065675;
	Wed,  4 Aug 2010 13:20:34 +0000 (UTC)
	(envelope-from attilio@FreeBSD.org)
Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c])
	by mx1.freebsd.org (Postfix) with ESMTP id ACF108FC29;
	Wed,  4 Aug 2010 13:20:34 +0000 (UTC)
Received: from svn.freebsd.org (localhost [127.0.0.1])
	by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o74DKY9V080979;
	Wed, 4 Aug 2010 13:20:34 GMT (envelope-from attilio@svn.freebsd.org)
Received: (from attilio@localhost)
	by svn.freebsd.org (8.14.3/8.14.3/Submit) id o74DKYDK080978;
	Wed, 4 Aug 2010 13:20:34 GMT (envelope-from attilio@svn.freebsd.org)
Message-Id: <201008041320.o74DKYDK080978@svn.freebsd.org>
From: Attilio Rao 
Date: Wed, 4 Aug 2010 13:20:34 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
	svn-src-stable@freebsd.org, svn-src-stable-6@freebsd.org
X-SVN-Group: stable-6
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: 
Subject: svn commit: r210844 - stable/6/sys/kern
X-BeenThere: svn-src-stable-6@freebsd.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: SVN commit messages for only the 6-stable src tree
	
List-Unsubscribe: , 
	
List-Archive: 
List-Post: 
List-Help: 
List-Subscribe: , 
	
X-List-Received-Date: Wed, 04 Aug 2010 13:20:34 -0000

Author: attilio
Date: Wed Aug  4 13:20:34 2010
New Revision: 210844
URL: http://svn.freebsd.org/changeset/base/210844

Log:
  MFC CVS r1.30:
  Remove a bogus KASSERT which will prevent rwlock to be acquired
  recursively in exclusive mode with debugging kernels.
  
  Reported by:	rwatson

Modified:
  stable/6/sys/kern/kern_rwlock.c

Modified: stable/6/sys/kern/kern_rwlock.c
==============================================================================
--- stable/6/sys/kern/kern_rwlock.c	Wed Aug  4 10:46:17 2010	(r210843)
+++ stable/6/sys/kern/kern_rwlock.c	Wed Aug  4 13:20:34 2010	(r210844)
@@ -152,9 +152,6 @@ _rw_wlock(struct rwlock *rw, const char 
 	MPASS(curthread != NULL);
 	KASSERT(rw->rw_lock != RW_DESTROYED,
 	    ("rw_wlock() of destroyed rwlock @ %s:%d", file, line));
-	KASSERT(rw_wowner(rw) != curthread,
-	    ("%s (%s): wlock already held @ %s:%d", __func__,
-	    rw->lock_object.lo_name, file, line));
 	WITNESS_CHECKORDER(&rw->lock_object, LOP_NEWORDER | LOP_EXCLUSIVE, file,
 	    line);
 	__rw_wlock(rw, curthread, file, line);

From owner-svn-src-stable-6@FreeBSD.ORG  Thu Aug  5 20:49:48 2010
Return-Path: 
Delivered-To: svn-src-stable-6@freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 43DDD1065674;
	Thu,  5 Aug 2010 20:49:48 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c])
	by mx1.freebsd.org (Postfix) with ESMTP id 31C818FC1F;
	Thu,  5 Aug 2010 20:49:48 +0000 (UTC)
Received: from svn.freebsd.org (localhost [127.0.0.1])
	by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o75KnmFo002262;
	Thu, 5 Aug 2010 20:49:48 GMT (envelope-from jhb@svn.freebsd.org)
Received: (from jhb@localhost)
	by svn.freebsd.org (8.14.3/8.14.3/Submit) id o75KnmgU002260;
	Thu, 5 Aug 2010 20:49:48 GMT (envelope-from jhb@svn.freebsd.org)
Message-Id: <201008052049.o75KnmgU002260@svn.freebsd.org>
From: John Baldwin 
Date: Thu, 5 Aug 2010 20:49:48 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
	svn-src-stable@freebsd.org, svn-src-stable-6@freebsd.org
X-SVN-Group: stable-6
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: 
Subject: svn commit: r210897 - stable/6/sys/dev/ipmi
X-BeenThere: svn-src-stable-6@freebsd.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: SVN commit messages for only the 6-stable src tree
	
List-Unsubscribe: , 
	
List-Archive: 
List-Post: 
List-Help: 
List-Subscribe: , 
	
X-List-Received-Date: Thu, 05 Aug 2010 20:49:48 -0000

Author: jhb
Date: Thu Aug  5 20:49:47 2010
New Revision: 210897
URL: http://svn.freebsd.org/changeset/base/210897

Log:
  MFC 210604:
  Fix test for double-nul characters that terminate the string table at
  the end of each SMBIOS/DMI structure.

Modified:
  stable/6/sys/dev/ipmi/ipmi_smbios.c
Directory Properties:
  stable/6/sys/   (props changed)
  stable/6/sys/contrib/pf/   (props changed)
  stable/6/sys/dev/cxgb/   (props changed)

Modified: stable/6/sys/dev/ipmi/ipmi_smbios.c
==============================================================================
--- stable/6/sys/dev/ipmi/ipmi_smbios.c	Thu Aug  5 20:45:46 2010	(r210896)
+++ stable/6/sys/dev/ipmi/ipmi_smbios.c	Thu Aug  5 20:49:47 2010	(r210897)
@@ -189,7 +189,7 @@ smbios_walk_table(uint8_t *p, int entrie
 		 * formatted area of this structure.
 		 */
 		p += s->length;
-		while (p[0] != 0 && p[1] != 0)
+		while (!(p[0] == 0 && p[1] == 0))
 			p++;
 
 		/*

From owner-svn-src-stable-6@FreeBSD.ORG  Fri Aug  6 14:18:37 2010
Return-Path: 
Delivered-To: svn-src-stable-6@freebsd.org
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 839831065675;
	Fri,  6 Aug 2010 14:18:37 +0000 (UTC) (envelope-from jhb@FreeBSD.org)
Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c])
	by mx1.freebsd.org (Postfix) with ESMTP id 573AD8FC18;
	Fri,  6 Aug 2010 14:18:37 +0000 (UTC)
Received: from svn.freebsd.org (localhost [127.0.0.1])
	by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o76EIbFI038829;
	Fri, 6 Aug 2010 14:18:37 GMT (envelope-from jhb@svn.freebsd.org)
Received: (from jhb@localhost)
	by svn.freebsd.org (8.14.3/8.14.3/Submit) id o76EIbj0038826;
	Fri, 6 Aug 2010 14:18:37 GMT (envelope-from jhb@svn.freebsd.org)
Message-Id: <201008061418.o76EIbj0038826@svn.freebsd.org>
From: John Baldwin 
Date: Fri, 6 Aug 2010 14:18:37 +0000 (UTC)
To: src-committers@freebsd.org, svn-src-all@freebsd.org,
	svn-src-stable@freebsd.org, svn-src-stable-6@freebsd.org
X-SVN-Group: stable-6
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Cc: 
Subject: svn commit: r210932 - in stable/6/sys: amd64/amd64 i386/i386
X-BeenThere: svn-src-stable-6@freebsd.org
X-Mailman-Version: 2.1.5
Precedence: list
List-Id: SVN commit messages for only the 6-stable src tree
	
List-Unsubscribe: , 
	
List-Archive: 
List-Post: 
List-Help: 
List-Subscribe: , 
	
X-List-Received-Date: Fri, 06 Aug 2010 14:18:37 -0000

Author: jhb
Date: Fri Aug  6 14:18:37 2010
New Revision: 210932
URL: http://svn.freebsd.org/changeset/base/210932

Log:
  MFC 170866,176206:
  If busdma is being used to realign dynamic buffers and the alignment is set to
  PAGE_SIZE or less, the bounce page counting logic was flawed and wouldn't
  reserve any pages.  Adjust to be correct.

Modified:
  stable/6/sys/amd64/amd64/busdma_machdep.c
  stable/6/sys/i386/i386/busdma_machdep.c
Directory Properties:
  stable/6/sys/   (props changed)
  stable/6/sys/contrib/pf/   (props changed)
  stable/6/sys/dev/cxgb/   (props changed)

Modified: stable/6/sys/amd64/amd64/busdma_machdep.c
==============================================================================
--- stable/6/sys/amd64/amd64/busdma_machdep.c	Fri Aug  6 13:45:16 2010	(r210931)
+++ stable/6/sys/amd64/amd64/busdma_machdep.c	Fri Aug  6 14:18:37 2010	(r210932)
@@ -594,14 +594,14 @@ _bus_dmamap_load_buffer(bus_dma_tag_t dm
 		 * Count the number of bounce pages
 		 * needed in order to complete this transfer
 		 */
-		vaddr = trunc_page((vm_offset_t)buf);
+		vaddr = (vm_offset_t)buf;
 		vendaddr = (vm_offset_t)buf + buflen;
 
 		while (vaddr < vendaddr) {
 			paddr = pmap_kextract(vaddr);
 			if (run_filter(dmat, paddr) != 0)
 				map->pagesneeded++;
-			vaddr += PAGE_SIZE;
+			vaddr += (PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK));
 		}
 		CTR1(KTR_BUSDMA, "pagesneeded= %d\n", map->pagesneeded);
 	}
@@ -832,7 +832,7 @@ bus_dmamap_load_uio(bus_dma_tag_t dmat, 
 		    bus_dmamap_callback2_t *callback, void *callback_arg,
 		    int flags)
 {
-	bus_addr_t lastaddr;
+	bus_addr_t lastaddr = 0;
 	int nsegs, error, first, i;
 	bus_size_t resid;
 	struct iovec *iov;

Modified: stable/6/sys/i386/i386/busdma_machdep.c
==============================================================================
--- stable/6/sys/i386/i386/busdma_machdep.c	Fri Aug  6 13:45:16 2010	(r210931)
+++ stable/6/sys/i386/i386/busdma_machdep.c	Fri Aug  6 14:18:37 2010	(r210932)
@@ -597,14 +597,14 @@ _bus_dmamap_load_buffer(bus_dma_tag_t dm
 		 * Count the number of bounce pages
 		 * needed in order to complete this transfer
 		 */
-		vaddr = trunc_page((vm_offset_t)buf);
+		vaddr = (vm_offset_t)buf;
 		vendaddr = (vm_offset_t)buf + buflen;
 
 		while (vaddr < vendaddr) {
 			paddr = pmap_kextract(vaddr);
 			if (run_filter(dmat, paddr) != 0)
 				map->pagesneeded++;
-			vaddr += PAGE_SIZE;
+			vaddr += (PAGE_SIZE - ((vm_offset_t)vaddr & PAGE_MASK));
 		}
 		CTR1(KTR_BUSDMA, "pagesneeded= %d\n", map->pagesneeded);
 	}