Defines | Functions
debugfs_sta.c File Reference
#include <linux/debugfs.h>
#include <linux/ieee80211.h>
#include "ieee80211_i.h"
#include "debugfs.h"
#include "debugfs_sta.h"
#include "sta_info.h"
Include dependency graph for kernel-3.5/debugfs_sta.c:

Go to the source code of this file.

Defines

#define DEBUGFS_ADD(name)
#define DEBUGFS_ADD_COUNTER(name, field)
#define PRINT_HT_CAP(_cond, _str)
#define STA_FILE(name, field, format)
#define STA_OPS(name)
#define STA_OPS_RW(name)
#define STA_READ(name, field, format_string)
#define STA_READ_D(name, field)   STA_READ(name, field, "%d\n")
#define STA_READ_S(name, field)   STA_READ(name, field, "%s\n")
#define STA_READ_U(name, field)   STA_READ(name, field, "%u\n")
#define TEST(flg)   test_sta_flag(sta, WLAN_STA_##flg) ? #flg "\n" : ""

Functions

void ieee80211_sta_debugfs_add (struct sta_info *sta)
void ieee80211_sta_debugfs_remove (struct sta_info *sta)
static ssize_t sta_agg_status_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
static ssize_t sta_agg_status_write (struct file *file, const char __user *userbuf, size_t count, loff_t *ppos)
static ssize_t sta_connected_time_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
 STA_FILE (aid, sta.aid, D)
 STA_FILE (dev, sdata->name, S)
 STA_FILE (last_signal, last_signal, D)
static ssize_t sta_flags_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
static ssize_t sta_ht_capa_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
static ssize_t sta_inactive_ms_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
static ssize_t sta_last_seq_ctrl_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
static ssize_t sta_num_ps_buf_frames_read (struct file *file, char __user *userbuf, size_t count, loff_t *ppos)
 STA_OPS (flags)
 STA_OPS (num_ps_buf_frames)
 STA_OPS (inactive_ms)
 STA_OPS (connected_time)
 STA_OPS (last_seq_ctrl)
 STA_OPS (ht_capa)
 STA_OPS_RW (agg_status)

Define Documentation

#define DEBUGFS_ADD (   name)
Value:
debugfs_create_file(#name, 0400, \
                sta->debugfs.dir, sta, &sta_ ##name## _ops);

Definition at line 323 of file kernel-3.5/debugfs_sta.c.

#define DEBUGFS_ADD_COUNTER (   name,
  field 
)
Value:
if (sizeof(sta->field) == sizeof(u32))                          \
                debugfs_create_u32(#name, 0400, sta->debugfs.dir,       \
                        (u32 *) &sta->field);                           \
        else                                                            \
                debugfs_create_u64(#name, 0400, sta->debugfs.dir,       \
                        (u64 *) &sta->field);

Definition at line 327 of file kernel-3.5/debugfs_sta.c.

#define PRINT_HT_CAP (   _cond,
  _str 
)
Value:
do { \
        if (_cond) \
                        p += scnprintf(p, sizeof(buf)+buf-p, "\t" _str "\n"); \
        } while (0)
#define STA_FILE (   name,
  field,
  format 
)
Value:
STA_READ_##format(name, field)                          \
                STA_OPS(name)

Definition at line 48 of file kernel-3.5/debugfs_sta.c.

#define STA_OPS (   name)
Value:
static const struct file_operations sta_ ##name## _ops = {              \
        .read = sta_##name##_read,                                      \
        .open = simple_open,                                            \
        .llseek = generic_file_llseek,                                  \
}

Definition at line 33 of file kernel-3.5/debugfs_sta.c.

#define STA_OPS_RW (   name)
Value:
static const struct file_operations sta_ ##name## _ops = {              \
        .read = sta_##name##_read,                                      \
        .write = sta_##name##_write,                                    \
        .open = simple_open,                                            \
        .llseek = generic_file_llseek,                                  \
}

Definition at line 40 of file kernel-3.5/debugfs_sta.c.

#define STA_READ (   name,
  field,
  format_string 
)
Value:
static ssize_t sta_ ##name## _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,             \
                                      format_string, sta->field);       \
}

Definition at line 20 of file kernel-3.5/debugfs_sta.c.

#define STA_READ_D (   name,
  field 
)    STA_READ(name, field, "%d\n")

Definition at line 29 of file kernel-3.5/debugfs_sta.c.

#define STA_READ_S (   name,
  field 
)    STA_READ(name, field, "%s\n")

Definition at line 31 of file kernel-3.5/debugfs_sta.c.

#define STA_READ_U (   name,
  field 
)    STA_READ(name, field, "%u\n")

Definition at line 30 of file kernel-3.5/debugfs_sta.c.

#define TEST (   flg)    test_sta_flag(sta, WLAN_STA_##flg) ? #flg "\n" : ""

Function Documentation

void ieee80211_sta_debugfs_add ( struct sta_info sta)

Definition at line 335 of file kernel-3.5/debugfs_sta.c.

void ieee80211_sta_debugfs_remove ( struct sta_info sta)

Definition at line 384 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_agg_status_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 145 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_agg_status_write ( struct file *  file,
const char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 184 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_connected_time_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 107 of file kernel-3.5/debugfs_sta.c.

STA_FILE ( aid  ,
sta.  aid,
 
)
STA_FILE ( dev  ,
sdata->  name,
 
)
STA_FILE ( last_signal  ,
last_signal  ,
 
)
static ssize_t sta_flags_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 56 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_ht_capa_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 241 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_inactive_ms_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 97 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_last_seq_ctrl_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 131 of file kernel-3.5/debugfs_sta.c.

static ssize_t sta_num_ps_buf_frames_read ( struct file *  file,
char __user *  userbuf,
size_t  count,
loff_t *  ppos 
) [static]

Definition at line 81 of file kernel-3.5/debugfs_sta.c.

STA_OPS ( flags  )
STA_OPS ( num_ps_buf_frames  )
STA_OPS ( inactive_ms  )
STA_OPS ( connected_time  )
STA_OPS ( last_seq_ctrl  )
STA_OPS ( ht_capa  )
STA_OPS_RW ( agg_status  )


ros_rt_wmp
Author(s): Danilo Tardioli, dantard@unizar.es
autogenerated on Fri Jan 3 2014 12:07:56