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]
Message-ID: <20131105224526.GA11759@localhost>
Date:	Tue, 5 Nov 2013 19:45:27 -0300
From:	Ezequiel Garcia <ezequiel.garcia@...e-electrons.com>
To:	Brian Norris <computersforpeace@...il.com>
Cc:	Jingoo Han <jg1.han@...sung.com>, "Gupta, Pekon" <pekon@...com>,
	Wei Yongjun <weiyj.lk@...il.com>,
	"tony@...mide.com" <tony@...mide.com>,
	Artem Bityutskiy <artem.bityutskiy@...ux.intel.com>,
	Linux Kernel <linux-kernel@...r.kernel.org>,
	Daniel Mack <zonque@...il.com>, yongjun_wei@...ndmicro.com.cn,
	avinashphilip@...com,
	"linux-mtd@...ts.infradead.org" <linux-mtd@...ts.infradead.org>,
	David Woodhouse <dwmw2@...radead.org>
Subject: Re: [PATCH -next] mtd: nand: omap: fix error return code in
 omap_nand_probe()

On Tue, Nov 05, 2013 at 01:59:25PM -0800, Brian Norris wrote:
> On Thu, Oct 31, 2013 at 7:18 PM, Jingoo Han <jg1.han@...sung.com> wrote:
> > On Friday, November 01, 2013 9:16 AM, Wei Yongjun wrote:
> >>
> >> From: Wei Yongjun <yongjun_wei@...ndmicro.com.cn>
> >>
> >> Fix to return a negative error code from the error handling
> >> case instead of 0, as done elsewhere in this function.
> >
> > Commit message is right? :-(
> 
> It sounds OK by my reading. Unless you're having trouble parsing what
> "as done elsewhere in this function" is being applied to. (IOW, is the
> rest of the function returning a negative error code on the error
> paths, or is it returning 0? Of course the answer is the former, but
> it's possible to misread it.) If it helps, I can try to tweak the
> wording a bit when applying this patch.
> 
> Pekon, can I get an Acked-by?
> 

I guess you'd prefer Pekon's ack than mine, but anyway:

Acked-by: Ezequiel Garcia <ezequiel.garcia@...e-electrons.com>

I'd like to point out this driver has other "mis-behaviors" in returning codes
in some other places.

In particular, this pattern can be found repeatedly:

	if (do_something()) {
		err = -ENXIO;
		goto some_other_place;
	}

Which should probably be:

	err = do_something();
	if (err)
		goto some_other_place;

Wei: maybe you'd like to prepare some more patches?
-- 
Ezequiel GarcĂ­a, Free Electrons
Embedded Linux, Kernel and Android Engineering
http://free-electrons.com
--
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