From patchwork Thu Jun 25 08:29:19 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michal Simek X-Patchwork-Id: 6672611 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 94ECB9F399 for ; Thu, 25 Jun 2015 08:32:14 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C5D0F206E6 for ; Thu, 25 Jun 2015 08:32:13 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id E8EFE206E4 for ; Thu, 25 Jun 2015 08:32:12 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Z82Xg-0006O5-2s; Thu, 25 Jun 2015 08:29:52 +0000 Received: from mail-wg0-f54.google.com ([74.125.82.54]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Z82Xc-0006D9-1i for linux-arm-kernel@lists.infradead.org; Thu, 25 Jun 2015 08:29:48 +0000 Received: by wgbhy7 with SMTP id hy7so55844511wgb.2 for ; Thu, 25 Jun 2015 01:29:25 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:sender:from:to:cc:subject:date:message-id; bh=yYn49jqXToOt/I5nMfF9pGkY8mRc4P+0qDLj4q+Mc1U=; b=Nl76SS4HW8c13QKA0Lq5HrLGUsD130np8ERFFQdrmiKYBHKdt56tT2P6ZiY96zFAQu o02M2GWCEHfJ7rym3YChBdU9ck8AduokAVOyN7ib2fY2WzFge6/yz7IsrWtQFcUBHHB6 RAPHM83TmQvumotRGa9Dzt+4CyzpzVyAvleN0OgDoh5VeZeGuh4ISZ1O+eYnr/C8HxYd 2JahyaZKxVvecD0DMtQD79pHgXssE1eFol4IzB1Ekb7n9bIYULZu8pcG7pFAqiWx+5KK 1bsuhmVfIBwo7mOkiKgEmjAQ2N4B74kOxdzPcpY+DIykZYmJo0wBr+6GhzBNzeoZI0RR uwew== X-Gm-Message-State: ALoCoQkmUYyke0qZ+9awuxk/ItLI2m8j9hgAy6p2mp4lgvCj4Ybezcq8zoD7x0Wb+YqPlEPD6/v3 X-Received: by 10.194.81.67 with SMTP id y3mr76396066wjx.7.1435220965580; Thu, 25 Jun 2015 01:29:25 -0700 (PDT) Received: from localhost (nat-35.starnet.cz. [178.255.168.35]) by mx.google.com with ESMTPSA id s10sm44606166wjy.35.2015.06.25.01.29.24 (version=TLSv1.1 cipher=RC4-SHA bits=128/128); Thu, 25 Jun 2015 01:29:24 -0700 (PDT) From: Michal Simek To: linux-kernel@vger.kernel.org, monstr@monstr.eu Subject: [PATCH] gpio: zynq: Fix problem with unbalanced pm_runtime_enable Date: Thu, 25 Jun 2015 10:29:19 +0200 Message-Id: X-Mailer: git-send-email 2.3.5 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150625_012948_250353_4BD2C478 X-CRM114-Status: GOOD ( 11.26 ) X-Spam-Score: -2.6 (--) Cc: Alexandre Courbot , Peter Crosthwaite , Josh Cartwright , Linus Walleij , linux-gpio@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Steffen Trumtrar , =?UTF-8?q?S=C3=B6ren=20Brinkmann?= X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-5.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Add missing pm_runtime_disabled to remove(). Error log: root@zynqmp:~# modprobe gpio_zynq root@zynqmp:~# lsmod Not tainted gpio_zynq 7086 0 - Live 0xffffffbffc00a000 root@zynqmp:~# rmmod gpio_zynq root@zynqmp:~# lsmod Not tainted root@zynqmp:~# modprobe gpio_zynq [ 246.924438] zynq-gpio ff0a0000.gpio: Unbalanced pm_runtime_enable! root@zynqmp:~# rmmod gpio_zynq root@zynqmp:~# lsmod Not tainted Signed-off-by: Michal Simek Reviewed-by: Alexandre Courbot --- drivers/gpio/gpio-zynq.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpio/gpio-zynq.c b/drivers/gpio/gpio-zynq.c index 2e87c4b8da26..a78882389836 100644 --- a/drivers/gpio/gpio-zynq.c +++ b/drivers/gpio/gpio-zynq.c @@ -757,6 +757,7 @@ static int zynq_gpio_remove(struct platform_device *pdev) gpiochip_remove(&gpio->chip); clk_disable_unprepare(gpio->clk); device_set_wakeup_capable(&pdev->dev, 0); + pm_runtime_disable(&pdev->dev); return 0; }