[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v6 6/9] xen/riscv: introduce functionality to work with CPU info
On 12.09.2024 18:02, oleksii.kurochko@xxxxxxxxx wrote: > On Tue, 2024-09-10 at 12:33 +0200, Jan Beulich wrote: >>> +/* >>> + * Mapping between linux logical cpu index and hartid. >>> + */ >>> +#define cpuid_to_hartid(cpu) (pcpu_info[cpu].hart_id) >> >> Does this need to be a macro (rather than an inline function)? > I started to rework that and I am using this macros for both read > and write. So it will be needed to introduce set and get inline > functions instead of just one macros. I think I will stick to one > macros instead of 2 inline functions. You may want to consult with Andrew as to use of such a macro on the lhs of an assignment. I expect he'll ask to avoid such, and instead indeed go with both a get and a set accessor (unless it would make sense to simply open-code the few sets that there are going to be). Jan
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |