We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e5262c9 commit 90ca275Copy full SHA for 90ca275
1 file changed
tests/nvme_test.py
@@ -315,14 +315,9 @@ def get_lba_format_size(self):
315
self.assertTrue(len(json_output['lbafs']) > self.flbas,
316
"Error : could not match the given flbas to an existing lbaf")
317
lbaf_json = json_output['lbafs'][int(self.flbas)]
318
- ms_expo = int(lbaf_json['ms'])
+ ms = int(lbaf_json['ms'])
319
ds_expo = int(lbaf_json['ds'])
320
- ds = 0
321
- ms = 0
322
- if ds_expo > 0:
323
- ds = (1 << ds_expo)
324
- if ms_expo > 0:
325
- ms = (1 << ms_expo)
+ ds = (1 << ds_expo) if ds_expo > 0 else 0
326
return (ds, ms)
327
328
def get_ncap(self):
0 commit comments