2014-11-06 22:56:36

by Krzysztof Konopko

[permalink] [raw]
Subject: [PATCH] rtl8188eu: Fix several stylistic problems in rtw_led.*

From: Krzysztof Konopko <[email protected]>

Several stylistics problems are reported by scripts/checkpatch.pl run on
rtw_led.*:

* FSF_MAILING_ADDRESS

Free Software Foundation's mailing address should not be included in
the sample GPL notice.

* LINE_SPACING

Missing a blank line after declarations.

* leading spaces

* a typo

* any too long lines changed with this patch

All of the problems above are fixed with this patch.

Signed-off-by: Krzysztof Konopko <[email protected]>
---
drivers/staging/rtl8188eu/core/rtw_led.c | 15 +++++++--------
drivers/staging/rtl8188eu/include/rtw_led.h | 6 +-----
2 files changed, 8 insertions(+), 13 deletions(-)

diff --git a/drivers/staging/rtl8188eu/core/rtw_led.c b/drivers/staging/rtl8188eu/core/rtw_led.c
index 2aa6251..5d7e8ec 100644
--- a/drivers/staging/rtl8188eu/core/rtw_led.c
+++ b/drivers/staging/rtl8188eu/core/rtw_led.c
@@ -11,10 +11,6 @@
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
- *
*
******************************************************************************/

@@ -44,6 +40,7 @@ void BlinkTimerCallback(void *data)
void BlinkWorkItemCallback(struct work_struct *work)
{
struct LED_871x *pLed = container_of(work, struct LED_871x, BlinkWorkItem);
+
BlinkHandler(pLed);
}

@@ -228,7 +225,8 @@ static void SwLedBlink1(struct LED_871x *pLed)
pLed->bLedWPSBlinkInProgress = false;
} else {
pLed->BlinkingLedState = RTW_LED_OFF;
- _set_timer(&(pLed->BlinkTimer), LED_BLINK_WPS_SUCESS_INTERVAL_ALPHA);
+ _set_timer(&(pLed->BlinkTimer),
+ LED_BLINK_WPS_SUCCESS_INTERVAL_ALPHA);
}
break;
default:
@@ -392,7 +390,8 @@ static void SwLedControlMode1(struct adapter *padapter, enum LED_CTL_MODE LedAct
pLed->CurrLedState = LED_BLINK_WPS_STOP;
if (pLed->bLedOn) {
pLed->BlinkingLedState = RTW_LED_OFF;
- _set_timer(&(pLed->BlinkTimer), LED_BLINK_WPS_SUCESS_INTERVAL_ALPHA);
+ _set_timer(&(pLed->BlinkTimer),
+ LED_BLINK_WPS_SUCCESS_INTERVAL_ALPHA);
} else {
pLed->BlinkingLedState = RTW_LED_ON;
_set_timer(&(pLed->BlinkTimer), 0);
@@ -461,8 +460,8 @@ void LedControl8188eu(struct adapter *padapter, enum LED_CTL_MODE LedAction)
{
struct led_priv *ledpriv = &(padapter->ledpriv);

- if ((padapter->bSurpriseRemoved) || (padapter->bDriverStopped) ||
- (!padapter->hw_init_completed))
+ if ((padapter->bSurpriseRemoved) || (padapter->bDriverStopped) ||
+ (!padapter->hw_init_completed))
return;

if (!ledpriv->bRegUseLed)
diff --git a/drivers/staging/rtl8188eu/include/rtw_led.h b/drivers/staging/rtl8188eu/include/rtw_led.h
index dec8dbc..23f0cfe 100644
--- a/drivers/staging/rtl8188eu/include/rtw_led.h
+++ b/drivers/staging/rtl8188eu/include/rtw_led.h
@@ -11,10 +11,6 @@
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
- * You should have received a copy of the GNU General Public License along with
- * this program; if not, write to the Free Software Foundation, Inc.,
- * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
- *
*
******************************************************************************/
#ifndef __RTW_LED_H_
@@ -27,7 +23,7 @@
#define LED_BLINK_LINK_INTERVAL_ALPHA 500 /* 500 */
#define LED_BLINK_SCAN_INTERVAL_ALPHA 180 /* 150 */
#define LED_BLINK_FASTER_INTERVAL_ALPHA 50
-#define LED_BLINK_WPS_SUCESS_INTERVAL_ALPHA 5000
+#define LED_BLINK_WPS_SUCCESS_INTERVAL_ALPHA 5000

enum LED_CTL_MODE {
LED_CTL_POWER_ON,
--
2.1.1


2014-11-06 23:04:03

by Greg Kroah-Hartman

[permalink] [raw]
Subject: Re: [PATCH] rtl8188eu: Fix several stylistic problems in rtw_led.*

On Thu, Nov 06, 2014 at 11:56:05PM +0100, [email protected] wrote:
> From: Krzysztof Konopko <[email protected]>
>
> Several stylistics problems are reported by scripts/checkpatch.pl run on
> rtw_led.*:
>
> * FSF_MAILING_ADDRESS
>
> Free Software Foundation's mailing address should not be included in
> the sample GPL notice.
>
> * LINE_SPACING
>
> Missing a blank line after declarations.
>
> * leading spaces
>
> * a typo
>
> * any too long lines changed with this patch
>
> All of the problems above are fixed with this patch.

Each patch should only do 1 thing, so please break this up into multiple
patches, each only doing 1 thing, in a patch series, and resend so it
can be applied.

thanks,

greg k-h