Exemplo n.º 1
0
static ssize_t sta_inactive_ms_read(struct file *file, char __user *userbuf,
				    size_t count, loff_t *ppos)
{
	struct sta_info *sta = file->private_data;
	return mac80211_format_buffer(userbuf, count, ppos, "%d\n",
				      jiffies_to_msecs(jiffies - sta->last_rx));
}
static ssize_t uapsd_queues_read(struct file *file, char __user *user_buf,
				 size_t count, loff_t *ppos)
{
	struct ieee80211_local *local = file->private_data;
	return mac80211_format_buffer(user_buf, count, ppos, "0x%x\n",
				      local->uapsd_queues);
}
Exemplo n.º 3
0
static ssize_t sta_num_ps_buf_frames_read(struct file *file,
					  char __user *userbuf,
					  size_t count, loff_t *ppos)
{
	struct sta_info *sta = file->private_data;
	return mac80211_format_buffer(userbuf, count, ppos, "%u\n",
				      skb_queue_len(&sta->ps_tx_buf));
}
static ssize_t noack_read(struct file *file, char __user *user_buf,
			  size_t count, loff_t *ppos)
{
	struct ieee80211_local *local = file->private_data;

	return mac80211_format_buffer(user_buf, count, ppos, "%d\n",
				      local->wifi_wme_noack_test);
}
Exemplo n.º 5
0
static ssize_t tsf_read(struct file *file, char __user *user_buf,
			     size_t count, loff_t *ppos)
{
	struct ieee80211_local *local = file->private_data;
	u64 tsf;

	tsf = drv_get_tsf(local);

	return mac80211_format_buffer(user_buf, count, ppos, "0x%016llx\n",
				      (unsigned long long) tsf);
}