Linux PCI subsystem development
 help / color / mirror / Atom feed
From: Chao Gao <chao.gao@intel.com>
To: Xu Yilun <yilun.xu@linux.intel.com>
Cc: <linux-pci@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
	<x86@kernel.org>, <linux-coco@lists.linux.dev>,
	<kvm@vger.kernel.org>, <rick.p.edgecombe@intel.com>,
	<kevin.tian@intel.com>, <yilun.xu@intel.com>,
	<chao.p.peng@intel.com>, <baolu.lu@linux.intel.com>,
	Bjorn Helgaas <bhelgaas@google.com>,
	Kiryl Shutsemau <kas@kernel.org>,
	Dave Hansen <dave.hansen@linux.intel.com>
Subject: Re: [RFC PATCH 5/7] coco/tdx-host: Configure an IDE stream
Date: Mon, 30 Nov 2026 21:00:26 +0800	[thread overview]
Message-ID: <aw1zai_20MOlZ9fl@intel.com> (raw)
In-Reply-To: <awrUV1hbcekti2ym@yilunxu-OptiPlex-7050>

On Sat, Nov 28, 2026 at 09:17:11PM +0800, Xu Yilun wrote:
>> +	/* Configure IDE capability for RP & get stream_id */
>> +	ret = tdx_ide_stream_create(tlink, ide);
>> +	if (ret)
>> +		goto out_pci_ide_stream_free;
>> +
>> +	ide->stream_id = tlink->stream_id;
>
>Nits:
>
>Maybe we don't save stream_id in tlink, it can later be accessed by
>tlink->ide->stream_id.
>
>And the function could be like:
>
>	ret = tdx_ide_stream_create(tlink, ide, &stream_id);
>
>which aligns better with the comment "get stream_id".

Looks good to me. Caching the stream_id in tlink needs a justification,
and I don't see a good one.

As I said in [1], I plan to drop func_id as well, because it can be
derived from the pci_dev at runtime.

[1]: https://lore.kernel.org/all/awzkWJ3aM6buVQm1@intel.com/

  reply	other threads:[~2026-11-30 13:01 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-11-16 11:10 [RFC PATCH 0/7] TDX: Enable PCIe link encryption for trusted I/O Chao Gao
2026-11-16 11:10 ` [RFC PATCH 5/7] coco/tdx-host: Configure an IDE stream Chao Gao
2026-11-28 13:17   ` Xu Yilun
2026-11-30 13:00     ` Chao Gao [this message]
2026-11-21  1:35 ` [RFC PATCH 0/7] TDX: Enable PCIe link encryption for trusted I/O Edgecombe, Rick P
2026-11-30 11:11   ` Chao Gao

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=aw1zai_20MOlZ9fl@intel.com \
    --to=chao.gao@intel.com \
    --cc=baolu.lu@linux.intel.com \
    --cc=bhelgaas@google.com \
    --cc=chao.p.peng@intel.com \
    --cc=dave.hansen@linux.intel.com \
    --cc=kas@kernel.org \
    --cc=kevin.tian@intel.com \
    --cc=kvm@vger.kernel.org \
    --cc=linux-coco@lists.linux.dev \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pci@vger.kernel.org \
    --cc=rick.p.edgecombe@intel.com \
    --cc=x86@kernel.org \
    --cc=yilun.xu@intel.com \
    --cc=yilun.xu@linux.intel.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox