From nobody Thu Jun 06 20:43:04 2024 X-Original-To: dev-commits-src-all@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 4VwGVw6J5hz5MxKX; Thu, 06 Jun 2024 20:43:04 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VwGVw563Gz4qYL; Thu, 6 Jun 2024 20:43:04 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1717706584; 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=Seh+o5wScyzaCiwZCWETGQJI204LpxpYWBkfpzM/5RY=; b=GgbMVKpe2qkiAjU0/3Sx3IwESW7JMfyZOTwk+Ofp4NgYX+v8lWSagHWbQq6lBhDhPbt55H /Pv5W0pCKoAaIE3PCjp9RelxKoYLcZ8oXxsv35ij4nnamg3vp+MXz+AF3aFQfXlS4p386g 9FvWYe6HG0nlE6AG2sOQCSvqmMslql85A5bmGeZNyC6mesx9GEdsLw+dAVOQnocHEGIlwQ WqMwk1ik+1OJUj7a06MYtFsSX4Cm9FrAqQUsWn7Lz/+NJVR38kzW2O+BJ2TTZLEwK84Nfb DBc0bfeP8IY3qe9G91gnoSl6yMS1Z9GEhCB2BgPYUO6/Tkg8zSeKLlwDY2dVTg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1717706584; a=rsa-sha256; cv=none; b=ELuX4oUA5Jxcu1j45t0Zoufpmy87SOGIz/lCT/HbyPEVniw6wmtZKL2DsDAnPfoxBPYyVd TfTWqz57zTbjY0A/NRK+2VsqqDkQaxX1mjhe8i3a31z/gM02fEneseRczX9rQAsR/PLPEY UjzxqNyCmqISc0CK7hVHM2+audOb7JOylaiwuBnQ3xssGE8wYB31PQXd+0MzVyAfIrEmQr n7qetMX5GUUzZg/goZWJY5/yAoLKq64aUVTRB8wXq+l4r4YgGFCXbDFTcpL0rG1RPsyN2a F10wkBaT605XFbHh+0HohHDW2WhJuSKsWXp0aY3t36CUKY+MYLhiHbgX6Sat2w== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1717706584; 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=Seh+o5wScyzaCiwZCWETGQJI204LpxpYWBkfpzM/5RY=; b=G2JP4ZLXaatPKEOJwmrWKO8sM/gU9UMSSOJrcJY4qgdJa9R458ZYYsyHoG1cm0Un3hi/Rp 6zdyoU5Xeagzn6c6ybWLszYdNrbQ1b6dpUnwLxq/6pJReQb67xxVo7A3MUiniUcQt9LleJ RqyLobcBXdgKFgbH4dik24MIslN7HDkEKVLvr+UvYYzgQB7m5eEy4BJGHXUa7WYmWT5H0h dP5K7X2XpANykovd/U++lSHGH+Fae4tE/JEYPu6rH6j9LHH/OmshVD44XHgTWyePkVx0wU oUl/MKPUDXvZV+wXH/HfxwRNx1vFDA4cev2bG6TiJ53jGqYcTqoCToZGwHr5aw== 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 4VwGVw4jG5z10qr; Thu, 6 Jun 2024 20:43:04 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 456Kh4T0046455; Thu, 6 Jun 2024 20:43:04 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 456Kh4BI046452; Thu, 6 Jun 2024 20:43:04 GMT (envelope-from git) Date: Thu, 6 Jun 2024 20:43:04 GMT Message-Id: <202406062043.456Kh4BI046452@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Vladimir Kondratyev Subject: git: d207a2dee332 - main - LinuxKPI: Add kstrtoll to linux/kstrtox.h List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: wulf X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: d207a2dee332706c352bf35c7e6ecea5240b1ceb Auto-Submitted: auto-generated The branch main has been updated by wulf: URL: https://cgit.FreeBSD.org/src/commit/?id=d207a2dee332706c352bf35c7e6ecea5240b1ceb commit d207a2dee332706c352bf35c7e6ecea5240b1ceb Author: Vladimir Kondratyev AuthorDate: 2024-06-06 20:42:07 +0000 Commit: Vladimir Kondratyev CommitDate: 2024-06-06 20:42:07 +0000 LinuxKPI: Add kstrtoll to linux/kstrtox.h kstrtoll converts a string to a long long. Sponsored by: Serenity Cyber Security, LLC MFC after: 1 week Reviewed by: bz, emaste Differential Revision: https://reviews.freebsd.org/D45455 --- sys/compat/linuxkpi/common/include/linux/kstrtox.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/kstrtox.h b/sys/compat/linuxkpi/common/include/linux/kstrtox.h index 5dfc56d40d6e..b723bd4a6fd0 100644 --- a/sys/compat/linuxkpi/common/include/linux/kstrtox.h +++ b/sys/compat/linuxkpi/common/include/linux/kstrtox.h @@ -7,6 +7,7 @@ * Copyright (c) 2018 Johannes Lundberg * Copyright (c) 2020-2022 The FreeBSD Foundation * Copyright (c) 2021 Vladimir Kondratyev + * Copyright (c) 2023 Serenity Cyber Security, LLC * * Portions of this software were developed by Bjoern A. Zeeb and * Emmanuel Vadot under sponsorship from the FreeBSD Foundation. @@ -193,6 +194,12 @@ kstrtos64(const char *cp, unsigned int base, s64 *res) return (0); } +static inline int +kstrtoll(const char *cp, unsigned int base, long long *res) +{ + return (kstrtos64(cp, base, (s64 *)res)); +} + static inline int kstrtou64(const char *cp, unsigned int base, u64 *res) {