Author: jhibbits
Date: Sun Aug 14 04:11:36 2016
New Revision: 304069
URL: https://svnweb.freebsd.org/changeset/base/304069

Log:
  Return 0 instead of an error code on failure to find dcsr.
  
  mpc85xx_map_dcsr() returns a vm_offset_t, not an error code.
  mpc85xx_fix_errata() will gracefully exit if mpc85xx_map_dcsr() returns 0, as
  that indicates an error (NULL pointer).

Modified:
  head/sys/powerpc/mpc85xx/mpc85xx.c

Modified: head/sys/powerpc/mpc85xx/mpc85xx.c
==============================================================================
--- head/sys/powerpc/mpc85xx/mpc85xx.c  Sun Aug 14 03:49:37 2016        
(r304068)
+++ head/sys/powerpc/mpc85xx/mpc85xx.c  Sun Aug 14 04:11:36 2016        
(r304069)
@@ -358,10 +358,10 @@ mpc85xx_map_dcsr(void)
         * Find the node the long way.
         */
        if ((node = OF_finddevice("/")) == -1)
-               return (ENXIO);
+               return (0);
 
        if ((node = ofw_bus_find_compatible(node, "fsl,dcsr")) == 0)
-               return (ENXIO);
+               return (0);
 
 moveon:
        err = fdt_get_range(node, 0, &b, &s);
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to