xserver-multidpi/hw/xfree86/os-support/bsd/bsd_kmod.c
Daniel Stone e03198972c Add Xtrans definitions (FONT_t, TRANS_CLIENT) to clean up warnings.
Add XSERV_t, TRANS_SERVER, TRANS_REOPEN to quash warnings.
Add #include <dix-config.h> or <xorg-config.h>, as appropriate, to all
    source files in the xserver/xorg tree, predicated on defines of
    HAVE_{DIX,XORG}_CONFIG_H. Change all Xfont includes to
    <X11/fonts/foo.h>.
2005-07-03 07:02:09 +00:00

32 lines
636 B
C

/* $XFree86$ */
#ifdef HAVE_XORG_CONFIG_H
#include <xorg-config.h>
#endif
#include <errno.h>
#include <fcntl.h>
#include <unistd.h>
#include <sys/param.h>
#include <sys/linker.h>
#include "xf86_OSproc.h"
#include "xf86_ansic.h"
/*
* Load a FreeBSD kernel module.
* This is used by the DRI/DRM to load a DRM kernel module when
* the X server starts. It could be used for other purposes in the future.
* Input:
* modName - name of the kernel module (Ex: "tdfx")
* Return:
* 0 for failure, 1 for success
*/
int xf86LoadKernelModule(const char *modName)
{
if (kldload(modName) != -1)
return 1;
else
return 0;
}