Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp300122rwd; Mon, 12 Jun 2023 13:50:11 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ51R7H8nKYhRerBTUEglOCrO1r/OJbSxw5I1u5hzlmNrkckX2U7Ea3p+n2QI6Hn/BnEvKGG X-Received: by 2002:a17:907:a4e:b0:969:fc68:fa9a with SMTP id be14-20020a1709070a4e00b00969fc68fa9amr11316704ejc.40.1686603011513; Mon, 12 Jun 2023 13:50:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1686603011; cv=none; d=google.com; s=arc-20160816; b=nSLoQ2B+ASs+9g1PAUyeDXB8fBAG1tJW7kxB8x64ztGCeBIlIYtyfwzd6p+2lrI0FO cr+m1t4Ws2tST+GQcGoM6lyrOuyfc10wsxwjepASb4wK5lgjxOmCmSI6DICd0W8YdS/5 31eDN6SnqEMsWmJRMYAMJFdPIhGwzKCgv0nnECmo9Z0JHn5BZG1+IF5uGou/lcAP/vLF 81XcZ9wZ5v4tO7ir9ctS43JvAHD7sum0scCxIEYxt3NJUfFI39ZAIRMVtyYkMybMDn1R tYVfcRNWmDoeY43bAYPUj1ud3gMWbj2/2fERJFD7sEcFmepueIKjWfStIljXKLjXnc88 K80g== 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:date:subject:cc:to:from :dkim-signature; bh=Peq3hixOqMcxkMOcrbfoNUG6Iq6VZyfPpUX85pucqBw=; b=nWyEMDt3J9m0fDieBEd8W2IMfWNqsKtJ4GpiFNSuoC8vXJ/YoZaBGc8i6s0ZaTrOrF PUQ4Rs6T3vRcWqdWVtsXhEA+Wyj5cvluye28Q9G5Cd5Y99JjE5hAIbcnRKXjkcRizLKG DmErz8S6xRFplcSfpKvM/qgII2tgNF+M22XtzINBQb38QO3bQm305mMpGwWwtf+cBbSC KLfIN1KBi4Vno9+/WERBRw6TZD0eN3eceznCUJViuOgoh5gFNLCSKoBG9Kuy+YTSn5qe qx+8gKdoJnoeODk2yqzlSsEo/tuCv9tUuILQDuPgcsOvk35KkrqLyffiVZZZv8/LcFWt /wfA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=iVs7ROr0; 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 kt5-20020a170906aac500b009788757c316si2108689ejb.545.2023.06.12.13.49.46; Mon, 12 Jun 2023 13:50:11 -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=iVs7ROr0; 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 S237761AbjFLUr6 (ORCPT + 99 others); Mon, 12 Jun 2023 16:47:58 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35656 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236284AbjFLUq5 (ORCPT ); Mon, 12 Jun 2023 16:46:57 -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 A1B5B26AD for ; Mon, 12 Jun 2023 13:46:28 -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 5155462E42 for ; Mon, 12 Jun 2023 20:45:17 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 7D848C433A8; Mon, 12 Jun 2023 20:45:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1686602716; bh=gd5sfN1vi5rnkiQ19By4Dp4+vXMweeEIcbPWx+T5fUQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=iVs7ROr0TZZJk5hr4p7bgRe7Ixi61cLbu+KRjwMiHHTow/NC+eOTRiyA8L5Jt/Wl7 b16b2/iOAaHRDgCCRdAwcJ3fObzTGPrkJX5QugC2mQ8XHdvXGw5oVm5DPfy7/W/WqO nBM2PR0TFpfs35JkZvRYTijzun9NnHmKTScDWeuldOVRecI1Y9uCYmOAJ3JI/OlJgW TzQuYe3l7iG9fUrnGVr/inL+csVTq6ixmZhCKaOzl5E5B1cJDWv+hhv7gcNv8lSAdi MvjBDBqSYW6ZTj+AFRZ+vB0pKWIO9hDRZPeoeStrFEMHilbHEtgG3C8GhEefLxHZtE oACspl2wu0gsw== Received: by paulmck-ThinkPad-P17-Gen-1.home (Postfix, from userid 1000) id BCFA9CE3A49; Mon, 12 Jun 2023 13:45:15 -0700 (PDT) From: "Paul E. McKenney" To: linux-kernel@vger.kernel.org Cc: gwml@vger.gnuweeb.org, kernel-team@meta.com, w@lwt.eu, =?UTF-8?q?Thomas=20Wei=C3=9Fschuh?= , Willy Tarreau , "Paul E . McKenney" Subject: [PATCH v2 nolibc 09/53] tools/nolibc: use standard __asm__ statements Date: Mon, 12 Jun 2023 13:44:30 -0700 Message-Id: <20230612204514.292087-9-paulmck@kernel.org> X-Mailer: git-send-email 2.40.1 In-Reply-To: <8b757cc0-3719-4e63-a755-9710384137bc@paulmck-laptop> References: <8b757cc0-3719-4e63-a755-9710384137bc@paulmck-laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,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 From: Thomas Weißschuh Most of the code was migrated to C99-conformant __asm__ statements before. It seems string.h was missed. Signed-off-by: Thomas Weißschuh Signed-off-by: Willy Tarreau Signed-off-by: Paul E. McKenney --- tools/include/nolibc/string.h | 4 ++-- tools/testing/selftests/nolibc/nolibc-test.c | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/include/nolibc/string.h b/tools/include/nolibc/string.h index fffdaf6ff467..0c2e06c7c477 100644 --- a/tools/include/nolibc/string.h +++ b/tools/include/nolibc/string.h @@ -90,7 +90,7 @@ void *memset(void *dst, int b, size_t len) while (len--) { /* prevent gcc from recognizing memset() here */ - asm volatile(""); + __asm__ volatile(""); *(p++) = b; } return dst; @@ -139,7 +139,7 @@ size_t strlen(const char *str) size_t len; for (len = 0; str[len]; len++) - asm(""); + __asm__(""); return len; } diff --git a/tools/testing/selftests/nolibc/nolibc-test.c b/tools/testing/selftests/nolibc/nolibc-test.c index 888da60eb5ba..e692be98973a 100644 --- a/tools/testing/selftests/nolibc/nolibc-test.c +++ b/tools/testing/selftests/nolibc/nolibc-test.c @@ -984,7 +984,7 @@ int main(int argc, char **argv, char **envp) #else else if (ioperm(0x501, 1, 1) == 0) #endif - asm volatile ("outb %%al, %%dx" :: "d"(0x501), "a"(0)); + __asm__ volatile ("outb %%al, %%dx" :: "d"(0x501), "a"(0)); /* if it does nothing, fall back to the regular panic */ #endif } -- 2.40.1