proxy_role/overlay/Gentoo/usr/local/sbin/gentoo_early-ucode.cpio.bash

17 lines
445 B
Bash
Raw Normal View History

2024-01-06 01:57:28 +00:00
# -*- mode: sh; fill-column: 75; tab-width: 8; coding: utf-8-unix -*-
ROLE=gpgkey
DST=/boot/intel-uc_pentoo19.cpio
a=$( find /lib/firmware/intel-ucode/ -type f -newer $DST |wc -l )
[ $? -ne 0 -o $a -eq 0 ] && exit 0
iucode_tool -S --write-earlyfw=$DST /lib/firmware/intel-ucode/*
base=$( basename $DST )
dir=/l/syslinux
[ -d $dir ] || exit 0
[ -f $dir/$base ] && diff -q $DST /l/syslinux/$base && exit 0
cp -p $DST /l/syslinux/$base
exit 0