summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChangqing Li <changqing.li@windriver.com>2025-04-10 13:59:58 +0800
committerKhem Raj <raj.khem@gmail.com>2025-04-10 08:31:05 -0700
commit2fb85f67dd724bdf806a0bda886ff7d6dfaeaab8 (patch)
tree91f5988d792351550cd6c47fdc2664a7a0fa6ec5
parent41ea13385170eacc1bc235256a370551830b8b30 (diff)
downloadmeta-openembedded-2fb85f67dd724bdf806a0bda886ff7d6dfaeaab8.tar.gz
pmtools: remove recipes
Remove this not maintained recipe. The latest commit of pmtools is 12 years ago. And it generates 3 binaries: acpidump/acpixtract/madt, but there is a recipe acpica in oe-core provides acpidump/acpixtract, and according to README.madt, it is hacked out from Linux kernel, if someone requests it, mayb user can add one recipe similar like turbostat. [1] https://github.com/anyc/pmtools/tree/master Signed-off-by: Changqing Li <changqing.li@windriver.com> Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r--meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb4
-rw-r--r--meta-oe/recipes-devtools/pmtools/pmtools/pmtools-switch-to-dynamic-buffer-for-huge-ACPI-table.patch82
-rw-r--r--meta-oe/recipes-devtools/pmtools/pmtools_git.bb34
3 files changed, 2 insertions, 118 deletions
diff --git a/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb b/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb
index 4b61548486..9b68e7be82 100644
--- a/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb
+++ b/meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb
@@ -294,8 +294,8 @@ RDEPENDS:packagegroup-meta-oe-devtools = "\
294 yajl \ 294 yajl \
295 yasm \ 295 yasm \
296" 296"
297RDEPENDS:packagegroup-meta-oe-devtools:append:x86 = " cpuid msr-tools pahole pmtools" 297RDEPENDS:packagegroup-meta-oe-devtools:append:x86 = " cpuid msr-tools pahole"
298RDEPENDS:packagegroup-meta-oe-devtools:append:x86-64 = " cpuid msr-tools pahole pcimem pmtools" 298RDEPENDS:packagegroup-meta-oe-devtools:append:x86-64 = " cpuid msr-tools pahole pcimem"
299RDEPENDS:packagegroup-meta-oe-devtools:append:riscv64 = " pcimem" 299RDEPENDS:packagegroup-meta-oe-devtools:append:riscv64 = " pcimem"
300RDEPENDS:packagegroup-meta-oe-devtools:append:arm = " pcimem" 300RDEPENDS:packagegroup-meta-oe-devtools:append:arm = " pcimem"
301RDEPENDS:packagegroup-meta-oe-devtools:append:aarch64 = " pahole pcimem" 301RDEPENDS:packagegroup-meta-oe-devtools:append:aarch64 = " pahole pcimem"
diff --git a/meta-oe/recipes-devtools/pmtools/pmtools/pmtools-switch-to-dynamic-buffer-for-huge-ACPI-table.patch b/meta-oe/recipes-devtools/pmtools/pmtools/pmtools-switch-to-dynamic-buffer-for-huge-ACPI-table.patch
deleted file mode 100644
index 3be18986fc..0000000000
--- a/meta-oe/recipes-devtools/pmtools/pmtools/pmtools-switch-to-dynamic-buffer-for-huge-ACPI-table.patch
+++ /dev/null
@@ -1,82 +0,0 @@
1From 03a886252f6555d6b0af76b654e76459642b89da Mon Sep 17 00:00:00 2001
2From: Yunguo Wei <yunguo.wei@windriver.com>
3Date: Tue, 3 Dec 2013 18:12:50 +0800
4Subject: [PATCH] pmtools: switch to dynamic buffer for huge ACPI tables
5
6For servers like Canoe Pass or Thunder Ridge, there are much more
7entries in ACPI table, so original 1K buffer is insufficient.
8
9We switch to dynamic buffer on this situation.
10
11Signed-off-by: Yunguo Wei <yunguo.wei@windriver.com>
12
13
14Upstream-Status: Pending
15
16Signed-off-by: Kai Kang <kai.kang@windriver.com>
17---
18 madt/madt.c | 18 +++++++++++++++++-
19 1 file changed, 17 insertions(+), 1 deletion(-)
20
21--- a/madt/madt.c
22+++ b/madt/madt.c
23@@ -34,14 +34,16 @@ typedef unsigned long long u64;
24 //#include <sys/mman.h>
25 #include <stdio.h> // fread
26 #include <stdlib.h> // malloc
27+#include <string.h> // memset/memcpy
28
29 #include "./tables.c"
30
31 int verbose = 0;
32 /*
33-/* read standard input
34+ * read standard input
35 * write decoded madt to standard output
36 */
37+size_t
38 get_next_entry(acpi_table_entry_header * entry_header)
39 {
40 size_t retval;
41@@ -51,9 +53,11 @@ get_next_entry(acpi_table_entry_header *
42 return retval;
43 }
44
45-u8 buffer[1024];
46
47-main()
48+u8 buf[1024];
49+u8 *buffer = buf;
50+int
51+main(int argc, char *argv[])
52 {
53 size_t retval;
54 struct acpi_table_madt *madt_header;
55@@ -75,6 +79,17 @@ main()
56
57 if (verbose) printf("header.length %d\n", madt_header->header.length);
58
59+ /* if 1K buffer is insufficient for acpi table, switch to a larger memory buffer */
60+ if(expected_length > sizeof(buf)) {
61+ buffer = malloc(expected_length);
62+ if (!buffer) {
63+ perror("malloc");
64+ exit(1);
65+ }
66+ memset(buffer, 0, expected_length);
67+ memcpy(buffer, buf, sizeof(struct acpi_table_madt));
68+ }
69+
70 acpi_table_print((void*)&(buffer[bytes_read]), 0);
71
72 bytes_read = sizeof(struct acpi_table_madt);
73@@ -118,6 +133,9 @@ done:
74 printf("Checksum 0x%x != 0; 0x%x in header ERROR\n", csum,
75 madt_header->header.checksum);
76
77+ if(buffer != buf)
78+ free(buffer);
79+
80 return 0;
81 }
82
diff --git a/meta-oe/recipes-devtools/pmtools/pmtools_git.bb b/meta-oe/recipes-devtools/pmtools/pmtools_git.bb
deleted file mode 100644
index ad149de12c..0000000000
--- a/meta-oe/recipes-devtools/pmtools/pmtools_git.bb
+++ /dev/null
@@ -1,34 +0,0 @@
1DESCRIPTION = "This is a small collection of power management \
2 test and investigation tools"
3HOMEPAGE = "http://lesswatts.org/projects/acpi"
4LICENSE = "GPL-2.0-or-later"
5LIC_FILES_CHKSUM = "file://COPYING;md5=0636e73ff0215e8d672dc4c32c317bb3"
6
7PV = "20130209+git"
8
9SRC_URI = "git://github.com/anyc/pmtools.git;branch=master;protocol=https \
10 file://pmtools-switch-to-dynamic-buffer-for-huge-ACPI-table.patch \
11"
12SRCREV = "3ebe0e54c54061b4c627236cbe35d820de2e1168"
13
14COMPATIBLE_HOST = "(i.86|x86_64).*-linux"
15
16S = "${WORKDIR}/git"
17
18inherit update-alternatives
19
20ALTERNATIVE_PRIORITY = "90"
21ALTERNATIVE:${PN} = "acpixtract acpidump"
22
23do_configure[noexec] = "1"
24do_compile() {
25 oe_runmake
26}
27
28do_install() {
29 install -d ${D}${bindir} ${D}${docdir}
30 install -m 755 ${S}/acpidump/acpidump ${D}${bindir}
31 install -m 755 ${S}/acpixtract/acpixtract ${D}${bindir}
32 install -m 755 ${S}/madt/madt ${D}${bindir}
33 install -m 644 ${S}/README ${D}${docdir}
34}