Re: [Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-09-01 Thread Daniel Kiper
On Thu, Sep 01, 2016 at 01:41:26AM -0600, Jan Beulich wrote: > >>> On 31.08.16 at 21:31, wrote: > > On Wed, Aug 31, 2016 at 07:01:10AM -0600, Jan Beulich wrote: > >> >>> On 30.08.16 at 21:58, wrote: > >> > On Thu, Aug 25, 2016 at 07:27:21AM -0600, Jan Beulich wrote: > >> >> >>> On 20.08.16 at 00:

Re: [Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-09-01 Thread Jan Beulich
>>> On 31.08.16 at 21:31, wrote: > On Wed, Aug 31, 2016 at 07:01:10AM -0600, Jan Beulich wrote: >> >>> On 30.08.16 at 21:58, wrote: >> > On Thu, Aug 25, 2016 at 07:27:21AM -0600, Jan Beulich wrote: >> >> >>> On 20.08.16 at 00:43, wrote: > > [...] > >> >> > +static unsigned int strtoui(const ch

Re: [Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-08-31 Thread Daniel Kiper
On Wed, Aug 31, 2016 at 07:01:10AM -0600, Jan Beulich wrote: > >>> On 30.08.16 at 21:58, wrote: > > On Thu, Aug 25, 2016 at 07:27:21AM -0600, Jan Beulich wrote: > >> >>> On 20.08.16 at 00:43, wrote: [...] > >> > +static unsigned int strtoui(const char *s, const char *stop, const char > >> > **

Re: [Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-08-31 Thread Jan Beulich
>>> On 30.08.16 at 21:58, wrote: > On Thu, Aug 25, 2016 at 07:27:21AM -0600, Jan Beulich wrote: >> >>> On 20.08.16 at 00:43, wrote: >> > +#define NULL ((void *)0) >> > + >> > +#define __packed __attribute__((__packed__)) >> > +#define __stdcall __attribute__((__stdcall__)) >> > + >> > +#def

Re: [Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-08-30 Thread Daniel Kiper
On Thu, Aug 25, 2016 at 07:27:21AM -0600, Jan Beulich wrote: > >>> On 20.08.16 at 00:43, wrote: > > +#define NULL ((void *)0) > > + > > +#define __packed __attribute__((__packed__)) > > +#define __stdcall __attribute__((__stdcall__)) > > + > > +#define max(x,y) ({ \ > > +const typ

Re: [Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-08-25 Thread Jan Beulich
>>> On 20.08.16 at 00:43, wrote: > +#define NULL ((void *)0) > + > +#define __packed __attribute__((__packed__)) > +#define __stdcall__attribute__((__stdcall__)) > + > +#define max(x,y) ({ \ > +const typeof(x) _x = (x); \ > +const typeof(y) _y = (y); \ > +

[Xen-devel] [PATCH v5 14/16] x86/boot: implement early command line parser in C

2016-08-19 Thread Daniel Kiper
Current early command line parser implementation in assembler is very difficult to change to relocatable stuff using segment registers. This requires a lot of changes in very weird and fragile code. So, reimplement this functionality in C. This way code will be relocatable out of the box (without p