lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190620094534.5658-2-muellerch-privat@web.de>
Date:   Thu, 20 Jun 2019 11:45:34 +0200
From:   Christian Müller <muellerch-privat@....de>
To:     gregkh@...uxfoundation.org
Cc:     johnfwhitmore@...il.com, devel@...verdev.osuosl.org,
        linux-kernel@...r.kernel.org, linux-kernel@...cs.fau.de,
        felix.trommer@...mail.de,
        Christian Müller <muellerch-privat@....de>
Subject: [PATCH 1/1] drivers/staging/rtl8129u: adjust block comments

As stated in coding-styles.rst multiline comments should be structured in a way,
that the actual comment starts on the second line of the commented portion. E.g:

/*
 * Multiline comments
 * should look like
 * this.
 */

The comments in this file were of a format, that looked like this:

/* Multiline comments previous
 * to this patch
 * looked like this.
 */

There is an exception to files in /net and drivers/net,
where multiline comments are preferred to look like the second example above,
but since this file resides in a different directory,
this patch changes the style to match the preferred style.

Signed-off-by: Christian Müller <muellerch-privat@....de>
Signed-off-by: Felix Trommer <felix.trommer@...mail.de>
---
 drivers/staging/rtl8192u/r819xU_phy.c | 39 ++++++++++++++++++---------
 1 file changed, 26 insertions(+), 13 deletions(-)

diff --git a/drivers/staging/rtl8192u/r819xU_phy.c b/drivers/staging/rtl8192u/r819xU_phy.c
index 5f04afe53d69..a51ed10be431 100644
--- a/drivers/staging/rtl8192u/r819xU_phy.c
+++ b/drivers/staging/rtl8192u/r819xU_phy.c
@@ -363,7 +363,8 @@ static u32 phy_FwRFSerialRead(struct net_device *dev,
 	u8		time = 0;
 	u32		tmp;

-	/* Firmware RF Write control.
+	/*
+	 * Firmware RF Write control.
 	 * We can not execute the scheme in the initial step.
 	 * Otherwise, RF-R/W will waste much time.
 	 * This is only for site survey.
@@ -379,7 +380,8 @@ static u32 phy_FwRFSerialRead(struct net_device *dev,
 	/* 6. We can not execute read operation if bit 31 is 1. */
 	read_nic_dword(dev, QPNR, &tmp);
 	while (tmp & 0x80000000) {
-		/* If FW can not finish RF-R/W for more than ?? times.
+		/*
+		 * If FW can not finish RF-R/W for more than ?? times.
 		 * We must reset FW.
 		 */
 		if (time++ < 100) {
@@ -394,7 +396,8 @@ static u32 phy_FwRFSerialRead(struct net_device *dev,
 	/* 8. Check if firmware send back RF content. */
 	read_nic_dword(dev, QPNR, &tmp);
 	while (tmp & 0x80000000) {
-		/* If FW can not finish RF-R/W for more than ?? times.
+		/*
+		 * If FW can not finish RF-R/W for more than ?? times.
 		 * We must reset FW.
 		 */
 		if (time++ < 100) {
@@ -426,7 +429,8 @@ static void phy_FwRFSerialWrite(struct net_device *dev,
 	u8	time = 0;
 	u32	tmp;

-	/* Firmware RF Write control.
+	/*
+	 * Firmware RF Write control.
 	 * We can not execute the scheme in the initial step.
 	 * Otherwise, RF-R/W will waste much time.
 	 * This is only for site survey.
@@ -445,7 +449,8 @@ static void phy_FwRFSerialWrite(struct net_device *dev,
 	/* 6. Write operation. We can not write if bit 31 is 1. */
 	read_nic_dword(dev, QPNR, &tmp);
 	while (tmp & 0x80000000) {
-		/* If FW can not finish RF-R/W for more than ?? times.
+		/*
+		 * If FW can not finish RF-R/W for more than ?? times.
 		 * We must reset FW.
 		 */
 		if (time++ < 100) {
@@ -455,11 +460,13 @@ static void phy_FwRFSerialWrite(struct net_device *dev,
 			break;
 		}
 	}
-	/* 7. No matter check bit. We always force the write.
+	/*
+	 * 7. No matter check bit. We always force the write.
 	 * Because FW will not accept the command.
 	 */
 	write_nic_dword(dev, QPNR, data);
-	/* According to test, we must delay 20us to wait firmware
+	/*
+	 * According to test, we must delay 20us to wait firmware
 	 * to finish RF write operation.
 	 */
 	/* We support delay in firmware side now. */
@@ -828,7 +835,8 @@ static void rtl8192_BB_Config_ParaFile(struct net_device *dev)
 				 reg_u32);
 	}

-	/* Check if the CCK HighPower is turned ON.
+	/*
+	 * Check if the CCK HighPower is turned ON.
 	 * This is used to calculate PWDB.
 	 */
 	priv->bCckHighPower = (u8)rtl8192_QueryBBReg(dev,
@@ -847,7 +855,8 @@ static void rtl8192_BB_Config_ParaFile(struct net_device *dev)
 void rtl8192_BBConfig(struct net_device *dev)
 {
 	rtl8192_InitBBRFRegDef(dev);
-	/* config BB&RF. As hardCode based initialization has not been well
+	/*
+	 * config BB&RF. As hardCode based initialization has not been well
 	 * implemented, so use file first.
 	 * FIXME: should implement it for hardcode?
 	 */
@@ -1168,7 +1177,8 @@ bool rtl8192_SetRFPowerState(struct net_device *dev,
 		case RF_8256:
 			switch (pHalData->eRFPowerState) {
 			case eRfOff:
-				/* If Rf off reason is from IPS,
+				/*
+				 * If Rf off reason is from IPS,
 				 * LED should blink with no link
 				 */
 				if (pMgntInfo->RfOffReason == RF_CHANGE_BY_IPS)
@@ -1179,7 +1189,8 @@ bool rtl8192_SetRFPowerState(struct net_device *dev,
 				break;

 			case eRfOn:
-				/* Turn on RF we are still linked, which might
+				/*
+				 * Turn on RF we are still linked, which might
 				 * happen when we quickly turn off and on HW RF.
 				 */
 				if (pMgntInfo->bMediaConnect)
@@ -1274,7 +1285,8 @@ static u8 rtl8192_phy_SwChnlStepByStep(struct net_device *dev, u8 channel,
 		 __func__, *stage, *step, channel);
 	if (!is_legal_channel(priv->ieee80211, channel)) {
 		RT_TRACE(COMP_ERR, "set to illegal channel: %d\n", channel);
-		/* return true to tell upper caller function this channel
+		/*
+		 * return true to tell upper caller function this channel
 		 * setting is finished! Or it will in while loop.
 		 */
 		return true;
@@ -1621,7 +1633,8 @@ void rtl8192_SetBWModeWorkItem(struct net_device *dev)
 		break;

 	}
-	/* Skip over setting of J-mode in BB register here.
+	/*
+	 * Skip over setting of J-mode in BB register here.
 	 * Default value is "None J mode".
 	 */

--
2.17.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ