[media] pwc: Remove software emulation of arbritary resolutions

The pwc driver claims to support any resolution between 160x120
and 640x480, but emulates this by simply drawing a black border
around the image. Userspace can draw its own black border if it
really wants one.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
diff --git a/drivers/media/video/pwc/pwc-dec23.c b/drivers/media/video/pwc/pwc-dec23.c
index e531f85..2c67091 100644
--- a/drivers/media/video/pwc/pwc-dec23.c
+++ b/drivers/media/video/pwc/pwc-dec23.c
@@ -656,10 +656,6 @@
  *
  * Uncompress a pwc23 buffer.
  *
- * pwc.view: size of the image wanted
- * pwc.image: size of the image returned by the camera
- * pwc.offset: (x,y) to displayer image in the view
- *
  * src: raw data
  * dst: image output
  */
@@ -667,7 +663,7 @@
 			  const void *src,
 			  void *dst)
 {
-	int bandlines_left, stride, bytes_per_block;
+	int bandlines_left, bytes_per_block;
 	struct pwc_dec23_private *pdec = pwc->decompress_data;
 
 	/* YUV420P image format */
@@ -678,28 +674,23 @@
 
 	mutex_lock(&pdec->lock);
 
-	bandlines_left = pwc->image.y / 4;
-	bytes_per_block = pwc->view.x * 4;
-	plane_size = pwc->view.x * pwc->view.y;
+	bandlines_left = pwc->height / 4;
+	bytes_per_block = pwc->width * 4;
+	plane_size = pwc->height * pwc->width;
 
-	/* offset in Y plane */
-	stride = pwc->view.x * pwc->offset.y;
-	pout_planar_y = dst + stride + pwc->offset.x;
-
-	/* offsets in U/V planes */
-	stride = (pwc->view.x * pwc->offset.y) / 4 + pwc->offset.x / 2;
-	pout_planar_u = dst + plane_size + stride;
-	pout_planar_v = dst + plane_size + plane_size / 4 + stride;
+	pout_planar_y = dst;
+	pout_planar_u = dst + plane_size;
+	pout_planar_v = dst + plane_size + plane_size / 4;
 
 	while (bandlines_left--) {
 		DecompressBand23(pwc->decompress_data,
 				 src,
 				 pout_planar_y, pout_planar_u, pout_planar_v,
-				 pwc->image.x, pwc->view.x);
+				 pwc->width, pwc->width);
 		src += pwc->vbandlength;
 		pout_planar_y += bytes_per_block;
-		pout_planar_u += pwc->view.x;
-		pout_planar_v += pwc->view.x;
+		pout_planar_u += pwc->width;
+		pout_planar_v += pwc->width;
 	}
 	mutex_unlock(&pdec->lock);
 }