Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-13 Thread Takashi Iwai
At Sun, 12 May 2013 21:59:51 +0800, Ming Lei wrote: > > On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: > > > > --- > > From: Takashi Iwai > > Subject: [PATCH v2] firmware: Avoid deadlock of usermodehelper lock at > > shutdown > > > > When a system goes to reboot/shutdown, it tries to disab

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-13 Thread Takashi Iwai
At Sun, 12 May 2013 21:32:39 +0800, Ming Lei wrote: > > On Sun, May 12, 2013 at 3:20 PM, Takashi Iwai wrote: > > At Sat, 11 May 2013 21:01:27 +0800, > > Ming Lei wrote: > >> > >> On Fri, May 10, 2013 at 5:32 PM, Takashi Iwai wrote: > >> > At Fri, 10 May 2013 09:25:51 +0800, > >> >> > >> >> Anywa

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-12 Thread Ming Lei
On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: > > --- > From: Takashi Iwai > Subject: [PATCH v2] firmware: Avoid deadlock of usermodehelper lock at > shutdown > > When a system goes to reboot/shutdown, it tries to disable the > usermode helper via usermodehelper_disable(). This might be b

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-12 Thread Ming Lei
On Sun, May 12, 2013 at 3:20 PM, Takashi Iwai wrote: > At Sat, 11 May 2013 21:01:27 +0800, > Ming Lei wrote: >> >> On Fri, May 10, 2013 at 5:32 PM, Takashi Iwai wrote: >> > At Fri, 10 May 2013 09:25:51 +0800, >> >> >> >> Anyway, if you want to force killing loader, please only kill these >> >> FW

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-12 Thread Takashi Iwai
At Sat, 11 May 2013 21:01:27 +0800, Ming Lei wrote: > > On Fri, May 10, 2013 at 5:32 PM, Takashi Iwai wrote: > > At Fri, 10 May 2013 09:25:51 +0800, > >> > >> Anyway, if you want to force killing loader, please only kill these > >> FW_ACTION_NOHOTPLUG before suspend and reboot, and do > >> not to

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-11 Thread Ming Lei
On Fri, May 10, 2013 at 5:32 PM, Takashi Iwai wrote: > At Fri, 10 May 2013 09:25:51 +0800, >> >> Anyway, if you want to force killing loader, please only kill these >> FW_ACTION_NOHOTPLUG before suspend and reboot, and do >> not touch FW_ACTION_HOTPLUG. Is it OK for you? > > Note that, as with my

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-10 Thread Takashi Iwai
At Fri, 10 May 2013 09:25:51 +0800, Ming Lei wrote: > > On Fri, May 10, 2013 at 1:04 AM, Takashi Iwai wrote: > > At Thu, 9 May 2013 16:43:28 +0800, > > Ming Lei wrote: > >> > >> On Thu, May 9, 2013 at 3:31 PM, Takashi Iwai wrote: > >> > At Thu, 9 May 2013 09:25:35 +0800, > >> > Ming Lei wrote: >

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-09 Thread Ming Lei
On Fri, May 10, 2013 at 1:04 AM, Takashi Iwai wrote: > At Thu, 9 May 2013 16:43:28 +0800, > Ming Lei wrote: >> >> On Thu, May 9, 2013 at 3:31 PM, Takashi Iwai wrote: >> > At Thu, 9 May 2013 09:25:35 +0800, >> > Ming Lei wrote: >> >> >> >> On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: >> >>

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-09 Thread Takashi Iwai
At Thu, 9 May 2013 16:43:28 +0800, Ming Lei wrote: > > On Thu, May 9, 2013 at 3:31 PM, Takashi Iwai wrote: > > At Thu, 9 May 2013 09:25:35 +0800, > > Ming Lei wrote: > >> > >> On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: > >> >> In other words, the first patch is no essential part of the

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-09 Thread Ming Lei
On Thu, May 9, 2013 at 3:31 PM, Takashi Iwai wrote: > At Thu, 9 May 2013 09:25:35 +0800, > Ming Lei wrote: >> >> On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: >> >> In other words, the first patch is no essential part of the fix. >> >> I can revisit the second patch without this one and res

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-09 Thread Takashi Iwai
At Thu, 9 May 2013 09:25:35 +0800, Ming Lei wrote: > > On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: > >> In other words, the first patch is no essential part of the fix. > >> I can revisit the second patch without this one and resend if > >> preferred. > > > > FWIW, below is the revised pa

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-08 Thread Ming Lei
On Thu, May 9, 2013 at 1:51 AM, Takashi Iwai wrote: >> In other words, the first patch is no essential part of the fix. >> I can revisit the second patch without this one and resend if >> preferred. > > FWIW, below is the revised patch. > It's alone without the patch 1 in the previous series. The

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-08 Thread Takashi Iwai
At Wed, 08 May 2013 18:37:01 +0200, Takashi Iwai wrote: > > At Wed, 08 May 2013 18:21:11 +0200, > Takashi Iwai wrote: > > > > At Wed, 8 May 2013 23:52:02 +0800, > > Ming Lei wrote: > > > > > > On Wed, May 8, 2013 at 2:56 PM, Takashi Iwai wrote: > > > > When a firmware file can be loaded directl

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-08 Thread Takashi Iwai
At Wed, 08 May 2013 18:21:11 +0200, Takashi Iwai wrote: > > At Wed, 8 May 2013 23:52:02 +0800, > Ming Lei wrote: > > > > On Wed, May 8, 2013 at 2:56 PM, Takashi Iwai wrote: > > > When a firmware file can be loaded directly, there is no good reason > > > to lock usermodehelper. It's needed only

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-08 Thread Takashi Iwai
At Wed, 8 May 2013 23:52:02 +0800, Ming Lei wrote: > > On Wed, May 8, 2013 at 2:56 PM, Takashi Iwai wrote: > > When a firmware file can be loaded directly, there is no good reason > > to lock usermodehelper. It's needed only when the direct fw load > > fails and falls back to the user-mode helpe

Re: [PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-08 Thread Ming Lei
On Wed, May 8, 2013 at 2:56 PM, Takashi Iwai wrote: > When a firmware file can be loaded directly, there is no good reason > to lock usermodehelper. It's needed only when the direct fw load > fails and falls back to the user-mode helper. I remembered that we discussed the problem before, :-) So

[PATCH 1/3] firmware: Avoid superfluous usermodehelper lock

2013-05-07 Thread Takashi Iwai
When a firmware file can be loaded directly, there is no good reason to lock usermodehelper. It's needed only when the direct fw load fails and falls back to the user-mode helper. Signed-off-by: Takashi Iwai --- drivers/base/firmware_class.c | 42 +++--- 1 fi