cvs commit: src/sys/bus/iicbus iicbb_if.m iicbus_if.m src/sys/bus/isa isa_if.m src/sys/bus/isa/i386 isa_compat.c src/sys/bus/pci pci.c pci_if.m src/sys/bus/smbus smbus_if.m src/sys/conf Makefile.i386 kmod.mk src/sys/dev/misc/dec ...
YONETANI Tomokazu
qhwt at myrealbox.com
Mon Nov 17 07:26:17 PST 2003
Hi,
On Sun, Nov 16, 2003 at 04:54:40PM -0800, Jeroen Ruigrok/asmodai wrote:
> asmodai 2003/11/16 16:54:40 PST
>
> DragonFly src repository
>
> Modified files:
> sys/bus/iicbus iicbb_if.m iicbus_if.m
> sys/bus/isa isa_if.m
> sys/bus/isa/i386 isa_compat.c
> sys/bus/pci pci.c pci_if.m
> sys/bus/smbus smbus_if.m
> sys/conf Makefile.i386 kmod.mk
> sys/dev/misc/dec mcclock_if.m
> sys/dev/netif/mii_layer miibus_if.m
> sys/kern bus_if.m device_if.m subr_bus.c
> sys/sys bus.h bus_private.h
> Log:
> Factor out the object system from new-bus so that it can be used by
> non-device code.
>
> Re-implement the method dispatch to improve efficiency. The new system
> takes about 40ns for a method dispatch on a 300Mhz PII which is only 10ns
> slower than a direct function call on the same hardware.
>
> This is all based on Doug Rabson's work in April and May of 2000.
>
> Revision Changes Path
> 1.3 +3 -1 src/sys/bus/iicbus/iicbb_if.m
> 1.3 +3 -1 src/sys/bus/iicbus/iicbus_if.m
> 1.4 +1 -2 src/sys/bus/isa/isa_if.m
> 1.4 +1 -1 src/sys/bus/isa/i386/isa_compat.c
> 1.6 +1 -1 src/sys/bus/pci/pci.c
> 1.3 +3 -1 src/sys/bus/pci/pci_if.m
> 1.3 +3 -1 src/sys/bus/smbus/smbus_if.m
> 1.11 +2 -2 src/sys/conf/Makefile.i386
> 1.8 +2 -2 src/sys/conf/kmod.mk
> 1.3 +3 -1 src/sys/dev/misc/dec/mcclock_if.m
> 1.3 +3 -1 src/sys/dev/netif/mii_layer/miibus_if.m
> 1.3 +3 -1 src/sys/kern/bus_if.m
> 1.3 +3 -1 src/sys/kern/device_if.m
> 1.5 +31 -213 src/sys/kern/subr_bus.c
> 1.3 +5 -15 src/sys/sys/bus.h
> 1.3 +7 -27 src/sys/sys/bus_private.h
After this commit, my DragonFly laptop panics in early stage of
boot process. I inserted a small printf() at the beginning of
kobj_delete() to see what's the problem, and I got:
Preloaded elf kernel "/kernel.new" at 0xc03af000.
Preloaded userconfig_script "/boot/kernel.conf" at 0xc03af28c.
Preloaded elf module "/modules.new/splash_bmp.ko" at 0xc03af2dc.
Preloaded elf module "/modules.new/vesa.ko" at 0xc03af38c.
Preloaded elf module "/modules.new/linux.ko" at 0xc03af438.
Preloaded elf module "/modules.new/miibus.ko" at 0xc03af4e4.
Preloaded elf module "/modules.new/if_fxp.ko" at 0xc03af590.
Preloaded elf module "/modules.new/if_wi.ko" at 0xc03af63c.
Preloaded elf module "/modules.new/snd_pcm.ko" at 0xc03af6e8.
Preloaded elf module "/modules.new/snd_t4dwave.ko" at 0xc03af794.
Preloaded elf module "/modules.new/usb.ko" at 0xc03af844.
Preloaded elf module "/modules.new/agp.ko" at 0xc03af8ec.
VESA: v2.0, 16384k memory, flags:0x0, mode table:0xc030f480 (1000040)
VESA: Trident CYBER 8820
Pentium Pro MTRR support enabled
obj: 0xc776b300, obj->ops: 0xc774bdb0, obj->ops->cls: 0xc027b560
Using $PIR table, 7 entries at 0xc00f0200
obj: 0xc776b348, obj->ops: 0xc774bdb0, obj->ops->cls: 0xc027b560
npx0: <math processor> on motherboard
npx0: INT 16 interface
obj: 0xc776b3d8, obj->ops: 0xc774bdb0, obj->ops->cls: 0xc027b560
acpi0: <TOSHIB 750 > on motherboard
installed MI handler for int 9
acpi0: power button is handled as a fixed feature programming model.
Timecounter "ACPI-safe" frequency 3579545 Hz
obj: 0xc776b4b0, obj->ops: 0xc774bdb0, obj->ops->cls: 0xc027b560
acpi_timer0: <24-bit timer at 3.579545MHz> port 0xd808-0xd80b on acpi0
obj: 0xc776b4f8, obj->ops: 0xc774bdb0, obj->ops->cls: 0xc027b560
obj: 0xc776b4f8, obj->ops: 0xc774e1b0, obj->ops->cls: 0xc0273954
obj: 0xc776b4f8, obj->ops: 0, obj->ops->cls: 0
Fatal trap 12: page fault while in kernel mode
fault virtual address = 0x800
fault code = supervisor read, page not present
instruction pointer = 0x8:0xc01831c9
stack pointer = 0x10:0xc03d1c34
frame pointer = 0x10:0xc03d1c4c
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 = 0 (swapper)
current thread = pri 12
interrupt mask = net tty bio cam
trap number = 12
panic: page fault
Uptime: 0s
Terminate ACPI
Automatic reboot in 15 seconds - press a key on the console to abort
--> Press a key on the console to reboot,
--> or switch off the system now.
Seems like obj->ops was NULL, so obj->ops->cls dereferenced a NULL pointer.
DDB didn't show a nice traceback(again). The lines immediately following
the "acpi_timer0" when I ran the working kernel are:
acpi_cpu0: <CPU> on acpi0
acpi_tz0: <thermal zone> on acpi0
acpi_button0: <Power Button> on acpi0
acpi_lid0: <Control Method Lid Switch> on acpi0
acpi_cmbat0: <Control method Battery> on acpi0
acpi_acad0: <AC adapter> on acpi0
acpi_toshiba0: <Toshiba Notebook Extra HCI driver> on acpi0
Regards.
More information about the Commits
mailing list