Whamcloud - gitweb
LU-5162 mdc: Add exception entry check for radix_tree
[fs/lustre-release.git] / lustre / ptlrpc / gss / gss_rawobj.c
index fe03be0..bb37c1a 100644 (file)
@@ -1,6 +1,4 @@
-/* -*- mode: c; c-basic-offset: 8; indent-tabs-mode: nil; -*-
- * vim:expandtab:shiftwidth=8:tabstop=8:
- *
+/*
  * GPL HEADER START
  *
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  * GPL HEADER END
  */
 /*
- * Copyright  2008 Sun Microsystems, Inc. All rights reserved
+ * Copyright (c) 2007, 2010, Oracle and/or its affiliates. All rights reserved.
  * Use is subject to license terms.
+ *
+ * Copyright (c) 2011, Intel Corporation.
  */
 /*
  * This file is part of Lustre, http://www.lustre.org/
@@ -38,9 +38,6 @@
  * Author: Eric Mei <ericm@clusterfs.com>
  */
 
-#ifndef EXPORT_SYMTAB
-# define EXPORT_SYMTAB
-#endif
 #define DEBUG_SUBSYSTEM S_SEC
 
 #include <linux/mutex.h>
@@ -65,7 +62,7 @@ int rawobj_alloc(rawobj_t *obj, char *buf, int len)
 
         obj->len = len;
         if (len) {
-                OBD_ALLOC(obj->data, len);
+                OBD_ALLOC_LARGE(obj->data, len);
                 if (!obj->data) {
                         obj->len = 0;
                         RETURN(-ENOMEM);
@@ -82,7 +79,7 @@ void rawobj_free(rawobj_t *obj)
 
         if (obj->len) {
                 LASSERT(obj->data);
-                OBD_FREE(obj->data, obj->len);
+                OBD_FREE_LARGE(obj->data, obj->len);
                 obj->len = 0;
                 obj->data = NULL;
         } else
@@ -103,7 +100,7 @@ int rawobj_dup(rawobj_t *dest, rawobj_t *src)
 
         dest->len = src->len;
         if (dest->len) {
-                OBD_ALLOC(dest->data, dest->len);
+                OBD_ALLOC_LARGE(dest->data, dest->len);
                 if (!dest->data) {
                         dest->len = 0;
                         return -ENOMEM;
@@ -167,7 +164,7 @@ static int __rawobj_extract(rawobj_t *obj, __u32 **buf, __u32 *buflen,
         if (!alloc)
                 obj->data = (__u8 *) *buf;
         else {
-                OBD_ALLOC(obj->data, obj->len);
+                OBD_ALLOC_LARGE(obj->data, obj->len);
                 if (!obj->data) {
                         CERROR("fail to alloc %u bytes\n", obj->len);
                         obj->len = 0;
@@ -217,7 +214,7 @@ int rawobj_from_netobj_alloc(rawobj_t *rawobj, netobj_t *netobj)
         if (netobj->len == 0)
                 return 0;
                 
-        OBD_ALLOC(rawobj->data, netobj->len);
+        OBD_ALLOC_LARGE(rawobj->data, netobj->len);
         if (rawobj->data == NULL)
                 return -ENOMEM;