Module Name: src
Committed By: riastradh
Date: Sun Dec 19 10:37:09 UTC 2021
Modified Files:
src/sys/external/bsd/drm2/pci: drm_pci.c
Log Message:
delete unused drm_pci_set_unique (entire ioctl removed)
drm/drm_agpsupport.h for drm_agp_init
Author: Maya Rashish <[email protected]>
To generate a diff of this commit:
cvs rdiff -u -r1.41 -r1.42 src/sys/external/bsd/drm2/pci/drm_pci.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/external/bsd/drm2/pci/drm_pci.c
diff -u src/sys/external/bsd/drm2/pci/drm_pci.c:1.41 src/sys/external/bsd/drm2/pci/drm_pci.c:1.42
--- src/sys/external/bsd/drm2/pci/drm_pci.c:1.41 Sun Dec 19 10:33:00 2021
+++ src/sys/external/bsd/drm2/pci/drm_pci.c Sun Dec 19 10:37:09 2021
@@ -1,4 +1,4 @@
-/* $NetBSD: drm_pci.c,v 1.41 2021/12/19 10:33:00 riastradh Exp $ */
+/* $NetBSD: drm_pci.c,v 1.42 2021/12/19 10:37:09 riastradh Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: drm_pci.c,v 1.41 2021/12/19 10:33:00 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: drm_pci.c,v 1.42 2021/12/19 10:37:09 riastradh Exp $");
#include <sys/types.h>
#include <sys/errno.h>
@@ -38,6 +38,7 @@ __KERNEL_RCSID(0, "$NetBSD: drm_pci.c,v
#include <dev/pci/pcivar.h>
+#include <drm/drm_agpsupport.h>
#include <drm/drm_device.h>
#include <drm/drm_drv.h>
#include <drm/drm_legacy.h>
@@ -271,35 +272,3 @@ drm_pci_set_busid(struct drm_device *dev
return 0;
}
-
-int
-drm_pci_set_unique(struct drm_device *dev, struct drm_master *master,
- struct drm_unique *unique)
-{
- char kbuf[64], ubuf[64];
- int ret;
-
- /* Reject excessively long unique strings. */
- if (unique->unique_len > sizeof(ubuf) - 1)
- return -EINVAL;
-
- /* Copy in the alleged unique string, NUL-terminated. */
- ret = -copyin(unique->unique, ubuf, unique->unique_len);
- if (ret)
- return ret;
- ubuf[unique->unique_len] = '\0';
-
- /* Make sure it matches what we expect. */
- snprintf(kbuf, sizeof kbuf, "PCI:%d:%ld:%ld", dev->pdev->bus->number,
- (long)PCI_SLOT(dev->pdev->devfn),
- (long)PCI_FUNC(dev->pdev->devfn));
- if (strncmp(kbuf, ubuf, sizeof(kbuf)) != 0)
- return -EINVAL;
-
- /* Remember it. */
- master->unique = kstrdup(ubuf, GFP_KERNEL);
- master->unique_len = strlen(master->unique);
-
- /* Success! */
- return 0;
-}