spi: dspi: clear SPI_SR before enable interrupt
authorYuan Yao <yao.yuan@nxp.com>
Mon, 17 Oct 2016 10:02:34 +0000 (18:02 +0800)
committerMark Brown <broonie@kernel.org>
Sat, 29 Oct 2016 18:51:29 +0000 (12:51 -0600)
commit5ee67b587a2b0092bdea3123349c8c3c43e8e46e
treeef87489bfc36118b99e15e5ac42ff06f83baed0d
parent1001354ca34179f3db924eb66672442a173147dc
spi: dspi: clear SPI_SR before enable interrupt

Once dspi is used in uboot, the SPI_SR have been set by some value.
At this time, if kernel enable the interrupt before clear the
status flag, that will trigger the wrong interrupt.

Signed-off-by: Yuan Yao <yao.yuan@nxp.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi-fsl-dspi.c