lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Message-Id: <1443672762-982936-16-git-send-email-green@linuxhacker.ru> Date: Thu, 1 Oct 2015 00:12:25 -0400 From: green@...uxhacker.ru To: Greg Kroah-Hartman <gregkh@...uxfoundation.org>, devel@...verdev.osuosl.org, Andreas Dilger <andreas.dilger@...el.com> Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>, Lustre Development List <lustre-devel@...ts.lustre.org>, Oleg Drokin <green@...uxhacker.ru> Subject: [PATCH 15/32] staging/lustre/ldlm: Remove ldlm_errno2error() From: Oleg Drokin <green@...uxhacker.ru> This particular incarnation is only used on the server. Signed-off-by: Oleg Drokin <green@...uxhacker.ru> --- drivers/staging/lustre/lustre/include/lustre_dlm.h | 3 +- drivers/staging/lustre/lustre/ldlm/ldlm_lib.c | 36 ---------------------- 2 files changed, 1 insertion(+), 38 deletions(-) diff --git a/drivers/staging/lustre/lustre/include/lustre_dlm.h b/drivers/staging/lustre/lustre/include/lustre_dlm.h index 72c52ef..432222b 100644 --- a/drivers/staging/lustre/lustre/include/lustre_dlm.h +++ b/drivers/staging/lustre/lustre/include/lustre_dlm.h @@ -1161,8 +1161,7 @@ static inline int ldlm_res_lvbo_update(struct ldlm_resource *res, } int ldlm_error2errno(ldlm_error_t error); -ldlm_error_t ldlm_errno2error(int err_no); /* don't call it `errno': this - * confuses user-space. */ + #if LUSTRE_TRACKS_LOCK_EXP_REFS void ldlm_dump_export_locks(struct obd_export *exp); #endif diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c index 584c4e6..b840200 100644 --- a/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c +++ b/drivers/staging/lustre/lustre/ldlm/ldlm_lib.c @@ -814,42 +814,6 @@ int ldlm_error2errno(ldlm_error_t error) } EXPORT_SYMBOL(ldlm_error2errno); -/** - * Dual to ldlm_error2errno(): maps errno values back to ldlm_error_t. - */ -ldlm_error_t ldlm_errno2error(int err_no) -{ - int error; - - switch (err_no) { - case 0: - error = ELDLM_OK; - break; - case -ESTALE: - error = ELDLM_LOCK_CHANGED; - break; - case -ENAVAIL: - error = ELDLM_LOCK_ABORTED; - break; - case -ESRCH: - error = ELDLM_LOCK_REPLACED; - break; - case -ENOENT: - error = ELDLM_NO_LOCK_DATA; - break; - case -EEXIST: - error = ELDLM_NAMESPACE_EXISTS; - break; - case -EBADF: - error = ELDLM_BAD_NAMESPACE; - break; - default: - error = err_no; - } - return error; -} -EXPORT_SYMBOL(ldlm_errno2error); - #if LUSTRE_TRACKS_LOCK_EXP_REFS void ldlm_dump_export_locks(struct obd_export *exp) { -- 2.1.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists