[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 1/5] x86/Swiotlb: Add Swiotlb bounce buffer remap function for HV IVM
- To: Christoph Hellwig <hch@xxxxxx>
- From: Tianyu Lan <ltykernel@xxxxxxxxx>
- Date: Wed, 17 Nov 2021 21:32:13 +0800
- Cc: dave.hansen@xxxxxxxxxxxxxxx, luto@xxxxxxxxxx, peterz@xxxxxxxxxxxxx, tglx@xxxxxxxxxxxxx, mingo@xxxxxxxxxx, bp@xxxxxxxxx, x86@xxxxxxxxxx, hpa@xxxxxxxxx, jgross@xxxxxxxx, sstabellini@xxxxxxxxxx, boris.ostrovsky@xxxxxxxxxx, kys@xxxxxxxxxxxxx, haiyangz@xxxxxxxxxxxxx, sthemmin@xxxxxxxxxxxxx, wei.liu@xxxxxxxxxx, decui@xxxxxxxxxxxxx, joro@xxxxxxxxxx, will@xxxxxxxxxx, davem@xxxxxxxxxxxxx, kuba@xxxxxxxxxx, jejb@xxxxxxxxxxxxx, martin.petersen@xxxxxxxxxx, m.szyprowski@xxxxxxxxxxx, robin.murphy@xxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxxx, michael.h.kelley@xxxxxxxxxxxxx, Tianyu Lan <Tianyu.Lan@xxxxxxxxxxxxx>, iommu@xxxxxxxxxxxxxxxxxxxxxxxxxx, linux-hyperv@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, linux-scsi@xxxxxxxxxxxxxxx, netdev@xxxxxxxxxxxxxxx, vkuznets@xxxxxxxxxx, brijesh.singh@xxxxxxx, konrad.wilk@xxxxxxxxxx, parri.andrea@xxxxxxxxx, thomas.lendacky@xxxxxxx, dave.hansen@xxxxxxxxx
- Delivery-date: Wed, 17 Nov 2021 13:32:47 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
Hi Christoph:
Thanks for your review.
On 11/17/2021 5:59 PM, Christoph Hellwig wrote:
The subject is wrong, nothing x86-specific here. Please use
"swiotlb: " as the prefix
OK. Will update. Thanks.
+ * @vaddr: The vaddr of the swiotlb memory pool. The swiotlb
+ * memory pool may be remapped in the memory encrypted case and
store
Please avoid the overly long line. >
+ /*
+ * With swiotlb_unencrypted_base setting, swiotlb bounce buffer will
+ * be remapped in the swiotlb_update_mem_attributes() and return here
+ * directly.
+ */
I'd word this as:
/*
* If swiotlb_unencrypted_base is set, the bounce buffer memory will
* be remapped and cleared in swiotlb_update_mem_attributes.
*/
Thanks for suggestion. Will update. Thanks.
+ ret = swiotlb_init_io_tlb_mem(mem, __pa(tlb), nslabs, false);
+ if (ret) {
+ memblock_free(mem->slots, alloc_size);
+ return ret;
+ }
With the latest update swiotlb_init_io_tlb_mem will always return 0,
so no need for the return value change or error handling here.
OK. Will revert the change.
|