Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp2389970rwl; Thu, 6 Apr 2023 09:32:27 -0700 (PDT) X-Google-Smtp-Source: AKy350ZHgQOwparJTZpueBoLwXehK9JCCQE9VwvFU2oKGidad3O39zEaEeJUS5BbPm7I736j2sCv X-Received: by 2002:aa7:cfcd:0:b0:4fd:1f7b:9fbd with SMTP id r13-20020aa7cfcd000000b004fd1f7b9fbdmr5293337edy.6.1680798747431; Thu, 06 Apr 2023 09:32:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680798747; cv=none; d=google.com; s=arc-20160816; b=IsZgRXYVrBWEYSbjVn+BRt1LA+sgKR2PvxakSS7fNlW4oqaitn1gbkjYbHlRsm8e6Y YhXmeMOpR153J2OINiKpyITjyJwYkVunIXf7QoOULUMs4kPjnomh4ZIdENUyPvI41gce AC2O3GsO0L9HCbfVImpFgw+kc+SwnvlU/lEvXcRoruBIiKlGRZFqroWK7oxs0CKUx4Q5 TgkNPq0Ze5Fv0w/z+I/SEx4eAKY6lzOeK7RtSLgEV+FWsVGxwK+QCROrMtXBF5LKa+Ir UxYUOCZz0i/lR3BreAyao4T292NWGra/hQpco9ng/IpnZ1wf3edBuO2axmSnZ0nIl16M My4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :dkim-signature; bh=VMmjScjE4fSobcxRFtJRkTN0pXnWi1cXS6+vTBexdw0=; b=C8uSjhW+AXyP4CGnvEwdwH80urTdOwtlRUqiEEeQrVn8xTfvPfoKIwfQIRQtg42o7/ kwmVJ5OegA4lxAUExYhR6fzSI8L3Eq99FoKpU2C3yNF6Bq6x6AzRILMw7JYfsVn1bFIm tTW1eXJQz0Ty7k3uSrLmnr7mdhRalgST+mFXCPhfRczdLQkmvJS1dkLqX8c6roPzq5L2 34utb110RT9CCEXLt6l/6FsJpqDmMDntiX2hRIGeWNwUhSM6QjWfZUzAu3FNpRRe1Cdc 3q8sbBXp8R4fPbnrt6eQc0f+V/clHWxsYIExINA615pHimSCvszbhQjWPwncMXvH4dOD mfug== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="L/eHlr/0"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id o11-20020aa7c50b000000b004fac11e70adsi1422685edq.637.2023.04.06.09.32.02; Thu, 06 Apr 2023 09:32:27 -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; dkim=pass header.i=@kernel.org header.s=k20201202 header.b="L/eHlr/0"; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S239363AbjDFQTt (ORCPT + 99 others); Thu, 6 Apr 2023 12:19:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239409AbjDFQTr (ORCPT ); Thu, 6 Apr 2023 12:19:47 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id CB7A526B2; Thu, 6 Apr 2023 09:19:46 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 672CB63E6A; Thu, 6 Apr 2023 16:19:46 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0B02FC433A1; Thu, 6 Apr 2023 16:19:43 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1680797985; bh=hamVzMz9fjIydQKzWnoxc8ljm2X/SGTmnnWMknPU8qo=; h=From:Date:Subject:References:In-Reply-To:To:Cc:From; b=L/eHlr/0i1MzCIAN1gHxc/YruWy3HG/FCt5fT8+ediYZVUMjiy/ecDx3D3dAkjtnJ hOkNU1KOAW24YeiYfm+qrEdwMkuNxVoKL0ZSBn8VHjb4vE7o8WNLJIGJ4gSYVGhvLa 6ip7Rt8HWIkeMcOT2aVm0/5ZhxNqqW+gJo9o/lwIKwahWAD00jPZPfBCnZyFukutdt fyRDHY+JIrRwXEXH5P6R1sb4D4NFNQ+/L8DtVX/ui9faJmwETABC3pEBVL9KJoNXdM krGbIoMTE0yXG5fCZn97ywZ76FkoHdCMqzo1Q2DfmC0LdcGwR9eX4IvcwvfJDxD4K2 IjKqX6Hiee6Rw== From: Mark Brown Date: Thu, 06 Apr 2023 17:19:10 +0100 Subject: [PATCH v2 1/3] tools/nolibc/stdio: Implement vprintf() MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20230405-kselftest-nolibc-v2-1-2ac2495814b5@kernel.org> References: <20230405-kselftest-nolibc-v2-0-2ac2495814b5@kernel.org> In-Reply-To: <20230405-kselftest-nolibc-v2-0-2ac2495814b5@kernel.org> To: Shuah Khan , Catalin Marinas , Will Deacon , "Paul E. McKenney" , Willy Tarreau Cc: linux-arm-kernel@lists.infradead.org, linux-kselftest@vger.kernel.org, linux-kernel@vger.kernel.org, Mark Brown X-Mailer: b4 0.13-dev-00303 X-Developer-Signature: v=1; a=openpgp-sha256; l=867; i=broonie@kernel.org; h=from:subject:message-id; bh=hamVzMz9fjIydQKzWnoxc8ljm2X/SGTmnnWMknPU8qo=; b=owEBbQGS/pANAwAKASTWi3JdVIfQAcsmYgBkLvEb/1QElH3jcf6mGR0Yr87YFxIWpB05FFQCPzUj d6UsAiOJATMEAAEKAB0WIQSt5miqZ1cYtZ/in+ok1otyXVSH0AUCZC7xGwAKCRAk1otyXVSH0E9VB/ 42fwyW20SjTj5Mg8Kks8LM/BQ3Rju1MQCEqx/puiJcz9ORzkHriIPJwp9O38Cij4AjZrb1JKVrSFi+ q8sePpQWXhEVu0NSjFJEg4ASrufsht6yNYSKLzeYS9GfOrHdWAa/46bRqWcp6Cay6qHtahrgfHXcV5 Lm0yyFGNzR8BikcOeAfljY3fydwpW08lyuHf1ig1EvBiDBsnoq+GxFm3URSgxvpKJ5laouaoV/c1zb RqnxACr9T90ChkaB/Y5L11TBfBMGDemXGsDvqwSrn3exOuFkP7+n0o9Puiraf+zbBwWc+tcybdgnwV 3QBfbxocQdxADvPwS9xH9Ace4PvXfZ X-Developer-Key: i=broonie@kernel.org; a=openpgp; fpr=3F2568AAC26998F9E813A1C5C3F436CA30F5D8EB X-Spam-Status: No, score=-5.2 required=5.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI,SPF_HELO_NONE, SPF_PASS autolearn=unavailable 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 vprintf() is equivalent to vfprintf() to stdout so implement it as a simple wrapper for the existing vfprintf(), allowing us to build kselftest.h. Suggested-by: Willy Tarreau Signed-off-by: Mark Brown --- tools/include/nolibc/stdio.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/tools/include/nolibc/stdio.h b/tools/include/nolibc/stdio.h index 96ac8afc5aee..6cbbb52836a0 100644 --- a/tools/include/nolibc/stdio.h +++ b/tools/include/nolibc/stdio.h @@ -273,6 +273,12 @@ int vfprintf(FILE *stream, const char *fmt, va_list args) return written; } +static __attribute__((unused)) +int vprintf(const char *fmt, va_list args) +{ + return vfprintf(stdout, fmt, args); +} + static __attribute__((unused, format(printf, 2, 3))) int fprintf(FILE *stream, const char *fmt, ...) { -- 2.30.2