Yes, you are right in that it is not possible to detect LPDDR2 chip model and appropriately configure MMDC by uboot since in that case there is a contradiction: uboot cannot be started until the memory is initialized, but the memory cannot be initialized until uboot detects the memory type...
Another way of implementing your task is to write a small piece of code that is loaded into the processor's internal SRAM, then it detects and appropriately initializes LPDDR2 and then loads the rest of the code (e.g. uboot) there.
Unfortunately, we don't have a ready-to-use solution for that.
Have a great day,
Artur
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------