How to use serial console to enter GELI password to boot kernel on a GELI encrypted ZFS pool

From: Guido van Rooij <guido_at_gvr.org>
Date: Mon, 15 Aug 2022 14:23:35 UTC
Currently I have a system with ZFS on GELI. I use the ability in
the EFI loader to enter the GELI password.

Is it possible somehow to use a serial console to enter the password?
My system does have a COM1 port but it isn't recognised at the early
bot stage. There I only see:

    Consoles: EFI console
    GELI Passphrase for disk0p4:

(Note: this is early in the boot process so there is no access to
boot.config (or any other file in the ZFS pool) as it still on
encrypted storage at that time).

Regards,
-Guido