[RESEND] mfd: rtsx: add support for rts522A

2015-06-28 Thread micky_ching
From: Micky Ching rts522a(rts5227s) is derived from rts5227, and mainly same with rts5227. Add it to file mfd/rts5227.c to support this chip. Signed-off-by: Micky Ching --- drivers/mfd/Kconfig | 7 ++-- drivers/mfd/rts5227.c| 77 ++--

[RESEND] mfd: rtsx: add support for rts522A

2015-06-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn rts522a(rts5227s) is derived from rts5227, and mainly same with rts5227. Add it to file mfd/rts5227.c to support this chip. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/Kconfig | 7 ++-- drivers/mfd/rts5227.c

[PATCH 01/12] mmc: core: add data structure define for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching The new data structure for SD4.0 including follows: register: SD4.0 IO space register define. protocol: host and card handshake data. tlp: tlp request data structure for SD4.0 mode. uhsii ios: UHSII bus control data structure. Signed-off-by: Micky Ching Signed-off-by: Wei

[PATCH 03/12] mmc: core: add SD4.0 operation function

2015-04-28 Thread micky_ching
From: Micky Ching SD4.0 add some new operations, which include follows: UHSII interface detect: when UHSII interface is detected, the power is up. go/exit dormant: enter or exit dormant state. device init: device init CCMD. enumerate: enumerate CCMD. config space read/write CCMD. when we send

[PATCH 04/12] mmc: core: add tlp request handler for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching when card is work in SD4.0 mode, we should send tlp instead of cmd. add this function to handle tlp request. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/core/core.c | 111 +--- 1 file changed, 104

[PATCH 05/12] mmc: core: disable full power cycle for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching We should not do power cycle when card is in SD4.0 mode, if we power off, we should detect UHSII interface again. so we can disable it when card is in UHSII mode. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/core/core.c | 3 ++- 1 file changed, 2

[PATCH 07/12] mmc: sdhci: add data structure for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching add SD4.0 register define and host data structure for handshake with SD4.0 card. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/host/sdhci.h | 136 ++- 1 file changed, 135 insertions(+), 1 deletion(-) diff

[PATCH 08/12] mmc: sdhci: add SD4.0 operations

2015-04-28 Thread micky_ching
From: Micky Ching SD4.0 operations include UHSII interface detect, go/exit dormant and uhsii ios settings. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/host/sdhci.c | 183 ++- 1 file changed, 182 insertions(+), 1 deletion(-)

[PATCH 12/12] mmc: sdhci: add SD4.0 support

2015-04-28 Thread micky_ching
From: Micky Ching Add support for SD4.0 card. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/host/sdhci.c | 108 --- 1 file changed, 102 insertions(+), 6 deletions(-) diff --git a/drivers/mmc/host/sdhci.c

[PATCH 00/12] mmc: core: add SD4.0 support

2015-04-28 Thread micky_ching
From: Micky Ching Add support for SD4.0 card, which introduce UHSII mode and tlp transfer. Micky Ching (12): mmc: core: add data structure define for SD4.0 mmc: core: modify mmc_app_cmd interface for SD4.0 mmc: core: add SD4.0 operation function mmc: core: add tlp request handler for

[PATCH 10/12] mmc: sdhci: disable clock control for SD4.0 mode

2015-04-28 Thread micky_ching
From: Micky Ching Skip clock control settings for UHSII mode. When card is in UHSII mode, we only allow poweroff. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/host/sdhci.c | 22 ++ 1 file changed, 14 insertions(+), 8 deletions(-) diff --git

[PATCH 06/12] mmc: core: init SD4.0 mode before legacy mode

2015-04-28 Thread micky_ching
From: Micky Ching We alloc card before init card, if init UHSII mode failed, then try to init legacy mode. Since we card is allocated before do init operations, so mmc/sdio card init should do some modify. To reduce many diff hunks, the old labels are reserved(we can remove them in the future).

[PATCH 02/12] mmc: core: modify mmc_app_cmd interface for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching When card running in SD4.0 mode, ACMD is not need to send two command, we only need to mark a flag for the CMD which is to be send. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/card/block.c | 2 +- drivers/mmc/core/sd_ops.c | 17 -

[PATCH 11/12] mmc: sdhci: set DMA configure for SD4.0 mode

2015-04-28 Thread micky_ching
From: Micky Ching SD4.0 mode not using SDMA any more, and UHSII mode using different register to specify block size/count. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/host/sdhci.c | 22 +- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git

[PATCH 09/12] mmc: sdhci: add tlp handler for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching SD4.0 mode using tlp for cmd/data transfer, add tlp functions to handle this case. Signed-off-by: Micky Ching Signed-off-by: Wei Wang --- drivers/mmc/host/sdhci.c | 244 ++- 1 file changed, 220 insertions(+), 24 deletions(-) diff

[PATCH 03/12] mmc: core: add SD4.0 operation function

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn SD4.0 add some new operations, which include follows: UHSII interface detect: when UHSII interface is detected, the power is up. go/exit dormant: enter or exit dormant state. device init: device init CCMD. enumerate: enumerate CCMD. config space

[PATCH 08/12] mmc: sdhci: add SD4.0 operations

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn SD4.0 operations include UHSII interface detect, go/exit dormant and uhsii ios settings. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/host/sdhci.c | 183

[PATCH 04/12] mmc: core: add tlp request handler for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn when card is work in SD4.0 mode, we should send tlp instead of cmd. add this function to handle tlp request. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/core/core.c | 111

[PATCH 05/12] mmc: core: disable full power cycle for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn We should not do power cycle when card is in SD4.0 mode, if we power off, we should detect UHSII interface again. so we can disable it when card is in UHSII mode. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang

[PATCH 07/12] mmc: sdhci: add data structure for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add SD4.0 register define and host data structure for handshake with SD4.0 card. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/host/sdhci.h | 136

[PATCH 09/12] mmc: sdhci: add tlp handler for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn SD4.0 mode using tlp for cmd/data transfer, add tlp functions to handle this case. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/host/sdhci.c | 244

[PATCH 06/12] mmc: core: init SD4.0 mode before legacy mode

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn We alloc card before init card, if init UHSII mode failed, then try to init legacy mode. Since we card is allocated before do init operations, so mmc/sdio card init should do some modify. To reduce many diff hunks, the old labels are reserved(we can

[PATCH 02/12] mmc: core: modify mmc_app_cmd interface for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn When card running in SD4.0 mode, ACMD is not need to send two command, we only need to mark a flag for the CMD which is to be send. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn ---

[PATCH 12/12] mmc: sdhci: add SD4.0 support

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Add support for SD4.0 card. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/host/sdhci.c | 108 --- 1 file changed, 102 insertions(+), 6

[PATCH 00/12] mmc: core: add SD4.0 support

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Add support for SD4.0 card, which introduce UHSII mode and tlp transfer. Micky Ching (12): mmc: core: add data structure define for SD4.0 mmc: core: modify mmc_app_cmd interface for SD4.0 mmc: core: add SD4.0 operation function mmc: core: add

[PATCH 10/12] mmc: sdhci: disable clock control for SD4.0 mode

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Skip clock control settings for UHSII mode. When card is in UHSII mode, we only allow poweroff. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/host/sdhci.c | 22

[PATCH 11/12] mmc: sdhci: set DMA configure for SD4.0 mode

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn SD4.0 mode not using SDMA any more, and UHSII mode using different register to specify block size/count. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Signed-off-by: Wei Wang wei_w...@realsil.com.cn --- drivers/mmc/host/sdhci.c | 22

[PATCH 01/12] mmc: core: add data structure define for SD4.0

2015-04-28 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn The new data structure for SD4.0 including follows: register: SD4.0 IO space register define. protocol: host and card handshake data. tlp: tlp request data structure for SD4.0 mode. uhsii ios: UHSII bus control data structure. Signed-off-by: Micky

[PATCH v2] mfd: rtsx: add support for rts522A

2015-04-16 Thread micky_ching
From: Micky Ching rts522a(rts5227s) is derived from rts5227, and mainly same with rts5227. Add it to file mfd/rts5227.c to support this chip. Signed-off-by: Micky Ching --- drivers/mfd/Kconfig | 7 ++-- drivers/mfd/rts5227.c| 77 ++--

[PATCH] mfd: rtsx: add support for rts522A

2015-04-16 Thread micky_ching
From: Micky Ching rts522a(rts5227s) is derived from rts5227, and mainly same with rts5227. Add it to file mfd/rts5227.c to support this chip. Signed-off-by: Micky Ching --- drivers/mfd/rts5227.c| 77 ++-- drivers/mfd/rtsx_pcr.c | 5 +++

[PATCH] mfd: rtsx: add support for rts522A

2015-04-16 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn rts522a(rts5227s) is derived from rts5227, and mainly same with rts5227. Add it to file mfd/rts5227.c to support this chip. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5227.c| 77

[PATCH v2] mfd: rtsx: add support for rts522A

2015-04-16 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn rts522a(rts5227s) is derived from rts5227, and mainly same with rts5227. Add it to file mfd/rts5227.c to support this chip. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/Kconfig | 7 ++-- drivers/mfd/rts5227.c

[PATCH] sdhci: rtsx: fix 64 BIT DMA quirks

2015-04-06 Thread micky_ching
From: Micky Ching rts5250 chip failed handle 64 bit ADMA for address below 4G. Add 64 BIT quirks to disable this feature. Signed-off-by: Micky Ching --- drivers/mmc/host/sdhci-pci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/mmc/host/sdhci-pci.c b/drivers/mmc/host/sdhci-pci.c

[PATCH] sdhci: rtsx: fix 64 BIT DMA quirks

2015-04-06 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn rts5250 chip failed handle 64 bit ADMA for address below 4G. Add 64 BIT quirks to disable this feature. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mmc/host/sdhci-pci.c | 1 + 1 file changed, 1 insertion(+) diff --git

[PATCH v3 4/9] mfd: rtsx: update driving settings

2015-02-24 Thread micky_ching
From: Micky Ching update card drive settings, This setting can be used for rts5249 rts524A and rts525A. Signed-off-by: Micky Ching Acked-by: Lee Jones --- drivers/mfd/rts5249.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/mfd/rts5249.c

[PATCH v3 3/9] mfd: rtsx: update PETXCFG address

2015-02-24 Thread micky_ching
From: Micky Ching PETXCFG is defined at 0xFF03, the old 0xFE49 not used any more. Signed-off-by: Micky Ching Acked-by: Lee Jones --- drivers/mfd/rts5227.c| 6 ++ drivers/mfd/rts5249.c| 6 ++ include/linux/mfd/rtsx_pci.h | 2 +- 3 files changed, 5 insertions(+), 9

[PATCH v3 2/9] mfd: rtsx: place register address and values togather

2015-02-24 Thread micky_ching
From: Micky Ching It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching Acked-by: Lee Jones --- include/linux/mfd/rtsx_pci.h | 836

[PATCH v3 0/9] mfd: rtsx: add support for new rts524A and rts525A

2015-02-24 Thread micky_ching
From: Micky Ching v3: - define member pcr->reg_pm_ctrl3 for PM_CTRL3 address - update phy register without change the indent - define macro for switch output voltage resend: - add lee jones ack for some patch. v2: - remove debug info when access failed. - using macro list for phy register init.

[PATCH v3 1/9] mfd: rtsx: replace TAB by SPC after #define

2015-02-24 Thread micky_ching
From: Micky Ching Re-format coding-style, using uniform SPC after "#define" keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching Acked-by: Lee Jones --- include/linux/mfd/rtsx_pci.h | 254 +-- 1 file changed, 127 insertions(+), 127

[PATCH v3 6/9] mfd: rtsx: remove LCTLR defination

2015-02-24 Thread micky_ching
From: Micky Ching To enable/disable ASPM we should find LINK CONTROL register in PCI config space. All old chip use 0x80 address, but new chip may use another address, so we using pci_find_capability() to get LINK CONTROL address. rtsx_gops.c was removed, we consider to put some common

[PATCH v3 8/9] mfd: rtsx: add support for rts525A

2015-02-24 Thread micky_ching
From: Micky Ching add support for new chip rts525A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 103 +++ drivers/mfd/rtsx_pcr.c | 13 -- drivers/mfd/rtsx_pcr.h | 1 + include/linux/mfd/rtsx_pci.h | 15 +++ 4

[PATCH v3 9/9] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-02-24 Thread micky_ching
From: Micky Ching pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching Acked-by: Lee Jones --- drivers/mfd/rtl8411.c | 11 +-- drivers/mfd/rts5209.c | 4 ++-- drivers/mfd/rts5227.c | 4 ++--

[PATCH v3 7/9] mfd: rtsx: add support for rts524A

2015-02-24 Thread micky_ching
From: Micky Ching add support for new chip rts524A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 186 --- drivers/mfd/rtsx_pcr.c | 25 +- drivers/mfd/rtsx_pcr.h | 7 ++ include/linux/mfd/rtsx_pci.h | 132

[PATCH v3 5/9] mfd: rtsx: update phy register

2015-02-24 Thread micky_ching
From: Micky Ching Update some phy register name and value for rts5249, the updated value makes chip more stable on some platform. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 29 +++- include/linux/mfd/rtsx_pci.h | 109 ++- 2

[PATCH v3 5/9] mfd: rtsx: update phy register

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Update some phy register name and value for rts5249, the updated value makes chip more stable on some platform. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 29 +++- include/linux/mfd/rtsx_pci.h |

[PATCH v3 7/9] mfd: rtsx: add support for rts524A

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add support for new chip rts524A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 186 --- drivers/mfd/rtsx_pcr.c | 25 +- drivers/mfd/rtsx_pcr.h | 7

[PATCH v3 6/9] mfd: rtsx: remove LCTLR defination

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn To enable/disable ASPM we should find LINK CONTROL register in PCI config space. All old chip use 0x80 address, but new chip may use another address, so we using pci_find_capability() to get LINK CONTROL address. rtsx_gops.c was removed, we consider

[PATCH v3 8/9] mfd: rtsx: add support for rts525A

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add support for new chip rts525A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 103 +++ drivers/mfd/rtsx_pcr.c | 13 -- drivers/mfd/rtsx_pcr.h | 1

[PATCH v3 9/9] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- drivers/mfd/rtl8411.c | 11 +--

[PATCH v3 3/9] mfd: rtsx: update PETXCFG address

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn PETXCFG is defined at 0xFF03, the old 0xFE49 not used any more. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- drivers/mfd/rts5227.c| 6 ++ drivers/mfd/rts5249.c| 6 ++

[PATCH v3 2/9] mfd: rtsx: place register address and values togather

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones

[PATCH v3 0/9] mfd: rtsx: add support for new rts524A and rts525A

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn v3: - define member pcr-reg_pm_ctrl3 for PM_CTRL3 address - update phy register without change the indent - define macro for switch output voltage resend: - add lee jones ack for some patch. v2: - remove debug info when access failed. - using macro

[PATCH v3 1/9] mfd: rtsx: replace TAB by SPC after #define

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Re-format coding-style, using uniform SPC after #define keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- include/linux/mfd/rtsx_pci.h | 254

[PATCH v3 4/9] mfd: rtsx: update driving settings

2015-02-24 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn update card drive settings, This setting can be used for rts5249 rts524A and rts525A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- drivers/mfd/rts5249.c | 12 ++-- 1 file changed, 6

[RESEND PATCH v2 0/9] mfd: rtsx: add support for new rts524A and rts525A

2015-01-21 Thread micky_ching
From: Micky Ching resend: - add lee jones ack for some patch. v2: - remove debug info when access failed. - using macro list for phy register init. - rename function for multi chip prefix with rtsx_base_ - save pcie_cap offset when init chip, not calling pci_find_capacity() every time. - add

[RESEND PATCH v2 5/9] mfd: rtsx: update phy register

2015-01-21 Thread micky_ching
From: Micky Ching update phy register value and using direct value instead of macros. It is much easier to debug using constant value than a lot of macros. We usually need compare the value directly to check the configure. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 55

[RESEND PATCH v2 4/9] mfd: rtsx: update driving settings

2015-01-21 Thread micky_ching
From: Micky Ching update card drive settings, This setting can be used for rts5249 rts524A and rts525A. Signed-off-by: Micky Ching Acked-by: Lee Jones --- drivers/mfd/rts5249.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/mfd/rts5249.c

[RESEND PATCH v2 2/9] mfd: rtsx: place register address and values togather

2015-01-21 Thread micky_ching
From: Micky Ching It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching Acked-by: Lee Jones --- include/linux/mfd/rtsx_pci.h | 836

[RESEND PATCH v2 6/9] mfd: rtsx: remove LCTLR defination

2015-01-21 Thread micky_ching
From: Micky Ching To enable/disable ASPM we should find LINK CONTROL register in PCI config space. All old chip use 0x80 address, but new chip may use another address, so we using pci_find_capability() to get LINK CONTROL address. rtsx_gops.c was removed, we consider to put some common

[RESEND PATCH v2 8/9] mfd: rtsx: add support for rts525A

2015-01-21 Thread micky_ching
From: Micky Ching add support for new chip rts525A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 104 ++- drivers/mfd/rtsx_pcr.c | 13 -- drivers/mfd/rtsx_pcr.h | 1 + include/linux/mfd/rtsx_pci.h | 15 +++ 4

[RESEND PATCH v2 9/9] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-01-21 Thread micky_ching
From: Micky Ching pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching Acked-by: Lee Jones --- drivers/mfd/rtl8411.c | 11 +-- drivers/mfd/rts5209.c | 4 ++-- drivers/mfd/rts5227.c | 4 ++--

[RESEND PATCH v2 7/9] mfd: rtsx: add support for rts524A

2015-01-21 Thread micky_ching
From: Micky Ching add support for new chip rts524A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 186 --- drivers/mfd/rtsx_pcr.c | 25 +- drivers/mfd/rtsx_pcr.h | 7 ++ include/linux/mfd/rtsx_pci.h | 125

[RESEND PATCH v2 3/9] mfd: rtsx: update PETXCFG address

2015-01-21 Thread micky_ching
From: Micky Ching PETXCFG is defined at 0xFF03, the old 0xFE49 not used any more. Signed-off-by: Micky Ching Acked-by: Lee Jones --- drivers/mfd/rts5227.c| 6 ++ drivers/mfd/rts5249.c| 6 ++ include/linux/mfd/rtsx_pci.h | 2 +- 3 files changed, 5 insertions(+), 9

[RESEND PATCH v2 1/9] mfd: rtsx: replace TAB by SPC after #define

2015-01-21 Thread micky_ching
From: Micky Ching Re-format coding-style, using uniform SPC after "#define" keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching Acked-by: Lee Jones --- include/linux/mfd/rtsx_pci.h | 254 +-- 1 file changed, 127 insertions(+), 127

[PATCH v2 7/9] mfd: rtsx: add support for rts524A

2015-01-21 Thread micky_ching
From: Micky Ching add support for new chip rts524A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 186 --- drivers/mfd/rtsx_pcr.c | 25 +- drivers/mfd/rtsx_pcr.h | 7 ++ include/linux/mfd/rtsx_pci.h | 125

[PATCH v2 6/9] mfd: rtsx: remove LCTLR defination

2015-01-21 Thread micky_ching
From: Micky Ching To enable/disable ASPM we should find LINK CONTROL register in PCI config space. All old chip use 0x80 address, but new chip may use another address, so we using pci_find_capability() to get LINK CONTROL address. rtsx_gops.c was removed, we consider to put some common

[PATCH v2 9/9] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-01-21 Thread micky_ching
From: Micky Ching pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching --- drivers/mfd/rtl8411.c | 11 +-- drivers/mfd/rts5209.c | 4 ++-- drivers/mfd/rts5227.c | 4 ++-- drivers/mfd/rts5229.c | 4

[PATCH v2 8/9] mfd: rtsx: add support for rts525A

2015-01-21 Thread micky_ching
From: Micky Ching add support for new chip rts525A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 104 ++- drivers/mfd/rtsx_pcr.c | 13 -- drivers/mfd/rtsx_pcr.h | 1 + include/linux/mfd/rtsx_pci.h | 15 +++ 4

[PATCH v2 2/9] mfd: rtsx: place register address and values togather

2015-01-21 Thread micky_ching
From: Micky Ching It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching --- include/linux/mfd/rtsx_pci.h | 836

[PATCH v2 4/9] mfd: rtsx: update driving settings

2015-01-21 Thread micky_ching
From: Micky Ching update card drive settings, This setting can be used for rts5249 rts524A and rts525A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/mfd/rts5249.c b/drivers/mfd/rts5249.c index

[PATCH v2 5/9] mfd: rtsx: update phy register

2015-01-21 Thread micky_ching
From: Micky Ching update phy register value and using direct value instead of macros. It is much easier to debug using constant value than a lot of macros. We usually need compare the value directly to check the configure. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 55

[PATCH v2 3/9] mfd: rtsx: update PETXCFG address

2015-01-21 Thread micky_ching
From: Micky Ching PETXCFG is defined at 0xFF03, the old 0xFE49 not used any more. Signed-off-by: Micky Ching --- drivers/mfd/rts5227.c| 6 ++ drivers/mfd/rts5249.c| 6 ++ include/linux/mfd/rtsx_pci.h | 2 +- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git

[PATCH v2 0/9] mfd: rtsx: add support for new rts524A and rts525A

2015-01-21 Thread micky_ching
From: Micky Ching v2: - remove debug info when access failed. - using macro list for phy register init. - rename function for multi chip prefix with rtsx_base_ - save pcie_cap offset when init chip, not calling pci_find_capacity() every time. - add pcr->ops: write_phy/read_phy for special

[PATCH v2 1/9] mfd: rtsx: replace TAB by SPC after #define

2015-01-21 Thread micky_ching
From: Micky Ching Re-format coding-style, using uniform SPC after "#define" keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching --- include/linux/mfd/rtsx_pci.h | 254 +-- 1 file changed, 127 insertions(+), 127 deletions(-) diff

[PATCH v2 6/9] mfd: rtsx: remove LCTLR defination

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn To enable/disable ASPM we should find LINK CONTROL register in PCI config space. All old chip use 0x80 address, but new chip may use another address, so we using pci_find_capability() to get LINK CONTROL address. rtsx_gops.c was removed, we consider

[PATCH v2 9/9] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rtl8411.c | 11 +-- drivers/mfd/rts5209.c | 4 ++--

[PATCH v2 8/9] mfd: rtsx: add support for rts525A

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add support for new chip rts525A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 104 ++- drivers/mfd/rtsx_pcr.c | 13 -- drivers/mfd/rtsx_pcr.h | 1

[PATCH v2 2/9] mfd: rtsx: place register address and values togather

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn ---

[PATCH v2 4/9] mfd: rtsx: update driving settings

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn update card drive settings, This setting can be used for rts5249 rts524A and rts525A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git

[PATCH v2 5/9] mfd: rtsx: update phy register

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn update phy register value and using direct value instead of macros. It is much easier to debug using constant value than a lot of macros. We usually need compare the value directly to check the configure. Signed-off-by: Micky Ching

[PATCH v2 3/9] mfd: rtsx: update PETXCFG address

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn PETXCFG is defined at 0xFF03, the old 0xFE49 not used any more. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5227.c| 6 ++ drivers/mfd/rts5249.c| 6 ++ include/linux/mfd/rtsx_pci.h | 2 +- 3 files

[RESEND PATCH v2 3/9] mfd: rtsx: update PETXCFG address

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn PETXCFG is defined at 0xFF03, the old 0xFE49 not used any more. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- drivers/mfd/rts5227.c| 6 ++ drivers/mfd/rts5249.c| 6 ++

[RESEND PATCH v2 1/9] mfd: rtsx: replace TAB by SPC after #define

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Re-format coding-style, using uniform SPC after #define keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- include/linux/mfd/rtsx_pci.h | 254

[RESEND PATCH v2 9/9] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- drivers/mfd/rtl8411.c | 11 +--

[RESEND PATCH v2 7/9] mfd: rtsx: add support for rts524A

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add support for new chip rts524A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 186 --- drivers/mfd/rtsx_pcr.c | 25 +- drivers/mfd/rtsx_pcr.h | 7

[RESEND PATCH v2 6/9] mfd: rtsx: remove LCTLR defination

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn To enable/disable ASPM we should find LINK CONTROL register in PCI config space. All old chip use 0x80 address, but new chip may use another address, so we using pci_find_capability() to get LINK CONTROL address. rtsx_gops.c was removed, we consider

[PATCH v2 7/9] mfd: rtsx: add support for rts524A

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add support for new chip rts524A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 186 --- drivers/mfd/rtsx_pcr.c | 25 +- drivers/mfd/rtsx_pcr.h | 7

[PATCH v2 1/9] mfd: rtsx: replace TAB by SPC after #define

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn Re-format coding-style, using uniform SPC after #define keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- include/linux/mfd/rtsx_pci.h | 254 +-- 1 file

[PATCH v2 0/9] mfd: rtsx: add support for new rts524A and rts525A

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn v2: - remove debug info when access failed. - using macro list for phy register init. - rename function for multi chip prefix with rtsx_base_ - save pcie_cap offset when init chip, not calling pci_find_capacity() every time. - add pcr-ops:

[RESEND PATCH v2 0/9] mfd: rtsx: add support for new rts524A and rts525A

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn resend: - add lee jones ack for some patch. v2: - remove debug info when access failed. - using macro list for phy register init. - rename function for multi chip prefix with rtsx_base_ - save pcie_cap offset when init chip, not calling

[RESEND PATCH v2 5/9] mfd: rtsx: update phy register

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn update phy register value and using direct value instead of macros. It is much easier to debug using constant value than a lot of macros. We usually need compare the value directly to check the configure. Signed-off-by: Micky Ching

[RESEND PATCH v2 4/9] mfd: rtsx: update driving settings

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn update card drive settings, This setting can be used for rts5249 rts524A and rts525A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones lee.jo...@linaro.org --- drivers/mfd/rts5249.c | 12 ++-- 1 file changed, 6

[RESEND PATCH v2 2/9] mfd: rtsx: place register address and values togather

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn Acked-by: Lee Jones

[RESEND PATCH v2 8/9] mfd: rtsx: add support for rts525A

2015-01-21 Thread micky_ching
From: Micky Ching micky_ch...@realsil.com.cn add support for new chip rts525A. Signed-off-by: Micky Ching micky_ch...@realsil.com.cn --- drivers/mfd/rts5249.c| 104 ++- drivers/mfd/rtsx_pcr.c | 13 -- drivers/mfd/rtsx_pcr.h | 1

[PATCH 02/10] mfd: rtsx: place register address and values togather

2015-01-15 Thread micky_ching
From: Micky Ching It is more readable to place register address and values define togather. The values define add two leading space indicate belong to the register address defined above. Signed-off-by: Micky Ching --- include/linux/mfd/rtsx_pci.h | 836

[PATCH 03/10] mfd: rtsx: add debug info when access register failed

2015-01-15 Thread micky_ching
From: Micky Ching Add debug info when access register failed, this is useful for debug. Signed-off-by: Micky Ching --- drivers/mfd/rtsx_pcr.c | 22 +- include/linux/mfd/rtsx_pci.h | 2 ++ 2 files changed, 19 insertions(+), 5 deletions(-) diff --git

[PATCH 01/10] mfd: rtsx: replace TAB by SPC after #define

2015-01-15 Thread micky_ching
From: Micky Ching Re-format coding-style, using uniform SPC after "#define" keyword instead of mixing using TAB and SPC. Signed-off-by: Micky Ching --- include/linux/mfd/rtsx_pci.h | 254 +-- 1 file changed, 127 insertions(+), 127 deletions(-) diff

[PATCH 08/10] mfd: rtsx: add support for rts524A

2015-01-15 Thread micky_ching
From: Micky Ching add support for new chip rts524A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c| 112 +++ drivers/mfd/rtsx_pcr.c | 5 ++ drivers/mfd/rtsx_pcr.h | 4 ++ include/linux/mfd/rtsx_pci.h | 87

[PATCH 10/10] mfd: rtsx: using pcr_dbg replace dev_dbg

2015-01-15 Thread micky_ching
From: Micky Ching pcr_dbg is a wrapper of dev_dbg, which can save some code, and help to enable/disable debug message static. Signed-off-by: Micky Ching --- drivers/mfd/rtl8411.c | 11 +-- drivers/mfd/rts5209.c | 4 ++-- drivers/mfd/rts5227.c | 4 ++-- drivers/mfd/rts5229.c | 4

[PATCH 09/10] mfd: rtsx: add support for rts525A

2015-01-15 Thread micky_ching
From: Micky Ching add support for new chip rts525A. Signed-off-by: Micky Ching --- drivers/mfd/rts5249.c | 93 +- drivers/mfd/rtsx_pcr.c | 13 +-- drivers/mfd/rtsx_pcr.h | 1 + 3 files changed, 103 insertions(+), 4 deletions(-) diff --git

  1   2   3   4   >