Lines Matching refs:np

25 static int parse_timing_property(const struct device_node *np, const char *name,  in parse_timing_property()  argument
31 prop = of_find_property(np, name, &length); in parse_timing_property()
33 pr_err("%pOF: could not find property %s\n", np, name); in parse_timing_property()
39 ret = of_property_read_u32(np, name, &result->typ); in parse_timing_property()
43 ret = of_property_read_u32_array(np, name, &result->min, cells); in parse_timing_property()
45 pr_err("%pOF: illegal timing specification in %s\n", np, name); in parse_timing_property()
57 static int of_parse_display_timing(const struct device_node *np, in of_parse_display_timing() argument
65 ret |= parse_timing_property(np, "hback-porch", &dt->hback_porch); in of_parse_display_timing()
66 ret |= parse_timing_property(np, "hfront-porch", &dt->hfront_porch); in of_parse_display_timing()
67 ret |= parse_timing_property(np, "hactive", &dt->hactive); in of_parse_display_timing()
68 ret |= parse_timing_property(np, "hsync-len", &dt->hsync_len); in of_parse_display_timing()
69 ret |= parse_timing_property(np, "vback-porch", &dt->vback_porch); in of_parse_display_timing()
70 ret |= parse_timing_property(np, "vfront-porch", &dt->vfront_porch); in of_parse_display_timing()
71 ret |= parse_timing_property(np, "vactive", &dt->vactive); in of_parse_display_timing()
72 ret |= parse_timing_property(np, "vsync-len", &dt->vsync_len); in of_parse_display_timing()
73 ret |= parse_timing_property(np, "clock-frequency", &dt->pixelclock); in of_parse_display_timing()
76 if (!of_property_read_u32(np, "vsync-active", &val)) in of_parse_display_timing()
79 if (!of_property_read_u32(np, "hsync-active", &val)) in of_parse_display_timing()
82 if (!of_property_read_u32(np, "de-active", &val)) in of_parse_display_timing()
85 if (!of_property_read_u32(np, "pixelclk-active", &val)) in of_parse_display_timing()
89 if (!of_property_read_u32(np, "syncclk-active", &val)) in of_parse_display_timing()
98 if (of_property_read_bool(np, "interlaced")) in of_parse_display_timing()
100 if (of_property_read_bool(np, "doublescan")) in of_parse_display_timing()
102 if (of_property_read_bool(np, "doubleclk")) in of_parse_display_timing()
106 pr_err("%pOF: error reading timing properties\n", np); in of_parse_display_timing()
119 int of_get_display_timing(const struct device_node *np, const char *name, in of_get_display_timing() argument
125 if (!np) in of_get_display_timing()
128 timing_np = of_get_child_by_name(np, name); in of_get_display_timing()
144 struct display_timings *of_get_display_timings(const struct device_node *np) in of_get_display_timings() argument
151 if (!np) in of_get_display_timings()
154 timings_np = of_get_child_by_name(np, "display-timings"); in of_get_display_timings()
156 pr_err("%pOF: could not find display-timings node\n", np); in of_get_display_timings()
162 pr_err("%pOF: could not allocate struct disp'\n", np); in of_get_display_timings()
172 pr_err("%pOF: no timing specifications given\n", np); in of_get_display_timings()
176 pr_debug("%pOF: using %pOFn as default timing\n", np, entry); in of_get_display_timings()
183 pr_err("%pOF: no timings specified\n", np); in of_get_display_timings()
191 pr_err("%pOF: could not allocate timings array\n", np); in of_get_display_timings()
205 np); in of_get_display_timings()
216 np, disp->num_timings + 1); in of_get_display_timings()
235 np, disp->num_timings, in of_get_display_timings()