003 File Manager
Current Path:
/usr/src/contrib/wpa/src/fst
usr
/
src
/
contrib
/
wpa
/
src
/
fst
/
📁
..
📄
Makefile
(95 B)
📄
fst.c
(5.07 KB)
📄
fst.h
(8.35 KB)
📄
fst_ctrl_aux.c
(1.94 KB)
📄
fst_ctrl_aux.h
(2.52 KB)
📄
fst_ctrl_defs.h
(4.7 KB)
📄
fst_ctrl_iface.c
(22.93 KB)
📄
fst_ctrl_iface.h
(1.17 KB)
📄
fst_defs.h
(1.82 KB)
📄
fst_group.c
(13.29 KB)
📄
fst_group.h
(1.9 KB)
📄
fst_iface.c
(1.71 KB)
📄
fst_iface.h
(3.3 KB)
📄
fst_internal.h
(1.34 KB)
📄
fst_session.c
(40 KB)
📄
fst_session.h
(2.88 KB)
Editing: fst_iface.c
/* * FST module - FST interface object implementation * Copyright (c) 2014, Qualcomm Atheros, Inc. * * This software may be distributed under the terms of the BSD license. * See README for more details. */ #include "utils/includes.h" #include "utils/common.h" #include "fst/fst_internal.h" #include "fst/fst_defs.h" struct fst_iface * fst_iface_create(struct fst_group *g, const char *ifname, const u8 *own_addr, const struct fst_wpa_obj *iface_obj, const struct fst_iface_cfg *cfg) { struct fst_iface *i; i = os_zalloc(sizeof(*i)); if (!i) { fst_printf_group(g, MSG_ERROR, "cannot allocate iface for %s", ifname); return NULL; } i->cfg = *cfg; i->iface_obj = *iface_obj; i->group = g; os_strlcpy(i->ifname, ifname, sizeof(i->ifname)); os_memcpy(i->own_addr, own_addr, sizeof(i->own_addr)); if (!i->cfg.llt) { fst_printf_iface(i, MSG_WARNING, "Zero llt adjusted"); i->cfg.llt = FST_DEFAULT_LLT_CFG_VALUE; } return i; } void fst_iface_delete(struct fst_iface *i) { fst_iface_set_ies(i, NULL); wpabuf_free(i->mb_ie); os_free(i); } Boolean fst_iface_is_connected(struct fst_iface *iface, const u8 *addr, Boolean mb_only) { struct fst_get_peer_ctx *ctx; const u8 *a = fst_iface_get_peer_first(iface, &ctx, mb_only); for (; a != NULL; a = fst_iface_get_peer_next(iface, &ctx, mb_only)) if (os_memcmp(addr, a, ETH_ALEN) == 0) return TRUE; return FALSE; } void fst_iface_attach_mbie(struct fst_iface *i, struct wpabuf *mbie) { wpabuf_free(i->mb_ie); i->mb_ie = mbie; } enum mb_band_id fst_iface_get_band_id(struct fst_iface *i) { enum hostapd_hw_mode hw_mode; u8 channel; fst_iface_get_channel_info(i, &hw_mode, &channel); return fst_hw_mode_to_band(hw_mode); }
Upload File
Create Folder