Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 26 Jun 2014 17:03:08 +0000 (UTC)
From:      "Bjoern A. Zeeb" <bz@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r267919 - head/sys/dev/netfpga10g/nf10bmac
Message-ID:  <201406261703.s5QH387o098273@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bz
Date: Thu Jun 26 17:03:08 2014
New Revision: 267919
URL: http://svnweb.freebsd.org/changeset/base/267919

Log:
  Rather than using a constant use sizeof(val) allowing for the length
  to automatically change as we switch between 32/64bit.
  
  MFC after:	2 weeks

Modified:
  head/sys/dev/netfpga10g/nf10bmac/if_nf10bmac.c

Modified: head/sys/dev/netfpga10g/nf10bmac/if_nf10bmac.c
==============================================================================
--- head/sys/dev/netfpga10g/nf10bmac/if_nf10bmac.c	Thu Jun 26 16:49:45 2014	(r267918)
+++ head/sys/dev/netfpga10g/nf10bmac/if_nf10bmac.c	Thu Jun 26 17:03:08 2014	(r267919)
@@ -229,7 +229,7 @@ nf10bmac_tx_locked(struct nf10bmac_softc
 				int sl;
 
 				if (l == (ml - 1))
-					len = 4;
+					len = sizeof(val);
 				cl = len;
 
 				for (s = 0, sl = len; sl > 0; sl--)



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