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: <1153683377.44c3cfb146443@portal.student.luth.se>
Date:	Sun, 23 Jul 2006 21:36:17 +0200
From:	ricknu-0@...dent.ltu.se
To:	Jan Engelhardt <jengelh@...ux01.gwdg.de>
Cc:	linux-kernel@...r.kernel.org, Andrew Morton <akpm@...l.org>,
	Jeff Garzik <jeff@...zik.org>,
	Alexey Dobriyan <adobriyan@...il.com>,
	Vadim Lobanov <vlobanov@...akeasy.net>,
	Shorty Porty <getshorty_@...mail.com>,
	Peter Williams <pwil3058@...pond.net.au>,
	Michael Buesch <mb@...sch.de>,
	Pekka Enberg <penberg@...helsinki.fi>,
	Stefan Richter <stefanr@...6.in-berlin.de>, larsbj@...lik.net
Subject: Re: [RFC][PATCH] A generic boolean (version 4)

Citerar Jan Engelhardt <jengelh@...ux01.gwdg.de>:

> 
> >Hopefully it is now ready for a "real" patch, whom adds bool to all
> >arches. If there is no comments on this one, it will be sent about
> >tomorrow night (GMT).
> 
> --- a/drivers/block/DAC960.h
> +++ b/drivers/block/DAC960.h
> @@ -71,7 +71,7 @@ #define DAC690_V2_PciDmaMask	0xfffffffff
>    Define a Boolean data type.
>  */
>  
> -typedef enum { false, true } __attribute__ ((packed)) boolean;
> +typedef bool boolean;
>  
>  
>  /*
> 
> Looks good. (I know found out what this is good for. Eventually, all
> booleans
> in the source of DAC960 et al. should be changed to just 'bool' but that's
> another patch's job.)

Yepp :)

> Looks good, except for the "all arches" thing. You only seem to add it
> to i386:

I said: 'ready for a "real" patch', meaning it will be in another patch.
Will try to be more clear in the future.

> >+#undef false
> >+#undef true
> >+
> >+enum {
> >+	false	= 0,
> >+	true	= 1
> >+};
> >+
> >+#define false false
> >+#define true true 
> 
> Can someone please tell me what advantage 'define true true' is going to
> bring, besides than being able to '#ifdef true'?

Assembly-code can not use enum but #define. That is the reason I find but there
might be more.


> Jan Engelhardt

/Richard Knutsson

-
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