Re: [PATCH 09/14] smbus-eeprom: remove PROP_PTR

2019-10-21 Thread Marc-André Lureau
Hi On Fri, Oct 18, 2019 at 5:43 PM Marc-André Lureau wrote: > > Instead, set the initial data field directly. Since it is only 256 > bytes, let's simply copy it to avoid invalid pointers issues. Actually, the commit message is wrong. The patch used to introduce a init_data[256] array, and copy i

Re: [PATCH 09/14] smbus-eeprom: remove PROP_PTR

2019-10-21 Thread Corey Minyard
On Fri, Oct 18, 2019 at 06:20:40PM +0100, Peter Maydell wrote: > On Fri, 18 Oct 2019 at 16:43, Marc-André Lureau > wrote: > > > > Instead, set the initial data field directly. Since it is only 256 > > bytes, let's simply copy it to avoid invalid pointers issues. > > (Commit message says you copy

Re: [PATCH 09/14] smbus-eeprom: remove PROP_PTR

2019-10-18 Thread Peter Maydell
On Fri, 18 Oct 2019 at 16:43, Marc-André Lureau wrote: > > Instead, set the initial data field directly. Since it is only 256 > bytes, let's simply copy it to avoid invalid pointers issues. (Commit message says you copy the 256 bytes, but the code doesn't seem to do any copying?) > Signed-off-by

[PATCH 09/14] smbus-eeprom: remove PROP_PTR

2019-10-18 Thread Marc-André Lureau
Instead, set the initial data field directly. Since it is only 256 bytes, let's simply copy it to avoid invalid pointers issues. Signed-off-by: Marc-André Lureau --- hw/i2c/smbus_eeprom.c | 17 - 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/hw/i2c/smbus_eeprom.c