/linux-6.6.21/include/linux/ |
D | gameport.h | 16 struct gameport { struct 26 void (*trigger)(struct gameport *); argument 27 unsigned char (*read)(struct gameport *); argument 28 int (*cooked_read)(struct gameport *, int *, int *); argument 29 int (*calibrate)(struct gameport *, int *, int *); argument 30 int (*open)(struct gameport *, int); argument 31 void (*close)(struct gameport *); argument 37 void (*poll_handler)(struct gameport *); argument 39 struct gameport *parent, *child; argument 48 #define to_gameport_port(d) container_of(d, struct gameport, dev) argument [all …]
|
/linux-6.6.21/drivers/input/gameport/ |
D | gameport.c | 43 static void gameport_add_port(struct gameport *gameport); 45 static void gameport_reconnect_port(struct gameport *gameport); 46 static void gameport_disconnect_port(struct gameport *gameport); 77 static int gameport_measure_speed(struct gameport *gameport) in gameport_measure_speed() argument 83 if (gameport_open(gameport, NULL, GAMEPORT_MODE_RAW)) in gameport_measure_speed() 92 gameport_read(gameport); in gameport_measure_speed() 102 gameport_close(gameport); in gameport_measure_speed() 109 static int old_gameport_measure_speed(struct gameport *gameport) in old_gameport_measure_speed() argument 116 if (gameport_open(gameport, NULL, GAMEPORT_MODE_RAW)) in old_gameport_measure_speed() 124 for (t = 0; t < 50; t++) gameport_read(gameport); in old_gameport_measure_speed() [all …]
|
D | fm801-gp.c | 24 struct gameport *gameport; member 29 static int fm801_gp_cooked_read(struct gameport *gameport, int *axes, int *buttons) in fm801_gp_cooked_read() argument 33 w = inw(gameport->io + 2); in fm801_gp_cooked_read() 36 w = inw(gameport->io + 4); in fm801_gp_cooked_read() 38 w = inw(gameport->io + 6); in fm801_gp_cooked_read() 41 w = inw(gameport->io + 8); in fm801_gp_cooked_read() 43 outw(0xff, gameport->io); /* reset */ in fm801_gp_cooked_read() 49 static int fm801_gp_open(struct gameport *gameport, int mode) in fm801_gp_open() argument 68 struct gameport *port; in fm801_gp_probe() 92 gp->gameport = port; in fm801_gp_probe() [all …]
|
D | lightning.c | 35 struct gameport *gameport; member 57 static int l4_cooked_read(struct gameport *gameport, int *axes, int *buttons) in l4_cooked_read() argument 59 struct l4 *l4 = gameport->port_data; in l4_cooked_read() 90 static int l4_open(struct gameport *gameport, int mode) in l4_open() argument 92 struct l4 *l4 = gameport->port_data; in l4_open() 177 static int l4_calibrate(struct gameport *gameport, int *axes, int *max) in l4_calibrate() argument 181 struct l4 *l4 = gameport->port_data; in l4_calibrate() 203 struct gameport *port; in l4_create_ports() 211 if (!(l4->gameport = port = gameport_allocate_port())) { in l4_create_ports() 214 gameport_free_port(l4->gameport); in l4_create_ports() [all …]
|
D | Kconfig | 9 Gameport support is for the standard 15-pin PC gameport. If you 10 have a joystick, gamepad, gameport card, a soundcard with a gameport 11 or anything else that uses the gameport, say Y or M here and also to 15 S3 SonicVibes, Trident 4DWave, SiS7018, and ALi 5451 gameport 22 module will be called gameport. 27 tristate "Classic ISA and PnP gameport support" 30 Say Y here if you have an ISA or PnP gameport. 47 tristate "SB Live and Audigy gameport support" 51 Audigy card and want to use its gameport. 57 tristate "ForteMedia FM801 gameport support" [all …]
|
D | emu10k1-gp.c | 24 struct gameport *gameport; member 43 struct gameport *port; in emu_probe() 62 emu->gameport = port; in emu_probe() 94 gameport_unregister_port(emu->gameport); in emu_remove()
|
D | ns558.c | 33 struct gameport *gameport; member 50 struct gameport *port; in ns558_isa_probe() 135 ns558->gameport = port; in ns558_isa_probe() 182 struct gameport *port; in ns558_pnp_probe() 207 ns558->gameport = port; in ns558_pnp_probe() 258 gameport_unregister_port(ns558->gameport); in ns558_exit()
|
/linux-6.6.21/drivers/input/joystick/ |
D | gf2k.c | 62 struct gameport *gameport; member 75 static int gf2k_read_packet(struct gameport *gameport, int length, char *data) in gf2k_read_packet() argument 82 t = gameport_time(gameport, GF2K_START); in gf2k_read_packet() 83 p = gameport_time(gameport, GF2K_STROBE); in gf2k_read_packet() 89 gameport_trigger(gameport); in gf2k_read_packet() 90 v = gameport_read(gameport); in gf2k_read_packet() 94 v = gameport_read(gameport); in gf2k_read_packet() 111 static void gf2k_trigger_seq(struct gameport *gameport, short *seq) in gf2k_trigger_seq() argument 121 gameport_trigger(gameport); in gf2k_trigger_seq() 122 t = gameport_time(gameport, GF2K_TIMEOUT * 1000); in gf2k_trigger_seq() [all …]
|
D | a3d.c | 36 struct gameport *gameport; member 37 struct gameport *adc; 52 static int a3d_read_packet(struct gameport *gameport, int length, char *data) in a3d_read_packet() argument 60 t = gameport_time(gameport, A3D_MAX_START); in a3d_read_packet() 61 s = gameport_time(gameport, A3D_MAX_STROBE); in a3d_read_packet() 64 gameport_trigger(gameport); in a3d_read_packet() 65 v = gameport_read(gameport); in a3d_read_packet() 69 u = v; v = gameport_read(gameport); in a3d_read_packet() 159 static void a3d_poll(struct gameport *gameport) in a3d_poll() argument 161 struct a3d *a3d = gameport_get_drvdata(gameport); in a3d_poll() [all …]
|
D | guillemot.c | 48 struct gameport *gameport; member 65 static int guillemot_read_packet(struct gameport *gameport, u8 *data) in guillemot_read_packet() argument 76 t = gameport_time(gameport, GUILLEMOT_MAX_START); in guillemot_read_packet() 77 s = gameport_time(gameport, GUILLEMOT_MAX_STROBE); in guillemot_read_packet() 80 gameport_trigger(gameport); in guillemot_read_packet() 81 v = gameport_read(gameport); in guillemot_read_packet() 85 u = v; v = gameport_read(gameport); in guillemot_read_packet() 102 static void guillemot_poll(struct gameport *gameport) in guillemot_poll() argument 104 struct guillemot *guillemot = gameport_get_drvdata(gameport); in guillemot_poll() 111 if (guillemot_read_packet(guillemot->gameport, data) != GUILLEMOT_MAX_LENGTH * 8 || in guillemot_poll() [all …]
|
D | grip_mp.c | 52 struct gameport *gameport; member 134 static inline int poll_until(u8 onbits, u8 offbits, int u_sec, struct gameport* gp, u8 *data) in poll_until() 164 static int mp_io(struct gameport* gameport, int sendflags, int sendcode, u32 *packet) in mp_io() argument 176 raw_data = gameport_read(gameport); in mp_io() 181 raw_data = gameport_read(gameport); in mp_io() 186 raw_data = gameport_read(gameport); in mp_io() 191 gameport_trigger(gameport); in mp_io() 193 if (!poll_until(0x10, 0, 308, gameport, &raw_data)) in mp_io() 217 if (!poll_until(0, 0x10, 77, gameport, &raw_data)) in mp_io() 225 if (!poll_until(0x10, 0, 77, gameport, &raw_data)) in mp_io() [all …]
|
D | interact.c | 35 struct gameport *gameport; member 72 static int interact_read_packet(struct gameport *gameport, int length, u32 *data) in interact_read_packet() argument 81 t = gameport_time(gameport, INTERACT_MAX_START); in interact_read_packet() 82 s = gameport_time(gameport, INTERACT_MAX_STROBE); in interact_read_packet() 85 gameport_trigger(gameport); in interact_read_packet() 86 v = gameport_read(gameport); in interact_read_packet() 90 u = v; v = gameport_read(gameport); in interact_read_packet() 109 static void interact_poll(struct gameport *gameport) in interact_poll() argument 111 struct interact *interact = gameport_get_drvdata(gameport); in interact_poll() 118 if (interact_read_packet(interact->gameport, interact->length, data) < interact->length) { in interact_poll() [all …]
|
D | cobra.c | 29 struct gameport *gameport; member 37 static unsigned char cobra_read_packet(struct gameport *gameport, unsigned int *data) in cobra_read_packet() argument 45 int strobe = gameport_time(gameport, COBRA_MAX_STROBE); in cobra_read_packet() 54 u = gameport_read(gameport); in cobra_read_packet() 58 v = gameport_read(gameport); in cobra_read_packet() 91 static void cobra_poll(struct gameport *gameport) in cobra_poll() argument 93 struct cobra *cobra = gameport_get_drvdata(gameport); in cobra_poll() 100 if ((r = cobra_read_packet(gameport, data)) != cobra->exists) { in cobra_poll() 125 gameport_start_polling(cobra->gameport); in cobra_open() 133 gameport_stop_polling(cobra->gameport); in cobra_close() [all …]
|
D | grip.c | 36 struct gameport *gameport; member 65 static int grip_gpp_read_packet(struct gameport *gameport, int shift, unsigned int *data) in grip_gpp_read_packet() argument 72 int strobe = gameport_time(gameport, GRIP_STROBE_GPP); in grip_gpp_read_packet() 80 v = gameport_read(gameport) >> shift; in grip_gpp_read_packet() 84 u = v; v = (gameport_read(gameport) >> shift) & 3; in grip_gpp_read_packet() 105 static int grip_xt_read_packet(struct gameport *gameport, int shift, unsigned int *data) in grip_xt_read_packet() argument 113 int strobe = gameport_time(gameport, GRIP_STROBE_XT); in grip_xt_read_packet() 121 v = w = (gameport_read(gameport) >> shift) & 3; in grip_xt_read_packet() 125 u = (gameport_read(gameport) >> shift) & 3; in grip_xt_read_packet() 163 static void grip_poll(struct gameport *gameport) in grip_poll() argument [all …]
|
D | sidewinder.c | 96 struct gameport *gameport; member 116 static int sw_read_packet(struct gameport *gameport, unsigned char *buf, int length, int id) in sw_read_packet() argument 123 …timeout = id ? gameport_time(gameport, SW_TIMEOUT * 1000) : 0; /* Set up global timeout for ID pac… in sw_read_packet() 124 kick = id ? gameport_time(gameport, SW_KICK) : 0; /* Set up kick timeout for ID packet */ in sw_read_packet() 125 start = gameport_time(gameport, SW_START); in sw_read_packet() 126 strobe = gameport_time(gameport, SW_STROBE); in sw_read_packet() 133 gameport_trigger(gameport); /* Trigger */ in sw_read_packet() 134 v = gameport_read(gameport); in sw_read_packet() 139 v = gameport_read(gameport); in sw_read_packet() 152 v = gameport_read(gameport); in sw_read_packet() [all …]
|
D | analog.c | 100 struct gameport *gameport; member 169 struct gameport *gameport = port->gameport; in analog_cooked_read() local 180 gameport_trigger(gameport); in analog_cooked_read() 193 this = gameport_read(gameport) & port->mask; in analog_cooked_read() 221 int strobe = gameport_time(port->gameport, ANALOG_SAITEK_TIME); in analog_button_read() 223 u = gameport_read(port->gameport); in analog_button_read() 237 gameport_trigger(port->gameport); in analog_button_read() 238 while (((u = gameport_read(port->gameport)) & port->mask) && t) t--; in analog_button_read() 249 static void analog_poll(struct gameport *gameport) in analog_poll() argument 251 struct analog_port *port = gameport_get_drvdata(gameport); in analog_poll() [all …]
|
D | joydump.c | 30 static int joydump_connect(struct gameport *gameport, struct gameport_driver *drv) in joydump_connect() argument 40 printk(KERN_INFO "joydump: | Dumping: %30s |\n", gameport->phys); in joydump_connect() 41 printk(KERN_INFO "joydump: | Speed: %28d kHz |\n", gameport->speed); in joydump_connect() 43 if (gameport_open(gameport, drv, GAMEPORT_MODE_RAW)) { in joydump_connect() 47 if (gameport_open(gameport, drv, GAMEPORT_MODE_COOKED)) { in joydump_connect() 54 gameport_cooked_read(gameport, axes, &buttons); in joydump_connect() 62 timeout = gameport_time(gameport, 10000); /* 10 ms */ in joydump_connect() 75 u = gameport_read(gameport); in joydump_connect() 81 gameport_trigger(gameport); in joydump_connect() 85 dump->data = gameport_read(gameport); in joydump_connect() [all …]
|
D | tmdc.c | 105 struct gameport *gameport; member 127 static int tmdc_read_packet(struct gameport *gameport, unsigned char data[2][TMDC_MAX_LENGTH]) in tmdc_read_packet() argument 133 p = gameport_time(gameport, TMDC_MAX_STROBE); in tmdc_read_packet() 136 t[k] = gameport_time(gameport, TMDC_MAX_START); in tmdc_read_packet() 141 gameport_trigger(gameport); in tmdc_read_packet() 143 w = gameport_read(gameport) >> 4; in tmdc_read_packet() 147 w = gameport_read(gameport) >> 4; in tmdc_read_packet() 220 static void tmdc_poll(struct gameport *gameport) in tmdc_poll() argument 223 struct tmdc *tmdc = gameport_get_drvdata(gameport); in tmdc_poll() 229 if ((r = tmdc_read_packet(tmdc->gameport, data)) != tmdc->exists) in tmdc_poll() [all …]
|
D | adi.c | 109 struct gameport *gameport; member 122 struct gameport *gameport = port->gameport; in adi_read_packet() local 129 t[i] = gameport_time(gameport, ADI_MAX_START); in adi_read_packet() 135 gameport_trigger(gameport); in adi_read_packet() 136 v = gameport_read(gameport); in adi_read_packet() 140 w = u ^ (v = x = gameport_read(gameport)); in adi_read_packet() 146 t[i] = gameport_time(gameport, ADI_MAX_STROBE); in adi_read_packet() 259 static void adi_poll(struct gameport *gameport) in adi_poll() argument 261 struct adi_port *port = gameport_get_drvdata(gameport); in adi_poll() 275 gameport_start_polling(port->gameport); in adi_open() [all …]
|
/linux-6.6.21/Documentation/input/ |
D | gameport-programming.rst | 2 Programming gameport drivers 5 A basic classic gameport 8 If the gameport doesn't provide more than the inb()/outb() functionality, 11 struct gameport gameport; 13 gameport.io = MY_IO_ADDRESS; 14 gameport_register_port(&gameport); 16 Make sure struct gameport is initialized to 0 in all other fields. The 17 gameport generic code will take care of the rest. 27 If your hardware supports a gameport address that is not mapped to ISA io 31 gameport. Although only one ioport is really used, the gameport usually [all …]
|
/linux-6.6.21/sound/pci/au88x0/ |
D | au88x0_game.c | 30 static unsigned char vortex_game_read(struct gameport *gameport) in vortex_game_read() argument 32 vortex_t *vortex = gameport_get_port_data(gameport); in vortex_game_read() 36 static void vortex_game_trigger(struct gameport *gameport) in vortex_game_trigger() argument 38 vortex_t *vortex = gameport_get_port_data(gameport); in vortex_game_trigger() 43 vortex_game_cooked_read(struct gameport *gameport, int *axes, int *buttons) in vortex_game_cooked_read() argument 45 vortex_t *vortex = gameport_get_port_data(gameport); in vortex_game_cooked_read() 59 static int vortex_game_open(struct gameport *gameport, int mode) in vortex_game_open() argument 61 vortex_t *vortex = gameport_get_port_data(gameport); in vortex_game_open() 84 struct gameport *gp; in vortex_gameport_register() 86 vortex->gameport = gp = gameport_allocate_port(); in vortex_gameport_register() [all …]
|
/linux-6.6.21/Documentation/sound/cards/ |
D | joystick.rst | 13 using a joystick with the ALSA driver. For the details of gameport 19 built-in gameport support. Hence, when the ALSA PCI driver is built 21 gameport support on that card will be (silently) disabled. 66 The following drivers don't support gameport natively, but there are 67 additional modules. Load the corresponding module to add the gameport 79 built-in gameport support. 81 As mentioned above, ALSA PCI drivers have the built-in gameport 89 ALSA ISA drivers don't have the built-in gameport support.
|
/linux-6.6.21/sound/isa/ |
D | cmi8328.c | 47 static bool gameport[CMI8328_MAX] = {[0 ... (CMI8328_MAX-1)] = true}; variable 69 module_param_array(gameport, bool, NULL, 0444); 70 MODULE_PARM_DESC(gameport, "Enable gameport."); 80 struct gameport *gameport; member 376 if (!gameport[ndev]) in snd_cmi8328_probe() 383 struct gameport *gp = cmi->gameport = gameport_allocate_port(); in snd_cmi8328_probe() 384 if (cmi->gameport) { in snd_cmi8328_probe() 405 if (cmi->gameport) in snd_cmi8328_remove() 406 gameport_unregister_port(cmi->gameport); in snd_cmi8328_remove()
|
/linux-6.6.21/sound/pci/ymfpci/ |
D | ymfpci.c | 64 struct gameport *gp; in snd_ymfpci_create_gameport() 119 chip->gameport = gp = gameport_allocate_port(); in snd_ymfpci_create_gameport() 138 gameport_register_port(chip->gameport); in snd_ymfpci_create_gameport() 145 if (chip->gameport) { in snd_ymfpci_free_gameport() 146 gameport_unregister_port(chip->gameport); in snd_ymfpci_free_gameport() 147 chip->gameport = NULL; in snd_ymfpci_free_gameport()
|
/linux-6.6.21/sound/pci/ |
D | als4000.c | 100 struct gameport *gameport; member 740 struct gameport *gp; in snd_als4000_create_gameport() 765 acard->gameport = gp = gameport_allocate_port(); in snd_als4000_create_gameport() 779 gameport_register_port(acard->gameport); in snd_als4000_create_gameport() 786 if (acard->gameport) { in snd_als4000_free_gameport() 787 gameport_unregister_port(acard->gameport); in snd_als4000_free_gameport() 788 acard->gameport = NULL; in snd_als4000_free_gameport() 963 if (acard->gameport) in snd_als4000_resume()
|