From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758282AbdLRLAk (ORCPT ); Mon, 18 Dec 2017 06:00:40 -0500 Received: from mail-lf0-f66.google.com ([209.85.215.66]:46204 "EHLO mail-lf0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756960AbdLRLAi (ORCPT ); Mon, 18 Dec 2017 06:00:38 -0500 X-Google-Smtp-Source: ACJfBovbEqoEpi4uQFXtIhGLFN/aQZDsjgiytYGs08Vm8zN6X9UJKDziqbgHRBwUmNOowZ9cPe3TgQ== From: Johan Hovold To: Rob Herring , Greg Kroah-Hartman Cc: Jiri Slaby , linux-serial@vger.kernel.org, linux-kernel@vger.kernel.org, Johan Hovold Subject: [PATCH RESEND] serdev: ttyport: do not used keyed wakeup in write_wakeup Date: Mon, 18 Dec 2017 12:00:19 +0100 Message-Id: <20171218110019.21934-1-johan@kernel.org> X-Mailer: git-send-email 2.15.1 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Serdev does not use the file abstraction and specifically there will never be anyone polling a file descriptor for POLLOUT events. Just use plain wake_up_interruptible() in the write_wakeup callback and document why it's there. Signed-off-by: Johan Hovold --- Here's a resend of the final patch from the series "[PATCH 0/8] serdev: receive_buf and locking fixes", which did not apply after the series was split over 4.15-rc and -next. Johan drivers/tty/serdev/serdev-ttyport.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/tty/serdev/serdev-ttyport.c b/drivers/tty/serdev/serdev-ttyport.c index c2629ab1bbcf..a5abb05be67d 100644 --- a/drivers/tty/serdev/serdev-ttyport.c +++ b/drivers/tty/serdev/serdev-ttyport.c @@ -59,7 +59,8 @@ static void ttyport_write_wakeup(struct tty_port *port) test_bit(SERPORT_ACTIVE, &serport->flags)) serdev_controller_write_wakeup(ctrl); - wake_up_interruptible_poll(&tty->write_wait, POLLOUT); + /* Wake up any tty_wait_until_sent() */ + wake_up_interruptible(&tty->write_wait); tty_kref_put(tty); } -- 2.15.1