codec : update something not that import

This commit is contained in:
zeroway
2017-03-04 18:18:10 +00:00
parent 8469a0845e
commit ac2bd37af1
4 changed files with 10 additions and 47 deletions

View File

@ -17,27 +17,25 @@ Codes test on the kernel version below
[I2C](./debug/i2c/README.md)
[REGULATOR (ACT8846 PMU)](./debug/regulator/README.md)
[Regulator (ACT8846, RK818)](./debug/regulator/README.md)
[REGULATOR (RK818 PMU)](./debug/regulator/README.md)
[Platform_Driver_Test](./debug/platform_driver_test/README.md)
[PLATFORM_DRIVER_TEST](./debug/platform_driver_test/README.md)
[PWM Backlight](./debug/pwm/README.md)
[PWM BACKLIGHT](./debug/pwm/README.md)
[Regmap](./debug/regmap/README.md)
[REGMAP](./debug/regmap/README.md)
[Audio (ES8323, ES8316)](./debug/codec/README.md)
[AUDIO (ES8323)](./debug/codec/README.md)
[Timer](./debug/timer/README.md)
[TIMER](./debug/timer/README.md)
[Timer And Workqueue](./debug/timer_workq/README.md)
[TIMER AND WORKQUEUE](./debug/timer_workq/README.md)
[Workqueue](./debug/workqueue/README.md)
[WORKQUEUE](./debug/workqueue/README.md)
[Notify](./debug/notify_chain/README.md)
[NOTIFY](./debug/notify_chain/README.md)
[SCRIPT](./script/README.md)
[Script](./script/README.md)
# 使用方法(单独编译模块)或者放到内核目录中编译

View File

@ -21,8 +21,6 @@
spk-con-gpio = <&gpio7 GPIO_B7 GPIO_ACTIVE_HIGH>;
hp-con-gpio = <&gpio0 GPIO_B5 GPIO_ACTIVE_HIGH>;
hp-det-gpio = <&gpio7 GPIO_A4 GPIO_ACTIVE_HIGH>;
hub_rest = <&gpio0 GPIO_B6 GPIO_ACTIVE_LOW>;
hub_en = <&gpio7 GPIO_B2 GPIO_ACTIVE_HIGH>;
};
};

View File

@ -643,8 +643,6 @@ void es8323_i2c_shutdown(struct i2c_client *client)
*/
int gpio_setup(struct es8323_chip *chip, struct i2c_client *client)
{
int hub_rest = -1;
int hub_en = -1;
int ret = 0;
enum of_gpio_flags flags;
@ -705,35 +703,6 @@ int gpio_setup(struct es8323_chip *chip, struct i2c_client *client)
gpio_direction_input(chip->hp_det_gpio);
}
hub_en = of_get_named_gpio_flags(client->dev.of_node, "hub_en", 0, &flags);
if (hub_en > 0)
{
printk("request gpio%d for hub enable gpio\n", hub_en);
ret = devm_gpio_request(chip->dev, hub_en, "hub_en");
if (ret != 0)
{
printk("%s request hub en error", __func__);
return ret;
}
gpio_direction_output(hub_en, 1);
msleep(10);
}
hub_rest = of_get_named_gpio_flags(client->dev.of_node, "hub_rest", 0, &flags);
if (hub_rest > 0)
{
printk("request gpio%d for hub reset gpio\n", hub_rest);
ret = devm_gpio_request(chip->dev, hub_rest, "hub_reset");
if (ret != 0)
{
printk("%s request hub rst error", __func__);
return ret;
}
gpio_direction_output(hub_rest, 0);
msleep(20);
gpio_set_value(hub_rest, 1);
}
return 0;
}

View File

@ -18,7 +18,5 @@ es8323: es8323@10 {
spk-con-gpio = <&gpio7 GPIO_B7 GPIO_ACTIVE_HIGH>;
hp-con-gpio = <&gpio0 GPIO_B5 GPIO_ACTIVE_HIGH>;
hp-det-gpio = <&gpio7 GPIO_A4 GPIO_ACTIVE_HIGH>;
hub_rest = <&gpio0 GPIO_B6 GPIO_ACTIVE_LOW>;
hub_en = <&gpio7 GPIO_B2 GPIO_ACTIVE_HIGH>;
};
};