Hi Christie Su
Yes, the problem is in the linker file. There is a part in the linker file that assigned ram size for usb to initialized this in the .bss section:
USB_RAM_GAP = DEFINED(__usb_ram_size__) ? __usb_ram_size__ : 0x00;
So if you have defined symbol __usb_ram_size__ it will use it in USB_RAM_GAP, but if not, it will assigned 0x00. If you check linker settings in the example code, you can see that they defined the symbol with the flag "defsym"

But you don't have this linker flag in your settings, so linker file assigned 0x00 to USB_RAM_GAP, and when USB_DeviceClassInit try to allocate memory for usb, it doesn't have size in the .bss section.
You have two options, you could add this flag in your linker flags settings "-Xlinker -defsym=__usb_ram_size__=0x800", or you could change the linker file:
USB_RAM_GAP = DEFINED(__usb_ram_size__) ? __usb_ram_size__ : 0x800;
(Note: this is how it is defined in the earlier KSDK 2.0 release)
I made this change in your project and it works now, so give it a try and tell me if it works.
Have a great day,
Jorge Alcala
-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------