[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [Xen-devel] [PATCH v2 47/52] xen: add basic support for runtime parameter changing
>>> On 14.08.17 at 09:08, <jgross@xxxxxxxx> wrote: > --- a/xen/arch/x86/xen.lds.S > +++ b/xen/arch/x86/xen.lds.S > @@ -226,6 +226,10 @@ SECTIONS > __start_schedulers_array = .; > *(.data.schedulers) > __end_schedulers_array = .; > + . = ALIGN(POINTER_ALIGN); > + __param_start = .; > + *(.data.param) > + __param_end = .; > } :text Why do you add this to .data.read_mostly instead of .rodata (or next to .data.rel, as there may be relocations)? Everything else looks okay; I'm slightly tempted to ask for ... > @@ -113,6 +118,19 @@ extern const struct kernel_param __setup_start[], > __setup_end[]; > __kparam __setup_##_var = \ > { __setup_str_##_var, OPT_STR, sizeof(_var), &_var } > > +#define __rtparam __param(__dataparam) > + > +#define custom_param_runtime(_name, _var) \ > + __rtparam __rtpar_##_var = { _name, OPT_CUSTOM, 0, _var } > +#define boolean_param_runtime(_name, _var) \ > + __rtparam __rtpar_##_var = { _name, OPT_BOOL, sizeof(_var), &_var } > +#define integer_param_runtime(_name, _var) \ > + __rtparam __rtpar_##_var = { _name, OPT_UINT, sizeof(_var), &_var } > +#define size_param_runtime(_name, _var) \ > + __rtparam __rtpar_##_var = { _name, OPT_SIZE, sizeof(_var), &_var } > +#define string_param_runtime(_name, _var) \ > + __rtparam __rtpar_##_var = { _name, OPT_STR, sizeof(_var), &_var } ... these to become xyz_runtime_param(), but that's really minor and a matter of taste. Jan _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx https://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |