patch-2.3.49 linux/fs/block_dev.c

Next file: linux/fs/exec.c
Previous file: linux/fs/binfmt_script.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.48/linux/fs/block_dev.c linux/fs/block_dev.c
@@ -630,7 +630,7 @@
 	/* syncing will go here */
 	if (kind == BDEV_FILE || kind == BDEV_FS)
 		fsync_dev(rdev);
-	if (atomic_dec_and_test(&bdev->bd_openers)) {
+	if (atomic_dec_and_test(&bdev->bd_openers) && MAJOR(rdev) != RAMDISK_MAJOR) {
 		/* invalidating buffers will go here */
 		invalidate_buffers(rdev);
 	}

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)