diff options
author | Malcolm Priestley <tvboxspy@gmail.com> | 2012-10-07 08:27:00 +0100 |
---|---|---|
committer | Willy Tarreau <w@1wt.eu> | 2013-06-10 11:42:47 +0200 |
commit | 3d4329e7924d1a1ccb1db2a074b8a4961b6fc254 (patch) | |
tree | e30bbd8012289a93646fa08e371bfa90b0108077 /drivers | |
parent | cb4d9e9e10d8b3fbc8cc75caf6f8d89f6cc0c0e2 (diff) |
staging: vt6656: [BUG] out of bound array reference in RFbSetPower.
commit ab1dd9963137a1e122004d5378a581bf16ae9bc8 upstream.
Calling RFbSetPower with uCH zero value will cause out of bound array reference.
This causes 64 bit kernels to oops on boot.
Note: Driver does not function on 64 bit kernels and should be
blacklisted on them.
Signed-off-by: Malcolm Priestley <tvboxspy@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Willy Tarreau <w@1wt.eu>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/vt6656/rf.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/staging/vt6656/rf.c b/drivers/staging/vt6656/rf.c index 405c4f71b5fd..9d059de17351 100644 --- a/drivers/staging/vt6656/rf.c +++ b/drivers/staging/vt6656/rf.c @@ -769,6 +769,9 @@ BYTE byPwr = pDevice->byCCKPwr; return TRUE; } + if (uCH == 0) + return -EINVAL; + switch (uRATE) { case RATE_1M: case RATE_2M: |