pinctrl-meson8b.c (70e5ecb1b994f2704c234cb12366d45474b98f32) pinctrl-meson8b.c (277d14eb815fdfb95a72ea126bc09f75a2bd58fd)
1/*
2 * Pin controller and GPIO driver for Amlogic Meson8b.
3 *
4 * Copyright (C) 2015 Endless Mobile, Inc.
5 * Author: Carlo Caione <carlo@endlessm.com>
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License

--- 890 unchanged lines hidden (view full) ---

899 BANK("DIF", DIF_0_P, DIF_4_N, -1, -1, 5, 8, 5, 8, 12, 12, 13, 12, 14, 12),
900};
901
902static struct meson_bank meson8b_aobus_banks[] = {
903 /* name first lastc irq pullen pull dir out in */
904 BANK("AO", GPIOAO_0, GPIO_TEST_N, 0, 13, 0, 0, 0, 16, 0, 0, 0, 16, 1, 0),
905};
906
1/*
2 * Pin controller and GPIO driver for Amlogic Meson8b.
3 *
4 * Copyright (C) 2015 Endless Mobile, Inc.
5 * Author: Carlo Caione <carlo@endlessm.com>
6 *
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License

--- 890 unchanged lines hidden (view full) ---

899 BANK("DIF", DIF_0_P, DIF_4_N, -1, -1, 5, 8, 5, 8, 12, 12, 13, 12, 14, 12),
900};
901
902static struct meson_bank meson8b_aobus_banks[] = {
903 /* name first lastc irq pullen pull dir out in */
904 BANK("AO", GPIOAO_0, GPIO_TEST_N, 0, 13, 0, 0, 0, 16, 0, 0, 0, 16, 1, 0),
905};
906
907struct meson_pinctrl_data meson8b_cbus_pinctrl_data = {
907static struct meson_pinctrl_data meson8b_cbus_pinctrl_data = {
908 .name = "cbus-banks",
909 .pins = meson8b_cbus_pins,
910 .groups = meson8b_cbus_groups,
911 .funcs = meson8b_cbus_functions,
912 .banks = meson8b_cbus_banks,
913 .num_pins = ARRAY_SIZE(meson8b_cbus_pins),
914 .num_groups = ARRAY_SIZE(meson8b_cbus_groups),
915 .num_funcs = ARRAY_SIZE(meson8b_cbus_functions),
916 .num_banks = ARRAY_SIZE(meson8b_cbus_banks),
917};
918
908 .name = "cbus-banks",
909 .pins = meson8b_cbus_pins,
910 .groups = meson8b_cbus_groups,
911 .funcs = meson8b_cbus_functions,
912 .banks = meson8b_cbus_banks,
913 .num_pins = ARRAY_SIZE(meson8b_cbus_pins),
914 .num_groups = ARRAY_SIZE(meson8b_cbus_groups),
915 .num_funcs = ARRAY_SIZE(meson8b_cbus_functions),
916 .num_banks = ARRAY_SIZE(meson8b_cbus_banks),
917};
918
919struct meson_pinctrl_data meson8b_aobus_pinctrl_data = {
919static struct meson_pinctrl_data meson8b_aobus_pinctrl_data = {
920 .name = "aobus-banks",
921 .pins = meson8b_aobus_pins,
922 .groups = meson8b_aobus_groups,
923 .funcs = meson8b_aobus_functions,
924 .banks = meson8b_aobus_banks,
925 .num_pins = ARRAY_SIZE(meson8b_aobus_pins),
926 .num_groups = ARRAY_SIZE(meson8b_aobus_groups),
927 .num_funcs = ARRAY_SIZE(meson8b_aobus_functions),
928 .num_banks = ARRAY_SIZE(meson8b_aobus_banks),
929};
920 .name = "aobus-banks",
921 .pins = meson8b_aobus_pins,
922 .groups = meson8b_aobus_groups,
923 .funcs = meson8b_aobus_functions,
924 .banks = meson8b_aobus_banks,
925 .num_pins = ARRAY_SIZE(meson8b_aobus_pins),
926 .num_groups = ARRAY_SIZE(meson8b_aobus_groups),
927 .num_funcs = ARRAY_SIZE(meson8b_aobus_functions),
928 .num_banks = ARRAY_SIZE(meson8b_aobus_banks),
929};
930
931static const struct of_device_id meson8b_pinctrl_dt_match[] = {
932 {
933 .compatible = "amlogic,meson8b-cbus-pinctrl",
934 .data = &meson8b_cbus_pinctrl_data,
935 },
936 {
937 .compatible = "amlogic,meson8b-aobus-pinctrl",
938 .data = &meson8b_aobus_pinctrl_data,
939 },
940 { },
941};
942
943static struct platform_driver meson8b_pinctrl_driver = {
944 .probe = meson_pinctrl_probe,
945 .driver = {
946 .name = "meson8b-pinctrl",
947 .of_match_table = meson8b_pinctrl_dt_match,
948 },
949};
950builtin_platform_driver(meson8b_pinctrl_driver);