Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp898343pxb; Tue, 19 Oct 2021 15:42:48 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyt2kWd6h7Cu1driwFqN5BjtXqHRDNz+3QgPTRjey8vxJg9ElHQkGCHxhzcfLEaEa4jqiWi X-Received: by 2002:a63:101c:: with SMTP id f28mr30534778pgl.330.1634683368172; Tue, 19 Oct 2021 15:42:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634683368; cv=none; d=google.com; s=arc-20160816; b=fPzsTxW3PwgTbyzuC4s0w5ogx9xUgfR07/dpo7ZruPszgzMV3SBTBapfRxU1bnPAuJ PN1XRmFsABmL+M4ZjPhPD5UECtwwRHSPDm2cuEJblFXoV4FKmNxqyO6gzJWR8ZKF2+Q8 cGC60YymLwtVunvUgu5g22g2FvZ1+CmqEnfa+PedDi/vgukbwfPosnDtM4JM4fGlDKmi cUX8OVqEw/Kd4oJwXRFqQLtB9pMbJD6NNQCO8qyTdnZV4tU7bj+wJk35RkCZy5LEyuGy j7J++XKJLUTBANHRZvoc+udsVmFz7RSiaLk9a03Fq+Dy++ORlCHupZ4EtOzVdIgjd9XK w/Ow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=d9wXTaAe8EZKUW9RoLamxl/gBzPnIjD8BEMLKwjF/+s=; b=Te96moom3Tt66q9IhH8KJvC0sx9KYCqqSdBJ/e+1qlXASR9cR4FunY2ly7mckRQPit Qqm30+S/Zn1QAxVr8CpxNMSYIJQ2W9aV6PzbnlAmUrg6+b4FP3ny8kF9biCZHjLncsRY /ZG0aB+uay88AKvCjPuQhqS36EVT+7iV7asf2ebwT7ZkkvTqLG6mOF/9kocct5Jj7BQz qwnoHMk1c7s2roePolEOODHf3Ni1UL58fYztjqZ1MYD/pxPkiUJo+UJsV1qr/L1swWNa uIxm+hlgl5olL2O9CfhYMP0Ai+nGnWHG9GWtn+LcqotN637XyIsS/zvelQFGvp88M37m P4Ug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kryo-se.20210112.gappssmtp.com header.s=20210112 header.b=Dv20iBPZ; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a12si460433pfh.148.2021.10.19.15.42.35; Tue, 19 Oct 2021 15:42:48 -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=@kryo-se.20210112.gappssmtp.com header.s=20210112 header.b=Dv20iBPZ; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229734AbhJSWmq (ORCPT + 99 others); Tue, 19 Oct 2021 18:42:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36026 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229632AbhJSWmq (ORCPT ); Tue, 19 Oct 2021 18:42:46 -0400 Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 98894C06161C for ; Tue, 19 Oct 2021 15:40:32 -0700 (PDT) Received: by mail-wm1-x333.google.com with SMTP id y74-20020a1c7d4d000000b00322f53b9bbfso6065935wmc.3 for ; Tue, 19 Oct 2021 15:40:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kryo-se.20210112.gappssmtp.com; s=20210112; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=d9wXTaAe8EZKUW9RoLamxl/gBzPnIjD8BEMLKwjF/+s=; b=Dv20iBPZdh24X6XR+0eFfH0JEwtZTNuZ3ZPlJbmppMhERHlI7RIY2VwuwoHxGIoNjs G7IsDZHlTlNNryQz7VT1AFQdt0kPpCJ5wOjqCH44TeqnqXn5kN+s/dlHaIj/+xUALFF/ /eYcF5nOJOtkFbUqtGCK3ZZm6h9assN8dAY1bfSoknVzieW4GnaxnFe98QSTxPtm3RRK bd+Anmoh4gKHKTQdx49iYF1lMZswRhr6nk7bUuAf7jcZapyTqOa3NtgMM3OpFhIPQ/P2 YqS2I9F+Ap3AU4thNA5KclHaxmphwDDfAuMfNKlbC7UgYRx0OA1heGhswrF7Er0STuHF bmoQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=d9wXTaAe8EZKUW9RoLamxl/gBzPnIjD8BEMLKwjF/+s=; b=2XyH5iZNzKWO5eCF99QO5TQDKSQjeLG3fXSdh7Bm0VGykTyeeBiypCrTjsOuGS4c3/ aF4kkC6ArUTt8b21Wvjpnp9xyztvX+XWWcp4oHbOWlYpveGG+Y5gK8cpC8HKXCi17bDR Oe0XZZWY6Q3fu2EdOoloWphhp9lztuf/OdXmjoOq102IALwrR3Ee/IYZa5AiTkxCl7lW poDSZEukGuhj3iJm3GBkGVVe8dg1KzEMh3Clx3Pew4jgtXh8nK1/UNe8Tnj/UE8jU8UF dgX3mG7iCpS90WWGbFwqVFcV/OQmXQjfRfyPSRbMiFvzM0zPafL/R2Pam+HGKzyekjO5 R1rg== X-Gm-Message-State: AOAM532+kUOmL+JPCAt3iX8922vC//hL3Y3IY15RFKEILZxQFmgeHbds 0WbxiDrgAA7tqfsnHR/u+IvdlA== X-Received: by 2002:adf:bbc2:: with SMTP id z2mr48382667wrg.359.1634683230721; Tue, 19 Oct 2021 15:40:30 -0700 (PDT) Received: from kerfuffle.. ([2a02:168:9619:0:e47f:e8d:2259:ad13]) by smtp.gmail.com with ESMTPSA id r5sm3270300wmh.28.2021.10.19.15.40.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Oct 2021 15:40:30 -0700 (PDT) From: Erik Ekman To: Edward Cree , Martin Habets , "David S. Miller" , Jakub Kicinski Cc: Erik Ekman , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH] sfc: Don't use netif_info before net_device setup Date: Wed, 20 Oct 2021 00:40:16 +0200 Message-Id: <20211019224016.26530-1-erik@kryo.se> X-Mailer: git-send-email 2.31.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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 --- 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