[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 2/8] xen/evtchn: modify evtchn_alloc_unbound to allocate specified port
- To: Julien Grall <julien@xxxxxxx>
- From: Rahul Singh <Rahul.Singh@xxxxxxx>
- Date: Thu, 21 Jul 2022 12:50:15 +0000
- Accept-language: en-US
- Arc-authentication-results: i=2; mx.microsoft.com 1; spf=pass (sender ip is 63.35.35.123) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=arm.com; dmarc=pass (p=none sp=none pct=100) action=none header.from=arm.com; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com; arc=pass (0 oda=1 ltdi=1 spf=[1,1,smtp.mailfrom=arm.com] dkim=[1,1,header.d=arm.com] dmarc=[1,1,header.from=arm.com])
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none
- Arc-message-signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=DeQr1vXptp6pTT09bPtp+3miZOJ5V5Uar/Aa96P3ZWw=; b=JppjC92jRvMVHJ/AZl/uy0w/+xMd42ZKEk0ner7XSvsjev2BJESCZ4a4H4EqDpsVa4MeaA7rSNgBwmgau1TbIOwKJaE59rqVYgg9/fWeK1DdRdhqYTkgwFJCBta7pjbwHtMYoDXE2QYCIpxXKL2VytxNmwUCjgo5ED96V+aYJ97H3t7p7Yo3PE8N74HhC29cen+M/Lh5hn2a8aafGslVMFW7fxxR7F26cWBgKM0z0G0mjf3DdsCgviY+dKhPhJaKweCrK57CKysGVFiHp141BV3+KiDDynFG42wUeRXO8/LA/9ulG8lLiGOaoPDPMrbSF0LsqVCuWvbCeXUNa5YsmA==
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=DeQr1vXptp6pTT09bPtp+3miZOJ5V5Uar/Aa96P3ZWw=; b=YiWMO7U+CLAx0/NIsvg7j8/Vvzo1qzd5g+XQAKbVfipPQuA9glqZ2hBGNoxLV8usqDBZ1OmQ3Vy5Q6OBl1/YoAAriJqaCTbKev+vc+NvP9pPwCN4nUEJmjlMbssN2l13vXR3evnTnoBk+a3brPPbRTJkBDqY+Vrk9nrLYnHQAG1PLwJSX7H/n5jm2Ip1ID6iI9AaC+BUii2Oy9/l751LWg/B/tyc4VOw5wM7liX5DXa645FoBaJY/g1Bg+kHAqpCVn07gfmrea39Mjw5Et6NN0IoND8mK2iaYeLUF3NvyUA8GM7S4cijglolRv8nnsHXhqPWJzc47sxnotrtmCO8gA==
- Arc-seal: i=2; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=pass; b=JZ4tybgaDFWjR2h7FS5aXI/5DQw2ID44lNqmiq/1vki4+8hBxI3hGXBE+Y35chFyssNbMHke1GV4Y9fonqJDcNwzLTV6JQV1ioEDSRxs3eL7KxYKaKaJNwIChPh/O8ZUXNH8mXZrKOJAX8FSKKjp0lW0Yax20B7mW+fuL09alJaIiHNhfLDwZj0m7109aZtcLztz1zVvx5gCP+Ce7KAi/usxS+pkyIl5s71V8qe4v85Q2pVJ73gC8OFqYf1qc1vU91kYtbAs83qCI/iOOnqtvY+9VuRt8RpVOsD5H40MT1f/DzTZezMGZXZCyKg0RA4uBcpq7NT6U/kNot3GE9o26w==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=C+5WhtA736SOS4vifFKTKOaiw0Edt9YOz86yXKSjBoRJEnVlAxLCjqiZUEdYgrsvznnch3nxRkYszyDIrJQkfnEi7yMfwi70Ul3Xr7xXws53/rqlHtGp5vBI5htVaWi1LIQ1ra4o9TyrxE5leA37e+efWHt27iQmc7B+M7CrNbxOsRv6ayaKmSxgr6HXEw+jeKLK4CDRYcTYriZ9gxW0Hv5j2j6i6mmTO3I6+G7o3oRtPAR/i2UyzXlKos+rkCYtdRfaX0zOT5S3E/KKeFPFuqLhBrGHrvTz/m66dyOirTox9Ttngc1XkeBfPE/cLmU5TVufTjbijiSpeUhgCtBoiA==
- Authentication-results-original: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
- Cc: Bertrand Marquis <Bertrand.Marquis@xxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, George Dunlap <george.dunlap@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
- Delivery-date: Thu, 21 Jul 2022 12:51:05 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Nodisclaimer: true
- Original-authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=arm.com;
- Thread-index: AQHYhkXaSSR0QDc2DUiowhnmyNd/Sq1bgqiAgB3xuACAAai8gIAA1/CAgAA2U4CAAAT8AIAABuwAgAAKeYCAAAnjAIAAC4AAgAAEsgCACtZcgIAAFXWAgAGspoA=
- Thread-topic: [PATCH 2/8] xen/evtchn: modify evtchn_alloc_unbound to allocate specified port
Hi Julien,
> On 20 Jul 2022, at 12:16 pm, Julien Grall <julien@xxxxxxx> wrote:
>
> Hi Rahul,
>
> On 20/07/2022 10:59, Rahul Singh wrote:
>>> On 13 Jul 2022, at 1:29 pm, Julien Grall <julien@xxxxxxx> wrote:
>>>
>>>
>>>
>>> On 13/07/2022 13:12, Bertrand Marquis wrote:
>>>>> On 13 Jul 2022, at 12:31, Julien Grall <julien@xxxxxxx> wrote:
>>>>>> I can't
>>>>>> see why it would be wrong to have a more tight limit on static ports
>>>>>> than on traditional ("dynamic") ones. Even if only to make sure so
>>>>>> many dynamic ones are left.
>>>>>
>>>>> This is similar to Xen forbidding to close a static port: it is not the
>>>>> hypervisor business to check that there are enough event channel ports
>>>>> freed for dynamic allocation.
>>>> On other side we need to be cautious not to add too much complexity in the
>>>> code by trying to make things always magically work.
>>>> If you want Xen to be accessible to non expert by magically working all
>>>> the time, there would be a lot of work to do.
>>>
>>> It is not clear to me whether you are referring to a developper or admin
>>> here.
>>>
>>> On the admin side, we need to make sure they have an easy way to configure
>>> event channels. One knob is always going to easier than two knobs.
>>>
>>> On the developper side, this could be resolved by better documentation in
>>> the code/interface.
>>>
>>> Cheers,
>> To conclude the discussion, If everyone agree I will add the below patch or
>> similar in the next version to restrict the
>> max number of evtchn supported as suggested.
>
> I am fine if the limit for domU is fixed by Xen for now. However, for dom0,
> 4096 is potentially too low if you have many PV drivers (each backend will
> need a few event channels). So I don't think this wants to be fixed by Xen.
Agree.
>
> I am not entirely sure we want to limit the number of event channels for
> dom0. But if you want to, then this will have to be done via a command line
> option (or device-tree property).
We need to support the static event channel for dom0 also, in that case, we
need to restrict the max number of evtchn for dom0 to mitigate the security
issue.
I am okay with introducing the new command line option "max_event_channels” for
dom0 and setting the default value to 4096.
If the admin set the value greater than 4096 (or what we agreed on) and static
event channel support is enabled we will print the warning to the user related
to fill
the hole issue for FIFO ABI.
Regards,
Rahul
|