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 4B285436DC; Wed, 13 Dec 2023 09:01:05 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2245842E88; Wed, 13 Dec 2023 09:01:05 +0100 (CET) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mails.dpdk.org (Postfix) with ESMTP id 92CAD42E55 for ; Wed, 13 Dec 2023 09:01:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1702454463; 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=g8bYTVHfkMJkNWlhv1TkkFdPYqbos2dLmNFP23txtNY=; b=OhFBf3sY+C3ZDS3/KnhSojsd1+NLTnv7jgeBgTJpoDGCgXEDUiF/OeTUpq8qlHP5tlI41d 6fhLrQxXnmqrxQnT6A15uURLQf2fzaU51RVHcBlXf064HsI54WsM9agsWjAhTo0hbl9Bt2 ZwjOj9XJp1JQ7T8bGUPlQMqcxlQ1fKY= Received: from mail-lj1-f198.google.com (mail-lj1-f198.google.com [209.85.208.198]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-37-kktdApRcPtOVreYTV7Zb8Q-1; Wed, 13 Dec 2023 03:01:01 -0500 X-MC-Unique: kktdApRcPtOVreYTV7Zb8Q-1 Received: by mail-lj1-f198.google.com with SMTP id 38308e7fff4ca-2ca1d169c0eso60851411fa.2 for ; Wed, 13 Dec 2023 00:01:01 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1702454460; x=1703059260; 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=g8bYTVHfkMJkNWlhv1TkkFdPYqbos2dLmNFP23txtNY=; b=UVUNuOUWk8GNBXBE2bzjI806jDLppWfA7uaUwwhU43JceCv6u/ti2STLSEhjaVwJcv eLKzhpjbeFuOLxmDr4vFzrs38GYfDO/aQAYWWC+NW/nk2809AKpLyCJebsVBZqXtLr06 v74AHamO8WGstdx+6AzwqnHnFirzjxvTrxyBe1yuNGAynuGOYU0Nv4VdiRxOZ4EFuzlK LM0cURbshev9lb4RjeWOPGogt88jD275j9GDdJ4HLEUNuGywJ3FwQUhu3SlZRQdtQFir ftiNLycjHMqG8Q9BTaPYj720KXVYDWaPmvRWM2P09tAJBglSHoJ0mlJfJ4JMabTpLNgw frCw== X-Gm-Message-State: AOJu0YzUeDiXAXkGsZLtDxQNbNAtMHMkl7zd1qHUyrnF/sbHGEBIAcLJ wIOO10KSZW32MD5tffh3m/V5ho+tDQTb1wIuqeOM2rCYiOBORa1CAYbaQO3pSO5ApvzDibS+tjD lXLrSBpdW/IhbmbH3e2RFeA3866tVYQ== X-Received: by 2002:a2e:9650:0:b0:2ca:1611:58e0 with SMTP id z16-20020a2e9650000000b002ca161158e0mr3064447ljh.71.1702454460461; Wed, 13 Dec 2023 00:01:00 -0800 (PST) X-Google-Smtp-Source: AGHT+IF0hlyyH5dEXzqexSTb4F0bixnJBiBXvr/idqbQMLGWf8b/lrntJafKLq9p9aTKTJAa1vjaJYNtI2PU4Op2kmI= X-Received: by 2002:a2e:9650:0:b0:2ca:1611:58e0 with SMTP id z16-20020a2e9650000000b002ca161158e0mr3064441ljh.71.1702454460138; Wed, 13 Dec 2023 00:01:00 -0800 (PST) MIME-Version: 1.0 References: <20231213014408.612051-1-stephen@networkplumber.org> <20231213041920.729403-1-stephen@networkplumber.org> In-Reply-To: <20231213041920.729403-1-stephen@networkplumber.org> From: David Marchand Date: Wed, 13 Dec 2023 09:00:48 +0100 Message-ID: Subject: Re: [PATCH v2 00/25] Replace use of RTE_LOGTYPE_PMD To: Stephen Hemminger Cc: dev@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: 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 On Wed, Dec 13, 2023 at 5:19=E2=80=AFAM Stephen Hemminger wrote: > > The generic RTE_LOGTYPE_PMD is a leftover and should be removed. > As a first step, fix many drivers to not use it, and add a > helper for the RTE_LOG_DP(). I don't see why we need a new rte_log_dp helper. The #define RTE_LOGTYPE_XXX trick should work fine with RTE_LOG_DP(). What else is missing? > > Most of this patchset is boiler plate but there were some > places where use of PMD type snuck in with changes to > original driver and get fixed here. I see odd changes, like a change in PMD_DRV_LOG meaning in the first patch: https://patchwork.dpdk.org/project/dpdk/patch/20231213041920.729403-4-steph= en@networkplumber.org/ A lot of drivers use this macro to log "driver"/configuration level errors (see below). Switching this macro to the DP version looks wrong to me. $ git grep PMD_DRV_LOG drivers/net/atlantic/ drivers/net/atlantic/atl_ethdev.c: PMD_DRV_LOG(ERR, "rte_eal_alarm_set fail"); drivers/net/atlantic/atl_ethdev.c: PMD_DRV_LOG(INFO, "Port %d: Link Up - speed %u Mbps - %s", drivers/net/atlantic/atl_ethdev.c: PMD_DRV_LOG(INFO, " Port %d: Link Down", drivers/net/atlantic/atl_ethdev.c: PMD_DRV_LOG(DEBUG, "PCI Address: " PCI_PRI_FMT, ... -- David Marchand