Skip to content

Commit 0a9a8bf

Browse files
nhormandavem330
authored andcommitted
printk: Add a DEPRECATED macro
sctp has several points in its setsockopt path in which it issues deprecation warnings. It seems like it might be handy to macrotize such a warning so other subsystems can use it easily Signed-off-by: Neil Horman <nhorman@tuxdriver.com> CC: Greg Kroah-Hartman <gregkh@linuxfoundation.org> CC: "David S. Miller" <davem@davemloft.net> CC: linux-kernel@vger.kernel.org CC: netdev@vger.kernel.org Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent c76f2a2 commit 0a9a8bf

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

include/linux/printk.h

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,13 @@ struct va_format {
8787
*/
8888
#define HW_ERR "[Hardware Error]: "
8989

90+
/*
91+
* DEPRECATED
92+
* Add this to a message whenever you want to warn user space about the use
93+
* of a deprecated aspect of an API so they can stop using it
94+
*/
95+
#define DEPRECATED "[Deprecated]: "
96+
9097
/*
9198
* Dummy printk for disabled debugging statements to use whilst maintaining
9299
* gcc's format and side-effect checking.

0 commit comments

Comments
 (0)