LU-11204 obdclass: remove unprotected access to lu_object
The check of lu_object_is_dying() is done after reference
drop and without lock, so can access freed object if concurrent
thread did final put.
The patch saves object state right before atomic_dec_and_lock()
and checks it after check, so object is not being accessed
Lustre-change: https://review.whamcloud.com/34960
Lustre-commit:
336cf0f2f3a9ce5b11a34aeaeec062a5d5144213
Signed-off-by: Mikhail Pershin <mpershin@whamcloud.com>
Change-Id: I926991f465e7913e5fc150095425bfb5bf07f57f
Reviewed-on: https://review.whamcloud.com/36217
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Andreas Dilger <adilger@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>