Hi Sean, I just realized that files in media_build/linux/driver are not associate with a git repository. They are retrieved by the build command. So, I cloned the linux-stable repository to generate the patch. Regards, Laurent 2017-11-11 11:56 GMT+01:00 Sean Young <sean@xxxxxxxx>: > Hi Laurent, > > On Fri, Nov 10, 2017 at 09:33:58PM +0100, Laurent Caumont wrote: >> Hi Mauro, >> >> I could send you a patch but my git doesn't see the modification I >> made, so it's unable to generate a patch. >> I don't know if it's a git issue on ubunu 17.10 or if it's the way the >> repository was created. > > The difference might be in the git index (or not in it). If you send a > Signed-off-by: Laurent etc line then I'm happy to handle the patch > generation. > > Thanks > > Sean
From 03cebd478b80677252a0f48d71d0de05e6c82740 Mon Sep 17 00:00:00 2001 From: Laurent Caumont <lcaumont2@xxxxxxxxx> Date: Sat, 11 Nov 2017 18:44:46 +0100 Subject: [PATCH] media: dvb: i2c transfers over usb - use kmalloc instead stack --- drivers/media/usb/dvb-usb/dibusb-common.c | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/drivers/media/usb/dvb-usb/dibusb-common.c b/drivers/media/usb/dvb-usb/dibusb-common.c index 8207e690..e1c31381 100644 --- a/drivers/media/usb/dvb-usb/dibusb-common.c +++ b/drivers/media/usb/dvb-usb/dibusb-common.c @@ -223,8 +223,26 @@ EXPORT_SYMBOL(dibusb_i2c_algo); int dibusb_read_eeprom_byte(struct dvb_usb_device *d, u8 offs, u8 *val) { - u8 wbuf[1] = { offs }; - return dibusb_i2c_msg(d, 0x50, wbuf, 1, val, 1); + u8 *wbuf; + u8 *rbuf; + int rc; + + rbuf = kmalloc(1, GFP_KERNEL); + if (!rbuf) + return -ENOMEM; + + wbuf = kmalloc(1, GFP_KERNEL); + if (!wbuf) + return -ENOMEM; + + *wbuf = offs; + + rc = dibusb_i2c_msg(d, 0x50, wbuf, 1, rbuf, 1); + kfree(wbuf); + *val = *rbuf; + kfree(rbuf); + + return rc; } EXPORT_SYMBOL(dibusb_read_eeprom_byte); -- 2.14.1