Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932272AbbBGIaM (ORCPT ); Sat, 7 Feb 2015 03:30:12 -0500 Received: from mezzanine.sirena.org.uk ([106.187.55.193]:54443 "EHLO mezzanine.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752217AbbBGIaG (ORCPT ); Sat, 7 Feb 2015 03:30:06 -0500 Date: Sat, 7 Feb 2015 07:09:51 +0800 From: Mark Brown To: Peter Rosin Cc: alsa-devel@alsa-project.org, Peter Rosin , Bo Shen , Liam Girdwood , Jaroslav Kysela , Takashi Iwai , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Message-ID: <20150206230951.GL31311@finisterre.sirena.org.uk> References: <1423050745-6372-1-git-send-email-peda@lysator.liu.se> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="oY1uq2ONqt5kuovO" Content-Disposition: inline In-Reply-To: <1423050745-6372-1-git-send-email-peda@lysator.liu.se> X-Cookie: Vitamin C deficiency is apauling. User-Agent: Mutt/1.5.23 (2014-03-12) X-SA-Exim-Connect-IP: 113.28.134.59 X-SA-Exim-Mail-From: broonie@sirena.org.uk Subject: Re: [PATCH v2] ASoC: atmel_ssc_dai: Allow more rates X-SA-Exim-Version: 4.2.1 (built Mon, 26 Dec 2011 16:24:06 +0000) X-SA-Exim-Scanned: Yes (on mezzanine.sirena.org.uk) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 2181 Lines: 56 --oY1uq2ONqt5kuovO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Feb 04, 2015 at 12:52:25PM +0100, Peter Rosin wrote: > One thing remains a bit unclear, and that is the 500ppm deduction. Is > that really warranted? The number was just pulled out of my hat... I don't really get what this is supposed to be protecting against. > + case SND_SOC_DAIFMT_CBM_CFS: > + case SND_SOC_DAIFMT_CBM_CFM: > + t.min = 8000; > + t.max = ssc_p->mck_rate / mck_div / frame_size; > + /* Take away 500ppm, just to be on the safe side. */ > + t.max -= t.max / 2000; > + t.openmin = t.openmax = 0; > + t.integer = 0; > + ret = snd_interval_refine(i, &t); As I understand it this is a straight divider rather than something that's doing dithering or anything else more fancy. Given that it seems as well just to trust the clock rate we've got - we don't do any error tracking with the clock API (perhaps we should) and for many applications some degree of divergence from the nominal rate is not *too* bad for audio systems (for application specific values of "some" and "too" of course). If it is just dividers I'm not sure the situation is really improved materially by knocking off the top frequency. If we are doing something more fancy than divididing my analysis is off base of course. --oY1uq2ONqt5kuovO Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iQEcBAEBCAAGBQJU1Um+AAoJECTWi3JdVIfQLU0H/33cg4ihNGi1mNycZGR2xc2c z3XXAg6iYOIyAFXHeUR9TZ+2pD+odzBKAZiFFhmcj2Vt+omIq3wrHDLT9/FDAX+H kfT4AjwrST1rvWn/pNORxtV4PC7ieLi/RLa4UrTKV8MHd/bmknBTaX4YxTH1gGIV +IXLXOaVfleReivPUX7l69KF50Q/mAXl2TN+UvnU9sWVuHyNJRJDBBWtmkAHAYEt 4cAMxvcc540vAjrRzC9jmxhI9FOMwHHtaD1bvXORc6KSVsIrNiTAAdm8AK0rgGv8 W7b5h/8ZBGSndBSOAKL/o2a2FDFW1sclyX7cye1RG59LXaaQ7cJq3DpA3Xqdzxw= =tvq8 -----END PGP SIGNATURE----- --oY1uq2ONqt5kuovO-- -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/