[prev in list] [next in list] [prev in thread] [next in thread] 

List:       evms-devel
Subject:    [Evms-devel] patch for further cleanup of atomic variables
From:       Oliver Neukum <oliver () neukum ! name>
Date:       2002-07-25 9:59:30
[Download RAW message or body]

You can import this changeset into BK by piping this whole message to:
'| bk receive [path to repository]' or apply the patch as usual.

===================================================================


ChangeSet@1.704, 2002-07-25 11:58:14+02:00, oliver@oenone.homelinux.org
  - fix missing init of atomic variables




diff -Nru a/drivers/evms/md_core.c b/drivers/evms/md_core.c
--- a/drivers/evms/md_core.c	Thu Jul 25 11:58:29 2002
+++ b/drivers/evms/md_core.c	Thu Jul 25 11:58:29 2002
@@ -490,6 +490,7 @@
 
 	memset(&cb, 0, sizeof(cb));
 	init_waitqueue_head(&cb.wait);
+	cb.io_count = (atomic_t)ATOMIC_INIT(0);
 
 	while (!rc && npages) {
 		if ((bio = bio_alloc(GFP_NOIO, 1)) == NULL) {
@@ -579,6 +580,7 @@
 
 	if (!rc) {
 		memset(&cb, 0, sizeof(cb));
+		cb.io_count = (atomic_t)ATOMIC_INIT(0);
 		init_waitqueue_head(&cb.wait);
 		if ((bio = bio_alloc(GFP_NOIO, 1)) == NULL) {
 			md_log_err_no_bio(__FUNCTION__, __LINE__);
@@ -701,6 +703,7 @@
 	chunk_size_mask = ~((chunk_size >> EVMS_VSECTOR_SIZE_SHIFT) - 1);
 
 	memset(&cb, 0, sizeof(cb));
+	cb.io_count = (atomic_t)ATOMIC_INIT(0);
 	init_waitqueue_head(&cb.wait);
 
 	while (!rc && total_nr_pages) {
@@ -1225,7 +1228,7 @@
 	INIT_LIST_HEAD(&mddev->all_mddevs);
 	INIT_LIST_HEAD(&mddev->incomplete_mddevs);
 	INIT_LIST_HEAD(&mddev->running_mddevs);
-	atomic_set(&mddev->active, 0);
+	mddev->active = (atomic_t)ATOMIC_INIT(0);
 
 	/*
 	 * The 'base' mddev is the one with data NULL.

===================================================================


This BitKeeper patch contains the following changesets:
1.704
## Wrapped with gzip_uu ##


begin 664 bkpatch12600
M'XL(`,7+/ST``[U4;6O;,!#^;/V*@WYI*;9/+WX=*>W2L9FM:\C:S\&VE-@D
MMHKM9!WXQT].2LH@R]:630CT<G>/[AX]T@G<MZJ)+;TJ-ZHA)_!)MYU9JEK7
MRBETI59EO7YT=+,PQJG6QN@.V^XNPLV6=M<HU;IJ4[7,(\9KDG9Y`<;8QA9U
M^'ZG^_&@8FOZX>/]EZLI(:,1C(NT7JAOJH/1B&3+2[E6*V?9Z+08#NSWYIXA
M4DJ9A]SSJ=>SD'/14Q\S:::2!=$\\R.R2^GR4/*_8C$,F&#<"S'J1>!S3JZ!
M.@$*0.9BX#(/*(V],*;B'%F,"$>@X9R"C>0]O+V`,<G!AGGY"%79MF6]@+(N
M.]!S2#M=E3ELTJ9,LY5JR6<001!R,GDFD=@O;(1@BN0"'H;K.4R;;(:Z=[?K
M5G*6ZT8Y^3.'2`7'7D2<8L]\FO'4"Z5DR",ECY'V!V`/(R^DHF?"%WPKE</^
M@V[^4?9OQ:4]%<QG6V6QU^E*@$W_OZYVG-^"W7S?=J.3R6_H?X7B$A$QH,3*
M,Z?4!F9=F\</I[L\9MW9U=WM33*>)5^3NU,\>T<2HX/!_^\#`N0O.>":,A::
I@.1IM"HIU<:^2//.E'PT=/^SY87*E^VZ&J49DX'(!/D)["+$5U@%````
`
end



-------------------------------------------------------
This sf.net email is sponsored by: Jabber - The world's fastest growing
real-time communications platform! Don't just IM. Build it in!
http://www.jabber.com/osdn/xim
_______________________________________________
Evms-devel mailing list
Evms-devel@lists.sourceforge.net
To subscribe/unsubscribe, please visit:
https://lists.sourceforge.net/lists/listinfo/evms-devel
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic