Search Linux Wireless

Re: [PATCH] rtl8180: avoid accessing the data mapped to streaming DMA

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 19 Oct 2020 10:54:20 +0800 Jia-Ju Bai wrote:
> +	if (info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ) {
> +		if (info->flags & IEEE80211_TX_CTL_FIRST_FRAGMENT)
> +			priv->seqno += 0x10;
> +		hdr->seq_ctrl &= cpu_to_le16(IEEE80211_SCTL_FRAG);
> +		hdr->seq_ctrl |= cpu_to_le16(priv->seqno);
> +	}
> +
>  	mapping = dma_map_single(&priv->pdev->dev, skb->data, skb->len,
>  				 DMA_TO_DEVICE);
>  
> @@ -534,13 +541,6 @@ static void rtl8180_tx(struct ieee80211_hw *dev,
>  
>  	spin_lock_irqsave(&priv->lock, flags);
>  
> -	if (info->flags & IEEE80211_TX_CTL_ASSIGN_SEQ) {
> -		if (info->flags & IEEE80211_TX_CTL_FIRST_FRAGMENT)
> -			priv->seqno += 0x10;

You're taking the priv->seqno access and modification from under
priv->lock. Is that okay?



[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux