Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp270051pxb; Thu, 25 Feb 2021 01:56:05 -0800 (PST) X-Google-Smtp-Source: ABdhPJxTEEpymOv5Fqo31PBP03qKaYbD14aRDRGS8ACfXpfLioObPAH2Fd5Qfzoqwl0r5KZk+3nU X-Received: by 2002:a05:6402:1201:: with SMTP id c1mr2047024edw.379.1614246965382; Thu, 25 Feb 2021 01:56:05 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1614246965; cv=none; d=google.com; s=arc-20160816; b=0qSZMzKaKWSBqpAc6POCfxWlOHLXFegm66HeLc77NUKAA1c446lB60mS+CLuYD2Rdh i2RzMwBryZy37AZA1vZhhxCx02IyJnWhuG/WQyaws4IcA01A5cBCjImv2ABeeW3Ch1ku 8NuuQEno3i5XjO8culfcjTEjJqhqQ6DntJugmwYT3juhOX+k53BvnzU0CedfsCbUgVhL vr+03x6kvrgLw2YSWHQ9Oo0WDx2p3aNkzTrSciO33pCE8oYR1I27PX39P8EJ5RRzeybb h+RgRS0sjIYWuwn5o7VkF810X+yfeysR1vPwcSHUnVOFgbaZ6GWDJGR5W8oUbvn25f5/ iXgQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=73AkoZhFQqiT5A98ge2GBiv+sajdq8CRILQetyBneUI=; b=RxXq6SRnc3p3xVR9XVyE+EQ603auCNQRXIT1kwWcFn+PEr/gTdTPB1vB7KkJWnPeNW 2UZdz61zxZG8lh55W14JSk3FP3y4gcTMAzAgC6Ruc3nwF20qmDI90hofNbKJ/0y4zcrW CWevX45lpS3K4FJKzxCMg8LFce1GmCKVefSnjVpu7XEgmsw0LiplEpiR+u2quCAH3Blz c9L0d5pNcOKF2lKmG4T5oJgs/IheoNeipMfskGLRzT1G0mN8WSMxiXIvYUiE4VBbR2Z+ uYnCaKCb46eCxsDFQySHPeDRYsgEvJJlxaqi/6iW9bdiJQkRNjssOD6W5f6zFblYgfGN b5uA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=XRsybevj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id m23si1636140ejr.429.2021.02.25.01.55.42; Thu, 25 Feb 2021 01:56:05 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=XRsybevj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235840AbhBYI0W (ORCPT + 99 others); Thu, 25 Feb 2021 03:26:22 -0500 Received: from mail.kernel.org ([198.145.29.99]:38850 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232601AbhBYI0V (ORCPT ); Thu, 25 Feb 2021 03:26:21 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 73F0664EC8; Thu, 25 Feb 2021 08:25:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1614241540; bh=RwokqPiVETJX28uISu7iObNBcTWEjC5c9EqPt2h2nJk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=XRsybevjiPEkWP/o9R8jrmCnFCRbb3pJmgoSoJdt06Iq1u/iUKLpSJ8r3AfflNXjm KAmVf48u8WRsfAZADyNPmMaGNxCT65WYVV8QxaS8q9E69GquFeptfB4jrQFfGWCvc/ 7QP5OO4hA05OmT0stAGMVSMPYP1mZ2MNuzzEmJfI= Date: Thu, 25 Feb 2021 09:25:37 +0100 From: Greg KH To: Xiaoming Ni Cc: linux-kernel@vger.kernel.org, stable@vger.kernel.org, sashal@kernel.org, tglx@linutronix.de, lee.jones@linaro.org, wangle6@huawei.com, zhengyejian1@huawei.com Subject: Re: [PATCH] futex: fix dead code in attach_to_pi_owner() Message-ID: References: <20210222125352.110124-1-nixiaoming@huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210222125352.110124-1-nixiaoming@huawei.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Feb 22, 2021 at 08:53:52PM +0800, Xiaoming Ni wrote: > From: Thomas Gleixner > > The handle_exit_race() function is defined in commit c158b461306df82 > ("futex: Cure exit race"), which never returns -EBUSY. This results > in a small piece of dead code in the attach_to_pi_owner() function: > > int ret = handle_exit_race(uaddr, uval, p); /* Never return -EBUSY */ > ... > if (ret == -EBUSY) > *exiting = p; /* dead code */ > > The return value -EBUSY is added to handle_exit_race() in upsteam > commit ac31c7ff8624409 ("futex: Provide distinct return value when > owner is exiting"). This commit was incorporated into v4.9.255, before > the function handle_exit_race() was introduced, whitout Modify > handle_exit_race(). > > To fix dead code, extract the change of handle_exit_race() from > commit ac31c7ff8624409 ("futex: Provide distinct return value when owner > is exiting"), re-incorporated. > > Fixes: c158b461306df82 ("futex: Cure exit race") > Cc: stable@vger.kernel.org # 4.9.258-rc1 > Signed-off-by: Xiaoming Ni > --- > kernel/futex.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) What is the git commit id of this patch in Linus's tree? Also, what kernel tree(s) is this supposed to go to? thanks, greg k-h