diff options
author | Arjan van de Ven <arjan@infradead.org> | 2005-11-29 09:43:42 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2006-01-04 13:51:40 -0800 |
commit | 4c4c9432a6c916729c7296c47fe93b053a73e20c (patch) | |
tree | 7f02f456359259da8bae5e3d32fc4411311ee135 /drivers/usb/input/hid-input.c | |
parent | 9fe6fcd8ccb2c8c661dfd1e07e3122aef31a67d4 (diff) |
[PATCH] USB: mark various usb tables const
patch below marks various USB tables and variables as const so that they
end up in .rodata section and don't cacheline share with things that get
written to. For the non-array variables it also allows gcc to optimize
more.
Signed-off-by: Arjan van de Ven <arjan@infradead.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/usb/input/hid-input.c')
-rw-r--r-- | drivers/usb/input/hid-input.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/usb/input/hid-input.c b/drivers/usb/input/hid-input.c index 1220a5004a5..192a03b2897 100644 --- a/drivers/usb/input/hid-input.c +++ b/drivers/usb/input/hid-input.c @@ -39,7 +39,7 @@ #define unk KEY_UNKNOWN -static unsigned char hid_keyboard[256] = { +static const unsigned char hid_keyboard[256] = { 0, 0, 0, 0, 30, 48, 46, 32, 18, 33, 34, 35, 23, 36, 37, 38, 50, 49, 24, 25, 16, 19, 31, 20, 22, 47, 17, 45, 21, 44, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 28, 1, 14, 15, 57, 12, 13, 26, @@ -58,7 +58,7 @@ static unsigned char hid_keyboard[256] = { 150,158,159,128,136,177,178,176,142,152,173,140,unk,unk,unk,unk }; -static struct { +static const struct { __s32 x; __s32 y; } hid_hat_to_axis[] = {{ 0, 0}, { 0,-1}, { 1,-1}, { 1, 0}, { 1, 1}, { 0, 1}, {-1, 1}, {-1, 0}, {-1,-1}}; |