From patchwork Mon Nov 19 11:15:02 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tushar Behera X-Patchwork-Id: 12926 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id E335B23E01 for ; Mon, 19 Nov 2012 11:21:12 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id 810D3A18ADE for ; Mon, 19 Nov 2012 11:21:12 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id e10so6253120iej.11 for ; Mon, 19 Nov 2012 03:21:12 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:x-gm-message-state; bh=T8yF2KyTEvi4h4sEj5wsP6HXU760HyuneAWIoc05RRc=; b=Uese9tJsEAtcW53gsoj7juNGJh0MvHLifDYKTXluLSJbw36xCJliqVB9V6HXmlWmFW psgjduWckYPBdW2IGWRVABp9oucAGAr8QjzsSYOYZH8+xPtnB2D93dHPj4sCf7CaitMG dGv0Cu2sImA0f1g7OnZex8xxRyzxHU38f/2JPFhRgscXnZvfJG8WtfFPZg32oshUQ67d I8EM+HCYoDC8OFK3mD6F+RYqsqBrX6Ughnuj/f6OOB307J3DnWoMF5jXbTVKY7qhGfNl pGj+6O64bq82n5NPCEXuJWRzjpVGbOtBb+4Y9pQGmyZHqUOAEDPx46T1H2JMKtUYx7n6 5RXg== Received: by 10.50.186.199 with SMTP id fm7mr6088457igc.62.1353324071945; Mon, 19 Nov 2012 03:21:11 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.67.148 with SMTP id n20csp144402igt; Mon, 19 Nov 2012 03:21:11 -0800 (PST) Received: by 10.66.89.9 with SMTP id bk9mr34500340pab.67.1353324071401; Mon, 19 Nov 2012 03:21:11 -0800 (PST) Received: from mail-da0-f51.google.com (mail-da0-f51.google.com [209.85.210.51]) by mx.google.com with ESMTPS id xg10si13395635pbc.207.2012.11.19.03.21.11 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 19 Nov 2012 03:21:11 -0800 (PST) Received-SPF: neutral (google.com: 209.85.210.51 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) client-ip=209.85.210.51; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.210.51 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) smtp.mail=tushar.behera@linaro.org Received: by mail-da0-f51.google.com with SMTP id i30so432644dad.38 for ; Mon, 19 Nov 2012 03:21:11 -0800 (PST) Received: by 10.68.230.135 with SMTP id sy7mr38266552pbc.76.1353324071102; Mon, 19 Nov 2012 03:21:11 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id nt5sm6074341pbb.59.2012.11.19.03.21.07 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 19 Nov 2012 03:21:10 -0800 (PST) From: Tushar Behera To: linux-kernel@vger.kernel.org Cc: khlebnikov@openvz.org, akpm@linux-foundation.org, patches@linaro.org Subject: [PATCH] bug: Fix sparse warning related to BUILD_BUG_ON_INVALID Date: Mon, 19 Nov 2012 16:45:02 +0530 Message-Id: <1353323702-13130-1-git-send-email-tushar.behera@linaro.org> X-Mailer: git-send-email 1.7.4.1 X-Gm-Message-State: ALoCoQneZHLOaBRbwSgCIlNAri9vM5ONgBMJySl+Sl4bdZn1ot0XDoYmq68WRvfML6ihgkr4SRQv commit baf05aa9271b ("bug: introduce BUILD_BUG_ON_INVALID() macro") introduces this macro when only _CHECKER_ is defined. Define a silent macro in the else condition to fix following sparse warning. mm/filemap.c:395:9: error: undefined identifier 'BUILD_BUG_ON_INVALID' mm/filemap.c:396:9: error: undefined identifier 'BUILD_BUG_ON_INVALID' mm/filemap.c:397:9: error: undefined identifier 'BUILD_BUG_ON_INVALID' include/linux/mm.h:419:9: error: undefined identifier 'BUILD_BUG_ON_INVALID' include/linux/mm.h:419:9: error: not a function Signed-off-by: Tushar Behera Signed-off-by: Konstantin Khlebnikov --- include/linux/bug.h | 1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/include/linux/bug.h b/include/linux/bug.h index aaac4bb..b1cf40d 100644 --- a/include/linux/bug.h +++ b/include/linux/bug.h @@ -15,6 +15,7 @@ struct pt_regs; #define BUILD_BUG_ON_NOT_POWER_OF_2(n) #define BUILD_BUG_ON_ZERO(e) (0) #define BUILD_BUG_ON_NULL(e) ((void*)0) +#define BUILD_BUG_ON_INVALID(e) (0) #define BUILD_BUG_ON(condition) #define BUILD_BUG() (0) #else /* __CHECKER__ */