One of my current engineering efforts is in support of the concept of hardware attestation. What is that? Here’s my attempt at a summary:
Continue readingCategory Archives: Software
Hello To Stephen Smoogen
This post is a novelty post merely to say hello to a friend of mine that gave me a shout out else-where.
Hi Stephen.
Building a Fedora Based Linux Kernel
We have a few different ways we build a Kernel for internal consumption. One is very minimal, to be used when space is at a premium. Another is very closely based on the Fedora configuration to be used as a replacement Kernel for a Fedora install. While we do provide our team with RPMs to install, development often requires building from source. I’ve done this (and forgotten steps) enough times to want to have a quick reference. The following should work on a recent Fedora install.
Continue readingQuerying the PCCT in Python
The Platform Communication Channel Table contains information used to send messages in a shared memory buffer between the Operating System and other subsystems on the platform. Typically, the Channel has an interrupt defined that is used to tell the other subsystem that there is new data available.
Recently, I’ve been working with a couple entries that are of a newer type. In addition to the shared memory region and the interrupt values, the PCCT entries for type 3 and type 4 channels also have a series of registers. Where before the PCCT entries were normalized, now they are hierarchical. This makes them a little harder to scan with the human eye to confirm that the proper values have been recorded and read.
To simplify development, I build a simple script.
Continue readingPerdido
Written By Adam Young.
This is a short story I wrote my Sophomore year at West Point. It was originally published in “The Circle in the Spiral” the one and only edition of the West Point literary magazine, published in early 1991. Apologies for in anachronisms. More on that later
Continue readingError building Kernel ln: target ‘+/source’: No such file or directory
I have battled this problem a couple times and so I am documenting the issue and solution here.
Here is the error message from make modules_install
ln: target '+/source': No such file or directory
Continue reading Make Haste Slowly
In the software development world, we call it technical debt.
In the Army it was “Half-assed, full-blast. Don’t know where we are going but we should have been there yesterday.”
Finding a line of code in the Kernel from a stack trace
To find out what line a particular stack trace entry points to, use the script ./scripts/faddr2line for example If I have the line __get_vm_area_node+0x17c/0x1a8 I can run
./scripts/faddr2line vmlinux.o __get_vm_area_node+0x17c/0x1a8
__get_vm_area_node+0x17c/0x1a8:
__get_vm_area_node at /root/linux/mm/vmalloc.c:2579 (discriminator 1)
Following a code path in the Linux Kernel without a debugger
Sometimes you don’t get to use a debugger. When do bare metal development, often it is faster to get to the root of a problem by throwing in trace statements, and seeing what path is taken through the code.
Continue readingBuilding a Kernel RPM with the Built-in Makefile target
Note that you need to have a .config file that will be included in the build. It will also use the Version as specified in your Makefile. Then run
make rpm-pkg
Which will use the RPM build infra set up for your user to put the rpm in $HOME/rpmbuild/
Edit: Note that a bunch of dependencies are needed to get the Kernel to build. If you run the above command and it fails out with a message that you are missing a dependency, you can use this pair of commands to get the yum-build dep tool installed, and use that to install the dependencies as listed by the generated kernel.spec file.
wget https://src.fedoraproject.org/rpms/kernel/raw/rawhide/f/kernel.spec
yum install dnf-utils
yum-builddep ./kernel.spec