Received: by 2002:a05:6358:c692:b0:131:369:b2a3 with SMTP id fe18csp5799205rwb; Tue, 1 Aug 2023 08:05:22 -0700 (PDT) X-Google-Smtp-Source: APBJJlFXDmp5I+WyS6enGAJYpTD63A3XOOcleVXbk7cT1p+1a5XqksvHH0x+syOO07wTU6yTs2Cy X-Received: by 2002:a17:90a:5d91:b0:267:f8a2:300a with SMTP id t17-20020a17090a5d9100b00267f8a2300amr11575779pji.7.1690902322548; Tue, 01 Aug 2023 08:05:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1690902322; cv=none; d=google.com; s=arc-20160816; b=dgZqFPIAjp/xGDGtg2jyAC8lwP2cfXsLNYSphDlkqb1VWn4GcH+2B6mpStJN3bBhtV jbu7WF/YV3HGNYvgxRiolvTDebO5fdPTHD+0UtBM5dXdv1NXkNrW9GpO7j/NYgp9JWB4 Hwi3ONdtedZndn2BivovPejB3VO6DD7dMSM37wGaFPw6BQNfeNY7LzRu10EOKCkh+qTS nFIqO1NoN2u+miRn1ibFyQ2GUCbkZ6KJhYbEFWs9Ljg8XWASBEL6tZbVWI3b+2apMQRd KdTd07dlEfA3rYzOuVHEsQwGUWtcoRI1C7m2TjPw4ebtg7c/t655Qg/oJg8ATQ4czGYN kSUQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=Up5HqNpxVVFXlEAHoTXsXWFje3WxCstms1Fjfa+LTVY=; fh=OMxxFdn5xPz5yjy3ZMfC5eNo17KizmU+vtQoaSHpS9E=; b=GxUkM5zXXHd1CinF90ssyBr8gNt1P3Pyip12YPChWN6Aa57Hd2MOpBVOkCT916RJzT X79jIO05aGkE5C68TQ5D1GAvfLfeJZmp6+pVhV5sU4ArAcND9qIoqweuZwNk1Tj9V3Ov 5u6lFJyRo0VhSPROp6H78SqwimEk56Pu/gcJadDv13bBYcfLifXNpvkjb9FMDXeT/+ib E1PUvGTfVTkhFS82tbIfKLVhvRR802SXLJSydHo2TcpGKK8RrJHUtXeGaqaFg1Vf8Z8c XeewrFrx2wbyuLurzku3rPK1p14ArWnMJKr40QTCkpCKpda/xMdPt36NydOs9oqLh9E2 C7SA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q7-20020a170902a3c700b001bb162e944dsi6062405plb.51.2023.08.01.08.04.58; Tue, 01 Aug 2023 08:05:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234268AbjHAODN (ORCPT + 99 others); Tue, 1 Aug 2023 10:03:13 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57490 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234582AbjHAODH (ORCPT ); Tue, 1 Aug 2023 10:03:07 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BB6512130 for ; Tue, 1 Aug 2023 07:02:51 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 276C6615B8 for ; Tue, 1 Aug 2023 14:02:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 68729C433C7; Tue, 1 Aug 2023 14:02:49 +0000 (UTC) Date: Tue, 1 Aug 2023 10:02:47 -0400 From: Steven Rostedt To: Yajun Deng Cc: mingo@redhat.com, peterz@infradead.org, juri.lelli@redhat.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, bsegall@google.com, mgorman@suse.de, bristot@redhat.com, vschneid@redhat.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH] sched/rt: move back to RT_GROUP_SCHED and rename it child Message-ID: <20230801100247.169b3a9c@gandalf.local.home> In-Reply-To: <20230801100030.5efec7e2@gandalf.local.home> References: <20230801062714.3424299-1-yajun.deng@linux.dev> <20230801100030.5efec7e2@gandalf.local.home> X-Mailer: Claws Mail 3.19.1 (GTK+ 2.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-4.0 required=5.0 tests=BAYES_00, HEADER_FROM_DIFFERENT_DOMAINS,RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 1 Aug 2023 10:00:30 -0400 Steven Rostedt wrote: > On Tue, 1 Aug 2023 14:27:14 +0800 > Yajun Deng wrote: > > > @@ -228,13 +228,10 @@ void init_tg_rt_entry(struct task_group *tg, struct rt_rq *rt_rq, > > if (!rt_se) > > return; Ah, I missed the second part of your change log where you said parent is only NULL when rt_se is NULL. I would then add: if (!rt_se) return; if (WARN_ON_ONCE(!parent)) return; -- Steve > > > > - if (!parent) > > - rt_se->rt_rq = &rq->rt; > > - else > > - rt_se->rt_rq = parent->my_q; > > - > > + rt_se->rt_rq = parent->my_q; > > So when this is called with parent = NULL, this will crash? > > -- Steve > > > rt_se->my_q = rt_rq; > > rt_se->parent = parent; > > + parent->child = rt_se; > > INIT_LIST_HEAD(&rt_se->run_list); > > } > >