xref: /openwifi/kernel_boot/ad9361.patch (revision 875d61369c599a2814473e278cf72a9dfa7a4b08)
1diff --git a/drivers/iio/adc/ad9361.c b/drivers/iio/adc/ad9361.c
2index b21e2129e27c..b53d7b7ab20d 100644
3--- a/drivers/iio/adc/ad9361.c
4+++ b/drivers/iio/adc/ad9361.c
5@@ -1234,7 +1234,7 @@ static int ad9361_load_mixer_gm_subtable(struct ad9361_rf_phy *phy)
6 	return 0;
7 }
8
9-static int ad9361_set_tx_atten(struct ad9361_rf_phy *phy, u32 atten_mdb,
10+int ad9361_set_tx_atten(struct ad9361_rf_phy *phy, u32 atten_mdb,
11 			       bool tx1, bool tx2, bool immed)
12 {
13 	u8 buf[2];
14@@ -1266,8 +1266,8 @@ static int ad9361_set_tx_atten(struct ad9361_rf_phy *phy, u32 atten_mdb,
15
16 	return ret;
17 }
18-
19-static int ad9361_get_tx_atten(struct ad9361_rf_phy *phy, u32 tx_num)
20+EXPORT_SYMBOL(ad9361_set_tx_atten);
21+int ad9361_get_tx_atten(struct ad9361_rf_phy *phy, u32 tx_num)
22 {
23 	u8 buf[2];
24 	int ret = 0;
25@@ -1285,7 +1285,7 @@ static int ad9361_get_tx_atten(struct ad9361_rf_phy *phy, u32 tx_num)
26
27 	return code;
28 }
29-
30+EXPORT_SYMBOL(ad9361_get_tx_atten);
31 int ad9361_tx_mute(struct ad9361_rf_phy *phy, u32 state)
32 {
33 	struct ad9361_rf_phy_state *st = phy->state;
34@@ -3744,7 +3744,7 @@ static int ad9361_get_auxadc(struct ad9361_rf_phy *phy)
35   // Setup Control Outs
36   //************************************************************
37
38-static int ad9361_ctrl_outs_setup(struct ad9361_rf_phy *phy,
39+int ad9361_ctrl_outs_setup(struct ad9361_rf_phy *phy,
40 				  struct ctrl_outs_control *ctrl)
41 {
42 	struct spi_device *spi = phy->spi;
43@@ -3754,6 +3754,7 @@ static int ad9361_ctrl_outs_setup(struct ad9361_rf_phy *phy,
44 	ad9361_spi_write(spi, REG_CTRL_OUTPUT_POINTER, ctrl->index); // Ctrl Out index
45 	return ad9361_spi_write(spi, REG_CTRL_OUTPUT_ENABLE, ctrl->en_mask); // Ctrl Out [7:0] output enable
46 }
47+EXPORT_SYMBOL(ad9361_ctrl_outs_setup);
48   //************************************************************
49   // Setup GPO
50   //************************************************************
51@@ -5235,7 +5236,7 @@ static int ad9361_setup(struct ad9361_rf_phy *phy)
52
53 }
54
55-static int ad9361_do_calib_run(struct ad9361_rf_phy *phy, u32 cal, int arg)
56+int ad9361_do_calib_run(struct ad9361_rf_phy *phy, u32 cal, int arg)
57 {
58 	struct ad9361_rf_phy_state *st = phy->state;
59 	int ret;
60@@ -5268,7 +5269,7 @@ static int ad9361_do_calib_run(struct ad9361_rf_phy *phy, u32 cal, int arg)
61
62 	return ret;
63 }
64-
65+EXPORT_SYMBOL(ad9361_do_calib_run);
66 static int ad9361_update_rf_bandwidth(struct ad9361_rf_phy *phy,
67 				     u32 rf_rx_bw, u32 rf_tx_bw)
68 {
69