diff options
author | Russ Weight <russell.h.weight@intel.com> | 2021-03-23 15:46:50 -0700 |
---|---|---|
committer | Moritz Fischer <mdf@kernel.org> | 2021-03-24 11:15:04 -0700 |
commit | 9a8d3cda8daf54b1f8e67ccb360876379b7e7895 (patch) | |
tree | 6b3edaecfaf44801b5bba4e4428b1776ba2bd542 /drivers/fpga/dfl-afu.h | |
parent | 6f1e376cfc6864a2f46538db909bbd5253c3c146 (diff) | |
download | lwn-9a8d3cda8daf54b1f8e67ccb360876379b7e7895.tar.gz lwn-9a8d3cda8daf54b1f8e67ccb360876379b7e7895.zip |
fpga: dfl: afu: harden port enable logic
Port enable is not complete until ACK = 0. Change
__afu_port_enable() to guarantee that the enable process
is complete by polling for ACK == 0.
Signed-off-by: Russ Weight <russell.h.weight@intel.com>
Reviewed-by: Tom Rix <trix@redhat.com>
Reviewed-by: Matthew Gerlach <matthew.gerlach@linux.intel.com>
Acked-by: Wu Hao <hao.wu@intel.com>
Signed-off-by: Moritz Fischer <mdf@kernel.org>
Diffstat (limited to 'drivers/fpga/dfl-afu.h')
-rw-r--r-- | drivers/fpga/dfl-afu.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/fpga/dfl-afu.h b/drivers/fpga/dfl-afu.h index 576e94960086..e5020e2b1f3d 100644 --- a/drivers/fpga/dfl-afu.h +++ b/drivers/fpga/dfl-afu.h @@ -80,7 +80,7 @@ struct dfl_afu { }; /* hold pdata->lock when call __afu_port_enable/disable */ -void __afu_port_enable(struct platform_device *pdev); +int __afu_port_enable(struct platform_device *pdev); int __afu_port_disable(struct platform_device *pdev); void afu_mmio_region_init(struct dfl_feature_platform_data *pdata); |