[PATCH 2/2] Staging: bcm: Add size maximum size restrictions for IOCTL_IDLE_REQ

Kevin McKinney klmckinney1 at gmail.com
Fri Sep 16 21:09:47 UTC 2011


Hi Greg,

On Fri, Sep 16, 2011 at 2:14 PM, Greg KH <greg at kroah.com> wrote:
> On Mon, Sep 12, 2011 at 08:59:18PM -0400, Kevin McKinney wrote:
>> In the first alteration, the MAX_CNTL_PKT_SIZE is the
>> maximum size of the control packet in ->Adapter->txctlpacket[]
>> which is defined in InitAdapter(). This caps the size of
>> kmalloc memory allocation. In the second change, this max
>> cap fixes a potential memory corruption bug when subsequent
>> memset and memcpy calls are invoked.
>>
>> Signed-off-by: Kevin McKinney <klmckinney1 at gmail.com>
>> ---
>>  drivers/staging/bcm/Bcmchar.c             |    3 +++
>>  drivers/staging/bcm/Misc.c                |    4 ++++
>>  2 files changed, 7 insertions(+), 0 deletions(-)
>>  delete mode 100644 arch/arm/mach-lpc32xx/include/mach/gpio.h
>>
>> diff --git a/arch/arm/mach-lpc32xx/include/mach/gpio.h b/arch/arm/mach-lpc32xx/include/mach/gpio.h
>> deleted file mode 100644
>> index e69de29..0000000
>
> Your diffstat above doesn't match this line, so I really can't trust
> this patch at all.
>
> And it doesn't make sense, care to redo these 2 so they do make sense?
>
I understand this is a MAJOR error on my part and I will correct
ASAP!!  Thanks for pointing this out to me.  I will be more careful in
the future.

Thanks,
Kevin



More information about the devel mailing list