Re: [PATCH 01/13] Bluetooth: btusb: Initialize @priv_size at declaration in btusb_probe()

From: Dmitry Baryshkov

Date: Mon Jun 22 2026 - 11:35:11 EST


On Mon, Jun 22, 2026 at 07:52:14AM -0700, Zijun Hu wrote:
> Initialize @priv_size at declaration to reduce a redundant assignment.

This is obvious from the commit. Please tell us, why?

>
> Signed-off-by: Zijun Hu <zijun.hu@xxxxxxxxxxxxxxxx>
> ---
> drivers/bluetooth/btusb.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
> index 7f14ce96319b..5209e2418493 100644
> --- a/drivers/bluetooth/btusb.c
> +++ b/drivers/bluetooth/btusb.c
> @@ -4082,7 +4082,7 @@ static int btusb_probe(struct usb_interface *intf,
> struct btusb_data *data;
> struct hci_dev *hdev;
> unsigned ifnum_base;
> - int err, priv_size;
> + int err, priv_size = 0;
>
> BT_DBG("intf %p id %p", intf, id);
>
> @@ -4152,8 +4152,6 @@ static int btusb_probe(struct usb_interface *intf,
> init_usb_anchor(&data->ctrl_anchor);
> spin_lock_init(&data->rxlock);
>
> - priv_size = 0;
> -
> data->recv_event = hci_recv_frame;
> data->recv_bulk = btusb_recv_bulk;
>
>
> --
> 2.34.1
>

--
With best wishes
Dmitry