1
Description: Avoid trolling /dev/mem for SMBIOS on aarch64
2
When lshw runs as superuser, it can crash aarch64 systems (kernel
3
oops) by accessing /dev/mem to look for the SMBIOS region. Since
4
SMBIOS is unlikely to exist in an aarch64 platform, simply disable
6
Author: dann frazier <dann.frazier@canonical.com>
7
Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/lshw/+bug/1284406
8
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=740034
9
Forwarded: http://ezix.org/project/ticket/642
10
Last-Update: 2014-03-07
12
Index: lshw-02.16/src/core/dmi.cc
13
===================================================================
14
--- lshw-02.16.orig/src/core/dmi.cc 2014-02-24 18:38:37.382039999 -0700
15
+++ lshw-02.16/src/core/dmi.cc 2014-02-24 18:39:51.062039999 -0700
17
u16 dmimaj = 0, dmimin = 0;
20
-#if defined(__arm__) || defined (__hppa__)
21
+#if defined (__aarch64__) || defined(__arm__) || defined (__hppa__)
22
return false; // SMBIOS not supported on ARM and PA-RISC machines