Bartosz Golaszewski 53661f3bc6 gpio: pca953x: code shrink
There are multiple places in the driver code where a
switch (chip->chip_type) is used to determine the proper register
offset.

Unduplicate the code by adding a simple structure holding the possible
offsets that differ between the pca953x and pca957x chip families and
use it to avoid the checks.

Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
2016-09-12 14:45:34 +02:00
..
2016-03-30 10:38:51 +02:00
2016-09-07 16:56:47 +02:00
2016-08-11 10:24:08 +02:00
2016-01-05 11:21:05 +01:00
2016-02-16 00:19:53 +01:00
2016-09-12 14:45:34 +02:00
2016-01-05 15:46:34 +01:00
2016-03-09 22:02:52 +07:00
2016-09-07 16:56:47 +02:00
2016-09-07 16:56:47 +02:00