Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id A4BE1C0015E for ; Wed, 19 Jul 2023 23:57:50 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 0DEA786879; Thu, 20 Jul 2023 01:52:20 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="hnwp/0Mg"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 20F02867F0; Thu, 20 Jul 2023 01:50:44 +0200 (CEST) Received: from mail-io1-xd2a.google.com (mail-io1-xd2a.google.com [IPv6:2607:f8b0:4864:20::d2a]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 94FA385E73 for ; Thu, 20 Jul 2023 01:50:38 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd2a.google.com with SMTP id ca18e2360f4ac-78625caa702so7771539f.1 for ; Wed, 19 Jul 2023 16:50:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1689810637; x=1690415437; 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=lGDWTsdt+9Zrdp4zkKL9dvAMjLiRJAJ2YxxdcqIbY1k=; b=hnwp/0MgKovrOSBCgZcCIpl3vYpq920ZkB6MonYfgS3A2CEG4znHJzhJ+oZDJpktw4 Qk8X5Fr962JM4uYwU3YogoK5idqpce3IuJKEdUHjo3HKwxIeP3MwD4ugrBILUHoOZcf0 6lE1I9weZlyUlbXQmToPsjRKcXwtAsrbOfFHg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689810637; x=1690415437; 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=lGDWTsdt+9Zrdp4zkKL9dvAMjLiRJAJ2YxxdcqIbY1k=; b=Oo4AOomEVH/leO668X8IKkh5AljW6PisTIaI9iOe3ep0uWDsUSQn60xMzVmdEj7bVm 5WZY8rWF7tloNu8k6l487GWO4/M8BJYG8wX/1EbUqk6lt3ZUtAPrCXRiiAbsnEFQsuGs qgC3xZbaz8cQGVekwDZEvyJIySlv9EDRSsmC/wNJGMmRDiJwJS96tsHwj5SCRShIrdBQ io0baLLD6l4qkcCBi3+44jVjReFpOVLAaA9zsiHlausvxj8Rz2HTQLV5nl7rxCTfcnOq rGt1ZQ4++GFetfIs1VXgu05LR17JDG2iyk8ecP8bJacjKNxIzAjHln1RkV6vVd6KeT8b my/w== X-Gm-Message-State: ABy/qLYgp1Uag5NdEgoMLsjcFxNrwT3q1DknerBr1GBmsZfZnuIUnI+M H3TzfN1AJcuGecencuiX9etaPAjXNpgLcJ/Ck6Y= X-Google-Smtp-Source: APBJJlFS4liNBfn/Yyx3kv6pk0HC5OGVnp7h2R//+0iwly1KgIMf3sjZnvNK47UXnpGPmzuGrA6Pog== X-Received: by 2002:a6b:661a:0:b0:785:d4f5:2225 with SMTP id a26-20020a6b661a000000b00785d4f52225mr799145ioc.19.1689810637154; Wed, 19 Jul 2023 16:50:37 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id ed16-20020a056638291000b0042bb1779c18sm1551779jab.151.2023.07.19.16.50.36 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 19 Jul 2023 16:50:36 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Mike Frysinger , Simon Glass Subject: [PATCH v4 51/83] buildman: Use get_alow_missing() directly to avoid var Date: Wed, 19 Jul 2023 17:48:59 -0600 Message-ID: <20230719234953.796101-52-sjg@chromium.org> X-Mailer: git-send-email 2.41.0.487.g6d72f3e995-goog In-Reply-To: <20230719234953.796101-1-sjg@chromium.org> References: <20230719234953.796101-1-sjg@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean Avoid an unnecessary local variable by moving this code to a function. This fixes the pylint warning about too many local variables. Signed-off-by: Simon Glass --- (no changes since v1) tools/buildman/control.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/tools/buildman/control.py b/tools/buildman/control.py index a20fa6286f72..b388d760ba4a 100644 --- a/tools/buildman/control.py +++ b/tools/buildman/control.py @@ -603,10 +603,6 @@ def do_buildman(options, args, toolchains=None, make_func=None, brds=None, options.verbose) return 0 - allow_missing = get_allow_missing(options.allow_missing, - options.no_allow_missing, len(selected), - options.branch) - # Create a new builder with the selected options builder = Builder(toolchains, output_dir, git_dir, options.threads, options.jobs, checkout=True, @@ -622,7 +618,10 @@ def do_buildman(options, args, toolchains=None, make_func=None, brds=None, test_thread_exceptions=test_thread_exceptions, adjust_cfg=calc_adjust_cfg(options.adjust_cfg, options.reproducible_builds), - allow_missing=allow_missing, no_lto=options.no_lto, + allow_missing=get_allow_missing(options.allow_missing, + options.no_allow_missing, + len(selected), options.branch), + no_lto=options.no_lto, reproducible_builds=options.reproducible_builds, force_build = options.force_build, force_build_failures = options.force_build_failures, -- 2.41.0.487.g6d72f3e995-goog