lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 09 Jun 2014 22:36:47 +0400
From:	Sergei Shtylyov <sergei.shtylyov@...entembedded.com>
To:	One Thousand Gnomes <gnomes@...rguk.ukuu.org.uk>,
	Sascha Silbe <x-linux@...ra-silbe.de>
CC:	Johan Hovold <jhovold@...il.com>,
	Linus Walleij <linus.walleij@...aro.org>,
	Alexandre Courbot <gnurou@...il.com>,
	Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
	linux-usb@...r.kernel.org, linux-gpio@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH] USB: ftdi_sio: add GPIO support

Hello.

On 06/09/2014 06:23 PM, One Thousand Gnomes wrote:

>>   #include <linux/kernel.h>
>>   #include <linux/errno.h>
>> +#ifdef CONFIG_GPIOLIB
>> +#include <linux/gpio.h>
>> +#endif

> Please create a new struct, a new file and put all the GPIO stuff in
> there rather than #if bombing the driver.

> You can then declare blank methods for the gpio stuff if GPIO is not
> compiled in - ie in the headers

> #ifdef CONFIG_GPIOLIB
> extern int ftdi_gpio_open(struct ftdi_private *priv);
> etc...
> #else
> extern inline  int ftdi_gpio_open(struct ftdi_private *priv) { return 0 };

    I guess you meant *static* instead of *extern* here?

> #endif

WBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ