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 4BF5D4266A for ; Wed, 4 Oct 2023 10:57:05 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3DF9740648; Wed, 4 Oct 2023 10:57:05 +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 55A8640289 for ; Wed, 4 Oct 2023 10:57:03 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1696409822; 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=JdrNywU+QcRg7McY2J540eCOElVz71tisb/SA+57yhg=; b=FS2OtN1VvWMTSQekQcevBa6gfdI+/mgm9Aaxo5PKU46bK4tDv5rXJKV975s/7vbTx/n1Fq PzqvfnOOVKMKgpN6geOkj7HZwbIHXavGiNqKL6ceLPhhFzYW9pocbXpo0M68HWB/omHJec zV8m6bmnF36N1uZ/NEKyWLtL+BrOSIY= Received: from mail-lf1-f70.google.com (mail-lf1-f70.google.com [209.85.167.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-674-3hyx8CUZNViNqorfajaI0Q-1; Wed, 04 Oct 2023 04:57:01 -0400 X-MC-Unique: 3hyx8CUZNViNqorfajaI0Q-1 Received: by mail-lf1-f70.google.com with SMTP id 2adb3069b0e04-503c774fd61so1658637e87.3 for ; Wed, 04 Oct 2023 01:57:01 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696409820; x=1697014620; 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=JdrNywU+QcRg7McY2J540eCOElVz71tisb/SA+57yhg=; b=mzta/xI7vr+VLbum12JU/egwTQkigjytkQ1WfaWhuUqjDFWPPzCXF4N0c55b6xqhb6 1dazMECFPlEDvuUcExBTi8M2jdkHyrKwd/l+9S8odFFYt35krHnZPF/S1fZNoWWtonZ4 ncU/NzWjW+NMer01YOS4vYebB8dSaCXOMl/qB8FNNdRnw1jjG7KjXHnmfdbdQBw2rIlW Q9DqJKrO5PwtC0ggV8RPqVVKO2D+6xA11TzDUCM5/xL5vK0M/cvTMKzclqegF70E1hwo JRHTal7+DuTiZBKRHT+V0W6JZ1gkHrDeoVq2rSTLvUHjXCB8d1pRQhG5tqLgUBBcp8cB zcsQ== X-Gm-Message-State: AOJu0YzUMJ64c8dQCar6CXlLllQmmM5o7cFI7NGHAUnLZKYFW08uC1WH CKiX5ypU5Y3HdqptkK8Da9IDgXT3H9s3mw5fFXzKw0eo6YzrOkbpEX4dyH9yVIM5/xlTiU8k9Tb 0WRxacam/VjxjFMYF+3RIvGs= X-Received: by 2002:a05:6512:3f0e:b0:502:f7a4:c31f with SMTP id y14-20020a0565123f0e00b00502f7a4c31fmr1969093lfa.45.1696409819953; Wed, 04 Oct 2023 01:56:59 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGYvBa4dO5mGLZpDFlfj4pDB8wTWNkC8pKRXb8xpSvMfvJgCifB4QZU/aeHqfzI9NizG3GCi7Zcn4dQO70WljQ= X-Received: by 2002:a05:6512:3f0e:b0:502:f7a4:c31f with SMTP id y14-20020a0565123f0e00b00502f7a4c31fmr1969079lfa.45.1696409819571; Wed, 04 Oct 2023 01:56:59 -0700 (PDT) MIME-Version: 1.0 References: <20231003113938.42959-1-selwin.sebastian@amd.com> In-Reply-To: <20231003113938.42959-1-selwin.sebastian@amd.com> From: David Marchand Date: Wed, 4 Oct 2023 10:56:48 +0200 Message-ID: Subject: Re: [PATCH v2] net/axgbe: use CPUID to identify cpu To: Selwin Sebastian Cc: dev@dpdk.org, Ferruh.Yigit@amd.com, stable@dpdk.org X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable 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 Hello Selwin, On Tue, Oct 3, 2023 at 1:40=E2=80=AFPM Selwin Sebastian wrote: > > Using root complex to identify cpu will not work for vm passthrough. > CPUID is used to get family and modelid to identify cpu > > Fixes: b0db927b5eba ("net/axgbe: use PCI root complex device to distingui= sh device") > Cc: stable@dpdk.org > > Signed-off-by: Selwin Sebastian > --- > drivers/net/axgbe/axgbe_ethdev.c | 106 ++++++++++++++++++------------- > 1 file changed, 63 insertions(+), 43 deletions(-) > > diff --git a/drivers/net/axgbe/axgbe_ethdev.c b/drivers/net/axgbe/axgbe_e= thdev.c > index 48714eebe6..4fdb0ae168 100644 > --- a/drivers/net/axgbe/axgbe_ethdev.c > +++ b/drivers/net/axgbe/axgbe_ethdev.c > @@ -12,6 +12,12 @@ > > #include "eal_filesystem.h" > > +#ifdef RTE_ARCH_X86 > +#include > +#else > +#define __cpuid (n, a, b, c, d) With a space in this macro definition, the precompiler will think that it must replace the __cpuid token as literally (n, a, b, c, d). --=20 David Marchand