Forum | Documentation | Website | Blog

Skip to content
Snippets Groups Projects
Commit d941b587 authored by Kieran Bingham's avatar Kieran Bingham Committed by Greg Kroah-Hartman
Browse files

staging: vc04_services: vchiq_arm: Fix initialisation check

The vchiq_state used to be obtained through an accessor which would
validate that the VCHIQ had been initialised correctly with the remote,
or return a null state.

In commit 42a2f666 ("staging: vc04_services: Move global g_state to
vchiq_state") the global state was moved to the vchiq_mgnt structures
stored as a vchiq instance specific context. This conversion removed the
helpers and instead replaced users of this helper with the assumption
that the state is always available and the remote connected.

The conversion does ensure that the state is always available, so some
remaining state null pointer checks that remain are unnecessary, but the
assumption that the remote is present and initialised is incorrect.

Fix this broken assumption by re-introducing the logic that was lost
during the conversion.

Fixes: 42a2f666

 ("staging: vc04_services: Move global g_state to vchiq_state")
Signed-off-by: default avatarKieran Bingham <kieran.bingham@ideasonboard.com>
Reviewed-by: default avatarStefan Wahren <wahrenst@gmx.net>
Reviewed-by: default avatarUmang Jain <umang.jain@ideasonboard.com>
Link: https://lore.kernel.org/r/20240620221046.2731704-1-kieran.bingham@ideasonboard.com


Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 6ba59ff4
Branches
No related merge requests found
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment