Received: by 2002:ab2:710b:0:b0:1ef:a325:1205 with SMTP id z11csp1434194lql; Tue, 12 Mar 2024 18:25:35 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWU87//m+g7cAgd2pjci7/eSoFShD9B9VejALCtW6/K80iEKXRg4Y1mDlqvNwSXMwEY1YFY6NkuZiz/9PHc7MJrJEsxMXd2WmXD/uEoAQ== X-Google-Smtp-Source: AGHT+IHw4S0FDJdVS3zLE4XJPBfcqjvdP6ehIcCgHEAFBvkI3a2lujLSuOrju2raizwLyJ7qLVqk X-Received: by 2002:a05:6808:2e99:b0:3c2:5236:6938 with SMTP id gt25-20020a0568082e9900b003c252366938mr8428680oib.29.1710293135247; Tue, 12 Mar 2024 18:25:35 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710293135; cv=pass; d=google.com; s=arc-20160816; b=JnCIsUHuq76j2qNwFM7TfLWMTeLar7fCV7AnJNss2mB1O0ZPR9ZTRooEe6mR85sRos 5RixGF2gZd6NGMO6XV55ivNoLJA6s5/X9jZVWynRsxLZJKCqFSuvUgu7UCADHwxk8lxq l1XIjwPHXuGK6YjL+9nnpAEz2SxiM6qpf+pJkp+ViO3UbAu1FyyYPvjqJSMpT+gFyJ1N k6EsUtwlFYi8Jp35AhjuPWfA88DtV9/27USBshE89S4Z+I4u30acMjH8B9EnG+V4L0zA xnBRppDsvToJ4jf394nSFS+DVkkUeP2oU4nVyOvDs2w4DTZa4Gi81Nw3uatrtbN9swPJ zNlw== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=eIq/RsKJ+ZDmqaV4DNR53VSSNnL2VAVCUisag/qJ124=; fh=QKvmJ7gTQNDYX26cKmMd3Q4+uQjEbBu+6bD4aQXMqzg=; b=sNrLb72U1vVF79i9aUp1vVbS4iaGFzA5t4yocvGPqz8mQIHioX1SfiJpCsDSIdAClt s6GibpvAZ7yrd3/VRIGtMF4JIjs19RfLf0EnfNu5imALzb7HVh6SsRfQf3kWxex4Dkuo teUQiEnP3/AxgzrWadAW9KZZoVxH2SCFajJdhbBUKcJbviqovWJOSZqGXR1GkMHVnHMg sIe45NO0S04nPAiwaW8ugeoJh74cRr1XF5lLPqBYAYC6s+IFbKRrlaNcZxw6xP2NMBA6 /Zl/d195ztnTMV3an7Gv/zjXdEcndptsOtXWXf83XtPljyKypvJgywe2DvUHBenKnMOp 2qlw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=w0SRTMg6; arc=pass (i=1 spf=pass spfdomain=joelfernandes.org dkim=pass dkdomain=joelfernandes.org); spf=pass (google.com: domain of linux-kernel+bounces-101002-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-101002-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id kc21-20020a056214411500b006909599ce30si8795657qvb.240.2024.03.12.18.25.35 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Mar 2024 18:25:35 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-101002-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=w0SRTMg6; arc=pass (i=1 spf=pass spfdomain=joelfernandes.org dkim=pass dkdomain=joelfernandes.org); spf=pass (google.com: domain of linux-kernel+bounces-101002-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-101002-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id EDB5F1C21554 for ; Wed, 13 Mar 2024 01:25:34 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 14099F9CB; Wed, 13 Mar 2024 01:25:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=joelfernandes.org header.i=@joelfernandes.org header.b="w0SRTMg6" Received: from mail-qv1-f48.google.com (mail-qv1-f48.google.com [209.85.219.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id BD566BA2D for ; Wed, 13 Mar 2024 01:25:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.48 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710293110; cv=none; b=ASN3kY4rzK5piSEHTJoXt5W1BQluBH2gMvQEigDDqMQmPhTTW44fcjVXLSX8iV/4fSsQWWLDWwwSSjgHinUm/Eg1zkOEWhAO58kA8JJrB12O+ayQzHRcyqYq62lVOOrjZb4pD3pqXpFpvWhESjF8gxH+BhtFqwaWI+67lEEqPcM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710293110; c=relaxed/simple; bh=ZOaTdU6+mkYKcu73jBNLA/JSAJmZHt+8O8zlVTj/AiM=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=Agtm3yqktSlEAoaTH/nyRjQUsfLuo7gxziGCijoYc6tgTeec6Cqm42Xc8KAR4xv6xzA0cXJXEhAofuhwHc/7xwUm+MpqDjXfnkKaIl7Jx/KefY6BIdOMBJS/ZCnrVnveTT86qTGgIdUksC+RbBcHTMQyT8U3y+o8qBs7ts4XVCE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=joelfernandes.org; spf=pass smtp.mailfrom=joelfernandes.org; dkim=pass (1024-bit key) header.d=joelfernandes.org header.i=@joelfernandes.org header.b=w0SRTMg6; arc=none smtp.client-ip=209.85.219.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=joelfernandes.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=joelfernandes.org Received: by mail-qv1-f48.google.com with SMTP id 6a1803df08f44-690b7ce0f59so29559736d6.3 for ; Tue, 12 Mar 2024 18:25:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; t=1710293107; x=1710897907; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=eIq/RsKJ+ZDmqaV4DNR53VSSNnL2VAVCUisag/qJ124=; b=w0SRTMg66QtBoU7h+Z5j+J5aWX6/gFxCfpQxwqeNuIBHTFJaz7lRwD3JDScgLJj0Ig qlB7+LRw0JURaKW62YheWAAL5yAUDD7Ls61oWyNG/8AEq5/kirbuvZjdjK2dagK0Famw 6ZaYGfSRr3n29cXqyCfFkOdSh/XVB2hnkb+G8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1710293107; x=1710897907; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=eIq/RsKJ+ZDmqaV4DNR53VSSNnL2VAVCUisag/qJ124=; b=iaCuzAtdZVEwsKXypVr6z8lGdJ9nGLMCgoFc054ZllR6Non3wYsBu0syA7dzeABFZN bgYPTvHyf3shwjmmQHdkY/ibyGGhPNpCEXk5RpRPLfFG2p7rHVTPdNFQYHnG1BWMnP2U MJP3CoLm+i7H4LIdW0xHd8EyTb7hstxmHwvyc2DBQ/wYcJhnz7iAvgbQG11NVWifr/jy dQLAs35pSjf9JH1aRhxgn+BNKQEC6ftxrxs/XrpyAw1cPXV5PRUvHiC8pw6AlMl4OnMw 01XOaicwU/x3xRQOPZ8xm1JRoTqTup4nTzxDo5MCEcrIDbi6QOFrlQ/S4rmhNdGoBaaX ps7A== X-Gm-Message-State: AOJu0Yx/RzQdVLQioPS4eJbrMRrgiD+y/K4Ff/b2OQ2DftGLjS7GSGHo +MLtzmihN2hr3iu0kCq+NtJUDoRmDDmE+iyFPCxpCkl1aS9rPQvJgJdK8E5ATZG1ixFIQwXrHO9 U X-Received: by 2002:a05:6214:888:b0:690:e2b5:9219 with SMTP id cz8-20020a056214088800b00690e2b59219mr4643667qvb.22.1710293106976; Tue, 12 Mar 2024 18:25:06 -0700 (PDT) Received: from joelbox2.. (c-98-249-43-138.hsd1.va.comcast.net. [98.249.43.138]) by smtp.gmail.com with ESMTPSA id u9-20020a05621411a900b00690314356a4sm4162132qvv.80.2024.03.12.18.25.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Mar 2024 18:25:06 -0700 (PDT) From: "Joel Fernandes (Google)" To: linux-kernel@vger.kernel.org, Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Daniel Bristot de Oliveira , Valentin Schneider Cc: Suleiman Souhlal , Youssef Esmat , David Vernet , Thomas Gleixner , "Paul E . McKenney" , joseph.salisbury@canonical.com, Luca Abeni , Tommaso Cucinotta , Vineeth Pillai , Shuah Khan , Phil Auld , Joel Fernandes Subject: [PATCH v2 02/15] sched/core: Clear prev->dl_server in CFS pick fast path Date: Tue, 12 Mar 2024 21:24:38 -0400 Message-Id: <20240313012451.1693807-3-joel@joelfernandes.org> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240313012451.1693807-1-joel@joelfernandes.org> References: <20240313012451.1693807-1-joel@joelfernandes.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit From: Youssef Esmat In case the previous pick was a DL server pick, ->dl_server might be set. Clear it in the fast path as well. Signed-off-by: Youssef Esmat Signed-off-by: Joel Fernandes (Google) --- kernel/sched/core.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 7f3a2596c1ed..63f41453b79e 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c @@ -6036,6 +6036,13 @@ __pick_next_task(struct rq *rq, struct task_struct *prev, struct rq_flags *rf) p = pick_next_task_idle(rq); } + /* + * This is a normal CFS pick, but the previous could be a DL pick. + * Clear it as previous is no longer picked. + */ + if (prev->dl_server) + prev->dl_server = NULL; + /* * This is the fast path; it cannot be a DL server pick; * therefore even if @p == @prev, ->dl_server must be NULL. -- 2.34.1