On Fri, Sep 22, 2017 at 04:42:24AM +0000, Vasily Khoruzhick wrote:
> >> >>> +     lcdc_init(lcdc);
> >> >>> +     sunxi_lcdc_config_pinmux();
> >> >>
> >> >> This is already handled in sunxi_lcdc_tcon0_mode_set, why duplicate
> >> >> it?
> >> >
> >> > Because the one that sunxi_lcdc_tcon0_mode_set() calls is
> >> > DE1-specific. I don't want to split out that code that won't be used
> >> > by DE2 driver.
> >
> > Then move out the common code. It's kind of weird though, since the
> > DE1 vs DE2 stuff is basically only for the layers part. The TCON is
> > always there, and is mostly the same. So you should be able to re-use
> > that with minor modifications.
> 
> I'm not sure what common code you're talking about. I've already moved
> out lcdc_pll_set(). Moving pinmux
> configuration out into common code doesn't look reasonable. It's
> different for A64 -- for A64 it configures
> GPD(0)-GPD(21) as function, while for other SoCs it's GPD(18)-GPD(27)
> or GPD(0)-GPD(27) depending
> on SoC model. Anyway, pinmux configuration code for DE1 contains a
> number of ifdef-s that are not necessary
> for DE2 -- these SoCs don't have DE2 and thus won't be supported.

Again, DE1 vs DE2 has nothing to do in the discussion

DE1 devices will look like this:
DE1 -> TCON -> HDMI / LCD / whatever -> pins

DE2 will be:
DE2 -> TCON -> HDMI / LCD / whatever -> pins

The only thing not in common between these two cases is the display
engine used. Everything else should be common (except for special
cases, like the HDMI controller itself that changed as well).

Maxime

-- 
Maxime Ripard, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com

Attachment: signature.asc
Description: PGP signature

_______________________________________________
U-Boot mailing list
U-Boot@lists.denx.de
https://lists.denx.de/listinfo/u-boot

Reply via email to