mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 02:21:52 +09:00
ASoC: rockchip: multicodecs: remove unused cables
Signed-off-by: Shunhua Lan <lsh@rock-chips.com> Change-Id: I66e1316e6c07fd13ce127c63d2f626803a96c6d1
This commit is contained in:
@@ -83,9 +83,9 @@ struct multicodecs_data {
|
||||
unsigned int rx_slot_mask;
|
||||
};
|
||||
|
||||
static const unsigned int headset_extcon_cable[] = {
|
||||
EXTCON_JACK_MICROPHONE,
|
||||
EXTCON_JACK_HEADPHONE,
|
||||
static unsigned int headset_extcon_cable[] = {
|
||||
EXTCON_NONE,
|
||||
EXTCON_NONE,
|
||||
EXTCON_NONE,
|
||||
};
|
||||
|
||||
@@ -762,6 +762,7 @@ static int rk_multicodecs_probe(struct platform_device *pdev)
|
||||
int count, irq;
|
||||
int ret = 0, i = 0, idx = 0;
|
||||
const char *prefix = "rockchip,";
|
||||
int cable = 0;
|
||||
|
||||
ret = wait_locked_card(np, &pdev->dev);
|
||||
if (ret < 0) {
|
||||
@@ -908,6 +909,7 @@ static int rk_multicodecs_probe(struct platform_device *pdev)
|
||||
ret = rk_multicodecs_probe_keys(pdev, mc_data);
|
||||
if (ret)
|
||||
dev_warn(&pdev->dev, "Has no input keys\n");
|
||||
headset_extcon_cable[cable++] = EXTCON_JACK_MICROPHONE;
|
||||
}
|
||||
|
||||
INIT_DEFERRABLE_WORK(&mc_data->handler, adc_jack_handler);
|
||||
@@ -927,8 +929,10 @@ static int rk_multicodecs_probe(struct platform_device *pdev)
|
||||
mc_data->hp_det_gpio = devm_gpiod_get_optional(&pdev->dev, "hp-det", GPIOD_IN);
|
||||
if (IS_ERR(mc_data->hp_det_gpio))
|
||||
return PTR_ERR(mc_data->hp_det_gpio);
|
||||
if (gpiod_to_irq(mc_data->hp_det_gpio) >= 0)
|
||||
if (gpiod_to_irq(mc_data->hp_det_gpio) >= 0) {
|
||||
headset_extcon_cable[cable++] = EXTCON_JACK_HEADPHONE;
|
||||
card->resume_post = &rk_multicodecs_resume_post;
|
||||
}
|
||||
|
||||
mc_data->extcon = devm_extcon_dev_allocate(&pdev->dev, headset_extcon_cable);
|
||||
if (IS_ERR(mc_data->extcon)) {
|
||||
|
||||
Reference in New Issue
Block a user