[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20220817195500.d6roam5gyghburjs@notapiano>
Date: Wed, 17 Aug 2022 15:55:00 -0400
From: Nícolas F. R. A. Prado
<nfraprado@...labora.com>
To: Hui Liu <hui.liu@...iatek.com>
Cc: linus.walleij@...aro.org, robh+dt@...nel.org,
krzysztof.kozlowski+dt@...aro.org, matthias.bgg@...il.com,
Project_Global_Chrome_Upstream_Group@...iatek.com,
jianguo.zhang@...iatek.com, zhiyong.tao@...iatek.com,
sean.wang@...iatek.com, linux-gpio@...r.kernel.org,
devicetree@...r.kernel.org, linux-arm-kernel@...ts.infradead.org,
linux-mediatek@...ts.infradead.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH v5 2/2] pinctrl: mediatek: add mt8188 driver
Hi Hui,
On Mon, Aug 01, 2022 at 05:52:15PM +0800, Hui Liu wrote:
> From: "Hui.Liu" <hui.liu@...iatek.com>
>
> Add pinctrl driver support for MediaTek SoC mt8188.
>
> Signed-off-by: Hui.Liu <hui.liu@...iatek.com>
> ---
[..]
> --- /dev/null
> +++ b/drivers/pinctrl/mediatek/pinctrl-mt8188.c
[..]
> +static const struct mtk_pin_field_calc mt8188_pin_mode_range[] = {
> + PIN_FIELD(0, 177, 0x0300, 0x10, 0, 4),
> +};
Missing blank line after declaration.
> +static const struct mtk_pin_field_calc mt8188_pin_dir_range[] = {
> + PIN_FIELD(0, 177, 0x0000, 0x10, 0, 1),
> +};
Ditto.
> +static const struct mtk_pin_field_calc mt8188_pin_di_range[] = {
> + PIN_FIELD(0, 177, 0x0200, 0x10, 0, 1),
> +};
Ditto.
> +static const struct mtk_pin_field_calc mt8188_pin_do_range[] = {
> + PIN_FIELD(0, 177, 0x0100, 0x10, 0, 1),
> +};
Ditto.
> +static const struct mtk_pin_field_calc mt8188_pin_smt_range[] = {
[..]
> +static const struct mtk_pin_reg_calc mt8188_reg_cals[PINCTRL_PIN_REG_MAX] = {
> + [PINCTRL_PIN_REG_MODE] = MTK_RANGE(mt8188_pin_mode_range),
> + [PINCTRL_PIN_REG_DIR] = MTK_RANGE(mt8188_pin_dir_range),
> + [PINCTRL_PIN_REG_DI] = MTK_RANGE(mt8188_pin_di_range),
> + [PINCTRL_PIN_REG_DO] = MTK_RANGE(mt8188_pin_do_range),
> + [PINCTRL_PIN_REG_SMT] = MTK_RANGE(mt8188_pin_smt_range),
> + [PINCTRL_PIN_REG_IES] = MTK_RANGE(mt8188_pin_ies_range),
> + [PINCTRL_PIN_REG_TDSEL] = MTK_RANGE(mt8188_pin_tdsel_range),
> + [PINCTRL_PIN_REG_RDSEL] = MTK_RANGE(mt8188_pin_rdsel_range),
> + [PINCTRL_PIN_REG_PUPD] = MTK_RANGE(mt8188_pin_pupd_range),
> + [PINCTRL_PIN_REG_R0] = MTK_RANGE(mt8188_pin_r0_range),
> + [PINCTRL_PIN_REG_R1] = MTK_RANGE(mt8188_pin_r1_range),
> + [PINCTRL_PIN_REG_PU] = MTK_RANGE(mt8188_pin_pu_range),
> + [PINCTRL_PIN_REG_PD] = MTK_RANGE(mt8188_pin_pd_range),
> + [PINCTRL_PIN_REG_DRV] = MTK_RANGE(mt8188_pin_drv_range),
> + [PINCTRL_PIN_REG_DRV_ADV] = MTK_RANGE(mt8188_pin_drv_adv_range),
> + [PINCTRL_PIN_REG_RSEL] = MTK_RANGE(mt8188_pin_rsel_range),
Please use just space around the = instead of tabs. Like is done on mt8183,
mt8186, mt8192 and mt8195.
> +};
[..]
> +static const struct mtk_pin_soc mt8188_data = {
> + .reg_cal = mt8188_reg_cals,
> + .pins = mtk_pins_mt8188,
> + .npins = ARRAY_SIZE(mtk_pins_mt8188),
> + .ngrps = ARRAY_SIZE(mtk_pins_mt8188),
> + .eint_hw = &mt8188_eint_hw,
> + .nfuncs = 8,
> + .gpio_m = 0,
> + .base_names = mt8188_pinctrl_register_base_name,
> + .nbase_names = ARRAY_SIZE(mt8188_pinctrl_register_base_name),
> + .bias_set_combo = mtk_pinconf_bias_set_combo,
> + .pull_type = mt8188_pull_type,
> + .pin_rsel = mt8188_pin_rsel_val_range,
> + .npin_rsel = ARRAY_SIZE(mt8188_pin_rsel_val_range),
> + .bias_get_combo = mtk_pinconf_bias_get_combo,
Keep this one together with bias_set_combo.
> + .drive_set = mtk_pinconf_drive_set_rev1,
> + .drive_get = mtk_pinconf_drive_get_rev1,
> + .adv_drive_set = mtk_pinconf_adv_drive_set_raw,
> + .adv_drive_get = mtk_pinconf_adv_drive_get_raw,
And also use spaces instead of tabs for all entries here.
With those changes,
Reviewed-by: Nícolas F. R. A. Prado <nfraprado@...labora.com>
Thanks,
Nícolas
Powered by blists - more mailing lists