qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: "Philippe Mathieu-Daudé" <philmd@linaro.org>
To: Titus Rwantare <titusr@google.com>,
	minyard@acm.org, eddie.dong@intel.com
Cc: qemu-arm@nongnu.org, qemu-devel@nongnu.org, joel@jms.id.au,
	Hao Wu <wuhaotsh@google.com>
Subject: Re: [PATCH v2 3/4] hw/gpio: add PCA9536 i2c gpio expander
Date: Thu, 9 Feb 2023 09:00:13 +0100	[thread overview]
Message-ID: <f1d5840f-5ead-a2b1-29f4-33360c00610f@linaro.org> (raw)
In-Reply-To: <20230208224339.270589-4-titusr@google.com>

On 8/2/23 23:43, Titus Rwantare wrote:
> This device has the same register layout as the pca9538, but 4 fewer
> gpio pins. This commit lowers the number of pins initialised, and reuses
> the pca9538 logic.
> 
> Reviewed-by: Hao Wu <wuhaotsh@google.com>
> Signed-off-by: Titus Rwantare <titusr@google.com>
> ---
>   hw/gpio/pca_i2c_gpio.c         | 18 ++++++++++++++++++
>   include/hw/gpio/pca_i2c_gpio.h |  2 ++
>   2 files changed, 20 insertions(+)


> +static void pca9536_gpio_class_init(ObjectClass *klass, void *data)
> +{
> +    DeviceClass *dc = DEVICE_CLASS(klass);
> +    I2CSlaveClass *k = I2C_SLAVE_CLASS(klass);
> +    PCAGPIOClass *pc = PCA_I2C_GPIO_CLASS(klass);
> +
> +    dc->desc = "PCA9536 4-bit I/O expander";
> +    pc->num_pins = PCA9536_NUM_PINS;
> +
> +    k->recv = pca9538_recv;
> +    k->send = pca9538_send;

Can we rename as pca953x_recv() / pca953x_send() in previous patch?

Otherwise,
Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org>


  reply	other threads:[~2023-02-09  8:00 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-08 22:43 [PATCH v2 0/4] PCA I2C GPIO expanders Titus Rwantare
2023-02-08 22:43 ` [PATCH v2 1/4] hw/gpio: add PCA6416 i2c GPIO expander Titus Rwantare
2023-02-09  7:44   ` Philippe Mathieu-Daudé
2023-02-08 22:43 ` [PATCH v2 2/4] hw/gpio: add PCA9538 8-bit " Titus Rwantare
2023-02-09  7:57   ` Philippe Mathieu-Daudé
2023-02-08 22:43 ` [PATCH v2 3/4] hw/gpio: add PCA9536 i2c gpio expander Titus Rwantare
2023-02-09  8:00   ` Philippe Mathieu-Daudé [this message]
2023-02-08 22:43 ` [PATCH v2 4/4] hw/i2c: add canonical path to i2c event traces Titus Rwantare
2023-02-09  8:01   ` Philippe Mathieu-Daudé

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=f1d5840f-5ead-a2b1-29f4-33360c00610f@linaro.org \
    --to=philmd@linaro.org \
    --cc=eddie.dong@intel.com \
    --cc=joel@jms.id.au \
    --cc=minyard@acm.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    --cc=titusr@google.com \
    --cc=wuhaotsh@google.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).