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]
Message-ID: <20170831164437.GJ4831@kernel.org>
Date:   Thu, 31 Aug 2017 13:44:37 -0300
From:   Arnaldo Carvalho de Melo <acme@...nel.org>
To:     Stephane Eranian <eranian@...gle.com>
Cc:     Peter Zijlstra <peterz@...radead.org>,
        "Liang, Kan" <kan.liang@...el.com>,
        "mingo@...hat.com" <mingo@...hat.com>,
        LKML <linux-kernel@...r.kernel.org>,
        Jiri Olsa <jolsa@...hat.com>,
        Thomas Gleixner <tglx@...utronix.de>,
        "ak@...ux.intel.com" <ak@...ux.intel.com>,
        Michael Ellerman <mpe@...erman.id.au>,
        Madhavan Srinivasan <maddy@...ux.vnet.ibm.com>
Subject: Re: [PATCH V6] perf: Add PERF_SAMPLE_PHYS_ADDR

Em Wed, Aug 23, 2017 at 10:00:37AM -0700, Stephane Eranian escreveu:
> On Wed, Aug 23, 2017 at 7:39 AM, Peter Zijlstra <peterz@...radead.org> wrote:
> > On Wed, Aug 23, 2017 at 04:33:08PM +0200, Peter Zijlstra wrote:
> >> > @@ -6145,6 +6183,9 @@ void perf_prepare_sample(struct perf_event_header *header,
> >> >
> >> >             header->size += size;
> >> >     }
> >> > +
> >> > +   if (sample_type & PERF_SAMPLE_PHYS_ADDR)
> >> > +           data->phys_addr = perf_virt_to_phys(data->addr);
> >>
> >> Only problem with this now is that it requires SAMPLE_ADDR to also be
> >> set in order to obtain data->addr.
> >>
> >> Either fix all to set data->attr for (SAMPLE_ADDR || SAMPLE_PHYS_ADDR)
> >> or mandate SAMPLE_ADDR when SAMPLE_PHYS_ADDR.
> >
> > I think the former suggestion is better, as it allows for smaller
> > samples.
> 
> Agreed. I may only care about physical addresses, so SAMPLE_PHYS_ADDR
> should suffice from the user.
> The kernel must save the virtual address in data->addr, and then convert it.

Stephane, have you took the time to test this together with Kan's latest
patchkit for tools/perf? v2? If so can I have your Tested-by or just an
Acked-by?

Thanks,

- Arnaldo

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ