mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] selftests/thermal: Remove duplicate sprintf() call in workload_hint_test
@ 2025-07-10 13:04 WangYuli
  2025-07-10 13:47 ` [PATCH] selftests/thermal: Remove duplicate newlines in perror calls WangYuli
  0 siblings, 1 reply; 2+ messages in thread
From: WangYuli @ 2025-07-10 13:04 UTC (permalink / raw)
  To: shuah, wangyuli, chelsyratnawat2001, akpm
  Cc: linux-kselftest, linux-kernel, zhanjun, niecheng1, guanwentao

Remove redundant sprintf() call that was duplicating the same operation
of formatting delay_str with argv[1].

Signed-off-by: WangYuli <wangyuli@uniontech.com>
---
 .../selftests/thermal/intel/workload_hint/workload_hint_test.c  | 2 --
 1 file changed, 2 deletions(-)

diff --git a/tools/testing/selftests/thermal/intel/workload_hint/workload_hint_test.c b/tools/testing/selftests/thermal/intel/workload_hint/workload_hint_test.c
index a40097232967..bda006af8b1b 100644
--- a/tools/testing/selftests/thermal/intel/workload_hint/workload_hint_test.c
+++ b/tools/testing/selftests/thermal/intel/workload_hint/workload_hint_test.c
@@ -67,8 +67,6 @@ int main(int argc, char **argv)
 		if (delay < 0)
 			exit(1);
 
-		sprintf(delay_str, "%s\n", argv[1]);
-
 		sprintf(delay_str, "%s\n", argv[1]);
 		fd = open(WORKLOAD_NOTIFICATION_DELAY_ATTRIBUTE, O_RDWR);
 		if (fd < 0) {
-- 
2.50.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-07-10 13:50 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-07-10 13:04 [PATCH] selftests/thermal: Remove duplicate sprintf() call in workload_hint_test WangYuli
2025-07-10 13:47 ` [PATCH] selftests/thermal: Remove duplicate newlines in perror calls WangYuli

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®