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] [day] [month] [year] [list]
Date:	Wed, 20 Nov 2013 21:13:30 +0200
From:	Stefan Kristiansson <stefan.kristiansson@...nalahti.fi>
To:	Jingoo Han <jg1.han@...sung.com>
Cc:	linux-kernel@...r.kernel.org, linux-fbdev@...r.kernel.org,
	'Tomi Valkeinen' <tomi.valkeinen@...com>,
	'Jean-Christophe PLAGNIOL-VILLARD' <plagnioj@...osoft.com>
Subject: Re: [PATCH v2] video: add OpenCores VGA/LCD framebuffer driver

On Wed, Nov 20, 2013 at 03:20:28PM +0900, Jingoo Han wrote:
> On Wednesday, November 20, 2013 1:14 PM, Stefan Kristiansson wrote:
> 
> > +static int ocfb_probe(struct platform_device *pdev)
> > +{
> > +	int ret = 0;
> > +	struct ocfb_dev *fbdev;
> > +	struct ocfb_par *par = &ocfb_par_priv;
> > +	struct resource *res;
> > +	struct resource *mmio;
> > +	int fbsize;
> > +
> > +	fbdev = kzalloc(sizeof(*fbdev), GFP_KERNEL);
> 
> Please use devm_kzalloc() instead of kzalloc().
> In this case, kfree() can be removed from ocfb_probe()
> and ocfb_remove(). Thus, it will make the code smaller.
> 

Nice, thanks for the hint!
Consider it done.

> [.....]
> 
> > +
> > +#ifdef MODULE
> 
> I don't think that '#ifdef MODULE' is necessary.
> Is there any reason?
> 

You're right, that's not necessary, I'll remove that.

Thanks alot for taking the time to review it!

Stefan
--
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