[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v4 2/4] xen/arm: Handle cases when hardware_domain is NULL
- To: Julien Grall <julien@xxxxxxx>
- From: Luca Fancellu <luca.fancellu@xxxxxxx>
- Date: Wed, 14 Apr 2021 12:29:34 +0100
- 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=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-SenderADCheck; bh=R/VN/GoQKR6zPj5D4Kg4MdD4GzHVKmR7F6Rx58LTb2E=; b=T/nGOUcachSsHHcBUdywpuIM83v2tc1fjbg8SOZaF41dVUfDRXNNuJX1N7WE+GpL3iFHOW/scHFpvAeF9vxVURuIgdd2KOjIDyN89PHT24R3i6C0Qy82mUzBha5mL6zbcawmSmznmwwXszszHot/zaR7y7iBgW+sRZ3bqJW+LA7AcDMsP910B7jtH4rn4PF/anRV3NBHZ87X5tNJfWU+rND81TPH7BSf5rq7aJzpQIWry+COi6fEhhWhlNj7d4WuOucV1C5hY1cAcUMuxvNhsev8VeJ9lKwb7SZH87m6b9pb3Z43ZEjm0Cn8hetap7u9+rUo7T7k0gE5g+YBGr+C+g==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=doeqdN87xrQskHcboqecBQWRylIvzZxucjEqW21FnYu9ClSQ9DaWWm/a8XG43ccblzgcZxCvmQDf+k7VuAW1X9IViGULg3OktBDGWfJ+Fav2yUiLbZSNEhw0il0JzljO640uGFunBrGDTGSoPH51nxx1V2r72/XLDBk6LM6aIzYmTswU3Z/dYeStmamqqyc7RLK1BumKXHE2p+Y8O3y4Xy0ZpLoG6vrWOGH5WeUH1o5o2i5TRONR3YVpIQ8FqvJTImCTG8UgfoCaqv5jJXme+YSymS7ie5cQTTo6NTXSiLKxAr6xoVwe5Vlt24Mx3pmb5H1+p3TCywXEqSeg+mc7cA==
- Authentication-results-original: xen.org; dkim=none (message not signed) header.d=none;xen.org; dmarc=none action=none header.from=arm.com;
- Cc: xen-devel@xxxxxxxxxxxxxxxxxxxx, Bertrand Marquis <bertrand.marquis@xxxxxxx>, wei.chen@xxxxxxx, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Volodymyr Babchuk <Volodymyr_Babchuk@xxxxxxxx>, Rahul Singh <rahul.singh@xxxxxxx>
- Delivery-date: Wed, 14 Apr 2021 11:30:09 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
- Nodisclaimer: true
- Original-authentication-results: xen.org; dkim=none (message not signed) header.d=none;xen.org; dmarc=none action=none header.from=arm.com;
> On 14 Apr 2021, at 12:16, Julien Grall <julien@xxxxxxx> wrote:
>
> Hi Luca,
>
> On 14/04/2021 10:14, Luca Fancellu wrote:
>> Among the common and arm codebase there are few cases where
>> the hardware_domain variable is checked to see if the current
>> domain is equal to the hardware_domain, change this cases to
>> use is_hardware_domain() function instead. >
>> Signed-off-by: Luca Fancellu <luca.fancellu@xxxxxxx>
>> ---
>> v4 changes:
>> - removed unneeded check for domain NULL from is_hardware_domain
>> introduced in v3
>
> After this change, this patch is only avoid to open-code
> is_hardware_domain(). Although, it adds an extra speculation barrier.
>
> I am not against the change, however I think the commit message needs to
> updated to match what the patch is doing.
>
> Can you propose a new commit message?
Hi Julien,
Yes I agree, what about:
xen/arm: Reinforce use of is_hardware_domain
Among the common and arm codebase there are few cases where
the hardware_domain variable is checked to see if the current
domain is equal to the hardware_domain, change this cases to
use is_hardware_domain() function instead.
In the eventuality that hardware_domain is NULL, is_hardware_domain
will return false because an analysis of the common and arm codebase
shows that is_hardware_domain is called always with a non NULL
domain pointer.
Cheers,
Luca
>
> Cheers,
>
> --
> Julien Grall
|