Tweaked tag encoding/naming for btrees/branches
LFSR_TAG_BNAME => LFSR_TAG_BRANCH LFSR_TAG_BRANCH => LFSR_TAG_BTREE Maybe this will be a problem in the future if our branch structure is not the same as a standalone btree, but I don't really see that happening.
This commit is contained in:
+4
-4
@@ -22,13 +22,13 @@ TAG_SUPERMAGIC = 0x0030
|
||||
TAG_SUPERCONFIG = 0x0040
|
||||
TAG_SUPERMDIR = 0x0110
|
||||
TAG_NAME = 0x1000
|
||||
TAG_BNAME = 0x1000
|
||||
TAG_BRANCH = 0x1000
|
||||
TAG_REG = 0x1010
|
||||
TAG_DIR = 0x1020
|
||||
TAG_STRUCT = 0x3000
|
||||
TAG_INLINED = 0x3000
|
||||
TAG_BLOCK = 0x3100
|
||||
TAG_BRANCH = 0x3200
|
||||
TAG_MDIR = 0x3200
|
||||
TAG_BTREE = 0x3300
|
||||
TAG_UATTR = 0x4000
|
||||
TAG_ALT = 0x0008
|
||||
@@ -119,7 +119,7 @@ def tagrepr(tag, w, size, off=None):
|
||||
elif (tag & 0xf00c) == TAG_NAME:
|
||||
return '%s%s%s %d' % (
|
||||
'rm' if tag & 0x2 else '',
|
||||
'bname' if (tag & 0xfffe) == TAG_BNAME
|
||||
'branch' if (tag & 0xfffe) == TAG_BRANCH
|
||||
else 'reg' if (tag & 0xfffe) == TAG_REG
|
||||
else 'dir' if (tag & 0xfffe) == TAG_DIR
|
||||
else 'name 0x%02x' % ((tag & 0x0ff0) >> 4),
|
||||
@@ -130,7 +130,7 @@ def tagrepr(tag, w, size, off=None):
|
||||
'rm' if tag & 0x2 else '',
|
||||
'inlined' if (tag & 0xfffe) == TAG_INLINED
|
||||
else 'block' if (tag & 0xfffe) == TAG_BLOCK
|
||||
else 'branch' if (tag & 0xfffe) == TAG_BRANCH
|
||||
else 'mdir' if (tag & 0xfffe) == TAG_MDIR
|
||||
else 'btree' if (tag & 0xfffe) == TAG_BTREE
|
||||
else 'struct 0x%02x' % ((tag & 0x0ff0) >> 4),
|
||||
' w%d' % w if w else '',
|
||||
|
||||
Reference in New Issue
Block a user