From nobody Mon Feb 9 13:00:44 2026 Received: from mail-yb1-f201.google.com (mail-yb1-f201.google.com [209.85.219.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 616151D9A40 for ; Thu, 19 Dec 2024 20:54:59 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734641700; cv=none; b=Je6qEyQyp+eewZ/9Jwq/8JuLxZmMsAQN4mzNqnoXvf1xQLlTK/wIBTVQmxF+s5eg7FOPjduXNrZATx/hqW5ubHdufHZ+KGMcpmGD0L3zwX4BDJZxB4qWndrBBfQrJpOBnanBbyxVUtraYnKZetP7sE1SZZu6i5Vyr6gVzQFQg4E= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1734641700; c=relaxed/simple; bh=SRD8tZACNTgWfx/X2zGBe2OpD/c2rOd9Vng5eVBS+LY=; h=Date:Message-Id:Mime-Version:Subject:From:To:Content-Type; b=kVeggamUeJLHnztBZSZRuYrIaIFI05PiNQVjQfZVXCoSVfbWbZ+I67h9yuDE38N6q84EPK4x4wyMdIXsPXEDPZuQYrLg6sLeHJj5Xrj+D3nCulsmgcxSZ6S36bZwCjHcRTqfIGgVe17KlzOnnv8VKxIkv80BHeI+iFQ4ekZ7LWM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b=lumpynpH; arc=none smtp.client-ip=209.85.219.201 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=google.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=flex--irogers.bounces.google.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=google.com header.i=@google.com header.b="lumpynpH" Received: by mail-yb1-f201.google.com with SMTP id 3f1490d57ef6-e4a8b40dd40so1570599276.3 for ; Thu, 19 Dec 2024 12:54:59 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20230601; t=1734641698; x=1735246498; darn=vger.kernel.org; h=to:from:subject:mime-version:message-id:date:from:to:cc:subject :date:message-id:reply-to; bh=JwF2YtaIR8lEGnMy9oSwqCJvpQRKlZKbAb6shRYXX1E=; b=lumpynpHi49HvrnHbLBUJfjnveOpacvj3teUwQBfiwQgCHKUTG6DV4qtGSNILmAG3D k81E1CAucx/y2+MhNSGTP5HN0Yue+a85E4xOqA7J3v8OMCRDIGiCRWJvpdFsylrTFVWH QrAJM6MRK9QfYyEy0r0oMNLge10HQqwGGMMOx2fenskBCitp7uXyD0FujkEqwEkHGuUk CAIqWe5Sfwqr09jgWUOhDW9Za/9J0P0eSks7xhjO5HmlnNoLo9Eth5yk00mLbbcZEP1B qgu030OX28M7VSlL21xAcdy/6GQ0I6qQ5p1+Sh8Me+82HQzY5ycLrx1kvT/MWqEfNhNl xk9A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1734641698; x=1735246498; h=to:from:subject:mime-version:message-id:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=JwF2YtaIR8lEGnMy9oSwqCJvpQRKlZKbAb6shRYXX1E=; b=IbpJT4aU4sYXlnyJrFrcGRfjlowUmkJzF44kpcHcRy9fDDk0zo0g7gy/JOaE87d90J GanwsNIYUu0zV8BuTMO9nH4Xjow1w2clcxRCS1e6v4cqcVNVUL9xPeO+l0MOrBHzPsl9 SaFglRfVnPKcR0EHlbWzKsVktWoLMKweXPAcIyqyoiX+4O5shIaKWBYCIAEsqdeSsQ+p gA2p1CWCbQmJzztI+eNYFaxXByF5cZDp7Qpm34pgXxA0knk+D2fDss+VYLpUO2+e3Ud7 jQ8zIQVnBX6uN1xcE2RQmzlJcivOrh6R0OMUbTHHZ5aLNsH26f9ThmMETxcmAuoyQ9sE DBFQ== X-Forwarded-Encrypted: i=1; AJvYcCV3bxsEYYU5TMWnxr6TGNJtDODNlIgyju6PxqRce0O1jd51v6SGerzK25VaPK+8asbMr1RmVAW2/RCHxyo=@vger.kernel.org X-Gm-Message-State: AOJu0YxEyhHOyiuoUTVYfJirE1dw6LdfGyEYrhAtTr0NXakH/EHIIQx+ Jk/yrKR6g0HDlyiWAlsYTsEKjbYWTaisBTTEpWA4P5rA7WZZNC36lTkvFM0wJD3iu8H7nvGD38m U6o+gSQ== X-Google-Smtp-Source: AGHT+IHdrpSntOaSp2b3pz33zySoxVYV+yJJaO1kAkHHusRR6aF4B7wW8Q985ftFmHWK3fHQNwB0S2MQlWJw X-Received: from irogers.svl.corp.google.com ([2620:15c:2c5:11:c4ca:4252:db7d:2183]) (user=irogers job=sendgmr) by 2002:a25:b18a:0:b0:e3d:da4c:7981 with SMTP id 3f1490d57ef6-e538c3841cfmr711276.7.1734641698277; Thu, 19 Dec 2024 12:54:58 -0800 (PST) Date: Thu, 19 Dec 2024 12:54:45 -0800 Message-Id: <20241219205445.103071-1-irogers@google.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 X-Mailer: git-send-email 2.47.1.613.gc27f4b7a9f-goog Subject: [PATCH v1] tools lib api cpu: Remove unused file From: Ian Rogers To: Ian Rogers , Arnaldo Carvalho de Melo , Jesper Juhl , Sam James , Namhyung Kim , linux-kernel@vger.kernel.org, Kan Liang Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" No use in tools could be found, remove to simplify the code base. Signed-off-by: Ian Rogers Acked-by: Kan Liang --- tools/lib/api/Build | 1 - tools/lib/api/Makefile | 2 +- tools/lib/api/cpu.c | 19 ------------------- tools/lib/api/cpu.h | 7 ------- 4 files changed, 1 insertion(+), 28 deletions(-) delete mode 100644 tools/lib/api/cpu.c delete mode 100644 tools/lib/api/cpu.h diff --git a/tools/lib/api/Build b/tools/lib/api/Build index 6e2373db5598..2be979407615 100644 --- a/tools/lib/api/Build +++ b/tools/lib/api/Build @@ -1,6 +1,5 @@ libapi-y +=3D fd/ libapi-y +=3D fs/ -libapi-y +=3D cpu.o libapi-y +=3D debug.o libapi-y +=3D str_error_r.o =20 diff --git a/tools/lib/api/Makefile b/tools/lib/api/Makefile index 7f6396087b46..bc08bccc94cb 100644 --- a/tools/lib/api/Makefile +++ b/tools/lib/api/Makefile @@ -95,7 +95,7 @@ install_lib: $(LIBFILE) $(call do_install_mkdir,$(libdir_SQ)); \ cp -fpR $(LIBFILE) $(DESTDIR)$(libdir_SQ) =20 -HDRS :=3D cpu.h debug.h io.h +HDRS :=3D debug.h io.h FD_HDRS :=3D fd/array.h FS_HDRS :=3D fs/fs.h fs/tracing_path.h INSTALL_HDRS_PFX :=3D $(DESTDIR)$(prefix)/include/api diff --git a/tools/lib/api/cpu.c b/tools/lib/api/cpu.c deleted file mode 100644 index 4af6d4b7aa07..000000000000 --- a/tools/lib/api/cpu.c +++ /dev/null @@ -1,19 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0 -#include - -#include "cpu.h" -#include "fs/fs.h" - -int cpu__get_max_freq(unsigned long long *freq) -{ - char entry[PATH_MAX]; - int cpu; - - if (sysfs__read_int("devices/system/cpu/online", &cpu) < 0) - return -1; - - snprintf(entry, sizeof(entry), - "devices/system/cpu/cpu%d/cpufreq/cpuinfo_max_freq", cpu); - - return sysfs__read_ull(entry, freq); -} diff --git a/tools/lib/api/cpu.h b/tools/lib/api/cpu.h deleted file mode 100644 index 90a102fb20de..000000000000 --- a/tools/lib/api/cpu.h +++ /dev/null @@ -1,7 +0,0 @@ -/* SPDX-License-Identifier: GPL-2.0 */ -#ifndef __API_CPU__ -#define __API_CPU__ - -int cpu__get_max_freq(unsigned long long *freq); - -#endif /* __API_CPU__ */ --=20 2.47.1.613.gc27f4b7a9f-goog