VENC type (composite/svideo) doesn't have to be fixed by board wiring,
it is possible to provide both connectors, which is what pandora does.
Having to recompile the kernel for users who have TV connector types
that's don't match default board setting is very inconvenient, especially
for users of a consumer device, so add support for switching VENC type
at runtime over a new sysfs file venc_type.
Signed-off-by: Grazvydas Ignotas <redacted>
---
Documentation/arm/OMAP/DSS | 1 +
drivers/video/omap2/dss/venc.c | 55 +++++++++++++++++++++++++++++++++++++++-
2 files changed, 55 insertions(+), 1 deletions(-)
@@ -156,6 +156,7 @@ timings Display timings (pixclock,xres/hfp/hbp/hsw,yres/vfp/vbp/vsw) "pal" and "ntsc" panel_name tear_elim Tearing elimination 0=off, 1=on+venc_type Output type (video encoder only): "composite" or "svideo" There are also some debugfs files at <debugfs>/omapdss/ which show information about clocks and registers.
From: Tomi Valkeinen <hidden> Date: 2012-04-20 08:38:57
On Thu, 2012-03-29 at 02:45 +0300, Grazvydas Ignotas wrote:
VENC type (composite/svideo) doesn't have to be fixed by board wiring,
it is possible to provide both connectors, which is what pandora does.
Having to recompile the kernel for users who have TV connector types
that's don't match default board setting is very inconvenient, especially
You don't have to recompile the kernel, you could just set the venc type
in the board file depending on a boot parameter.
for users of a consumer device, so add support for switching VENC type
at runtime over a new sysfs file venc_type.
I really dislike adding new custom sysfs entries for omapdss, and I'd
like to avoid them if at all possible. Do you need to change the venc
type during runtime, or is it enough that it can be set during boot?
Tomi
On Fri, Apr 20, 2012 at 11:38 AM, Tomi Valkeinen [off-list ref] wrote:
On Thu, 2012-03-29 at 02:45 +0300, Grazvydas Ignotas wrote:
quoted
VENC type (composite/svideo) doesn't have to be fixed by board wiring,
it is possible to provide both connectors, which is what pandora does.
Having to recompile the kernel for users who have TV connector types
that's don't match default board setting is very inconvenient, especially
You don't have to recompile the kernel, you could just set the venc type
in the board file depending on a boot parameter.
quoted
for users of a consumer device, so add support for switching VENC type
at runtime over a new sysfs file venc_type.
I really dislike adding new custom sysfs entries for omapdss, and I'd
like to avoid them if at all possible.
Well some panels already have custom attributes, and venc could be
considered as special panel type, so if it's allowed for panels, why
not allow it for venc?
Do you need to change the venc
type during runtime, or is it enough that it can be set during boot?
We need this on runtime, otherwise it causes several issues:
- reboot is required to change the setting, although there is no
technical reason to really require it. This punishes users who want to
try both settings or have both TV types (with a portable device this
may sometimes happen).
- having to provide a way for users to change this in kernel boot
arguments. Note that many pandora users don't know how to handle boot
scripts, so a bootloader menu of some sort would be needed or ability
to edit u-boot environment from Linux, both of which would be
needlessly complicated solutions.
--
Gražvydas
From: Tomi Valkeinen <hidden> Date: 2012-04-20 11:34:59
On Fri, 2012-04-20 at 13:49 +0300, Grazvydas Ignotas wrote:
On Fri, Apr 20, 2012 at 11:38 AM, Tomi Valkeinen [off-list ref] wrote:
quoted
On Thu, 2012-03-29 at 02:45 +0300, Grazvydas Ignotas wrote:
quoted
VENC type (composite/svideo) doesn't have to be fixed by board wiring,
it is possible to provide both connectors, which is what pandora does.
Having to recompile the kernel for users who have TV connector types
that's don't match default board setting is very inconvenient, especially
You don't have to recompile the kernel, you could just set the venc type
in the board file depending on a boot parameter.
quoted
for users of a consumer device, so add support for switching VENC type
at runtime over a new sysfs file venc_type.
I really dislike adding new custom sysfs entries for omapdss, and I'd
like to avoid them if at all possible.
Well some panels already have custom attributes, and venc could be
considered as special panel type, so if it's allowed for panels, why
not allow it for venc?
It's not really about "allowing". It's just that each new sysfs file is
a new non-standard custom API to userspace which we need to support
until the end of time. Adding new sysfs files carelessly will cause a
nightmare for me in the future, so by default I'm against new sysfs
files =).
quoted
Do you need to change the venc
type during runtime, or is it enough that it can be set during boot?
We need this on runtime, otherwise it causes several issues:
- reboot is required to change the setting, although there is no
technical reason to really require it. This punishes users who want to
try both settings or have both TV types (with a portable device this
may sometimes happen).
- having to provide a way for users to change this in kernel boot
arguments. Note that many pandora users don't know how to handle boot
scripts, so a bootloader menu of some sort would be needed or ability
to edit u-boot environment from Linux, both of which would be
needlessly complicated solutions.
Ok. Sounds like we need to have dynamic configuration. I'll review the
patch.
Tomi
From: Tomi Valkeinen <hidden> Date: 2012-04-23 12:23:22
On Thu, 2012-03-29 at 02:45 +0300, Grazvydas Ignotas wrote:
quoted hunk
VENC type (composite/svideo) doesn't have to be fixed by board wiring,
it is possible to provide both connectors, which is what pandora does.
Having to recompile the kernel for users who have TV connector types
that's don't match default board setting is very inconvenient, especially
for users of a consumer device, so add support for switching VENC type
at runtime over a new sysfs file venc_type.
Signed-off-by: Grazvydas Ignotas <redacted>
---
Documentation/arm/OMAP/DSS | 1 +
drivers/video/omap2/dss/venc.c | 55 +++++++++++++++++++++++++++++++++++++++-
2 files changed, 55 insertions(+), 1 deletions(-)
@@ -156,6 +156,7 @@ timings Display timings (pixclock,xres/hfp/hbp/hsw,yres/vfp/vbp/vsw) "pal" and "ntsc" panel_name tear_elim Tearing elimination 0=off, 1=on+venc_type Output type (video encoder only): "composite" or "svideo"
I think we could have a better name here. "venc" name is quite obscure
on the user level. And it's not even quite correct, venc stays the same,
it's just the output that is changed. "output_type"? "connector"?
"connector_type"?
quoted hunk
There are also some debugfs files at <debugfs>/omapdss/ which show information
about clocks and registers.
@@ -485,16 +485,69 @@ unsigned long venc_get_pixel_clock(void)return13500000;}+staticssize_tdisplay_venc_type_show(structdevice*dev,+structdevice_attribute*attr,char*buf)+{+structomap_dss_device*dssdev=to_dss_device(dev);+constchar*ret;++switch(dssdev->phy.venc.type){+caseOMAP_DSS_VENC_TYPE_COMPOSITE:+ret="composite";+break;+caseOMAP_DSS_VENC_TYPE_SVIDEO:+ret="svideo";+break;+default:+ret="unknown";+break;+}
Would it be better to return an error here? It would be nice to have
matching input and output for the sysfs file. And generally speaking,
the default branch should never happen.
On Mon, Apr 23, 2012 at 3:23 PM, Tomi Valkeinen [off-list ref] wrote:
On Thu, 2012-03-29 at 02:45 +0300, Grazvydas Ignotas wrote:
quoted
VENC type (composite/svideo) doesn't have to be fixed by board wiring,
it is possible to provide both connectors, which is what pandora does.
Having to recompile the kernel for users who have TV connector types
that's don't match default board setting is very inconvenient, especially
for users of a consumer device, so add support for switching VENC type
at runtime over a new sysfs file venc_type.
Signed-off-by: Grazvydas Ignotas <redacted>
---
Documentation/arm/OMAP/DSS | 1 +
drivers/video/omap2/dss/venc.c | 55 +++++++++++++++++++++++++++++++++++++++-
2 files changed, 55 insertions(+), 1 deletions(-)
"pal" and "ntsc"
panel_name
tear_elim Tearing elimination 0=off, 1=on
+venc_type Output type (video encoder only): "composite" or "svideo"
I think we could have a better name here. "venc" name is quite obscure
on the user level. And it's not even quite correct, venc stays the same,
it's just the output that is changed. "output_type"? "connector"?
"connector_type"?
I'll go for output_type then, connector* associates with fixed hardware to me.
I'll take care of other comments too.
--
Gražvydas