Dennis,
Thanks for the information.
One way you might do it is that since you know how big the flash memory is supposed to be (either from# defines in system.h or passed in on the command line to nios2-flash-programmer), if you find that after doing the first CFI query you've only detected a portion of the expected memory, do another CFI query beyond the address range of the first chip. In this manner you'd keep doing CFI queries until you detected the expected amount of memory, or exit with error if the additional memory is not detected.
--
Terry