Skip to content

Commit ce23139

Browse files
ausyskingregkh
authored andcommitted
mei: fix kernel-doc warnings
Add missed parameters descriptions and return values descriptions Signed-off-by: Alexander Usyskin <alexander.usyskin@intel.com> Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent a8605ea commit ce23139

14 files changed

Lines changed: 231 additions & 67 deletions

File tree

‎drivers/misc/mei/amthif.c‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ void mei_amthif_reset_params(struct mei_device *dev)
6464
*
6565
* @dev: the device structure
6666
*
67+
* Return: 0 on success, <0 on failure.
6768
*/
6869
int mei_amthif_host_init(struct mei_device *dev)
6970
{
@@ -352,7 +353,7 @@ int mei_amthif_write(struct mei_device *dev, struct mei_cl_cb *cb)
352353
return mei_amthif_send_cmd(dev, cb);
353354
}
354355
/**
355-
* mei_amthif_run_next_cmd
356+
* mei_amthif_run_next_cmd - send next amt command from queue
356357
*
357358
* @dev: the device structure
358359
*/
@@ -496,7 +497,7 @@ int mei_amthif_irq_write(struct mei_cl *cl, struct mei_cl_cb *cb,
496497
}
497498

498499
/**
499-
* mei_amthif_irq_read_message - read routine after ISR to
500+
* mei_amthif_irq_read_msg - read routine after ISR to
500501
* handle the read amthif message
501502
*
502503
* @dev: the device structure

‎drivers/misc/mei/client.c‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,6 +271,8 @@ int mei_io_cb_alloc_resp_buf(struct mei_cl_cb *cb, size_t length)
271271
* mei_cl_flush_queues - flushes queue lists belonging to cl.
272272
*
273273
* @cl: host client
274+
*
275+
* Return: 0 on success, -EINVAL if cl or cl->dev is NULL.
274276
*/
275277
int mei_cl_flush_queues(struct mei_cl *cl)
276278
{
@@ -402,6 +404,8 @@ int mei_cl_link(struct mei_cl *cl, int id)
402404
* mei_cl_unlink - remove me_cl from the list
403405
*
404406
* @cl: host client
407+
*
408+
* Return: always 0
405409
*/
406410
int mei_cl_unlink(struct mei_cl *cl)
407411
{
@@ -756,6 +760,7 @@ int mei_cl_flow_ctrl_reduce(struct mei_cl *cl)
756760
* mei_cl_read_start - the start read client message function.
757761
*
758762
* @cl: host client
763+
* @length: number of bytes to read
759764
*
760765
* Return: 0 on success, <0 on failure.
761766
*/
@@ -916,6 +921,7 @@ int mei_cl_irq_write(struct mei_cl *cl, struct mei_cl_cb *cb,
916921
*
917922
* @cl: host client
918923
* @cb: write callback with filled data
924+
* @blocking: block until completed
919925
*
920926
* Return: number of bytes sent on success, <0 on failure.
921927
*/

‎drivers/misc/mei/debugfs.c‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -177,6 +177,8 @@ void mei_dbgfs_deregister(struct mei_device *dev)
177177
*
178178
* @dev: the mei device structure
179179
* @name: the mei device name
180+
*
181+
* Return: 0 on success, <0 on failure.
180182
*/
181183
int mei_dbgfs_register(struct mei_device *dev, const char *name)
182184
{

‎drivers/misc/mei/hbm.c‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,8 @@ void mei_hbm_cl_hdr(struct mei_cl *cl, u8 hbm_cmd, void *buf, size_t len)
176176
* @cl: client
177177
* @hbm_cmd: host bus message command
178178
* @len: buffer length
179+
*
180+
* Return: 0 on success, <0 on failure.
179181
*/
180182
static inline
181183
int mei_hbm_cl_write(struct mei_device *dev,

‎drivers/misc/mei/hw-me.c‎

Lines changed: 34 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,7 @@ static inline u32 mei_hcsr_read(const struct mei_me_hw *hw)
9494
* and ignores the H_IS bit for it is write-one-to-zero.
9595
*
9696
* @hw: the me hardware structure
97+
* @hcsr: new register value
9798
*/
9899
static inline void mei_hcsr_set(struct mei_me_hw *hw, u32 hcsr)
99100
{
@@ -106,6 +107,8 @@ static inline void mei_hcsr_set(struct mei_me_hw *hw, u32 hcsr)
106107
*
107108
* @dev: mei device
108109
* @fw_status: fw status register values
110+
*
111+
* Return: 0 on success, error otherwise
109112
*/
110113
static int mei_me_fw_status(struct mei_device *dev,
111114
struct mei_fw_status *fw_status)
@@ -149,8 +152,9 @@ static void mei_me_hw_config(struct mei_device *dev)
149152
* mei_me_pg_state - translate internal pg state
150153
* to the mei power gating state
151154
*
152-
* @hw - me hardware
153-
* returns: MEI_PG_OFF if aliveness is on and MEI_PG_ON otherwise
155+
* @dev: mei device
156+
*
157+
* Return: MEI_PG_OFF if aliveness is on and MEI_PG_ON otherwise
154158
*/
155159
static inline enum mei_pg_state mei_me_pg_state(struct mei_device *dev)
156160
{
@@ -160,7 +164,7 @@ static inline enum mei_pg_state mei_me_pg_state(struct mei_device *dev)
160164
}
161165

162166
/**
163-
* mei_clear_interrupts - clear and stop interrupts
167+
* mei_me_intr_clear - clear and stop interrupts
164168
*
165169
* @dev: the device structure
166170
*/
@@ -187,7 +191,7 @@ static void mei_me_intr_enable(struct mei_device *dev)
187191
}
188192

189193
/**
190-
* mei_disable_interrupts - disables mei device interrupts
194+
* mei_me_intr_disable - disables mei device interrupts
191195
*
192196
* @dev: the device structure
193197
*/
@@ -222,6 +226,8 @@ static void mei_me_hw_reset_release(struct mei_device *dev)
222226
*
223227
* @dev: the device structure
224228
* @intr_enable: if interrupt should be enabled after reset.
229+
*
230+
* Return: always 0
225231
*/
226232
static int mei_me_hw_reset(struct mei_device *dev, bool intr_enable)
227233
{
@@ -259,10 +265,8 @@ static int mei_me_hw_reset(struct mei_device *dev, bool intr_enable)
259265
/**
260266
* mei_me_host_set_ready - enable device
261267
*
262-
* @dev - mei device
263-
* returns bool
268+
* @dev: mei device
264269
*/
265-
266270
static void mei_me_host_set_ready(struct mei_device *dev)
267271
{
268272
struct mei_me_hw *hw = to_me_hw(dev);
@@ -271,6 +275,7 @@ static void mei_me_host_set_ready(struct mei_device *dev)
271275
hw->host_hw_state |= H_IE | H_IG | H_RDY;
272276
mei_hcsr_set(hw, hw->host_hw_state);
273277
}
278+
274279
/**
275280
* mei_me_host_is_ready - check whether the host has turned ready
276281
*
@@ -299,6 +304,13 @@ static bool mei_me_hw_is_ready(struct mei_device *dev)
299304
return (hw->me_hw_state & ME_RDY_HRA) == ME_RDY_HRA;
300305
}
301306

307+
/**
308+
* mei_me_hw_ready_wait - wait until the me(hw) has turned ready
309+
* or timeout is reached
310+
*
311+
* @dev: mei device
312+
* Return: 0 on success, error otherwise
313+
*/
302314
static int mei_me_hw_ready_wait(struct mei_device *dev)
303315
{
304316
mutex_unlock(&dev->device_lock);
@@ -315,6 +327,12 @@ static int mei_me_hw_ready_wait(struct mei_device *dev)
315327
return 0;
316328
}
317329

330+
/**
331+
* mei_me_hw_start - hw start routine
332+
*
333+
* @dev: mei device
334+
* Return: 0 on success, error otherwise
335+
*/
318336
static int mei_me_hw_start(struct mei_device *dev)
319337
{
320338
int ret = mei_me_hw_ready_wait(dev);
@@ -381,6 +399,13 @@ static int mei_me_hbuf_empty_slots(struct mei_device *dev)
381399
return empty_slots;
382400
}
383401

402+
/**
403+
* mei_me_hbuf_max_len - returns size of hw buffer.
404+
*
405+
* @dev: the device structure
406+
*
407+
* Return: size of hw buffer in bytes
408+
*/
384409
static size_t mei_me_hbuf_max_len(const struct mei_device *dev)
385410
{
386411
return dev->hbuf_depth * sizeof(u32) - sizeof(struct mei_msg_hdr);
@@ -472,6 +497,8 @@ static int mei_me_count_full_read_slots(struct mei_device *dev)
472497
* @dev: the device structure
473498
* @buffer: message buffer will be written
474499
* @buffer_length: message size will be read
500+
*
501+
* Return: always 0
475502
*/
476503
static int mei_me_read_slots(struct mei_device *dev, unsigned char *buffer,
477504
unsigned long buffer_length)

‎drivers/misc/mei/hw-me.h‎

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,13 @@ struct mei_cfg {
4747
#define MEI_ME_RPM_TIMEOUT 500 /* ms */
4848

4949
/**
50+
* struct mei_me_hw - me hw specific data
51+
*
5052
* @cfg: per device generation config and ops
53+
* @mem_addr: io memory address
54+
* @host_hw_state: cached host state
55+
* @me_hw_state: cached me (fw) state
56+
* @pg_state: power gating state
5157
*/
5258
struct mei_me_hw {
5359
const struct mei_cfg *cfg;

0 commit comments

Comments
 (0)