Lines Matching full:s
69 my $type_fp_param2 = '\@(\w+->\S+)\(\)'; # Special RST handling for structs with func ptr params
71 my $type_enum = '\&(enum\s*([_\w]+))';
72 my $type_struct = '\&(struct\s*([_\w]+))';
73 my $type_typedef = '\&(typedef\s*([_\w]+))';
74 my $type_union = '\&(union\s*([_\w]+))';
160 (my $seconds = `date -d"${ENV{'KBUILD_BUILD_TIMESTAMP'}}" +%s`) ne '') {
195 # kernel's build system
203 # docbook v3.1 requires a non-zero sequence of RefEntry's; see:
234 # Spit a warning as it's not
246 my $doc_start = '^/\*\*\s*$'; # Allow whitespace at end of comment start.
248 my $doc_com = '\s*\*\s*';
249 my $doc_com_body = '\s*\* ?';
259 '\s*(\@[.\w]+|\@\.\.\.|description|context|returns?|notes?|examples?)\s*:([^:].*)?$';
261 my $doc_block = $doc_com . 'DOC:\s*(.*)?';
262 my $doc_inline_start = '^\s*/\*\*\s*$';
263 my $doc_inline_sect = '\s*\*\s*(@\s*[\w][\w\.]*\s*):(.*)';
264 my $doc_inline_end = '^\s*\*/\s*$';
265 my $doc_inline_oneline = '^\s*/\*\*\s*(@[\w\s]+):\s*(.*)\s*\*/\s*$';
266 my $export_symbol = '^\s*EXPORT_SYMBOL(_GPL)?\s*\(\s*(\w+)\s*\)\s*;';
267 my $export_symbol_ns = '^\s*EXPORT_SYMBOL_NS(_GPL)?\s*\(\s*(\w+)\s*,\s*\w+\)\s*;';
268 my $function_pointer = qr{([^\(]*\(\*)\s*\)\s*\(([^\)]*)\)};
269 my $attribute = qr{__attribute__\s*\(\([a-z0-9,_\*\s\(\)]*\)\)}i;
415 if (m/^\s*sphinx-build\s+([\d]+)\.([\d\.]+)(\+\/[\da-f]+)?$/) {
422 if (m/^\s*Sphinx.*\s+([\d]+)\.([\d\.]+)$/) {
546 $line =~ s/^\s*//;
570 …print ".TH \"$args{'function'}\" 9 \"$args{'function'}\" \"$man_date\" \"Kernel Hacker's Manual\" …
593 $type =~ s/([^\*])$/$1 /;
603 $parameter_name =~ s/\[.*//;
644 $parameter_name =~ s/\[.*//;
667 $declaration =~ s/\t/ /g;
668 $declaration =~ s/\n/"\n.br\n.BI \"/g;
678 $parameter_name =~ s/\[.*//;
725 # This could use some work; it's used to output the DOC: sections, and
777 if (! ($line =~ /^\s*$/)) {
783 $line =~ /^(\s*)/;
897 $parameter_name =~ s/\[.*//;
1021 $declaration =~ s/\t/$lineprefix/g;
1030 $parameter_name =~ s/\[.*//;
1119 my $definition_body = qr{\{(.*)\}\s*$qualifiers*};
1122 if ($x =~ /($type)\s+(\w+)\s*$definition_body/) {
1126 } elsif ($x =~ /typedef\s+($type)\s*$definition_body\s*(\w+)\s*;/) {
1139 $members =~ s/\/\*\s*private:.*?\/\*\s*public:.*?\*\///gosi;
1140 $members =~ s/\/\*\s*private:.*//gosi;
1142 $members =~ s/\/\*.*?\*\///gos;
1144 $members =~ s/\s*$attribute/ /gi;
1145 $members =~ s/\s*__aligned\s*\([^;]*\)/ /gos;
1146 $members =~ s/\s*__packed\s*/ /gos;
1147 $members =~ s/\s*CRYPTO_MINALIGN_ATTR/ /gos;
1148 $members =~ s/\s*____cacheline_aligned_in_smp/ /gos;
1149 $members =~ s/\s*____cacheline_aligned/ /gos;
1153 $members =~ s/\bstruct_group\s*\(([^,]*,)/STRUCT_GROUP(/gos;
1154 $members =~ s/\bstruct_group_(attr|tagged)\s*\(([^,]*,){2}/STRUCT_GROUP(/gos;
1155 $members =~ s/\b__struct_group\s*\(([^,]*,){3}/STRUCT_GROUP(/gos;
1156 $members =~ s/\bSTRUCT_GROUP(\(((?:(?>[^)(]+)|(?1))*)\))[^;]*;/$2/gos;
1160 …$members =~ s/__ETHTOOL_DECLARE_LINK_MODE_MASK\s*\(([^\)]+)\)/DECLARE_BITMAP($1, __ETHTOOL_LINK_MO…
1161 …$members =~ s/DECLARE_PHY_INTERFACE_MASK\s*\(([^\)]+)\)/DECLARE_BITMAP($1, PHY_INTERFACE_MODE_MAX)…
1162 $members =~ s/DECLARE_BITMAP\s*\($args,\s*$args\)/unsigned long $1\[BITS_TO_LONGS($2)\]/gos;
1164 $members =~ s/DECLARE_HASHTABLE\s*\($args,\s*$args\)/unsigned long $1\[1 << (($2) - 1)\]/gos;
1166 $members =~ s/DECLARE_KFIFO\s*\($args,\s*$args,\s*$args\)/$2 \*$1/gos;
1168 $members =~ s/DECLARE_KFIFO_PTR\s*\($args,\s*$args\)/$2 \*$1/gos;
1170 $members =~ s/(?:__)?DECLARE_FLEX_ARRAY\s*\($args,\s*$args\)/$1 $2\[\]/gos;
1172 $members =~ s/DEFINE_DMA_UNMAP_ADDR\s*\($args\)/dma_addr_t $1/gos;
1174 $members =~ s/DEFINE_DMA_UNMAP_LEN\s*\($args\)/__u32 $1/gos;
1186 $id =~ s/[:\[].*//;
1187 $id =~ s/^\s*\**(\S+)\s*/$1/;
1189 next if ($arg =~ m/^\s*$/);
1190 if ($arg =~ m/^([^\(]+\(\*?\s*)([\w\.]*)(\s*\).*)/) {
1196 if ($id =~ m/^\s*$/) {
1205 $arg =~ s/^\s+//;
1206 $arg =~ s/\s+$//;
1208 $arg =~ s/:\s*\d+\s*//g;
1210 $arg =~ s/\[.*\]//g;
1217 $arg =~ s/\s*,\s*/,/g;
1218 if ($arg =~ m/(.*)\s+([\S+,]+)/) {
1226 $name =~ s/^\s*\**(\S+)\s*/$1/;
1227 next if (($name =~ m/^\s*$/));
1228 if ($id =~ m/^\s*$/) {
1238 $members =~ s/$struct_members/$newmember/;
1242 $members =~ s/(\{[^\{\}]*\})//g;
1248 $declaration =~ s/([\{;])/$1\n/g;
1249 $declaration =~ s/\}\s+;/};/g;
1251 do {} while ($declaration =~ s/(enum\s+\{[^\}]+),([^\n])/$1,\n$2/);
1257 $clause =~ s/^\s+//;
1258 $clause =~ s/\s+$//;
1259 $clause =~ s/\s+/ /;
1262 if (!($clause =~ m/^\s*#/)) {
1327 $x =~ s/\/\*\s*private:.*?\/\*\s*public:.*?\*\///gosi;
1328 $x =~ s/\/\*\s*private:.*}/}/gosi;
1330 $x =~ s@/\*.*?\*/@@gos; # strip comments.
1332 $x =~ s@#\s*((define|ifdef)\s+|endif)[^;]*;@@gos;
1334 if ($x =~ /typedef\s+enum\s*\{(.*)\}\s*(\w*)\s*;/) {
1337 } elsif ($x =~ /enum\s+(\w*)\s*\{(.*)\}/) {
1355 $members =~ s/\s+$//;
1356 $members =~ s/\([^;]*?[\)]//g;
1359 $arg =~ s/^\s*(\w+).*/$1/;
1394 my $typedef_type = qr { ((?:\s+[\w\*]+\b){1,8})\s* }x;
1395 my $typedef_ident = qr { \*?\s*(\w\S+)\s* }x;
1396 my $typedef_args = qr { \s*\((.*)\); }x;
1405 $x =~ s@/\*.*?\*/@@gos; # strip comments.
1412 $return_type =~ s/^\s+//;
1437 while (($x =~ /\(*.\)\s*;$/) || ($x =~ /\[*.\]\s*;$/)) {
1438 $x =~ s/\(*.\)\s*;$/;/;
1439 $x =~ s/\[*.\]\s*;$/;/;
1442 if ($x =~ /typedef.*\s+(\w+)\s*;/) {
1469 $actual =~ s/\s*//g;
1484 $args =~ s/($arg_expr),/$1#/g;
1489 $arg =~ s/\/\*.*\*\///;
1491 $arg =~ s/\sPOS0?\s/ /;
1493 $arg =~ s/^\s*//;
1494 $arg =~ s/\s*$//;
1495 $arg =~ s/\s+/ /;
1502 } elsif ($arg =~ m/\(.+\)\s*\(/) {
1505 $arg =~ m/[^\(]+\(\*?\s*([\w\[\]\.]*)\s*\)/;
1508 $type =~ s/([^\(]+\(\*?)\s*$param/$1/;
1512 $arg =~ s/\s*:\s*/:/g;
1513 $arg =~ s/\s*\[/\[/g;
1515 my @args = split('\s*,\s*', $arg);
1517 $args[0] =~ s/(\*+)\s*/ $1/;
1521 if ($args[0] =~ /^(.*\s+)(.*?\[.*\].*)$/) {
1523 push(@first_arg, split('\s+', $1));
1526 @first_arg = split('\s+', shift @args);
1533 if ($param =~ m/^(\*+)\s*(.*)/) {
1566 $param =~ s/[\[\)].*//;
1576 $param =~ s/\.\.\.$//;
1613 # but it's better to maintain the param string unchanged for output,
1616 ###$param =~ s/\s*//g;
1618 $org_arg =~ s/\s\s+/ /g;
1634 $prm_clean =~ s/\[.*\]//;
1635 $prm_clean =~ s/$attribute//i;
1642 $prm_clean =~ s/\[.*//;
1644 ##$prm_clean =~ s/^\**//;
1668 # Ignore an empty return type (It's a macro)
1670 if (($return_type eq "") || ($return_type =~ /void\s*\w*\s*$/)) {
1693 $prototype =~ s/^static +//;
1694 $prototype =~ s/^extern +//;
1695 $prototype =~ s/^asmlinkage +//;
1696 $prototype =~ s/^inline +//;
1697 $prototype =~ s/^__inline__ +//;
1698 $prototype =~ s/^__inline +//;
1699 $prototype =~ s/^__always_inline +//;
1700 $prototype =~ s/^noinline +//;
1701 $prototype =~ s/^__FORTIFY_INLINE +//;
1702 $prototype =~ s/__init +//;
1703 $prototype =~ s/__init_or_module +//;
1704 $prototype =~ s/__deprecated +//;
1705 $prototype =~ s/__flatten +//;
1706 $prototype =~ s/__meminit +//;
1707 $prototype =~ s/__must_check +//;
1708 $prototype =~ s/__weak +//;
1709 $prototype =~ s/__sched +//;
1710 $prototype =~ s/__printf\s*\(\s*\d*\s*,\s*\d*\s*\) +//;
1711 $prototype =~ s/__(?:re)?alloc_size\s*\(\s*\d+\s*(?:,\s*\d+\s*)?\) +//;
1712 $prototype =~ s/__diagnose_as\s*\(\s*\S+\s*(?:,\s*\d+\s*)*\) +//;
1713 my $define = $prototype =~ s/^#\s*define\s+//; #ak added
1714 $prototype =~ s/__attribute_const__ +//;
1715 $prototype =~ s/__attribute__\s*\(\(
1717 [\w\s]++ # attribute name
1719 \s*+,? # optional comma at the end
1721 \)\)\s+//x;
1733 # If you mess with these regexps, it's a good idea to check that
1742 my $type1 = qr{[\w\s]+};
1745 if ($define && $prototype =~ m/^()($name)\s+/) {
1749 # declaration_name and opening parenthesis (notice the \s+).
1753 } elsif ($prototype =~ m/^()($name)\s*$prototype_end/ ||
1754 $prototype =~ m/^($type1)\s+($name)\s*$prototype_end/ ||
1755 $prototype =~ m/^($type2+)\s*($name)\s*$prototype_end/) {
1844 $tracepointname =~ s/^\s+//; #strip leading whitespace
1860 $prototype =~ s@[\r\n]+@ @gos; # strip newlines/CR's
1861 ## if ($prototype =~ m/SYSCALL_DEFINE0\s*\(\s*(a-zA-Z0-9_)*\s*\)/) {
1867 $prototype =~ s/SYSCALL_DEFINE.*\(/long sys_/; # fix return type & func name
1869 $prototype =~ s/,/\(/;
1871 $prototype =~ s/\)/\(void\)/;
1895 $x =~ s@\/\/.*$@@gos; # strip C99-style comments to end of line
1897 if ($x =~ m#\s*/\*\s+MACDOC\s*#io || ($x =~ /^#/ && $x !~ /^#\s*define/)) {
1904 if (($x =~ /\{/) || ($x =~ /\#\s*define/) || ($x =~ /;/)) {
1905 $prototype =~ s@/\*.*?\*/@@gos; # strip comments.
1906 $prototype =~ s@[\r\n]+@ @gos; # strip newlines/cr's.
1907 $prototype =~ s@^\s+@@gos; # strip leading spaces
1911 $prototype =~ s@^(\S+\s+)\(\s*\*(\S+)\)@$1$2@gos;
1930 $x =~ s@[\r\n]+@ @gos; # strip newlines/cr's.
1931 $x =~ s@^\s+@@gos; # strip leading spaces
1932 $x =~ s@\s+$@@gos; # strip trailing spaces
1933 $x =~ s@\/\/.*$@@gos; # strip C99-style comments to end of line
2038 my $fn_type = qr{\w+\s*\*\s*};
2041 if (/^$decl_start([\w\s]+?)$parenthesis?\s*$decl_end?$/) {
2044 if ($identifier =~ m/^(struct|union|enum|typedef)\b\s*(\S*)/) {
2051 elsif (/^$decl_start$fn_type?(\w+)\s*$parenthesis?\s*$decl_end?$/ ||
2052 /^$decl_start$fn_type?(\w+.*)$parenthesis?\s*$decl_end$/) {
2055 $identifier =~ s/^define\s+//;
2058 $identifier =~ s/\s+$//;
2061 # if there's no @param blocks need to set up default section
2069 $descr =~ s/^\s*//;
2070 $descr =~ s/\s*$//;
2071 $descr =~ s/\s+/ /g;
2108 if ($state == STATE_BODY_WITH_BLANK_LINE && /^\s*\*\s?\S/) {
2158 if ($_ =~ m'\s*\*\s*[a-zA-Z_0-9:\.]+\*/') {
2186 $declaration_purpose =~ s/\s+/ /g;
2191 if ($cont =~ m/^(\s+)/) {
2197 $cont =~ s/^$leading_space//;
2292 if ($contents =~ /^\s*$/) {
2320 while (s/\\\s*$//) {
2324 while ($_ =~ s/\t+/' ' x (length($&) * 8 - length($`) % 8)/e) {};
2364 # using the s// operator.
2369 $dohighlight .= "\$contents =~ s:$pattern:$result:gs;\n";
2379 $relname =~ s:^/+::;