linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Kent Gibson <warthog618@gmail.com>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: "Viresh Kumar" <viresh.kumar@linaro.org>,
	"Linus Walleij" <linus.walleij@linaro.org>,
	"Vincent Guittot" <vincent.guittot@linaro.org>,
	linux-gpio@vger.kernel.org,
	"Miguel Ojeda" <miguel.ojeda.sandonis@gmail.com>,
	"Wedson Almeida Filho" <wedsonaf@google.com>,
	"Alex Bennée" <alex.bennee@linaro.org>,
	stratos-dev@op-lists.linaro.org,
	"Gerard Ryan" <g.m0n3y.2503@gmail.com>
Subject: Re: [PATCH V7 3/8] libgpiod: Add rust wrapper crate
Date: Mon, 31 Oct 2022 20:33:57 +0800	[thread overview]
Message-ID: <Y1/AtfEhuijx1+tK@sol> (raw)
In-Reply-To: <CAMRc=MdWce2Msjwjyo3ny9LyUsA8Zeq_WhhJ2=ar5CG1BPmhtg@mail.gmail.com>

On Thu, Oct 27, 2022 at 02:09:31PM +0200, Bartosz Golaszewski wrote:
> On Fri, Oct 21, 2022 at 2:39 PM Kent Gibson <warthog618@gmail.com> wrote:
> >
> > On Fri, Oct 21, 2022 at 04:52:38PM +0530, Viresh Kumar wrote:
> > > Hi Kent,
> > >
> > > >
> > > > What if the Rust bindings version differ from the libgpiod version?
> > >
> > > Hmm, not sure which version should we return here. I think it should
> > > just be libgpiod's version. Though I am fine with whatever you and
> > > Bartosz decide.
> > >
> >
> > You need both - separately.
> >
> 
> For C++ and Python, the API version stays consistent across all three
> trees for simplicity. There are separate ABI numbers for libgpiod,
> libgpiodcxx and libgpiosim. Rust doesn't seem to have this kind of
> differentiation between ABI and API so I'd say we should have a single
> API version but see below about the idea for the contrib/ directory.
> 

My thinking was that if the Rust bindings end up being compiled into the
app then it may be difficult to identify the version it was built with,
as opposed to the version of libgpiod it is running against.
Not sure you can always determine that from the Cargo.toml or
Cargo.lock, or that those will always be available after the fact.

Not a biggy if the two always remain compatible, but if a libgpiod change
inadvertently triggers some fault in the Rust bindings then it could be a
PITA just to determine the versions involved.

> > > Will it be possible to get on with the current implementation and once
> > > this is merged you send patches on top of it which can then get
> > > reviewed properly by others too, who know Rust better than me ?
> > >
> >
> > The Rust bindings are your baby, and I don't have any plans to be
> > patching it.  And Bart is the arbiter of what gets merged, so that
> > decision is his.
> >
> 
> I was thinking about it lately and figured that - since I don't know
> Rust very well and cannot reliably maintain that part myself - how
> about we create a 'contrib' directory in the libgpiod tree for this
> kind of "third-party" bindings? The requirements for stability and
> correctness in there would be more relaxed compared to the main tree?
> 

The problem there is you thinking that you need to be able to personally
support every line of libgpiod, and that it is not a team effort.

Wrt the Rust bindings, I was assuming that either Viresh would provide
support, or as his work appears to be on behalf of Linaro that they
would have an interest in maintaining it.

Similarly, I was assuming that I would be providing support for the
proposed tool changes, should they ever get merged.  Though, based on the
little feedback to date, I'm dubious about that ever happening.
I could always split them off into a separate project, but maintaining
an autoconf based setup doesn't interest me, particularly when the Go and
Rust alternatives are one-liners that just work, so probably not.

I was thinking that some forum for libgpiod, or more broadly GPIO
user space development, would help increase community involvement,
in both directions, and that might help address the Bartosz doesn't
scale problem. But I don't have anything useful to add on that.
The only relevant experience I have is with github, and while it would
probably suffice I would explore other options first, with gitlab
being the most obvious alternative.  No help there, I know.

Sorry for not replying sooner.  I was hoping to do a respin in a more
positive light, but that has eluded me and time marches on.

Cheers,
Kent.

  reply	other threads:[~2022-10-31 12:34 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-10-14 10:47 [PATCH V7 0/8] libgpiod: Add Rust bindings Viresh Kumar
2022-10-14 10:47 ` [PATCH V7 1/8] libgpiod: Add libgpiod-sys rust crate Viresh Kumar
2022-10-17 12:59   ` Kent Gibson
2022-10-18 11:22     ` Viresh Kumar
2022-10-18 11:42       ` Miguel Ojeda
2022-10-18 11:49       ` Kent Gibson
2022-10-19  6:46         ` Viresh Kumar
2022-10-19  7:21           ` Kent Gibson
2022-10-19 11:22             ` Viresh Kumar
2022-10-19 12:01               ` Kent Gibson
2022-10-20  5:34                 ` Viresh Kumar
2022-10-27 12:18                 ` Bartosz Golaszewski
2022-10-14 10:47 ` [PATCH V7 2/8] libgpiod-sys: Add pre generated rust bindings Viresh Kumar
2022-10-14 10:47 ` [PATCH V7 3/8] libgpiod: Add rust wrapper crate Viresh Kumar
2022-10-17 12:59   ` Kent Gibson
2022-10-21 11:22     ` Viresh Kumar
2022-10-21 12:39       ` Kent Gibson
2022-10-27 12:09         ` Bartosz Golaszewski
2022-10-31 12:33           ` Kent Gibson [this message]
2022-10-31 12:45             ` Bartosz Golaszewski
2022-11-02  4:00             ` Viresh Kumar
2022-11-02 12:47               ` Bartosz Golaszewski
2022-11-02 13:08                 ` Kent Gibson
2022-11-02 16:34                   ` Bartosz Golaszewski
2022-11-03  0:38                     ` Kent Gibson
2022-11-03  8:35                       ` Bartosz Golaszewski
2022-11-03 12:29                         ` Kent Gibson
2022-11-04 15:51                           ` Bartosz Golaszewski
2022-10-18  3:27   ` Kent Gibson
2022-10-21 11:25     ` Viresh Kumar
2022-10-14 10:47 ` [PATCH V7 4/8] libgpiod: Add rust examples Viresh Kumar
2022-10-17 13:00   ` Kent Gibson
2022-10-14 10:47 ` [PATCH V7 5/8] libgpiod: Add gpiosim rust crate Viresh Kumar
2022-10-17 13:00   ` Kent Gibson
2022-10-21  9:56     ` Viresh Kumar
2022-10-14 10:47 ` [PATCH V7 6/8] gpiosim: Add pre generated rust bindings Viresh Kumar
2022-10-14 10:47 ` [PATCH V7 7/8] libgpiod: Add rust tests Viresh Kumar
2022-10-17 13:00   ` Kent Gibson
2022-10-17 14:30     ` Kent Gibson
2022-10-20 10:37     ` Viresh Kumar
2022-10-20 11:02       ` Kent Gibson
2022-10-20 12:40         ` Bartosz Golaszewski
2022-10-20 15:16           ` Miguel Ojeda
2022-10-14 10:47 ` [PATCH V7 8/8] libgpiod: Integrate building of rust bindings with make Viresh Kumar
2022-10-14 17:03 ` [PATCH V7 0/8] libgpiod: Add Rust bindings Miguel Ojeda
2022-10-20 13:29   ` Björn Roy Baron
2022-10-21  9:39     ` Viresh Kumar
2022-10-21 14:34       ` Björn Roy Baron
2022-10-25  6:42         ` Viresh Kumar
2022-10-29 17:46           ` Björn Roy Baron

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=Y1/AtfEhuijx1+tK@sol \
    --to=warthog618@gmail.com \
    --cc=alex.bennee@linaro.org \
    --cc=brgl@bgdev.pl \
    --cc=g.m0n3y.2503@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=miguel.ojeda.sandonis@gmail.com \
    --cc=stratos-dev@op-lists.linaro.org \
    --cc=vincent.guittot@linaro.org \
    --cc=viresh.kumar@linaro.org \
    --cc=wedsonaf@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).