media: rc: fix lots of documentation warnings
Building the driver with gcc 7.2.1 and: make ARCH=i386 CF=-D__CHECK_ENDIAN__ CONFIG_DEBUG_SECTION_MISMATCH=y W=1 CHECK='' M=drivers/media now produces a lot of warnings: drivers/media/rc/rc-main.c:278: warning: No description found for parameter 'new_keycode' drivers/media/rc/rc-main.c:278: warning: Excess function parameter 'keycode' description in 'ir_update_mapping' drivers/media/rc/rc-main.c:387: warning: No description found for parameter 'ke' drivers/media/rc/rc-main.c:387: warning: No description found for parameter 'old_keycode' drivers/media/rc/rc-main.c:387: warning: Excess function parameter 'scancode' description in 'ir_setkeycode' drivers/media/rc/rc-main.c:387: warning: Excess function parameter 'keycode' description in 'ir_setkeycode' drivers/media/rc/rc-main.c:433: warning: Excess function parameter 'to' description in 'ir_setkeytable' drivers/media/rc/rc-main.c:506: warning: No description found for parameter 'ke' drivers/media/rc/rc-main.c:506: warning: Excess function parameter 'scancode' description in 'ir_getkeycode' drivers/media/rc/rc-main.c:506: warning: Excess function parameter 'keycode' description in 'ir_getkeycode' drivers/media/rc/rc-main.c:634: warning: No description found for parameter 't' drivers/media/rc/rc-main.c:634: warning: Excess function parameter 'cookie' description in 'ir_timer_keyup' Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
This commit is contained in:
Родитель
46e42a3031
Коммит
f67f366c69
|
@ -170,10 +170,11 @@ static struct rc_map_list empty_map = {
|
||||||
* @name: name to assign to the table
|
* @name: name to assign to the table
|
||||||
* @rc_proto: ir type to assign to the new table
|
* @rc_proto: ir type to assign to the new table
|
||||||
* @size: initial size of the table
|
* @size: initial size of the table
|
||||||
* @return: zero on success or a negative error code
|
|
||||||
*
|
*
|
||||||
* This routine will initialize the rc_map and will allocate
|
* This routine will initialize the rc_map and will allocate
|
||||||
* memory to hold at least the specified number of elements.
|
* memory to hold at least the specified number of elements.
|
||||||
|
*
|
||||||
|
* return: zero on success or a negative error code
|
||||||
*/
|
*/
|
||||||
static int ir_create_table(struct rc_map *rc_map,
|
static int ir_create_table(struct rc_map *rc_map,
|
||||||
const char *name, u64 rc_proto, size_t size)
|
const char *name, u64 rc_proto, size_t size)
|
||||||
|
@ -216,10 +217,11 @@ static void ir_free_table(struct rc_map *rc_map)
|
||||||
* ir_resize_table() - resizes a scancode table if necessary
|
* ir_resize_table() - resizes a scancode table if necessary
|
||||||
* @rc_map: the rc_map to resize
|
* @rc_map: the rc_map to resize
|
||||||
* @gfp_flags: gfp flags to use when allocating memory
|
* @gfp_flags: gfp flags to use when allocating memory
|
||||||
* @return: zero on success or a negative error code
|
|
||||||
*
|
*
|
||||||
* This routine will shrink the rc_map if it has lots of
|
* This routine will shrink the rc_map if it has lots of
|
||||||
* unused entries and grow it if it is full.
|
* unused entries and grow it if it is full.
|
||||||
|
*
|
||||||
|
* return: zero on success or a negative error code
|
||||||
*/
|
*/
|
||||||
static int ir_resize_table(struct rc_map *rc_map, gfp_t gfp_flags)
|
static int ir_resize_table(struct rc_map *rc_map, gfp_t gfp_flags)
|
||||||
{
|
{
|
||||||
|
@ -265,11 +267,13 @@ static int ir_resize_table(struct rc_map *rc_map, gfp_t gfp_flags)
|
||||||
* @dev: the struct rc_dev device descriptor
|
* @dev: the struct rc_dev device descriptor
|
||||||
* @rc_map: scancode table to be adjusted
|
* @rc_map: scancode table to be adjusted
|
||||||
* @index: index of the mapping that needs to be updated
|
* @index: index of the mapping that needs to be updated
|
||||||
* @keycode: the desired keycode
|
* @new_keycode: the desired keycode
|
||||||
* @return: previous keycode assigned to the mapping
|
|
||||||
*
|
*
|
||||||
* This routine is used to update scancode->keycode mapping at given
|
* This routine is used to update scancode->keycode mapping at given
|
||||||
* position.
|
* position.
|
||||||
|
*
|
||||||
|
* return: previous keycode assigned to the mapping
|
||||||
|
*
|
||||||
*/
|
*/
|
||||||
static unsigned int ir_update_mapping(struct rc_dev *dev,
|
static unsigned int ir_update_mapping(struct rc_dev *dev,
|
||||||
struct rc_map *rc_map,
|
struct rc_map *rc_map,
|
||||||
|
@ -320,12 +324,13 @@ static unsigned int ir_update_mapping(struct rc_dev *dev,
|
||||||
* @scancode: the desired scancode
|
* @scancode: the desired scancode
|
||||||
* @resize: controls whether we allowed to resize the table to
|
* @resize: controls whether we allowed to resize the table to
|
||||||
* accommodate not yet present scancodes
|
* accommodate not yet present scancodes
|
||||||
* @return: index of the mapping containing scancode in question
|
|
||||||
* or -1U in case of failure.
|
|
||||||
*
|
*
|
||||||
* This routine is used to locate given scancode in rc_map.
|
* This routine is used to locate given scancode in rc_map.
|
||||||
* If scancode is not yet present the routine will allocate a new slot
|
* If scancode is not yet present the routine will allocate a new slot
|
||||||
* for it.
|
* for it.
|
||||||
|
*
|
||||||
|
* return: index of the mapping containing scancode in question
|
||||||
|
* or -1U in case of failure.
|
||||||
*/
|
*/
|
||||||
static unsigned int ir_establish_scancode(struct rc_dev *dev,
|
static unsigned int ir_establish_scancode(struct rc_dev *dev,
|
||||||
struct rc_map *rc_map,
|
struct rc_map *rc_map,
|
||||||
|
@ -375,11 +380,12 @@ static unsigned int ir_establish_scancode(struct rc_dev *dev,
|
||||||
/**
|
/**
|
||||||
* ir_setkeycode() - set a keycode in the scancode->keycode table
|
* ir_setkeycode() - set a keycode in the scancode->keycode table
|
||||||
* @idev: the struct input_dev device descriptor
|
* @idev: the struct input_dev device descriptor
|
||||||
* @scancode: the desired scancode
|
* @ke: Input keymap entry
|
||||||
* @keycode: result
|
* @old_keycode: result
|
||||||
* @return: -EINVAL if the keycode could not be inserted, otherwise zero.
|
|
||||||
*
|
*
|
||||||
* This routine is used to handle evdev EVIOCSKEY ioctl.
|
* This routine is used to handle evdev EVIOCSKEY ioctl.
|
||||||
|
*
|
||||||
|
* return: -EINVAL if the keycode could not be inserted, otherwise zero.
|
||||||
*/
|
*/
|
||||||
static int ir_setkeycode(struct input_dev *idev,
|
static int ir_setkeycode(struct input_dev *idev,
|
||||||
const struct input_keymap_entry *ke,
|
const struct input_keymap_entry *ke,
|
||||||
|
@ -422,11 +428,11 @@ out:
|
||||||
/**
|
/**
|
||||||
* ir_setkeytable() - sets several entries in the scancode->keycode table
|
* ir_setkeytable() - sets several entries in the scancode->keycode table
|
||||||
* @dev: the struct rc_dev device descriptor
|
* @dev: the struct rc_dev device descriptor
|
||||||
* @to: the struct rc_map to copy entries to
|
|
||||||
* @from: the struct rc_map to copy entries from
|
* @from: the struct rc_map to copy entries from
|
||||||
* @return: -ENOMEM if all keycodes could not be inserted, otherwise zero.
|
|
||||||
*
|
*
|
||||||
* This routine is used to handle table initialization.
|
* This routine is used to handle table initialization.
|
||||||
|
*
|
||||||
|
* return: -ENOMEM if all keycodes could not be inserted, otherwise zero.
|
||||||
*/
|
*/
|
||||||
static int ir_setkeytable(struct rc_dev *dev,
|
static int ir_setkeytable(struct rc_dev *dev,
|
||||||
const struct rc_map *from)
|
const struct rc_map *from)
|
||||||
|
@ -474,10 +480,11 @@ static int rc_map_cmp(const void *key, const void *elt)
|
||||||
* ir_lookup_by_scancode() - locate mapping by scancode
|
* ir_lookup_by_scancode() - locate mapping by scancode
|
||||||
* @rc_map: the struct rc_map to search
|
* @rc_map: the struct rc_map to search
|
||||||
* @scancode: scancode to look for in the table
|
* @scancode: scancode to look for in the table
|
||||||
* @return: index in the table, -1U if not found
|
|
||||||
*
|
*
|
||||||
* This routine performs binary search in RC keykeymap table for
|
* This routine performs binary search in RC keykeymap table for
|
||||||
* given scancode.
|
* given scancode.
|
||||||
|
*
|
||||||
|
* return: index in the table, -1U if not found
|
||||||
*/
|
*/
|
||||||
static unsigned int ir_lookup_by_scancode(const struct rc_map *rc_map,
|
static unsigned int ir_lookup_by_scancode(const struct rc_map *rc_map,
|
||||||
unsigned int scancode)
|
unsigned int scancode)
|
||||||
|
@ -495,11 +502,11 @@ static unsigned int ir_lookup_by_scancode(const struct rc_map *rc_map,
|
||||||
/**
|
/**
|
||||||
* ir_getkeycode() - get a keycode from the scancode->keycode table
|
* ir_getkeycode() - get a keycode from the scancode->keycode table
|
||||||
* @idev: the struct input_dev device descriptor
|
* @idev: the struct input_dev device descriptor
|
||||||
* @scancode: the desired scancode
|
* @ke: Input keymap entry
|
||||||
* @keycode: used to return the keycode, if found, or KEY_RESERVED
|
|
||||||
* @return: always returns zero.
|
|
||||||
*
|
*
|
||||||
* This routine is used to handle evdev EVIOCGKEY ioctl.
|
* This routine is used to handle evdev EVIOCGKEY ioctl.
|
||||||
|
*
|
||||||
|
* return: always returns zero.
|
||||||
*/
|
*/
|
||||||
static int ir_getkeycode(struct input_dev *idev,
|
static int ir_getkeycode(struct input_dev *idev,
|
||||||
struct input_keymap_entry *ke)
|
struct input_keymap_entry *ke)
|
||||||
|
@ -556,11 +563,12 @@ out:
|
||||||
* rc_g_keycode_from_table() - gets the keycode that corresponds to a scancode
|
* rc_g_keycode_from_table() - gets the keycode that corresponds to a scancode
|
||||||
* @dev: the struct rc_dev descriptor of the device
|
* @dev: the struct rc_dev descriptor of the device
|
||||||
* @scancode: the scancode to look for
|
* @scancode: the scancode to look for
|
||||||
* @return: the corresponding keycode, or KEY_RESERVED
|
|
||||||
*
|
*
|
||||||
* This routine is used by drivers which need to convert a scancode to a
|
* This routine is used by drivers which need to convert a scancode to a
|
||||||
* keycode. Normally it should not be used since drivers should have no
|
* keycode. Normally it should not be used since drivers should have no
|
||||||
* interest in keycodes.
|
* interest in keycodes.
|
||||||
|
*
|
||||||
|
* return: the corresponding keycode, or KEY_RESERVED
|
||||||
*/
|
*/
|
||||||
u32 rc_g_keycode_from_table(struct rc_dev *dev, u32 scancode)
|
u32 rc_g_keycode_from_table(struct rc_dev *dev, u32 scancode)
|
||||||
{
|
{
|
||||||
|
@ -625,7 +633,8 @@ EXPORT_SYMBOL_GPL(rc_keyup);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* ir_timer_keyup() - generates a keyup event after a timeout
|
* ir_timer_keyup() - generates a keyup event after a timeout
|
||||||
* @cookie: a pointer to the struct rc_dev for the device
|
*
|
||||||
|
* @t: a pointer to the struct timer_list
|
||||||
*
|
*
|
||||||
* This routine will generate a keyup event some time after a keydown event
|
* This routine will generate a keyup event some time after a keydown event
|
||||||
* is generated when no further activity has been detected.
|
* is generated when no further activity has been detected.
|
||||||
|
@ -780,7 +789,8 @@ EXPORT_SYMBOL_GPL(rc_keydown_notimeout);
|
||||||
* provides sensible defaults
|
* provides sensible defaults
|
||||||
* @dev: the struct rc_dev descriptor of the device
|
* @dev: the struct rc_dev descriptor of the device
|
||||||
* @filter: the scancode and mask
|
* @filter: the scancode and mask
|
||||||
* @return: 0 or -EINVAL if the filter is not valid
|
*
|
||||||
|
* return: 0 or -EINVAL if the filter is not valid
|
||||||
*/
|
*/
|
||||||
static int rc_validate_filter(struct rc_dev *dev,
|
static int rc_validate_filter(struct rc_dev *dev,
|
||||||
struct rc_scancode_filter *filter)
|
struct rc_scancode_filter *filter)
|
||||||
|
|
Загрузка…
Ссылка в новой задаче