From owner-freebsd-arm@freebsd.org Thu Jun 27 01:13:54 2019 Return-Path: Delivered-To: freebsd-arm@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 C16B315D6FE8 for ; Thu, 27 Jun 2019 01:13:54 +0000 (UTC) (envelope-from kayasaman@optiplex-networks.com) Received: from x-ray.optiplex-networks.com (mail.optiplex-networks.com [212.159.80.20]) (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 8ED558F510 for ; Thu, 27 Jun 2019 01:13:53 +0000 (UTC) (envelope-from kayasaman@optiplex-networks.com) Received: from localhost (localhost [127.0.0.1]) by x-ray.optiplex-networks.com (Postfix) with ESMTP id 653FD72C7A3 for ; Thu, 27 Jun 2019 02:13:49 +0100 (BST) Received: from x-ray.optiplex-networks.com ([127.0.0.1]) by localhost (x-ray.optiplex-networks.com [127.0.0.1]) (amavisd-new, port 10032) with ESMTP id 9er6mtvT57w0 for ; Thu, 27 Jun 2019 02:13:48 +0100 (BST) Received: from localhost (localhost [127.0.0.1]) by x-ray.optiplex-networks.com (Postfix) with ESMTP id DFA7B72C800 for ; Thu, 27 Jun 2019 02:13:48 +0100 (BST) X-Virus-Scanned: amavisd-new at x-ray.optiplex-networks.com Received: from x-ray.optiplex-networks.com ([127.0.0.1]) by localhost (x-ray.optiplex-networks.com [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id pwo9xS5R4C2F for ; Thu, 27 Jun 2019 02:13:48 +0100 (BST) Received: from x220.optiplex-networks.com (unknown [192.168.0.192]) by x-ray.optiplex-networks.com (Postfix) with ESMTPSA id C96E572C7A3 for ; Thu, 27 Jun 2019 02:13:48 +0100 (BST) Subject: Re: Pine64-LTS and UART ports To: freebsd-arm@freebsd.org References: <371fe0f0-9f91-e4ba-ff4e-8338fe9d63de@optiplex-networks.com> <20190623235732.4439b707@zeta.dino.sk> <20190624133017.5a9689b7@zeta.dino.sk> <62ba1a30-25bc-af65-beb2-0e05dfc76c79@optiplex-networks.com> <20190624164512.0ea5c4d3@zeta.dino.sk> <75d6afff-8d83-57da-0a13-a4977d12cb87@optiplex-networks.com> <20190624204216.GK2903@eldorado> <20aea57b-1ac5-15e9-ab2b-7230b81b8378@optiplex-networks.com> <20190624210245.GL2903@eldorado> <20190625082724.eb46a97c0c708f5dd033405e@bidouilliste.com> <2a5fea7a-add1-99e2-262e-7ee025679eca@optiplex-networks.com> From: Kaya Saman Message-ID: <898bc9b4-67ff-b8b2-1431-9721f48fe9a1@optiplex-networks.com> Date: Thu, 27 Jun 2019 02:13:48 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.7.1 MIME-Version: 1.0 In-Reply-To: <2a5fea7a-add1-99e2-262e-7ee025679eca@optiplex-networks.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Rspamd-Queue-Id: 8ED558F510 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; spf=pass (mx1.freebsd.org: domain of kayasaman@optiplex-networks.com designates 212.159.80.20 as permitted sender) smtp.mailfrom=kayasaman@optiplex-networks.com X-Spamd-Result: default: False [-6.91 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; RCVD_COUNT_FIVE(0.00)[6]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx]; TO_MATCH_ENVRCPT_ALL(0.00)[]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-arm@freebsd.org]; TO_DN_NONE(0.00)[]; RCPT_COUNT_ONE(0.00)[1]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; RCVD_TLS_LAST(0.00)[]; MX_GOOD(-0.01)[mail.optiplex-networks.com]; NEURAL_HAM_SHORT(-1.00)[-0.998,0]; DMARC_NA(0.00)[optiplex-networks.com]; IP_SCORE(-3.60)[ip: (-9.53), ipnet: 212.159.64.0/18(-4.77), asn: 6871(-3.64), country: GB(-0.09)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:6871, ipnet:212.159.64.0/18, country:GB]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 27 Jun 2019 01:13:55 -0000 On 6/25/19 4:24 PM, Kaya Saman wrote: > > On 6/25/19 7:27 AM, Emmanuel Vadot wrote: >> On Mon, 24 Jun 2019 22:14:15 +0100 >> Kaya Saman wrote: >> >>> On 6/24/19 10:02 PM, Sergey Manucharian wrote: >>>> Excerpts from Kaya Saman's message from Mon 24-Jun-19 21:58: >>>> [snip] >> =C2=A0 DTS and DTSO needs to be pre-processed by cpp as they use #incl= ude >> directives, you can have a look at sys/tools/fdt/make_dtb.sh and >> make_dtbo.sh >> =C2=A0 If you modify the DTS simply running make buildkernel will comp= ile the >> new one, just make sure to put it on the FAT32 partition in >> dts/allwinner as we need it loaded by u-boot and it can't read ufs. >> > > Thanks Emmanuel! > > > I ran: make=C2=A0 -j4 buildkernel KERNCONF=3DPPSGENERIC > > > Then installed with: make installkernel KERNCONF=3DPPSGENERIC > > > The sun50i-a64-pine64.dts has the modification already suggested: > > > /* On Pi-2 connector */ > &uart2 { > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 pinctrl-names =3D "default"; > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 pinctrl-0 =3D <&uart2_pins>; > =C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0 status =3D "okay"; > }; > > > Running: ls -l /boot/dtb/allwinner/ > total 140 > -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 19976 Jun 25 16:11 sun50i-a64= -nanopi-a64.dtb > -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20528 Jun 25 16:11 sun50i-a64= -olinuxino.dtb > -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20677 Jun 25 16:11 sun50i-a64= -pine64-plus.dtb > -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20603 Jun 25 16:11 sun50i-a64= -pine64.dtb > -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20585 Jun 25 16:11=20 > sun50i-a64-sopine-baseboard.dtb > -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 23227 Jun 25 16:11 sun50i-h5-= orangepi-pc2.dtb > > > The dtb files have been created and installed by the 'installkernel'=20 > command. > > > Unfortunately though nothing shows up in dmesg or /dev again outside=20 > of the standard uart0? > > > dmesg |grep uart > uart0: <16750 or compatible> mem 0x1c28000-0x1c283ff irq 23 on simplebu= s0 > uart0: console (115384,n,8,1) > > > Is there an additional step which needs to be done to get this to work? > > > Regards, > > > Kaya I found the FAT32 partition that Emmanuel mentioned: " just make sure to put it on the FAT32 partition in dts/allwinner as we need it loaded by u-boot and it can't read ufs." So after copying the overlays and allwinner files to=20 /boot/msdos/dtb/overlays and /boot/msdos/dtb/allwinner I have at least=20 some error messages: Booting [/boot/kernel/kernel]... Using DTB provided by EFI at 0x47ef8000. Loading DTB overlays:=20 'sun50i-a64-sid,sun50i-a64-ths,sun50i-a64-timer,sun50i-a64-uart2,sun50i-a= 64-uart4' /boot/dtb/overlays/sun50i-a64-sid.dtbo size=3D0x1fd /boot/dtb/overlays/sun50i-a64-ths.dtbo size=3D0x3e8 /boot/dtb/overlays/sun50i-a64-timer.dtbo size=3D0x175 /boot/dtb/overlays/sun50i-a64-uart2.dtbo size=3D0x123 /boot/dtb/overlays/sun50i-a64-uart4.dtbo size=3D0x123 applying DTB overlay '/boot/dtb/overlays/sun50i-a64-sid.dtbo' applying DTB overlay '/boot/dtb/overlays/sun50i-a64-ths.dtbo' failed to apply overlay: FDT_ERR_NOTFOUND applying DTB overlay '/boot/dtb/overlays/sun50i-a64-timer.dtbo' applying DTB overlay '/boot/dtb/overlays/sun50i-a64-uart2.dtbo' failed to apply overlay: FDT_ERR_NOTFOUND applying DTB overlay '/boot/dtb/overlays/sun50i-a64-uart4.dtbo' failed to apply overlay: FDT_ERR_NOTFOUND EHCI failed to shut down host controller. ---<>--- The file list: ls -l=C2=A0 /boot/msdos/dtb/allwinner total 140 -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 19976 Dec=C2=A0 7=C2=A0 2018 su= n50i-a64-nanopi-a64.dtb -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 20528 Dec=C2=A0 7=C2=A0 2018 su= n50i-a64-olinuxino.dtb -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 20685 Dec=C2=A0 7=C2=A0 2018 su= n50i-a64-pine64-plus.dtb -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 20603 Jun 27 01:54 sun50i-a64-p= ine64.dtb -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 20585 Dec=C2=A0 7=C2=A0 2018=20 sun50i-a64-sopine-baseboard.dtb -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 23227 Dec=C2=A0 7=C2=A0 2018 su= n50i-h5-orangepi-pc2.dtb ls -l /boot/msdos/dtb/overlays/ total 20 -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 509 Dec=C2=A0 7=C2=A0 201= 8 sun50i-a64-sid.dtbo -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0 1000 Dec=C2=A0 7=C2=A0 2018 sun= 50i-a64-ths.dtbo -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 373 Dec=C2=A0 7=C2=A0 201= 8 sun50i-a64-timer.dtbo -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 291 Jun 27 01:50 sun50i-a= 64-uart2.dtbo -rwxr-xr-x=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 291 Jun 27 01:50 sun50i-a= 64-uart4.dtbo ls -l /boot/dtb/allwinner total 140 -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 19976 Jun 25 16:11 sun50i-a64-n= anopi-a64.dtb -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20528 Jun 25 16:11 sun50i-a64-o= linuxino.dtb -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20677 Jun 25 16:11 sun50i-a64-p= ine64-plus.dtb -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20603 Jun 25 16:11 sun50i-a64-p= ine64.dtb -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 20585 Jun 25 16:11=20 sun50i-a64-sopine-baseboard.dtb -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 23227 Jun 25 16:11 sun50i-h5-or= angepi-pc2.dtb ls -l /boot/dtb/overlays total 20 -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 509 Jun 25 16:11 sun50i-a= 64-sid.dtbo -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0 1000 Jun 25 16:11 sun50i-a64-th= s.dtbo -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 373 Jun 25 16:11 sun50i-a= 64-timer.dtbo -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 291 Jun 24 21:40 sun50i-a= 64-uart2.dtbo -r--r--r--=C2=A0 1 root=C2=A0 wheel=C2=A0=C2=A0 291 Jun 24 21:12 sun50i-a= 64-uart4.dtbo Even with uart2 and uart4 enabled in: sun50i-a64-pine64.dtb I still=20 don't see anything outside of uart0 under dmesg. What else could I try at this stage? Regards, Kaya