> +#define SET_MCAST_STATE_INVALID \
> +do { \
> + viport->mc_info.state = MCAST_STATE_INVALID; \
> + viport->mc_info.mc = NULL; \
> + memset(&viport->mc_info.mgid, 0, sizeof(union ib_gid)); \
> +} while (0);
Seems like this could be profitably implemented in C instead of CPP.
> + spin_lock_irqsave(&viport->mc_info.lock, flags);
> + viport->mc_info.state = MCAST_STATE_INVALID;
> + spin_unlock_irqrestore(&viport->mc_info.lock, flags);
This pattern makes me uneasy about the locking... setting the state
member will already be atomic, so what do you think you're protecting
against here by taking the lock?
- R.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html| Andrew Morton | Re: Linux 2.6.21-rc4 |
| Andrew Morton | -mm merge plans for 2.6.23 |
| Greg KH | [GIT PATCH] driver core patches against 2.6.24 |
| Balbir Singh | Re: [RFC][PATCH 2/7] RSS controller core |
git: | |
| Gerrit Renker | [PATCH 15/37] dccp: Set per-connection CCIDs via socket options |
| David Miller | [GIT]: Networking |
| Andreas Henriksson | [PATCH 06/12] Remove bogus reference to tc-filters(8) from tc(8) manpage. |
| Jarek Poplawski | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
