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:   Tue, 29 Oct 2019 13:57:03 +0000
From:   "Ardelean, Alexandru" <alexandru.Ardelean@...log.com>
To:     "linux-input@...r.kernel.org" <linux-input@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
CC:     "dmitry.torokhov@...il.com" <dmitry.torokhov@...il.com>,
        "lars@...afoo.de" <lars@...afoo.de>
Subject: Re: [PATCH 1/2] input: adp5589: Add default platform data

On Tue, 2019-10-29 at 13:28 +0200, Alexandru Ardelean wrote:
> From: Lars-Peter Clausen <lars@...afoo.de>
> 

Disregard this series.
I just noticed that it needs to be re-visited.
Some things have changed, and I didn't notice.

Apologies for the noise.
Alex


> If no platform data is supplied use a dummy platform data that configures
> the device in GPIO only mode.
> 
> Signed-off-by: Lars-Peter Clausen <lars@...afoo.de>
> Signed-off-by: Alexandru Ardelean <alexandru.ardelean@...log.com>
> ---
>  drivers/input/keyboard/adp5589-keys.c | 14 ++++++++++----
>  1 file changed, 10 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/input/keyboard/adp5589-keys.c
> b/drivers/input/keyboard/adp5589-keys.c
> index e7d58e7f0257..ed2c13bef1b7 100644
> --- a/drivers/input/keyboard/adp5589-keys.c
> +++ b/drivers/input/keyboard/adp5589-keys.c
> @@ -987,6 +987,14 @@ static void adp5589_keypad_remove(struct
> adp5589_kpad *kpad)
>  	}
>  }
>  
> +static const struct adp5589_gpio_platform_data
> adp5589_default_gpio_pdata = {
> +	.gpio_start = -1,
> +};
> +
> +static const struct adp5589_kpad_platform_data adp5589_default_pdata = {
> +	.gpio_data = &adp5589_default_gpio_pdata,
> +};
> +
>  static int adp5589_probe(struct i2c_client *client,
>  			 const struct i2c_device_id *id)
>  {
> @@ -1002,10 +1010,8 @@ static int adp5589_probe(struct i2c_client
> *client,
>  		return -EIO;
>  	}
>  
> -	if (!pdata) {
> -		dev_err(&client->dev, "no platform data?\n");
> -		return -EINVAL;
> -	}
> +	if (!pdata)
> +		pdata = &adp5589_default_pdata;
>  
>  	kpad = kzalloc(sizeof(*kpad), GFP_KERNEL);
>  	if (!kpad)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ