Samer, A platform driver can be implemented to set the policy without defining PCDs in the MdeModulePkg or NetworkPkg.
Instead, a platform package can choose to define PCDs and potentially use those PCD values to set policy in calls to the EFI_IP4_CONFIG2_POLICY or EFI_IP6_CONFIG_POLICY. Or it could be an algorithm or HII forms in platform driver to set policy. Mike > -----Original Message----- > From: edk2-devel [mailto:[email protected]] On Behalf Of > El-Haj-Mahmoud, > Samer > Sent: Wednesday, February 17, 2016 3:20 PM > To: Kinney, Michael D <[email protected]>; Wu, Jiaxin > <[email protected]>; > Subramanian, Sriram (EG Servers Platform SW) <[email protected]>; Hegde, > Nagaraj P > <[email protected]>; Zimmer, Vincent <[email protected]>; Li, > Ruth > <[email protected]>; Ye, Ting <[email protected]>; Fu, Siyuan > <[email protected]>; > [email protected] > Subject: Re: [edk2] Using PCD to set default policy for IPv4/IPv6 > > 1) Yes you could... that is one implementation choice. There are cases where > you need > to start multiple adapters, just for inventory/other management tasks, and > you do not > want all of them to default to DHCP/automatic > > 2) Yes a platform driver can set the policy through the PCDs. I thought this > was the > intention of introducing the PCDs. Previously, the policy was hard-coded to > DHCP/auto > in the EDK2 drivers. > > > > -----Original Message----- > From: Kinney, Michael D [mailto:[email protected]] > Sent: Wednesday, February 17, 2016 3:00 PM > To: El-Haj-Mahmoud, Samer <[email protected]>; Wu, Jiaxin > <[email protected]>; Subramanian, Sriram (EG Servers Platform SW) > <[email protected]>; > Hegde, Nagaraj P <[email protected]>; Zimmer, Vincent > <[email protected]>; > Li, Ruth <[email protected]>; Ye, Ting <[email protected]>; Fu, Siyuan > <[email protected]>; [email protected]; Kinney, Michael D > <[email protected]> > Subject: RE: Using PCD to set default policy for IPv4/IPv6 > > Hi Samer, > > 1) If there are a large number of adapters, can you choose to only start the > ones > needed to boot? > > 2) Can't a platform driver set the policy needed for each NIC that is > required to boot? > > Mike > > > > > -----Original Message----- > > From: edk2-devel [mailto:[email protected]] On Behalf Of > > El-Haj-Mahmoud, Samer > > Sent: Wednesday, February 17, 2016 12:53 PM > > To: Kinney, Michael D <[email protected]>; Wu, Jiaxin > > <[email protected]>; Subramanian, Sriram (EG Servers Platform SW) > > <[email protected]>; Hegde, Nagaraj P <[email protected]>; > > Zimmer, Vincent <[email protected]>; Li, Ruth > > <[email protected]>; Ye, Ting <[email protected]>; Fu, Siyuan > > <[email protected]>; [email protected] > > Subject: Re: [edk2] Using PCD to set default policy for IPv4/IPv6 > > > > I believe the PCDs are just to let the core drivers select the default > > behavior (not full configuration) of automatic/DHCP vs. Static. Today, > > the core drivers hard-code the default behavior to DHCP/automatic, and > > that is not ideal in server platforms that may have a large number of > > adapters. > > > > > > > > From: Kinney, Michael D [mailto:[email protected]] > > Sent: Wednesday, February 17, 2016 11:34 AM > > To: Wu, Jiaxin <[email protected]>; Subramanian, Sriram (EG Servers > > Platform SW) <[email protected]>; El-Haj-Mahmoud, Samer > > <[email protected]>; Hegde, Nagaraj P > > <[email protected]>; Zimmer, Vincent <[email protected]>; > > Li, Ruth <[email protected]>; Ye, Ting <[email protected]>; Fu, Siyuan > > <[email protected]>; [email protected]; Kinney, Michael D > > <[email protected]> > > Subject: RE: Using PCD to set default policy for IPv4/IPv6 > > > > Jiaxin, > > > > If a platform module can set the policy for each network interface, > > then why do we need to add PCDs? > > > > Thanks, > > > > Mike > > > > From: Wu, Jiaxin > > Sent: Tuesday, February 16, 2016 6:30 PM > > To: Kinney, Michael D > > <[email protected]<mailto:[email protected]>>; > > Subramanian, Sriram (EG Servers Platform SW) > > <[email protected]<mailto:sriram- [email protected]>>; El-Haj-Mahmoud, Samer > > <[email protected]<mailto:samer.el-haj- > > [email protected]>>; Hegde, Nagaraj P > > <[email protected]<mailto:nagaraj- > > [email protected]>>; Zimmer, Vincent > > <[email protected]<mailto:[email protected]>>; Li, Ruth > > <[email protected]<mailto:[email protected]>>; Ye, Ting > > <[email protected]<mailto:[email protected]>>; Fu, Siyuan > > <[email protected]<mailto:[email protected]>>; > > [email protected]<mailto:edk2- > > [email protected]> > > Subject: RE: Using PCD to set default policy for IPv4/IPv6 > > > > Mike, > > Thanks your comments. > > First, I agree other platform modules can also change the police by > > using the set operation. > > Second for the complete design, the proposed for the new PCDs will > > only be consumed by Ip4Dxe/Ip6Dxe modules. The PCDs are used by these > > two modules to determine the default policy, the current Ip4Dxe/Ip6Dxe > > driver will make decision which more configuration information needed > > to be also configured. So, I think this a complete design to cover the > > IPv4/Ipv6 > configuration protocol. > > > > Thanks. > > Jiaxin > > > > From: Kinney, Michael D > > Sent: Wednesday, February 17, 2016 6:10 AM > > To: Wu, Jiaxin <[email protected]<mailto:[email protected]>>; > > Subramanian, Sriram (EG Servers Platform SW) > > <[email protected]<mailto:[email protected]>>; El-Haj-Mahmoud, Samer > > <[email protected]<mailto:[email protected]>>; > > Hegde, Nagaraj P > > <[email protected]<mailto:[email protected]>>; Zimmer, > > Vincent <[email protected]<mailto:[email protected]>>; > > Li, Ruth <[email protected]<mailto:[email protected]>>; Ye, Ting > > <[email protected]<mailto:[email protected]>>; Fu, Siyuan > > <[email protected]<mailto:[email protected]>>; > > [email protected]<mailto:edk2- > > [email protected]>; Kinney, Michael D > > <[email protected]<mailto:[email protected]>> > > Subject: RE: Using PCD to set default policy for IPv4/IPv6 > > > > Jiaxin, > > > > This proposal looks incomplete to me. If the configuration policy is > > set to Ip4Config2PolicyStatic or Ip6ConfigPolicyManual, then it seems > > like a lot more configuration information would be required for the static > > or manual > policies. > > > > Can you also provide details on the complete design. What modules are > > you proposing would use these new PCDs? These configuration protocols > > provide > get/set operations. > > Why can't a platform module use the set operation to set static/manual > > policy along with the additional set operations to completely configure > > static/manual > policy? > > > > Thanks, > > > > Mike > > > > From: Wu, Jiaxin > > Sent: Monday, February 15, 2016 7:37 PM > > To: Subramanian, Sriram (EG Servers Platform SW) > > <[email protected]<mailto:sriram- [email protected]>>; El-Haj-Mahmoud, Samer > > <[email protected]<mailto:samer.el-haj- > > [email protected]>>; Hegde, Nagaraj P > > <[email protected]<mailto:nagaraj- > > [email protected]>>; Zimmer, Vincent > > <[email protected]<mailto:[email protected]>>; Kinney, > > Michael D > > <[email protected]<mailto:[email protected]>>; Li, > > Ruth <[email protected]<mailto:[email protected]>>; Ye, Ting > > <[email protected]<mailto:[email protected]>>; Fu, Siyuan > > <[email protected]<mailto:[email protected]>>; > > [email protected]<mailto:edk2- > > [email protected]> > > Subject: Using PCD to set default policy for IPv4/IPv6 > > > > Hi all, > > > > Below is the descriptions about the default policy for IPv4/IPv6 in > > latest UEFI Spec (Version 2.6). > > > > << P1472: The EFI_IP4_CONFIG2_POLICY defines the general configuration > > policy the EFI > > IPv4 Configuration II Protocol supports. The default policy for a > > newly detected communication device is beyond the scope of this > > document. An implementation might leave it to platform to choose the > > default policy.>> > > > > << P1510: The EFI_IP6_CONFIG_POLICY defines the general configuration > > policy the EFI > > IPv6 Configuration Protocol supports. The default policy for a newly > > detected communication device is beyond the scope of this document. An > > implementation might leave it to platform to choose the default > > policy.>> > > > > So, I propose to introduce PCD to leave it to platform to choose the > > default policy. > > That's meaningful to make the source code consistent with UEFI Spec. > > Detailed see > > below: > > > > ## Ip4Config2 Policy Type configuration. > > # 01 = The configuration policy is Ip4Config2PolicyStatic # 02 = The > > configuration policy is Ip4Config2PolicyDhcp # @Prompt Type Value of > > Ip4Config2 Policy. > > gEfiMdeModulePkgTokenSpaceGuid.PcdIp4Config2PolicyType|2|UINT8|0x10000 > > 002 > > > > ## Ip6Config Policy Type configuration. > > # 01 = The configuration policy is Ip6ConfigPolicyManual # 02 = The > > configuration policy is Ip6ConfigPolicyAutomatic # @Prompt Type Value > > of Ip6Config Policy. > > gEfiNetworkPkgTokenSpaceGuid.PcdIp6ConfigPolicyType|2|UINT8|0x10000002 > > > > Do you have any opinion? If there is no objection, I will create the > > corresponding patches to fix it. > > > > Thanks. > > Jiaxin > > _______________________________________________ > > edk2-devel mailing list > > [email protected] > > https://lists.01.org/mailman/listinfo/edk2-devel > _______________________________________________ > edk2-devel mailing list > [email protected] > https://lists.01.org/mailman/listinfo/edk2-devel _______________________________________________ edk2-devel mailing list [email protected] https://lists.01.org/mailman/listinfo/edk2-devel

