Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove GPH7 on IT8587E #476

Merged
merged 1 commit into from
Jul 30, 2024
Merged

Remove GPH7 on IT8587E #476

merged 1 commit into from
Jul 30, 2024

Conversation

crawfxrd
Copy link
Member

@crawfxrd crawfxrd commented Jul 5, 2024

On IT8587E, pin 3 is VBAT and not a GPIO pin.

Ref: Table 4-1. Pins Listed in Numeric Order (128-pin LQFP)
Ref: Table 7-14. GPIO Alternate Function

@crawfxrd crawfxrd requested review from a team July 5, 2024 15:25
@leviport
Copy link
Member

Since I was testing this on my darp5 which suffers from the IT8587E hang without the latest commit on master, I was trying to build this in a convoluted way, and I don't think I was doing it quite right.

I was building a USB image from firmware-open, so the first thing I did was cd into ec and git checkout master && git pull.
Next, I did a git cherrypick it8587e-gph7 to try and pull in this change.
But then after flashing, I got EC lockups again when restoring my keymap with keyboard-configurator. I'm not really sure why though, since my git log looks about right:

commit 24fd877c348ecef1edc595df4ccc9804e192e795 (HEAD -> master)
Author: Tim Crawford <[email protected]>
Date:   Fri Jul 5 09:07:03 2024 -0600

    Remove GPH7 on IT8587E

    On IT8587E, pin 3 is VBAT and not a GPIO pin.

    Signed-off-by: Tim Crawford <[email protected]>

commit 716efd4eb50b5e364662705114b08b15cc254048 (origin/master, origin/HEAD)
Author: Tim Crawford <[email protected]>
Date:   Wed Jul 24 13:48:53 2024 -0600

    kbscan: Work around IT8587E hang

    IT8587E is hanging when reading the keyboard matrix.

    - Increasing the delay does not fix it
    - Placing delays between KSO* writes does not fix it
    - Code generated by SDCC looks valid to me

    Rewriting it like this does fix it, although I don't know why.

    Signed-off-by: Tim Crawford <[email protected]>

commit 984428b6a8df23a0589cd8dd9e60457d2016e8b8
Author: Tim Crawford <[email protected]>
Date:   Thu Jul 18 16:27:54 2024 -0600

---[snip]---

I did rebuild and re-flash firmware-open in the same state one more time, just to make sure it wasn't a fluke, but I got the same lockup again.

Last, I reset ec to origin/master and rebuilt and re-flashed, and the EC lockups stopped. It doesn't seem like this pin should be interfering with the keyboard scanning functionality, so I'm guessing my git meddling is just messing things up.

Can we update this branch on current master? It'll bypass my need to tamper with git history and eliminate the Levi variable from the equation.

On IT8587E, pin 3 is VBAT and not a GPIO pin.

Signed-off-by: Tim Crawford <[email protected]>
@crawfxrd
Copy link
Member Author

Rebased on master.

Copy link
Member

@leviport leviport left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, the problem was whatever I was doing. This change is working great now.

@crawfxrd crawfxrd merged commit 51d35cb into master Jul 30, 2024
47 checks passed
@crawfxrd crawfxrd deleted the it8587e-gph7 branch July 30, 2024 00:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants