All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
To: Linux Doc Mailing List <linux-doc@vger.kernel.org>,
	Jonathan Corbet <corbet@lwn.net>
Cc: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	Andrew Lunn <andrew@lunn.ch>,
	Heiner Kallweit <hkallweit1@gmail.com>,
	Russell King <linux@armlinux.org.uk>,
	linux-kernel@vger.kernel.org, netdev@vger.kernel.org
Subject: [PATCH v3 14/32] net: phy: remove kernel-doc duplication
Date: Tue, 27 Oct 2020 10:51:18 +0100	[thread overview]
Message-ID: <75e9a357f9a716833d2094b04898754876365e68.1603791716.git.mchehab+huawei@kernel.org> (raw)
In-Reply-To: <cover.1603791716.git.mchehab+huawei@kernel.org>

Sphinx 3 now checks for duplicated function declarations:

	.../Documentation/networking/kapi:143: ../include/linux/phy.h:163: WARNING: Duplicate C declaration, also defined in 'networking/kapi'.
	Declaration is 'unsigned int phy_supported_speeds (struct phy_device *phy, unsigned int *speeds, unsigned int size)'.
	.../Documentation/networking/kapi:143: ../include/linux/phy.h:1034: WARNING: Duplicate C declaration, also defined in 'networking/kapi'.
	Declaration is 'int phy_read_mmd (struct phy_device *phydev, int devad, u32 regnum)'.
	.../Documentation/networking/kapi:143: ../include/linux/phy.h:1076: WARNING: Duplicate C declaration, also defined in 'networking/kapi'.
	Declaration is 'int __phy_read_mmd (struct phy_device *phydev, int devad, u32 regnum)'.
	.../Documentation/networking/kapi:143: ../include/linux/phy.h:1088: WARNING: Duplicate C declaration, also defined in 'networking/kapi'.
	Declaration is 'int phy_write_mmd (struct phy_device *phydev, int devad, u32 regnum, u16 val)'.
	.../Documentation/networking/kapi:143: ../include/linux/phy.h:1100: WARNING: Duplicate C declaration, also defined in 'networking/kapi'.
	Declaration is 'int __phy_write_mmd (struct phy_device *phydev, int devad, u32 regnum, u16 val)'.

It turns that both the C and the H files have the same
kernel-doc markup for the same functions. Let's drop the
at the header file, keeping the one closer to the code.

Signed-off-by: Mauro Carvalho Chehab <mchehab+huawei@kernel.org>
---
 include/linux/phy.h | 40 +++++-----------------------------------
 1 file changed, 5 insertions(+), 35 deletions(-)

diff --git a/include/linux/phy.h b/include/linux/phy.h
index eb3cb1a98b45..56563e5e0dc7 100644
--- a/include/linux/phy.h
+++ b/include/linux/phy.h
@@ -147,16 +147,8 @@ typedef enum {
 	PHY_INTERFACE_MODE_MAX,
 } phy_interface_t;
 
-/**
+/*
  * phy_supported_speeds - return all speeds currently supported by a PHY device
- * @phy: The PHY device to return supported speeds of.
- * @speeds: buffer to store supported speeds in.
- * @size: size of speeds buffer.
- *
- * Description: Returns the number of supported speeds, and fills
- * the speeds buffer with the supported speeds. If speeds buffer is
- * too small to contain all currently supported speeds, will return as
- * many speeds as can fit.
  */
 unsigned int phy_supported_speeds(struct phy_device *phy,
 				      unsigned int *speeds,
@@ -1022,14 +1014,9 @@ static inline int __phy_modify_changed(struct phy_device *phydev, u32 regnum,
 					regnum, mask, set);
 }
 
-/**
+/*
  * phy_read_mmd - Convenience function for reading a register
  * from an MMD on a given PHY.
- * @phydev: The phy_device struct
- * @devad: The MMD to read from
- * @regnum: The register on the MMD to read
- *
- * Same rules as for phy_read();
  */
 int phy_read_mmd(struct phy_device *phydev, int devad, u32 regnum);
 
@@ -1064,38 +1051,21 @@ int phy_read_mmd(struct phy_device *phydev, int devad, u32 regnum);
 	__ret; \
 })
 
-/**
+/*
  * __phy_read_mmd - Convenience function for reading a register
  * from an MMD on a given PHY.
- * @phydev: The phy_device struct
- * @devad: The MMD to read from
- * @regnum: The register on the MMD to read
- *
- * Same rules as for __phy_read();
  */
 int __phy_read_mmd(struct phy_device *phydev, int devad, u32 regnum);
 
-/**
+/*
  * phy_write_mmd - Convenience function for writing a register
  * on an MMD on a given PHY.
- * @phydev: The phy_device struct
- * @devad: The MMD to write to
- * @regnum: The register on the MMD to read
- * @val: value to write to @regnum
- *
- * Same rules as for phy_write();
  */
 int phy_write_mmd(struct phy_device *phydev, int devad, u32 regnum, u16 val);
 
-/**
+/*
  * __phy_write_mmd - Convenience function for writing a register
  * on an MMD on a given PHY.
- * @phydev: The phy_device struct
- * @devad: The MMD to write to
- * @regnum: The register on the MMD to read
- * @val: value to write to @regnum
- *
- * Same rules as for __phy_write();
  */
 int __phy_write_mmd(struct phy_device *phydev, int devad, u32 regnum, u16 val);
 
-- 
2.26.2


  parent reply	other threads:[~2020-10-27 10:02 UTC|newest]

Thread overview: 59+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-10-27  9:51 [PATCH v3 00/32] Documentation build fixes against v5.10-rc1 Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 01/32] scripts: kernel-doc: use :c:union when needed Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 02/32] sphinx: conf.py: properly handle Sphinx 4.0 Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 03/32] docs: hwmon: adm1266.rst: fix a broken reference Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 04/32] docs: admin-guide: net.rst: add a missing blank line Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 05/32] docs: kasan.rst: add two missing blank lines Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 06/32] docs: net: statistics.rst: remove a duplicated kernel-doc Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 07/32] docs: hwmon: mp2975.rst: address some html build warnings Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 08/32] docs: userspace-api: add iommu.rst to the index file Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 09/32] blk-mq: docs: add kernel-doc description for a new struct member Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 10/32] drm: kernel-doc: document drm_dp_set_subconnector_property() params Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 11/32] drm/dp: fix kernel-doc warnings at drm_dp_helper.c Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 12/32] drm/dp: fix a kernel-doc issue at drm_edid.c Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 13/32] mm: pagemap.h: fix two kernel-doc markups Mauro Carvalho Chehab
2020-10-27  9:51 ` Mauro Carvalho Chehab [this message]
2020-10-27 12:41   ` [PATCH v3 14/32] net: phy: remove kernel-doc duplication Andrew Lunn
2020-10-27  9:51 ` [PATCH v3 15/32] crypto: sun8x-ce*: update entries to its documentation Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 16/32] ice: docs fix a devlink info that broke a table Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 17/32] MAINTAINERS: fix broken doc refs due to yaml conversion Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 18/32] docs: lockdep-design: fix some warning issues Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 19/32] locking/refcount: move kernel-doc markups to the proper place Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 20/32] IB/srpt: docs: add a description for cq_size member Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-28  3:48   ` Bart Van Assche
2020-10-28  3:48     ` Bart Van Assche
2020-10-27  9:51 ` [PATCH v3 21/32] docs: fs: api-summary.rst: get rid of kernel-doc include Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 22/32] drm: amdgpu: kernel-doc: update some adev parameters Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 23/32] jbd2: fix a kernel-doc markup Mauro Carvalho Chehab
2020-10-27 21:26   ` Theodore Y. Ts'o
2020-10-27  9:51 ` [PATCH v3 24/32] drm: drm_edid: remove a duplicated kernel-doc declaration Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 25/32] drm: kernel-doc: add description for a new function parameter Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27 10:04   ` Gerd Hoffmann
2020-10-27 10:04     ` Gerd Hoffmann
2020-10-27  9:51 ` [PATCH v3 26/32] gpu: docs: amdgpu.rst: get rid of wrong kernel-doc markups Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 27/32] drm: kernel-doc: drm_dp_helper.h: fix a typo Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 28/32] drm: amdgpu_dm: " Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 29/32] selftests: kselftest_harness.h: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 30/32] amdgpu: fix a few kernel-doc markup issues Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27  9:51 ` [PATCH v3 31/32] drm: drm_print.h: fix kernel-doc markups Mauro Carvalho Chehab
2020-10-27  9:51   ` Mauro Carvalho Chehab
2020-10-27 10:22   ` Daniel Vetter
2020-10-27 10:22     ` Daniel Vetter
2020-10-27  9:51 ` [PATCH v3 32/32] docs: SafeSetID: fix a warning Mauro Carvalho Chehab
2020-10-28 17:46 ` [PATCH v3 00/32] Documentation build fixes against v5.10-rc1 Jonathan Corbet

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=75e9a357f9a716833d2094b04898754876365e68.1603791716.git.mchehab+huawei@kernel.org \
    --to=mchehab+huawei@kernel.org \
    --cc=andrew@lunn.ch \
    --cc=corbet@lwn.net \
    --cc=hkallweit1@gmail.com \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.