aboutsummaryrefslogtreecommitdiff
path: root/includes
AgeCommit message (Collapse)Author
2017-12-09x86: add summary of caches to package informationBurt P
Show actual physical caches by counting only unique references from each "cpu" (hardware thread). Signed-off-by: Burt P <pburt0@gmail.com>
2017-09-04Add prototype for processor_frequency_desc()Leandro Pereira
2017-08-27dmi: requested changesBurt P
Change requested by lpereira in https://github.com/lpereira/hardinfo/pull/160 Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-27DMI: allow specifying type for dmi_chassis_type_str()Burt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-27Create dmi_util.c and move *_util.c to hardinfo/Burt P
These stand alone interfaces and are used across modules, so just make them available to any module by default. Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-27DMI: dmi_chassis_type_str() maps chassis-type to stringBurt P
dmi_chassis_type_str() is moved from code in computer.c:detect_machine_type(). It makes sense to keep it with dmi, as it maps a dmi-defined value to a string. This way it can be used in both dmi.c and computer.c. Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-27DMI: create single dmi_get_str() that uses sysfs with dmidecode fallbackBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-15Add info_field_printf() to reduce some sturct Info field boilerplateLeandro Pereira
2017-08-14Begin getting rid of callbacks returning stringsLeandro Pereira
Strings were never a good choice to begin with. However, with the efforts to improve translatability, they became even worse. This is an attempt to clean up the current mess and provide a more structured way for modules to commmunicate with the shell. The Computer module has been partially converted and changes will be provided next. It's partially converted since some of its information is still stored as strings. The Shell still only understands strings; that's why the structured data is converted to a string the way it is. Once all modules are converted, the Shell can be modified to handle struct Info directly without having to parse the .ini-like strings.
2017-08-14Move hardinfo_clean_label() and hardinfo_clean_value() to util.cBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-12x86: add microcode version to reported informationBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-11Separate processor name and description + count cores and threadsBurt P
* add cpu_procs_cores_threads() function to get counts from sysfs/topology * each platform must now provide processor_name() and processor_describe() * processor_name_default(): returns a list of unique processor->model_name * processor_describe_default(): returns "N physical; M cores; L threads" * processor_describe_by_counting_names(): returns a list of unique processor->model_name with Nx prefix (ex: "4x ARM Cortex A53 + 4x ARM Cortex A33") * x86: _name and _describe use defaults * arm: _name returns name of SOC, if available, _describe returns processor_describe_by_counting_names() * all other platforms: _name and _describe use defaults * Computer module summary now shows both name and description for CPU Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-09arm: Try to lookup the SOC name from dt/compatibleBurt P
Just ARM for now, but maybe this will become more generic and it will be possible to have the processor package name and description seperate, even for x86 and whatnot. Also perhaps work in Sockets/Threads/Cores information. Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-09arm: use decoded name instead of generic linux name for model_nameBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-09Handle mixed cores in get_processor_name(), ex: big.LITTLE or TegraBurt P
In the future, I think a processor will need a name and a description. Name as the straight name of the processor or SOC, and description as what name is now, with 4x and whatnot. x86 description might be "8 cores, 16 threads" or similar. Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-07Reset some file modes to 0644Burt P
Touched files were changed to 0755 in 6f8cedca0671ab68514352c64579546547804475 Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-04Remove tree_view_save_image()/cb_save_graphic() -related.Burt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-08-04About dialog changesBurt P
* Use a define for copyright latest year, also used by `hardinfo --version` * Don't translate Jakub Szypulka * Add myself to contributors list Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-30gtk3: loadgraph/uber-graph: support multiple lines on the graphBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-30loadgraph: make loadgraph opaque, sample gdoubleBurt P
Old load graph still uses ints internally. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-30GTK3 updatesBurt P
* Use gtk_widget_get_window() instead of ->window cmake: * add option to build against gtk3 `-DHARDINFO_GTK3=1` * combine hardinfo-shell static library and hardinfo * disable guibench for gtk3 hardinfo/util.c: * widget_set_cursor() gtk3 changes * For now, the whole function tree_view_save_image() is disabled for gtk3. shell/shell.c: * add gtk_notebook_set_page() compatibility macro if not defined * shell_summary_add_item() fixes * Disable RANGE_GET_VALUE() RANGE_SET_VALUE() macros for GTK3. This is a nigtmare onion to try and peel. shell/callbacks.c: * gtk_about_dialog_set_name() -> gtk_about_dialog_set_program_name() after GTK+2.12. shell/loadgraph.c: * builds, but not yet functioning under gtk3 Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-30Started GTK3 supportTotalCaesar659
2017-07-29Refactor distribution detection routineLeandro Pereira
2017-07-25device tree: silence some warningsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-25device tree: fix crash when device tree is not foundBurt P
* check if device tree was found before add_keys() * UNKIFNULL(model) before strcmp * make UNKIFNULL() STRIFNULL() EMPIFNULL() macros more generic Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-22device tree: interrupts-extended and dmas supportBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-22device tree: group interrupt specifiers' values using #interrupt-cellsBurt P
Also, add a message log to the dtr object. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-22device tree: fix bug in dtr_get_parent_obj()Burt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-21device tree: reg grouping with #address-cells + #size-cellsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-21device tree: add helper function for appending elementsBurt P
Cleans up code for lists of mixed-type elements. appf() is like h_strdup_cprintf() but with a cute name, logical param order and adds a space when the string is not empty. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-21device tree: try harder to find device-tree rootBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-21device tree: decode /__overrides__ fieldsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-21device tree: special handling gpios and clocksBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19device tree: display phandle, symbol, and alias mappingsBurt P
* Of course, symbols and aliases are are the same as in /__symbols__ and /aliases. It still helps a bit. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19device tree: fixesBurt P
* /aliases/* and /__symbols/* are always strings * phandle ref element bug fix, re-enabled phandle refs * notes on a few more property types Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19device tree: add lookup for /__symbols__ valuesBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19device tree: code comments and tweak dtr_str()Burt P
* dtr_str() requires obj, which knows its dtr. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19device tree: reworked and cleaned upBurt P
* Moved device tree functions to modules/devices/devicetree/dt_util.c * The dtr_* functions usable from outside devicetree.c, for example in get_motherboard(). Must #include "dt_util.h" * Now possible to use an alternate device tree root for testing -DOVRDTRROOT=\"/some/path\" * Alternately, pass dtr_new() an alternate base path. * Abandoned the tuple grouping and inherited properties stuff for now. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19Begin support for device treeBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19x86 flag definition lookup changesBurt P
* Avoid using GHashTable * Use single flag lookup table with bug: and pm: prefixes to avoid flag name collisions Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19Support for pgettext()Burt P
Attempt adding support for pgettext without the bulk of standard gettext.h Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19Make locale dir match install pathBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-19Use const for gettext stringsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12Fixup translation supportBurt P
* Use `bash updatepo.sh` instead of `make pot`. `make pot` will cause absolute paths to appear in hardinfo.pot of whomever last ran it. * C_() and NC_() support added for contexts Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12s390: multiple cpu, topolog, cpufreqBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12cpu topology: add book and drawerBurt P
Apparently used in s390. Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12parisc: multiple procs, topology, cpufreq, more cpuinfo fieldsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12ia64: multiple procs, topology, cpufreq, more cpuinfo fieldsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12riscv: show extension setsBurt P
Signed-off-by: Burt P <pburt0@gmail.com>
2017-07-12riscv: initial supportBurt P
Signed-off-by: Burt P <pburt0@gmail.com>