lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 12 Dec 2009 19:58:33 +0100
From:	Oliver Hartkopp <oliver@...tkopp.net>
To:	Wolfgang Grandegger <wg@...ndegger.com>
CC:	David Miller <davem@...emloft.net>,
	Linux Netdev List <netdev@...r.kernel.org>,
	Barry Song <21cnbao@...il.com>
Subject: Re: [PATCH net-2.6] can: Fix data length code handling in rx path

Wolfgang Grandegger wrote:
> Oliver Hartkopp wrote:
>> Wolfgang Grandegger wrote:

>>> Please send you patches inline next time please. For the bfin_can and
>>> the ems_usb driver your patch now masks the dlc with 0xf. Are you sure
>>> this is needed or even correct?
>> Yes. Both needed to be fixed.
>>
>> The bfin_can has an u16 value which is not reduced to 4-bits before.
> 
> The relevant bits are hardware specific.
> 

> 
> I just checked the bfin manual. The DLC value uses a 4 bit field and
> there is also written:
> 
>  "Any DLC value greater than 8 is treated the same as a value of 8."
> 
> That's exactly what this patch fixes. I didn't figure out though, if the
> masking is really required or if the higher bits are undefined (or "0").
> At least it does not harm.

The other 12 bits in the u16 dlc value of the blackfin CAN controller are
'shaded' == marked as 'reserved'. Therefore it's not really specified that
they are always '0' and the masking is indeed needed here.

Tnx for your sign-off.

Regards,
Oliver

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ