summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorRandy Dunlap <rdunlap@infradead.org>2021-10-29 19:11:21 -0700
committerJonathan Corbet <corbet@lwn.net>2021-11-01 11:28:35 -0600
commit603bdf5d6c092eb05666decd84288dfda71eee90 (patch)
tree140e50282ddb214abbeb01527937ec0bcf8f5713 /scripts
parent75ca80e4c4d779c1382595b172c3c21a8959fd6d (diff)
kernel-doc: support DECLARE_PHY_INTERFACE_MASK()
Support the DECLARE_PHY_INTERFACE_MASK() macro that is used to declare a bitmap by converting the macro to DECLARE_BITMAP(), as has been done for the __ETHTOOL_DECLARE_LINK_MODE_MASK() macro. This fixes a 'make htmldocs' warning: include/linux/phylink.h:82: warning: Function parameter or member 'DECLARE_PHY_INTERFACE_MASK(supported_interfaces' not described in 'phylink_config' that was introduced by commit 38c310eb46f5 ("net: phylink: add MAC phy_interface_t bitmap") Signed-off-by: Randy Dunlap <rdunlap@infradead.org> Reported-by: Stephen Rothwell <sfr@canb.auug.org.au> Cc: Russell King (Oracle) <linux@armlinux.org.uk> Link: https://lore.kernel.org/r/45934225-7942-4326-f883-a15378939db9@infradead.org Signed-off-by: Jonathan Corbet <corbet@lwn.net>
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/kernel-doc1
1 files changed, 1 insertions, 0 deletions
diff --git a/scripts/kernel-doc b/scripts/kernel-doc
index c123bac28f7a..3039059b3d68 100755
--- a/scripts/kernel-doc
+++ b/scripts/kernel-doc
@@ -1249,6 +1249,7 @@ sub dump_struct($$) {
my $args = qr{([^,)]+)};
# replace DECLARE_BITMAP
$members =~ s/__ETHTOOL_DECLARE_LINK_MODE_MASK\s*\(([^\)]+)\)/DECLARE_BITMAP($1, __ETHTOOL_LINK_MODE_MASK_NBITS)/gos;
+ $members =~ s/DECLARE_PHY_INTERFACE_MASK\s*\(([^\)]+)\)/DECLARE_BITMAP($1, PHY_INTERFACE_MODE_MAX)/gos;
$members =~ s/DECLARE_BITMAP\s*\($args,\s*$args\)/unsigned long $1\[BITS_TO_LONGS($2)\]/gos;
# replace DECLARE_HASHTABLE
$members =~ s/DECLARE_HASHTABLE\s*\($args,\s*$args\)/unsigned long $1\[1 << (($2) - 1)\]/gos;