summaryrefslogtreecommitdiff
path: root/graphics/libv4l/patches/patch-ad
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/libv4l/patches/patch-ad')
-rw-r--r--graphics/libv4l/patches/patch-ad42
1 files changed, 39 insertions, 3 deletions
diff --git a/graphics/libv4l/patches/patch-ad b/graphics/libv4l/patches/patch-ad
index 157bc7d70c4..62d5fb4ff38 100644
--- a/graphics/libv4l/patches/patch-ad
+++ b/graphics/libv4l/patches/patch-ad
@@ -1,7 +1,7 @@
-$NetBSD: patch-ad,v 1.2 2008/09/08 19:10:20 jmcneill Exp $
+$NetBSD: patch-ad,v 1.3 2008/09/13 17:59:27 jmcneill Exp $
---- libv4l2/libv4l2.c.orig 2008-09-08 14:41:10.000000000 -0400
-+++ libv4l2/libv4l2.c 2008-09-08 14:42:04.000000000 -0400
+--- libv4l2/libv4l2.c.orig 2008-09-03 06:23:46.000000000 -0400
++++ libv4l2/libv4l2.c 2008-09-13 13:50:47.000000000 -0400
@@ -59,7 +59,11 @@
#include <stdarg.h>
#include <stdio.h>
@@ -25,3 +25,39 @@ $NetBSD: patch-ad,v 1.2 2008/09/08 19:10:20 jmcneill Exp $
/* Note these flags are stored together with the flags passed to v4l2_fd_open()
in v4l2_dev_info's flags member, so care should be taken that the do not
use the same bits! */
+@@ -154,7 +162,7 @@
+ break;
+ }
+
+- devices[index].frame_pointers[i] = (void *)syscall(SYS_mmap2, NULL,
++ devices[index].frame_pointers[i] = mmap(NULL,
+ (size_t)buf.length, PROT_READ|PROT_WRITE, MAP_SHARED, devices[index].fd,
+ (__off_t)(buf.m.offset >> MMAP2_PAGE_SHIFT));
+ if (devices[index].frame_pointers[i] == MAP_FAILED) {
+@@ -871,7 +879,7 @@
+ but we need the buffer _now_ to write our converted data
+ to it! */
+ if (devices[index].convert_mmap_buf == MAP_FAILED) {
+- devices[index].convert_mmap_buf = (void *)syscall(SYS_mmap2,
++ devices[index].convert_mmap_buf = mmap(NULL,
+ (size_t)(
+ devices[index].no_frames *
+ V4L2_FRAME_BUF_SIZE),
+@@ -995,7 +1003,7 @@
+ return MAP_FAILED;
+ }
+
+- return (void *)syscall(SYS_mmap2, start, length, prot, flags, fd,
++ return mmap(start, length, prot, flags, fd,
+ (__off_t)(offset >> MMAP2_PAGE_SHIFT));
+ }
+
+@@ -1012,7 +1020,7 @@
+ }
+
+ if (devices[index].convert_mmap_buf == MAP_FAILED) {
+- devices[index].convert_mmap_buf = (void *)syscall(SYS_mmap2, NULL,
++ devices[index].convert_mmap_buf = mmap(NULL,
+ (size_t)(
+ devices[index].no_frames *
+ V4L2_FRAME_BUF_SIZE),