高通按键驱动(gpio) + 耳机插入检测
kernel/drivers/input/keyboard/gpio_keys.c
linux,input-type = <1>; //上报的类型
debounce-interval = <15>; //防反跳间隔时间 ms
gpios = <&msm_gpio 15 0x0>; // 0x0为未按下按键时的状态
从中高通本身的耳机检测得到的类型和键值:kernel\sound\core\jack.c
--------------------------------------------2019-5-22-------------------------------------------------------------------
wcd_mbhc_mech_plug_detect_irq -> wcd_mbhc_swch_irq_handler->
wcd_cancel_hs_detect_plug---取消work-- correct_plug_swch(wcd_correct_swch_plug函数)
wcd_mbhc_detect_plug_type ----如果目前是没有耳塞 -> wcd_schedule_hs_detect_plug->schedule_work(work);开始correct_plug_swch -> wcd_correct_swch_plug
连续调用4次wcd_check_cross_conn检测塞子类型,如果是MBHC_PLUG_TYPE_GND_MIC_SWAP类型