mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: mchehab@infradead.org
To: linux-kernel@vger.kernel.org
Cc: linux-dvb-maintainer@linuxtv.org,
	Luca Risolia <luca.risolia@studio.unibo.it>,
	Mauro Carvalho Chehab <mchehab@infradead.org>
Subject: [PATCH 5/5] V4L/DVB (4865): Fix: Slot 0 not NULL on disconnecting SN9C10x PC Camera
Date: Tue, 21 Nov 2006 10:38:50 -0200	[thread overview]
Message-ID: <20061121123850.PS6444860005@infradead.org> (raw)
In-Reply-To: <20061121123202.PS8610150000@infradead.org>


From: Luca Risolia <luca.risolia@studio.unibo.it>

The patch fix bug 5748.

Signed-off-by: Luca Risolia <luca.risolia@studio.unibo.it>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
---

 drivers/media/video/et61x251/et61x251_core.c |    3 +--
 drivers/media/video/sn9c102/sn9c102_core.c   |    3 +--
 2 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/media/video/et61x251/et61x251_core.c b/drivers/media/video/et61x251/et61x251_core.c
index f786ab1..86e353b 100644
--- a/drivers/media/video/et61x251/et61x251_core.c
+++ b/drivers/media/video/et61x251/et61x251_core.c
@@ -1182,8 +1182,6 @@ static void et61x251_release_resources(s
 	video_set_drvdata(cam->v4ldev, NULL);
 	video_unregister_device(cam->v4ldev);
 
-	usb_put_dev(cam->usbdev);
-
 	mutex_unlock(&et61x251_sysfs_lock);
 
 	kfree(cam->control_buffer);
@@ -1275,6 +1273,7 @@ static int et61x251_release(struct inode
 
 	if (cam->state & DEV_DISCONNECTED) {
 		et61x251_release_resources(cam);
+		usb_put_dev(cam->usbdev);
 		mutex_unlock(&cam->dev_mutex);
 		kfree(cam);
 		return 0;
diff --git a/drivers/media/video/sn9c102/sn9c102_core.c b/drivers/media/video/sn9c102/sn9c102_core.c
index a4702d3..42fb60d 100644
--- a/drivers/media/video/sn9c102/sn9c102_core.c
+++ b/drivers/media/video/sn9c102/sn9c102_core.c
@@ -1462,8 +1462,6 @@ static void sn9c102_release_resources(st
 	video_set_drvdata(cam->v4ldev, NULL);
 	video_unregister_device(cam->v4ldev);
 
-	usb_put_dev(cam->usbdev);
-
 	mutex_unlock(&sn9c102_sysfs_lock);
 
 	kfree(cam->control_buffer);
@@ -1555,6 +1553,7 @@ static int sn9c102_release(struct inode*
 
 	if (cam->state & DEV_DISCONNECTED) {
 		sn9c102_release_resources(cam);
+		usb_put_dev(cam->usbdev);
 		mutex_unlock(&cam->dev_mutex);
 		kfree(cam);
 		return 0;


  parent reply	other threads:[~2006-11-21 12:59 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-11-21 12:32 [PATCH 0/5] V4L/DVB bug fixes mchehab
2006-11-21 12:38 ` [PATCH 4/5] V4L/DVB (4849): Add missing spin_unlock to saa6588 decoder driver mchehab
2006-11-21 12:38 ` [PATCH 1/5] V4L/DVB (4831): Fix tuning on older budget DVBS cards mchehab
2006-11-21 12:38 ` mchehab [this message]
2006-11-21 12:38 ` [PATCH 3/5] V4L/DVB (4832): Fix uninitialised variable in dvb_frontend_swzigzag mchehab
2006-11-21 12:38 ` [PATCH 2/5] V4L/DVB (4840): Budget: diseqc_method module parameter for cards with subsystem-id 13c2:1003 mchehab

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20061121123850.PS6444860005@infradead.org \
    --to=mchehab@infradead.org \
    --cc=linux-dvb-maintainer@linuxtv.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luca.risolia@studio.unibo.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®