Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp633823yba; Sat, 20 Apr 2019 09:59:36 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvQNbyXr36IIdo/qfjYiSWeT89pIqlfCvAMtSTPgiLN8BkolqYsC3SklI9MRPOo0aqukIo X-Received: by 2002:aa7:86ce:: with SMTP id h14mr10684807pfo.84.1555779576099; Sat, 20 Apr 2019 09:59:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555779576; cv=none; d=google.com; s=arc-20160816; b=xNrzKucfRQKR8mB+evrwi/T4NKuCWYk+NX1gjQq7CXasmIpLolh1eG5TTTJtOxjodP nmpy/TrniH99YLwdkKMDjRUDYfxc3oD89lv8+eIj1JHziLPdIA12cOzqwBqKq9vvtpox 414lSEiDIAbjFwxfHp2yg+hkzvdnCBwc+o2V0Yq8oB6jv/gmN8PGe/mg05TVX7Wqbt59 t1zXPBnn4ac0BNjpEBQJr9PoDyrnEppZzbup0uu3bjUTkoIbiBKK2ng+hmwf8nFoKKSj 83tVYpL/rzxAOT5Il7EdjkUwMM/K8AosyNIiAVAJBXvbloK1Hh2eTs4g7UF0FwPnCbHi mPHw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from :dkim-signature; bh=oThT7uOJYj+D0UqYv7lT6L2LxoANKCg7LyACp/+if0s=; b=NdBOveMJ/JBCVXBS04A1lvdX4ZYczxI5fD1g21L8jYpRP+r6DF1SvqkNxEgCUc3tqL /99fXE/JgJx0OTQ9BtXdX++IDd6GAxigvAfjyzGmc85kzRlBB74yGykSjwT9hrJ+v994 aGEeCBlItUA2qIrT5jA3LH+fHmXbxtJmZnYyaWf7UcfP5D3oJCgZUDGrOTfOVBWk1kJM n0cttNMISyuFn+MbMPMi8FckSBKpKMVHL8oTR5S7hISnEbv1M++lB3F/v5q8j9u6jyo2 JF+tpfiN4KENpLg3KAoexJ8OCIwzazF1TorVRHeKAqGCzof+ZeLv6PEVCVktdVTp+sSC mb6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=SOYRxci5; 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 q11si3588762pll.181.2019.04.20.09.59.20; Sat, 20 Apr 2019 09:59:36 -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=SOYRxci5; 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 S1728409AbfDTQ4w (ORCPT + 99 others); Sat, 20 Apr 2019 12:56:52 -0400 Received: from mail-ot1-f66.google.com ([209.85.210.66]:45990 "EHLO mail-ot1-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726334AbfDTQ4w (ORCPT ); Sat, 20 Apr 2019 12:56:52 -0400 Received: by mail-ot1-f66.google.com with SMTP id e5so6510810otk.12 for ; Sat, 20 Apr 2019 09:56:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=oThT7uOJYj+D0UqYv7lT6L2LxoANKCg7LyACp/+if0s=; b=SOYRxci5ZsYcqpFBMNbq2HW5IhcQbkHUznBK1kzDFmcTe0OU3HhmeZMmKt70xetYzy WdEjsXaYT7IPmKv7d1lOr/zvuHoDJlWPHQKJCq+icDpdQQiECaa85RVNJ92B35rdI6PL QMrjMdzbjLw4HQ01o4KsQL1EhvgICRQbRtcOoH7OrkBohP8DzsxBwRfpbH9XySq+praO X3BR3o6AY9tbvXCBgeemlT5W90IJ2Ac3DQWf4YdIAnv8hxlQ17/aUDr2PJFa4+Q3Vvcw iNaQ/eR/CoIQeXwEKcARZUtu0OADNhrnFznA+8PybhiceTZRoFE/O/FIIu0zKCBP/FcQ BwvQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=oThT7uOJYj+D0UqYv7lT6L2LxoANKCg7LyACp/+if0s=; b=sG83ytU+obXXyxgS2ExMPY4HuEXbuNueg0o1N6mWUJrR6fVg8qhkz2n10Ri05HJwRr u6+P0HpRiX6/rKYUfsNGrv7IslTORcTTH4iaN6RuQQczr1SXN8uinPyTLsNFs5uV7tN6 PtVI+aPD/SLSk+0qqRq+tEls1lFsrOaHEBl1IHYVUjqcCPN1ArjGOJfUPu5zZ23obkss TXSpH8xllZxELTu2OQoXYPB8E22c70E032N8XhRtSgxuwstN8yvOsxBhDMf82gWnUlaU /cSoSRsT4oMOROUZUy1hmm+fDCjAxGgoT0vxDN07bLvMhDpSkKHLjdNGAWyQ+LmYi3px FDCg== X-Gm-Message-State: APjAAAXbNOEjHPGtCaR3y1cRXYtz4XZwkoY5ZLsuiLKnCFJqYe4gDs0F R8osXFVekhKVK0sBE6JQWaU= X-Received: by 2002:a9d:4799:: with SMTP id b25mr5861103otf.264.1555779411562; Sat, 20 Apr 2019 09:56:51 -0700 (PDT) Received: from madhuleo ([2605:6000:1023:606d:151b:11be:d797:d50]) by smtp.gmail.com with ESMTPSA id o1sm3740746otj.11.2019.04.20.09.56.50 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 20 Apr 2019 09:56:50 -0700 (PDT) From: Madhumitha Prabakaran To: eric@anholt.net, stefan.wahren@i2se.com, gregkh@linuxfoundation.org, f.fainelli@gmail.com, 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 Cc: Madhumitha Prabakaran Subject: [PATCH v2] Staging: vc04_services: Cleanup in ctrl_set_bitrate() Date: Sat, 20 Apr 2019 11:56:44 -0500 Message-Id: <20190420165644.11892-1-madhumithabiw@gmail.com> X-Mailer: git-send-email 2.17.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Remove unnecessary variable and replace return type. In addition to that align the function parameters with parentheses to maintain Linux coding style. Issue suggested by Coccinelle. Signed-off-by: Madhumitha Prabakaran --- Changes in v2 1) Fix my own error of removing function call from the variable. 2) Align the function parameters with parentheses. --- --- .../staging/vc04_services/bcm2835-camera/controls.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/staging/vc04_services/bcm2835-camera/controls.c b/drivers/staging/vc04_services/bcm2835-camera/controls.c index e39ab5fae724..71eb349c3138 100644 --- a/drivers/staging/vc04_services/bcm2835-camera/controls.c +++ b/drivers/staging/vc04_services/bcm2835-camera/controls.c @@ -607,18 +607,16 @@ 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; + vchiq_mmal_port_parameter_set(dev->instance, encoder_out, + mmal_ctrl->mmal_id, &ctrl->val, + sizeof(ctrl->val)); + return 0; } static int ctrl_set_bitrate_mode(struct bm2835_mmal_dev *dev, -- 2.17.1