Message ID | 20240822091117.1760423-15-portia.stephens@canonical.com |
---|---|
State | New |
Headers | show
Return-Path: <kernel-team-bounces@lists.ubuntu.com> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=185.125.189.65; helo=lists.ubuntu.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=patchwork.ozlabs.org) Received: from lists.ubuntu.com (lists.ubuntu.com [185.125.189.65]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4WqHXX5Lrgz1ybW for <incoming@patchwork.ozlabs.org>; Thu, 22 Aug 2024 19:12:28 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=lists.ubuntu.com) by lists.ubuntu.com with esmtp (Exim 4.86_2) (envelope-from <kernel-team-bounces@lists.ubuntu.com>) id 1sh3rj-0002uY-Lf; Thu, 22 Aug 2024 09:12:23 +0000 Received: from smtp-relay-internal-0.internal ([10.131.114.225] helo=smtp-relay-internal-0.canonical.com) by lists.ubuntu.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from <portia.stephens@canonical.com>) id 1sh3rh-0002nd-L3 for kernel-team@lists.ubuntu.com; Thu, 22 Aug 2024 09:12:21 +0000 Received: from mail-oa1-f71.google.com (mail-oa1-f71.google.com [209.85.160.71]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-0.canonical.com (Postfix) with ESMTPS id 796B83F12E for <kernel-team@lists.ubuntu.com>; Thu, 22 Aug 2024 09:12:21 +0000 (UTC) Received: by mail-oa1-f71.google.com with SMTP id 586e51a60fabf-2701eeb69f4so509543fac.3 for <kernel-team@lists.ubuntu.com>; Thu, 22 Aug 2024 02:12:21 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1724317940; x=1724922740; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=gNFkCXacIUh/+8/dZu2Ck1s3NR3JPoQH/EjsiZQupNw=; b=LbFBzie3X5jRSRW1brEYokkWuQZGjabMM1pFY0wrWt8xbP5vmey/ZPMtS3xZKvK6wr daGMIofA4+yAfGcLttGKzyLsHuSN1ycWRmQb44pirDqUGSxKz/r5dAZF0zhemp8PZsC2 L4gXdQl6EK89tOkBRCDVp6jKDpUz/gcIBv6nuGz7J09s0qKSrbOwDH78lP8b2vHHxVXj jc9Sphw0bYZutPU9u2YXsLUphZclMllpCTWQU6apTy0yBw3MyQ4NeVsxlPNol59aYezb c0xFSwBYFAUTQCprkjO/EgjFF/EVnSaUPzAFOXVunT+7znTZNBwvM9C2+uOCpbiZfIkJ 3sBQ== X-Gm-Message-State: AOJu0YwwHI/OSKY8YwpkMHkPXqPjX9iFtSQh/wMKUo9EH4TWpArA4fK+ oG4qHm2+I/EY5LwH2jHw+3TD5+c7Y+f8a0ZzkGRwDdMHoq9Ox36WmVHLqjK0hdqPVuOQ/NZ23yk mgyt4XvdDRhWZHPJzlck9w+gWYWo+PuIvoiWCKWWgtxgSPdrawD1PR4MZEjYdszJMAvf2WB88VP wWhi6I/LeAyg== X-Received: by 2002:a05:6870:f218:b0:260:ffaf:8126 with SMTP id 586e51a60fabf-2737eec8b51mr5570085fac.9.1724317939748; Thu, 22 Aug 2024 02:12:19 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFp7aDqvN+VsxUWmjF+pbSBUUtpRY8yjpQmkUv+sQkFIrxYzvotgi1fFQmcMoj/7COpI0KJ4A== X-Received: by 2002:a05:6870:f218:b0:260:ffaf:8126 with SMTP id 586e51a60fabf-2737eec8b51mr5570074fac.9.1724317939438; Thu, 22 Aug 2024 02:12:19 -0700 (PDT) Received: from localhost ([159.196.41.205]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-714342731acsm944144b3a.88.2024.08.22.02.12.18 for <kernel-team@lists.ubuntu.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 22 Aug 2024 02:12:18 -0700 (PDT) From: Portia Stephens <portia.stephens@canonical.com> To: kernel-team@lists.ubuntu.com Subject: [SRU] [jammy:linux-xilinx-zynqmp 14/14] serial: fix TIOCSRS485 locking Date: Thu, 22 Aug 2024 19:11:17 +1000 Message-Id: <20240822091117.1760423-15-portia.stephens@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240822091117.1760423-1-portia.stephens@canonical.com> References: <20240822091117.1760423-1-portia.stephens@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions <kernel-team.lists.ubuntu.com> List-Unsubscribe: <https://lists.ubuntu.com/mailman/options/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe> List-Archive: <https://lists.ubuntu.com/archives/kernel-team> List-Post: <mailto:kernel-team@lists.ubuntu.com> List-Help: <mailto:kernel-team-request@lists.ubuntu.com?subject=help> List-Subscribe: <https://lists.ubuntu.com/mailman/listinfo/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" <kernel-team-bounces@lists.ubuntu.com> |
Series |
Backport ps uart RS485 driver
|
expand
|
diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c index 2170721186f6b..d90184953977c 100644 --- a/drivers/tty/serial/serial_core.c +++ b/drivers/tty/serial/serial_core.c @@ -1445,7 +1445,7 @@ uart_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg) goto out; /* rs485_config requires more locking than others */ - if (cmd == TIOCGRS485) + if (cmd == TIOCSRS485) down_write(&tty->termios_rwsem); mutex_lock(&port->mutex); @@ -1488,7 +1488,7 @@ uart_ioctl(struct tty_struct *tty, unsigned int cmd, unsigned long arg) } out_up: mutex_unlock(&port->mutex); - if (cmd == TIOCGRS485) + if (cmd == TIOCSRS485) up_write(&tty->termios_rwsem); out: return ret;