From: kernel test robot <lkp@intel.com>
To: oe-kbuild@lists.linux.dev
Cc: lkp@intel.com, Julia Lawall <julia.lawall@inria.fr>
Subject: fs/btrfs/fs.c:94:2-8: preceding lock on line 90
Date: Thu, 01 Jan 2026 09:20:28 +0800 [thread overview]
Message-ID: <202601010939.mnUPfXJe-lkp@intel.com> (raw)
BCC: lkp@intel.com
CC: oe-kbuild-all@lists.linux.dev
CC: linux-kernel@vger.kernel.org
TO: Filipe Manana <fdmanana@suse.com>
CC: David Sterba <dsterba@suse.com>
CC: Qu Wenruo <wqu@suse.com>
CC: Johannes Thumshirn <johannes.thumshirn@wdc.com>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 9528d5c091c59b408a754a1823cf0942069867cc
commit: 0b93369104ac5f65721793e038cafa4b3e58fdba btrfs: move the exclusive operation functions into fs.c
date: 12 months ago
:::::: branch date: 5 hours ago
:::::: commit date: 12 months ago
config: arm-randconfig-r051-20251231 (https://download.01.org/0day-ci/archive/20260101/202601010939.mnUPfXJe-lkp@intel.com/config)
compiler: clang version 22.0.0git (https://github.com/llvm/llvm-project 86b9f90b9574b3a7d15d28a91f6316459dcfa046)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Reported-by: Julia Lawall <julia.lawall@inria.fr>
| Closes: https://lore.kernel.org/r/202601010939.mnUPfXJe-lkp@intel.com/
cocci warnings: (new ones prefixed by >>)
>> fs/btrfs/fs.c:94:2-8: preceding lock on line 90
vim +94 fs/btrfs/fs.c
0b93369104ac5f Filipe Manana 2024-12-16 75
0b93369104ac5f Filipe Manana 2024-12-16 76 /*
0b93369104ac5f Filipe Manana 2024-12-16 77 * Conditionally allow to enter the exclusive operation in case it's compatible
0b93369104ac5f Filipe Manana 2024-12-16 78 * with the running one. This must be paired with btrfs_exclop_start_unlock()
0b93369104ac5f Filipe Manana 2024-12-16 79 * and btrfs_exclop_finish().
0b93369104ac5f Filipe Manana 2024-12-16 80 *
0b93369104ac5f Filipe Manana 2024-12-16 81 * Compatibility:
0b93369104ac5f Filipe Manana 2024-12-16 82 * - the same type is already running
0b93369104ac5f Filipe Manana 2024-12-16 83 * - when trying to add a device and balance has been paused
0b93369104ac5f Filipe Manana 2024-12-16 84 * - not BTRFS_EXCLOP_NONE - this is intentionally incompatible and the caller
0b93369104ac5f Filipe Manana 2024-12-16 85 * must check the condition first that would allow none -> @type
0b93369104ac5f Filipe Manana 2024-12-16 86 */
0b93369104ac5f Filipe Manana 2024-12-16 87 bool btrfs_exclop_start_try_lock(struct btrfs_fs_info *fs_info,
0b93369104ac5f Filipe Manana 2024-12-16 88 enum btrfs_exclusive_operation type)
0b93369104ac5f Filipe Manana 2024-12-16 89 {
0b93369104ac5f Filipe Manana 2024-12-16 @90 spin_lock(&fs_info->super_lock);
0b93369104ac5f Filipe Manana 2024-12-16 91 if (fs_info->exclusive_operation == type ||
0b93369104ac5f Filipe Manana 2024-12-16 92 (fs_info->exclusive_operation == BTRFS_EXCLOP_BALANCE_PAUSED &&
0b93369104ac5f Filipe Manana 2024-12-16 93 type == BTRFS_EXCLOP_DEV_ADD))
0b93369104ac5f Filipe Manana 2024-12-16 @94 return true;
0b93369104ac5f Filipe Manana 2024-12-16 95
0b93369104ac5f Filipe Manana 2024-12-16 96 spin_unlock(&fs_info->super_lock);
0b93369104ac5f Filipe Manana 2024-12-16 97 return false;
0b93369104ac5f Filipe Manana 2024-12-16 98 }
0b93369104ac5f Filipe Manana 2024-12-16 99
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
next reply other threads:[~2026-01-01 1:21 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-01 1:20 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2026-01-01 11:38 fs/btrfs/fs.c:94:2-8: preceding lock on line 90 kernel test robot
2025-04-05 13:06 kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202601010939.mnUPfXJe-lkp@intel.com \
--to=lkp@intel.com \
--cc=julia.lawall@inria.fr \
--cc=oe-kbuild@lists.linux.dev \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.