Rust for Linux List
 help / color / mirror / Atom feed
From: "Maurice Hieronymus" <mhi@mailbox.org>
To: "Maurice Hieronymus" <mhi@mailbox.org>,
	"Danilo Krummrich" <dakr@kernel.org>,
	"Bjorn Helgaas" <bhelgaas@google.com>
Cc: "Alice Ryhl" <aliceryhl@google.com>,
	"Alexandre Courbot" <acourbot@nvidia.com>,
	"David Airlie" <airlied@gmail.com>,
	"Simona Vetter" <simona@ffwll.ch>,
	"Krzysztof Wilczyński" <kwilczynski@kernel.org>,
	"Miguel Ojeda" <ojeda@kernel.org>,
	"Boqun Feng" <boqun@kernel.org>, "Gary Guo" <gary@garyguo.net>,
	"Björn Roy Baron" <bjorn3_gh@protonmail.com>,
	"Benno Lossin" <lossin@kernel.org>,
	"Andreas Hindborg" <a.hindborg@kernel.org>,
	"Trevor Gross" <tmgross@umich.edu>,
	"Daniel Almeida" <daniel.almeida@collabora.com>,
	"Tamir Duberstein" <tamird@kernel.org>,
	"Onur Özkan" <work@onurozkan.dev>,
	nova-gpu@lists.linux.dev, dri-devel@lists.freedesktop.org,
	linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org,
	rust-for-linux@vger.kernel.org,
	"Beata Michalska" <beata.michalska@arm.com>
Subject: Re: [PATCH] rust: pci: rework device enabling API
Date: Sat, 11 Jul 2026 17:25:45 +0200	[thread overview]
Message-ID: <DJVUHS5VHP4Z.G2FV1QJQ8ZYH@mailbox.org> (raw)
In-Reply-To: <DJQXXV5KC973.1XAINGJFCKSWE@mailbox.org>

On Sun Jul 5, 2026 at 11:04 PM CEST, Maurice Hieronymus wrote:
>
> The one question is where the bit should live. pci_dev already has
> priv_flags, but its bit definitions and accessors are private to
> drivers/pci, while is_busmaster is accessed directly from outside:
> xen-pciback writes it, lpfc and sfc read it. So either priv_flags
> grows public accessors for this bit, or struct pci_dev gets a public
> flags bitmap with an accessor macro, like struct device.
>
> Bjorn, would you take such a patch, and which of the two would you
> prefer?
>
I went ahead and sent a series implementing the second option, a
public flags bitmap with generated accessors following the driver
core precedent, converting is_busmaster and broken_parity_status:

https://lore.kernel.org/r/20260711-pci-dev-flags-v1-0-2fcf2811138c@mailbox.org

Happy to respin on top of priv_flags instead if that is preferred.

Best,

Maurice


  reply	other threads:[~2026-07-11 15:25 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-02  9:32 [PATCH] rust: pci: rework device enabling API Maurice Hieronymus
2026-07-02 21:47 ` Danilo Krummrich
2026-07-05 21:04   ` Maurice Hieronymus
2026-07-11 15:25     ` Maurice Hieronymus [this message]
2026-07-30 13:25       ` Maurice Hieronymus

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=DJVUHS5VHP4Z.G2FV1QJQ8ZYH@mailbox.org \
    --to=mhi@mailbox.org \
    --cc=a.hindborg@kernel.org \
    --cc=acourbot@nvidia.com \
    --cc=airlied@gmail.com \
    --cc=aliceryhl@google.com \
    --cc=beata.michalska@arm.com \
    --cc=bhelgaas@google.com \
    --cc=bjorn3_gh@protonmail.com \
    --cc=boqun@kernel.org \
    --cc=dakr@kernel.org \
    --cc=daniel.almeida@collabora.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gary@garyguo.net \
    --cc=kwilczynski@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=lossin@kernel.org \
    --cc=nova-gpu@lists.linux.dev \
    --cc=ojeda@kernel.org \
    --cc=rust-for-linux@vger.kernel.org \
    --cc=simona@ffwll.ch \
    --cc=tamird@kernel.org \
    --cc=tmgross@umich.edu \
    --cc=work@onurozkan.dev \
    /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