函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:block\sed-opal.c Create Date:2022-07-27 19:46:29
Last Modify:2020-03-17 23:36:33 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:setup_locking_range

函数原型:static int setup_locking_range(struct opal_dev *dev, void *data)

返回类型:int

参数:

类型参数名称
struct opal_dev *dev
void *data
1349  setup等于data
1353  lr等于lr
1354  err等于build_locking_range(uid, uid的长度, lr)
1355  如果err则返回:err
1358  如果lr恒等于0则err等于enable_global_lr(dev, uid, setup)
1360  否则
1361  err等于cmd_start(dev, uid, TCG Storage SSC Methods.* Derived from: TCG_Storage_Architecture_Core_Spec_v2.01_r1.00* Section: 6.3 Assigned UIDs[OPAL_SET])
1363  add_token_u8( & err, dev, OPAL_STARTNAME)
1364  add_token_u8( & err, dev, OPAL_VALUES)
1365  add_token_u8( & err, dev, OPAL_STARTLIST)
1367  add_token_u8( & err, dev, OPAL_STARTNAME)
1368  add_token_u8( & err, dev, OPAL_RANGESTART)
1369  add_token_u64( & err, dev, range_start)
1370  add_token_u8( & err, dev, OPAL_ENDNAME)
1372  add_token_u8( & err, dev, OPAL_STARTNAME)
1373  add_token_u8( & err, dev, OPAL_RANGELENGTH)
1374  add_token_u64( & err, dev, range_length)
1375  add_token_u8( & err, dev, OPAL_ENDNAME)
1377  add_token_u8( & err, dev, OPAL_STARTNAME)
1378  add_token_u8( & err, dev, OPAL_READLOCKENABLED)
1379  add_token_u64( & err, dev, !! Read Lock enabled )
1380  add_token_u8( & err, dev, OPAL_ENDNAME)
1382  add_token_u8( & err, dev, OPAL_STARTNAME)
1383  add_token_u8( & err, dev, OPAL_WRITELOCKENABLED)
1384  add_token_u64( & err, dev, !! Write Lock Enabled )
1385  add_token_u8( & err, dev, OPAL_ENDNAME)
1387  add_token_u8( & err, dev, OPAL_ENDLIST)
1388  add_token_u8( & err, dev, OPAL_ENDNAME)
1390  如果err
1391  pr_debug("Error building Setup Locking range command.\n")
1392  返回:err
1395  返回:finalize_and_send(dev, Parses and checks for errors )