From: Andrew Morton <akpm@linux-foundation.org>
To: Larry Finger <Larry.Finger@lwfinger.net>
Cc: mjg59@srcf.ucam.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] hp-wmi: Fix warnings
Date: Tue, 11 Nov 2008 14:19:49 -0800 [thread overview]
Message-ID: <20081111141949.38c840d2.akpm@linux-foundation.org> (raw)
In-Reply-To: <490DD6F6.8000708@lwfinger.net>
On Sun, 02 Nov 2008 08:36:06 -0800
Larry Finger <Larry.Finger@lwfinger.net> wrote:
> Subject: [PATCH] hp-wmi: Fix warnings
A nit: the point of such a patch is _not_ to "fix warnings". It is to
fix the issues which those warnings are warning us about!
I renamed the patch to "hp-wmi: handle rfkill_register() failure",
thanks.
> Compilation of the HP WMI hotkeys code results in the following:
>
> CC [M] drivers/misc/hp-wmi.o
> drivers/misc/hp-wmi.c: In function hp_wmi_bios_setup:
> drivers/misc/hp-wmi.c:431: warning: ignoring return value of rfkill_register,
> declared with attribute warn_unused_result
> drivers/misc/hp-wmi.c:441: warning: ignoring return value of rfkill_register,
> declared with attribute warn_unused_result
> drivers/misc/hp-wmi.c:450: warning: ignoring return value of rfkill_register,
> declared with attribute warn_unused_result
>
> Signed-off-by: Larry Finger <Larry.Finger@lwfinger.net>
> ---
>
>
> Index: linux-2.6/drivers/misc/hp-wmi.c
> ===================================================================
> --- linux-2.6.orig/drivers/misc/hp-wmi.c
> +++ linux-2.6/drivers/misc/hp-wmi.c
> @@ -428,7 +428,9 @@ static int __init hp_wmi_bios_setup(stru
> wifi_rfkill->state = hp_wmi_wifi_state();
> wifi_rfkill->toggle_radio = hp_wmi_wifi_set;
> wifi_rfkill->user_claim_unsupported = 1;
> - rfkill_register(wifi_rfkill);
> + err = rfkill_register(wifi_rfkill);
> + if (err)
> + goto add_sysfs_error;
prev parent reply other threads:[~2008-11-11 22:20 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-11-02 16:36 [PATCH] hp-wmi: Fix warnings Larry Finger
2008-11-11 22:19 ` Andrew Morton [this message]
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=20081111141949.38c840d2.akpm@linux-foundation.org \
--to=akpm@linux-foundation.org \
--cc=Larry.Finger@lwfinger.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mjg59@srcf.ucam.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