lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 11 Nov 2014 13:08:56 +0900
From:	Greg KH <gregkh@...uxfoundation.org>
To:	Stephanie Wallick <stephanie.s.wallick@...el.com>
Cc:	linux-kernel@...r.kernel.org, linux-usb@...r.kernel.org,
	devel@...verdev.osuosl.org,
	"Sean O. Stalley" <sean.stalley@...el.com>
Subject: Re: [V2 PATCH 01/10] added media agnostic (MA) USB HCD driver

On Mon, Nov 10, 2014 at 06:09:32PM -0800, Stephanie Wallick wrote:
> +static int mausb_bus_probe(struct device *dev)
> +{
> +	return mausb_probe(dev);
> +}
> +
> +static int mausb_bus_remove(struct device *dev)
> +{
> +	return mausb_remove(dev);
> +}

Wrapper functions that just call another function?  Why?

> +static void mausb_dev_release(struct device *dev)
> +{
> +	/* TODO: if we dynamically allocate anything, free it here */
> +}

As per the documentation in the kernel source tree[1], I am now allowed
to mock you mercilessly for thinking that you know more than the kernel,
and are just providing an "empty" function just to shut it up from
complaining about no release function at all.  Did you stop to think
about _why_ the kernel was warning you about this, and how would an
empty function solve anything?

Sorry, I can never accept code that does this in the kernel, even in
staging, which says a lot...

thanks,

greg k-h

[1] Documentation/kobject.txt, line 270
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ