Lines Matching refs:i2400m

89 	struct i2400m *i2400m = net_dev_to_i2400m(net_dev);  in i2400m_open()  local
90 struct device *dev = i2400m_dev(i2400m); in i2400m_open()
92 d_fnstart(3, dev, "(net_dev %p [i2400m %p])\n", net_dev, i2400m); in i2400m_open()
94 mutex_lock(&i2400m->init_mutex); in i2400m_open()
95 if (i2400m->updown) in i2400m_open()
99 mutex_unlock(&i2400m->init_mutex); in i2400m_open()
101 net_dev, i2400m, result); in i2400m_open()
109 struct i2400m *i2400m = net_dev_to_i2400m(net_dev); in i2400m_stop() local
110 struct device *dev = i2400m_dev(i2400m); in i2400m_stop()
112 d_fnstart(3, dev, "(net_dev %p [i2400m %p])\n", net_dev, i2400m); in i2400m_stop()
113 i2400m_net_wake_stop(i2400m); in i2400m_stop()
114 d_fnend(3, dev, "(net_dev %p [i2400m %p]) = 0\n", net_dev, i2400m); in i2400m_stop()
141 struct i2400m *i2400m = container_of(ws, struct i2400m, wake_tx_ws); in i2400m_wake_tx_work() local
142 struct net_device *net_dev = i2400m->wimax_dev.net_dev; in i2400m_wake_tx_work()
143 struct device *dev = i2400m_dev(i2400m); in i2400m_wake_tx_work()
147 spin_lock_irqsave(&i2400m->tx_lock, flags); in i2400m_wake_tx_work()
148 skb = i2400m->wake_tx_skb; in i2400m_wake_tx_work()
149 i2400m->wake_tx_skb = NULL; in i2400m_wake_tx_work()
150 spin_unlock_irqrestore(&i2400m->tx_lock, flags); in i2400m_wake_tx_work()
152 d_fnstart(3, dev, "(ws %p i2400m %p skb %p)\n", ws, i2400m, skb); in i2400m_wake_tx_work()
163 result = i2400m_cmd_exit_idle(i2400m); in i2400m_wake_tx_work()
169 i2400m_reset(i2400m, I2400M_RT_BUS); in i2400m_wake_tx_work()
172 result = wait_event_timeout(i2400m->state_wq, in i2400m_wake_tx_work()
173 i2400m->state != I2400M_SS_IDLE, in i2400m_wake_tx_work()
180 i2400m_reset(i2400m, I2400M_RT_BUS); in i2400m_wake_tx_work()
184 result = i2400m_tx(i2400m, skb->data, skb->len, I2400M_PT_DATA); in i2400m_wake_tx_work()
190 i2400m_put(i2400m); in i2400m_wake_tx_work()
192 ws, i2400m, skb, result); in i2400m_wake_tx_work()
221 void i2400m_net_wake_stop(struct i2400m *i2400m) in i2400m_net_wake_stop() argument
223 struct device *dev = i2400m_dev(i2400m); in i2400m_net_wake_stop()
227 d_fnstart(3, dev, "(i2400m %p)\n", i2400m); in i2400m_net_wake_stop()
232 cancel_work_sync(&i2400m->wake_tx_ws); in i2400m_net_wake_stop()
234 spin_lock_irqsave(&i2400m->tx_lock, flags); in i2400m_net_wake_stop()
235 wake_tx_skb = i2400m->wake_tx_skb; in i2400m_net_wake_stop()
236 i2400m->wake_tx_skb = NULL; in i2400m_net_wake_stop()
237 spin_unlock_irqrestore(&i2400m->tx_lock, flags); in i2400m_net_wake_stop()
240 i2400m_put(i2400m); in i2400m_net_wake_stop()
244 d_fnend(3, dev, "(i2400m %p) = void\n", i2400m); in i2400m_net_wake_stop()
260 int i2400m_net_wake_tx(struct i2400m *i2400m, struct net_device *net_dev, in i2400m_net_wake_tx() argument
264 struct device *dev = i2400m_dev(i2400m); in i2400m_net_wake_tx()
278 spin_lock_irqsave(&i2400m->tx_lock, flags); in i2400m_net_wake_tx()
279 if (!i2400m->wake_tx_skb) { in i2400m_net_wake_tx()
281 i2400m_get(i2400m); in i2400m_net_wake_tx()
282 i2400m->wake_tx_skb = skb_get(skb); /* transfer ref count */ in i2400m_net_wake_tx()
284 result = schedule_work(&i2400m->wake_tx_ws); in i2400m_net_wake_tx()
287 spin_unlock_irqrestore(&i2400m->tx_lock, flags); in i2400m_net_wake_tx()
313 int i2400m_net_tx(struct i2400m *i2400m, struct net_device *net_dev, in i2400m_net_tx() argument
317 struct device *dev = i2400m_dev(i2400m); in i2400m_net_tx()
320 i2400m, net_dev, skb); in i2400m_net_tx()
327 result = i2400m_tx(i2400m, skb->data, skb->len, I2400M_PT_DATA); in i2400m_net_tx()
329 i2400m, net_dev, skb, result); in i2400m_net_tx()
356 struct i2400m *i2400m = net_dev_to_i2400m(net_dev); in i2400m_hard_start_xmit() local
357 struct device *dev = i2400m_dev(i2400m); in i2400m_hard_start_xmit()
365 if (i2400m->state == I2400M_SS_IDLE) in i2400m_hard_start_xmit()
366 result = i2400m_net_wake_tx(i2400m, net_dev, skb); in i2400m_hard_start_xmit()
368 result = i2400m_net_tx(i2400m, net_dev, skb); in i2400m_hard_start_xmit()
407 struct i2400m *i2400m = net_dev_to_i2400m(net_dev); in i2400m_rx_fake_eth_header() local
411 memcpy(eth_hdr->h_source, i2400m->src_mac_addr, in i2400m_rx_fake_eth_header()
453 void i2400m_net_rx(struct i2400m *i2400m, struct sk_buff *skb_rx, in i2400m_net_rx() argument
456 struct net_device *net_dev = i2400m->wimax_dev.net_dev; in i2400m_net_rx()
457 struct device *dev = i2400m_dev(i2400m); in i2400m_net_rx()
461 i2400m, buf, buf_len); in i2400m_net_rx()
478 i2400m_rx_fake_eth_header(i2400m->wimax_dev.net_dev, in i2400m_net_rx()
482 skb->dev = i2400m->wimax_dev.net_dev; in i2400m_net_rx()
492 i2400m, buf, buf_len); in i2400m_net_rx()
518 void i2400m_net_erx(struct i2400m *i2400m, struct sk_buff *skb, in i2400m_net_erx() argument
521 struct net_device *net_dev = i2400m->wimax_dev.net_dev; in i2400m_net_erx()
522 struct device *dev = i2400m_dev(i2400m); in i2400m_net_erx()
525 i2400m, skb, skb->len, cs); in i2400m_net_erx()
529 i2400m_rx_fake_eth_header(i2400m->wimax_dev.net_dev, in i2400m_net_erx()
533 skb->dev = i2400m->wimax_dev.net_dev; in i2400m_net_erx()
549 i2400m, skb, skb->len, cs); in i2400m_net_erx()
562 struct i2400m *i2400m = net_dev_to_i2400m(net_dev); in i2400m_get_drvinfo() local
565 strlcpy(info->fw_version, i2400m->fw_name ? : "", in i2400m_get_drvinfo()