Staging: media: vino: Replace printk() and dprintk() with dev_dbg()
Subsystems (2)
PATCH v3 1/1 Staging: media: vino: Replace printk() and dprintk() with dev_dbg()
Making variants of existing macros is against kernel coding style. This patch removes all definitions made by macro dprintk() and replaces them with dev_dbg().
---
v3: Added a pointer to a structure in dev_dbg() as the first
argument.
v2: Removed KERN_ERR and KERN_INFO from dev_dbg() argument list.
drivers/staging/media/vino/saa7191.c | 52 ++++++++++++++++++------------------ 1 file changed, 26 insertions(+), 26 deletions(-)
drivers/staging/media/vino/saa7191.c +26 -26
@@ -110,7 +110,7 @@ static int saa7191_read_status(struct v4l2_subdev *sd, u8 *value) ret =i2c_master_recv (client, value,1 );if (ret <0 ) { -dev_dbg ("saa7191_read_status(): read failed\n" ); +dev_dbg (sd->dev,"saa7191_read_status(): read failed\n" );return ret; }
@@ -141,7 +141,7 @@ static int saa7191_write_block(struct v4l2_subdev *sd, ret =i2c_master_send (client, data, length);if (ret <0 ) { -dev_dbg ("saa7191_write_block(): " +dev_dbg (sd->dev,"saa7191_write_block(): " "write failed\n" );return ret; }
@@ -224,9 +224,9 @@ static int saa7191_s_std(struct v4l2_subdev *sd, v4l2_std_id norm) decoder->norm = norm; -dev_dbg (&sd->dev,"ctl3: %02x stdc: %02x chcv: %02x\n" , ctl3, +dev_dbg (sd->dev,"ctl3: %02x stdc: %02x chcv: %02x\n" , ctl3, stdc, chcv); -dev_dbg ("norm: %llx\n" , norm); +dev_dbg (sd->dev,"norm: %llx\n" , norm);return 0 ; }
@@ -235,21 +235,21 @@ static int saa7191_wait_for_signal(struct v4l2_subdev *sd, u8 *status) {int i =0 ; -dev_dbg ("Checking for signal...\n" ); +dev_dbg (sd->dev,"Checking for signal...\n" );for (i =0 ; i <SAA7191_SYNC_COUNT ; i++) {if (saa7191_read_status (sd, status))return -EIO ;if (((*status) &SAA7191_STATUS_HLCK ) ==0 ) { -dev_dbg ("Signal found\n" ); +dev_dbg (sd->dev,"Signal found\n" );return 0 ; }msleep (SAA7191_SYNC_DELAY ); } -dev_dbg ("No signal\n" ); +dev_dbg (sd->dev,"No signal\n" );return -EBUSY ; }
@@ -263,7 +263,7 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)v4l2_std_id old_norm = decoder->norm;int err =0 ; -dev_dbg ("SAA7191 extended signal auto-detection...\n" ); +dev_dbg (sd->dev,"SAA7191 extended signal auto-detection...\n" ); *norm &=V4L2_STD_NTSC |V4L2_STD_PAL |V4L2_STD_SECAM ; stdc &= ~SAA7191_STDC_SECS ;
@@ -295,13 +295,13 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)if (status &SAA7191_STATUS_FIDT ) {/* 60Hz signal -> NTSC */ -dev_dbg ("60Hz signal: NTSC\n" ); +dev_dbg (sd->dev,"60Hz signal: NTSC\n" ); *norm &=V4L2_STD_NTSC ;return 0 ; }/* 50Hz signal */ -dev_dbg ("50Hz signal: Trying PAL...\n" ); +dev_dbg (sd->dev,"50Hz signal: Trying PAL...\n" );/* try PAL first */ err =saa7191_s_std (sd,V4L2_STD_PAL );
@@ -316,19 +316,19 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)/* not 50Hz ? */ if (status &SAA7191_STATUS_FIDT ) { -dev_dbg ("No 50Hz signal\n" ); +dev_dbg (sd->dev,"No 50Hz signal\n" );saa7191_s_std (sd, old_norm); *norm =V4L2_STD_UNKNOWN ;return 0 ; }if (status &SAA7191_STATUS_CODE ) { -dev_dbg ("PAL\n" ); +dev_dbg (sd->dev,"PAL\n" ); *norm &=V4L2_STD_PAL ;return saa7191_s_std (sd, old_norm); } -dev_dbg ("No color detected with PAL - Trying SECAM...\n" ); +dev_dbg (sd->dev,"No color detected with PAL - Trying SECAM...\n" );/* no color detected ? -> try SECAM */ err =saa7191_s_std (sd,V4L2_STD_SECAM );
@@ -343,19 +343,19 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)/* not 50Hz ? */ if (status &SAA7191_STATUS_FIDT ) { -dev_dbg ("No 50Hz signal\n" ); +dev_dbg (sd->dev,"No 50Hz signal\n" ); *norm =V4L2_STD_UNKNOWN ; goto out; }if (status &SAA7191_STATUS_CODE ) {/* Color detected -> SECAM */ -dev_dbg ("SECAM\n" ); +dev_dbg (sd->dev,"SECAM\n" ); *norm &=V4L2_STD_SECAM ;return saa7191_s_std (sd, old_norm); } -dev_dbg ("No color detected with SECAM - Going back to PAL.\n" ); +dev_dbg (sd->dev,"No color detected with SECAM - Going back to PAL.\n" ); *norm =V4L2_STD_UNKNOWN ; out:
@@ -366,30 +366,30 @@ static int saa7191_autodetect_norm(struct v4l2_subdev *sd) {u8 status; -dev_dbg ("SAA7191 signal auto-detection...\n" ); +dev_dbg (sd->dev,"SAA7191 signal auto-detection...\n" ); -dev_dbg ("Reading status...\n" ); +dev_dbg (sd->dev,"Reading status...\n" );if (saa7191_read_status (sd, &status))return -EIO ; -dev_dbg ("Checking for signal...\n" ); +dev_dbg (sd->dev,"Checking for signal...\n" );/* no signal ? */ if (status &SAA7191_STATUS_HLCK ) { -dev_dbg ("No signal\n" ); +dev_dbg (sd->dev,"No signal\n" );return -EBUSY ; } -dev_dbg ("Signal found\n" ); +dev_dbg (sd->dev,"Signal found\n" );if (status &SAA7191_STATUS_FIDT ) {/* 60hz signal -> NTSC */ -dev_dbg ("NTSC\n" ); +dev_dbg (sd->dev,"NTSC\n" );return saa7191_s_std (sd,V4L2_STD_NTSC ); }else {/* 50hz signal -> PAL */ -dev_dbg ("PAL\n" ); +dev_dbg (sd->dev,"PAL\n" );return saa7191_s_std (sd,V4L2_STD_PAL ); } }
@@ -600,18 +600,18 @@ static int saa7191_probe(struct i2c_client *client, err =saa7191_write_block (sd,sizeof (initseq), initseq);if (err) { -dev_dbg ("SAA7191 initialization failed\n" ); +dev_dbg (sd->dev,"SAA7191 initialization failed\n" );return err; } -dev_dbg ("SAA7191 initialized\n" ); +dev_dbg (sd->dev,"SAA7191 initialized\n" ); decoder->input =SAA7191_INPUT_COMPOSITE ; decoder->norm =V4L2_STD_PAL ; err =saa7191_autodetect_norm (sd);if (err && (err != -EBUSY )) -dev_dbg ("SAA7191: Signal auto-detection failed\n" ); +dev_dbg (sd->dev,"SAA7191: Signal auto-detection failed\n" );return 0 ; }
Signature · 1 line
1.9.1
drivers/staging/media/vino/saa7191.c static int saa7191_read_status(struct v4l2_subdev *sd, u8 *value) · line 113
Quoted 4 lines
drivers/staging/media/vino/saa7191.c +1
-1ret =i2c_master_recv (client, value,1 );if (ret <0 ) { -dev_dbg ("saa7191_read_status(): read failed\n" ); +dev_dbg (sd->dev,"saa7191_read_status(): read failed\n" );
This is a patch against your previous changes. Greg is just going to ignore that patch, since you have provided a revised one. So you need to go back to a state where your previous changes have not been made. Git checkout may be helpful.
julia
Quoted 190 lines
drivers/staging/media/vino/saa7191.c +25
-26return ret; }@@ -141,7 +141,7 @@ static int saa7191_write_block(struct v4l2_subdev *sd, ret =i2c_master_send (client, data, length);if (ret <0 ) { -dev_dbg ("saa7191_write_block(): " +dev_dbg (sd->dev,"saa7191_write_block(): " "write failed\n" );return ret; }@@ -224,9 +224,9 @@ static int saa7191_s_std(struct v4l2_subdev *sd, v4l2_std_id norm) decoder->norm = norm; -dev_dbg (&sd->dev,"ctl3: %02x stdc: %02x chcv: %02x\n" , ctl3, +dev_dbg (sd->dev,"ctl3: %02x stdc: %02x chcv: %02x\n" , ctl3, stdc, chcv); -dev_dbg ("norm: %llx\n" , norm); +dev_dbg (sd->dev,"norm: %llx\n" , norm);return 0 ; }@@ -235,21 +235,21 @@ static int saa7191_wait_for_signal(struct v4l2_subdev *sd, u8 *status) {int i =0 ; -dev_dbg ("Checking for signal...\n" ); +dev_dbg (sd->dev,"Checking for signal...\n" );for (i =0 ; i <SAA7191_SYNC_COUNT ; i++) {if (saa7191_read_status (sd, status))return -EIO ;if (((*status) &SAA7191_STATUS_HLCK ) ==0 ) { -dev_dbg ("Signal found\n" ); +dev_dbg (sd->dev,"Signal found\n" );return 0 ; }msleep (SAA7191_SYNC_DELAY ); } -dev_dbg ("No signal\n" ); +dev_dbg (sd->dev,"No signal\n" );return -EBUSY ; }@@ -263,7 +263,7 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)v4l2_std_id old_norm = decoder->norm;int err =0 ; -dev_dbg ("SAA7191 extended signal auto-detection...\n" ); +dev_dbg (sd->dev,"SAA7191 extended signal auto-detection...\n" ); *norm &=V4L2_STD_NTSC |V4L2_STD_PAL |V4L2_STD_SECAM ; stdc &= ~SAA7191_STDC_SECS ;@@ -295,13 +295,13 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)if (status &SAA7191_STATUS_FIDT ) {/* 60Hz signal -> NTSC */ -dev_dbg ("60Hz signal: NTSC\n" ); +dev_dbg (sd->dev,"60Hz signal: NTSC\n" ); *norm &=V4L2_STD_NTSC ;return 0 ; }/* 50Hz signal */ -dev_dbg ("50Hz signal: Trying PAL...\n" ); +dev_dbg (sd->dev,"50Hz signal: Trying PAL...\n" );/* try PAL first */ err =saa7191_s_std (sd,V4L2_STD_PAL );@@ -316,19 +316,19 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)/* not 50Hz ? */ if (status &SAA7191_STATUS_FIDT ) { -dev_dbg ("No 50Hz signal\n" ); +dev_dbg (sd->dev,"No 50Hz signal\n" );saa7191_s_std (sd, old_norm); *norm =V4L2_STD_UNKNOWN ;return 0 ; }if (status &SAA7191_STATUS_CODE ) { -dev_dbg ("PAL\n" ); +dev_dbg (sd->dev,"PAL\n" ); *norm &=V4L2_STD_PAL ;return saa7191_s_std (sd, old_norm); } -dev_dbg ("No color detected with PAL - Trying SECAM...\n" ); +dev_dbg (sd->dev,"No color detected with PAL - Trying SECAM...\n" );/* no color detected ? -> try SECAM */ err =saa7191_s_std (sd,V4L2_STD_SECAM );@@ -343,19 +343,19 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)/* not 50Hz ? */ if (status &SAA7191_STATUS_FIDT ) { -dev_dbg ("No 50Hz signal\n" ); +dev_dbg (sd->dev,"No 50Hz signal\n" ); *norm =V4L2_STD_UNKNOWN ; goto out; }if (status &SAA7191_STATUS_CODE ) {/* Color detected -> SECAM */ -dev_dbg ("SECAM\n" ); +dev_dbg (sd->dev,"SECAM\n" ); *norm &=V4L2_STD_SECAM ;return saa7191_s_std (sd, old_norm); } -dev_dbg ("No color detected with SECAM - Going back to PAL.\n" ); +dev_dbg (sd->dev,"No color detected with SECAM - Going back to PAL.\n" ); *norm =V4L2_STD_UNKNOWN ; out:@@ -366,30 +366,30 @@ static int saa7191_autodetect_norm(struct v4l2_subdev *sd) {u8 status; -dev_dbg ("SAA7191 signal auto-detection...\n" ); +dev_dbg (sd->dev,"SAA7191 signal auto-detection...\n" ); -dev_dbg ("Reading status...\n" ); +dev_dbg (sd->dev,"Reading status...\n" );if (saa7191_read_status (sd, &status))return -EIO ; -dev_dbg ("Checking for signal...\n" ); +dev_dbg (sd->dev,"Checking for signal...\n" );/* no signal ? */ if (status &SAA7191_STATUS_HLCK ) { -dev_dbg ("No signal\n" ); +dev_dbg (sd->dev,"No signal\n" );return -EBUSY ; } -dev_dbg ("Signal found\n" ); +dev_dbg (sd->dev,"Signal found\n" );if (status &SAA7191_STATUS_FIDT ) {/* 60hz signal -> NTSC */ -dev_dbg ("NTSC\n" ); +dev_dbg (sd->dev,"NTSC\n" );return saa7191_s_std (sd,V4L2_STD_NTSC ); }else {/* 50hz signal -> PAL */ -dev_dbg ("PAL\n" ); +dev_dbg (sd->dev,"PAL\n" );return saa7191_s_std (sd,V4L2_STD_PAL ); } }@@ -600,18 +600,18 @@ static int saa7191_probe(struct i2c_client *client, err =saa7191_write_block (sd,sizeof (initseq), initseq);if (err) { -dev_dbg ("SAA7191 initialization failed\n" ); +dev_dbg (sd->dev,"SAA7191 initialization failed\n" );return err; } -dev_dbg ("SAA7191 initialized\n" ); +dev_dbg (sd->dev,"SAA7191 initialized\n" ); decoder->input =SAA7191_INPUT_COMPOSITE ; decoder->norm =V4L2_STD_PAL ; err =saa7191_autodetect_norm (sd);if (err && (err != -EBUSY )) -dev_dbg ("SAA7191: Signal auto-detection failed\n" ); +dev_dbg (sd->dev,"SAA7191: Signal auto-detection failed\n" );return 0 ; } --1.9.1
--
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1424319465-2828-1-git-send-email-ksenija.stanojevic%40gmail.com.
For more options, visit https://groups.google.com/d/optout.
Ok, I understand, should I post that as v4?
Quoted 223 lines · Julia Lawall
Review
Quoted 5 lines
ret = i2c_master_recv(client, value, 1); if (ret < 0) {(quoted diff) +1
-1- dev_dbg("saa7191_read_status(): read failed\n"); + dev_dbg(sd->dev, "saa7191_read_status(): readfailed\n");
This is a patch against your previous changes. Greg is just going to ignore that patch, since you have provided a revised one. So you need to go back to a state where your previous changes have not been made. Git checkout may be helpful.
julia
Review static int saa7191_write_block(struct v4l2_subdev
Quoted 4 lines
return ret; }(quoted diff) +0
-0@@ -141,7 +141,7 @@ static int saa7191_write_block(struct v4l2_subdev*sd,
drivers/staging/media/vino/saa7191.c static int saa7191_s_std(struct v4l2_subdev *sd,
Quoted 9 lines
drivers/staging/media/vino/saa7191.c +1
-1ret =i2c_master_send (client, data, length);if (ret <0 ) { -dev_dbg ("saa7191_write_block(): " +dev_dbg (sd->dev,"saa7191_write_block(): " "write failed\n" );return ret; }@@ -224,9 +224,9 @@ static int saa7191_s_std(struct v4l2_subdev *sd,
v4l2_std_idnorm)drivers/staging/media/vino/saa7191.c static int saa7191_wait_for_signal(struct
Quoted 12 lines
drivers/staging/media/vino/saa7191.c +2
-2decoder->norm = norm; -dev_dbg (&sd->dev,"ctl3: %02x stdc: %02x chcv: %02x\n" , ctl3, +dev_dbg (sd->dev,"ctl3: %02x stdc: %02x chcv: %02x\n" , ctl3, stdc, chcv); -dev_dbg ("norm: %llx\n" , norm); +dev_dbg (sd->dev,"norm: %llx\n" , norm);return 0 ; }@@ -235,21 +235,21 @@ static int saa7191_wait_for_signal(struct
v4l2_subdev*sd, u8 *status)drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev *sd,
Quoted 25 lines
drivers/staging/media/vino/saa7191.c +3
-3{int i =0 ; -dev_dbg ("Checking for signal...\n" ); +dev_dbg (sd->dev,"Checking for signal...\n" );for (i =0 ; i <SAA7191_SYNC_COUNT ; i++) {if (saa7191_read_status (sd, status))return -EIO ;if (((*status) &SAA7191_STATUS_HLCK ) ==0 ) { -dev_dbg ("Signal found\n" ); +dev_dbg (sd->dev,"Signal found\n" );return 0 ; }msleep (SAA7191_SYNC_DELAY ); } -dev_dbg ("No signal\n" ); +dev_dbg (sd->dev,"No signal\n" );return -EBUSY ; }@@ -263,7 +263,7 @@ static int saa7191_querystd(struct v4l2_subdev *sd,
v4l2_std_id*norm)drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)
Quoted 5 lines
drivers/staging/media/vino/saa7191.c +1
-1v4l2_std_id old_norm = decoder->norm;int err =0 ; -dev_dbg ("SAA7191 extended signal auto-detection...\n" ); + dev_dbg(sd->dev, "SAA7191 extended signalauto-detection...\n");
drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev
Quoted 4 lines
drivers/staging/media/vino/saa7191.c +0
-0*norm &=V4L2_STD_NTSC |V4L2_STD_PAL |V4L2_STD_SECAM ; stdc &= ~SAA7191_STDC_SECS ;@@ -295,13 +295,13 @@ static int saa7191_querystd(struct v4l2_subdev*sd,
v4l2_std_id*norm)drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev
Quoted 16 lines
drivers/staging/media/vino/saa7191.c +2
-2if (status &SAA7191_STATUS_FIDT ) {/* 60Hz signal -> NTSC */ -dev_dbg ("60Hz signal: NTSC\n" ); +dev_dbg (sd->dev,"60Hz signal: NTSC\n" ); *norm &=V4L2_STD_NTSC ;return 0 ; }/* 50Hz signal */ -dev_dbg ("50Hz signal: Trying PAL...\n" ); +dev_dbg (sd->dev,"50Hz signal: Trying PAL...\n" );/* try PAL first */ err =saa7191_s_std (sd,V4L2_STD_PAL );@@ -316,19 +316,19 @@ static int saa7191_querystd(struct v4l2_subdev*sd,
v4l2_std_id*norm)Quoted 9 lines
drivers/staging/media/vino/saa7191.c +1
-1/* not 50Hz ? */ if (status &SAA7191_STATUS_FIDT ) { -dev_dbg ("No 50Hz signal\n" ); +dev_dbg (sd->dev,"No 50Hz signal\n" );saa7191_s_std (sd, old_norm); *norm =V4L2_STD_UNKNOWN ;return 0 ; }drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)
Quoted 10 lines
drivers/staging/media/vino/saa7191.c +2
-2if (status &SAA7191_STATUS_CODE ) { -dev_dbg ("PAL\n" ); +dev_dbg (sd->dev,"PAL\n" ); *norm &=V4L2_STD_PAL ;return saa7191_s_std (sd, old_norm); } -dev_dbg ("No color detected with PAL - Trying SECAM...\n" ); + dev_dbg(sd->dev, "No color detected with PAL - TryingSECAM...\n");
drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev
Quoted 4 lines
drivers/staging/media/vino/saa7191.c +0
-0/* no color detected ? -> try SECAM */ err =saa7191_s_std (sd,V4L2_STD_SECAM );@@ -343,19 +343,19 @@ static int saa7191_querystd(struct v4l2_subdev*sd,
v4l2_std_id*norm)Quoted 9 lines
drivers/staging/media/vino/saa7191.c +1
-1/* not 50Hz ? */ if (status &SAA7191_STATUS_FIDT ) { -dev_dbg ("No 50Hz signal\n" ); +dev_dbg (sd->dev,"No 50Hz signal\n" ); *norm =V4L2_STD_UNKNOWN ; goto out; }drivers/staging/media/vino/saa7191.c static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm)
Quoted 10 lines
drivers/staging/media/vino/saa7191.c +2
-2if (status &SAA7191_STATUS_CODE ) {/* Color detected -> SECAM */ -dev_dbg ("SECAM\n" ); +dev_dbg (sd->dev,"SECAM\n" ); *norm &=V4L2_STD_SECAM ;return saa7191_s_std (sd, old_norm); } -dev_dbg ("No color detected with SECAM - Going back to PAL.\n" ); + dev_dbg(sd->dev, "No color detected with SECAM - Going back toPAL.\n");
drivers/staging/media/vino/saa7191.c static int saa7191_autodetect_norm(struct
Quoted 4 lines
drivers/staging/media/vino/saa7191.c +0
-0*norm =V4L2_STD_UNKNOWN ; out:@@ -366,30 +366,30 @@ static int saa7191_autodetect_norm(struct
v4l2_subdev*sd)drivers/staging/media/vino/saa7191.c static int saa7191_probe(struct i2c_client
Quoted 38 lines
drivers/staging/media/vino/saa7191.c +7
-7{u8 status; -dev_dbg ("SAA7191 signal auto-detection...\n" ); +dev_dbg (sd->dev,"SAA7191 signal auto-detection...\n" ); -dev_dbg ("Reading status...\n" ); +dev_dbg (sd->dev,"Reading status...\n" );if (saa7191_read_status (sd, &status))return -EIO ; -dev_dbg ("Checking for signal...\n" ); +dev_dbg (sd->dev,"Checking for signal...\n" );/* no signal ? */ if (status &SAA7191_STATUS_HLCK ) { -dev_dbg ("No signal\n" ); +dev_dbg (sd->dev,"No signal\n" );return -EBUSY ; } -dev_dbg ("Signal found\n" ); +dev_dbg (sd->dev,"Signal found\n" );if (status &SAA7191_STATUS_FIDT ) {/* 60hz signal -> NTSC */ -dev_dbg ("NTSC\n" ); +dev_dbg (sd->dev,"NTSC\n" );return saa7191_s_std (sd,V4L2_STD_NTSC ); }else {/* 50hz signal -> PAL */ -dev_dbg ("PAL\n" ); +dev_dbg (sd->dev,"PAL\n" );return saa7191_s_std (sd,V4L2_STD_PAL ); } }@@ -600,18 +600,18 @@ static int saa7191_probe(struct i2c_client*client,
Quoted 8 lines
drivers/staging/media/vino/saa7191.c +1
-1err =saa7191_write_block (sd,sizeof (initseq), initseq);if (err) { -dev_dbg ("SAA7191 initialization failed\n" ); +dev_dbg (sd->dev,"SAA7191 initialization failed\n" );return err; }drivers/staging/media/vino/saa7191.c static int saa7191_probe(struct i2c_client *client,
Quoted 10 lines
drivers/staging/media/vino/saa7191.c +2
-2-dev_dbg ("SAA7191 initialized\n" ); +dev_dbg (sd->dev,"SAA7191 initialized\n" ); decoder->input =SAA7191_INPUT_COMPOSITE ; decoder->norm =V4L2_STD_PAL ; err =saa7191_autodetect_norm (sd);if (err && (err != -EBUSY )) -dev_dbg ("SAA7191: Signal auto-detection failed\n" ); + dev_dbg(sd->dev, "SAA7191: Signal auto-detectionfailed\n");
Quoted 8 lines
drivers/staging/media/vino/saa7191.c +0
-1return 0 ; } --1.9.1
Signature · 1 line
You received this message because you are subscribed to the GoogleGroups "outreachy-kernel" group.
Quoted 1 line
To unsubscribe from this group and stop receiving emails from it, send
an email to [email protected] <javascript:>.
Quoted 1 line
To post to this group, send email to [email protected]
<javascript:>.
Quoted 1 line
To view this discussion on the web visit
Quoted 2 lines
For more options, visit https://groups.google.com/d/optout.
Quoted 1 line · Ksenija Stanojevic
Ok, I understand, should I post that as v4?
Yes.
julia
Quoted 248 lines · Julia Lawall
> ret = i2c_master_recv(client, value, 1); > if (ret < 0) { > - dev_dbg("saa7191_read_status(): read failed\n"); > + dev_dbg(sd->dev, "saa7191_read_status(): read failed\n"); This is a patch against your previous changes. Greg is just going to ignore that patch, since you have provided a revised one. So you need to go back to a state where your previous changes have not been made. Git checkout may be helpful. julia > return ret; > } > > @@ -141,7 +141,7 @@ static int saa7191_write_block(struct v4l2_subdev *sd, > > ret = i2c_master_send(client, data, length); > if (ret < 0) { > - dev_dbg("saa7191_write_block(): " > + dev_dbg(sd->dev, "saa7191_write_block(): " > "write failed\n"); > return ret; > } > @@ -224,9 +224,9 @@ static int saa7191_s_std(struct v4l2_subdev *sd, v4l2_std_id norm) > > decoder->norm = norm; > > - dev_dbg(&sd->dev, "ctl3: %02x stdc: %02x chcv: %02x\n", ctl3, > + dev_dbg(sd->dev, "ctl3: %02x stdc: %02x chcv: %02x\n", ctl3, > stdc, chcv); > - dev_dbg("norm: %llx\n", norm); > + dev_dbg(sd->dev, "norm: %llx\n", norm); > > return 0; > } > @@ -235,21 +235,21 @@ static int saa7191_wait_for_signal(struct v4l2_subdev *sd, u8 *status) > { > int i = 0; > > - dev_dbg("Checking for signal...\n"); > + dev_dbg(sd->dev, "Checking for signal...\n"); > > for (i = 0; i < SAA7191_SYNC_COUNT; i++) { > if (saa7191_read_status(sd, status)) > return -EIO; > > if (((*status) & SAA7191_STATUS_HLCK) == 0) { > - dev_dbg("Signal found\n"); > + dev_dbg(sd->dev, "Signal found\n"); > return 0; > } > > msleep(SAA7191_SYNC_DELAY); > } > > - dev_dbg("No signal\n"); > + dev_dbg(sd->dev, "No signal\n"); > > return -EBUSY; > } > @@ -263,7 +263,7 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm) > v4l2_std_id old_norm = decoder->norm; > int err = 0; > > - dev_dbg("SAA7191 extended signal auto-detection...\n"); > + dev_dbg(sd->dev, "SAA7191 extended signal auto-detection...\n"); > > *norm &= V4L2_STD_NTSC | V4L2_STD_PAL | V4L2_STD_SECAM; > stdc &= ~SAA7191_STDC_SECS; > @@ -295,13 +295,13 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm) > > if (status & SAA7191_STATUS_FIDT) { > /* 60Hz signal -> NTSC */ > - dev_dbg("60Hz signal: NTSC\n"); > + dev_dbg(sd->dev, "60Hz signal: NTSC\n"); > *norm &= V4L2_STD_NTSC; > return 0; > } > > /* 50Hz signal */ > - dev_dbg("50Hz signal: Trying PAL...\n"); > + dev_dbg(sd->dev, "50Hz signal: Trying PAL...\n"); > > /* try PAL first */ > err = saa7191_s_std(sd, V4L2_STD_PAL); > @@ -316,19 +316,19 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm) > > /* not 50Hz ? */ > if (status & SAA7191_STATUS_FIDT) { > - dev_dbg("No 50Hz signal\n"); > + dev_dbg(sd->dev, "No 50Hz signal\n"); > saa7191_s_std(sd, old_norm); > *norm = V4L2_STD_UNKNOWN; > return 0; > } > > if (status & SAA7191_STATUS_CODE) { > - dev_dbg("PAL\n"); > + dev_dbg(sd->dev, "PAL\n"); > *norm &= V4L2_STD_PAL; > return saa7191_s_std(sd, old_norm); > } > > - dev_dbg("No color detected with PAL - Trying SECAM...\n"); > + dev_dbg(sd->dev, "No color detected with PAL - Trying SECAM...\n"); > > /* no color detected ? -> try SECAM */ > err = saa7191_s_std(sd, V4L2_STD_SECAM); > @@ -343,19 +343,19 @@ static int saa7191_querystd(struct v4l2_subdev *sd, v4l2_std_id *norm) > > /* not 50Hz ? */ > if (status & SAA7191_STATUS_FIDT) { > - dev_dbg("No 50Hz signal\n"); > + dev_dbg(sd->dev, "No 50Hz signal\n"); > *norm = V4L2_STD_UNKNOWN; > goto out; > } > > if (status & SAA7191_STATUS_CODE) { > /* Color detected -> SECAM */ > - dev_dbg("SECAM\n"); > + dev_dbg(sd->dev, "SECAM\n"); > *norm &= V4L2_STD_SECAM; > return saa7191_s_std(sd, old_norm); > } > > - dev_dbg("No color detected with SECAM - Going back to PAL.\n"); > + dev_dbg(sd->dev, "No color detected with SECAM - Going back to PAL.\n"); > *norm = V4L2_STD_UNKNOWN; > > out: > @@ -366,30 +366,30 @@ static int saa7191_autodetect_norm(struct v4l2_subdev *sd) > { > u8 status; > > - dev_dbg("SAA7191 signal auto-detection...\n"); > + dev_dbg(sd->dev, "SAA7191 signal auto-detection...\n"); > > - dev_dbg("Reading status...\n"); > + dev_dbg(sd->dev, "Reading status...\n"); > > if (saa7191_read_status(sd, &status)) > return -EIO; > > - dev_dbg("Checking for signal...\n"); > + dev_dbg(sd->dev, "Checking for signal...\n"); > > /* no signal ? */ > if (status & SAA7191_STATUS_HLCK) { > - dev_dbg("No signal\n"); > + dev_dbg(sd->dev, "No signal\n"); > return -EBUSY; > } > > - dev_dbg("Signal found\n"); > + dev_dbg(sd->dev, "Signal found\n"); > > if (status & SAA7191_STATUS_FIDT) { > /* 60hz signal -> NTSC */ > - dev_dbg("NTSC\n"); > + dev_dbg(sd->dev, "NTSC\n"); > return saa7191_s_std(sd, V4L2_STD_NTSC); > } else { > /* 50hz signal -> PAL */ > - dev_dbg("PAL\n"); > + dev_dbg(sd->dev, "PAL\n"); > return saa7191_s_std(sd, V4L2_STD_PAL); > } > } > @@ -600,18 +600,18 @@ static int saa7191_probe(struct i2c_client *client, > > err = saa7191_write_block(sd, sizeof(initseq), initseq); > if (err) { > - dev_dbg("SAA7191 initialization failed\n"); > + dev_dbg(sd->dev, "SAA7191 initialization failed\n"); > return err; > } > > - dev_dbg("SAA7191 initialized\n"); > + dev_dbg(sd->dev, "SAA7191 initialized\n"); > > decoder->input = SAA7191_INPUT_COMPOSITE; > decoder->norm = V4L2_STD_PAL; > > err = saa7191_autodetect_norm(sd); > if (err && (err != -EBUSY)) > - dev_dbg("SAA7191: Signal auto-detection failed\n"); > + dev_dbg(sd->dev, "SAA7191: Signal auto-detection failed\n"); > > return 0; > } > -- > 1.9.1 > > -- > You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. > To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. > To post to this group, send email to [email protected]. > To view this discussion on the web visithttps://groups.google.com/d/msgid/outreachy-kernel/1424319465-2828-1-git-se nd-email-ksenija.stanojevic%40gmail.com. > For more options, visit https://groups.google.com/d/optout. >--
You received this message because you are subscribed to the Google Groups
"outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visithttps://groups.google.com/d/msgid/outreachy-kernel/609089f3-4401-4caf-b4ab- 9f56b1ac12e5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.