All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Hans Verkuil <hverkuil@xs4all.nl>
Cc: Arvydas Sidorenko <asido4@gmail.com>, linux-media@vger.kernel.org
Subject: Re: [RFCv2 PATCH 01/12] stk-webcam: the initial hflip and vflip setup was the wrong way around
Date: Mon, 11 Feb 2013 15:55:08 +0100	[thread overview]
Message-ID: <5119064C.8040807@redhat.com> (raw)
In-Reply-To: <201302111451.31133.hverkuil@xs4all.nl>

Hi,

On 02/11/2013 02:51 PM, Hans Verkuil wrote:
> On Mon February 11 2013 14:41:08 Hans de Goede wrote:
>> Hi,
>>
>> On 02/11/2013 02:21 PM, Hans Verkuil wrote:
>>> On Mon February 11 2013 14:08:44 Hans de Goede wrote:
>>>> Hi,
>>>>
>>>> Subject: stk-webcam: the initial hflip and vflip setup was the wrong way around
>>>>
>>>> No it is not.
>>>
>>> You are right, that patch makes no sense. It was a long day :-)
>>>
>>>> On 02/10/2013 06:52 PM, Hans Verkuil wrote:
>>>>> From: Hans Verkuil <hans.verkuil@cisco.com>
>>>>>
>>>>> This resulted in an upside-down picture.
>>>>
>>>> No it does not, the laptop having an upside down mounted camera and not being
>>>> in the dmi-table is what causes an upside down picture. For a non upside
>>>> down camera (so no dmi-match) hflip and vflip should be 0.
>>>>
>>>> The fix for the upside-down-ness Arvydas Sidorenko reported would be to
>>>> add his laptop to the upside down table.
>>>
>>> That doesn't make sense either. Arvydas, it worked fine for you before, right?
>>
>> Yes, it probably worked before, but not with...
>>
>>> That is, if you use e.g. v3.8-rc7 then your picture is the right side up.
>>
>> 3.8 will show it upside down for Arvydas
>>
>> The story goes likes this:
>>
>> 1) Once upon a time the stkwebcam driver was written
>> 2) The webcam in question was used mostly in Asus laptop models, including
>> the laptop of the original author of the driver, and in these models, in
>> typical Asus fashion (see the long long list for uvc cams inside v4l-utils),
>> they mounted the webcam-module the wrong way up. So the hflip and vflip
>> module options were given a default value of 1 (the correct value for
>> upside down mounted models)
>>
>> 3) Years later I got a bug report from a user with a laptop with stkwebcam,
>> where the module was actually mounted the right way up, and thus showed upside
>> down under Linux. So now I was facing the choice of 2 options:
>> a) Add a not-upside-down list to stkwebcam, which overrules the default
>> b) Do it like all the other drivers do, and make the default right for
>> cams mounted the proper way and add an upside-down model list, with models
>> where we need to flip-by-default.
>>
>> Despite knowing that going b) would cause a period of pain where we were
>> building the table (ie what we're discussing now) I opted to go for option
>> b), since a) is just too ugly, and worse different from how every other
>> driver does it leading to confusion in the long run.
>>
>> IOW this is entirely my fault, and I take full responsibility for it.
>
> Ah, OK. Now it makes sense. I wasn't aware of this history and it (clearly)
> confused me greatly.
>
> Can you perhaps provide me with a patch that adds some comments to the source
> explaining this. And in particular with which kernel this change took place?

Feel free to copy my 1) - 3) From above to a comment, step 3 landed in kernel 3.6
(you doing it seems better then me doing a patch conflicting with your patchset)

> The next time some poor sod (e.g. me) has to work on this the comments should
> explain this history.

Ack.

Regards,

Hans

  reply	other threads:[~2013-02-11 14:52 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-10 17:52 [RFCv2 PATCH 00/12] stk-webcam: v4l2-compliance fixes Hans Verkuil
2013-02-10 17:52 ` [RFCv2 PATCH 01/12] stk-webcam: the initial hflip and vflip setup was the wrong way around Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 02/12] stk-webcam: remove bogus STD support Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 03/12] stk-webcam: add support for struct v4l2_device Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 04/12] stk-webcam: convert to the control framework Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 05/12] stk-webcam: don't use private_data, use video_drvdata Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 06/12] stk-webcam: add support for control events and prio handling Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 07/12] stk-webcam: fix querycap and simplify s_input Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 08/12] stk-webcam: zero the priv field of v4l2_pix_format Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 09/12] stk-webcam: enable core-locking Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 10/12] stk-webcam: fix read() handling when reqbufs was already called Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 11/12] stk-webcam: s_fmt shouldn't grab ownership Hans Verkuil
2013-02-10 17:52   ` [RFCv2 PATCH 12/12] stk-webcam: implement support for count == 0 when calling REQBUFS Hans Verkuil
2013-02-11 13:08   ` [RFCv2 PATCH 01/12] stk-webcam: the initial hflip and vflip setup was the wrong way around Hans de Goede
2013-02-11 13:21     ` Hans Verkuil
2013-02-11 13:41       ` Hans de Goede
2013-02-11 13:51         ` Hans Verkuil
2013-02-11 14:55           ` Hans de Goede [this message]
2013-02-11 15:11             ` Anca Emanuel
2013-02-11 15:32         ` Arvydas Sidorenko
2013-02-12  8:28           ` Hans Verkuil
2013-02-14  8:12             ` Hans Verkuil
2013-02-14 10:13               ` Arvydas Sidorenko
2013-02-12  8:30   ` Hans Verkuil

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5119064C.8040807@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=asido4@gmail.com \
    --cc=hverkuil@xs4all.nl \
    --cc=linux-media@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.