using compile time default '/usr/lib64/bochs/plugins'Ġ0000000000i BXSHARE not set. Version-Release number of selected component (if applicable):Ġ0000000000i LTDL_LIBRARY_PATH not set. NOTE: Issue still there even in F23 with the latest bochs-debugger.x86_64 2.6.2-9.fc23 rpmīochs-debugger fails on launch, due to a missing plugin module: Although I have got reasonably good at reading a "raw" stack dump (x/200a ) at this point.+++ This bug was initially created as a clone of Bug #1092192 +++ Out of interest, does anybody know if there's a way to get GDB to perform a stacktrace from an address other than the current stack pointer? That would be awfully useful. I've even gone so far as to add some simple commands to GDB via its Python support to show the status of my system's threads and processes as well as the addresses of loadable kernel modules (which I can then load into GDB with add-symbol-file). I've also used the serial output when I've tested on real hardware (old Dell Pentium 4 Optiplex with a serial port, null modem cable connected to ancient 80386 laptop running terminal software).Īlthough my kernel is "mature" enough that I haven't seen issues 1 & 2 in a good while and my page fault handler at least tells me which code address was trying to access which virtual address, along with a register dump. QEMU + GDB, plus a lot of debugging output to the virtual serial port (displayed on the console). I suggest Ouija for that-I’ve never been misled yet by Parker Brothers’ implementation of arcane magical tools or talismans, and their Vodun line is excellent if you have entrails to gaze into. So communing spuritually with your code is going to be necessary one way or another. Those registers tell you why & where the fault occurred in a local sense, but asynchrony is a bitch, and that would be true in any case, OS code or not by the time you’re debug-dumping, whatever brokenness won’t necessarily hang around for you to dump about it. You need to log spurious IRQs anyway, and an unhandled page fault (most kernel-mode faults) should usually trigger a BSOD with full register dump. You might also be able to beep (assuming your PCspk is attached) or blink keyboard LEDs (or sometimes HDD/FDD lights), which is usually how the BIOS POST reports errors during pre-display startup.Īny of the above works for the first situation, and a decent logging and BSOD setup for the others. Sometimes that head-dented wall is all you’ve got.) Failing that, there’s ICE debugging, or dumping to parallel port pins or the RS232 UART (although these peripherals may or may not exist in any direct/real sense any more). (Bochs didn’t trip on SSE misalignment which ate like two days of banging my head on the wall to figure out. The one glitch there is that, if the right monitor pin goes, some older VGA hardware would think you’d attached a monochrome monitor, so it decided to map the VGA regs & framebuffer to the MDA locations, whee.īut Bochs already existed back then, and its debug port worked well enough while I was doing broad-strokes testing. Once you’re to the point where you can kprintf, you can do actual logging to the screen.īack in the day (early 2000s) you could still slip an MDA/HGC card into the one remaining ISA (Industry-Standard Architecture IIRC, not Instruction Set Architecture) slot, and because MDA uses its own port range based at 0x3B0 instead of 0x3D0, and framebuffer window at 0xB0000 not 0xB8000, you had a second monitor you could dump to w/o interfering with the VGA side of things (SVGA/post-VGA modes will probably not be happy, but if you’re at the point where you’re concerned about graphics, you probably have some better, more permanent mode of exfil), and it can reuse any text-mode tty emulation code since both use 80×≥25 row-major (chr, color) pairs and similar CRTC cursor start/end and position registers. When you’re first getting started, you can poke bytes into the video buffer to indicate how far you’ve gotten and hand off error codes-just make sure the bootloader sets the video mode to something well-defined.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |