Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 25 Oct 2013 11:44:39 +0000 (UTC)
From:      Aleksandr Rybalko <ray@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r257111 - head/sys/dev/uart
Message-ID:  <201310251144.r9PBidEj036470@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ray
Date: Fri Oct 25 11:44:39 2013
New Revision: 257111
URL: http://svnweb.freebsd.org/changeset/base/257111

Log:
  Test UARTs physical address instead of virtual.

Modified:
  head/sys/dev/uart/uart_cpu_fdt.c

Modified: head/sys/dev/uart/uart_cpu_fdt.c
==============================================================================
--- head/sys/dev/uart/uart_cpu_fdt.c	Fri Oct 25 10:20:19 2013	(r257110)
+++ head/sys/dev/uart/uart_cpu_fdt.c	Fri Oct 25 11:44:39 2013	(r257111)
@@ -86,7 +86,13 @@ int
 uart_cpu_eqres(struct uart_bas *b1, struct uart_bas *b2)
 {
 
-	return ((b1->bsh == b2->bsh && b1->bst == b2->bst) ? 1 : 0);
+	if (b1->bst != b2->bst)
+		return (0);
+	if (pmap_kextract(b1->bsh) == 0)
+		return (0);
+	if (pmap_kextract(b2->bsh) == 0)
+		return (0);
+	return ((pmap_kextract(b1->bsh) == pmap_kextract(b2->bsh)) ? 1 : 0);
 }
 
 int



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