From patchwork Sat Jun 3 08:11:57 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Zhangjin Wu X-Patchwork-Id: 102802 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp1547377vqr; Sat, 3 Jun 2023 02:07:47 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6VIjrivI19LKV+MW42BwEuhCcBl8Lr1jHOZIkIP2u6/XTLpj+dhtoA9RY/Oz7yaFablb7o X-Received: by 2002:a17:90b:609:b0:256:9e9c:94e0 with SMTP id gb9-20020a17090b060900b002569e9c94e0mr848855pjb.29.1685783267086; Sat, 03 Jun 2023 02:07:47 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685783267; cv=none; d=google.com; s=arc-20160816; b=xFsrFhh03tMMNv+RGGb/2q7kC6q+wCjjPhFnhQMtcEvpra7c0agY47DmouGvCXPD2C pNOgSVKIlbEcTWTdGMEh6XXaNpcGics03npl1k6S84sxYuADA0MjFtE07OXmEMooppm5 MkiqanZiXto0wePtw/sFu/t5cypx97TXF0d7RMLZjlFwUx1ZQNkjMsWQ4eWm4NGnfzof QK+rQOajjNaCJZ9GCY1DXzOYVWkYUbtfrE0bi+G4f/FH2XRRq1sbXKcnWJTT8EdITbzX y6+mwXeQPxqrh2sBo74V3nX8jDvGB4mfBpIVUVDuvVd8pnZSD8VExJcpxaJhuZgJDdGf vo5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:feedback-id:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from; bh=YuL09C0zBu3VF62qHTPY25jEEePxMaEf5mLiCf8IrdA=; b=ARv/7uKl1aA5EmeqJ0dg1wfxOdZZ8dgEmP7z7yeW4TpDA7lkk1rLjNUgYhOVoULxDq M7Xiy6vEjcccznWkaz5oMlEyaqCL8RqAOxeBrBHHuBAkyYPvftfnmH1Tje0nyN5sNa09 TdUU2mBsnZHNSSrZMD77eMCBd0/oXTx8AKTdBrFtorBsHfBql5s97j2iHgkmv6PQIm6q hEzjDJ8nTFluGOVLMWZbM5xSHOpE05xJ2sA9fnaeEvEqmZcT2Ty8UZBYuz2x5cjZ+9XE HmHMsalU4S024leVF7D7Szz8VnhxAiKk2Te549KDqg4BCMxfhGaKPn+WY/LUv5dqcRmd 8/Ug== 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 x11-20020a63b34b000000b0053fb39d8e81si2414367pgt.584.2023.06.03.02.07.35; Sat, 03 Jun 2023 02:07:47 -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 S232378AbjFCIMp (ORCPT + 99 others); Sat, 3 Jun 2023 04:12:45 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57838 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229539AbjFCIMn (ORCPT ); Sat, 3 Jun 2023 04:12:43 -0400 Received: from bg4.exmail.qq.com (bg4.exmail.qq.com [43.155.65.254]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9FCF11B3; Sat, 3 Jun 2023 01:12:41 -0700 (PDT) X-QQ-mid: bizesmtp67t1685779952t05dliz3 Received: from linux-lab-host.localdomain ( [119.123.130.226]) by bizesmtp.qq.com (ESMTP) with id ; Sat, 03 Jun 2023 16:12:31 +0800 (CST) X-QQ-SSF: 00200000000000D0V000000A0000000 X-QQ-FEAT: 3M0okmaRx3jysSi7KPtogxkoekhC659z+ArtoJAEYTmllq6RxfjS8BCn5mqHJ O98HVUV0S5ZwQZkWqwX4sJdto+Rln35sV6MiI+4oN1YpPXiJxDGBEA0ZD4AsakhyzgxQEcB +LDpUY6CKcIgfZCHMis0AdjIpU+jAN8A1YDKWoNxahXCzvHZBH80INcI59EL0m1rulehtAa RwH6J1iAR8OzjdxwHL8YMi7pZ4WYVpQN/ClKWo1C7Cj+W/ub2y91JqWvGCCknHxX4AwBG9u te6wHZdWxiJ0EtJrB/vogkD5aJkiFm1IaZoceZHJ3taEVEj6VBkZe8YvGN3yEWituugrvxb HCZCVJNS/WOcoYH2sqLVK8Hb0OF8lhktNWXUUaOZNjhd5wXiHQMtjYv0sMB6U9wlr7QOZDx X-QQ-GoodBg: 0 X-BIZMAIL-ID: 7582937344931115199 From: Zhangjin Wu To: w@1wt.eu Cc: falcon@tinylab.org, arnd@arndb.de, linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org, linux-riscv@lists.infradead.org, thomas@t-8ch.de Subject: [PATCH v3 08/12] tools/nolibc: open: fix up compile warning for arm Date: Sat, 3 Jun 2023 16:11:57 +0800 Message-Id: <66f55993e77b55bc666c003de2d598f81f19e4e4.1685777982.git.falcon@tinylab.org> X-Mailer: git-send-email 2.25.1 In-Reply-To: References: MIME-Version: 1.0 X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:tinylab.org:qybglogicsvrsz:qybglogicsvrsz3a-3 X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL,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 X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1767671875277073920?= X-GMAIL-MSGID: =?utf-8?q?1767671875277073920?= In function ‘open’: nolibc/sysroot/arm/include/sys.h:919:23: warning: ‘mode_t’ {aka ‘short unsigned int’} is promoted to ‘int’ when passed through ‘...’ 919 | mode = va_arg(args, mode_t); | ^ nolibc/sysroot/arm/include/sys.h:919:23: note: (so you should pass ‘int’ not ‘mode_t’ {aka ‘short unsigned int’} to ‘va_arg’) nolibc/sysroot/arm/include/sys.h:919:23: note: if this code is reached, the program will abort Signed-off-by: Zhangjin Wu --- tools/include/nolibc/sys.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/include/nolibc/sys.h b/tools/include/nolibc/sys.h index 0160605444e7..856249a11890 100644 --- a/tools/include/nolibc/sys.h +++ b/tools/include/nolibc/sys.h @@ -862,7 +862,7 @@ int open(const char *path, int flags, ...) va_list args; va_start(args, flags); - mode = va_arg(args, mode_t); + mode = va_arg(args, int); va_end(args); }