From: kbuild test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [RFC][PATCH 4/6] ACPI: processor: Export acpi_processor_evaluate_cst()
Date: Sun, 08 Dec 2019 21:55:55 +0800 [thread overview]
Message-ID: <201912082145.jUkUQ8KD%lkp@intel.com> (raw)
In-Reply-To: <1840912.Bc70b32FYA@kreacher>
[-- Attachment #1: Type: text/plain, Size: 5012 bytes --]
Hi "Rafael,
[FYI, it's a private test report for your RFC patch.]
[auto build test ERROR on pm/linux-next]
[also build test ERROR on linus/master v5.4 next-20191208]
[if your patch is applied to the wrong git tree, please drop us a note to help
improve the system. BTW, we also suggest to use '--base' option to specify the
base tree in git format-patch, please see https://stackoverflow.com/a/37406982]
url: https://github.com/0day-ci/linux/commits/Rafael-J-Wysocki/cpuidle-intel_idle-Use-ACPI-_CTS-to-get-idle-states-information/20191208-022703
base: https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git linux-next
config: x86_64-randconfig-c003-20191208 (attached as .config)
compiler: gcc-7 (Debian 7.5.0-1) 7.5.0
reproduce:
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
ld: drivers/acpi/acpi_processor.o: in function `acpi_processor_evaluate_cst':
>> drivers/acpi/acpi_processor.c:831: undefined reference to `acpi_processor_ffh_cstate_probe'
vim +831 drivers/acpi/acpi_processor.c
732
733 /**
734 * acpi_processor_evaluate_cst - Evaluate the processor _CST control method.
735 * @handle: ACPI handle of the processor object containing the _CST.
736 * @cpu: The numeric ID of the target CPU.
737 * @info: Object write the C-states information into.
738 *
739 * Extract the C-state information for the given CPU from the output of the _CST
740 * control method under the corresponding ACPI processor object (or processor
741 * device object) and populate @info with it.
742 *
743 * If any ACPI_ADR_SPACE_FIXED_HARDWARE C-states are found, invoke
744 * acpi_processor_ffh_cstate_probe() to verify them and update the
745 * cpu_cstate_entry data for @cpu.
746 */
747 int acpi_processor_evaluate_cst(acpi_handle handle, u32 cpu,
748 struct acpi_processor_power *info)
749 {
750 struct acpi_buffer buffer = { ACPI_ALLOCATE_BUFFER, NULL };
751 union acpi_object *cst;
752 acpi_status status;
753 u64 count;
754 int last_index = 0;
755 int i, ret = 0;
756
757 status = acpi_evaluate_object(handle, "_CST", NULL, &buffer);
758 if (ACPI_FAILURE(status)) {
759 acpi_handle_debug(handle, "No _CST\n");
760 return -ENODEV;
761 }
762
763 cst = buffer.pointer;
764
765 /* There must be at least 2 elements. */
766 if (!cst || cst->type != ACPI_TYPE_PACKAGE || cst->package.count < 2) {
767 acpi_handle_warn(handle, "Invalid _CST output\n");
768 ret = -EFAULT;
769 goto end;
770 }
771
772 count = cst->package.elements[0].integer.value;
773
774 /* Validate the number of C-states. */
775 if (count < 1 || count != cst->package.count - 1) {
776 acpi_handle_warn(handle, "Inconsistent _CST data\n");
777 ret = -EFAULT;
778 goto end;
779 }
780
781 for (i = 1; i <= count; i++) {
782 union acpi_object *element;
783 union acpi_object *obj;
784 struct acpi_power_register *reg;
785 struct acpi_processor_cx cx;
786
787 /*
788 * If there is not enough space for all C-states, skip the
789 * excess ones and log a warning.
790 */
791 if (last_index >= ACPI_PROCESSOR_MAX_POWER - 1) {
792 acpi_handle_warn(handle,
793 "No room for more idle states (limit: %d)\n",
794 ACPI_PROCESSOR_MAX_POWER - 1);
795 break;
796 }
797
798 memset(&cx, 0, sizeof(cx));
799
800 element = &cst->package.elements[i];
801 if (element->type != ACPI_TYPE_PACKAGE)
802 continue;
803
804 if (element->package.count != 4)
805 continue;
806
807 obj = &element->package.elements[0];
808
809 if (obj->type != ACPI_TYPE_BUFFER)
810 continue;
811
812 reg = (struct acpi_power_register *)obj->buffer.pointer;
813
814 obj = &element->package.elements[1];
815 if (obj->type != ACPI_TYPE_INTEGER)
816 continue;
817
818 cx.type = obj->integer.value;
819 /*
820 * There are known cases in which the _CST output does not
821 * contain C1, so if the type of the first state found is not
822 * C1, leave an empty slot for C1 to be filled in later.
823 */
824 if (i == 1 && cx.type != ACPI_STATE_C1)
825 last_index = 1;
826
827 cx.address = reg->address;
828 cx.index = last_index + 1;
829
830 if (reg->space_id == ACPI_ADR_SPACE_FIXED_HARDWARE) {
> 831 if (!acpi_processor_ffh_cstate_probe(cpu, &cx, reg)) {
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org Intel Corporation
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 33743 bytes --]
next prev parent reply other threads:[~2019-12-08 13:55 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-12-06 9:28 [RFC][PATCH 0/6] cpuidle: intel_idle: Use ACPI _CTS to get idle states information Rafael J. Wysocki
2019-12-06 9:31 ` [RFC][PATCH 1/6] ACPI: processor: Export function to claim _CST control Rafael J. Wysocki
2019-12-06 9:32 ` [RFC][PATCH 2/6] ACPI: processor: Introduce acpi_processor_evaluate_cst() Rafael J. Wysocki
2019-12-06 9:36 ` [RFC][PATCH 3/6] ACPI: processor: Clean up acpi_processor_evaluate_cst() Rafael J. Wysocki
2019-12-06 9:37 ` [RFC][PATCH 4/6] ACPI: processor: Export acpi_processor_evaluate_cst() Rafael J. Wysocki
2019-12-08 13:55 ` kbuild test robot [this message]
2019-12-06 9:46 ` [RFC][PATCH 5/6] intel_idle: Refactor intel_idle_cpuidle_driver_init() Rafael J. Wysocki
2019-12-06 9:46 ` [RFC][PATCH 6/6] intel_idle: Use ACPI _CST for processor models without C-state tables Rafael J. Wysocki
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201912082145.jUkUQ8KD%lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.