summaryrefslogtreecommitdiff
path: root/kernel (follow)
Commit message (Collapse)AuthorAge
...
* | | smp: Allow booting a specific subset of CPUsStepan Moskovchenko2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In a heterogenous multiprocessor system, specifying the 'maxcpus' parameter on the kernel command line does not provide sufficient control over which CPUs are brought online at kernel boot time, since CPUs may have nonuniform performance characteristics. Thus, we introduce a 'boot_cpus' command line argument, allowing the user to explicitly specify the list of CPUs that shall be brought online during kernel boot. Change-Id: I5f119e23202660941fa7be8c4e6dd91a82365451 Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org> [abhimany: resolve trivial merge conflicts] Signed-off-by: Abhimanyu Kapur <abhimany@codeaurora.org>
* | | lpm-levels: Do not disable non-sec interrupts in suspendMurali Nalajala2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the system suspend is happening, last core disables the non-sec interrupts at QGIC by setting the GRPEN1_EL1_NS to ZERO. This makes core not seen any non-sec interrupts and would result into system do not wake up from any of interrupts. Do not touch GRPEN1_EL1_NS register while system is going into suspend. Change-Id: I7d6c5047fb4743df187fe49fba18b64db3179bc9 Signed-off-by: Murali Nalajala <mnalajal@codeaurora.org> Conflicts: drivers/irqchip/irq-gic-common.h
* | | cpuidle: lpm-levels: Fixes for clockevents_notifyMahesh Sivasubramanian2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | The use of clockevents_notify is deprcated and targeted APIs are used instead of the clockevents_notify callbacks. Switch broadcast timer notifications to tick_broadcast_enter and tick_broadcast_exit. Change-Id: I3441873eb4009b105db04f4a18d28ae9ccd07e95
* | | cpu_pm: Add level to the cluster pm notificationMurali Nalajala2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cluster pm notifications without level information increases difficulty and complexity for the registered drivers to figure out when the last coherency level is going into power collapse. Send notifications with level information that allows the registered drivers to easily determine the cluster level that is going in/out of power collapse. There is an issue with this implementation. GIC driver saves and restores the distributed registers as part of cluster notifications. On newer platforms there are multiple cluster levels are defined (e.g l2, cci etc). These cluster level notofications can happen independently. On MSM platforms GIC is still active while the cluster sleeps in idle, causing the GIC state to be overwritten with an incorrect previous state of the interrupts. This leads to a system hang. Do not save and restore on any L2 and higher cache coherency level sleep entry and exit. Change-Id: I31918d6383f19e80fe3b064cfaf0b55e16b97eb6 Signed-off-by: Archana Sathyakumar <asathyak@codeaurora.org> Signed-off-by: Murali Nalajala <mnalajal@codeaurora.org> Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org> Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
* | | block/fs: keep track of the task that dirtied the pageVenkat Gopalakrishnan2016-03-22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Background writes happen in the context of a background thread. It is very useful to identify the actual task that generated the request instead of background task that submited the request. Hence keep track of the task when a page gets dirtied and dump this task info while tracing. Not all the pages in the bio are dirtied by the same task but most likely it will be, since the sectors accessed on the device must be adjacent. Change-Id: I6afba85a2063dd3350a0141ba87cf8440ce9f777 Signed-off-by: Venkat Gopalakrishnan <venkatg@codeaurora.org> [venkatg@codeaurora.org: Fixed trivial merge conflicts] Signed-off-by: Venkat Gopalakrishnan <venkatg@codeaurora.org>
* | | qos: Add support for PM_QOS_SUM typeMahesh Sivasubramanian2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | PM_QOS_SUM is a new enum type supported in the upstream kernel. The target qos value for PM_QOS_SUM type is updated as the sum of all the priorities that are applicable to the current CPU. Change-Id: I89152db4fbbf08db113b52e6c5fee4aba9b70933 Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org>
* | | qos: Pass the list of cpus with affected qos to notifierMahesh Sivasubramanian2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Send the list of cpus whose qos has been affected along with the changed value. Driver listening in for notifier can use this to apply the qos value for the respective cpus. Change-Id: I8f3c2ea624784c806c55de41cc7c7fcf8ebf02da Signed-off-by: Mahesh Sivasubramanian <msivasub@codeaurora.org> [mattw@codeaurora.org: resolve trivial context conflicts] Signed-off-by: Matt Wagantall <mattw@codeaurora.org> Conflicts: kernel/power/qos.c
* | | QoS: Enhance framework to support cpu/irq specific QoS requestsPraveen Chidambaram2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QoS request for CPU_DMA_LATENCY can be better optimized if the request can be set only for the required cpus and not all cpus. This helps save power on other cores, while still gauranteeing the quality of service. Enhance the QoS constraints data structures to support target value for each core. Requests specify if the QoS is applicable to all cores (default) or to a selective subset of the cores or to a core(s), that the IRQ is affine to. QoS requests that need to track an IRQ can be set to apply only on the cpus to which the IRQ's smp_affinity attribute is set to. The QoS framework will automatically track IRQ migration between the cores. The QoS is updated to be applied only to the core(s) that the IRQ has been migrated to. Idle and interested drivers can request a PM QoS value for a constraint across all cpus, or a specific cpu or a set of cpus. Separate APIs have been added to request for individual cpu or a cpumask. The default behaviour of PM QoS is maintained i.e, requests that do not specify a type of the request will continue to be effected on all cores. Requests that want to specify an affinity of cpu(s) or an irq, can modify the PM QoS request data structures by specifying the type of the request and either the mask of the cpus or the IRQ number depending on the type. Updating the request does not reset the type of the request. The userspace sysfs interface does not support CPU/IRQ affinity. Change-Id: I09ae85a1e8585d44440e86d63504ad734e8e3e36 Signed-off-by: Praveen Chidambaram <pchidamb@codeaurora.org> Conflicts: kernel/power/qos.c
* | | QoS: Modify data structures and function arguments for scalability.Praveen Chidambaram2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QoS add requests uses a handle to the priority list that is used internally to save the request, but this does not extend well. Also, dev_pm_qos structure definition seems to use a list object directly. The 'derivative' relationship seems to be broken. Use pm_qos_request objects instead of passing around the protected priority list object. Change-Id: Ie4c9c22dd4ea13265fe01f080ba68cf77d9d484d Signed-off-by: Praveen Chidambaram <pchidamb@codeaurora.org> [mattw@codeaurora.org: resolve context conflicts and extend struct modifications to additional affected users] Signed-off-by: Matt Wagantall <mattw@codeaurora.org> Conflicts: include/linux/pm_qos.h
* | | trace: rtb: disable RTB in the first panic notifierSe Wang (Patrick) Oh2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As the priority of RTB panic notifier was zero, it was not guaranteed to disable RTB right after kernel panic. So RTB log buffer could be flooded with some I/O operations after panic. By setting the priority of RTB panic notifier to the highest value, make sure RTB is disabled right after a kernel panic. Change-Id: If9efc2ec31efa6aa17e92b2b01e81ab4df6d1730 Signed-off-by: Se Wang (Patrick) Oh <sewango@codeaurora.org>
* | | msm: rtb: Add timestamp to rtb loggingVignesh Radhakrishnan2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | RTB logging currently doesn't log the time at which the logging was done. This can be useful to compare with dmesg during debug. The bytes for timestamp are taken by reducing the sentinel array size to three from eleven thus giving the extra 8 bytes to store time. This maintains the size of the layout at 32. Change-Id: Ifc7e4d2e89ed14d2a97467891ebefa9515983630 Signed-off-by: Vignesh Radhakrishnan <vigneshr@codeaurora.org>
* | | trace: rtb: add msm_rtb register tracing feature snapshotMatt Wagantall2016-03-01
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This snapshot is taken as of msm-3.10 commit: 78c36fa0ef (Merge "msm: mdss: Prevent backlight update during continuous splash") RTB support captures system events such as register writes to a small uncached region. This is designed to aid in debugging, where it may be useful to know the last events that occurred prior to a device reset. Change-Id: Idc51e618380f58a6803f40c47f2b3d29033b3196 Signed-off-by: Matt Wagantall <mattw@codeaurora.org> [spjoshi@codeaurora.org: fix merge conflict] Signed-off-by: Sarangdhar Joshi <spjoshi@codeaurora.org>
* | | sysctl: add boot_reason and cold_boot sysctl entries for arm64David Collins2016-03-01
| |/ |/| | | | | | | | | | | | | | | | | | | | | | | Define boot_reason and cold_boot variables in the arm64 version of setup.c so that arm64 targets can export the boot_reason and cold_boot sysctl entries. This feature is required by the qpnp-power-on driver. Change-Id: Id2d4ff5b8caa2e6a35d4ac61e338963d602c8b84 Signed-off-by: David Collins <collinsd@codeaurora.org> [osvaldob: resolved trival merge conflicts] Signed-off-by: Osvaldo Banuelos <osvaldob@codeaurora.org>
* | hardlockup: detect hard lockups without NMIs using secondary cpusColin Cross2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Emulate NMIs on systems where they are not available by using timer interrupts on other cpus. Each cpu will use its softlockup hrtimer to check that the next cpu is processing hrtimer interrupts by verifying that a counter is increasing. This patch is useful on systems where the hardlockup detector is not available due to a lack of NMIs, for example most ARM SoCs. Without this patch any cpu stuck with interrupts disabled can cause a hardware watchdog reset with no debugging information, but with this patch the kernel can detect the lockup and panic, which can result in useful debugging info. Change-Id: Ia5faf50243e19c1755201212e04c8892d929785a Signed-off-by: Colin Cross <ccross@android.com>
* | FROMLIST: mm: mmap: Add new /proc tunable for mmap_base ASLR.dcashman2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | (cherry picked from commit https://lkml.org/lkml/2015/12/21/337) ASLR only uses as few as 8 bits to generate the random offset for the mmap base address on 32 bit architectures. This value was chosen to prevent a poorly chosen value from dividing the address space in such a way as to prevent large allocations. This may not be an issue on all platforms. Allow the specification of a minimum number of bits so that platforms desiring greater ASLR protection may determine where to place the trade-off. Bug: 24047224 Signed-off-by: Daniel Cashman <dcashman@android.com> Signed-off-by: Daniel Cashman <dcashman@google.com> Change-Id: Ibf9ed3d4390e9686f5cc34f605d509a20d40e6c2
* | mm: private anonymous memory build fixes for 4.4Amit Pundir2016-02-16
| | | | | | | | | | | | | | | | | | | | Update vma_merge() call in private anonymous memory prctl, introduced in AOSP commit ee8c5f78f09a "mm: add a field to store names for private anonymous memory", so as to align with changes from upstream commit 19a809afe2fe "userfaultfd: teach vma_merge to merge across vma->vm_userfaultfd_ctx". Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
* | mm: add a field to store names for private anonymous memoryColin Cross2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Userspace processes often have multiple allocators that each do anonymous mmaps to get memory. When examining memory usage of individual processes or systems as a whole, it is useful to be able to break down the various heaps that were allocated by each layer and examine their size, RSS, and physical memory usage. This patch adds a user pointer to the shared union in vm_area_struct that points to a null terminated string inside the user process containing a name for the vma. vmas that point to the same address will be merged, but vmas that point to equivalent strings at different addresses will not be merged. Userspace can set the name for a region of memory by calling prctl(PR_SET_VMA, PR_SET_VMA_ANON_NAME, start, len, (unsigned long)name); Setting the name to NULL clears it. The names of named anonymous vmas are shown in /proc/pid/maps as [anon:<name>] and in /proc/pid/smaps in a new "Name" field that is only present for named vmas. If the userspace pointer is no longer valid all or part of the name will be replaced with "<fault>". The idea to store a userspace pointer to reduce the complexity within mm (at the expense of the complexity of reading /proc/pid/mem) came from Dave Hansen. This results in no runtime overhead in the mm subsystem other than comparing the anon_name pointers when considering vma merging. The pointer is stored in a union with fieds that are only used on file-backed mappings, so it does not increase memory usage. Includes fix from Jed Davis <jld@mozilla.com> for typo in prctl_set_vma_anon_name, which could attempt to set the name across two vmas at the same time due to a typo, which might corrupt the vma list. Fix it to use tmp instead of end to limit the name setting to a single vma at a time. Change-Id: I9aa7b6b5ef536cd780599ba4e2fba8ceebe8b59f Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
* | add extra free kbytes tunableRik van Riel2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add a userspace visible knob to tell the VM to keep an extra amount of memory free, by increasing the gap between each zone's min and low watermarks. This is useful for realtime applications that call system calls and have a bound on the number of allocations that happen in any short time period. In this application, extra_free_kbytes would be left at an amount equal to or larger than than the maximum number of allocations that happen in any burst. It may also be useful to reduce the memory use of virtual machines (temporarily?), in a way that does not cause memory fragmentation like ballooning does. [ccross] Revived for use on old kernels where no other solution exists. The tunable will be removed on kernels that do better at avoiding direct reclaim. Change-Id: I765a42be8e964bfd3e2886d1ca85a29d60c3bb3e Signed-off-by: Rik van Riel<riel@redhat.com> Signed-off-by: Colin Cross <ccross@android.com>
* | ARM: Fix "Make low-level printk work" to use a separate config optionArve Hjønnevåg2016-02-16
| | | | | | | | | | Change-Id: I5ca8db61b595adc642a07ea187bd41fd7636840e Signed-off-by: Arve Hjønnevåg <arve@android.com>
* | panic: Add board ID to panic outputNishanth Menon2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | At times, it is necessary for boards to provide some additional information as part of panic logs. Provide information on the board hardware as part of panic logs. It is safer to print this information at the very end in case something bad happens as part of the information retrieval itself. To use this, set global mach_panic_string to an appropriate string in the board file. Change-Id: Id12cdda87b0cd2940dd01d52db97e6162f671b4d Signed-off-by: Nishanth Menon <nm@ti.com>
* | ARM: Make low-level printk workTony Lindgren2016-02-16
| | | | | | | | | | | | Makes low-level printk work. Signed-off-by: Tony Lindgren <tony@atomide.com>
* | proc: smaps: Allow smaps access for CAP_SYS_RESOURCESan Mehat2016-02-16
| | | | | | | | Signed-off-by: San Mehat <san@google.com>
* | prctl: make PR_SET_TIMERSLACK_PID pid namespace awareMicha Kalfon2016-02-16
| | | | | | | | | | | | | | | | | | | | Make PR_SET_TIMERSLACK_PID consider pid namespace and resolve the target pid in the caller's namespace. Otherwise, calls from pid namespace other than init would fail or affect the wrong task. Change-Id: I1da15196abc4096536713ce03714e99d2e63820a Signed-off-by: Micha Kalfon <micha@cellrox.com> Acked-by: Oren Laadan <orenl@cellrox.com>
* | prctl: fix misplaced PR_SET_TIMERSLACK_PID caseMicha Kalfon2016-02-16
| | | | | | | | | | | | | | | | | | | | The case clause for the PR_SET_TIMERSLACK_PID option was placed inside the an internal switch statement for PR_MCE_KILL (see commits 37a591d4 and 8ae872f1) . This commit moves it to the right place. Change-Id: I63251669d7e2f2aa843d1b0900e7df61518c3dea Signed-off-by: Micha Kalfon <micha@cellrox.com> Acked-by: Oren Laadan <orenl@cellrox.com>
* | prctl: adds the capable(CAP_SYS_NICE) check to PR_SET_TIMERSLACK_PID.Ruchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | | | Adds a capable() check to make sure that arbitary apps do not change the timer slack for other apps. Bug: 15000427 Change-Id: I558a2551a0e3579c7f7e7aae54b28aa9d982b209 Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
* | prctl: adds PR_SET_TIMERSLACK_PID for setting timer slack of an arbitrary ↵Ruchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | thread. Second argument is similar to PR_SET_TIMERSLACK, if non-zero then the slack is set to that value otherwise sets it to the default for the thread. Takes PID of the thread as the third argument. This allows power/performance management software to set timer slack for other threads according to its policy for the thread (such as when the thread is designated foreground vs. background activity) Change-Id: I744d451ff4e60dae69f38f53948ff36c51c14a3f Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
* | cgroup: refactor allow_attach handler for 4.4Amit Pundir2016-02-16
| | | | | | | | | | | | | | | | Refactor *allow_attach() handler to align it with the changes from mainline commit 1f7dd3e5a6e4 "cgroup: fix handling of multi-destination migration from subtree_control enabling". Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
* | cgroup: fix cgroup_taskset_for_each call in allow_attach() for 4.1Dmitry Shmidt2016-02-16
| | | | | | | | | | Change-Id: I05013f6e76c30b0ece3671f9f2b4bbdc626cd35c Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
* | Fix generic cgroup subsystem permission checksChristian Poetzsch2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In 53b5e2f generic cgroup subsystem permission checks have been added. When this is been done within procs_write an empty taskset is added to the tasks css set. When a task later on migrates to a new group we see a dmesg warning cause the mg_node isn't empty (cgroup.c:2086). Cause this happens all the time this spams dmesg. I am not really familiar with this code, but it looks to me like adding the taskset is just a temporary action in this context. Therefore this taskset should be removed after the actual check. This is what this fix does. This problem was seen and the fix tested on x86 using l-mr1 and master. Change-Id: I9894d39e8b5692ef65149002b07e65a84a33ffea Signed-off-by: Christian Poetzsch <christian.potzsch@imgtec.com>
* | cgroup: Fix issues in allow_attach callbackRom Lemarchand2016-02-16
| | | | | | | | | | | | | | | | - Return -EINVAL when cgroups support isn't enabled - Add allow_attach callback in CPU cgroups Change-Id: Id3360b4a39919524fc4b6fcbd44fa2050009f000 Signed-off-by: Rom Lemarchand <romlem@android.com>
* | cgroup: Add generic cgroup subsystem permission checksColin Cross2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Rather than using explicit euid == 0 checks when trying to move tasks into a cgroup via CFS, move permission checks into each specific cgroup subsystem. If a subsystem does not specify a 'allow_attach' handler, then we fall back to doing our checks the old way. Use the 'allow_attach' handler for the 'cpu' cgroup to allow non-root processes to add arbitrary processes to a 'cpu' cgroup if it has the CAP_SYS_NICE capability set. This version of the patch adds a 'allow_attach' handler instead of reusing the 'can_attach' handler. If the 'can_attach' handler is reused, a new cgroup that implements 'can_attach' but not the permission checks could end up with no permission checks at all. Change-Id: Icfa950aa9321d1ceba362061d32dc7dfa2c64f0c Original-Author: San Mehat <san@google.com> Signed-off-by: Colin Cross <ccross@android.com>
* | cgroup: refactor allow_attach function into common codeRom Lemarchand2016-02-16
| | | | | | | | | | | | | | | | | | | | move cpu_cgroup_allow_attach to a common subsys_cgroup_allow_attach. This allows any process with CAP_SYS_NICE to move tasks across cgroups if they use this function as their allow_attach handler. Bug: 18260435 Change-Id: I6bb4933d07e889d0dc39e33b4e71320c34a2c90f Signed-off-by: Rom Lemarchand <romlem@android.com>
* | wakeup_reason: use vsnprintf instead of snsprintf for vargs.Ruchi Kandoi2016-02-16
| | | | | | | | | | Bug: 22368519 Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
* | power: wakeup_reason: fix suspend time reportingAmit Pundir2016-02-16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Suspend time reporting Change-Id: I2cb9a9408a5fd12166aaec11b935a0fd6a408c63 (Power: Report suspend times from last_suspend_time), is broken on 3.16+ kernels because get_xtime_and_monotonic_and_sleep_offset() hrtimer helper routine is removed from kernel timekeeping. The replacement helper routines ktime_get_update_offsets_{tick,now}() are private to core kernel timekeeping so we can't use them, hence using ktime_get() and ktime_get_boottime() instead and sampling the time twice. Idea is to use Monotonic boottime offset to calculate total time spent in last suspend state and CLOCK_MONOTONIC to calculate time spent in last suspend-resume process. Signed-off-by: Amit Pundir <amit.pundir@linaro.org>
* | Power: Report suspend times from last_suspend_timejinqian2016-02-16
| | | | | | | | | | | | | | | | | | This node epxorts two values separated by space. From left to right: 1. time spent in suspend/resume process 2. time spent sleep in suspend state Change-Id: I2cb9a9408a5fd12166aaec11b935a0fd6a408c63
* | power: Remove HAS_WAKELOCK config and document WAKELOCKDylan Reid2016-02-16
| | | | | | | | | | | | | | | | | | | | Remove the HAS_WAKELOCK config as it doesn't seem to have been used in the 3.10 or 3.14 kernels. Add some Documentation to CONFIG_WAKELOCK so that it is selectable and can be disabled is desired. Signed-off-by: Dylan Reid <dgreid@chromium.org>
* | Make suspend abort reason logging depend on CONFIG_PM_SLEEPLorenzo Colitti2016-02-16
| | | | | | | | | | | | | | | | This unbreaks the build on architectures such as um that do not support CONFIG_PM_SLEEP. Change-Id: Ia846ed0a7fca1d762ececad20748d23610e8544f Signed-off-by: Lorenzo Colitti <lorenzo@google.com>
* | power: Add check_wakeup_reason() to verify wakeup source irqDmitry Shmidt2016-02-16
| | | | | | | | | | | | | | | | | | Wakeup reason is set before driver resume handlers are called. It is cleared before driver suspend handlers are called, on PM_SUSPEND_PREPARE. Change-Id: I04218c9b0c115a7877e8029c73e6679ff82e0aa4 Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
* | power: Adds functionality to log the last suspend abort reason.Ruchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | | | Extends the last_resume_reason to log suspend abort reason. The abort reasons will have "Abort:" appended at the start to distinguish itself from the resume reason. Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com> Change-Id: I3207f1844e3d87c706dfc298fb10e1c648814c5f
* | power: Avoids bogus error messages for the suspend aborts.Ruchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | Avoids printing bogus error message "tasks refusing to freeze", in cases where pending wakeup source caused the suspend abort. Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com> Change-Id: I913ad290f501b31cd536d039834c8d24c6f16928
* | Power: Changes the permission to read only for sysfs file ↵Ruchi Kandoi2016-02-16
| | | | | | | | | | | | | | /sys/kernel/wakeup_reasons/last_resume_reason Change-Id: I8ac568a7cb58c31decd379195de517ff3c6f9c65 Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
* | power: wakeup_reason: rename irq_count to irqcountGreg Hackmann2016-02-16
| | | | | | | | | | | | | | | | On x86, irq_count conflicts with a declaration in arch/x86/include/asm/processor.h Change-Id: I3e4fde0ff64ef59ff5ed2adc0ea3a644641ee0b7 Signed-off-by: Greg Hackmann <ghackmann@google.com>
* | Power: Add guard condition for maximum wakeup reasonsRuchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | Ensure the array for the wakeup reason IRQs does not overflow. Change-Id: Iddc57a3aeb1888f39d4e7b004164611803a4d37c Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com> (cherry picked from commit b5ea40cdfcf38296535f931a7e5e7bf47b6fad7f)
* | POWER: fix compile warnings in log_wakeup_reasonRuchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | Change I81addaf420f1338255c5d0638b0d244a99d777d1 introduced compile warnings, fix these. Change-Id: I05482a5335599ab96c0a088a7d175c8d4cf1cf69 Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
* | Power: add an API to log wakeup reasonsRuchi Kandoi2016-02-16
| | | | | | | | | | | | | | | | Add API log_wakeup_reason() and expose it to userspace via sysfs path /sys/kernel/wakeup_reasons/last_resume_reason Change-Id: I81addaf420f1338255c5d0638b0d244a99d777d1 Signed-off-by: Ruchi Kandoi <kandoiruchi@google.com>
* | PM / Suspend: Print wall time at suspend entry and exitTodd Poynor2016-02-16
| | | | | | | | | | Change-Id: I92f252414c013b018b9a392eae1ee039aa0e89dc Signed-off-by: Todd Poynor <toddpoynor@google.com>
* | tracing/sched: Add trace events to track cpu hotplug.Arun Bharadwaj2016-02-16
| | | | | | | | | | | | | | | | | | | | | | Add ftrace event trace_sched_cpu_hotplug to track cpu hot-add and hot-remove events. This is useful in a variety of power, performance and debug analysis scenarios. Change-Id: I5d202c7a229ffacc3aafb7cf9afee0b0ee7b0931 Signed-off-by: Arun Bharadwaj <abharadw@codeaurora.org>
* | trace: fix compilation for 4.1Dmitry Shmidt2016-02-16
| | | | | | | | | | Change-Id: Id88b5d30847bc6d3cfe1d8cd00cbdc975c9712d1 Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
* | trace: add non-hierarchical function_graph optionJamie Gennis2016-02-16
| | | | | | | | | | | | | | | | Add the 'funcgraph-flat' option to the function_graph tracer to use the default trace printing format rather than the hierarchical formatting normally used. Change-Id: If2900bfb86e6f8f51379f56da4f6fabafa630909 Signed-off-by: Jamie Gennis <jgennis@google.com>
* | trace: Add an option to show tgids in trace outputJamie Gennis2016-02-16
| | | | | | | | | | | | | | | | | | | | The tgids are tracked along side the saved_cmdlines tracking, and can be included in trace output by enabling the 'print-tgid' trace option. This is useful when doing post-processing of the trace data, as it allows events to be grouped by tgid. Change-Id: I52ed04c3a8ca7fddbb868b792ce5d21ceb76250e Signed-off-by: Jamie Gennis <jgennis@google.com>