[OPW,kernel] Staging: Fix indentation for conditional statement
diff mbox

Message ID 20131005124843.GA5068@gmail.com
State Superseded
Headers show

Commit Message

Rashika Oct. 5, 2013, 12:48 p.m. UTC
The patch fixes the WARNING: suspect code indent for conditional
statements detected via checkpatch.pl

Signed-off-by: Rashika <rashika.kheria@gmail.com>
---
 drivers/staging/btmtk_usb/btmtk_usb.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Sarah Sharp Oct. 8, 2013, 7:52 p.m. UTC | #1
Hi Rashika,

The patches you've sent for this file are very confusing.
You've used the same subject lines (and revisions versions) for at least
two different patches.  It's going to be a mess for Greg to figure out
which patches to apply.

I would suggest you update your patches against the staging tree, and
then send a completely new, numbered patchset with all your changes.
Here's some directions on how to do that:

1. Add the staging-next tree as a git remote:

git add remote staging git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git

2. Checkout a new branch with your current work on it:

git checkout -b staging-fixes-rebase

3. Rebase your fixes against the staging next branch:

git rebase staging/staging-next

You may need to clean up any code conflicts, so that your patches apply
cleanly against the staging tree.  This page might help explain how to
do that (although in your case, you have a merge conflict due to a
rebase, not from a merge commit):

https://help.github.com/articles/resolving-a-merge-conflict-from-the-command-line

After you've rebased your branch, please use `git format-patch -n` to
created a numbered patchset of all your patches on that branch.  That
will help Greg figure out which patches to apply.

If you have patches with the same subject line, you may want to merge
them into one bigger patch.  You can do that with the interactive rebase
tool, `git rebase -i`.  You can change the order of patches by moving
the 'pick' lines up or down, and you can squash patches into the patch
above it by changing 'pick' to 'squash'.  It's probably best to check
out a new branch to play around with interactive git rebase, in case you
mess things up.  You can always stop a rebase by running `git rebase
--abort`.

I'll be on IRC for the next couple of hours if you need some help with
any of this.

Sarah Sharp


On Sat, Oct 05, 2013 at 06:18:43PM +0530, Rashika wrote:
> The patch fixes the WARNING: suspect code indent for conditional
> statements detected via checkpatch.pl
> 
> Signed-off-by: Rashika <rashika.kheria@gmail.com>
> ---
>  drivers/staging/btmtk_usb/btmtk_usb.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/staging/btmtk_usb/btmtk_usb.c b/drivers/staging/btmtk_usb/btmtk_usb.c
> index 1a31f68..7bf3118 100644
> --- a/drivers/staging/btmtk_usb/btmtk_usb.c
> +++ b/drivers/staging/btmtk_usb/btmtk_usb.c
> @@ -1518,8 +1518,8 @@ static void btmtk_usb_work(struct work_struct *work)
>  		__set_isoc_interface(hdev, 0);
>  
>  		if (test_and_clear_bit(BTUSB_DID_ISO_RESUME, &data->flags))
> -			 usb_autopm_put_interface(data->isoc ? data->isoc
> -					 : data->intf);
> +			usb_autopm_put_interface(data->isoc ? data->isoc
> +					: data->intf);
>  	}
>  }
>  
> -- 
> 1.7.9.5
> 
> -- 
> You received this message because you are subscribed to the Google Groups "opw-kernel" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to opw-kernel+unsubscribe@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
Rashika Oct. 8, 2013, 7:56 p.m. UTC | #2
On Wed, Oct 9, 2013 at 1:22 AM, Sarah Sharp <sarah.a.sharp@intel.com> wrote:

> Hi Rashika,
>
> The patches you've sent for this file are very confusing.
> You've used the same subject lines (and revisions versions) for at least
> two different patches.  It's going to be a mess for Greg to figure out
> which patches to apply.
>
> I would suggest you update your patches against the staging tree, and
> then send a completely new, numbered patchset with all your changes.
> Here's some directions on how to do that:
>
> 1. Add the staging-next tree as a git remote:
>
> git add remote staging git://
> git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git
>
> 2. Checkout a new branch with your current work on it:
>
> git checkout -b staging-fixes-rebase
>
> 3. Rebase your fixes against the staging next branch:
>
> git rebase staging/staging-next
>
> You may need to clean up any code conflicts, so that your patches apply
> cleanly against the staging tree.  This page might help explain how to
> do that (although in your case, you have a merge conflict due to a
> rebase, not from a merge commit):
>
>
> https://help.github.com/articles/resolving-a-merge-conflict-from-the-command-line
>
> After you've rebased your branch, please use `git format-patch -n` to
> created a numbered patchset of all your patches on that branch.  That
> will help Greg figure out which patches to apply.
>
> If you have patches with the same subject line, you may want to merge
> them into one bigger patch.  You can do that with the interactive rebase
> tool, `git rebase -i`.  You can change the order of patches by moving
> the 'pick' lines up or down, and you can squash patches into the patch
> above it by changing 'pick' to 'squash'.  It's probably best to check
> out a new branch to play around with interactive git rebase, in case you
> mess things up.  You can always stop a rebase by running `git rebase
> --abort`.
>
> I'll be on IRC for the next couple of hours if you need some help with
> any of this.
>
> Sarah Sharp
>


Hi Sarah,

I have already sent a patch-set (though based on the linus tree only).
Aren't they available on the opw-kernel list?

Or do you want me to send it again?

Thanks

Patch
diff mbox

diff --git a/drivers/staging/btmtk_usb/btmtk_usb.c b/drivers/staging/btmtk_usb/btmtk_usb.c
index 1a31f68..7bf3118 100644
--- a/drivers/staging/btmtk_usb/btmtk_usb.c
+++ b/drivers/staging/btmtk_usb/btmtk_usb.c
@@ -1518,8 +1518,8 @@  static void btmtk_usb_work(struct work_struct *work)
 		__set_isoc_interface(hdev, 0);
 
 		if (test_and_clear_bit(BTUSB_DID_ISO_RESUME, &data->flags))
-			 usb_autopm_put_interface(data->isoc ? data->isoc
-					 : data->intf);
+			usb_autopm_put_interface(data->isoc ? data->isoc
+					: data->intf);
 	}
 }