Welcome in the forum.
"Q : Cause of the low speed of write flash directly with "spi serial communication block" This might be a language problem, so can you please tell us a bit more what you exactly mean. Writing to flash using DMA is not possible and the question is why you want to write to flash at all:
Sorry, my crystal ball is currently in repair, but I can make an assumption: you want to write to a SPI Flash memory chip (S25FL128). We would need to look at your code to determine why you think SPI communication is slow. You can be quite efficient when sending data via SPI, when using the FIFO (basically as fast as you can write a look checking a flag and putting a byte into memory).
When you want to use DMA: the source address needs to be incremented so you transfer the complate buffer. Start at the beginning of your buffer, and set the transfer count to the size of your buffer (e.g. 256 bytes). The destination address is the FIFO register of the SPI master. Read the documentation of the DMA component, it explains all the needed API calls.
Using google for 'psoc spi dma' I find two app notes regarding SPI master and DMA. Altough they are for PSoC3/5, the principle should be clear.
you are right,that's what i want to do.when i try to eraseall the flash ,but failed.please see the code below:
It could be you are getting stuck in one of the two loops?
Also, you can check the RX buffer and see if any return data is received.