diff options
| -rw-r--r-- | arch/um/drivers/line.c | 6 | ||||
| -rw-r--r-- | arch/um/drivers/line.h | 1 |
2 files changed, 0 insertions, 7 deletions
diff --git a/arch/um/drivers/line.c b/arch/um/drivers/line.c index 95d5e7803bc7..555ccfc7300c 100644 --- a/arch/um/drivers/line.c +++ b/arch/um/drivers/line.c | |||
| @@ -382,8 +382,6 @@ int setup_one_line(struct line *lines, int n, char *init, | |||
| 382 | struct tty_driver *driver = line->driver->driver; | 382 | struct tty_driver *driver = line->driver->driver; |
| 383 | int err = -EINVAL; | 383 | int err = -EINVAL; |
| 384 | 384 | ||
| 385 | mutex_lock(&line->count_lock); | ||
| 386 | |||
| 387 | if (line->port.count) { | 385 | if (line->port.count) { |
| 388 | *error_out = "Device is already open"; | 386 | *error_out = "Device is already open"; |
| 389 | goto out; | 387 | goto out; |
| @@ -425,7 +423,6 @@ int setup_one_line(struct line *lines, int n, char *init, | |||
| 425 | } | 423 | } |
| 426 | } | 424 | } |
| 427 | out: | 425 | out: |
| 428 | mutex_unlock(&line->count_lock); | ||
| 429 | return err; | 426 | return err; |
| 430 | } | 427 | } |
| 431 | 428 | ||
| @@ -513,7 +510,6 @@ int line_get_config(char *name, struct line *lines, unsigned int num, char *str, | |||
| 513 | 510 | ||
| 514 | line = &lines[dev]; | 511 | line = &lines[dev]; |
| 515 | 512 | ||
| 516 | mutex_lock(&line->count_lock); | ||
| 517 | if (!line->valid) | 513 | if (!line->valid) |
| 518 | CONFIG_CHUNK(str, size, n, "none", 1); | 514 | CONFIG_CHUNK(str, size, n, "none", 1); |
| 519 | else { | 515 | else { |
| @@ -525,7 +521,6 @@ int line_get_config(char *name, struct line *lines, unsigned int num, char *str, | |||
| 525 | tty_kref_put(tty); | 521 | tty_kref_put(tty); |
| 526 | } | 522 | } |
| 527 | } | 523 | } |
| 528 | mutex_unlock(&line->count_lock); | ||
| 529 | 524 | ||
| 530 | return n; | 525 | return n; |
| 531 | } | 526 | } |
| @@ -578,7 +573,6 @@ int register_lines(struct line_driver *line_driver, | |||
| 578 | tty_port_init(&lines[i].port); | 573 | tty_port_init(&lines[i].port); |
| 579 | lines[i].port.ops = &line_port_ops; | 574 | lines[i].port.ops = &line_port_ops; |
| 580 | spin_lock_init(&lines[i].lock); | 575 | spin_lock_init(&lines[i].lock); |
| 581 | mutex_init(&lines[i].count_lock); | ||
| 582 | lines[i].driver = line_driver; | 576 | lines[i].driver = line_driver; |
| 583 | INIT_LIST_HEAD(&lines[i].chan_list); | 577 | INIT_LIST_HEAD(&lines[i].chan_list); |
| 584 | } | 578 | } |
diff --git a/arch/um/drivers/line.h b/arch/um/drivers/line.h index ad00f3e11ecc..bae95611e7ab 100644 --- a/arch/um/drivers/line.h +++ b/arch/um/drivers/line.h | |||
| @@ -33,7 +33,6 @@ struct line_driver { | |||
| 33 | 33 | ||
| 34 | struct line { | 34 | struct line { |
| 35 | struct tty_port port; | 35 | struct tty_port port; |
| 36 | struct mutex count_lock; | ||
| 37 | int valid; | 36 | int valid; |
| 38 | 37 | ||
| 39 | char *init_str; | 38 | char *init_str; |
