From: xcq Date: Fri, 16 Jun 2017 09:52:19 +0000 (+0800) Subject: camera: rockchip: camsys driver v0.0x22.1 X-Git-Tag: release-20171130_firefly~4^2~394 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=f920ebcc80a844e8815e9cb5d313ededa47e8cf9;p=firefly-linux-kernel-4.4.55.git camera: rockchip: camsys driver v0.0x22.1 gpio0_D is unavailable on rk3288 with current pinctrl driver. Change-Id: I7d38ebd3b00ac0df31861406f758bdd9e57f9903 Signed-off-by: xcq --- diff --git a/drivers/media/video/rk_camsys/camsys_gpio.h b/drivers/media/video/rk_camsys/camsys_gpio.h old mode 100755 new mode 100644 index 88602af39e99..7c188b24c2b2 --- a/drivers/media/video/rk_camsys/camsys_gpio.h +++ b/drivers/media/video/rk_camsys/camsys_gpio.h @@ -6,6 +6,7 @@ #define NUM_GROUP (32) #define GPIO_BANKS (9) #endif +extern unsigned int CHIP_TYPE; static inline unsigned int camsys_gpio_group_pin(unsigned char *io_name) { @@ -79,6 +80,9 @@ static inline unsigned int camsys_gpio_get(unsigned char *io_name) else gpio += group * NUM_GROUP + group_pin; } + /* gpio0_D is unavailable on rk3288. */ + if (!strstr(io_name, "PIN0") && 3288 == CHIP_TYPE) + gpio -= 8; } #endif return gpio; diff --git a/drivers/media/video/rk_camsys/camsys_internal.h b/drivers/media/video/rk_camsys/camsys_internal.h index 43f6c8d9f20e..62a47882bc56 100644 --- a/drivers/media/video/rk_camsys/camsys_internal.h +++ b/drivers/media/video/rk_camsys/camsys_internal.h @@ -166,8 +166,10 @@ 1) add reference count for marvin. *v0.0x22.0: 1) delete node in irqpool list when thread disconnect. +*v0.0x22.1: + 1) gpio0_D is unavailable on rk3288 with current pinctrl driver. */ -#define CAMSYS_DRIVER_VERSION KERNEL_VERSION(0, 0x22, 0) +#define CAMSYS_DRIVER_VERSION KERNEL_VERSION(0, 0x22, 1) #define CAMSYS_PLATFORM_DRV_NAME "RockChip-CamSys" #define CAMSYS_PLATFORM_MARVIN_NAME "Platform_MarvinDev"