diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2017-09-04 19:52:56 +0200 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2017-09-04 20:25:22 +0200 |
| commit | e707c97f9a98166166f6ac1b11cd9a617aab8313 (patch) | |
| tree | a7c7f9fe625d23610dd195e683d4387a8a155a54 /sys | |
| parent | 54a92e90e0cfa9637bb5c4db4ffb4392e22705d5 (diff) | |
pkg/compiler: move bitfield marking from sys
Diffstat (limited to 'sys')
| -rw-r--r-- | sys/align.go | 41 | ||||
| -rw-r--r-- | sys/decl.go | 2 | ||||
| -rw-r--r-- | sys/sys_386.go | 76 | ||||
| -rw-r--r-- | sys/sys_amd64.go | 76 | ||||
| -rw-r--r-- | sys/sys_arm.go | 76 | ||||
| -rw-r--r-- | sys/sys_arm64.go | 76 | ||||
| -rw-r--r-- | sys/sys_ppc64le.go | 76 |
7 files changed, 191 insertions, 232 deletions
diff --git a/sys/align.go b/sys/align.go index 08f1acb03..1be1ccc82 100644 --- a/sys/align.go +++ b/sys/align.go @@ -22,7 +22,6 @@ func initAlign() { rec(f) } t1.Varlen() // dummy call to initialize t1.varlen - markBitfields(t1) addAlignment(t1) } case *UnionType: @@ -42,46 +41,6 @@ func initAlign() { } } -func setBitfieldOffset(t Type, offset uint64, last bool) { - switch t1 := t.(type) { - case *IntType: - t1.BitfieldOff = offset - t1.BitfieldLst = last - case *ConstType: - t1.BitfieldOff = offset - t1.BitfieldLst = last - case *LenType: - t1.BitfieldOff = offset - t1.BitfieldLst = last - case *FlagsType: - t1.BitfieldOff = offset - t1.BitfieldLst = last - case *ProcType: - t1.BitfieldOff = offset - t1.BitfieldLst = last - default: - panic(fmt.Sprintf("type %+v can't be a bitfield", t1)) - } -} - -func markBitfields(t *StructType) { - var bfOffset uint64 - for i, f := range t.Fields { - if f.BitfieldLength() == 0 { - continue - } - off, last := bfOffset, false - bfOffset += f.BitfieldLength() - if i == len(t.Fields)-1 || // Last bitfield in a group, if last field of the struct... - t.Fields[i+1].BitfieldLength() == 0 || // or next field is not a bitfield... - f.Size() != t.Fields[i+1].Size() || // or next field is of different size... - bfOffset+t.Fields[i+1].BitfieldLength() > f.Size()*8 { // or next field does not fit into the current group. - last, bfOffset = true, 0 - } - setBitfieldOffset(f, off, last) - } -} - func addAlignment(t *StructType) { if t.IsPacked { // If a struct is packed, statically sized and has explicitly set alignment, add a padding. diff --git a/sys/decl.go b/sys/decl.go index fe5744648..4295b014c 100644 --- a/sys/decl.go +++ b/sys/decl.go @@ -123,9 +123,9 @@ func (t *ResourceType) Align() uint64 { type IntTypeCommon struct { TypeCommon TypeSize uint64 - BigEndian bool BitfieldOff uint64 BitfieldLen uint64 + BigEndian bool BitfieldLst bool } diff --git a/sys/sys_386.go b/sys/sys_386.go index f29514dce..61d65f2c1 100644 --- a/sys/sys_386.go +++ b/sys/sys_386.go @@ -482,11 +482,11 @@ var structFields = []*StructFields{ &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "dst_port"}, TypeSize: 2, BigEndian: true}, ValuesStart: 20000, ValuesPerProc: 4}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "offset"}, TypeSize: 1}, ByteSize: 4, Buf: "parent"}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "cscov"}, TypeSize: 1, BitfieldLen: 4}, Val: 1}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "parent", Protocol: 33}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "x"}, TypeSize: 1, BitfieldLen: 1}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldLen: 3}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldOff: 5, BitfieldLen: 3, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "seq_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "ack_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, @@ -1488,9 +1488,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmp_ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "total_len"}, TypeSize: 2, BigEndian: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -1602,7 +1602,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmpv6_ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "length"}, TypeSize: 2, BigEndian: true}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2062,9 +2062,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "total_len"}, TypeSize: 2, BigEndian: true}, Buf: "ipv4_packet"}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -2136,7 +2136,7 @@ var structFields = []*StructFields{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 1}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "pointer"}, TypeSize: 1}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_flags", FldName: "flg"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "timestamps"}, Type: &StructType{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_timestamp"}, IsPacked: true}}, }}, {Key: StructKey{Name: "ipv4_option_timestamp_timestamp"}, Fields: []Type{ @@ -2255,8 +2255,8 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_hi"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "m_flag"}, TypeSize: 1, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldLen: 5}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 2}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldOff: 3, BitfieldLen: 5, BitfieldLst: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "identification"}, TypeSize: 4}, ValuesStart: 100, ValuesPerProc: 4}, }}, {Key: StructKey{Name: "ipv6_hopots_ext_header"}, Fields: []Type{ @@ -2275,7 +2275,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 2, BigEndian: true}, Buf: "payload"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2878,13 +2878,13 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "kvm_setup_opt_vmwrite"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ"}, TypeSize: 8}, Val: 8}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "sz"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldLen: 5}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldLen: 48}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldOff: 1, BitfieldLen: 5}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldOff: 6, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldOff: 10, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldOff: 12, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldOff: 13, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldOff: 15, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldOff: 16, BitfieldLen: 48, BitfieldLst: true}}, }}, {Key: StructKey{Name: "kvm_setup_opt_x86"}, Fields: []Type{ &StructType{TypeCommon: TypeCommon{TypeName: "kvm_setup_opt_cr0", FldName: "cr0"}}, @@ -4828,13 +4828,13 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, }}, {Key: StructKey{Name: "syz_bf_struct0"}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10}, Vals: []uint64{0, 1, 2}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10, BitfieldLst: true}, Vals: []uint64{0, 1, 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f2"}, TypeSize: 2, BitfieldLen: 5}, Val: 66}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldLen: 6}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15}, Val: 66}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11}, Buf: "parent"}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BigEndian: true, BitfieldLen: 11}, Buf: "parent"}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldOff: 5, BitfieldLen: 6, BitfieldLst: true}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15, BitfieldLst: true}, Val: 66}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11, BitfieldLst: true}, Buf: "parent"}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BitfieldLen: 11, BigEndian: true, BitfieldLst: true}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f7"}, TypeSize: 1}}, }}, {Key: StructKey{Name: "syz_bf_struct1"}, Fields: []Type{ @@ -4843,15 +4843,15 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_bf_struct1_internal"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, }}, {Key: StructKey{Name: "syz_csum_encode"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f0"}, TypeSize: 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "f1"}, TypeSize: 2, BigEndian: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f2"}, Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32"}, TypeSize: 4}}, Kind: 1, RangeEnd: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f3"}, TypeSize: 1, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f5"}, Kind: 1, RangeBegin: 4, RangeEnd: 4}, }}, {Key: StructKey{Name: "syz_csum_icmp_packet"}, Fields: []Type{ @@ -4925,12 +4925,12 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_length_bf_struct_inner"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f4"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldOff: 16, BitfieldLen: 16, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f7"}, TypeSize: 4}, Buf: "parent"}, }}, {Key: StructKey{Name: "syz_length_bytesize2_struct"}, Fields: []Type{ @@ -5140,8 +5140,8 @@ var structFields = []*StructFields{ &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "seq_num"}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "ack_num"}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ns"}, TypeSize: 1, BitfieldLen: 1}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldLen: 3}}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 3}}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, ByteSize: 4, Buf: "parent"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "tcp_flags", FldName: "flags"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 8, 16, 32, 64, 128, 194}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "window_size"}, TypeSize: 2, BigEndian: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "tcp_packet", Protocol: 6}, @@ -5550,14 +5550,14 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "vlan_tag_ad"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 37120}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vlan_tag_q"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 33024}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vt_consize"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "rows"}, TypeSize: 2}}, diff --git a/sys/sys_amd64.go b/sys/sys_amd64.go index 7c5beaf04..5a0403a84 100644 --- a/sys/sys_amd64.go +++ b/sys/sys_amd64.go @@ -482,11 +482,11 @@ var structFields = []*StructFields{ &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "dst_port"}, TypeSize: 2, BigEndian: true}, ValuesStart: 20000, ValuesPerProc: 4}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "offset"}, TypeSize: 1}, ByteSize: 4, Buf: "parent"}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "cscov"}, TypeSize: 1, BitfieldLen: 4}, Val: 1}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "parent", Protocol: 33}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "x"}, TypeSize: 1, BitfieldLen: 1}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldLen: 3}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldOff: 5, BitfieldLen: 3, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "seq_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "ack_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, @@ -1488,9 +1488,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmp_ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "total_len"}, TypeSize: 2, BigEndian: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -1602,7 +1602,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmpv6_ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "length"}, TypeSize: 2, BigEndian: true}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2062,9 +2062,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "total_len"}, TypeSize: 2, BigEndian: true}, Buf: "ipv4_packet"}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -2136,7 +2136,7 @@ var structFields = []*StructFields{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 1}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "pointer"}, TypeSize: 1}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_flags", FldName: "flg"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "timestamps"}, Type: &StructType{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_timestamp"}, IsPacked: true}}, }}, {Key: StructKey{Name: "ipv4_option_timestamp_timestamp"}, Fields: []Type{ @@ -2255,8 +2255,8 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_hi"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "m_flag"}, TypeSize: 1, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldLen: 5}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 2}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldOff: 3, BitfieldLen: 5, BitfieldLst: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "identification"}, TypeSize: 4}, ValuesStart: 100, ValuesPerProc: 4}, }}, {Key: StructKey{Name: "ipv6_hopots_ext_header"}, Fields: []Type{ @@ -2275,7 +2275,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 2, BigEndian: true}, Buf: "payload"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2878,13 +2878,13 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "kvm_setup_opt_vmwrite"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ"}, TypeSize: 8}, Val: 8}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "sz"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldLen: 5}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldLen: 48}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldOff: 1, BitfieldLen: 5}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldOff: 6, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldOff: 10, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldOff: 12, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldOff: 13, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldOff: 15, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldOff: 16, BitfieldLen: 48, BitfieldLst: true}}, }}, {Key: StructKey{Name: "kvm_setup_opt_x86"}, Fields: []Type{ &StructType{TypeCommon: TypeCommon{TypeName: "kvm_setup_opt_cr0", FldName: "cr0"}}, @@ -4828,13 +4828,13 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, }}, {Key: StructKey{Name: "syz_bf_struct0"}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10}, Vals: []uint64{0, 1, 2}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10, BitfieldLst: true}, Vals: []uint64{0, 1, 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f2"}, TypeSize: 2, BitfieldLen: 5}, Val: 66}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldLen: 6}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15}, Val: 66}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11}, Buf: "parent"}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BigEndian: true, BitfieldLen: 11}, Buf: "parent"}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldOff: 5, BitfieldLen: 6, BitfieldLst: true}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15, BitfieldLst: true}, Val: 66}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11, BitfieldLst: true}, Buf: "parent"}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BitfieldLen: 11, BigEndian: true, BitfieldLst: true}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f7"}, TypeSize: 1}}, }}, {Key: StructKey{Name: "syz_bf_struct1"}, Fields: []Type{ @@ -4843,15 +4843,15 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_bf_struct1_internal"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, }}, {Key: StructKey{Name: "syz_csum_encode"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f0"}, TypeSize: 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "f1"}, TypeSize: 2, BigEndian: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f2"}, Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32"}, TypeSize: 4}}, Kind: 1, RangeEnd: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f3"}, TypeSize: 1, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f5"}, Kind: 1, RangeBegin: 4, RangeEnd: 4}, }}, {Key: StructKey{Name: "syz_csum_icmp_packet"}, Fields: []Type{ @@ -4925,12 +4925,12 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_length_bf_struct_inner"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f4"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldOff: 16, BitfieldLen: 16, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f7"}, TypeSize: 4}, Buf: "parent"}, }}, {Key: StructKey{Name: "syz_length_bytesize2_struct"}, Fields: []Type{ @@ -5140,8 +5140,8 @@ var structFields = []*StructFields{ &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "seq_num"}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "ack_num"}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ns"}, TypeSize: 1, BitfieldLen: 1}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldLen: 3}}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 3}}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, ByteSize: 4, Buf: "parent"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "tcp_flags", FldName: "flags"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 8, 16, 32, 64, 128, 194}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "window_size"}, TypeSize: 2, BigEndian: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "tcp_packet", Protocol: 6}, @@ -5550,14 +5550,14 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "vlan_tag_ad"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 37120}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vlan_tag_q"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 33024}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vt_consize"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "rows"}, TypeSize: 2}}, diff --git a/sys/sys_arm.go b/sys/sys_arm.go index a15465aca..b46740a5f 100644 --- a/sys/sys_arm.go +++ b/sys/sys_arm.go @@ -482,11 +482,11 @@ var structFields = []*StructFields{ &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "dst_port"}, TypeSize: 2, BigEndian: true}, ValuesStart: 20000, ValuesPerProc: 4}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "offset"}, TypeSize: 1}, ByteSize: 4, Buf: "parent"}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "cscov"}, TypeSize: 1, BitfieldLen: 4}, Val: 1}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "parent", Protocol: 33}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "x"}, TypeSize: 1, BitfieldLen: 1}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldLen: 3}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldOff: 5, BitfieldLen: 3, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "seq_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "ack_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, @@ -1488,9 +1488,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmp_ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "total_len"}, TypeSize: 2, BigEndian: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -1602,7 +1602,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmpv6_ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "length"}, TypeSize: 2, BigEndian: true}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2062,9 +2062,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "total_len"}, TypeSize: 2, BigEndian: true}, Buf: "ipv4_packet"}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -2136,7 +2136,7 @@ var structFields = []*StructFields{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 1}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "pointer"}, TypeSize: 1}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_flags", FldName: "flg"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "timestamps"}, Type: &StructType{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_timestamp"}, IsPacked: true}}, }}, {Key: StructKey{Name: "ipv4_option_timestamp_timestamp"}, Fields: []Type{ @@ -2255,8 +2255,8 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_hi"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "m_flag"}, TypeSize: 1, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldLen: 5}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 2}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldOff: 3, BitfieldLen: 5, BitfieldLst: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "identification"}, TypeSize: 4}, ValuesStart: 100, ValuesPerProc: 4}, }}, {Key: StructKey{Name: "ipv6_hopots_ext_header"}, Fields: []Type{ @@ -2275,7 +2275,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 2, BigEndian: true}, Buf: "payload"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2878,13 +2878,13 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "kvm_setup_opt_vmwrite"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ"}, TypeSize: 8}, Val: 8}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "sz"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldLen: 5}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldLen: 48}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldOff: 1, BitfieldLen: 5}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldOff: 6, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldOff: 10, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldOff: 12, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldOff: 13, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldOff: 15, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldOff: 16, BitfieldLen: 48, BitfieldLst: true}}, }}, {Key: StructKey{Name: "kvm_setup_opt_x86"}, Fields: []Type{ &StructType{TypeCommon: TypeCommon{TypeName: "kvm_setup_opt_cr0", FldName: "cr0"}}, @@ -4828,13 +4828,13 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, }}, {Key: StructKey{Name: "syz_bf_struct0"}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10}, Vals: []uint64{0, 1, 2}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10, BitfieldLst: true}, Vals: []uint64{0, 1, 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f2"}, TypeSize: 2, BitfieldLen: 5}, Val: 66}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldLen: 6}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15}, Val: 66}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11}, Buf: "parent"}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BigEndian: true, BitfieldLen: 11}, Buf: "parent"}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldOff: 5, BitfieldLen: 6, BitfieldLst: true}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15, BitfieldLst: true}, Val: 66}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11, BitfieldLst: true}, Buf: "parent"}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BitfieldLen: 11, BigEndian: true, BitfieldLst: true}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f7"}, TypeSize: 1}}, }}, {Key: StructKey{Name: "syz_bf_struct1"}, Fields: []Type{ @@ -4843,15 +4843,15 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_bf_struct1_internal"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, }}, {Key: StructKey{Name: "syz_csum_encode"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f0"}, TypeSize: 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "f1"}, TypeSize: 2, BigEndian: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f2"}, Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32"}, TypeSize: 4}}, Kind: 1, RangeEnd: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f3"}, TypeSize: 1, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f5"}, Kind: 1, RangeBegin: 4, RangeEnd: 4}, }}, {Key: StructKey{Name: "syz_csum_icmp_packet"}, Fields: []Type{ @@ -4925,12 +4925,12 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_length_bf_struct_inner"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f4"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldOff: 16, BitfieldLen: 16, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f7"}, TypeSize: 4}, Buf: "parent"}, }}, {Key: StructKey{Name: "syz_length_bytesize2_struct"}, Fields: []Type{ @@ -5140,8 +5140,8 @@ var structFields = []*StructFields{ &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "seq_num"}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "ack_num"}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ns"}, TypeSize: 1, BitfieldLen: 1}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldLen: 3}}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 3}}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, ByteSize: 4, Buf: "parent"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "tcp_flags", FldName: "flags"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 8, 16, 32, 64, 128, 194}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "window_size"}, TypeSize: 2, BigEndian: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "tcp_packet", Protocol: 6}, @@ -5550,14 +5550,14 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "vlan_tag_ad"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 37120}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vlan_tag_q"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 33024}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vt_consize"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "rows"}, TypeSize: 2}}, diff --git a/sys/sys_arm64.go b/sys/sys_arm64.go index d4616b469..35f037ae0 100644 --- a/sys/sys_arm64.go +++ b/sys/sys_arm64.go @@ -482,11 +482,11 @@ var structFields = []*StructFields{ &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "dst_port"}, TypeSize: 2, BigEndian: true}, ValuesStart: 20000, ValuesPerProc: 4}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "offset"}, TypeSize: 1}, ByteSize: 4, Buf: "parent"}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "cscov"}, TypeSize: 1, BitfieldLen: 4}, Val: 1}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "parent", Protocol: 33}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "x"}, TypeSize: 1, BitfieldLen: 1}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldLen: 3}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldOff: 5, BitfieldLen: 3, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "seq_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "ack_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, @@ -1488,9 +1488,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmp_ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "total_len"}, TypeSize: 2, BigEndian: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -1602,7 +1602,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmpv6_ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "length"}, TypeSize: 2, BigEndian: true}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2062,9 +2062,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "total_len"}, TypeSize: 2, BigEndian: true}, Buf: "ipv4_packet"}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -2136,7 +2136,7 @@ var structFields = []*StructFields{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 1}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "pointer"}, TypeSize: 1}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_flags", FldName: "flg"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "timestamps"}, Type: &StructType{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_timestamp"}, IsPacked: true}}, }}, {Key: StructKey{Name: "ipv4_option_timestamp_timestamp"}, Fields: []Type{ @@ -2255,8 +2255,8 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_hi"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "m_flag"}, TypeSize: 1, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldLen: 5}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 2}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldOff: 3, BitfieldLen: 5, BitfieldLst: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "identification"}, TypeSize: 4}, ValuesStart: 100, ValuesPerProc: 4}, }}, {Key: StructKey{Name: "ipv6_hopots_ext_header"}, Fields: []Type{ @@ -2275,7 +2275,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 2, BigEndian: true}, Buf: "payload"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2878,13 +2878,13 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "kvm_setup_opt_vmwrite"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ"}, TypeSize: 8}, Val: 8}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "sz"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldLen: 5}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldLen: 48}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldOff: 1, BitfieldLen: 5}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldOff: 6, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldOff: 10, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldOff: 12, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldOff: 13, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldOff: 15, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldOff: 16, BitfieldLen: 48, BitfieldLst: true}}, }}, {Key: StructKey{Name: "kvm_setup_opt_x86"}, Fields: []Type{ &StructType{TypeCommon: TypeCommon{TypeName: "kvm_setup_opt_cr0", FldName: "cr0"}}, @@ -4828,13 +4828,13 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, }}, {Key: StructKey{Name: "syz_bf_struct0"}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10}, Vals: []uint64{0, 1, 2}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10, BitfieldLst: true}, Vals: []uint64{0, 1, 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f2"}, TypeSize: 2, BitfieldLen: 5}, Val: 66}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldLen: 6}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15}, Val: 66}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11}, Buf: "parent"}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BigEndian: true, BitfieldLen: 11}, Buf: "parent"}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldOff: 5, BitfieldLen: 6, BitfieldLst: true}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15, BitfieldLst: true}, Val: 66}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11, BitfieldLst: true}, Buf: "parent"}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BitfieldLen: 11, BigEndian: true, BitfieldLst: true}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f7"}, TypeSize: 1}}, }}, {Key: StructKey{Name: "syz_bf_struct1"}, Fields: []Type{ @@ -4843,15 +4843,15 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_bf_struct1_internal"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, }}, {Key: StructKey{Name: "syz_csum_encode"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f0"}, TypeSize: 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "f1"}, TypeSize: 2, BigEndian: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f2"}, Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32"}, TypeSize: 4}}, Kind: 1, RangeEnd: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f3"}, TypeSize: 1, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f5"}, Kind: 1, RangeBegin: 4, RangeEnd: 4}, }}, {Key: StructKey{Name: "syz_csum_icmp_packet"}, Fields: []Type{ @@ -4925,12 +4925,12 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_length_bf_struct_inner"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f4"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldOff: 16, BitfieldLen: 16, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f7"}, TypeSize: 4}, Buf: "parent"}, }}, {Key: StructKey{Name: "syz_length_bytesize2_struct"}, Fields: []Type{ @@ -5140,8 +5140,8 @@ var structFields = []*StructFields{ &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "seq_num"}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "ack_num"}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ns"}, TypeSize: 1, BitfieldLen: 1}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldLen: 3}}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 3}}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, ByteSize: 4, Buf: "parent"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "tcp_flags", FldName: "flags"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 8, 16, 32, 64, 128, 194}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "window_size"}, TypeSize: 2, BigEndian: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "tcp_packet", Protocol: 6}, @@ -5550,14 +5550,14 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "vlan_tag_ad"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 37120}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vlan_tag_q"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 33024}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vt_consize"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "rows"}, TypeSize: 2}}, diff --git a/sys/sys_ppc64le.go b/sys/sys_ppc64le.go index fd6afb16c..c99c07297 100644 --- a/sys/sys_ppc64le.go +++ b/sys/sys_ppc64le.go @@ -482,11 +482,11 @@ var structFields = []*StructFields{ &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "dst_port"}, TypeSize: 2, BigEndian: true}, ValuesStart: 20000, ValuesPerProc: 4}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "offset"}, TypeSize: 1}, ByteSize: 4, Buf: "parent"}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "cscov"}, TypeSize: 1, BitfieldLen: 4}, Val: 1}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ccval"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "parent", Protocol: 33}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "x"}, TypeSize: 1, BitfieldLen: 1}}, - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldLen: 3}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "dccp_types", FldName: "type"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1, BitfieldOff: 5, BitfieldLen: 3, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "seq_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "ack_num"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, @@ -1488,9 +1488,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmp_ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "total_len"}, TypeSize: 2, BigEndian: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -1602,7 +1602,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "icmpv6_ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "length"}, TypeSize: 2, BigEndian: true}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2062,9 +2062,9 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv4_header"}, Fields: []Type{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "ihl"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 4}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ecn"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldLen: 6}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "dscp"}, TypeSize: 1, BitfieldOff: 2, BitfieldLen: 6, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "total_len"}, TypeSize: 2, BigEndian: true}, Buf: "ipv4_packet"}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "id"}, TypeSize: 2, BigEndian: true}, ValuesStart: 100, ValuesPerProc: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "frag_off"}, TypeSize: 2, BigEndian: true}}, @@ -2136,7 +2136,7 @@ var structFields = []*StructFields{ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 1}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "pointer"}, TypeSize: 1}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_flags", FldName: "flg"}, TypeSize: 1, BitfieldLen: 4}, Vals: []uint64{0, 1, 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "oflw"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "timestamps"}, Type: &StructType{TypeCommon: TypeCommon{TypeName: "ipv4_option_timestamp_timestamp"}, IsPacked: true}}, }}, {Key: StructKey{Name: "ipv4_option_timestamp_timestamp"}, Fields: []Type{ @@ -2255,8 +2255,8 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved1"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_hi"}, TypeSize: 1}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "m_flag"}, TypeSize: 1, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldLen: 2}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldLen: 5}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "reserved2"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 2}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "fragment_off_lo"}, TypeSize: 1, BitfieldOff: 3, BitfieldLen: 5, BitfieldLst: true}}, &ProcType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "proc", FldName: "identification"}, TypeSize: 4}, ValuesStart: 100, ValuesPerProc: 4}, }}, {Key: StructKey{Name: "ipv6_hopots_ext_header"}, Fields: []Type{ @@ -2275,7 +2275,7 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "ipv6_packet"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "priority"}, TypeSize: 1, BitfieldLen: 4}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldLen: 4}, Val: 6}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "version"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, Val: 6}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "flow_label"}, Kind: 1, RangeBegin: 3, RangeEnd: 3}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "length"}, TypeSize: 2, BigEndian: true}, Buf: "payload"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "ipv6_types", FldName: "next_header"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 6, 8, 12, 17, 22, 29, 33, 41, 46, 47, 50, 51, 92, 94, 98, 103, 108, 132, 136, 137, 255, 0, 43, 44, 58, 59, 60, 135, 0, 43, 44, 47, 50, 51, 58, 59, 60, 135}}, @@ -2878,13 +2878,13 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "kvm_setup_opt_vmwrite"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "typ"}, TypeSize: 8}, Val: 8}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "sz"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldLen: 5}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldLen: 2}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldLen: 48}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fld"}, TypeSize: 8, BitfieldOff: 1, BitfieldLen: 5}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad0"}, TypeSize: 8, BitfieldOff: 6, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "ftyp"}, TypeSize: 8, BitfieldOff: 10, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad1"}, TypeSize: 8, BitfieldOff: 12, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "fsz"}, TypeSize: 8, BitfieldOff: 13, BitfieldLen: 2}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "pad2"}, TypeSize: 8, BitfieldOff: 15, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "val"}, TypeSize: 8, BitfieldOff: 16, BitfieldLen: 48, BitfieldLst: true}}, }}, {Key: StructKey{Name: "kvm_setup_opt_x86"}, Fields: []Type{ &StructType{TypeCommon: TypeCommon{TypeName: "kvm_setup_opt_cr0", FldName: "cr0"}}, @@ -4828,13 +4828,13 @@ var structFields = []*StructFields{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, }}, {Key: StructKey{Name: "syz_bf_struct0"}, Fields: []Type{ - &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10}, Vals: []uint64{0, 1, 2}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "syz_bf_flags", FldName: "f0"}, TypeSize: 2, BitfieldLen: 10, BitfieldLst: true}, Vals: []uint64{0, 1, 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int64", FldName: "f1"}, TypeSize: 8}}, &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f2"}, TypeSize: 2, BitfieldLen: 5}, Val: 66}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldLen: 6}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15}, Val: 66}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11}, Buf: "parent"}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BigEndian: true, BitfieldLen: 11}, Buf: "parent"}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f3"}, TypeSize: 2, BitfieldOff: 5, BitfieldLen: 6, BitfieldLst: true}}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "f4"}, TypeSize: 4, BitfieldLen: 15, BitfieldLst: true}, Val: 66}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f5"}, TypeSize: 2, BitfieldLen: 11, BitfieldLst: true}, Buf: "parent"}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f6"}, TypeSize: 2, BitfieldLen: 11, BigEndian: true, BitfieldLst: true}, Buf: "parent"}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f7"}, TypeSize: 1}}, }}, {Key: StructKey{Name: "syz_bf_struct1"}, Fields: []Type{ @@ -4843,15 +4843,15 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_bf_struct1_internal"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, }}, {Key: StructKey{Name: "syz_csum_encode"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "f0"}, TypeSize: 2}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "f1"}, TypeSize: 2, BigEndian: true}}, &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f2"}, Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32"}, TypeSize: 4}}, Kind: 1, RangeEnd: 4}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f3"}, TypeSize: 1, BitfieldLen: 4}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldLen: 4}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "f4"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}}, &BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "f5"}, Kind: 1, RangeBegin: 4, RangeEnd: 4}, }}, {Key: StructKey{Name: "syz_csum_icmp_packet"}, Fields: []Type{ @@ -4925,12 +4925,12 @@ var structFields = []*StructFields{ }}, {Key: StructKey{Name: "syz_length_bf_struct_inner"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f0"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldLen: 10}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f1"}, TypeSize: 4, BitfieldOff: 10, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f2"}, TypeSize: 4, BitfieldOff: 20, BitfieldLen: 10, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f3"}, TypeSize: 4, BitfieldLen: 32, BitfieldLst: true}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f4"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldLen: 16}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f5"}, TypeSize: 4, BitfieldOff: 16, BitfieldLen: 16, BitfieldLst: true}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", FldName: "f6"}, TypeSize: 4, BitfieldLen: 10, BitfieldLst: true}}, &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "f7"}, TypeSize: 4}, Buf: "parent"}, }}, {Key: StructKey{Name: "syz_length_bytesize2_struct"}, Fields: []Type{ @@ -5140,8 +5140,8 @@ var structFields = []*StructFields{ &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "seq_num"}}, &ResourceType{TypeCommon: TypeCommon{TypeName: "tcp_seq_num", FldName: "ack_num"}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "ns"}, TypeSize: 1, BitfieldLen: 1}}, - &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldLen: 3}}, - &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldLen: 4}, ByteSize: 4, Buf: "parent"}, + &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "reserved"}, TypeSize: 1, BitfieldOff: 1, BitfieldLen: 3}}, + &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize4", FldName: "data_off"}, TypeSize: 1, BitfieldOff: 4, BitfieldLen: 4, BitfieldLst: true}, ByteSize: 4, Buf: "parent"}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "tcp_flags", FldName: "flags"}, TypeSize: 1}, Vals: []uint64{0, 1, 2, 4, 8, 16, 32, 64, 128, 194}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16be", FldName: "window_size"}, TypeSize: 2, BigEndian: true}}, &CsumType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "csum", FldName: "csum"}, TypeSize: 2, BigEndian: true}, Kind: 1, Buf: "tcp_packet", Protocol: 6}, @@ -5550,14 +5550,14 @@ var structFields = []*StructFields{ {Key: StructKey{Name: "vlan_tag_ad"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 37120}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vlan_tag_q"}, Fields: []Type{ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "tpid"}, TypeSize: 2, BigEndian: true}, Val: 33024}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "pcp"}, TypeSize: 2, BitfieldLen: 3}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldLen: 1}}, - &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldLen: 12}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "dei"}, TypeSize: 2, BitfieldOff: 3, BitfieldLen: 1}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "vid"}, TypeSize: 2, BitfieldOff: 4, BitfieldLen: 12, BitfieldLst: true}}, }}, {Key: StructKey{Name: "vt_consize"}, Fields: []Type{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "rows"}, TypeSize: 2}}, |
