Package: installation-reports Version: 2.35 Severity: wishlist Tags: patch Hello
Recent kernels provides some DMI information in /sys/class/dmi/id/. This could be used by report-hw (and installation-report) in the case where dmidecode isn't installed (tiny Debian installation, etc). I've attached a simple proof-of concept patch. Here's a sample output : dmiinfo:uevent: MODALIAS=dmi:bvnLENOVO:bvr79ETD2WW(2.12):bd04/12/2007:svnLENOVO:pn1952W5R:pvrThinkPadT60:rvnLENOVO:rn1952W5R:rvrNotAvailable:cvnLENOVO:ct10:cvrNotAvailable: dmiinfo:bios_vendor: LENOVO dmiinfo:bios_version: 79ETD2WW (2.12 ) dmiinfo:bios_date: 04/12/2007 dmiinfo:sys_vendor: LENOVO dmiinfo:product_name: 1952W5R dmiinfo:product_version: ThinkPad T60 dmiinfo:board_vendor: LENOVO dmiinfo:board_name: 1952W5R dmiinfo:board_version: Not Available dmiinfo:board_asset_tag: dmiinfo:chassis_vendor: LENOVO dmiinfo:chassis_type: 10 dmiinfo:chassis_version: Not Available dmiinfo:chassis_asset_tag: No Asset Information dmiinfo:modalias: dmi:bvnLENOVO:bvr79ETD2WW(2.12):bd04/12/2007:svnLENOVO:pn1952W5R:pvrThinkPadT60:rvnLENOVO:rn1952W5R:rvrNotAvailable:cvnLENOVO:ct10:cvrNotAvailable: dmiinfo:wakeup: Franklin -- System Information: Debian Release: lenny/sid APT prefers testing APT policy: (990, 'testing'), (50, 'unstable') Architecture: i386 (i686) Kernel: Linux 2.6.25-2-686 (SMP w/2 CPU cores) Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash installation-report depends on no packages. Versions of packages installation-report recommends: ii pciutils 1:3.0.0-4 Linux PCI Utilities ii reportbug 3.41 reports bugs in the Debian distrib -- no debconf information
--- /usr/bin/report-hw-orig 2008-06-12 07:38:29.000000000 +0200 +++ /usr/bin/report-hw 2008-06-12 08:03:06.000000000 +0200 @@ -49,8 +49,16 @@ bus/input/devices; do addfile /proc/$file done -if type dmidecode >/dev/null 2>&1; then - dmidecode 2>&1 | addinfo dmidecode + +if type dmidecode >/dev/null 2>&1 && [ -r /dev/mem ]; then + dmidecode | addinfo dmidecode +else + if [ -d /sys/class/dmi/id ]; then + for file in $(find /sys/class/dmi/id -type f | \ + grep -v 'serial' | grep -v 'uuid' ); do + [ -r $file ] && cat $file | addinfo dmiinfo:$(basename $file) + done + fi fi if [ "$DEBIAN_FRONTEND" = gtk ]; then