Skip to content

Commit 06c2a5c

Browse files
Suraj Guptakuba-moo
authored andcommitted
net: axienet: Fix kernel doc warnings
Add description of mdio enable, mdio disable and mdio wait functions. Add description of skb pointer in axidma_bd data structure. Remove 'phy_node' description in axienet local data structure since it is not a valid struct member. Correct description of struct axienet_option. Fix below kernel-doc warnings in drivers/net/ethernet/xilinx/: 1) xilinx_axienet_mdio.c:1: warning: no structured comments found 2) xilinx_axienet.h:379: warning: Function parameter or struct member 'skb' not described in 'axidma_bd' 3) xilinx_axienet.h:538: warning: Excess struct member 'phy_node' description in 'axienet_local' 4) xilinx_axienet.h:1002: warning: expecting prototype for struct axiethernet_option. Prototype was for struct axienet_option instead Signed-off-by: Suraj Gupta <[email protected]> Reviewed-by: Radhey Shyam Pandey <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Jakub Kicinski <[email protected]>
1 parent 1ab6fe6 commit 06c2a5c

File tree

2 files changed

+22
-5
lines changed

2 files changed

+22
-5
lines changed

drivers/net/ethernet/xilinx/xilinx_axienet.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -359,6 +359,7 @@
359359
* @app2: MM2S/S2MM User Application Field 2.
360360
* @app3: MM2S/S2MM User Application Field 3.
361361
* @app4: MM2S/S2MM User Application Field 4.
362+
* @skb: Pointer to SKB transferred using DMA
362363
*/
363364
struct axidma_bd {
364365
u32 next; /* Physical address of next buffer descriptor */
@@ -399,7 +400,6 @@ struct skbuf_dma_descriptor {
399400
* struct axienet_local - axienet private per device data
400401
* @ndev: Pointer for net_device to which it will be attached.
401402
* @dev: Pointer to device structure
402-
* @phy_node: Pointer to device node structure
403403
* @phylink: Pointer to phylink instance
404404
* @phylink_config: phylink configuration settings
405405
* @pcs_phy: Reference to PCS/PMA PHY if used
@@ -537,7 +537,7 @@ struct axienet_local {
537537
};
538538

539539
/**
540-
* struct axiethernet_option - Used to set axi ethernet hardware options
540+
* struct axienet_option - Used to set axi ethernet hardware options
541541
* @opt: Option to be set.
542542
* @reg: Register offset to be written for setting the option
543543
* @m_or: Mask to be ORed for setting the option in the register

drivers/net/ethernet/xilinx/xilinx_axienet_mdio.c

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,14 @@
2020
#define DEFAULT_MDIO_FREQ 2500000 /* 2.5 MHz */
2121
#define DEFAULT_HOST_CLOCK 150000000 /* 150 MHz */
2222

23-
/* Wait till MDIO interface is ready to accept a new transaction.*/
23+
/**
24+
* axienet_mdio_wait_until_ready - MDIO wait function
25+
* @lp: Pointer to axienet local data structure.
26+
*
27+
* Return : 0 on success, Negative value on errors
28+
*
29+
* Wait till MDIO interface is ready to accept a new transaction.
30+
*/
2431
static int axienet_mdio_wait_until_ready(struct axienet_local *lp)
2532
{
2633
u32 val;
@@ -30,14 +37,24 @@ static int axienet_mdio_wait_until_ready(struct axienet_local *lp)
3037
1, 20000);
3138
}
3239

33-
/* Enable the MDIO MDC. Called prior to a read/write operation */
40+
/**
41+
* axienet_mdio_mdc_enable - MDIO MDC enable function
42+
* @lp: Pointer to axienet local data structure.
43+
*
44+
* Enable the MDIO MDC. Called prior to a read/write operation
45+
*/
3446
static void axienet_mdio_mdc_enable(struct axienet_local *lp)
3547
{
3648
axienet_iow(lp, XAE_MDIO_MC_OFFSET,
3749
((u32)lp->mii_clk_div | XAE_MDIO_MC_MDIOEN_MASK));
3850
}
3951

40-
/* Disable the MDIO MDC. Called after a read/write operation*/
52+
/**
53+
* axienet_mdio_mdc_disable - MDIO MDC disable function
54+
* @lp: Pointer to axienet local data structure.
55+
*
56+
* Disable the MDIO MDC. Called after a read/write operation
57+
*/
4158
static void axienet_mdio_mdc_disable(struct axienet_local *lp)
4259
{
4360
u32 mc_reg;

0 commit comments

Comments
 (0)