Skip to content

Commit e383ce0

Browse files
committed
[media] get rid of a number of problems at the cross references
As warned by linuxdoc[1] tool, using: $ for i in $(git grep kernel-doc Documentation/media/kapi/|cut -d: -f4); do kernel-lintdoc --sloppy $i; done include/media/v4l2-dev.h:118 :WARN: function name from comment differs: v4l2_prio_close <--> v4l2_prio_check include/media/v4l2-mc.h:56 [kernel-doc WARN] : enum name from comment differs: if_vid_dec_index <--> if_vid_dec_pad_index include/media/v4l2-mc.h:71 [kernel-doc WARN] : enum name from comment differs: if_aud_dec_index <--> if_aud_dec_pad_index include/media/v4l2-mem2mem.h:396 [kernel-doc WARN] : function name from comment differs: v4l2_m2m_num_src_bufs_ready <--> v4l2_m2m_num_dst_bufs_ready drivers/media/dvb-core/dvb_math.h:28 [kernel-doc WARN] : function name from comment differs: cintlog2 <--> intlog2 include/media/v4l2-subdev.h:215 [kernel-doc WARN] : struct name from comment differs: s_radio <--> v4l2_subdev_tuner_ops include/media/v4l2-subdev.h:890 [kernel-doc WARN] : function name from comment differs: v4l2_set_subdevdata <--> v4l2_set_subdev_hostdata include/media/v4l2-subdev.h:901 [kernel-doc WARN] : function name from comment differs: v4l2_get_subdevdata <--> v4l2_get_subdev_hostdata drivers/media/dvb-core/dvb_ringbuffer.h:196 [kernel-doc WARN] : function name from comment differs: dvb_ringbuffer_writeuser <--> dvb_ringbuffer_write_user include/media/videobuf2-core.h:399 [kernel-doc WARN] : struct name from comment differs: vb2_ops <--> vb2_buf_ops include/media/media-entity.h:132 [kernel-doc ERROR] : duplicate parameter definition 'source' include/media/media-entity.h:477 [kernel-doc WARN] : function name from comment differs: media_entity_enum_test <--> media_entity_enum_test_and_set include/media/media-entity.h:535 [kernel-doc WARN] : function name from comment differs: gobj_to_entity <--> gobj_to_pad include/media/media-entity.h:544 [kernel-doc WARN] : function name from comment differs: gobj_to_entity <--> gobj_to_link include/media/media-entity.h:553 [kernel-doc WARN] : function name from comment differs: gobj_to_entity <--> gobj_to_intf include/media/media-entity.h:562 [kernel-doc WARN] : function name from comment differs: gobj_to_entity <--> intf_to_devnode include/media/rc-core.h:234 [kernel-doc WARN] : function name from comment differs: rc_open <--> rc_close include/media/v4l2-ctrls.h:397 [kernel-doc WARN] : missing initial short description of 'v4l2_ctrl_handler_init' include/media/v4l2-dev.h:118 [kernel-doc WARN] : function name from comment differs: v4l2_prio_close <--> v4l2_prio_check include/media/v4l2-event.h:225 [kernel-doc WARN] : missing initial short description of 'v4l2_src_change_event_subscribe' [1] https://return42.github.io/linuxdoc/linux.html The above are real issues at the documentation. On several cases, caused by cut-and-paste. Fix them. Signed-off-by: Mauro Carvalho Chehab <[email protected]>
1 parent c2b66ca commit e383ce0

File tree

12 files changed

+24
-20
lines changed

12 files changed

+24
-20
lines changed

Documentation/media/kapi/v4l2-dev.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ The implementation of a hotplug disconnect should also take the lock from
173173
using :c:type:`video_device`->queue->lock, then you have to first lock
174174
:c:type:`video_device`->queue->lock followed by :c:type:`video_device`->lock.
175175
That way you can be sure no ioctl is running when you call
176-
:c:type:`v4l2_device_disconnect`.
176+
:c:func:`v4l2_device_disconnect`.
177177

178178
Video device registration
179179
-------------------------

drivers/media/dvb-core/dvb_math.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
#include <linux/types.h>
2626

2727
/**
28-
* cintlog2 - computes log2 of a value; the result is shifted left by 24 bits
28+
* intlog2 - computes log2 of a value; the result is shifted left by 24 bits
2929
*
3030
* @value: The value (must be != 0)
3131
*

drivers/media/dvb-core/dvb_ringbuffer.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ extern ssize_t dvb_ringbuffer_write(struct dvb_ringbuffer *rbuf, const u8 *buf,
193193
size_t len);
194194

195195
/**
196-
* dvb_ringbuffer_writeuser - Writes a buffer received via an user pointer
196+
* dvb_ringbuffer_write_user - Writes a buffer received via an user pointer
197197
*
198198
* @rbuf: pointer to struct dvb_ringbuffer
199199
* @buf: pointer to the buffer where the data will be read

include/media/media-entity.h

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ struct media_pipeline {
129129
* an interface.
130130
* @gobj1: Part of a union. Used to get the pointer for the second
131131
* graph_object of the link.
132-
* @source: Part of a union. Used only if the second object (gobj1) is
132+
* @sink: Part of a union. Used only if the second object (gobj1) is
133133
* a pad. In that case, it represents the sink pad.
134134
* @entity: Part of a union. Used only if the second object (gobj1) is
135135
* an entity.
@@ -474,7 +474,8 @@ static inline bool media_entity_enum_test(struct media_entity_enum *ent_enum,
474474
}
475475

476476
/**
477-
* media_entity_enum_test - Test whether the entity is marked, and mark it
477+
* media_entity_enum_test_and_set - Test whether the entity is marked,
478+
* and mark it
478479
*
479480
* @ent_enum: Entity enumeration
480481
* @entity: Entity to be tested
@@ -532,7 +533,7 @@ static inline bool media_entity_enum_intersects(
532533
container_of(gobj, struct media_entity, graph_obj)
533534

534535
/**
535-
* gobj_to_entity - returns the struct &media_pad pointer from the
536+
* gobj_to_pad - returns the struct &media_pad pointer from the
536537
* @gobj contained on it.
537538
*
538539
* @gobj: Pointer to the struct &media_gobj graph object
@@ -541,7 +542,7 @@ static inline bool media_entity_enum_intersects(
541542
container_of(gobj, struct media_pad, graph_obj)
542543

543544
/**
544-
* gobj_to_entity - returns the struct &media_link pointer from the
545+
* gobj_to_link - returns the struct &media_link pointer from the
545546
* @gobj contained on it.
546547
*
547548
* @gobj: Pointer to the struct &media_gobj graph object
@@ -550,7 +551,7 @@ static inline bool media_entity_enum_intersects(
550551
container_of(gobj, struct media_link, graph_obj)
551552

552553
/**
553-
* gobj_to_entity - returns the struct &media_interface pointer from the
554+
* gobj_to_intf - returns the struct &media_interface pointer from the
554555
* @gobj contained on it.
555556
*
556557
* @gobj: Pointer to the struct &media_gobj graph object
@@ -559,7 +560,7 @@ static inline bool media_entity_enum_intersects(
559560
container_of(gobj, struct media_interface, graph_obj)
560561

561562
/**
562-
* gobj_to_entity - returns the struct media_intf_devnode pointer from the
563+
* intf_to_devnode - returns the struct media_intf_devnode pointer from the
563564
* @intf contained on it.
564565
*
565566
* @intf: Pointer to struct &media_intf_devnode

include/media/rc-core.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ void rc_unregister_device(struct rc_dev *dev);
231231
int rc_open(struct rc_dev *rdev);
232232

233233
/**
234-
* rc_open - Closes a RC device
234+
* rc_close - Closes a RC device
235235
*
236236
* @rdev: pointer to struct rc_dev.
237237
*/

include/media/v4l2-ctrls.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,8 @@ int v4l2_ctrl_handler_init_class(struct v4l2_ctrl_handler *hdl,
394394
#ifdef CONFIG_LOCKDEP
395395

396396
/**
397-
* v4l2_ctrl_handler_init -
397+
* v4l2_ctrl_handler_init - helper function to create a static struct
398+
* &lock_class_key and calls v4l2_ctrl_handler_init_class()
398399
*
399400
* @hdl: The control handler.
400401
* @nr_of_controls_hint: A hint of how many controls this handler is

include/media/v4l2-dev.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ void v4l2_prio_close(struct v4l2_prio_state *global, enum v4l2_priority local);
115115
enum v4l2_priority v4l2_prio_max(struct v4l2_prio_state *global);
116116

117117
/**
118-
* v4l2_prio_close - Implements the priority logic for a file handler close
118+
* v4l2_prio_check - Implements the priority logic for a file handler close
119119
*
120120
* @global: pointer to the &struct v4l2_prio_state of the device node.
121121
* @local: desired priority, as defined by enum &v4l2_priority local

include/media/v4l2-event.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,8 @@ int v4l2_event_subdev_unsubscribe(struct v4l2_subdev *sd,
222222
struct v4l2_fh *fh,
223223
struct v4l2_event_subscription *sub);
224224
/**
225-
* v4l2_src_change_event_subscribe -
225+
* v4l2_src_change_event_subscribe - helper function that calls
226+
* v4l2_event_subscribe() if the event is %V4L2_EVENT_SOURCE_CHANGE.
226227
*
227228
* @fh: pointer to struct v4l2_fh
228229
* @sub: pointer to &struct v4l2_event_subscription

include/media/v4l2-mc.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ enum tuner_pad_index {
5353
};
5454

5555
/**
56-
* enum if_vid_dec_index - video IF-PLL pad index for
56+
* enum if_vid_dec_pad_index - video IF-PLL pad index for
5757
* MEDIA_ENT_F_IF_VID_DECODER
5858
*
5959
* @IF_VID_DEC_PAD_IF_INPUT: video Intermediate Frequency (IF) sink pad
@@ -68,7 +68,7 @@ enum if_vid_dec_pad_index {
6868
};
6969

7070
/**
71-
* enum if_aud_dec_index - audio/sound IF-PLL pad index for
71+
* enum if_aud_dec_pad_index - audio/sound IF-PLL pad index for
7272
* MEDIA_ENT_F_IF_AUD_DECODER
7373
*
7474
* @IF_AUD_DEC_PAD_IF_INPUT: audio Intermediate Frequency (IF) sink pad

include/media/v4l2-mem2mem.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ unsigned int v4l2_m2m_num_src_bufs_ready(struct v4l2_m2m_ctx *m2m_ctx)
393393
}
394394

395395
/**
396-
* v4l2_m2m_num_src_bufs_ready() - return the number of destination buffers
396+
* v4l2_m2m_num_dst_bufs_ready() - return the number of destination buffers
397397
* ready for use
398398
*
399399
* @m2m_ctx: m2m context assigned to the instance given by struct &v4l2_m2m_ctx

0 commit comments

Comments
 (0)