X-Git-Url: https://git.whamcloud.com/?a=blobdiff_plain;f=libcfs%2Flibcfs%2Flinux%2Flinux-proc.c;h=684423b31d2282caa8c6482783f3bdfafda5b144;hb=9fa85c69c9e582874f52473e2612407a82319cb6;hp=e82b67584597e2320f53d7a6ad5b3926667a0351;hpb=617e8e1229637908d4cce6725878dd5668960420;p=fs%2Flustre-release.git diff --git a/libcfs/libcfs/linux/linux-proc.c b/libcfs/libcfs/linux/linux-proc.c index e82b675..684423b 100644 --- a/libcfs/libcfs/linux/linux-proc.c +++ b/libcfs/libcfs/linux/linux-proc.c @@ -27,7 +27,7 @@ * Copyright (c) 2008, 2010, Oracle and/or its affiliates. All rights reserved. * Use is subject to license terms. * - * Copyright (c) 2011, Whamcloud, Inc. + * Copyright (c) 2011, 2012, Intel Corporation. */ /* * This file is part of Lustre, http://www.lustre.org/ @@ -40,25 +40,16 @@ * Author: Phil Schwan */ -#ifndef EXPORT_SYMTAB -# define EXPORT_SYMTAB -#endif - -#ifndef AUTOCONF_INCLUDED -#include -#endif #include #include #include #include #include #include -#include #include #include #include -#include #include #include @@ -184,8 +175,10 @@ static int __proc_dobitmasks(void *data, int write, } } else { rc = cfs_trace_copyin_string(tmpstr, tmpstrlen, buffer, nob); - if (rc < 0) - return rc; + if (rc < 0) { + cfs_trace_free_string_buffer(tmpstr, tmpstrlen); + return rc; + } rc = libcfs_debug_str2mask(mask, tmpstr, is_subsys); /* Always print LBUG/LASSERT to console, so keep this mask */ @@ -469,7 +462,7 @@ static cfs_sysctl_table_t lnet_table[] = { }, { - .ctl_name = PSDEV_CPT_TABLE, + INIT_CTL_NAME(PSDEV_CPT_TABLE) .procname = "cpu_partition_table", .maxlen = 128, .mode = 0444,