Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751736AbaJZSQM (ORCPT ); Sun, 26 Oct 2014 14:16:12 -0400 Received: from mail-vc0-f176.google.com ([209.85.220.176]:51697 "EHLO mail-vc0-f176.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751372AbaJZSQL (ORCPT ); Sun, 26 Oct 2014 14:16:11 -0400 MIME-Version: 1.0 In-Reply-To: References: Date: Sun, 26 Oct 2014 11:16:10 -0700 X-Google-Sender-Auth: 37n0YiUxkTps2CKZXGX47CQTHyE Message-ID: Subject: Re: vmalloced stacks on x86_64? From: Linus Torvalds To: Andy Lutomirski Cc: Richard Weinberger , "H. Peter Anvin" , X86 ML , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Oct 25, 2014 at 4:16 PM, Andy Lutomirski wrote: > > On brief inspection, grsecurity isn't actually vmallocing the stack. > It seems to be allocating it the normal way and then vmapping it. > That allows it to modify sg_set_buf to work on stack addresses (sigh). Perhaps more importantly, the vmalloc space is a limited resource (at least on 32-bit), and using vmap probably results in less fragmentation. I don't think either is really even an option on 32-bit due to the limited address space. On 64-bit, maybe a virtually remapped stack would be ok. Linus -- 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/