Skip to content

Commit a8605ea

Browse files
ausyskingregkh
authored andcommitted
mei: fix KDoc documentation formatting
Fix Kdoc documentation formatting warnings genertaed by ./scripts/kernel-doc 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 764c065 commit a8605ea

15 files changed

Lines changed: 243 additions & 225 deletions

File tree

‎drivers/misc/mei/amthif.c‎

Lines changed: 13 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ int mei_amthif_host_init(struct mei_device *dev)
122122
* @dev: the device structure
123123
* @file: pointer to file object
124124
*
125-
* returns returned a list entry on success, NULL on failure.
125+
* Return: returned a list entry on success, NULL on failure.
126126
*/
127127
struct mei_cl_cb *mei_amthif_find_read_list_entry(struct mei_device *dev,
128128
struct file *file)
@@ -140,15 +140,14 @@ struct mei_cl_cb *mei_amthif_find_read_list_entry(struct mei_device *dev,
140140
* mei_amthif_read - read data from AMTHIF client
141141
*
142142
* @dev: the device structure
143-
* @if_num: minor number
144143
* @file: pointer to file object
145-
* @*ubuf: pointer to user data in user space
144+
* @ubuf: pointer to user data in user space
146145
* @length: data length to read
147146
* @offset: data read offset
148147
*
149148
* Locking: called under "dev->device_lock" lock
150149
*
151-
* returns
150+
* Return:
152151
* returned data length on success,
153152
* zero if no data to read,
154153
* negative on failure.
@@ -256,7 +255,7 @@ int mei_amthif_read(struct mei_device *dev, struct file *file,
256255
* @dev: the device structure
257256
* @cb: mei call back struct
258257
*
259-
* returns 0 on success, <0 on failure.
258+
* Return: 0 on success, <0 on failure.
260259
*
261260
*/
262261
static int mei_amthif_send_cmd(struct mei_device *dev, struct mei_cl_cb *cb)
@@ -326,7 +325,7 @@ static int mei_amthif_send_cmd(struct mei_device *dev, struct mei_cl_cb *cb)
326325
* @dev: the device structure
327326
* @cb: mei call back struct
328327
*
329-
* returns 0 on success, <0 on failure.
328+
* Return: 0 on success, <0 on failure.
330329
*
331330
*/
332331
int mei_amthif_write(struct mei_device *dev, struct mei_cl_cb *cb)
@@ -356,8 +355,6 @@ int mei_amthif_write(struct mei_device *dev, struct mei_cl_cb *cb)
356355
* mei_amthif_run_next_cmd
357356
*
358357
* @dev: the device structure
359-
*
360-
* returns 0 on success, <0 on failure.
361358
*/
362359
void mei_amthif_run_next_cmd(struct mei_device *dev)
363360
{
@@ -420,12 +417,11 @@ unsigned int mei_amthif_poll(struct mei_device *dev,
420417
/**
421418
* mei_amthif_irq_write - write iamthif command in irq thread context.
422419
*
423-
* @dev: the device structure.
424-
* @cb_pos: callback block.
425420
* @cl: private data of the file object.
421+
* @cb: callback block.
426422
* @cmpl_list: complete list.
427423
*
428-
* returns 0, OK; otherwise, error.
424+
* Return: 0, OK; otherwise, error.
429425
*/
430426
int mei_amthif_irq_write(struct mei_cl *cl, struct mei_cl_cb *cb,
431427
struct mei_cl_cb *cmpl_list)
@@ -507,7 +503,7 @@ int mei_amthif_irq_write(struct mei_cl *cl, struct mei_cl_cb *cb,
507503
* @mei_hdr: header of amthif message
508504
* @complete_list: An instance of our list structure
509505
*
510-
* returns 0 on success, <0 on failure.
506+
* Return: 0 on success, <0 on failure.
511507
*/
512508
int mei_amthif_irq_read_msg(struct mei_device *dev,
513509
struct mei_msg_hdr *mei_hdr,
@@ -560,7 +556,7 @@ int mei_amthif_irq_read_msg(struct mei_device *dev,
560556
* @dev: the device structure.
561557
* @slots: free slots.
562558
*
563-
* returns 0, OK; otherwise, error.
559+
* Return: 0, OK; otherwise, error.
564560
*/
565561
int mei_amthif_irq_read(struct mei_device *dev, s32 *slots)
566562
{
@@ -590,7 +586,7 @@ int mei_amthif_irq_read(struct mei_device *dev, s32 *slots)
590586
* mei_amthif_complete - complete amthif callback.
591587
*
592588
* @dev: the device structure.
593-
* @cb_pos: callback block.
589+
* @cb: callback block.
594590
*/
595591
void mei_amthif_complete(struct mei_device *dev, struct mei_cl_cb *cb)
596592
{
@@ -624,7 +620,7 @@ void mei_amthif_complete(struct mei_device *dev, struct mei_cl_cb *cb)
624620
* mei_clear_list is called to clear resources associated with file
625621
* when application calls close function or Ctrl-C was pressed
626622
*
627-
* returns true if callback removed from the list, false otherwise
623+
* Return: true if callback removed from the list, false otherwise
628624
*/
629625
static bool mei_clear_list(struct mei_device *dev,
630626
const struct file *file, struct list_head *mei_cb_list)
@@ -664,7 +660,7 @@ static bool mei_clear_list(struct mei_device *dev,
664660
* mei_clear_lists is called to clear resources associated with file
665661
* when application calls close function or Ctrl-C was pressed
666662
*
667-
* returns true if callback removed from the list, false otherwise
663+
* Return: true if callback removed from the list, false otherwise
668664
*/
669665
static bool mei_clear_lists(struct mei_device *dev, struct file *file)
670666
{
@@ -705,7 +701,7 @@ static bool mei_clear_lists(struct mei_device *dev, struct file *file)
705701
* @dev: device structure
706702
* @file: pointer to file structure
707703
*
708-
* returns 0 on success, <0 on error
704+
* Return: 0 on success, <0 on error
709705
*/
710706
int mei_amthif_release(struct mei_device *dev, struct file *file)
711707
{

‎drivers/misc/mei/client.c‎

Lines changed: 41 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -27,13 +27,14 @@
2727
#include "client.h"
2828

2929
/**
30-
* mei_me_cl_by_uuid - locate index of me client
30+
* mei_me_cl_by_uuid - locate me client by uuid
3131
*
3232
* @dev: mei device
33+
* @uuid: me client uuid
3334
*
3435
* Locking: called under "dev->device_lock" lock
3536
*
36-
* returns me client or NULL if not found
37+
* Return: me client or NULL if not found
3738
*/
3839
struct mei_me_client *mei_me_cl_by_uuid(const struct mei_device *dev,
3940
const uuid_le *uuid)
@@ -48,16 +49,15 @@ struct mei_me_client *mei_me_cl_by_uuid(const struct mei_device *dev,
4849
}
4950

5051
/**
51-
* mei_me_cl_by_id return index to me_clients for client_id
52+
* mei_me_cl_by_id - locate me client by client id
5253
*
5354
* @dev: the device structure
5455
* @client_id: me client id
5556
*
5657
* Locking: called under "dev->device_lock" lock
5758
*
58-
* returns me client or NULL if not found
59+
* Return: me client or NULL if not found
5960
*/
60-
6161
struct mei_me_client *mei_me_cl_by_id(struct mei_device *dev, u8 client_id)
6262
{
6363

@@ -69,6 +69,17 @@ struct mei_me_client *mei_me_cl_by_id(struct mei_device *dev, u8 client_id)
6969
return NULL;
7070
}
7171

72+
/**
73+
* mei_me_cl_by_uuid_id - locate me client by client id and uuid
74+
*
75+
* @dev: the device structure
76+
* @uuid: me client uuid
77+
* @client_id: me client id
78+
*
79+
* Locking: called under "dev->device_lock" lock
80+
*
81+
* Return: me client or NULL if not found
82+
*/
7283
struct mei_me_client *mei_me_cl_by_uuid_id(struct mei_device *dev,
7384
const uuid_le *uuid, u8 client_id)
7485
{
@@ -109,7 +120,7 @@ void mei_me_cl_remove(struct mei_device *dev, const uuid_le *uuid, u8 client_id)
109120
* @cl1: host client 1
110121
* @cl2: host client 2
111122
*
112-
* returns true - if the clients has same host and me ids
123+
* Return: true - if the clients has same host and me ids
113124
* false - otherwise
114125
*/
115126
static inline bool mei_cl_cmp_id(const struct mei_cl *cl1,
@@ -184,10 +195,10 @@ void mei_io_cb_free(struct mei_cl_cb *cb)
184195
/**
185196
* mei_io_cb_init - allocate and initialize io callback
186197
*
187-
* @cl - mei client
198+
* @cl: mei client
188199
* @fp: pointer to file structure
189200
*
190-
* returns mei_cl_cb pointer or NULL;
201+
* Return: mei_cl_cb pointer or NULL;
191202
*/
192203
struct mei_cl_cb *mei_io_cb_init(struct mei_cl *cl, struct file *fp)
193204
{
@@ -211,7 +222,7 @@ struct mei_cl_cb *mei_io_cb_init(struct mei_cl *cl, struct file *fp)
211222
* @cb: io callback structure
212223
* @length: size of the buffer
213224
*
214-
* returns 0 on success
225+
* Return: 0 on success
215226
* -EINVAL if cb is NULL
216227
* -ENOMEM if allocation failed
217228
*/
@@ -235,7 +246,7 @@ int mei_io_cb_alloc_req_buf(struct mei_cl_cb *cb, size_t length)
235246
* @cb: io callback structure
236247
* @length: size of the buffer
237248
*
238-
* returns 0 on success
249+
* Return: 0 on success
239250
* -EINVAL if cb is NULL
240251
* -ENOMEM if allocation failed
241252
*/
@@ -305,7 +316,7 @@ void mei_cl_init(struct mei_cl *cl, struct mei_device *dev)
305316
* mei_cl_allocate - allocates cl structure and sets it up.
306317
*
307318
* @dev: mei device
308-
* returns The allocated file or NULL on failure
319+
* Return: The allocated file or NULL on failure
309320
*/
310321
struct mei_cl *mei_cl_allocate(struct mei_device *dev)
311322
{
@@ -325,7 +336,7 @@ struct mei_cl *mei_cl_allocate(struct mei_device *dev)
325336
*
326337
* @cl: host client
327338
*
328-
* returns cb on success, NULL on error
339+
* Return: cb on success, NULL on error
329340
*/
330341
struct mei_cl_cb *mei_cl_find_read_cb(struct mei_cl *cl)
331342
{
@@ -343,7 +354,7 @@ struct mei_cl_cb *mei_cl_find_read_cb(struct mei_cl *cl)
343354
* @cl - host client
344355
* @id - fixed host id or -1 for generic one
345356
*
346-
* returns 0 on success
357+
* Return: 0 on success
347358
* -EINVAL on incorrect values
348359
* -ENONET if client not found
349360
*/
@@ -455,10 +466,10 @@ void mei_host_client_init(struct work_struct *work)
455466
}
456467

457468
/**
458-
* mei_hbuf_acquire: try to acquire host buffer
469+
* mei_hbuf_acquire - try to acquire host buffer
459470
*
460471
* @dev: the device structure
461-
* returns true if host buffer was acquired
472+
* Return: true if host buffer was acquired
462473
*/
463474
bool mei_hbuf_acquire(struct mei_device *dev)
464475
{
@@ -485,7 +496,7 @@ bool mei_hbuf_acquire(struct mei_device *dev)
485496
*
486497
* Locking: called under "dev->device_lock" lock
487498
*
488-
* returns 0 on success, <0 on failure.
499+
* Return: 0 on success, <0 on failure.
489500
*/
490501
int mei_cl_disconnect(struct mei_cl *cl)
491502
{
@@ -566,7 +577,7 @@ int mei_cl_disconnect(struct mei_cl *cl)
566577
*
567578
* @cl: private data of the file object
568579
*
569-
* returns true if other client is connected, false - otherwise.
580+
* Return: true if other client is connected, false - otherwise.
570581
*/
571582
bool mei_cl_is_other_connecting(struct mei_cl *cl)
572583
{
@@ -593,10 +604,11 @@ bool mei_cl_is_other_connecting(struct mei_cl *cl)
593604
* mei_cl_connect - connect host client to the me one
594605
*
595606
* @cl: host client
607+
* @file: pointer to file structure
596608
*
597609
* Locking: called under "dev->device_lock" lock
598610
*
599-
* returns 0 on success, <0 on failure.
611+
* Return: 0 on success, <0 on failure.
600612
*/
601613
int mei_cl_connect(struct mei_cl *cl, struct file *file)
602614
{
@@ -671,7 +683,7 @@ int mei_cl_connect(struct mei_cl *cl, struct file *file)
671683
*
672684
* @cl: private data of the file object
673685
*
674-
* returns 1 if mei_flow_ctrl_creds >0, 0 - otherwise.
686+
* Return: 1 if mei_flow_ctrl_creds >0, 0 - otherwise.
675687
* -ENOENT if mei_cl is not present
676688
* -EINVAL if single_recv_buf == 0
677689
*/
@@ -707,7 +719,7 @@ int mei_cl_flow_ctrl_creds(struct mei_cl *cl)
707719
*
708720
* @cl: private data of the file object
709721
*
710-
* @returns
722+
* Return:
711723
* 0 on success
712724
* -ENOENT when me client is not found
713725
* -EINVAL when ctrl credits are <= 0
@@ -745,7 +757,7 @@ int mei_cl_flow_ctrl_reduce(struct mei_cl *cl)
745757
*
746758
* @cl: host client
747759
*
748-
* returns 0 on success, <0 on failure.
760+
* Return: 0 on success, <0 on failure.
749761
*/
750762
int mei_cl_read_start(struct mei_cl *cl, size_t length)
751763
{
@@ -823,7 +835,7 @@ int mei_cl_read_start(struct mei_cl *cl, size_t length)
823835
* @cb: callback block.
824836
* @cmpl_list: complete list.
825837
*
826-
* returns 0, OK; otherwise error.
838+
* Return: 0, OK; otherwise error.
827839
*/
828840
int mei_cl_irq_write(struct mei_cl *cl, struct mei_cl_cb *cb,
829841
struct mei_cl_cb *cmpl_list)
@@ -900,12 +912,12 @@ int mei_cl_irq_write(struct mei_cl *cl, struct mei_cl_cb *cb,
900912

901913
/**
902914
* mei_cl_write - submit a write cb to mei device
903-
assumes device_lock is locked
915+
* assumes device_lock is locked
904916
*
905917
* @cl: host client
906-
* @cl: write callback with filled data
918+
* @cb: write callback with filled data
907919
*
908-
* returns number of bytes sent on success, <0 on failure.
920+
* Return: number of bytes sent on success, <0 on failure.
909921
*/
910922
int mei_cl_write(struct mei_cl *cl, struct mei_cl_cb *cb, bool blocking)
911923
{
@@ -1042,7 +1054,7 @@ void mei_cl_complete(struct mei_cl *cl, struct mei_cl_cb *cb)
10421054
/**
10431055
* mei_cl_all_disconnect - disconnect forcefully all connected clients
10441056
*
1045-
* @dev - mei device
1057+
* @dev: mei device
10461058
*/
10471059

10481060
void mei_cl_all_disconnect(struct mei_device *dev)
@@ -1060,7 +1072,7 @@ void mei_cl_all_disconnect(struct mei_device *dev)
10601072
/**
10611073
* mei_cl_all_wakeup - wake up all readers and writers they can be interrupted
10621074
*
1063-
* @dev - mei device
1075+
* @dev: mei device
10641076
*/
10651077
void mei_cl_all_wakeup(struct mei_device *dev)
10661078
{
@@ -1080,8 +1092,8 @@ void mei_cl_all_wakeup(struct mei_device *dev)
10801092

10811093
/**
10821094
* mei_cl_all_write_clear - clear all pending writes
1083-
1084-
* @dev - mei device
1095+
*
1096+
* @dev: mei device
10851097
*/
10861098
void mei_cl_all_write_clear(struct mei_device *dev)
10871099
{

‎drivers/misc/mei/debugfs.c‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,8 @@ static const struct file_operations mei_dbgfs_fops_devstate = {
161161

162162
/**
163163
* mei_dbgfs_deregister - Remove the debugfs files and directories
164-
* @mei - pointer to mei device private data
164+
*
165+
* @dev: the mei device structure
165166
*/
166167
void mei_dbgfs_deregister(struct mei_device *dev)
167168
{
@@ -172,8 +173,10 @@ void mei_dbgfs_deregister(struct mei_device *dev)
172173
}
173174

174175
/**
175-
* Add the debugfs files
176+
* mei_dbgfs_register - Add the debugfs files
176177
*
178+
* @dev: the mei device structure
179+
* @name: the mei device name
177180
*/
178181
int mei_dbgfs_register(struct mei_device *dev, const char *name)
179182
{

0 commit comments

Comments
 (0)