From patchwork Tue Aug 18 07:24:52 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kinglong Mee X-Patchwork-Id: 7028841 Return-Path: X-Original-To: patchwork-linux-fsdevel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id DC96A9F358 for ; Tue, 18 Aug 2015 07:25:11 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 09A792078B for ; Tue, 18 Aug 2015 07:25:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 35EB120789 for ; Tue, 18 Aug 2015 07:25:10 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751318AbbHRHZH (ORCPT ); Tue, 18 Aug 2015 03:25:07 -0400 Received: from mail-pa0-f51.google.com ([209.85.220.51]:34114 "EHLO mail-pa0-f51.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750867AbbHRHZF (ORCPT ); Tue, 18 Aug 2015 03:25:05 -0400 Received: by paccq16 with SMTP id cq16so82949035pac.1; Tue, 18 Aug 2015 00:25:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:to:references:cc:from:message-id:date:user-agent :mime-version:in-reply-to:content-type:content-transfer-encoding; bh=3EZk3bUNOWTLi3wAkGx+hUKdMojvbexLPn1d/PQ8jxk=; b=Q6YwA38YCUrIbXOcICQ2eb0wxj2eaA0e9BaElYCErpvNd1tzpQ5I067BQ+9dKMH4jZ m73XlcMg65zBv4t3CZ50yYyj709PcHMWia21M/NhUJJB/jM9xh9EE83jZ/OLqP1Ru55p ba6s05eOPAIKTMeyO/i1/MXFrlF3ChhfIRrwTJCGOP+6+83/kstwaZfJQJVTsl5XRkDA WpCXxFdQsoE/vn0VbiFemVc8tyfRv89J7VCzPL+duyWjyE/dV/LnOuX9vWOLOrw4PFsp Mi9s2VNEy7Vik66XCkRBw3P0/vzjUp+6nz4ZAnMcdTLgrIv0Ffq8M7qneJzGj4cZlhVW rFTw== X-Received: by 10.68.115.143 with SMTP id jo15mr10356959pbb.142.1439882704660; Tue, 18 Aug 2015 00:25:04 -0700 (PDT) Received: from [192.168.99.18] ([104.143.41.79]) by smtp.googlemail.com with ESMTPSA id mi6sm17000372pdb.1.2015.08.18.00.24.58 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 18 Aug 2015 00:25:04 -0700 (PDT) Subject: [PATCH 2/6 v9] fs_pin: Export functions for specific filesystem To: "J. Bruce Fields" , Al Viro References: <55D2DBF6.3010406@gmail.com> Cc: "linux-nfs@vger.kernel.org" , linux-fsdevel@vger.kernel.org, NeilBrown , Trond Myklebust , kinglongmee@gmail.com From: Kinglong Mee Message-ID: <55D2DDC4.2010805@gmail.com> Date: Tue, 18 Aug 2015 15:24:52 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0 MIME-Version: 1.0 In-Reply-To: <55D2DBF6.3010406@gmail.com> Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Spam-Status: No, score=-7.2 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, 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 Exports functions for others who want pin to vfsmount, eg, nfsd's export cache. These are needed for any module to participate in pinning. mnt_pin_kill() and group_pin_kill() are just helper-functions for unmount etc (and are in fs/internal.h) so don't need to be exported. v9, same as v4 add exporting of pin_kill. Signed-off-by: Kinglong Mee --- fs/fs_pin.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/fs/fs_pin.c b/fs/fs_pin.c index b7954a9..b1a9654 100644 --- a/fs/fs_pin.c +++ b/fs/fs_pin.c @@ -33,6 +33,7 @@ int pin_remove(struct fs_pin *pin) spin_unlock_irq(&pin->wait.lock); return ret; } +EXPORT_SYMBOL(pin_remove); void pin_insert_group(struct fs_pin *pin, struct vfsmount *m, struct hlist_head *p) { @@ -42,11 +43,13 @@ void pin_insert_group(struct fs_pin *pin, struct vfsmount *m, struct hlist_head hlist_add_head(&pin->m_list, &real_mount(m)->mnt_pins); spin_unlock(&pin_lock); } +EXPORT_SYMBOL(pin_insert_group); void pin_insert(struct fs_pin *pin, struct vfsmount *m) { pin_insert_group(pin, m, &m->mnt_sb->s_pins); } +EXPORT_SYMBOL(pin_insert); void pin_kill(struct fs_pin *p) { @@ -88,6 +91,7 @@ void pin_kill(struct fs_pin *p) } rcu_read_unlock(); } +EXPORT_SYMBOL(pin_kill); void mnt_pin_kill(struct mount *m) {