Debian Codegraph @

message.c

raw symbols SCIP
1 // SPDX-License-Identifier: GPL-2.0-only
2 /*
3 * Copyright (C) 2018 Ernesto A. Fernández <[email protected]>
4 */
5
6 #include <linux/fs.h>
7 #include "apfs.h"
8
9 void apfs_msg(struct super_block *sb, const char *prefix, const char *func, int line, const char *fmt, ...)
10 {
11 char *sb_id = NULL;
12 struct va_format vaf;
13 va_list args;
14
15 va_start(args, fmt);
16
17 vaf.fmt = fmt;
18 vaf.va = &args;
19
20 /* The superblock is not available to all callers */
21 sb_id = sb ? sb->s_id : "?";
22
23 if (func)
24 printk("%sAPFS (%s): %pV (%s:%d)\n", prefix, sb_id, &vaf, func, line);
25 else
26 printk("%sAPFS (%s): %pV\n", prefix, sb_id, &vaf);
27
28 va_end(args);
29 }