Received: by 2002:a5b:505:0:0:0:0:0 with SMTP id o5csp6921346ybp; Wed, 16 Oct 2019 00:41:01 -0700 (PDT) X-Google-Smtp-Source: APXvYqyKQEZPmhl/Is69utaEOLtruHvTY2CKaHcNkHAo1q8V26MpxoanWRzOJ+KT7D5Wm4hS+cou X-Received: by 2002:a17:906:4a8d:: with SMTP id x13mr37362085eju.317.1571211661854; Wed, 16 Oct 2019 00:41:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1571211661; cv=none; d=google.com; s=arc-20160816; b=Sud3if/2TUVBR45ZgOLDNeL51XtA2XA4LN8naeOyL5wUbuRTPuAuIjzZEPmExw+Kvb bMeZoqESOARaJ4YSv28/IHtHmj4w4Rj+B5eZq/TPUoCbQj+rwl3NhMRY+S7O5cD8ja3b XGL6KosYpHS+N4Ne6fCbCerrKjFaRmk5p7pDwxLF58B7Cm5z8IUg2+HJ1merm6Cw+rq1 2oJ4ZiDq/E5K7ZTPGH4epgFqv2HbCzR0puy8EuQbpFoDhJs9RHsbPZbWq/etFE291Fcp Wbjkj4RKxlj7EI+r5+ur3u41ZDKXSixuqk4eP1q8f/5qXr1HfREok/E8AESHZjVWndV+ 3MOg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:from:subject:cc:to:message-id:date; bh=Y64TsmBKPuunPu7Rlj162CJlfWQmLTE3G5s6rVt5jlM=; b=wiGKGogd8vxGuQ9C2SDRBE0c+Lj7S5Ln+zra3FWHZ6vIneC0OeXEV8zue2H0sGExvJ P2MLhrw0Y7miVA1LyFG8AYWMCJHvQLunBVFEP/y6kBoCEPmkmxr3AGuCdc+QbtTpE7IJ qtZ0+Tjeiu5TvWD+3nwShXDVBZeO3/N80QC+6Yrint4SYtQdmtfmC7k08OQhy9bLClja inKmms0CGMJarH14taAskdaLxyVT+POtmqkc7h4MpToFefaP/RrWgMWRey50SeyJWNYR ZIalPoIyp8jOwa1piRfwLccjqEADvq2iYI0WNrdgg9sKDpcu7criFFGaHG0wGm9cISXN uQHQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id ca7si14879120ejb.319.2019.10.16.00.40.37; Wed, 16 Oct 2019 00:41:01 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388085AbfJPAFD convert rfc822-to-8bit (ORCPT + 99 others); Tue, 15 Oct 2019 20:05:03 -0400 Received: from shards.monkeyblade.net ([23.128.96.9]:42048 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726530AbfJPAFD (ORCPT ); Tue, 15 Oct 2019 20:05:03 -0400 Received: from localhost (unknown [IPv6:2601:601:9f00:1e2::d71]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) (Authenticated sender: davem-davemloft) by shards.monkeyblade.net (Postfix) with ESMTPSA id 1160311F5F624; Tue, 15 Oct 2019 17:05:02 -0700 (PDT) Date: Tue, 15 Oct 2019 17:04:59 -0700 (PDT) Message-Id: <20191015.170459.2090609203514838368.davem@davemloft.net> To: jakub.kicinski@netronome.com Cc: scott.branden@broadcom.com, f.fainelli@gmail.com, netdev@vger.kernel.org, phil@raspberrypi.org, jonathan@raspberrypi.org, matthias.bgg@kernel.org, linux-rpi-kernel@lists.infradead.org, wahrenst@gmx.net, nsaenzjulienne@suse.de, opendmb@gmail.com, bcm-kernel-feedback-list@broadcom.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next v2] net: bcmgenet: Generate a random MAC if none is valid From: David Miller In-Reply-To: <20191015153955.2e602903@cakuba.netronome.com> References: <20191014212000.27712-1-f.fainelli@gmail.com> <20191015153955.2e602903@cakuba.netronome.com> X-Mailer: Mew version 6.8 on Emacs 26.1 Mime-Version: 1.0 Content-Type: Text/Plain; charset=iso-8859-1 Content-Transfer-Encoding: 8BIT X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Tue, 15 Oct 2019 17:05:02 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Jakub Kicinski Date: Tue, 15 Oct 2019 15:39:55 -0700 > On Tue, 15 Oct 2019 15:32:28 -0700, Scott Branden wrote: >> > @@ -3482,7 +3476,12 @@ static int bcmgenet_probe(struct platform_device *pdev) >> > >> > SET_NETDEV_DEV(dev, &pdev->dev); >> > dev_set_drvdata(&pdev->dev, dev); >> > - ether_addr_copy(dev->dev_addr, macaddr); >> > + if (IS_ERR_OR_NULL(macaddr) || !is_valid_ether_addr(macaddr)) { >> > + dev_warn(&pdev->dev, "using random Ethernet MAC\n"); >> >> I would still consider this warrants a dev_err as you should not be >> using the device with a random MAC address assigned to it.? But I'll >> leave it to the "experts" to decide on the print level here. > > FWIW I'd stick to warn for this message since this is no longer a hard > failure. Agreed.