From patchwork Fri Aug 16 11:43:09 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 19222 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-qc0-f200.google.com (mail-qc0-f200.google.com [209.85.216.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 804DA246AB for ; Fri, 16 Aug 2013 11:44:30 +0000 (UTC) Received: by mail-qc0-f200.google.com with SMTP id n1sf2152023qcx.3 for ; Fri, 16 Aug 2013 04:44:30 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:x-gm-message-state:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:in-reply-to:references :x-original-sender:x-original-authentication-results:precedence :mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=MXOiRUUuSlUUdmX7IBHlCMsgsFwFyh/boYSPkFJnwmE=; b=JYMCtbUgbvru1H6uH5kvLGSLwz7PpzSYuTTHsOcGqZdHNXp2pM5EV0FRir9tGKimb8 edQfdI3Bv2+N7jLYk0/1oQb1+CjoaYKk0kx+qygv4LbsvM+d9sEkXHC4A7p1NHUxFtsR iLSreQpb32cEjWw9vf761yPBpZ9CyTJPK0Kg4f7BzfoMgU75q/7YC4AjRmpAPVjMrUv3 R5eyEaIa1B3EZgHDG1DXqqFDHX+xjvT/bNULEiZ8Bw7HcJNFOTcVaQ17gQMnxdLutC9t ESlVY830gYO/lvoEKVCPkXeCPZyR7K7WZHqSnV6Yn8zn/E77gEnSJ0sv64Ps7HMtw6Gt PMRg== X-Received: by 10.236.6.134 with SMTP id 6mr429360yhn.7.1376653470283; Fri, 16 Aug 2013 04:44:30 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.26.70 with SMTP id j6ls786277qeg.94.gmail; Fri, 16 Aug 2013 04:44:30 -0700 (PDT) X-Received: by 10.221.36.4 with SMTP id sy4mr888419vcb.11.1376653470151; Fri, 16 Aug 2013 04:44:30 -0700 (PDT) Received: from mail-vc0-f173.google.com (mail-vc0-f173.google.com [209.85.220.173]) by mx.google.com with ESMTPS id ix2si219944vdb.85.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 16 Aug 2013 04:44:30 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.173 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.173; Received: by mail-vc0-f173.google.com with SMTP id id13so1338115vcb.4 for ; Fri, 16 Aug 2013 04:44:30 -0700 (PDT) X-Gm-Message-State: ALoCoQklY5+MT4CVkep8394yHJOnTkryF08S400rTc4U1NiOO9WnahTSP1rTvT8Y6la6QASFfqCD X-Received: by 10.221.49.134 with SMTP id va6mr890635vcb.14.1376653470068; Fri, 16 Aug 2013 04:44:30 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp64122vcz; Fri, 16 Aug 2013 04:44:29 -0700 (PDT) X-Received: by 10.68.177.196 with SMTP id cs4mr1204207pbc.45.1376653469251; Fri, 16 Aug 2013 04:44:29 -0700 (PDT) Received: from mail-pa0-f41.google.com (mail-pa0-f41.google.com [209.85.220.41]) by mx.google.com with ESMTPS id g9si1493766pac.184.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 16 Aug 2013 04:44:29 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.41 is neither permitted nor denied by best guess record for domain of viresh.kumar@linaro.org) client-ip=209.85.220.41; Received: by mail-pa0-f41.google.com with SMTP id bj1so1794747pad.28 for ; Fri, 16 Aug 2013 04:44:28 -0700 (PDT) X-Received: by 10.68.59.98 with SMTP id y2mr1114365pbq.135.1376653468792; Fri, 16 Aug 2013 04:44:28 -0700 (PDT) Received: from localhost ([122.172.193.46]) by mx.google.com with ESMTPSA id pu5sm2898162pac.21.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Fri, 16 Aug 2013 04:44:28 -0700 (PDT) From: Viresh Kumar To: gregkh@linuxfoundation.org, jslaby@suse.cz Cc: linaro-kernel@lists.linaro.org, patches@linaro.org, linux-serial@vger.kernel.org, Viresh Kumar Subject: [PATCH 08/25] tty: serial: efm32: drop uart_port->lock before calling tty_flip_buffer_push() Date: Fri, 16 Aug 2013 17:13:09 +0530 Message-Id: <41721e2fcd0a0eff70f990afa37163e55c6f7480.1376651114.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 1.7.12.rc2.18.g61b472e In-Reply-To: References: In-Reply-To: References: X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: viresh.kumar@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.173 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , The -rt patch triggers a lockdep warning for serial drivers if tty_flip_buffer_push() is called with uart_port->lock locked. This never shows up on UP kernels. Release the port lock before calling tty_flip_buffer_push() and reacquire it after the call. Similar stuff was already done for few other drivers in the past, like: commit 2389b272168ceec056ca1d8a870a97fa9c26e11a Author: Thomas Gleixner Date: Tue May 29 21:53:50 2007 +0100 [ARM] 4417/1: Serial: Fix AMBA drivers locking Signed-off-by: Viresh Kumar --- drivers/tty/serial/efm32-uart.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/tty/serial/efm32-uart.c b/drivers/tty/serial/efm32-uart.c index 7d199c8..b4cef79 100644 --- a/drivers/tty/serial/efm32-uart.c +++ b/drivers/tty/serial/efm32-uart.c @@ -268,10 +268,10 @@ static irqreturn_t efm32_uart_rxirq(int irq, void *data) handled = IRQ_HANDLED; } - tty_flip_buffer_push(tport); - spin_unlock(&port->lock); + tty_flip_buffer_push(tport); + return handled; }