linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Ludovic Desroches <ludovic.desroches@microchip.com>
To: Bartosz Golaszewski <brgl@bgdev.pl>
Cc: linux-gpio@vger.kernel.org,
	Linus Walleij <linus.walleij@linaro.org>,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	Clemens Gruber <clemens.gruber@pqgruber.com>,
	Thierry Reding <thierry.reding@gmail.com>,
	Peter Rosin <peda@axentia.se>,
	Lars-Peter Clausen <lars@metafoo.de>
Subject: Re: [RFC] libgpiod public API reviews needed
Date: Tue, 23 Jan 2018 15:15:40 +0100	[thread overview]
Message-ID: <20180123141540.GJ3055@rfolt0960.corp.atmel.com> (raw)
In-Reply-To: <CAMRc=Md09CAQMS=5b7EUeh5AOjJ-zzbnETb_V+RdsxxafVxPdA@mail.gmail.com>

Hi,

On Fri, Jan 19, 2018 at 02:28:40PM +0100, Bartosz Golaszewski wrote:
> Hi,
> 
> I would like to release libgpiod v1.0 soon (preferably before FOSDEM
> 2018). The first version (v0.x series) was written in a matter of two
> weeks and the API was not well designed. Since v0.3 release I've been
> working on redesigning the public API to make it simplier and more
> useful.
> 
> I want to commit to a stable interface for the library starting from
> v1.0 but it would be great if I could get some reviews first - it's
> basically only about reviewing a single public header: include/gpiod.h
> in which all public symbols are documented. Any implementation details
> can always be changed later.
> 
> The most prominent changes since 0.3 include:
> - removal of custom error handling in favor of errnos
> - merge of two separate interfaces for event requests and regular line requests
> - redesign of the simple API
> - addition of a bunch of helpers for line requests
> - redesign of the iterator API
> - making the use of prefixes more consistent
> - renaming of symbols all over the place
> - and various minor tweaks
> 
> As far as usefulness goes - the user space tools that are included all
> use this API and it looks pretty clean.
> 
> The project is hosted at kernel.org:
> 
>     https://git.kernel.org/pub/scm/libs/libgpiod/libgpiod.git/
> 
> and the code that needs review is on the master branch.
> 
> Thanks in advance to anyone who'll find the time to take a look.
> 

Thanks for your work, I am using your library and I am trying to promote it.

Some people were confused concerning the naming when requesting line(s)
as output. 'init_val(s)' may be better than 'default_val(s)'.

The callback for gpiod_simple_set_value(_multiple) is optional, you may mention
it. Concerning the multiple variant, I would enforce that the callback
is called when ALL the values are set.
I don't see the added value of this callback. What's the difference with
executing it depending on gpiod_simple_set_value(_multiple) return value?

Regards

Ludovic

  parent reply	other threads:[~2018-01-23 14:15 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-19 13:28 [RFC] libgpiod public API reviews needed Bartosz Golaszewski
2018-01-20 16:02 ` Clemens Gruber
2018-01-21 21:14   ` Bartosz Golaszewski
2018-01-21 15:49 ` Linus Walleij
2018-01-21 21:30   ` Bartosz Golaszewski
2018-01-21 22:18     ` Arnd Bergmann
2018-01-22  8:21       ` Linus Walleij
2018-01-22  9:25         ` Arnd Bergmann
2018-01-22  9:28           ` Arnd Bergmann
2018-01-22 11:02           ` Bartosz Golaszewski
2018-01-22 11:12             ` Arnd Bergmann
2018-01-23 15:14               ` Bartosz Golaszewski
2018-01-22 12:02           ` Linus Walleij
2018-01-22 13:46             ` Arnd Bergmann
2018-01-23 14:15 ` Ludovic Desroches [this message]
2018-01-23 15:05   ` Bartosz Golaszewski
2018-01-25 16:29   ` Bartosz Golaszewski
2018-01-26  7:35     ` Ludovic Desroches

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=20180123141540.GJ3055@rfolt0960.corp.atmel.com \
    --to=ludovic.desroches@microchip.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=brgl@bgdev.pl \
    --cc=clemens.gruber@pqgruber.com \
    --cc=lars@metafoo.de \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=peda@axentia.se \
    --cc=thierry.reding@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).