From patchwork Wed May 10 15:56:11 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Andy Shevchenko X-Patchwork-Id: 9720121 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 D775460236 for ; Wed, 10 May 2017 15:56:22 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id CA7A628618 for ; Wed, 10 May 2017 15:56:22 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id BF2A32861F; Wed, 10 May 2017 15:56:22 +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.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI 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 6609D28618 for ; Wed, 10 May 2017 15:56:22 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753996AbdEJP4U (ORCPT ); Wed, 10 May 2017 11:56:20 -0400 Received: from mga03.intel.com ([134.134.136.65]:55412 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753988AbdEJP4S (ORCPT ); Wed, 10 May 2017 11:56:18 -0400 Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by orsmga103.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 10 May 2017 08:56:16 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.38,320,1491289200"; d="scan'208";a="1146226458" Received: from black.fi.intel.com ([10.237.72.28]) by fmsmga001.fm.intel.com with ESMTP; 10 May 2017 08:56:14 -0700 Received: by black.fi.intel.com (Postfix, from userid 1003) id C1B6390; Wed, 10 May 2017 18:56:13 +0300 (EEST) From: Andy Shevchenko To: Christoph Hellwig , Amir Goldstein , linux-xfs , Dan Williams , linux-fsdevel Cc: Andy Shevchenko Subject: [PATCH v1 2/3] (to be folded into): uuid: hoist uuid_is_null() helper from libnvdimm Date: Wed, 10 May 2017 18:56:11 +0300 Message-Id: <20170510155612.55870-2-andriy.shevchenko@linux.intel.com> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170510155612.55870-1-andriy.shevchenko@linux.intel.com> References: <20170510155612.55870-1-andriy.shevchenko@linux.intel.com> Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Signed-off-by: Andy Shevchenko --- include/linux/uuid.h | 7 ++----- lib/uuid.c | 5 ----- 2 files changed, 2 insertions(+), 10 deletions(-) diff --git a/include/linux/uuid.h b/include/linux/uuid.h index 2f9bdc88079e..5dcaabc1e28b 100644 --- a/include/linux/uuid.h +++ b/include/linux/uuid.h @@ -24,9 +24,6 @@ */ #define UUID_STRING_LEN 36 -extern const guid_t guid_null; -extern const uuid_t uuid_null; - static inline int guid_cmp(const guid_t u1, const guid_t u2) { return memcmp(&u1, &u2, sizeof(guid_t)); @@ -44,7 +41,7 @@ static inline void guid_copy(guid_t *dst, const guid_t *src) static inline bool guid_is_null(guid_t *guid) { - return guid_equal(guid, &guid_null); + return guid_equal(guid, &NULL_GUID); } static inline int uuid_cmp(const uuid_t u1, const uuid_t u2) @@ -64,7 +61,7 @@ static inline void uuid_copy(uuid_t *dst, const uuid_t *src) static inline bool uuid_is_null(uuid_t *uuid) { - return uuid_equal(uuid, &uuid_null); + return uuid_equal(uuid, &NULL_UUID); } void generate_random_uuid(unsigned char uuid[16]); diff --git a/lib/uuid.c b/lib/uuid.c index 25145bfb0eaa..003bf6823003 100644 --- a/lib/uuid.c +++ b/lib/uuid.c @@ -21,11 +21,6 @@ #include #include -const guid_t guid_null; -EXPORT_SYMBOL(guid_null); -const uuid_t uuid_null; -EXPORT_SYMBOL(uuid_null); - const u8 guid_index[16] = {3,2,1,0,5,4,7,6,8,9,10,11,12,13,14,15}; const u8 uuid_index[16] = {0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15};