01 Nov, 2011

1 commit


16 Dec, 2010

1 commit

  • Extend the perf_pmu_register() interface to allow for named and
    dynamic pmu types.

    Because we need to support the existing static types we cannot use
    dynamic types for everything, hence provide a type argument.

    If we want to enumerate the PMUs they need a name, provide one.

    Signed-off-by: Peter Zijlstra
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     

15 Oct, 2010

1 commit


11 Oct, 2010

2 commits

  • Introduce perf_pmu_name() helper function that returns the name of the
    pmu. This gives us a generic way to get the name of a pmu regardless of
    how an architecture identifies it internally.

    Signed-off-by: Matt Fleming
    Acked-by: Peter Zijlstra
    Acked-by: Paul Mundt
    Signed-off-by: Robert Richter

    Matt Fleming
     
  • The number of counters for the registered pmu is needed in a few places
    so provide a helper function that returns this number.

    Signed-off-by: Matt Fleming
    Tested-by: Will Deacon
    Acked-by: Paul Mundt
    Acked-by: Peter Zijlstra
    Signed-off-by: Robert Richter

    Matt Fleming
     

15 Sep, 2010

1 commit


10 Sep, 2010

5 commits

  • Replace pmu::{enable,disable,start,stop,unthrottle} with
    pmu::{add,del,start,stop}, all of which take a flags argument.

    The new interface extends the capability to stop a counter while
    keeping it scheduled on the PMU. We replace the throttled state with
    the generic stopped state.

    This also allows us to efficiently stop/start counters over certain
    code paths (like IRQ handlers).

    It also allows scheduling a counter without it starting, allowing for
    a generic frozen state (useful for rotating stopped counters).

    The stopped state is implemented in two different ways, depending on
    how the architecture implemented the throttled state:

    1) We disable the counter:
    a) the pmu has per-counter enable bits, we flip that
    b) we program a NOP event, preserving the counter state

    2) We store the counter state and ignore all read/overflow events

    Signed-off-by: Peter Zijlstra
    Cc: paulus
    Cc: stephane eranian
    Cc: Robert Richter
    Cc: Will Deacon
    Cc: Paul Mundt
    Cc: Frederic Weisbecker
    Cc: Cyrill Gorcunov
    Cc: Lin Ming
    Cc: Yanmin
    Cc: Deng-Cheng Zhu
    Cc: David Miller
    Cc: Michael Cree
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     
  • Changes perf_disable() into perf_pmu_disable().

    Signed-off-by: Peter Zijlstra
    Cc: paulus
    Cc: stephane eranian
    Cc: Robert Richter
    Cc: Will Deacon
    Cc: Paul Mundt
    Cc: Frederic Weisbecker
    Cc: Cyrill Gorcunov
    Cc: Lin Ming
    Cc: Yanmin
    Cc: Deng-Cheng Zhu
    Cc: David Miller
    Cc: Michael Cree
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     
  • Since the current perf_disable() usage is only an optimization,
    remove it for now. This eases the removal of the __weak
    hw_perf_enable() interface.

    Signed-off-by: Peter Zijlstra
    Cc: paulus
    Cc: stephane eranian
    Cc: Robert Richter
    Cc: Will Deacon
    Cc: Paul Mundt
    Cc: Frederic Weisbecker
    Cc: Cyrill Gorcunov
    Cc: Lin Ming
    Cc: Yanmin
    Cc: Deng-Cheng Zhu
    Cc: David Miller
    Cc: Michael Cree
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     
  • Simple registration interface for struct pmu, this provides the
    infrastructure for removing all the weak functions.

    Signed-off-by: Peter Zijlstra
    Cc: paulus
    Cc: stephane eranian
    Cc: Robert Richter
    Cc: Will Deacon
    Cc: Paul Mundt
    Cc: Frederic Weisbecker
    Cc: Cyrill Gorcunov
    Cc: Lin Ming
    Cc: Yanmin
    Cc: Deng-Cheng Zhu
    Cc: David Miller
    Cc: Michael Cree
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     
  • sed -ie 's/const struct pmu\>/struct pmu/g' `git grep -l "const struct pmu\>"`

    Signed-off-by: Peter Zijlstra
    Cc: paulus
    Cc: stephane eranian
    Cc: Robert Richter
    Cc: Will Deacon
    Cc: Paul Mundt
    Cc: Frederic Weisbecker
    Cc: Cyrill Gorcunov
    Cc: Lin Ming
    Cc: Yanmin
    Cc: Deng-Cheng Zhu
    Cc: David Miller
    Cc: Michael Cree
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     

09 Jun, 2010

1 commit


23 Mar, 2010

1 commit


10 Mar, 2010

1 commit

  • Remove the hw_perf_event_*() hotplug hooks in favour of per PMU hotplug
    notifiers. This has the advantage of reducing the static weak interface
    as well as exposing all hotplug actions to the PMU.

    Use this to fix x86 hotplug usage where we did things in ONLINE which
    should have been done in UP_PREPARE or STARTING.

    Signed-off-by: Peter Zijlstra
    Cc: Paul Mundt
    Cc: paulus@samba.org
    Cc: eranian@google.com
    Cc: robert.richter@amd.com
    Cc: fweisbec@gmail.com
    Cc: Arnaldo Carvalho de Melo
    LKML-Reference:
    Signed-off-by: Ingo Molnar

    Peter Zijlstra
     

05 Nov, 2009

1 commit


28 Oct, 2009

2 commits

  • num_events should be compared > MAX_HWEVENTS and not >=. The latter was
    used as a debugging test which accidentally slipped in.

    Signed-off-by: Paul Mundt

    Paul Mundt
     
  • This adds in preliminary support for the SH-4A performance counters.
    Presently only the first 2 counters are supported, as these are the ones
    of the most interest to the perf tool and end users. Counter chaining is
    not presently handled, so these are simply implemented as 32-bit
    counters.

    This also establishes a perf event support framework for other hardware
    counters, which the existing SH-4 oprofile code will migrate over to as
    the SH-4A support evolves.

    Signed-off-by: Paul Mundt

    Paul Mundt