From patchwork Wed Jan 5 20:35:45 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gaston Gonzalez X-Patchwork-Id: 12704699 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 1103FC433EF for ; Wed, 5 Jan 2022 20:38:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-Id:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=eFX2n3QHb1vXOSk+rz+484X/YKR1of05VWZ38Q6L4V8=; b=saOTdHnPVw2Wph a/K4a8HzPhPi/l/C/6z6bXPexfKEstrEtza6EAhMRj4qfT4FrY/uhAsUOL/FDIkCGVSghnr620suf Adpi7Xk1Vudmzg/MaHFj05JElPNuCt86bkGx4/fi0Ju4GdaDgJMAc2mHWVlKRZC+DzcGOjd6/9KFW zXHUtTA5bXbR4PFwWttXiok2h5DTkGnUTEo73AyYAXeBtyWMOqgU2Tac+6/IaZdvh0qRz6ubDmBsh DUMKpmqPuK7hr4le6t4Wu3AZAxgAUzTLhZ+Sn5n4bmQkT6H2V6ID941LTSGvrXaUhpkdvo9BEfWfC IZAmE80+shS0qbIiUG3w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1n5D23-00Flz0-7q; Wed, 05 Jan 2022 20:37:15 +0000 Received: from mail-vk1-xa2b.google.com ([2607:f8b0:4864:20::a2b]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1n5D1k-00Flq1-PO; Wed, 05 Jan 2022 20:36:58 +0000 Received: by mail-vk1-xa2b.google.com with SMTP id u1so374791vkn.10; Wed, 05 Jan 2022 12:36:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=w8EkkzNdsrnEqk2YciotM6EW2MTmAWF34zyjUlKhtkA=; b=ZNc0HGk+uxnzavqym+yTYhAXq6lmiJDpCdpKcUPhQpQ/v2s4ijDX9M5lpO0rIoGrpJ LM7uKW7jEV7HAOHBSFUeXVXpWz64sVUn1X5MKD6cgMaaDg73+OvohMoBQj6LbL8tE1Am Lrs9k7h8tjjT6wj3JHf8VNAECHiuhnZuazD3uMpQ8nb6Sbe+HhcCxNyGTy3/VbJHow0k qjGgN2oGeRHbSncqbVdp8Wk/gf/RBr/87y5qT1nPinyl1+SCL24kBbP27F7+2TTyiTgp gbxEL2khEgn6GbzZHNCV9ey9U2ybbpJ11eIDxpqA3+zAjG+l2pHyHbvtS7FXoF4vybsh WZpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=w8EkkzNdsrnEqk2YciotM6EW2MTmAWF34zyjUlKhtkA=; b=k8+paaCTRFeKL/HZtooEJYkYVjAFKxpR72PlD1mRsBoHTax6HXelAH2m4zcQ6c6UwB SNk8iWNYk7JUdnPq7HuvMcUh1ral9q9JyPULL+Y7myOmmzsGlEQspvbdLS3+k52qBtaw RSYnVkxli4kNz9GxjZt2PprZywY6fhxzxJDWfxwWZXMWUVlGQ/H7YDWkT/b/4pZYMRzo B2I3ZwVP9t4bz4LA45he+9O31Tz/XkRPmsiF9Vnl6rXY4R3Blk31AFhkYhpLpkcTd8F2 UqPDkfAMkvsmmvgPqtHV0nUEBGWKBdSpqIDgIWuDGW3PbUJQshCkg1Fkz6vH3aRr8kiF NnOA== X-Gm-Message-State: AOAM530IUZHg6aQZMq3Hs13Y/p2wKLPKmFgGYniQpalJxm32Fc8FPZ2R YIgPnHJTxtaDD5VF2jjddaM= X-Google-Smtp-Source: ABdhPJwhC9Ue0swAVd5zzL/J9JY/4NkVzVDYQvA6vAzqJIfw57q1jDgz+w3yei7bb9hr/ez3NXKRBg== X-Received: by 2002:a05:6122:8c6:: with SMTP id 6mr18487538vkg.33.1641415012981; Wed, 05 Jan 2022 12:36:52 -0800 (PST) Received: from localhost.localdomain ([181.22.170.52]) by smtp.gmail.com with ESMTPSA id t130sm7860vkc.32.2022.01.05.12.36.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 Jan 2022 12:36:52 -0800 (PST) From: Gaston Gonzalez To: linux-staging@lists.linux.dev Cc: gregkh@linuxfoundation.org, nsaenz@kernel.org, f.fainelli@gmail.com, rjui@broadcom.com, sbranden@broadcom.com, juerg.haefliger@canonical.com, rdunlap@infradead.org, dave.stevenson@raspberrypi.com, stefan.wahren@i2se.com, unixbhaskar@gmail.com, mitaliborkar810@gmail.com, phil@raspberrypi.com, len.baker@gmx.com, linux-rpi-kernel@lists.infradead.org, linux-arm-kernel@lists.infradead.org, bcm-kernel-feedback-list@broadcom.com, linux-kernel@vger.kernel.org, gascoar@gmail.com Subject: [PATCH 3/6] staging: vc04_services: rename variables containing bm2835_* to bcm2835_* Date: Wed, 5 Jan 2022 17:35:45 -0300 Message-Id: X-Mailer: git-send-email 2.34.1 In-Reply-To: References: MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220105_123656_861612_03B98E46 X-CRM114-Status: GOOD ( 13.21 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org In the kernel, all names related to the chip BCM2835 are always named bcm2835_*. To avoid confusion, and to make things more consistent, rename all variables using bm2835_* to bcm2835_*. While at it, some realignments were made to improve readability. Suggested-by: Stefan Wahren Signed-off-by: Gaston Gonzalez --- .../bcm2835-camera/bcm2835-camera.c | 4 +-- .../vc04_services/bcm2835-camera/controls.c | 31 +++++++------------ 2 files changed, 14 insertions(+), 21 deletions(-) diff --git a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c index 159ac600d11e..cbc881e19f65 100644 --- a/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c +++ b/drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c @@ -654,7 +654,7 @@ static void stop_streaming(struct vb2_queue *vq) v4l2_err(&dev->v4l2_dev, "Failed to disable camera\n"); } -static const struct vb2_ops bm2835_mmal_video_qops = { +static const struct vb2_ops bcm2835_mmal_video_qops = { .queue_setup = queue_setup, .buf_init = buffer_init, .buf_prepare = buffer_prepare, @@ -1930,7 +1930,7 @@ static int bcm2835_mmal_probe(struct platform_device *pdev) q->io_modes = VB2_MMAP | VB2_USERPTR | VB2_READ; q->drv_priv = dev; q->buf_struct_size = sizeof(struct vb2_mmal_buffer); - q->ops = &bm2835_mmal_video_qops; + q->ops = &bcm2835_mmal_video_qops; q->mem_ops = &vb2_vmalloc_memops; q->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_MONOTONIC; q->lock = &dev->mutex; diff --git a/drivers/staging/vc04_services/bcm2835-camera/controls.c b/drivers/staging/vc04_services/bcm2835-camera/controls.c index 08fadc164b02..178fb310b89a 100644 --- a/drivers/staging/vc04_services/bcm2835-camera/controls.c +++ b/drivers/staging/vc04_services/bcm2835-camera/controls.c @@ -58,7 +58,7 @@ static const u32 iso_values[] = { 0, 100, 200, 400, 800, }; -enum bm2835_mmal_ctrl_type { +enum bcm2835_mmal_ctrl_type { MMAL_CONTROL_TYPE_STD, MMAL_CONTROL_TYPE_STD_MENU, MMAL_CONTROL_TYPE_INT_MENU, @@ -67,7 +67,7 @@ enum bm2835_mmal_ctrl_type { struct bcm2835_mmal_v4l2_ctrl { u32 id; /* v4l2 control identifier */ - enum bm2835_mmal_ctrl_type type; + enum bcm2835_mmal_ctrl_type type; /* control minimum value or * mask for MMAL_CONTROL_TYPE_STD_MENU */ @@ -903,7 +903,7 @@ static int bcm2835_mmal_s_ctrl(struct v4l2_ctrl *ctrl) return ret; } -static const struct v4l2_ctrl_ops bm2835_mmal_ctrl_ops = { +static const struct v4l2_ctrl_ops bcm2835_mmal_ctrl_ops = { .s_ctrl = bcm2835_mmal_s_ctrl, }; @@ -1323,12 +1323,9 @@ int bcm2835_mmal_init_controls(struct bcm2835_mmal_dev *dev, struct v4l2_ctrl_ha switch (ctrl->type) { case MMAL_CONTROL_TYPE_STD: - dev->ctrls[c] = - v4l2_ctrl_new_std(hdl, - &bm2835_mmal_ctrl_ops, - ctrl->id, ctrl->min, - ctrl->max, ctrl->step, - ctrl->def); + dev->ctrls[c] = v4l2_ctrl_new_std(hdl, &bcm2835_mmal_ctrl_ops, + ctrl->id, ctrl->min, ctrl->max, + ctrl->step, ctrl->def); break; case MMAL_CONTROL_TYPE_STD_MENU: @@ -1352,20 +1349,16 @@ int bcm2835_mmal_init_controls(struct bcm2835_mmal_dev *dev, struct v4l2_ctrl_ha mask = ~mask; } - dev->ctrls[c] = - v4l2_ctrl_new_std_menu(hdl, - &bm2835_mmal_ctrl_ops, - ctrl->id, ctrl->max, - mask, ctrl->def); + dev->ctrls[c] = v4l2_ctrl_new_std_menu(hdl, &bcm2835_mmal_ctrl_ops, + ctrl->id, ctrl->max, mask, + ctrl->def); break; } case MMAL_CONTROL_TYPE_INT_MENU: - dev->ctrls[c] = - v4l2_ctrl_new_int_menu(hdl, - &bm2835_mmal_ctrl_ops, - ctrl->id, ctrl->max, - ctrl->def, ctrl->imenu); + dev->ctrls[c] = v4l2_ctrl_new_int_menu(hdl, &bcm2835_mmal_ctrl_ops, + ctrl->id, ctrl->max, + ctrl->def, ctrl->imenu); break; case MMAL_CONTROL_TYPE_CLUSTER: