From owner-freebsd-arm@freebsd.org Mon Jul 25 16:45:20 2016 Return-Path: Delivered-To: freebsd-arm@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 A80A7BA464B for ; Mon, 25 Jul 2016 16:45:20 +0000 (UTC) (envelope-from thomasskibo@yahoo.com) Received: from nm39-vm8.bullet.mail.bf1.yahoo.com (nm39-vm8.bullet.mail.bf1.yahoo.com [72.30.239.152]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 60E4B17C2 for ; Mon, 25 Jul 2016 16:45:19 +0000 (UTC) (envelope-from thomasskibo@yahoo.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1469464946; bh=RODsG6RT9e5EiViZey5fb769g+k8Ux78eR1UpgkdVTA=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From:Subject; b=LPWWQ/Lr/+vERRc7om5rlfVfasMngyNdgggCB/u1WxiDVGjH16oIkV0z13WR6LkaHiK4QZ4HdIHhWSXJCsrVwLg7wQ5K6GJfUpOSNiY9oJ58VGuFTAP021TZ7ztmzj5X0V4SpdKCZuJbe0v3uYixRjDeMy/NCAhHc2RhiDJ3d5nxkNMZEMa08zjFch6SgqozOtaIlE1aTFiq+GII3GKpdpFCUN9MEJiDgik5K6q3m8BSiYI9QxhZfrdc6QrIslAEjt87qFqn4zYO53dScp8l2HHKe1TOIf9AtVoOsXJmfIKoG78EQYFk/DMCjpL4XmcIAhfJK8CaJ9qx1MrJxPTaJw== Received: from [98.139.215.141] by nm39.bullet.mail.bf1.yahoo.com with NNFMP; 25 Jul 2016 16:42:26 -0000 Received: from [98.139.211.203] by tm12.bullet.mail.bf1.yahoo.com with NNFMP; 25 Jul 2016 16:42:26 -0000 Received: from [127.0.0.1] by smtp212.mail.bf1.yahoo.com with NNFMP; 25 Jul 2016 16:42:26 -0000 X-Yahoo-Newman-Id: 868352.13010.bm@smtp212.mail.bf1.yahoo.com X-Yahoo-Newman-Property: ymail-3 X-YMail-OSG: fVTltIgVM1nt1KnivCVIS3wMgJ5T_8nrCMd7Hal6BF03hBv xgSRducQIlOOWLSfxtfzB6sVyVJ4EC4vUk8ppNLVjEC7__qtgor8lM2vbiIX KNcyEhXQUqp6AgEChVcN42iOFDSVyFPjsyWyCFnp2m68sYhOeIW3e7zC1MUM A7jWTjHMDAZOmnf1lS2pAafdlaCEePZ3Byhd9qiOqKgPRXVqrZEp06V2kfIN Z0siV.HZpF0se75G9ChxoFKPUBAOYPOnwEaiycTNwXrd7tXXGiNjoQCofQJG JwOadLb33ewwAiouAtP5UVFR6yziLUVXo7S7.9qS0vOV9H_9Bzrq9fhtBHEv z59PcuY5Oo.VlIZyTwHRy6RcHb4P7mgzuCJ_AIs6XbhGCZF_updCEE7rV9w_ gc04DdWexRiHX9Vs0sGaxIiAnr8Hl9x4hJ4DBAcIvdyG5T8Gb1uu7v_KGbph oreAF8TEjYCmkzQIovAhutKduuN.uh_jxEMY42q70SepXDoukEX07z1s3a8u CsKDi4oMYqw_TQLbGV7jQvLZo_OkCDqpsSvCo3Uo6rZUNEt04p5wVW6Cq42c YWLiWD33o X-Yahoo-SMTP: .8Dytk6swBAeTUTcf.ezO8BKaYfn.mUV Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 9.3 \(3124\)) Subject: Re: Questions about writing custom boot loader, Zynq, Zybo From: Thomas Skibo In-Reply-To: Date: Mon, 25 Jul 2016 09:42:24 -0700 Cc: freebsd-arm Content-Transfer-Encoding: quoted-printable Message-Id: References: To: Lee D X-Mailer: Apple Mail (2.3124) X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 25 Jul 2016 16:45:20 -0000 > On Jul 24, 2016, at 3:25 PM, Lee D wrote: >=20 > Thanks for the tips. The RS232 issue was simple. Xilinx (or possibly = Digilent) changed the default clock for the serial port from 50MHz to = 100MHz. I made the correction in the DTS file and now the baud rate is = correct. I hadn=E2=80=99t noticed they changed it. My u-boot still uses the = 50Mhz so it matches the DTS file. What really ought to happen is the slcr driver should determine the = frequency of all the clocks derived from ps_clk so the only thing the = DTS file needs to provide is the ps_clk frequency. I=E2=80=99ll have to = do that anyway if we move over to using GNU DTS files. >=20 > Do you know if passing a boot params structure in R0 is necessary for = the kernel to boot? =20 >=20 > I still can't seem to get past that timer message. This is what I've = done: >=20 > 1. Made sure I am working with a bare default Zybo config generated in = Vivado 2016.2 >=20 > 2. compared my ps_init.[ch] to the one you pointed me to. There were = no significant differences except for the RS232 clock rate. I had some = MIO pins configured, and my DRAM timings were different. my DRAM works = fine with standalone apps so I assume that was a tweak made by Digilent = and not an issue. >=20 > 3. added printf's to inittimecounter() in src/sys/kern/kern_tc.c. It = is clear that it completes normally. Also the timer appears to be = running. =20 >=20 > However that function is part of the kernel init sequence (SYSINIT = macro), so I don't know what is getting called next.=20 >=20 > 4. I removed the ehci device from the DTS, and commented out all USB = related entries in the zybo kernel config file. Still it freezes after = that timer message. So probably not USB related. >=20 > 5. Checked to make sure that the USB3320 chip is not being held in = reset by the GPIO line. >=20 > My next steps are: >=20 > 1. keep digging through the kernel and placing printfs to pinpoint = where it is failing. >=20 > 2. try the ps_init.[ch] files you showed me in my project, even though = they shouldn't make any difference. >=20 > 3. try passing a boot params structure in r0.=20 >=20 > Thanks again for pointing me to the original ps_init files, that was = very helpful to be able to see those. >=20 > Lee >=20 =E2=80=94=E2=80=94 Thomas Skibo thomasskibo@yahoo.com