summaryrefslogtreecommitdiffstats
path: root/drivers/staging/bcm
diff options
context:
space:
mode:
authorMatthias Beyer <mail@beyermatthias.de>2014-07-29 16:52:26 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-07-30 17:14:23 -0700
commita21a3fe440f6d61cd341584b50d621b56ca59d52 (patch)
treee019fcee862021319f7625eb41eec7a6a25f6707 /drivers/staging/bcm
parent5fb136700da05f5257a5a7a2941a95b060ca3823 (diff)
downloadtalos-op-linux-a21a3fe440f6d61cd341584b50d621b56ca59d52.tar.gz
talos-op-linux-a21a3fe440f6d61cd341584b50d621b56ca59d52.zip
Staging: bcm: Qos.c: Line length / Whitespace cleanup in IpVersion4()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/bcm')
-rw-r--r--drivers/staging/bcm/Qos.c96
1 files changed, 75 insertions, 21 deletions
diff --git a/drivers/staging/bcm/Qos.c b/drivers/staging/bcm/Qos.c
index 589bd4256b58..747790d84c63 100644
--- a/drivers/staging/bcm/Qos.c
+++ b/drivers/staging/bcm/Qos.c
@@ -280,41 +280,78 @@ static USHORT IpVersion4(struct bcm_mini_adapter *Adapter,
struct bcm_transport_header *xprt_hdr = NULL;
bool bClassificationSucceed = false;
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "========>");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "========>");
xprt_hdr = (struct bcm_transport_header *)((PUCHAR)iphd + sizeof(struct iphdr));
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Trying to see Direction = %d %d",
- pstClassifierRule->ucDirection,
- pstClassifierRule->usVCID_Value);
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Trying to see Direction = %d %d",
+ pstClassifierRule->ucDirection,
+ pstClassifierRule->usVCID_Value);
/* Checking classifier validity */
- if (!pstClassifierRule->bUsed || pstClassifierRule->ucDirection == DOWNLINK_DIR)
+ if (!pstClassifierRule->bUsed ||
+ pstClassifierRule->ucDirection == DOWNLINK_DIR)
goto out;
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "is IPv6 check!");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "is IPv6 check!");
if (pstClassifierRule->bIpv6Protocol)
goto out;
/* Checking IP header parameter */
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Trying to match Source IP Address");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Trying to match Source IP Address");
if (!MatchSrcIpAddress(pstClassifierRule, iphd->saddr))
goto out;
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Source IP Address Matched");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Source IP Address Matched");
if (!MatchDestIpAddress(pstClassifierRule, iphd->daddr))
goto out;
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Destination IP Address Matched");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Destination IP Address Matched");
if (!MatchTos(pstClassifierRule, iphd->tos)) {
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "TOS Match failed\n");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "TOS Match failed\n");
goto out;
}
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "TOS Matched");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "TOS Matched");
if (!MatchProtocol(pstClassifierRule, iphd->protocol))
goto out;
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Protocol Matched");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Protocol Matched");
/*
* if protocol is not TCP or UDP then no
@@ -325,18 +362,31 @@ static USHORT IpVersion4(struct bcm_mini_adapter *Adapter,
goto out;
}
/* Checking Transport Layer Header field if present */
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Source Port %04x",
- (iphd->protocol == UDP) ? xprt_hdr->uhdr.source : xprt_hdr->thdr.source);
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Source Port %04x",
+ (iphd->protocol == UDP) ? xprt_hdr->uhdr.source : xprt_hdr->thdr.source);
if (!MatchSrcPort(pstClassifierRule,
ntohs((iphd->protocol == UDP) ?
xprt_hdr->uhdr.source : xprt_hdr->thdr.source)))
goto out;
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Src Port Matched");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Src Port Matched");
+
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "Destination Port %04x",
+ (iphd->protocol == UDP) ? xprt_hdr->uhdr.dest :
+ xprt_hdr->thdr.dest);
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "Destination Port %04x",
- (iphd->protocol == UDP) ? xprt_hdr->uhdr.dest :
- xprt_hdr->thdr.dest);
if (!MatchDestPort(pstClassifierRule,
ntohs((iphd->protocol == UDP) ?
xprt_hdr->uhdr.dest : xprt_hdr->thdr.dest)))
@@ -346,15 +396,19 @@ static USHORT IpVersion4(struct bcm_mini_adapter *Adapter,
out:
if (TRUE == bClassificationSucceed) {
INT iMatchedSFQueueIndex = 0;
-
- iMatchedSFQueueIndex = SearchSfid(Adapter, pstClassifierRule->ulSFID);
+ iMatchedSFQueueIndex =
+ SearchSfid(Adapter, pstClassifierRule->ulSFID);
if (iMatchedSFQueueIndex >= NO_OF_QUEUES)
bClassificationSucceed = false;
else if (false == Adapter->PackInfo[iMatchedSFQueueIndex].bActive)
bClassificationSucceed = false;
}
- BCM_DEBUG_PRINT(Adapter, DBG_TYPE_TX, IPV4_DBG, DBG_LVL_ALL, "IpVersion4 <==========");
+ BCM_DEBUG_PRINT(Adapter,
+ DBG_TYPE_TX,
+ IPV4_DBG,
+ DBG_LVL_ALL,
+ "IpVersion4 <==========");
return bClassificationSucceed;
}
OpenPOWER on IntegriCloud