aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/pvrusb2/pvrusb2-v4l2.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/pvrusb2/pvrusb2-v4l2.c')
-rw-r--r--drivers/media/video/pvrusb2/pvrusb2-v4l2.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/drivers/media/video/pvrusb2/pvrusb2-v4l2.c b/drivers/media/video/pvrusb2/pvrusb2-v4l2.c
index 5ffa0d2b0b0d..aaafa0398fd5 100644
--- a/drivers/media/video/pvrusb2/pvrusb2-v4l2.c
+++ b/drivers/media/video/pvrusb2/pvrusb2-v4l2.c
@@ -883,6 +883,17 @@ static void pvr2_v4l2_dev_destroy(struct pvr2_v4l2_dev *dip)
883{ 883{
884 struct pvr2_hdw *hdw = dip->v4lp->channel.mc_head->hdw; 884 struct pvr2_hdw *hdw = dip->v4lp->channel.mc_head->hdw;
885 enum pvr2_config cfg = dip->config; 885 enum pvr2_config cfg = dip->config;
886 char msg[80];
887 unsigned int mcnt;
888
889 /* Construct the unregistration message *before* we actually
890 perform the unregistration step. By doing it this way we don't
891 have to worry about potentially touching deleted resources. */
892 mcnt = scnprintf(msg, sizeof(msg) - 1,
893 "pvrusb2: unregistered device %s [%s]",
894 video_device_node_name(&dip->devbase),
895 pvr2_config_get_name(cfg));
896 msg[mcnt] = 0;
886 897
887 pvr2_hdw_v4l_store_minor_number(hdw,dip->minor_type,-1); 898 pvr2_hdw_v4l_store_minor_number(hdw,dip->minor_type,-1);
888 899
@@ -894,9 +905,7 @@ static void pvr2_v4l2_dev_destroy(struct pvr2_v4l2_dev *dip)
894 are gone. */ 905 are gone. */
895 video_unregister_device(&dip->devbase); 906 video_unregister_device(&dip->devbase);
896 907
897 printk(KERN_INFO "pvrusb2: unregistered device %s [%s]\n", 908 printk(KERN_INFO "%s\n", msg);
898 video_device_node_name(&dip->devbase),
899 pvr2_config_get_name(cfg));
900 909
901} 910}
902 911