Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\vsprintf.c Create Date:2022-07-28 06:12:14
Last Modify:2022-05-21 09:47:42 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:ip_addr_string

Proto:static __attribute__((__noinline__)) char *ip_addr_string(char *buf, char *end, const void *ptr, struct printf_spec spec, const char *fmt)

Type:char

Parameter:

TypeParameterName
char *buf
char *end
const void *ptr
struct printf_specspec
const char *fmt
1555  If check_pointer( & buf, end, ptr, spec) Then Return buf
1559  Case fmt[1] == '6'
1560  Return ip6_addr_string(buf, end, ptr, spec, fmt)
1561  Case fmt[1] == '4'
1562  Return ip4_addr_string(buf, end, ptr, spec, fmt)
1563  Case fmt[1] == 'S'
1564  const union{struct sockaddr raw;struct sockaddr_in v4;struct sockaddr_in6 v6;} * sa = ptr
1572  Return ip4_addr_string_sa(buf, end, & v4, spec, fmt)
1574  Return ip6_addr_string_sa(buf, end, & v6, spec, fmt)
1575  Default
1580  err_fmt_msg = If fmt[0] == 'i' Then "(%pi?)" Else "(%pI?)"
1581  Return Be careful: error messages must fit into the given buffer.
Caller
NameDescribe
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