* [PATCH 1/1] [media] v4l2-ctrls: Remove duplicate const
@ 2013-08-30 11:11 Sachin Kamat
2013-08-30 11:32 ` Sylwester Nawrocki
0 siblings, 1 reply; 4+ messages in thread
From: Sachin Kamat @ 2013-08-30 11:11 UTC (permalink / raw)
To: linux-media; +Cc: hans.verkuil, sachin.kamat, patches, Sylwester Nawrocki
The function returns a pointer to a const array. Duplicate use of const
led to the following warning.
drivers/media/v4l2-core/v4l2-ctrls.c:574:32: warning: duplicate const
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Sylwester Nawrocki <s.nawrocki@samsung.com>
---
drivers/media/v4l2-core/v4l2-ctrls.c | 6 +++---
include/media/v4l2-common.h | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/media/v4l2-core/v4l2-ctrls.c b/drivers/media/v4l2-core/v4l2-ctrls.c
index c6dc1fd..653d48d 100644
--- a/drivers/media/v4l2-core/v4l2-ctrls.c
+++ b/drivers/media/v4l2-core/v4l2-ctrls.c
@@ -565,13 +565,13 @@ EXPORT_SYMBOL(v4l2_ctrl_get_menu);
* Returns NULL or an s64 type array containing the menu for given
* control ID. The total number of the menu items is returned in @len.
*/
-const s64 const *v4l2_ctrl_get_int_menu(u32 id, u32 *len)
+const s64 *v4l2_ctrl_get_int_menu(u32 id, u32 *len)
{
- static const s64 const qmenu_int_vpx_num_partitions[] = {
+ static const s64 qmenu_int_vpx_num_partitions[] = {
1, 2, 4, 8,
};
- static const s64 const qmenu_int_vpx_num_ref_frames[] = {
+ static const s64 qmenu_int_vpx_num_ref_frames[] = {
1, 2, 3,
};
diff --git a/include/media/v4l2-common.h b/include/media/v4l2-common.h
index 16550c4..b87692c 100644
--- a/include/media/v4l2-common.h
+++ b/include/media/v4l2-common.h
@@ -86,7 +86,7 @@ int v4l2_ctrl_check(struct v4l2_ext_control *ctrl, struct v4l2_queryctrl *qctrl,
const char * const *menu_items);
const char *v4l2_ctrl_get_name(u32 id);
const char * const *v4l2_ctrl_get_menu(u32 id);
-const s64 const *v4l2_ctrl_get_int_menu(u32 id, u32 *len);
+const s64 *v4l2_ctrl_get_int_menu(u32 id, u32 *len);
int v4l2_ctrl_query_fill(struct v4l2_queryctrl *qctrl, s32 min, s32 max, s32 step, s32 def);
int v4l2_ctrl_query_menu(struct v4l2_querymenu *qmenu,
struct v4l2_queryctrl *qctrl, const char * const *menu_items);
--
1.7.9.5
^ permalink raw reply related [flat|nested] 4+ messages in thread* Re: [PATCH 1/1] [media] v4l2-ctrls: Remove duplicate const
2013-08-30 11:11 [PATCH 1/1] [media] v4l2-ctrls: Remove duplicate const Sachin Kamat
@ 2013-08-30 11:32 ` Sylwester Nawrocki
2013-08-30 11:42 ` Sachin Kamat
0 siblings, 1 reply; 4+ messages in thread
From: Sylwester Nawrocki @ 2013-08-30 11:32 UTC (permalink / raw)
To: Sachin Kamat; +Cc: linux-media, hans.verkuil, patches
Hi Sachin,
On 08/30/2013 01:11 PM, Sachin Kamat wrote:
> The function returns a pointer to a const array. Duplicate use of const
> led to the following warning.
> drivers/media/v4l2-core/v4l2-ctrls.c:574:32: warning: duplicate const
>
> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
> Cc: Sylwester Nawrocki <s.nawrocki@samsung.com>
Thanks for the patch. I have already submitted a fix for this:
https://patchwork.linuxtv.org/patch/19902/
Regards,
Sylwester
> ---
> drivers/media/v4l2-core/v4l2-ctrls.c | 6 +++---
> include/media/v4l2-common.h | 2 +-
> 2 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/media/v4l2-core/v4l2-ctrls.c b/drivers/media/v4l2-core/v4l2-ctrls.c
> index c6dc1fd..653d48d 100644
> --- a/drivers/media/v4l2-core/v4l2-ctrls.c
> +++ b/drivers/media/v4l2-core/v4l2-ctrls.c
> @@ -565,13 +565,13 @@ EXPORT_SYMBOL(v4l2_ctrl_get_menu);
> * Returns NULL or an s64 type array containing the menu for given
> * control ID. The total number of the menu items is returned in @len.
> */
> -const s64 const *v4l2_ctrl_get_int_menu(u32 id, u32 *len)
> +const s64 *v4l2_ctrl_get_int_menu(u32 id, u32 *len)
> {
> - static const s64 const qmenu_int_vpx_num_partitions[] = {
> + static const s64 qmenu_int_vpx_num_partitions[] = {
> 1, 2, 4, 8,
> };
>
> - static const s64 const qmenu_int_vpx_num_ref_frames[] = {
> + static const s64 qmenu_int_vpx_num_ref_frames[] = {
> 1, 2, 3,
> };
>
> diff --git a/include/media/v4l2-common.h b/include/media/v4l2-common.h
> index 16550c4..b87692c 100644
> --- a/include/media/v4l2-common.h
> +++ b/include/media/v4l2-common.h
> @@ -86,7 +86,7 @@ int v4l2_ctrl_check(struct v4l2_ext_control *ctrl, struct v4l2_queryctrl *qctrl,
> const char * const *menu_items);
> const char *v4l2_ctrl_get_name(u32 id);
> const char * const *v4l2_ctrl_get_menu(u32 id);
> -const s64 const *v4l2_ctrl_get_int_menu(u32 id, u32 *len);
> +const s64 *v4l2_ctrl_get_int_menu(u32 id, u32 *len);
> int v4l2_ctrl_query_fill(struct v4l2_queryctrl *qctrl, s32 min, s32 max, s32 step, s32 def);
> int v4l2_ctrl_query_menu(struct v4l2_querymenu *qmenu,
> struct v4l2_queryctrl *qctrl, const char * const *menu_items);
>
--
Sylwester Nawrocki
Samsung R&D Institute Poland
^ permalink raw reply [flat|nested] 4+ messages in thread* Re: [PATCH 1/1] [media] v4l2-ctrls: Remove duplicate const
2013-08-30 11:32 ` Sylwester Nawrocki
@ 2013-08-30 11:42 ` Sachin Kamat
2013-08-30 12:08 ` Sylwester Nawrocki
0 siblings, 1 reply; 4+ messages in thread
From: Sachin Kamat @ 2013-08-30 11:42 UTC (permalink / raw)
To: Sylwester Nawrocki; +Cc: linux-media, hans.verkuil, Patch Tracking
On 30 August 2013 17:02, Sylwester Nawrocki <s.nawrocki@samsung.com> wrote:
> Hi Sachin,
>
> On 08/30/2013 01:11 PM, Sachin Kamat wrote:
>> The function returns a pointer to a const array. Duplicate use of const
>> led to the following warning.
>> drivers/media/v4l2-core/v4l2-ctrls.c:574:32: warning: duplicate const
>>
>> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
>> Cc: Sylwester Nawrocki <s.nawrocki@samsung.com>
>
> Thanks for the patch. I have already submitted a fix for this:
> https://patchwork.linuxtv.org/patch/19902/
Oops.. missed out on that. Looks like it is not yet applied to your
for-3.12-3 branch?
--
With warm regards,
Sachin
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH 1/1] [media] v4l2-ctrls: Remove duplicate const
2013-08-30 11:42 ` Sachin Kamat
@ 2013-08-30 12:08 ` Sylwester Nawrocki
0 siblings, 0 replies; 4+ messages in thread
From: Sylwester Nawrocki @ 2013-08-30 12:08 UTC (permalink / raw)
To: Sachin Kamat; +Cc: linux-media, hans.verkuil, Patch Tracking
On 08/30/2013 01:42 PM, Sachin Kamat wrote:
> On 30 August 2013 17:02, Sylwester Nawrocki <s.nawrocki@samsung.com> wrote:
>> Hi Sachin,
>>
>> On 08/30/2013 01:11 PM, Sachin Kamat wrote:
>>> The function returns a pointer to a const array. Duplicate use of const
>>> led to the following warning.
>>> drivers/media/v4l2-core/v4l2-ctrls.c:574:32: warning: duplicate const
>>>
>>> Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
>>> Cc: Sylwester Nawrocki <s.nawrocki@samsung.com>
>>
>> Thanks for the patch. I have already submitted a fix for this:
>> https://patchwork.linuxtv.org/patch/19902/
>
> Oops.. missed out on that. Looks like it is not yet applied to your
> for-3.12-3 branch?
Yup, I didn't apply it since it touches the control framework. Thus
I assumed Hans will want to pick it up to his tree.
Regards,
Sylwester
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-08-30 12:08 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-30 11:11 [PATCH 1/1] [media] v4l2-ctrls: Remove duplicate const Sachin Kamat
2013-08-30 11:32 ` Sylwester Nawrocki
2013-08-30 11:42 ` Sachin Kamat
2013-08-30 12:08 ` Sylwester Nawrocki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox