06 Aug, 2014

1 commit

  • Pull timer and time updates from Thomas Gleixner:
    "A rather large update of timers, timekeeping & co

    - Core timekeeping code is year-2038 safe now for 32bit machines.
    Now we just need to fix all in kernel users and the gazillion of
    user space interfaces which rely on timespec/timeval :)

    - Better cache layout for the timekeeping internal data structures.

    - Proper nanosecond based interfaces for in kernel users.

    - Tree wide cleanup of code which wants nanoseconds but does hoops
    and loops to convert back and forth from timespecs. Some of it
    definitely belongs into the ugly code museum.

    - Consolidation of the timekeeping interface zoo.

    - A fast NMI safe accessor to clock monotonic for tracing. This is a
    long standing request to support correlated user/kernel space
    traces. With proper NTP frequency correction it's also suitable
    for correlation of traces accross separate machines.

    - Checkpoint/restart support for timerfd.

    - A few NOHZ[_FULL] improvements in the [hr]timer code.

    - Code move from kernel to kernel/time of all time* related code.

    - New clocksource/event drivers from the ARM universe. I'm really
    impressed that despite an architected timer in the newer chips SoC
    manufacturers insist on inventing new and differently broken SoC
    specific timers.

    [ Ed. "Impressed"? I don't think that word means what you think it means ]

    - Another round of code move from arch to drivers. Looks like most
    of the legacy mess in ARM regarding timers is sorted out except for
    a few obnoxious strongholds.

    - The usual updates and fixlets all over the place"

    * 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (114 commits)
    timekeeping: Fixup typo in update_vsyscall_old definition
    clocksource: document some basic timekeeping concepts
    timekeeping: Use cached ntp_tick_length when accumulating error
    timekeeping: Rework frequency adjustments to work better w/ nohz
    timekeeping: Minor fixup for timespec64->timespec assignment
    ftrace: Provide trace clocks monotonic
    timekeeping: Provide fast and NMI safe access to CLOCK_MONOTONIC
    seqcount: Add raw_write_seqcount_latch()
    seqcount: Provide raw_read_seqcount()
    timekeeping: Use tk_read_base as argument for timekeeping_get_ns()
    timekeeping: Create struct tk_read_base and use it in struct timekeeper
    timekeeping: Restructure the timekeeper some more
    clocksource: Get rid of cycle_last
    clocksource: Move cycle_last validation to core code
    clocksource: Make delta calculation a function
    wireless: ath9k: Get rid of timespec conversions
    drm: vmwgfx: Use nsec based interfaces
    drm: i915: Use nsec based interfaces
    timekeeping: Provide ktime_get_raw()
    hangcheck-timer: Use ktime_get_ns()
    ...

    Linus Torvalds
     

05 Aug, 2014

6 commits

  • Pull USB updates from Greg KH:
    "Here is the big USB driver update for 3.17-rc1.

    Loads of gadget driver changes in here, including some big file
    movements to make things easier to manage over time. There's also the
    usual xhci and uas driver updates, and a handful of other changes in
    here. The changelog has the full details.

    All of these have been in linux-next for a while"

    * tag 'usb-3.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb: (211 commits)
    USB: devio: fix issue with log flooding
    uas: Log a warning when we cannot use uas because the hcd lacks streams
    uas: Only complain about missing sg if all other checks succeed
    xhci: Add missing checks for xhci_alloc_command failure
    xhci: Rename Asrock P67 pci product-id to EJ168
    xhci: Blacklist using streams on the Etron EJ168 controller
    uas: Limit qdepth to 32 when connected over usb-2
    uwb/whci: use correct structure type name in sizeof
    usb-core bInterval quirk
    USB: serial: ftdi_sio: Add support for new Xsens devices
    USB: serial: ftdi_sio: Annotate the current Xsens PID assignments
    usb: chipidea: debug: fix sparse non static symbol warnings
    usb: ci_hdrc_imx doc: fsl,usbphy is required
    usb: ci_hdrc_imx: Return -EINVAL for missing USB PHY
    usb: core: allow zero packet flag for interrupt urbs
    usb: lvstest: Fix sparse warnings generated by kbuild test bot
    USB: core: hcd-pci: free IRQ before disabling PCI device when shutting down
    phy: miphy365x: Represent each PHY channel as a DT subnode
    phy: miphy365x: Provide support for the MiPHY356x Generic PHY
    phy: miphy365x: Add Device Tree bindings for the MiPHY365x
    ...

    Linus Torvalds
     
  • Pull driver core updates from Greg KH:
    "Here's the big driver-core pull request for 3.17-rc1.

    Largest thing in here is the dma-buf rework and fence code, that
    touched many different subsystems so it was agreed it should go
    through this tree to handle merge issues. There's also some firmware
    loading updates, as well as tests added, and a few other tiny changes,
    the changelog has the details.

    All have been in linux-next for a long time"

    * tag 'driver-core-3.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: (32 commits)
    ARM: imx: Remove references to platform_bus in mxc code
    firmware loader: Fix _request_firmware_load() return val for fw load abort
    platform: Remove most references to platform_bus device
    test: add firmware_class loader test
    doc: fix minor typos in firmware_class README
    staging: android: Cleanup style issues
    Documentation: devres: Sort managed interfaces
    Documentation: devres: Add devm_kmalloc() et al
    fs: debugfs: remove trailing whitespace
    kernfs: kernel-doc warning fix
    debugfs: Fix corrupted loop in debugfs_remove_recursive
    stable_kernel_rules: Add pointer to netdev-FAQ for network patches
    driver core: platform: add device binding path 'driver_override'
    driver core/platform: remove unused implicit padding in platform_object
    firmware loader: inform direct failure when udev loader is disabled
    firmware: replace ALIGN(PAGE_SIZE) by PAGE_ALIGN
    firmware: read firmware size using i_size_read()
    firmware loader: allow disabling of udev as firmware loader
    reservation: add suppport for read-only access using rcu
    reservation: update api and add some helpers
    ...

    Conflicts:
    drivers/base/platform.c

    Linus Torvalds
     
  • Pull char / misc driver patches from Greg KH:
    "Here's the big driver misc / char pull request for 3.17-rc1.

    Lots of things in here, the thunderbolt support for Apple laptops,
    some other new drivers, testing fixes, and other good things. All
    have been in linux-next for a long time"

    * tag 'char-misc-3.17-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (119 commits)
    misc: bh1780: Introduce the use of devm_kzalloc
    Lattice ECP3 FPGA: Correct endianness
    drivers/misc/ti-st: Load firmware from ti-connectivity directory.
    dt-bindings: extcon: Add support for SM5502 MUIC device
    extcon: sm5502: Change internal hardware switch according to cable type
    extcon: sm5502: Detect cable state after completing platform booting
    extcon: sm5502: Add support new SM5502 extcon device driver
    extcon: arizona: Get MICVDD against extcon device
    extcon: Remove unnecessary OOM messages
    misc: vexpress: Fix sparse non static symbol warnings
    mei: drop unused hw dependent fw status functions
    misc: bh1770glc: Use managed functions
    pcmcia: remove DEFINE_PCI_DEVICE_TABLE usage
    misc: remove DEFINE_PCI_DEVICE_TABLE usage
    ipack: Replace DEFINE_PCI_DEVICE_TABLE macro use
    drivers/char/dsp56k.c: drop check for negativity of unsigned parameter
    mei: fix return value on disconnect timeout
    mei: don't schedule suspend in pm idle
    mei: start disconnect request timer consistently
    mei: reset client connection state on timeout
    ...

    Linus Torvalds
     
  • Pull perf changes from Ingo Molnar:
    "Kernel side changes:

    - Consolidate the PMU interrupt-disabled code amongst architectures
    (Vince Weaver)

    - misc fixes

    Tooling changes (new features, user visible changes):

    - Add support for pagefault tracing in 'trace', please see multiple
    examples in the changeset messages (Stanislav Fomichev).

    - Add pagefault statistics in 'trace' (Stanislav Fomichev)

    - Add header for columns in 'top' and 'report' TUI browsers (Jiri
    Olsa)

    - Add pagefault statistics in 'trace' (Stanislav Fomichev)

    - Add IO mode into timechart command (Stanislav Fomichev)

    - Fallback to syscalls:* when raw_syscalls:* is not available in the
    perl and python perf scripts. (Daniel Bristot de Oliveira)

    - Add --repeat global option to 'perf bench' to be used in benchmarks
    such as the existing 'futex' one, that was modified to use it
    instead of a local option. (Davidlohr Bueso)

    - Fix fd -> pathname resolution in 'trace', be it using /proc or a
    vfs_getname probe point. (Arnaldo Carvalho de Melo)

    - Add suggestion of how to set perf_event_paranoid sysctl, to help
    non-root users trying tools like 'trace' to get a working
    environment. (Arnaldo Carvalho de Melo)

    - Updates from trace-cmd for traceevent plugin_kvm plus args cleanup
    (Steven Rostedt, Jan Kiszka)

    - Support S/390 in 'perf kvm stat' (Alexander Yarygin)

    Tooling infrastructure changes:

    - Allow reserving a row for header purposes in the hists browser
    (Arnaldo Carvalho de Melo)

    - Various fixes and prep work related to supporting Intel PT (Adrian
    Hunter)

    - Introduce multiple debug variables control (Jiri Olsa)

    - Add callchain and additional sample information for python scripts
    (Joseph Schuchart)

    - More prep work to support Intel PT: (Adrian Hunter)
    - Polishing 'script' BTS output
    - 'inject' can specify --kallsym
    - VDSO is per machine, not a global var
    - Expose data addr lookup functions previously private to 'script'
    - Large mmap fixes in events processing

    - Include standard stringify macros in power pc code (Sukadev
    Bhattiprolu)

    Tooling cleanups:

    - Convert open coded equivalents to asprintf() (Andy Shevchenko)

    - Remove needless reassignments in 'trace' (Arnaldo Carvalho de Melo)

    - Cache the is_exit syscall test in 'trace) (Arnaldo Carvalho de
    Melo)

    - No need to reimplement err() in 'perf bench sched-messaging', drop
    barf(). (Davidlohr Bueso).

    - Remove ev_name argument from perf_evsel__hists_browse, can be
    obtained from the other parameters. (Jiri Olsa)

    Tooling fixes:

    - Fix memory leak in the 'sched-messaging' perf bench test.
    (Davidlohr Bueso)

    - The -o and -n 'perf bench mem' options are mutually exclusive, emit
    error when both are specified. (Davidlohr Bueso)

    - Fix scrollbar refresh row index in the ui browser, problem exposed
    now that headers will be added and will be allowed to be switched
    on/off. (Jiri Olsa)

    - Handle the num array type in python properly (Sebastian Andrzej
    Siewior)

    - Fix wrong condition for allocation failure (Jiri Olsa)

    - Adjust callchain based on DWARF debug info on powerpc (Sukadev
    Bhattiprolu)

    - Fix a risk for doing free on uninitialized pointer in traceevent
    lib (Rickard Strandqvist)

    - Update attr test with PERF_FLAG_FD_CLOEXEC flag (Jiri Olsa)

    - Enable close-on-exec flag on perf file descriptor (Yann Droneaud)

    - Fix build on gcc 4.4.7 (Arnaldo Carvalho de Melo)

    - Event ordering fixes (Jiri Olsa)"

    * 'perf-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (123 commits)
    Revert "perf tools: Fix jump label always changing during tracing"
    perf tools: Fix perf usage string leftover
    perf: Check permission only for parent tracepoint event
    perf record: Store PERF_RECORD_FINISHED_ROUND only for nonempty rounds
    perf record: Always force PERF_RECORD_FINISHED_ROUND event
    perf inject: Add --kallsyms parameter
    perf tools: Expose 'addr' functions so they can be reused
    perf session: Fix accounting of ordered samples queue
    perf powerpc: Include util/util.h and remove stringify macros
    perf tools: Fix build on gcc 4.4.7
    perf tools: Add thread parameter to vdso__dso_findnew()
    perf tools: Add dso__type()
    perf tools: Separate the VDSO map name from the VDSO dso name
    perf tools: Add vdso__new()
    perf machine: Fix the lifetime of the VDSO temporary file
    perf tools: Group VDSO global variables into a structure
    perf session: Add ability to skip 4GiB or more
    perf session: Add ability to 'skip' a non-piped event stream
    perf tools: Pass machine to vdso__dso_findnew()
    perf tools: Add dso__data_size()
    ...

    Linus Torvalds
     
  • Pull RCU changes from Ingo Molar:
    "The main changes:

    - torture-test updates
    - callback-offloading changes
    - maintainership changes
    - update RCU documentation
    - miscellaneous fixes"

    * 'core-rcu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (32 commits)
    rcu: Allow for NULL tick_nohz_full_mask when nohz_full= missing
    rcu: Fix a sparse warning in rcu_report_unblock_qs_rnp()
    rcu: Fix a sparse warning in rcu_initiate_boost()
    rcu: Fix __rcu_reclaim() to use true/false for bool
    rcu: Remove CONFIG_PROVE_RCU_DELAY
    rcu: Use __this_cpu_read() instead of per_cpu_ptr()
    rcu: Don't use NMIs to dump other CPUs' stacks
    rcu: Bind grace-period kthreads to non-NO_HZ_FULL CPUs
    rcu: Simplify priority boosting by putting rt_mutex in rcu_node
    rcu: Check both root and current rcu_node when setting up future grace period
    rcu: Allow post-unlock reference for rt_mutex
    rcu: Loosen __call_rcu()'s rcu_head alignment constraint
    rcu: Eliminate read-modify-write ACCESS_ONCE() calls
    rcu: Remove redundant ACCESS_ONCE() from tick_do_timer_cpu
    rcu: Make rcu node arrays static const char * const
    signal: Explain local_irq_save() call
    rcu: Handle obsolete references to TINY_PREEMPT_RCU
    rcu: Document deadlock-avoidance information for rcu_read_unlock()
    scripts: Teach get_maintainer.pl about the new "R:" tag
    rcu: Update rcu torture maintainership filename patterns
    ...

    Linus Torvalds
     
  • Pull config-bisect changes from Steven Rostedt:
    "The big change here is the rewrite of config-bisect. The old way
    never worked properly as it assumed the bad config was a subset of the
    good config, and just found the config that would break the build.

    The new way does a diff of the bad config verses the good config and
    makes the similar until it finds that one config works and the other
    does not and reports the config that makes that difference. The two
    configs do not need to be related. It is much more useful now:

    * tag 'ktest-v3.17' of git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-ktest:
    ktest: Update documentation on config_bisect
    ktest: Add the config bisect manual back
    ktest: Remove unused functions
    ktest: Put back in the CONFIG_BISECT_CHECK
    ktest: Rewrite the config-bisect to actually work
    ktest: Some cleanup for improving readability
    ktest: add 2nd parameter of run_command() to set the redirect target file

    Linus Torvalds
     

28 Jul, 2014

4 commits

  • This reverts commit deaff8b659cf4d34181c087b8cdf74f1eb17b02b.

    This commit makes CLOEXEC feature undetected for normal users,
    because per-cpu events are priviledged.

    Reported-by: Peter Zijlstra
    Cc: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/20140728065844.GK6758@twins.programming.kicks-ass.net
    Signed-off-by: Jiri Olsa

    Jiri Olsa
     
  • Fixing perf usage string leftover pointed out by Namhyung.

    Reported-by: Namhyung Kim
    Cc: Arnaldo Carvalho de Melo
    Cc: Corey Ashford
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Ingo Molnar
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Link: http://lkml.kernel.org/n/tip-vkcf53oultknsh3ue9fhin94@git.kernel.org
    Signed-off-by: Jiri Olsa

    Jiri Olsa
     
  • …/acme/linux into perf/core

    Pull perf/core improvements and fixes from Arnaldo Carvalho de Melo:

    Infrastructure changes:

    o More prep work to support Intel PT: (Adrian Hunter)
    - Polishing 'script' BTS output
    - 'inject' can specify --kallsym
    - VDSO is per machine, not a global var
    - Expose data addr lookup functions previously private to 'script'
    - Large mmap fixes in events processing

    o Fix build on gcc 4.4.7 (Arnaldo Carvalho de Melo)

    o Event ordering fixes (Jiri Olsa)

    o Include standard stringify macros in power pc code (Sukadev Bhattiprolu)

    Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
    Signed-off-by: Ingo Molnar <mingo@kernel.org>

    Ingo Molnar
     
  • Signed-off-by: Ingo Molnar

    Ingo Molnar
     

25 Jul, 2014

5 commits

  • Currently we store PERF_RECORD_FINISHED_ROUND event each time
    we go throught mmap buffers no matter if it contains any data,
    which is useless.

    Forcing the PERF_RECORD_FINISHED_ROUND event to be stored any
    time we finished the round AND wrote at least one event.

    Signed-off-by: Jiri Olsa
    Acked-by: Adrian Hunter
    Acked-by: David Ahern
    Cc: Corey Ashford
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Ingo Molnar
    Cc: Jean Pihet
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Link: http://lkml.kernel.org/r/1406300177-31805-19-git-send-email-jolsa@kernel.org
    Signed-off-by: Arnaldo Carvalho de Melo

    Jiri Olsa
     
  • The PERF_RECORD_FINISHED_ROUND synthetic record governs queue flushing
    in reporting, so it needs to be stored for any kind of event.

    The lack of such periodic flushing made the tools use more memory than
    needed, as the reordering was being done only after processing all
    events. This was the case when no tracepoints were in the mix.

    Forcing the PERF_RECORD_FINISHED_ROUND event to be stored for all event
    types.

    Signed-off-by: Jiri Olsa
    Acked-by: Adrian Hunter
    Acked-by: David Ahern
    Cc: Corey Ashford
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Ingo Molnar
    Cc: Jean Pihet
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Link: http://lkml.kernel.org/r/1406300177-31805-18-git-send-email-jolsa@kernel.org
    Signed-off-by: Arnaldo Carvalho de Melo

    Jiri Olsa
     
  • Let perf inject take --kallsyms parameter the same as perf script and
    perf report do.

    That is needed for decoding Instruction Trace data using a copy of
    /proc/kcore for the kernel object because the kallsyms path is used to
    locate that copy.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-30-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Move some functions and functionality related to the use of
    'addr' out of builtin-script so they can be reused.

    The moved functions are: is_bts_event() and sample_addr_correlates_sym()
    and a new function perf_event__preprocess_sample_addr() is created from
    bits of print_sample_addr().

    perf_event__preprocess_sample_addr() is the equivalent of
    perf_event__preprocess_sample() but for 'addr' instead of 'ip'.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-31-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Properly account flushed samples within the ordered samples queue.

    Signed-off-by: Jiri Olsa
    Acked-by: Adrian Hunter
    Acked-by: David Ahern
    Cc: Corey Ashford
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Ingo Molnar
    Cc: Jean Pihet
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Link: http://lkml.kernel.org/r/1405893363-21967-2-git-send-email-jolsa@kernel.org
    Signed-off-by: Arnaldo Carvalho de Melo

    Jiri Olsa
     

24 Jul, 2014

12 commits

  • The stringify macros are defined in tools/perf/util/util.h and don't
    need to be redfined specfiically for powerpc.

    Signed-off-by: Sukadev Bhattiprolu
    Cc: Andi Kleen
    Cc: Jiri Olsa
    Cc: Michael Ellerman
    Link: http://lkml.kernel.org/r/20140724074718.GB18829@us.ibm.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Sukadev Bhattiprolu
     
  • [acme@sandy linux]$ gcc --version
    gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)
    Copyright (C) 2010 Free Software Foundation, Inc.
    This is free software; see the source for copying conditions. There is NO
    warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

    [acme@sandy linux]$ make O=/tmp/build/perf -C tools/perf install-bin

    CC /tmp/build/perf/builtin-trace.o
    builtin-trace.c: In function ‘perf_evlist__add_pgfault’:
    builtin-trace.c:1997: error: unknown field ‘sample_period’ specified in initializer
    make[1]: *** [/tmp/build/perf/builtin-trace.o] Error 1
    make: *** [install-bin] Error 2
    make: Leaving directory `/home/acme/git/linux/tools/perf'
    [acme@sandy linux]$ make O=/tmp/build/perf -C tools/perf install-bin
    make O=/tmp/build/perf -C tools/perf install-bin
    make: Entering directory `/home/acme/git/linux/tools/perf'

    Cc: Adrian Hunter
    Cc: David Ahern
    Cc: Don Zickus
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Mike Galbraith
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/n/tip-qt7h2g5fcf42qiw5hv7mgpjk@git.kernel.org
    Signed-off-by: Arnaldo Carvalho de Melo

    Arnaldo Carvalho de Melo
     
  • The thread will be needed to determine the VDSO type.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-52-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • dso__type() determines wheather a dso is 32-bit, x32 (32-bit with 64-bit
    registers) or 64-bit.

    dso__type() will be used to determine the VDSO a program maps.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-51-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • This is in preparation for supporting 32-bit compatibility VDSOs.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-49-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • This is preparation for adding support for compat VDSOs.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-48-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • The VDSO temporary file is unlinked when a session is deleted. That
    precludes the possibilities that there is no session or there is more
    than one session.

    Correctly the vdso belongs to the machine so put the information on
    'struct machine' and get rid of the global variables.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/53CF9B14.7040408@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • This is preparation for removing the global variables used in vdso.c and
    thereby fixing the lifetime of the VDSO temporary file.

    Also allowance is made for the later addition of support for compat
    VDSOs.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-46-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • A session can be made to skip portions of the input file. Do not limit
    that size to 32-bits.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406143198-20732-2-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • A piped event stream may contain arbitary sized tracepoint information
    following a PERF_RECORD_HEADER_TRACING_DATA event. The position in the
    stream has to be 'skipped' to match the start of the next event.

    Provide the same ability to a non-piped event stream to allow for
    Instruction Trace data that may also be in a non-piped event stream.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406143198-20732-1-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • This is preparation for removing the global variables used in vdso.c and
    thereby fixing the lifetime of the VDSO temporary file.

    Reviewed-by: Jiri Olsa
    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-45-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • This script makes use of the udelay_test module to exercise udelay()
    and ensure that it is delaying long enough (as compared to ktime).

    Signed-off-by: David Riley
    Signed-off-by: John Stultz

    David Riley
     

23 Jul, 2014

10 commits

  • Add a function to return the dso data size, for use in estimating the
    size an instruction cache.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-27-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Move the rdtsc() function so it can be reusued.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-24-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Add an array to struct machine to store the current tid running on each
    cpu.

    Add machine functions to get / set the tid for a cpu.

    This will be used to determine the tid when decoding a per-cpu
    Instruction Trace.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-17-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Tools may wish to track on which cpu a thread is running. Add 'cpu' to
    struct thread for that purpose.

    This will be used to determine the cpu when decoding a per-thread
    Instruction Trace.

    E.g: Intel PT decoding uses sched_switch events to determine which task
    is running on which cpu. The Intel PT data comes straight from the
    hardware which doesn't know about linux threads.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-16-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Add ability to mark all dsos as hit.

    This is needed in the case of Instruction Tracing. It takes so long to
    decode an Instruction Trace that it is not worth doing just to determine
    which dsos are hit. A later patch takes this into use.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-15-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Add a function to track whether a caller has seen the data status of a
    dso. This is needed to enable callers to report the error exactly once
    only per dso.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-11-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Add 'data.status' to record whether a dso has data (i.e. an object
    file). This is used to avoid repeatedly creating the file name and
    attempting to open a file that is not present.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-10-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • When using:

    perf record -e branches:u -c1 usleep 1
    perf script -f ip

    lines are displayed like:

    ffffffff813b23d5 =>

    Change so that the dangling '=>' does not appear.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-8-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Change the order of the output to put the srcline last.

    It puts the branch 'from address' and 'to address' on the same line,
    which is how it would be without the source line reference.

    So it makes it consistent and much easier to read.

    E.g. old format:

    4028fc main+0x2c (/bin/ls)
    /build/buildd/coreutils-8.20/src/ls.c:1269 => 40d8a0 set_program_name+0x0 (/bin/ls)

    new format:

    4028fc main+0x2c (/bin/ls) => 40d8a0 set_program_name+0x0 (/bin/ls)
    /build/buildd/coreutils-8.20/src/ls.c:1269

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-7-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     
  • Intel PT decoding walks the object code to reconstruct the trace. A
    jump label change during tracing causes decoding errors.

    The "Enable close-on-exec flag on perf file descriptor" patch caused
    there to be always a jump label change.

    It was found that using a per-cpu context instead of a per-thread
    context for the probe of the close-on-exec feature, made the problem go
    away.

    Signed-off-by: Adrian Hunter
    Cc: David Ahern
    Cc: Frederic Weisbecker
    Cc: Jiri Olsa
    Cc: Namhyung Kim
    Cc: Paul Mackerras
    Cc: Peter Zijlstra
    Cc: Stephane Eranian
    Link: http://lkml.kernel.org/r/1406035081-14301-2-git-send-email-adrian.hunter@intel.com
    Signed-off-by: Arnaldo Carvalho de Melo

    Adrian Hunter
     

22 Jul, 2014

2 commits