All of lore.kernel.org
 help / color / mirror / Atom feed
From: Benjamin Herrenschmidt <benh@kernel.crashing.org>
To: Sven Anderson <sven@anderson.de>
Cc: Matthias Lange <matthias.lange@kernkonzept.com>,
	The development of GNU GRUB <grub-devel@gnu.org>
Subject: Re: [PATCH 3/5] ns8250: Add base support for MMIO UARTs
Date: Wed, 31 Aug 2022 15:56:05 +1000	[thread overview]
Message-ID: <d3678aae43df7d0e4e7393dbb4e7c25d0adb7cfa.camel@kernel.crashing.org> (raw)
In-Reply-To: <CAAQhRycnu8WyieWZ8uGT7T+in_s9rASQndRtCMhkMnOibPqKOQ@mail.gmail.com>

On Mon, 2022-05-23 at 19:11 +0200, Sven Anderson wrote:
> 
> I had a couple of sleepless nights trying to find out why this didn't
> work for my MMIO UART (Intel Cannon Lake PCH Intel C246), so I
> thought I would share my findings with others in a similar situation.
> (See below.)
>  
 .../...
> 
> This code assumes that the registers are only 8 bit wide. Apparently
> for my chipset they are 32 bits wide, so it only (finally) worked
> when I rewrote this code to address and write full grub_uint32_t
> values, like this: 
> 
> ------
>   volatile grub_uint32_t* p = (void*)(port->mmio_base);
>   *(p + reg) = (grub_uint32_t)(value);
> ------

Sorry, I dopped the ball on this for a while. Getting back to it and
will re-submit the patches.

Can you send me a dump of your SPCR table ? I'd like to see if it
properly says "32-bit" there to auto-detect this.

Cheers,
Ben.


  parent reply	other threads:[~2022-08-31  5:58 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-18 22:07 [PATCH 0/5] serial: Add MMIO & SPCR support for AWS EC2 metal instances Benjamin Herrenschmidt
2021-03-18 22:07 ` [PATCH 1/5] acpi: Export a generic grub_acpi_find_table Benjamin Herrenschmidt
2021-03-18 22:07 ` [PATCH 2/5] acpi: Add SPCR and generic address definitions Benjamin Herrenschmidt
2021-03-18 22:07 ` [PATCH 3/5] ns8250: Add base support for MMIO UARTs Benjamin Herrenschmidt
2021-03-19 17:16   ` Glenn Washburn
2021-03-19 23:30     ` Benjamin Herrenschmidt
2022-05-23 17:11   ` Sven Anderson
2022-05-25  3:13     ` Benjamin Herrenschmidt
2022-08-31  5:56     ` Benjamin Herrenschmidt [this message]
2022-08-31  8:26       ` Benjamin Herrenschmidt
2022-09-02  3:58         ` Benjamin Herrenschmidt
2021-03-18 22:07 ` [PATCH 4/5] ns8250: Add configuration parameter when adding ports Benjamin Herrenschmidt
2021-03-18 22:07 ` [PATCH 5/5] ns8250: Use ACPI SPCR table when available to configure serial Benjamin Herrenschmidt
2021-03-19  0:03 ` [PATCH 0/5] serial: Add MMIO & SPCR support for AWS EC2 metal instances Glenn Washburn
2021-03-19  1:27   ` Benjamin Herrenschmidt
2021-03-19 16:25     ` Glenn Washburn
2021-03-23 18:04 ` Daniel Kiper
2021-03-23 22:23   ` Benjamin Herrenschmidt

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=d3678aae43df7d0e4e7393dbb4e7c25d0adb7cfa.camel@kernel.crashing.org \
    --to=benh@kernel.crashing.org \
    --cc=grub-devel@gnu.org \
    --cc=matthias.lange@kernkonzept.com \
    --cc=sven@anderson.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.