[{"id":3680521,"web_url":"http://patchwork.ozlabs.org/comment/3680521/","msgid":"<20260422111139.4036-1-linuxtestproject.agent@gmail.com>","list_archive_url":null,"date":"2026-04-22T11:11:39","subject":"Re: [LTP] cpufreq.c: add new test for cpufreq sysfs interface\n validation","submitter":{"id":93132,"url":"http://patchwork.ozlabs.org/api/people/93132/","name":null,"email":"linuxtestproject.agent@gmail.com"},"content":"Hi Piotr,\n\nOn 2026-04-22, Piotr Kubaj wrote:\n> cpufreq.c: add new test for cpufreq sysfs interface validation\n\n> +static long *previous_scaling_max_freq, *previous_scaling_min_freq;\n> +\n> +static void cleanup(void)\n> +{\n> [...]\n> +               SAFE_FILE_PRINTF(path, \"%ld\", previous_scaling_max_freq[i]);\n> [...]\n> +               SAFE_FILE_PRINTF(path, \"%ld\", previous_scaling_min_freq[i]);\n\nBoth arrays are zeroed by SAFE_CALLOC in setup() and only populated\ninside run(). If run() aborts before reaching the per-CPU save loops\n(e.g. a SAFE_OPEN or SAFE_FILE_SCANF fails on an earlier cpufreq node),\ncleanup() writes 0 to scaling_max_freq and scaling_min_freq for every\nonline CPU, leaving the system in an invalid state.\n\nRead the original per-CPU values in setup() instead.\n\nPre-existing issues noticed in the surrounding code (not introduced\nby this patch):\n\n- cpufreq.c:116 — strstr(contents, \"performance powersave\") assumes\n  a specific governor ordering that the kernel does not guarantee.\n- cpufreq.c:170 — same issue for \"performance schedutil\".\n\n---\nNote:\n\nOur agent completed the review of the patch.\n\nThe agent can sometimes produce false positives although often its\nfindings are genuine. If you find issues with the review, please\ncomment this email or ignore the suggestions.\n\nRegards,\nLTP AI Reviewer","headers":{"Return-Path":"<ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it>","X-Original-To":["incoming@patchwork.ozlabs.org","ltp@lists.linux.it"],"Delivered-To":["patchwork-incoming@legolas.ozlabs.org","ltp@picard.linux.it"],"Authentication-Results":["legolas.ozlabs.org;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=pg9MkmBN;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=pass (sender SPF authorized) smtp.mailfrom=lists.linux.it\n (client-ip=213.254.12.146; helo=picard.linux.it;\n envelope-from=ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it;\n receiver=patchwork.ozlabs.org)"],"Received":["from picard.linux.it (picard.linux.it [213.254.12.146])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g0xPg3BRbz1yCv\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 22 Apr 2026 21:11:51 +1000 (AEST)","from picard.linux.it (localhost [IPv6:::1])\n\tby picard.linux.it (Postfix) with ESMTP id 520733E53B2\n\tfor <incoming@patchwork.ozlabs.org>; Wed, 22 Apr 2026 13:11:47 +0200 (CEST)","from in-2.smtp.seeweb.it (in-2.smtp.seeweb.it [217.194.8.2])\n (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n (No client certificate requested)\n by picard.linux.it (Postfix) with ESMTPS id 81BDC3E1B20\n for <ltp@lists.linux.it>; Wed, 22 Apr 2026 13:11:43 +0200 (CEST)","from mail-dy1-x1341.google.com (mail-dy1-x1341.google.com\n [IPv6:2607:f8b0:4864:20::1341])\n (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)\n key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest\n SHA256)\n (No client certificate requested)\n by in-2.smtp.seeweb.it (Postfix) with ESMTPS id CCBD7600683\n for <ltp@lists.linux.it>; Wed, 22 Apr 2026 13:11:42 +0200 (CEST)","by mail-dy1-x1341.google.com with SMTP id\n 5a478bee46e88-2b6b0500e06so8457888eec.1\n for <ltp@lists.linux.it>; Wed, 22 Apr 2026 04:11:42 -0700 (PDT)","from\n runnervmeorf1.x4tjlv0jbqcu3pgfkj12tkpfpd.dx.internal.cloudapp.net\n ([172.184.213.165]) by smtp.gmail.com with ESMTPSA id\n 5a478bee46e88-2e539fa6134sm23384318eec.3.2026.04.22.04.11.40\n (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256);\n Wed, 22 Apr 2026 04:11:40 -0700 (PDT)"],"DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=gmail.com; s=20251104; t=1776856301; x=1777461101; darn=lists.linux.it;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n :message-id:reply-to;\n bh=1B4KG9caQPyAuUlmAFeoHVTKr/D6yylwxirC023kQ3E=;\n b=pg9MkmBNT/9aU0WuzbA5QBbNjrje63NdZm4F8tsiyXbVhdiJF8uOIOPOsLoJpUwxVn\n o7UAPBBbhi/ogK/JPdEfG02ZBhE5gPIFJownjCKcKpXoomdmamtevs/tE4Bgg83IfP3F\n chq8Kkj3dV2KuSZTQMgxja9ZSg5nMxDQwOiLyjuULt+eXPGNhS0hVhlTcFFzJ88umeSz\n rWLi35bZ0Fu3imD6Tf7dieLs+ChYREmaEMnhKJ+othwfcKCmeAKVKaExdbSP+7MAkQyG\n bWoLr9dLuWjki6Jd3QCY5o5jzYKP/BeTjsLM9J/bA1P5bjF/fl0qrfv1EEGyFegnDTwI\n XnHQ==","X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n d=1e100.net; s=20251104; t=1776856301; x=1777461101;\n h=content-transfer-encoding:mime-version:references:in-reply-to\n :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n :to:cc:subject:date:message-id:reply-to;\n bh=1B4KG9caQPyAuUlmAFeoHVTKr/D6yylwxirC023kQ3E=;\n b=mPnEEtPq1p54di8oU0yaIxbR6cvtU+0kU0lIvJS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c:b0:2d2:c60d:4fe5 with SMTP id\n 5a478bee46e88-2e464ea4e10mr10699335eec.6.1776856300992;\n Wed, 22 Apr 2026 04:11:40 -0700 (PDT)","From":"linuxtestproject.agent@gmail.com","To":"Piotr Kubaj <piotr.kubaj@intel.com>","Date":"Wed, 22 Apr 2026 11:11:39 +0000","Message-ID":"<20260422111139.4036-1-linuxtestproject.agent@gmail.com>","X-Mailer":"git-send-email 2.54.0","In-Reply-To":"<20260422103542.20933-2-piotr.kubaj@intel.com>","References":"<20260422103542.20933-2-piotr.kubaj@intel.com>","MIME-Version":"1.0","X-Spam-Status":"No, score=0.1 required=7.0 tests=DKIM_SIGNED,DKIM_VALID,\n DKIM_VALID_AU,DKIM_VALID_EF,DMARC_PASS,FREEMAIL_FROM,SPF_HELO_NONE,\n SPF_PASS shortcircuit=no autolearn=disabled version=4.0.1","X-Spam-Checker-Version":"SpamAssassin 4.0.1 (2024-03-25) on in-2.smtp.seeweb.it","X-Virus-Scanned":"clamav-milter 1.0.9 at in-2.smtp.seeweb.it","X-Virus-Status":"Clean","Subject":"Re: [LTP] cpufreq.c: add new test for cpufreq sysfs interface\n validation","X-BeenThere":"ltp@lists.linux.it","X-Mailman-Version":"2.1.29","Precedence":"list","List-Id":"Linux Test Project <ltp.lists.linux.it>","List-Unsubscribe":"<https://lists.linux.it/options/ltp>,\n <mailto:ltp-request@lists.linux.it?subject=unsubscribe>","List-Archive":"<http://lists.linux.it/pipermail/ltp/>","List-Post":"<mailto:ltp@lists.linux.it>","List-Help":"<mailto:ltp-request@lists.linux.it?subject=help>","List-Subscribe":"<https://lists.linux.it/listinfo/ltp>,\n <mailto:ltp-request@lists.linux.it?subject=subscribe>","Cc":"ltp@lists.linux.it","Content-Type":"text/plain; charset=\"utf-8\"","Content-Transfer-Encoding":"base64","Errors-To":"ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it","Sender":"\"ltp\" <ltp-bounces+incoming=patchwork.ozlabs.org@lists.linux.it>"}}]