static void otm8009a_dcs_write_buf(struct udevice *dev, const void *data,
size_t len)
{
- struct mipi_dsi_panel_plat *plat = dev_get_platdata(dev);
+ struct mipi_dsi_panel_plat *plat = dev_get_plat(dev);
struct mipi_dsi_device *device = plat->device;
if (mipi_dsi_dcs_write_buffer(device, data, len) < 0)
static void otm8009a_dcs_write_buf_hs(struct udevice *dev, const void *data,
size_t len)
{
- struct mipi_dsi_panel_plat *plat = dev_get_platdata(dev);
+ struct mipi_dsi_panel_plat *plat = dev_get_plat(dev);
struct mipi_dsi_device *device = plat->device;
/* data will be sent in dsi hs mode (ie. no lpm) */
static int otm8009a_init_sequence(struct udevice *dev)
{
- struct mipi_dsi_panel_plat *plat = dev_get_platdata(dev);
+ struct mipi_dsi_panel_plat *plat = dev_get_plat(dev);
struct mipi_dsi_device *device = plat->device;
int ret;
static int otm8009a_panel_enable_backlight(struct udevice *dev)
{
- struct mipi_dsi_panel_plat *plat = dev_get_platdata(dev);
+ struct mipi_dsi_panel_plat *plat = dev_get_plat(dev);
struct mipi_dsi_device *device = plat->device;
int ret;
return 0;
}
-static int otm8009a_panel_ofdata_to_platdata(struct udevice *dev)
+static int otm8009a_panel_of_to_plat(struct udevice *dev)
{
struct otm8009a_panel_priv *priv = dev_get_priv(dev);
int ret;
static int otm8009a_panel_probe(struct udevice *dev)
{
struct otm8009a_panel_priv *priv = dev_get_priv(dev);
- struct mipi_dsi_panel_plat *plat = dev_get_platdata(dev);
+ struct mipi_dsi_panel_plat *plat = dev_get_plat(dev);
int ret;
if (IS_ENABLED(CONFIG_DM_REGULATOR) && priv->reg) {
.id = UCLASS_PANEL,
.of_match = otm8009a_panel_ids,
.ops = &otm8009a_panel_ops,
- .ofdata_to_platdata = otm8009a_panel_ofdata_to_platdata,
+ .of_to_plat = otm8009a_panel_of_to_plat,
.probe = otm8009a_panel_probe,
- .platdata_auto = sizeof(struct mipi_dsi_panel_plat),
+ .plat_auto = sizeof(struct mipi_dsi_panel_plat),
.priv_auto = sizeof(struct otm8009a_panel_priv),
};