From: Dan Carpenter <dan.carpenter@linaro.org>
To: Jai Luthra <jai.luthra@ideasonboard.com>
Cc: Florian Fainelli <florian.fainelli@broadcom.com>,
Broadcom internal kernel review list
<bcm-kernel-feedback-list@broadcom.com>,
Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
Ray Jui <rjui@broadcom.com>,
Scott Branden <sbranden@broadcom.com>,
linux-rpi-kernel@lists.infradead.org,
linux-arm-kernel@lists.infradead.org,
linux-staging@lists.linux.dev, linux-kernel@vger.kernel.org,
kernel-list@raspberrypi.com, Stefan Wahren <wahrenst@gmx.net>,
Dave Stevenson <dave.stevenson@raspberrypi.com>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>,
Kieran Bingham <kieran.bingham@ideasonboard.com>,
Phil Elwell <phil@raspberrypi.com>,
Umang Jain <uajain@igalia.com>
Subject: Re: [PATCH v3 0/7] staging: Destage VCHIQ interface and MMAL
Date: Wed, 29 Oct 2025 15:10:32 +0300 [thread overview]
Message-ID: <aQIEOJUHdVMriz7S@stanley.mountain> (raw)
In-Reply-To: <20251029-vchiq-destage-v3-0-da8d6c83c2c5@ideasonboard.com>
I did a review of some Smatch warnings. These aren't published because
they generate too many false positives. Only number 3 and number 7
are actual issues the rest are style nit-picks.
1. drivers/staging/vc04_services/interface/vchiq_arm/vchiq_core.c:2728 vchiq_add_service_internal() info: returning a literal zero is cleaner
s/return service;/return NULL;/
2. drivers/staging/vc04_services/interface/vchiq_arm/vchiq_arm.c:408 vchiq_shutdown() info: returning a literal zero is cleaner
Delete the "ret" variable.
3. drivers/staging/vc04_services/bcm2835-camera/controls.c:198 ctrl_set_iso() warn: array off by one? 'iso_values[ctrl->val]'
There seems to be a mixup between iso_qmenu[] and iso_values[]. The one
is only used for ARRAY_SIZE() and the other is never checked for
ARRAY_SIZE().
4. drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c:337 buffer_cb() warn: can 'buf' even be NULL?
Delete the NULL check.
5. drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c:513 start_streaming() pedantic: propagate return from 'enable_camera' instead of returning '-EINVAL'
- if (enable_camera(dev) < 0) {
+ ret = enable_camera(dev);
+ if (ret) {
v4l2_err(&dev->v4l2_dev, "Failed to enable camera\n");
- return -EINVAL;
+ return ret;
}
6. drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c:576 start_streaming() pedantic: propagate return from 'disable_camera' instead of returning '-EINVAL'
Same.
7. drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c:881 vidioc_querycap() error: uninitialized symbol 'major'.
drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c:881 vidioc_querycap() error: uninitialized symbol 'minor'.
No error checking on vchiq_mmal_version()
8. drivers/staging/vc04_services/bcm2835-camera/bcm2835-camera.c:1276 mmal_setup_components() info: returning a literal zero is cleaner
s/return ret;/return 0;/
regards,
dan carpenter
next prev parent reply other threads:[~2025-10-29 12:10 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-10-29 10:30 [PATCH v3 0/7] staging: Destage VCHIQ interface and MMAL Jai Luthra
2025-10-29 10:30 ` [PATCH v3 2/7] staging: vchiq_arm: Remove bcm2835_camera from vchiq Jai Luthra
2025-10-30 16:58 ` Stefan Wahren
2025-10-29 10:30 ` [PATCH v3 3/7] staging: vchiq_arm: Improve inline documentation Jai Luthra
2025-10-29 10:30 ` [PATCH v3 4/7] include: linux: Destage VCHIQ interface headers Jai Luthra
2025-10-29 10:30 ` [PATCH v3 5/7] staging: vc04_services: Cleanup VCHIQ TODO entries Jai Luthra
2025-10-30 16:48 ` Stefan Wahren
2025-10-29 10:30 ` [PATCH v3 6/7] platform/raspberrypi: Destage VCHIQ interface Jai Luthra
2025-11-05 15:00 ` Dan Carpenter
2025-11-05 15:17 ` Phil Elwell
2025-11-05 16:48 ` Dan Carpenter
2025-10-29 10:30 ` [PATCH v3 7/7] platform/raspberrypi: Destage VCHIQ MMAL driver Jai Luthra
2025-10-29 12:10 ` Dan Carpenter [this message]
2025-10-30 5:00 ` [PATCH v3 0/7] staging: Destage VCHIQ interface and MMAL Jai Luthra
[not found] ` <20251029-vchiq-destage-v3-1-da8d6c83c2c5@ideasonboard.com>
2025-10-30 16:55 ` [PATCH v3 1/7] staging: vc04_services: Drop bcm2835-camera driver Stefan Wahren
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=aQIEOJUHdVMriz7S@stanley.mountain \
--to=dan.carpenter@linaro.org \
--cc=bcm-kernel-feedback-list@broadcom.com \
--cc=dave.stevenson@raspberrypi.com \
--cc=florian.fainelli@broadcom.com \
--cc=gregkh@linuxfoundation.org \
--cc=jai.luthra@ideasonboard.com \
--cc=kernel-list@raspberrypi.com \
--cc=kieran.bingham@ideasonboard.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-rpi-kernel@lists.infradead.org \
--cc=linux-staging@lists.linux.dev \
--cc=phil@raspberrypi.com \
--cc=rjui@broadcom.com \
--cc=sbranden@broadcom.com \
--cc=uajain@igalia.com \
--cc=wahrenst@gmx.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).