This is in preparation for the later patches which do away with struct irctl entirely.
Showing the changes to include/media/lirc_dev.h (1 of 5 files). Show all
Unified · Split
| @@ -111,54 +111,32 @@ static inline unsigned int lirc_buffer_write(struct lirc_buffer *buf, · 110 unmodified lines | ||
| 111 | 111 | } |
| 112 | 112 | |
| 113 | 113 | /** |
| 114 | − * struct lirc_driver - Defines the parameters on a LIRC driver | |
| 115 | − * | |
| 116 | − * @name: this string will be used for logs | |
| 117 | − * | |
| 118 | − * @minor: the minor device (/dev/lircX) number for a registered | |
| 119 | − * driver. | |
| 120 | − * | |
| 121 | − * @code_length: length of the remote control key code expressed in bits. | |
| 114 | + * struct lirc_dev - represents a LIRC device | |
| 122 | 115 | * |
| 116 | + * @name: used for logging | |
| 117 | + * @minor: the minor device (/dev/lircX) number for the device | |
| 118 | + * @code_length: length of a remote control key code expressed in bits | |
| 123 | 119 | * @features: lirc compatible hardware features, like LIRC_MODE_RAW, |
| 124 | 120 | * LIRC_CAN\_\*, as defined at include/media/lirc.h. |
| 125 | − * | |
| 126 | 121 | * @buffer_size: Number of FIFO buffers with @chunk_size size. |
| 127 | 122 | * Only used if @rbuf is NULL. |
| 128 | − * | |
| 129 | 123 | * @chunk_size: Size of each FIFO buffer. |
| 130 | 124 | * Only used if @rbuf is NULL. |
| 131 | − * | |
| 132 | − * @data: it may point to any driver data and this pointer will | |
| 133 | − * be passed to all callback functions. | |
| 134 | − * | |
| 125 | + * @data: private per-driver data | |
| 135 | 126 | * @min_timeout: Minimum timeout for record. Valid only if |
| 136 | 127 | * LIRC_CAN_SET_REC_TIMEOUT is defined. |
| 137 | − * | |
| 138 | 128 | * @max_timeout: Maximum timeout for record. Valid only if |
| 139 | 129 | * LIRC_CAN_SET_REC_TIMEOUT is defined. |
| 140 | − * | |
| 141 | 130 | * @rbuf: if not NULL, it will be used as a read buffer, you will |
| 142 | 131 | * have to write to the buffer by other means, like irq's |
| 143 | 132 | * (see also lirc_serial.c). |
| 144 | − * | |
| 145 | − * @rdev: Pointed to struct rc_dev associated with the LIRC | |
| 146 | − * device. | |
| 147 | − * | |
| 148 | − * @fops: file_operations for drivers which don't fit the current | |
| 149 | − * driver model. | |
| 150 | − * Some ioctl's can be directly handled by lirc_dev if the | |
| 151 | − * driver's ioctl function is NULL or if it returns | |
| 152 | − * -ENOIOCTLCMD (see also lirc_serial.c). | |
| 153 | − * | |
| 154 | − * @dev: pointer to the struct device associated with the LIRC | |
| 155 | − * device. | |
| 156 | − * | |
| 133 | + * @rdev: &struct rc_dev associated with the device | |
| 134 | + * @fops: &struct file_operations for the device | |
| 135 | + * @dev: &struct device assigned to the device | |
| 157 | 136 | * @owner: the module owning this struct |
| 158 | − * | |
| 159 | − * @irctl: the struct irctl for this LIRC device. | |
| 137 | + * @irctl: &struct irctl assigned to the device | |
| 160 | 138 | */ |
| 161 | −struct lirc_driver { | |
| 139 | +struct lirc_dev { | |
| 162 | 140 | char name[40]; |
| 163 | 141 | unsigned int minor; |
| 164 | 142 | __u32 code_length; |
| @@ -183,14 +161,14 @@ struct lirc_driver { · 18 unmodified lines | ||
| 183 | 161 | * returns negative value on error or zero |
| 184 | 162 | * contents of the structure pointed by p is copied |
| 185 | 163 | */ |
| 186 | −int lirc_register_driver(struct lirc_driver *d); | |
| 164 | +int lirc_register_device(struct lirc_dev *d); | |
| 187 | 165 | |
| 188 | −void lirc_unregister_driver(struct lirc_driver *d); | |
| 166 | +void lirc_unregister_device(struct lirc_dev *d); | |
| 189 | 167 | |
| 190 | 168 | /* Must be called in the open fop before lirc_get_pdata() can be used */ |
| 191 | 169 | void lirc_init_pdata(struct inode *inode, struct file *file); |
| 192 | 170 | |
| 193 | −/* Returns the private data stored in the lirc_driver | |
| 171 | +/* Returns the private data stored in the lirc_dev | |
| 194 | 172 | * associated with the given device file pointer. |
| 195 | 173 | */ |
| 196 | 174 | void *lirc_get_pdata(struct file *file); |