All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
       [not found] <CAFVLVSOp750X4L+qgR16Qc53V+jOKsxA-ujskx3K0BX9kQOzTw@mail.gmail.com>
@ 2012-01-11  0:42 ` Jonathan Nieder
  2012-01-11  0:56   ` Jonathan Nieder
                     ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Jonathan Nieder @ 2012-01-11  0:42 UTC (permalink / raw)
  To: stable
  Cc: platform-driver-x86, Artem X, Rene Bolldorf, Matthew Garrett,
	Ike Panhc, Corentin Chary

From: René Bollford <xsecute@googlemail.com>
Date: Sun, 23 Oct 2011 09:56:42 +0200

commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.

This patch avoid a page fault in the ideapad-laptop extras when
turning the backlight power on or off.

Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>
Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Tested-by: Artem X <artem.brz@gmail.com>
---
Artem X wrote:

> I've compiled vanilla 3.1.6 with that patch and turning off blacklight
> was working.

This fixes an oops reported by a few people in the new ideapad-laptop
backlight driver.  See:

 - http://thread.gmane.org/gmane.linux.kernel/1205259
 - http://thread.gmane.org/gmane.linux.drivers.platform.x86.devel/2405
 - http://bugs.debian.org/655377

Luckily the ideapad-laptop backlight driver was introduced in
v3.1-rc1~14^2~29, so older kernels do not have this bug.  Fix is
already included in v3.2.

 drivers/platform/x86/ideapad-laptop.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/drivers/platform/x86/ideapad-laptop.c b/drivers/platform/x86/ideapad-laptop.c
index 0c595410e788..0d94eec00f4d 100644
--- a/drivers/platform/x86/ideapad-laptop.c
+++ b/drivers/platform/x86/ideapad-laptop.c
@@ -493,6 +493,8 @@ static void ideapad_backlight_notify_power(struct ideapad_private *priv)
 	unsigned long power;
 	struct backlight_device *blightdev = priv->blightdev;
 
+	if (!blightdev)
+		return;
 	if (read_ec_data(ideapad_handle, 0x18, &power))
 		return;
 	blightdev->props.power = power ? FB_BLANK_UNBLANK : FB_BLANK_POWERDOWN;
-- 
1.7.8.3

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11  0:42 ` [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault Jonathan Nieder
@ 2012-01-11  0:56   ` Jonathan Nieder
  2012-01-11 11:47   ` Ike Panhc
  2012-01-12 22:59   ` Greg KH
  2 siblings, 0 replies; 8+ messages in thread
From: Jonathan Nieder @ 2012-01-11  0:56 UTC (permalink / raw)
  To: stable
  Cc: platform-driver-x86, Artem X, Rene Bolldorf, Matthew Garrett,
	Ike Panhc, Corentin Chary

Jonathan Nieder wrote:

> From: René Bollford <xsecute@googlemail.com>
> Date: Sun, 23 Oct 2011 09:56:42 +0200
>
> commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.
>
> This patch avoid a page fault in the ideapad-laptop extras when
> turning the backlight power on or off.
>
> Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>

I believe René's last name is Bolldorf, not Bollford as in the "From"
line.  (The typo comes from the commit log and I forgot to check it
before sending.)  Either way --- sorry for the noise, and René, sorry
for mangling your name.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11  0:42 ` [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault Jonathan Nieder
  2012-01-11  0:56   ` Jonathan Nieder
@ 2012-01-11 11:47   ` Ike Panhc
  2012-01-11 16:11     ` Greg KH
  2012-01-12 22:59   ` Greg KH
  2 siblings, 1 reply; 8+ messages in thread
From: Ike Panhc @ 2012-01-11 11:47 UTC (permalink / raw)
  To: Jonathan Nieder
  Cc: stable, platform-driver-x86, Artem X, Rene Bolldorf,
	Matthew Garrett, Corentin Chary

Thanks, and this is necessary for 3.1.y

On 01/11/2012 08:42 AM, Jonathan Nieder wrote:
> From: René Bollford <xsecute@googlemail.com>
> Date: Sun, 23 Oct 2011 09:56:42 +0200
> 
> commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.
> 
> This patch avoid a page fault in the ideapad-laptop extras when
> turning the backlight power on or off.
> 
> Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>
> Signed-off-by: Matthew Garrett <mjg@redhat.com>
> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
> Tested-by: Artem X <artem.brz@gmail.com>

Acked-by: Ike Panhc <ike.pan@canonical.com>

> ---
> Artem X wrote:
> 
>> I've compiled vanilla 3.1.6 with that patch and turning off blacklight
>> was working.
> 
> This fixes an oops reported by a few people in the new ideapad-laptop
> backlight driver.  See:
> 
>  - http://thread.gmane.org/gmane.linux.kernel/1205259
>  - http://thread.gmane.org/gmane.linux.drivers.platform.x86.devel/2405
>  - http://bugs.debian.org/655377
> 
> Luckily the ideapad-laptop backlight driver was introduced in
> v3.1-rc1~14^2~29, so older kernels do not have this bug.  Fix is
> already included in v3.2.
> 
>  drivers/platform/x86/ideapad-laptop.c |    2 ++
>  1 files changed, 2 insertions(+), 0 deletions(-)
> 
> diff --git a/drivers/platform/x86/ideapad-laptop.c b/drivers/platform/x86/ideapad-laptop.c
> index 0c595410e788..0d94eec00f4d 100644
> --- a/drivers/platform/x86/ideapad-laptop.c
> +++ b/drivers/platform/x86/ideapad-laptop.c
> @@ -493,6 +493,8 @@ static void ideapad_backlight_notify_power(struct ideapad_private *priv)
>  	unsigned long power;
>  	struct backlight_device *blightdev = priv->blightdev;
>  
> +	if (!blightdev)
> +		return;
>  	if (read_ec_data(ideapad_handle, 0x18, &power))
>  		return;
>  	blightdev->props.power = power ? FB_BLANK_UNBLANK : FB_BLANK_POWERDOWN;

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11 11:47   ` Ike Panhc
@ 2012-01-11 16:11     ` Greg KH
  2012-01-11 16:40       ` Jonathan Nieder
  0 siblings, 1 reply; 8+ messages in thread
From: Greg KH @ 2012-01-11 16:11 UTC (permalink / raw)
  To: Ike Panhc
  Cc: Jonathan Nieder, stable, platform-driver-x86, Artem X,
	Rene Bolldorf, Matthew Garrett, Corentin Chary

On Wed, Jan 11, 2012 at 07:47:33PM +0800, Ike Panhc wrote:
> Thanks, and this is necessary for 3.1.y
> 
> On 01/11/2012 08:42 AM, Jonathan Nieder wrote:
> > From: René Bollford <xsecute@googlemail.com>
> > Date: Sun, 23 Oct 2011 09:56:42 +0200
> > 
> > commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.
> > 
> > This patch avoid a page fault in the ideapad-laptop extras when
> > turning the backlight power on or off.
> > 
> > Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>
> > Signed-off-by: Matthew Garrett <mjg@redhat.com>
> > Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
> > Tested-by: Artem X <artem.brz@gmail.com>
> 
> Acked-by: Ike Panhc <ike.pan@canonical.com>

<formletter>

This is not the correct way to submit patches for inclusion in the
stable kernel tree.  Please read Documentation/stable_kernel_rules.txt
for how to do this properly.

</formletter>

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11 16:11     ` Greg KH
@ 2012-01-11 16:40       ` Jonathan Nieder
  2012-01-11 17:05         ` Greg KH
  0 siblings, 1 reply; 8+ messages in thread
From: Jonathan Nieder @ 2012-01-11 16:40 UTC (permalink / raw)
  To: Greg KH
  Cc: Ike Panhc, stable, platform-driver-x86, Artem X, Rene Bolldorf,
	Matthew Garrett, Corentin Chary

Greg KH wrote:
>> On 01/11/2012 08:42 AM, Jonathan Nieder wrote:

>>> From: René Bollford <xsecute@googlemail.com>
>>> Date: Sun, 23 Oct 2011 09:56:42 +0200
>>> 
>>> commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.
>>> 
>>> This patch avoid a page fault in the ideapad-laptop extras when
>>> turning the backlight power on or off.
>>> 
>>> Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>
>>> Signed-off-by: Matthew Garrett <mjg@redhat.com>
>>> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
>>> Tested-by: Artem X <artem.brz@gmail.com>
[...]
> <formletter>
>
> This is not the correct way to submit patches for inclusion in the
> stable kernel tree.  Please read Documentation/stable_kernel_rules.txt
> for how to do this properly.
>
> </formletter>

Well, what did I do wrong this time?

 - The patch is obviously correct and tested.
 - It is a two-liner, plus context.
 - It fixes exactly one thing.
 - The bug bothers people, and I gave links to reports.
 - It is an oops (a null pointer dereference).
 - No unrelated "trivial" fixes in there.
 - Follows SubmittingPatches rules, as far as I know.
 - Patch was produced by cherry-picking the commit named above from
   Linus's tree.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11 16:40       ` Jonathan Nieder
@ 2012-01-11 17:05         ` Greg KH
  2012-01-11 18:57           ` Jonathan Nieder
  0 siblings, 1 reply; 8+ messages in thread
From: Greg KH @ 2012-01-11 17:05 UTC (permalink / raw)
  To: Jonathan Nieder
  Cc: Ike Panhc, stable, platform-driver-x86, Artem X, Rene Bolldorf,
	Matthew Garrett, Corentin Chary

On Wed, Jan 11, 2012 at 10:40:28AM -0600, Jonathan Nieder wrote:
> Greg KH wrote:
> >> On 01/11/2012 08:42 AM, Jonathan Nieder wrote:
> 
> >>> From: René Bollford <xsecute@googlemail.com>
> >>> Date: Sun, 23 Oct 2011 09:56:42 +0200
> >>> 
> >>> commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.
> >>> 
> >>> This patch avoid a page fault in the ideapad-laptop extras when
> >>> turning the backlight power on or off.
> >>> 
> >>> Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>
> >>> Signed-off-by: Matthew Garrett <mjg@redhat.com>
> >>> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
> >>> Tested-by: Artem X <artem.brz@gmail.com>
> [...]
> > <formletter>
> >
> > This is not the correct way to submit patches for inclusion in the
> > stable kernel tree.  Please read Documentation/stable_kernel_rules.txt
> > for how to do this properly.
> >
> > </formletter>
> 
> Well, what did I do wrong this time?
> 
>  - The patch is obviously correct and tested.
>  - It is a two-liner, plus context.
>  - It fixes exactly one thing.
>  - The bug bothers people, and I gave links to reports.
>  - It is an oops (a null pointer dereference).
>  - No unrelated "trivial" fixes in there.
>  - Follows SubmittingPatches rules, as far as I know.
>  - Patch was produced by cherry-picking the commit named above from
>    Linus's tree.

Sorry, I missed the 3.1 in the subject line.  That's what I get for
processing email before my morning coffee...

This is all fine, I'll queue it up for the next release.

Oh wait, there isn't going to be another 3.1 kernel release, so this
might not have been needed.  I'll see if others really want another 3.1
release, and if so, I'll add this to it.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11 17:05         ` Greg KH
@ 2012-01-11 18:57           ` Jonathan Nieder
  0 siblings, 0 replies; 8+ messages in thread
From: Jonathan Nieder @ 2012-01-11 18:57 UTC (permalink / raw)
  To: Greg KH
  Cc: Ike Panhc, stable, platform-driver-x86, Artem X, Rene Bolldorf,
	Matthew Garrett, Corentin Chary

Greg KH wrote:

> This is all fine, I'll queue it up for the next release.
>
> Oh wait, there isn't going to be another 3.1 kernel release, so this
> might not have been needed.  I'll see if others really want another 3.1
> release, and if so, I'll add this to it.

Thanks.  Sounds good to me.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault
  2012-01-11  0:42 ` [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault Jonathan Nieder
  2012-01-11  0:56   ` Jonathan Nieder
  2012-01-11 11:47   ` Ike Panhc
@ 2012-01-12 22:59   ` Greg KH
  2 siblings, 0 replies; 8+ messages in thread
From: Greg KH @ 2012-01-12 22:59 UTC (permalink / raw)
  To: Jonathan Nieder
  Cc: stable, platform-driver-x86, Artem X, Rene Bolldorf,
	Matthew Garrett, Ike Panhc, Corentin Chary

On Tue, Jan 10, 2012 at 06:42:56PM -0600, Jonathan Nieder wrote:
> From: René Bollford <xsecute@googlemail.com>
> Date: Sun, 23 Oct 2011 09:56:42 +0200
> 
> commit d4afc7754a60b885b63ef23fd194984e2d53a4e6 upstream.
> 
> This patch avoid a page fault in the ideapad-laptop extras when
> turning the backlight power on or off.
> 
> Signed-off-by: Rene Bolldorf <xsecute@googlemail.com>
> Signed-off-by: Matthew Garrett <mjg@redhat.com>
> Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
> Tested-by: Artem X <artem.brz@gmail.com>
> ---
> Artem X wrote:
> 
> > I've compiled vanilla 3.1.6 with that patch and turning off blacklight
> > was working.
> 
> This fixes an oops reported by a few people in the new ideapad-laptop
> backlight driver.  See:
> 
>  - http://thread.gmane.org/gmane.linux.kernel/1205259
>  - http://thread.gmane.org/gmane.linux.drivers.platform.x86.devel/2405
>  - http://bugs.debian.org/655377
> 
> Luckily the ideapad-laptop backlight driver was introduced in
> v3.1-rc1~14^2~29, so older kernels do not have this bug.  Fix is
> already included in v3.2.

Now applied, thanks.

greg k-h

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2012-01-12 23:04 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <CAFVLVSOp750X4L+qgR16Qc53V+jOKsxA-ujskx3K0BX9kQOzTw@mail.gmail.com>
2012-01-11  0:42 ` [PATCH linux-3.1.y] ideapad: Check if acpi already handle backlight power to avoid a page fault Jonathan Nieder
2012-01-11  0:56   ` Jonathan Nieder
2012-01-11 11:47   ` Ike Panhc
2012-01-11 16:11     ` Greg KH
2012-01-11 16:40       ` Jonathan Nieder
2012-01-11 17:05         ` Greg KH
2012-01-11 18:57           ` Jonathan Nieder
2012-01-12 22:59   ` Greg KH

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.