Author: emaste
Date: Thu Oct 13 17:16:32 2016
New Revision: 307225
URL: https://svnweb.freebsd.org/changeset/base/307225

Log:
  Fix octeon model comparison in Cavium SDK
  
  buildkernel failed with GCC 5.3 with
  error: comparison of constant '852736' with boolean expression is always true
  
  Sponsored by: The FreeBSD Foundation

Modified:
  head/sys/contrib/octeon-sdk/cvmx-pcie.c

Modified: head/sys/contrib/octeon-sdk/cvmx-pcie.c
==============================================================================
--- head/sys/contrib/octeon-sdk/cvmx-pcie.c     Thu Oct 13 17:03:54 2016        
(r307224)
+++ head/sys/contrib/octeon-sdk/cvmx-pcie.c     Thu Oct 13 17:16:32 2016        
(r307225)
@@ -981,7 +981,7 @@ static int __cvmx_pcie_rc_initialize_gen
 
     /* Make sure we aren't trying to setup a target mode interface in host 
mode */
     mio_rst_ctl.u64 = cvmx_read_csr(CVMX_MIO_RST_CTLX(pcie_port));
-    ep_mode = (OCTEON_IS_MODEL(OCTEON_CN61XX || 
OCTEON_IS_MODEL(OCTEON_CNF71XX)) ? (mio_rst_ctl.s.prtmode != 1) : 
(!mio_rst_ctl.s.host_mode));
+    ep_mode = ((OCTEON_IS_MODEL(OCTEON_CN61XX) || 
OCTEON_IS_MODEL(OCTEON_CNF71XX)) ? (mio_rst_ctl.s.prtmode != 1) : 
(!mio_rst_ctl.s.host_mode));
     if (ep_mode)
     {
         cvmx_dprintf("PCIe: Port %d in endpoint mode.\n", pcie_port);
_______________________________________________
svn-src-head@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-head
To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"

Reply via email to