Commit 2df331cf authored by Colin Ian King's avatar Colin Ian King Committed by Jonathan Cameron

iio:adc:at91-sama5d2: make array startup_lookup static to reduce code size

Making the const array startup_lookup static rather having it on the
stack saves 69 bytes. Add in missing int specifier to clean up a
checkpatch warning.

Before:
   text	   data	    bss	    dec	    hex	filename
  10297	   2800	    128	  13225	   33a9	drivers/iio/adc/at91-sama5d2_adc.o

After:
   text	   data	    bss	    dec	    hex	filename
  10140	   2888	    128	  13156	   3364	drivers/iio/adc/at91-sama5d2_adc.o
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
Signed-off-by: default avatarJonathan Cameron <Jonathan.Cameron@huawei.com>
parent 72e36017
...@@ -411,7 +411,7 @@ static int at91_adc_buffer_init(struct iio_dev *indio) ...@@ -411,7 +411,7 @@ static int at91_adc_buffer_init(struct iio_dev *indio)
static unsigned at91_adc_startup_time(unsigned startup_time_min, static unsigned at91_adc_startup_time(unsigned startup_time_min,
unsigned adc_clk_khz) unsigned adc_clk_khz)
{ {
const unsigned startup_lookup[] = { static const unsigned int startup_lookup[] = {
0, 8, 16, 24, 0, 8, 16, 24,
64, 80, 96, 112, 64, 80, 96, 112,
512, 576, 640, 704, 512, 576, 640, 704,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment