Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp54308yba; Fri, 19 Apr 2019 20:15:00 -0700 (PDT) X-Google-Smtp-Source: APXvYqyduwaJ/8wmaBZ9F0ru9uxcTDah7j0BSzAwq6+pjQX32THEdQvJUSn1f7im8tr/9WLKFg/l X-Received: by 2002:a63:a18:: with SMTP id 24mr6434219pgk.332.1555730100504; Fri, 19 Apr 2019 20:15:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555730100; cv=none; d=google.com; s=arc-20160816; b=kxpqrE6BZVdGT+YUy02Hz6qksCrtQTtskmk2AQszi6utp9aLlDLwivrA+/vAdYzX9y MVW64Eh/3LxfufH+OH8m1Y6R4Z57EYU9EcrAbTHXmgiFOmBCxdArMiAV2zECBkEF7umF k1PQeD2nU4VYBHTzXWoSZdEZL7uQacV+s/qJGnTNBZB30+FedrBQNxzurKQliXYwM6Mk qj5TFPnXyh4738vXPwA2ksNXo4k+SXYnrFHUKZtaK5b8ETd2kD8nX1dPFVQxjkiegpyb c41ssyrm1P8ztB59POjw7iLyxnZjTHl61hlZ4BsGGL6ufXgONBV+IK9yx1zJVAsd0nJy SuxA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=Nsby3r1McbkZMSmZ0BcydHpE4vwRehK0xlPN+cMJu4k=; b=iRyCAbWcsqxOPw1Yz+kMu3fVaBpbAtq3NrVtsaTXRwHB9Qrg4nMW33c0vZd71uPgn9 Oz9Tq6K5jQ/XsbhuGMef6WGN6k8nBy1elel7OVS8Py/UzgKzsytYb5oNKlaybMcnoYDP PhqvpHgursroFBHvBKLCkDWwEBCV2tB08FOZPEnZVA3oeV9JF4NogryXoZwXHVUwSqjE d2bffkFfmOzPCOuS3ad6rOjTrbioAhOyoKkOFO+HDkVUdhhmV0+nx3sWLfhrRDA9wfAr T2dqjZxRD8NOorIB8avSsRtfDi/3RP62av+EfQmJ+sm+YKDvQfJF25asKHDAfEM1dH44 FH/g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=D0Az7iHb; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id y24si6716340plr.255.2019.04.19.20.14.45; Fri, 19 Apr 2019 20:15:00 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=D0Az7iHb; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726148AbfDTDMm (ORCPT + 99 others); Fri, 19 Apr 2019 23:12:42 -0400 Received: from mail-ot1-f66.google.com ([209.85.210.66]:46840 "EHLO mail-ot1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725911AbfDTDMm (ORCPT ); Fri, 19 Apr 2019 23:12:42 -0400 Received: by mail-ot1-f66.google.com with SMTP id s24so5606338otk.13 for ; Fri, 19 Apr 2019 20:12:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=Nsby3r1McbkZMSmZ0BcydHpE4vwRehK0xlPN+cMJu4k=; b=D0Az7iHb04B8XyJHQUHkwI8CbDwXf7k+3c47Wb2P1VSXZhmTpG5b9+CiAPCDo+uNB1 fHA8Kj3BvEOSWyInsSGRbZvMHxUXhNGow2UsEhLHQJoXGs+fzD2VCJ0o+3dzxSplBVjA edS06G6brffhFZal+xH6LT7rSF7SQCBGDo6tYX8fYOsOjge75Uh2KG9ZKx2JdhmMP1Oo I9yagGNmTgZ986MFG1KHKFrtBDBndn+5NVVCjYiblA+twD6HapCkMTrGLzp+5yo8ZAg9 EXWTsS5A7eSPxT97h9Wi+UyXQonxvi6gLBVszjo+k9S6Mse62EDR1Hi85RZeTgTBvtw4 Lh7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=Nsby3r1McbkZMSmZ0BcydHpE4vwRehK0xlPN+cMJu4k=; b=XfS3n9KVSBBiuQLm4kb+O3UYMdXTw9HWopX0Uh3i3+haWgaKRlV1KN+9J+MMO8pGn2 5zEiO8YHbeYj+C9BEy4jlmr8wzutAasKHDS2NAzmHYB8B5TYKHB5OcPX+I8iYR21SJun s5j9I+KwDxQyA+K2z2ZDSVtQgTRPNiTiHZ2TBJnRRaF1gvDNUpgJQFgnHzTgrcU/tPTf gCW4KBVpkIGEJwi/IXW+bKUB+NyREt5RF+8dBgNjEpM0FWtqhUEOAYXinX+9YV2kmqz4 JfQO7LfB5KxItENb7hl1CR/lgPXTIfpUi4IrXHZHzdf9gHBiipjmrK89PLdMr4xOx7LW UQ+Q== X-Gm-Message-State: APjAAAW4Y6/IdqWzwWMZLFBkv26sJSf6rFhZJgdPwKLqLBVhonygdye7 ii8EGqdy7CxigT2VpeZP8xY= X-Received: by 2002:a05:6830:1051:: with SMTP id b17mr3835750otp.341.1555729961626; Fri, 19 Apr 2019 20:12:41 -0700 (PDT) Received: from madhuleo ([2605:6000:1023:606d:151b:11be:d797:d50]) by smtp.gmail.com with ESMTPSA id 189sm2895721oii.58.2019.04.19.20.12.39 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Fri, 19 Apr 2019 20:12:40 -0700 (PDT) Date: Fri, 19 Apr 2019 22:12:38 -0500 From: Madhumitha Prabakaran To: Stefan Wahren Cc: gregkh@linuxfoundation.org, f.fainelli@gmail.com, eric@anholt.net, rjui@broadcom.com, sbranden@broadcom.com, bcm-kernel-feedback-list@broadcom.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] Staging: vc04_services: Cleanup in ctrl_set_bitrate() Message-ID: <20190420031236.GA23925@madhuleo> References: <20190419212321.7325-1-madhumithabiw@gmail.com> <2d48664a-eb36-4fcc-7bc5-b1b480dbce9a@i2se.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2d48664a-eb36-4fcc-7bc5-b1b480dbce9a@i2se.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 04/19 :49, Stefan Wahren wrote: > Hi Madhumitha, > > Am 19.04.19 um 23:23 schrieb Madhumitha Prabakaran: > > Remove unnecessary variable and replace return type. > > > > Issue suggested by Coccinelle. > > > > Signed-off-by: Madhumitha Prabakaran > > --- > > drivers/staging/vc04_services/bcm2835-camera/controls.c | 7 +------ > > 1 file changed, 1 insertion(+), 6 deletions(-) > > > > diff --git a/drivers/staging/vc04_services/bcm2835-camera/controls.c b/drivers/staging/vc04_services/bcm2835-camera/controls.c > > index e39ab5fae724..f87fa7f61db3 100644 > > --- a/drivers/staging/vc04_services/bcm2835-camera/controls.c > > +++ b/drivers/staging/vc04_services/bcm2835-camera/controls.c > > @@ -607,18 +607,13 @@ static int ctrl_set_bitrate(struct bm2835_mmal_dev *dev, > > struct v4l2_ctrl *ctrl, > > const struct bm2835_mmal_v4l2_ctrl *mmal_ctrl) > > { > > - int ret; > > struct vchiq_mmal_port *encoder_out; > > > > dev->capture.encode_bitrate = ctrl->val; > > > > encoder_out = &dev->component[MMAL_COMPONENT_VIDEO_ENCODE]->output[0]; > > > > - ret = vchiq_mmal_port_parameter_set(dev->instance, encoder_out, > > - mmal_ctrl->mmal_id, > > - &ctrl->val, sizeof(ctrl->val)); > > - ret = 0; > > - return ret; > > + return 0; > > i don't understand why we can remove here the function call. I overlooked the function call. I will fix it. > > Stefan > > > } > > > > static int ctrl_set_bitrate_mode(struct bm2835_mmal_dev *dev,