netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
To: johannes-cdvu00un1VgdHxzADdlk8Q@public.gmane.org
Cc: linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org,
	netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH 1/4] genetlink: introduce pre_doit/post_doit hooks
Date: Tue, 05 Oct 2010 00:08:50 -0700 (PDT)	[thread overview]
Message-ID: <20101005.000850.241436160.davem@davemloft.net> (raw)
In-Reply-To: <20101004191838.763690480-cdvu00un1VgdHxzADdlk8Q@public.gmane.org>

From: Johannes Berg <johannes-cdvu00un1VgdHxzADdlk8Q@public.gmane.org>
Date: Mon, 04 Oct 2010 21:14:03 +0200

> From: Johannes Berg <johannes.berg-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
> 
> Each family may have some amount of boilerplate
> locking code that applies to most, or even all,
> commands.
> 
> This allows a family to handle such things in
> a more generic way, by allowing it to
>  a) include private flags in each operation
>  b) specify a pre_doit hook that is called,
>     before an operation's doit() callback and
>     may return an error directly,
>  c) specify a post_doit hook that can undo
>     locking or similar things done by pre_doit,
>     and finally
>  d) include two private pointers in each info
>     struct passed between all these operations
>     including doit(). (It's two because I'll
>     need two in nl80211 -- can be extended.)
> 
> Signed-off-by: Johannes Berg <johannes.berg-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

Acked-by: David S. Miller <davem-fT/PcQaiUtIeIZ0/mPfg9Q@public.gmane.org>
--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  parent reply	other threads:[~2010-10-05  7:08 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-10-04 19:14 [PATCH 0/4] nl80211 cleanups Johannes Berg
2010-10-04 19:14 ` [PATCH 1/4] genetlink: introduce pre_doit/post_doit hooks Johannes Berg
     [not found]   ` <20101004191838.763690480-cdvu00un1VgdHxzADdlk8Q@public.gmane.org>
2010-10-05  7:08     ` David Miller [this message]
2010-10-04 19:14 ` [PATCH 2/4] nl80211: use the new genetlink pre/post_doit hooks Johannes Berg
     [not found]   ` <20101004191838.964614880-cdvu00un1VgdHxzADdlk8Q@public.gmane.org>
2010-10-04 19:36     ` [PATCH 2/4 v2] " Johannes Berg
2010-10-04 19:14 ` [PATCH 3/4] nl80211: use generic check for netif_running Johannes Berg
2010-10-04 19:14 ` [PATCH 4/4] nl80211: reduce dumping boilerplate Johannes Berg
     [not found] ` <20101004191402.183055479-cdvu00un1VgdHxzADdlk8Q@public.gmane.org>
2010-10-04 19:33   ` [PATCH 0/4] nl80211 cleanups 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=20101005.000850.241436160.davem@davemloft.net \
    --to=davem-ft/pcqaiutieiz0/mpfg9q@public.gmane.org \
    --cc=johannes-cdvu00un1VgdHxzADdlk8Q@public.gmane.org \
    --cc=linux-wireless-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
    --cc=linville-2XuSBdqkA4R54TAoqtyWWQ@public.gmane.org \
    --cc=netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.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).