Commit 161db575 authored by Moritz Fischer's avatar Moritz Fischer Committed by Greg Kroah-Hartman

fpga: region: Add fpga-region property 'encrypted-fpga-config'

Add fpga-region property to allow passing the fact that the bitstream is
encrypted to the fpga-region and ultimately to the low-level driver.
Signed-off-by: default avatarMoritz Fischer <mdf@kernel.org>
Acked-by: default avatarMichal Simek <michal.simek@xilinx.com>
Signed-off-by: default avatarAlan Tull <atull@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 7f33bbca
...@@ -186,6 +186,7 @@ Optional properties: ...@@ -186,6 +186,7 @@ Optional properties:
otherwise full reconfiguration is done. otherwise full reconfiguration is done.
- external-fpga-config : boolean, set if the FPGA has already been configured - external-fpga-config : boolean, set if the FPGA has already been configured
prior to OS boot up. prior to OS boot up.
- encrypted-fpga-config : boolean, set if the bitstream is encrypted
- region-unfreeze-timeout-us : The maximum time in microseconds to wait for - region-unfreeze-timeout-us : The maximum time in microseconds to wait for
bridges to successfully become enabled after the region has been bridges to successfully become enabled after the region has been
programmed. programmed.
......
...@@ -337,8 +337,9 @@ static int child_regions_with_firmware(struct device_node *overlay) ...@@ -337,8 +337,9 @@ static int child_regions_with_firmware(struct device_node *overlay)
* The overlay must add either firmware-name or external-fpga-config property * The overlay must add either firmware-name or external-fpga-config property
* to the FPGA Region. * to the FPGA Region.
* *
* firmware-name : program the FPGA * firmware-name : program the FPGA
* external-fpga-config : FPGA is already programmed * external-fpga-config : FPGA is already programmed
* encrypted-fpga-config : FPGA bitstream is encrypted
* *
* The overlay can add other FPGA regions, but child FPGA regions cannot have a * The overlay can add other FPGA regions, but child FPGA regions cannot have a
* firmware-name property since those regions don't exist yet. * firmware-name property since those regions don't exist yet.
...@@ -373,6 +374,9 @@ static int fpga_region_notify_pre_apply(struct fpga_region *region, ...@@ -373,6 +374,9 @@ static int fpga_region_notify_pre_apply(struct fpga_region *region,
if (of_property_read_bool(nd->overlay, "external-fpga-config")) if (of_property_read_bool(nd->overlay, "external-fpga-config"))
info->flags |= FPGA_MGR_EXTERNAL_CONFIG; info->flags |= FPGA_MGR_EXTERNAL_CONFIG;
if (of_property_read_bool(nd->overlay, "encrypted-fpga-config"))
info->flags |= FPGA_MGR_ENCRYPTED_BITSTREAM;
of_property_read_string(nd->overlay, "firmware-name", &firmware_name); of_property_read_string(nd->overlay, "firmware-name", &firmware_name);
of_property_read_u32(nd->overlay, "region-unfreeze-timeout-us", of_property_read_u32(nd->overlay, "region-unfreeze-timeout-us",
......
Markdown is supported
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