X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=datapath%2Fbrc_procfs.c;h=6bcb51c2412bf44e348eabc1ab080512e58625fc;hb=9fe3b9a2eeace9689def807e78e35c79e4b1814b;hp=cfe0175b3e57c327832ec141eb0de35da853abcb;hpb=a0bc29a541fc7dc6e20137d5558e2094d614e6ab;p=openvswitch diff --git a/datapath/brc_procfs.c b/datapath/brc_procfs.c index cfe0175b..6bcb51c2 100644 --- a/datapath/brc_procfs.c +++ b/datapath/brc_procfs.c @@ -1,11 +1,13 @@ /* - * Copyright (c) 2009, 2010 Nicira Networks. + * Copyright (c) 2009, 2010, 2011 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 @@ -69,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); @@ -169,7 +171,7 @@ static void kill_proc_dir(const char *dir_name, if (!e) break; - if (e->namelen >= sizeof name) { + if (e->namelen >= sizeof(name)) { /* Can't happen: we prevent adding names this long by * limiting the BRC_GENL_A_PROC_NAME string to * BRC_NAME_LEN_MAX bytes. */