Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\string.c Create Date:2022-07-28 06:00:37
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:sysfs_streq - return true if strings are equal, modulo trailing newline*@s1: one string*@s2: another string* This routine returns true iff two strings are equal, treating both* NUL and newline-then-NUL as equivalent string terminations

Proto:bool sysfs_streq(const char *s1, const char *s2)

Type:bool

Parameter:

TypeParameterName
const char *s1
const char *s2
664  When s1 && s1 == s2 cycle
665  s1++
666  s2++
669  If s1 == s2 Then Return true
671  If Not s1 && s2 == '\n' && Not s2[1] Then Return true
673  If s1 == '\n' && Not s1[1] && Not s2 Then Return true
675  Return false
Caller
NameDescribe
__sysfs_match_string__sysfs_match_string - matches given string in an array*@array: array of strings*@n: number of strings in the array or -1 for NULL terminated arrays*@str: string to match with* Returns index of @str in the @array or -EINVAL, just like match_string().