From patchwork Tue Jun 6 20:23:10 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Li kunyu X-Patchwork-Id: 103062 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp2438525vqr; Sun, 4 Jun 2023 20:59:04 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ7fgfQOUpQM11hrZuO8YBIcy2MPsnQNeKeEqSN8OMpZkBJGnB0on4e8d7QP8n3gsOpvWeF4 X-Received: by 2002:a17:903:2291:b0:1af:c7f8:b329 with SMTP id b17-20020a170903229100b001afc7f8b329mr7400412plh.24.1685937544379; Sun, 04 Jun 2023 20:59:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685937544; cv=none; d=google.com; s=arc-20160816; b=MkYwmEsDWVOWb/mBysaxzvFjqTuepHdP2mJcxerCMS8bz4g/8CNcXuUXREp2mOXyL3 Tlt+Op8nL8dZLGsIgnbEkG7TN24R9VTFuh74kBfaoT7Uk0eX7E7kTD1HXsEEF8inM/jq B1tRqc18SxJKjAwFuxf+T43srjuhxmEvJn2hTOu3qaZj31Q566bWq59VwTdi4oww9O1/ O/tBRxZLDRQV8WT3HULnZiyGrRCljZ70fn4n/jzNdKbvI39LazL+pcwDJFR5/FCQGNL6 mcUDD4i/4fGt/xfVbffA17wSBCFVdtIcaXEk1AC4tPIxp6L06CaO3WwiagDAMFa5Hflb dC+g== 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 :message-id:date:subject:cc:to:from; bh=m0pCFw8CQhpxROVPaexIzeWEOiE7QQ7mMw62CrJvxIw=; b=blzd2+cvS80VX1nby2W9Z0CmVjTJe2T09Al/yMo2yo9z+rxETapJYYjNQa/EUIw/2o fLCuapAF0hXoH1DWprJ07kfljC4AOHOeIsnHl7hsr0L56BlirgkrHLxfIu1+XF1uX25g nNOAIa8QBsmT9lqchyEjOrhhUOYlQHrQBm9SZVHPwDCB3GXtvzc9XTBREnyevosRuFL7 a7iZ1fv7vO1t/s6PSWWamNhyFakZIJU+N8qnxQVUaiNlVuDvhhYREoY/CPKDtpM5sRYk y45KalkwhRKfhCYwZjrGOayhf8ovjg+wVIksl4uRi5jAZbTYuDnbINUz0ukIraNzgS6/ WCcg== 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 Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id r15-20020a170902be0f00b001a68d4a42c0si4740679pls.560.2023.06.04.20.58.52; Sun, 04 Jun 2023 20:59:04 -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 S232808AbjFEDwQ (ORCPT + 99 others); Sun, 4 Jun 2023 23:52:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39928 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230193AbjFEDwM (ORCPT ); Sun, 4 Jun 2023 23:52:12 -0400 Received: from mail.nfschina.com (unknown [42.101.60.195]) by lindbergh.monkeyblade.net (Postfix) with SMTP id B26D0A6 for ; Sun, 4 Jun 2023 20:52:10 -0700 (PDT) Received: from localhost.localdomain (unknown [219.141.250.2]) by mail.nfschina.com (Maildata Gateway V2.8.8) with ESMTPA id 8A028180034500; Mon, 5 Jun 2023 11:51:50 +0800 (CST) X-MD-Sfrom: kunyu@nfschina.com X-MD-SrcIP: 219.141.250.2 From: Li kunyu To: mingo@redhat.com, peterz@infradead.org, juri.lelli@redhat.com, vincent.guittot@linaro.org, dietmar.eggemann@arm.com, rostedt@goodmis.org, bsegall@google.com, mgorman@suse.de, bristot@redhat.com, vschneid@redhat.com Cc: linux-kernel@vger.kernel.org, Li kunyu Subject: [PATCH] =?utf-8?q?sched=3A_deadline=3A_Remove_unnecessary_=E2=80=98?= =?utf-8?q?NULL=E2=80=99_values_from_p?= Date: Wed, 7 Jun 2023 04:23:10 +0800 Message-Id: <20230606202310.3039-1-kunyu@nfschina.com> X-Mailer: git-send-email 2.18.2 MIME-Version: 1.0 X-Spam-Status: No, score=0.9 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_24_48, RDNS_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=no 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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1767833646762325579?= X-GMAIL-MSGID: =?utf-8?q?1767833646762325579?= p is assigned first, so it does not need to initialize the assignment. Signed-off-by: Li kunyu --- kernel/sched/deadline.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/sched/deadline.c b/kernel/sched/deadline.c index b94a498f8cd9..cbb13a23a5f9 100644 --- a/kernel/sched/deadline.c +++ b/kernel/sched/deadline.c @@ -2104,7 +2104,7 @@ static int pick_dl_task(struct rq *rq, struct task_struct *p, int cpu) */ static struct task_struct *pick_earliest_pushable_dl_task(struct rq *rq, int cpu) { - struct task_struct *p = NULL; + struct task_struct *p; struct rb_node *next_node; if (!has_pushable_dl_tasks(rq))