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 X-Spam-Level: X-Spam-Status: No, score=-11.3 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 0EE66C43465 for ; Mon, 21 Sep 2020 14:40:30 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C15A922574 for ; Mon, 21 Sep 2020 14:40:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (1024-bit key) header.d=redhat.com header.i=@redhat.com header.b="e9bgo7aD" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727776AbgIUOk2 (ORCPT ); Mon, 21 Sep 2020 10:40:28 -0400 Received: from us-smtp-delivery-124.mimecast.com ([216.205.24.124]:51763 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727610AbgIUOk1 (ORCPT ); Mon, 21 Sep 2020 10:40:27 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1600699226; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=+enI0R7DMCyjAKerCPgkYFbbuWxHbIO4MyCZsWUDDyc=; b=e9bgo7aDnMqIdiImJBlvJB4rbph0IWPNqlQ7zwZzQqPbO+JhIx+hXIwZOVvc2Ll+l4GPBn 910DubhAauVDWzG+DU/AVcqmuLI3g1Wm9ILNbHXK4X8jUhdrRvvBh+3pbdWFvIWqVVCWuc TB+kbwKhGIUt+gdHWgTBB5l26fTOvBE= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-343-PhKmVfuPMJ-JDwgUEL8ctA-1; Mon, 21 Sep 2020 10:40:20 -0400 X-MC-Unique: PhKmVfuPMJ-JDwgUEL8ctA-1 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 1C0D2802B4A; Mon, 21 Sep 2020 14:40:16 +0000 (UTC) Received: from x1.bristot.me.redhat.com (ovpn-113-39.rdu2.redhat.com [10.10.113.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 7248A60BF4; Mon, 21 Sep 2020 14:40:06 +0000 (UTC) From: Daniel Bristot de Oliveira To: linux-kernel@vger.kernel.org, Ingo Molnar , Peter Zijlstra Cc: "J . Avila" , Wei Wang , Todd Kjos , Daniel Bristot de Oliveira , Juri Lelli , Vincent Guittot , Dietmar Eggemann , Steven Rostedt , Ben Segall , Mel Gorman , Thomas Gleixner Subject: [PATCH] sched/rt: Disable RT_RUNTIME_SHARE by default Date: Mon, 21 Sep 2020 16:39:49 +0200 Message-Id: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.12 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The RT_RUNTIME_SHARE sched feature enables the sharing of rt_runtime between CPUs, allowing a CPU to run a real-time task up to 100% of the time while leaving more space for non-real-time tasks to run on the CPU that lend rt_runtime. The problem is that a CPU can easily borrow enough rt_runtime to allow a spinning rt-task to run forever, starving per-cpu tasks like kworkers, which are non-real-time by design. This patch disables RT_RUNTIME_SHARE by default, avoiding this problem. The feature will still be present for users that want to enable it, though. Signed-off-by: Daniel Bristot de Oliveira Cc: Ingo Molnar Cc: Peter Zijlstra Cc: Juri Lelli Cc: Vincent Guittot Cc: Dietmar Eggemann Cc: Steven Rostedt Cc: Ben Segall Cc: Mel Gorman Cc: Daniel Bristot de Oliveira Cc: Thomas Gleixner Cc: linux-kernel@vger.kernel.org --- kernel/sched/features.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/sched/features.h b/kernel/sched/features.h index 7481cd96f391..68d369cba9e4 100644 --- a/kernel/sched/features.h +++ b/kernel/sched/features.h @@ -77,7 +77,7 @@ SCHED_FEAT(WARN_DOUBLE_CLOCK, false) SCHED_FEAT(RT_PUSH_IPI, true) #endif -SCHED_FEAT(RT_RUNTIME_SHARE, true) +SCHED_FEAT(RT_RUNTIME_SHARE, false) SCHED_FEAT(LB_MIN, false) SCHED_FEAT(ATTACH_AGE_LOAD, true) -- 2.26.2