xref: /freebsd/sys/dev/ath/if_athdfs.h (revision 95ee2897e98f5d444f26ed2334cc7c439f9c16c6)
148237774SAdrian Chadd /*-
2*4d846d26SWarner Losh  * SPDX-License-Identifier: BSD-2-Clause
3718cf2ccSPedro F. Giffuni  *
448237774SAdrian Chadd  * Copyright (c) 2011 Adrian Chadd, Xenion Pty Ltd
548237774SAdrian Chadd  * All rights reserved.
648237774SAdrian Chadd  *
748237774SAdrian Chadd  * Redistribution and use in source and binary forms, with or without
848237774SAdrian Chadd  * modification, are permitted provided that the following conditions
948237774SAdrian Chadd  * are met:
1048237774SAdrian Chadd  * 1. Redistributions of source code must retain the above copyright
1148237774SAdrian Chadd  *    notice, this list of conditions and the following disclaimer,
1248237774SAdrian Chadd  *    without modification.
1348237774SAdrian Chadd  * 2. Redistributions in binary form must reproduce at minimum a disclaimer
1448237774SAdrian Chadd  *    similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any
1548237774SAdrian Chadd  *    redistribution must be conditioned upon including a substantially
1648237774SAdrian Chadd  *    similar Disclaimer requirement for further binary redistribution.
1748237774SAdrian Chadd  *
1848237774SAdrian Chadd  * NO WARRANTY
1948237774SAdrian Chadd  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
2048237774SAdrian Chadd  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
2148237774SAdrian Chadd  * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY
2248237774SAdrian Chadd  * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL
2348237774SAdrian Chadd  * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY,
2448237774SAdrian Chadd  * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
2548237774SAdrian Chadd  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
2648237774SAdrian Chadd  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
2748237774SAdrian Chadd  * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
2848237774SAdrian Chadd  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
2948237774SAdrian Chadd  * THE POSSIBILITY OF SUCH DAMAGES.
3048237774SAdrian Chadd  */
3148237774SAdrian Chadd #ifndef	__IF_ATHDFS_H__
3248237774SAdrian Chadd #define	__IF_ATHDFS_H__
3348237774SAdrian Chadd 
3448237774SAdrian Chadd extern	int ath_dfs_attach(struct ath_softc *sc);
3548237774SAdrian Chadd extern	int ath_dfs_detach(struct ath_softc *sc);
36ead404d4SAdrian Chadd extern	int ath_dfs_radar_enable(struct ath_softc *,
3748237774SAdrian Chadd     struct ieee80211_channel *chan);
38c9b690d3SAdrian Chadd extern	int ath_dfs_radar_disable(struct ath_softc *sc);
39d77363adSAdrian Chadd extern	void ath_dfs_process_phy_err(struct ath_softc *sc, struct mbuf *m,
4048237774SAdrian Chadd     uint64_t tsf, struct ath_rx_status *rxstat);
4148237774SAdrian Chadd extern	int ath_dfs_process_radar_event(struct ath_softc *sc,
4248237774SAdrian Chadd     struct ieee80211_channel *chan);
4348237774SAdrian Chadd extern	int ath_dfs_tasklet_needed(struct ath_softc *sc,
4448237774SAdrian Chadd     struct ieee80211_channel *chan);
4548237774SAdrian Chadd extern	int ath_ioctl_phyerr(struct ath_softc *sc, struct ath_diag *ad);
468db87e40SAdrian Chadd extern	int ath_dfs_get_thresholds(struct ath_softc *sc,
478db87e40SAdrian Chadd     HAL_PHYERR_PARAM *param);
4848237774SAdrian Chadd 
4948237774SAdrian Chadd #endif	/* __IF_ATHDFS_H__ */
50