git: 47fb8095f8a8 - stable/13 - LinuxKPI: cast jiffies_to_msecs() result

From: Bjoern A. Zeeb <bz_at_FreeBSD.org>
Date: Wed, 29 Nov 2023 16:37:50 UTC
The branch stable/13 has been updated by bz:

URL: https://cgit.FreeBSD.org/src/commit/?id=47fb8095f8a840e5cb38e5431d3b128f61b5db40

commit 47fb8095f8a840e5cb38e5431d3b128f61b5db40
Author:     Bjoern A. Zeeb <bz@FreeBSD.org>
AuthorDate: 2023-06-10 22:57:27 +0000
Commit:     Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2023-11-29 16:36:03 +0000

    LinuxKPI: cast jiffies_to_msecs() result
    
    jiffies_to_msecs() is expected to return an uint_t.  In order to avoid
    changing printf format strings, properly cast the result to the
    expected type.
    
    Sponsored by:   The FreeBSD Foundation
    
    (cherry picked from commit 08bc2cc4c4d8e94ad1db63f97d923dee18bee668)
---
 sys/compat/linuxkpi/common/include/linux/jiffies.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys/compat/linuxkpi/common/include/linux/jiffies.h b/sys/compat/linuxkpi/common/include/linux/jiffies.h
index d86e5226420d..d5cb6e14860e 100644
--- a/sys/compat/linuxkpi/common/include/linux/jiffies.h
+++ b/sys/compat/linuxkpi/common/include/linux/jiffies.h
@@ -38,7 +38,7 @@
 
 #define	jiffies			ticks
 #define	jiffies_64		ticks
-#define	jiffies_to_msecs(x)     (((int64_t)(int)(x)) * 1000 / hz)
+#define	jiffies_to_msecs(x)     ((unsigned int)(((int64_t)(int)(x)) * 1000 / hz))
 
 #define	MAX_JIFFY_OFFSET	((INT_MAX >> 1) - 1)