From patchwork Sat Sep 12 14:49:31 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Ellingsworth X-Patchwork-Id: 47075 X-Patchwork-Delegate: dougsland@redhat.com Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n8CEnXuP027528 for ; Sat, 12 Sep 2009 14:49:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754598AbZILOti (ORCPT ); Sat, 12 Sep 2009 10:49:38 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754556AbZILOth (ORCPT ); Sat, 12 Sep 2009 10:49:37 -0400 Received: from qw-out-2122.google.com ([74.125.92.27]:15620 "EHLO qw-out-2122.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754545AbZILOth (ORCPT ); Sat, 12 Sep 2009 10:49:37 -0400 Received: by qw-out-2122.google.com with SMTP id 9so632979qwb.37 for ; Sat, 12 Sep 2009 07:49:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:message-id:date:from :reply-to:user-agent:mime-version:to:subject:content-type; bh=ew/4GD3FpgaDcX6Y0UKxtjhW119ZOp+1xki8pCZhlvY=; b=hAQQ6yD0Rkn4Fik3baKV+LKrJleMuPLIYLsyEq52KTuWc4oiW3oS7/2tQExEQiysoL VnZ/S/YewP+O3QvjPIHlS1JP4xIY5SQmNHhDKOvL+keN7lsSsDZvXMt46WvEJNQso5kG vtlbMtN8xYWb7riDFaajkAbS6YmFB976rPLXQ= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:message-id:date:from:reply-to:user-agent:mime-version:to :subject:content-type; b=frOTa28vBt7ehNjhD5Ct9ZBLhU8bfu/kpugTrKJBeXjh8dFcgAgQmRJRNFja6aWwhy FmNXIm4FliXsfXwuwb6tdeCtxszm4ppePKxJqjFSNNvYbgIL2yWlLDBNFhPbg1pSf1ZU 0ir1awuK5FzPzaNREPYp9cfXzLkrbUQyCkvAs= Received: by 10.224.96.202 with SMTP id i10mr3719627qan.311.1252766980353; Sat, 12 Sep 2009 07:49:40 -0700 (PDT) Received: from ?192.168.10.110? (cpe-71-72-62-249.neo.res.rr.com [71.72.62.249]) by mx.google.com with ESMTPS id 2sm1740727qwi.56.2009.09.12.07.49.38 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sat, 12 Sep 2009 07:49:39 -0700 (PDT) Message-ID: <4AABB4FB.4050102@gmail.com> Date: Sat, 12 Sep 2009 10:49:31 -0400 From: David Ellingsworth Reply-To: david@identd.dyndns.org User-Agent: Mozilla-Thunderbird 2.0.0.22 (X11/20090701) MIME-Version: 1.0 To: linux-media@vger.kernel.org, klimov.linux@gmail.com Subject: [RFC/RFT 04/10] radio-mr800: remove unnecessary local variable Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org From f2fdb83ce649e9e69413ab533ec4a84d96850ed4 Mon Sep 17 00:00:00 2001 From: David Ellingsworth Date: Sat, 12 Sep 2009 00:19:48 -0400 Subject: [PATCH 04/10] mr800: remove unnecessary local variable Signed-off-by: David Ellingsworth --- drivers/media/radio/radio-mr800.c | 10 ++++------ 1 files changed, 4 insertions(+), 6 deletions(-) radio->videodev.release = usb_amradio_video_device_release; @@ -742,7 +740,7 @@ static int usb_amradio_probe(struct usb_interface *intf, return 0; err_vdev: - v4l2_device_unregister(v4l2_dev); + v4l2_device_unregister(&radio->v4l2_dev); err_v4l2: kfree(radio->buffer); err_nobuf: From f2fdb83ce649e9e69413ab533ec4a84d96850ed4 Mon Sep 17 00:00:00 2001 From: David Ellingsworth Date: Sat, 12 Sep 2009 00:19:48 -0400 Subject: [PATCH 04/10] mr800: remove unnecessary local variable Signed-off-by: David Ellingsworth --- drivers/media/radio/radio-mr800.c | 10 ++++------ 1 files changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/media/radio/radio-mr800.c b/drivers/media/radio/radio-mr800.c index d01b96c..fb99c6b 100644 --- a/drivers/media/radio/radio-mr800.c +++ b/drivers/media/radio/radio-mr800.c @@ -688,7 +688,6 @@ static int usb_amradio_probe(struct usb_interface *intf, const struct usb_device_id *id) { struct amradio_device *radio; - struct v4l2_device *v4l2_dev; int retval = 0; radio = kzalloc(sizeof(struct amradio_device), GFP_KERNEL); @@ -707,16 +706,15 @@ static int usb_amradio_probe(struct usb_interface *intf, goto err_nobuf; } - v4l2_dev = &radio->v4l2_dev; - retval = v4l2_device_register(&intf->dev, v4l2_dev); + retval = v4l2_device_register(&intf->dev, &radio->v4l2_dev); if (retval < 0) { dev_err(&intf->dev, "couldn't register v4l2_device\n"); goto err_v4l2; } - strlcpy(radio->videodev.name, v4l2_dev->name, + strlcpy(radio->videodev.name, radio->v4l2_dev.name, sizeof(radio->videodev.name)); - radio->videodev.v4l2_dev = v4l2_dev; + radio->videodev.v4l2_dev = &radio->v4l2_dev; radio->videodev.fops = &usb_amradio_fops; radio->videodev.ioctl_ops = &usb_amradio_ioctl_ops; radio->videodev.release = usb_amradio_video_device_release; @@ -742,7 +740,7 @@ static int usb_amradio_probe(struct usb_interface *intf, return 0; err_vdev: - v4l2_device_unregister(v4l2_dev); + v4l2_device_unregister(&radio->v4l2_dev); err_v4l2: kfree(radio->buffer); err_nobuf: -- 1.6.3.3