if_bwn_phy_g.h revision 298948
1298948Sadrian/*- 2298948Sadrian * Copyright (c) 2009-2010 Weongyo Jeong <weongyo@freebsd.org> 3298948Sadrian * All rights reserved. 4298948Sadrian * 5298948Sadrian * Redistribution and use in source and binary forms, with or without 6298948Sadrian * modification, are permitted provided that the following conditions 7298948Sadrian * are met: 8298948Sadrian * 1. Redistributions of source code must retain the above copyright 9298948Sadrian * notice, this list of conditions and the following disclaimer, 10298948Sadrian * without modification. 11298948Sadrian * 2. Redistributions in binary form must reproduce at minimum a disclaimer 12298948Sadrian * similar to the "NO WARRANTY" disclaimer below ("Disclaimer") and any 13298948Sadrian * redistribution must be conditioned upon including a substantially 14298948Sadrian * similar Disclaimer requirement for further binary redistribution. 15298948Sadrian * 16298948Sadrian * NO WARRANTY 17298948Sadrian * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 18298948Sadrian * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 19298948Sadrian * LIMITED TO, THE IMPLIED WARRANTIES OF NONINFRINGEMENT, MERCHANTIBILITY 20298948Sadrian * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL 21298948Sadrian * THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR SPECIAL, EXEMPLARY, 22298948Sadrian * OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 23298948Sadrian * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 24298948Sadrian * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 25298948Sadrian * IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 26298948Sadrian * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF 27298948Sadrian * THE POSSIBILITY OF SUCH DAMAGES. 28298948Sadrian * 29298948Sadrian * $FreeBSD: head/sys/dev/bwn/if_bwn_phy_g.h 298948 2016-05-02 22:58:11Z adrian $ 30298948Sadrian */ 31298948Sadrian 32298948Sadrian#ifndef __IF_BWN_PHY_G_H__ 33298948Sadrian#define __IF_BWN_PHY_G_H__ 34298948Sadrian 35298948Sadrianextern int bwn_phy_g_attach(struct bwn_mac *mac); 36298948Sadrianextern void bwn_phy_g_detach(struct bwn_mac *mac); 37298948Sadrianextern int bwn_phy_g_prepare_hw(struct bwn_mac *mac); 38298948Sadrianextern void bwn_phy_g_init_pre(struct bwn_mac *mac); 39298948Sadrianextern int bwn_phy_g_init(struct bwn_mac *mac); 40298948Sadrianextern void bwn_phy_g_exit(struct bwn_mac *mac); 41298948Sadrianextern uint16_t bwn_phy_g_read(struct bwn_mac *mac, uint16_t reg); 42298948Sadrianextern void bwn_phy_g_write(struct bwn_mac *mac, uint16_t reg, uint16_t value); 43298948Sadrianextern uint16_t bwn_phy_g_rf_read(struct bwn_mac *mac, uint16_t reg); 44298948Sadrianextern void bwn_phy_g_rf_write(struct bwn_mac *mac, uint16_t reg, uint16_t value); 45298948Sadrianextern int bwn_phy_g_hwpctl(struct bwn_mac *mac); 46298948Sadrianextern void bwn_phy_g_rf_onoff(struct bwn_mac *mac, int on); 47298948Sadrianextern void bwn_phy_switch_analog(struct bwn_mac *mac, int on); 48298948Sadrianextern int bwn_phy_g_switch_channel(struct bwn_mac *mac, uint32_t newchan); 49298948Sadrianextern uint32_t bwn_phy_g_get_default_chan(struct bwn_mac *mac); 50298948Sadrianextern void bwn_phy_g_set_antenna(struct bwn_mac *mac, int antenna); 51298948Sadrianextern int bwn_phy_g_im(struct bwn_mac *mac, int mode); 52298948Sadrianextern int bwn_phy_g_recalc_txpwr(struct bwn_mac *mac, int ignore_tssi); 53298948Sadrianextern void bwn_phy_g_set_txpwr(struct bwn_mac *mac); 54298948Sadrianextern void bwn_phy_g_task_15s(struct bwn_mac *mac); 55298948Sadrianextern void bwn_phy_g_task_60s(struct bwn_mac *mac); 56298948Sadrian 57298948Sadrian#endif /* __IF_BWN_PHY_G_H__ */ 58