From nobody Sat Feb 01 00:49:32 2025 X-Original-To: dev-commits-src-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4YlDg06Hcsz5m9KS; Sat, 01 Feb 2025 00:49:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4YlDg05npMz4695; Sat, 01 Feb 2025 00:49:32 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1738370972; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=t3wO44kGZVxZXrxMZG09UZqRga96vt47bJf0DQDOj+M=; b=kKG26f63hiq4hDFVk1dKS1srWKc4v2tdD1ZYXEtgQDtV6lJaEBanKhMu13YQtU/am0Uc2T L9Yq1QWfP1OXlueetv+sy0ZpyKN4DBbgdCMsmUqputbRSqV0ua+5qtsS/af+zwZAX9v3nk MivZ4/dDPqgOk5IrL70JgIf9MM6Nc8ifEjrpF6JJLfz/RUmcxfLYvbYMaiUvvm0Dm2CYoX djgkKvridQmW1BvGX5GHwoLyZVfF3Zl6GWN2oaLm6KemB+KmQInU4Ch4m1LLbEjy3duaeo sVZMJmSFGQZH+nGhrYqEjbvqISIfV8MEQAAKgz3OLd2PZUtV64d80cZbftCc+Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1738370972; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=t3wO44kGZVxZXrxMZG09UZqRga96vt47bJf0DQDOj+M=; b=iSKT9ThxETGvBK+TyT4DFSW8qw9vYcpjENZfHXak7GegyVtaVXYkUiKemz9e+eXtfQcybz sLF8YBsWNEMA4VE+LlQl0huS1ue5FvkIyBKW3mZ3t0IbnZn331Rg28ICb6EoOYixPm7/qf L+c8GANL+TN6cDJ/eaj4X9RIcBArX/DRIiCqtWuhYssSTTDUt2RBEBQosKItZUsjuSjXMN pYkEsDi/teWUlho62CkTxiOeWcxwEjgn/xUUYOWdi5fCSrg5DSEDkoW2rj7Lh8eF7jzbGA Cr/4ahAjmOCoxEyH3nJRffLa0oWeDZfY/mOhZX/ru4YXBI+UPJX4SWpzmWk/sw== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1738370972; a=rsa-sha256; cv=none; b=vYSdr6wX/5D/MEGL0B6S/sQ/UEYPMCs0Tw/+siPvytyf3AadlLnMtpQ5F28vLh4yQMMXvp ffoZtEtZk+UNIXi22KcRKSSC3axx9T7CFvVl7ZpZeitT95H8e30OywCnTmBluJ7qtcGeb0 RCmSTJyy8GZP9FT8gqZ6CQzlhYFYLfAe62EyKgH36lSV87kP7Qi6f/b+2ji1aqSPUkEwp2 MVT2aB9UcBLaVUAmKEXdEbxJwkWIra7R9pwilN7ZKVlfH/Z9Nmlk3V/TCIrWkxx88NRIIJ imrSk9BtkRTCTh92jhJ4q9D0f6NYl7Ei9LghjZaVi6UNOp/n4SfKme14T5r5Sw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4YlDg05Fvwzj7y; Sat, 01 Feb 2025 00:49:32 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 5110nWC8013330; Sat, 1 Feb 2025 00:49:32 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 5110nWg0013327; Sat, 1 Feb 2025 00:49:32 GMT (envelope-from git) Date: Sat, 1 Feb 2025 00:49:32 GMT Message-Id: <202502010049.5110nWg0013327@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: "Bjoern A. Zeeb" Subject: git: 95ea57c85639 - main - LinnuxKPI: drm2: retire timespec_to_jiffies() List-Id: Commit messages for the main branch of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-main@freebsd.org Sender: owner-dev-commits-src-main@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: bz X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 95ea57c856392e2824d9c5b68ac912066e7fde36 Auto-Submitted: auto-generated The branch main has been updated by bz: URL: https://cgit.FreeBSD.org/src/commit/?id=95ea57c856392e2824d9c5b68ac912066e7fde36 commit 95ea57c856392e2824d9c5b68ac912066e7fde36 Author: Bjoern A. Zeeb AuthorDate: 2025-01-07 19:57:41 +0000 Commit: Bjoern A. Zeeb CommitDate: 2025-02-01 00:47:30 +0000 LinnuxKPI: drm2: retire timespec_to_jiffies() Linux has removed timespec_to_jiffies() half a decade ago [1]. I cannot find any use of it anymore in recent drm-kmod branches or in the tree so retire it. While here also retire it from drm2. Reported by: emaste (D48318) [1]. Sponsored by: The freeBSD Foundation MFC after: 2 weeks Reviewed by: emaste, dumbbell (tested all drm-kmod versions, thanks!) Differential Revision: https://reviews.freebsd.org/D48379 --- sys/compat/linuxkpi/common/include/linux/jiffies.h | 13 ------------- sys/dev/drm2/drm_os_freebsd.h | 1 - 2 files changed, 14 deletions(-) diff --git a/sys/compat/linuxkpi/common/include/linux/jiffies.h b/sys/compat/linuxkpi/common/include/linux/jiffies.h index bd05a0db0767..f099caa1ce18 100644 --- a/sys/compat/linuxkpi/common/include/linux/jiffies.h +++ b/sys/compat/linuxkpi/common/include/linux/jiffies.h @@ -68,19 +68,6 @@ extern uint64_t lkpi_msec2hz_rem; extern uint64_t lkpi_msec2hz_div; extern uint64_t lkpi_msec2hz_max; -static inline int -timespec_to_jiffies(const struct timespec *ts) -{ - u64 result; - - result = ((u64)hz * ts->tv_sec) + - (((u64)hz * ts->tv_nsec + NSEC_PER_SEC - 1) / NSEC_PER_SEC); - if (result > MAX_JIFFY_OFFSET) - result = MAX_JIFFY_OFFSET; - - return ((int)result); -} - static inline int msecs_to_jiffies(uint64_t msec) { diff --git a/sys/dev/drm2/drm_os_freebsd.h b/sys/dev/drm2/drm_os_freebsd.h index b2a2e82b748b..71a9637ddd9f 100644 --- a/sys/dev/drm2/drm_os_freebsd.h +++ b/sys/dev/drm2/drm_os_freebsd.h @@ -447,7 +447,6 @@ extern unsigned long drm_linux_timer_hz_mask; #define jiffies ticks #define jiffies_to_msecs(x) (((int64_t)(x)) * 1000 / hz) #define msecs_to_jiffies(x) (((int64_t)(x)) * hz / 1000) -#define timespec_to_jiffies(x) (((x)->tv_sec * 1000000 + (x)->tv_nsec) * hz / 1000000) #define time_after(a,b) ((long)(b) - (long)(a) < 0) #define time_after_eq(a,b) ((long)(b) - (long)(a) <= 0) #define round_jiffies(j) ((unsigned long)(((j) + drm_linux_timer_hz_mask) & ~drm_linux_timer_hz_mask))