History

mfd: rtsx: Add clock divider hook

Add callback function conv_clk_and_div_n to convert between SSC clock and its divider N. For rtl8411, the formula to calculate SSC clock divider N is different with the other card reader models.

Wei WANG committed 13 years ago

Commit ab4e8f81 parent ef85e736 files · +31 −2Browse files

Showing the changes to include/linux (2 of 6 files). Show all

Unified · Split

2 files
  1. include/linux/mfd/rtsx_common.h +3 −0
  2. include/linux/mfd/rtsx_pci.h +1 −0
include/linux/mfd/rtsx_common.h+3−0
@@ -38,6 +38,9 @@ · 37 unmodified lines
38#define RTSX_SD_CARD 038#define RTSX_SD_CARD 0
39#define RTSX_MS_CARD 139#define RTSX_MS_CARD 1
40 40
41#define CLK_TO_DIV_N 0
42#define DIV_N_TO_CLK 1
43
41struct platform_device;44struct platform_device;
42 45
43struct rtsx_slot {46struct rtsx_slot {
include/linux/mfd/rtsx_pci.h+1−0
@@ -704,6 +704,7 @@ struct pcr_ops { · 703 unmodified lines
704 int (*switch_output_voltage)(struct rtsx_pcr *pcr,704 int (*switch_output_voltage)(struct rtsx_pcr *pcr,
705 u8 voltage);705 u8 voltage);
706 unsigned int (*cd_deglitch)(struct rtsx_pcr *pcr);706 unsigned int (*cd_deglitch)(struct rtsx_pcr *pcr);
707 int (*conv_clk_and_div_n)(int clk, int dir);
707};708};
708 709
709enum PDEV_STAT {PDEV_STAT_IDLE, PDEV_STAT_RUN};710enum PDEV_STAT {PDEV_STAT_IDLE, PDEV_STAT_RUN};