Skip to content

Commit 17c2584

Browse files
Neelima PatelBhawana Sahu
authored andcommitted
sysmonpsv: Add doxygen and editorial fixes
Doxygen warnings and code documentation fixes for SYSMONPSV driver. Signed-off-by: Neelima Patel <Neelima.Patel@amd.com> Acked-by: Erim, Salih <Salih.Erim@amd.com>
1 parent 5594558 commit 17c2584

14 files changed

Lines changed: 486 additions & 603 deletions

XilinxProcessorIPLib/drivers/sysmonpsv/src/common/xsysmonpsv_common.c

Lines changed: 70 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,11 @@
88
/**
99
*
1010
* @file xsysmonpsv_common.c
11-
* @addtogroup Overview
11+
* @addtogroup sysmonpsv_api SYSMONPSV APIs
1212
*
13-
* Functions in this file are basic driver functions which will be used in the
13+
* Functions in the xsysmonpsv_common.c file are basic driver functions which will be used in the
1414
* in servies or directly by the user.
1515
*
16-
* @note None.
1716
*
1817
* <pre>
1918
*
@@ -37,12 +36,12 @@
3736
/****************************************************************************/
3837
/**
3938
*
40-
* This function gives the register offset for the different type.
39+
* Provides the register offset for the different type.
4140
*
42-
* @param Type is Max or Min Temperature Type
41+
* @param Type Max or Min Temperature Type
4342
*
4443
* @return -XST_FAILURE when fails
45-
* Register offset
44+
* -Register offset
4645
*
4746
***************************************************************************/
4847
int XSysMonPsv_TempOffset(XSysMonPsv_TempType Type)
@@ -68,14 +67,14 @@ int XSysMonPsv_TempOffset(XSysMonPsv_TempType Type)
6867
/****************************************************************************/
6968
/**
7069
*
71-
* This function gives the temperature threshold (upper or lower) offset.
70+
* Provides the temperature threshold (upper or lower) offset.
7271
*
73-
* @param Event is Temp or OT event type.
74-
* @param Dir is falling or rising direction
75-
* @param Offset is the upper or lower threshold offset.
72+
* @param Event Temp or OT event type.
73+
* @param Dir Falling or rising direction
74+
* @param Offset Upper or lower threshold offset.
7675
*
77-
* @return -XST_FAILURE when fails
78-
* XST_SUCCESS when correct params are used.
76+
* @return - -XST_FAILURE when fails
77+
* - XST_SUCCESS when correct params are used.
7978
*
8079
***************************************************************************/
8180
int XSysMonPsv_TempThreshOffset(XSysMonPsv_TempEvt Event,
@@ -103,10 +102,10 @@ int XSysMonPsv_TempThreshOffset(XSysMonPsv_TempEvt Event,
103102
/****************************************************************************/
104103
/**
105104
*
106-
* This function gives the supply offset.
105+
* Provides the supply offset.
107106
*
108-
* @param InstancePtr is a pointer to the XSysMonPsv instance.
109-
* @param Supply is an enum which indicates the desired supply.
107+
* @param InstancePtr Pointer to the XSysMonPsv instance.
108+
* @param Supply Enum which indicates the desired supply.
110109
*
111110
* @return Offset supply.
112111
*
@@ -129,11 +128,11 @@ u32 XSysMonPsv_SupplyOffset(XSysMonPsv *InstancePtr, int Supply)
129128
/****************************************************************************/
130129
/**
131130
*
132-
* This function gives the supply threshold (upper or lower) offset.
131+
* Provides the supply threshold (upper or lower) offset.
133132
*
134-
* @param InstancePtr is a pointer to the XSysMonPsv instance.
135-
* @param Supply is an enum which indicates the desired supply.
136-
* @param Dir is Falling or rising direction.
133+
* @param InstancePtr Pointer to the XSysMonPsv instance.
134+
* @param Supply Enum which indicates the desired supply.
135+
* @param Dir Type of the direction - falling or rising.
137136
*
138137
* @return Upper or lower threshold offset.
139138
*
@@ -161,11 +160,11 @@ u32 XSysMonPsv_SupplyThreshOffset(XSysMonPsv *InstancePtr, int Supply,
161160
/****************************************************************************/
162161
/**
163162
*
164-
* This function converts Q8P7 To Celsius.
163+
* Converts Q8P7 To Celsius.
165164
*
166-
* @param RawData is Raw temperature Data.
167-
* @param Val is value in Q8P7 format.
168-
* @param Val2 is constant 128.
165+
* @param RawData Raw temperature Data.
166+
* @param Val Value in Q8P7 format.
167+
* @param Val2 Constant 128.
169168
*
170169
* @return None.
171170
*
@@ -179,11 +178,11 @@ void XSysMonPsv_Q8P7ToCelsius(u32 RawData, int *Val, int *Val2)
179178
/****************************************************************************/
180179
/**
181180
*
182-
* This function converts Celsius To Q8P7.
181+
* Converts Celsius To Q8P7.
183182
*
184-
* @param RawData is Raw Temperature Data.
185-
* @param Val is the numerator for covnersion to deg C.
186-
* @param Val2 is the denominator for conversion to deg C in Q8.7 format.
183+
* @param RawData Raw Temperature Data.
184+
* @param Val Numerator for covnersion to deg C.
185+
* @param Val2 Denominator for conversion to deg C in Q8.7 format.
187186
*
188187
* @return None.
189188
*
@@ -199,11 +198,11 @@ void XSysMonPsv_CelsiusToQ8P7(u32 *RawData, int Val, int Val2)
199198
/****************************************************************************/
200199
/**
201200
*
202-
* This function converts raw data to processed.
201+
* Converts raw data to processed.
203202
*
204-
* @param RawData is raw voltage data.
205-
* @param Val is numerator for conversion to volts.
206-
* @param Val2 is denominator for conversion to volts.
203+
* @param RawData Raw voltage data.
204+
* @param Val Numerator for conversion to volts.
205+
* @param Val2 Denominator for conversion to volts.
207206
*
208207
* @return None.
209208
*
@@ -228,12 +227,12 @@ void XSysMonPsv_SupplyRawToProcessed(int RawData, int *Val, int *Val2)
228227
/****************************************************************************/
229228
/**
230229
*
231-
* This function converts processed data to raw.
230+
* Converts processed data to raw.
232231
*
233-
* @param Val is numerator for conversion to volts.
234-
* @param Val2 is denominator for conversion to volts.
235-
* @param RegVal is Register Value.
236-
* @param RawData is converted Raw data.
232+
* @param Val Numerator for conversion to volts.
233+
* @param Val2 Denominator for conversion to volts.
234+
* @param RegVal Register Value.
235+
* @param RawData Converted Raw data.
237236
*
238237
* @return None.
239238
*
@@ -272,15 +271,15 @@ void XSysMonPsv_SupplyProcessedToRaw(int Val, int Val2, u32 RegVal,
272271
/*****************************************************************************/
273272
/**
274273
*
275-
* This function is to be used to check if the supply value has exceeded the set
274+
* Checks if the supply value has exceeded the set
276275
* threshold values.
277276
*
278-
* @param InstancePtr is a pointer to the driver instance.
279-
* @param Supply is an enum which indicates the desired supply.
277+
* @param InstancePtr Pointer to the driver instance.
278+
* @param Supply Enum which indicates the desired supply.
280279
*
281-
* @return True if new data available
282-
* False if new data isn't available
283-
* Invalid if the Supply hasn't been configured
280+
* @return True if new data available.
281+
* False if new data is not available.
282+
* Invalid if the Supply has not been configured.
284283
*
285284
******************************************************************************/
286285
u32 XSysMonPsv_IsAlarmPresent(XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
@@ -314,14 +313,14 @@ u32 XSysMonPsv_IsAlarmPresent(XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
314313
/*****************************************************************************/
315314
/**
316315
*
317-
* This function is to be used to clear alarm status.
316+
* Clears alarm status.
318317
*
319-
* @param InstancePtr is a pointer to the driver instance.
320-
* @param Supply is an enum which indicates the desired supply.
318+
* @param InstancePtr Pointer to the driver instance.
319+
* @param Supply Enum which indicates the desired supply.
321320
*
322-
* @return True if new data available
323-
* False if new data isn't available
324-
* Invalid if the Supply hasn't been configured
321+
* @return True if new data available.
322+
* False if new data isn't available.
323+
* Invalid if the Supply hasn't been configured.
325324
*
326325
******************************************************************************/
327326
u32 XSysMonPsv_ClearAlarm(XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
@@ -359,17 +358,17 @@ u32 XSysMonPsv_ClearAlarm(XSysMonPsv *InstancePtr, XSysMonPsv_Supply Supply)
359358
/****************************************************************************/
360359
/**
361360
*
362-
* This function enables the specified interrupts in the device.
361+
* Enables the specified interrupts in the device.
363362
*
364-
* @param InstancePtr is a pointer to the driver instance.
365-
* @param Mask is the 32 bit-mask of the interrupts to be enabled.
363+
* @param InstancePtr Pointer to the driver instance.
364+
* @param Mask 32 bit-mask of the interrupts to be enabled.
366365
* Bit positions of 1 will be enabled. Bit positions of 0 will
367366
* keep the previous setting. This mask is formed by OR'ing
368367
* XSYSMON_IER_* bits defined in InstancePtr.h.
369-
* @param IntrNum is the interrupt enable register to be used
368+
* @param IntrNum Interrupt enable register to be used
370369
*
371-
* @return - -XST_FAILURE if error
372-
* - XST_SUCCESS if successful
370+
* @return - XST_FAILURE if error
371+
* - XST_SUCCESS if successful
373372
*
374373
*****************************************************************************/
375374
int XSysMonPsv_InterruptEnable(XSysMonPsv *InstancePtr, u32 Mask, u8 IntrNum)
@@ -393,17 +392,17 @@ int XSysMonPsv_InterruptEnable(XSysMonPsv *InstancePtr, u32 Mask, u8 IntrNum)
393392
/****************************************************************************/
394393
/**
395394
*
396-
* This function disables the specified interrupts in the device.
395+
* Disables the specified interrupts in the device.
397396
*
398-
* @param InstancePtr is a pointer to the driver instance.
399-
* @param Mask is the 32 bit-mask of the interrupts to be enabled.
397+
* @param InstancePtr Pointer to the driver instance.
398+
* @param Mask 32 bit-mask of the interrupts to be enabled.
400399
* Bit positions of 1 will be disabled. Bit positions of 0 will
401400
* keep the previous setting. This mask is formed by OR'ing
402401
* XSYSMONPSV_IDR_* bits defined in InstancePtr.h.
403-
* @param IntrNum is the interrupt disable register to be used
402+
* @param IntrNum Interrupt disable register to be used
404403
*
405-
* @return - -XST_FAILURE if error
406-
* - XST_SUCCESS if successful
404+
* @return - XST_FAILURE if error
405+
* - XST_SUCCESS if successful
407406
*
408407
*****************************************************************************/
409408
int XSysMonPsv_InterruptDisable(XSysMonPsv *InstancePtr, u32 Mask, u8 IntrNum)
@@ -427,16 +426,16 @@ int XSysMonPsv_InterruptDisable(XSysMonPsv *InstancePtr, u32 Mask, u8 IntrNum)
427426
/****************************************************************************/
428427
/**
429428
*
430-
* This function returns the interrupt status read from Interrupt Status
429+
* Returns the interrupt status read from Interrupt Status
431430
* Register(ISR). Use the XSYSMONPSV_ISR* constants defined in InstancePtr.h
432431
* to interpret the returned value.
433432
*
434-
* @param InstancePtr is a pointer to the driver instance.
435-
* @param A 32-bit value representing the contents of the Interrupt Status
433+
* @param InstancePtr Pointer to the driver instance.
434+
* @param IntrStatus 32-bit value representing the contents of the Interrupt Status
436435
* Register (ISR).
437436
*
438-
* @return -XST_FAILURE when NULL Instance is passed
439-
* XST_SUCCESS if succeeds
437+
* @return - -XST_FAILURE when NULL Instance is passed
438+
* - XST_SUCCESS if succeeds
440439
*
441440
*****************************************************************************/
442441
int XSysMonPsv_InterruptGetStatus(XSysMonPsv *InstancePtr, u32 *IntrStatus)
@@ -452,11 +451,11 @@ int XSysMonPsv_InterruptGetStatus(XSysMonPsv *InstancePtr, u32 *IntrStatus)
452451
/****************************************************************************/
453452
/**
454453
*
455-
* This function clears the specified interrupts in the Interrupt Status
456-
* Register (ISR).
454+
* Clears the specified interrupts in the Interrupt Status
455+
* Register(ISR).
457456
*
458-
* @param InstancePtr is a pointer to the struct InstancePtr.
459-
* @param Mask is the 32 bit-mask of the interrupts to be cleared.
457+
* @param InstancePtr Pointer to the struct InstancePtr.
458+
* @param Mask 32 bit-mask of the interrupts to be cleared.
460459
* Bit positions of 1 will be cleared. Bit positions of 0 will not
461460
* change the previous interrupt status.*
462461
* @return None.
@@ -473,9 +472,9 @@ void XSysMonPsv_InterruptClear(XSysMonPsv *InstancePtr, u32 Mask)
473472
/****************************************************************************/
474473
/**
475474
*
476-
* This function unlocks the register space of InstancePtr hardware.
475+
* Unlocks the register space of InstancePtr hardware.
477476
*
478-
* @param InstancePtr is a pointer to the driver instance.
477+
* @param InstancePtr Pointer to the driver instance.
479478
*
480479
* @return None.
481480
*

XilinxProcessorIPLib/drivers/sysmonpsv/src/common/xsysmonpsv_common.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
/*****************************************************************************/
88
/**
99
* @file xsysmonpsv_common.h
10-
* @addtogroup Overview
10+
* @addtogroup sysmonpsv_api SYSMONPSV APIs
1111
*
12-
* Functions in this file are basic driver functions which will be used in the
12+
* Functions in the xsysmonpsv_common.h file are basic driver functions which will be used in the
1313
* in servies or directly by the user.
1414
*
1515
* <pre>

XilinxProcessorIPLib/drivers/sysmonpsv/src/lowlevel/xsysmonpsv_direct.c

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,10 @@
88
/**
99
*
1010
* @file xsysmonpsv_direct.c
11-
* @addtogroup Overview
11+
* @addtogroup sysmonpsv_api SYSMONPSV APIs
1212
*
13-
* This file contains the function implementation for low level sysmon APIs.
13+
* The xsysmonpsv_direct.c file contains the function implementation for low level sysmon APIs.
1414
*
15-
* @note None.
1615
*
1716
* <pre>
1817
*
@@ -33,11 +32,11 @@
3332
#if !defined(XSYSMONPSV_SECURE_MODE)
3433
/******************************************************************************/
3534
/**
36-
* This function reads register value.
35+
* Reads the register value.
3736
*
38-
* @param InstancePtr is a pointer to the driver instance.
39-
* @param Offset is offset address for register.
40-
* @param Data is value to be read in.
37+
* @param InstancePtr Pointer to the driver instance.
38+
* @param Offset Offset address for the register.
39+
* @param Data Value to be read.
4140
*
4241
* @return None.
4342
*
@@ -49,11 +48,11 @@ void XSysMonPsv_ReadReg32(XSysMonPsv *InstancePtr, u32 Offset, u32 *Data)
4948

5049
/******************************************************************************/
5150
/**
52-
* This function writes register value.
51+
* Writes the register value.
5352
*
54-
* @param InstancePtr is a pointer to the driver instance.
55-
* @param Offset is offset address of the register.
56-
* @param Data is value to be written.
53+
* @param InstancePtr Pointer to the driver instance.
54+
* @param Offset Offset address of the register.
55+
* @param Data Value to be written.
5756
*
5857
* @return None.
5958
*
@@ -65,12 +64,12 @@ void XSysMonPsv_WriteReg32(XSysMonPsv *InstancePtr, u32 Offset, u32 Data)
6564

6665
/******************************************************************************/
6766
/**
68-
* This function updates register value.
67+
* Updates the register value.
6968
*
70-
* @param InstancePtr is a pointer to the driver instance.
71-
* @param Offset offset addtress of the register.
72-
* @param Mask is bits to be masked.
73-
* @param Data is value to be written.
69+
* @param InstancePtr Pointer to the driver instance.
70+
* @param Offset Offset addtress of the register.
71+
* @param Mask Bits to be masked.
72+
* @param Data Value to be written.
7473
*
7574
* @return None.
7675
*

XilinxProcessorIPLib/drivers/sysmonpsv/src/lowlevel/xsysmonpsv_driver.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@
77
/*****************************************************************************/
88
/**
99
* @file xsysmonpsv_driver.h
10-
* @addtogroup Overview
10+
* @addtogroup sysmonpsv_api SYSMONPSV APIs
1111
*
12-
* The SysMon driver supports the Xilinx System Monitor device on Versal
12+
* SysMon driver supports the AMD System Monitor device on Versal.
1313
*
1414
* The System Monitor device has the following features:
1515
* - Measure and monitor up to 160 voltages across the chip
@@ -59,7 +59,7 @@ extern "C" {
5959
* This data type defines a handler that an application defines to communicate
6060
* with interrupt system to retrieve state information about an application.
6161
*
62-
* @param CallbackRef is a callback reference passed in by the upper layer
62+
* @param CallbackRef Callback reference passed in by the upper layer
6363
* when setting the handler, and is passed back to the upper layer
6464
* when the handler is called. It is used to find the device driver
6565
* instance.
@@ -125,3 +125,4 @@ typedef struct {
125125
}
126126
#endif
127127
#endif /* _XSYSMONPSV_DRIVER_H_ */
128+
/** @} */

0 commit comments

Comments
 (0)