All of lore.kernel.org
 help / color / mirror / Atom feed
From: Artem Mygaiev <artem_mygaiev@epam.com>
To: Julien Grall <julien.grall@arm.com>,
	Jan Beulich <JBeulich@suse.com>,
	Oleksandr Andrushchenko <andr2000@gmail.com>
Cc: Lars Kurth <lars.kurth@citrix.com>,
	Iurii Konovalenko <iurii.konovalenko@globallogic.com>,
	Volodymyr Babchuk <vlad.babchuk@gmail.com>,
	TimDeegan <tim@xen.org>,
	Dario Faggioli <dario.faggioli@citrix.com>,
	ian.jackson@eu.citrix.com,
	Andrii Anisov <andrii.anisov@gmail.com>,
	Oleksandr Tyshchenko <olekstysh@gmail.com>,
	embedded-pv-devel <embedded-pv-devel@lists.xenproject.org>,
	al1img@gmail.com, David Vrabel <david.vrabel@citrix.com>,
	xen-devel <xen-devel@lists.xenproject.org>,
	Oleksandr Dmytryshyn <oleksandr.dmytryshyn@globallogic.com>,
	Mygaiev Artem <joculator@gmail.com>
Subject: Re: [Embedded-pv-devel] [PATCH v9] xen: add para-virtual sound interface header files
Date: Thu, 24 Nov 2016 18:29:31 +0200	[thread overview]
Message-ID: <c1e3aee1-e9f9-71d5-2431-c1d247ad1209@epam.com> (raw)
In-Reply-To: <95590564-4f6f-6fd7-f9f3-5bf9e3c4ecb2@arm.com>



On 24.11.16 18:08, Julien Grall wrote:
> On 24/11/16 15:50, Artem Mygaiev wrote:
>> On 24.11.16 17:09, Julien Grall wrote:
>>> Hi Artem,
>>>
>>> On 24/11/16 14:58, Artem Mygaiev wrote:
>>>> On 24.11.16 15:31, Jan Beulich wrote:
>>>>>>>> On 24.11.16 at 14:18, <artem_mygaiev@epam.com> wrote:
>>>>>> On 24.11.16 15:04, Jan Beulich wrote:
>>>>>>>> In my case I need it to at least define Linux specific __packed
>>>>>>>> attribute which is not supported by Win AFAIK.
>>>>>>> ... needs to avoid using platform specific constructs (or making
>>>>>>> other assumptions on the platform). I can only re-iterate: Please
>>>>>>> follow the model other PV protocols already present (without
>>>>>>> repeating their mistakes, if at all possible).
>>>>>> But if we don't pack (or enforce some specific alignment) data
>>>>>> structures used between domains they may have different alignment on
>>>>>> different domains, no?
>>>>> Let me repeat what I've said before: Please take a look at existing
>>>>> interface headers. By properly placing fields and adding explicit
>>>>> padding where needed, you can avoid such layout differences.
>>>>
>>>> Don't get me wrong - I have checked the i/f headers before. My concern
>>>> is very generic: C standard defines alignment as an
>>>> *implementation-defined* integer, so current implementation is based
>>>> under two assumptions on the guest platforms: a) guest compiler
>>>> does not
>>>> have "packing" enabled by default and b) alignment follows typical
>>>> values (1 byte for char, 2 bytes for short, ...). While this is
>>>> true in
>>>> most cases, with some embedded RTOS this may become an issue.
>>>
>>> I am not sure why you mentioned embedded RTOS, this is specific to the
>>> compiler and not an OS.
>>>
>> Indeed, my statement is not quite correct. It is just that there are
>> proprietary RTOSes bundled with IDEs with own or customized tools,
>> compilers, etc.
>
> And their own ABI? It sounds crazy to me that someone may decide to
> use padding even when field are naturally aligned.
No, no, that would be overkill... I am just talking about system-wide
alignment configuration for performance/size balance (reduce padding,
not increase).

_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  reply	other threads:[~2016-11-24 16:29 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-23 16:38 [PATCH v9] sndif: add ABI for para-virtual sound Oleksandr Andrushchenko
2016-11-23 16:38 ` [PATCH v9] xen: add para-virtual sound interface header files Oleksandr Andrushchenko
2016-11-24 10:58   ` Jan Beulich
2016-11-24 11:49     ` Oleksandr Andrushchenko
2016-11-24 12:15       ` Jan Beulich
2016-11-24 12:52         ` Oleksandr Andrushchenko
2016-11-24 13:02           ` Jan Beulich
2016-11-24 12:15       ` [Embedded-pv-devel] " Julien Grall
2016-11-24 12:53         ` Oleksandr Andrushchenko
2016-11-24 13:00           ` Julien Grall
2016-11-24 14:28             ` Oleksandr Andrushchenko
2016-11-24 13:04           ` Jan Beulich
2016-11-24 13:18             ` Artem Mygaiev
2016-11-24 13:31               ` Jan Beulich
2016-11-24 14:58                 ` Artem Mygaiev
2016-11-24 15:09                   ` Julien Grall
2016-11-24 15:50                     ` Artem Mygaiev
2016-11-24 16:08                       ` Julien Grall
2016-11-24 16:29                         ` Artem Mygaiev [this message]
2016-11-24 15:11                   ` Jan Beulich
2016-11-24 15:29                   ` Oleksandr Andrushchenko
2016-11-24 12:13   ` Julien Grall
2016-11-24 12:35     ` Oleksandr Andrushchenko

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c1e3aee1-e9f9-71d5-2431-c1d247ad1209@epam.com \
    --to=artem_mygaiev@epam.com \
    --cc=JBeulich@suse.com \
    --cc=al1img@gmail.com \
    --cc=andr2000@gmail.com \
    --cc=andrii.anisov@gmail.com \
    --cc=dario.faggioli@citrix.com \
    --cc=david.vrabel@citrix.com \
    --cc=embedded-pv-devel@lists.xenproject.org \
    --cc=ian.jackson@eu.citrix.com \
    --cc=iurii.konovalenko@globallogic.com \
    --cc=joculator@gmail.com \
    --cc=julien.grall@arm.com \
    --cc=lars.kurth@citrix.com \
    --cc=oleksandr.dmytryshyn@globallogic.com \
    --cc=olekstysh@gmail.com \
    --cc=tim@xen.org \
    --cc=vlad.babchuk@gmail.com \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.