[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>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
9fe6fcd8cc
commit
4c4c9432a6
@@ -146,7 +146,7 @@ static char init1[] = { 0x01, 0x00, 0x20, 0x14 };
|
||||
static char init2[] = { 0x01, 0x00, 0x20, 0x14, 0x20, 0x20, 0x20 };
|
||||
|
||||
/* Acceleration curve for directional control pad */
|
||||
static char accel[] = { 1, 2, 4, 6, 9, 13, 20 };
|
||||
static const char accel[] = { 1, 2, 4, 6, 9, 13, 20 };
|
||||
|
||||
/* Duplicate event filtering time.
|
||||
* Sequential, identical KIND_FILTERED inputs with less than
|
||||
@@ -197,7 +197,7 @@ struct ati_remote {
|
||||
#define KIND_ACCEL 7 /* Directional keypad - left, right, up, down.*/
|
||||
|
||||
/* Translation table from hardware messages to input events. */
|
||||
static struct {
|
||||
static const struct {
|
||||
short kind;
|
||||
unsigned char data1, data2;
|
||||
int type;
|
||||
|
Reference in New Issue
Block a user