All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mattia Dongili <malattia@linux.it>
To: Dan Carpenter <error27@gmail.com>
Cc: Matthew Garrett <mjg@redhat.com>,
	platform-driver-x86@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch 2/4] sony-laptop: return negative on failure in
Date: Sun, 27 Feb 2011 12:27:55 +0000	[thread overview]
Message-ID: <20110227122755.GE29319@kamineko.org> (raw)
In-Reply-To: <20110226125456.GJ18043@bicker>

On Sat, Feb 26, 2011 at 03:54:57PM +0300, Dan Carpenter wrote:
> There were two places in sony_nc_add() where we returned zero on failure
> instead of a negative error code.
> 
> Signed-off-by: Dan Carpenter <error27@gmail.com>

Acked-by: Mattia Dongili <malattia@linux.it>

> diff --git a/drivers/platform/x86/sony-laptop.c b/drivers/platform/x86/sony-laptop.c
> index a7b9c72..d0d0522 100644
> --- a/drivers/platform/x86/sony-laptop.c
> +++ b/drivers/platform/x86/sony-laptop.c
> @@ -1593,9 +1593,11 @@ static int sony_nc_add(struct acpi_device *device)
>  	if (ACPI_SUCCESS(acpi_get_handle(sony_nc_acpi_handle, "SN00",
>  					 &handle))) {
>  		dprintk("Doing SNC setup\n");
> -		if (sony_nc_handles_setup(sony_pf_device))
> +		result = sony_nc_handles_setup(sony_pf_device);
> +		if (result)
>  			goto outpresent;
> -		if (sony_nc_kbd_backlight_setup(sony_pf_device))
> +		result = sony_nc_kbd_backlight_setup(sony_pf_device);
> +		if (result)
>  			goto outsnc;
>  		sony_nc_function_setup(device);
>  		sony_nc_rfkill_setup(device);
-- 
mattia
:wq!

WARNING: multiple messages have this Message-ID (diff)
From: Mattia Dongili <malattia@linux.it>
To: Dan Carpenter <error27@gmail.com>
Cc: Matthew Garrett <mjg@redhat.com>,
	platform-driver-x86@vger.kernel.org,
	kernel-janitors@vger.kernel.org
Subject: Re: [patch 2/4] sony-laptop: return negative on failure in sony_nc_add()
Date: Sun, 27 Feb 2011 21:27:55 +0900	[thread overview]
Message-ID: <20110227122755.GE29319@kamineko.org> (raw)
In-Reply-To: <20110226125456.GJ18043@bicker>

On Sat, Feb 26, 2011 at 03:54:57PM +0300, Dan Carpenter wrote:
> There were two places in sony_nc_add() where we returned zero on failure
> instead of a negative error code.
> 
> Signed-off-by: Dan Carpenter <error27@gmail.com>

Acked-by: Mattia Dongili <malattia@linux.it>

> diff --git a/drivers/platform/x86/sony-laptop.c b/drivers/platform/x86/sony-laptop.c
> index a7b9c72..d0d0522 100644
> --- a/drivers/platform/x86/sony-laptop.c
> +++ b/drivers/platform/x86/sony-laptop.c
> @@ -1593,9 +1593,11 @@ static int sony_nc_add(struct acpi_device *device)
>  	if (ACPI_SUCCESS(acpi_get_handle(sony_nc_acpi_handle, "SN00",
>  					 &handle))) {
>  		dprintk("Doing SNC setup\n");
> -		if (sony_nc_handles_setup(sony_pf_device))
> +		result = sony_nc_handles_setup(sony_pf_device);
> +		if (result)
>  			goto outpresent;
> -		if (sony_nc_kbd_backlight_setup(sony_pf_device))
> +		result = sony_nc_kbd_backlight_setup(sony_pf_device);
> +		if (result)
>  			goto outsnc;
>  		sony_nc_function_setup(device);
>  		sony_nc_rfkill_setup(device);
-- 
mattia
:wq!

  reply	other threads:[~2011-02-27 12:27 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-02-26 12:54 [patch 2/4] sony-laptop: return negative on failure in Dan Carpenter
2011-02-26 12:54 ` [patch 2/4] sony-laptop: return negative on failure in sony_nc_add() Dan Carpenter
2011-02-27 12:27 ` Mattia Dongili [this message]
2011-02-27 12:27   ` Mattia Dongili

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=20110227122755.GE29319@kamineko.org \
    --to=malattia@linux.it \
    --cc=error27@gmail.com \
    --cc=kernel-janitors@vger.kernel.org \
    --cc=mjg@redhat.com \
    --cc=platform-driver-x86@vger.kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.