Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 5f550d93 authored by Arnd Bergmann's avatar Arnd Bergmann Committed by Greg Kroah-Hartman
Browse files

staging/wilc1000: remove unused functions



A number of symbols in the wilc1000 driver are completely unused
and can be removed.
This includes two variables that are only written but not read.

Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent d3ae4fa4
Loading
Loading
Loading
Loading
+0 −295
Original line number Original line Diff line number Diff line
@@ -3366,36 +3366,6 @@ s32 host_int_set_pmkid_info(struct host_if_drv *hif_drv, struct host_if_pmkid_at
	return result;
	return result;
}
}


s32 host_int_get_pmkid_info(struct host_if_drv *hif_drv,
			    u8 *pu8PmkidInfoArray,
			    u32 u32PmkidInfoLen)
{
	struct wid wid;

	wid.id = (u16)WID_PMKID_INFO;
	wid.type = WID_STR;
	wid.size = u32PmkidInfoLen;
	wid.val = pu8PmkidInfoArray;

	return 0;
}

s32 host_int_set_RSNAConfigPSKPassPhrase(struct host_if_drv *hif_drv,
					 u8 *pu8PassPhrase,
					 u8 u8Psklength)
{
	struct wid wid;

	if ((u8Psklength > 7) && (u8Psklength < 65)) {
		wid.id = (u16)WID_11I_PSK;
		wid.type = WID_STR;
		wid.val = pu8PassPhrase;
		wid.size = u8Psklength;
	}

	return 0;
}

s32 hif_get_mac_address(struct host_if_drv *hif_drv, u8 *pu8MacAddress)
s32 hif_get_mac_address(struct host_if_drv *hif_drv, u8 *pu8MacAddress)
{
{
	s32 result = 0;
	s32 result = 0;
@@ -3436,19 +3406,6 @@ s32 host_int_set_MacAddress(struct host_if_drv *hif_drv, u8 *pu8MacAddress)
	return result;
	return result;
}
}


s32 host_int_get_RSNAConfigPSKPassPhrase(struct host_if_drv *hif_drv,
					 u8 *pu8PassPhrase, u8 u8Psklength)
{
	struct wid wid;

	wid.id = (u16)WID_11I_PSK;
	wid.type = WID_STR;
	wid.size = u8Psklength;
	wid.val = pu8PassPhrase;

	return 0;
}

s32 host_int_set_start_scan_req(struct host_if_drv *hif_drv, u8 scanSource)
s32 host_int_set_start_scan_req(struct host_if_drv *hif_drv, u8 scanSource)
{
{
	struct wid wid;
	struct wid wid;
@@ -3461,18 +3418,6 @@ s32 host_int_set_start_scan_req(struct host_if_drv *hif_drv, u8 scanSource)
	return 0;
	return 0;
}
}


s32 host_int_get_start_scan_req(struct host_if_drv *hif_drv, u8 *pu8ScanSource)
{
	struct wid wid;

	wid.id = (u16)WID_START_SCAN_REQ;
	wid.type = WID_CHAR;
	wid.val = (s8 *)pu8ScanSource;
	wid.size = sizeof(char);

	return 0;
}

s32 host_int_set_join_req(struct host_if_drv *hif_drv, u8 *pu8bssid,
s32 host_int_set_join_req(struct host_if_drv *hif_drv, u8 *pu8bssid,
			  const u8 *pu8ssid, size_t ssidLen,
			  const u8 *pu8ssid, size_t ssidLen,
			  const u8 *pu8IEs, size_t IEsLen,
			  const u8 *pu8IEs, size_t IEsLen,
@@ -3589,31 +3534,6 @@ s32 host_int_disconnect(struct host_if_drv *hif_drv, u16 u16ReasonCode)
	return result;
	return result;
}
}


s32 host_int_disconnect_station(struct host_if_drv *hif_drv, u8 assoc_id)
{
	struct wid wid;

	wid.id = (u16)WID_DISCONNECT;
	wid.type = WID_CHAR;
	wid.val = (s8 *)&assoc_id;
	wid.size = sizeof(char);

	return 0;
}

s32 host_int_get_assoc_req_info(struct host_if_drv *hif_drv,
				u8 *pu8AssocReqInfo,
				u32 u32AssocReqInfoLen)
{
	struct wid wid;

	wid.id = (u16)WID_ASSOC_REQ_INFO;
	wid.type = WID_STR;
	wid.val = pu8AssocReqInfo;
	wid.size = u32AssocReqInfoLen;

	return 0;
}


s32 host_int_get_assoc_res_info(struct host_if_drv *hif_drv,
s32 host_int_get_assoc_res_info(struct host_if_drv *hif_drv,
				u8 *pu8AssocRespInfo,
				u8 *pu8AssocRespInfo,
@@ -3646,20 +3566,6 @@ s32 host_int_get_assoc_res_info(struct host_if_drv *hif_drv,
	return result;
	return result;
}
}


s32 host_int_get_rx_power_level(struct host_if_drv *hif_drv,
				u8 *pu8RxPowerLevel,
				u32 u32RxPowerLevelLen)
{
	struct wid wid;

	wid.id = (u16)WID_RX_POWER_LEVEL;
	wid.type = WID_STR;
	wid.val = pu8RxPowerLevel;
	wid.size = u32RxPowerLevelLen;

	return 0;
}

int host_int_set_mac_chnl_num(struct host_if_drv *hif_drv, u8 channel)
int host_int_set_mac_chnl_num(struct host_if_drv *hif_drv, u8 channel)
{
{
	int result;
	int result;
@@ -3740,31 +3646,6 @@ int host_int_set_operation_mode(struct host_if_drv *hif_drv, u32 mode)
	return result;
	return result;
}
}


s32 host_int_get_host_chnl_num(struct host_if_drv *hif_drv, u8 *pu8ChNo)
{
	s32 result = 0;
	struct host_if_msg msg;

	if (!hif_drv) {
		PRINT_ER("driver is null\n");
		return -EFAULT;
	}

	memset(&msg, 0, sizeof(struct host_if_msg));

	msg.id = HOST_IF_MSG_GET_CHNL;
	msg.drv = hif_drv;

	result = wilc_mq_send(&hif_msg_q, &msg, sizeof(struct host_if_msg));
	if (result)
		PRINT_ER("wilc mq send fail\n");
	down(&hif_drv->sem_get_chnl);

	*pu8ChNo = ch_no;

	return result;
}

s32 host_int_get_inactive_time(struct host_if_drv *hif_drv,
s32 host_int_get_inactive_time(struct host_if_drv *hif_drv,
			       const u8 *mac, u32 *pu32InactiveTime)
			       const u8 *mac, u32 *pu32InactiveTime)
{
{
@@ -3793,34 +3674,6 @@ s32 host_int_get_inactive_time(struct host_if_drv *hif_drv,
	return result;
	return result;
}
}


s32 host_int_test_get_int_wid(struct host_if_drv *hif_drv, u32 *pu32TestMemAddr)
{
	s32 result = 0;
	struct wid wid;

	if (!hif_drv) {
		PRINT_ER("driver is null\n");
		return -EFAULT;
	}

	wid.id = (u16)WID_MEMORY_ADDRESS;
	wid.type = WID_INT;
	wid.val = (s8 *)pu32TestMemAddr;
	wid.size = sizeof(u32);

	result = send_config_pkt(GET_CFG, &wid, 1,
				 get_id_from_handler(hif_drv));

	if (result) {
		PRINT_ER("Failed to get wid value\n");
		return -EINVAL;
	} else {
		PRINT_D(HOSTINF_DBG, "Successfully got wid value\n");
	}

	return result;
}

s32 host_int_get_rssi(struct host_if_drv *hif_drv, s8 *ps8Rssi)
s32 host_int_get_rssi(struct host_if_drv *hif_drv, s8 *ps8Rssi)
{
{
	s32 result = 0;
	s32 result = 0;
@@ -3848,33 +3701,6 @@ s32 host_int_get_rssi(struct host_if_drv *hif_drv, s8 *ps8Rssi)
	return result;
	return result;
}
}


s32 host_int_get_link_speed(struct host_if_drv *hif_drv, s8 *ps8lnkspd)
{
	struct host_if_msg msg;
	s32 result = 0;

	memset(&msg, 0, sizeof(struct host_if_msg));
	msg.id = HOST_IF_MSG_GET_LINKSPEED;
	msg.drv = hif_drv;

	result = wilc_mq_send(&hif_msg_q, &msg, sizeof(struct host_if_msg));
	if (result) {
		PRINT_ER("Failed to send GET_LINKSPEED to message queue ");
		return -EFAULT;
	}

	down(&hif_drv->sem_get_link_speed);

	if (!ps8lnkspd) {
		PRINT_ER("LINKSPEED pointer value is null");
		return -EFAULT;
	}

	*ps8lnkspd = link_speed;

	return result;
}

s32 host_int_get_statistics(struct host_if_drv *hif_drv, struct rf_info *pstrStatistics)
s32 host_int_get_statistics(struct host_if_drv *hif_drv, struct rf_info *pstrStatistics)
{
{
	s32 result = 0;
	s32 result = 0;
@@ -3969,99 +3795,6 @@ s32 hif_set_cfg(struct host_if_drv *hif_drv,
	return result;
	return result;
}
}


s32 hif_get_cfg(struct host_if_drv *hif_drv, u16 u16WID, u16 *pu16WID_Value)
{
	s32 result = 0;

	down(&hif_drv->sem_cfg_values);

	if (!hif_drv) {
		PRINT_ER("hif_drv NULL\n");
		return -EFAULT;
	}
	PRINT_D(HOSTINF_DBG, "Getting configuration parameters\n");
	switch (u16WID)	{
	case WID_BSS_TYPE:
		*pu16WID_Value = (u16)hif_drv->cfg_values.bss_type;
		break;

	case WID_AUTH_TYPE:
		*pu16WID_Value = (u16)hif_drv->cfg_values.auth_type;
		break;

	case WID_AUTH_TIMEOUT:
		*pu16WID_Value = hif_drv->cfg_values.auth_timeout;
		break;

	case WID_POWER_MANAGEMENT:
		*pu16WID_Value = (u16)hif_drv->cfg_values.power_mgmt_mode;
		break;

	case WID_SHORT_RETRY_LIMIT:
		*pu16WID_Value = hif_drv->cfg_values.short_retry_limit;
		break;

	case WID_LONG_RETRY_LIMIT:
		*pu16WID_Value = hif_drv->cfg_values.long_retry_limit;
		break;

	case WID_FRAG_THRESHOLD:
		*pu16WID_Value = hif_drv->cfg_values.frag_threshold;
		break;

	case WID_RTS_THRESHOLD:
		*pu16WID_Value = hif_drv->cfg_values.rts_threshold;
		break;

	case WID_PREAMBLE:
		*pu16WID_Value = (u16)hif_drv->cfg_values.preamble_type;
		break;

	case WID_SHORT_SLOT_ALLOWED:
		*pu16WID_Value = (u16)hif_drv->cfg_values.short_slot_allowed;
		break;

	case WID_11N_TXOP_PROT_DISABLE:
		*pu16WID_Value = (u16)hif_drv->cfg_values.txop_prot_disabled;
		break;

	case WID_BEACON_INTERVAL:
		*pu16WID_Value = hif_drv->cfg_values.beacon_interval;
		break;

	case WID_DTIM_PERIOD:
		*pu16WID_Value = (u16)hif_drv->cfg_values.dtim_period;
		break;

	case WID_SITE_SURVEY:
		*pu16WID_Value = (u16)hif_drv->cfg_values.site_survey_enabled;
		break;

	case WID_SITE_SURVEY_SCAN_TIME:
		*pu16WID_Value = hif_drv->cfg_values.site_survey_scan_time;
		break;

	case WID_ACTIVE_SCAN_TIME:
		*pu16WID_Value = hif_drv->cfg_values.active_scan_time;
		break;

	case WID_PASSIVE_SCAN_TIME:
		*pu16WID_Value = hif_drv->cfg_values.passive_scan_time;
		break;

	case WID_CURRENT_TX_RATE:
		*pu16WID_Value = hif_drv->cfg_values.curr_tx_rate;
		break;

	default:
		break;
	}

	up(&hif_drv->sem_cfg_values);

	return result;
}

static void GetPeriodicRSSI(unsigned long arg)
static void GetPeriodicRSSI(unsigned long arg)
{
{
	struct host_if_drv *hif_drv = (struct host_if_drv *)arg;
	struct host_if_drv *hif_drv = (struct host_if_drv *)arg;
@@ -4916,34 +4649,6 @@ void host_int_freeJoinParams(void *pJoinParams)
		PRINT_ER("Unable to FREE null pointer\n");
		PRINT_ER("Unable to FREE null pointer\n");
}
}


s32 host_int_delBASession(struct host_if_drv *hif_drv, char *pBSSID, char TID)
{
	s32 result = 0;
	struct host_if_msg msg;
	struct ba_session_info *pBASessionInfo = &msg.body.session_info;

	if (!hif_drv) {
		PRINT_ER("driver is null\n");
		return -EFAULT;
	}

	memset(&msg, 0, sizeof(struct host_if_msg));

	msg.id = HOST_IF_MSG_DEL_BA_SESSION;

	memcpy(pBASessionInfo->bssid, pBSSID, ETH_ALEN);
	pBASessionInfo->tid = TID;
	msg.drv = hif_drv;

	result = wilc_mq_send(&hif_msg_q, &msg, sizeof(struct host_if_msg));
	if (result)
		PRINT_ER("wilc_mq_send fail\n");

	down(&hif_sema_wait_response);

	return result;
}

s32 host_int_del_All_Rx_BASession(struct host_if_drv *hif_drv,
s32 host_int_del_All_Rx_BASession(struct host_if_drv *hif_drv,
				  char *pBSSID,
				  char *pBSSID,
				  char TID)
				  char TID)
+0 −19
Original line number Original line Diff line number Diff line
@@ -326,18 +326,10 @@ s32 host_int_add_tx_gtk(struct host_if_drv *hWFIDrv, u8 u8KeyLen,
			u8 *pu8TxGtk, u8 u8KeyIdx);
			u8 *pu8TxGtk, u8 u8KeyIdx);
s32 host_int_set_pmkid_info(struct host_if_drv *hWFIDrv,
s32 host_int_set_pmkid_info(struct host_if_drv *hWFIDrv,
			    struct host_if_pmkid_attr *pu8PmkidInfoArray);
			    struct host_if_pmkid_attr *pu8PmkidInfoArray);
s32 host_int_get_pmkid_info(struct host_if_drv *hWFIDrv, u8 *pu8PmkidInfoArray,
			    u32 u32PmkidInfoLen);
s32 host_int_set_RSNAConfigPSKPassPhrase(struct host_if_drv *hWFIDrv,
					 u8 *pu8PassPhrase,
					 u8 u8Psklength);
s32 host_int_get_RSNAConfigPSKPassPhrase(struct host_if_drv *hWFIDrv,
					 u8 *pu8PassPhrase, u8 u8Psklength);
s32 hif_get_mac_address(struct host_if_drv *hWFIDrv, u8 *pu8MacAddress);
s32 hif_get_mac_address(struct host_if_drv *hWFIDrv, u8 *pu8MacAddress);
s32 host_int_set_MacAddress(struct host_if_drv *hWFIDrv, u8 *pu8MacAddress);
s32 host_int_set_MacAddress(struct host_if_drv *hWFIDrv, u8 *pu8MacAddress);
int host_int_wait_msg_queue_idle(void);
int host_int_wait_msg_queue_idle(void);
s32 host_int_set_start_scan_req(struct host_if_drv *hWFIDrv, u8 scanSource);
s32 host_int_set_start_scan_req(struct host_if_drv *hWFIDrv, u8 scanSource);
s32 host_int_get_start_scan_req(struct host_if_drv *hWFIDrv, u8 *pu8ScanSource);
s32 host_int_set_join_req(struct host_if_drv *hWFIDrv, u8 *pu8bssid,
s32 host_int_set_join_req(struct host_if_drv *hWFIDrv, u8 *pu8bssid,
			  const u8 *pu8ssid, size_t ssidLen,
			  const u8 *pu8ssid, size_t ssidLen,
			  const u8 *pu8IEs, size_t IEsLen,
			  const u8 *pu8IEs, size_t IEsLen,
@@ -346,21 +338,12 @@ s32 host_int_set_join_req(struct host_if_drv *hWFIDrv, u8 *pu8bssid,
			  u8 u8channel, void *pJoinParams);
			  u8 u8channel, void *pJoinParams);
s32 host_int_flush_join_req(struct host_if_drv *hWFIDrv);
s32 host_int_flush_join_req(struct host_if_drv *hWFIDrv);
s32 host_int_disconnect(struct host_if_drv *hWFIDrv, u16 u16ReasonCode);
s32 host_int_disconnect(struct host_if_drv *hWFIDrv, u16 u16ReasonCode);
s32 host_int_disconnect_station(struct host_if_drv *hWFIDrv, u8 assoc_id);
s32 host_int_get_assoc_req_info(struct host_if_drv *hWFIDrv,
				u8 *pu8AssocReqInfo,
				u32 u32AssocReqInfoLen);
s32 host_int_get_assoc_res_info(struct host_if_drv *hWFIDrv,
s32 host_int_get_assoc_res_info(struct host_if_drv *hWFIDrv,
				u8 *pu8AssocRespInfo,
				u8 *pu8AssocRespInfo,
				u32 u32MaxAssocRespInfoLen,
				u32 u32MaxAssocRespInfoLen,
				u32 *pu32RcvdAssocRespInfoLen);
				u32 *pu32RcvdAssocRespInfoLen);
s32 host_int_get_rx_power_level(struct host_if_drv *hWFIDrv,
				u8 *pu8RxPowerLevel,
				u32 u32RxPowerLevelLen);
int host_int_set_mac_chnl_num(struct host_if_drv *wfi_drv, u8 channel);
int host_int_set_mac_chnl_num(struct host_if_drv *wfi_drv, u8 channel);
s32 host_int_get_host_chnl_num(struct host_if_drv *hWFIDrv, u8 *pu8ChNo);
s32 host_int_get_rssi(struct host_if_drv *hWFIDrv, s8 *ps8Rssi);
s32 host_int_get_rssi(struct host_if_drv *hWFIDrv, s8 *ps8Rssi);
s32 host_int_get_link_speed(struct host_if_drv *hWFIDrv, s8 *ps8lnkspd);
s32 host_int_scan(struct host_if_drv *hWFIDrv, u8 u8ScanSource,
s32 host_int_scan(struct host_if_drv *hWFIDrv, u8 u8ScanSource,
		  u8 u8ScanType, u8 *pu8ChnlFreqList,
		  u8 u8ScanType, u8 *pu8ChnlFreqList,
		  u8 u8ChnlListLen, const u8 *pu8IEs,
		  u8 u8ChnlListLen, const u8 *pu8IEs,
@@ -368,7 +351,6 @@ s32 host_int_scan(struct host_if_drv *hWFIDrv, u8 u8ScanSource,
		  void *pvUserArg, struct hidden_network *pstrHiddenNetwork);
		  void *pvUserArg, struct hidden_network *pstrHiddenNetwork);
s32 hif_set_cfg(struct host_if_drv *hWFIDrv,
s32 hif_set_cfg(struct host_if_drv *hWFIDrv,
		struct cfg_param_val *pstrCfgParamVal);
		struct cfg_param_val *pstrCfgParamVal);
s32 hif_get_cfg(struct host_if_drv *hWFIDrv, u16 u16WID, u16 *pu16WID_Value);
s32 host_int_init(struct net_device *dev, struct host_if_drv **phWFIDrv);
s32 host_int_init(struct net_device *dev, struct host_if_drv **phWFIDrv);
s32 host_int_deinit(struct host_if_drv *hWFIDrv);
s32 host_int_deinit(struct host_if_drv *hWFIDrv);
s32 host_int_add_beacon(struct host_if_drv *hWFIDrv, u32 u32Interval,
s32 host_int_add_beacon(struct host_if_drv *hWFIDrv, u32 u32Interval,
@@ -394,7 +376,6 @@ s32 host_int_setup_multicast_filter(struct host_if_drv *hWFIDrv,
s32 host_int_setup_ipaddress(struct host_if_drv *hWFIDrv,
s32 host_int_setup_ipaddress(struct host_if_drv *hWFIDrv,
			     u8 *pu8IPAddr,
			     u8 *pu8IPAddr,
			     u8 idx);
			     u8 idx);
s32 host_int_delBASession(struct host_if_drv *hWFIDrv, char *pBSSID, char TID);
s32 host_int_del_All_Rx_BASession(struct host_if_drv *hWFIDrv,
s32 host_int_del_All_Rx_BASession(struct host_if_drv *hWFIDrv,
				  char *pBSSID,
				  char *pBSSID,
				  char TID);
				  char TID);
+0 −11
Original line number Original line Diff line number Diff line
@@ -226,17 +226,6 @@ int linux_sdio_init(void)
	return 1;
	return 1;
}
}


void linux_sdio_deinit(void *pv)
{

	/**
	 *      TODO :
	 **/


	sdio_unregister_driver(&wilc_bus);
}

int linux_sdio_set_max_speed(void)
int linux_sdio_set_max_speed(void)
{
{
	return linux_sdio_set_speed(MAX_SPEED);
	return linux_sdio_set_speed(MAX_SPEED);
+0 −1
Original line number Original line Diff line number Diff line
@@ -4,7 +4,6 @@ extern struct sdio_driver wilc_bus;
#include <linux/mmc/sdio_func.h>
#include <linux/mmc/sdio_func.h>


int linux_sdio_init(void);
int linux_sdio_init(void);
void linux_sdio_deinit(void *);
int linux_sdio_cmd52(sdio_cmd52_t *cmd);
int linux_sdio_cmd52(sdio_cmd52_t *cmd);
int linux_sdio_cmd53(sdio_cmd53_t *cmd);
int linux_sdio_cmd53(sdio_cmd53_t *cmd);
int enable_sdio_interrupt(void);
int enable_sdio_interrupt(void);
+0 −14
Original line number Original line Diff line number Diff line
@@ -42,7 +42,6 @@
static u32 SPEED = MIN_SPEED;
static u32 SPEED = MIN_SPEED;


struct spi_device *wilc_spi_dev;
struct spi_device *wilc_spi_dev;
void linux_spi_deinit(void *vp);


static int __init wilc_bus_probe(struct spi_device *spi)
static int __init wilc_bus_probe(struct spi_device *spi)
{
{
@@ -80,19 +79,6 @@ struct spi_driver wilc_bus __refdata = {
	.remove = __exit_p(wilc_bus_remove),
	.remove = __exit_p(wilc_bus_remove),
};
};



void linux_spi_deinit(void *vp)
{

	spi_unregister_driver(&wilc_bus);

	SPEED = MIN_SPEED;
	PRINT_ER("@@@@@@@@@@@@ restore SPI speed to %d @@@@@@@@@\n", SPEED);

}



int linux_spi_init(void)
int linux_spi_init(void)
{
{
	int ret = 1;
	int ret = 1;
Loading