From 9829676dae59d7eb50d35657d32438b13cc1d44b Mon Sep 17 00:00:00 2001 From: Mike Isely Date: Sat, 7 Apr 2007 23:09:11 -0500 Subject: pvrusb2: Use NULL instead of 0 for null pointer values (trivial) From: Mike Isely Signed-off-by: Mike Isely --- linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c') diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c b/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c index 9f2f11754..4b1cd2b2e 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c @@ -809,11 +809,11 @@ static void pvr2_v4l2_destroy_no_lock(struct pvr2_v4l2 *vp) { if (vp->dev_video) { pvr2_v4l2_dev_destroy(vp->dev_video); - vp->dev_video = 0; + vp->dev_video = NULL; } if (vp->dev_radio) { pvr2_v4l2_dev_destroy(vp->dev_radio); - vp->dev_radio = 0; + vp->dev_radio = NULL; } pvr2_trace(PVR2_TRACE_STRUCT,"Destroying pvr2_v4l2 id=%p",vp); @@ -1142,7 +1142,7 @@ static void pvr2_v4l2_dev_init(struct pvr2_v4l2_dev *dip, #endif int mindevnum; int unit_number; - int *nr_ptr = 0; + int *nr_ptr = NULL; dip->v4lp = vp; #if 0 -- cgit v1.2.3 From fd865ea20e1c05d7e9b7d081632db5fa6ad32a3a Mon Sep 17 00:00:00 2001 From: Mike Isely Date: Sat, 7 Apr 2007 23:11:47 -0500 Subject: pvrusb2: Gather USB bus address info and report it From: Mike Isely The V4L2 API requires a unique bus_info string returned as part of the v4l2_capability structure. These changes gather up the USB address information, from the underlying device, into a string and report that out through v4l2 and via sysfs (for completeness). Signed-off-by: Mike Isely --- linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c') diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c b/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c index 4b1cd2b2e..a8a8a36ee 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-v4l2.c @@ -204,6 +204,8 @@ static int pvr2_v4l2_do_ioctl(struct inode *inode, struct file *file, struct v4l2_capability *cap = arg; memcpy(cap, &pvr_capability, sizeof(struct v4l2_capability)); + strlcpy(cap->bus_info,pvr2_hdw_get_bus_info(hdw), + sizeof(cap->bus_info)); ret = 0; break; -- cgit v1.2.3