'offset' field in struct Property is calculated as a diff between two pointers
(hw/core/qdev-properties.c:802)
arrayprop->prop.offset = eltptr - (void *)dev;
If offset is declared as int, this subtraction can cause type overflow
thus leading to the fall of the subsequent assert
(hw/core/qdev-pr
Peter Maydell writes:
> On 25 August 2015 at 15:17, Markus Armbruster wrote:
>> Stumbled over this while throwing away old mail. Andreas, what do you
>> think?
>
> Seems right to me -- I suspect the original properties code was
> written with the assumption that the property field would be
> in
Am 11.11.2015 um 09:54 schrieb Markus Armbruster:
> Peter Maydell writes:
>> On 25 August 2015 at 15:17, Markus Armbruster wrote:
>>> Stumbled over this while throwing away old mail. Andreas, what do you
>>> think?
>>
>> Seems right to me -- I suspect the original properties code was
>> written
On 11/12/2015 12:41 PM, Andreas Färber wrote:
> Am 11.11.2015 um 09:54 schrieb Markus Armbruster:
>> Peter Maydell writes:
>>> On 25 August 2015 at 15:17, Markus Armbruster wrote:
Stumbled over this while throwing away old mail. Andreas, what do you
think?
>>>
>>> Seems right to me -
Am 13.11.2015 um 19:32 schrieb John Snow:
> On 11/12/2015 12:41 PM, Andreas Färber wrote:
>> [...] Testing
>> got stuck in ahci though, investigating.
>>
>> Thanks,
>> Andreas
>>
>
> Did you ever reproduce this, or does it seem to just be a race?
Once I updated to a later git commit I was no long
On 11/13/2015 01:36 PM, Andreas Färber wrote:
> Am 13.11.2015 um 19:32 schrieb John Snow:
>> On 11/12/2015 12:41 PM, Andreas Färber wrote:
>>> [...] Testing
>>> got stuck in ahci though, investigating.
>>>
>>> Thanks,
>>> Andreas
>>>
>>
>> Did you ever reproduce this, or does it seem to just be a
Stumbled over this while throwing away old mail. Andreas, what do you
think?
Ildar Isaev writes:
> 'offset' field in struct Property is calculated as a diff between two
> pointers (hw/core/qdev-properties.c:802)
>
> arrayprop->prop.offset = eltptr - (void *)dev;
>
> If offset is declared as in
On 25 August 2015 at 15:17, Markus Armbruster wrote:
> Stumbled over this while throwing away old mail. Andreas, what do you
> think?
Seems right to me -- I suspect the original properties code was
written with the assumption that the property field would be
inside the device struct (and so offs