Lines Matching refs:cfg
346 static int omap1_cfg_reg(const struct pin_config *cfg) in omap1_cfg_reg() argument
355 if (cfg->mux_reg) { in omap1_cfg_reg()
359 reg_orig = omap_readl(cfg->mux_reg); in omap1_cfg_reg()
362 mask = (0x7 << cfg->mask_offset); in omap1_cfg_reg()
366 tmp2 = (cfg->mask << cfg->mask_offset); in omap1_cfg_reg()
372 omap_writel(reg, cfg->mux_reg); in omap1_cfg_reg()
378 if (cfg->pu_pd_reg && cfg->pull_val) { in omap1_cfg_reg()
380 pu_pd_orig = omap_readl(cfg->pu_pd_reg); in omap1_cfg_reg()
381 mask = 1 << cfg->pull_bit; in omap1_cfg_reg()
383 if (cfg->pu_pd_val) { in omap1_cfg_reg()
394 omap_writel(pu_pd, cfg->pu_pd_reg); in omap1_cfg_reg()
400 if (cfg->pull_reg) { in omap1_cfg_reg()
402 pull_orig = omap_readl(cfg->pull_reg); in omap1_cfg_reg()
403 mask = 1 << cfg->pull_bit; in omap1_cfg_reg()
405 if (cfg->pull_val) { in omap1_cfg_reg()
417 omap_writel(pull, cfg->pull_reg); in omap1_cfg_reg()
423 printk(KERN_WARNING "MUX: initialized %s\n", cfg->name); in omap1_cfg_reg()
428 if (cfg->debug || warn) { in omap1_cfg_reg()
429 printk("MUX: Setting register %s\n", cfg->name); in omap1_cfg_reg()
431 cfg->mux_reg_name, cfg->mux_reg, reg_orig, reg); in omap1_cfg_reg()
434 if (cfg->pu_pd_reg && cfg->pull_val) { in omap1_cfg_reg()
436 cfg->pu_pd_name, cfg->pu_pd_reg, in omap1_cfg_reg()
441 if (cfg->pull_reg) in omap1_cfg_reg()
443 cfg->pull_name, cfg->pull_reg, pull_orig, pull); in omap1_cfg_reg()