Lines Matching defs:prescaler
808 int prescaler;
837 /* The prescaler is 5 for PERCLK2 equal to 96MHz
841 prescaler = (clk + (CLK_RATE * 7) / 8) / CLK_RATE;
842 switch (prescaler) {
844 case 1: prescaler = 0;
846 case 2: prescaler = 1;
848 case 3: prescaler = 2;
850 case 4: prescaler = 4;
853 case 5: prescaler = 5;
857 dev_dbg(mmc_dev(host->mmc), "PERCLK2 %d MHz -> prescaler %d\n",
858 clk, prescaler);
873 writew((prescaler << 3) | clk, host->base + MMC_REG_CLK_RATE);