X-Git-Url: https://git.kernelconcepts.de/?p=karo-tx-uboot.git;a=blobdiff_plain;f=drivers%2Fspi%2Fmxc_spi.c;h=cb48019a42b409acb8195ea3bd3cfa97f005de5d;hp=d792d8d493c13c475ec8ca03694f4efd8fde0e7f;hb=be08abc2429c2e9cbce3d0abc1d315171d683520;hpb=5eaa215607c8668bfa6a7183407eba8fec63d648 diff --git a/drivers/spi/mxc_spi.c b/drivers/spi/mxc_spi.c index d792d8d493..cb48019a42 100644 --- a/drivers/spi/mxc_spi.c +++ b/drivers/spi/mxc_spi.c @@ -137,11 +137,11 @@ static s32 spi_cfg_mxc(struct mxc_spi_slave *mxcs, unsigned int cs, return -1; } - reg_ctrl = reg_read(®s->ctrl); - /* Reset spi */ - reg_write(®s->ctrl, (reg_ctrl & ~MXC_CSPICTRL_EN)); - reg_write(®s->ctrl, (reg_ctrl | MXC_CSPICTRL_EN)); + reg_write(®s->ctrl, 0); + reg_write(®s->ctrl, MXC_CSPICTRL_EN); + + reg_ctrl = reg_read(®s->ctrl); /* * The following computation is taken directly from Freescale's code.