From owner-svn-src-head@freebsd.org Fri Dec 8 10:05:25 2017 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2F3BAE9FF48; Fri, 8 Dec 2017 10:05:25 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id ED6ED6BB55; Fri, 8 Dec 2017 10:05:24 +0000 (UTC) (envelope-from andrew@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id vB8A5OpU047235; Fri, 8 Dec 2017 10:05:24 GMT (envelope-from andrew@FreeBSD.org) Received: (from andrew@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id vB8A5OV7047234; Fri, 8 Dec 2017 10:05:24 GMT (envelope-from andrew@FreeBSD.org) Message-Id: <201712081005.vB8A5OV7047234@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: andrew set sender to andrew@FreeBSD.org using -f From: Andrew Turner Date: Fri, 8 Dec 2017 10:05:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r326683 - head/sys/dev/uart X-SVN-Group: head X-SVN-Commit-Author: andrew X-SVN-Commit-Paths: head/sys/dev/uart X-SVN-Commit-Revision: 326683 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Dec 2017 10:05:25 -0000 Author: andrew Date: Fri Dec 8 10:05:23 2017 New Revision: 326683 URL: https://svnweb.freebsd.org/changeset/base/326683 Log: Set the io width when using an ACPI uart. Previously it would only ever be set when finding the uart from the device tree. Sponsored by: DARPA, AFRL Modified: head/sys/dev/uart/uart_cpu_arm64.c Modified: head/sys/dev/uart/uart_cpu_arm64.c ============================================================================== --- head/sys/dev/uart/uart_cpu_arm64.c Fri Dec 8 08:16:36 2017 (r326682) +++ head/sys/dev/uart/uart_cpu_arm64.c Fri Dec 8 10:05:23 2017 (r326683) @@ -100,7 +100,8 @@ uart_cpu_acpi_scan(uint8_t interface_type) static int uart_cpu_acpi_probe(struct uart_class **classp, bus_space_tag_t *bst, - bus_space_handle_t *bsh, int *baud, u_int *rclk, u_int *shiftp) + bus_space_handle_t *bsh, int *baud, u_int *rclk, u_int *shiftp, + u_int *iowidthp) { struct acpi_uart_compat_data *cd; ACPI_TABLE_SPCR *spcr; @@ -142,6 +143,7 @@ uart_cpu_acpi_probe(struct uart_class **classp, bus_sp *classp = cd->clas; *rclk = 0; *shiftp = 2; + *iowidthp = spcr->SerialPort.BitWidth / 8; out: acpi_unmap_table(spcr); @@ -169,7 +171,8 @@ uart_cpu_getdev(int devtype, struct uart_devinfo *di) err = ENXIO; #ifdef DEV_ACPI - err = uart_cpu_acpi_probe(&class, &bst, &bsh, &br, &rclk, &shift); + err = uart_cpu_acpi_probe(&class, &bst, &bsh, &br, &rclk, &shift, + &iowidth); #endif #ifdef FDT if (err != 0) {