mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Paul Menzel <pmenzel@molgen.mpg.de>
To: Oliver Neukum <oneukum@suse.com>,
	marcel@holtmann.org, luiz.dentz@gmail.com,
	linux-bluetooth@vger.kernel.org, linux-kernel@vger.kernel.org,
	Kiran K <kiran.k@intel.com>
Subject: Re: [PATCH] bluetooth: btintel_pcie: nonsense error recording in irq
Date: Thu, 16 May 2024 07:44:44 +0200	[thread overview]
Message-ID: <5aa68ee5-dd84-4ac2-9fd1-36160358fdcf@molgen.mpg.de> (raw)
In-Reply-To: <20240516045118.18552-1-oneukum@suse.com>

[Cc: +Kiran]

Dear Oliver,


Thank you for the patch. I have two minor comments. Could you please 
word the summary as a statement by adding a verb (in imperative mood). 
Maybe:

 > Fix nonsense …

or

 > Remove unused `ret` assignment

Am 16.05.24 um 06:50 schrieb Oliver Neukum:
> Either you return an error or you ignore it.
> Recording it but then overwriting it makes no sense.
It’d be great if you added a Fixes: tag.

> Signed-off-by: Oliver Neukum <oneukum@suse.com>
> ---
>   drivers/bluetooth/btintel_pcie.c | 8 ++------
>   1 file changed, 2 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/bluetooth/btintel_pcie.c b/drivers/bluetooth/btintel_pcie.c
> index 590c188a4bb3..c507422d6b1b 100644
> --- a/drivers/bluetooth/btintel_pcie.c
> +++ b/drivers/bluetooth/btintel_pcie.c
> @@ -498,19 +498,15 @@ static int btintel_pcie_submit_rx_work(struct btintel_pcie_data *data, u8 status
>   	rfh_hdr = buf;
>   
>   	len = rfh_hdr->packet_len;
> -	if (len <= 0) {
> -		ret = -EINVAL;
> +	if (len <= 0)
>   		goto resubmit;
> -	}
>   
>   	/* Remove RFH header */
>   	buf += sizeof(*rfh_hdr);
>   
>   	skb = alloc_skb(len, GFP_ATOMIC);
> -	if (!skb) {
> -		ret = -ENOMEM;
> +	if (!skb)
>   		goto resubmit;
> -	}
>   
>   	skb_put_data(skb, buf, len);
>   	skb_queue_tail(&data->rx_skb_q, skb);


Kind regards,

Paul

      reply	other threads:[~2024-05-16  5:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-16  4:50 Oliver Neukum
2024-05-16  5:44 ` Paul Menzel [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=5aa68ee5-dd84-4ac2-9fd1-36160358fdcf@molgen.mpg.de \
    --to=pmenzel@molgen.mpg.de \
    --cc=kiran.k@intel.com \
    --cc=linux-bluetooth@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luiz.dentz@gmail.com \
    --cc=marcel@holtmann.org \
    --cc=oneukum@suse.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®