From patchwork Mon Dec 23 13:29:42 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Horman X-Patchwork-Id: 304769 X-Patchwork-Delegate: davem@davemloft.net Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by ozlabs.org (Postfix) with ESMTP id C68902C00B0 for ; Tue, 24 Dec 2013 00:30:22 +1100 (EST) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757381Ab3LWNaB (ORCPT ); Mon, 23 Dec 2013 08:30:01 -0500 Received: from charlotte.tuxdriver.com ([70.61.120.58]:39233 "EHLO smtp.tuxdriver.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756990Ab3LWN3y (ORCPT ); Mon, 23 Dec 2013 08:29:54 -0500 Received: from hmsreliant.think-freely.org ([2001:470:8:a08:7aac:c0ff:fec2:933b] helo=localhost) by smtp.tuxdriver.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63) (envelope-from ) id 1Vv5Zv-0006hB-FQ; Mon, 23 Dec 2013 08:29:53 -0500 From: Neil Horman To: linux-sctp@vger.kernel.org Cc: Neil Horman , Greg Kroah-Hartman , "David S. Miller" , linux-kernel@vger.kernel.org, netdev@vger.kernel.org Subject: [PATCH v4 1/2] printk: Add a DEPRECATED macro Date: Mon, 23 Dec 2013 08:29:42 -0500 Message-Id: <1387805383-21500-2-git-send-email-nhorman@tuxdriver.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1387805383-21500-1-git-send-email-nhorman@tuxdriver.com> References: <1387205049-22752-1-git-send-email-nhorman@tuxdriver.com> <1387805383-21500-1-git-send-email-nhorman@tuxdriver.com> X-Spam-Score: -2.9 (--) X-Spam-Status: No Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org 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 CC: Greg Kroah-Hartman CC: "David S. Miller" CC: linux-kernel@vger.kernel.org CC: netdev@vger.kernel.org --- Change Notes: v3) * Convert to using a string prefix rather than a specific pr_ macro --- include/linux/printk.h | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/linux/printk.h b/include/linux/printk.h index 6949258..26fb95c 100644 --- a/include/linux/printk.h +++ b/include/linux/printk.h @@ -88,6 +88,13 @@ struct va_format { #define HW_ERR "[Hardware Error]: " /* + * DEPRECATED + * Add this to a message whenever you want to warn user space about the use + * of a deprecated aspect of an API so they can stop using it + */ +#define DEPRECATED "[Deprecated]: " + +/* * Dummy printk for disabled debugging statements to use whilst maintaining * gcc's format and side-effect checking. */