]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
firmware: qcom_scm: Make __qcom_scm_is_call_available() return bool
authorStephen Boyd <swboyd@chromium.org>
Tue, 23 Feb 2021 21:45:34 +0000 (13:45 -0800)
committerKelsey Skunberg <kelsey.skunberg@canonical.com>
Mon, 24 May 2021 23:46:23 +0000 (17:46 -0600)
commit42932292fc32a9e0f1ca2175284060ae5896be17
tree0e0c1d1b593c646fbc6f973b1d980a1c10baefe0
parentfa66e131b5fc5b85dbd1e2a9b029c0fe0bc2b79c
firmware: qcom_scm: Make __qcom_scm_is_call_available() return bool

BugLink: https://bugs.launchpad.net/bugs/1929455
[ Upstream commit 9d11af8b06a811c5c4878625f51ce109e2af4e80 ]

Make __qcom_scm_is_call_available() return bool instead of int. The
function has "is" in the name, so it should return a bool to indicate
the truth of the call being available. Unfortunately, it can return a
number < 0 which also looks "true", but not all callers expect that and
thus they think a call is available when really the check to see if the
call is available failed to figure it out.

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Cc: Elliot Berman <eberman@codeaurora.org>
Cc: Brian Masney <masneyb@onstation.org>
Cc: Stephan Gerhold <stephan@gerhold.net>
Cc: Jeffrey Hugo <jhugo@codeaurora.org>
Cc: Douglas Anderson <dianders@chromium.org>
Fixes: 0f206514749b ("scsi: firmware: qcom_scm: Add support for programming inline crypto keys")
Fixes: 0434a4061471 ("firmware: qcom: scm: add support to restore secure config to qcm_scm-32")
Fixes: b0a1614fb1f5 ("firmware: qcom: scm: add OCMEM lock/unlock interface")
Signed-off-by: Stephen Boyd <swboyd@chromium.org>
Link: https://lore.kernel.org/r/20210223214539.1336155-2-swboyd@chromium.org
Signed-off-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Kelsey Skunberg <kelsey.skunberg@canonical.com>
drivers/firmware/qcom_scm.c