super.c (9b569ea0be6fb27a4985acc9325896a3edc95ede) | super.c (bbde07a40a13cc5a3483eaeb52e9bb3b61d2cf57) |
---|---|
1// SPDX-License-Identifier: GPL-2.0 2/* 3 * Copyright (C) 2007 Oracle. All rights reserved. 4 */ 5 6#include <linux/blkdev.h> 7#include <linux/module.h> 8#include <linux/fs.h> --- 167 unchanged lines hidden (view full) --- 176 unsigned int line, int errno, const char *fmt, ...) 177{ 178 struct super_block *sb = fs_info->sb; 179#ifdef CONFIG_PRINTK 180 char statestr[STATE_STRING_BUF_LEN]; 181 const char *errstr; 182#endif 183 | 1// SPDX-License-Identifier: GPL-2.0 2/* 3 * Copyright (C) 2007 Oracle. All rights reserved. 4 */ 5 6#include <linux/blkdev.h> 7#include <linux/module.h> 8#include <linux/fs.h> --- 167 unchanged lines hidden (view full) --- 176 unsigned int line, int errno, const char *fmt, ...) 177{ 178 struct super_block *sb = fs_info->sb; 179#ifdef CONFIG_PRINTK 180 char statestr[STATE_STRING_BUF_LEN]; 181 const char *errstr; 182#endif 183 |
184#ifdef CONFIG_PRINTK_INDEX 185 printk_index_subsys_emit( 186 "BTRFS: error (device %s%s) in %s:%d: errno=%d %s", 187 KERN_CRIT, fmt); 188#endif 189 |
|
184 /* 185 * Special case: if the error is EROFS, and we're already 186 * under SB_RDONLY, then it is safe here. 187 */ 188 if (errno == -EROFS && sb_rdonly(sb)) 189 return; 190 191#ifdef CONFIG_PRINTK --- 76 unchanged lines hidden (view full) --- 268{ 269 char lvl[PRINTK_MAX_SINGLE_HEADER_LEN + 1] = "\0"; 270 struct va_format vaf; 271 va_list args; 272 int kern_level; 273 const char *type = logtypes[4]; 274 struct ratelimit_state *ratelimit = &printk_limits[4]; 275 | 190 /* 191 * Special case: if the error is EROFS, and we're already 192 * under SB_RDONLY, then it is safe here. 193 */ 194 if (errno == -EROFS && sb_rdonly(sb)) 195 return; 196 197#ifdef CONFIG_PRINTK --- 76 unchanged lines hidden (view full) --- 274{ 275 char lvl[PRINTK_MAX_SINGLE_HEADER_LEN + 1] = "\0"; 276 struct va_format vaf; 277 va_list args; 278 int kern_level; 279 const char *type = logtypes[4]; 280 struct ratelimit_state *ratelimit = &printk_limits[4]; 281 |
282#ifdef CONFIG_PRINTK_INDEX 283 printk_index_subsys_emit("%sBTRFS %s (device %s): ", NULL, fmt); 284#endif 285 |
|
276 va_start(args, fmt); 277 278 while ((kern_level = printk_get_level(fmt)) != 0) { 279 size_t size = printk_skip_level(fmt) - fmt; 280 281 if (kern_level >= '0' && kern_level <= '7') { 282 memcpy(lvl, fmt, size); 283 lvl[size] = '\0'; --- 2595 unchanged lines hidden --- | 286 va_start(args, fmt); 287 288 while ((kern_level = printk_get_level(fmt)) != 0) { 289 size_t size = printk_skip_level(fmt) - fmt; 290 291 if (kern_level >= '0' && kern_level <= '7') { 292 memcpy(lvl, fmt, size); 293 lvl[size] = '\0'; --- 2595 unchanged lines hidden --- |