summaryrefslogtreecommitdiff
path: root/drivers/nfc/s3fwrn5
diff options
context:
space:
mode:
authorColin Ian King <colin.king@canonical.com>2017-09-19 17:25:15 +0300
committerSamuel Ortiz <sameo@linux.intel.com>2017-11-06 03:05:06 +0300
commit5057f6647b3286eee2d9a7eff7f3c072ea7573d9 (patch)
treefa2f806a3d57477774551ee9729ed66e309143ad /drivers/nfc/s3fwrn5
parenta122ffd0911d563f4b5e95120259ec5d2e8e3c4f (diff)
downloadlinux-5057f6647b3286eee2d9a7eff7f3c072ea7573d9.tar.xz
nfc: s3fwrn5: make array match static const
Don't populate the read-only array match on the stack, instead make it static const. Makes the object code smaller by over 310 bytes: Before: text data bss dec hex filename 8304 1084 128 9516 252c drivers/nfc/s3fwrn5/firmware.o After: text data bss dec hex filename 7894 1180 128 9202 23f2 drivers/nfc/s3fwrn5/firmware.o Signed-off-by: Colin Ian King <colin.king@canonical.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'drivers/nfc/s3fwrn5')
-rw-r--r--drivers/nfc/s3fwrn5/firmware.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nfc/s3fwrn5/firmware.c b/drivers/nfc/s3fwrn5/firmware.c
index 38548bd970cd..b7828fb252f2 100644
--- a/drivers/nfc/s3fwrn5/firmware.c
+++ b/drivers/nfc/s3fwrn5/firmware.c
@@ -336,7 +336,7 @@ static int s3fwrn5_fw_get_base_addr(
struct s3fwrn5_fw_cmd_get_bootinfo_rsp *bootinfo, u32 *base_addr)
{
int i;
- struct {
+ static const struct {
u8 version[4];
u32 base_addr;
} match[] = {