mfd: rtsx: Do retry when DMA transfer error

The request should be resent when DMA transfer error occurred.
For rts5227, the clock rate needs to be reduced when error occurred.

Signed-off-by: Steven Feng <steven_feng@realsil.com.cn>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
This commit is contained in:
Steven Feng
2017-05-23 15:13:24 +08:00
committed by Lee Jones
parent 9b79ff104f
commit 87d284443d
2 changed files with 20 additions and 2 deletions

View File

@@ -850,6 +850,9 @@
#define rtsx_pci_init_cmd(pcr) ((pcr)->ci = 0)
#define RTS5227_DEVICE_ID 0x5227
#define RTS_MAX_TIMES_FREQ_REDUCTION 8
struct rtsx_pcr;
struct pcr_handle {
@@ -957,6 +960,8 @@ struct rtsx_pcr {
int num_slots;
struct rtsx_slot *slots;
u8 dma_error_count;
};
#define CHK_PCI_PID(pcr, pid) ((pcr)->pci->device == (pid))