+ lockdep-annotate-the-blkpg_del_partition-ioctl.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



The patch titled

     lockdep: annotate the BLKPG_DEL_PARTITION ioctl

has been added to the -mm tree.  Its filename is

     lockdep-annotate-the-blkpg_del_partition-ioctl.patch

See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find
out what to do about this

------------------------------------------------------
Subject: lockdep: annotate the BLKPG_DEL_PARTITION ioctl
From: Arjan van de Ven <arjan@xxxxxxxxxxxxxxx>

The delete partition IOCTL takes the bd_mutex for both the disk and the
partition; these have an obvious hierarchical relationship and this patch
annotates this relationship for lockdep.

Signed-off-by: Arjan van de Ven <arjan@xxxxxxxxxxxxxxx>
Acked-by: Ingo Molnar <mingo@xxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxx>
---

 block/ioctl.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff -puN block/ioctl.c~lockdep-annotate-the-blkpg_del_partition-ioctl block/ioctl.c
--- a/block/ioctl.c~lockdep-annotate-the-blkpg_del_partition-ioctl
+++ a/block/ioctl.c
@@ -72,7 +72,7 @@ static int blkpg_ioctl(struct block_devi
 			bdevp = bdget_disk(disk, part);
 			if (!bdevp)
 				return -ENOMEM;
-			mutex_lock(&bdevp->bd_mutex);
+			mutex_lock_nested(&bdevp->bd_mutex, BD_MUTEX_PARTITION);
 			if (bdevp->bd_openers) {
 				mutex_unlock(&bdevp->bd_mutex);
 				bdput(bdevp);
@@ -82,7 +82,7 @@ static int blkpg_ioctl(struct block_devi
 			fsync_bdev(bdevp);
 			invalidate_bdev(bdevp, 0);
 
-			mutex_lock(&bdev->bd_mutex);
+			mutex_lock_nested(&bdev->bd_mutex, BD_MUTEX_WHOLE);
 			delete_partition(disk, part);
 			mutex_unlock(&bdev->bd_mutex);
 			mutex_unlock(&bdevp->bd_mutex);
_

Patches currently in -mm which might be from arjan@xxxxxxxxxxxxxxx are

origin.patch
lockdep-annotate-the-sysfs-i_mutex-to-be-a-separate-class.patch
lockdep-hpet-rtc-fix.patch
lockdep-annotate-8390c-disable_irq-2.patch
lockdep-fix-sk_dst_check-deadlock.patch
lockdep-split-the-skb_queue_head_init-lock-class.patch
fix-deadlock-in-the-bluetooth-l2cap-layer.patch
sleazy-fpu-feature-x86_64-support.patch
sleazy-fpu-feature-i386-support.patch
lockdep-annotate-the-blkpg_del_partition-ioctl.patch
delay-accounting-taskstats-interface-send-tgid-once.patch

-
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux