From owner-svn-src-head@freebsd.org Fri Jun 22 20:45:41 2018 Return-Path: Delivered-To: svn-src-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 84BA01026CE0; Fri, 22 Jun 2018 20:45:41 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 37F4A80FC6; Fri, 22 Jun 2018 20:45:41 +0000 (UTC) (envelope-from ian@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 mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id F322325C38; Fri, 22 Jun 2018 20:45:40 +0000 (UTC) (envelope-from ian@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id w5MKje3u084918; Fri, 22 Jun 2018 20:45:40 GMT (envelope-from ian@FreeBSD.org) Received: (from ian@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id w5MKjePq084915; Fri, 22 Jun 2018 20:45:40 GMT (envelope-from ian@FreeBSD.org) Message-Id: <201806222045.w5MKjePq084915@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: ian set sender to ian@FreeBSD.org using -f From: Ian Lepore Date: Fri, 22 Jun 2018 20:45:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r335564 - in head/sys: dts/arm/overlays modules/dtb/rpi X-SVN-Group: head X-SVN-Commit-Author: ian X-SVN-Commit-Paths: in head/sys: dts/arm/overlays modules/dtb/rpi X-SVN-Commit-Revision: 335564 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.26 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, 22 Jun 2018 20:45:41 -0000 Author: ian Date: Fri Jun 22 20:45:40 2018 New Revision: 335564 URL: https://svnweb.freebsd.org/changeset/base/335564 Log: Add spigen(4) fdt data overlays for RPI-B, RPI-2. By adding spigen-rpi{2,-b}.dtso to fdt_overlays= in loader.conf, the fdt data will set up the correct pinmux and device nodes to create a spigen(4) device for each available chipselect pin. Submitted by: Bob Frazier Differential Revision: https://reviews.freebsd.org/D15067 Added: head/sys/dts/arm/overlays/spigen-rpi-b.dtso (contents, props changed) head/sys/dts/arm/overlays/spigen-rpi2.dtso (contents, props changed) Modified: head/sys/modules/dtb/rpi/Makefile Added: head/sys/dts/arm/overlays/spigen-rpi-b.dtso ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dts/arm/overlays/spigen-rpi-b.dtso Fri Jun 22 20:45:40 2018 (r335564) @@ -0,0 +1,29 @@ +/* $FreeBSD$ */ + +/dts-v1/; +/plugin/; + +/ { + compatible = "brcm,bcm2835"; +}; + +&{/soc/spi@7e204000} { + status = "okay"; + + spigen0: spigen0 { + compatible = "freebsd,spigen"; + reg = <0>; + status = "okay"; + }; + spigen1: spigen1 { + compatible = "freebsd,spigen"; + reg = <1>; + status = "okay"; + }; +}; + +&{/soc/gpio@7e200000/spi0_cs_pins} { + brcm,pins = <8 7>; + brcm,function = <4>; /* ALT0 */ +}; + Added: head/sys/dts/arm/overlays/spigen-rpi2.dtso ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/sys/dts/arm/overlays/spigen-rpi2.dtso Fri Jun 22 20:45:40 2018 (r335564) @@ -0,0 +1,37 @@ +/* $FreeBSD$ */ + +/dts-v1/; +/plugin/; + +/ { + compatible = "brcm,bcm2836"; +}; + +&{/soc/spi@7e204000} { + status = "okay"; + spigen0: spigen0 { + compatible = "freebsd,spigen"; + reg = <0>; + status = "okay"; + }; + spigen1: spigen1 { + compatible = "freebsd,spigen"; + reg = <1>; + status = "okay"; + }; + spigen2: spigen2 { + compatible = "freebsd,spigen"; + reg = <2>; + status = "okay"; + }; +}; + +&{/soc/gpio@7e200000/spi0_cs_pins} { + brcm,pins = <8 7 16>; + brcm,function = <4>; /* ALT0 */ +}; + +&{/soc/gpio@7e200000/spi0_gpio7} { + brcm,pins = <7 8 16 9 10 11>; +}; + Modified: head/sys/modules/dtb/rpi/Makefile ============================================================================== --- head/sys/modules/dtb/rpi/Makefile Fri Jun 22 20:27:40 2018 (r335563) +++ head/sys/modules/dtb/rpi/Makefile Fri Jun 22 20:45:40 2018 (r335564) @@ -2,6 +2,10 @@ # DTS files for the Raspberry Pi-B DTS=rpi.dts rpi2.dts +DTSO= \ + spigen-rpi-b.dtso \ + spigen-rpi2.dtso \ + LINKS= \ ${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b.dtb \ ${DTBDIR}/rpi.dtb ${DTBDIR}/bcm2835-rpi-b-rev2.dtb \