33 #define TA_MAX_INTERVALS_IN_C1 100
37 #define TA_INTERVALS_NUM 10
42 #define TA_INTERVALS_STEP 10
53 #define TA_ETHERNET_TYPE_OFFSET 6
54 #define TA_LLC_HEADER_SIZE 8
55 #define TA_IP_TYPE_OFFSET 17
56 #define TA_UDP_SOURCE_PORT_OFFSET 28
57 #define TA_UDP_DEST_PORT_OFFSET (TA_UDP_SOURCE_PORT_OFFSET + 2)
58 #define TA_BOOTP_CLIENT_MAC_ADDR_OFFSET 64
59 #define TA_DHCP_MESSAGE_TYPE_OFFSET 278
60 #define TA_DHCP_MESSAGE_TYPE_ACK 0x05
61 #define TA_PROTO_TYPE_IP 0x0800
62 #define TA_PROTO_TYPE_EAP 0x888E
63 #define TA_PROTO_TYPE_WAI 0x8864
64 #define TA_PROTO_TYPE_ARP 0x0806
65 #define TA_IP_TYPE_TCP 0x06
66 #define TA_IP_TYPE_UDP 0x11
67 #define TA_UDP_PORT_BOOTPC 0x0044
68 #define TA_UDP_PORT_BOOTPS 0x0043
69 #define TA_EAPOL_TYPE_OFFSET 9
70 #define TA_EAPOL_TYPE_START 0x01
72 #define snap_802_2 0xAAAA0300
73 #define oui_rfc1042 0x00000000
74 #define oui_8021h 0x0000f800
75 static const u8 aironet_snap[5] = { 0x00, 0x40, 0x96, 0x00, 0x00 };
97 const u8 *sta_macaddr)
103 u32 snap_hdr, oui_hdr;
236 direction, &srcAddress);
250 direction, &srcAddress);
264 direction, &srcAddress);
272 static void tas_reset_data(
ta_data_t *tad)
348 const u8 *sta_macaddr,
361 identity = ta_detect_protocol(card, direction, data, saddr, sta_macaddr);
391 u32 index_in_intervals;
401 "unifi_ta_sample: TX interval=%d index=%d\n",
402 interval, index_in_intervals);
420 if (time_delta >= 1000)
426 u32 temp_rxFramesNum;
430 if (temp_rxFramesNum)
435 "unifi_ta_sample: RX fr=%lu, r=%u, sum=%lu, av=%lu\n",
536 "Changed current ta classification to: %d\n", traffic_type);