X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=datapath%2Fbrc_procfs.c;h=bf328c9b8d264c10da549689077723b6b6508224;hb=d8ae4d672673cd72285eb405a96b4ac3590a7639;hp=733e9a94d88b939f8708c6bd898be014ab1b286f;hpb=064af42167bf4fc9aaea2702d80ce08074b889c0;p=openvswitch diff --git a/datapath/brc_procfs.c b/datapath/brc_procfs.c index 733e9a94..bf328c9b 100644 --- a/datapath/brc_procfs.c +++ b/datapath/brc_procfs.c @@ -1,9 +1,20 @@ +/* + * Copyright (c) 2009, 2010 Nicira Networks. + * Distributed under the terms of the GNU GPL version 2. + * + * Significant portions of this file may be copied from parts of the Linux + * kernel, by Linus Torvalds and others. + */ + +#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt + #include #include #include #include #include #include +#include "brc_procfs.h" #include "openvswitch/brcompat-netlink.h" /* This code implements a Generic Netlink command BRC_GENL_C_SET_PROC that can @@ -41,7 +52,7 @@ static struct file_operations brc_fops = { static struct proc_dir_entry *proc_vlan_dir; static struct proc_dir_entry *proc_bonding_dir; -struct proc_dir_entry *brc_lookup_entry(struct proc_dir_entry *de, const char *name) +static struct proc_dir_entry *brc_lookup_entry(struct proc_dir_entry *de, const char *name) { int namelen = strlen(name); for (de = de->subdir; de; de = de->next) { @@ -60,9 +71,9 @@ static struct proc_dir_entry *brc_open_dir(const char *dir_name, if (!*dirp) { struct proc_dir_entry *dir; if (brc_lookup_entry(parent, dir_name)) { - printk(KERN_WARNING "%s proc directory exists, can't " - "simulate--probably its real module is " - "loaded\n", dir_name); + pr_warn("%s proc directory exists, can't simulate--" + "probably its real module is loaded\n", + dir_name); return NULL; } dir = *dirp = proc_mkdir(dir_name, parent);