media: gspca: Convert PERR to gspca_err
Use a more typical kernel logging style. The current macro hides the gspca_dev argument so add it to the macro uses instead. Miscellanea: o Add missing '\n' terminations to formats o Realign arguments to open parenthesis Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com> Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
This commit is contained in:

committed by
Mauro Carvalho Chehab

parent
6e298d5847
commit
52173c5f3f
@@ -274,7 +274,7 @@ static void sd_isoc_irq(struct urb *urb)
|
||||
if (gspca_dev->frozen)
|
||||
return;
|
||||
#endif
|
||||
PERR("urb status: %d", urb->status);
|
||||
gspca_err(gspca_dev, "urb status: %d\n", urb->status);
|
||||
st = usb_submit_urb(urb, GFP_ATOMIC);
|
||||
if (st < 0)
|
||||
pr_err("resubmit urb error %d\n", st);
|
||||
@@ -292,30 +292,31 @@ static void sd_isoc_irq(struct urb *urb)
|
||||
sd->last_data_urb = NULL;
|
||||
|
||||
if (!data_urb || data_urb->start_frame != status_urb->start_frame) {
|
||||
PERR("lost sync on frames");
|
||||
gspca_err(gspca_dev, "lost sync on frames\n");
|
||||
goto resubmit;
|
||||
}
|
||||
|
||||
if (data_urb->number_of_packets != status_urb->number_of_packets) {
|
||||
PERR("no packets does not match, data: %d, status: %d",
|
||||
data_urb->number_of_packets,
|
||||
status_urb->number_of_packets);
|
||||
gspca_err(gspca_dev, "no packets does not match, data: %d, status: %d\n",
|
||||
data_urb->number_of_packets,
|
||||
status_urb->number_of_packets);
|
||||
goto resubmit;
|
||||
}
|
||||
|
||||
for (i = 0; i < status_urb->number_of_packets; i++) {
|
||||
if (data_urb->iso_frame_desc[i].status ||
|
||||
status_urb->iso_frame_desc[i].status) {
|
||||
PERR("pkt %d data-status %d, status-status %d", i,
|
||||
data_urb->iso_frame_desc[i].status,
|
||||
status_urb->iso_frame_desc[i].status);
|
||||
gspca_err(gspca_dev, "pkt %d data-status %d, status-status %d\n",
|
||||
i,
|
||||
data_urb->iso_frame_desc[i].status,
|
||||
status_urb->iso_frame_desc[i].status);
|
||||
gspca_dev->last_packet_type = DISCARD_PACKET;
|
||||
continue;
|
||||
}
|
||||
|
||||
if (status_urb->iso_frame_desc[i].actual_length != 1) {
|
||||
PERR("bad status packet length %d",
|
||||
status_urb->iso_frame_desc[i].actual_length);
|
||||
gspca_err(gspca_dev, "bad status packet length %d\n",
|
||||
status_urb->iso_frame_desc[i].actual_length);
|
||||
gspca_dev->last_packet_type = DISCARD_PACKET;
|
||||
continue;
|
||||
}
|
||||
@@ -360,11 +361,12 @@ resubmit:
|
||||
if (data_urb) {
|
||||
st = usb_submit_urb(data_urb, GFP_ATOMIC);
|
||||
if (st < 0)
|
||||
PERR("usb_submit_urb(data_urb) ret %d", st);
|
||||
gspca_err(gspca_dev, "usb_submit_urb(data_urb) ret %d\n",
|
||||
st);
|
||||
}
|
||||
st = usb_submit_urb(status_urb, GFP_ATOMIC);
|
||||
if (st < 0)
|
||||
PERR("usb_submit_urb(status_urb) ret %d\n", st);
|
||||
gspca_err(gspca_dev, "usb_submit_urb(status_urb) ret %d\n", st);
|
||||
}
|
||||
|
||||
static int sd_s_ctrl(struct v4l2_ctrl *ctrl)
|
||||
|
Reference in New Issue
Block a user