Skip to content

Commit 19d5672

Browse files
authored
Merge pull request #705 from FrameworkComputer/revert-693-azalea.keyboard_issue
Revert "azalea: fixed PS2 yellow band"
2 parents eeea6c9 + 2d3171f commit 19d5672

File tree

2 files changed

+0
-65
lines changed

2 files changed

+0
-65
lines changed

zephyr/program/lotus/azalea/project.conf

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,3 @@ CONFIG_PLATFORM_EC_PWM_KBLIGHT=y
2424
CONFIG_PLATFORM_EC_KEYBOARD_VIVALDI=n
2525
CONFIG_PLATFORM_EC_KEYBOARD_CUSTOMIZATION=y
2626
CONFIG_PLATFORM_KEYBOARD_SCANCODE_CALLBACK=y
27-
28-
# Thrid party change
29-
CONFIG_THIRD_PARTY_CUSTOMIZED_DESIGN=y

zephyr/shim/src/espi.c

Lines changed: 0 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -644,67 +644,6 @@ void lpc_aux_put_char(uint8_t chr, int send_irq)
644644
LOG_INF("AUX put %02x", kb_char);
645645
}
646646

647-
#ifdef CONFIG_THIRD_PARTY_CUSTOMIZED_DESIGN
648-
649-
/*
650-
* this can delay EC release irq and clear IBF
651-
* it will let host not send data too fast, make EC
652-
* have time to process 8042 data and also not lose data
653-
* after delay finish read HIKMDI clear IBF data and release 8042 irq
654-
*/
655-
static void lpc_kbc_process(void)
656-
{
657-
int rv;
658-
uint32_t status;
659-
660-
rv = espi_read_lpc_request(espi_dev, E8042_CLEAR_IBF, &status);
661-
if (rv) {
662-
LOG_ERR("ESPI read failed: E8042_CLEAR_IBF = %d", rv);
663-
return;
664-
}
665-
666-
rv = espi_write_lpc_request(espi_dev, E8042_RESUME_IRQ, 0);
667-
if (rv) {
668-
LOG_ERR("ESPI write failed: E8042_RESUME_IRQ = %d", rv);
669-
}
670-
}
671-
DECLARE_DEFERRED(lpc_kbc_process);
672-
673-
static void kbc_ibf_obe_handler(uint32_t data)
674-
{
675-
#ifdef HAS_TASK_KEYPROTO
676-
uint8_t is_ibf = is_8042_ibf(data);
677-
uint32_t status = I8042_AUX_DATA;
678-
int rv;
679-
680-
if (is_ibf == HOST_KBC_EVT_IBF) {
681-
682-
/* put data to queue and trigger 8042 task*/
683-
keyboard_host_write(get_8042_data(data), get_8042_type(data));
684-
685-
/* Pause 8042 irq let KB task process data */
686-
rv = espi_write_lpc_request(espi_dev, E8042_PAUSE_IRQ, 0);
687-
if (rv) {
688-
LOG_ERR("ESPI write failed: E8042_PAUSE_IRQ = %d", rv);
689-
}
690-
691-
hook_call_deferred(&lpc_kbc_process_data, 200);
692-
693-
} else if (IS_ENABLED(CONFIG_8042_AUX)) {
694-
rv = espi_write_lpc_request(espi_dev, E8042_CLEAR_FLAG,
695-
&status);
696-
if (rv) {
697-
LOG_ERR("ESPI write failed: E8042_CLEAR_FLAG = %d", rv);
698-
}
699-
}
700-
701-
/* OBE data coming */
702-
if (is_ibf != HOST_KBC_EVT_IBF)
703-
task_wake(TASK_ID_KEYPROTO);
704-
705-
#endif
706-
}
707-
#else
708647
static void kbc_ibf_obe_handler(uint32_t data)
709648
{
710649
#ifdef HAS_TASK_KEYPROTO
@@ -724,7 +663,6 @@ static void kbc_ibf_obe_handler(uint32_t data)
724663
task_wake(TASK_ID_KEYPROTO);
725664
#endif
726665
}
727-
#endif
728666

729667
int lpc_keyboard_input_pending(void)
730668
{

0 commit comments

Comments
 (0)