[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] move __read_mostly to xen/cache.h
- To: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- From: Jan Beulich <jbeulich@xxxxxxxx>
- Date: Tue, 8 Aug 2023 12:32:51 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=eQ7m4npKV+BARwzs3twm21xAb/EAsWBaVN1ShDwcHkk=; b=dHHBz47F+ALlJ+HFpqlmwH7GEttjYEf2tHzmZeyL2qHXCok6auGh6Ep5rV4VxXMcd9No13UZj3WVNE882rT+HMesEshWca4KEpO0Z+dEH8NKQkBaQ68ecnJQMIiE93tRfLp1OdWgcPTeVcz+ndEYKuoEo1ODzg1mg6EoQfh+hXjg2PbLwFWldpn/C05pWdj8Pp9J+TcY2jXALeaDJbTLghjgIHqKSAAhi4nLZaUzGvMUeCMmAztsqWAJBNkE5SzimMPllJXwW3IGHeQ0PmpF/emQmVX1nKDun5cEIKFTGZ16HbUrYT7MnRfXg8oqMYYJf3tC8pV4YIku7Uz4YNyqig==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=FWLtjisE9QzbfTYXaigkyWZvWAPFo7vt+951Py5m7vA9s1niWpVgjHIWGxJlkwl5t6SLhrBos6vtaQocQNayg1cg/WhE0779D1DJrKHWmdNAOTwe2qOHmwgQ0Lq3N7f3cwMhA7Gxut1Ps7r0uUwaeTrtSHf3D0eDgRsdrmu5kGEMkKhoNla1JW2BsYym4bYgSl4k6RTlz8nek39WpJwOfMCblX2eoOgkxxVUSw6vhPqlzoMu6G5CAbiN195CQzZM9SMlim9I3Js0eXNQ707RcHz55VIgI6BSjow5t5eiSdweP6yCrFcuUS2misi/RnCPY0KltfDPxC3UlvuSDOFGAA==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=suse.com;
- Cc: George Dunlap <george.dunlap@xxxxxxxxxx>, Julien Grall <julien@xxxxxxx>, Stefano Stabellini <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>, Bertrand Marquis <bertrand.marquis@xxxxxxx>, Volodymyr Babchuk <volodymyr_babchuk@xxxxxxxx>, Shawn Anastasio <sanastasio@xxxxxxxxxxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Tue, 08 Aug 2023 10:33:02 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On 08.08.2023 12:18, Andrew Cooper wrote:
> On 08/08/2023 10:46 am, Jan Beulich wrote:
>> There's no need for every arch to define its own identical copy. If down
>> the road an arch needs to customize it, we can add #ifndef around the
>> common #define.
>>
>> To be on the safe side build-breakage-wise, change a couple of #include
>> <asm/cache.h> to the xen/ equivalent.
>>
>> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
>
> Could we find a better place to put this?
>
> __read_mostly is just a section. It's relationship to the cache is only
> microarchitectural, and is not the same kind of information as the rest
> of cache.h
>
> __ro_after_init is only here because __read_mostly is here, but has
> absolutely nothing to do with caches whatsoever.
>
> If we're cleaning them up, they ought to live elsewhere.
I would be considering init.h (for having most other __section() uses,
and for also needing __read_mostly), but that's not a great place to
put these either. In fact I see less connection there than for cache.h.
So the primary need is a good suggestion (I'm hesitant to suggest to
introduce section.h just for this). In the absence of this, can we
perhaps deal with this in a 2nd step, thus not blocking this patch and
therefore not needing to then also clean up PPC-specific code?
Jan
|