diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..a152530 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +/rtl8168-eeprom +/rtl8168-eeprom.o diff --git a/debian/changelog b/debian/changelog new file mode 100644 index 0000000..de9b0c0 --- /dev/null +++ b/debian/changelog @@ -0,0 +1,18 @@ +rtl8168-eeprom (1.0.2) unstable; urgency=medium + + * Query PCI_FILL_{BASES,SIZES} in pci_fill_info too + + -- Oliver Smith Mon, 16 May 2022 14:05:15 +0200 + +rtl8168-eeprom (1.0.1) unstable; urgency=medium + + * Fix missing pci_fill_info() + * Exit with error if no device was found + + -- Oliver Smith Mon, 16 May 2022 10:49:48 +0200 + +rtl8168-eeprom (1.0.0) unstable; urgency=medium + + * Initial debian packaging. + + -- Oliver Smith Mon, 09 May 2022 16:28:19 +0200 diff --git a/debian/compat b/debian/compat new file mode 100644 index 0000000..f599e28 --- /dev/null +++ b/debian/compat @@ -0,0 +1 @@ +10 diff --git a/debian/control b/debian/control new file mode 100644 index 0000000..ffcadca --- /dev/null +++ b/debian/control @@ -0,0 +1,14 @@ +Source: rtl8168-eeprom +Section: devel +Priority: optional +Maintainer: Oliver Smith +Standards-Version: 4.5.0 +Build-Depends: debhelper (>= 10), + gcc, + libpci-dev, + pkg-config +Homepage: https://gitea.sysmocom.de/sysmocom/rtl8168-eeprom + +Package: rtl8168-eeprom +Architecture: any +Description: Tool to set MAC address in EEPROM of RTL8168/8111E devices diff --git a/debian/copyright b/debian/copyright new file mode 100644 index 0000000..a2b0e3d --- /dev/null +++ b/debian/copyright @@ -0,0 +1,23 @@ +Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Upstream-Name: rtl8168-eeprom + +Files: * +Copyright: Copyright 2015 Harald Welte +License: GPL-2+ + +License: GPL-2+ + This program is free software; you can redistribute it + and/or modify it under the terms of the GNU General Public + License as published by the Free Software Foundation; either + version 2 of the License, or (at your option) any later + version. + . + This program is distributed in the hope that it will be + useful, but WITHOUT ANY WARRANTY; without even the implied + warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR + PURPOSE. See the GNU General Public License for more + details. + . + On Debian systems, the full text of the GNU General Public + License version 2 can be found in the file + `/usr/share/common-licenses/GPL-2'. diff --git a/debian/rtl8168-eeprom.install b/debian/rtl8168-eeprom.install new file mode 100644 index 0000000..5018571 --- /dev/null +++ b/debian/rtl8168-eeprom.install @@ -0,0 +1 @@ +/rtl8168-eeprom /usr/bin/ diff --git a/debian/rules b/debian/rules new file mode 100755 index 0000000..2d33f6a --- /dev/null +++ b/debian/rules @@ -0,0 +1,4 @@ +#!/usr/bin/make -f + +%: + dh $@ diff --git a/debian/source/format b/debian/source/format new file mode 100644 index 0000000..89ae9db --- /dev/null +++ b/debian/source/format @@ -0,0 +1 @@ +3.0 (native) diff --git a/rtl8168-eeprom.c b/rtl8168-eeprom.c index 19cae0d..6c85fbb 100644 --- a/rtl8168-eeprom.c +++ b/rtl8168-eeprom.c @@ -466,6 +466,7 @@ static void iterate_devices(struct pci_access *pa, char *filter_id, char *filter continue; /* our own clumsy implementation of filtering */ + pci_fill_info(p, PCI_FILL_IDENT | PCI_FILL_BASES | PCI_FILL_SIZES); if (p->vendor_id != 0x10ec || p->device_id != 0x8168) continue; @@ -497,6 +498,8 @@ static void iterate_devices(struct pci_access *pa, char *filter_id, char *filter if (new_mac) exit(0); } + + die("no matching device found!\n"); } int main(int argc, char **argv)