Hi, Reza

I don't get your meaning about " the ChannelCount is initialized too early ". 
These drivers are UEFI driver binding drivers, which means they get initialized 
by pre-assigned order.

Why we did put SataController Driver at DuetPkg before rather than at 
PcAtChipsetPkg is because it's a platform driver and may vary at different 
platforms with different configurations. 

So I don't think moving SataController driver from Duet to PcAtChipsetPkg is a 
good idea. If you want to enable Ovmf, I would like to suggest you implement a 
similar on in Ovmf platform package.

Last, IdeBus is different story. First of all, it was obsolete at all. 
Secondly, it's a UEFI BUS driver rather than UEFI Device driver. so it could 
parse remaining device path to know with channel to be enumerated. 
AtaAtapiPassThru driver is a UEFI Device driver, which has no idea on remaining 
device path and have to use IdeInit.ChannelCount.

Thanks
Feng

-----Original Message-----
From: Reza Jelveh [mailto:reza.jel...@tuhh.de] 
Sent: Friday, August 15, 2014 18:24
To: Tian, Feng
Cc: edk2-devel@lists.sourceforge.net; ag...@suse.de
Subject: Re: [edk2] [PATCH 4/6] MdeModulePkg: IdeMode should not depend on 
SataController

On 15/08/14 04:51, Tian, Feng wrote:
> Hi, Reza
> 
> This is a reason to use IdeInit.ChannelCount rather than the constant value. 
> Some platforms may only expose one ide channel to external. By this way, we 
> can skip unnecessary enumeration time according to platform policy.
> 
> Do you see any real impact with original code?
Yes, it won't work with the original code, because the ChannelCount is 
initialized too early.

Also, the IdeBus.c works in a similar fashion to this one. It does not use 
IdeInit.ChannelCount, but instead uses IdeMaxChannel, which is defined in 
IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeData.h

------------------------------------------------------------------------------
_______________________________________________
edk2-devel mailing list
edk2-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/edk2-devel

Reply via email to