lkml.org 
[lkml]   [2003]   [Mar]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: ancient block_dev patch
davej@codemonkey.org.uk wrote:
>
> Andrew,
> What became of this patch ? Is it needed ?
>
>
> ...
> down(&bdev->bd_sem);
> - switch (kind) {
> - case BDEV_FILE:
> - case BDEV_FS:
> - sync_blockdev(bd_inode->i_bdev);
> - break;
> - }
> lock_kernel();
> - if (!--bdev->bd_openers)
> + if (!--bdev->bd_openers) {
> + switch (kind) {
> + case BDEV_FILE:
> + case BDEV_FS:
> + sync_blockdev(bd_inode->i_bdev);
> + break;
> + }
> kill_bdev(bdev);
> + }

Seems so, yes. Without it we sync the blockdev on every close rather
than on the final one.

It has scary potential to expose existing bugs. I shall play with it,
thanks.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:34    [W:0.028 / U:0.220 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site