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:	Thu, 22 Jul 2010 22:37:40 +1000
From:	Neil Brown <neilb@...e.de>
To:	Boaz Harrosh <bharrosh@...asas.com>
Cc:	Christoph Hellwig <hch@...radead.org>,
	Jiri Slaby <jirislaby@...il.com>,
	James Bottomley <James.Bottomley@...e.de>,
	linux-scsi@...r.kernel.org, hch@....de, jaxboe@...ionio.com,
	LKML <linux-kernel@...r.kernel.org>, linux-raid@...r.kernel.org
Subject: Re: [PATCH] md: bitwise operations might not fit in a "bool"

On Thu, 22 Jul 2010 15:20:53 +0300
Boaz Harrosh <bharrosh@...asas.com> wrote:

> On 07/22/2010 02:55 PM, Neil Brown wrote:
> > On Thu, 22 Jul 2010 14:44:53 +0300
> > Boaz Harrosh <bharrosh@...asas.com> wrote:
> > 
> >>
> >> when taking a resolute of a bit-wise AND as true false. Better / faster
> >> to make it a boolean operation.
> >>
> >> This fixes a bug and a crash because the flags field did not fit into
> >> the bool operands.
> > 
> > No, that won't work.
> > Read the rest of the code and see where 'do_sync' and 'do_barriers' are used.
> > 
> > NeilBrown
> > 
> 
> You are right! (I didn't look)
> 
> the use of "bool" was wrong from the get go. it was never a bool operation.
> What was the guy thinking? What is that do_XXX name? that name should change
> as well. Perhaps flg_sync, flg_barriers.

Check the git history - 'bool' was originally appropriate.  But when the
value was recently changed, the type and name were not.
I would actually prefer "sync_flg" and "barrier_flg", but your suggestion
that we change the name as well as the type is a good one.

Thanks,
NeilBrown
--
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