CC: [email protected] CC: [email protected] TO: David Howells <[email protected]>
tree: https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git fscache-iter head: 47585048b7ec10d66ca6c102b468b9b362910475 commit: 69bc0560f489485c3d20cf7b968303bbfd890cc5 [20/55] fscache: Replace the object management state machine :::::: branch date: 3 months ago :::::: commit date: 3 months ago config: i386-randconfig-s002-20210801 (attached as .config) compiler: gcc-10 (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0 reproduce: # apt-get install sparse # sparse version: v0.6.3-341-g8af24329-dirty # https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git/commit/?id=69bc0560f489485c3d20cf7b968303bbfd890cc5 git remote add dhowells-fs https://git.kernel.org/pub/scm/linux/kernel/git/dhowells/linux-fs.git git fetch --no-tags dhowells-fs fscache-iter git checkout 69bc0560f489485c3d20cf7b968303bbfd890cc5 # save the attached .config to linux build tree make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=i386 SHELL=/bin/bash fs/fscache/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <[email protected]> sparse warnings: (new ones prefixed by >>) >> fs/fscache/cookie.c:363:6: sparse: sparse: context imbalance in >> '__fscache_use_cookie' - different lock contexts for basic block vim +/__fscache_use_cookie +363 fs/fscache/cookie.c ccc4fc3d11e914 David Howells 2009-04-03 358 94d30ae90a00ca David Howells 2013-09-21 359 /* 69bc0560f48948 David Howells 2020-02-06 360 * Start using the cookie for I/O. This prevents the backing object from being 69bc0560f48948 David Howells 2020-02-06 361 * reaped by VM pressure. ccc4fc3d11e914 David Howells 2009-04-03 362 */ 69bc0560f48948 David Howells 2020-02-06 @363 void __fscache_use_cookie(struct fscache_cookie *cookie, bool will_modify) ccc4fc3d11e914 David Howells 2009-04-03 364 { 69bc0560f48948 David Howells 2020-02-06 365 enum fscache_cookie_stage stage; ccc4fc3d11e914 David Howells 2009-04-03 366 69bc0560f48948 David Howells 2020-02-06 367 _enter("c=%08x", cookie->debug_id); ccc4fc3d11e914 David Howells 2009-04-03 368 69bc0560f48948 David Howells 2020-02-06 369 if (WARN(test_bit(FSCACHE_COOKIE_RELINQUISHED, &cookie->flags), 69bc0560f48948 David Howells 2020-02-06 370 "Trying to use relinquished cookie\n")) 69bc0560f48948 David Howells 2020-02-06 371 return; ccc4fc3d11e914 David Howells 2009-04-03 372 69bc0560f48948 David Howells 2020-02-06 373 spin_lock(&cookie->lock); ccc4fc3d11e914 David Howells 2009-04-03 374 69bc0560f48948 David Howells 2020-02-06 375 atomic_inc(&cookie->n_active); ccc4fc3d11e914 David Howells 2009-04-03 376 69bc0560f48948 David Howells 2020-02-06 377 again: 69bc0560f48948 David Howells 2020-02-06 378 stage = cookie->stage; 69bc0560f48948 David Howells 2020-02-06 379 switch (stage) { 69bc0560f48948 David Howells 2020-02-06 380 case FSCACHE_COOKIE_STAGE_QUIESCENT: 69bc0560f48948 David Howells 2020-02-06 381 cookie->stage = FSCACHE_COOKIE_STAGE_INITIALISING; ccc4fc3d11e914 David Howells 2009-04-03 382 69bc0560f48948 David Howells 2020-02-06 383 /* The lookup job holds its own active increment */ 69bc0560f48948 David Howells 2020-02-06 384 atomic_inc(&cookie->n_active); 69bc0560f48948 David Howells 2020-02-06 385 spin_unlock(&cookie->lock); 69bc0560f48948 David Howells 2020-02-06 386 wake_up_cookie_stage(cookie); ccc4fc3d11e914 David Howells 2009-04-03 387 69bc0560f48948 David Howells 2020-02-06 388 fscache_dispatch(cookie, NULL, will_modify, fscache_lookup_object); 69bc0560f48948 David Howells 2020-02-06 389 break; ccc4fc3d11e914 David Howells 2009-04-03 390 69bc0560f48948 David Howells 2020-02-06 391 case FSCACHE_COOKIE_STAGE_INITIALISING: 69bc0560f48948 David Howells 2020-02-06 392 case FSCACHE_COOKIE_STAGE_LOOKING_UP: ccc4fc3d11e914 David Howells 2009-04-03 393 spin_unlock(&cookie->lock); 69bc0560f48948 David Howells 2020-02-06 394 wait_var_event(&cookie->stage, READ_ONCE(cookie->stage) != stage); 69bc0560f48948 David Howells 2020-02-06 395 spin_lock(&cookie->lock); 69bc0560f48948 David Howells 2020-02-06 396 goto again; ccc4fc3d11e914 David Howells 2009-04-03 397 69bc0560f48948 David Howells 2020-02-06 398 case FSCACHE_COOKIE_STAGE_NO_DATA_YET: 69bc0560f48948 David Howells 2020-02-06 399 case FSCACHE_COOKIE_STAGE_ACTIVE: 69bc0560f48948 David Howells 2020-02-06 400 case FSCACHE_COOKIE_STAGE_INVALIDATING: 69bc0560f48948 David Howells 2020-02-06 401 // TODO: Handle will_modify 69bc0560f48948 David Howells 2020-02-06 402 spin_unlock(&cookie->lock); 69bc0560f48948 David Howells 2020-02-06 403 break; ccc4fc3d11e914 David Howells 2009-04-03 404 69bc0560f48948 David Howells 2020-02-06 405 case FSCACHE_COOKIE_STAGE_FAILED: 69bc0560f48948 David Howells 2020-02-06 406 case FSCACHE_COOKIE_STAGE_WITHDRAWING: ccc4fc3d11e914 David Howells 2009-04-03 407 spin_unlock(&cookie->lock); 69bc0560f48948 David Howells 2020-02-06 408 break; ccc4fc3d11e914 David Howells 2009-04-03 409 69bc0560f48948 David Howells 2020-02-06 410 case FSCACHE_COOKIE_STAGE_INDEX: 69bc0560f48948 David Howells 2020-02-06 411 case FSCACHE_COOKIE_STAGE_DROPPED: 69bc0560f48948 David Howells 2020-02-06 412 case FSCACHE_COOKIE_STAGE_RELINQUISHING: 69bc0560f48948 David Howells 2020-02-06 413 spin_unlock(&cookie->lock); 69bc0560f48948 David Howells 2020-02-06 414 WARN(1, "Can't use cookie in stage %u\n", cookie->stage); 69bc0560f48948 David Howells 2020-02-06 415 break; ccc4fc3d11e914 David Howells 2009-04-03 416 } ccc4fc3d11e914 David Howells 2009-04-03 417 69bc0560f48948 David Howells 2020-02-06 418 _leave(""); ccc4fc3d11e914 David Howells 2009-04-03 419 } 69bc0560f48948 David Howells 2020-02-06 420 EXPORT_SYMBOL(__fscache_use_cookie); ccc4fc3d11e914 David Howells 2009-04-03 421 --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/[email protected]
.config.gz
Description: application/gzip
_______________________________________________ kbuild mailing list -- [email protected] To unsubscribe send an email to [email protected]
