• Grazvydas Ignotas's avatar
    wl1251: fix ELP_CTRL register reads · 832c10fd
    Grazvydas Ignotas authored
    Reading the ELP_CTRL register with sdio_readb causes problems because
    hardware seems to be performing a write using stuff bits in the request
    (those bits contain write data in write request). This indicates that it
    actually expects RAW (read after write) type of request, so perform that
    when reading ELP_CTRL instead. Also cache last written value so we know
    what to write when doing RAW request.
    
    Because of the above it was not possible to wake the chip from ELP power
    saving mode, PM had to be disabled to have the driver usable in SDIO
    mode. After this patch PM is functional.
    
    For backporting to 2.6.34 or earlier, this patch depends on
    6c1f716e, which adds the
    required SDIO funcion.
    Signed-off-by: default avatarGrazvydas Ignotas <notasas@gmail.com>
    Acked-by: default avatarKalle Valo <kvalo@adurom.com>
    Signed-off-by: default avatarJohn W. Linville <linville@tuxdriver.com>
    832c10fd
wl1251_sdio.c 7.74 KB