hwdb: add IEEE OUI data
This commit is contained in:
parent
c67fbe4c71
commit
448004c340
|
@ -1799,7 +1799,8 @@ dist_udevrules_DATA += \
|
||||||
dist_udevhwdb_DATA = \
|
dist_udevhwdb_DATA = \
|
||||||
hwdb/20-pci-vendor-product.hwdb \
|
hwdb/20-pci-vendor-product.hwdb \
|
||||||
hwdb/20-usb-vendor-product.hwdb \
|
hwdb/20-usb-vendor-product.hwdb \
|
||||||
hwdb/20-acpi-vendor.hwdb
|
hwdb/20-acpi-vendor.hwdb \
|
||||||
|
hwdb/20-OUI-vendor.hwdb
|
||||||
|
|
||||||
udevconfdir = $(sysconfdir)/udev
|
udevconfdir = $(sysconfdir)/udev
|
||||||
dist_udevconf_DATA = \
|
dist_udevconf_DATA = \
|
||||||
|
@ -3985,7 +3986,7 @@ distclean-local: $(DISTCLEAN_LOCAL_HOOKS)
|
||||||
|
|
||||||
clean-local:
|
clean-local:
|
||||||
rm -rf $(abs_srcdir)/install-tree
|
rm -rf $(abs_srcdir)/install-tree
|
||||||
rm -f $(abs_srcdir)/hwdb/usb.ids $(abs_srcdir)/hwdb/pci.ids
|
rm -f $(abs_srcdir)/hwdb/usb.ids $(abs_srcdir)/hwdb/pci.ids $(abs_srcdir)/hwdb/oui.txt
|
||||||
|
|
||||||
DISTCHECK_CONFIGURE_FLAGS = \
|
DISTCHECK_CONFIGURE_FLAGS = \
|
||||||
--with-sysvinit-path=$$dc_install_base/$(sysvinitdir) \
|
--with-sysvinit-path=$$dc_install_base/$(sysvinitdir) \
|
||||||
|
@ -4006,6 +4007,7 @@ hwdb-update:
|
||||||
( cd hwdb && \
|
( cd hwdb && \
|
||||||
wget -N http://www.linux-usb.org/usb.ids && \
|
wget -N http://www.linux-usb.org/usb.ids && \
|
||||||
wget -N http://pciids.sourceforge.net/v2.2/pci.ids && \
|
wget -N http://pciids.sourceforge.net/v2.2/pci.ids && \
|
||||||
|
wget -N http://standards.ieee.org/develop/regauth/oui/oui.txt && \
|
||||||
./ids-update.pl )
|
./ids-update.pl )
|
||||||
|
|
||||||
upload: all distcheck
|
upload: all distcheck
|
||||||
|
|
1
hwdb/.gitignore
vendored
1
hwdb/.gitignore
vendored
|
@ -1,2 +1,3 @@
|
||||||
/pci.ids
|
/pci.ids
|
||||||
/usb.ids
|
/usb.ids
|
||||||
|
/oui.txt
|
||||||
|
|
51108
hwdb/20-OUI-vendor.hwdb
Normal file
51108
hwdb/20-OUI-vendor.hwdb
Normal file
File diff suppressed because it is too large
Load diff
|
@ -78,3 +78,23 @@ while (my $line = <IN>) {
|
||||||
}
|
}
|
||||||
close(INP);
|
close(INP);
|
||||||
close(OUTP);
|
close(OUTP);
|
||||||
|
|
||||||
|
open(IN, "<", "oui.txt");
|
||||||
|
open(OUT, ">", "20-OUI-vendor.hwdb");
|
||||||
|
print(OUT "# This file is part of systemd.\n" .
|
||||||
|
"#\n" .
|
||||||
|
"# Data imported and updated from: http://standards.ieee.org/develop/regauth/oui/oui.txt\n");
|
||||||
|
|
||||||
|
while (my $line = <IN>) {
|
||||||
|
$line =~ s/\s+$//;
|
||||||
|
$line =~ m/^([0-9A-F]{6})\s*\(base 16\)\s*(.*)$/;
|
||||||
|
if (defined $1) {
|
||||||
|
my $vendor = uc $1;
|
||||||
|
my $text = $2;
|
||||||
|
print(OUT "\n");
|
||||||
|
print(OUT "OUI:" . $vendor . "\n");
|
||||||
|
print(OUT " ID_VENDOR_FROM_DATABASE=" . $text . "\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
close(INP);
|
||||||
|
close(OUTP);
|
||||||
|
|
Loading…
Reference in a new issue