Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Linux linaro lsk v3.14 mx6 thermal #24

Merged

Commits on Nov 26, 2014

  1. thermal: Add braces around suspect code

    It looks like this code is missing braces, otherwise the if
    statement shouldn't have been indented. Fix it.
    
    Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
    Signed-off-by: Zhang Rui <rui.zhang@intel.com>
    bebarino authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    3f41dc2 View commit details
    Browse the repository at this point in the history
  2. thermal: Bind cooling devices with the correct arguments

    When binding cooling devices to thermal zones created from the device
    tree the minimum and maximum cooling states are in the wrong order
    leading to failure to bind.
    
    Fix the order of cooling states in the call to
    thermal_zone_bind_cooling_device to fix this.
    
    Cc:Zhang Rui <rui.zhang@intel.com>
    Signed-off-by: Punit Agrawal <punit.agrawal@arm.com>
    Reviewed-by: Stephen Boyd <sboyd@codeaurora.org>
    Signed-off-by: Zhang Rui <rui.zhang@intel.com>
    punitagrawal authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    f16fa8e View commit details
    Browse the repository at this point in the history
  3. thermal: imx: update formula for thermal sensor

    Thermal sensor used to need two calibration points which are
    in fuse map to get a slope for converting thermal sensor's raw
    data to real temperature in degree C. Due to the chip calibration
    limitation, hardware team provides an universal formula to get
    real temperature from internal thermal sensor raw data:
    
    Slope = 0.4297157 - (0.0015976 * 25C fuse);
    
    Update the formula, as there will be no hot point calibration
    data in fuse map from now on.
    
    Signed-off-by: Anson Huang <b20788@freescale.com>
    Acked-by: Shawn Guo <shawn.guo@linaro.org>
    Signed-off-by: Zhang Rui <rui.zhang@intel.com>
    Anson Huang authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    2b1601b View commit details
    Browse the repository at this point in the history
  4. Thermal: imx: correct critical trip temperature setting

    On latest i.MX6 SOC with thermal calibration data of 0x5A100000,
    the critical trip temperature will be an invalid value and
    cause system auto shutdown as below log:
    
    thermal thermal_zone0: critical temperature reached(42 C),shutting down
    
    So, with universal formula for thermal sensor, only room
    temperature point is calibrated, which means the calibration
    data read from fuse only has valid data of bit [31:20], others
    are all 0, the critical trip point temperature can NOT depend
    on the hot point calibration data, here we set it to 20 C higher
    than default passive temperature.
    
    Signed-off-by: Anson Huang <b20788@freescale.com>
    Acked-by: Shawn Guo <shawn.guo@linaro.org>
    Signed-off-by: Zhang Rui <rui.zhang@intel.com>
    Anson Huang authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    1d484d2 View commit details
    Browse the repository at this point in the history
  5. thermal: trace: Trace temperature changes

    Create a new event to trace the temperature of a thermal zone. Using
    this event trace the temperature changes of the thermal zone every-time
    it is updated.
    
    Cc: Zhang Rui <rui.zhang@intel.com>
    Cc: Eduardo Valentin <edubezval@gmail.com>
    Cc: Steven Rostedt <rostedt@goodmis.org>
    Cc: Frederic Weisbecker <fweisbec@gmail.com>
    Cc: Ingo Molnar <mingo@redhat.com>
    Signed-off-by: Punit Agrawal <punit.agrawal@arm.com>
    Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
    punitagrawal authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    d735911 View commit details
    Browse the repository at this point in the history
  6. thermal: trace: Trace when a cooling device's state is updated

    Introduce and use an event to trace when a cooling device's state is
    updated. This is useful to follow the effect of governor decisions on
    cooling devices.
    
    Cc: Zhang Rui <rui.zhang@intel.com>
    Cc: Eduardo Valentin <edubezval@gmail.com>
    Cc: Steven Rostedt <rostedt@goodmis.org>
    Cc: Frederic Weisbecker <fweisbec@gmail.com>
    Cc: Ingo Molnar <mingo@redhat.com>
    Signed-off-by: Punit Agrawal <punit.agrawal@arm.com>
    Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
    punitagrawal authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    fbdc9d6 View commit details
    Browse the repository at this point in the history
  7. thermal: trace: Trace when temperature is above a trip point

    Create a new event to trace when the temperature is above a trip
    point. Use the trace-point when handling non-critical and critical
    trip pionts.
    
    Cc: Zhang Rui <rui.zhang@intel.com>
    Cc: Eduardo Valentin <edubezval@gmail.com>
    Cc: Steven Rostedt <rostedt@goodmis.org>
    Cc: Frederic Weisbecker <fweisbec@gmail.com>
    Cc: Ingo Molnar <mingo@redhat.com>
    Signed-off-by: Punit Agrawal <punit.agrawal@arm.com>
    Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
    punitagrawal authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    458d18c View commit details
    Browse the repository at this point in the history
  8. Thermal:Remove usless if(!result) before return tz

    result is always zero when comes here.
    
    Signed-off-by: Yao Dongdong <yaodongdong@huawei.com>
    Acked-by: Eduardo Valentin <edubezval@gmail.com>
    Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
    Yao Dongdong authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    dbf8e94 View commit details
    Browse the repository at this point in the history
  9. thermal: imx: correct driver load sequence for cpu cooling

    thermal driver should be regisetered after cpufreq driver has
    been registered and probed. Doing so is to make sure that thermal
    driver can get the max cpu cooling states correctly when calling
    get_property.
    
    Signed-off-by: Bai Ping <b51503@freescale.com>
    Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
    Bai Ping authored and linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    2c61c01 View commit details
    Browse the repository at this point in the history
  10. thermal: imx_thermal: Second cooling device uses devfreq driver

    The second cooling device was being registered as another cpu
    frequency device.  This is incorrect register it as a device
    frequency device.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    3694c1a View commit details
    Browse the repository at this point in the history
  11. thermal: imx_thermal: re-org the _probe function to fix unbalanced in…

    …terrupts
    
    Initializing the thermal_device causes get_temp to get called which in turns
    tries to enable interrupts.  Move clock code and the enable_irq setting
    up in the probe function to get rid of the kernel warnings on boot.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    8398747 View commit details
    Browse the repository at this point in the history
  12. thermal: imx_thermal: Add a trip point for each cpu_freq state

    The driver currently would only trip at 85C and then bring the
    SOC and GPU down to the slowest speeds until it reached 75C.
    
    Now we read the number of cpufreq states and spread out trip points
    between 85C and critical temp.  At each trip point we drop the
    top cpufrequency down and don't raise it again until the temp is
    lower than the previous zones trip point.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    d748dbb View commit details
    Browse the repository at this point in the history
  13. thermal: step_wise: Add and fix debug output

    Add some additional debug output to track the changes being
    detected by the driver.  Also fix the typing of some variables
    to verify that they print out properly in the debug output.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    9963c50 View commit details
    Browse the repository at this point in the history
  14. thermal: devfreq_cooling: Allow max_states to be variable

    This allows max_state to be set at the time the devfreq cooling
    device is instantiated.  This allows events to match the cpufreq
    cooling device and gives tighter grained control over the
    devices listening.
    
    Currently I am using state 5 as the critical event number.  This
    could be dynamic as well but since only the imx_thermal and galcore
    use this driver I am okay hardcoding it for testing.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    d971414 View commit details
    Browse the repository at this point in the history
  15. thermal: imx_thermal: Set max_events for devfreq_cooling

    Tell the devfreq device how many cooling states it will have.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    72fe282 View commit details
    Browse the repository at this point in the history
  16. gpu: galcore: Handle additional cooling information

    Rather than just scaling down the GPU's 3D core to the slowest
    speed at the first passive cooling trip point, we slowly scale back
    the core clock speed trying to achieve balance.  If we reach the
    critical speed we scale all the way back to the lowest freq.
    
    *TEST* the divider number is completely guestimated and needs to be
    tested.
    linux4kix committed Nov 26, 2014
    Configuration menu
    Copy the full SHA
    0424f6a View commit details
    Browse the repository at this point in the history

Commits on Dec 17, 2014

  1. char: fsl_otp: Enable kernel config option to enable write support

    Write access to the fuses is very dangerous as they can only be
    written once.  This is the first commit in locking this down a bit.
    Now you must explicitely enable this functionality in the kernel.
    linux4kix committed Dec 17, 2014
    Configuration menu
    Copy the full SHA
    4e02d4b View commit details
    Browse the repository at this point in the history
  2. char: fsl_otp: Add function to read otp values

    Instead of having all drivers mapping the otp memory and checking
    values provide a function so they can do it through the driver.
    linux4kix committed Dec 17, 2014
    Configuration menu
    Copy the full SHA
    5e36f29 View commit details
    Browse the repository at this point in the history
  3. mach: imx: Use fsl_otp helper function

    Instead of checking device-tree for the otp definition and mapping
    memory ourselves, use the new helper function to read fuse values.
    linux4kix committed Dec 17, 2014
    Configuration menu
    Copy the full SHA
    c019307 View commit details
    Browse the repository at this point in the history
  4. thermal: imx: Rework driver for better flexibility

    This should probably be broken up into multiple patches but I will
    do that when I get them ready for upstreaming.  Functionality that
    I have added is follows.
    
    - read grade of chip from otp and set critical based on this value.
    - base the default passive trip points based on the number of cpu
    frequency points and the critical thermal temperature.
    - allow the user to change the trip_point0 up to a maximum of 85c
    and then scale the trip points based on that.
    linux4kix committed Dec 17, 2014
    Configuration menu
    Copy the full SHA
    212c17d View commit details
    Browse the repository at this point in the history