v2 is merged. Bruce
In message: [v2][inux-yocto][v5.10/standard/intel-sdk-5.10/intel-socfpga & v5.10/standard/preempt-rt/intel-sdk-5.10/intel-socfpga] HSD #14017114324: fpga: stratix10-soc: wait for COMMAND_FIRMWARE_VERSION to complete on 22/03/2023 Kang Wenlin wrote: > From: Teh Wen Ping <[email protected]> > > commit b575e6b93a77c42ea31af0787347d5b3cc67fff4 from > https://github.com/altera-opensource/linux-socfpga.git > > With the introduction of stratix10_svc_done(), all SMC call has to be > completed before calling stratix10_svc_done(). The driver is missing a > wait_for_completion_timeout() after requesting for > COMMAND_FIRMWARE_VERSION. This cause SVC driver to stop its thread before > COMMAND_FIRMWARE_VERSION is complete. Thus, the driver will receive > invalid firmware version. > > Signed-off-by: Teh Wen Ping <[email protected]> > Signed-off-by: Wenlin Kang <[email protected]> > --- > drivers/fpga/stratix10-soc.c | 12 ++++++++++++ > 1 file changed, 12 insertions(+) > > diff --git a/drivers/fpga/stratix10-soc.c b/drivers/fpga/stratix10-soc.c > index 225a1211ba62..ca253ee400cb 100644 > --- a/drivers/fpga/stratix10-soc.c > +++ b/drivers/fpga/stratix10-soc.c > @@ -496,6 +496,18 @@ static int s10_probe(struct platform_device *pdev) > goto probe_err; > } > > + ret = wait_for_completion_timeout( > + &priv->status_return_completion, S10_RECONFIG_TIMEOUT); > + if (!ret) { > + dev_err(dev, "timeout waiting for firmware version\n"); > + stratix10_svc_done(priv->chan); > + fpga_mgr_free(mgr); > + ret = -ETIMEDOUT; > + goto probe_err; > + } > + > + ret = 0; > + > stratix10_svc_done(priv->chan); > platform_set_drvdata(pdev, mgr); > return ret; > -- > 2.17.1 >
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#12302): https://lists.yoctoproject.org/g/linux-yocto/message/12302 Mute This Topic: https://lists.yoctoproject.org/mt/97769992/21656 Group Owner: [email protected] Unsubscribe: https://lists.yoctoproject.org/g/linux-yocto/leave/6687884/21656/624485779/xyzzy [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
