09 Sep, 2016

1 commit


31 Aug, 2016

5 commits

  • PCC status field exposes an error bit(2) to indicate any errors during
    the execution of last comamnd. This patch checks the error bit before
    notifying success/failure to the cpufreq driver.

    Signed-off-by: Prashanth Prakash
    Signed-off-by: Rafael J. Wysocki

    Prakash, Prashanth
     
  • The CPPC tables contain entries for per CPU feedback counters which
    allows us to compute the delivered performance over a given interval
    of time.

    The math for delivered performance per the CPPCv5.0+ spec is:
    reference perf * delta(delivered perf ctr)/delta(ref perf ctr)

    Maintaining deltas of the counters in the kernel is messy, as it
    depends on when the reads are triggered. (e.g. via the cpufreq
    ->get() interface). Also the ->get() interace only returns one
    value, so cant return raw values. So instead, leave it to userspace
    to keep track of raw values and do its math for CPUs it cares about.

    delivered and reference perf counters are exposed via the same
    sysfs file to avoid the potential "skid", if these values are read
    individually from userspace.

    Signed-off-by: Prashanth Prakash
    Signed-off-by: Ashwin Chaugule
    Signed-off-by: Rafael J. Wysocki

    Ashwin Chaugule
     
  • Compute the expected transition latency for frequency transitions
    using the values from the PCCT tables when the desired perf
    register is in PCC.

    Signed-off-by: Prashanth Prakash
    Reviewed-by: Alexey Klimov
    Signed-off-by: Rafael J. Wysocki

    Prakash, Prashanth
     
  • CPPC defined in section 8.4.7 of ACPI 6.0 specification suggests
    "To amortize the cost of PCC transactions, OSPM should read or write
    all PCC registers via a single read or write command when possible"
    This patch enables opportunistic batching of frequency transition
    requests whenever the request happen to overlap in time.

    Currently the access to pcc is serialized by a spin lock which does
    not scale well as we increase the number of cores in the system. This
    patch improves the scalability by allowing the differnt CPU cores to
    update PCC subspace in parallel and by batching requests which will
    reduce the certain types of operation(checking command completion bit,
    ringing doorbell) by a significant margin.

    Profiling shows significant improvement in the overall effeciency
    to service freq. transition requests. With this patch we observe close
    to 30% of the frequency transition requests being batched with other
    requests while running apache bench on a ARM platform with 6
    independent domains(or sets of related cpus).

    Signed-off-by: Prashanth Prakash
    Signed-off-by: Rafael J. Wysocki

    Prakash, Prashanth
     
  • For cases where sys mapped CPC registers need to be accessed
    frequently, it helps immensly to pre-map them rather than map
    and unmap for each operation. e.g. case where feedback counters
    are sys mem map registers.

    Restructure cpc_read/write and the cpc_regs structure to allow
    pre-mapping the system addresses and unmap them when the CPU exits.

    Signed-off-by: Ashwin Chaugule
    Signed-off-by: Prashanth Prakash
    Signed-off-by: Rafael J. Wysocki

    Ashwin Chaugule
     

25 Jun, 2016

1 commit


03 Feb, 2016

1 commit


13 Oct, 2015

1 commit

  • CPPC stands for Collaborative Processor Performance Controls
    and is defined in the ACPI v5.0+ spec. It describes CPU
    performance controls on an abstract and continuous scale
    allowing the platform (e.g. remote power processor) to flexibly
    optimize CPU performance with its knowledge of power budgets
    and other architecture specific knowledge.

    This patch adds a shim which exports commonly used functions
    to get and set CPPC specific controls for each CPU. This enables
    CPUFreq drivers to gather per CPU performance data and use
    with exisiting governors or even allows for customized governors
    which are implemented inside CPUFreq drivers.

    Signed-off-by: Ashwin Chaugule
    Reviewed-by: Al Stone
    Signed-off-by: Rafael J. Wysocki

    Ashwin Chaugule