From patchwork Mon Jul 26 14:13:52 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jarod Wilson X-Patchwork-Id: 3884 Return-path: Envelope-to: mchehab@infradead.org Delivery-date: Mon, 26 Jul 2010 14:24:06 +0000 Received: from bombadil.infradead.org [18.85.46.34] by pedra with IMAP (fetchmail-6.3.17) for (single-drop); Mon, 26 Jul 2010 11:28:33 -0300 (BRT) Received: from vger.kernel.org ([209.132.180.67]) by bombadil.infradead.org with esmtp (Exim 4.72 #1 (Red Hat Linux)) id 1OdOb8-0003q8-GJ; Mon, 26 Jul 2010 14:24:06 +0000 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754613Ab0GZOYE (ORCPT + 1 other); Mon, 26 Jul 2010 10:24:04 -0400 Received: from mx1.redhat.com ([209.132.183.28]:45868 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754348Ab0GZOYB (ORCPT ); Mon, 26 Jul 2010 10:24:01 -0400 Received: from int-mx04.intmail.prod.int.phx2.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.17]) by mx1.redhat.com (8.13.8/8.13.8) with ESMTP id o6QEO0Bs018337 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 26 Jul 2010 10:24:00 -0400 Received: from xavier.bos.redhat.com (xavier.bos.redhat.com [10.16.16.50]) by int-mx04.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id o6QEO0ZC031411; Mon, 26 Jul 2010 10:24:00 -0400 Received: by xavier.bos.redhat.com (Postfix, from userid 501) id B0A1E21D59; Mon, 26 Jul 2010 10:13:52 -0400 (EDT) Date: Mon, 26 Jul 2010 10:13:52 -0400 From: Jarod Wilson To: linux-media@vger.kernel.org Cc: Dmitry Torokhov Subject: [PATCH] IR/imon: remove incorrect calls to input_free_device Message-ID: <20100726141352.GA28182@redhat.com> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.20 (2009-12-10) X-Scanned-By: MIMEDefang 2.67 on 10.5.11.17 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Per Dmitry Torokhov (in a completely unrelated thread on linux-input), following input_unregister_device with an input_free_device is forbidden, the former is sufficient alone. CC: Dmitry Torokhov Signed-off-by: Jarod Wilson Acked-by: Dmitry Torokhov --- drivers/media/IR/imon.c | 5 +---- 1 files changed, 1 insertions(+), 4 deletions(-) diff --git a/drivers/media/IR/imon.c b/drivers/media/IR/imon.c index 0195dd5..08dff8c 100644 --- a/drivers/media/IR/imon.c +++ b/drivers/media/IR/imon.c @@ -1944,7 +1944,6 @@ static struct imon_context *imon_init_intf0(struct usb_interface *intf) urb_submit_failed: ir_input_unregister(ictx->idev); - input_free_device(ictx->idev); idev_setup_failed: find_endpoint_failed: mutex_unlock(&ictx->lock); @@ -2014,10 +2013,8 @@ static struct imon_context *imon_init_intf1(struct usb_interface *intf, return ictx; urb_submit_failed: - if (ictx->touch) { + if (ictx->touch) input_unregister_device(ictx->touch); - input_free_device(ictx->touch); - } touch_setup_failed: find_endpoint_failed: mutex_unlock(&ictx->lock);