mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Oleg Drokin <green@linuxhacker.ru>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-kernel@vger.kernel.org, devel@driverdev.osuosl.org,
	Andreas Dilger <andreas.dilger@intel.com>
Cc: "John L. Hammond" <john.hammond@intel.com>
Subject: [PATCH 05/12] staging/lustre/obdclass: remove lu_ucred.c
Date: Sat, 30 Aug 2014 17:12:44 -0400	[thread overview]
Message-ID: <1409433171-23572-6-git-send-email-green@linuxhacker.ru> (raw)
In-Reply-To: <1409433171-23572-1-git-send-email-green@linuxhacker.ru>

From: "John L. Hammond" <john.hammond@intel.com>

The functions exported by lustre/obdclass/lu_ucred.c are not used so
remove that file.

Signed-off-by: John L. Hammond <john.hammond@intel.com>
---
 drivers/staging/lustre/lustre/obdclass/Makefile   |   3 +-
 drivers/staging/lustre/lustre/obdclass/lu_ucred.c | 107 ----------------------
 2 files changed, 1 insertion(+), 109 deletions(-)
 delete mode 100644 drivers/staging/lustre/lustre/obdclass/lu_ucred.c

diff --git a/drivers/staging/lustre/lustre/obdclass/Makefile b/drivers/staging/lustre/lustre/obdclass/Makefile
index 989fb7c..91a5a2b 100644
--- a/drivers/staging/lustre/lustre/obdclass/Makefile
+++ b/drivers/staging/lustre/lustre/obdclass/Makefile
@@ -6,5 +6,4 @@ obdclass-y := linux/linux-module.o linux/linux-obdo.o linux/linux-sysctl.o \
 	      lustre_handles.o lustre_peer.o llog_osd.o \
 	      local_storage.o statfs_pack.o obdo.o obd_config.o obd_mount.o\
 	      mea.o lu_object.o dt_object.o capa.o cl_object.o   \
-	      cl_page.o cl_lock.o cl_io.o lu_ref.o acl.o \
-	      lu_ucred.o
+	      cl_page.o cl_lock.o cl_io.o lu_ref.o acl.o
diff --git a/drivers/staging/lustre/lustre/obdclass/lu_ucred.c b/drivers/staging/lustre/lustre/obdclass/lu_ucred.c
deleted file mode 100644
index 3676563..0000000
--- a/drivers/staging/lustre/lustre/obdclass/lu_ucred.c
+++ /dev/null
@@ -1,107 +0,0 @@
-/*
- * GPL HEADER START
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 only,
- * as published by the Free Software Foundation.
- *
- * This program is distributed in the hope that it will be useful, but
- * WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
- * General Public License version 2 for more details (a copy is included
- * in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU General Public License
- * version 2 along with this program; If not, see
- * http://www.sun.com/software/products/lustre/docs/GPLv2.pdf
- *
- * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
- * CA 95054 USA or visit www.sun.com if you need additional information or
- * have any questions.
- *
- * GPL HEADER END
- */
-/*
- * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
- * Use is subject to license terms.
- *
- * Copyright (c) 2011, 2012, Intel Corporation.
- */
-/*
- * This file is part of Lustre, http://www.lustre.org/
- * Lustre is a trademark of Sun Microsystems, Inc.
- *
- * lustre/obdclass/lu_ucred.c
- *
- * Lustre user credentials context infrastructure.
- *
- *   Author: Nikita Danilov <nikita.danilov@sun.com>
- *   Author: Fan Yong <fan.yong@intel.com>
- *   Author: Vitaly Fertman <vitaly_fertman@xyratex.com>
- */
-
-#define DEBUG_SUBSYSTEM S_CLASS
-
-#include "../../include/linux/libcfs/libcfs.h"
-#include "../include/obd_support.h"
-#include "../include/lu_object.h"
-#include "../include/md_object.h"
-
-/* context key constructor/destructor: lu_ucred_key_init, lu_ucred_key_fini */
-LU_KEY_INIT_FINI(lu_ucred, struct lu_ucred);
-
-static struct lu_context_key lu_ucred_key = {
-	.lct_tags = LCT_SESSION,
-	.lct_init = lu_ucred_key_init,
-	.lct_fini = lu_ucred_key_fini
-};
-
-/**
- * Get ucred key if session exists and ucred key is allocated on it.
- * Return NULL otherwise.
- */
-struct lu_ucred *lu_ucred(const struct lu_env *env)
-{
-	if (!env->le_ses)
-		return NULL;
-	return lu_context_key_get(env->le_ses, &lu_ucred_key);
-}
-EXPORT_SYMBOL(lu_ucred);
-
-/**
- * Get ucred key and check if it is properly initialized.
- * Return NULL otherwise.
- */
-struct lu_ucred *lu_ucred_check(const struct lu_env *env)
-{
-	struct lu_ucred *uc = lu_ucred(env);
-	if (uc && uc->uc_valid != UCRED_OLD && uc->uc_valid != UCRED_NEW)
-		return NULL;
-	return uc;
-}
-EXPORT_SYMBOL(lu_ucred_check);
-
-/**
- * Get ucred key, which must exist and must be properly initialized.
- * Assert otherwise.
- */
-struct lu_ucred *lu_ucred_assert(const struct lu_env *env)
-{
-	struct lu_ucred *uc = lu_ucred_check(env);
-	LASSERT(uc != NULL);
-	return uc;
-}
-EXPORT_SYMBOL(lu_ucred_assert);
-
-int lu_ucred_global_init(void)
-{
-	LU_CONTEXT_KEY_INIT(&lu_ucred_key);
-	return lu_context_key_register(&lu_ucred_key);
-}
-
-void lu_ucred_global_fini(void)
-{
-	lu_context_key_degister(&lu_ucred_key);
-}
-- 
1.9.3


  parent reply	other threads:[~2014-08-30 21:13 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-08-30 21:12 [PATCH 00/12] lustre: continues dead code removal Oleg Drokin
2014-08-30 21:12 ` [PATCH 01/12] staging/lustre: Remove unused header libcfs_heap.h Oleg Drokin
2014-08-30 21:12 ` [PATCH 02/12] staging/lustre/obdecho: remove metadata echo client Oleg Drokin
2014-08-30 21:12 ` [PATCH 03/12] staging/lustre/obdecho: remove #if 0-ed out regions Oleg Drokin
2014-08-30 21:12 ` [PATCH 04/12] staging/lustre/obdclass: remove idmap.c Oleg Drokin
2014-08-30 21:12 ` Oleg Drokin [this message]
2014-08-30 21:12 ` [PATCH 06/12] staging/lustre/obdclass: remove mea.c Oleg Drokin
2014-08-30 21:12 ` [PATCH 07/12] staging/lustre: remove md_object.h Oleg Drokin
2014-08-30 21:12 ` [PATCH 08/12] staging/lustre/mgc: remove server specific handlers Oleg Drokin
2014-08-30 21:12 ` [PATCH 09/12] staging/lustre/obdclass: remove llog_test.ko Oleg Drokin
2014-08-30 21:12 ` [PATCH 10/12] staging/lustre/obdclass: remove llog_osd.c Oleg Drokin
2014-08-30 21:12 ` [PATCH 11/12] staging/lustre/mdc: remove obsolete llog ioctl handlers Oleg Drokin
2014-08-30 21:12 ` [PATCH 12/12] staging/lustre: remove unused som_attrs and hsm_attrs structures Oleg Drokin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1409433171-23572-6-git-send-email-green@linuxhacker.ru \
    --to=green@linuxhacker.ru \
    --cc=andreas.dilger@intel.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=john.hammond@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome