Re: [PATCH] firmware: wake all waiters

2017-07-12 Thread Luis R. Rodriguez
On Wed, Jul 05, 2017 at 09:33:38AM -0700, Linus Torvalds wrote: > On Wed, Jul 5, 2017 at 9:18 AM, Peter Zijlstra wrote: > > In any case, I'm not seeing why you call it idiotic. > > Have you read the problems? > > There were originally three users: > > - one of them is

Re: [PATCH] firmware: wake all waiters

2017-07-12 Thread Luis R. Rodriguez
On Wed, Jul 05, 2017 at 09:33:38AM -0700, Linus Torvalds wrote: > On Wed, Jul 5, 2017 at 9:18 AM, Peter Zijlstra wrote: > > In any case, I'm not seeing why you call it idiotic. > > Have you read the problems? > > There were originally three users: > > - one of them is firmware loading, and it

Re: [PATCH] firmware: wake all waiters

2017-07-05 Thread Linus Torvalds
On Wed, Jul 5, 2017 at 9:18 AM, Peter Zijlstra wrote: > > So swait should be capable of most things people want from a waitqueue. But what's the point? Regular wait-queues work fine. The advantages of swait aren't huge even if you fix the crap it does now. And the

Re: [PATCH] firmware: wake all waiters

2017-07-05 Thread Linus Torvalds
On Wed, Jul 5, 2017 at 9:18 AM, Peter Zijlstra wrote: > > So swait should be capable of most things people want from a waitqueue. But what's the point? Regular wait-queues work fine. The advantages of swait aren't huge even if you fix the crap it does now. And the disadvantages of "another

Re: [PATCH] firmware: wake all waiters

2017-07-05 Thread Peter Zijlstra
On Tue, Jun 27, 2017 at 01:30:30AM +0200, Luis R. Rodriguez wrote: > > But the *only* reason for swait is extreme memory issues and some very > > special realtime issues, where it saves a couple of bytes in > > structures that need close packing, and doesn't even use normal > > spinlocks, so it

Re: [PATCH] firmware: wake all waiters

2017-07-05 Thread Peter Zijlstra
On Tue, Jun 27, 2017 at 01:30:30AM +0200, Luis R. Rodriguez wrote: > > But the *only* reason for swait is extreme memory issues and some very > > special realtime issues, where it saves a couple of bytes in > > structures that need close packing, and doesn't even use normal > > spinlocks, so it

Re: [PATCH] firmware: wake all waiters

2017-06-30 Thread Davidlohr Bueso
On Thu, 29 Jun 2017, Luis R. Rodriguez wrote: And do we want to make it even more *special-use* by wrapping it with #ifndef MODULE as suggested by Matthew Wilcox ? Not if we want to add any sort of module that tests swait vs wait. Thanks, Davidlohr

Re: [PATCH] firmware: wake all waiters

2017-06-30 Thread Davidlohr Bueso
On Thu, 29 Jun 2017, Luis R. Rodriguez wrote: And do we want to make it even more *special-use* by wrapping it with #ifndef MODULE as suggested by Matthew Wilcox ? Not if we want to add any sort of module that tests swait vs wait. Thanks, Davidlohr

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-29 Thread Daniel Wagner
On 06/28/2017 06:06 PM, Luis R. Rodriguez wrote: On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering wrote: On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: I think it was first packaged into systemd, and then it was split out to help those who want

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-29 Thread Daniel Wagner
On 06/28/2017 06:06 PM, Luis R. Rodriguez wrote: On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering wrote: On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: I think it was first packaged into systemd, and then it was split out to help those who want it external.

Re: [PATCH] firmware: wake all waiters

2017-06-29 Thread Luis R. Rodriguez
On Thu, Jun 29, 2017 at 12:08 PM, Davidlohr Bueso wrote: > On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: >> >> * As a side effect of this; the data structures are slimmer. >> * >> - * One would recommend using this wait queue where possible. >> + * NOTE: swait is for cases of

Re: [PATCH] firmware: wake all waiters

2017-06-29 Thread Luis R. Rodriguez
On Thu, Jun 29, 2017 at 12:08 PM, Davidlohr Bueso wrote: > On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: >> >> * As a side effect of this; the data structures are slimmer. >> * >> - * One would recommend using this wait queue where possible. >> + * NOTE: swait is for cases of extreme memory

Re: [PATCH] firmware: wake all waiters

2017-06-29 Thread Davidlohr Bueso
On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: * As a side effect of this; the data structures are slimmer. * - * One would recommend using this wait queue where possible. + * NOTE: swait is for cases of extreme memory considerations and some very + * special realtime issues, where it saves a

Re: [PATCH] firmware: wake all waiters

2017-06-29 Thread Davidlohr Bueso
On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: * As a side effect of this; the data structures are slimmer. * - * One would recommend using this wait queue where possible. + * NOTE: swait is for cases of extreme memory considerations and some very + * special realtime issues, where it saves a

Re: [PATCH] firmware: wake all waiters

2017-06-28 Thread Davidlohr Bueso
Hi Luis! On Wed, 28 Jun 2017, Luis R. Rodriguez wrote: On Wed, Jun 28, 2017 at 06:45:14AM -0700, Davidlohr Bueso wrote: On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: > diff --git a/include/linux/swait.h b/include/linux/swait.h > index 4a4e180d0a35..14fcf23cece4 100644 > ---

Re: [PATCH] firmware: wake all waiters

2017-06-28 Thread Davidlohr Bueso
Hi Luis! On Wed, 28 Jun 2017, Luis R. Rodriguez wrote: On Wed, Jun 28, 2017 at 06:45:14AM -0700, Davidlohr Bueso wrote: On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: > diff --git a/include/linux/swait.h b/include/linux/swait.h > index 4a4e180d0a35..14fcf23cece4 100644 > ---

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Luis R. Rodriguez
On Wed, Jun 28, 2017 at 06:21:09PM +0200, Lennart Poettering wrote: > On Wed, 28.06.17 09:06, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > > On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering > > wrote: > > > On Wed, 28.06.17 00:24, Luis R. Rodriguez

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Luis R. Rodriguez
On Wed, Jun 28, 2017 at 06:21:09PM +0200, Lennart Poettering wrote: > On Wed, 28.06.17 09:06, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > > On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering > > wrote: > > > On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > > > > >>

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Lennart Poettering
On Wed, 28.06.17 09:06, Luis R. Rodriguez (mcg...@kernel.org) wrote: > On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering > wrote: > > On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > > >> > Do you know how systemd developers feel about the issue

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Lennart Poettering
On Wed, 28.06.17 09:06, Luis R. Rodriguez (mcg...@kernel.org) wrote: > On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering > wrote: > > On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > > >> > Do you know how systemd developers feel about the issue (CCed)? Given > >> >

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Luis R. Rodriguez
On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering wrote: > On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > >> > Do you know how systemd developers feel about the issue (CCed)? Given >> > that it seems to dominate in data center OSes now I'm

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Luis R. Rodriguez
On Wed, Jun 28, 2017 at 12:06 AM, Lennart Poettering wrote: > On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > >> > Do you know how systemd developers feel about the issue (CCed)? Given >> > that it seems to dominate in data center OSes now I'm slightly worried >> > having

Re: [PATCH] firmware: wake all waiters

2017-06-28 Thread Luis R. Rodriguez
On Wed, Jun 28, 2017 at 06:45:14AM -0700, Davidlohr Bueso wrote: > On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: > > > diff --git a/include/linux/swait.h b/include/linux/swait.h > > index 4a4e180d0a35..14fcf23cece4 100644 > > --- a/include/linux/swait.h > > +++ b/include/linux/swait.h > > @@

Re: [PATCH] firmware: wake all waiters

2017-06-28 Thread Luis R. Rodriguez
On Wed, Jun 28, 2017 at 06:45:14AM -0700, Davidlohr Bueso wrote: > On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: > > > diff --git a/include/linux/swait.h b/include/linux/swait.h > > index 4a4e180d0a35..14fcf23cece4 100644 > > --- a/include/linux/swait.h > > +++ b/include/linux/swait.h > > @@

Re: [PATCH] firmware: wake all waiters

2017-06-28 Thread Davidlohr Bueso
On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: diff --git a/include/linux/swait.h b/include/linux/swait.h index 4a4e180d0a35..14fcf23cece4 100644 --- a/include/linux/swait.h +++ b/include/linux/swait.h @@ -29,7 +29,10 @@ * * As a side effect of this; the data structures are slimmer. * - * One

Re: [PATCH] firmware: wake all waiters

2017-06-28 Thread Davidlohr Bueso
On Tue, 27 Jun 2017, Luis R. Rodriguez wrote: diff --git a/include/linux/swait.h b/include/linux/swait.h index 4a4e180d0a35..14fcf23cece4 100644 --- a/include/linux/swait.h +++ b/include/linux/swait.h @@ -29,7 +29,10 @@ * * As a side effect of this; the data structures are slimmer. * - * One

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Lennart Poettering
On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > Do you know how systemd developers feel about the issue (CCed)? Given > > that it seems to dominate in data center OSes now I'm slightly worried > > having to push Big Linux Vendors to package some seemingly > >

Re: [systemd-devel] [PATCH] firmware: wake all waiters

2017-06-28 Thread Lennart Poettering
On Wed, 28.06.17 00:24, Luis R. Rodriguez (mcg...@kernel.org) wrote: > > Do you know how systemd developers feel about the issue (CCed)? Given > > that it seems to dominate in data center OSes now I'm slightly worried > > having to push Big Linux Vendors to package some seemingly > >

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 3:39 PM, Jakub Kicinski wrote: > On Wed, 28 Jun 2017 00:24:19 +0200, Luis R. Rodriguez wrote: >> On Tue, Jun 27, 2017 at 02:25:53PM -0700, Jakub Kicinski wrote: >> > On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: >> > > >> > > >

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 3:39 PM, Jakub Kicinski wrote: > On Wed, 28 Jun 2017 00:24:19 +0200, Luis R. Rodriguez wrote: >> On Tue, Jun 27, 2017 at 02:25:53PM -0700, Jakub Kicinski wrote: >> > On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: >> > > >> > > > The problem is that advanced

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Jakub Kicinski
On Wed, 28 Jun 2017 00:24:19 +0200, Luis R. Rodriguez wrote: > On Tue, Jun 27, 2017 at 02:25:53PM -0700, Jakub Kicinski wrote: > > On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: > > > > > > > The problem is that advanced NICs are quite programmable [1] and > > > > depending on

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Jakub Kicinski
On Wed, 28 Jun 2017 00:24:19 +0200, Luis R. Rodriguez wrote: > On Tue, Jun 27, 2017 at 02:25:53PM -0700, Jakub Kicinski wrote: > > On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: > > > > > > > The problem is that advanced NICs are quite programmable [1] and > > > > depending on

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 02:25:53PM -0700, Jakub Kicinski wrote: > On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: > > > > > The problem is that advanced NICs are quite programmable [1] and > > > depending on use case one may want to load different firmware files. > > > > Right, so

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 02:25:53PM -0700, Jakub Kicinski wrote: > On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: > > > > > The problem is that advanced NICs are quite programmable [1] and > > > depending on use case one may want to load different firmware files. > > > > Right, so

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Jakub Kicinski
On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: > On Mon, Jun 26, 2017 at 07:10:09PM -0700, Jakub Kicinski wrote: > > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > > > > In that case we will make them all use the same struct firmware_buf. > > > > When wake up

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Jakub Kicinski
On Tue, 27 Jun 2017 18:39:42 +0200, Luis R. Rodriguez wrote: > On Mon, Jun 26, 2017 at 07:10:09PM -0700, Jakub Kicinski wrote: > > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > > > > In that case we will make them all use the same struct firmware_buf. > > > > When wake up

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 12:52 PM, Bjorn Andersson wrote: > On Tue 27 Jun 12:08 PDT 2017, Luis R. Rodriguez wrote: >> On Tue, Jun 27, 2017 at 11:59:15AM -0700, Bjorn Andersson wrote: >> > Are you saying that each kernel driver should be written so that it will >> >

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 12:52 PM, Bjorn Andersson wrote: > On Tue 27 Jun 12:08 PDT 2017, Luis R. Rodriguez wrote: >> On Tue, Jun 27, 2017 at 11:59:15AM -0700, Bjorn Andersson wrote: >> > Are you saying that each kernel driver should be written so that it will >> > either do direct loading or use

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Bjorn Andersson
On Tue 27 Jun 12:08 PDT 2017, Luis R. Rodriguez wrote: > On Tue, Jun 27, 2017 at 11:59:15AM -0700, Bjorn Andersson wrote: > > On Tue 27 Jun 11:03 PDT 2017, Luis R. Rodriguez wrote: > > [..] > > > Let's consider a crazy case where the uevent gets triggered, and > > > userspace goes > > > and

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Bjorn Andersson
On Tue 27 Jun 12:08 PDT 2017, Luis R. Rodriguez wrote: > On Tue, Jun 27, 2017 at 11:59:15AM -0700, Bjorn Andersson wrote: > > On Tue 27 Jun 11:03 PDT 2017, Luis R. Rodriguez wrote: > > [..] > > > Let's consider a crazy case where the uevent gets triggered, and > > > userspace goes > > > and

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 11:59:15AM -0700, Bjorn Andersson wrote: > On Tue 27 Jun 11:03 PDT 2017, Luis R. Rodriguez wrote: > [..] > > Let's consider a crazy case where the uevent gets triggered, and userspace > > goes > > and signals Elon Musk somehow to transmit the needed firmware from Mars > >

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 11:59:15AM -0700, Bjorn Andersson wrote: > On Tue 27 Jun 11:03 PDT 2017, Luis R. Rodriguez wrote: > [..] > > Let's consider a crazy case where the uevent gets triggered, and userspace > > goes > > and signals Elon Musk somehow to transmit the needed firmware from Mars > >

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Bjorn Andersson
On Tue 27 Jun 11:03 PDT 2017, Luis R. Rodriguez wrote: [..] > Let's consider a crazy case where the uevent gets triggered, and userspace > goes > and signals Elon Musk somehow to transmit the needed firmware from Mars > through > a serial satellite link to earth, and somehow someday the device

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Bjorn Andersson
On Tue 27 Jun 11:03 PDT 2017, Luis R. Rodriguez wrote: [..] > Let's consider a crazy case where the uevent gets triggered, and userspace > goes > and signals Elon Musk somehow to transmit the needed firmware from Mars > through > a serial satellite link to earth, and somehow someday the device

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 10:48:25AM -0700, Bjorn Andersson wrote: > On Mon, Jun 26, 2017 at 7:10 PM, Jakub Kicinski > wrote: > > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > [..] > > - how to stay bound and retry the direct default FW load until

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Tue, Jun 27, 2017 at 10:48:25AM -0700, Bjorn Andersson wrote: > On Mon, Jun 26, 2017 at 7:10 PM, Jakub Kicinski > wrote: > > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > [..] > > - how to stay bound and retry the direct default FW load until rootfs > >is mounted

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Bjorn Andersson
On Mon, Jun 26, 2017 at 7:10 PM, Jakub Kicinski wrote: > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: [..] > - how to stay bound and retry the direct default FW load until rootfs >is mounted (equivalent to when -EPROBE_DEFER would give up); If

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Bjorn Andersson
On Mon, Jun 26, 2017 at 7:10 PM, Jakub Kicinski wrote: > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: [..] > - how to stay bound and retry the direct default FW load until rootfs >is mounted (equivalent to when -EPROBE_DEFER would give up); If you constrain this problem to

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 07:10:09PM -0700, Jakub Kicinski wrote: > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > > > In that case we will make them all use the same struct firmware_buf. > > > When wake up happens make sure it's propagated to all of them. > > > > > > Signed-off-by:

Re: [PATCH] firmware: wake all waiters

2017-06-27 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 07:10:09PM -0700, Jakub Kicinski wrote: > On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > > > In that case we will make them all use the same struct firmware_buf. > > > When wake up happens make sure it's propagated to all of them. > > > > > > Signed-off-by:

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Jakub Kicinski
On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > > In that case we will make them all use the same struct firmware_buf. > > When wake up happens make sure it's propagated to all of them. > > > > Signed-off-by: Jakub Kicinski > > There's a slew of

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Jakub Kicinski
On Mon, 26 Jun 2017 23:20:36 +0200, Luis R. Rodriguez wrote: > > In that case we will make them all use the same struct firmware_buf. > > When wake up happens make sure it's propagated to all of them. > > > > Signed-off-by: Jakub Kicinski > > There's a slew of bugs lurking here though! > >

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 04:43:10PM -0700, Linus Torvalds wrote: > The swait interface is so special and so undocumented, that I really > didn't expect anybody to even know about it unless they had very > specific needs, much less use it. If swait is really not designed and intended to be used for

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 04:43:10PM -0700, Linus Torvalds wrote: > The swait interface is so special and so undocumented, that I really > didn't expect anybody to even know about it unless they had very > specific needs, much less use it. If swait is really not designed and intended to be used for

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Linus Torvalds
On Mon, Jun 26, 2017 at 4:30 PM, Luis R. Rodriguez wrote: > > On Mon, Jun 26, 2017 at 02:44:17PM -0700, Linus Torvalds wrote: > > > > Among all the simplifications it has is exactly the fact that it wakes > > up only one thing, because it is *so* specialized. > > Not sure I

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Linus Torvalds
On Mon, Jun 26, 2017 at 4:30 PM, Luis R. Rodriguez wrote: > > On Mon, Jun 26, 2017 at 02:44:17PM -0700, Linus Torvalds wrote: > > > > Among all the simplifications it has is exactly the fact that it wakes > > up only one thing, because it is *so* specialized. > > Not sure I follow, it can wake up

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 11:20:36PM +0200, Luis R. Rodriguez wrote: > On Fri, Jun 23, 2017 at 04:37:02PM -0700, Jakub Kicinski wrote: > There's a slew of bugs lurking here though! > > As noted the reported Intel driver issues still need other fixes, one was the > fw_state_done() on the direct

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 11:20:36PM +0200, Luis R. Rodriguez wrote: > On Fri, Jun 23, 2017 at 04:37:02PM -0700, Jakub Kicinski wrote: > There's a slew of bugs lurking here though! > > As noted the reported Intel driver issues still need other fixes, one was the > fw_state_done() on the direct

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 02:44:17PM -0700, Linus Torvalds wrote: > On Fri, Jun 23, 2017 at 4:37 PM, Jakub Kicinski > wrote: > > - swake_up(_st->wq); > > + swake_up_all(_st->wq); > > Why is that code using the braindamaed "swait" model in

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
On Mon, Jun 26, 2017 at 02:44:17PM -0700, Linus Torvalds wrote: > On Fri, Jun 23, 2017 at 4:37 PM, Jakub Kicinski > wrote: > > - swake_up(_st->wq); > > + swake_up_all(_st->wq); > > Why is that code using the braindamaed "swait" model in the first place? The

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Linus Torvalds
On Fri, Jun 23, 2017 at 4:37 PM, Jakub Kicinski wrote: > - swake_up(_st->wq); > + swake_up_all(_st->wq); Why is that code using the braindamaed "swait" model in the first place? That's the real problem here - swait() is a very

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Linus Torvalds
On Fri, Jun 23, 2017 at 4:37 PM, Jakub Kicinski wrote: > - swake_up(_st->wq); > + swake_up_all(_st->wq); Why is that code using the braindamaed "swait" model in the first place? That's the real problem here - swait() is a very specialized interface, and it does not

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
Thank you for your patch! On Fri, Jun 23, 2017 at 04:37:02PM -0700, Jakub Kicinski wrote: > Multiple devices may be waiting for firmware with the same name. This is due to a hidden and not-well understood feature of the firmware API. I can trace commit logs loosely documenting this as an

Re: [PATCH] firmware: wake all waiters

2017-06-26 Thread Luis R. Rodriguez
Thank you for your patch! On Fri, Jun 23, 2017 at 04:37:02PM -0700, Jakub Kicinski wrote: > Multiple devices may be waiting for firmware with the same name. This is due to a hidden and not-well understood feature of the firmware API. I can trace commit logs loosely documenting this as an

[PATCH] firmware: wake all waiters

2017-06-23 Thread Jakub Kicinski
Multiple devices may be waiting for firmware with the same name. In that case we will make them all use the same struct firmware_buf. When wake up happens make sure it's propagated to all of them. Signed-off-by: Jakub Kicinski --- drivers/base/firmware_class.c | 2

[PATCH] firmware: wake all waiters

2017-06-23 Thread Jakub Kicinski
Multiple devices may be waiting for firmware with the same name. In that case we will make them all use the same struct firmware_buf. When wake up happens make sure it's propagated to all of them. Signed-off-by: Jakub Kicinski --- drivers/base/firmware_class.c | 2 +- 1 file changed, 1