Re: [PATCH v3 4/7] can: Add Nuvoton NCT6694 CAN support

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

 



On 16/12/2024 at 15:58, Ming Yu wrote:
> Dear Vincent,
> 
> Thank you for your comments,
> 
> Vincent Mailhol <mailhol.vincent@xxxxxxxxxx> 於 2024年12月11日 週三 下午11:25寫道:

(...)

>>>> +     cf->len = xmit->dlc;
>>>
>>> what does xmit->dlc contain? The DLC or the length?
>>
>> +1
>>
>> Also, do not trust the device data. Even if SPI attacks are less
>> common, make sure to sanitize this length.
>>
>>   cf->len = canfd_sanitize_len(xmit->dlc);
>>
>> Or
>>
>>   cf->len = canfd_sanitize_len(xmit->dlc);
>>
>> if xmit->dlc is in fact a DLC.
>>
> 
> Excuse me, the xmit->dlc is actual data length.
> Does it need to be fixed?

Yes, name is xmit->len. DLC has a different meaning.


Yours sincerely,
Vincent Mailhol





[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux