From ea50fce839b2058694e2fb38d82f902b136af7bf Mon Sep 17 00:00:00 2001 From: Andrey Konovalov Date: Sun, 5 Feb 2017 19:54:44 +0100 Subject: report: handle new kind of RIP: line format --- report/report.go | 12 ++++++++++++ report/report_test.go | 40 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 52 insertions(+) diff --git a/report/report.go b/report/report.go index f8afae1fc..8132e5148 100644 --- a/report/report.go +++ b/report/report.go @@ -148,6 +148,10 @@ var oopses = []*oops{ compile("general protection fault:(?:.*\\n)+?.*RIP: [0-9]+:{{PC}} +{{PC}} +{{FUNC}}"), "general protection fault in %[1]v", }, + { + compile("general protection fault:(?:.*\\n)+?.*RIP: [0-9]+:{{FUNC}}"), + "general protection fault in %[1]v", + }, }, []*regexp.Regexp{}, }, @@ -192,6 +196,10 @@ var oopses = []*oops{ compile("divide error: (?:.*\\n)+?.*RIP: [0-9]+:{{PC}} +{{PC}} +{{FUNC}}"), "divide error in %[1]v", }, + { + compile("divide error: (?:.*\\n)+?.*RIP: [0-9]+:{{FUNC}}"), + "divide error in %[1]v", + }, }, []*regexp.Regexp{}, }, @@ -202,6 +210,10 @@ var oopses = []*oops{ compile("invalid opcode: (?:.*\\n)+?.*RIP: [0-9]+:{{PC}} +{{PC}} +{{FUNC}}"), "invalid opcode in %[1]v", }, + { + compile("invalid opcode: (?:.*\\n)+?.*RIP: [0-9]+:{{FUNC}}"), + "invalid opcode in %[1]v", + }, }, []*regexp.Regexp{}, }, diff --git a/report/report_test.go b/report/report_test.go index 1134767df..e3c705b69 100644 --- a/report/report_test.go +++ b/report/report_test.go @@ -72,6 +72,26 @@ IP: [] __call_rcu.constprop.76+0x1f/0x280 kernel/rcu/tree.c:30 [ 1722.511384] RSP: 0018:ffff88005062fb48 EFLAGS: 00010206 `: `general protection fault in logfs_init_inode`, + ` +general protection fault: 0000 [#1] SMP KASAN +Dumping ftrace buffer: + (ftrace buffer empty) +Modules linked in: +CPU: 0 PID: 27388 Comm: syz-executor5 Not tainted 4.10.0-rc6+ #117 +Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011 +task: ffff88006252db40 task.stack: ffff880062090000 +RIP: 0010:__ip_options_echo+0x120a/0x1770 +RSP: 0018:ffff880062097530 EFLAGS: 00010206 +RAX: dffffc0000000000 RBX: ffff880062097910 RCX: 0000000000000000 +RDX: 0000000000000003 RSI: ffffffff83988dca RDI: 0000000000000018 +RBP: ffff8800620976a0 R08: ffff88006209791c R09: ffffed000c412f26 +R10: 0000000000000004 R11: ffffed000c412f25 R12: ffff880062097900 +R13: ffff88003a8c0a6c R14: 1ffff1000c412eb3 R15: 000000000000000d +FS: 00007fd61b443700(0000) GS:ffff88003ec00000(0000) knlGS:0000000000000000 +CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 +CR2: 000000002095f000 CR3: 0000000062876000 CR4: 00000000000006f0 +`: `general protection fault in __ip_options_echo`, + ` ================================================================== BUG: KASAN: slab-out-of-bounds in memcpy+0x1d/0x40 at addr ffff88003a6bd110 @@ -332,6 +352,26 @@ sp : c23e1db0 ip : c3cf8848 fp : c23e1df4 [ 616.312546] RSP: 0018:ffff88003ed07d98 EFLAGS: 00010006 `: `divide error in snd_hrtimer_callback`, + ` +divide error: 0000 [#1] SMP KASAN +Dumping ftrace buffer: + (ftrace buffer empty) +Modules linked in: +CPU: 2 PID: 5664 Comm: syz-executor5 Not tainted 4.10.0-rc6+ #122 +Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS Bochs 01/01/2011 +task: ffff88003a46adc0 task.stack: ffff880036a00000 +RIP: 0010:__tcp_select_window+0x6db/0x920 +RSP: 0018:ffff880036a07638 EFLAGS: 00010212 +RAX: 0000000000000480 RBX: ffff880036a077d0 RCX: ffffc900030db000 +RDX: 0000000000000000 RSI: 0000000000000000 RDI: ffff88003809c3b5 +RBP: ffff880036a077f8 R08: ffff880039de5dc0 R09: 0000000000000000 +R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000480 +R13: 0000000000000000 R14: ffff88003809bb00 R15: 0000000000000000 +FS: 00007f35ecf32700(0000) GS:ffff88006de00000(0000) knlGS:0000000000000000 +CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 +CR2: 00000000205fb000 CR3: 0000000032467000 CR4: 00000000000006e0 +`: `divide error in __tcp_select_window`, + ` unreferenced object 0xffff880039a55260 (size 64): comm "executor", pid 11746, jiffies 4298984475 (age 16.078s) -- cgit mrf-deployment