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: <20080829172304.bcfa5f9d.akpm@linux-foundation.org>
Date:	Fri, 29 Aug 2008 17:23:04 -0700
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	"Yinghai Lu" <yhlu.kernel@...il.com>
Cc:	mingo@...e.hu, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] dyn_array: using %pF instead of
 print_fn_descriptor_symbol

On Fri, 29 Aug 2008 16:34:26 -0700
"Yinghai Lu" <yhlu.kernel@...il.com> wrote:

> On Fri, Aug 29, 2008 at 3:53 PM, Andrew Morton
> <akpm@...ux-foundation.org> wrote:
> >>       ptr = __alloc_bootmem_nopanic(total_size, max_align, 0);
> >>       if (!ptr)
> >>               panic("Can not alloc dyn_alloc\n");
> 
> like to give exact error message.

It's pointless.  panic() will do a dump_stack().

> >
> > Why duplicate the panic()?  Just call __alloc_bootmem().
> >
> >> #ifdef CONFIF_GENERIC_HARDIRQS
> >
> > That doesn't appear to have been very well tested?
> 
> ah!
> it should break sparc, m68k, and s390...
> 
> >
> > The code has a few coding-style glitches which checkpatch can detect.
> >
> 
> should only have 80 char length warning...
> 

sure.  The code looks rather miserable in an 80-col display.

there's also

WARNING: braces {} are not necessary for single statement blocks
#119: FILE: dyn_array.c:119:
+               if (da->init_work) {
+                       da->init_work(da);
+               }



and checkpatch should have detected the misplaced semicolon here:

+       for (daa = __per_cpu_dyn_array_start ; daa < __per_cpu_dyn_array_end; daa++) {

but didn't.

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