Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

phy: exynos5: Remove duplicated defines of PHY register defines

Phy drivers access PMU region through regmap provided by exynos-pmu
driver. However there is no need to duplicate defines for PMU
registers. Instead just use whatever is defined in exynos-regs-pmu.h.

This reduces number of defines.

Suggested-by: Marek Szyprowski <m.szyprowski@samsung.com>
Signed-off-by: Krzysztof Kozlowski <krzk@kernel.org>
Acked-by: Lee Jones <lee.jones@linaro.org>
Reviewed-by: Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>

authored by

Krzysztof Kozlowski and committed by
Kishon Vijay Abraham I
424c9841 5812f010

+10 -27
+1
drivers/phy/phy-exynos-dp-video.c
··· 20 20 #include <linux/phy/phy.h> 21 21 #include <linux/platform_device.h> 22 22 #include <linux/regmap.h> 23 + #include <linux/soc/samsung/exynos-regs-pmu.h> 23 24 24 25 struct exynos_dp_video_phy_drvdata { 25 26 u32 phy_ctrl_offset;
+1
drivers/phy/phy-exynos5-usbdrd.c
··· 25 25 #include <linux/mfd/syscon/exynos5-pmu.h> 26 26 #include <linux/regmap.h> 27 27 #include <linux/regulator/consumer.h> 28 + #include <linux/soc/samsung/exynos-regs-pmu.h> 28 29 29 30 /* Exynos USB PHY registers */ 30 31 #define EXYNOS5_FSEL_9MHZ6 0x0
-27
include/linux/mfd/syscon/exynos5-pmu.h
··· 12 12 #ifndef _LINUX_MFD_SYSCON_PMU_EXYNOS5_H_ 13 13 #define _LINUX_MFD_SYSCON_PMU_EXYNOS5_H_ 14 14 15 - /* Exynos5 PMU register definitions */ 16 - #define EXYNOS5_HDMI_PHY_CONTROL (0x700) 17 - #define EXYNOS5_USBDRD_PHY_CONTROL (0x704) 18 - 19 - /* Exynos5250 specific register definitions */ 20 - #define EXYNOS5_USBHOST_PHY_CONTROL (0x708) 21 - #define EXYNOS5_EFNAND_PHY_CONTROL (0x70c) 22 - #define EXYNOS5_MIPI_PHY0_CONTROL (0x710) 23 - #define EXYNOS5_MIPI_PHY1_CONTROL (0x714) 24 - #define EXYNOS5_ADC_PHY_CONTROL (0x718) 25 - #define EXYNOS5_MTCADC_PHY_CONTROL (0x71c) 26 - #define EXYNOS5_DPTX_PHY_CONTROL (0x720) 27 - #define EXYNOS5_SATA_PHY_CONTROL (0x724) 28 - 29 - /* Exynos5420 specific register definitions */ 30 - #define EXYNOS5420_USBDRD1_PHY_CONTROL (0x708) 31 - #define EXYNOS5420_USBHOST_PHY_CONTROL (0x70c) 32 - #define EXYNOS5420_MIPI_PHY0_CONTROL (0x714) 33 - #define EXYNOS5420_MIPI_PHY1_CONTROL (0x718) 34 - #define EXYNOS5420_MIPI_PHY2_CONTROL (0x71c) 35 - #define EXYNOS5420_ADC_PHY_CONTROL (0x720) 36 - #define EXYNOS5420_MTCADC_PHY_CONTROL (0x724) 37 - #define EXYNOS5420_DPTX_PHY_CONTROL (0x728) 38 - 39 - /* Exynos5433 specific register definitions */ 40 - #define EXYNOS5433_USBHOST30_PHY_CONTROL (0x728) 41 - 42 15 #define EXYNOS5_PHY_ENABLE BIT(0) 43 16 #define EXYNOS5_MIPI_PHY_S_RESETN BIT(1) 44 17 #define EXYNOS5_MIPI_PHY_M_RESETN BIT(2)
+8
include/linux/soc/samsung/exynos-regs-pmu.h
··· 349 349 350 350 #define EXYNOS5_AUTO_WDTRESET_DISABLE 0x0408 351 351 #define EXYNOS5_MASK_WDTRESET_REQUEST 0x040C 352 + #define EXYNOS5_USBDRD_PHY_CONTROL 0x0704 353 + #define EXYNOS5_DPTX_PHY_CONTROL 0x0720 352 354 353 355 #define EXYNOS5_USE_RETENTION BIT(4) 354 356 #define EXYNOS5_SYS_WDTRESET (1 << 20) ··· 504 502 #define EXYNOS5420_KFC_CORE_RESET(_nr) \ 505 503 ((EXYNOS5420_KFC_CORE_RESET0 | EXYNOS5420_KFC_ETM_RESET0) << (_nr)) 506 504 505 + #define EXYNOS5420_USBDRD1_PHY_CONTROL 0x0708 506 + #define EXYNOS5420_MIPI_PHY0_CONTROL 0x0714 507 + #define EXYNOS5420_MIPI_PHY1_CONTROL 0x0718 508 + #define EXYNOS5420_MIPI_PHY2_CONTROL 0x071C 509 + #define EXYNOS5420_DPTX_PHY_CONTROL 0x0728 507 510 #define EXYNOS5420_ARM_CORE2_SYS_PWR_REG 0x1020 508 511 #define EXYNOS5420_DIS_IRQ_ARM_CORE2_LOCAL_SYS_PWR_REG 0x1024 509 512 #define EXYNOS5420_DIS_IRQ_ARM_CORE2_CENTRAL_SYS_PWR_REG 0x1028 ··· 646 639 | EXYNOS5420_KFC_USE_STANDBY_WFI3) 647 640 648 641 /* For EXYNOS5433 */ 642 + #define EXYNOS5433_USBHOST30_PHY_CONTROL (0x0728) 649 643 #define EXYNOS5433_PAD_RETENTION_AUD_OPTION (0x3028) 650 644 #define EXYNOS5433_PAD_RETENTION_MMC2_OPTION (0x30C8) 651 645 #define EXYNOS5433_PAD_RETENTION_TOP_OPTION (0x3108)