Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp465033pxb; Thu, 21 Oct 2021 03:11:33 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx2Hbs6QmwLOqY961ZmHXhk4JYa73pPBSG12wzPu35jQWhSSDgctoEvk/ClFok7zQFGfasd X-Received: by 2002:a17:906:fc0a:: with SMTP id ov10mr6149681ejb.536.1634811092769; Thu, 21 Oct 2021 03:11:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634811092; cv=none; d=google.com; s=arc-20160816; b=SGefHogiZdF3q4KGv9OG6R5H+jjZ27RKl73Tdm07/Y9dMJdCtec0Csr5QD/yy3p0UZ s0nsnCfsk/m8S/y7vD+mYOaw0mQm/3piztyQSj+OPUyfHD2RUXzH3donjOAfo8NAWOy/ Hw0V0u2aI7u3sERlmpI1wRsxJNj3WIMlg8of34WBK5AAWH7AlUWLiV/wSql3wsqIMF7h qrB0Mpp0eH6iz8WhzLFSEgP7anj0y4c+UZCvSGCo8lnli9ErZRcy54rku5Z3u0CZS0eo m+OnGaDq59VUYqV3dfqIZKkhh0Uo5yihpA4ypOQ7X7T8Kpj4DHMFk9N0zBGdsUQyqlwI 9G+g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:mail-followup-to:message-id:subject:cc:to :from:date:dkim-signature; bh=lJ5VWnCKzJUxsEb5WXqBp1tX6Jd2/Goa19ZNuDx2zbY=; b=r5WUepe3zu9dbaq20UalGvhPcp1t6EkjmufHXJ/hcluV8HET2cdVmS55xDnd3VTFqW J31WVyHiBwo10KnXdvncMOG/MHQUDnIIMlNzx8abIQOpij+iK34wP7tHppm86RV9tpS7 VtmUFQ1AL5IgkD/nCbXItGscNL0kp0T8qUxV8+sZQKKjuF40pa51UbC6N780SFnNxqiJ ILUclYdI40tfvO72Q+mEowkJ+o/Sb2XdlPX6ty5wslIgpLBiUrZ8TRyfrxtYpImWfI9C 6OoGMm3caqJ026wOSKpDSR38BFNaCscCGjRJkHkrSz3G+y8ABfxV5DgfJ9DtA34zvwmG YIEA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=I2vBIlED; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id q19si8622288edd.187.2021.10.21.03.11.09; Thu, 21 Oct 2021 03:11:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20210112 header.b=I2vBIlED; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231637AbhJUKJW (ORCPT + 99 others); Thu, 21 Oct 2021 06:09:22 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34486 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231499AbhJUKJV (ORCPT ); Thu, 21 Oct 2021 06:09:21 -0400 Received: from mail-wr1-x42d.google.com (mail-wr1-x42d.google.com [IPv6:2a00:1450:4864:20::42d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 378E8C06161C; Thu, 21 Oct 2021 03:07:05 -0700 (PDT) Received: by mail-wr1-x42d.google.com with SMTP id i12so179664wrb.7; Thu, 21 Oct 2021 03:07:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to:user-agent; bh=lJ5VWnCKzJUxsEb5WXqBp1tX6Jd2/Goa19ZNuDx2zbY=; b=I2vBIlEDPcFsZ05k3kMzo4kRJ2geEppMpkr4CtWNblQGP1wotFk7UZ53i7zlPGyNkm AHMoMtovSifZeMEDcWuEO+6KGUuco02L8Z/8eytzKuZZvj0UB6LfLMLU6solL4Rbh77V iOYeuIovCNftFtjEVmqBGMU2SV0JvD53/cZuj3cQOTWJPt+DBtYAluGuEog0qkC3YCcl Xr90bcxBjotlEmQ3PoGCZVFZtpn9uh13ayewG1xs/SqtkudRjAvgBq1ZMFGhYau5s/2w iwnyBXoSSxRHQ/jOiDW3xyLMOfjpWxmbL+db2CssWJtQZO2z7GULYy9Hu9HKk7KF5KCh 9kQw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id :mail-followup-to:references:mime-version:content-disposition :in-reply-to:user-agent; bh=lJ5VWnCKzJUxsEb5WXqBp1tX6Jd2/Goa19ZNuDx2zbY=; b=gHOxrAgW7nHMOBwDE7Z9zCsJ/3sR8qS2VDEoxfDsxRndyUDfQFkjj3vDzO85cAURK4 SUcmH714Aay2514e7KlN+AMSVC6MOAwGbwlYABF5qjQfq3kiOwtSHRWINfwFY98d1LvJ ga4noF9N8g4W2eQhFjDq2AXBi+eVeUQcyr66h4VTMXSBHwGFGyZegqmSMCila9psBuSr Ko8WKiezbqEzB3IYuSQBN5XL2R+XhfE+9zdTsT7AGjGG+9b4gAfP7yOqnVYu6HBpBICr TJADGrBLEMYaAC/LH5L+qZQv+9BkCkaHfoK9t1mul4eUDyEGhq7v3T3+YWkA1bIgmAdB 4ASA== X-Gm-Message-State: AOAM533yFVH0w3Ardkbpyp+tm62RXFo43Cv9m+UqU6WvVio0uuDUfvau UHAzj+RVCmB/N5xxOl8KbeE= X-Received: by 2002:a05:6000:8a:: with SMTP id m10mr1854481wrx.115.1634810823861; Thu, 21 Oct 2021 03:07:03 -0700 (PDT) Received: from gmail.com ([81.168.73.77]) by smtp.gmail.com with ESMTPSA id v185sm7573709wme.35.2021.10.21.03.07.03 (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Thu, 21 Oct 2021 03:07:03 -0700 (PDT) Date: Thu, 21 Oct 2021 11:07:01 +0100 From: Martin Habets To: Erik Ekman Cc: Edward Cree , "David S. Miller" , Jakub Kicinski , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] sfc: Don't use netif_info before net_device setup Message-ID: <20211021100701.k2dzn7mn5exyofkm@gmail.com> Mail-Followup-To: Erik Ekman , Edward Cree , "David S. Miller" , Jakub Kicinski , netdev@vger.kernel.org, linux-kernel@vger.kernel.org References: <20211019224016.26530-1-erik@kryo.se> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20211019224016.26530-1-erik@kryo.se> User-Agent: NeoMutt/20170113 (1.7.2) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 20, 2021 at 12:40:16AM +0200, Erik Ekman wrote: > Use pci_info instead to avoid unnamed/uninitialized noise: > > [197088.688729] sfc 0000:01:00.0: Solarflare NIC detected > [197088.690333] sfc 0000:01:00.0: Part Number : SFN5122F > [197088.729061] sfc 0000:01:00.0 (unnamed net_device) (uninitialized): no SR-IOV VFs probed > [197088.729071] sfc 0000:01:00.0 (unnamed net_device) (uninitialized): no PTP support > > Inspired by fa44821a4ddd ("sfc: don't use netif_info et al before > net_device is registered") from Heiner Kallweit. > > Signed-off-by: Erik Ekman Acked-by: Martin Habets > --- > drivers/net/ethernet/sfc/ptp.c | 4 ++-- > drivers/net/ethernet/sfc/siena_sriov.c | 2 +- > 2 files changed, 3 insertions(+), 3 deletions(-) > > diff --git a/drivers/net/ethernet/sfc/ptp.c b/drivers/net/ethernet/sfc/ptp.c > index a39c5143b386..797e51802ccb 100644 > --- a/drivers/net/ethernet/sfc/ptp.c > +++ b/drivers/net/ethernet/sfc/ptp.c > @@ -648,7 +648,7 @@ static int efx_ptp_get_attributes(struct efx_nic *efx) > } else if (rc == -EINVAL) { > fmt = MC_CMD_PTP_OUT_GET_ATTRIBUTES_SECONDS_NANOSECONDS; > } else if (rc == -EPERM) { > - netif_info(efx, probe, efx->net_dev, "no PTP support\n"); > + pci_info(efx->pci_dev, "no PTP support\n"); > return rc; > } else { > efx_mcdi_display_error(efx, MC_CMD_PTP, sizeof(inbuf), > @@ -824,7 +824,7 @@ static int efx_ptp_disable(struct efx_nic *efx) > * should only have been called during probe. > */ > if (rc == -ENOSYS || rc == -EPERM) > - netif_info(efx, probe, efx->net_dev, "no PTP support\n"); > + pci_info(efx->pci_dev, "no PTP support\n"); > else if (rc) > efx_mcdi_display_error(efx, MC_CMD_PTP, > MC_CMD_PTP_IN_DISABLE_LEN, > diff --git a/drivers/net/ethernet/sfc/siena_sriov.c b/drivers/net/ethernet/sfc/siena_sriov.c > index 83dcfcae3d4b..441e7f3e5375 100644 > --- a/drivers/net/ethernet/sfc/siena_sriov.c > +++ b/drivers/net/ethernet/sfc/siena_sriov.c > @@ -1057,7 +1057,7 @@ void efx_siena_sriov_probe(struct efx_nic *efx) > return; > > if (efx_siena_sriov_cmd(efx, false, &efx->vi_scale, &count)) { > - netif_info(efx, probe, efx->net_dev, "no SR-IOV VFs probed\n"); > + pci_info(efx->pci_dev, "no SR-IOV VFs probed\n"); > return; > } > if (count > 0 && count > max_vfs) > -- > 2.31.1