Re: [PATCH] staging: rtl8712: fix uninit-value "data" and "mac"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 22/04/15 12:57PM, Dan Carpenter wrote:
> 
> But in r8712_usbctrl_vendorreq() you really need to make the other
> changes I mentioned as well.  If you want to do it as a separate patch
> that's fine too.
> 
> 	if (status < 0)
> 		return status;
> 	if (status != len)
> 		return -EREMOTEIO;
> 
> 	if (reqtype == 0x1)
> 		memcpy();
> 
> 	return 0;

Hi Dan and Pavel,

Sorry for the late reply. A v2 patch series is prepared, in which the
uninit-value bug is fixed by adding error checking and initialization.
In that case, r8712_usbctrl_vendorreq() is not touched any more. So
WDYT to refactor r8712_usbctrl_vendorreq() in another patch with the
code Dan mentioned above and usb_control_msg_{recv,send} suggested by
Pavel? And for now, the patch series is just confined to fixing
uninit-values. The patches will each focus on one thing that is easy
to understand.

thanks,
- w




[Index of Archives]     [Linux Driver Development]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux