[ipxe-devel] [PATCH 1/5] get-pci-ids checks Linux for other file

Geert Stappers stappers at stappers.nl
Tue May 24 20:13:47 UTC 2022


From: Geert Stappers <stappers at stappers.nl>

It seems in Linux source tree was
the file include/version.h renamed to include/vermagic.h
---
 src/util/get-pci-ids | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/util/get-pci-ids b/src/util/get-pci-ids
index 42466221..1550677d 100755
--- a/src/util/get-pci-ids
+++ b/src/util/get-pci-ids
@@ -47,8 +47,8 @@ if($#ARGV >= 0) {
 	exit 1;
 }
 
-unless(-f "$kernel_src/include/linux/version.h") {
-	print STDERR "Could not find $kernel_src/include/linux/version.h.\n";
+unless(-f "$kernel_src/include/linux/vermagic.h") {
+	print STDERR "Could not find $kernel_src/include/linux/vermagic.h.\n";
 	print STDERR "$kernel_src is probably no Linux kernel source tree.\n";
 	exit 1;
 }
@@ -64,7 +64,7 @@ my $cpp="gcc -E";
 my @drivers = split /\s+/, `find $kernel_src/drivers/net -name '*.c' | sort`;
 
 # Kernel version
-my $version = `grep UTS_RELEASE $kernel_src/include/linux/version.h`;
+my $version = `grep UTS_RELEASE $kernel_src/include/linux/vermagic.h`;
 chomp $version;
 $version =~ s/\s*#define\s+UTS_RELEASE\s+"(\S+)".*$/$1/g;
 
-- 
2.11.0




More information about the ipxe-devel mailing list