aboutsummaryrefslogtreecommitdiffstats
path: root/net/wireless/trace.h
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2013-05-15 18:55:00 -0400
committerJohannes Berg <johannes.berg@intel.com>2013-06-04 07:03:10 -0400
commit6ff57cf88807dd81300b5b9c623dc5eb6422b9f6 (patch)
tree8819fea1f493077ff311208986ebfe27bd327623 /net/wireless/trace.h
parent51217cee3a94d5409d6ee2ac090ae96bc9a06757 (diff)
cfg80211/mac80211: clean up cfg80211 SME APIs
Do some cleanups in the cfg80211 SME APIs, which are only used by mac80211. Most of these functions get a frame passed, and there isn't really any reason to export multiple functions as cfg80211 can check the frame type instead, do that. Additionally, the API functions have confusing names like cfg80211_send_...() which was meant to indicate that it sends an event to userspace, but gets a bit confusing when there's both TX and RX and they're not all clearly labeled. Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'net/wireless/trace.h')
-rw-r--r--net/wireless/trace.h46
1 files changed, 34 insertions, 12 deletions
diff --git a/net/wireless/trace.h b/net/wireless/trace.h
index 23fafeae8a10..e1534baf2ebb 100644
--- a/net/wireless/trace.h
+++ b/net/wireless/trace.h
@@ -1911,24 +1911,46 @@ TRACE_EVENT(cfg80211_send_rx_assoc,
1911 NETDEV_PR_ARG, MAC_PR_ARG(bssid), CHAN_PR_ARG) 1911 NETDEV_PR_ARG, MAC_PR_ARG(bssid), CHAN_PR_ARG)
1912); 1912);
1913 1913
1914DEFINE_EVENT(netdev_evt_only, cfg80211_send_deauth, 1914DECLARE_EVENT_CLASS(netdev_frame_event,
1915 TP_PROTO(struct net_device *netdev), 1915 TP_PROTO(struct net_device *netdev, const u8 *buf, int len),
1916 TP_ARGS(netdev) 1916 TP_ARGS(netdev, buf, len),
1917 TP_STRUCT__entry(
1918 NETDEV_ENTRY
1919 __dynamic_array(u8, frame, len)
1920 ),
1921 TP_fast_assign(
1922 NETDEV_ASSIGN;
1923 memcpy(__get_dynamic_array(frame), buf, len);
1924 ),
1925 TP_printk(NETDEV_PR_FMT ", ftype:0x%.2x",
1926 NETDEV_PR_ARG,
1927 le16_to_cpup((__le16 *)__get_dynamic_array(frame)))
1917); 1928);
1918 1929
1919DEFINE_EVENT(netdev_evt_only, cfg80211_send_disassoc, 1930DEFINE_EVENT(netdev_frame_event, cfg80211_rx_unprot_mlme_mgmt,
1920 TP_PROTO(struct net_device *netdev), 1931 TP_PROTO(struct net_device *netdev, const u8 *buf, int len),
1921 TP_ARGS(netdev) 1932 TP_ARGS(netdev, buf, len)
1922); 1933);
1923 1934
1924DEFINE_EVENT(netdev_evt_only, cfg80211_send_unprot_deauth, 1935DEFINE_EVENT(netdev_frame_event, cfg80211_rx_mlme_mgmt,
1925 TP_PROTO(struct net_device *netdev), 1936 TP_PROTO(struct net_device *netdev, const u8 *buf, int len),
1926 TP_ARGS(netdev) 1937 TP_ARGS(netdev, buf, len)
1927); 1938);
1928 1939
1929DEFINE_EVENT(netdev_evt_only, cfg80211_send_unprot_disassoc, 1940TRACE_EVENT(cfg80211_tx_mlme_mgmt,
1930 TP_PROTO(struct net_device *netdev), 1941 TP_PROTO(struct net_device *netdev, const u8 *buf, int len),
1931 TP_ARGS(netdev) 1942 TP_ARGS(netdev, buf, len),
1943 TP_STRUCT__entry(
1944 NETDEV_ENTRY
1945 __dynamic_array(u8, frame, len)
1946 ),
1947 TP_fast_assign(
1948 NETDEV_ASSIGN;
1949 memcpy(__get_dynamic_array(frame), buf, len);
1950 ),
1951 TP_printk(NETDEV_PR_FMT ", ftype:0x%.2x",
1952 NETDEV_PR_ARG,
1953 le16_to_cpup((__le16 *)__get_dynamic_array(frame)))
1932); 1954);
1933 1955
1934DECLARE_EVENT_CLASS(netdev_mac_evt, 1956DECLARE_EVENT_CLASS(netdev_mac_evt,