linux-i2c.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
@ 2015-05-03 18:13 Vasily Khoruzhick
  2015-05-03 23:50 ` Krzysztof Kozlowski
       [not found] ` <1430676790-30500-1-git-send-email-anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
  0 siblings, 2 replies; 7+ messages in thread
From: Vasily Khoruzhick @ 2015-05-03 18:13 UTC (permalink / raw)
  To: Kukjin Kim, Wolfram Sang, linux-samsung-soc, linux-i2c; +Cc: Vasily Khoruzhick

Initialize sysreg by default, otherwise driver will crash in suspend callback.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
---
 drivers/i2c/busses/i2c-s3c2410.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/i2c/busses/i2c-s3c2410.c b/drivers/i2c/busses/i2c-s3c2410.c
index 958c8db..297e9c9 100644
--- a/drivers/i2c/busses/i2c-s3c2410.c
+++ b/drivers/i2c/busses/i2c-s3c2410.c
@@ -1143,6 +1143,7 @@ static int s3c24xx_i2c_probe(struct platform_device *pdev)
 		return -ENOMEM;
 
 	i2c->quirks = s3c24xx_get_device_quirks(pdev);
+	i2c->sysreg = ERR_PTR(-ENOENT);
 	if (pdata)
 		memcpy(i2c->pdata, pdata, sizeof(*pdata));
 	else
-- 
2.3.5

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

* Re: [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
  2015-05-03 18:13 [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms Vasily Khoruzhick
@ 2015-05-03 23:50 ` Krzysztof Kozlowski
       [not found]   ` <CAJKOXPd71vnup-RZYAh7UM2Tky2M64tA=u0Ydy=ti0yOC6h5aQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
       [not found] ` <1430676790-30500-1-git-send-email-anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
  1 sibling, 1 reply; 7+ messages in thread
From: Krzysztof Kozlowski @ 2015-05-03 23:50 UTC (permalink / raw)
  To: Vasily Khoruzhick; +Cc: Kukjin Kim, Wolfram Sang, linux-samsung-soc, linux-i2c

2015-05-04 3:13 GMT+09:00 Vasily Khoruzhick <anarsoul@gmail.com>:
> Initialize sysreg by default, otherwise driver will crash in suspend callback.
>
> Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>

I think the crash is possible if device node is missing in DT or pdata
is supplied. If you agree, could you add this information to commit
message, along with Cc-stable and Fixes tag?

Anyway, the patch itself looks good:
Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>

Best regards,
Krzysztof

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

* Re: [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
       [not found]   ` <CAJKOXPd71vnup-RZYAh7UM2Tky2M64tA=u0Ydy=ti0yOC6h5aQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2015-05-04 17:52     ` Vasily Khoruzhick
       [not found]       ` <CA+E=qVdjvx=0PSh-ead_pABd9D=bG3ua1FFRTSN2U5BVf2a=Og-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  2015-05-05 21:28     ` Kukjin Kim
  1 sibling, 1 reply; 7+ messages in thread
From: Vasily Khoruzhick @ 2015-05-04 17:52 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Kukjin Kim, Wolfram Sang, linux-samsung-soc,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA

On Mon, May 4, 2015 at 2:50 AM, Krzysztof Kozlowski
<k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org> wrote:
> 2015-05-04 3:13 GMT+09:00 Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>:
>> Initialize sysreg by default, otherwise driver will crash in suspend callback.
>>
>> Signed-off-by: Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
>
> I think the crash is possible if device node is missing in DT or pdata
> is supplied.

And it's exactly the case for non-DT boot, right?

> If you agree, could you add this information to commit
> message, along with Cc-stable and Fixes tag?

How do I add "Fixes tag"?

> Anyway, the patch itself looks good:
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
>
> Best regards,
> Krzysztof

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

* Re: [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
       [not found]       ` <CA+E=qVdjvx=0PSh-ead_pABd9D=bG3ua1FFRTSN2U5BVf2a=Og-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
@ 2015-05-05  1:46         ` Krzysztof Kozlowski
  0 siblings, 0 replies; 7+ messages in thread
From: Krzysztof Kozlowski @ 2015-05-05  1:46 UTC (permalink / raw)
  To: Vasily Khoruzhick
  Cc: Krzysztof Kozlowski, Kukjin Kim, Wolfram Sang, linux-samsung-soc,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA

2015-05-05 2:52 GMT+09:00 Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>:
> On Mon, May 4, 2015 at 2:50 AM, Krzysztof Kozlowski
> <k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org> wrote:
>> 2015-05-04 3:13 GMT+09:00 Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>:
>>> Initialize sysreg by default, otherwise driver will crash in suspend callback.
>>>
>>> Signed-off-by: Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
>>
>> I think the crash is possible if device node is missing in DT or pdata
>> is supplied.
>
> And it's exactly the case for non-DT boot, right?

Right, please add this to commit message.

>
>> If you agree, could you add this information to commit
>> message, along with Cc-stable and Fixes tag?
>
> How do I add "Fixes tag"?

In tbe commit message just add below Signed-off-by:
1. Cc: <stable-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>
2. Fixes: abbreviated SHA ("commit subject")
The SHA of commit which introduced this error. It indicates how far
your patch should be backported.

Look for examples in kernel GIT and
Documentation/stable_kernel_rules.txt. For example:
https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=1c363c7cccf64128087002b0779986ad16aff6dc

Best regards,
Krzysztof

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

* Re: [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
       [not found]   ` <CAJKOXPd71vnup-RZYAh7UM2Tky2M64tA=u0Ydy=ti0yOC6h5aQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
  2015-05-04 17:52     ` Vasily Khoruzhick
@ 2015-05-05 21:28     ` Kukjin Kim
  2015-05-05 21:30       ` Kukjin Kim
  1 sibling, 1 reply; 7+ messages in thread
From: Kukjin Kim @ 2015-05-05 21:28 UTC (permalink / raw)
  To: Krzysztof Kozlowski
  Cc: Vasily Khoruzhick, Kukjin Kim, Wolfram Sang,
	linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA

On 05/04/15 08:50, Krzysztof Kozlowski wrote:
> 2015-05-04 3:13 GMT+09:00 Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>:
>> Initialize sysreg by default, otherwise driver will crash in suspend callback.
>>
>> Signed-off-by: Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
> 
> I think the crash is possible if device node is missing in DT or pdata
> is supplied. If you agree, could you add this information to commit
> message, along with Cc-stable and Fixes tag?
> 
> Anyway, the patch itself looks good:
> Reviewed-by: Krzysztof Kozlowski <k.kozlowski-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
> 
Can you please add me in Cc in your next posting?

I can't see the patch in my mail box...

- Kukjin

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

* Re: [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
  2015-05-05 21:28     ` Kukjin Kim
@ 2015-05-05 21:30       ` Kukjin Kim
  0 siblings, 0 replies; 7+ messages in thread
From: Kukjin Kim @ 2015-05-05 21:30 UTC (permalink / raw)
  To: Kukjin Kim
  Cc: Krzysztof Kozlowski, Vasily Khoruzhick, Wolfram Sang,
	linux-samsung-soc, linux-i2c

On 05/06/15 06:28, Kukjin Kim wrote:
> On 05/04/15 08:50, Krzysztof Kozlowski wrote:
>> 2015-05-04 3:13 GMT+09:00 Vasily Khoruzhick <anarsoul@gmail.com>:
>>> Initialize sysreg by default, otherwise driver will crash in suspend callback.
>>>
>>> Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
>>
>> I think the crash is possible if device node is missing in DT or pdata
>> is supplied. If you agree, could you add this information to commit
>> message, along with Cc-stable and Fixes tag?
>>
>> Anyway, the patch itself looks good:
>> Reviewed-by: Krzysztof Kozlowski <k.kozlowski@samsung.com>
>>
> Can you please add me in Cc in your next posting?
> 
> I can't see the patch in my mail box...
> 
Oops, sorry for the noise. My email client had a problem and I can see
the patch now. Please kindly ignore the request :)

Thanks,
Kukjin

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

* Re: [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms
       [not found] ` <1430676790-30500-1-git-send-email-anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
@ 2015-05-12 16:15   ` Wolfram Sang
  0 siblings, 0 replies; 7+ messages in thread
From: Wolfram Sang @ 2015-05-12 16:15 UTC (permalink / raw)
  To: Vasily Khoruzhick
  Cc: Kukjin Kim, linux-samsung-soc-u79uwXL29TY76Z2rM5mHXA,
	linux-i2c-u79uwXL29TY76Z2rM5mHXA

[-- Attachment #1: Type: text/plain, Size: 316 bytes --]

On Sun, May 03, 2015 at 09:13:10PM +0300, Vasily Khoruzhick wrote:
> Initialize sysreg by default, otherwise driver will crash in suspend callback.
> 
> Signed-off-by: Vasily Khoruzhick <anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>

Applied to for-current, thanks!
Added stable and the fixes tag, too.


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

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

end of thread, other threads:[~2015-05-12 16:15 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-03 18:13 [PATCH] i2c: s3c2410: fix oops in suspend callback for non-dt platforms Vasily Khoruzhick
2015-05-03 23:50 ` Krzysztof Kozlowski
     [not found]   ` <CAJKOXPd71vnup-RZYAh7UM2Tky2M64tA=u0Ydy=ti0yOC6h5aQ-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-04 17:52     ` Vasily Khoruzhick
     [not found]       ` <CA+E=qVdjvx=0PSh-ead_pABd9D=bG3ua1FFRTSN2U5BVf2a=Og-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2015-05-05  1:46         ` Krzysztof Kozlowski
2015-05-05 21:28     ` Kukjin Kim
2015-05-05 21:30       ` Kukjin Kim
     [not found] ` <1430676790-30500-1-git-send-email-anarsoul-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2015-05-12 16:15   ` Wolfram Sang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).