| Submitter | Igor Maravić |
|---|---|
| Date | Nov. 29, 2011, 10:30 a.m. |
| Message ID | <1322562649-20876-1-git-send-email-igorm@etf.rs> |
| Download | mbox | patch |
| Permalink | /patch/128271/ |
| State | Not Applicable |
| Delegated to: | David Miller |
| Headers | show |
Comments
Please ignore this. My mistake. 2011/11/29 <igorm@etf.rs>: > From: Igor Maravic <igorm@etf.rs> > > static_branch instead of atomic_read. > Eric forgot to replace that. > > Signed-off-by: Igor Maravic <igorm@etf.rs> > > :100644 100644 579ce33... d358088... M net/core/dev.c > > diff --git a/net/core/dev.c b/net/core/dev.c > index 579ce33..d358088 100644 > --- a/net/core/dev.c > +++ b/net/core/dev.c > @@ -1482,12 +1482,12 @@ EXPORT_SYMBOL(net_disable_timestamp); > static inline void net_timestamp_set(struct sk_buff *skb) > { > skb->tstamp.tv64 = 0; > - if (atomic_read(&netstamp_needed)) > + if (static_branch(&netstamp_needed)) > __net_timestamp(skb); > } > > #define net_timestamp_check(COND, SKB) \ > - if (atomic_read(&netstamp_needed)) { \ > + if (static_branch(&netstamp_needed)) { \ > if ((COND) && !(SKB)->tstamp.tv64) \ > __net_timestamp(SKB); \ > } \ > -- > 1.7.5.4 > > -- 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
Le mardi 29 novembre 2011 à 12:07 +0100, Igor Maravić a écrit : > Please ignore this. > My mistake. OK ;) One last thing : Dont top post on netdev, please. -- 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
Patch
diff --git a/net/core/dev.c b/net/core/dev.c index 579ce33..d358088 100644 --- a/net/core/dev.c +++ b/net/core/dev.c @@ -1482,12 +1482,12 @@ EXPORT_SYMBOL(net_disable_timestamp); static inline void net_timestamp_set(struct sk_buff *skb) { skb->tstamp.tv64 = 0; - if (atomic_read(&netstamp_needed)) + if (static_branch(&netstamp_needed)) __net_timestamp(skb); } #define net_timestamp_check(COND, SKB) \ - if (atomic_read(&netstamp_needed)) { \ + if (static_branch(&netstamp_needed)) { \ if ((COND) && !(SKB)->tstamp.tv64) \ __net_timestamp(SKB); \ } \