MLK-14548: video: fb: hdmi: Allow Sil902 init regardless of fb registration time
authorCristina Ciocan <cristina-mihaela.ciocan@nxp.com>
Thu, 20 Apr 2017 10:48:50 +0000 (13:48 +0300)
committerNitin Garg <nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:22:02 +0000 (15:22 -0500)
commiteb388d6f56c75737c0a3854e3073eaccd0389726
tree30efd4333f70b1f9dbc2e91e9f4a412df4cc4235
parente59404aa4f92ab0eb4ab3aa52dd6ae9fb66cf024
MLK-14548: video: fb: hdmi: Allow Sil902 init regardless of fb registration time

When a new fb is registered, a FB_EVENT_FB_REGISTERED event is sent to
any registered fb client. Upon event receipt, the Sil902 HDMI transmitter
saves the fb info structure address for future use and schedules a cable
state check in order to setup and power up/down the device.

The current Sil902 driver registers as fb client at the end of the probe
function, thus events from fb core will only be received after the probe()
call. If a framebuffer is registered before Sil902's probe() is called,
the HDMI transmitter will not have knowledge of the framebuffer.

This patch moves the Sil902 fb client registration step into an __init
function and saves the fb info in case any registration event is received
prior to the probe() call. When the probe() is called, check for any
registration event and act accordingly.

Sil902's init function class is called after the frame buffer core's init
function class.

Signed-off-by: Cristina Ciocan <cristina-mihaela.ciocan@nxp.com>
drivers/video/fbdev/mxc/mxsfb_sii902x.c