Commit Graph

631 Commits

Author SHA1 Message Date
Peter Senna Tschudin
4764ca981b drivers/staging: Remove useless return variables
This patch remove variables that are initialized with a constant,
are never updated, and are only used as parameter of return.
Return the constant instead of using a variable.

Verified by compilation only.

The coccinelle script that find and fixes this issue is:
// <smpl>
@@
type T;
constant C;
identifier ret;
@@
- T ret = C;
... when != ret
    when strict
return
- ret
+ C
;
// </smpl>

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-26 10:32:15 -07:00
Joe Perches
f8628a47ba staging: Convert __FUNCTION__ to __func__
Use the normal mechanism for emitting a function name.

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-25 11:05:07 -07:00
Matthias Beyer
1808bc67b1 Staging: bcm: Shortened prototype for GetNextTargetBufferLocation()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:39 +09:00
Matthias Beyer
3fdf44ca2a Staging: bcm: Shortened lines in SearchClsid()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:39 +09:00
Matthias Beyer
3563e4ee9c Staging: bcm: Shortened lines in deleteSFBySfid()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:39 +09:00
Matthias Beyer
e61f63557b Staging: bcm: Shortened lines in CopyIpAddrToClassifier()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:38 +09:00
Matthias Beyer
780eb92c85 Staging: bcm: Replaced member accessing by variable
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:38 +09:00
Matthias Beyer
d52fe04a64 Staging: bcm: Shortened lines and replaced member accessing in CopyIpAddrToClassifier()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:38 +09:00
Matthias Beyer
eb8d0c9195 Staging: bcm: Shortened lines in CopyClassifierRuleToSF()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:38 +09:00
Matthias Beyer
732f1eee33 Staging: bcm: Replaced member accessing with variable
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:38 +09:00
Matthias Beyer
e8a9447780 Staging: bcm: Shortened lines in DeleteClassifierRuleFromSF()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:38 +09:00
Matthias Beyer
a03420b622 Staging: bcm: Shortened line in DeleteAllClassifiersForSF()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:37 +09:00
Matthias Beyer
ad9af0801d Staging: bcm: Shortened lines in CopyToAdapter()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:37 +09:00
Matthias Beyer
7d4e910462 Staging: bcm: Replaced struct member accessing with variable
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:37 +09:00
Matthias Beyer
efd2ee6d5a Staging: bcm: Outsourced PHS rule applying
This patch outsources the big PHS-rule-applying code chunk into a
function.

It also replaces member accessing by using variables.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:37 +09:00
Matthias Beyer
5c2c68d01b Staging: bcm: Shortened some lines in DumpCmControlPacker()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:37 +09:00
Matthias Beyer
500501fad6 Staging: bcm: Replaced long member-accessing
This patch replaces long object->member.member foo by variable useage.
Increases the reading experience a lot by introducing only one variable
(as it decreases the whoa-wall-of-text experience).

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:37 +09:00
Matthias Beyer
ba3d0ee976 Staging: bcm: Shortened lines in RestoreSFParam()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:36 +09:00
Matthias Beyer
b9e9c27410 Staging: bcm: Shortened lines in StoreSFParam()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:36 +09:00
Matthias Beyer
c61f404478 Staging: bcm: Shortened lines in StoreCmControlResponseMessage()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:36 +09:00
Matthias Beyer
f61d1d554d Staging: bcm: Shortened lines in RestoreCmControlResponseMessage()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:36 +09:00
Matthias Beyer
ae6586f5de Staging: bcm: Shortened lines in SetupTargetDsxBuffers()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:36 +09:00
Matthias Beyer
0e5129185a Staging: bcm: Shortenend lines in GetNextTargetBufferLocation()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:35 +09:00
Matthias Beyer
2ad5c499b9 Staging: bcm: Shortened line
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:35 +09:00
Matthias Beyer
cdc299b7a5 Staging: bcm: Simplified by using variables
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:35 +09:00
Matthias Beyer
311cb0786a Staging: bcm: Outsourced restoring of endianess for ip adresses
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:35 +09:00
Matthias Beyer
15bba866c7 Staging: bcm: Shortened lines in get_dsx_sf_data_to_application()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:35 +09:00
Matthias Beyer
c4fe6fa71d Staging: bcm: Shortened lines in OverrideServiceFlowParams()
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:35 +09:00
Matthias Beyer
c4396e7479 Staging: bcm: Shortened code by using variable
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-24 07:26:34 +09:00
Greg DeAngelis
4c165843ea staging: bcm: fix lines over 80 characters
Signed-off-by: Greg DeAngelis <gdeangel@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23 20:54:23 +09:00
Matthias Beyer
2c11ca29a0 Staging: bcm: Indentation fixes in Bcmchar.c
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23 20:53:40 +09:00
Matthias Beyer
e5c34a1aad Staging: bcm: Outsourced IsFlash2x() handling
This patch outsources the code from the IsFlash2x() check in
bcm_char_ioctl_nvm_rw() function to shorten it.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23 20:53:40 +09:00
Matthias Beyer
8224ac2a78 Staging: bcm: Outsourced cmd handling to function
This patch outsourced the true-branch for the IOCTL_BCM_NVM_READ command
handling to shorten the bcm_char_ioctl_nvm_rw() function.

Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23 20:53:40 +09:00
Matthias Beyer
22840adaf7 Staging: bcm: Fixed line lengths
Signed-off-by: Matthias Beyer <mail@beyermatthias.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23 20:53:40 +09:00
Daeseok Youn
87755c0b3a staging: bcm: use kzalloc instead of kmalloc/memset
Signed-off-by: Daeseok Youn <daeseok.youn@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-05-23 20:52:21 +09:00
Marcos A. Di Pietro
e347fa5f42 Staging:bcm: Fixes coding style issues in drivers/staging/bcm/Qos.c
Fixes code style errors in drivers/staging/bcm/Qos.c

Signed-off-by: Marcos A. Di Pietro <marcosadp@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-18 16:23:55 -07:00
Julian Gindi
22bfe7e89c bcm: Fixing a few checkpatch issues in InterfaceMisc.h
Just cleaned up a few issues presented by checkpatch in InterfaceMisc.h.
I converted some spaces to tabs, and removed unnecessary whitespace. The
kernel version I am using linux-next-20140411.

Signed-off-by: Julian Gindi <juliangindi@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-16 20:20:03 -07:00
Luis Ortega
2315e49e78 Staging: bcm: Qos: fixed braces' coding style
Fixed badly placed and unnecessary braces.

PS: Performed as task 10 of the Eudyptula Challenge.

Signed-off-by: Luis Ortega <luiorpe1@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-14 08:29:28 -07:00
Jake Edge
32f21cee85 staging/bcm fix hostmibs.c checkpatch problems
Fix 4 checkpatch errors, many warnings in bcm/hostmibs.c

Signed-off-by: Jake Edge <jake@edge2.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-14 08:29:28 -07:00
Gary Rookard
a47a0f5064 Staging: bcm: CmHost: remove temp bracing from switch/cases.
Remove the temp bracing afixed to case labels.

Properly indent switch/case breaks.

Signed-off-by: Gary Alan Rookard <garyrookard@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-04-14 08:29:27 -07:00
Linus Torvalds
159d8133d0 Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial
Pull trivial tree updates from Jiri Kosina:
 "Usual rocket science -- mostly documentation and comment updates"

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jikos/trivial:
  sparse: fix comment
  doc: fix double words
  isdn: capi: fix "CAPI_VERSION" comment
  doc: DocBook: Fix typos in xml and template file
  Bluetooth: add module name for btwilink
  driver core: unexport static function create_syslog_header
  mmc: core: typo fix in printk specifier
  ARM: spear: clean up editing mistake
  net-sysfs: fix comment typo 'CONFIG_SYFS'
  doc: Insert MODULE_ in module-signing macros
  Documentation: update URL to hfsplus Technote 1150
  gpio: update path to documentation
  ixgbe: Fix format string in ixgbe_fcoe.
  Kconfig: Remove useless "default N" lines
  user_namespace.c: Remove duplicated word in comment
  CREDITS: fix formatting
  treewide: Fix typo in Documentation/DocBook
  mm: Fix warning on make htmldocs caused by slab.c
  ata: ata-samsung_cf: cleanup in header file
  idr: remove unused prototype of idr_free()
2014-04-02 16:23:38 -07:00
Tugce Sirin
65fbed376a Staging: bcm: Remove unnecessary parentheses
This patch fixes checkpatch.pl warning Unnecessary parentheses in bcm
driver.

Signed-off-by: Tugce Sirin <ztugcesirin@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-19 13:53:56 -07:00
Heena Sirwani
280c4c8f99 staging: bcm: Fix line over 80 characters.
Fix checkpatch.pl issues with line over 80 characters in Adapter.h

Signed-off-by: Heena Sirwani <heenasirwani@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-19 09:32:11 -07:00
Gary Rookard
3c13b046d5 Staging: bcm: CmHost: moved and removed declarations and tmp bracing.
Firstly, some background is needed to confirm the validity of
this patch as error fixing. It seems the developer when writing
this driver from scratch, used what are known to me as error
suppressors in the form of extra tmp bracing added to the case labels.
They aid during construction time, but are not intended to remain.

In this scenario there are declarations occupying space only
reserved for statements. If these tmp braces were to be removed
before the declarations in question were reassigned to there
proper place in the funtion, compile time errors would result.

So, having that said, I moved the declarations,
UINT uiSearchRuleIndex = 0; and ULONG ulSFID;,
and also deleted the duplicates thereof from
the switch/case statement.

Removed temporary bracing from case labels.

Removed new lines as needed.

Properly indented case breaks.

Added /* FALLTHROUGH */ comments to switch/case.

Signed-off-by: Gary Rookard <garyrookard@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 16:22:27 -07:00
Jade Bilkey
9b14459654 staging: bcm: Remove unneeded boolean comparisons and reflow lines
Removes needless boolean TRUE and false comparisons and reflows some lines to
eliminate over 80 character if statments.

Signed-off-by: Jade Bilkey <herself@thefumon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 11:48:42 -07:00
Jade Bilkey
6246432f73 staging: bcm: Fix space before semicolon
Fixes several checkpatch

WARNING: space prohibited before semicolon

Signed-off-by: Jade Bilkey <herself@thefumon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 11:48:42 -07:00
Jade Bilkey
529d08e97d staging: bcm: Fix lines over 80 characters
Signed-off-by: Jade Bilkey <herself@thefumon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 11:48:42 -07:00
Jade Bilkey
c6e50bafd0 staging: bcm: Cleanup unneeded boolean comparisons
Cleans up a few needless comparisons with booleans and cleans up an
interupt handler to take advantage of earlier bailout shortcircuit.

Signed-off-by: Jade Bilkey <herself@thefumon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 11:48:42 -07:00
Jade Bilkey
6a259d9b7b staging: bcm: Cleanup CreateInterruptUrb() and StartInterruptUrb()
Fixes checkpatch.pl warnings and errors:

ERROR: that open brace { should be on the previous line
+	if (!psIntfAdapter->psInterruptUrb)
+	{

WARNING: line over 80 characters
+		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Cannot allocate interrupt urb");

ERROR: space required after that ',' (ctx:VxV)
+		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Cannot allocate interrupt urb");
 		                                        ^

ERROR: space required after that ',' (ctx:VxV)
+		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Cannot allocate interrupt urb");
 		                                                                                ^

WARNING: line over 80 characters
+								psIntfAdapter->ulInterruptData;

WARNING: line over 80 characters
+							sizeof(psIntfAdapter->ulInterruptData);

WARNING: line over 80 characters
+						psIntfAdapter->sIntrIn.int_in_endpointAddr);

WARNING: line over 80 characters
+					psIntfAdapter->psInterruptUrb->transfer_buffer,

WARNING: line over 80 characters
+					psIntfAdapter->psInterruptUrb->transfer_buffer_length,

WARNING: line over 80 characters
+	BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Interrupt Interval: %d\n",

ERROR: space required after that ',' (ctx:VxV)
+	BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Interrupt Interval: %d\n",
 	                                        ^

ERROR: space required after that ',' (ctx:VxV)
+	BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Interrupt Interval: %d\n",
 	                                                                                ^

ERROR: that open brace { should be on the previous line
+	if( false == psIntfAdapter->psAdapter->device_removed &&
+		false == psIntfAdapter->psAdapter->bEndPointHalted &&
+		false == psIntfAdapter->bSuspended &&
+		false == psIntfAdapter->bPreparingForBusSuspend &&
+		false == psIntfAdapter->psAdapter->StopAllXaction)
+	{

ERROR: space prohibited after that open parenthesis '('
+	if( false == psIntfAdapter->psAdapter->device_removed &&

ERROR: space required before the open parenthesis '('
+	if( false == psIntfAdapter->psAdapter->device_removed &&

WARNING: line over 80 characters
+		status = usb_submit_urb(psIntfAdapter->psInterruptUrb, GFP_ATOMIC);

ERROR: that open brace { should be on the previous line
+		if (status)
+		{

WARNING: line over 80 characters
+			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Cannot send int urb %d\n", status);

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Cannot send int urb %d\n", status);
 			                                        ^

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Cannot send int urb %d\n", status);
 			                                                                                ^

ERROR: that open brace { should be on the previous line
+			if(status == -EPIPE)
+			{

ERROR: space required before the open parenthesis '('
+			if(status == -EPIPE)

WARNING: line over 80 characters
+				psIntfAdapter->psAdapter->bEndPointHalted = TRUE ;

WARNING: space prohibited before semicolon
+				psIntfAdapter->psAdapter->bEndPointHalted = TRUE ;

WARNING: line over 80 characters
+				wake_up(&psIntfAdapter->psAdapter->tx_packet_wait_queue);

Signed-off-by: Jade Bilkey <herself@thefumon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 11:48:42 -07:00
Jade Bilkey
94e74333d0 staging: bcm: Cleanup switch statement
Fixes checkpatch.pl warnings and errors:

ERROR: switch and case should be at the same indent
+	switch (status) {
[...]
+	    case STATUS_SUCCESS:
[...]
+		case -ENOENT :
[...]
+		case -EINPROGRESS:
[...]
+		case -EPIPE:
[...]
+	    case -ECONNRESET: //URB got unlinked.
+	    case -ESHUTDOWN:		// hardware gone. this is the serious problem.
[...]
+	    case -ENODEV : //Device got removed
+		case -EINVAL : //Some thing very bad happened with the URB. No description is available.
[...]
+	    default:

ERROR: that open brace { should be on the previous line
+		if ( urb->actual_length )
+		{

ERROR: space prohibited after that open parenthesis '('
+		if ( urb->actual_length )

ERROR: space prohibited before that close parenthesis ')'
+		if ( urb->actual_length )

ERROR: that open brace { should be on the previous line
+			if(psIntfAdapter->ulInterruptData[1] & 0xFF)
+			{

ERROR: space required before the open parenthesis '('
+			if(psIntfAdapter->ulInterruptData[1] & 0xFF)

WARNING: line over 80 characters
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL, "Got USIM interrupt");

ERROR: space required after that ',' (ctx:VxV)
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL, "Got USIM interrupt");
 				                       ^
ERROR: that open brace { should be on the previous line
+			if(psIntfAdapter->ulInterruptData[1] & 0xFF00)
+			{

ERROR: space required before the open parenthesis '('
+			if(psIntfAdapter->ulInterruptData[1] & 0xFF00)

WARNING: line over 80 characters
+					(psIntfAdapter->ulInterruptData[1] & 0xFF00) >> 8);

WARNING: space prohibited between function name and open parenthesis '('
+				atomic_set (&Adapter->uiMBupdate, TRUE);

WARNING: line over 80 characters
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL, "TX mailbox contains %d",

ERROR: space required after that ',' (ctx:VxV)
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL, "TX mailbox contains %d",
 				                       ^
+					atomic_read(&Adapter->CurrNumFreeTxDesc));

ERROR: that open brace { should be on the previous line
+			if(psIntfAdapter->ulInterruptData[1] >> 16)
+			{

ERROR: space required before the open parenthesis '('
+			if(psIntfAdapter->ulInterruptData[1] >> 16)

ERROR: spaces required around that '=' (ctx:VxE)
+				Adapter->CurrNumRecvDescs=
 				                         ^

WARNING: line over 80 characters
+					(psIntfAdapter->ulInterruptData[1]  >> 16);
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"RX mailbox contains %d",

ERROR: space required after that ',' (ctx:VxV)
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"RX mailbox contains %d",
 				                       ^

ERROR: space required after that ',' (ctx:VxV)
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"RX mailbox contains %d",
 				                                                               ^

ERROR: that open brace { should be on the previous line
+			if(Adapter->fw_download_done &&
+				!Adapter->downloadDDR &&
+				atomic_read(&Adapter->CurrNumFreeTxDesc))
+			{

ERROR: space required before the open parenthesis '('
+			if(Adapter->fw_download_done &&

ERROR: spaces required around that '+=' (ctx:WxV)
+				psIntfAdapter->psAdapter->downloadDDR +=1;
 				                                      ^

ERROR: that open brace { should be on the previous line
+			if(false == Adapter->waiting_to_fw_download_done)
+			{

ERROR: space required before the open parenthesis '('
+			if(false == Adapter->waiting_to_fw_download_done)

ERROR: that open brace { should be on the previous line
+			if(!atomic_read(&Adapter->TxPktAvail))
+			{

ERROR: space required before the open parenthesis '('
+			if(!atomic_read(&Adapter->TxPktAvail))

WARNING: line over 80 characters
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Firing interrupt in URB");

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Firing interrupt in URB");
 			                       ^

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Firing interrupt in URB");
 			                                                               ^

ERROR: space prohibited before that ':' (ctx:WxE)
+		case -ENOENT :
 		             ^

WARNING: line over 80 characters
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"URB has got disconnected ....");

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"URB has got disconnected ....");
 			                       ^

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"URB has got disconnected ....");
 			                                                               ^

WARNING: space prohibited before semicolon
+			return ;

WARNING: line over 80 characters
+			//This situation may happened when URBunlink is used. for detail check usb_unlink_urb documentation.

ERROR: do not use C99 // comments
+			//This situation may happened when URBunlink is used. for detail check usb_unlink_urb documentation.

WARNING: line over 80 characters
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Impossibe condition has occurred... something very bad is going on");

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Impossibe condition has occurred... something very bad is going on");
 			                       ^

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Impossibe condition has occurred... something very bad is going on");
 			                                                               ^

WARNING: space prohibited before semicolon
+			break ;

ERROR: do not use C99 // comments
+			//return;

WARNING: line over 80 characters
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Interrupt IN endPoint  has got halted/stalled...need to clear this");

ERROR: space required after that ',' (ctx:VxV)
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Interrupt IN endPoint  has got halted/stalled...need to clear this");
 				                       ^

ERROR: space required after that ',' (ctx:VxV)
+				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"Interrupt IN endPoint  has got halted/stalled...need to clear this");
 				                                                               ^

WARNING: space prohibited before semicolon
+				Adapter->bEndPointHalted = TRUE ;

WARNING: space prohibited before semicolon
+				urb->status = STATUS_SUCCESS ;

ERROR: do not use C99 // comments
+	    case -ECONNRESET: //URB got unlinked.

WARNING: line over 80 characters
+	    case -ESHUTDOWN:		// hardware gone. this is the serious problem.

ERROR: do not use C99 // comments
+	    case -ESHUTDOWN:		// hardware gone. this is the serious problem.

WARNING: line over 80 characters
+	    						//Occurs only when something happens with the host controller device

ERROR: code indent should use tabs where possible
+^I    ^I^I^I^I^I^I//Occurs only when something happens with the host controller device$

WARNING: please, no space before tabs
+^I    ^I^I^I^I^I^I//Occurs only when something happens with the host controller device$

ERROR: do not use C99 // comments
+	    						//Occurs only when something happens with the host controller device

ERROR: do not use C99 // comments
+	    case -ENODEV : //Device got removed

ERROR: space prohibited before that ':' (ctx:WxW)
+	    case -ENODEV : //Device got removed
 	                 ^

WARNING: line over 80 characters
+		case -EINVAL : //Some thing very bad happened with the URB. No description is available.

ERROR: do not use C99 // comments
+		case -EINVAL : //Some thing very bad happened with the URB. No description is available.

ERROR: space prohibited before that ':' (ctx:WxW)
+		case -EINVAL : //Some thing very bad happened with the URB. No description is available.
 		             ^

WARNING: line over 80 characters
+	    	BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"interrupt urb error %d", status);

ERROR: code indent should use tabs where possible
+^I    ^IBCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"interrupt urb error %d", status);$

WARNING: please, no space before tabs
+^I    ^IBCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"interrupt urb error %d", status);$

ERROR: space required after that ',' (ctx:VxV)
+	    	BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"interrupt urb error %d", status);
 	    	                       ^

ERROR: space required after that ',' (ctx:VxV)
+	    	BCM_DEBUG_PRINT(Adapter,DBG_TYPE_OTHERS, INTF_INIT, DBG_LVL_ALL,"interrupt urb error %d", status);
 	    	                                                               ^

WARNING: space prohibited before semicolon
+			urb->status = STATUS_SUCCESS ;

WARNING: space prohibited before semicolon
+			break ;

ERROR: do not use C99 // comments
+			//return;

ERROR: spaces required around that ':' (ctx:VxE)
+	    default:
 	           ^

WARNING: line over 80 characters
+			//This is required to check what is the defaults conditions when it occurs..

ERROR: do not use C99 // comments
+			//This is required to check what is the defaults conditions when it occurs..

WARNING: line over 80 characters
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, NEXT_SEND, DBG_LVL_ALL,"GOT DEFAULT INTERRUPT URB STATUS :%d..Please Analyze it...", status);

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, NEXT_SEND, DBG_LVL_ALL,"GOT DEFAULT INTERRUPT URB STATUS :%d..Please Analyze it...", status);
 			                       ^

ERROR: space required after that ',' (ctx:VxV)
+			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_TX, NEXT_SEND, DBG_LVL_ALL,"GOT DEFAULT INTERRUPT URB STATUS :%d..Please Analyze it...", status);
 			                                                           ^
Signed-off-by: Jade Bilkey <herself@thefumon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-03-18 11:48:42 -07:00