Skip to contentSkip to conversation

linux-next: build failure after merge of the tip tree

PATCH Stephen Rothwell 2 participants 4 messages Jul 9, 2019 – Jul 10, 2019

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

Hi all,

After merging the tip tree, today's linux-next build (x86_64 allmodconfig) failed like this:

drivers/block/rbd.c: In function 'wake_lock_waiters':
drivers/block/rbd.c:3933:2: error: implicit declaration of function 'lockdep_assert_held_exclusive'; did you mean 'lockdep_assert_held_write'? [-Werror=implicit-function-declaration]
lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lockdep_assert_held_write

Caused by commit

9ffbe8ac05db ("locking/lockdep: Rename lockdep_assert_held_exclusive() -> lockdep_assert_held_write()")

interacting with commits

637cd060537d ("rbd: new exclusive lock wait/wake code") a2b1da09793d ("rbd: lock should be quiesced on reacquire")

from the ceph tree.

I have added the following merge fix patch for today.

From: Stephen Rothwell <[email protected]>
Date: Tue, 9 Jul 2019 16:46:12 +1000
Subject: [PATCH] rbd: fix up for lockdep_assert_held_exclusive rename

---
 drivers/block/rbd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/block/rbd.c +2 -2
index 723c3ef4bd59..02216fbdb854 100644
@@ -3930,7 +3930,7 @@ static void wake_lock_waiters(struct rbd_device *rbd_dev, int result)
 	struct rbd_img_request *img_req;
 
 	dout("%s rbd_dev %p result %d\n", __func__, rbd_dev, result);
-	lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
+	lockdep_assert_held_write(&rbd_dev->lock_rwsem);
 
 	cancel_delayed_work(&rbd_dev->lock_dwork);
 	if (!completion_done(&rbd_dev->acquire_wait)) {
@@ -4209,7 +4209,7 @@ static bool rbd_quiesce_lock(struct rbd_device *rbd_dev)
 	bool need_wait;
 
 	dout("%s rbd_dev %p\n", __func__, rbd_dev);
-	lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
+	lockdep_assert_held_write(&rbd_dev->lock_rwsem);
 
 	if (rbd_dev->lock_state != RBD_LOCK_STATE_LOCKED)
 		return false;
Signature · 5 lines
2.20.1

-- 
Cheers,
Stephen Rothwell
#1 lore raw

Hi all,

Quoted 46 lines · On Tue, 9 Jul 2019 16:54:59 +1000 Stephen Rothwell <[email protected]> wrote:

After merging the tip tree, today's linux-next build (x86_64 allmodconfig) failed like this:

drivers/block/rbd.c: In function 'wake_lock_waiters':
drivers/block/rbd.c:3933:2: error: implicit declaration of function 'lockdep_assert_held_exclusive'; did you mean 'lockdep_assert_held_write'? [-Werror=implicit-function-declaration]
lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lockdep_assert_held_write

Caused by commit

9ffbe8ac05db ("locking/lockdep: Rename lockdep_assert_held_exclusive() -> lockdep_assert_held_write()")

interacting with commits

637cd060537d ("rbd: new exclusive lock wait/wake code") a2b1da09793d ("rbd: lock should be quiesced on reacquire")

from the ceph tree.

I have added the following merge fix patch for today.

From: Stephen Rothwell <[email protected]>
Date: Tue, 9 Jul 2019 16:46:12 +1000
Subject: [PATCH] rbd: fix up for lockdep_assert_held_exclusive rename

---
 drivers/block/rbd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/block/rbd.c +1 -1
index 723c3ef4bd59..02216fbdb854 100644
@@ -3930,7 +3930,7 @@ static void wake_lock_waiters(struct rbd_device *rbd_dev, int result)
 	struct rbd_img_request *img_req;
 
 	dout("%s rbd_dev %p result %d\n", __func__, rbd_dev, result);
-	lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
+	lockdep_assert_held_write(&rbd_dev->lock_rwsem);
 
 	cancel_delayed_work(&rbd_dev->lock_dwork);
 	if (!completion_done(&rbd_dev->acquire_wait)) {

drivers/block/rbd.c static bool rbd_quiesce_lock(struct rbd_device *rbd_dev) · line 4215

Quoted 8 lines
drivers/block/rbd.c +1 -1
@@ -4209,7 +4209,7 @@ static bool rbd_quiesce_lock(struct rbd_device *rbd_dev)
 	bool need_wait;
 
 	dout("%s rbd_dev %p\n", __func__, rbd_dev);
-	lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
+	lockdep_assert_held_write(&rbd_dev->lock_rwsem);
 
 	if (rbd_dev->lock_state != RBD_LOCK_STATE_LOCKED)
 		return false;

This fix now needs to be applied to the merge of the ceph tree.

Signature · 2 lines
Cheers,
Stephen Rothwell
maintainer
#2 lore raw
Quoted 52 lines · Stephen Rothwell

Hi all,

Quoted 48 lines · On Tue, 9 Jul 2019 16:54:59 +1000 Stephen Rothwell <[email protected]> wrote:

After merging the tip tree, today's linux-next build (x86_64 allmodconfig) failed like this:

drivers/block/rbd.c: In function 'wake_lock_waiters':
drivers/block/rbd.c:3933:2: error: implicit declaration of function 'lockdep_assert_held_exclusive'; did you mean 'lockdep_assert_held_write'? [-Werror=implicit-function-declaration]
lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lockdep_assert_held_write

Caused by commit

9ffbe8ac05db ("locking/lockdep: Rename lockdep_assert_held_exclusive() -> lockdep_assert_held_write()")

interacting with commits

637cd060537d ("rbd: new exclusive lock wait/wake code") a2b1da09793d ("rbd: lock should be quiesced on reacquire")

from the ceph tree.

I have added the following merge fix patch for today.

From: Stephen Rothwell <[email protected]>
Date: Tue, 9 Jul 2019 16:46:12 +1000
Subject: [PATCH] rbd: fix up for lockdep_assert_held_exclusive rename

---
 drivers/block/rbd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/block/rbd.c +1 -1
index 723c3ef4bd59..02216fbdb854 100644
@@ -3930,7 +3930,7 @@ static void wake_lock_waiters(struct rbd_device *rbd_dev, int result)
      struct rbd_img_request *img_req;
 
      dout("%s rbd_dev %p result %d\n", __func__, rbd_dev, result);
-     lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
+     lockdep_assert_held_write(&rbd_dev->lock_rwsem);
 
      cancel_delayed_work(&rbd_dev->lock_dwork);
      if (!completion_done(&rbd_dev->acquire_wait)) {
@@ -4209,7 +4209,7 @@ static bool rbd_quiesce_lock(struct rbd_device *rbd_dev)
      bool need_wait;
 
Quoted 8 lines

drivers/block/rbd.c static bool rbd_quiesce_lock(struct rbd_device *rbd_dev) · line 4215

Quoted 6 lines
drivers/block/rbd.c +1 -1
      dout("%s rbd_dev %p\n", __func__, rbd_dev);
-     lockdep_assert_held_exclusive(&rbd_dev->lock_rwsem);
+     lockdep_assert_held_write(&rbd_dev->lock_rwsem);
 
      if (rbd_dev->lock_state != RBD_LOCK_STATE_LOCKED)
              return false;

This fix now needs to be applied to the merge of the ceph tree.

Hi Stephen,

Yes, that is what I figured would happen. I assume you would keep carrying this fixup until the ceph tree is merged.

Thanks,

Ilya

#3 lore raw

Hi Ilya,

Quoted 3 lines · On Wed, 10 Jul 2019 20:21:33 +0200 Ilya Dryomov <[email protected]> wrote:

Yes, that is what I figured would happen. I assume you would keep carrying this fixup until the ceph tree is merged.

Of course.

Signature · 2 lines
Cheers,
Stephen Rothwell