sunxi: GPIO pin mux hardware-feature-specific function index defines
Each hardware feature exposed through the GPIO pin mux is usually using the same function index (for a given port), so there is no need to define one value per pin: one value per hardware feature per port is sufficient, avoids duplication and makes everything easier to understand. Signed-off-by: Paul Kocialkowski <contact@paulk.fr> Acked-by: Hans de Goede <hdegoede@redhat.com> Signed-off-by: Hans de Goede <hdegoede@redhat.com>
This commit is contained in:
committed by
Hans de Goede
parent
81f11872f3
commit
487b3277d4
@@ -497,7 +497,7 @@ int sunxi_emac_initialize(void)
|
||||
|
||||
/* Configure pin mux settings for MII Ethernet */
|
||||
for (pin = SUNXI_GPA(0); pin <= SUNXI_GPA(17); pin++)
|
||||
sunxi_gpio_set_cfgpin(pin, SUNXI_GPA0_EMAC);
|
||||
sunxi_gpio_set_cfgpin(pin, SUNXI_GPA_EMAC);
|
||||
|
||||
/* Set up clock gating */
|
||||
setbits_le32(&ccm->ahb_gate0, 0x1 << AHB_GATE_OFFSET_EMAC);
|
||||
|
||||
Reference in New Issue
Block a user