All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Marek Marczykowski-Górecki" <marmarek@invisiblethingslab.com>
To: Jan Beulich <jbeulich@suse.com>
Cc: "Connor Davis" <davisc@ainfosec.com>,
	"Andrew Cooper" <andrew.cooper3@citrix.com>,
	"Roger Pau Monné" <roger.pau@citrix.com>, "Wei Liu" <wl@xen.org>,
	"George Dunlap" <george.dunlap@citrix.com>,
	"Julien Grall" <julien@xen.org>,
	"Stefano Stabellini" <sstabellini@kernel.org>,
	"Connor Davis" <connojdavis@gmail.com>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH v1 01/10] drivers/char: Add support for Xue USB3 debugger
Date: Sun, 3 Jul 2022 14:17:17 +0200	[thread overview]
Message-ID: <YsGIzXKPr+j05TC4@mail-itl> (raw)
In-Reply-To: <8322303f-021a-b520-d2ad-cf8310573df5@suse.com>

[-- Attachment #1: Type: text/plain, Size: 1710 bytes --]

On Thu, Jun 23, 2022 at 11:29:31AM +0200, Jan Beulich wrote:
> On 22.06.2022 17:47, Marek Marczykowski-Górecki wrote:
> > On Wed, Jun 15, 2022 at 04:25:54PM +0200, Jan Beulich wrote:
> >> On 07.06.2022 16:30, Marek Marczykowski-Górecki wrote:
> >>> +    memset(xue, 0, sizeof(*xue));
> >>> +
> >>> +    xue->dbc_ctx = &ctx;
> >>> +    xue->dbc_erst = &erst;
> >>> +    xue->dbc_ering.trb = evt_trb;
> >>> +    xue->dbc_oring.trb = out_trb;
> >>> +    xue->dbc_iring.trb = in_trb;
> >>> +    xue->dbc_owork.buf = wrk_buf;
> >>> +    xue->dbc_str = str_buf;
> >>
> >> Especially the page-sized entities want allocating dynamically here, as
> >> they won't be needed without the command line option requesting the use
> >> of this driver.
> > 
> > Are you okay with changing this only in patch 9, where I restructure those
> > buffers anyway?
> 
> I'm afraid I'll need to make it to patch 9 to answer this question. If
> suitable dealt with later, I don't see a fundamental problem, as long
> as it's clear then that I will request that this patch be committed in
> a batch with that later one, not in isolation.

This turns out to be rather problematic. xue_uart_init() is called
really early (as it should, to get console as early as possible). It's
before even boot allocator is functioning, so I can't use alloc_boot_pages().
Are there any other options for memory allocations at this point?
We are talking about 58 pages. It isn't much, but isn't exactly nothing
either. Maybe there is way to keep the memory allocated statically as it
is now, but return it to the allocator is xue is _not_ enabled?

-- 
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]

  reply	other threads:[~2022-07-03 12:17 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-07 14:30 [PATCH v1 00/10] Add Xue - console over USB 3 Debug Capability Marek Marczykowski-Górecki
2022-06-07 14:30 ` [PATCH v1 01/10] drivers/char: Add support for Xue USB3 debugger Marek Marczykowski-Górecki
2022-06-15 14:25   ` Jan Beulich
2022-06-22 15:47     ` Marek Marczykowski-Górecki
2022-06-23  9:29       ` Jan Beulich
2022-07-03 12:17         ` Marek Marczykowski-Górecki [this message]
2022-07-04  6:05           ` Jan Beulich
2022-07-04  9:27             ` Marek Marczykowski-Górecki
2022-07-04  9:36               ` Jan Beulich
2022-06-07 14:30 ` [PATCH v1 02/10] xue: reset XHCI ports when initializing dbc Marek Marczykowski-Górecki
2022-06-15 14:35   ` Jan Beulich
2022-06-07 14:30 ` [PATCH v1 03/10] xue: add support for selecting specific xhci Marek Marczykowski-Górecki
2022-06-15 14:40   ` Jan Beulich
2022-06-07 14:30 ` [PATCH v1 04/10] ehci-dbgp: fix selecting n-th ehci controller Marek Marczykowski-Górecki
2022-06-15 14:42   ` Jan Beulich
2022-06-07 14:30 ` [PATCH v1 05/10] console: support multiple serial console simultaneously Marek Marczykowski-Górecki
2022-06-07 14:30 ` [PATCH v1 06/10] IOMMU: add common API for device reserved memory Marek Marczykowski-Górecki
2022-06-07 14:30 ` [PATCH v1 07/10] IOMMU/VT-d: wire common device reserved memory API Marek Marczykowski-Górecki
2022-06-07 14:30 ` [PATCH v1 08/10] IOMMU/AMD: " Marek Marczykowski-Górecki
2022-06-07 14:30 ` [PATCH v1 09/10] xue: mark DMA buffers as reserved for the device Marek Marczykowski-Górecki
2022-06-07 14:30 ` [PATCH v1 10/10] xue: allow driving the rest of XHCI by a domain while Xen uses DbC Marek Marczykowski-Górecki
2022-06-07 18:48 ` [PATCH v1 00/10] Add Xue - console over USB 3 Debug Capability Tamas K Lengyel
2022-07-06  7:30 ` Henry Wang

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=YsGIzXKPr+j05TC4@mail-itl \
    --to=marmarek@invisiblethingslab.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=connojdavis@gmail.com \
    --cc=davisc@ainfosec.com \
    --cc=george.dunlap@citrix.com \
    --cc=jbeulich@suse.com \
    --cc=julien@xen.org \
    --cc=roger.pau@citrix.com \
    --cc=sstabellini@kernel.org \
    --cc=wl@xen.org \
    --cc=xen-devel@lists.xenproject.org \
    /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.