qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: Peter Maydell <peter.maydell@linaro.org>,
	qemu-arm@nongnu.org, qemu-devel@nongnu.org
Cc: "Philippe Mathieu-Daudé" <f4bug@amsat.org>,
	"Kevin Townsend" <kevin.townsend@linaro.org>
Subject: Re: [PATCH 0/2] Kconfig: Add an I2C_DEVICES device group
Date: Tue, 8 Feb 2022 17:20:48 +0100	[thread overview]
Message-ID: <687ca4ab-eef3-56f6-2cc1-a6d98d77d304@redhat.com> (raw)
In-Reply-To: <20220208155911.3408455-1-peter.maydell@linaro.org>

On 2/8/22 16:59, Peter Maydell wrote:
> This patchset adds a new Kconfig "device group" for I2C devices which
> a user might reasonably want to plug in to an arbitrary i2c bus via
> the command line.  This follows the approach we use for PCI devices:
> generally-usable i2c devices have
>         default y if I2C_DEVICES
> and board models with user-accessible i2c buses have
>         imply I2C_DEVICES
> 
> This means that when building a board model that pulls in the device
> group, the devices are all compiled in and available for use.
> (Previously they would happen to be present and usable only if some
> other board that explicitly pulled that device in happened to also be
> built into the same QEMU binary.)
> 
> I have been fairly conservative in marking devices as being in the
> group and in marking board models as pulling in the group; feel free
> to suggest changes.
> 
> In particular I've only added 'imply I2C_DEVICES' to arm boards.
> Grepping through Kconfig files I only found the PPC boards e500 and
> ppc44x that enable some kind of i2c controller anyway.
> 
> The immediate motivation here is that the recently added lsm303dlhc
> magnetometer isn't currently built unless the user manually adds it
> to their config, because as it happens no boards have it as a
> hard-wired device.

Acked-by: Paolo Bonzini <pbonzini@redhat.com>

> thanks
> -- PMM
> 
> Peter Maydell (2):
>    Kconfig: Add I2C_DEVICES device group
>    Kconfig: Add 'imply I2C_DEVICES' on boards with available i2c bus
> 
>   docs/devel/kconfig.rst |  8 ++++++--
>   hw/arm/Kconfig         | 10 ++++++++++
>   hw/i2c/Kconfig         |  5 +++++
>   hw/rtc/Kconfig         |  2 ++
>   hw/sensor/Kconfig      |  5 +++++
>   5 files changed, 28 insertions(+), 2 deletions(-)
> 



  parent reply	other threads:[~2022-02-08 17:38 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-08 15:59 [PATCH 0/2] Kconfig: Add an I2C_DEVICES device group Peter Maydell
2022-02-08 15:59 ` [PATCH 1/2] Kconfig: Add " Peter Maydell
2022-02-08 18:03   ` Hao Wu
2022-02-08 15:59 ` [PATCH 2/2] Kconfig: Add 'imply I2C_DEVICES' on boards with available i2c bus Peter Maydell
2022-02-08 18:04   ` Hao Wu
2022-02-08 16:20 ` Paolo Bonzini [this message]
2022-02-10 11:19 ` [PATCH 0/2] Kconfig: Add an I2C_DEVICES device group Philippe Mathieu-Daudé via

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=687ca4ab-eef3-56f6-2cc1-a6d98d77d304@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=f4bug@amsat.org \
    --cc=kevin.townsend@linaro.org \
    --cc=peter.maydell@linaro.org \
    --cc=qemu-arm@nongnu.org \
    --cc=qemu-devel@nongnu.org \
    /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).