All, I would like to propose 3 new UserExtensions in the INF specification. These would be optional sections that can be used to convey additional information about the module. This additional meta data is not expected to be used by the build. This is used by additional tools to help verify DSC functionality and completeness. Modules that will not function based on the contents of the flash image could for example be easily identified.
Please respond with comments/objections/suggestions by next Friday June 17th. 1) BY_START / TO_START interaction Currently the Protocols that are produced or consumed by the driver are marked as such in the INF file [Protocols] section, but there is no information on the interactions between these protocols. This extension would allow the conveying of complex interactions to fully describe the meaning behind the TO_START and BY_START tags in the [Protocols] section. The syntax for this section is proposed as: [UserExtensions.TianoCore."ByStartExpressions"] <BY_START Protocol Id> "|" <Expression> Where Expression uses Protocols marked TO_START, PCDs from the [Pcd] section of this INF file, and standard operators per the EDKII Expression Syntax document. Each entry evaluates to TRUE or FALSE and if any expression evaluates to TRUE, then that Protocol will be produced in the DriverBinding Start(). Here is a valid example for a file system driver. The additional information that is conveyed here is that BlockIo and DiskIo are both required, but only one of UnicodeCollation and UnicodeCollation2 are required. Otherwise, the meta data requires both UC and UC2 for DriverBinding Start() to be successful. [Protocols] gEfiDiskIoProtocolGuid ## TO_START gEfiBlockIoProtocolGuid ## TO_START gEfiSimpleFileSystemProtocolGuid ## BY_START gEfiUnicodeCollationProtocolGuid ## TO_START gEfiUnicodeCollation2ProtocolGuid ## TO_START [UserExtensions.TianoCore."ByStartExpressions"] gEfiSimpleFileSystemProtocolGuid | gEfiBlockIoProtocolGuid AND gEfiDiskIoProtocolGuid AND (gEfiUnicodeCollationProtocolGuid OR gEfiUnicodeCollation2ProtocolGuid) 2) SOMETIMES_CONSUMES additional information. Currently Protocols/PPI/GUIDs are marked as UNDEFINED or SOMETIMES_CONSUMES with no way to know whether these will be consumed (thus required). This section would have information to define which would be consumed based on other data. The syntax for this section is proposed as: [UserExtensions.TianoCore."ConsumesExpressions"] <Expression> Where Expression uses items marked UNDEFINED or SOMETIMES_CONSUMES, PCDs from the [Pcd] section of this INF file, and standard operators per the EDKII Expression Syntax document. Each entry is evaluated individually as a Boolean and if any one evaluate to FALSE, then the module will not function due to missing dependencies. Here is an example. The additional information that is conveyed here is that one of Performance and PerformanceEx is required, but not both. [Guids] gPerformanceProtocolGuid ## SOMETIMES_CONSUMES gPerformanceExProtocolGuid ## SOMETIMES_CONSUMES [UserExtensions.TianoCore."ConsumesExpressions"] gPerformanceProtocolGuid OR gPerformanceExProtocolGuid 3) SOMETIMES_PRODUCES additional information. Currently Protocols/PPI/GUIDs are marked as SOMETIMES_PRODUCES with no way to know when these will be produced. This section would have information to define which would be produced based on other data. The syntax for this section is proposed as: [UserExtensions.TianoCore."ProducesExpressions"] <PRODUCES Id> "|" <Expression> Where Expression uses items marked SOMETIMES_PRODUCES, PCDs from the [Pcd] section of this INF file, and standard operators per the EDKII Expression Syntax document. Each entry evaluates to TRUE or FALSE and if any expression evaluates to TRUE, then that item will be produced. Here is an example. The additional information that is conveyed here is that one of gEfiDiskInfoIdeInterfaceGuid is produced if gEfiDiskInfoProtocolGuid is present (or produced). [Guids] gEfiDiskInfoIdeInterfaceGuid ## SOMETIMES_PRODUCES [Protocols] gEfiDiskInfoProtocolGuid ## BY_START [UserExtensions.TianoCore."ProducesExpressions"] gEfiDiskInfoIdeInterfaceGuid | gEfiDiskInfoProtocolGuid _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel