From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 2E3CC4373B for ; Tue, 19 Dec 2023 03:56:49 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 266D942DD3; Tue, 19 Dec 2023 03:56:49 +0100 (CET) Received: from NAM11-CO1-obe.outbound.protection.outlook.com (mail-co1nam11on2044.outbound.protection.outlook.com [40.107.220.44]) by mails.dpdk.org (Postfix) with ESMTP id 4E4E1402BC for ; Tue, 19 Dec 2023 03:56:47 +0100 (CET) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=HrtJABJovPhwdO42fAPpFxHJBb5Bzm9tyGrXzTKVvp780QlR8JmVF8VQO49jbrpm8Zfj1Qb3rtKgprpa0aoxMoXKDhVoI5klmZl9Dm4CymYj7IOdFaco5RTcN38uc8zTph8BI+uyQvhF4SoKunE22na3z1aolO0khJzAbJ1wM2b6BFTGJyvmFG1spHsM4CkFWmfQ0BlEj1VyMiHsN8XjGpCQXOBY43mA5J0EbUnpmyHmi6N3+wY+1M0XnaVA64pPRA4xKIigduDgl/uNXOs7ONt3ly/qSm2w4Hg2GJbdwdJv6l/Kjui9RKMAHnJi8KeMRp3jTGnUzE9msMD7pOxiLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=pelULDo/Wpz4C81J43QCyteewJdU1439J7sWe81Jjj8=; b=NCfhLKURswwcZ/Pj0Uw29EKCEKHjsCg5CcibNPqXzdSjjqNZsVctfBl0ClNakhoHycksMo47mFis2JYDYnMChWjqBp3bTSFKJvillKr9UNrDAB/jjldzcFukDFw5XlSlM34koHExqkbG01MMa1V/JwINxPaljdVxRq2fvLCFZAFxuFEde1DC+5Rr+OmS8AlhAc0p7Xc6CLkjEi8dPY7Bbon6SJa/cFcUQ4p2Bnslsda1OYgBBTUASF1vT57e0dpYdxn0lYrygr8fdrrGVPzuUj8K/mwfBRHlb6vSMKQC+fN6Mkhar2JrZwpaL9LXn0Iuqc5l8kb5nd7EBxIQbwiM2g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=intel.com smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pelULDo/Wpz4C81J43QCyteewJdU1439J7sWe81Jjj8=; b=FJLNtRNTfXSXvWx59lx/3h1wYj1pAHEowUFPF6lLOOVVbAofEvke+FLxTueCFf8D7GrZWXTN2ZRSCjZsafU1nRyXw37fxdgrRZ7vPw2YUKidzeIzZDWwdnMcMs/r8hoZzwtDmHc2HUh+224c2CWQg6w0B7pKO82ldkJXk2TVBlE= Received: from DM6PR08CA0019.namprd08.prod.outlook.com (2603:10b6:5:80::32) by IA1PR12MB8466.namprd12.prod.outlook.com (2603:10b6:208:44b::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7091.37; Tue, 19 Dec 2023 02:56:44 +0000 Received: from CY4PEPF0000EE3A.namprd03.prod.outlook.com (2603:10b6:5:80:cafe::35) by DM6PR08CA0019.outlook.office365.com (2603:10b6:5:80::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7091.38 via Frontend Transport; Tue, 19 Dec 2023 02:56:43 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CY4PEPF0000EE3A.mail.protection.outlook.com (10.167.242.14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.7113.14 via Frontend Transport; Tue, 19 Dec 2023 02:56:43 +0000 Received: from ubuntu2004.linuxvmimages.local (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.34; Mon, 18 Dec 2023 20:56:41 -0600 From: Sivaprasad Tummala To: CC: , Subject: [PATCH v2 6/6] examples/vm_power_manager: fix lcore ID restriction Date: Tue, 19 Dec 2023 03:56:07 +0100 Message-ID: <20231219025608.2538-7-sivaprasad.tummala@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20231219025608.2538-1-sivaprasad.tummala@amd.com> References: <20231218074905.42749-1-sivaprasad.tummala@amd.com> <20231219025608.2538-1-sivaprasad.tummala@amd.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB04.amd.com (10.181.40.145) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CY4PEPF0000EE3A:EE_|IA1PR12MB8466:EE_ X-MS-Office365-Filtering-Correlation-Id: 31bdee66-5a25-4c7a-a6f1-08dc003e21e9 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Lyiu5e4wP5GcogG1Oq0bq4Z6I3KNeAwmBIEP0kF8CNocQK9te/5PPgEYY0k4FwvhNZLVEsiuh/OISDIUtS8id6qS98rGzL2z8KcV1vkqJU6fMtaZ2wIBOmCw+dNrwUOEkfUZpzxMZ0v+TX9ukQE0iZmJe+krvWBjccbkAYzAzHJ6Ol/V4urkLMnSJ+HCL2TtaXQAs2vfKD3QWw/RICnGgsq9I73Vfs5C581xvP5MItl2/SJZvsWPD7s5XyeKT4IWzv3oVsZX/jmGvBKM3OHvJ9TshtsTzuyKMNxZzO7njxLZPyO+weN8juCm/mQnzmx7R0yyvj+iEUDf+7JGZJ7hy/zA8T8li/Xo3SZad5fAWWLbZ1eEtHFfnBxuAj7AEiKJP1gwmvOrVanccKAORGAawomVctyRU3FvIjOidFGt75p7UmIvBR16qsG5AMl8juMTKbAYCQo0NJxjm36JwCK3Xc9xgF4ItxZiKkBeO1krkjOtgNPgkcRNltoLLuLhRWAsdwGzZQDqRfr5cb9AANr1EhXd0671SgOZUKKd+fBmRvHUpsAYo/FDdUhLvxErcBa/Pr9hlvbK1808Y6y5jxlvmplnpTHvHH3WS5/rqOJRQnqrCFh6LkeIcDeWvLNQDUCfV4ETbO3vhMqw8AoQ4C8dnlq9UmfwSltaNl/s9+jLm4nGDvuZGNzn3HWcmW9pM1G/2f/ULQeT/sAEaxxvOzXCFlopTEB7BjO4QBuc0hffBI0FUYYcv9fOOtmmA//DN47JyZnWg1jDSSyys0yObdH1kw== X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230031)(4636009)(396003)(39860400002)(376002)(136003)(346002)(230922051799003)(186009)(64100799003)(82310400011)(1800799012)(451199024)(40470700004)(46966006)(36840700001)(47076005)(44832011)(8676002)(8936002)(70206006)(478600001)(6636002)(70586007)(37006003)(6862004)(54906003)(4326008)(41300700001)(316002)(36756003)(86362001)(1076003)(2616005)(2906002)(36860700001)(82740400003)(5660300002)(6666004)(83380400001)(81166007)(26005)(426003)(356005)(16526019)(336012)(40480700001)(40460700003)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Dec 2023 02:56:43.5763 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 31bdee66-5a25-4c7a-a6f1-08dc003e21e9 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CY4PEPF0000EE3A.namprd03.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA1PR12MB8466 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Currently the config option allows lcore IDs up to 255, irrespective of RTE_MAX_LCORES and needs to be fixed. The patch allows config options based on DPDK config. Fixes: 0e8f47491f09 ("examples/vm_power: add command to query CPU frequency") Cc: marcinx.hajkowski@intel.com Cc: stable@dpdk.org Signed-off-by: Sivaprasad Tummala --- examples/vm_power_manager/guest_cli/vm_power_cli_guest.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c b/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c index 94bfbbaf78..a586853a76 100644 --- a/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c +++ b/examples/vm_power_manager/guest_cli/vm_power_cli_guest.c @@ -401,7 +401,7 @@ check_response_cmd(unsigned int lcore_id, int *result) struct cmd_set_cpu_freq_result { cmdline_fixed_string_t set_cpu_freq; - uint8_t lcore_id; + uint16_t lcore_id; cmdline_fixed_string_t cmd; }; @@ -444,7 +444,7 @@ cmdline_parse_token_string_t cmd_set_cpu_freq = set_cpu_freq, "set_cpu_freq"); cmdline_parse_token_num_t cmd_set_cpu_freq_core_num = TOKEN_NUM_INITIALIZER(struct cmd_set_cpu_freq_result, - lcore_id, RTE_UINT8); + lcore_id, RTE_UINT16); cmdline_parse_token_string_t cmd_set_cpu_freq_cmd_cmd = TOKEN_STRING_INITIALIZER(struct cmd_set_cpu_freq_result, cmd, "up#down#min#max#enable_turbo#disable_turbo"); -- 2.25.1