Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756103Ab2BHEAk (ORCPT ); Tue, 7 Feb 2012 23:00:40 -0500 Received: from mail-gx0-f174.google.com ([209.85.161.174]:35158 "EHLO mail-gx0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753935Ab2BHEAh (ORCPT ); Tue, 7 Feb 2012 23:00:37 -0500 MIME-Version: 1.0 In-Reply-To: References: <20120116163106.GC7180@jl-vm1.vm.bytemark.co.uk> <1326776095-2629-1-git-send-email-siddhesh.poyarekar@gmail.com> <4F2B02BC.8010308@gmail.com> Date: Wed, 8 Feb 2012 09:30:36 +0530 Message-ID: Subject: Re: [RESEND][PATCH] Mark thread stack correctly in proc//maps From: Siddhesh Poyarekar To: KOSAKI Motohiro Cc: Jamie Lokier , linux-mm@kvack.org, linux-kernel@vger.kernel.org, Alexander Viro , linux-fsdevel@vger.kernel.org, Michael Kerrisk , linux-man@vger.kernel.org, Mike Frysinger Content-Type: text/plain; charset=ISO-8859-1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1736 Lines: 41 On Sat, Feb 4, 2012 at 12:04 AM, Siddhesh Poyarekar wrote: > On Fri, Feb 3, 2012 at 1:31 PM, KOSAKI Motohiro > wrote: >> The fact is, now process stack and pthread stack clearly behave >> different dance. libc don't expect pthread stack grow automatically. >> So, your patch will break userland. Just only change display thing. > I have also dropped an email on the libc-alpha list here to solicit > comments from libc maintainers on this: > > http://sourceware.org/ml/libc-alpha/2012-02/msg00036.html > Kosaki-san, your suggestion of adding an extra flag seems like the right way to go about this based on the discussion on libc-alpha, specifically, your point about pthread_getattr_np() -- it may not be a standard, but it's a breakage anyway. However, looking at the vm_flags options in mm.h, it looks like the entire 32-bit space has been exhausted for the flag value. The vm_flags is an unsigned long, so it ought to take 8 bytes on a 64-bit system, but 32-bit systems will be left behind. So there are two options for this: 1) make vm_flags 64-bit for all arches. This will cause ABI breakage on 32-bit systems, so any external drivers will have to be rebuilt 2) Implement this patch for 64-bit only by defining the new flag only for 64-bit. 32-bit systems behave as is Which of these would be better? I prefer the latter because it looks like the path of least breakage. -- Siddhesh Poyarekar http://siddhesh.in -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/