All of lore.kernel.org
 help / color / mirror / Atom feed
From: Dan Carpenter <dan.carpenter@oracle.com>
To: kernel-janitors@vger.kernel.org
Subject: Re: [patch 2/2] bluetooth:bfusb.c Clean assigment in if condition.
Date: Mon, 11 Nov 2013 07:59:38 +0000	[thread overview]
Message-ID: <20131111075938.GE5302@mwanda> (raw)
In-Reply-To: <CAAL8FfATHpfzeJor5x8yj6VbguMGrKFjFt8Xk4d2ZkVF_-66_w@mail.gmail.com>

On Mon, Nov 11, 2013 at 02:06:21AM -0200, Luca Bartolacci wrote:
> I'm not sure if the change is justified.
> An other question is. Can i "clean" a complete directory (Like
> /bluetooth) an put it all in one patch? That way is more easy for you?
> Im asking all these questions to understand what is better to avoid
> spam to the others.
> Im sure the these questions are dumb. But i really want to help to this project.
> 

This change introduces bugs.

No signed-off-by line either, btw.

regards,
dan carpenter

> index 3138699..08fba91 100644
> --- a/drivers/bluetooth/bfusb.c
> +++ b/drivers/bluetooth/bfusb.c
> @@ -131,8 +131,10 @@ static int bfusb_send_bulk(struct bfusb_data *data, struct
> 
>         BT_DBG("bfusb %p skb %p len %d", data, skb, skb->len);
> 
> -       if (!urb && !(urb = usb_alloc_urb(0, GFP_ATOMIC)))
> -               return -ENOMEM;
> +       if (!urb)
> +               urb = usb_alloc_urb(0, GFP_ATOMIC);
> +               if (!urb)
> +                       return -ENOMEM;
> 
>         pipe = usb_sndbulkpipe(data->udev, data->bulk_out_ep);
> 
> 
> @@ -218,8 +220,10 @@ static int bfusb_rx_submit(struct bfusb_data *data, struct
> 
>         BT_DBG("bfusb %p urb %p", data, urb);
> 
> -       if (!urb && !(urb = usb_alloc_urb(0, GFP_ATOMIC)))
> -               return -ENOMEM;
> +       if (!urb)
> +               urb = usb_alloc_urb(0, GFP_ATOMIC);
> +               if (!urb)
> +                       return -ENOMEM;
> --
> To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

      reply	other threads:[~2013-11-11  7:59 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-11-11  4:06 [patch 2/2] bluetooth:bfusb.c Clean assigment in if condition Luca Bartolacci
2013-11-11  7:59 ` Dan Carpenter [this message]

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=20131111075938.GE5302@mwanda \
    --to=dan.carpenter@oracle.com \
    --cc=kernel-janitors@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.