Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 14 Jan 2016 15:21:51 +0000 (UTC)
From:      Andrew Rybchenko <arybchik@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r293956 - stable/10/sys/dev/sfxge/common
Message-ID:  <201601141521.u0EFLph3042628@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: arybchik
Date: Thu Jan 14 15:21:51 2016
New Revision: 293956
URL: https://svnweb.freebsd.org/changeset/base/293956

Log:
  MFC r291925
  
  sfxge: fix name conflict with crc32_table from sys/crc32.h
  
  The header is not present on FreeBSD, but exists on OmniOS where sfxge
  common code is used as well.
  
  Reviewed by:    gnn
  Sponsored by:   Solarflare Communications, Inc.

Modified:
  stable/10/sys/dev/sfxge/common/efx_crc32.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/sfxge/common/efx_crc32.c
==============================================================================
--- stable/10/sys/dev/sfxge/common/efx_crc32.c	Thu Jan 14 15:16:24 2016	(r293955)
+++ stable/10/sys/dev/sfxge/common/efx_crc32.c	Thu Jan 14 15:21:51 2016	(r293956)
@@ -41,7 +41,7 @@ __FBSDID("$FreeBSD$");
  * with polynomial 0x04c11db7 (bit-reversed 0xedb88320)
  */
 
-static const uint32_t crc32_table[256] = {
+static const uint32_t efx_crc32_table[256] = {
     0x00000000, 0x77073096, 0xee0e612c, 0x990951ba,
     0x076dc419, 0x706af48f, 0xe963a535, 0x9e6495a3,
     0x0edb8832, 0x79dcb8a4, 0xe0d5e91e, 0x97d2d988,
@@ -120,7 +120,7 @@ efx_crc32_calculate(
 
 	for (index = 0; index < length; index++) {
 		uint32_t data = *(input++);
-		crc = (crc >> 8) ^ crc32_table[(crc ^ data) & 0xff];
+		crc = (crc >> 8) ^ efx_crc32_table[(crc ^ data) & 0xff];
 	}
 
 	return (crc);



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