mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: navin patidar <navin.patidar@gmail.com>
To: gregkh@linuxfoundation.org
Cc: Larry.Finger@lwfinger.net, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org,
	navin patidar <navin.patidar@gmail.com>
Subject: [PATCH 40/41] staging: rtl8188eu: rtw_efuse.c: Remove unnecessary comments
Date: Fri, 20 Jun 2014 20:29:46 +0530	[thread overview]
Message-ID: <1403276387-11841-41-git-send-email-navin.patidar@gmail.com> (raw)
In-Reply-To: <1403276387-11841-1-git-send-email-navin.patidar@gmail.com>


Signed-off-by: navin patidar <navin.patidar@gmail.com>
---
 drivers/staging/rtl8188eu/core/rtw_efuse.c |  125 ++++++----------------------
 1 file changed, 24 insertions(+), 101 deletions(-)

diff --git a/drivers/staging/rtl8188eu/core/rtw_efuse.c b/drivers/staging/rtl8188eu/core/rtw_efuse.c
index 26d1d51..7eb8946 100644
--- a/drivers/staging/rtl8188eu/core/rtw_efuse.c
+++ b/drivers/staging/rtl8188eu/core/rtw_efuse.c
@@ -24,14 +24,10 @@
 #include <rtw_efuse.h>
 #include <usb_ops_linux.h>
 
-/*  */
 #define REG_EFUSE_CTRL		0x0030
 #define EFUSE_CTRL			REG_EFUSE_CTRL		/*  E-Fuse Control. */
-/*  */
 
-/*  11/16/2008 MH Add description. Get current efuse area enabled word!!. */
-u8
-Efuse_CalculateWordCnts(u8 word_en)
+u8 Efuse_CalculateWordCnts(u8 word_en)
 {
 	u8 word_cnts = 0;
 	if (!(word_en & BIT(0)))
@@ -50,8 +46,6 @@ u8 efuse_OneByteRead(struct adapter *pAdapter, u16 addr, u8 *data)
 	u8 tmpidx = 0;
 	u8 result;
 
-	/*  -----------------e-fuse reg ctrl --------------------------------- */
-	/* address */
 	usb_write8(pAdapter, EFUSE_CTRL+1, (u8)(addr & 0xff));
 	usb_write8(pAdapter, EFUSE_CTRL+2, ((u8)((addr>>8) & 0x03)) |
 		   (usb_read8(pAdapter, EFUSE_CTRL+2) & 0xFC));
@@ -70,14 +64,11 @@ u8 efuse_OneByteRead(struct adapter *pAdapter, u16 addr, u8 *data)
 	return result;
 }
 
-/*  11/16/2008 MH Write one byte to reald Efuse. */
 u8 efuse_OneByteWrite(struct adapter *pAdapter, u16 addr, u8 data)
 {
 	u8 tmpidx = 0;
 	u8 result;
 
-	/*  -----------------e-fuse reg ctrl --------------------------------- */
-	/* address */
 	usb_write8(pAdapter, EFUSE_CTRL+1, (u8)(addr&0xff));
 	usb_write8(pAdapter, EFUSE_CTRL+2,
 		   (usb_read8(pAdapter, EFUSE_CTRL+2) & 0xFC) |
@@ -97,23 +88,9 @@ u8 efuse_OneByteWrite(struct adapter *pAdapter, u16 addr, u8 data)
 	return result;
 }
 
-/*-----------------------------------------------------------------------------
- * Function:	efuse_WordEnableDataRead
- *
- * Overview:	Read allowed word in current efuse section data.
- *
- * Input:       NONE
- *
- * Output:      NONE
- *
- * Return:      NONE
- *
- * Revised History:
- * When			Who		Remark
- * 11/16/2008	MHC		Create Version 0.
- * 11/21/2008	MHC		Fix Write bug when we only enable late word.
- *
- *---------------------------------------------------------------------------*/
+/*
+ * Overview:   Read allowed word in current efuse section data.
+ */
 void efuse_WordEnableDataRead(u8 word_en, u8 *sourdata, u8 *targetdata)
 {
 	if (!(word_en&BIT(0))) {
@@ -186,14 +163,14 @@ u8 rtw_efuse_access(struct adapter *padapter, u8 write, u16 start_addr, u16 cnts
 
 	return res;
 }
-/*  */
+
 u16 efuse_GetMaxSize(struct adapter *padapter)
 {
 	u16 max_size;
 	EFUSE_GetEfuseDefinition(padapter, EFUSE_WIFI , TYPE_AVAILABLE_EFUSE_BYTES_TOTAL, (void *)&max_size);
 	return max_size;
 }
-/*  */
+
 u8 efuse_GetCurrentSize(struct adapter *padapter, u16 *size)
 {
 	Efuse_PowerSwitch(padapter, false, true);
@@ -202,7 +179,7 @@ u8 efuse_GetCurrentSize(struct adapter *padapter, u16 *size)
 
 	return _SUCCESS;
 }
-/*  */
+
 u8 rtw_efuse_map_read(struct adapter *padapter, u16 addr, u16 cnts, u8 *data)
 {
 	u16 mapLen = 0;
@@ -221,7 +198,6 @@ u8 rtw_efuse_map_read(struct adapter *padapter, u16 addr, u16 cnts, u8 *data)
 	return _SUCCESS;
 }
 
-/*  */
 u8 rtw_efuse_map_write(struct adapter *padapter, u16 addr, u16 cnts, u8 *data)
 {
 	u8 offset, word_en;
@@ -313,24 +289,13 @@ exit:
 	return ret;
 }
 
-/*-----------------------------------------------------------------------------
- * Function:	efuse_ShadowRead1Byte
- *			efuse_ShadowRead2Byte
- *			efuse_ShadowRead4Byte
- *
- * Overview:	Read from efuse init map by one/two/four bytes !!!!!
- *
- * Input:       NONE
- *
- * Output:      NONE
- *
- * Return:      NONE
- *
- * Revised History:
- * When			Who		Remark
- * 11/12/2008	MHC		Create Version 0.
+/*
+ * Function:   efuse_ShadowRead1Byte
+ *             efuse_ShadowRead2Byte
+ *             efuse_ShadowRead4Byte
  *
- *---------------------------------------------------------------------------*/
+ * Overview:   Read from efuse init map by one/two/four bytes !!!!!
+ */
 static void
 efuse_ShadowRead1Byte(
 		struct adapter *pAdapter,
@@ -341,9 +306,8 @@ efuse_ShadowRead1Byte(
 
 	*Value = pEEPROM->efuse_eeprom_data[Offset];
 
-}	/*  EFUSE_ShadowRead1Byte */
+}
 
-/* Read Two Bytes */
 static void
 efuse_ShadowRead2Byte(
 		struct adapter *pAdapter,
@@ -355,9 +319,8 @@ efuse_ShadowRead2Byte(
 	*Value = pEEPROM->efuse_eeprom_data[Offset];
 	*Value |= pEEPROM->efuse_eeprom_data[Offset+1]<<8;
 
-}	/*  EFUSE_ShadowRead2Byte */
+}
 
-/* Read Four Bytes */
 static void
 efuse_ShadowRead4Byte(
 		struct adapter *pAdapter,
@@ -371,24 +334,11 @@ efuse_ShadowRead4Byte(
 	*Value |= pEEPROM->efuse_eeprom_data[Offset+2]<<16;
 	*Value |= pEEPROM->efuse_eeprom_data[Offset+3]<<24;
 
-}	/*  efuse_ShadowRead4Byte */
+}
 
-/*-----------------------------------------------------------------------------
- * Function:	Efuse_ReadAllMap
- *
+/*
  * Overview:	Read All Efuse content
- *
- * Input:       NONE
- *
- * Output:      NONE
- *
- * Return:      NONE
- *
- * Revised History:
- * When			Who		Remark
- * 11/11/2008	MHC		Create Version 0.
- *
- *---------------------------------------------------------------------------*/
+ */
 static void Efuse_ReadAllMap(struct adapter *pAdapter, u8 efuseType, u8 *Efuse)
 {
 	u16 mapLen = 0;
@@ -402,22 +352,9 @@ static void Efuse_ReadAllMap(struct adapter *pAdapter, u8 efuseType, u8 *Efuse)
 	Efuse_PowerSwitch(pAdapter, false, false);
 }
 
-/*-----------------------------------------------------------------------------
- * Function:	EFUSE_ShadowMapUpdate
- *
+/*
  * Overview:	Transfer current EFUSE content to shadow init and modify map.
- *
- * Input:       NONE
- *
- * Output:      NONE
- *
- * Return:      NONE
- *
- * Revised History:
- * When			Who		Remark
- * 11/13/2008	MHC		Create Version 0.
- *
- *---------------------------------------------------------------------------*/
+ */
 void EFUSE_ShadowMapUpdate(
 	struct adapter *pAdapter,
 	u8 efuseType)
@@ -431,24 +368,11 @@ void EFUSE_ShadowMapUpdate(
 		_rtw_memset(pEEPROM->efuse_eeprom_data, 0xFF, mapLen);
 	else
 		Efuse_ReadAllMap(pAdapter, efuseType, pEEPROM->efuse_eeprom_data);
-} /*  EFUSE_ShadowMapUpdate */
+}
 
-/*-----------------------------------------------------------------------------
- * Function:	EFUSE_ShadowRead
- *
+/*
  * Overview:	Read from efuse init map !!!!!
- *
- * Input:       NONE
- *
- * Output:      NONE
- *
- * Return:      NONE
- *
- * Revised History:
- * When			Who		Remark
- * 11/12/2008	MHC		Create Version 0.
- *
- *---------------------------------------------------------------------------*/
+ */
 void EFUSE_ShadowRead(struct adapter *pAdapter, u8 Type, u16 Offset, u32 *Value)
 {
 	if (Type == 1)
@@ -457,5 +381,4 @@ void EFUSE_ShadowRead(struct adapter *pAdapter, u8 Type, u16 Offset, u32 *Value)
 		efuse_ShadowRead2Byte(pAdapter, Offset, (u16 *)Value);
 	else if (Type == 4)
 		efuse_ShadowRead4Byte(pAdapter, Offset, (u32 *)Value);
-
-}	/*  EFUSE_ShadowRead */
+}
-- 
1.7.10.4


  parent reply	other threads:[~2014-06-20 15:05 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-06-20 14:59 [PATCH 00/41] Cleanup and consolidate efuse related code navin patidar
2014-06-20 14:59 ` [PATCH 01/41] staging: rtl8188eu: Rename hal_EfusePowerSwitch_RTL8188E() navin patidar
2014-06-20 14:59 ` [PATCH 02/41] staging: rtl8188eu: Remove rtl8188e_ReadEFuse() navin patidar
2014-06-20 14:59 ` [PATCH 03/41] staging: rtl8188eu: Remove unused function ReadEFuse_Pseudo() navin patidar
2014-06-20 14:59 ` [PATCH 04/41] staging: rtl8188eu: Remove rtl8188e_EfuseGetCurrentSize() navin patidar
2014-06-20 14:59 ` [PATCH 05/41] staging: rtl8188eu: Remove unused function Hal_EfuseGetCurrentSize_Pseudo() navin patidar
2014-06-20 14:59 ` [PATCH 06/41] staging: rtl8188eu: Remove function Hal_EFUSEGetEfuseDefinition_Pseudo88E() navin patidar
2014-06-20 14:59 ` [PATCH 07/41] staging: rtl8188eu: Rename Hal_EFUSEGetEfuseDefinition88E() navin patidar
2014-06-20 14:59 ` [PATCH 08/41] staging: rtl8188eu: assign hal_EfusePgPacketRead_8188e() to ->Efuse_PgPacketRead navin patidar
2014-06-20 14:59 ` [PATCH 09/41] staging:rtl8188eu:assign hal_EfusePgPacketWrite_8188e() to ->Efuse_PgPacketWrite navin patidar
2014-06-20 14:59 ` [PATCH 10/41] staging:rtl8188eu: Assign rtl8188e_Efuse_WordEnableDataWrite() to ->Efuse_WordEnableDataWrite navin patidar
2014-06-20 14:59 ` [PATCH 11/41] staging: rtl8188eu: rtw_efuse.c: Remove unnecessary function declaration navin patidar
2014-06-20 14:59 ` [PATCH 12/41] staging: rtl8188eu: Rename rtl8188e_EFUSE_GetEfuseDefinition() navin patidar
2014-06-20 14:59 ` [PATCH 13/41] staging: rtl8188eu: Rename hal_EfuseGetCurrentSize_8188e() navin patidar
2014-06-20 14:59 ` [PATCH 14/41] staging: rtl8188eu: Rename rtl8188e_EfusePowerSwitch() to Efuse_PowerSwitch() navin patidar
2014-06-20 14:59 ` [PATCH 15/41] staging: rtl8188eu: Rename function Hal_EfuseWordEnableDataWrite() navin patidar
2014-06-20 14:59 ` [PATCH 16/41] staging: rtl8188eu: Remove function Hal_EfuseReadEFuse88E() navin patidar
2014-06-20 14:59 ` [PATCH 17/41] staging: rtl8188eu: Rename function ReadEFuseByIC() to efuse_ReadEFuse() navin patidar
2014-06-20 14:59 ` [PATCH 18/41] staging: rtl8188eu: Rename hal_EfusePgPacketRead_8188e() to Efuse_PgPacketRead() navin patidar
2014-06-20 14:59 ` [PATCH 19/41] staging: rtl8188eu: Rename hal_EfusePgPacketWrite_8188e() navin patidar
2014-06-20 14:59 ` [PATCH 20/41] staging: rtl8188eu: Remove function Efuse_Write1ByteToFakeContent() navin patidar
2014-06-20 14:59 ` [PATCH 21/41] staging: rtl8188eu: Remove function Efuse_Read1ByteFromFakeContent() navin patidar
2014-06-20 14:59 ` [PATCH 22/41] staging: rtl8188eu: Remove function rtw_BT_efuse_map_write() navin patidar
2014-06-20 14:59 ` [PATCH 23/41] staging: rtl8188eu: Remove unused function Efuse_PgPacketWrite_BT() navin patidar
2014-06-20 14:59 ` [PATCH 24/41] staging: rtl8188eu: Remove function rtw_BT_efuse_map_read() navin patidar
2014-06-20 14:59 ` [PATCH 25/41] staging: rtl8188eu: Remove unused function ReadEFuseByte() navin patidar
2014-06-20 14:59 ` [PATCH 26/41] staging: rtl8188eu: Remove unused function EFUSE_Read1Byte() navin patidar
2014-06-20 14:59 ` [PATCH 27/41] staging: rtl8188eu: efuse_OneByteRead():Remove unused parameter bool test navin patidar
2014-06-20 14:59 ` [PATCH 28/41] staging: rtl8188eu: efuse_OneByteWrite(): Remove " navin patidar
2014-06-20 14:59 ` [PATCH 29/41] staging: rtl8188eu: efuse_ReadEFuse(): Remove parameter bool bPseudoTest navin patidar
2014-06-20 14:59 ` [PATCH 30/41] staging: rtl8188eu: Efuse_GetCurrentSize(): Remove parameter bool test navin patidar
2014-06-20 14:59 ` [PATCH 31/41] staging: rtl8188eu: Efuse_ReadAllMap(): Remove unused " navin patidar
2014-06-20 14:59 ` [PATCH 32/41] staging: rtl8188eu: EFUSE_ShadowMapUpdate():Remove " navin patidar
2014-06-20 14:59 ` [PATCH 33/41] staging: rtl8188eu: Efuse_WordEnableDataWrite(): Remove unused parameter test navin patidar
2014-06-20 14:59 ` [PATCH 34/41] staging: rtl8188eu: hal_EfuseCheckIfDatafollowed(): Remove unused parameter navin patidar
2014-06-20 14:59 ` [PATCH 35/41] staging: rtl8188eu: Remove bool bPseudoTest parameter from efuse functions navin patidar
2014-06-20 14:59 ` [PATCH 36/41] staging: rtl8188eu: rtl8188e_hal_init.c: Remove forward declarations navin patidar
2014-06-20 14:59 ` [PATCH 37/41] staging: rtl8188eu: hal_EfusePartialWriteCheck(): Remove bluetooth specific code navin patidar
2014-06-20 14:59 ` [PATCH 38/41] staging: rtl8188eu: rtw_efuse.c: Remove unused global variables navin patidar
2014-06-20 14:59 ` [PATCH 39/41] staging: rtl8188eu: rtw_efuse.c: Remove unused local variables navin patidar
2014-06-20 14:59 ` navin patidar [this message]
2014-06-20 14:59 ` [PATCH 41/41] staging: rtl8188eu: Move all efuse related code to rtw_efuse.c navin patidar

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1403276387-11841-41-git-send-email-navin.patidar@gmail.com \
    --to=navin.patidar@gmail.com \
    --cc=Larry.Finger@lwfinger.net \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®