* Oops in mpc52xx_uart_init (2.6.34-rc5)
@ 2010-05-04 20:39 Leonardo Chiquitto
2010-05-04 21:14 ` Anatolij Gustschin
2010-05-04 22:18 ` Anatolij Gustschin
0 siblings, 2 replies; 12+ messages in thread
From: Leonardo Chiquitto @ 2010-05-04 20:39 UTC (permalink / raw)
To: linuxppc-dev; +Cc: Anatolij Gustschin
[-- Attachment #1: Type: text/plain, Size: 565 bytes --]
Hello,
Kernel 2.6.34-rc5 crashes on boot in a ppc32 machine (Mac Mini G4).
Reverting the following commit makes the kernel boot normally again:
commit 6acc6833510db8f72b5ef343296d97480555fda9
Author: Anatolij Gustschin <agust@denx.de>
Date: Tue Feb 16 22:30:03 2010 -0700
serial: mpc52xx_uart: re-enable mpc5121 PSC UART support
I'm attaching a photo with the panic message and call trace (I apologize
for the poor image quality and cropped left border). Please let me know if I
can provide any other info to help debugging this issue.
Thanks,
Leonardo
[-- Attachment #2: mpc52xx-oops.jpg --]
[-- Type: image/jpeg, Size: 101883 bytes --]
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: Oops in mpc52xx_uart_init (2.6.34-rc5)
2010-05-04 20:39 Oops in mpc52xx_uart_init (2.6.34-rc5) Leonardo Chiquitto
@ 2010-05-04 21:14 ` Anatolij Gustschin
2010-05-04 22:18 ` Anatolij Gustschin
1 sibling, 0 replies; 12+ messages in thread
From: Anatolij Gustschin @ 2010-05-04 21:14 UTC (permalink / raw)
To: Leonardo Chiquitto; +Cc: linuxppc-dev
On Tue, 4 May 2010 17:39:25 -0300
Leonardo Chiquitto <leonardo.lists@gmail.com> wrote:
> Kernel 2.6.34-rc5 crashes on boot in a ppc32 machine (Mac Mini G4).
>
> Reverting the following commit makes the kernel boot normally again:
>
> commit 6acc6833510db8f72b5ef343296d97480555fda9
> Author: Anatolij Gustschin <agust@denx.de>
> Date: Tue Feb 16 22:30:03 2010 -0700
>
> serial: mpc52xx_uart: re-enable mpc5121 PSC UART support
>
> I'm attaching a photo with the panic message and call trace (I apologize
> for the poor image quality and cropped left border). Please let me know if I
> can provide any other info to help debugging this issue.
Thanks for the bug report! This info is enough, I will submit a
fix soon.
Thanks,
Anatolij
^ permalink raw reply [flat|nested] 12+ messages in thread
* [PATCH] serial: mpc52xx_uart: fix null pointer dereference
2010-05-04 20:39 Oops in mpc52xx_uart_init (2.6.34-rc5) Leonardo Chiquitto
@ 2010-05-04 22:18 ` Anatolij Gustschin
2010-05-04 22:18 ` Anatolij Gustschin
1 sibling, 0 replies; 12+ messages in thread
From: Anatolij Gustschin @ 2010-05-04 22:18 UTC (permalink / raw)
To: linux-kernel
Cc: linuxppc-dev, grant.likely, leonardo.lists, gregkh, Anatolij Gustschin
Commit 6acc6833510db8f72b5ef343296d97480555fda9
introduced NULL pointer dereference and kernel crash
on ppc32 machines while booting. Fix this bug now.
Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
Signed-off-by: Anatolij Gustschin <agust@denx.de>
---
drivers/serial/mpc52xx_uart.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.c
index a176ab4..02469c3 100644
--- a/drivers/serial/mpc52xx_uart.c
+++ b/drivers/serial/mpc52xx_uart.c
@@ -1467,7 +1467,7 @@ mpc52xx_uart_init(void)
/*
* Map the PSC FIFO Controller and init if on MPC512x.
*/
- if (psc_ops->fifoc_init) {
+ if (psc_ops && psc_ops->fifoc_init) {
ret = psc_ops->fifoc_init();
if (ret)
return ret;
--
1.7.0.4
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [PATCH] serial: mpc52xx_uart: fix null pointer dereference
@ 2010-05-04 22:18 ` Anatolij Gustschin
0 siblings, 0 replies; 12+ messages in thread
From: Anatolij Gustschin @ 2010-05-04 22:18 UTC (permalink / raw)
To: linux-kernel; +Cc: linuxppc-dev, leonardo.lists, gregkh, Anatolij Gustschin
Commit 6acc6833510db8f72b5ef343296d97480555fda9
introduced NULL pointer dereference and kernel crash
on ppc32 machines while booting. Fix this bug now.
Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
Signed-off-by: Anatolij Gustschin <agust@denx.de>
---
drivers/serial/mpc52xx_uart.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.c
index a176ab4..02469c3 100644
--- a/drivers/serial/mpc52xx_uart.c
+++ b/drivers/serial/mpc52xx_uart.c
@@ -1467,7 +1467,7 @@ mpc52xx_uart_init(void)
/*
* Map the PSC FIFO Controller and init if on MPC512x.
*/
- if (psc_ops->fifoc_init) {
+ if (psc_ops && psc_ops->fifoc_init) {
ret = psc_ops->fifoc_init();
if (ret)
return ret;
--
1.7.0.4
^ permalink raw reply related [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
2010-05-04 22:18 ` Anatolij Gustschin
@ 2010-05-05 12:40 ` Leonardo Chiquitto
-1 siblings, 0 replies; 12+ messages in thread
From: Leonardo Chiquitto @ 2010-05-05 12:40 UTC (permalink / raw)
To: Anatolij Gustschin; +Cc: linux-kernel, linuxppc-dev, grant.likely, gregkh
On Tue, May 4, 2010 at 7:18 PM, Anatolij Gustschin <agust@denx.de> wrote:
> Commit 6acc6833510db8f72b5ef343296d97480555fda9
> introduced NULL pointer dereference and kernel crash
> on ppc32 machines while booting. Fix this bug now.
>
> Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
> Signed-off-by: Anatolij Gustschin <agust@denx.de>
> ---
> drivers/serial/mpc52xx_uart.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.c
> index a176ab4..02469c3 100644
> --- a/drivers/serial/mpc52xx_uart.c
> +++ b/drivers/serial/mpc52xx_uart.c
> @@ -1467,7 +1467,7 @@ mpc52xx_uart_init(void)
> /*
> * Map the PSC FIFO Controller and init if on MPC512x.
> */
> - if (psc_ops->fifoc_init) {
> + if (psc_ops && psc_ops->fifoc_init) {
> ret = psc_ops->fifoc_init();
> if (ret)
> return ret;
> --
> 1.7.0.4
Thanks for the quick fix, Anatolij. I just tested it and confirm it resolves
the problem.
Leonardo
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
@ 2010-05-05 12:40 ` Leonardo Chiquitto
0 siblings, 0 replies; 12+ messages in thread
From: Leonardo Chiquitto @ 2010-05-05 12:40 UTC (permalink / raw)
To: Anatolij Gustschin; +Cc: linuxppc-dev, gregkh, linux-kernel
On Tue, May 4, 2010 at 7:18 PM, Anatolij Gustschin <agust@denx.de> wrote:
> Commit 6acc6833510db8f72b5ef343296d97480555fda9
> introduced NULL pointer dereference and kernel crash
> on ppc32 machines while booting. Fix this bug now.
>
> Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
> Signed-off-by: Anatolij Gustschin <agust@denx.de>
> ---
> =A0drivers/serial/mpc52xx_uart.c | =A0 =A02 +-
> =A01 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.=
c
> index a176ab4..02469c3 100644
> --- a/drivers/serial/mpc52xx_uart.c
> +++ b/drivers/serial/mpc52xx_uart.c
> @@ -1467,7 +1467,7 @@ mpc52xx_uart_init(void)
> =A0 =A0 =A0 =A0/*
> =A0 =A0 =A0 =A0 * Map the PSC FIFO Controller and init if on MPC512x.
> =A0 =A0 =A0 =A0 */
> - =A0 =A0 =A0 if (psc_ops->fifoc_init) {
> + =A0 =A0 =A0 if (psc_ops && psc_ops->fifoc_init) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0ret =3D psc_ops->fifoc_init();
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (ret)
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0return ret;
> --
> 1.7.0.4
Thanks for the quick fix, Anatolij. I just tested it and confirm it resolve=
s
the problem.
Leonardo
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
2010-05-04 22:18 ` Anatolij Gustschin
@ 2010-05-09 22:04 ` Grant Likely
-1 siblings, 0 replies; 12+ messages in thread
From: Grant Likely @ 2010-05-09 22:04 UTC (permalink / raw)
To: Anatolij Gustschin
Cc: linux-kernel, linuxppc-dev, leonardo.lists, gregkh, Andrew Morton
On Wed, May 5, 2010 at 12:18 AM, Anatolij Gustschin <agust@denx.de> wrote:
> Commit 6acc6833510db8f72b5ef343296d97480555fda9
> introduced NULL pointer dereference and kernel crash
> on ppc32 machines while booting. Fix this bug now.
>
> Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
> Signed-off-by: Anatolij Gustschin <agust@denx.de>
Thanks for being so quick to pick up on this Anatolij. I've been
traveling and not able to respond to stuff. I see that Greg has
already picked this up (thanks Greg!), but FWIW:
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Actually, now that I look, this fix needs to go into Linus' tree right
away (not just linux-next) since the offending patch went in during
the 2.6.34 merge window.
Greg, I can either pick this up and push it out to Linus tomorrow, or
let you do it. Whichever you prefer. Let me know so I don't cause
conflicts in your tree.
On another note, this patch isn't actually the right fix, but that's
because this driver is such a horribly bad example of handling private
data that doing the right thing requires some re-architecting. The
driver should not need any of that extra code in the module_init hook.
For now this is the best thing to do, but I'll dig into it tomorrow
and see if I can churn out a patch to fix it properly for the 2.6.35
merge window.
Cheers and thanks,
g.
> ---
> drivers/serial/mpc52xx_uart.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.c
> index a176ab4..02469c3 100644
> --- a/drivers/serial/mpc52xx_uart.c
> +++ b/drivers/serial/mpc52xx_uart.c
> @@ -1467,7 +1467,7 @@ mpc52xx_uart_init(void)
> /*
> * Map the PSC FIFO Controller and init if on MPC512x.
> */
> - if (psc_ops->fifoc_init) {
> + if (psc_ops && psc_ops->fifoc_init) {
> ret = psc_ops->fifoc_init();
> if (ret)
> return ret;
> --
> 1.7.0.4
>
>
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
@ 2010-05-09 22:04 ` Grant Likely
0 siblings, 0 replies; 12+ messages in thread
From: Grant Likely @ 2010-05-09 22:04 UTC (permalink / raw)
To: Anatolij Gustschin
Cc: linuxppc-dev, leonardo.lists, gregkh, linux-kernel, Andrew Morton
On Wed, May 5, 2010 at 12:18 AM, Anatolij Gustschin <agust@denx.de> wrote:
> Commit 6acc6833510db8f72b5ef343296d97480555fda9
> introduced NULL pointer dereference and kernel crash
> on ppc32 machines while booting. Fix this bug now.
>
> Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
> Signed-off-by: Anatolij Gustschin <agust@denx.de>
Thanks for being so quick to pick up on this Anatolij. I've been
traveling and not able to respond to stuff. I see that Greg has
already picked this up (thanks Greg!), but FWIW:
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Actually, now that I look, this fix needs to go into Linus' tree right
away (not just linux-next) since the offending patch went in during
the 2.6.34 merge window.
Greg, I can either pick this up and push it out to Linus tomorrow, or
let you do it. Whichever you prefer. Let me know so I don't cause
conflicts in your tree.
On another note, this patch isn't actually the right fix, but that's
because this driver is such a horribly bad example of handling private
data that doing the right thing requires some re-architecting. The
driver should not need any of that extra code in the module_init hook.
For now this is the best thing to do, but I'll dig into it tomorrow
and see if I can churn out a patch to fix it properly for the 2.6.35
merge window.
Cheers and thanks,
g.
> ---
> =A0drivers/serial/mpc52xx_uart.c | =A0 =A02 +-
> =A01 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/serial/mpc52xx_uart.c b/drivers/serial/mpc52xx_uart.=
c
> index a176ab4..02469c3 100644
> --- a/drivers/serial/mpc52xx_uart.c
> +++ b/drivers/serial/mpc52xx_uart.c
> @@ -1467,7 +1467,7 @@ mpc52xx_uart_init(void)
> =A0 =A0 =A0 =A0/*
> =A0 =A0 =A0 =A0 * Map the PSC FIFO Controller and init if on MPC512x.
> =A0 =A0 =A0 =A0 */
> - =A0 =A0 =A0 if (psc_ops->fifoc_init) {
> + =A0 =A0 =A0 if (psc_ops && psc_ops->fifoc_init) {
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0ret =3D psc_ops->fifoc_init();
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0if (ret)
> =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0return ret;
> --
> 1.7.0.4
>
>
--=20
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
2010-05-09 22:04 ` Grant Likely
@ 2010-05-10 16:25 ` Greg KH
-1 siblings, 0 replies; 12+ messages in thread
From: Greg KH @ 2010-05-10 16:25 UTC (permalink / raw)
To: Grant Likely
Cc: Anatolij Gustschin, linux-kernel, linuxppc-dev, leonardo.lists,
Andrew Morton
On Mon, May 10, 2010 at 12:04:30AM +0200, Grant Likely wrote:
> On Wed, May 5, 2010 at 12:18 AM, Anatolij Gustschin <agust@denx.de> wrote:
> > Commit 6acc6833510db8f72b5ef343296d97480555fda9
> > introduced NULL pointer dereference and kernel crash
> > on ppc32 machines while booting. Fix this bug now.
> >
> > Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
> > Signed-off-by: Anatolij Gustschin <agust@denx.de>
>
> Thanks for being so quick to pick up on this Anatolij. I've been
> traveling and not able to respond to stuff. I see that Greg has
> already picked this up (thanks Greg!), but FWIW:
>
> Acked-by: Grant Likely <grant.likely@secretlab.ca>
>
> Actually, now that I look, this fix needs to go into Linus' tree right
> away (not just linux-next) since the offending patch went in during
> the 2.6.34 merge window.
>
> Greg, I can either pick this up and push it out to Linus tomorrow, or
> let you do it. Whichever you prefer. Let me know so I don't cause
> conflicts in your tree.
I have 2 other tty/serial fixes to go to Linus for .34 along with this
one, so I'll be glad to send it to him. I've added your ack to the
patch.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
@ 2010-05-10 16:25 ` Greg KH
0 siblings, 0 replies; 12+ messages in thread
From: Greg KH @ 2010-05-10 16:25 UTC (permalink / raw)
To: Grant Likely
Cc: linuxppc-dev, leonardo.lists, Anatolij Gustschin, linux-kernel,
Andrew Morton
On Mon, May 10, 2010 at 12:04:30AM +0200, Grant Likely wrote:
> On Wed, May 5, 2010 at 12:18 AM, Anatolij Gustschin <agust@denx.de> wrote:
> > Commit 6acc6833510db8f72b5ef343296d97480555fda9
> > introduced NULL pointer dereference and kernel crash
> > on ppc32 machines while booting. Fix this bug now.
> >
> > Reported-by: Leonardo Chiquitto <leonardo.lists@gmail.com>
> > Signed-off-by: Anatolij Gustschin <agust@denx.de>
>
> Thanks for being so quick to pick up on this Anatolij. I've been
> traveling and not able to respond to stuff. I see that Greg has
> already picked this up (thanks Greg!), but FWIW:
>
> Acked-by: Grant Likely <grant.likely@secretlab.ca>
>
> Actually, now that I look, this fix needs to go into Linus' tree right
> away (not just linux-next) since the offending patch went in during
> the 2.6.34 merge window.
>
> Greg, I can either pick this up and push it out to Linus tomorrow, or
> let you do it. Whichever you prefer. Let me know so I don't cause
> conflicts in your tree.
I have 2 other tty/serial fixes to go to Linus for .34 along with this
one, so I'll be glad to send it to him. I've added your ack to the
patch.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
2010-05-10 16:25 ` Greg KH
@ 2010-05-10 20:46 ` Grant Likely
-1 siblings, 0 replies; 12+ messages in thread
From: Grant Likely @ 2010-05-10 20:46 UTC (permalink / raw)
To: Greg KH
Cc: Anatolij Gustschin, linux-kernel, linuxppc-dev, leonardo.lists,
Andrew Morton
On Mon, May 10, 2010 at 6:25 PM, Greg KH <gregkh@suse.de> wrote:
> On Mon, May 10, 2010 at 12:04:30AM +0200, Grant Likely wrote:
>> Greg, I can either pick this up and push it out to Linus tomorrow, or
>> let you do it. Whichever you prefer. Let me know so I don't cause
>> conflicts in your tree.
>
> I have 2 other tty/serial fixes to go to Linus for .34 along with this
> one, so I'll be glad to send it to him. I've added your ack to the
> patch.
Perfect. Thanks Greg.
g.
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH] serial: mpc52xx_uart: fix null pointer dereference
@ 2010-05-10 20:46 ` Grant Likely
0 siblings, 0 replies; 12+ messages in thread
From: Grant Likely @ 2010-05-10 20:46 UTC (permalink / raw)
To: Greg KH
Cc: linuxppc-dev, leonardo.lists, Anatolij Gustschin, linux-kernel,
Andrew Morton
On Mon, May 10, 2010 at 6:25 PM, Greg KH <gregkh@suse.de> wrote:
> On Mon, May 10, 2010 at 12:04:30AM +0200, Grant Likely wrote:
>> Greg, I can either pick this up and push it out to Linus tomorrow, or
>> let you do it. =A0Whichever you prefer. =A0Let me know so I don't cause
>> conflicts in your tree.
>
> I have 2 other tty/serial fixes to go to Linus for .34 along with this
> one, so I'll be glad to send it to him. =A0I've added your ack to the
> patch.
Perfect. Thanks Greg.
g.
^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2010-05-10 20:46 UTC | newest]
Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-05-04 20:39 Oops in mpc52xx_uart_init (2.6.34-rc5) Leonardo Chiquitto
2010-05-04 21:14 ` Anatolij Gustschin
2010-05-04 22:18 ` [PATCH] serial: mpc52xx_uart: fix null pointer dereference Anatolij Gustschin
2010-05-04 22:18 ` Anatolij Gustschin
2010-05-05 12:40 ` Leonardo Chiquitto
2010-05-05 12:40 ` Leonardo Chiquitto
2010-05-09 22:04 ` Grant Likely
2010-05-09 22:04 ` Grant Likely
2010-05-10 16:25 ` Greg KH
2010-05-10 16:25 ` Greg KH
2010-05-10 20:46 ` Grant Likely
2010-05-10 20:46 ` Grant Likely
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.