ipfilter cannot be build within because warning's are present

Victor M. Blood freebsd at masm.elcom.ru
Thu Oct 18 22:51:55 PDT 2007


On 18.10.2007, Max Laier wrote:
> On Thursday 18 October 2007, Victor M. Blood wrote:
>> On 18.10.2007, Max Laier wrote:
>> > On Wednesday 17 October 2007, Victor M. Blood wrote:
>> >> Hi, All.
>> >>
>> >> I try to use options in kernel instead of a module build of the
>> >> ipfilter and got error then kernel builds.
>> >>
>> >> I'm edit files: fil.c, ip_auth.h, ip_auth.h, ip_log.c ip_compat.h
>> >> and correct #ifdef statament :) no more warnings...
>> >
>> > ipf is likely broken anyway.  See thread: "7.0 CURRENT, need help
>> > with panic: Trying sleep, but thread marked as sleeping prohibited"
>> > on this ML a few days back.  That this warning went unnoticed tells
>> > you something, too.
>>
>> New version, new problems, no more to say) few days back I have panic
>> with ip filter, now it seems as worked, after upgrade.
>>
>> #ipf -V
>> ipf: IP Filter: v4.1.27 (404)
>> Kernel: IP Filter: v4.1.27
>> Running: yes
>> Log Flags: 0 = none set
>> Default: block all, Logging: available
>> Active list: 0
>> Feature mask: 0xe

> Is this with a WITNESS/INVARIANTS enabled kernel?  From a quick glance at
> the code you should see warnings on the ioctl path as there are copy 
> operations to/from userland with the lock held.

Hmm... is it may crash ipnat, then it runs with `-s' key? In attach
new panics :))


-- 
With all regards, Victor M. Blood.   mailto: freebsd at masm.elcom.ru
FTN: 2:5024/1.95 at Fidonet.org, ICQ#3567656



-------------- next part --------------

Kernel page fault with the following non-sleepable locks held:

shared rw ipf filter load/unload mutex r = 0 (0xc0744820) locked @ contrib/ipfilter/netinet/ip_fil_freebsd.c:348

KDB: stack backtrace:
db_trace_self_wrapper(c06edc0d,c8813cec,c0589d8d,c06edfc7,c8813d00,...) at db_trace_self_wrapper+0x26
kdb_backtrace(c06edfc7,c8813d00,4,1,0,...) at kdb_backtrace+0x29
witness_warn(5,0,c0709b64,0,c1a37d48,...) at witness_warn+0x1cd
trap(c8813d8c) at trap+0x11e
calltrap() at calltrap+0x6
--- trap 0xc, eip = 0xc06af07c, esp = 0xc8813dcc, ebp = 0xc8814b98 ---
slow_copyout(c194f840,c034725d,1,0,c1a39840,...) at slow_copyout+0x4
fr_ioctlswitch(1,c194f840,c034725d,1,0,...) at fr_ioctlswitch+0x79
iplioctl(c176d500,c034725d,c194f840,1,c1a39840,...) at iplioctl+0xda
devfs_ioctl_f(c183b438,c034725d,c194f840,c1a07800,c1a39840,...) at devfs_ioctl_f+0xd5
kern_ioctl(c1a39840,3,c034725d,c194f840,1000000,...) at kern_ioctl+0x253
ioctl(c1a39840,c8814cfc,c,c06e86c6,c0720970,...) at ioctl+0x13f
syscall(c8814d38) at syscall+0x2f3
Xint0x80_syscall() at Xint0x80_syscall+0x20
--- syscall (54, FreeBSD ELF32, ioctl), eip = 0x28166f63, esp = 0xbfbfeb1c, ebp = 0xbfbfeb88 ---


Fatal trap 12: page fault while in kernel mode
fault virtual address	= 0x28202000
fault code		= supervisor write, page not present
instruction pointer	= 0x20:0xc06af07c
stack pointer	        = 0x28:0xc8813dcc
frame pointer	        = 0x28:0xc8814b98
code segment		= base 0x0, limit 0xfffff, type 0x1b
			= DPL 0, pres 1, def32 1, gran 1
processor eflags	= interrupt enabled, resume, IOPL = 0
current process		= 661 (ipnat)
panic: from debugger
Uptime: 30s
Physical memory: 119 MB
Dumping 41 MB: 26 10

#0  doadump () at pcpu.h:195
	in pcpu.h
-------------- next part --------------

Kernel page fault with the following non-sleepable locks held:

shared rw ipf filter load/unload mutex r = 0 (0xc0744820) locked @ contrib/ipfilter/netinet/ip_fil_freebsd.c:348
KDB: stack backtrace:
db_trace_self_wrapper(c06edc0d,c816ecec,c0589d8d,c06edfc7,c816ed00,...) at db_trace_self_wrapper+0x26
kdb_backtrace(c06edfc7,c816ed00,4,1,0,...) at kdb_backtrace+0x29
witness_warn(5,0,c0709b64,c816ed1c,c19092a8,...) at witness_warn+0x1cd
trap(c816ed8c) at trap+0x11e
calltrap() at calltrap+0x6
--- trap 0xc, eip = 0xc06af07c, esp = 0xc816edcc, ebp = 0xc816fb98 ---
slow_copyout(c1953b40,c034725d,1,0,c1755630,...) at slow_copyout+0x4
fr_ioctlswitch(1,c1953b40,c034725d,1,0,...) at fr_ioctlswitch+0x79
iplioctl(c176d500,c034725d,c1953b40,1,c1755630,...) at iplioctl+0xda
devfs_ioctl_f(c183c828,c034725d,c1953b40,c1ab7500,c1755630,...) at devfs_ioctl_f+0xd5
kern_ioctl(c1755630,3,c034725d,c1953b40,1000000,...) at kern_ioctl+0x253
ioctl(c1755630,c816fcfc,c,c06e86c6,c0720970,...) at ioctl+0x13f
syscall(c816fd38) at syscall+0x2f3
Xint0x80_syscall() at Xint0x80_syscall+0x20
--- syscall (54, FreeBSD ELF32, ioctl), eip = 0x28166f63, esp = 0xbfbfeb1c, ebp = 0xbfbfeb88 ---


Fatal trap 12: page fault while in kernel mode
fault virtual address	= 0x28202000
fault code		= supervisor write, page not present
instruction pointer	= 0x20:0xc06af07c
stack pointer	        = 0x28:0xc816edcc
frame pointer	        = 0x28:0xc816fb98
code segment		= base 0x0, limit 0xfffff, type 0x1b
			= DPL 0, pres 1, def32 1, gran 1
processor eflags	= interrupt enabled, resume, IOPL = 0
current process		= 949 (ipnat)
panic: from debugger
Uptime: 48m41s
Physical memory: 119 MB
Dumping 29 MB: 14

#0  doadump () at pcpu.h:195
	in pcpu.h


More information about the freebsd-current mailing list