<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/fs/block_dev.c, branch v2.6.32</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.32</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v2.6.32'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2009-10-26T14:27:11Z</updated>
<entry>
<title>block: use after free bug in __blkdev_get</title>
<updated>2009-10-26T14:27:11Z</updated>
<author>
<name>Neil Brown</name>
<email>neilb@suse.de</email>
</author>
<published>2009-10-26T07:59:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=960cc0f4fef607baabc2232fbd7cce5368a9dcfd'/>
<id>urn:sha1:960cc0f4fef607baabc2232fbd7cce5368a9dcfd</id>
<content type='text'>
commit 0762b8bde9729f10f8e6249809660ff2ec3ad735
(from 14 months ago) introduced a use-after-free bug which has just
recently started manifesting in my md testing.
I tried git bisect to find out what caused the bug to start
manifesting, and it could have been the recent change to
blk_unregister_queue (48c0d4d4c04) but the results were inconclusive.

This patch certainly fixes my symptoms and looks correct as the two
calls are now in the same order as elsewhere in that function.

Signed-off-by: NeilBrown &lt;neilb@suse.de&gt;
Acked-by: Tejun Heo &lt;tj@kernel.org&gt;
Signed-off-by: Jens Axboe &lt;jens.axboe@oracle.com&gt;
</content>
</entry>
<entry>
<title>freeze_bdev: grab active reference to frozen superblocks</title>
<updated>2009-09-24T11:47:41Z</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2009-08-03T21:28:35Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4504230a71566785a05d3e6b53fa1ee071b864eb'/>
<id>urn:sha1:4504230a71566785a05d3e6b53fa1ee071b864eb</id>
<content type='text'>
Currently we held s_umount while a filesystem is frozen, despite that we
might return to userspace and unlock it from a different process.  Instead
grab an active reference to keep the file system busy and add an explicit
check for frozen filesystems in remount and reject the remount instead
of blocking on s_umount.

Add a new get_active_super helper to super.c for use by freeze_bdev that
grabs an active reference to a superblock from a given block device.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>freeze_bdev: kill bd_mount_sem</title>
<updated>2009-09-24T11:47:39Z</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2009-08-03T21:28:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4fadd7bb20a1e7c774ed88dc703d8fbcd00ff917'/>
<id>urn:sha1:4fadd7bb20a1e7c774ed88dc703d8fbcd00ff917</id>
<content type='text'>
Now that we have the freeze count there is not much reason for bd_mount_sem
anymore.  The actual freeze/thaw operations are serialized using the
bd_fsfreeze_mutex, and the only other place we take bd_mount_sem is
get_sb_bdev which tries to prevent mounting a filesystem while the block
device is frozen.  Instead of add a check for bd_fsfreeze_count and
return -EBUSY if a filesystem is frozen.  While that is a change in user
visible behaviour a failing mount is much better for this case rather
than having the mount process stuck uninterruptible for a long time.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>const: make block_device_operations const</title>
<updated>2009-09-22T14:17:25Z</updated>
<author>
<name>Alexey Dobriyan</name>
<email>adobriyan@gmail.com</email>
</author>
<published>2009-09-22T00:01:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=83d5cde47dedf01b6a4a4331882cbc0a7eea3c2e'/>
<id>urn:sha1:83d5cde47dedf01b6a4a4331882cbc0a7eea3c2e</id>
<content type='text'>
Signed-off-by: Alexey Dobriyan &lt;adobriyan@gmail.com&gt;
Signed-off-by: Andrew Morton &lt;akpm@linux-foundation.org&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@linux-foundation.org&gt;
</content>
</entry>
<entry>
<title>fs: remove bdev-&gt;bd_inode_backing_dev_info</title>
<updated>2009-09-16T13:16:18Z</updated>
<author>
<name>Jens Axboe</name>
<email>jens.axboe@oracle.com</email>
</author>
<published>2009-09-15T07:43:56Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=2c96ce9f2084c1e04d02883e622f74a537a63aea'/>
<id>urn:sha1:2c96ce9f2084c1e04d02883e622f74a537a63aea</id>
<content type='text'>
It has been unused since it was introduced in:

commit 520808bf20e90fdbdb320264ba7dd5cf9d47dcac
Author: Andrew Morton &lt;akpm@osdl.org&gt;
Date:   Fri May 21 00:46:17 2004 -0700

    [PATCH] block device layer: separate backing_dev_info infrastructure

So lets just kill it.

Acked-by: Jan Kara &lt;jack@suse.cz&gt;
Signed-off-by: Jens Axboe &lt;jens.axboe@oracle.com&gt;
</content>
</entry>
<entry>
<title>vfs: Rename generic_file_aio_write_nolock</title>
<updated>2009-09-14T15:08:15Z</updated>
<author>
<name>Christoph Hellwig</name>
<email>hch@lst.de</email>
</author>
<published>2009-08-20T15:43:41Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=eef99380679e20e7edc096aa4d8a98b875404d79'/>
<id>urn:sha1:eef99380679e20e7edc096aa4d8a98b875404d79</id>
<content type='text'>
generic_file_aio_write_nolock() is now used only by block devices and raw
character device. Filesystems should use __generic_file_aio_write() in case
generic_file_aio_write() doesn't suit them. So rename the function to
blkdev_aio_write() and move it to fs/blockdev.c.

Signed-off-by: Christoph Hellwig &lt;hch@lst.de&gt;
Signed-off-by: Jan Kara &lt;jack@suse.cz&gt;
</content>
</entry>
<entry>
<title>PM / Hibernate: Replace bdget call with simple atomic_inc of i_count</title>
<updated>2009-07-29T19:07:55Z</updated>
<author>
<name>Alan Jenkins</name>
<email>alan-jenkins@tuffmail.co.uk</email>
</author>
<published>2009-07-29T19:07:55Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=dddac6a7b445de95515f64fdf82fe5dc36c02f26'/>
<id>urn:sha1:dddac6a7b445de95515f64fdf82fe5dc36c02f26</id>
<content type='text'>
Create bdgrab().  This function copies an existing reference to a
block_device.  It is safe to call from any context.

Hibernation code wishes to copy a reference to the active swap device.
Right now it calls bdget() under a spinlock, but this is wrong because
bdget() can sleep.  It doesn't need a full bdget() because we already
hold a reference to active swap devices (and the spinlock protects
against swapoff).

Fixes http://bugzilla.kernel.org/show_bug.cgi?id=13827

Signed-off-by: Alan Jenkins &lt;alan-jenkins@tuffmail.co.uk&gt;
Signed-off-by: Rafael J. Wysocki &lt;rjw@sisk.pl&gt;
</content>
</entry>
<entry>
<title>vfs: Rename fsync_super() to sync_filesystem() (version 4)</title>
<updated>2009-06-12T01:36:04Z</updated>
<author>
<name>Jan Kara</name>
<email>jack@suse.cz</email>
</author>
<published>2009-04-27T14:43:53Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=60b0680fa236ac4e17ce31a50048c9d75f9ec831'/>
<id>urn:sha1:60b0680fa236ac4e17ce31a50048c9d75f9ec831</id>
<content type='text'>
Rename the function so that it better describe what it really does. Also
remove the unnecessary include of buffer_head.h.

Signed-off-by: Jan Kara &lt;jack@suse.cz&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>vfs: Make sys_sync() use fsync_super() (version 4)</title>
<updated>2009-06-12T01:36:03Z</updated>
<author>
<name>Jan Kara</name>
<email>jack@suse.cz</email>
</author>
<published>2009-04-27T14:43:51Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=5cee5815d1564bbbd505fea86f4550f1efdb5cd0'/>
<id>urn:sha1:5cee5815d1564bbbd505fea86f4550f1efdb5cd0</id>
<content type='text'>
It is unnecessarily fragile to have two places (fsync_super() and do_sync())
doing data integrity sync of the filesystem. Alter __fsync_super() to
accommodate needs of both callers and use it. So after this patch
__fsync_super() is the only place where we gather all the calls needed to
properly send all data on a filesystem to disk.

Nice bonus is that we get a complete livelock avoidance and write_supers()
is now only used for periodic writeback of superblocks.

sync_blockdevs() introduced a couple of patches ago is gone now.

[build fixes folded]

Signed-off-by: Jan Kara &lt;jack@suse.cz&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
<entry>
<title>vfs: Make __fsync_super() a static function (version 4)</title>
<updated>2009-06-12T01:36:03Z</updated>
<author>
<name>Jan Kara</name>
<email>jack@suse.cz</email>
</author>
<published>2009-04-27T14:43:50Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=429479f031322a0cc5c921ffb2321a51718dc875'/>
<id>urn:sha1:429479f031322a0cc5c921ffb2321a51718dc875</id>
<content type='text'>
__fsync_super() does the same thing as fsync_super(). So change the only
caller to use fsync_super() and make __fsync_super() static. This removes
unnecessarily duplicated call to sync_blockdev() and prepares ground
for the changes to __fsync_super() in the following patches.

Signed-off-by: Jan Kara &lt;jack@suse.cz&gt;
Signed-off-by: Al Viro &lt;viro@zeniv.linux.org.uk&gt;
</content>
</entry>
</feed>
