@@ -29,9 +29,12 @@
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
+
#include <errno.h>
#include <stdlib.h>
#include <string.h>
+
+#include "libdrm.h"
#include "internal.h"
int kms_create(int fd, struct kms_driver **out)
@@ -190,7 +190,7 @@ dumb_bo_destroy(struct kms_bo *_bo)
return 0;
}
-int
+drm_private int
dumb_create(int fd, struct kms_driver **out)
{
struct kms_driver *kms;
@@ -185,7 +185,7 @@ exynos_bo_destroy(struct kms_bo *_bo)
return 0;
}
-int
+drm_private int
exynos_create(int fd, struct kms_driver **out)
{
struct kms_driver *kms;
@@ -216,7 +216,7 @@ intel_bo_destroy(struct kms_bo *_bo)
return 0;
}
-int
+drm_private int
intel_create(int fd, struct kms_driver **out)
{
struct kms_driver *kms;
@@ -29,6 +29,11 @@
#ifndef INTERNAL_H_
#define INTERNAL_H_
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include "libdrm.h"
#include "libkms.h"
struct kms_driver
@@ -62,18 +67,18 @@ struct kms_bo
unsigned handle;
};
-int linux_create(int fd, struct kms_driver **out);
+drm_private int linux_create(int fd, struct kms_driver **out);
-int vmwgfx_create(int fd, struct kms_driver **out);
+drm_private int vmwgfx_create(int fd, struct kms_driver **out);
-int intel_create(int fd, struct kms_driver **out);
+drm_private int intel_create(int fd, struct kms_driver **out);
-int dumb_create(int fd, struct kms_driver **out);
+drm_private int dumb_create(int fd, struct kms_driver **out);
-int nouveau_create(int fd, struct kms_driver **out);
+drm_private int nouveau_create(int fd, struct kms_driver **out);
-int radeon_create(int fd, struct kms_driver **out);
+drm_private int radeon_create(int fd, struct kms_driver **out);
-int exynos_create(int fd, struct kms_driver **out);
+drm_private int exynos_create(int fd, struct kms_driver **out);
#endif
@@ -39,9 +39,9 @@
#include <xf86drm.h>
#include <string.h>
#include <unistd.h>
-
#include <sys/stat.h>
+#include "libdrm.h"
#include "internal.h"
#define PATH_SIZE 512
@@ -225,7 +225,7 @@ linux_from_udev(int fd, struct kms_driver **out)
}
#endif
-int
+drm_private int
linux_create(int fd, struct kms_driver **out)
{
if (!dumb_create(fd, out))
@@ -198,7 +198,7 @@ nouveau_bo_destroy(struct kms_bo *_bo)
return 0;
}
-int
+drm_private int
nouveau_create(int fd, struct kms_driver **out)
{
struct kms_driver *kms;
@@ -219,7 +219,7 @@ radeon_bo_destroy(struct kms_bo *_bo)
return 0;
}
-int
+drm_private int
radeon_create(int fd, struct kms_driver **out)
{
struct kms_driver *kms;
@@ -185,7 +185,7 @@ vmwgfx_bo_destroy(struct kms_bo *_bo)
return 0;
}
-int
+drm_private int
vmwgfx_create(int fd, struct kms_driver **out)
{
struct kms_driver *kms;
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com> --- libkms/api.c | 3 +++ libkms/dumb.c | 2 +- libkms/exynos.c | 2 +- libkms/intel.c | 2 +- libkms/internal.h | 19 ++++++++++++------- libkms/linux.c | 4 ++-- libkms/nouveau.c | 2 +- libkms/radeon.c | 2 +- libkms/vmwgfx.c | 2 +- 9 files changed, 23 insertions(+), 15 deletions(-)