Re: [PATCH v1 3/3] crypto: ccp - Protect against poorly marked end of sg list

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

 



On 05/27/2015 07:36 PM, Herbert Xu wrote:
On Wed, May 27, 2015 at 09:12:02AM -0500, Tom Lendacky wrote:

The reason I'm asking is because while this patch fixes your driver
everybody else will still crash and burn should something like this
happen again.

A number of other drivers already have similar sg-count functions in
them.

Perhaps you can help abstract this into a helper that everybody can
call?

I can do that.  Something like an sg_nents_for_len() function that takes
an sg pointer and a u64 length as arguments. The function should also
return an error if the length requirement isn't satisfied.

Thanks,
Tom


Cheers,

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




[Index of Archives]     [Kernel]     [Gnu Classpath]     [Gnu Crypto]     [DM Crypt]     [Netfilter]     [Bugtraq]

  Powered by Linux