From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932359Ab3B0LPJ (ORCPT ); Wed, 27 Feb 2013 06:15:09 -0500 Received: from e06smtp16.uk.ibm.com ([195.75.94.112]:58268 "EHLO e06smtp16.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756521Ab3B0LPH (ORCPT ); Wed, 27 Feb 2013 06:15:07 -0500 Date: Wed, 27 Feb 2013 12:15:02 +0100 From: Heiko Carstens To: Linus Torvalds Cc: "David S. Miller" , Andrew Morton , Linux Kernel Mailing List , Gerald Schaefer , Martin Schwidefsky Subject: Re: bug in generic strncpy_from_user Message-ID: <20130227111502.GE4832@osiris> References: <20130226045424.GA3576@osiris> <20130226125739.GA3924@osiris> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) X-Content-Scanned: Fidelis XPS MAILER x-cbid: 13022711-3548-0000-0000-000004A92CAE Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Feb 26, 2013 at 04:30:50PM -0800, Linus Torvalds wrote: > On Tue, Feb 26, 2013 at 3:43 PM, Linus Torvalds > wrote: > > > > So I'll need to extend on that logic a bit more. > > Ok, here's the fleshed-out patch. Also fixed to use "expand_stack()", > which is what the page fault handling actually uses. And it has the > GROWSUP case as well as a comment about this all. > > So it all looks good. But it's still totally and entirely untested. Tested with 64 bit kernel with 64 bit and 31 bit mode user space as well as with 31 bit kernel and 31 bit user space. Each with legacy and flexible mmap layout. The bug is fixed and everything else still seems to work. Thanks! Tested-By: Heiko Carstens