RE: Add GPIO support for mcp251x driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Marc,

Thanks for the pointer.

What do you mean with "proper"? Can't we just add the relevant gpiochip_ calls in mcp251xx.c?

Regards
Timo



-----Original Message-----
From: Marc Kleine-Budde [mailto:mkl@xxxxxxxxxxxxxx] 
Sent: Monday, August 19, 2019 5:07 PM
To: Schlüßler, Timo; wg@xxxxxxxxxxxxxx; linux-can@xxxxxxxxxxxxxxx
Subject: Re: Add GPIO support for mcp251x driver

On 8/19/19 4:49 PM, Schlüßler, Timo wrote:
> what do you think would be the right way to control the GPIOs of the
> MCP251x/25625 from userland?

You want to implement a proper kernel driver, attaching the GPIOs to the kernel GPIO framework: See

https://git.kernel.org/pub/scm/linux/kernel/git/mkl/linux-can-next.git/commit/?h=mcp25xxfd&id=55eb3afa5c29bd0d5046a40cc0802a495406ac15

for an example.

> Is this something that should be done
> using a SIOCDEVPRIVATE ioctl? Where should this get documented? I 
> could imagine something like this, but am not sure whether this is the 
> right way to go.

Marc

-- 
Pengutronix e.K.                  | Marc Kleine-Budde           |
Industrial Linux Solutions        | Phone: +49-231-2826-924     |
Vertretung West/Dortmund          | Fax:   +49-5121-206917-5555 |
Amtsgericht Hildesheim, HRA 2686  | http://www.pengutronix.de   |





[Index of Archives]     [Automotive Discussions]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]     [CAN Bus]

  Powered by Linux