* [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
@ 2024-05-06 3:59 Brad Smith
2024-05-07 21:49 ` Marton Balint
2024-05-18 11:27 ` Brad Smith
0 siblings, 2 replies; 6+ messages in thread
From: Brad Smith @ 2024-05-06 3:59 UTC (permalink / raw)
To: ffmpeg-devel
lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
The proper type was used until 73251678c83cbe24d08264da693411b166239bc7.
This covers all of the OS's that currently have V4L2 support, permutations
of Linux glibc/musl, Android bionic, FreeBSD, NetBSD, OpenBSD, Solaris.
Copied from FreeBSD ports patch.
Signed-off-by: Brad Smith <brad@comstyle.com>
---
libavdevice/v4l2.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/libavdevice/v4l2.c b/libavdevice/v4l2.c
index 3706582bc6..74f43ef6a9 100644
--- a/libavdevice/v4l2.c
+++ b/libavdevice/v4l2.c
@@ -108,10 +108,10 @@ struct video_data {
int (*open_f)(const char *file, int oflag, ...);
int (*close_f)(int fd);
int (*dup_f)(int fd);
-#ifdef __GLIBC__
- int (*ioctl_f)(int fd, unsigned long int request, ...);
-#else
+#if defined(__sun) || defined(__BIONIC__) || defined(__musl__) /* POSIX-like */
int (*ioctl_f)(int fd, int request, ...);
+#else
+ int (*ioctl_f)(int fd, unsigned long int request, ...);
#endif
ssize_t (*read_f)(int fd, void *buffer, size_t n);
void *(*mmap_f)(void *start, size_t length, int prot, int flags, int fd, int64_t offset);
--
2.44.0
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
2024-05-06 3:59 [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's Brad Smith
@ 2024-05-07 21:49 ` Marton Balint
2024-05-18 11:27 ` Brad Smith
1 sibling, 0 replies; 6+ messages in thread
From: Marton Balint @ 2024-05-07 21:49 UTC (permalink / raw)
To: FFmpeg development discussions and patches
On Sun, 5 May 2024, Brad Smith wrote:
> lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
>
> The proper type was used until 73251678c83cbe24d08264da693411b166239bc7.
>
> This covers all of the OS's that currently have V4L2 support, permutations
> of Linux glibc/musl, Android bionic, FreeBSD, NetBSD, OpenBSD, Solaris.
>
> Copied from FreeBSD ports patch.
>
> Signed-off-by: Brad Smith <brad@comstyle.com>
> ---
> libavdevice/v4l2.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/libavdevice/v4l2.c b/libavdevice/v4l2.c
> index 3706582bc6..74f43ef6a9 100644
> --- a/libavdevice/v4l2.c
> +++ b/libavdevice/v4l2.c
> @@ -108,10 +108,10 @@ struct video_data {
> int (*open_f)(const char *file, int oflag, ...);
> int (*close_f)(int fd);
> int (*dup_f)(int fd);
> -#ifdef __GLIBC__
> - int (*ioctl_f)(int fd, unsigned long int request, ...);
> -#else
> +#if defined(__sun) || defined(__BIONIC__) || defined(__musl__) /* POSIX-like */
> int (*ioctl_f)(int fd, int request, ...);
> +#else
> + int (*ioctl_f)(int fd, unsigned long int request, ...);
> #endif
> ssize_t (*read_f)(int fd, void *buffer, size_t n);
> void *(*mmap_f)(void *start, size_t length, int prot, int flags, int fd, int64_t offset);
Will apply.
Thanks,
Marton
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
2024-05-06 3:59 [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's Brad Smith
2024-05-07 21:49 ` Marton Balint
@ 2024-05-18 11:27 ` Brad Smith
2024-05-18 12:40 ` Dennis Mungai
2024-05-18 19:58 ` Michael Niedermayer
1 sibling, 2 replies; 6+ messages in thread
From: Brad Smith @ 2024-05-18 11:27 UTC (permalink / raw)
To: ffmpeg-devel
Can this be backported to 7, 6, 5 and 4.4 releases?
On 2024-05-05 11:59 p.m., Brad Smith wrote:
> lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
>
> The proper type was used until 73251678c83cbe24d08264da693411b166239bc7.
>
> This covers all of the OS's that currently have V4L2 support, permutations
> of Linux glibc/musl, Android bionic, FreeBSD, NetBSD, OpenBSD, Solaris.
>
> Copied from FreeBSD ports patch.
>
> Signed-off-by: Brad Smith <brad@comstyle.com>
> ---
> libavdevice/v4l2.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/libavdevice/v4l2.c b/libavdevice/v4l2.c
> index 3706582bc6..74f43ef6a9 100644
> --- a/libavdevice/v4l2.c
> +++ b/libavdevice/v4l2.c
> @@ -108,10 +108,10 @@ struct video_data {
> int (*open_f)(const char *file, int oflag, ...);
> int (*close_f)(int fd);
> int (*dup_f)(int fd);
> -#ifdef __GLIBC__
> - int (*ioctl_f)(int fd, unsigned long int request, ...);
> -#else
> +#if defined(__sun) || defined(__BIONIC__) || defined(__musl__) /* POSIX-like */
> int (*ioctl_f)(int fd, int request, ...);
> +#else
> + int (*ioctl_f)(int fd, unsigned long int request, ...);
> #endif
> ssize_t (*read_f)(int fd, void *buffer, size_t n);
> void *(*mmap_f)(void *start, size_t length, int prot, int flags, int fd, int64_t offset);
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
2024-05-18 11:27 ` Brad Smith
@ 2024-05-18 12:40 ` Dennis Mungai
2024-05-18 19:58 ` Michael Niedermayer
1 sibling, 0 replies; 6+ messages in thread
From: Dennis Mungai @ 2024-05-18 12:40 UTC (permalink / raw)
To: FFmpeg development discussions and patches
On Sat, 18 May 2024, 14:27 Brad Smith, <brad-at-comstyle.com@ffmpeg.org>
wrote:
> Can this be backported to 7, 6, 5 and 4.4 releases?
>
> On 2024-05-05 11:59 p.m., Brad Smith wrote:
> > lavd/v4l2: Use proper field type for second parameter of ioctl() with
> BSD's
> >
> > The proper type was used until 73251678c83cbe24d08264da693411b166239bc7.
> >
> > This covers all of the OS's that currently have V4L2 support,
> permutations
> > of Linux glibc/musl, Android bionic, FreeBSD, NetBSD, OpenBSD, Solaris.
> >
> > Copied from FreeBSD ports patch.
> >
> > Signed-off-by: Brad Smith <brad@comstyle.com>
> > ---
> > libavdevice/v4l2.c | 6 +++---
> > 1 file changed, 3 insertions(+), 3 deletions(-)
> >
> > diff --git a/libavdevice/v4l2.c b/libavdevice/v4l2.c
> > index 3706582bc6..74f43ef6a9 100644
> > --- a/libavdevice/v4l2.c
> > +++ b/libavdevice/v4l2.c
> > @@ -108,10 +108,10 @@ struct video_data {
> > int (*open_f)(const char *file, int oflag, ...);
> > int (*close_f)(int fd);
> > int (*dup_f)(int fd);
> > -#ifdef __GLIBC__
> > - int (*ioctl_f)(int fd, unsigned long int request, ...);
> > -#else
> > +#if defined(__sun) || defined(__BIONIC__) || defined(__musl__) /*
> POSIX-like */
> > int (*ioctl_f)(int fd, int request, ...);
> > +#else
> > + int (*ioctl_f)(int fd, unsigned long int request, ...);
> > #endif
> > ssize_t (*read_f)(int fd, void *buffer, size_t n);
> > void *(*mmap_f)(void *start, size_t length, int prot, int flags,
> int fd, int64_t offset);
> _".
>
Seconded, a backport would be ideal for prior releases.
>
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
2024-05-18 11:27 ` Brad Smith
2024-05-18 12:40 ` Dennis Mungai
@ 2024-05-18 19:58 ` Michael Niedermayer
2024-05-18 23:53 ` Brad Smith
1 sibling, 1 reply; 6+ messages in thread
From: Michael Niedermayer @ 2024-05-18 19:58 UTC (permalink / raw)
To: FFmpeg development discussions and patches
[-- Attachment #1.1: Type: text/plain, Size: 393 bytes --]
On Sat, May 18, 2024 at 07:27:35AM -0400, Brad Smith wrote:
> Can this be backported to 7, 6, 5 and 4.4 releases?
yes and everyone who has write access to master also has write access to
the releases branches!
thx
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
There will always be a question for which you do not know the correct answer.
[-- Attachment #1.2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]
[-- Attachment #2: Type: text/plain, Size: 251 bytes --]
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's
2024-05-18 19:58 ` Michael Niedermayer
@ 2024-05-18 23:53 ` Brad Smith
0 siblings, 0 replies; 6+ messages in thread
From: Brad Smith @ 2024-05-18 23:53 UTC (permalink / raw)
To: FFmpeg development discussions and patches, Michael Niedermayer
> yes and everyone who has write access to master also has write access to
> the releases branches!
>
> thx
Ok, I don't mind helping out here.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2024-05-18 23:53 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-06 3:59 [FFmpeg-devel] [PATCH] lavd/v4l2: Use proper field type for second parameter of ioctl() with BSD's Brad Smith
2024-05-07 21:49 ` Marton Balint
2024-05-18 11:27 ` Brad Smith
2024-05-18 12:40 ` Dennis Mungai
2024-05-18 19:58 ` Michael Niedermayer
2024-05-18 23:53 ` Brad Smith
Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
This inbox may be cloned and mirrored by anyone:
git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git
# If you have public-inbox 1.1+ installed, you may
# initialize and index your mirror using the following commands:
public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
ffmpegdev@gitmailbox.com
public-inbox-index ffmpegdev
Example config snippet for mirrors.
AGPL code for this site: git clone https://public-inbox.org/public-inbox.git