From: Johannes Berg <johannes@sipsolutions.net>
To: Stanislaw Gruszka <sgruszka@redhat.com>
Cc: Wey-Yi Guy <wey-yi.w.guy@intel.com>,
Reinette Chatre <reinette.chatre@intel.com>,
"John W. Linville" <linville@tuxdriver.com>,
linux-wireless@vger.kernel.org
Subject: Re: [PATCH w-t] iwlwifi: rewrite iwl-scan.c to avoid race conditions
Date: Wed, 01 Sep 2010 16:26:44 +0200 [thread overview]
Message-ID: <1283351204.4124.10.camel@jlt3.sipsolutions.net> (raw)
In-Reply-To: <20100901141643.GC6547@redhat.com>
On Wed, 2010-09-01 at 16:16 +0200, Stanislaw Gruszka wrote:
> On Wed, Sep 01, 2010 at 02:41:52PM +0200, Johannes Berg wrote:
> > > Custom workqueue is not strictly needed, but it assure all works will
> > > run short after schedule. Common workqueue can not give us such guarantees,
> > > as other driver/subsystem can schedule own work, possibly slow, which
> > > can block start of our work for long time.
> >
> > I believe that's no longer true, with Tejun's workqueue rewrite that
> > just got into mainline.
>
> Good. However I still think having separate workqueue for scanning is clean
> and consistent solution, I prefer it over schedule_work() ... and want
> that patch backport to RHEL6 2.6.32 where we do not have such goodies :-)
Ah, but Tejun will kill us if we add more workqueues to the current
kernel :-)
> > > For sure abort_scan and abort_timeout works have to be scheduled on something
> > > other than priv->workqueue. I'm queuing all scan works on priv->scan_workqueue
> > > for consistency.
> >
> > Remind me: The reason is that we need to cancel them from within the
> > workqueue? But if we're on the same workqueue, it seems like they
> > couldn't be running already, so cancel_work_sync() would always cancel
> > them?
>
> Problem is not canceling, but exactly that we can not run new work when
> old one does not finish. For example, if queued to priv->workqueue
> abort_timeout will not be able run when we are performing iwl_bg_restart.
> Will run after iwl_bg_restart finish, we don't want that.
Ok ... Not sure I understand. Why do we care about abort_timeout work
coming after it? We'd cancel it anyway, when we kill the scan from
bg_restart, no?
johannes
next prev parent reply other threads:[~2010-09-01 14:26 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-08-31 15:00 [PATCH w-t] iwlwifi: rewrite iwl-scan.c to avoid race conditions Stanislaw Gruszka
2010-09-01 10:59 ` Johannes Berg
2010-09-01 11:58 ` Stanislaw Gruszka
2010-09-01 12:41 ` Johannes Berg
2010-09-01 14:16 ` Stanislaw Gruszka
2010-09-01 14:26 ` Johannes Berg [this message]
2010-09-01 15:24 ` Stanislaw Gruszka
2010-09-01 16:04 ` Johannes Berg
2010-09-02 8:47 ` Stanislaw Gruszka
2010-09-02 9:21 ` Johannes Berg
2010-09-02 10:52 ` Stanislaw Gruszka
2010-09-01 12:52 ` Johannes Berg
2010-09-01 14:16 ` Stanislaw Gruszka
2010-09-01 14:24 ` Johannes Berg
2010-09-02 9:36 ` Johannes Berg
2010-09-02 11:07 ` Stanislaw Gruszka
2010-09-02 11:36 ` Johannes Berg
2010-09-02 11:42 ` Stanislaw Gruszka
2010-09-02 10:17 ` Johannes Berg
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1283351204.4124.10.camel@jlt3.sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
--cc=reinette.chatre@intel.com \
--cc=sgruszka@redhat.com \
--cc=wey-yi.w.guy@intel.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.