Re: Problem with atomic accesses in pstore on some ARM CPUs

2016-08-16 Thread Colin Cross
On Mon, Aug 15, 2016 at 3:15 PM, Mark Rutland wrote: > On Tue, Aug 16, 2016 at 08:02:53AM -0700, Guenter Roeck wrote: >> On Tue, Aug 16, 2016 at 6:21 AM, Will Deacon wrote: >> > On Tue, Aug 16, 2016 at 06:14:53AM -0700, Guenter Roeck wrote: >> >> On Tue, Aug 16, 2016 at 3:32 AM, Robin Murphy >>

Re: Severe performance regression w/ 4.4+ on Android due to cgroup locking changes

2016-07-13 Thread Colin Cross
On Wed, Jul 13, 2016 at 11:21 AM, Tejun Heo wrote: > (cc'ing Oleg) > > Hello, > > On Tue, Jul 12, 2016 at 05:00:04PM -0700, John Stultz wrote: >> So Dmitry Shmidt recently noticed that with 4.4 based systems we're >> seeing quite a bit of performance overhead from >> __cgroup_procs_write(). >> >

Re: [PATCH] ion: scatterlist offset not used for buffer map

2016-04-08 Thread Colin Cross
On Thu, Apr 7, 2016 at 11:56 PM, John Einar Reitan wrote: > On Thu, Apr 07, 2016 at 12:37:50PM -0700, Laura Abbott wrote: >> On 04/07/2016 04:29 AM, John Einar Reitan wrote: >> > ion's default user/kernel page mapping code don't honor the offset >> > option for scatterlists. It uses sg_page and ex

VM_GROWSDOWN and fixed size stacks

2016-03-21 Thread Colin Cross
I recently came across some Android userspace code that jumps through some strange hoops to produce a fixed size stack on the main stack (https://android.googlesource.com/platform/art/+/db1f7dac02f6dcecac3e032f10abbcdbf3cf4331/runtime/thread.cc#543). ART (the Android runtime) uses a unified stack f

Re: [PATCH] proc: revert /proc//maps [stack:TID] annotation

2016-01-25 Thread Colin Cross
On Mon, Jan 25, 2016 at 3:14 PM, Kirill A. Shutemov wrote: > On Mon, Jan 25, 2016 at 01:30:00PM -0800, Colin Cross wrote: >> On Tue, Jan 19, 2016 at 3:30 PM, Kirill A. Shutemov >> wrote: >> > On Tue, Jan 19, 2016 at 02:14:30PM -0800, Andrew Morton wrote: >> >>

Re: [PATCH] proc: revert /proc//maps [stack:TID] annotation

2016-01-25 Thread Colin Cross
On Tue, Jan 19, 2016 at 3:30 PM, Kirill A. Shutemov wrote: > On Tue, Jan 19, 2016 at 02:14:30PM -0800, Andrew Morton wrote: >> On Tue, 19 Jan 2016 13:02:39 -0500 Johannes Weiner >> wrote: >> >> > b764375 ("procfs: mark thread stack correctly in proc//maps") >> > added [stack:TID] annotation to /

Re: [PATCH] staging: ion: fix corruption of ion_import_dma_buf

2015-09-09 Thread Colin Cross
On Wed, Sep 9, 2015 at 10:19 AM, Laura Abbott wrote: > (adding Colin and John) > > > On 09/09/2015 12:41 AM, Shawn Lin wrote: >> >> we found this issue but still exit in lastest kernel. Simply >> keep ion_handle_create under mutex_lock to avoid this race. >> >> WARNING: CPU: 2 PID: 2648 at drivers

Re: [RFC PATCH] PM / Runtime: runtime: Add sysfs option for forcing runtime suspend

2015-09-09 Thread Colin Cross
On Wed, Sep 9, 2015 at 1:35 PM, Rafael J. Wysocki wrote: > > On Wednesday, September 09, 2015 11:20:25 AM Alan Stern wrote: > > On Wed, 9 Sep 2015, Rafael J. Wysocki wrote: > > > > > > The best example and actually the very specific problem we want to > > > > solve is handling touchscreens on a ph

Re: [PATCH v2 2/2] staging: ion: chunk_heap: use %pad for printing dma_addr_t's

2015-05-04 Thread Colin Cross
On Mon, May 4, 2015 at 1:22 AM, Dan Carpenter wrote: > On Thu, Apr 09, 2015 at 06:10:04PM -0700, Mitchel Humpherys wrote: >> We're currently using %lu and %ld to print some variables of type >> dma_addr_t, which results in the following warning when dma_addr_t is >> 64-bits wide: >> >> drivers

Re: [RFC v3] debug: prevent entering debug mode on errors

2014-12-01 Thread Colin Cross
On Thu, Nov 27, 2014 at 1:49 AM, Daniel Thompson wrote: > On 26/11/14 17:45, Colin Cross wrote: >> The original patch was more useful as it allowed re-enabling break on >> panic on specific devices where you were trying to debug a >> reproducible issue. What about using a mo

Re: [RFC v3] debug: prevent entering debug mode on errors

2014-11-26 Thread Colin Cross
On Wed, Nov 26, 2014 at 1:14 AM, Kiran Raparthy wrote: > From: Colin Cross > > debug: prevent entering debug mode on errors > > On non-developer devices kgdb prevents CONFIG_PANIC_TIMEOUT from rebooting the > device after a panic. > > In case of panics

Re: [PATCH] ARM: b.L: fix unmet dependency for CPU_PM

2014-11-14 Thread Colin Cross
On Thu, Nov 13, 2014 at 10:10 PM, Pankaj Dubey wrote: > +CC: Colin Cross, James Hogan > > On Thursday, November 13, 2014 11:30 PM, Nicolas Pitre wrote: >> To: Russell King - ARM Linux >> Cc: Pankaj Dubey; linux-arm-ker...@lists.infradead.org; linux- >> ker...@vge

Re: Re: [PATCH 1/1] [ion]: system-heap use PAGE_ALLOC_COSTLY_ORDER for high order

2014-10-07 Thread Colin Cross
On Tue, Oct 7, 2014 at 9:07 AM, PINTU KUMAR wrote: > - Original Message - >> From: Colin Cross >> To: pint...@samsung.com >> Cc: Laura Abbott ; Heesub Shin >> ; "a...@linux-foundation.org" >> ; "gre...@linuxfoundation.org" >

Re: Re: [PATCH 1/1] [ion]: system-heap use PAGE_ALLOC_COSTLY_ORDER for high order

2014-10-06 Thread Colin Cross
On Mon, Oct 6, 2014 at 9:26 AM, PINTU KUMAR wrote: > > Hi, > > > > From: Laura Abbott > >To: Heesub Shin ; Pintu Kumar > >; a...@linux-foundation.org; > >gre...@linuxfoundation.org; john.stu...@linaro.org; rebe...@android.com; > >ccr...@android.com; de...@driver

Re: staging: Unwritten function for ion_carveout_heap.c

2014-07-23 Thread Colin Cross
On Wed, Jul 23, 2014 at 1:04 PM, Nick Krause wrote: > Hey Greg and others. > Sorry for another email but it seems the function, > ion_carveout_heap_unmap_dma is > just returning and not doing anything useful. Furthermore I am new so > I don't known how > to write this function but this may be cau

Re: [PATCH] drivers: staging: android: ion: Kconfig: Let it also depend on HAS_DMA

2014-07-09 Thread Colin Cross
K > + depends on HAVE_MEMBLOCK && HAS_DMA > select GENERIC_ALLOCATOR > select DMA_SHARED_BUFFER > ---help--- > -- > 1.9.2.459.g68773ac Acked-by: Colin Cross -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [PATCH] ARM64: implement TASK_SIZE_OF

2014-06-20 Thread Colin Cross
On Fri, Jun 20, 2014 at 1:25 AM, Will Deacon wrote: > Hi Colin, > > On Wed, Jun 18, 2014 at 09:10:09PM +0100, Colin Cross wrote: >> include/linux/sched.h implements TASK_SIZE_OF as TASK_SIZE if it >> is not set by the architecture headers. TASK_SIZE uses the >> current

Re: [REPOST PATCH 4/8] android: convert sync to fence api, v5

2014-06-19 Thread Colin Cross
On Thu, Jun 19, 2014 at 5:28 AM, Daniel Vetter wrote: > On Thu, Jun 19, 2014 at 1:48 PM, Thierry Reding > wrote: >>> > With these changes, can we pull the android sync logic out of >>> > drivers/staging/ now? >>> >>> Afaik the google guys never really looked at this and acked it. So I'm not >>> s

Re: [REPOST PATCH 4/8] android: convert sync to fence api, v5

2014-06-19 Thread Colin Cross
l fence_remove_callback in sync_fence_free if not all fences have >> > fired. >> > v3: >> > - Merge Colin Cross' bugfixes, and the android fence merge optimization. >> > v4: >> > - Merge with the upstream fixes. >> > v5: >> >

[PATCH] ARM64: implement TASK_SIZE_OF

2014-06-18 Thread Colin Cross
return EOF when it reads past 0x. Implement TASK_SIZE_OF exactly the same as TASK_SIZE with test_tsk_thread_flag instead of test_thread_flag. Cc: sta...@vger.kernel.org Signed-off-by: Colin Cross --- arch/arm64/include/asm/memory.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch

Re: [PATCH] staging: ion: WARN when the handle kmap_cnt is going to wrap around

2014-05-22 Thread Colin Cross
, > hosted by The Linux Foundation > > To unsubscribe from this group and stop receiving emails from it, send an > email to kernel-team+unsubscr...@android.com. Acked-by: Colin Cross -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [RFC v3 1/9] sysrq: Implement __handle_sysrq_nolock to avoid recursive locking in kdb

2014-04-29 Thread Colin Cross
On Tue, Apr 29, 2014 at 1:59 AM, Daniel Thompson wrote: > On 28/04/14 18:44, Colin Cross wrote: >>>> Is that case documented somewhere in the code comments? >>> >>> Perhaps not near enough to the _nolock but the primary bit of comment is >>> here (and

Re: [RFC v3 1/9] sysrq: Implement __handle_sysrq_nolock to avoid recursive locking in kdb

2014-04-28 Thread Colin Cross
On Mon, Apr 28, 2014 at 3:24 AM, Daniel Thompson wrote: > On 25/04/14 17:45, Steven Rostedt wrote: >> On Fri, 25 Apr 2014 17:29:22 +0100 >> Daniel Thompson wrote: >> >>> If kdb is triggered using SysRq-g then any use of the sr command results >>> in the SysRq key table lock being recursively acqu

Re: [PATCH] staging/android: Remove ram_console.h

2014-04-23 Thread Colin Cross
LATFORM_DATA_RAM_CONSOLE_H_ */ > -- > 1.7.9.5 > > > -- > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read

Re: [PATCH] staging : android : uapi : fix coding style

2014-04-16 Thread Colin Cross
(resending without the html) On Wed, Apr 16, 2014 at 9:36 AM, John Stultz wrote: > > On 04/16/2014 07:39 AM, Joe Perches wrote: > > On Wed, 2014-04-16 at 23:27 +0900, Seunghun Lee wrote: > >> This patch fix checkpatch.pl warnings and errors. > > [] > >> diff --git a/drivers/staging/android/uapi/b

Re: [PATCH] dma-buf: avoid using IS_ERR_OR_NULL

2014-02-07 Thread Colin Cross
On Fri, Feb 7, 2014 at 8:43 AM, Greg Kroah-Hartman wrote: > On Sat, Dec 21, 2013 at 07:42:17AM -0500, Rob Clark wrote: >> On Fri, Dec 20, 2013 at 7:43 PM, Colin Cross wrote: >> > dma_buf_map_attachment and dma_buf_vmap can return NULL or >> > ERR_PTR on a error. Thi

[PATCH] security: select correct default LSM_MMAP_MIN_ADDR on arm on arm64

2014-02-03 Thread Colin Cross
Binaries compiled for arm may run on arm64 if CONFIG_COMPAT is selected. Set LSM_MMAP_MIN_ADDR to 32768 if ARM64 && COMPAT to prevent selinux failures launching 32-bit static executables that are mapped at 0x8000. Signed-off-by: Colin Cross --- security/Kconfig | 2 +- 1 file ch

Re: [PATCH 1/7] sched: allow try_to_wake_up to be used internally outside of core.c

2014-01-13 Thread Colin Cross
On Mon, Jan 13, 2014 at 4:31 AM, Maarten Lankhorst wrote: > The kernel fence implementation doesn't use event queues, but needs > to perform the same wake up. The symbol is not exported, since the > fence implementation is not built as a module. > > Signed-off-by: Maarten Lankhorst > --- > inclu

Re: [PATCH] arm: mm: add memory type for inner-writeback

2014-01-07 Thread Colin Cross
On Tue, Jan 7, 2014 at 7:09 AM, Catalin Marinas wrote: > On Fri, Dec 27, 2013 at 04:58:48AM +, Mark Zhang wrote: >> From: Colin Cross >> >> For streaming-style operations (e.g., software rendering of graphics >> surfaces shared with non-coherent DMA devices), t

[PATCH] dma-buf: avoid using IS_ERR_OR_NULL

2013-12-20 Thread Colin Cross
check for NULL, and would have dereferenced an ERR_PTR and panic'd if one was ever returned. This is not consistent with the rest of the dma buf APIs, but matches the expectations of all of the callers. Signed-off-by: Colin Cross --- drivers/base/dma-buf.c

Re: [PATCH] ion_test: Add compat_ioctl support (v2)

2013-12-19 Thread Colin Cross
t; Changes in v2: > - Add a padding int rather then making write a u64 > > Cc: Colin Cross > Cc: Greg KH > Cc: Android Kernel Team > Signed-off-by: John Stultz > --- > drivers/staging/android/ion/ion_test.c | 1 + > drivers/staging/android/uapi/ion_test.h | 1 + &g

Re: [PATCH] ion_test: Add compat_ioctl support

2013-12-19 Thread Colin Cross
On Thu, Dec 19, 2013 at 3:30 PM, John Stultz wrote: > On 12/19/2013 02:52 PM, Colin Cross wrote: >> On Thu, Dec 19, 2013 at 2:40 PM, John Stultz wrote: >>> Prior to subitting this, Colin reworked the compat_ioctl support >>> for the ion_test driver, moving the st

Re: [PATCH] ion_test: Add compat_ioctl support

2013-12-19 Thread Colin Cross
his does affect the ABI for 32bit users, its only > the ABI for the ion_test driver, not ion itself. > > Cc: Colin Cross > Cc: Greg KH > Cc: Android Kernel Team > Signed-off-by: John Stultz > --- > drivers/staging/android/ion/ion_test.c | 1 + > drivers/staging/and

Re: [PATCH v3] staging: ion: Avoid using rt_mutexes directly

2013-12-17 Thread Colin Cross
t get used as a general heap lock." > > Thus this patch converts the rt_mutex usage to a spinlock and > renames the lock free_lock to be more clear as to its use. > > I also had to change a bit of logic in ion_heap_freelist_drain() > to safely avoid list corruption. > > Cc:

Re: [PATCH 3/3] staging: ion: Avoid using rt_mutexes directly.

2013-12-16 Thread Colin Cross
gt; > Not sure if its the mixing of list traversal methods causing the issue? > Thoughts would be appreciated. list_for_each_entry_safe just stores the next pointer to allow deleting the current pointer, but that isn't safe if you follow my suggestion to drop the lock because the next poin

Re: [PATCH 1/3] staging: ion: Add HAVE_MEMBLOCK config dependency

2013-12-16 Thread Colin Cross
Acked-by: Colin Cross On Mon, Dec 16, 2013 at 9:07 PM, John Stultz wrote: > The kbuild test robot reported a build issue w/ ION on m68k: > > drivers/staging/android/ion/ion.c: In function 'ion_reserve': > drivers/staging/android/ion/ion.c:1526:4: error: implicit decl

Re: [PATCH 2/3] staging: ion: Fix possible null pointer dereference

2013-12-16 Thread Colin Cross
m kmalloc goes unchecked for failure. > > This patch checks the return for NULL, and reworks the logic, as > suggested by Colin, so we allocate the page_info structure first. > > Cc: Colin Cross > Cc: Greg KH > Cc: Android Kernel Team > Cc: kbuild test robot > Repor

Re: [RFC][PATCH 3/3] staging: ion: Avoid using rt_mutexes directly.

2013-12-16 Thread Colin Cross
On Mon, Dec 16, 2013 at 5:22 PM, John Stultz wrote: > On 12/16/2013 04:17 PM, Colin Cross wrote: >> The lock is only used to protect the heap's free_list and >> free_list_size members, and is not held for any long or sleeping >> operations. Converting to a spinlo

[PATCH] ion: remove ion_user_handle_t from ion_test.h

2013-12-16 Thread Colin Cross
i/ion.h:23: note: previous declaration of 'ion_user_handle_t' was here Reported-by: Andrew Morton Signed-off-by: Colin Cross --- drivers/staging/android/uapi/ion_test.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/staging/android/uapi/ion_test.h b/drivers/staging/and

Re: [RFC][PATCH 2/3] staging: ion: Fix possible null pointer dereference

2013-12-16 Thread Colin Cross
On Mon, Dec 16, 2013 at 1:32 PM, John Stultz wrote: > The kbuild test robot reported: > > drivers/staging/android/ion/ion_system_heap.c:122 alloc_largest_available() > error: potential null dereference 'info'. (kmalloc returns null) > > Where the pointer returned from kmalloc goes unchecked for

Re: [RFC][PATCH 3/3] staging: ion: Avoid using rt_mutexes directly.

2013-12-16 Thread Colin Cross
On Mon, Dec 16, 2013 at 1:32 PM, John Stultz wrote: > RT_MUTEXES can be configured out of the kernel, causing compile > problems with ION. > > Since there is no documentation as to why directly using rt_mutexes > is necessary (and very few drivers directly use rt_mutexes), simply > convert the ion

Re: [PATCH 1/2] ion: Don't allow building ION as a module.

2013-12-14 Thread Colin Cross
On Sat, Dec 14, 2013 at 2:19 PM, John Stultz wrote: > On 12/14/2013 01:48 PM, Greg KH wrote: >> On Sat, Dec 14, 2013 at 12:06:45PM -0800, John Stultz wrote: >>> ION doesn't export the proper symbols for it to be a module. This >>> causes build issues when ION is configured as a module. >>> >>> Sin

Re: [PATCH 001/115] gpu: ion: Add ION Memory Manager

2013-12-14 Thread Colin Cross
On Sat, Dec 14, 2013 at 1:44 PM, Greg KH wrote: > On Sat, Dec 14, 2013 at 01:10:38PM -0800, Colin Cross wrote: >> On Sat, Dec 14, 2013 at 8:52 AM, Greg KH wrote: >> > On Fri, Dec 13, 2013 at 02:23:35PM -0800, John Stultz wrote: >> >> + idev->debug_root

Re: [PATCH 001/115] gpu: ion: Add ION Memory Manager

2013-12-14 Thread Colin Cross
On Sat, Dec 14, 2013 at 8:52 AM, Greg KH wrote: > On Fri, Dec 13, 2013 at 02:23:35PM -0800, John Stultz wrote: >> + idev->debug_root = debugfs_create_dir("ion", NULL); >> + if (IS_ERR_OR_NULL(idev->debug_root)) >> + pr_err("ion: failed to create debug files.\n"); > > There's no

[PATCH] ioprio: move userspace api into uapi

2013-12-09 Thread Colin Cross
Move the userspace interface described in Documentation/block/ioprio.txt from include/linux/ioprio.h to include/uapi/linux/ioprio.h. Signed-off-by: Colin Cross --- include/linux/ioprio.h | 42 + include/uapi/linux/ioprio.h | 46

Re: [PATCH v1 9/9] staging: android: binder: Add binder compat layer

2013-12-04 Thread Colin Cross
On Wed, Dec 4, 2013 at 4:02 PM, Greg KH wrote: > On Wed, Dec 04, 2013 at 02:22:13PM -0800, Colin Cross wrote: >> On Wed, Dec 4, 2013 at 2:02 PM, Greg KH wrote: >> > On Wed, Dec 04, 2013 at 01:55:34PM -0800, Colin Cross wrote: >> >> On Wed, Dec 4, 2013 at

Re: [PATCH v1 9/9] staging: android: binder: Add binder compat layer

2013-12-04 Thread Colin Cross
On Wed, Dec 4, 2013 at 3:21 PM, One Thousand Gnomes wrote: > On Wed, 4 Dec 2013 10:35:54 -0800 > Greg KH wrote: > >> On Wed, Dec 04, 2013 at 06:09:41PM +, Serban Constantinescu wrote: >> > +#define size_helper(x) ({ \ >> > + size_t __size;

Re: [PATCH v1 9/9] staging: android: binder: Add binder compat layer

2013-12-04 Thread Colin Cross
On Wed, Dec 4, 2013 at 2:02 PM, Greg KH wrote: > On Wed, Dec 04, 2013 at 01:55:34PM -0800, Colin Cross wrote: >> On Wed, Dec 4, 2013 at 1:43 PM, Greg KH wrote: >> > On Wed, Dec 04, 2013 at 12:46:42PM -0800, Colin Cross wrote: >> >> On Wed, Dec 4, 2013 at 1

Re: [PATCH v1 9/9] staging: android: binder: Add binder compat layer

2013-12-04 Thread Colin Cross
On Wed, Dec 4, 2013 at 1:43 PM, Greg KH wrote: > On Wed, Dec 04, 2013 at 12:46:42PM -0800, Colin Cross wrote: >> On Wed, Dec 4, 2013 at 10:35 AM, Greg KH wrote: >> >> >> > And finally, is this all really needed? Why not just fix the structures >> > to

Re: [PATCH v1 9/9] staging: android: binder: Add binder compat layer

2013-12-04 Thread Colin Cross
On Wed, Dec 4, 2013 at 10:35 AM, Greg KH wrote: > And finally, is this all really needed? Why not just fix the structures > to be "correct", and then fix userspace to use the correct structures as > well, thereby not needing a compat layer at all? Some of the binder ioctls take userspace point

[PATCHv4 1/2] mm: rearrange madvise code to allow for reuse

2013-10-30 Thread Colin Cross
madvise_update_vma. The next patch will add support for updating a new anon_name field as well. Signed-off-by: Colin Cross Cc: Pekka Enberg Cc: Dave Hansen Cc: Peter Zijlstra Cc: Ingo Molnar Cc: Oleg Nesterov Cc: "Eric W. Biederman" Cc: Jan Glauber Cc: John Stultz Cc: Rob L

[PATCHv4 2/2] mm: add a field to store names for private anonymous memory

2013-10-30 Thread Colin Cross
he mm subsystem other than comparing the anon_name pointers when considering vma merging. The pointer is stored in a union with fields that are only used on file-backed mappings, so it does not increase memory usage. Signed-off-by: Colin Cross Cc: Pekka Enberg Cc: Dave Hansen Cc: Peter Zijlstr

Re: [PATCH 2/2] mm: add a field to store names for private anonymous memory

2013-10-15 Thread Colin Cross
On Mon, Oct 14, 2013 at 6:31 PM, Colin Cross wrote: > In many userspace applications, and especially in VM based > applications like Android uses heavily, there are multiple different > allocators in use. At a minimum there is libc malloc and the stack, > and in many cases there are

[PATCHv3 1/2] mm: rearrange madvise code to allow for reuse

2013-10-14 Thread Colin Cross
function called madvise_update_vma. The next patch will add support for updating a new anon_name field as well. Signed-off-by: Colin Cross --- mm/madvise.c | 272 +-- 1 file changed, 151 insertions(+), 121 deletions(-) diff --git a/mm/madvise.c

[PATCH 2/2] mm: add a field to store names for private anonymous memory

2013-10-14 Thread Colin Cross
t are only used on file-backed mappings, so it does not increase memory usage. Signed-off-by: Colin Cross --- v2: updates the commit message to explain in more detail why the patch is useful. v3: renames vma_get_anon_name to vma_anon_name replaces logic in seq_print_vma_name

Re: [PATCH v1] seq_file: Fix overflow condition in seq_commit

2013-10-14 Thread Colin Cross
On Tue, Aug 20, 2013 at 7:04 AM, Al Viro wrote: > On Tue, Aug 20, 2013 at 08:36:22AM +0100, Al Viro wrote: > >> Aha. _That_ is a bug, all right - dynamic_dname() is simply not suitable >> for that kind of uses. ashmem.c is certainly abusing shmem_file_setup(); >> feeding that kind of mess as den

[PATCHv2 1/2] mm: rearrange madvise code to allow for reuse

2013-10-01 Thread Colin Cross
function called madvise_update_vma. The next patch will add support for updating a new anon_name field as well. Signed-off-by: Colin Cross --- mm/madvise.c | 272 +-- 1 file changed, 151 insertions(+), 121 deletions(-) diff --git a/mm/madvise.c

Re: [PATCH 14/21] cpuidle: coupled: don't compare cpu masks unnecessarily

2013-09-25 Thread Colin Cross
On Thu, Sep 26, 2013 at 1:36 AM, Viresh Kumar wrote: > On 26 September 2013 05:55, Colin Cross wrote: >> I don't agree with this. This patch is a tiny optimization in code >> that is rarely called, and it moves a final sanity check somewhere >> that it might get mis

Re: [RFC PATCH] freezer: allow killing of frozen tasks

2013-09-25 Thread Colin Cross
On Wed, Sep 25, 2013 at 1:07 AM, Rafael J. Wysocki wrote: > On Wednesday, September 25, 2013 02:52:26 PM Kyungmin Park wrote: >> On Tue, Aug 20, 2013 at 9:41 PM, Rafael J. Wysocki wrote: >> > On Tuesday, August 20, 2013 08:27:27 AM Tejun Heo wrote: >> >> On Tue, Aug 20, 2013 at 02:34:14PM +0200,

Re: [PATCH 14/21] cpuidle: coupled: don't compare cpu masks unnecessarily

2013-09-25 Thread Colin Cross
On Sat, Sep 21, 2013 at 6:21 PM, Viresh Kumar wrote: > In cpuidle_coupled_register_device() we do following: > if (WARN_ON(!cpumask_equal(&dev->coupled_cpus, > &coupled->coupled_cpus))) > coupled->prevent++; > > This is only required to be done when we are using 'coupled'

Re: [PATCH v2] cpuidle: coupled: abort idle if pokes are pending

2013-08-29 Thread Colin Cross
On Thu, Aug 29, 2013 at 1:28 PM, Rafael J. Wysocki wrote: > On Wednesday, August 28, 2013 06:41:47 PM Colin Cross wrote: >> Joseph Lo reported a lockup on Tegra20 caused >> by a race condition in coupled cpuidle. When two or more cpus >> enter idle at the same time, the fir

Re: [PATCH 1/3] cpuidle: coupled: disable interrupts after entering safe state

2013-08-29 Thread Colin Cross
On Wed, Aug 28, 2013 at 11:50 PM, Prashant Gaikwad wrote: > On Saturday 24 August 2013 01:15 AM, Colin Cross wrote: >> >> Calling cpuidle_enter_state is expected to return with interrupts >> enabled, but interrupts must be disabled before starting the >> ready loop s

[PATCH v2] cpuidle: coupled: abort idle if pokes are pending

2013-08-28 Thread Colin Cross
enters the waiting loop and when it moves on to the ready loop. Reported-by: Joseph Lo Tested-by: Stephen Warren Tested-by: Joseph Lo Signed-off-by: Colin Cross --- drivers/cpuidle/coupled.c | 107 +++--- 1 file changed, 82 insertions(+), 25 deletions

Re: [RFC PATCHv3] drivers: power: Detect device suspend/resume lockup and log event in pstore.

2013-08-28 Thread Colin Cross
On Wed, Aug 28, 2013 at 3:36 PM, John Stultz wrote: > On 08/28/2013 01:52 PM, Rafael J. Wysocki wrote: >> On Wednesday, August 28, 2013 10:45:45 AM Zoran Markovic wrote: >>> Hi Rafael, It doesn't look too bad from a quick look, but there's a couple of things I don't like in it still (rel

Re: [PATCH 1/3] cpuidle: coupled: disable interrupts after entering safe state

2013-08-28 Thread Colin Cross
On Wed, Aug 28, 2013 at 2:28 PM, Rafael J. Wysocki wrote: > On Friday, August 23, 2013 12:45:10 PM Colin Cross wrote: >> Calling cpuidle_enter_state is expected to return with interrupts >> enabled, but interrupts must be disabled before starting the >> ready loop synchro

Re: [PATCH 1/3] cpuidle: coupled: disable interrupts after entering safe state

2013-08-23 Thread Colin Cross
On Fri, Aug 23, 2013 at 4:09 PM, Stephen Warren wrote: > On 08/23/2013 01:45 PM, Colin Cross wrote: >> Calling cpuidle_enter_state is expected to return with interrupts >> enabled, but interrupts must be disabled before starting the >> ready loop synchronization stage. C

[PATCH 3/3] cpuidle: coupled: fix race condition between pokes and safe state

2013-08-23 Thread Colin Cross
() checks into the callers. In the waiting loop, if a poke was cleared restart the loop to repeat the while condition checks. Reported-by: Neil Zhang CC: sta...@vger.kernel.org Signed-off-by: Colin Cross --- drivers/cpuidle/coupled.c | 20 ++-- 1 file changed, 14 insertions(+), 6

[PATCH 1/3] cpuidle: coupled: disable interrupts after entering safe state

2013-08-23 Thread Colin Cross
Calling cpuidle_enter_state is expected to return with interrupts enabled, but interrupts must be disabled before starting the ready loop synchronization stage. Call local_irq_disable after each call to cpuidle_enter_state for the safe state. CC: sta...@vger.kernel.org Signed-off-by: Colin Cross

[PATCH 2/3] cpuidle: coupled: abort idle if pokes are pending

2013-08-23 Thread Colin Cross
enters the waiting loop and when it moves on to the ready loop. Reported-by: Joseph Lo CC: sta...@vger.kernel.org Signed-off-by: Colin Cross --- drivers/cpuidle/coupled.c | 107 +++--- 1 file changed, 82 insertions(+), 25 deletions(-) diff --git a/drivers

Re: [PATCH] cpuidle: coupled: fix dead loop corner case

2013-08-22 Thread Colin Cross
On Mon, Aug 19, 2013 at 10:17 PM, Neil Zhang wrote: > There is a corener case when no peripheral irqs route to secondary > cores. > Let's take dual core system for example, the sequence is as following: > > Core 0 Core1 > 1.

Re: [PATCH] LMK: Optimize lowmem_shrink

2013-08-19 Thread Colin Cross
On Mon, Aug 19, 2013 at 7:23 PM, Colin Cross wrote: > On Mon, Aug 19, 2013 at 6:16 PM, Leon Ma wrote: >> From: Leon Ma >> Date: Mon, 19 Aug 2013 14:22:38 +0800 >> Subject: [PATCH] LMK: Optimize lowmem_shrink. >> >> By comparing with selected_oom_score_adj inste

Re: [PATCH] LMK: Optimize lowmem_shrink

2013-08-19 Thread Colin Cross
On Mon, Aug 19, 2013 at 6:16 PM, Leon Ma wrote: > From: Leon Ma > Date: Mon, 19 Aug 2013 14:22:38 +0800 > Subject: [PATCH] LMK: Optimize lowmem_shrink. > > By comparing with selected_oom_score_adj instead of min_score_adj, > we may do less calculation. > > Signed-off-by: Leon Ma > --- > drivers

Re: Linux apanic mechanism and difference from newer ram_console/persistent_ram mechanism

2013-08-08 Thread Colin Cross
On Thu, Aug 8, 2013 at 4:50 AM, Yuva Raj wrote: > On Thu, Aug 8, 2013 at 3:03 PM, Vijay wrote: >> >> Hello, >> >> >> I am new to the Kernel-Mailing list. I am not subscribed at the moment >> and would really appreciate it, if I can be CC'd in the >> reply/responses for my question. >> >> I am stu

Re: linux-next: Tree for Aug 7 [ call-trace on suspend: ext4 | pm related ? ]

2013-08-07 Thread Colin Cross
On Wed, Aug 7, 2013 at 6:01 PM, Sedat Dilek wrote: > On Thu, Aug 8, 2013 at 1:34 AM, Colin Cross wrote: >> On Wed, Aug 7, 2013 at 4:15 PM, Sedat Dilek wrote: >>> On Thu, Aug 8, 2013 at 12:58 AM, Colin Cross wrote: >>>> Can you try add a call to show_state_f

Re: linux-next: Tree for Aug 7 [ call-trace on suspend: ext4 | pm related ? ]

2013-08-07 Thread Colin Cross
On Wed, Aug 7, 2013 at 4:15 PM, Sedat Dilek wrote: > On Thu, Aug 8, 2013 at 12:58 AM, Colin Cross wrote: >> Can you try add a call to show_state_filter(TASK_UNINTERRUPTIBLE) in >> the error path of try_to_freeze_tasks(), where it prints the "refusing >> to freeze&qu

Re: linux-next: Tree for Aug 7 [ call-trace on suspend: ext4 | pm related ? ]

2013-08-07 Thread Colin Cross
Can you try add a call to show_state_filter(TASK_UNINTERRUPTIBLE) in the error path of try_to_freeze_tasks(), where it prints the "refusing to freeze" message? It will print the stack trace of every thread since they are all in the freezer, so the output will be very long. On Wed, Aug 7, 2013 at

[PATCH] power: set PF_SUSPEND_TASK flag on tasks that call freeze_processes

2013-07-24 Thread Colin Cross
by the time suspend is triggered, otherwise they may run when userspace is expected to be frozen. Add a WARN_ON in thaw_processes if more than one thread has the PF_SUSPEND_TASK flag set. Reported-by: Michael Leun Tested-by: Michael Leun Signed-off-by: Colin Cross --- Resending not as an

Re: 3.11-rc regression bisected: s2disk does not work (was Re: [PATCH v3 13/16] futex: use freezable blocking call)

2013-07-23 Thread Colin Cross
On Mon, Jul 22, 2013 at 11:28 PM, Colin Cross wrote: > On Mon, Jul 22, 2013 at 6:41 PM, Rafael J. Wysocki wrote: >> On Monday, July 22, 2013 05:42:49 PM Colin Cross wrote: >>> On Mon, Jul 22, 2013 at 5:32 PM, Linus Torvalds >>> wrote: >>> > On Mon, Jul

Re: 3.11-rc regression bisected: s2disk does not work (was Re: [PATCH v3 13/16] futex: use freezable blocking call)

2013-07-23 Thread Colin Cross
On Tue, Jul 23, 2013 at 12:16 PM, Michael Leun wrote: > On Tue, 23 Jul 2013 11:29:57 -0700 > Colin Cross wrote: > >> On Tue, Jul 23, 2013 at 11:08 AM, Michael Leun >> wrote: >> > On Mon, 22 Jul 2013 16:55:58 -0700 >> > Colin Cross wrote: >> > >

Re: 3.11-rc regression bisected: s2disk does not work (was Re: [PATCH v3 13/16] futex: use freezable blocking call)

2013-07-23 Thread Colin Cross
On Tue, Jul 23, 2013 at 11:08 AM, Michael Leun wrote: > On Mon, 22 Jul 2013 16:55:58 -0700 > Colin Cross wrote: > >> On Mon, Jul 22, 2013 at 4:02 PM, Michael Leun >> wrote: >> > On Mon, 6 May 2013 16:50:18 -0700 >> > Colin Cross wrote: >> >

Re: 3.11-rc regression bisected: s2disk does not work (was Re: [PATCH v3 13/16] futex: use freezable blocking call)

2013-07-22 Thread Colin Cross
On Mon, Jul 22, 2013 at 6:41 PM, Rafael J. Wysocki wrote: > On Monday, July 22, 2013 05:42:49 PM Colin Cross wrote: >> On Mon, Jul 22, 2013 at 5:32 PM, Linus Torvalds >> wrote: >> > On Mon, Jul 22, 2013 at 4:55 PM, Colin Cross wrote: >> >> >> >>

Re: 3.11-rc regression bisected: s2disk does not work (was Re: [PATCH v3 13/16] futex: use freezable blocking call)

2013-07-22 Thread Colin Cross
On Mon, Jul 22, 2013 at 5:32 PM, Linus Torvalds wrote: > On Mon, Jul 22, 2013 at 4:55 PM, Colin Cross wrote: >> >> I think the right solution is to add a flag to the freezing task that >> marks it unfreezable. I think PF_NOFREEZE would work, although it is >> norm

Re: 3.11-rc regression bisected: s2disk does not work (was Re: [PATCH v3 13/16] futex: use freezable blocking call)

2013-07-22 Thread Colin Cross
On Mon, Jul 22, 2013 at 4:02 PM, Michael Leun wrote: > On Mon, 6 May 2013 16:50:18 -0700 > Colin Cross wrote: > >> Avoid waking up every thread sleeping in a futex_wait call during > [...] > > With 3.11-rc s2disk from suspend-utils stopped working: Frozen at > displ

[tip:core/locking] futex: Use freezable blocking call

2013-06-25 Thread tip-bot for Colin Cross
Commit-ID: 88c8004fd3a5fdd2378069de86b90b21110d33a4 Gitweb: http://git.kernel.org/tip/88c8004fd3a5fdd2378069de86b90b21110d33a4 Author: Colin Cross AuthorDate: Wed, 1 May 2013 18:35:05 -0700 Committer: Thomas Gleixner CommitDate: Tue, 25 Jun 2013 23:11:19 +0200 futex: Use freezable

Re: RFC: named anonymous vmas

2013-06-24 Thread Colin Cross
On Mon, Jun 24, 2013 at 4:48 AM, Christoph Hellwig wrote: > On Sat, Jun 22, 2013 at 12:47:29PM -0700, Alex Elsayed wrote: >> Couldn't this be done by having a root-only tmpfs, and having a userspace >> component that creates per-app directories with restrictive permissions on >> startup/app instal

Re: RFC: named anonymous vmas

2013-06-22 Thread Colin Cross
On Sat, Jun 22, 2013 at 3:31 AM, Christoph Hellwig wrote: > On Fri, Jun 21, 2013 at 04:42:41PM -0700, Colin Cross wrote: >> ranges, which John Stultz has been implementing. The second is >> anonymous shareable memory without having a world-writable tmpfs that >> untrusted

Re: RFC: named anonymous vmas

2013-06-21 Thread Colin Cross
On Fri, Jun 21, 2013 at 10:12 PM, Kyungmin Park wrote: > On Sat, Jun 22, 2013 at 8:42 AM, Colin Cross wrote: >> One of the features of ashmem (drivers/staging/android/ashmem.c) that >> hasn't gotten much discussion about moving out of staging is named >> anonymou

RFC: named anonymous vmas

2013-06-21 Thread Colin Cross
One of the features of ashmem (drivers/staging/android/ashmem.c) that hasn't gotten much discussion about moving out of staging is named anonymous memory. In Android, ashmem is used for three different features, and most users of it only care about one feature at a time. One is volatile ranges, w

Re: [RFC PATCH] mmc: Enable wakeup_sources for mmc core

2013-06-19 Thread Colin Cross
On Wed, Jun 19, 2013 at 7:21 AM, Ulf Hansson wrote: > It seems like a bad idea that an insertion of an SD card should > trigger the display to be light up. That is indirectly in principle > what you suggest should happen from user space once a new SD card is > found. Right? Most likely what will

Re: [RFC PATCH] mmc: Enable wakeup_sources for mmc core

2013-06-18 Thread Colin Cross
On Tue, Jun 18, 2013 at 6:17 AM, Ulf Hansson wrote: > On 17 June 2013 20:33, Colin Cross wrote: >> This is a generic requirement for using a kernel with autosleep >> enabled. Autosleep will enter suspend whenever there is no wakeup >> source/wakelock held. Consider t

Re: [RFC PATCH] mmc: Enable wakeup_sources for mmc core

2013-06-17 Thread Colin Cross
On Mon, Jun 17, 2013 at 7:22 AM, Ulf Hansson wrote: > On 14 June 2013 22:52, Colin Cross wrote: >> On Fri, Jun 14, 2013 at 11:42 AM, Zoran Markovic >> wrote: >>>> I am not sure I understand why this patch is needed. When a new card >>>> is inserted/removed

Re: [RFC PATCH] mmc: Enable wakeup_sources for mmc core

2013-06-14 Thread Colin Cross
On Fri, Jun 14, 2013 at 11:42 AM, Zoran Markovic wrote: >> I am not sure I understand why this patch is needed. When a new card >> is inserted/removed and the upper levels gets notification about the >> new card, triggering the mounting/un-mounting of the file system, why >> should it be the lowes

Re: [PATCH] ARM: convert max_pfn and max_low_pfn to be relative to PFN0

2013-06-13 Thread Colin Cross
On Thu, Jun 13, 2013 at 7:37 AM, Russell King - ARM Linux wrote: > On Wed, Jun 12, 2013 at 07:13:23PM -0700, Colin Cross wrote: >> >From code inspection, I believe this will also improve block device >> performance where the bounce limit was set to BLK_BOUNCE_HIGH, whi

[PATCH] ARM: convert max_pfn and max_low_pfn to be relative to PFN0

2013-06-12 Thread Colin Cross
ice performance where the bounce limit was set to BLK_BOUNCE_HIGH, which was bouncing unnecessarily for the top PHYS_PFN_OFFSET pages of low memory. Signed-off-by: Colin Cross --- arch/arm/mm/init.c | 21 ++--- 1 file changed, 6 insertions(+), 15 deletions(-) Boot tested on 3.4 and filled

Re: [RFC PATCHv2 1/2] drivers: power: Add watchdog timer to catch drivers which lockup during suspend/resume.

2013-06-10 Thread Colin Cross
On Thu, Jun 6, 2013 at 7:12 AM, Alan Stern wrote: > On Wed, 5 Jun 2013, Zoran Markovic wrote: > >> > It does block in my environment, AFAICS. Looking a bit further in the >> > code, it looks like dpm_suspend() does an async_synchronize_full() >> > which would wait for all async tasks to complete.

Re: [RFC PATCHv2 1/2] drivers: power: Add watchdog timer to catch drivers which lockup during suspend/resume.

2013-05-12 Thread Colin Cross
On Sat, May 11, 2013 at 5:39 PM, Rafael J. Wysocki wrote: > On Friday, May 10, 2013 11:13:27 PM Colin Cross wrote: >> On Fri, May 10, 2013 at 2:28 PM, Zoran Markovic >> wrote: >> > From: Benoit Goby >> > >> > Below is a patch from android kernel that d

Re: [RFC PATCHv2 2/2] PM: compile-time configuration of device suspend/resume watchdogs.

2013-05-11 Thread Colin Cross
On Sat, May 11, 2013 at 2:28 AM, Pavel Machek wrote: > Hi! > >> Power management debug option to configure device suspend/resume watchdogs. >> Available options are: >> 1. Enable/disable the feature. >> 2. Select triggered watchdog action between: >> - system panic (default) >>

Re: [RFC PATCHv2 2/2] PM: compile-time configuration of device suspend/resume watchdogs.

2013-05-10 Thread Colin Cross
hdog(s). > > Minor changes were made to watchdog code to accommodate this feature. > > Cc: Android Kernel Team > Cc: Colin Cross > Cc: Todd Poynor > Cc: San Mehat > Cc: Benoit Goby > Cc: John Stultz > Cc: Pavel Machek > Cc: Rafael J. Wysocki > Cc: Len Br

Re: [RFC PATCHv2 1/2] drivers: power: Add watchdog timer to catch drivers which lockup during suspend/resume.

2013-05-10 Thread Colin Cross
ttle context as to why. > The patch hence uses system timer and assumes it is still active while the > devices are suspended/resumed. > > Cc: Android Kernel Team > Cc: Colin Cross > Cc: Todd Poynor > Cc: San Mehat > Cc: Benoit Goby > Cc: John Stultz > Cc: Pavel M

Re: [PATCH v4 02/16] freezer: add unsafe versions of freezable helpers for CIFS

2013-05-07 Thread Colin Cross
ll allow problems to be found in other drivers that may have a more serious deadlock risk, and prevent new problems from being added. Acked-by: Pavel Machek Signed-off-by: Colin Cross --- v4: Corrected to include CIFS wait_for_response hunk. The rest of this series is still at v3. fs/cifs/

  1   2   3   >