Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/bsd/drm2/drm Add a stub for drm_ioctl() so that...



details:   https://anonhg.NetBSD.org/src/rev/68c2ad1ea506
branches:  trunk
changeset: 966783:68c2ad1ea506
user:      christos <christos%NetBSD.org@localhost>
date:      Sat Nov 16 04:10:33 2019 +0000

description:
Add a stub for drm_ioctl() so that compat32 links with kernels without drmkms.

diffstat:

 sys/external/bsd/drm2/drm/drm_stub.c   |  41 ++++++++++++++++++++++++++++++++++
 sys/external/bsd/drm2/drm/files.drmkms |   3 +-
 2 files changed, 43 insertions(+), 1 deletions(-)

diffs (59 lines):

diff -r c53fa34ed249 -r 68c2ad1ea506 sys/external/bsd/drm2/drm/drm_stub.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/sys/external/bsd/drm2/drm/drm_stub.c      Sat Nov 16 04:10:33 2019 +0000
@@ -0,0 +1,41 @@
+/*     $NetBSD: drm_stub.c,v 1.1 2019/11/16 04:10:33 christos Exp $    */
+
+/*-
+ * Copyright (c) 2019 The NetBSD Foundation, Inc.
+ * All rights reserved.
+ *
+ * This code is derived from software contributed to The NetBSD Foundation
+ * by Christos Zoulas.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
+ * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+ * POSSIBILITY OF SUCH DAMAGE.
+ */
+#include <sys/cdefs.h>
+__KERNEL_RCSID(0, "$NetBSD: drm_stub.c,v 1.1 2019/11/16 04:10:33 christos Exp $");
+
+#include <sys/errno.h>
+
+int drm_ioctl(int, unsigned long, ...);
+
+int
+drm_ioctl(int fd, unsigned long cmd, ...) {
+       return ENOSYS;
+}
diff -r c53fa34ed249 -r 68c2ad1ea506 sys/external/bsd/drm2/drm/files.drmkms
--- a/sys/external/bsd/drm2/drm/files.drmkms    Sat Nov 16 03:26:19 2019 +0000
+++ b/sys/external/bsd/drm2/drm/files.drmkms    Sat Nov 16 04:10:33 2019 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.drmkms,v 1.30 2018/08/28 03:41:39 riastradh Exp $
+#      $NetBSD: files.drmkms,v 1.31 2019/11/16 04:10:33 christos Exp $
 
 include "external/bsd/drm2/linux/files.drmkms_linux"
 
@@ -100,3 +100,4 @@
 file   external/bsd/drm2/dist/drm/drm_trace_points.c   drmkms
 file   external/bsd/drm2/drm/drm_vm.c  drmkms
 file   external/bsd/drm2/drm/drm_vma_manager.c drmkms
+file   external/bsd/drm2/drm/drm_stub.c        !drmkms



Home | Main Index | Thread Index | Old Index