Posts in category Warner’s Random Hacking Blog

If you go buy a D-LINK DIR-615, make sure that it is hardware revision A1. Hardware revision B2 has less flash (only 4MB) and RAM (16MB) and a completely different processor: Ubicom IP5090U cpu. This CPU uses a new instruction set (ubicom32) that isn\'t supported by any open source operating system that I could find. This is also the previ [...]

The other day I saw that Target was selling the D-LINK DIR-615 draft N router for $50.00 each. Since it had been a while since I purchased a wireless router to hack, I bought one. It turns out that this was a wise choice.This router chip has an 88F5180NB1 CPU. This is a Marvell Orion SoC. Support for this (Read more...)

Thanks to some encouragement from Gavin Atkinson, I have been able to boot the AVILA kernel on my Linksys NSLU2 (slug). I have it running of NFS root at 266MHz. Not super fast, but not too bad. I need to clean up a bunch of stuff still, but at least I have the basics working.I\'ll post more in a (Read more...)

Today I\'m writing about the Buffalo LinkStation PC-L4PWAP. It was on clearance at Circuit City, so I thought I\'d take a chance and pick it up. At the very least, I\'d have a new \'receiver\' on my network to play tunes through at parties.I cracked it open when I got it home. There\'s a Phillips PNX-1520E processor running at (Read more. [...]

I was looking over some code for someone today. They were having problems with preemption in the write routine and couldn\'t understand why, since they said to take Giant for all devsw operations. In digging into the problem, I discovered the following code. Maybe you can spot the bug:#ifdef D_NEED_GIANT#define FOO_GIANT D_NEEDGIANT#else#d [...]

I went to my old house yesterday. Like many others, my old house hasn\'t sold in a while. There was a showing today, so I had to shovel the snow off the driveway. While I was there I discovered a most interesting package on my doorstep.It was a nice, large calendar of African animals in the wild. I hadn\'t (Read more...)

Let\'s say you want to create a ram disk for a kernel, or a ufs image for an emulator. To make it interesting, the image needs to be in big endian format and you just have an intel x86 machine which is little endian. How do you proceed? If you were building a little endian image, the answer is simple: (Read more...)

Way back in the days of yore, when Turbo C++ had just came out, I was using a DEC Rainbow 100B+. For those not old enough to recall, this was a machine that came out in 1985 with software that came out in about 1990. Boreland had done a good job of not using all the IBM BIOS calls, so (Read more...)

A few weeks ago, I wrote up how to make a bootable i386 image. People have been asking me to extend it for my ARM platform.Here are the instructions for a hypothetical box that has a boot loader that can load an image from a FAT partition of a SD card, and FreeBSD runs off of a ufs partition (Read more...)

Wired has a great article about the high precision hobbyist timing community. These folks are less fanatical about timing than the professionals, but not by much. You know you are a true time geek when you understand the joke in Tom\'s quote from the article about his trip to a tall mountain near his home \"It was the best extra (Read more [...]

Last week I started at Cisco. The entire week I tried to figure out how to drink from a fire hose without getting hurt. This week, I\'ll be learning where to go for help with fire hose related injuries. :-).Seriously, I\'ve joined a very dynamic and energetic group here at Cisco. The job so far has been a blast, (Read more...)

This is just a quick thumbnail about how to take a core file from a FreeBSD/arm box and debug it on a FreeBSD/i386 box you cross compiled the FreeBSD/arm image on.For normal gdb, one would just type:gdb prog prog.coreand be done with it. However, without careful setup, this won\'t work when cross debugging. If you do the (Read more...)

Today, while I was ordering a new keyboard for my laptop (a 1-year-old is very hard on them), I ordered a 4GB SDHC card. When it arrives, I plan on expanding FreeBSD\'s support for SDHC. I had been waiting for the card to arrive to post this, but so far it has taken two weeks and no SDHC card. I (Read more...)

From time to time I hear people complain at how hard it is to build an image from the FreeBSD sources. This week, I\'ll explain how I built a bootable i386 image on a USB flash device and also make some observations about the results.Recently, I needed to create a bootable i386 image. The easiest way was to build (Read more...)

GDB Cross building on FreeBSDI recently had to build a gdb that worked on our development host, but understood arm binaries and core files. It turns out to be fairly easy to do this in the FreeBSD tree. I did this on RELENG_6, but the same techniques will work for RELENG_7 or -CURRENT.The Cookbook% setenv TARGET_ARCH arm (Read more...)

Today I started work on porting FreeBSD/arm to a new SoC. I\'m taking very detailed notes on this process, as well as attempting to learn from my atmel port how best to organize the port. I\'ll keep everybody posted and once I get far enough into it, I\'ll summarize the notes in a series of articles here. Hopefully this will (Read more... [...]

Once upon a time, all the BSD\'s got their USB stack from NetBSD. With it came a usbdevs file. This file has grown and mutated on the different BSDs for some time. The time has come to merge them all back together. This sounds simple in theory, but in practice it is a lot more complicated. Different BSDs use different (Read more...)

I\'ve finished much of the work on improving the in-tree USB stack, apart from adding device IDs. This is just the initial round. Now that all the cruft has been removed from the in-tree USB stack, we\'ll be able to support it better in RELENG_7. I plan on merging most of the client drivers into RELENG_6 after a couple of (Read more...)

After the shared library version bump, the xorg 7.2 transition and the new gcc compiler in the base, I started to rebuild everything. After some snafu deleted all my +CONTENTS files, I\'ve finally managed to rebuild everything (I think). The last major thing was ooo. After my laptop would shut down for being too hot a dozen times, and havi [...]

I did a quick pass through the tree tonight eliminating all the devinfo stuff. This code had been implemented in uhub a while ago, but the client drivers were never updated to remove the bloat. We set the device name to usbd_get_devinfo in uhub, but then in the client drivers, we computed it again, and printed it, so the data (Read more... [...]