void s3c6410_setup_sdhci1_cfg_gpio(struct platform_device *dev, int width) { unsigned int gpio; switch (width) { /* Channel 1 supports 4-bit bus width */ case 0: case 1: case 4: /* Set all the necessary GPIO function and pull up/down */ for (gpio = S5PC11X_GPG1(0); gpio <= S5PC11X_GPG1(6); gpio++) { s3c_gpio_cfgpin(gpio, S3C_GPIO_SFN(2)); s3c_gpio_setpull(gpio, S3C_GPIO_PULL_UP); } writel(0x3fff, S5PC11X_GPG1DRV); /* Chip detect pin Pull up*/ s3c_gpio_setpull(S5PC11X_GPG1(2), S3C_GPIO_PULL_UP); break; default: printk(KERN_ERR "Wrong SD/MMC bus width : %d\n", width); } }
.ngpio = S5PC11X_GPIO_F3_NR, .label = "GPF3", }, }, { .base = S5PC11X_GPG0_BASE, .config = &gpio_cfg, .chip = { .base = S5PC11X_GPG0(0), .ngpio = S5PC11X_GPIO_G0_NR, .label = "GPG0", }, }, { .base = S5PC11X_GPG1_BASE, .config = &gpio_cfg, .chip = { .base = S5PC11X_GPG1(0), .ngpio = S5PC11X_GPIO_G1_NR, .label = "GPG1", }, }, { .base = S5PC11X_GPG2_BASE, .config = &gpio_cfg, .chip = { .base = S5PC11X_GPG2(0), .ngpio = S5PC11X_GPIO_G2_NR, .label = "GPG2", }, }, { .base = S5PC11X_GPG3_BASE, .config = &gpio_cfg, .chip = {