diff options
| author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-04-19 08:23:28 -0400 |
|---|---|---|
| committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-04-19 08:23:28 -0400 |
| commit | d5aeee8cb28317ef608ecac421abc4d986d585d2 (patch) | |
| tree | 70ec8ed8891f26e5c58152ffca9924ea1c58fe3a /include/linux/blkdev.h | |
| parent | 32898a145404acbebe3256709e012c2830a2043b (diff) | |
| parent | e816b57a337ea3b755de72bec38c10c864f23015 (diff) | |
Merge tag 'v3.4-rc3' into staging/for_v3.5
* tag 'v3.4-rc3': (3755 commits)
Linux 3.4-rc3
x86-32: fix up strncpy_from_user() sign error
ARM: 7386/1: jump_label: fixup for rename to static_key
ARM: 7384/1: ThumbEE: Disable userspace TEEHBR access for !CONFIG_ARM_THUMBEE
ARM: 7382/1: mm: truncate memory banks to fit in 4GB space for classic MMU
ARM: 7359/2: smp_twd: Only wait for reprogramming on active cpus
PCI: Fix regression in pci_restore_state(), v3
SCSI: Fix error handling when no ULD is attached
ARM: OMAP: clock: cleanup CPUfreq leftovers, fix build errors
ARM: dts: remove blank interrupt-parent properties
ARM: EXYNOS: Fix Kconfig dependencies for device tree enabled machine files
do not export kernel's NULL #define to userspace
ARM: EXYNOS: Remove broken config values for touchscren for NURI board
ARM: EXYNOS: set fix xusbxti clock for NURI and Universal210 boards
ARM: EXYNOS: fix regulator name for NURI board
ARM: SAMSUNG: make SAMSUNG_PM_DEBUG select DEBUG_LL
cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
sparc64: Eliminate obsolete __handle_softirq() function
sparc64: Fix bootup crash on sun4v.
ARM: msm: Fix section mismatches in proc_comm.c
...
Diffstat (limited to 'include/linux/blkdev.h')
| -rw-r--r-- | include/linux/blkdev.h | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index 606cf339bb56..2aa24664a5b5 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h | |||
| @@ -426,14 +426,10 @@ struct request_queue { | |||
| 426 | (1 << QUEUE_FLAG_SAME_COMP) | \ | 426 | (1 << QUEUE_FLAG_SAME_COMP) | \ |
| 427 | (1 << QUEUE_FLAG_ADD_RANDOM)) | 427 | (1 << QUEUE_FLAG_ADD_RANDOM)) |
| 428 | 428 | ||
| 429 | static inline int queue_is_locked(struct request_queue *q) | 429 | static inline void queue_lockdep_assert_held(struct request_queue *q) |
| 430 | { | 430 | { |
| 431 | #ifdef CONFIG_SMP | 431 | if (q->queue_lock) |
| 432 | spinlock_t *lock = q->queue_lock; | 432 | lockdep_assert_held(q->queue_lock); |
| 433 | return lock && spin_is_locked(lock); | ||
| 434 | #else | ||
| 435 | return 1; | ||
| 436 | #endif | ||
| 437 | } | 433 | } |
| 438 | 434 | ||
| 439 | static inline void queue_flag_set_unlocked(unsigned int flag, | 435 | static inline void queue_flag_set_unlocked(unsigned int flag, |
| @@ -445,7 +441,7 @@ static inline void queue_flag_set_unlocked(unsigned int flag, | |||
| 445 | static inline int queue_flag_test_and_clear(unsigned int flag, | 441 | static inline int queue_flag_test_and_clear(unsigned int flag, |
| 446 | struct request_queue *q) | 442 | struct request_queue *q) |
| 447 | { | 443 | { |
| 448 | WARN_ON_ONCE(!queue_is_locked(q)); | 444 | queue_lockdep_assert_held(q); |
| 449 | 445 | ||
| 450 | if (test_bit(flag, &q->queue_flags)) { | 446 | if (test_bit(flag, &q->queue_flags)) { |
| 451 | __clear_bit(flag, &q->queue_flags); | 447 | __clear_bit(flag, &q->queue_flags); |
| @@ -458,7 +454,7 @@ static inline int queue_flag_test_and_clear(unsigned int flag, | |||
| 458 | static inline int queue_flag_test_and_set(unsigned int flag, | 454 | static inline int queue_flag_test_and_set(unsigned int flag, |
| 459 | struct request_queue *q) | 455 | struct request_queue *q) |
| 460 | { | 456 | { |
| 461 | WARN_ON_ONCE(!queue_is_locked(q)); | 457 | queue_lockdep_assert_held(q); |
| 462 | 458 | ||
| 463 | if (!test_bit(flag, &q->queue_flags)) { | 459 | if (!test_bit(flag, &q->queue_flags)) { |
| 464 | __set_bit(flag, &q->queue_flags); | 460 | __set_bit(flag, &q->queue_flags); |
| @@ -470,7 +466,7 @@ static inline int queue_flag_test_and_set(unsigned int flag, | |||
| 470 | 466 | ||
| 471 | static inline void queue_flag_set(unsigned int flag, struct request_queue *q) | 467 | static inline void queue_flag_set(unsigned int flag, struct request_queue *q) |
| 472 | { | 468 | { |
| 473 | WARN_ON_ONCE(!queue_is_locked(q)); | 469 | queue_lockdep_assert_held(q); |
| 474 | __set_bit(flag, &q->queue_flags); | 470 | __set_bit(flag, &q->queue_flags); |
| 475 | } | 471 | } |
| 476 | 472 | ||
| @@ -487,7 +483,7 @@ static inline int queue_in_flight(struct request_queue *q) | |||
| 487 | 483 | ||
| 488 | static inline void queue_flag_clear(unsigned int flag, struct request_queue *q) | 484 | static inline void queue_flag_clear(unsigned int flag, struct request_queue *q) |
| 489 | { | 485 | { |
| 490 | WARN_ON_ONCE(!queue_is_locked(q)); | 486 | queue_lockdep_assert_held(q); |
| 491 | __clear_bit(flag, &q->queue_flags); | 487 | __clear_bit(flag, &q->queue_flags); |
| 492 | } | 488 | } |
| 493 | 489 | ||
