Commit graph

1994 commits

Author SHA1 Message Date
Harald Hope 089766b34e typo fix 2023-09-17 17:46:15 -07:00
Harald Hope 71cfe887a3 Updated for change to codeberg.org from github, updated readme,
added a short term patch version so the master inxi has the right
urls in it.
2023-09-17 17:42:36 -07:00
Harald Hope 209b979f1f Added TLS removal notice for inxi/pinxi install on README.txt 2023-09-13 19:15:33 -07:00
Harald Hope 9cca058f5d Some significant bugs, 1 showstopper for FreeBSD, and one universal one for USB
network devices, and possibly some other USB device types. Also some nice new
features.

--------------------------------------------------------------------------------
SPECIAL THANKS:

1. SYSTEM: Github user chromer030 in issue #285 - a very nice small enhancement
to -Sxxx line, adding kernel clocksource, and with -Sa, adding available
clocksources. I wish all issues were this clean and easy to implemment, with
such clear benefit.

2. BLUETOOTH: Github user chromer030, issue #286 - extending and adding
bluetooth report feature. This required refactors and some cleanup of bad logic
to make -E more able to handle new data sources, and also made me fix the docs
and add debugger data files to make testing changes for various bluetooth
datasources easier. Adding btmgmt turned out to have a lot of long term benefits
to the bluetooth feature and internal inxi logic, I hadn't realized how hacked
on bluetooth feature was, but code review showed it clearly.

3. SYSTEM: Github user oleg-indeez found a break in FreeBSD compiler data, 2
glitches, one made inxi crash due to is array test on undefined reference, the
other maybe a bad copy paste in the past that assigned compiler data to wrong
hash. See CODE 3 for details on the ref issue.

4. SWAP: Github user chromer030, again, issue #290 suggested some swap
zram/zswap data enhancements, seems good, so thanks.

5. UsbData: Slackware/Linuxquestions.org poster J_W for posting on a device
missing in his output as of 3.3.27 inxi. This exposed bug 3, which usually was
npt visible since the fallback was catching most of the network matches, but
since he had a TP-Link, and it went missing, it triggered the issues, and also
exposed the inconsistent upper/lower case use in device type from kernel.

6. NETWORK: Slackware user babydr on linuxquestions.org tripped a bug in
network, was not counting correctly to limit IP list. Led to showing limit
message on 10th row of network report, not 10th IP of a device. See Bug 4.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Nothing new.

--------------------------------------------------------------------------------
BUGS:

1. BLUETOOTH: with hciconfig, would show wrong LMP/HCI version because either
the syntax changed for those strings, or it was wrong always. I think it changed
because this worked correctly at one point. Should now show the right hci/lmp
versions, and the bluetooth version as expected for hcicconfig/btmgmt.

2. SYSTEM: CPU compiler broke for FreeBSD 13.2, caused by bad test for undefined
array in CompilerVersion::version_bsd(), and also, assigned kernel compiler data
to %dboot instead of %sysctl hash. Thanks oleg-indeez for spotting that one and
figuring it out.

3a. UsbData: Failure to use /i caseinsensitive on regex led to failure to detect
USB type using standard defaults, but then a further regex error, subtle, missed
a | between two elements of a pattern, led to the last fallback case for network
detection failing. This was coupled with a change in the Kernel, which now uses
Uppercase first sometimes, and sometimes lowercase first. I think that's a
change anyway. This resulted in some usb type hashes failing to load specific
devices, network in this case, TP-Link, which was the fallback pattern that
broke.

3b. UsbData::assign_usb_type() improper nesting of tests led to failures that
should not have happened, like a bluetooth device cascading down to network.

4. NETWORK: IP limit was limiting based on total row count, not the actual count
of IPs for that device. Not sure how that slipped up. Now correctly limits the
IPs, not the previous total rows in Network report. Thanks babydr / Slackware
forums for finding yet more issues.

--------------------------------------------------------------------------------
FIXES:

1a. BLUETOOTH: added in switches for fake bluetooth data for all bluetooth data
sources.

1b. BLUETOOTH: made --bt-tool load $force{[tool]} to be consistent with rest of
logic in inxi for forcing use of specific tools. No idea why I made a standalone
one only for Bluetooth.

1c. BLUETOOTH: the HCI/LMP version generators were mixing up bluetooth version
string and LMP, leading to wrong results. See BUGS 1. I think this was a syntax
change because I would not have generated this originally if the syntax had not
worked, at least I don't think I would have. See also DOCS DATA item, added in
samples for dev purposes to avoid this type of issue in future.

2. UsbData: Device type from /sys could be upper/lower case first, but inxi was
not testing for anything but lower case, which would lead to fallback tests for
Bluetooth, Network, at least, maybe others. This goes with BUG 3, which exposed
a small torrent of such potential failure cases. The fallback block of regex is
really only designed to catch the few that don't get caught by the generic type
tests.

3. NETWORK: UsbData::set_network_regex(). Bad regex caused bluetooth device:
"Intel Bluetooth wireless interface" to trip an overly loose regex for wireless.
See BUG 3b. The real issue was incorrect test nesting which led to a bluetooth
device falling down to network regex, which it should not have done. It also
failed test the product name for bluetooth, which led to failure as well.

4. SWAP: Was failing to capture some zram syntaxes, regex was too tight. Failed:
/run/initramfs/dev/zram0.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. SYSTEM: added kernel current clocksource for -Sxxx, and alternates for -Sa.

2. BLUETOOTH: added btmgmt as first fallback to hciconfig, that one also
supplies bt version via lmp version, like hciconfig. Note this tool has very
little useful information.

3. Added back in discoverable, active discovery, and pairing status with -Ea.
This data is also crudely available from btmgmt but I would not bet on those
items actually being right. I'm not totally convinced that's good data, so
making it admin for now. Put these in a 'status:' parent container.

4a. SWAP: Added zswap enabled, compressor, max_pool_percent for -ja swap general
features line. If no zswap data and Linux, shows 'N/A'.
https://www.kernel.org/doc/Documentation/vm/zswap.txt

4b. SWAP: Added zram comp_algorithm max_comp_streams to -j per line report, only
for zram, of course.
https://docs.kernel.org/admin-guide/blockdev/zram.html

--------------------------------------------------------------------------------
CHANGES:

1. None that are obvious.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. DATA: Added new data/bluetooth/, with several sample 'btmgmt info' and
'hciconfig -a' outputs for debugging and reference purposes. These work with
the revised debuggers and force/fake data switches for bluetooth. Should add
some bt-adapter --info samples too to make testing/debugging easier.

2a. DOCS: Made new docs/inxi-bluetooth.txt doc.

2b. DOCS: Moved more data out of inxi-data.txt and inxi-resources.txt, into
inxi-bluetooth.txt, tips-tricks.txt, man-pages.txt. While I'm not going to do it
all at once, I am trying to move relevant data into granular doc file as I hit
that during dev.

2c. DOCS: Updated and organized docs/inxi-tools-mapping.txt more, new mapping
tools added. inxi has so many manually updated mapping tools that it's going to
get more and more important that this document is accurate, and is updated when
required.

3a. MAN/OPTIONS: Added BT tools to --force lists, and updated --bt-tool list.
Also added -Ea options, the status: stuff.

3b. MAN/OPTIONS: Made consistent, lower case rpm, both PM type rpm and rpm as
rotation were switching between RPM and rpm randomly.

3b. MAN/OPTIONS: Updated for --force ip/ifconfig, --ifconfig.

3c. MAN/OPTIONS: Updated for zswap, zram extra -ja data.

--------------------------------------------------------------------------------
CODE:

1. BLUETOOTH: added %force bluetoothctrl, bt-adapter, btmgmt, hciconfig, rfkill,
and added checks to enable $fake{'bluetooth'} in the main callers for each type.
This makes debugging and development a lot easier. Also removed the force tool
block in CheckTools, no idea, again, why I did it that way only for bluetooth.

2. CheckTools: got rid of set_forced_tools(), which was only used for bluetooth
tools, and didn't fit with the rest of the core logic.

3. SYSTEM: CompilerVersion: used array refs wrong, or rather, used refs wrong,
which led to various errors that were confusing. Corrected to start out with an
array ref, then to pass that as is, leaving it the same ref all through, for bsd
and linux. This is the method inxi should have always used for passing array/
hash refs around, create as ref, then pass around, and update, without assigning
a new ref to it.

I had failed to verify that the same ref was being used through the sequence.
Unfortunately this error is probably very widespread in inxi, because no
consistent rule was created and enforced from the first lines of Perl.

4. UsbData: added source type to --dbg 6 output, and added --dbg 55 to output
the per type arrays.

5. NETWORK: IpData:: added --ifconfig/--force [ip|ifconfig], --fake ip-if to
allow for basic debugging for -n / -i IP data sources. Not super useful since so
much comes from /sys, but there was nothing there at all, which is weird for
networking.

6. SWAP: Changed to passing data using scalar references, not returning an
array of the items, and got rid of the copies in the swap_data_advanced() tool.
It's less readable, but incurs basically very little overhead, and with the new
function / method arg lists I'm using more now, it's clear what the references
are.

7. IpData: got rid of extra array copies for push, pointless.
2023-08-15 20:07:26 -07:00
Harald Hope 7a79e846de small fix 2023-07-10 15:40:08 -07:00
Harald Hope 2434d89d0c New version, new man. Continuing the Memory info rollout started in 3.3.27.
--------------------------------------------------------------------------------
SPECIAL THANKS:

1. Thanks to linuxquestions.org Slackware forums for poking around a bit at the
new Memory total logic.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1a. MEMORY: The memory total: has to be synthesized in some cases, based on some
math and educated guessing. When these guesses fall outside of predetermined
ranges, inxi will show note: est. to let the user know the total was synthesized
and possibly incorrect. For detected virtual machines, inxi does not try to
synthesize the total because a VM can have any amount of RAM assigned.

If superuser, and -m used, shows the real total from dmidecode if any RAM was
found. Not all systems have DMI RAM data however, or have dmidecode installed.
Will fallback to sythetic method in that case, which is usually right.

1b. MEMORY: With the superuser /proc/iomem method, if on a VM and not using even
GiB sized RAM ollocation, and -M is not triggered (which usually lets inxi know
it's a VM), the total will get rounded up or down based on a set of rules. For
example, 2.5 GiB real would become 3 GiB. I don't see any solution to this,
either assume the /proc/iomem is right but needs rounding up, or assume the /sys
block counts are right, or remove the feature.

Shows note: est. in cases where the rounded total is greater than a dynamic
factor difference from the internal total amount.

2. GENERAL/GRAPHICS: The problem of users showing up, requesting a feature, then
not doing any work, research, supplying energy, interest, and dare I say,
passion - nothing, expecting 'someone else' to do the work for them, continues,
sadly, with the recent request for vulkan data for Graphics. This appears to be
a problem more with the modern generation of free software users, I don't
remember this type of attitude 20 years ago, but I did watch it as it started
getting more common. Demotivating to be honest, but maybe one day someone will
show up who actually cares enough to help get the features they want developed.

While I am leaving that up as a low priority feature request, I am not
personally interested in that feature, nor is anyone else I asked, and given how
much raw data there is, and how difficult it is to parse, I'll just leave it as
an existing issue which might get work in a few years time, or not, basically
will require someone showing up who actually actively cares.

--------------------------------------------------------------------------------
BUGS:

1. DISK: total: used: report could have had wrong results for used:, like used
being > total: because the filter lists were missing some file systems for
exclusion. More of a fix than a bug, but users might see it as a bug.

--------------------------------------------------------------------------------
FIXES:

1. INFO: get_gcc_data(): was showing same GCC version as main and alternate.
Failed to filter out the discovered primary, that is. This is because usually
name is gcc-11 but sometimes it's the whole version, like gcc-11.2.0, the full
version string. This is the case in Slackware for example.

2. SHORT: MEMORY: BSD: did not show '%' for memory used percent, just the
number.

3. DRIVES/PARTITIONS: PartitionItem::set_filters() added many more exclude
types, that will help avoid both creating wrong disk used totals, and also not
show label:/uuid: fields for filesystem types that don't have uuid/labels. There
were a lot missing: encrypted, distributed, stackable, remote. Should clean up
wrong disk used values in some cases.

4a. PARTITIONS: PartitionItem::set_filters(). Added a lot of file systems, many
fuse, distributed, stackable types.

4b. PARTITIONS: Extended remote file system ID by fs, and added fuse fs for
local mounts, like gvfs, mtp, ptp and many other variants, that's things like
mounting apple partition, android, iphone, archives, etc. This should correct an
entire class of source: ERR-102 outputs.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. BATTERY: Added 'power' to battery report. That's the amount of watts its
using at that moment, so not super useful since it's running inxi at that
moment. But the data was there, so might as well show it. Only for -Bxx since it
will be so variable. Shows after the charge/condition item.

2. SYSTEM: DistroData: added Oracle id and system base. Added Springdale/PUIAS
system base support. Note, unusually, Eurolinux, ScientificLinux 'just worked'
re id and system base even though that had never been explicitly added. This is
because their os-release file contains 'centos' string.

3. SYSTEM: DistroData: Added ubuntu mantic minotaur to ubuntu id matching table.
This only really is used by Mint, but there you have it. Also added Debian 14
codename Forky.

4a. MEMORY: Add total RAM from one of following:

* /sys/devices/system/memory (if it's available). This directory has to be
compiled into kernel, so is not always present. This source has advantage of
being user readable. If out of set bounds, shows note: est. to let user know
it's an estimate.

* If superuser and /proc/iomme, gets the total from /proc/iomem using some
tricks and synthetic methods, which in general is pretty accurate, but when out
of the bounds set, shows note: est. to let user know results are only estimates.
This overrides /sys total.

* If -m and dmidecode data found, uses the real RAM module total. For Linux and
superuser. This overrides iomem and /sys totals.

4b. MEMORY: add iGPU RAM from /proc/iomem when detected. Requires sudo/root.

4c. MEMORY: using the real -m/RAM total for memory total when available, since
that is the actual value we want, not the estimated stuff from /proc/iomem or
/sys/devices/system.

5. RAM: added a long time oversight, lack of per array RAM installed size and
occupied slots (modules). Those are now part of the Array line for each set of
modules. Since total already shows in System RAM line above, the granular per
array installed size total only shows if > 1 array is present, ie, almost never.

6. DRIVES: disk vendors, added more matches and vendors. We'll know the world is
changing in a significant way when no new vendors appear for a while, but that's
unlikely in the near term.

7. CPU: cpu_arch(), a few new ids added.

8. GRAPHICS: new amd, intel, nvidia ids, updates to driver version etc.

--------------------------------------------------------------------------------
CHANGES:

1. SHORT: for Memory:, switched to using MiB/GiB/TiB, these numbers are just
getting too big to be readable. This is also dynamic, if both used and available
are the same unit, shows x/y [unit], otherwise shows x [unit]/y [unit].

2. MEMORY: changed gpu: to igpu: to avoid confusing it with standalone gpu.
Since only raspberry pi had gpu ram data before, almost nobody would have seen
this in general anyway.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. MAN/OPTIONS: Updated for -Bxx, battery power now.

2. MAN: updated to better define where the System RAM: total:.. available etc
come from, and what they refer to. Also added explanation in -m section about
what the stuff is, and what the field names refer to.

2a. DOCS: docs/inxi-ram.txt added, and more info moved from inxi-data.txt and
inxi-resources.txt. Goal is to remove both those files and move all their data,
and any new data, into granular inxi-xxx.txt files. Also moved some RAM data
from inx-unit-handling.txt to inxi-ram.txt.

2b. DOCS: docs/inxi-unit-handling.txt: updated with more ram / memory units,
code, etc, to better fit with the concept of the inxi-unit-handling.txt doc.

2c. DOCS: docs/inxi-partitions.txt: updated, added more sources for partition
file system types, cleaned up, more useful as a reference now.

2d. DOCS: docs/inxi-distros.txt: NEW, merged data from inxi-data.txt,
inxi-resources.txt. Updated and added more info.

2e. DOCS: docs/inxi-tools-mapping.txt split off from inxi-tools.txt, makes it
easier to find the mapping functions and features, which are hard to remember.
Also updated and improved its usability. This is kind of a key document because
it's hard to remember all the mapping tools internally, and this also connects
those tools to their relevant granular inxi-xxx.txt docs. Not that it will help
get helpers for these tedious tasks, but one can always dream, can't one?

3. DATA: data/graphics/ added for first vulkaninfo output file.

--------------------------------------------------------------------------------
CODE:

1a. RAM: Fixed an irregularity, for RamItem, it used MiB as internal unit, this
was silly because inxi uses KiB everywhere else. This correction was relatively
easy to do, and allows the values to be used by other parts of inxi, like
MemoryData.

1b. RAM: Added return of ram total for memory.

2a. INFO/RAM/PROCESSES: When MEMORY active, now uses row reference to create the
fields. For INFO, now uses MemoryData::row() to generate the row fields instead
of doing the logic in the info line generator. This simplifies the processing
and allows for more granular control of output.

2b. INFO/RAM/PROCESSES: Added debugger switches --dbg 53 (show raw KiB/count
values for /sys/devices/system/memory and /proc/iomem. Added --dbg 54, which
shows per line size for iomem, in human readable units, and a final summary
report of iomem and /sys data, this speeds up debugging.

2c. INFO/RAM/PROCESSES: Added --fake iomem, --fake sys-mem for debugging and
testing.

3. MEMORY: MemoryData::short_data(): added so one tool generates output for all
sources for short data. Easier to track and make consistent, and to make more
granular and robust.

4. DRIVES/PARTITIONS: PartitionItem::partition_filters(),
PartitionItem::fs_excludes(): refactored into PartitionItem::get_filters(),
PartitionItem::set_filters(). Cleaned up, organized better, made comments much
more useful. Goes with DOCS 2c updates. Now there's just one sub that does this
filter/exclude work, which makes it easier to maintain long term.

5. GLOBAL: Used a trick I just learned, declaring variables in the bracket scope
of a class, but not inside the package/class declaration. This makes it work
like a static variable, which Perl 5.008 doesn't support. You have to use a sub
inside the bracket scope to return the data outside that scope, but that is easy
to do.

6. MACHINE: Added return of b_vm for VM detection in MEMORY.

7. SYSTEM: CompilerVersion: Failed to properly use references when passing
$compiler around, not actually sure why it worked, but now is consistent.
2023-07-10 14:18:45 -07:00
Harald Hope ed7049fcc1 Completion of the audio fixes and improvements of 3.3.26. Added less common
sound servers like EsounD and aRts, and made state reports more accurate for
ALSA.

Major USB code and data upgrades/refactors. The USB changes prepare inxi for USB
4, and adds lanes and Si/IEC speeds to the report. It is important to determine
what USB mode you are running in with 3.x and 4. These changes conform more
closely to how the USB consortium wants USB speeds refered to.

With more robust USB data, this data now appears in a similar form as pcie: data
for Devices, -A, -E, -G, -N, and for -D drives, as usb: plus rev, speed, lanes,
mode, with the -xx/-a options, like pcie. This has been a long standing
oversight and weakness of inxi USB and Device data, but now the two are fully
integrated, including for drives, which was quite tricky to get working.

Added netpkg and Zenwalk support to packages and repos. Also added repos support
for sbopkg and slpkg, and updated package tools for Slackware.

And more distros added to system base feature, and a few more for main ID.

Improved --recommends report quite a bit, now it's more granular for missing
packages and package manager reports, and also fixed a long standing missing
current shell + version issue. Added the final package manager type, pkgtool
(Slackware), that will be supported, which makes for 4, which is enough. Note
that other package managers can be added following the documentation
instructions for packagers, but this is enough for out of the box pm handling.

Fixed a long standing oddity with how free / /proc/meminfo report MemTotal vs
the actual physical RAM. I believe this issue also showed with GPU assigned RAM,
but now for all but short form, shows Memory/RAM: available: ... used: ...

--------------------------------------------------------------------------------
SPECIAL THANKS:

1. To the Slackware people at linuxquestions.org forums, who helped, again, on
this audio feature, even finding current or not too old systems that use some of
the new / old audio servers (EsoundD) running in the wild, which I never
expected to see. And also for exposing some weak spots in the USB advanced
logic, and helping with the sbopkg and slpkg repo logic and tools reports.

2. To the Manjaro forum users, for providing cases that show where inxi can be
improved. The audio server/api issue, the current USB 3/4 upgrade, were
initiated by threads pointing to things that could be improved in inxi. So I
guess the real thanks are for using inxi enough to trigger cases that show where
it's weak or can be better. Note that this requires that I follow roughly their
forums, however I only look at threads that seem like they might be of general
interest, or which suggest a possible weak spot in inxi, and I don't follow them
consistently. More reliable is to file github issues, since I will always see
those.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. DesktopData: at one point, BunsenLabs Debian OpenBox had XDG_CURRENT_DESKTOP
set to XFCE, which it isn't, but inxi can't work around such hacks, plus I don't
even know if Bunsen is around anymore anyway.

2. DesktopData: CODE 1 reminds us that the time to depend on x tools like xprop
for anything re desktop/wm detections is fast drawing to a close, true Wayland
will not have xprop, unless it's running on xwayland, which is not something
that should be relied on. Maybe recheck Moksha/Enlightenment which depend on
xprop for version detection.

The list of xprop detected wm/desktops in get_env_xprop_misc_data() is almost
all X only wm/desktops, so those should be safe unless one of them decides to
work on a wayland comositor.

3. BSD: ongoing weaknesses in BSD data sources make maintaining feature parity
impossible, but I am trying to get the BSD data as clean and consistent as
possible. I wish this were not the case, but the fact is, /sys is expanding and
creating excellent and reliable data sources with every major Linux kernel
update, and so far nothing comparable has appeared in the BSDs. This is just
reality, it's not a condemnation, but something like the /proc then /sys file
systems are an excellent idea, well worth emulating.

4. For the RAM available/total clarification, there's a slight issue because
free/meminfo show MemAvailable as Free for use RAM, but dmesg shows available
meaning what was available to the system during boot, minus the reserved
percentage. Since we needed one term, available to System offers the closest
in terms of technical precision without being too verbose. Technically available
in this context means: total physical minus 'kernel code' minus 'reserved'.

--------------------------------------------------------------------------------
BUGS:

1. CheckRecommends: See Fix 6b, more or less a bug, but really just a fix.

2. AUDIO: for USB devices, put extra data into row 0, no matter which row the
USB device is. This led to the extra data for USB being assigned to the wrong
row. Sigh.

3. OptionsHandler: When show{'ram'} was set, for bsd, set use{'bsd-raid'}, which
makes both show raid and ram fail for BSD. Oops. User mode RAM data only seen in
OpenBSD so far. This made loading $dboot{'ram'} fail, and any raid as well,
sigh, unless -m was also tripped.

--------------------------------------------------------------------------------
FIXES:

1. DistroData: typo for Arch base: was ctios, was supposed to be ctlos.

2a. DesktopData: found case where xprop -root not present (Void Linux), so xfce
test failed. Split to new function dedicated to xfce detection that doesn't use
xprop data. Also, XFCE is working on their Wayland version, which would in
theory not even have xprop by default.

Also, the base version number test for xfce depended on xprop, but
xprop doesn't even have that xfce version data anymore, so just checking if
xfce(4|5|)-panel exist and assigning primary version based on that test.

2b. DesktopData: Also see See CODE 1a,1b for further xprop and test fixes that
could have led to false positive or negative test conditions for the items that
used xprop tests. These tests are all xprop agnostic now, if it's there, they
will use it, if not, do the best they can.

3. PackageData: fixed legacy dpkg-query, old version did not support -f shortcut
for --showformat. This made dpkg package listing fail.

4a. GRAPHICS: Added legacy XFree86.0.log to X log path detection, that was an
oversight. Also added legacy module syntax _drv.o (not _drv.so). This gets X
driver data now for very old systems.

4b. GRAPHICS: fixed corner case where no x driver data, running as root, was not
supposed to show 'note: X driver n/a' message, that was a holdover from before
driver output was cleaned up and driver: N/A shows when no drivers at all found.
Just forgot to remove it when doing recent updates in the driver section, maybe?

5. REPOS/PackageData: For netpkg Zenwalk Slackware systems, showed only slackpkg
repo data, empty, and showed the Slackware pm, not netpkg for pm. See
Enhancements 5, 6.

6. REPOS: removed slapt_get file /etc/slapt-get/pubring.kbx, that's not a repo
file. Thanks chrisreturn for pointing that out.

7a. CheckRecommends: See also CODE 6. Fixed case where > 1 package manager is
detected on system, now lists them one by one for detected, and shows package
install options as well. Before only picked first detected, which could lead
to wrong results for Missing Package lists.

7b. CheckRecommends: Fixed glitch, forgot to update the current shell/version
when ShellData was refactored, this led to no current shell + version showing
up in recommends core tools report.

8. RAM: fixed speed_mapper string match to allow for older syntaxes. This is as
far as known OpenBSD only, from dboot data. Matches then converts PC2700 to
PC-2700 which then allows for mapping.

9. RAM/PROCESSES/INFO/SHORT: Finally tracked down a long time oddity, where for
example:
 RAM: total: 31.28 GiB
does not match 32 GiB physical installed. This is because that is the total
available after kernel and system reserved RAM is deducted, and in some cases,
GPU allocated RAM. There are also corner cases where the listed amount can be
less due to physical RAM damage, but that's uncommon.

Added explanation of why it's different, and what available is referring to in
man -m/--memory.

Changed -m, -tm to show:

System RAM: available: 31.28 GiB used 26.23 GiB (83.9%)

and -I to show:

Memory: available: 31.28 GiB used 26.23 GiB (83.9%)

You can get the 'reserved' and 'kernel code' data from dmesg, but since Debian
made that root/sudo tool, can't count on being able to parse that out of dmesg,
plus you can never count no dmesg anyway since it can get overwritten by kernel
oops or wonky device etc. inxi doesn't use dmesg data for Linux for this reason.

... [    0.000000] Memory: 32784756K/33435864K available (10252K kernel code,
1243K rwdata, 3324K rodata, 1584K init, 2280K bss, 651108K reserved, 0K
cma-reserved)

Also removed Raspberry Pi video RAM added back in to total now that it's clear
it's what is available. This may also make systems with GPU using system RAM
more correct.

9. SENSORS: sensors /sys tried to create concatenated string with $unit $value
but these are not necessarily defined, that needed to be protected with defined
tests.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1a. AUDIO: JACK: added helper nsmd (new session manager), and its recommended
gui agordejo. That's the drop in replacement for non-session-manager, the dev of
which apparently lost interest in that project. But the ID method will work fine
for for either, since both ran as nsmd.

1b. AUDIO: PULSE: added pulseaudio-alsa plugin support for helpers. This is like
pipewire-alsa plugin, just alsa config file. Only seen in Arch Linux so far, but
if others use similar paths for the glob pattern, they will also work fine.

Also added pulseaudio-esound-compat plugin, which is easier to detect with
/usr/bin/esdcompat.

Also added paman, pulseaudio manager.

1c. AUDIO: ESOUND,ARTS: added legacy esd (EsounD aka: Enlightened Sound Daemon)
and aRts sound server support, with basic help/tools. These are quite old, but
are still occasionally seen in the wild on newer systems, surprisingly enough.

1d. AUDIO: ALSA: added alsactl to alsa tools. Missed that one, it's an /sbin
type utility.

1e. AUDIO: ALSA: First try at ALSA compiled in but inactive report,  previously
depended on active only state of the API. Now uses compiled in SND_ kernel
switch using the /boot/config-[kernel] file, which is a big expensive parse but
only will activate on Linux kernels with no /proc/asound present. This fallback
fails if kernel config file not present: /boot/config-$(uname -r).

1f. AUDIO: OSS: added tool ossctl.

1g. AUDIO: NAS: added helper: audiooss which is an OSS compat layer.

2a. DistroData: added Arch base distros: ArchEX, Bridge Linux, Condres OS,
Feliz, LiriOS, Magpie, Namib, Porteus, RevengeOS, SalientOS, VeltOS.

None of these are verified. Some don't exist anymore.
Source: https://www.slant.co/topics/7603/~arch-linux-based-distributions

2b. DistroData: added ubuntu lunar 23-4 release id.

2c. DistroData: added porteux, added porteux, zenwalk to slackware systembase

3. DesktopData/GRAPHICS: added Smithay Wayland compositor. Not verified.

4a. UsbData/UsbItem: added USB lanes (-Jxx) and mode (-Ja), to add more useful
data about USB revision and mode names the USB group has created. Otherwise it's
too difficult to try to explain it. Note that -Jxx lanes follows other inxi
items that show PCIe lanes as an -xx item to try to keep it consistent.

This also consolidates the bsd and linux data sources, see CODE 5.

Note modes and lanes are Linux only because the revision number, lanes, and
speed used to determine mode are only natively available in Linux as actual
internal data values. If this changes BSD support will be added in the future.

The BSD rev and speed data is synthesized completely by inxi using some string
values, and thus is not reliable, which means that pretending inxi can get this
granular with data that is not coming directly from the system itself is
probably not a good idea.

Following wikipedia mode names: https://en.wikipedia.org/wiki/USB4

These are the known possible combinations:
rev: 1.0 mode: 1.0 lanes: 1 speed: 1.5 Mbps
rev: 1.1 mode: 1.0 lanes: 1 speed: 1.5 Mbps
rev: 1.1 mode: 1.1 lanes: 1 speed: 12 Mbps
rev: 2.0 mode: 1.0 lanes: 1 speed: 1.5 Mbps
rev: 2.0 mode: 1.1 lanes: 1 speed: 12 Mbps
rev: 2.0 mode: 2.0 lanes: 1 speed: 480 Mbps
rev: 2.1 mode: 2.0 lanes: 1 speed: 480 Mbps
rev: 3.0 mode: 3.2 gen-1x1 lanes: 1 speed:  5 Gbps
rev: 3.0 mode: 3.2 gen-1x2 lanes: 2 speed: 10 Gbps
rev: 3.1 mode: 3.2 gen-1x1 lanes: 1 speed:  5 Gbps
rev: 3.1 mode: 3.2 gen-1x2 lanes: 2 speed: 10 Gbps
rev: 3.1 mode: 3.2 gen-2x2 lanes: 2 speed: 20 Gbps [seen this case]
rev: 3.2 mode: 3.2 gen-1x1 lanes: 1 speed:  5 Gbps [wrong rev: seen this case]
rev: 3.2 mode: 3.2 gen-1x2 lanes: 2 speed: 10 Gbps [wrong rev: possible case]
rev: 3.2 mode: 3.2 gen-2x1 lanes: 1 speed: 10 Gbps
rev: 3.2 mode: 3.2 gen-2x2 lanes: 2 speed: 20 Gbps
rev: 3.2 mode: 4-v1 gen-3x2 lanes: 2 speed: 40 Gbps [not seen, but possible]
rev: 4 mode: 4-v1 gen-2x1 lanes; 1 speed: 10 Gbps
rev: 4 mode: 4-v1 gen-2x2 lanes: 2 speed: 20 Gbps
rev: 4 mode: 4-v1 gen-3x1 lanes: 1 speed: 20 Gbps
rev: 4 mode: 4-v2 gen-3x2 lanes: 2 speed: 40 Gbps
rev: 4 mode: 4-v2 gen-4x1 lanes: 1 speed: 40 Gbps
rev: 4 mode: 4-v2 gen-4x2 lanes: 2 speed: 80 Gbps
rev: 4 mode: 4-v2 gen-4x3-asymmetric lanes: 3 up, 1 down speed:120 Gbps

I believe 120Gbps takes the 2 lanes of tx/rx and converts 2 rx lanes to tx so
the entire lane is dedicated to transmit. and the third lane is dedicated to rx.

Includes error message for unknown usb 3/4 rev/speed match combos. These can be
bad hardware self reporting or unknown other issues.

4b. USB: Added Si/IEC speeds (base 2, base 10). -Ja triggers extra IEC, base 2
Bytes (xxx [MG]iB/s). -Jx triggers basic standard Si xxx [MG]b/s base 10 bits.

5a. PackageData: added netpkg as package tool. This stores data in same location
as slackpkg, but assume if exists directory /var/netpkg, then the system is
using netpkg as pm, not slackpkg.

5b. PackageData: added Slackware sbopkg, sboui as tools for pkgtool and netpkg.

6a. REPOS: added netpkg (Zenwalk Slackware based pm) repo report.

6b. REPOS: added sbopkg basic repo report. This handles both value syntax types,
as well as the ability of /root config file to overwrite /etc config repo.

6c. REPOS: added slpkg repo report. This handles their old and newer syntax.

7a. CheckRecommends: For Slackware users, added pkgtool missing package name,
also will use netpkg so hopefully Zenwalk uses same package names.

7b. CheckRecommends: Added radeon to kernel modules checks.

8. AUDIO/BLUETOOTH/DRIVES/GRAPHICS/NETWORK: For USB, -[ADEGN]xx adds rev, speed,
lanes. -[ADEGN]a adds mode.

9. RAM: Updated RAM PC DDR in speed_mapper(), which is as far as I know only
used by OpenBSD, which allows for MT/s speeds as non-root user, which is nice.
That list hadn't been updated in a long time, so filled out DDR 1-5 PCx-yyyy
ids.

--------------------------------------------------------------------------------
CHANGES:

1a. USB: For -Jxy1, speed is now a child of rev: parent. This goes along with
mode: and lanes: being children of rev:. This follows how USB consortium wants
to refer to USB revisions now: by speed, lanes, and modes, the latter being the
technical term, the speed being the marketing term.

1b. USB: If no speed data found, show N/A. This should almost never happen
except for very old Linux and rarely with BSD.

1c. USB: Device type is lower cased except for abbreviations (type-C, HID). This
makes it more consistent as a value.

1d. USB: Show basic Si speed with -Jx, and adds new IEC speed with -Ja.

2. CheckRecommends: See ENHANCEMENT, CODE 6. Now showing row by row package
managers and missing packages, by package manager(s).

3. DRIVES: Changed long standing redundant use of 'type':
type: USB ... type: HDD
to:
type: USB ... tech: HDD
'tech:' means the technology used, HDD, SDD, and if we can ever figure out how
to detect it, Hybrid Hard Drive (HHD),

4. AUDIO/BLUETOOTH/DRIVES/GRAPHIC/NETWORK: moved 'type: USB' pair to after
driver for -A/-E/-G/-N, which allows it to be the parent of the new USB data
block. Negative is it moves it a bit further back in the line.

For Drives, it moves it from after /dev.. maj-min to after block-size, However,
with -D/-Dx, it's last in the line, which is nice. This is the only way I could
find to make it more consistent across all possible USB device/drive type
reports.

5. INFO/RAM/PROCESSES: Changed -I:

Memory: [total] used:
to:
Memory: available: [total] used:

Changed -tm/-m to be consistent:

Memory: RAM: total: .. used..
to:
Memory: System RAM: available: ... used:..

This corrects a long standing inaccuracy where MemTotal is not actually the full
system RAM, but is the RAM minus reserved stuff for system and kernel, and GPU
memory in some cases.

--------------------------------------------------------------------------------
DOCUMENTATION:

1a. DOCS: docs/inxi-audio.txt: ongoing updates, adding more information, more
on helpers, detection methods, etc.

1b. DOCS: New: docs/inxi-usb.txt: USB info, update, added more, a work in
progress.

1c. DOCS: docs/inxi-custom-recommends.txt: name in inxi comment did not match,
and updated to new comment cleaned up syntax in example. Fixed inxi comment file
name.

1d. DOCS: New: docs/inxi-unit-handling.txt: To document how inxi handles
size/speed data internally, and ideally, to help integrate all those methods
into one big tool one day, not spread across many area.

1e. DOCS: New: docs/inxi-repo-package-manager.txt: To start to document arcana
and methods and commands and outputs for package managers. Since this is a late
start, will take time to complete, but better late than never.

2a. MAN/OPTIONS: updated for USB -Jx, -Jxx, -Ja, adding lanes, mode, iec speed
items.

2b. MAN/OPTIONS: fixed error which had USB speed as -Jxxx instead of -Jxx. Also
then changed speed to be -Jx.

2c. MAN/OPTIONS: updated for repos for SBOPKG, SBOUI, SLPKG, and added
SLAPT_GET, I'd forgotten that one.

2d. MAN/OPTIONS: updated for -xx[ADEGN] USB rev, speed, lanes; for -a[ADEGN]
updated for USB mode.

2e. MAN/OPTIONS: updated for memory available/used changed.

3. MAN: fixed some inconsistent use of short/long form display in extra data
options.

--------------------------------------------------------------------------------
CODE:

1a. DesktopData: New function for xfce only detections, turns out xprop is not
necessarily installed, Void Linux for example had failed ID. Old version
required xprop to do the tests, which was not robust and failed in this case.
Function: get_env_xfce_data(). Also made xprop data optional for all the
xxx_xprop_data desktop tests, not just some of them. This will forward proof
the desktops

1b. DesktopData: Fixed bad parens in test cases, was not correctly organized.
if (a || b || (c || d) && e)
was supposed to be:
if (a || b || ((c || d) && e))
Odd how those types of glitches creep in, one fix is also to just make the lines
break more reasonably so the conditions are easier to parse visually.

2a. DEBUGGER: Added /etc/X11/XF86Config-4 xorg conf file to debugger.

2b. DEBUGGER: audio_data(): added audio server versions to cover all known ones.

3. MemoryData: changed all $memory to array references, got rid of split :
separators, which were clearly legacy items leftover from bash/gawk days. Also
changed MemoryData::get('splits') to get('full') to reflect this change.

This change should be transparent though it may introduce corner case undefined
value situation but that should not happen since array values are defined first.

4. UsbData: Refactor of usb speed, rev, added lanes, mode. Refactored most of
the bsd/linux rev/speed logic, merged some of bsd speed/rev into the new
version_data() function, which loads all the data based on what is calling it.
This helps consolidate the logic across usb data sources.

5a. GLOBAL: made functions/methods use same comment syntax for args:
 args: 0:...; 1:...
always starting with 0, to match array index. Same syntax for return array index
values. In some cases simply note a variable is passed by ref:
 args: $value passed by reference.

5b. GLOBAL: made all sub/functions/methods follow the same spacing syntax. This
seems to be a good compromise for space/readability. Note that adding in these
new lines added about 400 lines to the total length, plus the line breaks that
were already there. Yes, inxi has a lot of sub routines! aka functions and
sometimes aka methods.

[empty line]
[comments]
sub [name] {

Packages/classes now also all follow the same spacing rules:

[empty line]
[comments]
{
package [name];
[empty line]
[comments]
sub [name] {
...
}
}

Internally, subs generally do not use any empty lines unless it makes sense to
do so for some specific reason.

5c: GLOBAL: made start of sub comments be upper case, I have a bad habit of
typing comments in lower case, easier to read if it's reads like a normal
sentence.

6. CheckRecommends: refactored entire items logic, set global hash for test
items. Made support > 1 detected package manager.

7. REPOS: cleaned up comments for package manager/repo blocks.

8. SENSORS: sensors_sys failed to reset to undefined $unit and $value, and also
failed to test if they were defined before using them in concatenation.
2023-05-07 11:59:56 -07:00
Harald Hope beddf67370 undid oops 2023-04-29 20:20:35 -07:00
Harald Hope a2a955d870 oops 2023-04-29 20:18:50 -07:00
Harald Hope f22449a205 man fix 2023-03-28 14:54:49 -07:00
Harald Hope 5ee29fa022 Significant upgrade to sound server running detections, much more granular and
hopefully more accurate, with more useful reporting values. Also added some nice
useful audio api/server tool and info items.

Packagers: this corrects possibly wrong or misleading audio server reports,
particularly related to PulseAudio/PipeWire, which can lead to support issues
and lack of clarity due to ambiguous or wrong reports about sound Servers
present, active, or off. Upgrading your package is highly recommended.

--------------------------------------------------------------------------------
SPECIAL THANKS:

1. Thanks to people like Chimera dev Daniel "q66" Kolesa for experimenting with
non systemd (uses dinit/dinitctl), non GCC, non GNU linux, and for making early
pre-alpha versions run in vm, and for being easy to test!

Not so much because I personally want or care about or view as a positive
skipping GNU tools or GCC in favor of clang and BSD tools, but more because
these experiments help make the general overall Linux ecosystem more robust.
Including inxi.

2. Thanks for the Manjaro people for noting this issue on their forums.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1a. AUDIO: jack_control and pw-cli won't run as root, exit with error. This
forces back to fallback process present tests for active running state.

1b. AUDIO: pactl will start pipewire/pipewire-pulse/pulseaudio if stopped and
not masked, so not using since that would make inxi alter the state of the
system.

1c. AUDIO: pipewire-alsa, pulseaudio-jack depend on file exist globs, tested on
Arch Linux, Debian base, but unknown if paths exist on other Linux pimary
distros. Easy to add to globbing tests, but no going to check them all!

2. SERVICES: systemctl status [service] can fail if service loaded using --user
which is a new one on me, not sure how to handle that.

3. It would be nice to get inxi issues like the sound server/api glitches
handled by filing an issue on inxi github, and not to rely on my seeing a random
distro forum post, which I only found by pure coincidence.

--------------------------------------------------------------------------------
BUGS:

1. AUDIO: See Fixes 3a,b,c. In some cases false report of pulseaudio and
pipewire running: yes create unclear output and results, or misleading. Thanks
to manjaro users to noticing this and mentioning it in a forum post.

Note: it's much more effective to file issues on inxi github than to hope I will
see a random forum post one day.

2. DEBUGGER: Bug in debugger, somewhere introduced '-- list' (instead of
'--list') for bluetoothctl which made older systems hang when running the
debugger. No idea when or how that space got introduced.

--------------------------------------------------------------------------------
FIXES:

1. INFO: Compilers showed Compilers: gcc: N/A when clang/gcc not installed, this
was not intended, but was a small glitch in main::get_gcc_data(), where it
assigned undef as array contents when gcc not defined. This was exposed by
Chimera, which uses clang, but would have happened any time gcc not installed on
system.

2. SYSTEM: tiny fix, was getting ',' at end of kernel compiler version.

3a. AUDIO: For pipewire, made process detection test more robust, now excludes
pipewire-pulse in case where that might be running without pipewire on/enabled.

3b. AUDIO: bigger fix, more robust tests for audio servers running for jack,
pipewire, pulseaudio, these look for more explicit server tool reports. Certain
not to be reliable always, and fail for superuser, will probably need more
tweaking. Also notes for jack, pulse, pipewire if only positive detection found
via ps aux: active (process) to avoid incorrect data, and root specific messages
depending on situation.

3c. AUDIO: was testing for pactl to determine if pulseaudio installed, but found
case where pactl could be installed without pulseaudio. Now tests for pulseaudio
installed.

3d. AUDIO: weak fix for Linux OSS4 version, using /etc/oss4/version.dat file,
which may or may not exist on all distros.

3e. AUDIO: alsa-oss compat can create /dev/sndstat file, which would then lead
to positive OSS detection even if it's not present. This is corrected, and will
not show if asound/version exists and no ossinfo. For linux, relying on ossinfo
presence, which comes from oss4-base.

3f. AUDIO: Older ALSA /proc/asound/version had a date string in parentheses
after the Driver Version, so now explicitly get the string after Version.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. REPOS: added support for /etc/apk/repositories.d/*.list, which works pretty
much the same as /etc/apt/sources.list.d/*.list. This is to make Chimera apk
repos show up, previously only supported /etc/apk/repositories file read.

2a. DistroData: Added Feren to distro system base. This was much trickier than
it should be due to inconsistent use of os-release field names, but that's how
it goes.

2b. DistroData: new Arch derived distro XeroLinux added to system base. I know,
I know, it's a never-ending endeavor (get it?) since these pop up all the time,
but might as well add them now and then as they appear.

3a. AUDIO: inxi now handles pipewire-pulse as top layer audio daemon, along with
several other server/api helpers. Note that pw-jack does not appear to be a
daemon, just a plugin, so shows 'plugin'. Extra sound server helpers added when
discovered or requested.

  API: ALSA
    v: k5.19.0-16.2-liquorix-amd64
    status: kernel-api
  Server-1: PulseAudio
    v: 16.1
    status: off (on pipewire-pulse)
  Server-2: PipeWire
    v: 0.3.65
    status: active
    with:
      1: pipewire-pulse
        status: active
      2: pw-jack
        type: plugin

3b. AUDIO: For -Aa, added tools: report. Currently supports these basic tools:

alsa: alsamixer alsamixergui amixer
jack: cadence jack_control jack_mixer qjackctl
oss: dsbmixer mixer ossinfo ossmix ossxmix vmixctl
nas: auctl auinfo
pipewire: pw-cat pw-cli wpctl) [+pactl if pipewire-pulse and no pulseaudio
pulse: pacat pactl pamix pamixer pavucontrol pulsemixer
roar: roarcat roarctl
sndiod: aucat midicat mixerctl sndioctl

Note that inxi-perl/docs/inxi-audio.txt has lists of alternates or rejected
helpers and tools, but we want to keep that output short and sane.

3c. AUDIO: For BSDs, if sndiod is detected, adds an API line for sndio. Note
this may create 2 API lines for FreeBSD using OSS.

3d. AUDIO: Added basic support for roar sound server, NAS (Network Audio
System).

4. CPU: new Intel and AMD cpu model matches for latest and future, Luna Lake,
Zen 4c.

5. GRAPHICS: new nvidia current, AMD, and Intel GPU ids.

6. DRIVES: more disk vendors, ids! The list never stops, but sadly, so many are
not identifiable. Check: inxi-perl/tools/lists/disks_unhandled to see if you
can positively identify any of those.

--------------------------------------------------------------------------------
CHANGES:

1a. AUDIO: Changed main API/Server running: to status: [status], that syntax is
more able to handle different circumstances.

1b. AUDIO: With change to status:, now uses granular fixes above, and adds root
notes if no active detections.

1c. AUDIO: Changed 'Sound API', 'Sound Server' to 'API', 'Server'. This avoids
ambiguity with some types, it's the Audio section, and those are the APIs and
Servers for that Audio section. Makes it match Graphics as well. and is shorter.

1d. AUDIO: Changed 'Sound Interface' for sndiod to 'Server', which is how it's
listed, and for BSD, added API: sndio item. Also changed 'sndio' to 'sndiod' for
the Server: item.

1e. AUDIO: Changed ALSA/BSD sndio to show: status: api since saying an api
is running makes little sense, it's there or it's not there. OSS can be enabled
or disabled so shows status: active/off for Linux, but kernel-api for BSDs.

--------------------------------------------------------------------------------
DOCUMENTATION:

1a. MAN: Added note for helpers item: with: pipewire-pulse/pw-jack etc to -Axx.

1b. MAN: Added -Aa item for audio server tools.

2. OPTIONS: Updated for -Axx helpers, -Aa tools.

3. DOCS: Created inxi-perl/docs/inxi-audio.txt doc file. Too many odd factoids
to forget about during this upgrade!

--------------------------------------------------------------------------------
CODE:

1. REPOS: Moved %keys to %repo_keys and set it only once with set_repo_keys(),
those big hash assigns per iteration are really expensive, now stores it
globally in RepoItem and sets only once.

2. INFO: main::get_gcc_data() failed to handle case where there is no gcc at all
installed, resulted in returning an array with content of 'undef', not an empty
array as intended. This made the array not set test fail for Compilers, so gcc
showed as N/A, which was not intended.

3. DistroData: changed internal lsb/osr $distro to $distro_lsb/$distro_osr,
which lets inxi update the distro name during system base processing in cases
where the data is redundant. Stupid hack, sigh, should not be necessary, but
that's life, /etc/os-release was poorly designed so it leads to such confusions.

4a. AUDIO: Added --dbg 52 to output results of pw-cli.

4b. AUDIO: refactored sound_data, renamed, added {jack,pipewire,pulse}_status(),
sound_helpers(), sound_tools() utilities.

5. DEBUGGER: added more pactl and pw-cli outputs, and pipewire-pulse,
pipewire-jack --version.

6. main::get_driver_modules(): add space after ',' if total string > 40
characters to allow splitting very long unbroken strings of modules that
otherwise would not break as expected.
2023-03-28 14:48:52 -07:00
Harald Hope 464cac2f1e A small point release, various smaller items, ongoing updates to matching table
features, bug fixes, but nothing major.

--------------------------------------------------------------------------------
SPECIAL THANKS:

1. Thanks Umio-Yasuno in github issue #281 for actually being proactive and
finding some Intel/AMD gpu device id lists. I wish more issues would be like
that.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. DEBUG: --debug-arg and --debug-arg-use must use the full format:
--debug-arg="-GS", or else the command line eats the args, even if in quotes.
The error handlers will then complain about no data supplied, and it will exit.

--------------------------------------------------------------------------------
BUGS:

1. GRAPHICS: An accidental 'and' instead of 'or' test (see Code 1) led to
systems without gpu or dri graphics drivers not showing their xorg driver even
when present. This was due to a mistake, and also due to how Perl handles || and
&& in sequence, which made this bug not show up until I tested on a system with
xorg graphics driver, but without dri or gpu drivers. Virtually no modern
hardware or operating systems would trip this condition, but older hardware and
operating systems, which may not have gpu or dri drivers, might. And did, in my
case. This is by the way why I try to test on old hardware at least now and
then.

--------------------------------------------------------------------------------
FIXES:

1. CODE: A poorly done attempt at optimization would have broken case
insensitive pre-compiled regex with $pattern = qr/../ because you can't add
/$pattern/i to precompiled pattern, but qr/.../i support only added perl 5.014.
This should impact almost nobody, but it is/was a glitch. Basically qr/../ can
only be used when no /i type modifier is required if supporting Perl less than
5.014.

See inxi-perl/docs/optimization.txt section REGEX for more on this.

Note that Perl already compares the values in the variable each iteration via a
simple equality test, so the only real gain from using qr// is not having to do
that equality test each iteration of a loop.

2. OUTPUT: Fixed a few small inner key name failures to use '-' instead of ' '
to separate key terms:

3. REPOS: Called urpm urpmq, which is the query tool, not the actual type.

4. GRAPHICS: Fixed some gpu_id.pl matching rules. Thanks Umio-Yasuno in github
issue #281 for noticing that some of the matching rules were either wrong or not
loose enough.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1a. OPTIONS: Long time oversight, no option to test or do one time change of key:
value separator string ':'. This goes along with existing config option
SEP2_CONSOLE. Added --separator/--sep {character}.

1b. OPTIONS: Added synonym for --output: --export, and for --output-file:
--export-file.

2a. GRAPHICS: New Intel gpu data source, from intel, finally. This let us add a
lot more gpu ids. Thanks Umio-Yasuno in github issue #281 for finding these.

2b. GRAPHICS: New AMD data source, from github. This let me fill in some more,
albeit not as accurately as previous sources, but added more so fine. Thanks
Umio-Yasuno in github issue #281 for finding these.

3. CONFIG: In a first, took a feature from acxi, --config, and imported it into
inxi! This shows active current configuration, by file.

4. CPU: updated, fine tuned amd cpu microarch ids.

5. DISKS: More disk vendors added. Not as many as usual, I think the high tech
sanctions against China may be slowing the rate of new Chinese SSD/USB vendors.
But still some new ones, as always. Not many new IDs for existing ones though,
that is noteworthy. A few new data sources to help pinpoint vendor names found
too, though those won't in general impact users, but can be used to determine if
a string is in fact a company name.

--------------------------------------------------------------------------------
CHANGES:

1. OUTPUT: Fix 2, -t 'started by:' key name changed to: started-by:
-G 'direct render:' changed to 'direct-render:'.

--------------------------------------------------------------------------------
DOCUMENTATION:

1a. MAN: there were a few <...> instead of [...] for required option arguments.
Fixed those.

1b. MAN: also added --debug-id [string] since that is in general useful info.

1c. MAN: Added qualifiers about when xwayland: and compositor: items appear for
default -Ga output.

1d. MAN: Typo in config path in man page, .conf/ should be .config/.

1e. MAN: for --output json/xml, added pointer to doc page on smxi.org, people
being unable to grasp the output is getting tiresome.

1f. MAN: Added synonym for --output, --export.

2a. SMXI.ORG DOCS: added --output json/xml documentation page:
https://smxi.org/docs/inxi-json-xml-output.htm - this is also linked to from the
github wiki page, though of course nobody is going to read it, as well as from
a few pages in smxi.org.

2b. Updated inxi-man,options,changelog.htm files.

3. CHANGELOG: Changed to use same format as acxi.changelog, leading topic id's
in upper case, makes it easier to scan read and organize.

4a. DOCS: docs/inxi-cpu.txt - cleaned up, re-arranged a bit, added cpuid data
explanation, and updated header on inxi-perl/data/cpu/microarch to better
explain the way amd does ext fam / ext model, which are not the same,
bizarrrely, very confusing.

4b. DOCS: New: docs/inxi-disks.txt. Split out from inxi-resources.txt, part of
the ongoing to documentation modularization, slowly splitting out sub topics
from inxi-data.txt and inxi-resources.txt. Note this is in general only done
when I'm working on that specific feature. But slowly, surely.

--------------------------------------------------------------------------------
CODE:

1. GRAPHICS: Test when no gpu drivers and no dri drivers but x drivers never
showed x driver. Was supposed to be all || for tests:

if (@$gpu_drivers || $graphics{'dri-drivers'} && @$x_drivers){

https://perldoc.perl.org/perlop. I believe this led to test 1 being false, test
2 being false, and since that left tests 2 and 3 needing to be true for the &&
logical and to be true. Since only one of the two was true, the last bit was
seen as false.

2. GRAPHICS: Connected with 1, noticed that for some weird reason, I'd decided
to assign the array ref for drivers like this:

@$x_drivers = (a, b, c);
when it was supposed to be:
$x_drivers = [a,b,c];

This did not cause any issues, since they mean the same thing, but it was silly
to write it that way.

3a. DEBUG: Added --debug-arg-use which allows testers to run a specific argument
combination that may be causing issues.

3b. DEBUG: Also added more validation, to make sure arg for --debug-arg /
--debug-arg-use start with - or -- followed by a letter.

4. START: Removed this code block from set_konvi_data. I had left this in place
for a release or two to make sure no need for it was found, but it will never be
used since it never worked in the first place.
	# my $config_cmd = '';
	# there's no current kde 5 konvi config tool that we're aware of. Correct if changes.
	# This part may never have worked, but I don't have legacy data to determine.
	# The idea was to get inxi.conf files from konvi data stores, but that was never right.
	# if (main::check_program('kde4-config')){
	#	$config_cmd = 'kde4-config --path data';
	# }
	# kde5-coinfig never existed, was replaced by $XDG_DATA_HOME in KDE
	# elsif (main::check_program('kde-config')){
	# 	$config_cmd = 'kde-config --path data';
	# }
	# elsif (main::check_program('qtpaths')){
	# 	$config_cmd = 'qtpaths --paths GenericDataLocation';
	# }
	# The section below is on request of Argonel from the Konversation developer team:
	# it sources config files like $HOME/.kde/share/apps/konversation/scripts/inxi.conf
	#  if ($config_cmd){
	#	  my @data = main::grabber("$config_cmd 2>/dev/null",':');
	# 	Configs::set(\@data) if @data;
	#	 main::log_data('dump',"kde config \@data",\@data) if $b_log;
	# }

5. OPTIONS: in OptionsHandler::post_process(), reorganized the various run and
exit triggers, help, configs, recommends, version, etc. All on top now.
2023-02-07 17:59:56 -08:00
Harald Hope eacf7f4819 readme update, link to wiki page etc. 2023-01-23 12:12:20 -08:00
Harald Hope d1fddeb9ac tiny corner case fix to master, corrected bad dri/gpu/x driver test.
Should impact almost nobody, very hard to trigger, but fixing in master
so inxi -U will correct it.
2022-12-27 16:04:25 -08:00
Harald Hope 85f1720a93 A small point release, mainly to get some bug fixes, and a few minor issues, and
some ongoing updates to various matching rule features like CPU, Disk Vendors,
etc.

--------------------------------------------------------------------------------
SPECIAL THANKS:

1. mrmazda, for continuing to poke around and finding oddities on occasion.

2. The various packagers, for continuing to package inxi.

3. Nothing else really comes to mind, so I'm thankful that no real issues popped
up, and the ongoing attempt to stabilize and clean up the several year
aggressive development cycle of code is proceeding quite well.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. I'm currently getting no data samples from new server type CPU systems,
Nvidia Grace, Ampere, both ARM V2 based. The ARM cpu arch logic hasn't been
updated in many years since I have gotten no meaningful data, currently
Raspberry Pi 4 is the latest ARM generation I've seen data for, and no ARM
server type for many years. So support there is really not happening, and won't
be until I start getting real datasets on those server systems.

Nvidia uses Neoverse V2 ARM core, but I have no information on that yet. Also
nothing from the Amazon CPU, new Marvell datacenter type CPUs. But that's not
surprising.Also, nothing from the N1 (2019) or V1 Neoverse (2021) ARM CPU family
even though those have now been out a while.

A lot of the advanced CPU data should 'just work' because of the huge CPU
refactor done recently, but some of the more advanced data, particularly
cpu_arch type data, isn't going to be available until I get real data sets so I
can see what's going on. No idea how CPUID might work for ARM cpus, for example.

Objectively many of these datacenter/machine learning focused CPUs will never
see a system inxi will run on, though most I suspect will be running GNU/Linux
in some form, so inxi can in theory run on them, but those people all know what
their systems are doing, so the need isn't particularly pressing of course.

With this said, I did used to have more access to cutting edge server stuff, but
that has largely dried up, particularly ARM based chips.

--------------------------------------------------------------------------------
BUGS:

1. Found while resolving Fix 2, it turns out > 1 X Screens would not have shown
correctly due to failing to pass $j row counter by reference. This bug was
introduced when the big Monitor updates were done, since you almost never see
> 1 X Screens now, I never saw it until testing something for another reason.

This led to > 1 Screen showing on the same line as the last monitor of the
previous Screen.

See also Fixes 2, 3, 4, and Code 1, 2, 3.

--------------------------------------------------------------------------------
FIXES:

1. Changed Intel Saphire Rapids release data from 2021+ (what Intel had
initially announced) to 2023+ (the actual release date). Not my fault!! They
were too optimistic, inxi merely repeated their claims.

2. While trying to figure out extra Screen showing up, found a series of subtle
issues with how X Screens are handled. Added in more robust test for if Screen
ID has been added by xdpyinfo_data, and other weird corner cases that might
cause strange results in Display Screen-x.

Created check_screen() to allow for more granular and debugable testing.

This forum post helped focus attention on this issue:

https://forum.endeavouros.com/t/\
my-second-screen-is-not-working-after-installing-nvidia/33388

3. %monitors was not correctly assigned in xrandr screen fallback.

4. Set number of Screens found if no xdpyinfo or if xrandr found > xdpyinfo
number of screens.

5. Added Zhaoxin match to Centaur match, might show up on cpu string.

6. OpenBSD's package manager was listed as pkg_info, but it's slightly more
accurate to call it pkg_add. As far as I understand it, OpenBSD doesn't really
have a 'package manager' per se, it has a suite of tools to manage packages.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Added some Zhaoxin/Centaur IDs, unlikely to show up, but you never know.

2. Added m68k to X display driver list. This was just added to kernel as a full
drm driver! Very legacy, but has users in vm, qemu, etc.

3. More disk vendors! I skipped updating this last time because, well,
collecting the data is really boring, and slightly tedious, and really serves to
simply remind that this is not the way towards a better world. Or are cheap SSDs
the true path after all? I doubt it, but you never know.

4. New AMD, Nvidia gpu ids.

5. New Intel Cpu Microarch IDs.

--------------------------------------------------------------------------------
CHANGES:

1. No changes to speak of, so I won't.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Various ongoing updates to inxi-perl/docs. These are very slowly being pulled
into a more useful form. Emphasis on slowly.

--------------------------------------------------------------------------------
CODE:

1. In Graphics::xdpyinfo_data() and Graphics::xrandr_data() got rid of extra
step, now just assign hash reference directly to push anonymous hash reference
into array. Had used intermidiate variable assignement of hash ref, but that is
pointless.

2. Added $fake{'xdpyinfo'}, hoping to get some debugger data to test weird
extra 'Screen' seen with Endeavor user (see Fix 2, 3, Bug 1).

3. Also, instead of using \%monitors, which creates a reference to the last
value of %monitors, used the correct and safer {%monitors}, which creates an
anonymous reference of the value %monitors had at that moment. This is a subtle
Perl error which is easy to make in cases where the hash or array reference is
almsot never > 1 instance, such as > 1 X Screens.

This should at least help resolve the repeated 'monitors' rows in the output
in Fixes 2, 3, 4.

4. Added 'source' to $graphics{'screens'} to log where each detected screen came
from, xdpyinfo or xrandr.
2022-12-10 16:04:04 -08:00
Harald Hope 029a331a06 This release fixes another very long standing bug, which I was not sure was an
inxi or a Konversation bug, which made tracking it down very difficult. Special
thanks to argonel of Konversation for helping solve this problem, or at least,
for directing my attention towards the likely cause area, and away from wrong
ideas. The bug was that inxi simply did not run in Konversation, it would exit
with error when run with /cmd or /inxi via symbolic links.

This may not seem like a huge deal to many of you, but the actual history of
inxi was directly linked to user support in mainly Konversation, so this feature
not working I have alwyas found extremely annoying, but I could never figure out
why it wasn't workiing, and didn't really know where to start until Argonel
helped narrow it down to a specific Konversation function in inxi. At which
point tracking down the real bug was fairly easy. Since testing in IRC is always
a key test point for inxi features and releases, not working in my main GUI IRC
client forced me to use CLI clients like irssi, via /exec -o inxi.

There was a secondary cause of failure, which was missing a key qdbus package,
which made figuring this one out a two step process.

So inxi is once again working in all areas, with no known significant failure
areas beyond known issues that have no current solution, or which I don't feel
like doing.

But possibly more important, a goal I have had for a while now of doing long
needed code refactors, bug fixes, without huge new code blocks or features
adding new future fixes and bugs, has been slowly happening.

This was quite important, because inxi's codebase and logic is so complex and
large now that at some point, it required rest and cleanup and corrections,
without continuously adding new code and logic, which would then trigger new
fixes and bugs. In other words, the code is taking a long needed, and well
deserved, breather, to recover after huge increases in the overall LOC and
feature sets.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. No known way to detect that the system might be Wayland for the Graphics:..
API: fixes, unless Xwayland is installed if the wayland protocol detections
failed, which they often do in console. Not practical to look for all compositor
variants on system to determine if it could be Wayland if not X or Xvesa, so
that one will just be what it is, which is fine, definitely better than it was
before. Note this is only an issue if in Console, no Display. Note that if inxi
is run as root, Wayland data also usually fails, even in Display.

--------------------------------------------------------------------------------
BUGS:

1. Another corner case monitor position issue, applied fallback primary monitor
rule when a primary monitor had already been located. This is corrected via a
graphics global $b_primary which once set will disable this fallback feature.
Objectively, the fallback feature should just be removed. The test is if that
monitor is not primary, and if position is 0x0, then assume primary, without
verifying no primary had been located yet.

2. A super old bug, in current konversation, was failing to trip the konvi
detections, which then resulted in not stripping off the first two args in
@ARGV, which then resulted in bad args being passed to inxi on konvi start,
which then resulted in silent failing. Many thanks to argonel of #konversation
for the patience to help me figure out what was going on with this bug. He's
been a Konversation developer probably longer than I've been doing inxi.

Cause was very tricky and subtle, the ps aux path for konvi had changed
slightly, not the path, but the pattern, it used to be:

konversation -session [sessin id]
but it's changed to:
konversation -qwindowtitle Konversation
or just plain:
konversation as line ending.

This led to failure to find konvi running, which then made the konvi ids fail.

Also, this would not work if the qdbus-qt5 package was not installed, or other
distros might have that packaged differently. Because of these dual causes, I
was simply unable to figure out what was going on for many years. I suspect this
stopped working with KDE 5/QT 5, but I'm not sure.

3. Used wrong key names for some ZFS tests and fallbacks, those could have led
to failures though very difficult to test and verify this. Also see fix 5, which
of course also looks like a bug, acts like one, but was actually due to a new
use of /dev/disk/by-partuuid for ZFS components in Ubuntu which inxi had not
seen before.

--------------------------------------------------------------------------------
FIXES:

1. Alternate ps IDs for appimage detection (try appimagelauncher), alternate
paths for possible appimage storage locations (also try ~/.appimage/*). File
names might be *.appimage or *.AppImage, probably other variants too.

2. Going along with Change 1, made tests more granular for missing graphics API
type data. Also updated messages to be more correct and clear, in and out of
display. This corrects an issue I'd seen but never resolved, which was on
headless systems showing this message:

Message: GL data unavailable in console. Try -G --display

Now the tests are far more granular, and only show that if glxinfo is installed,
and also shows specific messages if glxinfo not installed, but X/Xorg present,
or, for Wayland, if Xwayland present. These all get their own specific messages
now, and generally will also show which API is being used, or API: N/A if
nothing is detected, as in the case of a headless system with no X, Wayland,
etc.

3. Github issue #275 on of all things Microsoft WSL environment, has a small
glitch with undefined display hz, but otherwise inxi seems to work in that
environment, albeit missing many data types!

4. Made tests for konversation more robust, including test for
$ENV{'PYTHONPATH'} containing konversation in path, which I believe will work
for all new Konversations (KDE 5 and newer), and be much faster. The previous
tests are now more robust and less prone to failure, and only activate when
PYTHONPATH is not present with konversation string present as well.

5. Fix for ZFS using /dev/disk/by-partuuid for partition id in zfs,
which can lead to wrong usable disk total size report, along with failure
to show components. Thanks delanym, issue #276 for reporting this problem, which
also exposed some harder to trigger bugs in ZFS (Bug 3).

6. Exposed by issue #276, case where line was wrapping value when value was too
short visually to value: used: 34.4 GiB (4.5%) due to the 3 or more words
trigger to enable wrapping of value, but noticed that if length of line was
exactly max-width, not > or <, it might vanish.

7. Case where no X or GPU drivers found, but dri driver detected, was not
showing, now does.

8. OpenRC is the init system in some cases, that is: readlink /sbin/init >
/sbin/openrc-init, where /proc/1/comm == init. Was showing only as OpenRC rc
type, which wasn't actually correct.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. New nvidia gpu product ids for Turing, Ampere, Lovelace, Hopper. New Intel
GPU ids.

2. Added Zinc to systembase/distro, needs slightly special handling to get both
names right. Also added Tuxedo, which could use existing methods.

3. Added dpkg tool nala, which is sort of a CLI front end for apt, zinc uses it,
but it's also in Debian main package pool. Also deb-get, which is another zinc
thing for package management.

4. Full support for dinit: version, dinitctl w/status in ServiceData

4. Added initial support for init systems: 31init (31 line C program, no
--version), Hummingbird (unknown if -v/--version).

5. A few new CPU arch ids (new Intels).

--------------------------------------------------------------------------------
CHANGES:

1. Going somewhat along with the change in Audio to call ALSA a Sound API
instead of a sound server, changed key name OpenGL: to API: OpenGL in Graphics.
Also for EGL wayland, calling that the api too.

https://en.wikipedia.org/wiki/OpenGL

This conforms more closely to how these things are defined. Note that once
again, a value had been used as a key name, which almost always indicates a
failure to understand something about the core tech.

2. Changed wrapping of values from 3 words or more to 3 or more words AND length
> 24 characters. Saw example of:
 .... used: 28.45 GiB
  (4.5%)

which isn't desirable.

3. Changed minimum wrap to 60 columns, the new wrapper features are working so
well that if users want output that short, it will usually work fine, except of
course for very long word strings like a kernel name or parameter.

Note that this does not truncate long 'words' that might be wrapped, or going
along with Change 2, long 'sentences' of 2 words, those will always appear on
the same line regardless. For 'sentences' of 3 or more words, however, it goes
word by word, so it could well wrap after the first word, and so on. Obviously,
a 24 or fewer character value will never be wrapped, which was the intended
correction of change 2.

4. Going with Fix 8, OpenRc is an init system when it owns /proc/1/comm, had not
realized that /proc/1/comm == init can map to dinit, openrc as init. Now will
only show OpenRc as rc: type if not init as well.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Updates in man for Change 1.

2. Added to docs/inxi-graphics.txt good quote re EGL/GBM, as well as VBE/GOP for
vesa. Trying to find docs where they actually say clearly it's an API is
remarkably difficult.

3. Man page, added note about Konversation requiring qdbus-qt5 (Debian+),
qt5-qttool (RHEL+/SUSE+), qt-tools (Arch+) for inxi to work inside it. Also
updated smxi.org/docs/inxi-usage.txt to note requirements for Konversation use
and setup.

4. Man, help, changed min width for -y/--width from 80 to 60.

5. docs/inxi-values.txt updated for --cygwin, --wsl fake OS type switches. Not
technically the OS, more the environment, but close enough.

6. docs/inxi-init.txt updated for new init types.

--------------------------------------------------------------------------------
CODE:

1. Refactored tools/gpu_ids.pl to correct and enhance some features.

2. Renamed functions and sections to better reflect that the display interface
is an API, this makes stuff less odd internally, and makes the function/variable
names correspond better to what the stuff really is.

3. Commented out kde konversation data source config collector, that logic looks
like it never worked, and couldn't work, since it never actually located
inxi.conf files, just paths to the data directories.

4. Expanded release.pl to handle acxi docs as well, makes it all consistent and
a lot easier to do long term.

5. Fake --wsl WSL switch, not really used, but in case.

6. Changed $b_cygwin to $windows{'cygwin'} and added $windows{'wsl'}.

7. Added -WSL to debugger string generator once WSL type is detected.

8. Refactored init, runlevel functions get_init_data() (now InitData::get()),
get_runlevel_data() (now InitData::get_runlevel()), get_runlevel_default() (now
InitData::get_runlevel_default()) into one package/class: InitData. This should
have been done a long time ago, to follow the general rule "if > 1 functions for
a tool refactor it into a class/package" for when to create a package/class
internally.

9. Completed gpu_ids.pl, now outputs the full hash set per item, so entire
blocks can be copied/pasted over. Something of a pain to get comments included,
which aren't strictly necessary in pinxi itself, but they do help read the
hashes for gpu data.
2022-10-31 15:47:31 -07:00
Harald Hope b6ac6026f2 Another big one, with a long time to-do item done! /sys based sensors data is
now used as a fallback, with fully revised error messages to handle this new
sensor data variant. Due to potential bugs this might create, this was left off
of the 3.3.21 release, which needed to go out on a schedule, but there is plenty
of time for 3.3.22 to be debugged.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. inxi can't currently handle raw in[0-9] voltage sensor data from
/sys/class/hwmon, that may get corrected, but I've honestly never seen a system
that shows raw in[0-9] values as field names, so it's probably not very
pressing, but it can happen. Similar that is to how default fanx and tempx field
names are processed.

2. Currently only checking -Gx, -Nx device temp for bus IDs ending in .0, which
is the primary PCI device. I think that's the only one that will have a temp,
.1, which is a second device on the same hardware, doesn't have that data in
tests. Saves some requests since it's a big glob of /sys.

3. Spiral Linux has no obvious way to determine that it is Spiral and not Debian
11 as base distro. No /etc/ files for distro ID contain anything for spiral, so
leaving that one alone.

4. Can't get 100% reliable cpu level > v2 due to it not being a pure cpu flag
based test, which is kind of sadly typical for the originators of this idea, but
since the choice was dump the feature, or just use the note: check for > v2,
opted for note: check. One wants to ask questions here, but honestly I already
know the answer so why bother asking the question... The docs for this are
awful, inadequate, incomplete.

My strong suspicion is that this is NOT intended to be a distro-wide feature
beyond v2 support minimum, but rather is for specific compile options for a
package or daemon or server or whatever that can benefit from this type of
fine-tuning. One thinks of Gentoo for example back when such fine-tunings could
actually deliver noticeable differences in performance. A per system type
feature that is, not a distro-wide feature. At least that's my initial feeling,
but this is probably about all the  time I will spend on it since inxi can't get
it more accurate anyway.

--------------------------------------------------------------------------------
BUGS:

1. Bug in monitor position logic, the horizontal/vertical sorts were being done
alphanumerically, leading to absurd results where 800 > 2560 or whatever.
Basically all x / y positions less than 1000 would have forced the smaller
number to be considered as the greatest value. Another corner case find by
mrmazda. Thanks mrmazda!

--------------------------------------------------------------------------------
FIXES:

1. Added i350bb sensor to network sensor type.

2. Small glitch with some scenarios with missing fan1 in sensors, showed fan1 0
rpm, but then showed fan 3: empty. That was a slight error in how undefined vs
'' empty was treated.

3. Added fix for defective fan speeds, skip fan item if > 15000, which is a bug
in the fan speed report, making it useless. Seen 65535 reported RPM. Could
probably make it 10000 upper limit but suspect that is a simple bug that creates
an absurd value, 2^16 so won't be anything high unless bug active. This fix runs
for ipmi, linux, and sysctl fan data.

4. Trying for fix for dynamic gpu voltage, assumed always mV, but might be V.

5. Inadequate or obscure or non-existent redhat/suse documentation led to some
fixes for cpu v levels. Note that level v3/v4 can't be fully determined by cpu
flag tests, but who cares? Certainly not me. Added 'note: check' for v3/v4.

6. Nvidia device arch id was too loose, false id for non existing lovelace arch.
Note that due to array reverse, the newest ids will always run first, which
leads to possible false positives with first string match tests when no product
IDs are available yet.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Elbrus CPU arch, process, year, arch data made more complete using new data
resource. Thanks Elbrus guys!

2. Finally, raw, basic /sys/class/hwmon temp data. Linux kernel docs note
supports temp, fan, volts, amps, energy. But have only seen temps so far. Can
force /sys use with --force sensors-sys / --sensors-sys, though there's no point
to doing that except to test.

Also changed --recommends to note lm-sensors not required for sensor data now.

3. Adding device temp for -Gx, -Nx. Will only work for Linux and when found, and
only for free drivers (I think).

4. Added xdriinfo based dri drivers (with fallback to Xorg.0.log as data source,
not as accurate), that will show if and only if that driver is not the same name
as a detected X or gpu driver.

5. Another big upgrade to cp_cpu_arch, added and corrected many AMD/Intel
matches.

6. A few more gpu product ids, Intel, added.

7. More disk vendors, ids, the list, as we are now well aware, is endless,
reflecting perhaps the futility of pursuing the infinite using finite means.

--------------------------------------------------------------------------------
CHANGES:

1. Slight changes in how inxi supplies no sensor data messages, and in the
fallback cases and handling. More accurate and precise, and more robust overall.

2. Due to complexity of understanding level: and the fact not all cpu flags are
exposed that are required, moved -Cxx level: to -Ca.

3. Changing slightly inaccurate Sound Server for ALSA/OSS to Sound API, which is
the closest I can come to explaining clearly what it is. Note that you can only
load one API type audio subsystem/driver, so you will be running one or the
other, never both, from what I understand.

Since OpenBSD sndio includes sndiod, calling that a sound server is basically
fine, since it's both the server and the interface, if I understand it right,
and there won't be a second sound server listed, actually won't be for any BSD
that I know of, it's going to be sndio or OSS or nothing, unless something has
changed.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Man page, updates for /sys/class/hwmon based sensor data.

2. Small update for cpu level v3/v4, added note: check explanation, though it's
too hard to really explain this stuff since the docs are... not wonderful, when
they even exist and don't contradict each other.

--------------------------------------------------------------------------------
CODE:

1. Refined significantly sensors missing data and error messages to be much more
accurate and granular. Also enables more sensors tools, though hopefully they
won't appear since those are a real pain to implement, but it's more open to
being sensor tool agnostic now due to these refinements than before.

2. Added xdpiinfo to debugger.

3. Switched x_drivers to return ref of array of refs, use join for output only,
that lets us use the drivers to test dri stuff also (if we want or need to), and
keeps it consistent with how most of inxi does that type of data
handling/testing. If undef, it means no array ref exists, which makes testing
easy.

Not truly understanding hash/array refs when inxi rewrite to Perl started is
probably one of the bigger causes of glitches and ongoing optimizations.
Basically, in all but very small array cases, it's almost always better to start
with a ref from the start as soon as the hash/array moves between functions,
with one exception, when it's a globally stored data item. Then it depends. But
this requires a consistent testing for null data as well, which is harder if you
did it in different ways from the start. But slowly and surely chipping away at
these.
2022-10-07 19:43:17 -07:00
Harald Hope a87da04d67 edit 2022-08-22 19:33:40 -07:00
Harald Hope 8b334cf56b changelog edit 2022-08-22 19:29:45 -07:00
Harald Hope 4fc568822c comments 2022-08-22 18:57:11 -07:00
Harald Hope 10f88b360e bug fix for ipmitool located, typo, sensors instead of sensor 2022-08-22 18:53:52 -07:00
Harald Hope 915c7efa34 A small point release, some nice enhancements, a few bug fixes, and some fixes
to correct or update some issues. Main new features:
* -rx,-rxx,-ra/-Ix,-Ixx,-Ia: enhanced Packages: report
* -Cxx: microarchitecture level. This is a relatively new convention, used to
set various compile flags.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Can't safely look for pm tool KDE Discover because apt calls it
plasma-discover, but other packaging systems call it discover, which is already
a non-related program (hardware data). Since it's not really core to any package
manager, it's not really a necessary thing to report anyway, though
gnome-software is added because that appears to be more like syntaptic than
anything else.

There's also a qt variant of the rpm packagekit, packagekit-qt, which is
available in for example Arch, but again, it's too granular, and not really
core.

2. At some point, sensors should add /sys hwmon sensor data, then switch to
using lm-sensors as a fallback, and remove one recommended tool from newer linux
systems. I don't think that's too hard, just a bunch of little steps to
integrate that into the main logic.

--------------------------------------------------------------------------------
BUGS:

1. For Slackware slackpkg/pkgtool:
a: Failed to show package counts at all because of bad globbing path, forgot /*.
b. Failed to show lib counts for packages due to having wrong counter for path.

2. If no ipmi sensor data was found but the tools are present, could result in
an undefined hash reference error for sensors. The most likely cause for this is
that one of the ipmi commands:
"ipmi-tool sensors" or "ipmi-sensors"
had an error, and since errors are sent to /dev/null, inxi saw null data, then
returned an undefined value instead of the hash reference it was supposed to.
This is the first time I've seen this happen with ipmi, but there have not been
a lot of ipmi samples.

Thanks issue poster #274 for having systems that triggered this scenario.

3. $source for ipmi was set to lm-sensors by accident.

4. For sensors, with > 1 sensor type, like lm-sensors + ipmi, sensor data from
second sensor type was getting written to first sensor type row. See Fixes 9 for
more sensors fixes.

--------------------------------------------------------------------------------
FIXES:

1. Force CPU bits to 64 if LM flag is present, if it reports as i686. This fix
only runs for non RISC CPUs that show as 32 bit, so it won't run very often. If
no LM found, remains 32 bit.

This fix goes along with enhancement 1, which only applies to 64 bit CPUs.

2. In --recommends, JSON::PP module package names were wrong, they were copied
from JSON::Cpanel::XS and hadn't been changed to the right package names. Note
that for most distros, this is in Perl Core Modules, but not all.

3. Samsung ram vendor id was too tight, loosened it up a bit. Missed this one:
K3LK7K70BM

4. With Bug 1, extended possible package manager tool detection for slackware
type systems. Slackware is kind of unique in that it is not actually made out of
a core package manager as a collection of packages, but uses package managers as
a kind of layer on top of that, but none of those tools is required to run the
system.

5. Found another corner case indentation glitch, was adding in level 2 on -I
which is has no second level indentation.

6. Forgot to add $force{'pkg'} to -v8.

7. Small fix, if -Z is used, forgot to force --zl, --zu, --zv to false as well
as -z.

8. Small fix, for saphire rapids, alder lake, added + to year built, since those
are ongoing.

9. Sensors:
a. in one case, with an array of fan speeds, set to '' instead of undef, which
made test fail, and showed empty fan item.
b. added wildcards for possible voltage/power matches, was too restrictive for
ipmi sensors values.
c. added better space regex for ipmi temps [\s_-]?
d. DIMM voltage/temp excluded > 9 numbering, like DIMM 19

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. New feature: -Cxx shows for AMD / Intel 64 bit CPUs the microarchitecture
level (v1,v2,v3,v4). v1 is baseline. GCC supports this I believe in latest
versions, and some distros use it to determine CPU support levels for compile
time optimizations. This was introduced in 2020 via a collaboration between AMD,
Intel, SUSE, and Redhat. Now you know. This is a simple test based on which CPU
flags/features are present.

These levels can be used for Go language optimization (GOAMD64), GCC
optimization switches (GCC -O2 for example), and probably more.

2. Expanded YMTC (Yangtze Memory) RAM vendor ids and detections.

3. Added [unverified] window managers CDE and NsCDE. No data, only using ps aux
method.

4a. Added slax ID to distro id, added slax to system base support. Currently
only work on slackware based 15.0, not debian based 11.4.

4b. Added SteamOS debian/arch for system  base.

4c. Added os-release VERSION_CODENAME to enhance distro ID data (eg steamos)

5. Added to -ra/-Ia package tools installed report, this goes along with change
2, which changes apt to dpkg, the low level tool. Now with -a, shows the package
manager tools installed, like slackpkg, apt, apt-get, dnf, yum, zypper, etc.

rpm installed as secondary pm requires some further tests. Currently known pm
that have tools (and rpm tests if detected):
All these are known to support rpm secondary pm:
* dpkg - Debian, Ubuntu, and apt-rpm based distros like PCLinuxOS, Alt Linux
* pacman - Arch based distros
* pkgtool - Slackware based distros
* tce - TinyCore Linux

6. A few more pci product IDs for GPU matches. Slow going.

--------------------------------------------------------------------------------
CHANGES:

1. Changed --pkg to --rpm, the original intention was that this could apply to
more than RPM package manager, but that's the only one that it's used for. This
leads to unclear output for other distributions where the user might have rpm
installed alongside their standard package manager.

2. Changed package pm: 'apt' to 'dpkg', to go along with type rpm (suse,redhat)
and pkgtool (slackware). Note that dpkg is the actual package manager of Debian,
inxi had this wrong, apt interacts with dpkg.

3. Changed -h -a section, to follow after -x, -xx, -xxx, like on man page.

4. For rpm notes, after running some tests to determine whether to use rpm or
not, will show the rpm note: see --rpm in pm: rpm note:... This allows for
more granular errors which will be more useful to users.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Docs were wrong for -ra/-Ia packages, from original when it package report
was only an -a option, but it got moved to -rx, -rxx for basic features, and -a
for advanced features.

2. Updated for --pkg/--rpm and --force rpm/pkg

3. See change 3, I think people tend to miss the sequence of -x, -xx, -xxx, -a
because -a came before -x, -xx, -xxx in -h menu, but on man page, -a correctly
comes after the -xxx options. Better to be consistent.

--------------------------------------------------------------------------------
CODE:

1. Switched force{pkg} to force{package} internally, and added converts to
change --force pkg/rpm to switch on $force{package}.

2. Refactored package PackageData to be more granular.
2022-08-22 17:55:45 -07:00
Harald Hope a17d1b958a man fix 2022-07-27 14:10:52 -07:00
Harald Hope a980e17a18 man page fix 2022-07-27 14:03:40 -07:00
Harald Hope 6d71f06c3e corrected amd tctl/tdie sensor failure 2022-07-27 13:26:45 -07:00
Harald Hope ff81310652 A good bug fix, and several very good indentation fixes that had always been
around, and some of them known. More fine tuning of CPU process/built data. Bit
by bit it's getting filled out.

Thanks again mrmazda for all the suggestions and watchful eyes.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. CPU built, process are not perfect and complete and always right. Like life,
it's not perfect, but it is ok. Help complete the feature if it bothers you.

2. Intel Raptor Lake and related APUs are trickling out, but I have not found
cpuid data for the cpu, or generation data for the apu. Was hoping to squeeze
that into 3.3.20, but looks like it will have to go into 3.3.21 or later.

--------------------------------------------------------------------------------
BUGS:

1. MrMazda pointed this out, the printer was not correctly indenting long values
in specific cases, not adding indentation level 1 when the key: value pair was
not the last item on the logical line. Subtle, but could hit Device, OpenGL, and
a few other cases.

2. When SMT is disabled, cpu speed from /sys can return <unknown>, which is a
string, not the numeric value inxi expected. This trips multipe errors when
speed cleaner is used. Thanks issue #273 reporter iamc for this one. My guess is
all during all cpu testing, none of us thought to disable smt to see what would
happen.

--------------------------------------------------------------------------------
FIXES:

1. On disk vendors, Initio isn't a vendor, it's either a misconfigured ide hdd,
slave/master wrong, or bad usb controller. Initio is a default controller, not a
vendor. Added pre-filter in disk_vendor() to remove that string if it appears.

2. Going along with bug 1, finally fixed long standing weakness with long value
wrapping, now continues to build line until it's done, and does not force a new
line after the last long value item.

3. Another glitch where last key: value pair was less than working width, but
total width was greater, was not wrapping correctly.

4. Saw a corner case Intel Core name: Core i7-1165G7 which did not use the
expected intel (core number)(3 digits), modified to look for 3 digits after core
numer OR 2 digits + letter + digit.

5. Added 'tar' installed test for debugger, found cases in actual distros that
shipped without it in their minimal installs. Times sure have changed!

6. Another Centos type change, amazingly, this was shipped without lspci as
well! No idea what went into the install ISO if this stuff didn't include the
most elementary Linux tools. Added lspci missing error if linux and not risc and
no pci_tool detected. I have to admit this is really surprising to me, I mean, I
thought the entire purpose of the rhel family was to provide enterprise
solutions, but to leave out such elementary tools required by every sys admin is
very difficult to understand. This was centos 7.5. I believe Alma and Rocky 9
minimal have those basic tools, so that's an improvement, though they didn't
have tar.

7. Added a '-' between gen and gen number for Intel GPU generation output. Even
though it's documented as for example gen9.5, it looks odd to see it that way,
it's easier to read it as gen-9.5 I think.

8. Did same for AMD arch/codes, for numbered arch/codes like Rage 9, easier to
read as Rage-9.

9. Extreme corner case spotted by mrmazda, if KDE is started by TDE, inxi showed
Trinity, not KDE-Plasma as the desktop. Further, it failed to show Trinity
version, maybe because Trinity was not installed?

--------------------------------------------------------------------------------
ENHANCEMENTS:

1a. More or less completed verification of AMD cpu microarch/built/process, and
added more accurate fallback cases for stray model IDs.
* family 5h: K5, K6
* family 6h: K7
* family 7h: K8 - mostly done, needs some checks.
* family 10h: K10
* family 11h: K11 Turion X2. Note there is some uncertainy about this family
name. Built years n/a yet. Mix of K8/K10
* family 12h: K12 Fusion, K10 based, first APU type?

1b. Extended Intel cpu data a bit more as well. Thanks linuxdaddy from slackware
for the research help there.
* family 4: mostly new, fine tuned, granular
* family 5: more granular, better date/process info.
* family 6: built dates added
* family F: corrected some overly specific stuff

2. Tentative support for finit init system (fast init). Runs in /proc/1/comm,
uses initctl, which may have been revived from its upstart days, not sure. Added
potential support for nosh, linux only, don't know how to detect other bsd init
system.

3. Added amd/intel gpu product IDs.

4. Added shortcut --filter-all/--za, activates all filters: -z, --zl, --zu,
--zv. Why not?

5. Added support for dm types kdmctl and xdmctl, opensuse and maybe redhat use
the latter to start the actual dm running the desktop/wm. You want to see that
because you need to do systemctl restart xdm to restart the actual dm. Thanks
mrmazda for pointing out this one.

6. Added AlmaLinux, RockyLinux, CentosStream to system base (RHEL derived).

7. Basic Raptor Lake gpu/apu support added, with patterns to detect since few
product ids yet. Same applies to Arctic and Alchemist, which still have no
product IDs.

8. More disk vendors and disk vendor ids, never stops - the waters flow on, the
rain falls, then the sun comes out. Until one day it doesn't.

--------------------------------------------------------------------------------
CHANGES:

1. Deprecated --gpu, now it works the same as -Ga, that was too granular and
nobody would use it I think. Now that the new gpu features are solid, no need
for this special feature.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Updated docs/inxi-values.txt, it didn't have all the --debug-xxx options
listed.

2. Split out some BSD data into docs/inxi-bsd.txt.

3. Big update on docs/inxi-init.txt, moved data to it from other files, updated
the init/service tool data.

4. Renamed init-data.txt to inxi-init.txt, renamed cpu-flags to
inxi-cpu-flags.txt to be more consistent.

5. Updated help, man for new --filter-all option.

6. Updated help and man for --gpu deprecation.

--------------------------------------------------------------------------------
CODE:

1. Moved required perl modules and system programs checks to
check_required_items() in debugger, why not? Also added an error handler for
missing required programs, this is really the only one, and only for
--debug >= 20
This is the only required program test inxi has in it I believe, really amazing
that such a core tool would be left out of an OS today.

2. Removed this redundant block of code from Network device_output() end
section, that repeated in the main get() so didn't seem to serve any purpose.
The test in get() is if n!@rows and if !%risc, same as here, so can't see any
use for it. I'm leaving this here in case that did have some use, but I don't
see it.

if (!@$rows && !%risc){
	my $key = 'Message';
	my $type = 'pci-card-data';
	if ($pci_tool && $alerts{$pci_tool}->{'action'} eq 'permissions'){
		$type = 'pci-card-data-root';
	}
	@$rows = ({
	main::key($num++,0,1,$key) => main::message($type,'')
	});
}
2022-07-27 12:02:36 -07:00
Harald Hope a5e8e3eec7 Added cpu arch ids for k6, k7 2022-06-16 20:42:54 -07:00
Harald Hope 320011471d added amd family 10 model detect 2022-06-16 16:42:39 -07:00
Harald Hope 25b2d2edb9 This is a quick bug fix release, and one other fix, the bug only impact Debian/
Ubuntu distros.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Nothing new.

--------------------------------------------------------------------------------
BUGS:

1. Two repo_builders could create an undefined array ref situation, one in Antix
I have no idea was triggered since it requires an apt file be not readable but
existing, which just isn't a normal debian/ubuntu situation. Void linux was the
other. Since those were the only two with a -r file test, there must be some
case where the file was not readable, though I have no idea what that case might
be.

Further examination showed this can hit all apt based systems, the cause is no
/etc/apt/sources.list file, which is a possible scenario across all apt systems.

--------------------------------------------------------------------------------
FIXES:

1. Blacklisted all apcitz sensors that are not acpitz-virtual, which is the cpu
temp. This may help resolve issues for some users where for example using
acpitz-acpi, which is not the cpu sensor.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. A few more AMD family F empirical IDs made.

--------------------------------------------------------------------------------
CHANGES:

1. None.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Started to split/merge inxi-data.txt and inxi-resources.txt into topic
specific files, like inxi-sensors.txt, inxi-graphics.txt, etc. inxi-values and
inxi-resources have just gotten too big over the years.

--------------------------------------------------------------------------------
CODE:

1. Corrected in RepoItem possible use of undefined array references.

2. Finally, a full releawse tool!! inxi-perl/tools/release.pl. Validates man,
verifies pinxi commands to avoid errors, then updates man/options/changelog
html pages for smxi.org/docs, and then syncs pinxi* files to inxi*.
2022-06-16 16:04:35 -07:00
Harald Hope 96be073515 typo 2022-06-13 17:30:11 -07:00
Harald Hope 80522b55b1 Bug release, replace 3.3.17 asap, most users will not experience the bug, but if
they do, inxi stops right before the -D line. Failed to do an if defined test on
an array ref that could be undefined or an array ref. That makes Perl very
unhappy!

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. AMD family F, K8 series, will need more granular treatments to get the data
to be more accurate and less generic. We got 2 IDs nailed from raw visual data
confirmations and cpuid values, which leaves many, but good start. We will chip
away (pardon the pun) at these more ambiguous IDs over time, but don't need to
get them all done instantly, just eventually. Thanks slackware person linuxdaddy
for doing really good research and actually looking at the cpu to find dates
etc.

--------------------------------------------------------------------------------
BUGS:

1. Bug, fatal, caused by internal hash/array ref refactor of 3.3.17. Thanks
alaymari github issue #271 for reporting this one.

--------------------------------------------------------------------------------
FIXES:

1. None except for code fixes to try to avoid the cause of the bug in Bugs 1.

2. Fixed nvidia eol try --gpu, it was showing backwards, with --gpu, not
without, sigh.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Added slimski dm data. That's a new fork of SLiM. Also guessing that brzdm
has same version -v output: brzdm version x.xx

--------------------------------------------------------------------------------
CHANGES:

1. None

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Refactors of core docs, ongoing, but will list those next release.

--------------------------------------------------------------------------------
CODE:

1. Cleaned up some array ref handling in subs, returned as: ($var1,$var2) =
@{block_data(...)}, skipped initializing and creating scalar to hold the ref,
just use it directly for DiskItem::block_data().

2. Also switched to local ref scalar array in DiskItem::scsi_data(),
DiskItem::block_data(). Not set local array, set local array ref, to keep it
clear. Also made DriveItem::drive_speed() return straight ref, not array then
ref. Same for many other subs, switched to ref assignment so it's the same ref
all through all the sub and return.

3. Fixed a redundant return \@$data to simply assinging to @$data ref, no return
needed, in DiskItem::smartctl_data().

4. Tightened some returns of ref so that tests if good test @$ref, not $ref.
Trying to avoid more cases like issue #271.

5. Going along with array ref local/return, switched all hash refs to local hash
ref returning ref, and working local with ref. More efficient, avoids creating
new refs over and over, dugh. This made a particularly large difference in CPU
because in certain parts, new references were being created over and over, and
subs were returning like \@arr or \%hash instead of declaring to start:
my $arr = []; my $hash = {};

Then working with the data from there on as an array or hash reference, to the
same original reference, rather than creating new ones over and over, which Perl
then has to track til they expire.
2022-06-13 16:32:32 -07:00
Harald Hope 4d7d43580a bug fix, corner case, undefined array ref test in disks. 2022-06-12 15:10:14 -07:00
Harald Hope 354c44eb76 bug fix for openbsd -i 2022-06-10 13:29:28 -07:00
Harald Hope 35e8a95055 Rollout of advanced microarchitecture info continues, added AMD/Intel gfx
devices, CPU built dates, process nodes, generation (in some cases, where it
makes sense), etc.

Please note: the 3.3.16 > 17 releases require manual matching table updates. If
you think disk or ram vendor, CPU or GPU process, release date, generation, etc,
information is not correct:

* FIRST: do the research, confirm it's wrong, using wikichips, techpowerup,
wikipedia links, but also be aware, sometimes these slightly contradict each-
other, so research. Don't make me do all your work for you.

* Show the relelevant data, like cpu model/stepping, to correct the issue, or
model name string.

* There are 4 main manually updated matching tables, which use either raw regex
to generate the match based on the model name (ram, disk vendors), or vendor id
matching (ram vendors), product id matching (gpu data), or cpu family / model /
stepping id matching. Each of these has its own matching tool at:
  inxi-perl/tools/[tool-name].pl
which is used to generate either raw data used by the functions (ids for gpu
data), or which contains the master copy of the function used to generate the
regex matches (cp_cpu_arch/set_ram_vendors/set_disk_vendors).

* Please use pinxi and inxi-perl branch for this data, inxi is only released
when next stable is done, all development is done in inxi-perl branch. All
development for the data or functions these tools are made for occurs in the
tools, not in pinxi, and those results are moved into pinxi from the tools.

* Saying something "doesn't work" is not helpful, provide the required data for
the feature that needs updating, or ideally, find the correct answer yourself
and do the research and then provide the updated data for matching.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. GPU/CPU process node sizes are marketing, not engineering, terms, but
work-around is to list the fab too so you at least know which set of marketing
terms you're dealing with. As of around 7nm, most of the fabs are not using nm
in their names anymore, TSMC is using n7, Intel 7, for example. While these
marketing terms do reflect changes from the previous process node, more
efficient, faster, faster per watt, and so on, and these changes are often quite
significant, 10-30%, or more, they do not reflect the size of the transistor
gate like they used to up until about 350nm. Intel will move to A20 for the node
after 4 or 5, 2nm, meaning 20 angstroms.

Intel suggested million transistors per mm^2 as an objective measure (currently
around 300+ million!! as of ~7nm), but TSMC didn't take them up on it.

GlobalFoundries (GF) stepped away from these ultra small processes at around
14nm, so you won't see GF very often in the data. AMD spun off its chip fabs to
GF aound 2009, so you don't see AMD as foundry after GF was formed. ATI always
used TSMC so GPU data for AMD/ATI is I think all TSMC. Intel has always been its
own foundry.

2. Wayland drops all its data and can't be detected if sudo or su is used to run
inxi. That's unfortunate, but goes along with their dropping support for > 1
user, which was one of the points of wayland, same reason you can do desktop
sharing or ssh desktop forwarding etc. This means inxi doesn't show wayland as
Display protocol, it is just blank, if you use su, or sudo start. This makes
some internal inxi wayland triggers then fail. Still looking to see if there is
a fix or workaround for this.

3. In sensors, a new syntax for k10-pci temp, Tctl, which unfortunately is the
only temp type present for AMD family 17h (zen) and newer cpus, but that is not
an actual cpu temp, it's:
https://www.kernel.org/doc/html/v5.12/hwmon/k10temp.html

"Tctl is the processor temperature control value, used by the platform to
control cooling systems. Tctl is a non-physical temperature on an arbitrary
scale measured in degrees. It does _not_ represent an actual physical
temperature like die or case temperature."

Even worse, it replaced Tdie, which was, correctly, temp1_input, and, somewhat
insanely, the non real cpu temp is now temp1_input, and if present, the real
Tdie cpu temp is temp2_input. I don't know how to work around this problem.

--------------------------------------------------------------------------------
BUGS:

1. Fallback test for Intel cpu arch was not doing anything, used wrong variable
name.

2. A very old bug, thanks mrmazda for spotting this one, runlevel in case of
init 3 > init 5 showed 35, not 5. Doesn't show on systemd stuff often since it
doesn't use runlevels in this way, but this bug has been around a really long
time.

3. SensorItem::gpu_data was always logging its data, missing the if $b_log.

--------------------------------------------------------------------------------
FIXES:

1. Fixed some disk vendor detection rules.

2. Failing to return default target for systemd/systemctl when no:
 /etc/systemd/system/default.target
file exists. Corrected to use systemctl get-default as fallback if file doesn't
exist.

3. Fixed indentation for default: runlevel, should be child of runlevel: /
target:

4. Fixed corner case where systemd has no /proc/1/comm file but is still the
init system. Added fallback check for /run/systemd/units, if that exists, safe
to assume systemd is running init.

5. Fixed subtle case, -h/--recommends/--version/--version-short should not print
to -y1 width, but rather to the original or modified widths >= 80 cols.
Corrected this in print_basic() by using max-cols-basic.

6. Forgot to add --pkg, --edid, and --gpu to debugger run_self() tool.

7. Fixed broken sandisk vendor id.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Added AMD and Intel GPU microarchitecture detections for -Gx. These are not
as easy as Nvidia because there is no one reliable data source for product ids.

2. Going with the -Ga process: .. built: item, -Ca will show process: [node] and
built: years and sometimes gen: if available. Geeky, sure, not always perfect,
or correct, but will generally be close. Due to difficultly in finding reliable
release > build end years for example, not all cpus have all this data.

Using CPU generation,where that data is available and makes sense. Like AMD
Zen+ is zen gen: 2, for example,. Because Intel microarch names are often
marketing driven, not engineering, it's too difficult to assign gen consistently
based only on model names. Shows for Core intels like: gen: core 3

That will cover most consumer Intel CPU users currently.

3. Added initial Zen 3+ and Zen 4 ids for cp_cpu_arch(). There is very little
info on these yet, so I'm going on what may prove to be incomplete or wrong
data.

4. Added GPU process, build years for -Ga.

5. Added fallback test for gpus that we don't have product IDs for yet because
dbs have not been updated. Only used for cases where it's the newest gpu series
and no prodoct IDs have been found.

6. Added AMD am386 support to cp_cpu_arch... ok ok, inxi takes 9 minutes to
execute on that, but there you have it.

7. Added unverified Hyprland wayland compositor detection.

8. By request, added --version-short/--vs, which outputs version info in one
line if used together with other options and if not short form. With any normal
line option, will output version (date) info first line, without any other
option, will output 1 line version info and exit.

9. More disk vendors, ids! Much easier with new tool disk_vendors.pl.

--------------------------------------------------------------------------------
CHANGES:

1. Deprecated --nvidia/--nv in favor of more consistent --gpu, that's easier to
work with multiple vendors for advanced gpu architecture. Note for non nvidia,
--gpu only adds codename, if available and different from arch name. For nvidia,
it adds a lot more data.

2. Changed inxi-perl/tools tool names to more clearly reflect what function they
serve.

3. Going with runlevel fixes, changed 'runlevel:' to be 'target:' if systemd.
Also changed incorrect 'target:' for 'default:'.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Updated man, help, docs/inxi-data.txt for new gpu data and tools, and to
indicate switch to more generic --gpu trigger for advanced gpu data, instead of
the now deprecated --nvidia/--nv, which probably will go down as the shortest
lasting option documented, though of course inxi always keeps legacy syntax
working, behind the scenes, it's just removed from the -h and man page in favor
of --gpu. Also updated to show AMD/Intel/Nvidia now, since the data now roughly
works for all three main gpus.

2. Updated pinxi README.txt to reflect the tools and how to use them and what
they are for.

3. --help, man, updated for target/runlevel, default: changes for init data.

4. Updated configuration html and man for --fake-data-dir.

--------------------------------------------------------------------------------
CODE:

1. Upgraded tools/gpu_ids.pl to handle nvidia, intel, or amd data, added data
files in tools/lists/ for amd. First changed name from ids.pl to gpu_ids.pl

2. New data files added for amd/intel pci ids, and a new tool to merge them and
prep them for gpu_ids.pl -j amd|intel handling. All work. Took a while to get
these things sorted, but don't want to get stuck in future with manual updates,
it needs to be automated as much as possible, same as with disk_vendors.pl etc,
if I'm going to try to maintain this over time.

3. Made all gpu data file names use consistent formats, and made disk data files
also follow this format.

4. Changed raw_ids.pl to gpu_raw.pl, trying to keep things easy to remember and
consistent here.

5. Refactored core gpu data logic, now all types use the same sub, and just
assign various data depending on the type.

6. Changed vendors.pl name to disk_vendors.pl

7. Big redo of array/hash handling in OutputHandler, was partially by reference,
now is completely by reference. All Items now use and return $rows array ref as
well, from start to finish, unlike previously, where @rows was copied
repeatedly.

8. Going along with 7, made most internal passing of hash/arrays use hash/array
references instead, where it makes sense, and doesn't make the code harder to
work with.

9. Refactored WeatherItem, split apart the parts from output to be more like
normal Items in terms of error handling etc.

10. Added 'ref' return option for reader() and grabber(). Only useful for very
large data sets, added also default 'arr' if no value is provided for that
argument.

11. Switched some features to use grabber/reader by ref on the off chance that
will dump some execution time.

12. A few places added qr/.../ precompiled regex, in simple form, for loops,
maybe it helps a little. I don't know.

13. Added global $fake_data_dir, this can be changed via configuration item:
FAKE_DATA_DIR or one time by --fake-data-dir.

14. Created data directory, and initial data items. cpu is the fake data used to
test CPU info. More will be added as data is checked and sanitized.
2022-06-10 12:40:18 -07:00
Harald Hope 7245e42aa2 changelog fix 2022-05-19 16:57:53 -07:00
Harald Hope 1684c6e172 changelog edits 2022-05-19 16:56:28 -07:00
Harald Hope 2934175b34 last vendor bug fixes 2022-05-19 16:25:06 -07:00
Harald Hope 87bc34da8b vendors bug fix 2022-05-19 16:06:34 -07:00
Harald Hope cce18d8564 vendor bug fix 2022-05-19 15:53:48 -07:00
Harald Hope 6023702097 A nice release, some good corner case bug and glitch fixes, along with some much
needed documentation fixes to bring inxi-values.txt up to date for changes that
have been evolving steadily. And a useful option for nvidia legacy card info.

I'm hoping that will help support people and users as nvidia open source driver
gets more usable in the future, since that will never support legacy cards, only
the current series supported by 510/515 drivers.

Also, in inxi-perl/tools, new tools and data so you can reproduce certain arcane
data assembly features like disk vendors and nvidia product ids.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Not known yet if you can get Wayland display drivers along with kernel gpu
drivers. In other words, is a similar use of kernel/display driver as in Xorg
found with Wayland? Hard to dig up actual answers to questions like this.

2. Similarly, unknown if it's possible to get current active xorg display
driver, not just the list from Xorg.0.log file. No idea how to discover that,
there are cases where past use of Xorg leaves log file present, but drivers are
not used with Wayland, leading to confusing driver reports. Issues 1 and 2 are
similar but probably have similar solutions.

--------------------------------------------------------------------------------
BUGS:

1. Very subtle failure caused by odd mount point in partitions: a too loose
regex rule designed to capture spaces in device names was running loose to the
end of the string, where it was triggered by a number in the mount point.

Fix was to make rule much more strict, now needs to match 3 number space in a
row after the initial part, and then a number%

2. Bug in corner case, with Monitors, if > 2 connected monitors, and 1 disabled,
inxi was trying to test numeric position values for the disabled monitor, which
with xrandr, has no position values, thus tripping undefined pos-x and pos-y
errors. Thanks to fourtysixandtwo for spotting this corner case.

3. Bug in wan IP, if dig failed, set_dowloader() is not set unless other
parameters were used, which results in failing to set parameters for downloader,
which leads to screen errors spraying out. Thanks to Manjaro user exaveal for
posting this issue, with error outputs, which helped pinpoint the cause.

--------------------------------------------------------------------------------
FIXES:

1. More absurd xorg port ID variations: DP-1 kernel, DP1-1 X driver. Wny?
Trying to add in XX-?\d+-\d+ variation, which I think will be safe, made the
first - optional, though it's just idiotic for this amount of randomness to be
allowed to exist in the 21st century. If this reflects other discipline failures
in Xorg, it starts to get somewhat more obvious why Wayland was considered as
the only forward path, though that's just as chaotic and disorganized... but in
different ways.

2. Removed darwin distro version detection, which of course broke, and using
standard fallback for BSD made out of uname array bits. If it works, it works,
if not, who cares. This should handle issue #267 hopefully.

3. Trying for more monitor matches, now in cases where 1 monitor display ID
remained unmatched, and 1 sys kms id remains unused, assume the remaining
nonitor ID is a match and overwrite the unmatched message for that ID. This
will cover basically all single monitor match failure cases, and many multi
monitor failures with only 1 out of x monitor ids unmatched. While guessing a
bit, it's not a bad guess, and will slightly expand the number of matched
monitor ids. This extends the previous guess where if single monitor and
unmatched, use it to cover > 1 monitors, with 1 unmatched.

4. LINES_MAX configuration item did not assign to right variable when -1 value.
Used non-existing $size{'output-block'} instead of correct $use{'output-block'}

5. Forgot to add pkg to --force, goes with --pkg.

6. Finally! Added in busybox shell detection, it's not of course reliable if
they change internal light shells, but all the docs say they use ash, so now
it will show shell: ash (busybox) to make it clear. Hurray!! This means that
tinycore users will get this long awaited feature! Ok, ok, long awaited by
probably only me, but since I package inxi for busybox, it was on my todo list.

7. Cleaned up and re-organized many disk vendor matching rules, made them easier
to read and debug, going along with Code 3, vendors.pl development and release.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. New feature: in -Ga, if Nvidia card, shows last supported nvidia legacy
series driver (like 304.xx), status, microarch. If --nvidia and EOL, shows
last-supported: kernel: xorg: info. This should be useful for support people,
we'll see.

-Gx shows nvidia microarchitecture, if it was found. This is based on matching
tables so will go out of date if you have non current inxi's, but that's life.

If --nvidia or --nv shortcut is used instead, triggers -Ga and shows much more
nvidia driver data for legacy, and for EOL drivers, last supported kernel, xorg,
and last release version. --nvidia also adds process node if available.

More important perhaps is the fact that as of May 2022, nvidia is starting the
process of open sourcing its current latest driver (515, but Turning, Ampere
architectures only so far), which will only support non legacy nvidia cards,
making detection of legacy cards even more important to support people and end
users, since that will be a common question support people will have: does my
card support the open source driver?"

Read about the new open sourcing of the 515 nvidia module:
https://developer.nvidia.com/blog/nvidia-releases-open-source-gpu-kernel-modules/
https://github.com/NVIDIA/open-gpu-kernel-modules
https://www.phoronix.com/scan.php?page=article&item=nvidia-open-kernel&num=1

2. Going along with new and upgraded tools in Code 3, massive, huge, upgrade to
disk vendors, 100s of new matches, biggest upgrade ever for disk vendors. This
feature should work much better now with the new backend tools.

3. Added shortcuts: --mm for --memory-modules, --ms for --memory-short.

--------------------------------------------------------------------------------
CHANGES:

1. None.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Big update to docs/inxi-values.txt. This had gotten really out of date, with
incorrect hash and other internal data assignments, all updated to be current,
along with sample greps to make it easier to locate changes in the future as
well. This makes this document fairly up to date and useful again for dev
reference purposes, should such a dev ever appear, lol. Many values had not
been updated after global refactors, like switching to the %risk data for all
arm/mips/ppc platform types, and making %load, %use, %force, %fake uses more
consistent. Doing this helped expose some subtle bugs and failure cases in
inxi as well.

2. Added to -h and man -Ga Nvidia option info. Fixed some typos and glitches.
Includes new --nvidia / --nv options for full data.

--------------------------------------------------------------------------------
CODE:

1. Changed $dl{'no-ssl-opt'} to $use{'no-ssl'} and $dl{'no-ssl'}, that was a
confusing inconsistency.

2. Added comma separated list of --dbg numbers, since often > 1 is used. Saves
some debugging time, otherwise nothing changes.

3. Huge new public release of some back end tools in new section:
inxi-perl/tools
* vendors.pl - disk vendors tool, with data in lists/disks*.txt
* ids.pl - nvidia product id generator tool, with data in lists/nv_*

4. While doing vendors.pl, I noticed that the use of array ref for $vendors was
not done correctly, that's fixed now, simplifies it slightly.
2022-05-19 14:17:33 -07:00
Harald Hope f3f7dec169 bug fix, strange mount point name tripped output errors for partitions,
that name exposed some weak/greedy regex that didn't do what it was intended
to do in such cases. Solution was to tighten the regex and make it much
more explicit.
2022-04-25 22:32:57 -07:00
Harald Hope 2801b1d1e2 edit 2022-04-07 22:52:24 -07:00
Harald Hope 8e0b7b5ccf Bug fix, it's a bad edid data bug, rare, but when it trips, kills inxi execution
dead right before -G/Graphics shows. Also some nice fixes and enhancements.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Possible case of Gnome Wayland failing to set any gnome environmental
variables, making wayland detection not possible. This was in anonymous dataset
inxi-proBook4540s dataset. Person never appeared in real life so can't follow up
on it. This cascaded down to other failures in display detection, and desktop
detection, though in theory much of the data needed was present. I expect
similar issues may appear with kde wayland. This is/was probably a configuration
or build error I believe, though not enough data yet.

It appears that sudo start disabled the display environmental variable
detections, which is unfortunate, and the fallback loginctl tests do not appear
to work for unknown reasons. I've confirmed this on Fedora stock Gnome as well.

--------------------------------------------------------------------------------
BUGS:

1. Forgot to test that return from get_display_manager is array ref, this
impacts only a tiny handful of distros probably, TinyCore was one, but it is
a fatal failure, so fixed it. Also fixed in 3.3.14 inxi branch. Never trips in
console, only on tiny linux where no dm is used at all, I think Xvesa might be
the only case this would have tripped.

2. EDID errors and warnings had several bugs, errors a fatal critical bug which
made execution stop. Had forgotten to pass the $edid hash reference to the error
constructor. Also had used wrong hash key in output so would never have shown.

--------------------------------------------------------------------------------
FIXES:

1. Corrected ram device indentation levels.

2. Made memory width more clear with: width: data: total: which more
accurately reflects the source data. Also in cases where no data or total
values, only show width: N/A, not the data: total: sub items.

3. Made edid errors/warnings output to numbered list of warnings/errors instead
of using join() to made one long list. Much more consistent that way. This fixes
issue #266 - thanks SheridanOAI for finding this bug.

4. In --slots, -x wasn't loading the bus ID so it showed N/A, unnecessary data
collection granularity, removed.

5. For Display, if no X or gpu driver, show: driver: N/A. Showed driver: gpu:
N/A before.

6. For Display, remove filters for Xwayland tests, we always want to see
xwayland data if it's installed. This was actually an error to not show it since
display_server_data already had the correct tests to not redo Xorg data if found
previously, which would be glxinfo based data. This is a partial fix also for
Known Issue 1, at least we'll see Xwayland is present even if Wayland detections
failed for unkonwn reasons.

7. Added some ram value dmi filters, found some that had 'none' or 'unknown'.

8. Show display protocol out of display!! Also handles most common root use
cases as well, so in most cases, if the initial protocol detections failed, this
will result in a decent attempt, though if root it is less reliable. sudo or
regular user will be fine since looks for not tty/pts TTY type and username.

This should also help narrow down Known Issue 1 failures, though there are more
cases to be dealt with, but can only chip away since not enough data.

9. Made info: item in slots more robust, and able to handle more diverse
scenarios.

10. Added alternate syntaxes for dmidecode permissions errors.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Added brzdm clogin mlogind xlogin display managers. Not verified. Version for
brzdm is probably like slim since brzdm is a fork of slim.

2. Added voltages to ram module report, that had been left out. Note that it's
common for voltages to be either 'unknown' or not present at all. This is as
close as inxi can get to handling issue #265 since there is no other source for
the requested data type (show DDR3L, low voltage DDR3, which doesn't exist as a
type in dmidecode).

3. Added voltages to --slots report, --slots -xx. Only shows if present.

4. Added for --slots -a for Linux, if detected, the PCI children of the bus ID
of the slot. This is recursive, so supports as many levels as are present,
though it would be rare for there to be more than one level of children.

--------------------------------------------------------------------------------
CHANGES:

1. In -m ram report, moved ram type before size/speed/voltage, that makes more
sense.

2. Also in -m ram report, make type: the default value (was an -x options
before), which contains the no module found messages etc, making the order:
  Device-1: DIMM 0 type: no module installed
  Device-2: DIMM 1 type: DDR4 size: 16 GiB speed: 2400 MT/s

This puts all the speed/size/voltage data together, and stops putting the no
module found message in speed, which never made any sense.

2. In -m, changed width data to more clearly reflect the data source:
      width (bits):
        data: 64
        total: 72

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Man page, added a TABLE OF CONTENTS section which lists all the primary
sections. Can help since the man page has gotten so darned long and man doesn't
as far as I know support clickable internal links, sadly.

2. For -m, updated for revised output syntax and -x levels. Note that the help
and man actually had the type: as default for -m, not -mx, but for some reason,
the code had it wrong. Oops.

3. For -m, fixed some legacy output syntax in the examples.

--------------------------------------------------------------------------------
CODE:

1. Some refactors of slots, ram, as well as a bit more refactoring of edid stuff
for graphics.

2. Added $ENV{'DISPLAY'} to debugger data collector, no idea why that was left
out.
2022-04-07 22:49:36 -07:00
Harald Hope 29e241dc0f tiny bug fix for tinycore/xvesa, other distros can ignore this. 2022-03-25 14:16:15 -07:00
Harald Hope b3cdcd979a New version, man. Continuing development of EDID and monitor features, bug
fixes, normal fixes.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Failed to handle case for monitor positions of array type: 2-2, 3-1, 1-3,
4-4. I'm not sure what structure those are really arranged in, but might be
worth adding in the x+y pos values along with the row-col values.

2. For Monitors and graphics Device ports, if using non free nvidia driver and:
nvidia-drm.modeset=1 not set in grub kernel boot parameters, there will be no
/sys/class/drm data for the nvidia device, and thus no ports data, and no
monitor data.

3. A class of high count DP or DVI port IDs are changed by Xorg drivers to for
example: DP-6 > DP-2-3. This is very difficult to handle and will in general
probably fail unfortunately because that level of port ID abstraction is just
reazlly hard to deal with dynamically.

4. A to-do item: add bus ID children on --slots. This will probablby be in next
inxi.

--------------------------------------------------------------------------------
BUGS:

1. None outside of the various fixes.

--------------------------------------------------------------------------------
FIXES:

1. In sensors, failed to pull out BAT sensor data. In most cases, this would not
lead to any issues, but it could have.

2. This one just slipped my mind, I'd meant to do it, but in Montitor-x:, the
primary ID should have been the 'real' kernel ID, not the mapped: ID, which is
the X.org ID when different from the kernel ID. So mapped should be the Xorg
version when they are different from the kernel version.

3. In Graphics, monitors can show > 1 ratio, failed to set all to :, resulting
in: ratio: 3:2 or 16/10 modes:. Also fixed ParseEDID to output an array of
ratios, which can then be processed as wanted.

4. Monitor map fixes:
* Handle case in monitors where display ID: eDP and sys ID: eDP-1, this only
works if 1 monitor in array. There's a variety of this type of failure, when
X.org or its drivers decide to call the port ID XYZ with no number at all. All
those possible cases are now handled, like eDP > eDP-1, VGA > VGA-1, and so on.

* Added fallback, if no match, and if only 1 monitor, just map them to eachother
if other mappings failed. Prompted by things like: s: DP-6 > d: DP-2-3;
s: eDP-1 > d: DP-4, which are just impossible to create logic to map.

5. Removed 'ati' driver from xorg drivers list, it's simply a wrapper for r128,
mach64, or radeon (and maybe amdgpu), and shows as failed, unloaded, or loaded,
because of this. ati basically assigns the correct driver, that is, but is not
itself a driver. Thanks mrmazda for spotting this issue.

6. Typo on QDI => Quantum Data.

7. Added fallback for monitor model, now using vendor code plus product code
if nothing found for vendor nice name or model. This will show as 'model-id:'
instead of model: to help differentiate the two.

8. Added Monitor product_code to manufacturer if no model name is found.

9. get_pci_vendor was trimming at ' / ' if the product string also contained
' / '. Fix is to ignore 1 character 'words' in the logic.

10. In Slots, failed to remove_duplicates in the slot info field, leading to
redundant output strings. See Enhancement 3 and Code 4.

11. See Change 3, finally made -S section use full key: value pair, which makes
stuff more explicit, like:

System:
  Host: yawn
  Kernel: 5.16.0-11.1-liquorix-amd64
    arch: x86_64
    bits: 64
    compiler: gcc
      v: 11.2.0
  Desktop: Xfce
    v: 4.16.0
    tk: Gtk
      v: 3.24.24
    info: xfce4-panel
    wm: xfwm
      v: 4.16.1
    vt: 7
    dm:
      1: LightDM
        v: 1.26.0
      2: SDDM
        note: stopped
  Distro: Debian GNU/Linux bookworm/sid

12. Fix for mageia and lsb distro data, force use of os-release for mageia if
detected. That overrides the forced use of lsb release for mandrake/mandriva,
because for some reason mageia has decided to carry ALL the legacy distro files:
'/etc/lsb-release',
'/etc/lsb-release.d',
'/etc/mageia-release',
'/etc/mandrake-release',
'/etc/mandrakelinux-release',
'/etc/mandriva-release',
'/etc/os-release',
'/etc/redhat-release',
'/etc/system-release'
which is really not what this stuff is intended for, if it's an actual derived
distro from a living base, then yes, include the base file, but all these have
the same distro id data for mageia, none for the derived distros.

Also, fixed an lsb release thing to avoid using codename if codename contains
release number as well. Since lsb_release is totally legacy at this point, who
cares if we might miss a specific codename here and there on legacy system.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Added Color Characteristics to EDID parser, for some reason that had been
left out.

2. Added advanced EDID output option --edid, that allows for showing more
advanced EDID data than is appropriate for most users cases. Ihcludes errors,
color characteristics chroma: (chromacity), full modes, not just min/max.

3. In --slots, added bus-ID.

Also extended report quality, made more granular, got rid of single blob from
Type and Designation and now get more accurate and useful data.

4. In cases with > 1 DM, check to see if one or more are stopped or disabled, =
and add (stopped) if it was detected in running service as stopped.

--------------------------------------------------------------------------------
CHANGES:

1. Reversed monitor ID and mapped: ID values, that was a mistake, the mapped:
item was supposed to contain the X.org mapped name, and the primary ID was
supposed to be the actual real ID the kernel uses. Not a huge deal either way,
but there it is.

2. Include disabled but connected Monitors. This works around nvidia bug showing
monitors disabled when they are enabled, but also allows for showing connected
monitors, though without as much data.

3. Made the last holdout -S > -Sa use strict full key: value pair output, like
Desktop: XFCE v: 4.14.12 and so on.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Added help/man for --edid info.

--------------------------------------------------------------------------------
CODE:

1. In ParseEDID: made new key: edid_error, which contains an array ref of 1 or
more edid errors. The previous version did a poor job and returned only the
first error found, so there could have been > 1 error, and you'd never know it.

This changes check_parsed_edid to _check_parsed_edid(). and adds a utility tool
_edid_error, which grabs the message from main::message, giving better output
integration.

This also allows for future error handling expansion quite easily.

2. In map_monitor_ids() fixed matching pattern, made more robust and explicit,
to catch things like s: eDP-1 d: eDP or eDP-1-1, both have been seen. Also added
fallback for single monitor, just map them to eachother if mapping failed.

3. get_pci_vendor() added test for using anything that is 1 character length,
to not break on 1 character length string matches.

4. Fully refactored --slots, that was originally written purely as a proof of
concept in terms of adding a new feature during the original inxi 2.9 rewrite,
and was never actually touched after that.
2022-03-24 11:45:05 -07:00
Harald Hope 7ba2e0220f readme update 2022-02-23 15:19:37 -08:00
Harald Hope 8b5fefed22 version fix 2022-02-22 17:35:09 -08:00
Harald Hope cd1e29b0af Just as 3.3.10 > 3.3.11 were a huge set of CPU upgrades, including significant
internal refactors, so too is 3.3.13 a significant Graphics upgrade, featuring
significant upgrades to Wayland (and Xvesa/TinyX!) support, and allowing for
much more granular output controls. The legacy -Ga showing
Display/Screen/Monitors is now split apart, and can now work for some features
in and out of display.

This upgrade should be of significant interest to any Wayland using distro, as
well as the tiny Xvesa based distros like TinyCore, Slitaz, and Puppy.

--------------------------------------------------------------------------------
NOTE TO MAINTAINERS AND PACKAGERS:

If you had Cpanel::JSON::XS or JSON::XS Perl modules as dependencies, you can
remove those, inxi now can use JSON::PP, which is in Core Modules since Perl
5.14 (unless for some reason your distro removed that module from Core Modules).

Basically inxi will simply look for whichever of the 3 is installed, and use
that one.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. The free drivers for xorg like amdgpu, modesetting, alter the the internal
kernel IDs for monitors/gfx device ports, which is somewhat bizarre since the
ideal role of any ID is to be an identifier that always works. Due to this
situation, inxi has to map the kernel ids to the x driver monitor IDs in order
to show the advanced monitor data, like model: mapped: and modes:. This may not
always work as expected since if the mapping fails, the data will fail to match
to the monitors. While not enough data is in to make any conclusions, hoping
that this issue does not exist on Wayland compositors.

--------------------------------------------------------------------------------
BUGS:

1. Not sure if this was a bug, but I believe RAM vendor ID matches would never
have generated results, and might have generated errors. That's corrected as
part of Code fix 1.

--------------------------------------------------------------------------------
FIXES:

1. Tiny indentation level issue, for -Ga, Monitor was not set to be a container
for its data. This would only impact -y 1 or json and xml output cases, and would
be subtle, but it was an oversight.

2. Small fix for monitor dimensions, failed to switch the mm dimensions for
monitors placed in a vertical, portait mode, instead of standard landscape mode.
Now switches mm x and y if that is detected, which corrects dpi as well.

3. For Xvesa:

* Show vesa as display driver, Xvesa == vesa, dugh,lol.

* Show better Interface and Screen resolution data missing messages.

* See FIX 5 for adding in display-ID:.

* Show TinX Xvesa string for server data, not just Xvesa.

4. For Wayland, which currently has no EGL support in inxi, if no glxinfo
present, show EGL Wayland specific Messsage: for advanced EGL data, not the
generic glxinfo that were shown previously.

5. Display was relying on xdpyinfo or a Wayland environmental variable to set
display-ID:, now falls back always to $ENV{DISPLAY} if nothing else was found
and that exists. I hadn't realized how much was depending on those x tools,
which many people never had installed in the first place. This also supplies
that for Xvesa as well, which has features that need the Display-ID to use.

6. Intel family 6, model 17h, supposed to be yorkfield, was penryn, fixed.

7. Small fix for remove_duplicates, it was not case insensitive so missed things
like DELL Dell in strings.

8. Failed to detect or get Xfree86 X server version number.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Extensive Graphics Upgrades:

* -Gxx Devices: For some gpus / drivers, show vram total and used for -Gxx.
amdgpu supports this, I believe it's the only one, but don't know for sure.

* -Gxx Devices: (Linux only): Show active, off (connected but disabled, like a
closed laptop screen with attached moniitor), and empty ports on devices. Not
tested for USB yet.

* -Gxx Devices: Show device ports (like VGA-1, DVI-I-1, HDMI-A-1), active, off
(off is connected but disabled) and empty (linux only).

* -G Display/Screen: Removed strict dependency on xdpyinfo to show advanced xorg
screen and display data. Now it will show most of the data if xrandr is
available, and all if xrandr and xdpyinfo are installed. More granular error
messages as well.

* -G Wayland Display: new type, d-rect: for > 1 monitor Wayland display layouts.
Works roughly the same as Screen: s-res: does, except since Wayland has no
'Screen' concept, that goes into Display. This is sort of a rough algo,
basically it takes either the dimensions of the total of x and y resolutions, or
the greatest x or y resolution found for any monitor, whichever is greater, and
uses that to create the display rectangle resolution composite value.

* -G Display, Monitors: Extended display tool options from just xrandr to
swaymsg, wlr-xrandr, weston-info, wayland-info. Still nothing on kwin_wayland or
gnome-shell and mutter data.

*. -S, -G: compositors, full redo of list, now supported:

asc awc cage cagebreak cardboard chameleonwm clayland comfc dwc dwl epd-wm
fireplace feathers fenestra glass gamescope greenfield grefson hikari hopalong
inaban japokwm kiwmi kwinft  labwc laikawm lipstick liri mahogany marina maze
motorcar newm nucleus orbital perceptia phoc pywm qtile river rustland simulavr
skylight sommelier sway swc swvkc tabby taiwins tinybox tinywl trinkster velox
vimway vivarium wavy waybox way-cooler wayfire wayhouse waymonad westeros
westford weston wio+ wio wxrc wxrd xuake

* -G Enhanced Interfaces/GL item, previously only type OpenGL forX, now has:

  * X - OpenGL, requires glxinfo , same as before.

  * Wayland - EGL, currently no tool available, stub in place. Allegedly this
  data can be found but have no idea how or if a tool does that yet

  * Xvesa - Interface: interface type (VBE/GOP). GOP not confirmed, no data
  samples; v:, source:, dac: (no idea what it is, show it though), controller:,
  and ram: items.

  This is based on TinyX/Xvesa as found in TinyCore, but should work in Slitaz
  and Puppy TinyX as well if those projects are still around.

* -G Display/Screen/Monitor data: Created structures and abstractions that allow
for Wayland/Xorg/Xvesa data, most new features will work with any of these. Or
Arcan, if that actually makes it, and we get data for it. We'll wait on Arcan,
heh.

* -G Display server: For Xvesa, added type TinyX to server if detected. Added
Xwayland, which was not handled previously. For Xwayland, if wayland running,
and if Xorg also installed, shows:

  server: X.org
    v: 1.20.14
    with: Xwayland
      v: 21.01

Otherwise shows:

  server: Xwayland
    v: 21.01

* -G Compositors: fixed a long standing weak spot, if > 1 compositor detected
running, not common, but could happen, shows all detected compositors.

  Display: x11
    server: X.Org
      v: 1.20.13
    compositors:
      1: Mutter
        v: 41.1
      2: xfwm
        v: 4.16.1
    driver:
      X:
        loaded: modesetting
      gpu: radeon

* -G drivers: now shows if X or gpu driver, in each its own section. This makes
it more obvious what is going on:

  Display: x11
    server: X.Org
      v: 1.20.13
    driver:
      X:
        loaded: modesetting
      gpu: radeon
    resolution:

* -Gxx Monitors: Show primary monitor with pos: primary,right. Uses either
xrandr 'primary' value, or if no 'primary' found in an Xorg Screen, uses +0+0
positioned monitor. Position is based on the row and column number in the
rectangular grid of monitors when monitors per Xorg Screen are > 1.

For most common multi-monitor layouts, text positions are used, which are in
general more clear and easy to understand than their internal numeric
counterparts, that is, unless the layout is too complicated, it will show left,
or top-left, instead of 1-1, and so on.

Text mode positions are available for the following grid styles currently: 1x2,
1x3, 1x4, 2x1, 2x2, 2x3, 3x1, 3x2, 3x3. 'top' means the top row if > 1 row,
'bottom' means the bottom row, 'middle' is the middle row if 3 rows, 'left' is
the first column, 'right' the last, 'center' if 3 columns, and 'center-l' (1-2),
'center-r' (1-3) are the 2 center columns if 4 columns. 'bottom-l', 'bottom-c',
'bottom-r'; 'middle-l', 'middle-c', 'middle-r'; 'top-left', 'top-center',
'top-right' complete the possible values.

If the grid of monitors is greater than the supported rows or columns, it will
switch to numeric row-column mode, with column-row numbering starting at 1-1,
top left.

* -Gxx Monitors: show (if detected, Linux only) monitor model, and if the
display ID (from Xorg or Wayland) is different from the /sys monitor ID, show
mapped: to show the /sys id.

* -Gxxx Monitors: show modes: max: XxY min: XxY, or mode: XxY (if only 1 mode
found). Shows hz:

* -Ga Monitors: shows serial, built year, gamma, ratio, if detected.

2. Added impish 21-10 and jammy 22-04 to ubuntu id. That's for Mint base ID. Not
huge point in updating if Mint doesn't update inxi, but there it is.

3. For -Axx, -Exx, -Gxx, -Nxx, shows PCIe speed and lanes. With -a, shows max
speed / lanes if different than current speeds/lanes. Note that for unknown
reasons not all devices in a PCIe slot show this data.

4. -Ixx: terminals added: foot, ate

5. -Sxx: login/display managers added: emptty, greetd, qingy, tbsm. See CODE 5
for more info on how this change was done.

6. -Sxxx: status/dock/panel bars added: i3-status-rs, luastatus, nwg-bar,
nwg-dock, nwg-panel, rootbar, sfwbar, wapanel, waybar, yambar

7. Added a Tyan board IPMI sensor data set.

8. Added support for fruid_print for Elbrus -M Machine data. Those boards don't
have dmi tables, but do ship with Elbrus OS which has fruid_print.

9. More disk vendors! Yes, you know the drill, the world turns, and with every
turn, a flock of new vendors appears, like baby rabbits emerging from their
warren, endlessly, a stream that is the life essence itself... or something.

--------------------------------------------------------------------------------
CHANGES:

1. When xdpyinfo is not installed, user will still see advanced -Ga Monitor and
Screen data as long as xrandr at least is installed. Better error messages as
well now to explain which tool or tools missing caused the missing data.

2. -Gxx will show basic Screen and Monitors, id, mapped, pos:, model, res, dpi,
diag; -Gxxx adds Monitor modes; --Ga adds screen/monitor size, Screen diag.

3. -ba/-v2 no longer show the full screens/monitor report, now it remains basic
mode output, which it should have always done, unless -G is also explicitly
added.

4. Split apart x-server version to v:, which should always have been the case.

5. Xvesa and Wayland no longer show glxinfo messages for no glxinfo for GL data.
Now they show their own custom messages, appropriate to the case.

6. json features now test for JSON::PP, JSON::XS, or Cpanel::JSON::XS modules,
and use whichever is found. Note I did not realize JSON::PP was in core modules
as of 5.14 so that makes sense to use, and will allow inxi to start using json
data sources, which are a lot easier to parse.

7. Changed -G drivers to show subsections for X and gpu drivers, and updated
missing driver messages to account for this change. X drivers now show the sub
sets of loaded/unloaded/failed/alternate, and gpu shows active gpu drivers,
assuming such are detected.

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Help and man page updates for -G Display/Screen/Monitor changes. Redid -G,
-Gx, -Gxx, -Gxxx, -Ga. Added monitor layout position feature.

2. Updated -Ga for xrandr/xdpyinfo changes.

3. Updated --recommends to more accurately show function of xdpyinfo and xrandr
for -G and -Ga.

4. Reorganized and added complete table of contents to docs/inxi-data.txt

--------------------------------------------------------------------------------
CODE:

1. Slightly optimized use of array loads on disk_vendor() and ram_vendor() based
on how it's now done for monitor layouts, which is more efficient, use a scalar
to hold a reference to the array, that avoids having the array ever exist in
more than 1 place. Part of the ongoing process of avoiding extra hash and array
copies globally.

2. Moved to consistent undef behaviors.
 * For lists of variables use () to undefine, changed all of the the following:
    1. (@a,$b,$c,%d) = (undef,undef,undef,undef);
    2. (@a,$b,$c,%d) = (undef);
    3. (@a,$b,$c,%d) = undef;
   to use: (@a,$b,$c,%d) = (); This undefines all the variables in the list.
   Note that assigning undef to @a in the first example creates an array of 1
   key, with the value undef, and (@a,@b) = (undef,undef) creates arrays of 2
   indexes, or something like that. Not what was wanted.
   Examples 2 and 3 assign undef to @a: an array of 1 index, value undef, and
   undefine the others variables in the list. This was not the desired behavior!
 * For most scalars, arrays, and hashes, use: undef @a; undef $s; undef %h.
 * For some hash and array index values, use $h{a} = undef. These cases may want
   the key itself to exist, with the value of undef, though I believe:
    undef $h{a};
   is synonymous, but still have to verify that.

I did some testing, and realized that some of the undef I had used in the
various previous ways of using undef were not actually resulting in the expected
behaviors.

3. Refactored display_data_x into 3 functions, added display_data_xdpyinfo and
display_data_xrandr, which allows for more granular handling of those
dependencies, now inxi can show most advanced display data with only xrandr
installed.

4. Significantly improved all error handling and missing data for Wayland/Xorg.

5. Refactored get_display_manager() to better handle corner case dm file or
directory names, and to avoid endless loops. Much cleaner now. Required because
greetd had varying file names, greetd.run, or just greet-546.sock. With some
other dm's that use similar, or unreadable directories in /run, now just doing
a glob of /run/ /var/run, /var/run/rc.d as detected and checking for the dms
in the names, then just using the dms that were found. Simpler.

6. Massively simplified and integrated compositor logic in Graphics, now using
program_values() and program_data() as appropriate, and simple matching list
to ps_gui data to get detected compositor[s], much simpler, far more efficient
code, less to maintain. Also fixed long-standing weak spot of exiting on first
detected compositor, now shows all detected, with version etc for each if
available.

7. With 6. also significantly simplified and optimized get_ps_de_data() for
desktop data, that's the ps aux fallback case for wm desktop detections.

8. Made $wl compositors list global to avoid having to update each section,
that's now used in -G compositor, -S desktop/wm, and wm sections. It is set
in ps_gui() on initial load.

7. Settled on one and only way to do multiline conditionals, now use no space,
use same indent level as starting if/elsif etc. I've been debating this one, but
can't find any real way to handle that elegantly so I think best to just not
try, and leave it up the code flow to show when it's wrapped condition tests.

8. Refactored previous gl_output, expanded it to handle all interface types,
OpenGL, EGL (not currently active due to no known tool to get EGL data for
Wayland, and Interface: VBE type data for Xvesa. This roughly completed the
breaking apart of the X.org centric logic for Display, Monitors, and GL data,
and make all sections now fully agnostic to display server or protocol type.

Should new display servers appear, it will now be far more simple to add support
for them, since they would just plug into the existing abstraction layers.

9. Added --debug-arg to allow for passing specific custom args to the debugger.

10. Refactored display_server version, now works much better, creates lists of
server/version, and xwayland as well if found.
2022-02-22 15:58:37 -08:00
Harald Hope 87ebdfff2a readme update 2022-02-13 14:39:32 -08:00
Harald Hope 1da75146cc Small point release with some useful fixes, some bugs corrected, small
enhancement.

--------------------------------------------------------------------------------
KNOWN ISSUES:

1. Note on KNOWN ISSUES 2 from 3.3.10, I realized that the second level
indentation actually takes care of that hanging parent, since now it's quite
clear that its children are indented on the following line. So that issue took
care of itself.

--------------------------------------------------------------------------------
BUGS:

1. In $bsd_type cases, specifically SunOS triggered this, where sysctl was not
present (which it always is in all other BSD types), it tripped an error due to
failure to update to revised $alerts{'sysctl'}->{'message'}, instead was using
the old method. Failed to update that in refactor of CheckTools logic. Would
impact no supported operating systems, but is a bug.

2. Corner case, a combination I never used, inxi -a, triggers error in the RAID
logic because the mdadm test was not run, generating an undefined eq error. Only
happened when mdraid was present and used on system.

3. Tiny bug, for st+mt cpus, like alder lake,  was printing out second tpc by
accident which made it look like it said st: 4 tpc: 2. Just a small output
glitch.

--------------------------------------------------------------------------------
FIXES:

1. Added some fallback 32 bit system tests, [2345]86, like i386, i686.

2. Changed shell: Unknown Shell to shell: N/A, that was a legacy use, and was
obviously redundant. N/A is more consistent with rest of output no value found
handling. Due to requirement of doing empty tests, this is set in the data, not
output, generator component.

3. Refactored partition data logic to get rid of bsd tests for df -kTP, -kT, -k.
Now tests only to see if returns data, cascades down until it gets something.
Now will attempt to reconnect hanging lines when no -P feature available prior
to main partition data processing. This makes it agnostic to os issues, and it
just pays attention to feature support.

Also adds in dynamic column count instead of hard-coded, this avoids oddities
and future proofs to some degree. Now systems will adapt seamlessly if support
for -P appears, or -T, or whatever.

4. Partitions corner case, where has zram, but has no partitions, failed to show
partitions no data found message since @partitions had data in it, but nothing
for partitions output to print. Seen in TinyCore for example, but might happen
in other ram based systems.

--------------------------------------------------------------------------------
ENHANCEMENTS:

1. Added Slint to distro ID, and slint/slackware to system base.

--------------------------------------------------------------------------------
CHANGES:

1. None

--------------------------------------------------------------------------------
DOCUMENTATION:

1. Typo in man page fixed.

2. A few more edits and corrections on 3.3.10 changelong. That thing was written
concurrently with the development, and thus had lingering errors when things
were changed in midstream.

--------------------------------------------------------------------------------
CODE:

1. Added --cygwin and --android fake system type flag. Switches on $b_android/
$b_cygwin flags.
2022-01-18 14:08:04 -08:00