/* This function transmit an IEEE 802.11 network frame to the device. The control block of the skbuff will be initialized. If necessary the incoming mac80211 queues will be stopped.  */
static int zd_op_tx(struct ieee80211_hw *hw, struct sk_buff *skb)
/* This function transmit an IEEE 802.11 network frame to the device. The control block of the skbuff will be initialized. If necessary the incoming mac80211 queues will be stopped.  */
static int zd_op_tx(struct ieee80211_hw *hw, struct sk_buff *skb)
{
	struct zd_mac *mac = zd_hw_mac(hw);
	struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
	int r;
	r = fill_ctrlset(mac, skb);
	if (r)
		goto fail;
	info->rate_driver_data[0] = hw;
	r = zd_usb_tx(&mac->chip.usb, skb);
	if (r)
		goto fail;
	return 0;
fail:
	dev_kfree_skb(skb);
	return 0;
}