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 606B141B26; Mon, 28 Aug 2023 09:08:25 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 210B94026D; Mon, 28 Aug 2023 09:08:24 +0200 (CEST) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mails.dpdk.org (Postfix) with ESMTP id 668F24021E for ; Mon, 28 Aug 2023 09:08:22 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1693206501; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=EWz5psqAUPHVQ9Gu9QLyaiibwIEu1Hx5TdhUS++ehZs=; b=WZhQuFwK70I+81Jdn1tyNFdooIK8zawSmRBPBJqKiUQavaHPQHJ8Vslt9/+CvBC+swi8zd m+1/8dm4vd8nrBfwJ/7heI4GRmBfVvvYMZupF8o1PLtAUKsBllRllO+GKb4o1GiI8Jn9Vc iupkc8LFe0CfN0X7XuEwTyzsXPmP0+E= Received: from mail-lf1-f72.google.com (mail-lf1-f72.google.com [209.85.167.72]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-466-x8CpYbeCMYmqtUjFAdbt8g-1; Mon, 28 Aug 2023 03:08:20 -0400 X-MC-Unique: x8CpYbeCMYmqtUjFAdbt8g-1 Received: by mail-lf1-f72.google.com with SMTP id 2adb3069b0e04-5007f3d3293so3251469e87.3 for ; Mon, 28 Aug 2023 00:08:19 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1693206498; x=1693811298; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=EWz5psqAUPHVQ9Gu9QLyaiibwIEu1Hx5TdhUS++ehZs=; b=PYqQCZnXUs0e09+WhZ5CMJQTS4ltL3rsxHcnqwNWLRK0m0Rk4yQa/InHoLu0+gIZly vb1x56HCWkXpv7WmgCB/Iof6hlLsXunyU6pI0PiBItKXiapMPtGaVHyV+MSD0FI2RPU0 4nOZ+s7lDInk51MuqQpdYtvzOUuNlSg2r6S0AZC/SNC3OcQG5B6riJdJ5F7zB0/uPhp/ rGMJmBe8BGSVGfJ6XI9d7tDCL2fkDBtp6N+heZRD6wkMkUoBgqv8+RSdx8iiTcz6ybBy sJgXbixmAM2yksBaY181jpDZwyMg8DV5zu9B2MnpMaN04I6gilBSsrpcFBm+sMMDm/ma Fq7A== X-Gm-Message-State: AOJu0Yzqp9G8xgaDB7Xfr6Cx+gNKPg/EsxW2tsF+Nve8aHL7Sie3dk4o 92+w0VhKb0aoMvNrg7biZFPRRitJ79WOmNDyKr2Gn/DEG2OKeq5kqdywbkhKK811fcnd6EjQYvG CDWqPNPlxA69vl7Cd7Kg= X-Received: by 2002:a05:6512:2399:b0:500:ba39:f0c1 with SMTP id c25-20020a056512239900b00500ba39f0c1mr1329952lfv.20.1693206498771; Mon, 28 Aug 2023 00:08:18 -0700 (PDT) X-Google-Smtp-Source: AGHT+IEm8siB67zv9tKIxGyVXJjpm6WJj/sL6uAy2lWZWY6bBAngmT6beMjiIP8AXavCpIXPwbFZzlmIvDpotlC/Mmk= X-Received: by 2002:a05:6512:2399:b0:500:ba39:f0c1 with SMTP id c25-20020a056512239900b00500ba39f0c1mr1329940lfv.20.1693206498435; Mon, 28 Aug 2023 00:08:18 -0700 (PDT) MIME-Version: 1.0 References: <20230825152850.1107690-1-bruce.richardson@intel.com> In-Reply-To: <20230825152850.1107690-1-bruce.richardson@intel.com> From: David Marchand Date: Mon, 28 Aug 2023 09:08:07 +0200 Message-ID: Subject: Re: [PATCH] eal/x86: fix build on systems with WAITPKG support To: Bruce Richardson Cc: dev@dpdk.org, mb@smartsharesystems.com, roretzla@linux.microsoft.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Hello Bruce, On Fri, Aug 25, 2023 at 5:29=E2=80=AFPM Bruce Richardson wrote: > > When doing a build for a system with WAITPKG support and a modern > compiler, we get build errors for the "_umonitor" intrinsic, due to the > casting away of the "volatile" on the parameter. > > ../lib/eal/x86/rte_power_intrinsics.c: In function 'rte_power_monitor': > ../lib/eal/x86/rte_power_intrinsics.c:113:22: error: passing argument 1 > of '_umonitor' discards 'volatile' qualifier from pointer target type > [-Werror=3Ddiscarded-qualifiers] > 113 | _umonitor(pmc->addr); > | ~~~^~~~~~ > > We can avoid this issue by using RTE_PTR_ADD(..., 0) to cast the pointer > through "uintptr_t" and thereby remove the volatile without warning. > We also ensure comments are correct for each leg of the > ifdef..else..endif block. > > Fixes: 60943c04f3bc ("eal/x86: use intrinsics for power management") > Cc: roretzla@linux.microsoft.com > > Signed-off-by: Bruce Richardson I'm looking for a system with WAITPKG in the RH lab.. so far, no luck. Do you have a way to force-reproduce this issue? Like some compiler options forcing support? --=20 David Marchand