Whamcloud - gitweb
LU-9930 llite: only clear lli_sai if the setter 94/28794/4
authorBruno Faccini <bruno.faccini@intel.com>
Wed, 30 Aug 2017 09:37:03 +0000 (11:37 +0200)
committerOleg Drokin <oleg.drokin@intel.com>
Mon, 18 Sep 2017 05:24:59 +0000 (05:24 +0000)
commitf4a0ebe28e88cbdd79061fad275cb9494fdba225
tree4238c05f002934e77f31e605220a2a6a76e6a793
parentb5ee02111c30d12fcf3a51b64fae326cb0d8d331
LU-9930 llite: only clear lli_sai if the setter

Previous to this patch, start_statahead_thread() was
unconditionnally clearing lli->lli_sai upon error, leading
to crash upon racy scenario where it has just been set in/by
another thread context.
Now, only clear lli_sai if current thread has set it.

Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Change-Id: I555febfad3494c9dd90eeb72d6dd9157428179ea
Reviewed-on: https://review.whamcloud.com/28794
Reviewed-by: Fan Yong <fan.yong@intel.com>
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>
Reviewed-by: Lai Siyao <lai.siyao@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
lustre/llite/statahead.c