From patchwork Thu May 16 09:17:08 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Chestnykh X-Patchwork-Id: 1935870 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20230601 header.b=SjWG2d9Z; dkim-atps=neutral Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=uclibc-ng.org (client-ip=2a00:1828:2000:679::23; helo=helium.openadk.org; envelope-from=devel-bounces@uclibc-ng.org; receiver=patchwork.ozlabs.org) Received: from helium.openadk.org (helium.openadk.org [IPv6:2a00:1828:2000:679::23]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (secp384r1) server-digest SHA384) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Vg4J73MMlz20KF for ; Thu, 16 May 2024 19:17:57 +1000 (AEST) Received: from helium.openadk.org (localhost [IPv6:::1]) by helium.openadk.org (Postfix) with ESMTP id 6F2D63528311; Thu, 16 May 2024 11:17:45 +0200 (CEST) Authentication-Results: helium.openadk.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256 header.s=20230601 header.b=SjWG2d9Z; dkim-atps=neutral Received: from mail-lj1-f172.google.com (mail-lj1-f172.google.com [209.85.208.172]) by helium.openadk.org (Postfix) with ESMTPS id 8955635210E4 for ; Thu, 16 May 2024 11:17:33 +0200 (CEST) Received: by mail-lj1-f172.google.com with SMTP id 38308e7fff4ca-2e2554b8cdfso1256831fa.0 for ; Thu, 16 May 2024 02:17:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715851052; x=1716455852; darn=uclibc-ng.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=Mka2qXgTCRgafiG/BjNa0WowFi0nsf8yNxdd2alcL98=; b=SjWG2d9Zw1sMrSs7y/hUdTgDH6qSDkCtbSCjaOK70TP6g+nt2LyomccuVHiRQA0MPM I57BRgsyS5W9Ysazo5O4swpS3Yh4Kn7oH8QFjfWqV/1m9oQ1zb88hHKKyCv4HKUu10Ah kuPo7XYP6XanL7a6sGXim2Kt2jIUcpjHVaHDUUsALqX/FRDeqH/a9IjBgMslB3ZIeurP tMC9SGaO0spSe5AqV329AOEBQPWG79248R2D5mqMsc0tJ2hCHpY5px9/lYBE/FyfhPWm k8UAZ2E/G4U3KLoo/KmQnyu0DNvijsjL9jk+9uGee8BSScma55JaOrNiAIQEacEyAUl5 T3DA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715851052; x=1716455852; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=Mka2qXgTCRgafiG/BjNa0WowFi0nsf8yNxdd2alcL98=; b=bBHLWlE+so9soAfC+GwYujvq/FVbUPLrzedrHpk1V7xBr7nHfAHYB/TrDEmoJyVP5Q nTcK89NTLBGMhyslBwq4BLwbEfJiEpMVhOZXyfTIX4oRxQ9goDXEK4VH1DRzCH+QlD4Z x0oN4ghpZtF+AnWCj0r0sHo7Gv9IaZlzC8x8zpzHh15TvPZMicOvLaw8/XBhd7jDCh64 UEYn8g01qrserjNv4I1Inby7/JLvvPsuQYaD+Aa++97Djb+GyHV8XrcTs6XxyqzRXypi I+fzxcXI5Lcik1Wft7YpXsh3p7P9FLTgfdS0rh5mL+0R+UvchOWB+7TXcdw4h5lZG7uW 2YoA== X-Gm-Message-State: AOJu0YwZj11ifv1byTthSVgf2Z05gb1vBNZI2c1GZ2ujgnfJ49R+Veae hG9D/TAoGYnXQWVwt14o5MGKm9hO6NfCOZ+x/TgBbkE0kMwpi1htO0DW9Q== X-Google-Smtp-Source: AGHT+IHmVxTUbRjzs/hpTqjqD39EAZZppHPbd+U3eKHLpFgLewRQjZnEzdlNPkRZ2xYaUEm287VpPg== X-Received: by 2002:a05:6512:3b1f:b0:523:94a3:26b5 with SMTP id 2adb3069b0e04-52394a32793mr3463360e87.5.1715851051658; Thu, 16 May 2024 02:17:31 -0700 (PDT) Received: from localhost.localdomain (109-252-38-243.nat.spd-mgts.ru. [109.252.38.243]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-521f35ad6desm2911142e87.2.2024.05.16.02.17.30 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 16 May 2024 02:17:31 -0700 (PDT) From: Dmitry Chestnykh To: devel@uclibc-ng.org Date: Thu, 16 May 2024 12:17:08 +0300 Message-ID: <20240516091708.519229-1-dm.chestnykh@gmail.com> X-Mailer: git-send-email 2.45.1 MIME-Version: 1.0 Message-ID-Hash: 4QOJRBXFOOG2QFBKE54KEKLGRYYRPTKZ X-Message-ID-Hash: 4QOJRBXFOOG2QFBKE54KEKLGRYYRPTKZ X-MailFrom: dm.chestnykh@gmail.com X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: Dmitry Chestnykh X-Mailman-Version: 3.3.3 Precedence: list Subject: [uclibc-ng-devel] [PATCH] Correct uClibc compilation. List-Id: uClibc-ng Development Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: - Include sys/types.h instead of asm/types.h to prevent types conflict for uClibc typedefs and kernel headers typedefs. - Cast 3rd arg of utimensat_time64 syscall to integer type to avoid compiler's -Wint-conversion error. The error was found during uClibc compilation for mips32. Signed-off-by: Dmitry Chestnykh --- include/net/ppp_defs.h | 2 +- libc/sysdeps/linux/common/utimensat.c | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/include/net/ppp_defs.h b/include/net/ppp_defs.h index f8924c4f2..904d1933c 100644 --- a/include/net/ppp_defs.h +++ b/include/net/ppp_defs.h @@ -4,7 +4,7 @@ #define __need_time_t #include -#include +#include #include #endif /* net/ppp_defs.h */ diff --git a/libc/sysdeps/linux/common/utimensat.c b/libc/sysdeps/linux/common/utimensat.c index fa6f90e55..5816c7890 100644 --- a/libc/sysdeps/linux/common/utimensat.c +++ b/libc/sysdeps/linux/common/utimensat.c @@ -8,6 +8,7 @@ #include #include +#include #if defined(__UCLIBC_USE_TIME64__) #include "internal/time64_helpers.h" @@ -28,7 +29,7 @@ int utimensat(int fd, const char *path, const struct timespec times[2], int flag } }; - return INLINE_SYSCALL(utimensat_time64, 4, fd, path, times ? &__times64 : 0, flags); + return INLINE_SYSCALL(utimensat_time64, 4, fd, path, times ? (uintptr_t) &__times64 : 0, flags); } #else _syscall4(int, utimensat, int, fd, const char *, path, const struct timespec *, times, int, flags)