From e6806d0f7321f4fc18a13f474976d2e68f9ca4de Mon Sep 17 00:00:00 2001 From: Denis Efremov Date: Thu, 7 Jun 2018 10:59:06 +0300 Subject: sys/linux: floppy interface description For floppy fuzzing you need to enable: 1) CONFIG_BLK_DEV_FD in your kernel configuration 2) "cmdline": " -fda FLOPPY.img " in syzkaller configuration Signed-off-by: Denis Efremov Signed-off-by: Alexander Popov --- sys/linux/gen/arm.go | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'sys/linux/gen/arm.go') diff --git a/sys/linux/gen/arm.go b/sys/linux/gen/arm.go index c455f58d2..d741f6edc 100644 --- a/sys/linux/gen/arm.go +++ b/sys/linux/gen/arm.go @@ -44,6 +44,7 @@ var resources_arm = []*ResourceDesc{ {Name: "fd_evdev", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_evdev"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, {Name: "fd_event", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_event"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, {Name: "fd_fanotify", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_fanotify"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, + {Name: "fd_floppy", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_floppy"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, {Name: "fd_fuse", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_fuse"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, {Name: "fd_i2c", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_i2c"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, {Name: "fd_inotify", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_inotify"}, Values: []uint64{18446744073709551615, 18446744073709551516}}, @@ -33845,6 +33846,11 @@ var syscalls_arm = []*Syscall{ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "id", TypeSize: 4}}}, &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "open_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 1024, 8192, 524288, 64, 65536, 16384, 128, 131072, 262144, 256, 32768, 2048, 2097152, 1052672, 512, 4194304}, BitMask: true}, }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_cdrom", FldName: "ret", TypeSize: 4, ArgDir: 1}}}, + {Name: "syz_open_dev$FLOPPY", CallName: "syz_open_dev", Args: []Type{ + &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "string", TypeSize: 9}, Kind: 2, Values: []string{"/dev/fd#\x00"}}}, + &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "id", TypeSize: 4}}}, + &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "open_flags", FldName: "flags", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 1024, 8192, 524288, 64, 65536, 16384, 128, 131072, 262144, 256, 32768, 2048, 2097152, 1052672, 512, 4194304}, BitMask: true}, + }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_floppy", FldName: "ret", TypeSize: 4, ArgDir: 1}}}, {Name: "syz_open_dev$I2C", CallName: "syz_open_dev", Args: []Type{ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 4}, Type: &BufferType{TypeCommon: TypeCommon{TypeName: "string", TypeSize: 11}, Kind: 2, Values: []string{"/dev/i2c-#\x00"}}}, &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "intptr", FldName: "id", TypeSize: 4}}}, @@ -41196,4 +41202,4 @@ var consts_arm = []ConstValue{ {Name: "bpf_insn_load_imm_dw", Value: 24}, } -const revision_arm = "15223c241125b3b97cca255736128daf2364eb5f" +const revision_arm = "159cd727c1551ba9f1ddb35408ab61c3866826a3" -- cgit mrf-deployment