From owner-freebsd-arm@freebsd.org Wed Sep 28 21:54:31 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 1B124C0124B for ; Wed, 28 Sep 2016 21:54:31 +0000 (UTC) (envelope-from gonzo@id.bluezbox.com) Received: from id.bluezbox.com (id.bluezbox.com [45.55.20.155]) (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 F20002D7 for ; Wed, 28 Sep 2016 21:54:30 +0000 (UTC) (envelope-from gonzo@id.bluezbox.com) Received: from [208.184.220.60] (helo=limiting-factor.dolby.net) by id.bluezbox.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256) (Exim 4.86_2 (FreeBSD)) (envelope-from ) id 1bpMo8-000Kaa-5F; Wed, 28 Sep 2016 14:54:28 -0700 Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 10.0 \(3226\)) Subject: Re: SD-Card driver modification for Zynq questions From: Oleksandr Tymoshenko In-Reply-To: Date: Wed, 28 Sep 2016 14:53:58 -0700 Cc: freebsd-arm@freebsd.org, Lee D Content-Transfer-Encoding: quoted-printable Message-Id: <9859398E-0592-4B8F-A3DA-0364970A92B4@bluezbox.com> References: <02E012FA-342E-4EB7-99F2-733FA7990BDD@yahoo.com> <49016789-66F8-4B34-9FA7-8E97143634AF@bluezbox.com> To: Thomas Skibo X-Mailer: Apple Mail (2.3226) Sender: gonzo@id.bluezbox.com X-Spam-Level: -- X-Spam-Report: Spam detection software, running on the system "id.bluezbox.com", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see The administrator of that system for details. Content preview: > On Sep 28, 2016, at 2:49 PM, Thomas Skibo wrote: > > >> On Sep 28, 2016, at 2:00 PM, Oleksandr Tymoshenko wrote: >> >> >>> On Sep 28, 2016, at 7:16 AM, Thomas Skibo via freebsd-arm wrote: >>> >>> >>> Why not just set max-frequency to 200Mhz in the DTS file entry? >> >> From quick glance it’s not going to help. Slot’s max_clk is set to that value but then it’s >> overwritten in sdhci_init_slot by value obtained from register. We need to fix it and also >> add tunable for non-fdt systems. > > I checked the Zynq manual and it looks like it doesn’t provide a frequency in the capabilities register so sdhci_init_slot() won’t change the slot’s max_clk. [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-BeenThere: freebsd-arm@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "Porting FreeBSD to ARM processors." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 28 Sep 2016 21:54:31 -0000 > On Sep 28, 2016, at 2:49 PM, Thomas Skibo = wrote: >=20 >=20 >> On Sep 28, 2016, at 2:00 PM, Oleksandr Tymoshenko = wrote: >>=20 >>=20 >>> On Sep 28, 2016, at 7:16 AM, Thomas Skibo via freebsd-arm = wrote: >>>=20 >>>=20 >>> Why not just set max-frequency to 200Mhz in the DTS file entry? >>=20 >> =46rom quick glance it=E2=80=99s not going to help. Slot=E2=80=99s = max_clk is set to that value but then it=E2=80=99s >> overwritten in sdhci_init_slot by value obtained from register. We = need to fix it and also >> add tunable for non-fdt systems. =20 >=20 > I checked the Zynq manual and it looks like it doesn=E2=80=99t provide = a frequency in the capabilities register so sdhci_init_slot() won=E2=80=99= t change the slot=E2=80=99s max_clk. You=E2=80=99re right, I misread code, max-frequency can do the trick. = Still tunable may be a good idea.=20=