From patchwork Wed Dec 4 15:12:40 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tejun Heo X-Patchwork-Id: 3282901 Return-Path: X-Original-To: patchwork-linux-sparse@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id D00239F37A for ; Wed, 4 Dec 2013 15:12:54 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id BA91820498 for ; Wed, 4 Dec 2013 15:12:53 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id DAE58204EB for ; Wed, 4 Dec 2013 15:12:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932508Ab3LDPMs (ORCPT ); Wed, 4 Dec 2013 10:12:48 -0500 Received: from mail-qe0-f53.google.com ([209.85.128.53]:52594 "EHLO mail-qe0-f53.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932178Ab3LDPMp (ORCPT ); Wed, 4 Dec 2013 10:12:45 -0500 Received: by mail-qe0-f53.google.com with SMTP id nc12so14379635qeb.40 for ; Wed, 04 Dec 2013 07:12:44 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:in-reply-to:user-agent; bh=YEAGJzo+amjODRMkQnhD9N1vsu+v4HWpDEx7qfGXqL0=; b=kTqK6fIKChnEPzv3ayyqChk270D9GBy1DKQ1rzDXG0zn9eaA0Qzx8FPrKN8ABOtiv6 srdU55PpcmJMAqGLLzusJJP9AOa3f7XE/1lKfjcCcyjReultlF5YacFakvquElnrQkTV sTOBzqKjk97QiUvcfXwHY/Q0QWCHlznoulpcUFpdmWz4nsZ+mKPg7COPmpDR6LBlt2dc 5AyV3iRGpRPbahmXeQ+2xapNX4oMStRH3BMirMzV8fJ7P7dr6HWScljAlFQnqqJwNCPx hKa4ZwtAg3i6YBtdP/WY68BhDCOgewl+8eVTn9TMSpNt6TMZSb2INA/eqbjG6FRzO+JP iZfg== X-Received: by 10.49.132.65 with SMTP id os1mr120262237qeb.39.1386169964304; Wed, 04 Dec 2013 07:12:44 -0800 (PST) Received: from htj.dyndns.org (207-38-225-25.c3-0.43d-ubr1.qens-43d.ny.cable.rcn.com. [207.38.225.25]) by mx.google.com with ESMTPSA id o5sm18532700qeg.2.2013.12.04.07.12.43 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 04 Dec 2013 07:12:43 -0800 (PST) Date: Wed, 4 Dec 2013 10:12:40 -0500 From: Tejun Heo To: Wanlong Gao Cc: josh@kernel.org, linux-sparse@vger.kernel.org, Wu Fengguang , kbuild-all@01.org, Rusty Russell , Christoph Lameter Subject: Re: [BUG report]sparse warnings on DEFINE_PER_CPU() symbols non-static Message-ID: <20131204151240.GO3158@htj.dyndns.org> References: <5294175F.2080407@cn.fujitsu.com> <20131203222543.GQ8277@htj.dyndns.org> <529EA0F4.5070205@cn.fujitsu.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <529EA0F4.5070205@cn.fujitsu.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-sparse-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sparse@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Wed, Dec 04, 2013 at 11:26:44AM +0800, Wanlong Gao wrote: > Goes away but comes new error: > > /git/linux/fs/inode.c:74:8: error: symbol 'nr_inodes' redeclared with different type (originally declared at /git/linux/fs/inode.c:74) - different address spaces > /git/linux/fs/inode.c:75:8: error: symbol 'nr_unused' redeclared with different type (originally declared at /git/linux/fs/inode.c:75) - different address spaces > /git/linux/fs/inode.c:835:8: error: symbol 'last_ino' redeclared with different type (originally declared at /git/linux/fs/inode.c:835) - different address spaces Oops, my bad. How about the following? Tested-by: Wanlong Gao --- To unsubscribe from this list: send the line "unsubscribe linux-sparse" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/include/linux/percpu-defs.h b/include/linux/percpu-defs.h index 57e890a..a5fc7d0 100644 --- a/include/linux/percpu-defs.h +++ b/include/linux/percpu-defs.h @@ -69,6 +69,7 @@ __PCPU_DUMMY_ATTRS char __pcpu_scope_##name; \ extern __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ __PCPU_DUMMY_ATTRS char __pcpu_unique_##name; \ + extern __PCPU_ATTRS(sec) __typeof__(type) name; \ __PCPU_ATTRS(sec) PER_CPU_DEF_ATTRIBUTES __weak \ __typeof__(type) name #else