aboutsummaryrefslogtreecommitdiff
path: root/drivers/staging/csr
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/staging/csr')
-rw-r--r--drivers/staging/csr/bh.c2
-rw-r--r--drivers/staging/csr/csr_log.h6
-rw-r--r--drivers/staging/csr/csr_sdio.h24
-rw-r--r--drivers/staging/csr/csr_time.c8
-rw-r--r--drivers/staging/csr/csr_wifi_fsm.h6
-rw-r--r--drivers/staging/csr/csr_wifi_hip_card_sdio.c8
-rw-r--r--drivers/staging/csr/csr_wifi_hip_card_sdio_intr.c10
-rw-r--r--drivers/staging/csr/csr_wifi_hip_chiphelper.h4
-rw-r--r--drivers/staging/csr/csr_wifi_hip_unifi.h20
-rw-r--r--drivers/staging/csr/drv.c4
-rw-r--r--drivers/staging/csr/netdev.c2
-rw-r--r--drivers/staging/csr/sdio_mmc.c3
-rw-r--r--drivers/staging/csr/sme_native.c2
-rw-r--r--drivers/staging/csr/sme_wext.c3
-rw-r--r--drivers/staging/csr/unifi_pdu_processing.c20
-rw-r--r--drivers/staging/csr/unifi_sme.c2
16 files changed, 61 insertions, 63 deletions
diff --git a/drivers/staging/csr/bh.c b/drivers/staging/csr/bh.c
index 7b133597e92..b53a9e29a97 100644
--- a/drivers/staging/csr/bh.c
+++ b/drivers/staging/csr/bh.c
@@ -373,7 +373,7 @@ CsrResult unifi_run_bh(void *ospriv)
unifi_priv_t *priv = ospriv;
/*
- * If an error has occured, we discard silently all messages from the bh
+ * If an error has occurred, we discard silently all messages from the bh
* until the error has been processed and the unifi has been reinitialised.
*/
if (priv->bh_thread.block_thread == 1) {
diff --git a/drivers/staging/csr/csr_log.h b/drivers/staging/csr/csr_log.h
index 5de5650767d..982941043dd 100644
--- a/drivers/staging/csr/csr_log.h
+++ b/drivers/staging/csr/csr_log.h
@@ -34,7 +34,7 @@ typedef u32 CsrLogLevelEnvironment;
#define CSR_LOG_LEVEL_ENVIRONMENT_BGINT_START ((CsrLogLevelEnvironment) 0x00000100) /* Background Interrupt start events are logged */
#define CSR_LOG_LEVEL_ENVIRONMENT_BGINT_DONE ((CsrLogLevelEnvironment) 0x00000200) /* Background Interrupt done events are logged */
#define CSR_LOG_LEVEL_ENVIRONMENT_PROTO ((CsrLogLevelEnvironment) 0x00000400) /* Transport protocol events are logged */
-#define CSR_LOG_LEVEL_ENVIRONMENT_PROTO_LOC ((CsrLogLevelEnvironment) 0x00000800) /* The Location where the transport protocol event occured are logged NB: This is a supplement to CSR_LOG_LEVEL_ENVIRONMENT_PROTO, it has no effect without it */
+#define CSR_LOG_LEVEL_ENVIRONMENT_PROTO_LOC ((CsrLogLevelEnvironment) 0x00000800) /* The Location where the transport protocol event occurred are logged NB: This is a supplement to CSR_LOG_LEVEL_ENVIRONMENT_PROTO, it has no effect without it */
/* The bit masks between here are reserved for future usage */
#define CSR_LOG_LEVEL_ENVIRONMENT_ALL ((CsrLogLevelEnvironment) 0xFFFFFFFF) /* All possible environment data/events are logged WARNING: By using this define the application also accepts future possible environment data/events in the logs */
@@ -44,10 +44,10 @@ typedef u32 CsrLogLevelEnvironment;
typedef u32 CsrLogLevelTask;
#define CSR_LOG_LEVEL_TASK_OFF ((CsrLogLevelTask) 0x00000000) /* No events are logged for this task */
#define CSR_LOG_LEVEL_TASK_TEXT ((CsrLogLevelTask) 0x00000001) /* Text strings printed by a task are logged NB: This bit does not affect the CSR_LOG_TEXT_LEVEL interface. This has to be configured separately */
-#define CSR_LOG_LEVEL_TASK_TEXT_LOC ((CsrLogLevelTask) 0x00000002) /* The locaction where the text string call occured are logged. NB: This is a supplement to CSR_LOG_LEVEL_TASK_TEXT, it has no effect without it */
+#define CSR_LOG_LEVEL_TASK_TEXT_LOC ((CsrLogLevelTask) 0x00000002) /* The locaction where the text string call occurred are logged. NB: This is a supplement to CSR_LOG_LEVEL_TASK_TEXT, it has no effect without it */
#define CSR_LOG_LEVEL_TASK_STATE ((CsrLogLevelTask) 0x00000004) /* FSM state transitions in a task are logged */
#define CSR_LOG_LEVEL_TASK_STATE_NAME ((CsrLogLevelTask) 0x00000008) /* The name of each state in a FSM state transition are logged. NB: This is a supplement to CSR_LOG_LEVEL_TASK_STATE, it has no effect without it */
-#define CSR_LOG_LEVEL_TASK_STATE_LOC ((CsrLogLevelTask) 0x00000010) /* The location where the FSM state transition occured are logged. NB: This is a supplement to CSR_LOG_LEVEL_TASK_STATE, it has no effect without it */
+#define CSR_LOG_LEVEL_TASK_STATE_LOC ((CsrLogLevelTask) 0x00000010) /* The location where the FSM state transition occurred are logged. NB: This is a supplement to CSR_LOG_LEVEL_TASK_STATE, it has no effect without it */
#define CSR_LOG_LEVEL_TASK_TASK_SWITCH ((CsrLogLevelTask) 0x00000020) /* Activation and deactiation of a task are logged */
#define CSR_LOG_LEVEL_TASK_MESSAGE_PUT ((CsrLogLevelTask) 0x00000080) /* Message put operations are logged */
#define CSR_LOG_LEVEL_TASK_MESSAGE_PUT_LOC ((CsrLogLevelTask) 0x00000100) /* The location where a message was sent are logged. NB: This is a supplement to CSR_LOG_LEVEL_TASK_MESSAGE_PUT, it has no effect without it */
diff --git a/drivers/staging/csr/csr_sdio.h b/drivers/staging/csr/csr_sdio.h
index 624a53fa1d7..0971d135abf 100644
--- a/drivers/staging/csr/csr_sdio.h
+++ b/drivers/staging/csr/csr_sdio.h
@@ -257,7 +257,7 @@ void CsrSdioFunctionDriverUnregister(CsrSdioFunctionDriver *functionDriver);
* CSR_RESULT_SUCCESS - The specified function was enabled/disabled.
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. The state of the
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. The state of the
* related bit in the I/O Enable register is
* undefined.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device, or the related
@@ -295,7 +295,7 @@ CsrResult CsrSdioFunctionDisable(CsrSdioFunction *function);
* CSR_RESULT_SUCCESS - The specified function was enabled/disabled.
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. The state of the
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. The state of the
* related bit in the INT Enable register is
* unchanged.
* CSR_SDIO_RESULT_INVALID_VALUE - The specified function cannot be
@@ -408,7 +408,7 @@ void CsrSdioResumeAcknowledge(CsrSdioFunction *function, CsrResult result);
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_INVALID_VALUE - One or more arguments were invalid.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. The configured block
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. The configured block
* size is undefined.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device.
*
@@ -456,7 +456,7 @@ CsrResult CsrSdioBlockSizeSet(CsrSdioFunction *function, u16 blockSize);
* maxFrequency - The maximum clock frequency for the function in Hertz.
*
* RETURNS
- * CSR_RESULT_SUCCESS - The maximum clock frequency was succesfully
+ * CSR_RESULT_SUCCESS - The maximum clock frequency was successfully
* set for the function.
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_INVALID_VALUE - One or more arguments were invalid.
@@ -494,7 +494,7 @@ CsrResult CsrSdioMaxBusClockFrequencySet(CsrSdioFunction *function, u32 maxFrequ
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_INVALID_VALUE - One or more arguments were invalid.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. No data read/written.
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. No data read/written.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device.
*
* NOTE: If the SDIO R5 response is available, and either of the
@@ -537,7 +537,7 @@ void CsrSdioWrite8Async(CsrSdioFunction *function, u32 address, u8 data, CsrSdio
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_INVALID_VALUE - One or more arguments were invalid.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. Data may have been
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. Data may have been
* partially read/written.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device.
*
@@ -583,7 +583,7 @@ void CsrSdioWrite16Async(CsrSdioFunction *function, u32 address, u16 data, CsrSd
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_INVALID_VALUE - One or more arguments were invalid.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. No data read/written.
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. No data read/written.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device.
*
* NOTE: If the SDIO R5 response is available, and either of the
@@ -628,7 +628,7 @@ void CsrSdioF0Write8Async(CsrSdioFunction *function, u32 address, u8 data, CsrSd
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_INVALID_VALUE - One or more arguments were invalid.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured. Data may have been
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred. Data may have been
* partially read/written.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device.
*
@@ -666,11 +666,11 @@ void CsrSdioWriteAsync(CsrSdioFunction *function, u32 address, const void *data,
* the device to power on/off.
*
* RETURNS (only CsrSdioPowerOn)
- * CSR_RESULT_SUCCESS - Power was succesfully reapplied and the device
+ * CSR_RESULT_SUCCESS - Power was successfully reapplied and the device
* has been reinitialised.
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured during reinitialisation.
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred during reinitialisation.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device during
* reinitialisation.
* CSR_SDIO_RESULT_NOT_RESET - The power was not removed by the
@@ -693,11 +693,11 @@ void CsrSdioPowerOff(CsrSdioFunction *function);
* the device to hard reset.
*
* RETURNS
- * CSR_RESULT_SUCCESS - Reset was succesfully performed and the device
+ * CSR_RESULT_SUCCESS - Reset was successfully performed and the device
* has been reinitialised.
* CSR_RESULT_FAILURE - Unspecified/unknown error.
* CSR_SDIO_RESULT_NO_DEVICE - The device does not exist anymore.
- * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occured during reinitialisation.
+ * CSR_SDIO_RESULT_CRC_ERROR - A CRC error occurred during reinitialisation.
* CSR_SDIO_RESULT_TIMEOUT - No response from the device during
* reinitialisation.
* CSR_SDIO_RESULT_NOT_RESET - The reset was not applied because it is not
diff --git a/drivers/staging/csr/csr_time.c b/drivers/staging/csr/csr_time.c
index f3f4a9c9c67..01179e46f47 100644
--- a/drivers/staging/csr/csr_time.c
+++ b/drivers/staging/csr/csr_time.c
@@ -1,10 +1,10 @@
/*****************************************************************************
- (c) Cambridge Silicon Radio Limited 2010
- All rights reserved and confidential information of CSR
+ (c) Cambridge Silicon Radio Limited 2010
+ All rights reserved and confidential information of CSR
- Refer to LICENSE.txt included with this source for details
- on the license terms.
+ Refer to LICENSE.txt included with this source for details
+ on the license terms.
*****************************************************************************/
diff --git a/drivers/staging/csr/csr_wifi_fsm.h b/drivers/staging/csr/csr_wifi_fsm.h
index fde1508c1ea..fc5c5aa6a3c 100644
--- a/drivers/staging/csr/csr_wifi_fsm.h
+++ b/drivers/staging/csr/csr_wifi_fsm.h
@@ -70,7 +70,7 @@ extern CsrWifiFsmContext* CsrWifiFsmInit(void *applicationContext, void *externa
* This function is used to free any dynamic resources allocated for the
* given context by CsrWifiFsmInit().
* The FSM's reset function is called to cleanup any fsm specific memory
- * The reset funtion does NOT need to free the fsm data pointer as
+ * The reset function does NOT need to free the fsm data pointer as
* CsrWifiFsmShutdown() will do it.
* the FSM's init function is call again to reinitialise the FSM context.
* CsrWifiFsmReset() should NEVER be called when CsrWifiFsmExecute() is running.
@@ -91,7 +91,7 @@ extern void CsrWifiFsmReset(CsrWifiFsmContext *context);
* given context by CsrWifiFsmInit(), prior to complete termination of
* the program.
* The FSM's reset function is called to cleanup any fsm specific memory.
- * The reset funtion does NOT need to free the fsm data pointer as
+ * The reset function does NOT need to free the fsm data pointer as
* CsrWifiFsmShutdown() will do it.
* CsrWifiFsmShutdown() should NEVER be called when CsrWifiFsmExecute() is running.
*
@@ -203,7 +203,7 @@ extern void CsrWifiFsmFastForward(CsrWifiFsmContext *context, u16 ms);
* shift the current time of day by ms amount
*
* @par Description
- * usefull to speed up tests where time needs to pass
+ * useful to speed up tests where time needs to pass
*
* @param[in] context : FSM context
* @param[in] ms : ms to adjust time by
diff --git a/drivers/staging/csr/csr_wifi_hip_card_sdio.c b/drivers/staging/csr/csr_wifi_hip_card_sdio.c
index 25cabf3234c..d5425325894 100644
--- a/drivers/staging/csr/csr_wifi_hip_card_sdio.c
+++ b/drivers/staging/csr/csr_wifi_hip_card_sdio.c
@@ -559,7 +559,7 @@ static void _build_sdio_config_data(sdio_config_data_t *cfg_data,
* padding bytes. Every read from this memory has to be transformed in
* host (cpu specific) format, before it is stored in driver's parameters
* or/and structures. Athough unifi_card_read16() and unifi_read32() do perform
- * the convertion internally, unifi_readn() does not.
+ * the conversion internally, unifi_readn() does not.
* ---------------------------------------------------------------------------
*/
static CsrResult card_hw_init(card_t *card)
@@ -1332,7 +1332,7 @@ static CsrResult card_access_panic(card_t *card)
s32 i;
CsrResult r, sr;
- /* A chip version of zero means that the version never got succesfully read
+ /* A chip version of zero means that the version never got successfully read
* during reset. In this case give up because it will not be possible to
* verify the chip version.
*/
@@ -2446,7 +2446,7 @@ static CsrResult unifi_prepare_hw(card_t *card)
if (old_state == UNIFI_HOST_STATE_TORPID)
{
- /* Ensure the initial clock rate is set; if a reset occured when the chip was
+ /* Ensure the initial clock rate is set; if a reset occurred when the chip was
* TORPID, unifi_set_host_state() may have raised it to MAX.
*/
csrResult = CsrSdioMaxBusClockFrequencySet(card->sdio_if, UNIFI_SDIO_CLOCK_INIT_HZ);
@@ -2567,7 +2567,7 @@ static CsrResult unifi_reset_hardware(card_t *card)
csrResult = CsrSdioHardReset(card->sdio_if);
if (csrResult == CSR_RESULT_SUCCESS)
{
- unifi_info(card->ospriv, "CsrSdioHardReset succeeded on reseting UniFi\n");
+ unifi_info(card->ospriv, "CsrSdioHardReset succeeded on resetting UniFi\n");
r = unifi_prepare_hw(card);
if (r == CSR_WIFI_HIP_RESULT_NO_DEVICE)
{
diff --git a/drivers/staging/csr/csr_wifi_hip_card_sdio_intr.c b/drivers/staging/csr/csr_wifi_hip_card_sdio_intr.c
index 97f645c0681..cfe186e0707 100644
--- a/drivers/staging/csr/csr_wifi_hip_card_sdio_intr.c
+++ b/drivers/staging/csr/csr_wifi_hip_card_sdio_intr.c
@@ -883,7 +883,7 @@ static CsrResult handle_host_protocol(card_t *card, u8 *processed_something)
r = read_to_host_signals(card, &done);
if (r != CSR_RESULT_SUCCESS)
{
- unifi_error(card->ospriv, "Error occured reading to-host signals\n");
+ unifi_error(card->ospriv, "Error occurred reading to-host signals\n");
return r;
}
if (done > 0)
@@ -899,7 +899,7 @@ static CsrResult handle_host_protocol(card_t *card, u8 *processed_something)
r = process_to_host_signals(card, &done);
if (r != CSR_RESULT_SUCCESS)
{
- unifi_error(card->ospriv, "Error occured processing to-host signals\n");
+ unifi_error(card->ospriv, "Error occurred processing to-host signals\n");
return r;
}
@@ -908,7 +908,7 @@ static CsrResult handle_host_protocol(card_t *card, u8 *processed_something)
r = process_fh_cmd_queue(card, &done);
if (r != CSR_RESULT_SUCCESS)
{
- unifi_error(card->ospriv, "Error occured processing from-host signals\n");
+ unifi_error(card->ospriv, "Error occurred processing from-host signals\n");
return r;
}
if (done > 0)
@@ -919,7 +919,7 @@ static CsrResult handle_host_protocol(card_t *card, u8 *processed_something)
r = process_fh_traffic_queue(card, &done);
if (r != CSR_RESULT_SUCCESS)
{
- unifi_error(card->ospriv, "Error occured processing from-host data signals\n");
+ unifi_error(card->ospriv, "Error occurred processing from-host data signals\n");
return r;
}
if (done > 0)
@@ -1953,7 +1953,7 @@ static CsrResult check_fh_sig_slots(card_t *card, u16 needed, s32 *space_fh)
* in the from-host queue using the wire-format structures, as they arrive.
* All other requests are stored in the from-host queue using the host
* (cpu specific) structures. We use the is_packed member of the card_signal_t
- * structure that describes the queue to make the distiction.
+ * structure that describes the queue to make the distinction.
* ---------------------------------------------------------------------------
*/
static CsrResult process_fh_cmd_queue(card_t *card, s32 *processed)
diff --git a/drivers/staging/csr/csr_wifi_hip_chiphelper.h b/drivers/staging/csr/csr_wifi_hip_chiphelper.h
index b6b67ee11db..09b3aefcbce 100644
--- a/drivers/staging/csr/csr_wifi_hip_chiphelper.h
+++ b/drivers/staging/csr/csr_wifi_hip_chiphelper.h
@@ -354,7 +354,7 @@ CHIP_HELPER_LIST(C_DEC)
map that is part of the window and the size is the number of
visible words.
- Some of the windows have thier lowest portion covered by
+ Some of the windows have their lowest portion covered by
registers. For these windows address is the first address
after the registers and size is the siave excluding the part
covered by registers.
@@ -375,7 +375,7 @@ CHIP_HELPER_LIST(C_DEC)
will be needed if the device is being booted from cold. These
register writes enable the clocks and setup the PLL to a basic
working state. SPI access might be unreliable until these writes
- have occured (And they may take mulitple goes).
+ have occurred (And they may take mulitple goes).
*/
/* HostResetSequence
diff --git a/drivers/staging/csr/csr_wifi_hip_unifi.h b/drivers/staging/csr/csr_wifi_hip_unifi.h
index c2a2231680f..1160a0e25c7 100644
--- a/drivers/staging/csr/csr_wifi_hip_unifi.h
+++ b/drivers/staging/csr/csr_wifi_hip_unifi.h
@@ -117,9 +117,9 @@ typedef enum
UNIFI_TRAFFIC_Q_BE,
UNIFI_TRAFFIC_Q_VI,
UNIFI_TRAFFIC_Q_VO,
- UNIFI_TRAFFIC_Q_EAPOL, /* Non existant in HIP */
- UNIFI_TRAFFIC_Q_MAX, /* Non existant */
- UNIFI_TRAFFIC_Q_MLME /* Non existant */
+ UNIFI_TRAFFIC_Q_EAPOL, /* Non existent in HIP */
+ UNIFI_TRAFFIC_Q_MAX, /* Non existent */
+ UNIFI_TRAFFIC_Q_MLME /* Non existent */
} unifi_TrafficQueue;
/*
@@ -263,7 +263,7 @@ card_t* unifi_alloc_card(CsrSdioFunction *sdiopriv, void *ospriv);
*
* @return \b 0 if UniFi is initialized.
*
- * @return \b -CSR_EIO if an I/O error occured while initializing UniFi
+ * @return \b -CSR_EIO if an I/O error occurred while initializing UniFi
*
* @return \b -CSR_ENODEV if the card is no longer present.
*
@@ -311,7 +311,7 @@ void unifi_cancel_pending_signals(card_t *card);
*
* @return \b 0 signal is sent.
*
- * @return \b -CSR_EIO if an error occured while sending the signal
+ * @return \b -CSR_EIO if an error occurred while sending the signal
*
* @return \b -CSR_ENODEV if the card is no longer present.
*
@@ -361,7 +361,7 @@ void unifi_card_info(card_t *card, card_info_t *card_info);
*
* @return \b 0 if the check was performed.
*
- * @return \b -CSR_EIO if an error occured while checking the status.
+ * @return \b -CSR_EIO if an error occurred while checking the status.
*
* @return \b -CSR_ENODEV if the card is no longer present.
*
@@ -383,11 +383,11 @@ CsrResult unifi_check_io_status(card_t *card, s32 *status);
* is required. If unifi_bh() is called before the timeout expires,
* the caller must pass in the remaining time.
*
- * @return \b 0 if no error occured.
+ * @return \b 0 if no error occurred.
*
* @return \b -CSR_ENODEV if the card is no longer present.
*
- * @return \b -CSR_E* if an error occured while running the bottom half.
+ * @return \b -CSR_E* if an error occurred while running the bottom half.
*
* @ingroup upperedge
*/
@@ -439,7 +439,7 @@ enum unifi_periodic_wake_mode
*
* @param periodic_wake_mode the Periodic Wake Mode.
*
- * @return \b 0 if no error occured.
+ * @return \b 0 if no error occurred.
*
* @return \b -CSR_E* if the request failed.
*
@@ -458,7 +458,7 @@ CsrResult unifi_configure_low_power_mode(card_t *card,
*
* @param card the HIP core lib API context.
*
- * @return \b 0 if no error occured.
+ * @return \b 0 if no error occurred.
*
* @return \b -CSR_ENODEV if the card is no longer present.
*
diff --git a/drivers/staging/csr/drv.c b/drivers/staging/csr/drv.c
index 3bd52fdeac3..5520d6539f7 100644
--- a/drivers/staging/csr/drv.c
+++ b/drivers/staging/csr/drv.c
@@ -1815,7 +1815,7 @@ udi_log_event(ul_client_t *pcli,
}
/* Allocate log structure plus actual signal. */
- logptr = (udi_log_t *)kmalloc(sizeof(udi_log_t) + total_len, GFP_KERNEL);
+ logptr = kmalloc(sizeof(udi_log_t) + total_len, GFP_KERNEL);
if (logptr == NULL) {
printk(KERN_ERR
@@ -1890,7 +1890,7 @@ uf_sme_queue_message(unifi_priv_t *priv, u8 *buffer, int length)
}
/* Allocate log structure plus actual signal. */
- logptr = (udi_log_t *)kmalloc(sizeof(udi_log_t) + length, GFP_ATOMIC);
+ logptr = kmalloc(sizeof(udi_log_t) + length, GFP_ATOMIC);
if (logptr == NULL) {
unifi_error(priv, "Failed to allocate %d bytes for an SME message\n",
sizeof(udi_log_t) + length);
diff --git a/drivers/staging/csr/netdev.c b/drivers/staging/csr/netdev.c
index 7dad26f7017..a0177d99897 100644
--- a/drivers/staging/csr/netdev.c
+++ b/drivers/staging/csr/netdev.c
@@ -2365,7 +2365,7 @@ unifi_rx(unifi_priv_t *priv, CSR_SIGNAL *signal, bulk_data_param_t *bulkdata)
rx_buffered_packets_t *rx_q_item;
struct list_head *rx_list;
- rx_q_item = (rx_buffered_packets_t *)kmalloc(sizeof(rx_buffered_packets_t),
+ rx_q_item = kmalloc(sizeof(rx_buffered_packets_t),
GFP_KERNEL);
if (rx_q_item == NULL) {
unifi_error(priv, "%s: Failed to allocate %d bytes for rx packet record\n",
diff --git a/drivers/staging/csr/sdio_mmc.c b/drivers/staging/csr/sdio_mmc.c
index b6a16de08f4..30271d35af5 100644
--- a/drivers/staging/csr/sdio_mmc.c
+++ b/drivers/staging/csr/sdio_mmc.c
@@ -1031,8 +1031,7 @@ uf_glue_sdio_probe(struct sdio_func *func,
sdio_func_id(func), instance);
/* Allocate context */
- sdio_ctx = (CsrSdioFunction *)kmalloc(sizeof(CsrSdioFunction),
- GFP_KERNEL);
+ sdio_ctx = kmalloc(sizeof(CsrSdioFunction), GFP_KERNEL);
if (sdio_ctx == NULL) {
sdio_release_host(func);
return -ENOMEM;
diff --git a/drivers/staging/csr/sme_native.c b/drivers/staging/csr/sme_native.c
index 525fe1bce0e..ca55249bde3 100644
--- a/drivers/staging/csr/sme_native.c
+++ b/drivers/staging/csr/sme_native.c
@@ -273,7 +273,7 @@ sme_native_log_event(ul_client_t *pcli,
}
/* Allocate log structure plus actual signal. */
- logptr = (udi_log_t *)kmalloc(sizeof(udi_log_t) + total_len, GFP_KERNEL);
+ logptr = kmalloc(sizeof(udi_log_t) + total_len, GFP_KERNEL);
if (logptr == NULL) {
unifi_error(priv,
diff --git a/drivers/staging/csr/sme_wext.c b/drivers/staging/csr/sme_wext.c
index 5e06a380b40..4129a6436b7 100644
--- a/drivers/staging/csr/sme_wext.c
+++ b/drivers/staging/csr/sme_wext.c
@@ -1273,7 +1273,6 @@ unifi_siwscan(struct net_device *dev, struct iw_request_info *info,
{
netInterface_priv_t *interfacePriv = (netInterface_priv_t *)netdev_priv(dev);
unifi_priv_t *priv = interfacePriv->privPtr;
- int scantype;
int r;
CsrWifiSsid scan_ssid;
unsigned char *channel_list = NULL;
@@ -1293,8 +1292,6 @@ unifi_siwscan(struct net_device *dev, struct iw_request_info *info,
}
- scantype = UNIFI_SCAN_ACTIVE;
-
#if WIRELESS_EXT > 17
/* Providing a valid channel list will force an active scan */
if (req) {
diff --git a/drivers/staging/csr/unifi_pdu_processing.c b/drivers/staging/csr/unifi_pdu_processing.c
index 95efc360cc2..f9b421b5aa3 100644
--- a/drivers/staging/csr/unifi_pdu_processing.c
+++ b/drivers/staging/csr/unifi_pdu_processing.c
@@ -403,7 +403,7 @@ CsrResult enque_tx_data_pdu(unifi_priv_t *priv, bulk_data_param_t *bulkdata,
- tx_q_item = (tx_buffered_packets_t *)kmalloc(sizeof(tx_buffered_packets_t), GFP_ATOMIC);
+ tx_q_item = kmalloc(sizeof(tx_buffered_packets_t), GFP_ATOMIC);
if (tx_q_item == NULL) {
unifi_error(priv,
"Failed to allocate %d bytes for tx packet record\n",
@@ -1468,7 +1468,7 @@ static int update_macheader(unifi_priv_t *priv, struct sk_buff *skb,
}
}
- /* prepare the complete skb, by pushing the MAC header to the begining of the skb->data */
+ /* prepare the complete skb, by pushing the MAC header to the beginning of the skb->data */
unifi_trace(priv, UDBG5, "updated Mac Header: %d \n",macHeaderLengthInBytes);
memcpy(bufPtr, macHeaderBuf, macHeaderLengthInBytes);
@@ -1546,7 +1546,7 @@ uf_ap_process_data_pdu(unifi_priv_t *priv, struct sk_buff *skb,
return -1;
}
- /* fetch the destination record from staion record database */
+ /* fetch the destination record from station record database */
dstStaInfo = CsrWifiRouterCtrlGetStationRecordFromPeerMacAddress(priv, ehdr->h_dest, interfaceTag);
/* AP mode processing, & if packet is unicast */
@@ -1878,13 +1878,13 @@ CsrResult uf_process_ma_packet_req(unifi_priv_t *priv,
}
else if ((pktType == CSR_WIFI_MULTICAST_PDU) && (!status))
{
- /* If broadcast Tim is set && queuing is successfull, then only update TIM */
+ /* If broadcast Tim is set && queuing is successful, then only update TIM */
spin_lock_irqsave(&priv->staRecord_lock,lock_flags);
interfacePriv->noOfbroadcastPktQueued++;
spin_unlock_irqrestore(&priv->staRecord_lock,lock_flags);
}
}
- /* If broadcast Tim is set && queuing is successfull, then only update TIM */
+ /* If broadcast Tim is set && queuing is successful, then only update TIM */
if(setBcTim && !status) {
unifi_trace(priv, UDBG3, "tim set due to broadcast pkt\n");
if (!interfacePriv->bcTimSetReqPendingFlag)
@@ -1995,7 +1995,7 @@ s8 uf_get_protection_bit_from_interfacemode(unifi_priv_t *priv, u16 interfaceTag
*/
protection = interfacePriv->protect;
} else {
- /* fetch the destination record from staion record database */
+ /* fetch the destination record from station record database */
dstStaInfo = CsrWifiRouterCtrlGetStationRecordFromPeerMacAddress(priv, daddr, interfaceTag);
if (!dstStaInfo) {
unifi_trace(priv, UDBG3, "peer not found in station record in send_ma_pkt_request\n");
@@ -3170,7 +3170,7 @@ void uf_process_ps_poll(unifi_priv_t *priv,u8* sa,u8* da,u8 pmBit,u16 interfaceT
/*Send Data From Management Frames*/
/* Priority orders for delivering the buffered packets are
* 1. Deliver the Management frames if there
- * 2. Other access catagory frames which are non deliver enable including UNIFI_TRAFFIC_Q_VO
+ * 2. Other access category frames which are non deliver enable including UNIFI_TRAFFIC_Q_VO
* priority is from VO->BK
*/
@@ -3282,7 +3282,7 @@ void add_to_send_cfm_list(unifi_priv_t * priv,
{
tx_buffered_packets_t *send_cfm_list_item = NULL;
- send_cfm_list_item = (tx_buffered_packets_t *) kmalloc(sizeof(tx_buffered_packets_t), GFP_ATOMIC);
+ send_cfm_list_item = kmalloc(sizeof(tx_buffered_packets_t), GFP_ATOMIC);
if(send_cfm_list_item == NULL){
unifi_warning(priv, "%s: Failed to allocate memory for new list item \n");
@@ -3439,7 +3439,7 @@ CsrWifiRouterCtrlStaInfo_t *CsrWifiRouterCtrlGetStationRecordFromPeerMacAddress(
interfacePriv = priv->interfacePriv[interfaceTag];
- /* disable the preemption untill station record is fetched */
+ /* disable the preemption until station record is fetched */
spin_lock_irqsave(&priv->staRecord_lock,lock_flags);
for (i = 0; i < UNIFI_MAX_CONNECTIONS; i++) {
@@ -3665,7 +3665,7 @@ void update_eosp_to_head_of_broadcast_list_head(unifi_priv_t *priv,u16 interface
if (interfacePriv->noOfbroadcastPktQueued) {
/* Update the EOSP to the HEAD of b/c list
- * beacuse we have received any mgmt packet so it should not hold for long time
+ * because we have received any mgmt packet so it should not hold for long time
* peer may time out.
*/
spin_lock_irqsave(&priv->tx_q_lock,lock_flags);
diff --git a/drivers/staging/csr/unifi_sme.c b/drivers/staging/csr/unifi_sme.c
index 7d19e632a5e..90295035621 100644
--- a/drivers/staging/csr/unifi_sme.c
+++ b/drivers/staging/csr/unifi_sme.c
@@ -876,6 +876,8 @@ int unifi_cfg_get_info(unifi_priv_t *priv, unsigned char *arg)
{
#ifdef CSR_SUPPORT_WEXT_AP
uf_cfg_ap_config_t cfg_ap_config;
+
+ memset(&cfg_ap_config, 0, sizeof(cfg_ap_config));
cfg_ap_config.channel = priv->ap_config.channel;
cfg_ap_config.beaconInterval = priv->ap_mac_config.beaconInterval;
cfg_ap_config.wmmEnabled = priv->ap_mac_config.wmmEnabled;