Browse Source

Use proper locks terminology.

Georgi Chorbadzhiyski 9 years ago
parent
commit
3adee6c91b
4 changed files with 7 additions and 7 deletions
  1. 1
    1
      ChangeLog
  2. 4
    4
      cmd.c
  3. 1
    1
      data.h
  4. 1
    1
      videohubctrl.c

+ 1
- 1
ChangeLog View File

@@ -3,7 +3,7 @@ xxxx-xx-xx : Version 0.2 - dev
3 3
  * Fix port routing. Previously it was reversed and incorrect.
4 4
  * Fix command parsing of multiple commands comming in one packet.
5 5
  * Add -m / --monitor parameter for live configuration monitoring.
6
- * Add support for reporting exclusive and non-exclusive locks.
6
+ * Add support for reporting own locks and other's locks.
7 7
 
8 8
 2014-11-26 : Version 0.1
9 9
  * Initial vesion with support for showing Videohub configuration

+ 4
- 4
cmd.c View File

@@ -258,14 +258,14 @@ bool parse_command(struct videohub_data *data, char *cmd) {
258 258
 
259 259
 		case CMD_VIDEO_OUTPUT_LOCKS:
260 260
 			if (valid_slot) {
261
-				// L is exclusive lock     - can be set only via USB
262
-				// O is non-exclusive lock - can be set via network
261
+				// L is lock owned by somebody else (set from other IP address)
262
+				// O is lock owned by us (set from our IP address)
263 263
 				if (slot_data[0] == 'L' || slot_data[0] == 'O') {
264 264
 					data->outputs[slot_pos].locked = true;
265 265
 					if (slot_data[0] == 'L')
266
-						data->outputs[slot_pos].locked_exclusive = true;
266
+						data->outputs[slot_pos].locked_other = true;
267 267
 					else
268
-						data->outputs[slot_pos].locked_exclusive = false;
268
+						data->outputs[slot_pos].locked_other = false;
269 269
 				} else {
270 270
 					data->outputs[slot_pos].locked = false;
271 271
 				}

+ 1
- 1
data.h View File

@@ -40,7 +40,7 @@ struct output_desc {
40 40
 	char			name[MAX_NAME_LEN];
41 41
 	unsigned int	routed_to;
42 42
 	bool			locked;
43
-	bool			locked_exclusive;
43
+	bool			locked_other;
44 44
 };
45 45
 
46 46
 struct videohub_data {

+ 1
- 1
videohubctrl.c View File

@@ -141,7 +141,7 @@ static void print_device_settings(struct videohub_data *d) {
141 141
 	for(i = 0; i < d->device.num_video_inputs; i++) {
142 142
 		printf("| %2d | %c | %-27s | %-27s |\n",
143 143
 			i + 1,
144
-			d->outputs[i].locked ? (d->outputs[i].locked_exclusive ? 'L' : 'O') : ' ',
144
+			d->outputs[i].locked ? (d->outputs[i].locked_other ? 'L' : 'O') : ' ',
145 145
 			d->inputs[d->outputs[i].routed_to].name,
146 146
 			d->outputs[i].name
147 147
 		);

Loading…
Cancel
Save