History log of /linux-master/tools/power/acpi/Makefile
Revision Date Author Comments
# 53e85588 21-Dec-2021 Chen Yu <yu.c.chen@intel.com>

ACPI: tools: Introduce utility for firmware updates/telemetry

Introduce a user space tool to make use of the interface exposed by
Platform Firmware Runtime Update and Telemetry drivers.

It can be used for firmware code injection, driver updates and
to retrieve platform firmware telemetry data.

Tested-by: Hongyu Ning <hongyu.ning@intel.com>
Signed-off-by: Chen Yu <yu.c.chen@intel.com>
[ rjw: Subject and changelog edits ]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 05c36e5a 25-Sep-2020 Thomas Renninger <trenn@suse.de>

tools/power/acpi: Serialize Makefile

Before this patch you get tools/power/acpi/Makefile.rules
included in parallel trying to copy KERNEL_INCLUDE multiple
times:

make -j20 acpi
DESCEND power/acpi
DESCEND tools/acpidbg
DESCEND tools/acpidump
DESCEND tools/ec
MKDIR include
MKDIR include
MKDIR include
CP include
CP include
cp: cannot create directory '/home/abuild/rpmbuild/BUILD/linux-5.7.7+git20200917.10b82d517648/tools/power/acpi/include/acpi': File exists
make[2]: *** [../../Makefile.rules:20: /home/abuild/rpmbuild/BUILD/linux-5.7.7+git20200917.10b82d517648/tools/power/acpi/include] Error 1
make[1]: *** [Makefile:16: acpidbg] Error 2
make[1]: *** Waiting for unfinished jobs....

with this patch each subdirectory will be processed serialized:

DESCEND power/acpi
DESCEND tools/acpidbg
MKDIR include
CP include
CC tools/acpidbg/acpidbg.o
LD acpidbg
STRIP acpidbg
DESCEND tools/acpidump
CC tools/acpidump/apdump.o
...
LD acpidump
STRIP acpidump
DESCEND tools/ec
CC tools/ec/ec_access.o
LD ec
STRIP ec

Signed-off-by: Thomas Renninger <trenn@suse.de>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# b886d83c 01-Jun-2019 Thomas Gleixner <tglx@linutronix.de>

treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 441

Based on 1 normalized pattern(s):

this program is free software you can redistribute it and or modify
it under the terms of the gnu general public license as published by
the free software foundation version 2 of the license

extracted by the scancode license scanner the SPDX license identifier

GPL-2.0-only

has been chosen to replace the boilerplate/reference in 315 file(s).

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Allison Randal <allison@lohutok.net>
Reviewed-by: Armijn Hemel <armijn@tjaldur.nl>
Cc: linux-spdx@vger.kernel.org
Link: https://lkml.kernel.org/r/20190531190115.503150771@linutronix.de
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>


# 37645d65 02-Dec-2015 Lv Zheng <lv.zheng@intel.com>

tools/power/acpi: Add userspace AML interface support

This patch adds a userspace tool to access Linux kernel AML debugger
interface.

Tow modes are supported by this tool:
1. Interactive: Users are able to launch a debugging shell to talk with
in-kernel AML debugger.
Note that it's user duty to ensure kernel runtime integrity by using
this debugging tool:
A. Some control methods evaluated by the users may result in kernel
panics if those control methods shouldn't be evaluated by the OSPMs
according to the current BIOS/OS configurations.
B. Currently if a single stepping evaluation couldn't run to an end,
then the synchronization primitives acquired by the evaluation may
block normal OSPM control method evaluations.
2. Batch: Users are able to execute debugger commands in a script.
Note that in addition to the above duties, it's user duty to ensure
script runtime integrity by using this debugging tool in this mode:
C. Currently only those commands that are not used for single stepping
are suitable to be used in this mode.
D. If the execution of the command may cause a failure that could result
in an endless kernel execution, the execution of the script may also
get blocked.
To exit the utility, currently "exit/quit" commands are recommended, but
ctrl-C" can also be used.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 4305cd02 27-Jul-2015 Lv Zheng <lv.zheng@intel.com>

tools/power/acpi: Enable build for EC userspace tool

This patch allows EC userspace tool to be built as an ACPI tool.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 391fc234 27-Jul-2015 Lv Zheng <lv.zheng@intel.com>

tools/power/acpi: Add descend support in ACPI tools Makefile

This patch splits tools/power/acpi/Makefile to support descend compling for
ACPI tools. In this patch tools/ec related stuff is removed as it is
originally not enabled.

Also a missing .o (utnonansi.o) is added to the acpidump/Makefile.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 3c9349c9 07-Jul-2014 Lv Zheng <lv.zheng@intel.com>

ACPICA: Common: Enhance cm_get_file_size() to improve portability

This patch uses abstract file IO and acpi_log_error() APIs to enhance
cm_get_file_size() so that applications that invoke this API could have
portability improved.

With actual references added to abstract file IO and acpi_log_error(), the
applications need to link oslibcfs.o, utdebug.o, utexcep.o, utmath.o,
utprint.o and utxferror.o.

It is also required to add acpi_os_initialize() invocations if an
application starts to use acpi_log_error().

acpidump has already invoked acpi_os_initialize() in this way. Lv Zheng.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 83b80bac 07-Jul-2014 Lv Zheng <lv.zheng@intel.com>

ACPICA: OSL: Clean up acpi_os_printf()/acpi_os_vprintf() stubs

This patch is mainly for acpidump where there are redundant
acpi_os_printf()/acpi_os_vprintf() stubs implemented. This patch cleans up such
specific implementation by linking acpidump to osunixxf.c/oswinxf.c.

To make acpi_os_printf() exported by osunixxf.c/oswinxf.c to behave as the
old acpidump specific ones, applications need to:
1. Initialize acpi_gbl_db_output_flags to ACPI_DB_CONSOLE_OUTPUT.
This is automatically done by ACPI_INIT_GLOBAL(), applications need to
link utglobal.o to utilize this mechanism.
2. Initialize acpi_gbl_output_file to stdout.
For GCC, assigning stdout to acpi_gbl_output_file using ACPI_INIT_GLOBAL()
is not possible as stdout is not a constant in GCC environment. As an
alternative solution, stdout assignment is put into acpi_os_initialize().
Thus acpi_os_initialize() need to be invoked very early by the
applications to initialize the default output of acpi_os_printf().

This patch also releases osunixxf.c to the Linux kernel. Lv Zheng.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# e8c038a3 07-Jul-2014 Lv Zheng <lv.zheng@intel.com>

ACPICA: Utilities: Cleanup DEFINE_ACPI_GLOBALS by moving acpi_ut_init_global() from utglobal.c to utinit.c

The utglobal.c is used to define and initialize global variables. It makes
sense if just adding utglobal.o to applications that are using such
variables. But acpi_ut_init_globals() is preventing us from doing so as
this initialization function references other components' initializations
code, which leads to the requirement that many files should also get linked
if one wants to link utglobal.o.

It is possible to just move acpi_ut_init_global() to utinit.c for
applications that require this function to link.

By linking utglobal.o, we can stop defining DEFINE_ACPI_GLOBALS for
applications (currently only acpidump is affected). Lv Zheng.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Bob Moore <robert.moore@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# d7cddbb0 07-Apr-2014 Thomas Renninger <trenn@suse.de>

ACPI / tools: Introduce ec_access.c - tool to access the EC

This userspace tool accesses the EC through the ec_sys debug driver
(through /sys/kernel/debug/ec/ec0/io).

The EC command/data registers cannot be accessed directly, because they
may be manipulated by the AML interpreter in parallel.

The ec_sys driver synchronizes user space (debug) access with the AML
interpreter.

Signed-off-by: Thomas Renninger <trenn@suse.de>
[rjw: Changelog]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 75e4f206 07-Apr-2014 Thomas Renninger <trenn@suse.de>

tools/power/acpi: Minor bugfixes

- bindir is created, but sbindir is used -> fix that
- the debug parts are there twice (copy paste bug?). Remove one of the
exact same parts

Signed-off-by: Thomas Renninger <trenn@suse.de>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# edbe47c1 03-Apr-2014 Lv Zheng <lv.zheng@intel.com>

ACPICA: acpidump: Update Makefile to build acpidump from ACPICA.

This patch updates tools Makefile to use new acpidump.

ACPICA's acpidump relies on various ACPICA components/common/os_specific
source code. They are located in various kernel folders, being searched
and compiled using vpath technique in Makefile. These files include:
1. drivers/acpi/acpica/acapps.h
2. tools/power/acpi/common/getopt.c
3. tools/power/acpi/common/cmfsize.c
4. tools/power/acpi/os_specific/service_layers/oslinuxtbl.c
5. tools/power/acpi/os_specific/service_layers/osunixdir.c
6. tools/power/acpi/os_specific/service_layers/osunixmap.c

This patch has been tested on DELL Inspiron Mini, acpidump output can be
successfully generated by typing the following commands:
# cd tools/power/acpi
# make DEBUG=false
# sudo make install DESTDIR=/opt
# sudo make uninstall DESTDIR=/opt
# make clean
Or
# cd tools
# make acpi
# sudo make acpi_install
# sudo make acpi_uninstall
# make acpi_clean
A kernel build test is also performed on DELL Inspiron Mini to verify that
the changes done to actypes.h and aclinux.h won't affect the kernel
build process.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
[rjw: Subject]
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# f677b30b 14-Jan-2014 Lv Zheng <lv.zheng@intel.com>

ACPICA: acpidump: Cleanup tools/power/acpi makefiles.

This patch cleans up old tools/power/acpi Makefile for further porting,
make it compiled in a similar way as the other tools. No functional
changes.

The CFLAGS is modified as follows:
1. Previous cc flags:
-Wall -Wstrict-prototypes -Wdeclaration-after-statement -Os -s \
-D_LINUX -DDEFINE_ALTERNATE_TYPES -I../../../include
2. Current cc flags:
DEBUG=false:
-D_LINUX -DDEFINE_ALTERNATE_TYPES -I../../../include -Wall \
-Wstrict-prototypes -Wdeclaration-after-statement -Os \
-fomit-frame-pointer
Normal:
-D_LINUX -DDEFINE_ALTERNATE_TYPES -I../../../include -Wall \
-Wstrict-prototypes -Wdeclaration-after-statement -O1 -g -DDEBUG

There is only one difference: -fomit-frame-pointer.

Signed-off-by: Lv Zheng <lv.zheng@intel.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# e183fcb3 05-Feb-2013 Thomas Renninger <trenn@suse.de>

ACPI tools / acpidump: must be run as root - install it into /usr/sbin

Change the default location to install acpidump into from /usr/bin
to /usr/sbin, as this tool needs to be run as root.

[rjw: Subject and changelog]
Signed-off-by: Thomas Renninger <trenn@suse.de>
Tested-by: Lee, Chun-Yi <jlee@suse.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>


# 45e1424b 22-Sep-2012 Len Brown <len.brown@intel.com>

tools/power/acpi/acpidump: create acpidump(8), local make install targets

Signed-off-by: Len Brown <len.brown@intel.com>


# 0e7cc279 22-Sep-2012 Len Brown <len.brown@intel.com>

tools/power/acpi/acpidump: create acpidump(8), local make install targets

Signed-off-by: Len Brown <len.brown@intel.com>


# 981efe9a 22-Sep-2012 Len Brown <len.brown@intel.com>

tools/power/acpi/acpidump: version 20070714

This is unchanged version 20070714, plus a small bit in
DEFINE_ALTERNATE_TYPES to enable building with latest kernel headers.

Signed-off-by: Len Brown <len.brown@intel.com>


# 0efea7b6 22-Sep-2012 Len Brown <len.brown@intel.com>

tools/power/acpi/acpidump: version 20051111

This is unchanged version 20051111, plus a small bit in
DEFINE_ALTERNATE_TYPES to enable building with latest kernel headers.

Signed-off-by: Len Brown <len.brown@intel.com>