Skip to contentSkip to conversation

phy: mvebu-cp110-utmi: Fix kernel-doc warns

PATCH In review Vinod Koul 4 participants 14 messages Nov 16, 2021 – Nov 20, 2021

Subsystems (2)
lore
Share & tools
lore

Vinod Koul

author maintainer
#0 lore raw

PATCH 1/6 phy: mvebu-cp110-utmi: Fix kernel-doc warns

Fix the format and add description for ops to fix the below warnings:

drivers/phy/marvell/phy-mvebu-cp110-utmi.c:94: warning: Function parameter or member 'syscon' not described in 'mvebu_cp110_utmi' drivers/phy/marvell/phy-mvebu-cp110-utmi.c:94: warning: Function parameter or member 'ops' not described in 'mvebu_cp110_utmi'

---
 drivers/phy/marvell/phy-mvebu-cp110-utmi.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/phy/marvell/phy-mvebu-cp110-utmi.c +2 -2
index 08d178a4dc13..aa27c7994610 100644
@@ -82,9 +82,9 @@
  * struct mvebu_cp110_utmi - PHY driver data
  *
  * @regs: PHY registers
- * @syscom: Regmap with system controller registers
+ * @syscon: Regmap with system controller registers
  * @dev: device driver handle
- * @caps: PHY capabilities
+ * @ops: phy ops
  */
 struct mvebu_cp110_utmi {
 	void __iomem *regs;
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
author maintainer
#1 lore raw

PATCH 2/6 phy: qualcomm: ipq806x-usb: Fix kernel-doc style

The functions are documented but there were style issues, so fix the style and add missing description for phy_dwc3

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:130:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:174:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:212: warning:
This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

---
 drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c | 26 +++++++++++----------
 1 file changed, 14 insertions(+), 12 deletions(-)
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +14 -12
index bfff0c8c9130..e1b8fa911416 100644
@@ -127,12 +127,13 @@ struct phy_drvdata {
 };
 
 /**
- * Write register and read back masked value to confirm it is written
+ * usb_phy_write_readback - Write register and read back masked value to
+ * confirm it is written
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @offset - register offset.
- * @mask - register bitmask specifying what should be updated
- * @val - value to write.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.
+ * @offset: register offset.
+ * @mask: register bitmask specifying what should be updated
+ * @val: value to write.
  */
 static inline void usb_phy_write_readback(struct usb_phy *phy_dwc3,
 					  u32 offset,
@@ -171,11 +172,11 @@ static int wait_for_latch(void __iomem *addr)
 }
 
 /**
- * Write SSPHY register
+ * usb_ss_write_phycreg - Write SSPHY register
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @addr - SSPHY address to write.
- * @val - value to write.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.
+ * @addr: SSPHY address to write.
+ * @val: value to write.
  */
 static int usb_ss_write_phycreg(struct usb_phy *phy_dwc3,
 				u32 addr, u32 val)
@@ -209,10 +210,11 @@ static int usb_ss_write_phycreg(struct usb_phy *phy_dwc3,
 }
 
 /**
- * Read SSPHY register.
+ * usb_ss_read_phycreg - Read SSPHY register.
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @addr - SSPHY address to read.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.
+ * @addr: SSPHY address to read.
+ * @val: pointer in which read is store.
  */
 static int usb_ss_read_phycreg(struct usb_phy *phy_dwc3,
 			       u32 addr, u32 *val)
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
Reviewed-by on v1 2/6
#2 lore raw

Re: [PATCH 2/6] phy: qualcomm: ipq806x-usb: Fix kernel-doc style

Quoted 9 lines · Vinod Koul

The functions are documented but there were style issues, so fix the style and add missing description for phy_dwc3

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:130:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:174:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:212: warning:
This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

Quoted 5 lines
---
  drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c | 26 +++++++++++----------
  1 file changed, 14 insertions(+), 12 deletions(-)

thanks.

Signature · 1 line
~Randy
#3 lore raw

Re: [PATCH 2/6] phy: qualcomm: ipq806x-usb: Fix kernel-doc style

In reply to Vinod Koul
Quoted 19 lines · Vinod Koul

The functions are documented but there were style issues, so fix the style and add missing description for phy_dwc3

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:130:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:174:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:212: warning:
This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

---
 drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c | 26 +++++++++++----------
 1 file changed, 14 insertions(+), 12 deletions(-)
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +0 -0
index bfff0c8c9130..e1b8fa911416 100644

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c struct phy_drvdata { · line 130

Quoted 5 lines
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +1 -1
@@ -127,12 +127,13 @@ struct phy_drvdata {
 };
 
 /**
- * Write register and read back masked value to confirm it is written
+ * usb_phy_write_readback - Write register and read back masked value to

"Writing kernel-doc" indicates that you should have some parenthesis after that function.

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c struct phy_drvdata { · line 133

Quoted 7 lines
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +2 -4
+ * confirm it is written
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @offset - register offset.
- * @mask - register bitmask specifying what should be updated
- * @val - value to write.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.

I guess this was "base" at some point? As you're fixing up the kerneldoc, it would be nice to correct this to say something like "usb_phy context".

Regards,
Bjorn

Quoted 40 lines
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +11 -7
+ * @offset: register offset.
+ * @mask: register bitmask specifying what should be updated
+ * @val: value to write.
  */
 static inline void usb_phy_write_readback(struct usb_phy *phy_dwc3,
 					  u32 offset,
@@ -171,11 +172,11 @@ static int wait_for_latch(void __iomem *addr)
 }
 
 /**
- * Write SSPHY register
+ * usb_ss_write_phycreg - Write SSPHY register
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @addr - SSPHY address to write.
- * @val - value to write.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.
+ * @addr: SSPHY address to write.
+ * @val: value to write.
  */
 static int usb_ss_write_phycreg(struct usb_phy *phy_dwc3,
 				u32 addr, u32 val)
@@ -209,10 +210,11 @@ static int usb_ss_write_phycreg(struct usb_phy *phy_dwc3,
 }
 
 /**
- * Read SSPHY register.
+ * usb_ss_read_phycreg - Read SSPHY register.
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @addr - SSPHY address to read.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.
+ * @addr: SSPHY address to read.
+ * @val: pointer in which read is store.
  */
 static int usb_ss_read_phycreg(struct usb_phy *phy_dwc3,
 			       u32 addr, u32 *val)
Signature · 1 line
2.31.1
Signature · 3 lines
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
author maintainer
#4 lore raw

Re: [PATCH 2/6] phy: qualcomm: ipq806x-usb: Fix kernel-doc style

Quoted 23 lines · Bjorn Andersson
Quoted 21 lines · Vinod Koul

The functions are documented but there were style issues, so fix the style and add missing description for phy_dwc3

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:130:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:174:
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c:212: warning:
This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

---
 drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c | 26 +++++++++++----------
 1 file changed, 14 insertions(+), 12 deletions(-)
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +0 -0
index bfff0c8c9130..e1b8fa911416 100644
@@ -127,12 +127,13 @@ struct phy_drvdata {
 };
 
Quoted 6 lines

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c struct phy_drvdata { · line 130

Quoted 3 lines
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +1 -1
 /**
- * Write register and read back masked value to confirm it is written
+ * usb_phy_write_readback - Write register and read back masked value to

"Writing kernel-doc" indicates that you should have some parenthesis after that function.

Heh, it does not warn :(, will update this

Quoted 9 lines

drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c struct phy_drvdata { · line 133

Quoted 8 lines
drivers/phy/qualcomm/phy-qcom-ipq806x-usb.c +2 -4
+ * confirm it is written
  *
- * @base - QCOM DWC3 PHY base virtual address.
- * @offset - register offset.
- * @mask - register bitmask specifying what should be updated
- * @val - value to write.
+ * @phy_dwc3: QCOM DWC3 PHY base virtual address.
Quoted 3 lines

I guess this was "base" at some point? As you're fixing up the kerneldoc, it would be nice to correct this to say something like "usb_phy context".

Why did I miss this one :(, yeah will update this

Signature · 1 line
~Vinod
author maintainer
#5 lore raw

PATCH 3/6 phy: qualcomm: qmp: Add missing struct documentation

In reply to Vinod Koul

dp-* members were added to qmp_phy_combo_cfg but documentation was missed, so add that.

drivers/phy/qualcomm/phy-qcom-qmp.c:2995: warning: Function parameter or member 'dp_aux_cfg' not described in 'qmp_phy' drivers/phy/qualcomm/phy-qcom-qmp.c:2995: warning: Function parameter or member 'dp_opts' not described in 'qmp_phy' drivers/phy/qualcomm/phy-qcom-qmp.c:2995: warning: Function parameter or member 'dp_clks' not described in 'qmp_phy'

---
 drivers/phy/qualcomm/phy-qcom-qmp.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/phy/qualcomm/phy-qcom-qmp.c +3 -0
index 456a59d8c7d0..c96639d5f581 100644
@@ -2973,6 +2973,9 @@ struct qmp_phy_combo_cfg {
  * @qmp: QMP phy to which this lane belongs
  * @lane_rst: lane's reset controller
  * @mode: current PHY mode
+ * @dp_aux_cfg: Display port aux config
+ * @dp_opts: Display port optional config
+ * @dp_clks: Display port clocks
  */
 struct qmp_phy {
 	struct phy *phy;
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
Reviewed-by on v1 3/6
#6 lore raw

Re: [PATCH 3/6] phy: qualcomm: qmp: Add missing struct documentation

Quoted 7 lines · Vinod Koul

dp-* members were added to qmp_phy_combo_cfg but documentation was missed, so add that.

drivers/phy/qualcomm/phy-qcom-qmp.c:2995: warning: Function parameter or member 'dp_aux_cfg' not described in 'qmp_phy' drivers/phy/qualcomm/phy-qcom-qmp.c:2995: warning: Function parameter or member 'dp_opts' not described in 'qmp_phy' drivers/phy/qualcomm/phy-qcom-qmp.c:2995: warning: Function parameter or member 'dp_clks' not described in 'qmp_phy'

Regards,
Bjorn

Quoted 22 lines
---
 drivers/phy/qualcomm/phy-qcom-qmp.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/phy/qualcomm/phy-qcom-qmp.c +3 -0
index 456a59d8c7d0..c96639d5f581 100644
@@ -2973,6 +2973,9 @@ struct qmp_phy_combo_cfg {
  * @qmp: QMP phy to which this lane belongs
  * @lane_rst: lane's reset controller
  * @mode: current PHY mode
+ * @dp_aux_cfg: Display port aux config
+ * @dp_opts: Display port optional config
+ * @dp_clks: Display port clocks
  */
 struct qmp_phy {
 	struct phy *phy;
Signature · 1 line
2.31.1
Signature · 3 lines
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
author maintainer
#7 lore raw

PATCH 4/6 phy: qualcomm: usb-hsic: Fix the kernel-doc warn

In reply to Vinod Koul

The comment is not kernel-doc one and starts with /**, so fix that.

drivers/phy/qualcomm/phy-qcom-usb-hsic.c:3: warning:
This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

---
 drivers/phy/qualcomm/phy-qcom-usb-hsic.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/phy/qualcomm/phy-qcom-usb-hsic.c +1 -1
index 04d18d52f700..716a77748ed8 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * Copyright (C) 2016 Linaro Ltd
  */
 #include <linux/module.h>
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
Reviewed-by on v1 4/6
#8 lore raw

Re: [PATCH 4/6] phy: qualcomm: usb-hsic: Fix the kernel-doc warn

Quoted 5 lines · Vinod Koul

The comment is not kernel-doc one and starts with /**, so fix that.

drivers/phy/qualcomm/phy-qcom-usb-hsic.c:3: warning:
This comment starts with '/**', but isn't a kernel-doc comment. Refer Documentation/doc-guide/kernel-doc.rst

Quoted 20 lines
---
 drivers/phy/qualcomm/phy-qcom-usb-hsic.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/phy/qualcomm/phy-qcom-usb-hsic.c +1 -1
index 04d18d52f700..716a77748ed8 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * Copyright (C) 2016 Linaro Ltd
  */
 #include <linux/module.h>
Signature · 1 line
2.31.1
Signature · 3 lines
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
author maintainer
#9 lore raw

PATCH 5/6 phy: ti: omap-usb2: Fix the kernel-doc style

In reply to Vinod Koul

The documentation uses incorrect style, so fix that.

drivers/phy/ti/phy-omap-usb2.c:102: warning: Function parameter or member 'comparator' not described in 'omap_usb2_set_comparator'

While at it, use a single line for function description

---
 drivers/phy/ti/phy-omap-usb2.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/phy/ti/phy-omap-usb2.c +3 -3
index ebceb1520ce8..2102b7f73ffa 100644
@@ -89,9 +89,9 @@ static inline void omap_usb_writel(void __iomem *addr, unsigned int offset,
 }
 
 /**
- * omap_usb2_set_comparator - links the comparator present in the system with
- *	this phy
- * @comparator - the companion phy(comparator) for this phy
+ * omap_usb2_set_comparator - links the comparator present in the system with this phy
+ *
+ * @comparator:  the companion phy(comparator) for this phy
  *
  * The phy companion driver should call this API passing the phy_companion
  * filled with set_vbus and start_srp to be used by usb phy.
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
Reviewed-by on v1 5/6
#10 lore raw

Re: [PATCH 5/6] phy: ti: omap-usb2: Fix the kernel-doc style

Hi Vinod,

Quoted 7 lines · Vinod Koul

The documentation uses incorrect style, so fix that.

drivers/phy/ti/phy-omap-usb2.c:102: warning: Function parameter or member 'comparator' not described in 'omap_usb2_set_comparator'

While at it, use a single line for function description

Minor nit below.

Quoted 9 lines
---
 drivers/phy/ti/phy-omap-usb2.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/phy/ti/phy-omap-usb2.c +0 -0
index ebceb1520ce8..2102b7f73ffa 100644

drivers/phy/ti/phy-omap-usb2.c static inline void omap_usb_writel(void __iomem *addr, unsigned int offset, · line 94

Quoted 9 lines
drivers/phy/ti/phy-omap-usb2.c +3 -3
@@ -89,9 +89,9 @@ static inline void omap_usb_writel(void __iomem *addr, unsigned int offset,
 }
 
 /**
- * omap_usb2_set_comparator - links the comparator present in the system with
- *	this phy
- * @comparator - the companion phy(comparator) for this phy
+ * omap_usb2_set_comparator - links the comparator present in the system with this phy
+ *
+ * @comparator:  the companion phy(comparator) for this phy

There's an extra space after the colon here.

Cheers,
Liam

Quoted 11 lines
drivers/phy/ti/phy-omap-usb2.c +0 -0
  *
  * The phy companion driver should call this API passing the phy_companion
  * filled with set_vbus and start_srp to be used by usb phy.
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
Signature · 3 lines
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
#11 lore raw

Re: [PATCH 5/6] phy: ti: omap-usb2: Fix the kernel-doc style

In reply to Vinod Koul

Hi Vinod,

Quoted 16 lines · Vinod Koul

The documentation uses incorrect style, so fix that.

drivers/phy/ti/phy-omap-usb2.c:102: warning: Function parameter or member 'comparator' not described in 'omap_usb2_set_comparator'

While at it, use a single line for function description

---
 drivers/phy/ti/phy-omap-usb2.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/phy/ti/phy-omap-usb2.c +0 -0
index ebceb1520ce8..2102b7f73ffa 100644

drivers/phy/ti/phy-omap-usb2.c static inline void omap_usb_writel(void __iomem *addr, unsigned int offset, · line 92

Quoted 7 lines
drivers/phy/ti/phy-omap-usb2.c +1 -3
@@ -89,9 +89,9 @@ static inline void omap_usb_writel(void __iomem *addr, unsigned int offset,
 }
 
 /**
- * omap_usb2_set_comparator - links the comparator present in the system with
- *	this phy
- * @comparator - the companion phy(comparator) for this phy
+ * omap_usb2_set_comparator - links the comparator present in the system with this phy

I missed it before but as Bjorn pointed out in this thread, it appears the function name should end with parentheses.

Cheers,
Liam

Quoted 13 lines
drivers/phy/ti/phy-omap-usb2.c +2 -0
+ *
+ * @comparator:  the companion phy(comparator) for this phy
  *
  * The phy companion driver should call this API passing the phy_companion
  * filled with set_vbus and start_srp to be used by usb phy.
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
author maintainer
#12 lore raw

PATCH 6/6 phy: ti: tusb1210: Fix the kernel-doc warn

In reply to Vinod Koul

The comment is not kernel-doc one and starts with /**, so fix that.

drivers/phy/ti/phy-tusb1210.c:16: warning: expecting prototype for tusb1210.c(). Prototype was for TUSB1210_VENDOR_SPECIFIC2() instead

---
 drivers/phy/ti/phy-tusb1210.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/phy/ti/phy-tusb1210.c +1 -1
index a63213f5972a..15c1c79e5c29 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * tusb1210.c - TUSB1210 USB ULPI PHY driver
  *
  * Copyright (C) 2015 Intel Corporation
Signature · 7 lines
2.31.1


-- 
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy
Reviewed-by on v1 6/6
#13 lore raw

Re: [PATCH 6/6] phy: ti: tusb1210: Fix the kernel-doc warn

Quoted 5 lines · Vinod Koul

The comment is not kernel-doc one and starts with /**, so fix that.

drivers/phy/ti/phy-tusb1210.c:16: warning: expecting prototype for tusb1210.c(). Prototype was for TUSB1210_VENDOR_SPECIFIC2() instead

Quoted 18 lines
---
 drivers/phy/ti/phy-tusb1210.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/phy/ti/phy-tusb1210.c +1 -1
index a63213f5972a..15c1c79e5c29 100644
@@ -1,5 +1,5 @@
 // SPDX-License-Identifier: GPL-2.0-only
-/**
+/*
  * tusb1210.c - TUSB1210 USB ULPI PHY driver
  *
  * Copyright (C) 2015 Intel Corporation
Signature · 1 line
2.31.1
Signature · 3 lines
linux-phy mailing list
[email protected]
https://lists.infradead.org/mailman/listinfo/linux-phy