Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 31 Jul 2015 15:54:35 +0000 (UTC)
From:      Andrew Turner <andrew@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r286134 - head/sys/arm64/arm64
Message-ID:  <201507311554.t6VFsZgi094815@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: andrew
Date: Fri Jul 31 15:54:34 2015
New Revision: 286134
URL: https://svnweb.freebsd.org/changeset/base/286134

Log:
  Try to put the CPU into a low power state if we failed to otherwise halt
  the system.
  
  Obtained from:	ABT Systems Ltd
  Sponsored by:	The FreeBSD Foundation

Modified:
  head/sys/arm64/arm64/machdep.c

Modified: head/sys/arm64/arm64/machdep.c
==============================================================================
--- head/sys/arm64/arm64/machdep.c	Fri Jul 31 15:32:32 2015	(r286133)
+++ head/sys/arm64/arm64/machdep.c	Fri Jul 31 15:54:34 2015	(r286134)
@@ -376,7 +376,11 @@ void
 cpu_halt(void)
 {
 
-	panic("ARM64TODO: cpu_halt");
+	/* We should have shutdown by now, if not enter a low power sleep */
+	intr_disable();
+	while (1) {
+		__asm __volatile("wfi");
+	}
 }
 
 /*



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