LKML Archive on lore.kernel.org
 help / color / Atom feed
From: sebhtml <sebhtml@videotron.qc.ca>
To: Andrew Morton <akpm@linux-foundation.org>,
	Dan Williams <dan.j.williams@intel.com>
Cc: Steven Rostedt <rostedt@goodmis.org>,
	acme@redhat.com, tz.stoyanov@gmail.com,
	Namhyung Kim <namhyung@kernel.org>,
	zwisler@kernel.org, arangradient@gmail.com,
	linux-perf-users@vger.kernel.org,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] pfn_t: force '~' to be parsed as an unary operator
Date: Wed, 24 Oct 2018 19:52:40 -0400
Message-ID: <d48b2b1b-201a-d350-6bda-943a66f1abfb@videotron.qc.ca> (raw)
In-Reply-To: <FRrzgp7InaOtKFRs0geay1@videotron.ca>

On 2018-10-24 6:43 p.m., Andrew Morton wrote:
> 
> I grabbed it, and added cc:stable.
> 
> But aren't we fixing this in the wrong place?  That's a valid
> expression and if this isn't addressed in perf then we may hit a
> similar issue elsewhere...
> 

Right.

Based on:
     git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 01aa9d518eae8a4d75cd3049defc6ed0b6d0a658

In perf, the warning
       [fs_dax:dax_pmd_insert_mapping] unknown op '~'
comes from tools/lib/traceevent/event-parse.c at line 2045:
                 do_warning_event(event, "unknown op '%s'", token);

This is in this function:

static enum tep_event_type
process_op(struct tep_event_format *event, struct tep_print_arg *arg, char **tok);

The code path to reach the good '~' case needs:
         if (arg->type == TEP_PRINT_OP && !arg->op.left) {

I assume that here arg->op.left is not NULL because of (u64) on the left.

~(((u64) ~(~(((1UL) << 12)-1)))
          ^

However, I fail to see where '~' is parsed as a binary operator though.

Any pointer would be welcome.

      parent reply index

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-21 14:59 Sebastien Boisvert
2018-10-22 17:13 ` Dan Williams
2018-10-24 22:43   ` Andrew Morton
     [not found]   ` <FRrzgp7InaOtKFRs0geay1@videotron.ca>
2018-10-24 23:52     ` sebhtml [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d48b2b1b-201a-d350-6bda-943a66f1abfb@videotron.qc.ca \
    --to=sebhtml@videotron.qc.ca \
    --cc=acme@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=arangradient@gmail.com \
    --cc=dan.j.williams@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-perf-users@vger.kernel.org \
    --cc=namhyung@kernel.org \
    --cc=rostedt@goodmis.org \
    --cc=tz.stoyanov@gmail.com \
    --cc=zwisler@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

LKML Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/lkml/0 lkml/git/0.git
	git clone --mirror https://lore.kernel.org/lkml/1 lkml/git/1.git
	git clone --mirror https://lore.kernel.org/lkml/2 lkml/git/2.git
	git clone --mirror https://lore.kernel.org/lkml/3 lkml/git/3.git
	git clone --mirror https://lore.kernel.org/lkml/4 lkml/git/4.git
	git clone --mirror https://lore.kernel.org/lkml/5 lkml/git/5.git
	git clone --mirror https://lore.kernel.org/lkml/6 lkml/git/6.git
	git clone --mirror https://lore.kernel.org/lkml/7 lkml/git/7.git
	git clone --mirror https://lore.kernel.org/lkml/8 lkml/git/8.git
	git clone --mirror https://lore.kernel.org/lkml/9 lkml/git/9.git
	git clone --mirror https://lore.kernel.org/lkml/10 lkml/git/10.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 lkml lkml/ https://lore.kernel.org/lkml \
		linux-kernel@vger.kernel.org
	public-inbox-index lkml

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-kernel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git