diff options
author | Pavel Roskin <[email protected]> | 2009-08-04 17:48:16 -0400 |
---|---|---|
committer | John W. Linville <[email protected]> | 2009-08-14 09:06:52 -0400 |
commit | 6b26dead3ce97d016b57724b01974d5ca5c84bd5 (patch) | |
tree | d6968f04884bcb8bf28f29a6ed8f0dc73ea191ef /drivers/mtd/lpddr/lpddr_cmds.c | |
parent | 416fbdff2137e8d8cc8f23f517bee3a26b11526f (diff) |
rt2x00: fix memory corruption in rf cache, add a sanity check
Change rt2x00_rf_read() and rt2x00_rf_write() to subtract 1 from the rf
register number. This is needed because the rf registers are enumerated
starting with one. The size of the rf register cache is just enough to
hold all registers, so writing to the highest register was corrupting
memory. Add a check to make sure that the rf register number is valid.
Signed-off-by: Pavel Roskin <[email protected]>
Cc: [email protected]
Acked-by: Ivo van Doorn <[email protected]>
Signed-off-by: John W. Linville <[email protected]>
Diffstat (limited to 'drivers/mtd/lpddr/lpddr_cmds.c')
0 files changed, 0 insertions, 0 deletions