Skip to content

drivers: staging: bcm2835-isp: Clear LS table handle in the firmware #4952

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 25, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 13 additions & 0 deletions drivers/staging/vc04_services/bcm2835-isp/bcm2835-v4l2-isp.c
Original file line number Diff line number Diff line change
Expand Up @@ -655,6 +655,19 @@ static void bcm2835_isp_node_stop_streaming(struct vb2_queue *q)
atomic_dec(&dev->num_streaming);
/* If all ports disabled, then disable the component */
if (atomic_read(&dev->num_streaming) == 0) {
struct bcm2835_isp_lens_shading ls;
/*
* The ISP component on the firmware has a reference to the
* dmabuf handle for the lens shading table. Pass a null handle
* to remove that reference now.
*/
memset(&ls, 0, sizeof(ls));
/* Must set a valid grid size for the FW */
ls.grid_cell_size = 16;
set_isp_param(&dev->node[0],
MMAL_PARAMETER_LENS_SHADING_OVERRIDE,
&ls, sizeof(ls));

ret = vchiq_mmal_component_disable(dev->mmal_instance,
dev->component);
if (ret) {
Expand Down