From: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx> Date: Wed, 13 Sep 2017 20:32:25 +0200 Assign a pointer to a data structure member without using an intermediate local variable. Signed-off-by: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx> --- drivers/media/usb/ttusb-dec/ttusb_dec.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/drivers/media/usb/ttusb-dec/ttusb_dec.c b/drivers/media/usb/ttusb-dec/ttusb_dec.c index 26d637684b30..7759de653ee9 100644 --- a/drivers/media/usb/ttusb-dec/ttusb_dec.c +++ b/drivers/media/usb/ttusb-dec/ttusb_dec.c @@ -1650,14 +1650,10 @@ static const struct ttusbdecfe_config fe_config = { static int ttusb_dec_probe(struct usb_interface *intf, const struct usb_device_id *id) { - struct usb_device *udev; struct ttusb_dec *dec; int result; dprintk("%s\n", __func__); - - udev = interface_to_usbdev(intf); - dec = kzalloc(sizeof(*dec), GFP_KERNEL); if (!dec) return -ENOMEM; @@ -1678,7 +1674,7 @@ static int ttusb_dec_probe(struct usb_interface *intf, break; } - dec->udev = udev; + dec->udev = interface_to_usbdev(intf); result = ttusb_dec_init_usb(dec); if (result) -- 2.14.1