lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <DM6PR03MB527487EAB8D2977CF1925BBC9BDD0@DM6PR03MB5274.namprd03.prod.outlook.com>
Date:   Mon, 13 Apr 2020 08:39:29 +0000
From:   "Togorean, Bogdan" <Bogdan.Togorean@...log.com>
To:     Andrzej Hajda <a.hajda@...sung.com>,
        "dri-devel@...ts.freedesktop.org" <dri-devel@...ts.freedesktop.org>
CC:     "jernej.skrabec@...l.net" <jernej.skrabec@...l.net>,
        "jonas@...boo.se" <jonas@...boo.se>,
        "airlied@...ux.ie" <airlied@...ux.ie>,
        "narmstrong@...libre.com" <narmstrong@...libre.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "alexios.zavras@...el.com" <alexios.zavras@...el.com>,
        "Laurent.pinchart@...asonboard.com" 
        <Laurent.pinchart@...asonboard.com>,
        "tglx@...utronix.de" <tglx@...utronix.de>
Subject: RE: [RESEND 2/2] drm: bridge: adv7511: Extend list of audio sample
 rates

> > ADV7511 support sample rates up to 192kHz. CTS and N parameters should
> > be computed accordingly so this commit extend the list up to maximum
> > supported sample rate.
> >
> > Signed-off-by: Bogdan Togorean <bogdan.togorean@...log.com>
> > ---
> >  drivers/gpu/drm/bridge/adv7511/adv7511_audio.c | 12 ++++++++++++
> >  1 file changed, 12 insertions(+)
> >
> > diff --git a/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
> b/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
> > index 1e9b128d229b..13e8cee6e827 100644
> > --- a/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
> > +++ b/drivers/gpu/drm/bridge/adv7511/adv7511_audio.c
> > @@ -27,6 +27,18 @@ static void adv7511_calc_cts_n(unsigned int f_tmds,
> unsigned int fs,
> >  	case 48000:
> >  		*n = 6144;
> >  		break;
> > +	case 88200:
> > +		*n = 12544;
> > +		break;
> > +	case 96000:
> > +		*n = 12288;
> > +		break;
> > +	case 176400:
> > +		*n = 25088;
> > +		break;
> > +	case 192000:
> > +		*n = 24576;
> > +		break;
> 
> 
> I would put:
> 
> case 32000:
> case 48000:
> case 96000:
> case 192000:
>     *n = fs * 128 / 1000;
>     break;
> case 44100:
> case 88200:
> case 176400:
>     *n = fs * 128 / 900;
>     break;
> 
> To uncover the magic. Up to you.
Great solution Andrzej,

Thank you for your suggestion.

Regards,
Bogdan
> 
> Reviewed-by: Andrzej Hajda <a.hajda@...sung.com>
> 
> 
> Regards
> Andrzej
> >  	}
> >
> >  	*cts = ((f_tmds * *n) / (128 * fs)) * 1000;
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ