Message ID | 20180924113114.858873958@linuxfoundation.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 3C230913 for <patchwork-linux-mm@patchwork.kernel.org>; Mon, 24 Sep 2018 12:32:45 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2C1C029EB4 for <patchwork-linux-mm@patchwork.kernel.org>; Mon, 24 Sep 2018 12:32:45 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 1FFE629EC1; Mon, 24 Sep 2018 12:32:45 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 7AA2F29EC0 for <patchwork-linux-mm@patchwork.kernel.org>; Mon, 24 Sep 2018 12:32:44 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 62E038E0018; Mon, 24 Sep 2018 08:32:43 -0400 (EDT) Delivered-To: linux-mm-outgoing@kvack.org Received: by kanga.kvack.org (Postfix, from userid 40) id 5DE388E0001; Mon, 24 Sep 2018 08:32:43 -0400 (EDT) X-Original-To: int-list-linux-mm@kvack.org X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4CD6E8E0018; Mon, 24 Sep 2018 08:32:43 -0400 (EDT) X-Original-To: linux-mm@kvack.org X-Delivered-To: linux-mm@kvack.org Received: from mail-pf1-f200.google.com (mail-pf1-f200.google.com [209.85.210.200]) by kanga.kvack.org (Postfix) with ESMTP id 0F0E48E0001 for <linux-mm@kvack.org>; Mon, 24 Sep 2018 08:32:43 -0400 (EDT) Received: by mail-pf1-f200.google.com with SMTP id e15-v6so10265357pfi.5 for <linux-mm@kvack.org>; Mon, 24 Sep 2018 05:32:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-original-authentication-results:x-gm-message-state:from:to:cc :subject:date:message-id:in-reply-to:references:user-agent :mime-version:content-transfer-encoding; bh=5LMaYms4ckNSVhzzMDcK3TWfvGO6y9FC1eL+CT/nMYY=; b=WWSCyxrb9x7Dew7gxc+l6CUOWn6TZY/G16hd4Ln855MnT0H81i1qTksjD2uFHsvaGo 1xdQ2r4gQfdl7h+a9RseC/OPv3/e9WOXASzzQbuqTlpge8+l1clz4IxMIOYgIHj85IVm 8nPkwhjoVpD8WZvcn1vUzJcX3TmKnWEkB2M/4o60OSJxrsMMxYyaO7brAht087Fmi7Am 6Y/ZpxO/wmxl+b12kDs3Iubm4WWSJGbZ82gxMxHn3BQlZ6voSXc6tQL1NTfAhlJphaKS MTYwy8S+63qsDT0WtgyjOQr+YjBL4cMEYHmQHfZRBPMqWeY2VAM85Dl3bKkGbSJKs1Gu 7KkQ== X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of gregkh@linuxfoundation.org designates 140.211.169.12 as permitted sender) smtp.mailfrom=gregkh@linuxfoundation.org X-Gm-Message-State: APzg51CnJORGMhv1scTJ76yjhPY1x0iy+IZScu6dgBXO5bgrlYc8OJhD bT0GzARrP/YU24LRg5LemqjWETK+YoXX62z1IldlcyF2O1sstGzXPX0fmMwMa9dnuHHBpoihrZ0 ebmjtjoaWJkQCIH+vMhIgyk8psUDZ8Muj5o44YTnBwhS918QnCSnBBh/t4XMpwPOpnA== X-Received: by 2002:a62:6283:: with SMTP id w125-v6mr10160974pfb.108.1537792362742; Mon, 24 Sep 2018 05:32:42 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZsVWHTDHsUPppwNvVAY6XzcQe4CrsmZI+bvYGd2ICUla7q0Lbimu+eZP2+xt1DAfPQZiSF X-Received: by 2002:a62:6283:: with SMTP id w125-v6mr10160913pfb.108.1537792361913; Mon, 24 Sep 2018 05:32:41 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1537792361; cv=none; d=google.com; s=arc-20160816; b=m47fenc7fk/Of2edFgICP4N1iw6Iy08scTLZG8mHbz9X6lFl9mNxWVrDz/255R1pvh xbz8ltY2oUC3BE+bFczj7O5psze0dQE7ujQohqU9KNW676RB/hyKOzh7YBK2qlso2Gnf BTqay4EVPsDV0xrcuattqaG4X18liog/yMID27JlpHz4l8Uu6YoKTcdNzah1Xgqec53x R8Fhw30+iL0LNlddDagBe7f6mr5Go/8bwnqDuYiXsovTo4RnigIdLyDRhws3T75R/G60 Fdi4a8oq3M6Kll9ewz2Tu8O4hL8qCOvdsXurhO6N3nyvvuhXuS6ORyV6taskl+TG4+Jv XdOw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:user-agent:references :in-reply-to:message-id:date:subject:cc:to:from; bh=5LMaYms4ckNSVhzzMDcK3TWfvGO6y9FC1eL+CT/nMYY=; b=Yq2UcqgEFfei6QLDBeL342esHDMmPahmWucazZFLJAt/M4m8c5kcWH6vJe3wnYE+EM Z3fVKq7R+dpdLRe5rJjNsy/6SrPvWPx8EDk936VygVLyUeOIfrSzv8bGZufRs02Z5kgR 2JnheCG5I98DqclfdjYOeUStcJ9dpsa5f5ou1QoqZfVGq52I2fusHe88Pox01a4HDNKy FOsXob4QXl7YF6WAAx4NdZm/if5t8AaOrkCKV/SjPK+EVMFXrPpAaQHBK6q1SVfOsa/W S+liNvd2CRfKDxJiYvc8yjxJ8OuClc0tYYglzymt2Qu2nlkAD7wGzVHvYMVcvPQ/Z2x+ P3zw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of gregkh@linuxfoundation.org designates 140.211.169.12 as permitted sender) smtp.mailfrom=gregkh@linuxfoundation.org Received: from mail.linuxfoundation.org (mail.linuxfoundation.org. [140.211.169.12]) by mx.google.com with ESMTPS id r8-v6si1151439plo.516.2018.09.24.05.32.41 for <linux-mm@kvack.org> (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 24 Sep 2018 05:32:41 -0700 (PDT) Received-SPF: pass (google.com: domain of gregkh@linuxfoundation.org designates 140.211.169.12 as permitted sender) client-ip=140.211.169.12; Authentication-Results: mx.google.com; spf=pass (google.com: domain of gregkh@linuxfoundation.org designates 140.211.169.12 as permitted sender) smtp.mailfrom=gregkh@linuxfoundation.org Received: from localhost (ip-213-127-77-73.ip.prioritytelecom.net [213.127.77.73]) by mail.linuxfoundation.org (Postfix) with ESMTPSA id D0A4C1099; Mon, 24 Sep 2018 12:32:40 +0000 (UTC) From: Greg Kroah-Hartman <gregkh@linuxfoundation.org> To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>, stable@vger.kernel.org, Joerg Roedel <jroedel@suse.de>, Thomas Gleixner <tglx@linutronix.de>, Pavel Machek <pavel@ucw.cz>, "H . Peter Anvin" <hpa@zytor.com>, linux-mm@kvack.org, Linus Torvalds <torvalds@linux-foundation.org>, Andy Lutomirski <luto@kernel.org>, Dave Hansen <dave.hansen@intel.com>, Josh Poimboeuf <jpoimboe@redhat.com>, Juergen Gross <jgross@suse.com>, Peter Zijlstra <peterz@infradead.org>, Borislav Petkov <bp@alien8.de>, Jiri Kosina <jkosina@suse.cz>, Boris Ostrovsky <boris.ostrovsky@oracle.com>, Brian Gerst <brgerst@gmail.com>, David Laight <David.Laight@aculab.com>, Denys Vlasenko <dvlasenk@redhat.com>, Eduardo Valentin <eduval@amazon.com>, Will Deacon <will.deacon@arm.com>, aliguori@amazon.com, daniel.gruss@iaik.tugraz.at, hughd@google.com, keescook@google.com, Andrea Arcangeli <aarcange@redhat.com>, Waiman Long <llong@redhat.com>, "David H . Gutteridge" <dhgutteridge@sympatico.ca>, joro@8bytes.org, Sasha Levin <alexander.levin@microsoft.com> Subject: [PATCH 4.18 096/235] x86/mm/pti: Add an overflow check to pti_clone_pmds() Date: Mon, 24 Sep 2018 13:51:22 +0200 Message-Id: <20180924113114.858873958@linuxfoundation.org> X-Mailer: git-send-email 2.19.0 In-Reply-To: <20180924113103.999624566@linuxfoundation.org> References: <20180924113103.999624566@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
None
|
expand
|
--- a/arch/x86/mm/pti.c +++ b/arch/x86/mm/pti.c @@ -306,6 +306,10 @@ pti_clone_pmds(unsigned long start, unsi p4d_t *p4d; pud_t *pud; + /* Overflow check */ + if (addr < start) + break; + pgd = pgd_offset_k(addr); if (WARN_ON(pgd_none(*pgd))) return;