From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B8C2AC7EE23 for ; Tue, 23 May 2023 14:12:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S237207AbjEWOMj (ORCPT ); Tue, 23 May 2023 10:12:39 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48410 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236851AbjEWOMU (ORCPT ); Tue, 23 May 2023 10:12:20 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6E4EE1733 for ; Tue, 23 May 2023 07:11:59 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id DF6496284B for ; Tue, 23 May 2023 14:11:58 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id A3F83C433D2; Tue, 23 May 2023 14:11:55 +0000 (UTC) Date: Tue, 23 May 2023 15:11:52 +0100 From: Catalin Marinas To: Florent Revest Cc: linux-kernel@vger.kernel.org, linux-mm@kvack.org, akpm@linux-foundation.org, anshuman.khandual@arm.com, joey.gouly@arm.com, mhocko@suse.com, keescook@chromium.org, david@redhat.com, peterx@redhat.com, izbyshev@ispras.ru, broonie@kernel.org, szabolcs.nagy@arm.com, kpsingh@kernel.org, gthelen@google.com, toiwoton@gmail.com Subject: Re: [PATCH v2 3/5] mm: Make PR_MDWE_REFUSE_EXEC_GAIN an unsigned long Message-ID: References: <20230517150321.2890206-1-revest@chromium.org> <20230517150321.2890206-4-revest@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230517150321.2890206-4-revest@chromium.org> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 17, 2023 at 05:03:19PM +0200, Florent Revest wrote: > Alexey pointed out that defining a prctl flag as an int is a footgun > because, under some circumstances, when used as a flag to prctl, it can > be casted to long with garbage upper bits which would result in > unexpected behaviors. > > This patch changes the constant to a UL to eliminate these > possibilities. > > Signed-off-by: Florent Revest > Suggested-by: Alexey Izbyshev FWIW, I'm fine with this patch and I don't think it introduces an ABI change. Acked-by: Catalin Marinas