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] [day] [month] [year] [list]
Date:	Wed, 14 Apr 2010 17:12:40 +0200
From:	Erik Faye-Lund <kusmabite@...glemail.com>
To:	mingo@...hat.com, acme@...hat.com, jkacur@...hat.com,
	a.p.zijlstra@...llo.nl, rusty@...tcorp.com.au, efault@....de,
	mitake@....info.waseda.ac.jp, imunsie@....ibm.com,
	fweisbec@...il.com, rostedt@...dmis.org,
	hirofumi@...l.parknet.co.jp, imunsie@...ibm.com,
	tglx@...utronix.de, mhiramat@...hat.com, paulus@...ba.org,
	hpa@...or.com, linux-kernel@...r.kernel.org, anton@...ba.org,
	tzanussi@...il.com, arjan@...ux.intel.com, lizf@...fujitsu.com,
	tfransosi@...il.com, xiaoguangrong@...fujitsu.com,
	git@...r.kernel.org, amwang@...hat.com, davem@...emloft.net,
	jaswinderrajput@...il.com, ebmunson@...ibm.com,
	kosaki.motohiro@...fujitsu.com, mingo@...e.hu
Cc:	linux-tip-commits@...r.kernel.org
Subject: Re: [tip:perf/core] perf: Fix endianness argument compatibility with 
	OPT_BOOLEAN() and introduce OPT_INCR()

I'd just like to point out that I'm commenting from the Git
pont-of-view, since this patch was CC'ed to the Git mailing-list.

On Wed, Apr 14, 2010 at 11:36 AM, tip-bot for Ian Munsie
<imunsie@...ibm.com> wrote:
> Commit-ID:  c05556421742eb47f80301767653a4bcb19de9de
> Gitweb:     http://git.kernel.org/tip/c05556421742eb47f80301767653a4bcb19de9de
> Author:     Ian Munsie <imunsie@...ibm.com>
> AuthorDate: Tue, 13 Apr 2010 18:37:33 +1000
> Committer:  Ingo Molnar <mingo@...e.hu>
> CommitDate: Wed, 14 Apr 2010 11:26:44 +0200
>
> perf: Fix endianness argument compatibility with OPT_BOOLEAN() and introduce OPT_INCR()
>
> Parsing an option from the command line with OPT_BOOLEAN on a
> bool data type would not work on a big-endian machine due to the
> manner in which the boolean was being cast into an int and
> incremented.

We don't use C99 features like the "bool"-type in Git, so this
shouldn't really be a problem in our end.

> For example, running 'perf probe --list' on a
> PowerPC machine would fail to properly set the list_events bool
> and would therefore print out the usage information and
> terminate.
>

I don't know what this 'perf'-thing is, but it sounds like it's some
external client for the parse-options-API that uses OPT_BOOLEAN
incorrectly.

Looking at linux-next.git, it seems so. The code in tools/perf/ seems
to use OPT_BOOLEAN with C99 bools, and it seems to have imported git's
parse-options API (in commit 0780060124011b94af55830939c86cc0916be0f5,
it seems).

I'd suggest either fixing the call-sites to use int, or just keeping
these changes in linux-next.git.

-- 
Erik "kusma" Faye-Lund
--
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