2009/07/22 Linux Kernel Podcast
Audio: http://media.libsyn.com/media/jcm/linux_kernel_podcast_20090722.mp3
This Podcast is brought to you in association with the humble coffee bean, providing constant uptime since sometime yesterday.
For Wednesday the 22nd of July, 2009, I’m Jon Masters with a summary of today’s LKML traffic.
In today’s issue: Checkpatch, checkpoint and restart, High Resolution Timers and tasklets, Linux 2.6.27.27, Tux, Userspace MMU notifications, VFAT, and multiple hardware watchdogs.
Checkpatch. Several people have been discussing the checkpatch script and its whining about extraneous whitespace in kernel patches. Pavel Machek asked whether it would be possible to add autofixing to checkpatch, to which Bartlomiej Zolnierkiewicz pointed out that there are two other scripts already in the kernel tree that do this – scripts/cleanfile, and scripts/cleanpatch. He notes that it might be worth checkpatch pointing this out on whining.
Checkpoint and restart. Oren Laadan surfaced with another round of checkpoint patches that enable the kernel to preserve the current state of running applications so that they can be resumed later from that point. This is similar to how processes (tasks) are suspended and resumed upon hibernate but allows one (in theory anyway) to resume tasks on an entirely new system, following a reboot, or in various other contexts. The latest version introduces a new system call entitled “clone_with_pids()” to preset the pid(s) of created processes (if they are available with the current namespace). The patch includes an FAQ that points out that this already has some limited real world use cases that could actually work, a guide to actually using the patch, and a number of hints at the sorts of features yet to come. Checkpointing is a hard Computer Science topic that none of the existing attempts have ever gotten quite right, but one has to give Oren credit for his persistence.
High Resolution Timers and tasklets. Peter Zijlstra posted a patch implementing a generic tasklet_hrtimer infrastructure (and accompanying tasklet_hrtimer_init exported symbol) that allows one to register a combination of a hrtimer and a tasklet that will be scheduled the moment that the timer expires. Thomas Gleixner posted this patch in the (shared) tip tree and requested that Linus pull into 2.6.31 since this is being requested by the network folks, who are waiting for it. Thomas noted that Peter has cleaned this patch up since the last posting, moving it to softirq.c and adding documentation and comments to aid others who might use it later. Separately, Thomas posted a bunch of other timer fixes for 2.6.31 in the form of a pull request of Linus.
Linux 2.6.27.27. Following on from earlier discussions concerning broken GCC code generation when specifying -fno-strict-overflow, the problem was tracked down to incorrect code generation in edd_checksum() in driver/video/fbmon.c. Linus was genuinely impressed at the ability for Troy Moure to seemingly stare at tens of thousands of lines of dissassemly diffs and work out where the code generation had failed, then concluded Troy might have instead simply looked for the section with the greatest change. But Troy instead replied that he had simply gotten lucky after looking at the boot output and persuing the radeonfb code on a hunch. As Troy says, “obviously I got a bit lucky that problem was actually basically where I started looking for it. But I figured even if I didn’t find it, I’d learn something about the radeonfb code. And who would pass up an opportunity to learn about that?”. In any case, Linus posted a patch that he thought might make the difference, which Krzysztof Oledzki noted did indeed fix his system, which could now boot, although there was still likely some broken code generation present because the console geometry was incorrect after running the affected radeonfb loop.
Tux. Some years ago now, Ingo Molnar (famous for inventing nearly everything, or at least re-writing it in an impossibly short period of time) wrote a static in-kernel web server named “tux”. This was in a time before dynamic web content (or even wide adoption of sendfile()) when slow machines struggled to push through large amounts of static content – and as Dave Jones points out (in referencing a humorous blog entry), especially to a certain high bandwidth internet user demographic interested in graphics and motion video – and so in-kernel optimization of such essential content delivery made a lot of sense. But times have moved on (and most Internet users desire dynamic content generation and streaming web video – especially the demographic mentioned before). Today, apache is more than good enough even for sites like youtube, and the mirrors on kernel.org (as Peter Anvin confirms in the same thread). So when Luis Rodriguez inquired as to the fate of the earlier khttpd that had inspired tux, he was told largely the same things – that there’s little incentive for an upstream in-kernel HTTP accelerator at this time. The whole thing served as a nice reminder of how far we have come since those days. And also gave us an opportunity to reference Dave’s humorous analysis once again.
Userspace MMU notifications. Roland Dreier posted an RFC patch series implementing userspace support for MMU notifications. This enables (for example) libraries in userspace using RDMA to track precisely when application code changes memory mappings via cals to functions like free(), munmap(), etc. It replaces the previous malloc hooks and other tricks with a robust implementation inspired by (but nevertheless not identical to) previous discussions (that were referenced). The patch series implements a new character device entitled ummunot that can be opened and upon which address range mapping change notifications can be requested of the kernel using ioctls. A fast path zero page offset mapping of the device allows quick checks for notification changes without (e)poll()ing, select()ing, or other syscalls.
VFAT. Something non-Micrsoft related. Jorg Schummer noted that standard FAT implementations (especially in Linux) cannot store any of the FAT root directory’s timestamps. But there is a hackish way to implement this via timestamps on the FAT volume label, as supported by Mac OS X. Jorg posted a patch that implements the same on Linux, via a “rootts” mount option.
Watchdog (multiple thereof). Simon Braunschmidt noted that he has an emlix board with two hardware watchdogs (woof! woof!) and would like to use both of them. The current watchdog implementation really only supports one, as Alan Cox confirmed in his comments – suggesting that previous attempts to add multiple watchdog support hadn’t really gone anywhere. Simon had posted some code and may well become the poor smuck who has to implement it officially.
In today’s miscellaneous items: support for named (and also empty) cgroup hierachies, version 3 of Dave Hansen’s “flexible array implementation”, some perf counters patches (Peter Zijlstra), some wireless fixes (John Linville), some NFS bugfixes (Trond Myklebust), some lockdep patches (Peter Zijlstra), some IRQ and scheduler fixes (Thomas Gleixner), some block fixes (Tejun Heo), some networking and IDE fixes (David Miller), and flashing LED support using GFS2 tracepoints in GFS2 (Steven Whitehouse). Valdis Kletnieks pointed out a lockdep “whinge” in the ext3/quota code as part of other unrelated bisection efforts.
Finally today, someone still cares about Amstrad’s E3 E-Mailer Videophone. I don’t think you can buy these any more (although they were very cheap, and I physically have three at home that I need to get setup – an update on current development is appreciated) but Janusz Krzysztofik posted some patches for the audio chipset nonetheless.
In today’s announcements: Linux 2.6.31-rc4.
The latest kernel release is 2.6.31-rc4, which was released by Linus on Wednesday evening (at 19:44 PDT). In his release announcement, Linus reminds us that this has been a “fun week”, filled with an exciting triple whammy of tools bugs to screw with our minds, and kernel builds. As Linus says, “and that was just the bugs that were outside the kernel”. Aside from the tools problems, things have been progressing reasonably, with lesser churn.
Stephen Rothwell posted a linux-next tree for July 22nd. Since Tuesday, there is a new “ext3″ tree (also containing some jbd changes – typoed in the announce mail), the tree still fails to build in an allyesconfig build configuration on powerpc, and the net tree gained 2 conflicts against the wireless-current tree maintained by John Linville. The total sub-tree count is now up to 134 trees.
That’s a summary of today’s Linux Kernel Mailing List traffic, for further information visit www.kernel.org. I’m Jon Masters.

