#!/bin/sh
set -eu

echo "I: Content of /boot/microcode.cpio:"
3cpio -tv /boot/microcode.cpio

for file in AuthenticAMD.bin GenuineIntel.bin; do
    echo "I: Check that kernel/x86/microcode/${file} is present..."
    3cpio -t /boot/microcode.cpio | grep -q "^kernel/x86/microcode/${file}$"
done
