[PATCH 4/5] mfd:rtsx: Clear hardware PFM mode in rtl8411b

2013-07-15 Thread wei_wang
From: Wei WANG Clear hw_pfm_en to disable hardware PFM mode, to fix a bug that in some situation registers in 0xFDxx domain can't be accessed. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c|2 ++ include/linux/mfd/rtsx_pci.h |1 + 2 files changed, 3 insertions(+) diff --git

[PATCH 5/5] mfd:rtsx: Configure to enter a deeper power-saving mode in S3

2013-07-15 Thread wei_wang
From: Wei WANG Set a bit to enable rts5227 and rts5249 to enter a deeper internal power-saving mode in S3, and recover it after resuming. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c|2 +- drivers/mfd/rts5209.c|2 +- drivers/mfd/rts5227.c|6 +- driv

[PATCH 1/5] mfd:rtsx: Read vendor setting from config space

2013-07-15 Thread wei_wang
From: Wei WANG Normally OEMs will set vendor setting to the config space of Realtek card reader in BIOS stage. This patch reads the setting at the first, and configure the internal registers according to it, to improve card reader's compatibility condition. Signed-off-by: Wei WANG --- drivers/

[PATCH 2/5] mfd:rtsx: Add shutdown callback in rtsx_pci_driver

2013-07-15 Thread wei_wang
From: Wei WANG Some actions to clear power state should be handled in .shutdown callback in rtsx_pci_driver. This patch adopts the following measures to catch this goal: 1. Add a function rtsx_pci_power_off to abstract the common ops in .shutdown and .suspend 2. Add pcr->ops->force_power_down to

[PATCH 0/5] mfd:rtsx: MFD patches for Realtek cardreader

2013-07-15 Thread wei_wang
From: Wei WANG Wei WANG (5): mfd:rtsx: Read vendor setting from config space mfd:rtsx: Add shutdown callback in rtsx_pci_driver mfd:rtsx: Move some actions from rtsx_pci_init_hw to individual extra_init_hw mfd:rtsx: Clear hardware PFM mode in rtl8411b mfd:rtsx: Configure to enter a

[PATCH 3/5] mfd:rtsx: Move some actions from rtsx_pci_init_hw to individual extra_init_hw

2013-07-15 Thread wei_wang
From: Wei WANG These actions are individual for each reader model, so should be put in extra_init_hw instead of rtsx_pci_init_hw. Signed-off-by: Wei WANG --- drivers/mfd/rts5209.c |4 drivers/mfd/rts5227.c |2 ++ drivers/mfd/rts5229.c |4 drivers/mfd/rts5249.c |2

[PATCH] mmc:host: Remove a duplicate line in Makefile

2013-07-16 Thread wei_wang
From: Wei WANG Signed-off-by: Wei WANG --- drivers/mmc/host/Makefile |2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/mmc/host/Makefile b/drivers/mmc/host/Makefile index d422e21..c41d0c3 100644 --- a/drivers/mmc/host/Makefile +++ b/drivers/mmc/host/Makefile @@ -52,8 +52,6 @@ obj-

[PATCH] mmc/core: free mmc_card when cmd 3, 9, 7 got failed in mmc_sd_init_card

2013-07-16 Thread wei_wang
From: Wei WANG In function mmc_sd_init_card, if command 3/9/7 got failed, mmc_card allocated just before won't be freed. This would cause memory leak. Signed-off-by: Wei WANG --- drivers/mmc/core/sd.c |6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/mmc/core

[PATCH v2 1/5] mfd:rtsx: Read vendor setting from config space

2013-07-17 Thread wei_wang
From: Wei WANG Normally OEMs will set vendor setting to the config space of Realtek card reader in BIOS stage. This patch reads the setting at the first, and configure the internal registers according to it, to improve card reader's compatibility condition. Signed-off-by: Wei WANG --- drivers/

[PATCH v2 0/5] mfd:rtsx: MFD patches for Realtek cardreader

2013-07-17 Thread wei_wang
From: Wei WANG v2: Use macro when initializing vendor settings Wei WANG (5): mfd:rtsx: Read vendor setting from config space mfd:rtsx: Add shutdown callback in rtsx_pci_driver mfd:rtsx: Move some actions from rtsx_pci_init_hw to individual extra_init_hw mfd:rtsx: Clear hardware PFM m

[PATCH v2 4/5] mfd:rtsx: Clear hardware PFM mode in rtl8411b

2013-07-17 Thread wei_wang
From: Wei WANG Clear hw_pfm_en to disable hardware PFM mode, to fix a bug that in some situation registers in 0xFDxx domain can't be accessed. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c|2 ++ include/linux/mfd/rtsx_pci.h |1 + 2 files changed, 3 insertions(+) diff --git

[PATCH v2 5/5] mfd:rtsx: Configure to enter a deeper power-saving mode in S3

2013-07-17 Thread wei_wang
From: Wei WANG Set a bit to enable rts5227 and rts5249 to enter a deeper internal power-saving mode in S3, and recover it after resuming. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c|2 +- drivers/mfd/rts5209.c|2 +- drivers/mfd/rts5227.c|6 +- driv

[PATCH v2 3/5] mfd:rtsx: Move some actions from rtsx_pci_init_hw to individual extra_init_hw

2013-07-17 Thread wei_wang
From: Wei WANG These actions are individual for each reader model, so should be put in extra_init_hw instead of rtsx_pci_init_hw. Signed-off-by: Wei WANG --- drivers/mfd/rts5209.c |4 drivers/mfd/rts5227.c |2 ++ drivers/mfd/rts5229.c |4 drivers/mfd/rts5249.c |2

[PATCH v2 2/5] mfd:rtsx: Add shutdown callback in rtsx_pci_driver

2013-07-17 Thread wei_wang
From: Wei WANG Some actions to clear power state should be handled in .shutdown callback in rtsx_pci_driver. This patch adopts the following measures to catch this goal: 1. Add a function rtsx_pci_power_off to abstract the common ops in .shutdown and .suspend 2. Add pcr->ops->force_power_down to

[PATCH v3 1/6] mfd:rtsx: Read vendor setting from config space

2013-08-19 Thread wei_wang
From: Wei WANG Normally OEMs will set vendor setting to the config space of Realtek card reader in BIOS stage. This patch reads the setting at the first, and configure the internal registers according to it, to improve card reader's compatibility condition. Signed-off-by: Wei WANG --- drivers/

[PATCH v3 6/6] mfd:rtsx: Modify copyright comments

2013-08-19 Thread wei_wang
From: Wei WANG Update copyright date, and remove author address. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c |4 ++-- drivers/mfd/rts5209.c |3 +-- drivers/mfd/rts5227.c |5 + drivers/mfd/rts5229.c |3 +-- drivers/mfd/rts5249.c

[PATCH v3 2/6] mfd:rtsx: Add shutdown callback in rtsx_pci_driver

2013-08-19 Thread wei_wang
From: Wei WANG Some actions to clear power state should be handled in .shutdown callback in rtsx_pci_driver. This patch adopts the following measures to catch this goal: 1. Add a function rtsx_pci_power_off to abstract the common ops in .shutdown and .suspend 2. Add pcr->ops->force_power_down to

[PATCH v3 5/6] mfd:rtsx: Configure to enter a deeper power-saving mode in S3

2013-08-19 Thread wei_wang
From: Wei WANG Set a bit to enable rts5227 and rts5249 to enter a deeper internal power-saving mode in S3, and recover it after resuming. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c|2 +- drivers/mfd/rts5209.c|2 +- drivers/mfd/rts5227.c|6 +- driv

[PATCH v3 4/6] mfd:rtsx: Clear hardware PFM mode in rtl8411b

2013-08-19 Thread wei_wang
From: Wei WANG Clear hw_pfm_en to disable hardware PFM mode, to fix a bug that in some situation registers in 0xFDxx domain can't be accessed. Signed-off-by: Wei WANG --- drivers/mfd/rtl8411.c|2 ++ include/linux/mfd/rtsx_pci.h |1 + 2 files changed, 3 insertions(+) diff --git

[PATCH v3 3/6] mfd:rtsx: Move some actions from rtsx_pci_init_hw to individual extra_init_hw

2013-08-19 Thread wei_wang
From: Wei WANG These actions are individual for each reader model, so should be put in extra_init_hw instead of rtsx_pci_init_hw. Signed-off-by: Wei WANG --- drivers/mfd/rts5209.c |4 drivers/mfd/rts5227.c |2 ++ drivers/mfd/rts5229.c |4 drivers/mfd/rts5249.c |2

[PATCH v3 0/6] MFD patches for Realtek cardreader

2013-08-19 Thread wei_wang
From: Wei WANG v3: Seperate copyright changes to a distinct patch Modify some coding style and naming style Fix a bug that sd30_drive_sel would be assigned a wrong value, in rts5227 and rts5249 v2: Use macro when initializing vendor settings Wei WANG (6): mfd:rtsx: Read vendor setting from c

[PATCH 0/3] Fix sd3.0 issues for Realtek card reader

2013-08-20 Thread wei_wang
From: Wei WANG Wei WANG (3): mfd:mmc:rtsx: Change default tx phase mmc:rtsx:Clear SD_CLK toggle enable bit if switching voltage fail mmc:memstick:rtsx: Modify copyright comments drivers/memstick/host/rtsx_pci_ms.c |3 +- drivers/mfd/rtl8411.c |4 ++ drivers/mfd/rts52

[PATCH 1/3] mfd:mmc:rtsx: Change default tx phase

2013-08-20 Thread wei_wang
From: Wei WANG The default phase can meet most cards' requirement, but it is not the optimal one. In some extreme situation, the rx phase point produced by the following tuning process will drift quite a distance. Before tuning UHS card, this patch will set a more proper initial tx phase point, w

[PATCH 2/3] mmc:rtsx:Clear SD_CLK toggle enable bit if switching voltage fail

2013-08-20 Thread wei_wang
From: Wei WANG If switching voltage fails, SD_CLK toggle enable bit should been cleared so that SD host can control SD clock automatically. Signed-off-by: Wei WANG --- drivers/mmc/host/rtsx_pci_sdmmc.c |9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/drivers/mmc/h

[PATCH 3/3] mmc:memstick:rtsx: Modify copyright comments

2013-08-20 Thread wei_wang
From: Wei WANG Update copyright date, and remove author address. Signed-off-by: Wei WANG --- drivers/memstick/host/rtsx_pci_ms.c |3 +-- drivers/mmc/host/rtsx_pci_sdmmc.c |3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/memstick/host/rtsx_pci_ms.c b/dri

[PATCH] mfd: rtsx: Modify rts5249_optimize_phy

2013-09-05 Thread wei_wang
From: Wei WANG In some platforms, specially Thinkpad series, rts5249 won't be initialized properly. So we need adjust some phy parameters to improve the compatibility issue. Signed-off-by: Wei WANG --- drivers/mfd/rts5249.c | 25 +++-- 1 file changed, 23 insertions(+), 2

[PATCH v2] mfd: rtsx: Modify rts5249_optimize_phy

2013-09-05 Thread wei_wang
From: Wei WANG v2: Name those new-added register values Wei WANG (1): mfd: rtsx: Modify rts5249_optimize_phy drivers/mfd/rts5249.c| 35 -- include/linux/mfd/rtsx_pci.h | 43 ++ 2 files changed, 76 insertions(

[PATCH v2] mfd: rtsx: Modify rts5249_optimize_phy

2013-09-05 Thread wei_wang
From: Wei WANG In some platforms, specially Thinkpad series, rts5249 won't be initialized properly. So we need adjust some phy parameters to improve the compatibility issue. Signed-off-by: Wei WANG --- drivers/mfd/rts5249.c| 35 -- include/linux/mfd/rt

[PATCH] mfd: rtsx: Modify rts5249_optimize_phy

2013-09-10 Thread wei_wang
From: Wei WANG In some platforms, specially Thinkpad series, rts5249 won't be initialized properly. So we need adjust some phy parameters to improve the compatibility issue. Signed-off-by: Wei WANG --- drivers/mfd/rts5249.c| 48 -- include/linux/mf

[PATCH v3] mfd: rtsx: Modify rts5249_optimize_phy

2013-09-10 Thread wei_wang
From: Wei WANG In some platforms, specially Thinkpad series, rts5249 won't be initialized properly. So we need adjust some phy parameters to improve the compatibility issue. Signed-off-by: Wei WANG --- drivers/mfd/rts5249.c| 48 -- include/linux/mf

[PATCH v4] mfd: rtsx: Modify rts5249_optimize_phy

2013-09-13 Thread wei_wang
From: Wei WANG In some platforms, specially Thinkpad series, rts5249 won't be initialized properly. So we need adjust some phy parameters to improve the compatibility issue. It is a little different between simulation and real chip. We have no idea about which configuration is better before tape