Lines Matching refs:command
109 static int ps2_adjust_timeout(struct ps2dev *ps2dev, int command, int timeout) in ps2_adjust_timeout() argument
111 switch (command) { in ps2_adjust_timeout()
164 int ps2_command(struct ps2dev *ps2dev, unsigned char *param, int command) in ps2_command() argument
167 int send = (command >> 12) & 0xf; in ps2_command()
168 int receive = (command >> 8) & 0xf; in ps2_command()
185 ps2dev->flags = command == PS2_CMD_GETID ? PS2_FLAG_WAITID : 0; in ps2_command()
197 if (ps2_sendbyte(ps2dev, command & 0xff, in ps2_command()
198 command == PS2_CMD_RESET_BAT ? 1000 : 200)) in ps2_command()
208 timeout = msecs_to_jiffies(command == PS2_CMD_RESET_BAT ? 4000 : 500); in ps2_command()
215 timeout = ps2_adjust_timeout(ps2dev, command, timeout); in ps2_command()
224 if (ps2dev->cmdcnt && (command != PS2_CMD_RESET_BAT || ps2dev->cmdcnt != 1)) in ps2_command()