1c68e865eSAdrian Chadd /*- 2c68e865eSAdrian Chadd * Copyright (c) 2016 Adrian Chadd <adrian@FreeBSD.org>. 3c68e865eSAdrian Chadd * All rights reserved. 4c68e865eSAdrian Chadd * 5c68e865eSAdrian Chadd * Redistribution and use in source and binary forms, with or without 6c68e865eSAdrian Chadd * modification, are permitted provided that the following conditions 7c68e865eSAdrian Chadd * are met: 8c68e865eSAdrian Chadd * 1. Redistributions of source code must retain the above copyright 9c68e865eSAdrian Chadd * notice, this list of conditions and the following disclaimer, 10c68e865eSAdrian Chadd * without modification. 11c68e865eSAdrian Chadd * 2. Redistributions in binary form must reproduce at minimum a disclaimer 12c68e865eSAdrian Chadd * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any 13c68e865eSAdrian Chadd * redistribution must be conditioned upon including a substantially 14c68e865eSAdrian Chadd * similar Disclaimer requirement for further binary redistribution. 15c68e865eSAdrian Chadd * 16c68e865eSAdrian Chadd * NO WARRANTY 17c68e865eSAdrian Chadd * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 18c68e865eSAdrian Chadd * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 19c68e865eSAdrian Chadd * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY 20c68e865eSAdrian Chadd * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL 21c68e865eSAdrian Chadd * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, 22c68e865eSAdrian Chadd * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23c68e865eSAdrian Chadd * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 24c68e865eSAdrian Chadd * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 25c68e865eSAdrian Chadd * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 26c68e865eSAdrian Chadd * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 27c68e865eSAdrian Chadd * THE POSSIBILITY OF SUCH DAMAGES. 28c68e865eSAdrian Chadd */ 29c68e865eSAdrian Chadd #ifndef __PHY_COMMON_H__ 30c68e865eSAdrian Chadd #define __PHY_COMMON_H__ 31c68e865eSAdrian Chadd 32*d177c199SLandon J. Fuller extern void bwn_mac_switch_freq(struct bwn_mac *mac, 33*d177c199SLandon J. Fuller bhnd_pmu_spuravoid spurmode); 34*d177c199SLandon J. Fuller extern int bwn_phy_force_clock(struct bwn_mac *mac, int force); 35c68e865eSAdrian Chadd extern int bwn_radio_wait_value(struct bwn_mac *mac, uint16_t offset, 36c68e865eSAdrian Chadd uint16_t mask, uint16_t value, int delay, int timeout); 37*d177c199SLandon J. Fuller extern int bwn_mac_phy_clock_set(struct bwn_mac *mac, int enabled); 38*d177c199SLandon J. Fuller extern int bwn_wireless_core_phy_pll_reset(struct bwn_mac *mac); 39c68e865eSAdrian Chadd 40c68e865eSAdrian Chadd #endif /* __PHY_COMMON_H__ */ 41