linux/drivers/input/joystick/gf2k.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
 *  Copyright (c) 1998-2001 Vojtech Pavlik
 */

/*
 * Genius Flight 2000 joystick driver for Linux
 */

#include <linux/delay.h>
#include <linux/kernel.h>
#include <linux/slab.h>
#include <linux/module.h>
#include <linux/input.h>
#include <linux/gameport.h>
#include <linux/jiffies.h>

#define DRIVER_DESC

MODULE_AUTHOR();
MODULE_DESCRIPTION();
MODULE_LICENSE();

#define GF2K_START
#define GF2K_STROBE
#define GF2K_TIMEOUT
#define GF2K_LENGTH

/*
 * Genius joystick ids ...
 */

#define GF2K_ID_G09
#define GF2K_ID_F30D
#define GF2K_ID_F30
#define GF2K_ID_F31D
#define GF2K_ID_F305
#define GF2K_ID_F23P
#define GF2K_ID_F31
#define GF2K_ID_MAX

static char gf2k_length[] =;
static char gf2k_hat_to_axis[][2] =;

static char *gf2k_names[] =;
static unsigned char gf2k_hats[] =;
static unsigned char gf2k_axes[] =;
static unsigned char gf2k_joys[] =;
static unsigned char gf2k_pads[] =;
static unsigned char gf2k_lens[] =;

static unsigned char gf2k_abs[] =;
static short gf2k_btn_joy[] =;
static short gf2k_btn_pad[] =;


static short gf2k_seq_reset[] =;
static short gf2k_seq_digital[] =;

struct gf2k {};

/*
 * gf2k_read_packet() reads a Genius Flight2000 packet.
 */

static int gf2k_read_packet(struct gameport *gameport, int length, char *data)
{}

/*
 * gf2k_trigger_seq() initializes a Genius Flight2000 joystick
 * into digital mode.
 */

static void gf2k_trigger_seq(struct gameport *gameport, short *seq)
{}

/*
 * js_sw_get_bits() composes bits from the triplet buffer into a __u64.
 * Parameter 'pos' is bit number inside packet where to start at, 'num' is number
 * of bits to be read, 'shift' is offset in the resulting __u64 to start at, bits
 * is number of bits per triplet.
 */

#define GB(p,n,s)

static int gf2k_get_bits(unsigned char *buf, int pos, int num, int shift)
{}

static void gf2k_read(struct gf2k *gf2k, unsigned char *data)
{}

/*
 * gf2k_poll() reads and analyzes Genius joystick data.
 */

static void gf2k_poll(struct gameport *gameport)
{}

static int gf2k_open(struct input_dev *dev)
{}

static void gf2k_close(struct input_dev *dev)
{}

/*
 * gf2k_connect() probes for Genius id joysticks.
 */

static int gf2k_connect(struct gameport *gameport, struct gameport_driver *drv)
{}

static void gf2k_disconnect(struct gameport *gameport)
{}

static struct gameport_driver gf2k_drv =;

module_gameport_driver();