From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: linux-aspeed@lists.ozlabs.org
Subject: [PATCH 4/4] gpio: aspeed: Add interfaces for co-processor to grab GPIOs
Date: Fri, 15 Jun 2018 09:40:53 +1000 [thread overview]
Message-ID: <480dd5a586acfaaeddcd099e3f1854f27fa44522.camel@kernel.crashing.org> (raw)
In-Reply-To: <CACRpkdbup=bx3rnZbWBMD_p2+8EHkY9Mxc2UEOwHzZE10=VeQA@mail.gmail.com>
On Thu, 2018-06-14 at 10:59 +0200, Linus Walleij wrote:
>
> Overall looks fine!
>
> You definately need something like this for handling this special case.
>
> > +#include <linux/gpio/consumer.h>
>
> Why do you need this?
>
> I don't see that you use any functions from it.
>
> > +#include "gpiolib.h"
>
> I'm not so happy about this either, what is this needed for?
>
> It seems to me you can remove both includes, but admittedly I miss
> fine details all the time.
I wish I could :-) This is the main wart in there to be honest.
consumer.h is needed to build gpiolib.h
gpiolib.h is needed for gpio_chip_hwgpio() which needs the definition
of gpio_desc, etc...
I didn't find a simple way out if it... the "API" I expose to the copro
driver takes a gpio_desc which is the clean thing to do but I can't get
to the underlying GPIO number without gpiolib.
Cheers,
Ben.
next prev parent reply other threads:[~2018-06-14 23:40 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-06-12 0:10 [PATCH 0/4] gpio: aspeed: Fixes and support for sharing with co-processor Benjamin Herrenschmidt
2018-06-12 0:10 ` [PATCH 1/4] gpio: aspeed: Rework register type accessors Benjamin Herrenschmidt
2018-06-12 4:49 ` Benjamin Herrenschmidt
2018-06-12 0:10 ` [PATCH 2/4] gpio: aspeed: Add "Read Data" register to read the write latch Benjamin Herrenschmidt
2018-06-12 5:38 ` Joel Stanley
2018-06-12 7:18 ` Benjamin Herrenschmidt
2018-06-12 0:10 ` [PATCH 3/4] gpio: aspeed: Add command source registers Benjamin Herrenschmidt
2018-06-12 5:38 ` Joel Stanley
2018-06-12 0:10 ` [PATCH 4/4] gpio: aspeed: Add interfaces for co-processor to grab GPIOs Benjamin Herrenschmidt
2018-06-12 5:37 ` Joel Stanley
2018-06-12 7:17 ` Benjamin Herrenschmidt
2018-06-15 6:04 ` Benjamin Herrenschmidt
2018-06-14 8:59 ` Linus Walleij
2018-06-14 23:40 ` Benjamin Herrenschmidt [this message]
2018-06-28 13:42 ` Linus Walleij
2018-06-28 23:53 ` Benjamin Herrenschmidt
2018-06-14 9:01 ` [PATCH 0/4] gpio: aspeed: Fixes and support for sharing with co-processor Linus Walleij
2018-06-14 23:42 ` Benjamin Herrenschmidt
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=480dd5a586acfaaeddcd099e3f1854f27fa44522.camel@kernel.crashing.org \
--to=benh@kernel.crashing.org \
--cc=linux-aspeed@lists.ozlabs.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).