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:	Sun, 27 Jan 2008 13:51:12 +0100 (CET)
From:	Jan Engelhardt <jengelh@...putergmbh.de>
To:	monstr@...str.eu
cc:	linux-kernel@...r.kernel.org, stephen.neuendorffer@...inx.com,
	john.williams@...alogix.com, microblaze-uclinux@...e.uq.edu.au
Subject: Re: [PATCH 12/52] [microblaze] lmb support


On Jan 24 2008 16:02, monstr@...str.eu wrote:
>+
>+#define DEBUG
>+
>+#ifdef DEBUG
>+#define DBG(fmt...) printk(fmt)
>+#else
>+#define DBG(fmt...)
>+#endif

Phew, don't reinvent the wheel - use the existing pr_debug() instead.


>+static unsigned long __init lmb_addrs_overlap(unsigned long base1,
>+		unsigned long size1, unsigned long base2, unsigned long size2)
>+{
>+	return ((base1 < (base2+size2)) && (base2 < (base1+size1)));
	return base1 < base2 + size2 && base2 < base1 + size1;
>+}

Operator precedence makes it possible; you could omit a lot of () in the code.
(Also try checkpatch.pl to get to know of other style 'errors')
--
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