Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 Nov 2018 07:06:24 +0000 (UTC)
From:      Andrew Rybchenko <arybchik@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r341301 - head/sys/dev/sfxge/common
Message-ID:  <201811300706.wAU76Ob1082338@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: arybchik
Date: Fri Nov 30 07:06:24 2018
New Revision: 341301
URL: https://svnweb.freebsd.org/changeset/base/341301

Log:
  sfxge(4): prevent access to the NIC config before probe
  
  NIC config is initialized during NIC probe.
  
  Submitted by:   Mark Spender <mspender at solarflare.com>
  Sponsored by:   Solarflare Communications, Inc.
  MFC after:      1 week
  Differential Revision:  https://reviews.freebsd.org/D18263

Modified:
  head/sys/dev/sfxge/common/efx_nic.c

Modified: head/sys/dev/sfxge/common/efx_nic.c
==============================================================================
--- head/sys/dev/sfxge/common/efx_nic.c	Fri Nov 30 07:06:13 2018	(r341300)
+++ head/sys/dev/sfxge/common/efx_nic.c	Fri Nov 30 07:06:24 2018	(r341301)
@@ -624,6 +624,7 @@ efx_nic_cfg_get(
 	__in		efx_nic_t *enp)
 {
 	EFSYS_ASSERT3U(enp->en_magic, ==, EFX_NIC_MAGIC);
+	EFSYS_ASSERT3U(enp->en_mod_flags, &, EFX_MOD_PROBE);
 
 	return (&(enp->en_nic_cfg));
 }



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201811300706.wAU76Ob1082338>