Skip to content

Commit 5a96c0b

Browse files
committed
Merge tag 'tty-5.5-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Pull tty/serial fixes from Greg KH: "Here are two tty/serial driver fixes for 5.5-rc6. The first fixes a much much reported issue with a previous tty port link patch that is in your tree, and the second fixes a problem where the serdev driver would claim ACPI devices that it shouldn't be claiming. Both have been in linux-next for a while with no reported issues" * tag 'tty-5.5-rc6' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: serdev: Don't claim unsupported ACPI serial devices tty: always relink the port
2 parents 4e4cd21 + c5ee0b3 commit 5a96c0b

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

drivers/tty/serdev/core.c

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -663,6 +663,12 @@ static acpi_status acpi_serdev_register_device(struct serdev_controller *ctrl,
663663
return AE_OK;
664664
}
665665

666+
static const struct acpi_device_id serdev_acpi_devices_blacklist[] = {
667+
{ "INT3511", 0 },
668+
{ "INT3512", 0 },
669+
{ },
670+
};
671+
666672
static acpi_status acpi_serdev_add_device(acpi_handle handle, u32 level,
667673
void *data, void **return_value)
668674
{
@@ -675,6 +681,10 @@ static acpi_status acpi_serdev_add_device(acpi_handle handle, u32 level,
675681
if (acpi_device_enumerated(adev))
676682
return AE_OK;
677683

684+
/* Skip if black listed */
685+
if (!acpi_match_device_ids(adev, serdev_acpi_devices_blacklist))
686+
return AE_OK;
687+
678688
if (acpi_serdev_check_resources(ctrl, adev))
679689
return AE_OK;
680690

drivers/tty/tty_port.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,8 +89,7 @@ void tty_port_link_device(struct tty_port *port,
8989
{
9090
if (WARN_ON(index >= driver->num))
9191
return;
92-
if (!driver->ports[index])
93-
driver->ports[index] = port;
92+
driver->ports[index] = port;
9493
}
9594
EXPORT_SYMBOL_GPL(tty_port_link_device);
9695

0 commit comments

Comments
 (0)