diff options
author | David S. Miller <davem@davemloft.net> | 2018-03-23 11:24:57 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2018-03-23 11:31:58 -0400 |
commit | 03fe2debbb2771fb90881e4ce8109b09cf772a5c (patch) | |
tree | fbaf8738296b2e9dcba81c6daef2d515b6c4948c /drivers/gpu/drm/sun4i/sun4i_tcon.c | |
parent | 6686c459e1449a3ee5f3fd313b0a559ace7a700e (diff) | |
parent | f36b7534b83357cf52e747905de6d65b4f7c2512 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Fun set of conflict resolutions here...
For the mac80211 stuff, these were fortunately just parallel
adds. Trivially resolved.
In drivers/net/phy/phy.c we had a bug fix in 'net' that moved the
function phy_disable_interrupts() earlier in the file, whilst in
'net-next' the phy_error() call from this function was removed.
In net/ipv4/xfrm4_policy.c, David Ahern's changes to remove the
'rt_table_id' member of rtable collided with a bug fix in 'net' that
added a new struct member "rt_mtu_locked" which needs to be copied
over here.
The mlxsw driver conflict consisted of net-next separating
the span code and definitions into separate files, whilst
a 'net' bug fix made some changes to that moved code.
The mlx5 infiniband conflict resolution was quite non-trivial,
the RDMA tree's merge commit was used as a guide here, and
here are their notes:
====================
Due to bug fixes found by the syzkaller bot and taken into the for-rc
branch after development for the 4.17 merge window had already started
being taken into the for-next branch, there were fairly non-trivial
merge issues that would need to be resolved between the for-rc branch
and the for-next branch. This merge resolves those conflicts and
provides a unified base upon which ongoing development for 4.17 can
be based.
Conflicts:
drivers/infiniband/hw/mlx5/main.c - Commit 42cea83f9524
(IB/mlx5: Fix cleanup order on unload) added to for-rc and
commit b5ca15ad7e61 (IB/mlx5: Add proper representors support)
add as part of the devel cycle both needed to modify the
init/de-init functions used by mlx5. To support the new
representors, the new functions added by the cleanup patch
needed to be made non-static, and the init/de-init list
added by the representors patch needed to be modified to
match the init/de-init list changes made by the cleanup
patch.
Updates:
drivers/infiniband/hw/mlx5/mlx5_ib.h - Update function
prototypes added by representors patch to reflect new function
names as changed by cleanup patch
drivers/infiniband/hw/mlx5/ib_rep.c - Update init/de-init
stage list to match new order from cleanup patch
====================
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/gpu/drm/sun4i/sun4i_tcon.c')
-rw-r--r-- | drivers/gpu/drm/sun4i/sun4i_tcon.c | 97 |
1 files changed, 52 insertions, 45 deletions
diff --git a/drivers/gpu/drm/sun4i/sun4i_tcon.c b/drivers/gpu/drm/sun4i/sun4i_tcon.c index b3960118deb9..a818ca491605 100644 --- a/drivers/gpu/drm/sun4i/sun4i_tcon.c +++ b/drivers/gpu/drm/sun4i/sun4i_tcon.c | |||
@@ -101,10 +101,13 @@ static void sun4i_tcon_channel_set_status(struct sun4i_tcon *tcon, int channel, | |||
101 | return; | 101 | return; |
102 | } | 102 | } |
103 | 103 | ||
104 | if (enabled) | 104 | if (enabled) { |
105 | clk_prepare_enable(clk); | 105 | clk_prepare_enable(clk); |
106 | else | 106 | clk_rate_exclusive_get(clk); |
107 | } else { | ||
108 | clk_rate_exclusive_put(clk); | ||
107 | clk_disable_unprepare(clk); | 109 | clk_disable_unprepare(clk); |
110 | } | ||
108 | } | 111 | } |
109 | 112 | ||
110 | static void sun4i_tcon_lvds_set_status(struct sun4i_tcon *tcon, | 113 | static void sun4i_tcon_lvds_set_status(struct sun4i_tcon *tcon, |
@@ -260,7 +263,7 @@ static void sun4i_tcon0_mode_set_common(struct sun4i_tcon *tcon, | |||
260 | const struct drm_display_mode *mode) | 263 | const struct drm_display_mode *mode) |
261 | { | 264 | { |
262 | /* Configure the dot clock */ | 265 | /* Configure the dot clock */ |
263 | clk_set_rate_exclusive(tcon->dclk, mode->crtc_clock * 1000); | 266 | clk_set_rate(tcon->dclk, mode->crtc_clock * 1000); |
264 | 267 | ||
265 | /* Set the resolution */ | 268 | /* Set the resolution */ |
266 | regmap_write(tcon->regs, SUN4I_TCON0_BASIC0_REG, | 269 | regmap_write(tcon->regs, SUN4I_TCON0_BASIC0_REG, |
@@ -421,7 +424,7 @@ static void sun4i_tcon1_mode_set(struct sun4i_tcon *tcon, | |||
421 | WARN_ON(!tcon->quirks->has_channel_1); | 424 | WARN_ON(!tcon->quirks->has_channel_1); |
422 | 425 | ||
423 | /* Configure the dot clock */ | 426 | /* Configure the dot clock */ |
424 | clk_set_rate_exclusive(tcon->sclk1, mode->crtc_clock * 1000); | 427 | clk_set_rate(tcon->sclk1, mode->crtc_clock * 1000); |
425 | 428 | ||
426 | /* Adjust clock delay */ | 429 | /* Adjust clock delay */ |
427 | clk_delay = sun4i_tcon_get_clk_delay(mode, 1); | 430 | clk_delay = sun4i_tcon_get_clk_delay(mode, 1); |
@@ -873,52 +876,56 @@ static int sun4i_tcon_bind(struct device *dev, struct device *master, | |||
873 | return ret; | 876 | return ret; |
874 | } | 877 | } |
875 | 878 | ||
876 | /* | 879 | if (tcon->quirks->supports_lvds) { |
877 | * This can only be made optional since we've had DT nodes | 880 | /* |
878 | * without the LVDS reset properties. | 881 | * This can only be made optional since we've had DT |
879 | * | 882 | * nodes without the LVDS reset properties. |
880 | * If the property is missing, just disable LVDS, and print a | 883 | * |
881 | * warning. | 884 | * If the property is missing, just disable LVDS, and |
882 | */ | 885 | * print a warning. |
883 | tcon->lvds_rst = devm_reset_control_get_optional(dev, "lvds"); | 886 | */ |
884 | if (IS_ERR(tcon->lvds_rst)) { | 887 | tcon->lvds_rst = devm_reset_control_get_optional(dev, "lvds"); |
885 | dev_err(dev, "Couldn't get our reset line\n"); | 888 | if (IS_ERR(tcon->lvds_rst)) { |
886 | return PTR_ERR(tcon->lvds_rst); | 889 | dev_err(dev, "Couldn't get our reset line\n"); |
887 | } else if (tcon->lvds_rst) { | 890 | return PTR_ERR(tcon->lvds_rst); |
888 | has_lvds_rst = true; | 891 | } else if (tcon->lvds_rst) { |
889 | reset_control_reset(tcon->lvds_rst); | 892 | has_lvds_rst = true; |
890 | } else { | 893 | reset_control_reset(tcon->lvds_rst); |
891 | has_lvds_rst = false; | 894 | } else { |
892 | } | 895 | has_lvds_rst = false; |
896 | } | ||
893 | 897 | ||
894 | /* | 898 | /* |
895 | * This can only be made optional since we've had DT nodes | 899 | * This can only be made optional since we've had DT |
896 | * without the LVDS reset properties. | 900 | * nodes without the LVDS reset properties. |
897 | * | 901 | * |
898 | * If the property is missing, just disable LVDS, and print a | 902 | * If the property is missing, just disable LVDS, and |
899 | * warning. | 903 | * print a warning. |
900 | */ | 904 | */ |
901 | if (tcon->quirks->has_lvds_alt) { | 905 | if (tcon->quirks->has_lvds_alt) { |
902 | tcon->lvds_pll = devm_clk_get(dev, "lvds-alt"); | 906 | tcon->lvds_pll = devm_clk_get(dev, "lvds-alt"); |
903 | if (IS_ERR(tcon->lvds_pll)) { | 907 | if (IS_ERR(tcon->lvds_pll)) { |
904 | if (PTR_ERR(tcon->lvds_pll) == -ENOENT) { | 908 | if (PTR_ERR(tcon->lvds_pll) == -ENOENT) { |
905 | has_lvds_alt = false; | 909 | has_lvds_alt = false; |
910 | } else { | ||
911 | dev_err(dev, "Couldn't get the LVDS PLL\n"); | ||
912 | return PTR_ERR(tcon->lvds_pll); | ||
913 | } | ||
906 | } else { | 914 | } else { |
907 | dev_err(dev, "Couldn't get the LVDS PLL\n"); | 915 | has_lvds_alt = true; |
908 | return PTR_ERR(tcon->lvds_pll); | ||
909 | } | 916 | } |
910 | } else { | ||
911 | has_lvds_alt = true; | ||
912 | } | 917 | } |
913 | } | ||
914 | 918 | ||
915 | if (!has_lvds_rst || (tcon->quirks->has_lvds_alt && !has_lvds_alt)) { | 919 | if (!has_lvds_rst || |
916 | dev_warn(dev, | 920 | (tcon->quirks->has_lvds_alt && !has_lvds_alt)) { |
917 | "Missing LVDS properties, Please upgrade your DT\n"); | 921 | dev_warn(dev, "Missing LVDS properties, Please upgrade your DT\n"); |
918 | dev_warn(dev, "LVDS output disabled\n"); | 922 | dev_warn(dev, "LVDS output disabled\n"); |
919 | can_lvds = false; | 923 | can_lvds = false; |
924 | } else { | ||
925 | can_lvds = true; | ||
926 | } | ||
920 | } else { | 927 | } else { |
921 | can_lvds = true; | 928 | can_lvds = false; |
922 | } | 929 | } |
923 | 930 | ||
924 | ret = sun4i_tcon_init_clocks(dev, tcon); | 931 | ret = sun4i_tcon_init_clocks(dev, tcon); |
@@ -1137,7 +1144,7 @@ static const struct sun4i_tcon_quirks sun8i_a33_quirks = { | |||
1137 | }; | 1144 | }; |
1138 | 1145 | ||
1139 | static const struct sun4i_tcon_quirks sun8i_a83t_lcd_quirks = { | 1146 | static const struct sun4i_tcon_quirks sun8i_a83t_lcd_quirks = { |
1140 | /* nothing is supported */ | 1147 | .supports_lvds = true, |
1141 | }; | 1148 | }; |
1142 | 1149 | ||
1143 | static const struct sun4i_tcon_quirks sun8i_v3s_quirks = { | 1150 | static const struct sun4i_tcon_quirks sun8i_v3s_quirks = { |