From: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>
To: Baoyou Xie <baoyou.xie@linaro.org>
Cc: mark.rutland@arm.com, alsa-devel@alsa-project.org,
kuninori.morimoto.gx@renesas.com, lgirdwood@gmail.com,
tiwai@suse.com, srinivas.kandagatla@linaro.org,
bardliao@realtek.com, lars@metafoo.de, axel.lin@ingics.com,
Paul.Handrigan@cirrus.com, chen.chaokai@zte.com.cn,
wang.qiang01@zte.com.cn, devicetree@vger.kernel.org,
arnd@arndb.de, yesanishhere@gmail.com, xie.baoyou@zte.com.cn,
nh6z@nh6z.net, robh+dt@kernel.org,
linux-arm-kernel@lists.infradead.org, oder_chiou@realtek.com,
linux-kernel@vger.kernel.org, petr@barix.com, broonie@kernel.org,
jun.nie@linaro.org, shawnguo@kernel.org
Subject: Re: [PATCH v1 3/3] ASoC: zx-96p22: add zte's aud96p22 controller driver
Date: Wed, 15 Feb 2017 11:24:25 +0000 [thread overview]
Message-ID: <20170215112425.GC30007@localhost.localdomain> (raw)
In-Reply-To: <1487156110-12840-3-git-send-email-baoyou.xie@linaro.org>
On Wed, Feb 15, 2017 at 06:55:10PM +0800, Baoyou Xie wrote:
> This patch adds aud96p22 controller driver for zte's SoC family.
>
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
> ---
<snip>
> +static int zx_aud96p22_i2c_write(struct i2c_client *i2c_client,
> + const void *data, size_t count)
> +{
> + int xfer;
> +
> + xfer = i2c_master_send(i2c_client, data, count);
> + if (xfer == count)
> + return 0;
> + else if (xfer < 0)
> + return xfer;
> + else
> + return -EIO;
> +}
> +
> +static int zx_aud96p22_i2c_read(struct i2c_client *i2c_client,
> + unsigned char addr)
> +{
> + int xfer;
> +
> + xfer = i2c_smbus_read_word_data(i2c_client, addr);
> + if (xfer < 0)
> + dev_warn(&i2c_client->dev, "transfer error %d\n", xfer);
> +
> + return xfer;
> +}
> +
Is there any reason this isn't using regmap? It looks like it
should be, have a look at any of the other mainline CODECs for an
example.
Thanks,
Charles
next prev parent reply other threads:[~2017-02-15 11:24 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-15 10:55 [PATCH v1 1/3] ASoC: zx-96p22: add documentation for zte's aud96p22 controller Baoyou Xie
[not found] ` <1487156110-12840-1-git-send-email-baoyou.xie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2017-02-15 10:55 ` [PATCH v1 2/3] MAINTAINERS: add zte 96p22 controller driver to ARM ZTE architecture Baoyou Xie
2017-02-15 10:55 ` [PATCH v1 3/3] ASoC: zx-96p22: add zte's aud96p22 controller driver Baoyou Xie
2017-02-15 11:24 ` Charles Keepax [this message]
2017-02-16 0:24 ` Baoyou Xie
2017-02-16 3:09 ` Baoyou Xie
[not found] ` <1487156110-12840-3-git-send-email-baoyou.xie-QSEj5FYQhm4dnm+yROfE0A@public.gmane.org>
2017-02-16 11:17 ` Shawn Guo
2017-02-16 11:00 ` [PATCH v1 1/3] ASoC: zx-96p22: add documentation for zte's aud96p22 controller Shawn Guo
2017-02-27 17:20 ` Rob Herring
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=20170215112425.GC30007@localhost.localdomain \
--to=ckeepax@opensource.wolfsonmicro.com \
--cc=Paul.Handrigan@cirrus.com \
--cc=alsa-devel@alsa-project.org \
--cc=arnd@arndb.de \
--cc=axel.lin@ingics.com \
--cc=baoyou.xie@linaro.org \
--cc=bardliao@realtek.com \
--cc=broonie@kernel.org \
--cc=chen.chaokai@zte.com.cn \
--cc=devicetree@vger.kernel.org \
--cc=jun.nie@linaro.org \
--cc=kuninori.morimoto.gx@renesas.com \
--cc=lars@metafoo.de \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=nh6z@nh6z.net \
--cc=oder_chiou@realtek.com \
--cc=petr@barix.com \
--cc=robh+dt@kernel.org \
--cc=shawnguo@kernel.org \
--cc=srinivas.kandagatla@linaro.org \
--cc=tiwai@suse.com \
--cc=wang.qiang01@zte.com.cn \
--cc=xie.baoyou@zte.com.cn \
--cc=yesanishhere@gmail.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).