diff options
| author | Maarten Lankhorst <maarten.lankhorst@linux.intel.com> | 2024-11-04 14:44:16 +0100 | 
|---|---|---|
| committer | Maarten Lankhorst <maarten.lankhorst@linux.intel.com> | 2024-11-04 14:45:21 +0100 | 
| commit | d78f0ee0406803cda8801fd5201746ccf89e5e4a (patch) | |
| tree | d0d145319344a07cb6f4b47578f01236b71ad473 /drivers/net/macsec.c | |
| parent | a88f9ed63b3cec761b04cba8104b2d0b2b66b25d (diff) | |
| parent | 30169bb64580bd7bce9290c1952bf0aa6cc37fe5 (diff) | |
Merge remote-tracking branch 'drm/drm-next' into drm-misc-next
Didn't notice drm/drm-next had the build fix for drm_bridge, so ended up
committing the same patch. Sync with drm and pretend it didn't happen?
Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Diffstat (limited to 'drivers/net/macsec.c')
| -rw-r--r-- | drivers/net/macsec.c | 21 | 
1 files changed, 1 insertions, 20 deletions
diff --git a/drivers/net/macsec.c b/drivers/net/macsec.c index 12d1b205f6d1..ee2159282573 100644 --- a/drivers/net/macsec.c +++ b/drivers/net/macsec.c @@ -154,19 +154,6 @@ static struct macsec_rx_sa *macsec_rxsa_get(struct macsec_rx_sa __rcu *ptr)  	return sa;  } -static struct macsec_rx_sa *macsec_active_rxsa_get(struct macsec_rx_sc *rx_sc) -{ -	struct macsec_rx_sa *sa = NULL; -	int an; - -	for (an = 0; an < MACSEC_NUM_AN; an++)	{ -		sa = macsec_rxsa_get(rx_sc->sa[an]); -		if (sa) -			break; -	} -	return sa; -} -  static void free_rx_sc_rcu(struct rcu_head *head)  {  	struct macsec_rx_sc *rx_sc = container_of(head, struct macsec_rx_sc, rcu_head); @@ -1208,15 +1195,12 @@ static rx_handler_result_t macsec_handle_frame(struct sk_buff **pskb)  		/* If validateFrames is Strict or the C bit in the  		 * SecTAG is set, discard  		 */ -		struct macsec_rx_sa *active_rx_sa = macsec_active_rxsa_get(rx_sc);  		if (hdr->tci_an & MACSEC_TCI_C ||  		    secy->validate_frames == MACSEC_VALIDATE_STRICT) {  			u64_stats_update_begin(&rxsc_stats->syncp);  			rxsc_stats->stats.InPktsNotUsingSA++;  			u64_stats_update_end(&rxsc_stats->syncp);  			DEV_STATS_INC(secy->netdev, rx_errors); -			if (active_rx_sa) -				this_cpu_inc(active_rx_sa->stats->InPktsNotUsingSA);  			goto drop_nosa;  		} @@ -1226,8 +1210,6 @@ static rx_handler_result_t macsec_handle_frame(struct sk_buff **pskb)  		u64_stats_update_begin(&rxsc_stats->syncp);  		rxsc_stats->stats.InPktsUnusedSA++;  		u64_stats_update_end(&rxsc_stats->syncp); -		if (active_rx_sa) -			this_cpu_inc(active_rx_sa->stats->InPktsUnusedSA);  		goto deliver;  	} @@ -3816,8 +3798,7 @@ static void macsec_free_netdev(struct net_device *dev)  {  	struct macsec_dev *macsec = macsec_priv(dev); -	if (macsec->secy.tx_sc.md_dst) -		metadata_dst_free(macsec->secy.tx_sc.md_dst); +	dst_release(&macsec->secy.tx_sc.md_dst->dst);  	free_percpu(macsec->stats);  	free_percpu(macsec->secy.tx_sc.stats);  | 
