Date: Tue, 23 Feb 2016 03:34:36 +0000 (UTC) From: Ian Lepore <ian@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r295911 - head/sys/dev/uart Message-ID: <201602230334.u1N3YaxK021317@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ian Date: Tue Feb 23 03:34:36 2016 New Revision: 295911 URL: https://svnweb.freebsd.org/changeset/base/295911 Log: Stop using the global fdtbus_bs_tag and instead use the tag from the softc that was set up properly at init time. Modified: head/sys/dev/uart/uart_dev_lpc.c Modified: head/sys/dev/uart/uart_dev_lpc.c ============================================================================== --- head/sys/dev/uart/uart_dev_lpc.c Tue Feb 23 03:01:46 2016 (r295910) +++ head/sys/dev/uart/uart_dev_lpc.c Tue Feb 23 03:34:36 2016 (r295911) @@ -32,7 +32,6 @@ __FBSDID("$FreeBSD$"); #include <sys/bus.h> #include <sys/conf.h> #include <machine/bus.h> -#include <machine/fdt.h> #include <dev/uart/uart.h> #include <dev/uart/uart_cpu.h> @@ -49,9 +48,9 @@ __FBSDID("$FreeBSD$"); static bus_space_handle_t bsh_clkpwr; #define lpc_ns8250_get_clkreg(_bas, _reg) \ - bus_space_read_4(fdtbus_bs_tag, bsh_clkpwr, (_reg)) + bus_space_read_4((_bas)->bst, bsh_clkpwr, (_reg)) #define lpc_ns8250_set_clkreg(_bas, _reg, _val) \ - bus_space_write_4(fdtbus_bs_tag, bsh_clkpwr, (_reg), (_val)) + bus_space_write_4((_bas)->bst, bsh_clkpwr, (_reg), (_val)) /* * Clear pending interrupts. THRE is cleared by reading IIR. Data @@ -292,7 +291,7 @@ lpc_ns8250_init(struct uart_bas *bas, in u_long clkmode; /* Enable UART clock */ - bus_space_map(fdtbus_bs_tag, LPC_CLKPWR_PHYS_BASE, LPC_CLKPWR_SIZE, 0, + bus_space_map(bas->bst, LPC_CLKPWR_PHYS_BASE, LPC_CLKPWR_SIZE, 0, &bsh_clkpwr); clkmode = lpc_ns8250_get_clkreg(bas, LPC_UART_CLKMODE); lpc_ns8250_set_clkreg(bas, LPC_UART_CLKMODE, clkmode |
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201602230334.u1N3YaxK021317>