** Description changed:

- lshw parses /proc/device-tree to read system properties on device-tree-
- based platforms. But, on little endian systems like armhf and arm64, it
- doesn't properly convert the data, which should always be big endian.
- This can cause incorrect data to be reported. For instance, a 1GHz cpu
- might be reported as 13MHz because lshw reads a frequency of 0xca9a3b
- (13MHz) instead of 0x3b9aca00 (1GHz).
+ [Impact]
+ lshw parses /proc/device-tree to read system properties on device-tree-based 
platforms. But, on little endian systems like armhf and arm64, it doesn't 
properly convert the data, which should always be big endian. This can cause 
incorrect data to be reported. For instance, a 1GHz cpu might be reported as 
13MHz because lshw reads a frequency of 0xca9a3b (13MHz) instead of 0x3b9aca00 
(1GHz).
+ [Test Case]
+ Run lshw on an HP m800 cartridge and examine the cpu frequency.
+ [Regression Potential]
+ We're changing parsing code, so there's a possibility that we break that code 
on systems that currently work in trusty. I tested on a big endian system to 
make sure it didn't break things there (powerpc), and found the output to be 
byte-for-byte identical before and after the patch.

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1308760

Title:
  lshw doesn't deal w/ device-tree endianness

To manage notifications about this bug go to:
https://bugs.launchpad.net/lshw/+bug/1308760/+subscriptions

-- 
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to