From patchwork Mon Nov 6 14:34:49 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 10043561 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 5435C60247 for ; Mon, 6 Nov 2017 14:35:06 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4194129D3E for ; Mon, 6 Nov 2017 14:35:06 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 36C5029D3C; Mon, 6 Nov 2017 14:35:06 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0296B29D3E for ; Mon, 6 Nov 2017 14:35:05 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752489AbdKFOfE (ORCPT ); Mon, 6 Nov 2017 09:35:04 -0500 Received: from bombadil.infradead.org ([65.50.211.133]:38506 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752315AbdKFOfD (ORCPT ); Mon, 6 Nov 2017 09:35:03 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=References:In-Reply-To:Message-Id: Date:Subject:To:From:Sender:Reply-To:Cc:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=ii6SFxYo4L5FqA7p4xOITwxENQHVDMNqP7vsgWFQn6U=; b=J3cL+H6J8M4vmsxSUW56QwqD7 yRbi6sOTzsFV1WJP3FZo0yddEF8EbLR9DsEHD0k8/nqlFtCY2/HqmgM3QgQ5aB4ntfvRUZ8rWMB7c R3rpMeq20bzK5Z+IYnVup+1sxWYSXfWYPI9NTSyljh36Zd9yhLFmhGQC31Rf3nv52cjnlfmqqpcZi 5W7WpXNVwpOvNlnAS0SCnV4fqx8hSZ1iXRNF81ImupLwIxR+SrQ8v/RLyr1xS8P2ECuM6WSgEfO9u pJ4mR1oRB3oEc+L5zwBj+qWiGKf+k4XUNFFO1VfxTsP9SbEe0OOuIx6TV64/vZGx/g0yWqgSw0AJk Ergx927tQ==; Received: from clnet-p099-196.ikbnet.co.at ([83.175.99.196] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.87 #1 (Red Hat Linux)) id 1eBiUR-0000tc-Cc for linux-xfs@vger.kernel.org; Mon, 06 Nov 2017 14:35:03 +0000 From: Christoph Hellwig To: linux-xfs@vger.kernel.org Subject: [PATCH 1/8] xfs: always define STATIC to static noinline Date: Mon, 6 Nov 2017 15:34:49 +0100 Message-Id: <20171106143456.13567-2-hch@lst.de> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20171106143456.13567-1-hch@lst.de> References: <20171106143456.13567-1-hch@lst.de> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-xfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Ever since we added the noinline tag there is no good reason to define away the static for debug builds - we'll get just as good debug information with our without it, so don't mess up sparse and other checkers due to it. Signed-off-by: Christoph Hellwig Reviewed-by: Darrick J. Wong --- fs/xfs/xfs.h | 1 - fs/xfs/xfs_linux.h | 14 ++------------ 2 files changed, 2 insertions(+), 13 deletions(-) diff --git a/fs/xfs/xfs.h b/fs/xfs/xfs.h index 80cd0fd86783..5ff7f228d616 100644 --- a/fs/xfs/xfs.h +++ b/fs/xfs/xfs.h @@ -19,7 +19,6 @@ #define __XFS_H__ #ifdef CONFIG_XFS_DEBUG -#define STATIC #define DEBUG 1 #define XFS_BUF_LOCK_TRACKING 1 #endif diff --git a/fs/xfs/xfs_linux.h b/fs/xfs/xfs_linux.h index 00a5efeec496..6282bfc1afa9 100644 --- a/fs/xfs/xfs_linux.h +++ b/fs/xfs/xfs_linux.h @@ -250,10 +250,6 @@ static inline uint64_t howmany_64(uint64_t x, uint32_t y) #define ASSERT(expr) \ (likely(expr) ? (void)0 : assfail(#expr, __FILE__, __LINE__)) -#ifndef STATIC -# define STATIC noinline -#endif - #else /* !DEBUG */ #ifdef XFS_WARN @@ -261,21 +257,15 @@ static inline uint64_t howmany_64(uint64_t x, uint32_t y) #define ASSERT(expr) \ (likely(expr) ? (void)0 : asswarn(#expr, __FILE__, __LINE__)) -#ifndef STATIC -# define STATIC static noinline -#endif - #else /* !DEBUG && !XFS_WARN */ #define ASSERT(expr) ((void)0) -#ifndef STATIC -# define STATIC static noinline -#endif - #endif /* XFS_WARN */ #endif /* DEBUG */ +#define STATIC static noinline + #ifdef CONFIG_XFS_RT /*