Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improvement to CPU Vendor tests #284

Merged
merged 3 commits into from
Aug 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions perl/lib/NeedRestart/uCode/Intel.pm
Original file line number Diff line number Diff line change
Expand Up @@ -52,6 +52,13 @@ sub nr_ucode_check_real {
my $info = shift;
my %vars;

# check for Intel cpu
unless ( defined( $info->{vendor_id} )
&& $info->{vendor_id} eq 'GenuineIntel' )
{
die "$LOGPREF #$info->{processor} cpu vendor id mismatch\n";
}

# get current microcode revision
if ( defined( $info->{microcode} ) ) {
$vars{CURRENT} = sprintf( "0x%04x", hex( $info->{microcode} ) );
Expand Down