From nobody Fri Jun 17 19:41:18 2022 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 F353F85DAAF; Fri, 17 Jun 2022 19:41:20 +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 4LPqCz4KWnz3jFm; Fri, 17 Jun 2022 19:41:19 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1655494879; 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=pnAZTb/MafQd5nJepC6XZSbpM+T/rG68/f5und+N+5c=; b=Pni0kyjgxCBSzs2Rigw/XbZ2/5x5Q/KhfR1Ptgnik7rcpPRJQlOjANzrs1o8/AX9N3oKhe gnjiMx4i6fMcB9rzg4I5j26OYhzq/9+v8HsmgPbj/gwTx6c2H1FH0XU7Z32lIl9BsQkd2e 9TtZRUBPr5Ndv4dkKItnMZ/yGELU87QTNTq9lAwCl3lZ0sc5yGyP7SehaoakGdGnb5Y+IM 1GTt0W+r6HoUFrBzj54Jx5rCR30zDuATw5wO2G7yu9/6LOsTb4xu4VuGROdPk5zUAApT+P MEcdRQ/r1YV4gGdt5BeeoK93JKLG2skvD9HQfxmWU2enxtGowZcABiv9ldZHOg== 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 1774925C76; Fri, 17 Jun 2022 19:41:19 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 25HJfIMV030311; Fri, 17 Jun 2022 19:41:18 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 25HJfIrF030310; Fri, 17 Jun 2022 19:41:18 GMT (envelope-from git) Date: Fri, 17 Jun 2022 19:41:18 GMT Message-Id: <202206171941.25HJfIrF030310@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Dmitry Chagin Subject: git: b13a727fceee - stable/13 - linux(4): Add LINUX_RATELIMIT_MSG_OPT2 for future use 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: Sender: owner-dev-commits-src-all@freebsd.org X-BeenThere: dev-commits-src-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: dchagin X-Git-Repository: src X-Git-Refname: refs/heads/stable/13 X-Git-Reftype: branch X-Git-Commit: b13a727fceee3e500fd4e0f26ecd183e03031080 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1655494879; 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=pnAZTb/MafQd5nJepC6XZSbpM+T/rG68/f5und+N+5c=; b=YCqeNdXGNbXMbzBf5LR0QdYja1PviR2lH6793F4lqK2Vi5NRYpbYykDVI+3Cea0vzUMfjb sEMeU/qIFYcNTReIlBrG8sRfiSpq+lMq8OYk5+9hMm7ygMBucnIKKnO1JlgHiaUvOQUMNw rtGPFZ5Xyj3L4FCbjeEbSDWx0L/4IR9eFwoh+saB5kX4vX6ipSP89DBMJHBmp6+qjUK2jw wwiy8CJdJ6UxpPOacA5CREDNWhpSXEnqtSZQTlxbMpiB2hmUixc2djNP+1mGn22wbjoDuu 3z8ATPL9wdP350KWSPEN2DOV7bQUN6tcer6QeiTxz4UTMP3aT8x02vodHdUUmg== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1655494879; a=rsa-sha256; cv=none; b=BqO2QSZN7Xx7mHpVe+8+umVZQg05hJoy7i8/fyq/zrf6UjhjzLQ94ra+Fvo/I9kM/mySvD UhHigaXoI+vRmkVN8v6wzRaKRiC7emzVHjPUwYH7inUDCsamTW0/WIVuNfn1UxhI3igN0/ /xdCQ4AiJrwlciEg/Ikh9JPoSWCtgTbaEwGxZ6nmmQKapUOsBE6bTlDtow4xiVURxom6IH jskjQW7siTnzLI/Qmo+V7I4SeXt7ZJdolKMnuKduHRKfUBroWbDbuIiZu5A3ZO1APEvrkL i3B/dXoAO6hCryS8VCWRYmWtHjLCYqJb/nF7ktstT+6e4KtKKXckp1b0gZlPqw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch stable/13 has been updated by dchagin: URL: https://cgit.FreeBSD.org/src/commit/?id=b13a727fceee3e500fd4e0f26ecd183e03031080 commit b13a727fceee3e500fd4e0f26ecd183e03031080 Author: Dmitry Chagin AuthorDate: 2022-05-28 20:47:23 +0000 Commit: Dmitry Chagin CommitDate: 2022-06-17 19:35:36 +0000 linux(4): Add LINUX_RATELIMIT_MSG_OPT2 for future use MFC after: 2 weeks (cherry picked from commit 4f02a4f48c080ad56f0d7c745ace4d2f7dacf928) --- sys/compat/linux/linux_util.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/sys/compat/linux/linux_util.h b/sys/compat/linux/linux_util.h index a29ba0bc4af1..6f7b55be8123 100644 --- a/sys/compat/linux/linux_util.h +++ b/sys/compat/linux/linux_util.h @@ -198,4 +198,16 @@ bool linux_use_real_ifname(const struct ifnet *ifp); } \ } while (0) +#define LINUX_RATELIMIT_MSG_OPT2(_message, _opt1, _opt2) \ + do { \ + static int seen = 0; \ + \ + if (seen == 0) { \ + linux_msg(curthread, _message, _opt1, _opt2); \ + \ + if (linux_debug < 3) \ + seen = 1; \ + } \ + } while (0) + #endif /* ! _LINUX_UTIL_H_ */