<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/md/bitmap.c, branch v2.6.30</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v2.6.30</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v2.6.30'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2009-05-25T23:41:17Z</updated>
<entry>
<title>md: bitmap: improve bitmap maintenance code.</title>
<updated>2009-05-25T23:41:17Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-05-25T23:41:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=be512691036cc989c11d0f418187efbbf14468e6'/>
<id>urn:sha1:be512691036cc989c11d0f418187efbbf14468e6</id>
<content type='text'>
The code for checking which bits in the bitmap can be cleared
has 2 problems:
 1/ it repeatedly takes and drops a spinlock, where it would make
    more sense to just hold on to it most of the time.
 2/ it doesn't make use of some opportunities to skip large sections
    of the bitmap

This patch fixes those.  It will only affect CPU consumption, not
correctness.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: fix some (more) errors with bitmaps on devices larger than 2TB.</title>
<updated>2009-05-07T02:49:06Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-05-07T02:49:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=db305e507d554430a69ede901a6308e6ecb72349'/>
<id>urn:sha1:db305e507d554430a69ede901a6308e6ecb72349</id>
<content type='text'>
If a write intent bitmap covers more than 2TB, we sometimes work with
values beyond 32bit, so these need to be sector_t.  This patches
add the required casts to some unsigned longs that are being shifted
up.

This will affect any raid10 larger than 2TB, or any raid1/4/5/6 with
member devices that are larger than 2TB.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
Reported-by: "Mario 'BitKoenig' Holbe" &lt;Mario.Holbe@TU-Ilmenau.DE&gt;
Cc: stable@kernel.org
</content>
</entry>
<entry>
<title>md: fix loading of out-of-date bitmap.</title>
<updated>2009-05-07T02:47:19Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-05-07T02:47:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=b74fd2826c5acce20e6f691437b2d19372bc2057'/>
<id>urn:sha1:b74fd2826c5acce20e6f691437b2d19372bc2057</id>
<content type='text'>
When md is loading a bitmap which it knows is out of date, it fills
each page with 1s and writes it back out again.  However the
write_page call makes used of bitmap-&gt;file_pages and
bitmap-&gt;last_page_size which haven't been set correctly yet.  So this
can sometimes fail.

Move the setting of file_pages and last_page_size to before the call
to write_page.

This bug can cause the assembly on an array to fail, thus making the
data inaccessible.  Hence I think it is a suitable candidate for
-stable.

Cc: stable@kernel.org
Reported-by: Vojtech Pavlik &lt;vojtech@suse.cz&gt;
Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: support bitmaps on RAID10 arrays larger then 2 terabytes</title>
<updated>2009-04-20T01:50:24Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-04-20T01:50:24Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=1f59390339f263c0fe7908fbe54466dbf3a64b58'/>
<id>urn:sha1:1f59390339f263c0fe7908fbe54466dbf3a64b58</id>
<content type='text'>
.. and other arrays with components larger than 2 terabytes.

We use a "long" rather than a "sector_t" in part of the bitmap
size calculations, which is sad.

Reported-by: "Mario 'BitKoenig' Holbe" &lt;Mario.Holbe@TU-Ilmenau.DE&gt;
Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: improve usefulness and accuracy of sysfs file md/sync_completed.</title>
<updated>2009-04-14T06:28:34Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-04-14T06:28:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=acb180b0e335ad88acfed6c8a33e39c05b95dc49'/>
<id>urn:sha1:acb180b0e335ad88acfed6c8a33e39c05b95dc49</id>
<content type='text'>
The sync_completed file reports how much of a resync (or recovery or
reshape) has been completed.
However due to the possibility of out-of-order completion of writes,
it is not certain to be accurate.

We have an internal value - mddev-&gt;curr_resync_completed - which is an
accurate value (though it might not always be quite so uptodate).

So:
 - make curr_resync_completed be uptodate a little more often,
   particularly when raid5 reshape updates status in the metadata
 - report curr_resync_completed in the sysfs file
 - allow poll/select to report all updates to md/sync_completed.

This makes sync_completed completed usable by any external metadata
handler that wants to record this status information in its metadata.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: Make mddev-&gt;size sector-based.</title>
<updated>2009-03-31T03:33:13Z</updated>
<author>
<name>Andre Noll</name>
<email>maan@systemlinux.org</email>
</author>
<published>2009-03-31T03:33:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=58c0fed400603a802968b23ddf78f029c5a84e41'/>
<id>urn:sha1:58c0fed400603a802968b23ddf78f029c5a84e41</id>
<content type='text'>
This patch renames the "size" field of struct mddev_s to "dev_sectors"
and stores the number of 512-byte sectors instead of the number of
1K-blocks in it.

All users of that field, including raid levels 1,4-6,10, are adjusted
accordingly. This simplifies the code a bit because it allows to get
rid of a couple of divisions/multiplications by two.

In order to make checkpatch happy, some minor coding style issues
have also been addressed. In particular, size_store() now uses
strict_strtoull() instead of simple_strtoull().

Signed-off-by: Andre Noll &lt;maan@systemlinux.org&gt;
Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: occasionally checkpoint drive recovery to reduce duplicate effort after a crash</title>
<updated>2009-03-31T03:33:13Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-03-31T03:33:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=97e4f42d62badb0f9fbc27c013e89bc1336a03bc'/>
<id>urn:sha1:97e4f42d62badb0f9fbc27c013e89bc1336a03bc</id>
<content type='text'>
Version 1.x metadata has the ability to record the status of a
partially completed drive recovery.
However we only update that record on a clean shutdown.
It would be nice to update it on unclean shutdowns too, particularly
when using a bitmap that removes much to the 'sync' effort after an
unclean shutdown.

One complication with checkpointing recovery is that we only know
where we are up to in terms of IO requests started, not which ones
have completed.  And we need to know what has completed to record
how much is recovered.  So occasionally pause the recovery until all
submitted requests are completed, then update the record of where
we are up to.

When we have a bitmap, we already do that pause occasionally to keep
the bitmap up-to-date.  So enhance that code to record the recovery
offset and schedule a superblock update.
And when there is no bitmap, just pause 16 times during the resync to
do a checkpoint.
'16' is a fairly arbitrary number.  But we don't really have any good
way to judge how often is acceptable, and it seems like a reasonable
number for now.


Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: move md_k.h from include/linux/raid/ to drivers/md/</title>
<updated>2009-03-31T03:33:13Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-03-31T03:33:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=43b2e5d86d8bdd77386226db0bc961529492c043'/>
<id>urn:sha1:43b2e5d86d8bdd77386226db0bc961529492c043</id>
<content type='text'>
It really is nicer to keep related code together..

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: move lots of #include lines out of .h files and into .c</title>
<updated>2009-03-31T03:33:13Z</updated>
<author>
<name>NeilBrown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-03-31T03:33:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=bff61975b3d6c18ee31457cc5b4d73042f44915f'/>
<id>urn:sha1:bff61975b3d6c18ee31457cc5b4d73042f44915f</id>
<content type='text'>
This makes the includes more explicit, and is preparation for moving
md_k.h to drivers/md/md.h

Remove include/raid/md.h as its only remaining use was to #include
other files.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
<entry>
<title>md: move headers out of include/linux/raid/</title>
<updated>2009-03-31T03:27:03Z</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2009-03-31T03:27:03Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=ef740c372dfd80e706dbf955d4e4aedda6c0c148'/>
<id>urn:sha1:ef740c372dfd80e706dbf955d4e4aedda6c0c148</id>
<content type='text'>
Move the headers with the local structures for the disciplines and
bitmap.h into drivers/md/ so that they are more easily grepable for
hacking and not far away.  md.h is left where it is for now as there
are some uses from the outside.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
</content>
</entry>
</feed>
