函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\vsprintf.c Create Date:2022-07-27 07:09:25
Last Modify:2022-05-21 09:47:42 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:resource_string

函数原型:static __attribute__((__noinline__)) char *resource_string(char *buf, char *end, struct resource *res, struct printf_spec spec, const char *fmt)

返回类型:char

参数:

类型参数名称
char *buf
char *end
struct resource *res
struct printf_specspec
const char *fmt
1012  static const struct printf_spec io_spec = { number base, 8, 10 or 16 only = 16, width of output field = IO_RSRC_PRINTK_SIZE, # of digits/chars = - 1, flags to number() = prefix hex with "0x", octal with "0" | use lowercase in hex (must be 32 == 0x20) | pad with zero, must be 16 == '0' - ' ' , }
1018  static const struct printf_spec mem_spec = { number base, 8, 10 or 16 only = 16, width of output field = MEM_RSRC_PRINTK_SIZE, # of digits/chars = - 1, flags to number() = prefix hex with "0x", octal with "0" | use lowercase in hex (must be 32 == 0x20) | pad with zero, must be 16 == '0' - ' ' , }
1024  static const struct printf_spec bus_spec = { number base, 8, 10 or 16 only = 16, width of output field = 2, # of digits/chars = - 1, flags to number() = use lowercase in hex (must be 32 == 0x20) | pad with zero, must be 16 == '0' - ' ' , }
1030  static const struct printf_spec str_spec = { width of output field = - 1, # of digits/chars = 10, flags to number() = left justified , }
1045  p等于sym, pend等于symsym的长度
1046  decode等于如果fmt[0]恒等于'R'则1否则0
1049  如果check_pointer( & buf, end, res, spec)则返回:buf
1052  p自加等于'['
1053  如果flags按位与PCI/ISA I/O ports
1054  p等于Handle string from a well known address.
1055  specp等于io_spec
1056  否则如果flags按位与IORESOURCE_MEM
1057  p等于Handle string from a well known address.
1058  specp等于mem_spec
1059  否则如果flags按位与IORESOURCE_IRQ
1060  p等于Handle string from a well known address.
1061  specp等于default_dec_spec
1062  否则如果flags按位与IORESOURCE_DMA
1063  p等于Handle string from a well known address.
1064  specp等于default_dec_spec
1065  否则如果flags按位与IORESOURCE_BUS
1066  p等于Handle string from a well known address.
1067  specp等于bus_spec
1068  否则
1069  p等于Handle string from a well known address.
1070  specp等于mem_spec
1071  decode等于0
1073  如果decodeflags按位与No address assigned yet
1074  p等于Handle string from a well known address.
1075  p等于number(p, pend, resource_size(res), * specp)
1076  否则
1077  p等于number(p, pend, start, * specp)
1078  如果start不等于end
1079  p自加等于'-'
1080  p等于number(p, pend, end, * specp)
1083  如果decode
1084  如果flags按位与IORESOURCE_MEM_64p等于Handle string from a well known address.
1086  如果flags按位与No side effects p等于Handle string from a well known address.
1088  如果flags按位与rwarded by bridge p等于Handle string from a well known address.
1090  如果flags按位与IORESOURCE_DISABLEDp等于Handle string from a well known address.
1092  否则
1093  p等于Handle string from a well known address.
1094  p等于number(p, pend, flags, default_flag_spec)
1096  p自加等于']'
1097  p等于'\0'
1099  返回:Handle string from a well known address.
调用者
名称描述
pointerShow a '%p' thing. A kernel extension is that the '%p' is followed* by an extra set of alphanumeric characters that are extended format* specifiers.* Please update scripts/checkpatch.pl when adding/removing conversion* characters