[LU-6693] object_update_param_get inconsistent return value Created: 05/Jun/15  Updated: 04/Dec/15  Resolved: 04/Dec/15

Status: Resolved
Project: Lustre
Component/s: None
Affects Version/s: None
Fix Version/s: Lustre 2.8.0

Type: Bug Priority: Critical
Reporter: Oleg Drokin Assignee: Di Wang
Resolution: Fixed Votes: 0
Labels: None

Severity: 3
Rank (Obsolete): 9223372036854775807

 Description   

Recent patch http://review.whamcloud.com/14787 added a code to object_update_param_get that returns PTR_ERR. But before it only returned NUL on error which all callers expect.
Now every caller is broken as they don't expect non NULL errors.

E.g. in out_xattr_set, out_read (twice). in target/out_handler.c

I think we need to convert object_update_param_get back to returning just NULL on error.



 Comments   
Comment by Di Wang [ 14/Jul/15 ]

http://review.whamcloud.com/#/c/12825/ has fixed this issue.

Comment by Oleg Drokin [ 19/Jul/15 ]

This is not a full fix.
Remaining problems:

/home/green/smt/git/lustre-release/lustre/ptlrpc/../../lustre/target/out_lib.c:204 out_create_pack() error: 'obdo' dereferencing possible ERR_PTR()
/home/green/smt/git/lustre-release/lustre/ptlrpc/../../lustre/target/out_lib.c:252 out_attr_set_pack() error: 'obdo' dereferencing possible ERR_PTR()

Comment by Gerrit Updater [ 14/Sep/15 ]

wangdi (di.wang@intel.com) uploaded a new patch: http://review.whamcloud.com/16417
Subject: LU-6693 out: replace assert with error check in out_xx()
Project: fs/lustre-release
Branch: master
Current Patch Set: 1
Commit: 942234aace34b48dc06cdbe0f112662f4eeba214

Comment by Gerrit Updater [ 02/Dec/15 ]

Oleg Drokin (oleg.drokin@intel.com) merged in patch http://review.whamcloud.com/16417/
Subject: LU-6693 out: not return NULL in object_update_param_get
Project: fs/lustre-release
Branch: master
Current Patch Set:
Commit: d059b3c01a9784b8da61ea99fb746e949d681b7e

Comment by Peter Jones [ 04/Dec/15 ]

Landed for 2.8

Generated at Sat Feb 10 02:02:25 UTC 2024 using Jira 9.4.14#940014-sha1:734e6822bbf0d45eff9af51f82432957f73aa32c.