netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Evgeniy Polyakov <zbr@ioremap.net>
To: Patrick McHardy <kaber@trash.net>
Cc: Linux Netdev List <netdev@vger.kernel.org>
Subject: Re: connector: convert to synchronous netlink message processing
Date: Wed, 30 Mar 2011 17:39:13 +0400	[thread overview]
Message-ID: <20110330133913.GA9425@ioremap.net> (raw)
In-Reply-To: <4D90D5E8.4080002@trash.net>

Hi Patrick

On Mon, Mar 28, 2011 at 08:39:36PM +0200, Patrick McHardy (kaber@trash.net) wrote:
> This patch fixes up connector to work properly with the recent
> netlink changes that require synchronous netlink message processing.
> 
> The patch is so far only compile tested since I'm still looking
> for a good way to test it. If you could point me to some software
> using the proc events that would be appreciated.

There is test module in Documentation/connector/ and/or samples/ which I
used for tests. It was quite for a while when it was used last time
though.

Your patch looks very good and I definitely ack this :)
Thank you.

> commit 21c40e4675954b42c939334e3ed15e1bd0a4da29
> Author: Patrick McHardy <kaber@trash.net>
> Date:   Mon Mar 28 20:20:26 2011 +0200
> 
>     connector: convert to synchronous netlink message processing
>     
>     Commits 01a16b21 (netlink: kill eff_cap from struct netlink_skb_parms)
>     and c53fa1ed (netlink: kill loginuid/sessionid/sid members from struct
>     netlink_skb_parms) removed some members from struct netlink_skb_parms
>     that depend on the current context, all netlink users are now required
>     to do synchronous message processing.
>     
>     connector however queues received messages and processes them in a work
>     queue, which is not valid anymore. This patch converts connector to do
>     synchronous message processing by invoking the registered callback handler
>     directly from the netlink receive function.
>     
>     In order to avoid invoking the callback with connector locks held, a
>     reference count is added to struct cn_callback_entry, the reference
>     is taken when finding a matching callback entry on the device's queue_list
>     and released after the callback handler has been invoked.
>     
>     Signed-off-by: Patrick McHardy <kaber@trash.net>

Acked-by: Evgeniy Polyakov <zbr@ioremap.net>


-- 
	Evgeniy Polyakov

  reply	other threads:[~2011-03-30 13:39 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-28 18:39 connector: convert to synchronous netlink message processing Patrick McHardy
2011-03-30 13:39 ` Evgeniy Polyakov [this message]
2011-03-31  0:15   ` David Miller
2011-04-04 12:47   ` Patrick McHardy

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=20110330133913.GA9425@ioremap.net \
    --to=zbr@ioremap.net \
    --cc=kaber@trash.net \
    --cc=netdev@vger.kernel.org \
    /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 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).