summaryrefslogtreecommitdiff
path: root/hw/kdrive/src/kdrive.c
diff options
context:
space:
mode:
authorAdam Jackson <ajax@redhat.com>2017-03-24 15:58:54 -0400
committerAdam Jackson <ajax@redhat.com>2017-05-03 16:00:54 -0400
commitc42311a9d7d2e5a67bdb7f4fa32032b4feba59b1 (patch)
tree3447c054e519f286b9edccf392d260572d959e72 /hw/kdrive/src/kdrive.c
parentc0375dced38674ed98562529530d89ff02c48100 (diff)
kdrive: Remove KdOsFuncs
Only the Init slot was used, and Xephyr can just as easily do that initialization directly. Reviewed-by: Eric Anholt <eric@anholt.net> Signed-off-by: Adam Jackson <ajax@redhat.com>
Diffstat (limited to 'hw/kdrive/src/kdrive.c')
-rw-r--r--hw/kdrive/src/kdrive.c50
1 files changed, 3 insertions, 47 deletions
diff --git a/hw/kdrive/src/kdrive.c b/hw/kdrive/src/kdrive.c
index a68a57072..8283b8e7d 100644
--- a/hw/kdrive/src/kdrive.c
+++ b/hw/kdrive/src/kdrive.c
@@ -90,13 +90,6 @@ const char *kdGlobalXkbOptions = NULL;
static Bool kdCaughtSignal = FALSE;
-/*
- * Carry arguments from InitOutput through driver initialization
- * to KdScreenInit
- */
-
-KdOsFuncs *kdOsFuncs;
-
void
KdDisableScreen(ScreenPtr pScreen)
{
@@ -162,11 +155,7 @@ static void
KdDisableScreens(void)
{
KdSuspend();
- if (kdEnabled) {
- if (kdOsFuncs->Disable)
- (*kdOsFuncs->Disable) ();
- kdEnabled = FALSE;
- }
+ kdEnabled = FALSE;
}
Bool
@@ -198,13 +187,6 @@ void
AbortDDX(enum ExitCode error)
{
KdDisableScreens();
- if (kdOsFuncs) {
- if (kdEnabled && kdOsFuncs->Disable)
- (*kdOsFuncs->Disable) ();
- if (kdOsFuncs->Fini)
- (*kdOsFuncs->Fini) ();
- KdDoSwitchCmd("stop");
- }
if (kdCaughtSignal)
OsAbort();
@@ -560,24 +542,6 @@ KdProcessArgument(int argc, char **argv, int i)
return 0;
}
-/*
- * These are getting tossed in here until I can think of where
- * they really belong
- */
-
-void
-KdOsInit(KdOsFuncs * pOsFuncs)
-{
- kdOsFuncs = pOsFuncs;
- if (pOsFuncs) {
- if (serverGeneration == 1) {
- KdDoSwitchCmd("start");
- if (pOsFuncs->Init)
- (*pOsFuncs->Init) ();
- }
- }
-}
-
static Bool
KdAllocatePrivates(ScreenPtr pScreen)
{
@@ -668,11 +632,7 @@ KdCloseScreen(ScreenPtr pScreen)
* Clean up OS when last card is closed
*/
if (card == kdCardInfo) {
- if (kdEnabled) {
- kdEnabled = FALSE;
- if (kdOsFuncs->Disable)
- (*kdOsFuncs->Disable) ();
- }
+ kdEnabled = FALSE;
}
}
@@ -923,11 +883,7 @@ KdScreenInit(ScreenPtr pScreen, int argc, char **argv)
/*
* Enable the hardware
*/
- if (!kdEnabled) {
- kdEnabled = TRUE;
- if (kdOsFuncs->Enable)
- (*kdOsFuncs->Enable) ();
- }
+ kdEnabled = TRUE;
if (screen->mynum == card->selected) {
if (card->cfuncs->preserve)