Dear all,

I found this question raised in the mail list, which also interests
me, prior to my registration.

I am trying to do something similar as Bruno suggested, using
ath5k_tx_queue() or ath5k_tx() to transmit a packet in the ath5k
layer.

However, I am currently troubled with how to prepare a complete WLAN
packet from scratch.

Could anyone please advise? Thanks in advance.

Best Regards
YY




From: n n
Subject: [ath5k-devel] Help, A fresher's Question.
Date: Thursday, May 13, 2010 - 3:32 pm

Hi, all
   I'm a student at NYU and I'm very interested in ath5k driver code.

What I'm trying to do now is to make the ath5k broadcast my own "hello
packet" every 3 sec.

I've successfully put a timer in the ath5k_attach() function, and it works
good.
Next, I put ieee80211_subif_start_xmit(skb, dev) in the timer.
Here comes the problem. The ieee80211_subif_start_xmit(skb, dev) wants the
struct net_device *dev, but in ath5k_attach we only have struct ieee80211_hw
*hw.
I dont konw where to get the struct net_device *dev.

Is anyone can help me?
Plz~~~~~


Thank you very much


BEST

From: Bruno Randolf
Subject: Re: [ath5k-devel] Help, A fresher's Question.
Date: Thursday, May 13, 2010 - 5:52 pm

you are mixing layers here. ieee80211_subif_start_xmit() is a function of
mac80211 and you are in the ath5k driver code, so you can either just use

static int ath5k_tx_queue(struct ieee80211_hw *hw, struct sk_buff *skb,
                          struct ath5k_txq *txq)

directly, and give it a complete WLAN packet, including 802.11 headers and all
- or you but your timer somewhere else where you can access the net_device.

bruno
_______________________________________________
ath5k-devel mailing list
ath5k-devel@lists.ath5k.org
https://lists.ath5k.org/mailman/listinfo/ath5k-devel

Reply via email to