1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29
|
/* Copyright 2010 Stefan Tomanek <stefan.tomanek+th@wertarbyte.de>
* You have permission to copy, modify, and redistribute under the
* terms of the GPLv3 or any later version.
* For full license terms, see COPYING.
*/
#include "devtag.h"
#define TH_COMMAND_PARAM_LENGTH 256
enum command_type {
CMD_NOP,
CMD_ADD,
CMD_REMOVE,
CMD_QUIT,
CMD_DISABLE,
CMD_ENABLE,
CMD_PASSFD,
CMD_CLEARDEVS,
CMD_CHANGEMODE
};
struct command {
enum command_type type;
/* udev pathnames are long, but not that long */
char param[TH_COMMAND_PARAM_LENGTH];
int fd;
int exclusive;
char tag[TH_DEVICE_TAG_LENGTH];
};
|