xref: /illumos-gate/usr/src/uts/common/io/ath/ath_aux.h (revision 129d67ac)
17a1306a7Sxc /*
2*3caf1114Sxc  * Copyright 2008 Sun Microsystems, Inc.  All rights reserved.
37a1306a7Sxc  * Use is subject to license terms.
47a1306a7Sxc  */
57a1306a7Sxc 
67a1306a7Sxc /*
77a1306a7Sxc  * Copyright (c) 2002-2004 Sam Leffler, Errno Consulting
87a1306a7Sxc  * All rights reserved.
97a1306a7Sxc  *
107a1306a7Sxc  * Redistribution and use in source and binary forms, with or without
117a1306a7Sxc  * modification, are permitted provided that the following conditions
127a1306a7Sxc  * are met:
137a1306a7Sxc  * 1. Redistributions of source code must retain the above copyright
147a1306a7Sxc  * notice, this list of conditions and the following disclaimer,
157a1306a7Sxc  * without modification.
167a1306a7Sxc  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
177a1306a7Sxc  * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any
187a1306a7Sxc  * redistribution must be conditioned upon including a substantially
197a1306a7Sxc  * similar Disclaimer requirement for further binary redistribution.
207a1306a7Sxc  * 3. Neither the names of the above-listed copyright holders nor the names
217a1306a7Sxc  * of any contributors may be used to endorse or promote products derived
227a1306a7Sxc  * from this software without specific prior written permission.
237a1306a7Sxc  *
247a1306a7Sxc  * NO WARRANTY
257a1306a7Sxc  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
267a1306a7Sxc  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
277a1306a7Sxc  * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY
287a1306a7Sxc  * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
297a1306a7Sxc  * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY,
307a1306a7Sxc  * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
317a1306a7Sxc  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
327a1306a7Sxc  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
337a1306a7Sxc  * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
347a1306a7Sxc  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
357a1306a7Sxc  * THE POSSIBILITY OF SUCH DAMAGES.
367a1306a7Sxc  */
377a1306a7Sxc 
387a1306a7Sxc #ifndef _ATH_AUX_H
397a1306a7Sxc #define	_ATH_AUX_H
407a1306a7Sxc 
417a1306a7Sxc #ifdef __cplusplus
427a1306a7Sxc extern "C" {
437a1306a7Sxc #endif
447a1306a7Sxc 
457a1306a7Sxc #include "ath_hal.h"
467a1306a7Sxc #include "ath_impl.h"
477a1306a7Sxc 
487a1306a7Sxc uint32_t ath_calcrxfilter(ath_t *asc);
497a1306a7Sxc void ath_beacon_config(ath_t *asc);
500ba2cbe9Sxc int ath_reset(ieee80211com_t *ic);
517a1306a7Sxc int32_t ath_startrecv(ath_t *asc);
527a1306a7Sxc void ath_stoprecv(ath_t *asc);
537a1306a7Sxc uint32_t ath_chan2flags(ieee80211com_t *isc,
540ba2cbe9Sxc     struct ieee80211_channel *chan);
557a1306a7Sxc int32_t ath_getchannels(ath_t *asc, uint32_t cc,
567a1306a7Sxc     HAL_BOOL outdoor, HAL_BOOL xchanmode);
570ba2cbe9Sxc void ath_chan_change(ath_t *asc, struct ieee80211_channel *chan);
580ba2cbe9Sxc int32_t ath_chan_set(ath_t *asc, struct ieee80211_channel *chan);
597a1306a7Sxc int ath_txq_setup(ath_t *asc);
600ba2cbe9Sxc void ath_txq_cleanup(ath_t *asc);
617a1306a7Sxc void ath_rate_setup(ath_t *asc, uint32_t mode);
627a1306a7Sxc void ath_setcurmode(ath_t *asc, enum ieee80211_phymode mode);
637a1306a7Sxc void ath_mode_init(ath_t *asc);
647a1306a7Sxc void ath_draintxq(ath_t *asc);
650ba2cbe9Sxc int ath_key_alloc(ieee80211com_t *ic, const struct ieee80211_key *k,
660ba2cbe9Sxc     ieee80211_keyix *keyix, ieee80211_keyix *rxkeyix);
670ba2cbe9Sxc int ath_key_delete(ieee80211com_t *ic, const struct ieee80211_key *k);
680ba2cbe9Sxc int ath_key_set(ieee80211com_t *ic, const struct ieee80211_key *k,
690ba2cbe9Sxc     const uint8_t mac[IEEE80211_ADDR_LEN]);
700ba2cbe9Sxc void ath_set_shortslot(ieee80211com_t *ic, int onoff);
71*3caf1114Sxc const char *ath_get_hal_status_desc(HAL_STATUS status);
727a1306a7Sxc 
737a1306a7Sxc #ifdef __cplusplus
747a1306a7Sxc }
757a1306a7Sxc #endif
767a1306a7Sxc 
777a1306a7Sxc #endif /* _ATH_AUX_H */
78