From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: "Hebbar, Gururaja" <gururaja.hebbar@ti.com>
Cc: alsa-devel@alsa-project.org, sudhakar.raj@ti.com,
tony@atomide.com, nsekhar@ti.com,
davinci-linux-open-source@linux.davincidsp.com, lrg@ti.com,
linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 1/3] ASoC: Davinci: McASP: add support new McASP IP Variant
Date: Fri, 31 Aug 2012 17:44:44 -0700 [thread overview]
Message-ID: <20120901004443.GB21451@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <1346417459-30042-2-git-send-email-gururaja.hebbar@ti.com>
On Fri, Aug 31, 2012 at 06:20:57PM +0530, Hebbar, Gururaja wrote:
> + if (dev->version == MCASP_VERSION_3) {
> + mcasp_clr_bits(dev->base + MCASP_VER3_RFIFOCTL,
> FIFO_ENABLE);
> - mcasp_set_bits(dev->base + DAVINCI_MCASP_RFIFOCTL,
> + mcasp_set_bits(dev->base + MCASP_VER3_RFIFOCTL,
> FIFO_ENABLE);
> + } else {
> + mcasp_clr_bits(dev->base +
> + DAVINCI_MCASP_RFIFOCTL, FIFO_ENABLE);
> + mcasp_set_bits(dev->base +
> + DAVINCI_MCASP_RFIFOCTL, FIFO_ENABLE);
> + }
This is all basically OK but it seems like it'd be better if all these
dev->version checks were switch statements. That way when the hardware
designers get bored and add version 4 of the register map it'll slot in
naturally, and it'll be more clear what the code currently handles.
next prev parent reply other threads:[~2012-09-01 0:44 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-08-31 12:50 [PATCH 0/3] ASoC: Davinci: McASP: add support new McASP IP Variant Hebbar, Gururaja
2012-08-31 12:50 ` [PATCH 1/3] " Hebbar, Gururaja
2012-09-01 0:44 ` Mark Brown [this message]
2012-09-03 6:57 ` Hebbar, Gururaja
2012-09-05 4:01 ` Mark Brown
2012-08-31 12:50 ` [PATCH 2/3] ASoC: Davinci: pcm: add support for sram-support-less platforms Hebbar, Gururaja
2012-09-12 7:50 ` Hebbar, Gururaja
2012-09-12 7:52 ` Mark Brown
2012-09-22 15:33 ` Mark Brown
2012-09-27 6:57 ` Hebbar, Gururaja
[not found] ` <1BAFE6F6C881BF42822005164F1491C33EA92A1D-Er742YJ7I/eIQmiDNMet8wC/G2K4zDHf@public.gmane.org>
2012-10-01 15:54 ` Mark Brown
2012-10-02 7:48 ` Peter Ujfalusi
2012-10-02 9:37 ` Mark Brown
2012-10-02 10:33 ` Daniel Mack
2012-10-02 11:06 ` [alsa-devel] " Sekhar Nori
2012-10-02 13:42 ` Daniel Mack
[not found] ` <506AEF57.2000306-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-02 16:41 ` Matt Porter
2012-10-02 16:50 ` Daniel Mack
[not found] ` <506B1B46.2070006-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-02 17:28 ` [alsa-devel] " Matt Porter
2012-10-04 9:21 ` Daniel Mack
[not found] ` <506D552A.2000506-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-04 9:38 ` [alsa-devel] " Porter, Matt
2012-10-04 9:57 ` Daniel Mack
[not found] ` <506D5D8A.7030902-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-04 10:28 ` [alsa-devel] " Matt Porter
2012-10-04 11:11 ` Daniel Mack
2012-10-02 16:30 ` [alsa-devel] " Matt Porter
[not found] ` <506A9C65.5040309-l0cyMroinI0@public.gmane.org>
2012-10-02 16:28 ` Matt Porter
2012-10-02 8:37 ` Sekhar Nori
2012-08-31 12:50 ` [PATCH 3/3] ASoC: Davinci: evm: Fix typo in cpu dai name Hebbar, Gururaja
2012-09-01 0:47 ` Mark Brown
2012-10-02 22:28 ` [alsa-devel] [PATCH 0/3] ASoC: Davinci: McASP: add support new McASP IP Variant Daniel Mack
[not found] ` <506B6A9D.3090100-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-03 7:16 ` Hebbar, Gururaja
2012-10-03 11:16 ` Daniel Mack
[not found] ` <506C1E97.1070700-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-03 12:57 ` [alsa-devel] " Hebbar, Gururaja
2012-10-03 14:07 ` Daniel Mack
[not found] ` <506C46AD.1090807-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2012-10-04 19:50 ` [alsa-devel] " Matt Porter
2012-11-25 10:26 ` Yegor Yefremov
2012-11-26 11:32 ` Hebbar, Gururaja
2012-11-26 11:35 ` Mark Brown
[not found] ` <20121126113521.GD9411-yzvPICuk2AATkU/dhu1WVueM+bqZidxxQQ4Iyu8u01E@public.gmane.org>
2012-11-26 11:42 ` [alsa-devel] " Hebbar, Gururaja
2012-11-26 11:57 ` Mark Brown
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20120901004443.GB21451@opensource.wolfsonmicro.com \
--to=broonie@opensource.wolfsonmicro.com \
--cc=alsa-devel@alsa-project.org \
--cc=davinci-linux-open-source@linux.davincidsp.com \
--cc=gururaja.hebbar@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=lrg@ti.com \
--cc=nsekhar@ti.com \
--cc=sudhakar.raj@ti.com \
--cc=tony@atomide.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).