Message ID | 5686AFAE.7020401@users.sourceforge.net |
---|---|
State | Changes Requested, archived |
Delegated to: | David Miller |
Headers | show |
SF Markus Elfring <elfring@users.sourceforge.net> writes: > From: Markus Elfring <elfring@users.sourceforge.net> > Date: Fri, 1 Jan 2016 17:35:03 +0100 > > Omit explicit initialisation at the beginning for one local variable > that is redefined before its first use. This patch is unnecessary. The variable initialisation is redundant. See the difference? Sending an unnecessary patch causes unnecessary load on reviewers and maintainers. Keeping redundant code has no measurable cost, and can save the same maintainers a lot of trouble later. I'd like to keep this particular redundant initialisation as a safe guard against future code refactoring, causing for example the err label to move up. Yes, I do understand that any patch with such a bug should be rejected, but I do know what happens in the real world and how easy it is for something like that to slip through in a stream of unnecessary "cleanup" patches. Reducing redundancy in the kernel is only making the code less robust. It is harmful. Please stop. Thanks. Bjørn -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
From: Bjørn Mork <bjorn@mork.no> Date: Sat, 02 Jan 2016 22:30:48 +0100 > SF Markus Elfring <elfring@users.sourceforge.net> writes: > >> From: Markus Elfring <elfring@users.sourceforge.net> >> Date: Fri, 1 Jan 2016 17:35:03 +0100 >> >> Omit explicit initialisation at the beginning for one local variable >> that is redefined before its first use. > > > This patch is unnecessary. The variable initialisation is redundant. > See the difference? Sending an unnecessary patch causes unnecessary > load on reviewers and maintainers. Keeping redundant code has no > measurable cost, and can save the same maintainers a lot of trouble > later. +1 I'm getting really tired of these changes. And a lot of them are coming in right now... -- To unsubscribe from this list: send the line "unsubscribe netdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/drivers/net/usb/qmi_wwan.c b/drivers/net/usb/qmi_wwan.c index 5b8af06..5962099 100644 --- a/drivers/net/usb/qmi_wwan.c +++ b/drivers/net/usb/qmi_wwan.c @@ -286,7 +286,7 @@ static int qmi_wwan_cdc_wdm_manage_power(struct usb_interface *intf, int on) static int qmi_wwan_register_subdriver(struct usbnet *dev) { int rv; - struct usb_driver *subdriver = NULL; + struct usb_driver *subdriver; struct qmi_wwan_state *info = (void *)&dev->data; /* collect bulk endpoints */